Content deleted Content added
→coordinsert problem?: new section |
|||
(33 intermediate revisions by 14 users not shown) | |||
Line 303:
|maxarchivesize = 75K
|counter = 2
|minthreadsleft =
|minthreadstoarchive =
|algo = old(
|archive = Module talk:Coordinates/Archive %(counter)d
}}
Line 378:
:::::::Yeah, I like how frwp does their coordinates. [[User:Galobtter|Galobtter]] ([[User talk:Galobtter|talk]]) 10:04, 1 May 2023 (UTC)
:I revived the indicator change in the sandbox. Some changes were made to the css to ensure 100% similar positioning. CSS for original however is still in place. This means we can do the template change without making a CSS cache mess and we can postpone actual CSS rework to when this change settles. —[[User:TheDJ|Th<span style="color: green">e</span>DJ]] ([[User talk:TheDJ|talk]] • [[Special:Contributions/TheDJ|contribs]]) 09:36, 21 May 2023 (UTC)
::The problem that I reported at 10:59, 5 February 2022 (UTC), which had been fixed, has returned again in the same form. --[[User:Redrose64|<span style="color:#a80000; background:#ffeeee; text-decoration:inherit">Red</span>rose64]] 🌹 ([[User talk:Redrose64|talk]]) 19:22, 28 May 2023 (UTC)
:::@[[User:
::::{{ty}} The live module is now working as expected. --[[User:Redrose64|<span style="color:#a80000; background:#ffeeee; text-decoration:inherit">Red</span>rose64]] 🌹 ([[User talk:Redrose64|talk]]) 19:40, 5 June 2023 (UTC)
{{Admin help|answered=yes}}▼
:Please see [[Module talk:Coordinates#coordinsert feature broken|#Coordinsert feature broken]] up above, which already discusses this problem. —[[User:TheDJ|Th<span style="color: green">e</span>DJ]] ([[User talk:TheDJ|talk]] • [[Special:Contributions/TheDJ|contribs]]) 08:46, 28 April 2023 (UTC)▼
:: {{ping|BrandonXLF}} in case you are interested in this. [[User:Pppery|* Pppery *]] [[User talk:Pppery|<sub style="color:#800000">it has begun...</sub>]] 18:24, 21 May 2023 (UTC)▼
▲:::@[[User:Pppery|Pppery]] The error is caused by the call to <code>frame:preprocess</code> at [[Module:Mapframe#L-599]], but I'm not sure why it's there in the first place. @[[User:Evad37|Evad37]] Do you know if it would be safe to remove the call to <code>frame:preprocess</code>? <span class="nowrap">– [[User:BrandonXLF|<span style="color:blue;">Brandon</span><span style="color:green;">XLF</span>]] ([[User talk:BrandonXLF|talk]])</span> 10:00, 22 May 2023 (UTC)
== Coord2text ==
I would like to call the function coord2text from another module. Can I make [https://en.wikipedia.org/w/index.php?title=
:Seems like pretty straightforward change. —[[User:TheDJ|Th<span style="color: green">e</span>DJ]] ([[User talk:TheDJ|talk]] • [[Special:Contributions/TheDJ|contribs]]) 13:04, 22 May 2023 (UTC)
Line 424 ⟶ 390:
::I am using it to parse wikitext to extract coordinates which can then be imported into wikidata - want more details? — Martin <small>([[User:MSGJ|MSGJ]] · [[User talk:MSGJ|talk]])</small> 21:50, 24 May 2023 (UTC)
:::That's cool, but how is that useful onwiki? I can't see how that would be useful here. And I mean that in the sense of "what are you even doing" and not "oh, Wikidata, go away". :P [[User:Izno|Izno]] ([[User talk:Izno|talk]]) 22:07, 24 May 2023 (UTC)
::::I see I've aroused your curiosity :) I am reading a page like [[User:MSGJ/Sandbox/3|this]] and outputting a page like [[User talk:MSGJ/Sandbox/3|this]] which can then be pasted into [https://quickstatements.toolforge.org QuickStatements] to quickly import data into Wikidata — Martin <small>([[User:MSGJ|MSGJ]] · [[User talk:MSGJ|talk]])</small> 21:51, 27 May 2023 (UTC)
== Protected edit request on 24 May 2023 ==
Line 473 ⟶ 440:
:::{{done}} [[User:Izno|Izno]] ([[User talk:Izno|talk]]) 22:52, 24 May 2023 (UTC)
::::Thanks all! [[User:Jon (WMF)|Jon (WMF)]] ([[User talk:Jon (WMF)|talk]]) 04:48, 25 May 2023 (UTC)
Three more:
*[[Beuvry Communal Cemetery Extension]]
*[[Martyrs' Cemetery, Kobanî]]
*[[St. James Episcopal Cemetery]]
[[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 08:57, 26 May 2023 (UTC)
:These might be pre existing issues. The templates specify coordinates without making use of template coord, but also without specifying NSWE, which is a format that module:mapframe’s parseCoord does not seem to be able to handle ? —[[User:TheDJ|Th<span style="color: green">e</span>DJ]] ([[User talk:TheDJ|talk]] • [[Special:Contributions/TheDJ|contribs]]) 11:24, 26 May 2023 (UTC)
::Those were GIGO problems. They should have been using {{tl|coord}}, and two of the articles had duplicate coordinates. – [[User:Jonesey95|Jonesey95]] ([[User talk:Jonesey95|talk]]) 13:23, 26 May 2023 (UTC)
:::Thanks, it's all good now. [[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 00:33, 27 May 2023 (UTC)
== Protected edit request on 29 May 2023 ==
{{edit fully-protected|Module:Coordinates|answered=yes}}
Copy the code from [[Module:Coordinates/sandbox]] to the main module. I adjusted the code so coordinsert works properly with the indicator in the title. The only difference to the output is that inline coordinates are now wrapped in a {{tag|span|attribs=class="geo-inline"}} tag, but I don't see anywhere where this would be an issue. I also added some manual testcases for when [[Module talk:Coordinates/testcases/manual/display t coordinsert|display=title]] and when [[Module talk:Coordinates/testcases/manual/display it coordinsert|display=inline title]] to verify the changes. The difference between the sandbox and module can be seen [https://en.wikipedia.org/w/index.php?title=Special%3AComparePages&page1=Module%3ACoordinates&page2=Module%3ACoordinates%2Fsandbox here]. <span class="nowrap">– [[User:BrandonXLF|<span style="color:blue;">Brandon</span><span style="color:green;">XLF</span>]] ([[User talk:BrandonXLF|talk]])</span> 19:41, 29 May 2023 (UTC)
:{{done}}<!-- Template:EP --> also made the change to coord2text noted above — Martin <small>([[User:MSGJ|MSGJ]] · [[User talk:MSGJ|talk]])</small> 15:00, 5 June 2023 (UTC)
::{{re|BrandonXLF|MSGJ}} based on timing, it appears that this change has broken page previews. For instance, hovering over [[Free City of Danzig]] shows just the coordinates, rather than the beginning of the article as it should. I haven't looked too closely to see whether this is a bug in the module or page previews, but you ought to consider reverting. [[User:Vahurzpu|Vahurzpu]] ([[User talk:Vahurzpu|talk]]) 03:15, 6 June 2023 (UTC)
:::This needs to be done, but I favor leaving it as is for a short period to allow debugging. [[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 03:54, 6 June 2023 (UTC)
I'm trying to find the documentation to see what popups needs. It starts at [[mw:Page previews]] but I don't think there is anything relevant there apart from the link to the implementation at [[mw:Special:MyLanguage/Extension:Popups]]. That has a FAQ with two items reproduced below without the links.
*How can I remove content from a page preview? Any element marked with the noexcerpt class will be stripped from the summary.
*Where do summaries come from? These are provided by the summary REST API or the TextExtracts API in case your wiki is using the default mwApiPlain gateway.
Some investigation might show why the new coordinates code is messing up the popup preview or how it can be fixed. {{u|BrandonXLF}} is not active at the moment but I'm pinging to alert them. [[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 03:54, 6 June 2023 (UTC)
:Strangely, hovering over [[Tokyo]] shows a proper popup. A lot of other ___location links on that page also work. Some examples where the popup does not work (it shows the coordinates) are [[Australia (continent)]] and [[Regional Representative Council]] and [[United Arab Emirates]], as reported at [[Template talk:Coord#Preview page broken]]. [[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 05:05, 6 June 2023 (UTC)
::The three listed pages have their coords templates defined outside the infobox. None of them are defined with inline accordingly.
::I don't know why that matters, but that's the obvious pattern. [[User:Izno|Izno]] ([[User talk:Izno|talk]]) 05:32, 6 June 2023 (UTC)
:::This smells like [[:phab:T334273]]: because the inline text is hidden via TemplateStyles, and the extracts module doesn't care about TemplateStyles, it decides the text that is being dumped out in the geo-inline is Good Enough. It doesn't have an issue with <code>infobox</code> things because it already yanks all of that before consideration of what it thinks the first paragraph should be.
:::As you can see, I've already argued that this is a flawed expectation for how TemplateStyles should interact with TextExtracts.
:::We can probably work around this locally by adding the <code>noexcerpt</code> class. [[User:Izno|Izno]] ([[User talk:Izno|talk]]) 05:39, 6 June 2023 (UTC)
::::Independently of workarounds, this looks to me like a parsing bug, so I filed {{phab|T338204}} to report it to the maintainers. --[[User:JCrespo (WMF)|JCrespo (WMF)]] ([[User talk:JCrespo (WMF)|talk]]) 07:44, 6 June 2023 (UTC)
▲:
:::::No? [[User:Izno|Izno]] ([[User talk:Izno|talk]]) 16:59, 6 June 2023 (UTC)
:::After the recent edit to Module:Coordinates and an low-substance edit on [[Australia (continent)]] the coordinates no longer appear. The [https://en.wikipedia.org/api/rest_v1/page/summary/Australia_(continent) REST endpoint] is still picking up the empty p and newlines: <code>extract: "\n\n"; extract_html: "<p>\n\n</p>"</code>. Yes, I think it was changing it from a div to a span that did this particular line in. I think we can fix this by changing the hidden inline back to a div and then doing a second passover looking for a div in <code>coordinsert</code>, or changing the regex to be a bit more greedy at the beginning by removing its dependence on the tag. [[User:Izno|Izno]] ([[User talk:Izno|talk]]) 17:12, 6 June 2023 (UTC)
== Protected edit request on 28 September 2023 ==
{{edit fully-protected|Module:Coordinates|answered=yes}}
Add a format=dec4 function to output decimal degrees rounded to four places from data entered as either DMS or higher precision DEC format. The [[Geographical Names Board of Canada|Canadian Geographical Names Database]], [[Geographic Names Information System]], and [[Ordinance Survey]] provide ___location information with seven decimal degrees of precision. The dec4 format will permit the input data to be checked with the original data source while displaying the more reasonable and compact four decimal degrees of precision (+/- 10 m). [[User:Buaidh|<span style="color:white;background-color:#770022;font-weight:bold;"> Buaidh </span>]]<span style="font-size:75%;vertical-align:middle;"> [[w:User talk:Buaidh|talk]] [[Special:EmailUser/Buaidh|e-mail]]</span> 21:57, 28 September 2023 (UTC)
: {{not done}} This is a repost of [[Module talk:Coordinates/Archive 2#Protected edit request on 14 September 2022]], which was closed as needing to be sandboxed and tested. We're a year and two weeks later, and this still hasn't AFAICS been sandboxed and tested. [[User:Pppery|* Pppery *]] [[User talk:Pppery|<sub style="color:#800000">it has begun...</sub>]] 22:16, 28 September 2023 (UTC)
== Interface-protected edit request 27 December 2023 ==
Please sync from [[Module:Coordinates/sandbox]] ([https://en.wikipedia.org/wiki/Special:ComparePages?page1=Module%3ACoordinates&rev1=1161270528&page2=Module%3ACoordinates%2Fsandbox&rev2=1192087921&action=&diffonly=&unhide=&diffmode=source diff]).
This adds a class and a data-gadget attribute to the span. For now, this is a no-op change. It is intended to facilitate a more performant way of loading the WikiMiniAtlas script, when coupled with the proposed changes in [[MediaWiki talk:Common.js#Class-triggered gadgets]]. – [[User:SD0001|<span style="font-weight: bold; color: #C30">SD0001</span>]] ([[User talk:SD0001|talk]]) 14:36, 27 December 2023 (UTC)
: {{done}} [[User:Pppery|* Pppery *]] [[User talk:Pppery|<sub style="color:#800000">it has begun...</sub>]] 16:54, 27 December 2023 (UTC)
{{sudo|Module:Coordinates|answered=yes}}
As MediaWiki now supports category-based gadget load, we can switch to that. Please sync from [[Module:Coordinates/sandbox]] ([[Special:Diff/1192107975/1226463973]]). For now, this is a no-op as the gadget isn't actually defined. – [[User:SD0001|<span style="font-weight: bold; color: #C30">SD0001</span>]] ([[User talk:SD0001|talk]]) 20:17, 30 May 2024 (UTC)
▲
== coordinsert problem? ==
@[[User:Jonesey95|Jonesey95]] I recently found your [[de:Benutzer_Diskussion:Plenz/OSM_for_Wiki#Errors_at_en:Hatfield_Chase|old question]] on German WP. It could be because of a malformed Geohack link: "Infobox UK place" uses coordinsert which generates a broken string when "coord" got a "title" parameter: https://geohack.toolforge.org/geohack.php?pagename=Hatfield_Chase¶ms=53.528_N_0.893_W_&title=Tunnel+Pits_region:GB_type:city (see the splitted "params" seperated by the "title" parameter).
"coordinsert" assumes "params" always as last parameter? Which isn't true when "title" is used. [[User:DB111|DB111]] ([[User talk:DB111|talk]]) 09:10, 14 August 2024 (UTC)
|