Page MenuHomePhabricator

Wikidata PageBanner extension
Closed, ResolvedPublic

Description

It would be great to package up the awesome work that the Wikivoyage community has been doing on page banners. Sadly these page banners are restricted by the template system and to be truly mobile friendly/performant we would need to package it up as its own separate extension.

The banner images would use JavaScript to determine the best banner size to use for the current device.
The source of the image would be configurable.
https://www.wikidata.org/wiki/Property:P948 for Wikivoyage.

Let's make this happen!

Note: The mobile web team is currently interested in this for mobile projects.

Phases of the project (draft):

  1. Set up a test MediaWiki server on Labs
  2. Create an extension that shows a hardcoded banner on all pages (desktop website)
  3. Modify this extension to take the banner from Wikidata
  4. Create a user interface that allows anyone to modify a banner directly from the wiki
  5. Set up a second MediaWiki server on Labs, and set up the extension on it
  6. Install the extension on a live small Wikivoyage, which one will be decided in a few months
  7. If time allows, imagine and implement a way to override a article's banner locally, probably within the wikicode or with a special Wikidata variable

Phases of the project ( final ) - taken from the proposal and slightly tweaked:
Phase I: Get a mediawiki test lab instance and create and deploy the basic version of the extension which simply displays a banner image given to it through the parser hook
Phase II: Add fetching of default banner value from wikidata and add functionality to load banner image of varying sizes.
Phase III: Add banner customization options to the extension as well as styles.
Phase IV: Create horizontal TOC at the bottom of the banner.
Phase V: Make the banner responsive so that it renders well on Mobile View as well.
Phase V: Create and integrate the image chooser UI into the banner
Phase VI: Create unit tests,Deploy and test the final extension on mediawiki-test labs ,document the extension

Related Objects

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes

The whole idea sounds good to me. As a WV user and frequent page banenner editor, I have some concerns:

  1. I agree we need to maintain the possibility of having different page banner pictures in different language versions or projects.

Ideally I would imagine an edit button on the banner which when clicked pops up an input field where you can search for an image on commons and saves as a page property separate to wikitext. Would this be sufficient or would it need to be part of the wiki text?

Searching for an image is usually not the whole story. The image needs usually quite a bit of editting, including resizing (cropping) to 7:1 ratio, sometimes rotation and maybe some other corrections. After that the file is saved to commons under a new name (under special naming convention).

  1. When banner file is added locally with the pagebanner template, the administrators maintain certain control over quality of the banners during patrolling new changes. If the property is only changed in wikidata, WV community has not much chance to check if the banners criteria were maintained.
Sumit added a comment.Mar 15 2015, 5:58 PM

Searching for an image is usually not the whole story. The image needs usually quite a bit of editting, including resizing (cropping) to 7:1 ratio, sometimes rotation and maybe some other corrections. After that the file is saved to commons under a new name (under special naming convention).

@Danapit, if I'm not wrong, the final banners are stored under http://commons.wikimedia.org/wiki/Category:Wikivoyage_banners and its sub-namespaces, in which case we can restrict the searching of images to only those namespaces rather than the entire wikimedia commons, so that we have only standardized approved banners

Yes. The banners are specifically created for each article, then stored within this category in commons and immidiatelly used. That means that there would be hardly any banners which are not used somewhere (except when someone created a small number of alternative banners for some article and then selected one of them). I don't think there are actually users making WV banners withoutr immidiate use of them - so there isn't anything like a stock of WV banners. And using each banner for only one article at a time (with a few exceptions) is one of the criteria for WV banners use.

On https://it.wikivoyage.org we store the banner locally without using the one on wikidata because we add a description for each banner, so we can't allow that the image will be changed from wikidata. We just have a category that list the articles that have a different local banner from the one on wikidata in order to discuss about its change.

Note this extension doesn't need to be installed everywhere to start with so we could trial this on english wikivoyage first.

Could the description be kept in wikidata too?

This description could be kept on Wikidata if there is a convenient UI to edit it from Wikivoyage.
Of course, the description would be different (or non-existent) for each language, though.

Qgil added a comment.Mar 17 2015, 7:56 AM

GSoC and Outreach have opened their application period, and we need to decide whether this project idea is on or out for this round. If you want an intern to work on this task in the next months, please fill the description. If not, let's move this task out of the way for this round.

Qgil: I think there is matter for a GSoC task, and the benefits would be great for Wikivoyage but also as an experiment for all wikis.

I can act as a Wikivoyage-side contact if you want. I successfully served as a GSoC mentor last year.

Andyrom75 added a comment.EditedMar 17 2015, 8:52 AM

Image description, more than image selection, are not objective data, so it should stay in the specific project.
FYI descriptions are managed by en:voy articles, although are not used by a big part of them.

IMHO, if you want a broader test, you should allow the use of local data, like other tool that Wikivoyage used for map (POI, article coverage, GPX, etc...)

Qgil added a comment.Mar 17 2015, 11:30 AM

Good! We have a second mentor. Please add the skills needed and some microtasks, and we will add this task to the featured project ideas.

Niharika updated the task description. (Show Details)Mar 17 2015, 12:32 PM

@Nicolas_Raoul I added you as a co-mentor. Please add the skills needed and possible microtasks so we can open this to students. Thank you!

FDMS removed a subscriber: FDMS.Mar 17 2015, 10:30 PM
Qgil added a comment.EditedMar 18 2015, 7:23 AM

@Nicolas_Raoul, @Jdlrobson, the microtasks listed in the description look like steps for implementing the actual project idea. We are talking about really small tasks that someone can complete in 2-4 hours to be considered as part of the evaluation of candidates, right now. Usually they are good first bug tasks in Phabricator related to the project idea.

Here is a query with a list of potential candidates: https://phabricator.wikimedia.org/maniphest/query/MvVomxtsVWtM/#R

Also, in skills "Software development" is too broad. Which programming languages or frameworks or something?

If "Software development" is too broad, how about asking for PHP skills? Although I feel that anyone with software development skills can get up to speed with PHP in a day or two. We can also ask for MediaWiki development experience. Requiring these two skills is OK if you can afford to exclude many candidates, I guess.

Thanks for the explanation of microtasks.
How about this one, moving a small feature into an extension: https://phabricator.wikimedia.org/T44913
And maybe this one, deep in Wikidata, though I am not sure how "Easy" it is: https://phabricator.wikimedia.org/T56085

I move the list of tasks to a different paragraph, it might be useful later.

By the way, my google-melange identifier is nicolas_raoul in case you need it.

Sushrutsg added a subscriber: Sushrutsg.EditedMar 18 2015, 5:43 PM

Hi,
I'm interested in working for this project idea. Could you please assign me to the micro-task(s)?
Thanks!

@Sushrutsg just jump in and start working on them. :)

Qgil updated the task description. (Show Details)Mar 19 2015, 9:36 AM

We're holding an IRC meeting on March 25, at 1700 UTC for prospective GSoC and Outreachy participants with Wikimedia, on #wikimedia-office channel. Do join us!

Hello! The IRC meeting tomorrow has been shifted to #wikimedia-ect channel. Looking forward to seeing you there. :)

I've now setup https://phabricator.wikimedia.org/project/profile/1158/ so we can start scoping out the needs of this extension. Stakeholders should feel free to dive in and open tasks describing how this should look.

Bene added a subscriber: Bene.Apr 8 2015, 2:32 PM
Bene added a comment.Apr 8 2015, 2:41 PM

I'd really like to take this task and already have some ideas how this could be managed. However, I'm unfortunately am not eligible for GSoC. Do you already have a student who wants to work on this or can I tackle this not within the scope of GSoC?

Qgil added a comment.Apr 8 2015, 2:53 PM

@Bene, thank you for your interest in this task, but we cannot disclose any information about GSoC / Outreachy until April 27th.

Meanwhile, maye there are other open tasks that would welcome your help? :)

@Bene just make sure you subscribe to this phabricator task and I'll post any updates. I'll be keen to get your involvement around this at some point -this is open source project after all. If this is a GSoc project 'm sure we can find a way for you to help contribute without interfering with that project.

Can I tempt you to help me out in Gather [1] in the mean time? It's a new and I think exciting project that I'm maintaining with several others and it would get you familiar with our codebase :-)
[1] https://www.mediawiki.org/wiki/Extension:Gather

@Jdlrobson, you need to sign up on http://www.google-melange.com/gsoc/homepage/google/gsoc2015 in order to evaluate incoming proposals.

@Nicolas_Raoul you too need to sign up on Melange. :)

@NiharikaKohli I already had an account (nicolas_raoul) so I have sent a connection request to the organization "wikimedia" :-)

@Jdlrobson, @Nicolas_Raoul Not sure you're getting the melange emails. We need your comments on the proposal you want to mentor urgently. Please do this as soon as possible.
Thanks.

I was receiving many emails about totally unrelated projects so I unsubscribed, thinking the discussion were available online anyway.
I re-subscribed now.

Can the discussions be seen on a Google Group or somewhere similar? Sorry for the trouble!

@Nicolas_Raoul This is a one time thing, I believe. You can see the relevant discussion on the proposals. You can comment and rate the proposal you want to pick so I can assign it to you.
Thanks!

Wrh2 removed a subscriber: Wrh2.Apr 17 2015, 2:57 AM
Deskana removed a subscriber: Deskana.Apr 30 2015, 7:00 PM
Lydia_Pintscher moved this task from incoming to hold on the Wikidata board.May 4 2015, 12:57 PM
Bene added a comment.May 4 2015, 5:26 PM

I'm not very happing with naming this Wikidata Page Banner extension as the Wikidata access should be optional. The extension should also work without Wikidata access on other MediaWiki installations so perhaps renaming this to Page Banners only would be more appropriate.

We should reserve the name at least and then decide on end of project - we may result in one extension or 2 extensions... (I'm not sure how complex the Wikidata aspect will be :-))

Niharika assigned this task to Sumit.May 12 2015, 1:17 PM
Sumit updated the task description. (Show Details)May 23 2015, 3:18 PM
Lydia_Pintscher triaged this task as Normal priority.Jun 12 2015, 1:19 PM

Hello!

End of GSoC is fast approaching. 17 August is "Suggested pencils down" deadline and 21 August is "Firm pencils down" deadline. It is expected that you don't dive into new features which might take longer than two weeks to complete and instead work on polishing up your project, testing thoroughly and getting your code merged into the main branch. I hope this project is almost complete so you can merge it and make it available to everyone as quickly as possible. :)

A few questions (for both mentors and student):

  • Are you confident in completing the project on time?
  • By when do you think you can merge the code, if at all?
  • Are there any major blockers or important missing features?

We are looking for projects which are (nearly) complete to feature on our post on Wikimedia and Google OSPO's blogs (for example: http://google-opensource.blogspot.in/2015/02/google-summer-of-code-wrap-up-processing.html). If you're interested in getting yours up there, hurry up and get this finished!

The hard deadline on getting code merged is September. T101393: Goal: All completed GSoC and Outreachy projects have code merged and deployed by September for details.

We'll be asking the students to demo their projects towards the end of the program as well.

Good luck!

@NiharikaKohli we're looking to get this deployed on Wikivoyage.org next week.
Potentially this could be a good project to feature in your post. @Sumit has done a great job, and hopefully the deploy will go well without too many hiccups and there will be a happy community benefiting from it.

You can see a sneak preview on: http://pagebanner.wmflabs.org/wiki/Agra

Awesome. @Sumit, could you write up a short blurb about the project so I can incorporate it in the blog post?
Thanks and good job!

Hi, I have associated two blocked-by tasks with this project.

For the student:

  1. Please go through the checklist in the end-term evaluation and fill out the fields which require any links. The checkboxes are for the mentor(s) only. Adding information on the past projects page is your task.
  2. Ensure that you have completed all the items listed in the end-term evaluation task. If there's a strong reason about why a particular item was not completed, please comment on the task and we shall look into it.
  3. Wrap-up report is mandatory and so is a demo-able link to the project (either in production or in a demo server).
  4. If you want your project to be featured in the blogpost on the Google OSPO blog, kindly comment back with a short, catchy description of the project along with a screenshot.

@Sumit can you confirm you have read and are doing the above?
@NiharikaKohli do I need to do anything at this point? (I assume you will poke me when I do need to do something! :))

Restricted Application added a project: Wikidata. · View Herald TranscriptAug 18 2015, 11:11 PM
kaldari removed a subscriber: kaldari.Aug 19 2015, 12:54 AM

@NiharikaKohli do I need to do anything at this point? (I assume you will poke me when I do need to do something! :))

You can go through the end-term evaluation task any time you feel like, after @Sumit has completed it with the required links. Also, you need to submit an evaluation on Melange which will be available after 21st August 1900 UTC. :)

Sumit added a comment.Aug 30 2015, 1:17 PM
In T77925#1527209, @NiharikaKohli wrote:

Awesome. @Sumit, could you write up a short blurb about the project so I can incorporate it in the blog post?
Thanks and good job!

@NiharikaKohli, I've written a short post about the project here on my blog - http://blog.sumitasthana.net/End_of_GSoC2015/
If it could be of any help for acting as a referral or for putting it on Wikimedia blog, please let me know!
If any changes be needed, let me know about the same. :)

@NiharikaKohli, I've written a short post about the project here on my blog - http://blog.sumitasthana.net/End_of_GSoC2015/
If it could be of any help for acting as a referral or for putting it on Wikimedia blog, please let me know!
If any changes be needed, let me know about the same. :)

That's a very nice post, which could have been made a little bit nicer with a few screenshots here and there. Add some? :)

/me makes note to fork codezee's blog repo and write her own! It's quite nice. :)

Sumit added a comment.Aug 30 2015, 1:54 PM

That's a very nice post, which could have been made a little bit nicer with a few screenshots here and there. Add some? :)

Done!

I guess so :-)
Thanks everyone!

Niharika closed this task as Resolved.Aug 31 2015, 2:51 PM

:D Indeed. Well done, Sumit! I really hope you had fun and are planning to stick around!