Template talk:Jct

(Redirected from Module talk:Jct/city)
Latest comment: 11 days ago by WOSlinker in topic lang-?? templates

Route number space for Ireland

edit

I'm reposting an archived request from 16 October 2023, which asked "if it is possible to remove the space between the letter and number(s) for all Irish route numbers" e.g.   M50 would display as "M50". Thanks, Declangi (talk) 06:29, 27 June 2024 (UTC)Reply

  Done at Module:Road data/strings/IRL BrandonXLF (talk) 17:43, 23 August 2024 (UTC)Reply

Space between markers

edit

To bring this template inline with Template:Infobox road and to improve its appearance, a (thin) space should be added between shields. For example:    Highway 401 / Highway 24 vs    Highway 401 / Highway 24 and    US 1 / US 2 vs    US 1 / US 2. Alternatively, a normal space can be added, which would look like    . BrandonXLF (talk) 03:41, 24 August 2024 (UTC)Reply

lang-?? templates

edit

{{jct|country=ISR|Route|232}}[[File:ISR-HW-232.svg|x24px|link=|alt=]] [[Route 232 (Israel)|Route 232]]  Route 232

The {{lang-??}} templates are going away. It is not clear to me where this template uses {{lang-??}} templates but it is clear that some of them do. Apparently this is invocation specific. Try this experiment:

  1. edit Template:Jct § Examples
  2. click Show preview
  3. open the 'Templates used in this preview' dropdown
  4. notice that there are no {{lang-??}} templates listed nor is Module:Lang and its submodules.

Compare that result with the result you get when you:

  1. edit Template talk:Jct § lang-?? templates
  2. click Show preview
  3. open the 'Templates used in this preview' dropdown
  4. notice that both of {{lang-ar}} and {{lang-he}} templates along with Module:Lang and its submodules.

It is not obvious to me why those two templates are transcluded because there is no Arabic or Hebrew text in the template call and none in its output as you can see above. So why transclude these templates?

Where ever the fix needs to be made, the fix may be as simple as changing {{lang-ar|...}} and {{lang-ar|...}} to {{langx|ar|...}} and {{langx|he|...}}.

I noticed this because Monkbot/task 20 keeps a log of pages that it skips. So far, after processing 80k-ish pages, only the Israeli highways seem to transclude {{lang-??}} templates. Of course there may be more; at this writing there are ~470,000 pages listed in Category:Pages using Lang-xx templates.

Trappist the monk (talk) 14:31, 25 October 2024 (UTC)Reply

I've updated Module:Road data/strings/ISR. -- WOSlinker (talk) 15:35, 25 October 2024 (UTC)Reply
Thanks. Are you sure that this part of line 27 is correct?
frame:expandTemplate{ title = 'langx', args = {"he","طريق السريع 3"}}
Shouldn't the language tag be ar?
Trappist the monk (talk) 16:29, 25 October 2024 (UTC)Reply
I undid your similar edit at Module:Road_data/strings/SRB because {{lang-sr-Latn}} and {{lang-sr-Cyrl}} use |label= with custom values. {{langx}} does not know about custom labels so rejects the sr-Latn and sr-Cyrl language tags. Those uses in ~/strings/SRB might be rewritten to specify the script in a separate parameter. For example, line 23 (and other similar lines) might be rewritten like this:
SRB.E.translation = frame:expandTemplate{ title = 'langx', args = {'sr', ['script'] = 'Latn', "Evropski put E%route%"}} .. "<br>" .. frame:expandTemplate{ title = 'langx', args = {'sr', ['script'] = 'Cyrl', "Европски пут Е%route%"}}
The above is not tested but should produce substrings that look like these:
{{langx|sr|script=Latn|Evropski put E%route%}} [[Serbian language|Serbian]]: <i lang="sr-Latn">Evropski put E%route%</i>Serbian: Evropski put E%route%
{{langx|sr|script=Cyrl|Европски пут Е%route%}} [[Serbian language|Serbian]]: <span lang="sr-Cyrl">Европски пут Е%route%</span>Serbian: Европски пут Е%route%
Trappist the monk (talk) 17:09, 25 October 2024 (UTC)Reply
I've fixed the mistake I made on line 27. -- WOSlinker (talk) 18:23, 25 October 2024 (UTC)Reply