Page MenuHomePhabricator

Wikidata identifiers are not linked on mobile
Closed, DeclinedPublic


Identifiers on items are not linked on mobile. They should be.
This is done by this gadget:

Event Timeline

Jdlrobson set Security to None.

Mobile doesn't support gadgets so this will need to be moved into the wikidata extension itself to work.

What is an identifier?

Hmm @MaxSem said that was possible?

An identifier is for example tt0133093 which is then linked to by this gadget on

I see. So it takes a value and enhances it e.g. turns it into a link e.g. takes the IMDB identifier and makes it a link
Any reason this is not done on the backend?


We don't have it in Wikibase itself so far for two reasons:

  • Wikibase should not have any knowledge about special properties. Here it would have to know that some properties turn their value into links. We'd like to avoid this as much as possible.
  • We didn't have a proper way to store the URL used for expanding the identifier. We have that now with statements on properties.

So we will need to figure out a way to do that in Wikibase as well but I am not sure how yet. Until then it'd be good to get this working with the gadget.

It should be possible to migrate this Gadget into a module and add the dependencies: AuthorityControl[ResourceLoader|default|dependencies=wikibase.api.RepoApi]|AuthorityControl.js
Another way would be to add a wrapper JS module for it (to make sure, that the dependencies are loaded) and load the Gadget with mw.loader.load( 'gadget-url' );

But it should be configurable to be a specific module for wikidata.

Mobile has no plans to support global site gadgets right now. They make it really difficult to debug issues and lack a code review process which is pretty important when it comes to exposing JS code to mobile users.

I think if we can find a way to do this on the backend in a generic way this would be the best solution for the long term lifespan of this project.

Mobile doesn't support gadgets so this will need to be moved into the wikidata extension itself to work.

Um, I'm pretty sure it does if you set the target properly? Though AFAIS 'wikibase.api.RepoApi' doesn't set a target for mobile, so it won't work.

Yep but no easy way of setting that target. I guess what I'm saying is I discourage the use of a global gadget on mobile. User scripts are fine but I think we have to be more responsible when considering the quirks, performance issues and capabilities of mobile phones.

I think we all agree that ultimately it should be in Wikibase itself somehow. Question is: Can we do anything until that happens?

wikibase.api.RepoApi looks like it's safe to slap a mobile target on it and load it on demand - after it's mibilified, the above change should just work. However, for me this gadget doesn't work in Chrome even on desktop.

We don't know if it is safe. I would want to review this firstand would still prefer us to find a non gadget based solution.

Jdlrobson renamed this task from identifiers are not linked on mobile to Wikidata identifiers are not linked on mobile.Jan 20 2015, 11:59 PM
Jdlrobson moved this task from Needs triage to Triaged on the Mobile board.
Lydia_Pintscher claimed this task.

I am going to close this. We'll solve this with the new datatype for identifiers. No need to keep this ticket open.