Page MenuHomePhabricator

Prototype user script for adding filter behavior to the Wikimedia tutorials page
Open, Needs TriagePublic

Description

Background

Wikimedia tutorials is a page on mediawiki.org intended to help people learn about Wikimedia technologies by aggregating both on-wiki and off-wiki tutorials. To help people choose a tutorial, the page uses topic tags via Template:Topic.

To do

  • Create a user script as a proof of concept for adding filter behavior based on topic tags. See https://www.mediawiki.org/wiki/Gadget_kitchen for more information on user scripts.
  • Review and test
  • Start the process of enabling it as a gadget on the Wikimedia tutorials page

Concept

Create a gadget (prototype as a user script!) that adds search/filter behavior to the page by first walking the DOM to extract the topics, keywords, etc that can be used for filtering. Then add inputs to the page via js that are bound to events that walk the collected data and show/hide divs as appropriate. The js used in Hay's Directory is relatively easy to understand. Template:Topic adds a data-topic="..." attribute now. Something like $("span[data-topic=Python]") will find all the "Python" topic tags. And something like $("span[data-topic=Python]").parents(".mw-tpl-colorbox").css( "border", "2px red solid" ) would then highlight the cards that contain the Python topic tag.

Related Objects

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptSep 24 2020, 4:13 PM

Sir I want to contribute in this issues...

Esther.Osayande added a subscriber: Esther.Osayande.

Hello mentor, could you please assign this task to me.
Thanks.

Aklapper removed Esther.Osayande as the assignee of this task.Oct 9 2020, 11:39 AM
Aklapper updated the task description. (Show Details)

In my understanding, several people are welcome to work on this task at the same time. Hence I'm unassigning this task, but please feel welcome to work on this. :)
Also see https://www.mediawiki.org/wiki/How_to_become_a_MediaWiki_hacker#Feedback,_questions_and_support - thanks!

Gaurlaksh added a subscriber: Gaurlaksh.
This comment was removed by Gaurlaksh.

Hi @Gaurlaksh, thanks for your interest and welcome to Wikimedia Phabricator! Please read the previous comments in this ticket, and please check https://www.mediawiki.org/wiki/How_to_become_a_MediaWiki_hacker#Suggested_reading - thanks a lot!

Aklapper removed Gaurlaksh as the assignee of this task.Oct 13 2020, 9:47 AM