`<maplink>` and `<mapframe>` wiki markup needs to specify a list of Wikidata IDs to get shapes stored in the OSM database. This way, someone may add a shaded area (e.g. highlight a city/state/country) by specifying their Wikidata ID, instead of copy/pasting the whole geojson with a complex geometry into wikitext.
There are two ways we can do it: via params and by modifying content (geojson) format:
==== As attribute
```lang=html
<mapframe ... show="wikidata:Q12345,wikidata:Q67890">
```
* PROS: simple, integrates well with other group/show concepts
* CONS: hard to specify styling parameters
==== As geojson
```lang=json
{
"type": "WikidataShape",
"properties": { ... }, // same as simple styling
"ids": [ 12345, 67890 ] // Qnumbers
}
```
* PROS: Allows styling, easy to enforce syntax
* CONS: not standard geojson
==== Implementation thoughts
The service returns data as highly optimized TopoJSON, with each object IDed with Qnumber. Once decoded into GeoJSON, each Q id is given as a separate feature object:
```lang=json
{
"type": "FeatureCollection",
"features": [{
"type": "Feature",
"id": "Q12130",
"properties": {},
"geometry": { "type": "MultiPolygon", ... }
}, { ... }, { ... }]
}
```
**Parsing**: More optimally we should use the [[ https://github.com/mbostock/topojson | TopoJSON library ]], but if we want "all you can eat", we could use the [[ https://github.com/mapbox/leaflet-omnivore | leaflet-omnivore ]].
**Optimization**: To get the best mileage out of TopoJSON, all maps on the page should combine all their requests into one, instead of each retrieving their own. It may be very wasteful for multiple maps to each generate nearly identical request to the server.