Page MenuHomePhabricator

Map marker is misplaced when loading from PCS
Closed, DeclinedPublic1 Estimated Story Points

Description

Steps to reproduce

  1. Ensure app is loading from MCS
  2. Change app language to de
  3. Open [[Watkin's Tower]]
  4. View the map in the article infobox

Expected results

Map marker appears over London

Actual results

Map marker appears on the southern coast of England. (It is correctly placed in the web version and when loading from mobileview.)

Event Timeline

https://de.wikipedia.org/api/rest_v1/page/mobile-sections/Watkin%E2%80%99s_Tower provides the following geo coordinates:

"geo": {
  "latitude": 51.555556,
  "longitude": -0.279444
},

The Koordinaten link from de:Watkin's Tower shows the same coordinates to me:

Geo URI	geo:51.555556,-0.279444

Edit: Ok, just realized that this is not about the geo portion missing but having the wrong location in there. Updated the comment to reflect that.

Duh, the coordinates I was talking about don't even get used by the app. This is about a marker in an image in the infobox.

Looks like an issue with Template:Location map in Parsoid. VE has problems with this template, too (T52714).

Supporting the location map feature would be an unreasonable amount of effort for a legacy feature that has now been replaced by proper software support for maps. Other software components don't support them either, see e.g. T193822: Pushpin disappears after opening image in mediaviewer or T64572: Media Viewer and location map overlays. I would suggest declining and pointing people to Maps (Kartographer) as a replacement for the template.

From Android email:

Call "Land (Deutschland)". Have a look at the map. Try different devices and turn them to landscape/portrait.

Thats the problem with all those maps. Try "St. Helena (Island)". The difference can bee about 2000km, depending on the device/sreen.

+1 user through the Android support email:

The map was marked incorrectly in the Qing Dynasty and Beiyang governments. The incorrectly marked places were marked in red.

1280px-Map-Qing_Dynasty_1820.jpg (972×1 px, 274 KB)

Screenshot_20221219_204422_Samsung Internet.jpg (1×1 px, 146 KB)

+1 user through the Android support email:

Beiyang Government or Beijing Government It is not a map from In 1924, the Mongolian People's Republic was established. And exclude the Republic of Tuva, parts of Central Asia, Afghanistan, and Bhutan.

600px-Republic_of_China_(orthographic_projection,_historical).svg.png (598×600 px, 191 KB)

+1:

The map of Bohai is wrong. It completely occupied Liaodong (the place marked with a red circle) and it was also Bohai territory.

600px-Balhae_map.png (600×600 px, 167 KB)

+1:
Daegu Metropolitan City was incorporated into Gunwi-gun.

Screenshot_20230703_181847_Samsung Internet.jpg (985×713 px, 116 KB)

MSantos renamed this task from Map marker is misplaced when loading from MCS to Map marker is misplaced when loading from PCS.Dec 5 2024, 3:21 PM
MSantos moved this task from Backlog to Needs Investigation on the Content-Transform-Team-WIP board.

There is an issue with the Vorlage:Infobox_Verwaltungseinheit_in_Deutschland template on German Wikipedia, visible among others on
https://de.wikipedia.org/api/rest_v1/page/mobile-html/M%C3%BCnchen (compare to the position of the dot on https://de.wikipedia.org/wiki/M%C3%BCnchen) and https://de.wikipedia.org/api/rest_v1/page/mobile-html/Helgoland (compare to https://de.wikipedia.org/wiki/Helgoland).

A priori, the issue comes from the fact that the red dot is shown relatively to the table cell rather than the map itself (to be confirmed), and that these do not have the same width on the PCS rendering than on the desktop rendering. Why exactly that is the case may warrant a look, but it seems to me that the position of the dot should not be dependent on that (from a template design point of view). It's also quite unclear to me if the issue also triggers on mobile-web, where the responsive design seem keep the infobox width more-or-less stable.

Additionally, some issues reported on this ticket have 0 information on the impacted page (or even wiki); some others (such as https://de.wikipedia.org/api/rest_v1/page/mobile-html/Watkin%E2%80%99s_Tower) have apparently been fixed by template/module edit.

I'll have a last look at the table width considerations, but a priori the fix is on the template rather than on the code base.

PCS does indeed add wrappers around a number of tables to make them collapsable and to ensure that they fit the mobile screen. As far as I can tell, this is a desirable behaviour. The styles are marked as "!important", which overrides the template-defined table width; if the fixed width is the desired behavior, the template can be edited to either override the override or to re-define an element in the infobox with the desired fixed size so that the dot lands on the right place. Whether that is a good idea from a "mobile responsive" perspective is out of the scope of my knowledge but, in my view, this is not a PCS bug.