Open 1ec5 opened 11 months ago
And if there’s no Wikipedia article, the same API call we’re making to Wikipedia would yield a similar excerpt (image plus description) if we point it to the Wikidata API instead.
Would you recommend we deemphasize the need for Wikipedia links altogether? (I'd love that)
Would you recommend we deemphasize the need for Wikipedia links altogether? (I'd love that)
Deemphasizing is probably the right word. I wouldn’t go so far as to start removing them yet, but if we have a fallback to find the Wikipedia content using wikidata
, then there’s much less need to promote wikipedia
tagging on new features.
@ZeLonewolf implemented an extension for Chrome and Firefox that automatically resolves QIDs in the openstreetmap-website inspector to human-readable blurbs from Wikidata. We should integrate the script that powers this extension into ohm-inspector.
Would my extensions work out of the box if I allowed it to run on OHM?
Most likely.
One thing you may run into is dealing with CORS issues. The plugin avoids that problem with permissions declarations that the browser knows to allow.
Do you mean that the Wikidata API might disallow requests from within openhistoricalmap.org? ohm-inspector already makes requests to the Wikipedia API, which is essentially the same thing.
If a feature is tagged with
wikipedia
, the inspector will show a multimedia excerpt of the Wikipedia article. It should do the same if the feature is only tagged withwikidata
but notwikipedia
. For example, this relation is taggedwikidata=Q3275007
; since Q3275007 on Wikidata links to the article “Lunken Airport” on the English Wikipedia, the inspector should show an excerpt from that article, including the following image:To determine the Wikipedia article associated with a Wikidata QID, we could use the Wikidata API or Hub.