Page MenuHomePhabricator

Deprecate <slippymap> provided by MapSources in favor of Kartographer's <mapframe>
Closed, ResolvedPublic

Description

Currently, it adds an iframe to tools.wmflabs.org/wiwosm which is not of production quality and violates our privacy policy.

Current usage is MapSources template on most Wikivoyages, and a single page on dewv.

We need to figure out the precise way to replace <slippymap> in templates (example) and discuss it with community. The actual replacement would not touch too many pages and thus should be fairly straightforward. After that, <slippymap> should be removed completely.

Event Timeline

Ideally <mapframe> is going to use the same syntax (parameters, options / lat, lon, z, w, h, layer, marker, etc. ) as <slippymap>.

@MaxSem A few questions to better understand this change.

  • Does this remove any features provided by <slippymap> (MapSources)?
  • How much work are we asking Wikivoyager's to do to make this change?

I think writing something explaining the need for the change and posting it to the Traveler's Pub for the Wikivoyages would be a good first start. I can draft something up on Meta for translation and posting.

  • Does this remove any features provided by <slippymap> (MapSources)?

<mapframe> already does much more than slippymap, and it supports custom layers for Wikivoyage.

  • How much work are we asking Wikivoyager's to do to make this change?

It doesn't seem to be used much. Searching with [[ https://en.wikivoyage.org/w/index.php?title=Special:Search&profile=all&fulltext=Search&search=insource%3Aslippymap | insource:slippymap ]] and [[ https://en.wikivoyage.org/w/index.php?title=Special:Search&profile=all&fulltext=Search&search=insource%3Ageolink | insource:geolink ]] gives almost no results.

As Max said it looks like there are only a few instances where it is being used, primarily in Wikivoyage:Map_sources copies across the Wikivoyages.

They all contain the following use of slippymap:

<slippymap lat="{latdegdec}" lon="{londegdec}" z="{osmzoommap}" w="360" h="360" layer="Mapnik" marker="0" />

Examples:

https://en.wikivoyage.org/wiki/Wikivoyage:Map_sources

https://ru.wikivoyage.org/wiki/Wikivoyage:Источники_карт

https://it.wikivoyage.org/wiki/Wikivoyage:Fonte_della_mappa

https://uk.wikivoyage.org/wiki/Вікімандри:Джерела_карт

https://fr.wikivoyage.org/wiki/Wikivoyage:Sources_de_cartes

Since these appear to be nearly identical am I correct that theMapframe syntax would look something like this?

{{Mapframe|{latdegdec}|{londegdec}|{osmzoommap}|height=360|width=360|layer=W}}

I'm not sure of the exact syntax. Is this more complicated than I'm understanding? Some help would be appreciated.

If that's the change that is needed, I think posting a request on the talk pages for each instance asking for approval to make the change would suffice. We could follow up in a few days for those that did not have any objections, but were not bothered to make a change.

{{mapframe}} is a template that's not guaranteed to be present everywhere or function the same. A direct syntax should be used: <mapframe latitude="{latdegdec}" longitude="{londegdec}" zoom="{osmzoommap}" width="360" height="360" />

Btw, now <slippymap> is present only in MapSources templates.

Oops German Wikivoyage has in the meantime been migrated [[ https://de.wikivoyage.org/w/index.php?title=Vorlage%3AOpenStreetMap&type=revision&diff=944128&oldid=798211 | from slippymap to the {{mapframe}} template ]]. But this involves Scribunto and such. Perhaps this is as good.

Oops, turns out to catch everything you need to search for insource:/slippymap/. I've made a pass through projects' MapSources templates, and here's what's left, mostly with low usage:

https://el.wikivoyage.org/wiki/%CE%95%CE%B9%CE%B4%CE%B9%CE%BA%CF%8C:%CE%A4%CE%B9%CE%A3%CF%85%CE%BD%CE%B4%CE%AD%CE%B5%CE%B9%CE%95%CE%B4%CF%8E/%CE%A0%CF%81%CF%8C%CF%84%CF%85%CF%80%CE%BF:OpenStreetMap
https://nl.wikivoyage.org/wiki/Sjabloon:OpenStreetMap
https://fr.wikivoyage.org/wiki/Mod%C3%A8le:OpenStreetMap
https://it.wikivoyage.org/wiki/Wikivoyage:Fonte_della_mappa (protected)
https://it.wikivoyage.org/wiki/Template:OpenStreetMap
https://es.wikivoyage.org/wiki/Plantilla:OpenStreetMap (medium usage)
https://es.wikivoyage.org/wiki/Plantilla:Ficha_de_entidad_subnacional (medium usage)
https://vi.wikivoyage.org/wiki/B%E1%BA%A3n_m%E1%BA%ABu:OpenStreetMap (broken anyway)

The code I used was:

{{#tag:mapframe|
| latitude={{#iferror:{{#expr:{latdegdec}+0}}|0|{latdegdec} }}
| longitude={{#iferror:{{#expr:{londegdec}+0}}|0|{londegdec} }}
| zoom={{#iferror:{{#expr:{osmzoommap}+0}}|0|{osmzoommap} }}
| width=360
| height=360
| frameless=
| align=center
}}

I propose that we set a hard removal date, publish in tech news and inform the affected communities.

Per discussion with Chris, I'm setting the sunset to the week of October 24th.

Draft message here: https://meta.wikimedia.org/wiki/User:CKoerner_(WMF)/Slippymap_sunset

@MaxSem If this looks good to you I can ask for translation and post it to the talk pages of the pages you listed early next week.

Page marked for translation and a request made to volunteer translators for help. As I receive completed translations I'll post them to the respective wikis.

I'm going to claim this just so keep it on my radar.

I've posted the notice to the last two templates and asked for clarification on the French Wikivoyage.

Rolland Unger has graciously helped address one of the templates on the Italian Wikivoyage.

If we don't hear back from folks in the next few days I'll post it again at the village pumps early next week to hopefully bring more awareness.

I updated the template https://it.wikivoyage.org/wiki/Template:OpenStreetMap at the Italian Wikivoyage. Unfortunately, I am not an admin at the other Wikivoyage branches to change the coding.

All OpenStreetMap templates adapted.

@RolandUnger, I appreciate you taking the time to fix these templates. Thank you.

I just did another check before I closed this as 'Resolved'.

I think I missed one in my listing, but it is protected.

https://es.wikivoyage.org/wiki/Plantilla:Ficha_de_entidad_subnacional

Now, Template:Ficha_de_entidad_subnacional was also fixed.

Thank you again @RolandUnger.

@MaxSem at this point all references have been removed. I'm reassigning to you to handle the technical side.

Thank you so much, everybody!

It's still doned.