Page MenuHomePhabricator

Localise Module:OSM_Location_map in order to faciliate migration away from Graph:Street map with marks
Open, Needs TriagePublic

Description

Many articles in different Wikipedias used https://www.mediawiki.org/wiki/Template:Graph:Street_map_with_marks. The graph had more than one approach: via inline data or via Wikidata SPARQL query. Inline data is available via Module:OSM_Location_map.

Once this module has added the capability to support SPARQL queries this should cover most of the previous usecases for Template:Graph:Street_map_with_marks.

The module then needs to be set up to be localised to work in other languages with localised template variables.

Event Timeline

Theklan renamed this task from Graph:Street map with marks should work work to Graph:Street map with marks should work.

This could go a similar route to https://en.wikipedia.org/wiki/Template:OSM_Location_map. OSM location was ported from the graph extension. OSM location map uses the kartographer extension, which does support sparql, but OSM location also uses CSS overlays on top of that.

Seddon renamed this task from Graph:Street map with marks should work to Localise Module:OSM_Location_map in order to faciliate migration away from Graph:Street map with marks.Jun 17 2025, 12:18 PM
Seddon edited projects, added Maps (Kartographer); removed Charts.

This is request that should be covered by the capabilities of Kartographer and not the Chart extension. This is already being done with Module:OSM_Location_map. Whilst there are some aspects to using stylable geojsons etc. that would be in the scope of this extension, street maps is not currently one of them. The solution here is to localise https://en.wikipedia.org/wiki/Module:OSM_Location_map in order to be used cross wiki as this covers off most of the use cases and as noted above comes with sparql integration.

We can use Kartographer extension to show points, there's no need to localize OSM Location map for that. However, it should be mentioned that Charts will be unable to do things that Graphs was able to do, and all the graphs using location data should be moved to use Kartographer.

Module:OSM_Location_map via Kartographer plugs much of the features that was being facilited by the graph extension in Template:Graph:Street_map_with_marks. Ideally the module would be localised on mediawiki.org for use across the projects. So the things Graphs used to do here are now mostly covered by a different module through other existing capabilities powered by Kartographer and Lua. I've made some updates to both https://www.mediawiki.org/wiki/Extension:Graph and https://www.mediawiki.org/wiki/Extension:Chart to reflect that more than just the Chart extension will supplant the graph extension.

I have been testing OSM Location map and I'm sorry to say that it doesn't cover what Graph:Street map with marks used to cover. Kartographer can load data from a Wikidata query, Graph could load data from a Wikidata quety, but OSM Location map can only add individual points, without Wikidata query integration. The template is good, but can't be named as a substitute, as it doesn't do the same thing.

I’m not sure I fully understand what you say. So the underlying technology (Kartographer) supports everything we need, only the template/module doesn’t allow us to specify the input? In that case, simply the template should be expanded, no development in Chart is needed. (Personally I always found it strange that we have two ways to show maps, so I’d avoid adding map features to Chart if possible. I can support the capabilities of Kartographer if necessary.)

Oh! Then the documentation lacks that information.

The kartographer documentation covers it, its just the module needs the 5 lines of lua to enable the capability within the template itself.

I've proposed the change here: https://en.wikipedia.org/wiki/Module_talk:OSM_Location_map#Add_compatibility_for_use_with_wdqs_within_mapframe.

@RobinLeicester a huge appreciation for you contributions in rewriting the template in Lua!

Seddon updated the task description. (Show Details)

@Seddon and @Tacsipacsi excellent work on SPARQL for OSM Location map. It is now live, with some starter documentation for the map-wdqs parameters. Is there a beginner's guide to writing a geojson wdqs query that would be helpful to point to?

Along the same lines, OSM Location map has just gone live with a 'map-raw' parameter to display raw geoJSON data files, in a similar way to wdqs. Examples are now included at https://en.wikipedia.org/wiki/Template:OSM_Location_map/ModuleSandbox/doc, and a brief entry in the template doc