Page MenuHomePhabricator

Translate hand made HTML templates into JS generated ones
Closed, DeclinedPublic

Description

We need to move from hand made HTML templates to generated ones to avoid breaking the tool in case of wikidata UI changes.

Event Timeline

Hjfocs created this task.Jun 19 2017, 9:55 AM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJun 19 2017, 9:55 AM
Kiailandi claimed this task.Jul 4 2017, 1:24 PM
Kiailandi moved this task from Upcoming to Doing on the Wikidata-primary-sources board.
Kiailandi renamed this task from Translate HTML templates into PHP to Translate hand made HTML templates into JS generated ones.Aug 3 2017, 8:56 AM
Kiailandi triaged this task as Unbreak Now! priority.
Kiailandi updated the task description. (Show Details)

We can generate the template for our tool starting from the mw.wbTemplates.store.values javascript object which contains the templates used to generate the wikidata pages.
We will probably need to extend the available templates with the ones we need for the Primary Sources tool.

A possible solution could be to add a mw.psTemplates object or even extending the wbTemplates object directly.
Another possible path could be adding our templates to the templates.php file in wikibase-view which declares the same templates.

I am still trying to understand which way is the best one as far as maintainability and best practices are concerned.

Kiailandi added a comment.EditedAug 3 2017, 10:08 AM

Another part in the UI is played by jQuery.wikibase, I still need to understand if and how this library is partially responsible for the templates generation or if it is just used to manipulate the DOM objects at later stages.

I'll try to add some more comments when I'll understand how to leverage both to obtain our final template.

@Kiailandi triaged this task as Unbreak Now! priority.

@Kiailandi: This task has been open for nearly two months. If this task has suddenly become a super urgent crucial task that needs to be fixed immediately, setting anything else aside (see the definition of the "Unbreak now!" priority), please elaborate why. If not, please decrease the task priority. Thanks!

Kiailandi lowered the priority of this task from Unbreak Now! to High.Aug 7 2017, 3:55 PM

@Kiailandi triaged this task as Unbreak Now! priority.

@Kiailandi: This task has been open for nearly two months. If this task has suddenly become a super urgent crucial task that needs to be fixed immediately, setting anything else aside (see the definition of the "Unbreak now!" priority), please elaborate why. If not, please decrease the task priority. Thanks!

My bad, fixed.

It has always been one of the top priorities as a task, but I suppose the best priority is high.

Will fix the other tasks in the same way

Lydia_Pintscher moved this task from incoming to monitoring on the Wikidata board.Dec 22 2017, 4:53 PM
Hjfocs closed this task as Resolved.May 31 2018, 8:57 AM
Hjfocs changed the task status from Resolved to Invalid.

This is unfortunately not possible until a Wikidata UI SDK is made available.

Restricted Application removed a subscriber: Liuxinyu970226. · View Herald TranscriptMay 31 2018, 8:59 AM
Hjfocs changed the task status from Invalid to Declined.May 31 2018, 9:01 AM