Jump to content

Template talk:Jct/Archive/2014

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia


Extra line break on OK-Spur

Live US 177 / SH-7 Spur US 177 / SH-7
Sandbox US 177 / SH-7 Spur US 177 / SH-7

Is there anything that can be done on the line break on SH-Spur for Oklahoma, since its not calling File:Spur plate.svg (as its part of the shield)? File:No image wide.svg seems to be inserted twice (once above each shield). --AdmrBoltz 19:01, 31 January 2014 (UTC)

Add it to the to-do list. I'll get to it eventually. -happy5214 19:02, 31 January 2014 (UTC)

Non consistant hyphens

SR-67 vs SR-67

When using the SR parameter a hyphen (is correctly) used between SR and the route number. When using the UT parameter a breaking space is incorrectly used. --AdmrBoltz 23:31, 3 February 2014 (UTC)

Fixed. –Fredddie 23:50, 3 February 2014 (UTC)

Clickable icons

Hello,

Why is this template set up like this: E15 / E80 / E714
Why not just make the icons clickable? I think that would look a lot cleaner. Thewombatguru (talk) 12:43, 1 March 2014 (UTC)

Because it's made by Americans, for American states where shields aren't simply the same as the route abbreviation. ;) In all seriousness, it'd probably violate MOS to shove all of that info into the icon. -happy5214 13:22, 1 March 2014 (UTC)
(edit conflict) Where would the links point to, the articles? There are a number of issues with that:
  • Not all web browsers can display graphics. Some people disable graphics to speed up page loading on slower connections. Other browsers, like Lynx, can't display graphics at all.
  • Hiding the link to the article in the graphic means there's no visual clue that there is a link to an article involved.
  • If a graphic links to something, it should normally be to the file description page on that graphic. In most cases, we have to link there, and can't link to an article, for licensing issues. The graphics used by this template should all be in the public domain as simple works (the E-road graphics above are ineligible for copyright), so that means there isn't a licensing issue.
  • Per WP:ALT, these are decorative images. The links to the right of them serve as the caption. That caption in the form of a link also serves to explain that the shield shape in US 66 means it is a US Highway. Non-American readers may not catch some of the subtleties to

    I-75 / US 23 to M-28 / H-58, but the links as a caption afterwards will help to clarify them.
  • Last, and this may be something of a North American issue, but how would we treat cases like
    M-6 to M-37 without the text next to the graphics? The slashes in the E-road example above indicates that E15, E80 and E714 are concurrent, but when a highway sign indicates that the intersecting road leads to another one, if we didn't have the text, we would falsely imply a concurrency by placing the signs adjacent.
For MOS:RJL compliance, and to follow other provisions of the MOS, icons like these are supposed to appear at the beginning of a line in a table or infobox, not separated by intervening text. Also, these icon graphics should never appear in the prose in the middle of an article.
The principles and guidelines behind the usage of this template were hammered out many years ago through the feedback at dozens of WP:FACs over the years. Imzadi 1979  13:38, 1 March 2014 (UTC)
Ok sorry, I didn't look at all the archives to find these discussions. So no clickable images, I understand now, thanks for the many reasons. Can browsers without graphics enabled not see icons made with html? And pages like this: European_route_E50 have clickable icons all over the place, should they be replaced? Also the ones in the infobox road at the right? Thewombatguru (talk) 15:09, 1 March 2014 (UTC)
A browser like Lynx can only show plain text. The fancy text links with colored backgrounds and colored text will only appear as plain hyperlinks. In other browsers that just have graphics shut off, the links would appear with the colors if that browser can show them that way normally. However, fancy links like that don't look like the rest of the links, so readers may not know they can click the green and white text to get to another article, not like the standard blue text links do. Also, people may not know that an article doesn't exist because the red link is white on green... so readers may click on the link expecting an article and find nothing.
Eventually, as we complete some updates to this template, we will be looking into creating new graphics, or linking to existing highway marker graphics. Then various countries' articles can be switched over. If the template already handles something, the article should be switched. Imzadi 1979  15:19, 1 March 2014 (UTC)

Two different countries

Hello,

How do I add two road signs from two different countries? I'm talking about the A28 from the Netherlands and the E232 European route. I tried something like this A 28 / E232 but that only shows the last one. Thewombatguru (talk) 21:39, 1 March 2014 (UTC)

There is no |country2= parameter. A 28 / E232 will work here in a moment because I'm adding the E type to NLD. Imzadi 1979  21:43, 1 March 2014 (UTC)
Thanks, but isn't it better to add a |country2= instead of adding the E to NLD? Because that needs to be done to all countries. Thewombatguru (talk) 21:49, 1 March 2014 (UTC)
The template just needs to be set up for each type of highway in that country, no more, no less. Imzadi 1979  21:55, 1 March 2014 (UTC)

Feature request

Prior to 2009, any missing shields could be found easily because there was a redlink where the shield would be. That's the same time when linking to the shield file was disabled as part of WP:ALT then-requirements. What I'd like to propose is that we re-add a visual clue for missing shields, say File:Red.svg. I was thinking it would be best if the red square were disabled in the Article space, that way you could see it in Draft or User space, but it wouldn't disrupt an article. However, after discussing it offwiki, I could be swayed towards including it in all spaces. I do not seek to get rid of the tracking category, otherwise how would we find the red squares? –Fredddie 04:12, 23 April 2014 (UTC)

+1, and I think even using them in article space would be good. Imzadi 1979  04:17, 23 April 2014 (UTC)
+1 - I think this would help a lot with locating missing shields. Dough4872 04:42, 23 April 2014 (UTC)
+1 – Good idea. TCN7JM 04:43, 23 April 2014 (UTC)
There are a few architectural issues that would have to be resolved to implement this in the Lua version. With the current design, the jct module itself doesn't know if the file exists or not. Ifexists testing is handled by the parser on a type-by-type basis, and most types don't have any testing done. I removed the automatic ifexists test to reduce the expensive PF count. Am I going to have to re-add it? -happy5214 07:49, 23 April 2014 (UTC)
The red square would only be used when Category:Jct template transclusions with missing shields is flagged, so the same logic that applies to the category should apply to the red square. –Fredddie 19:03, 23 April 2014 (UTC)
That's the problem. There currently isn't logic for the category in the Lua version. -happy5214 04:24, 24 April 2014 (UTC)
So how is the category flagged, if it is at all? –Fredddie 12:11, 24 April 2014 (UTC)

Temp fix for NC

Similar to how the South Carolina Temporary signs are setup, I need Temporary signs in North Carolina to use the banner "TEMP" for them. Need it for Interstate 85 Business (North Carolina) (for I-85 Temp and maybe a couple of other Interstate Temp routes that had existed in the state), should look the same as the I-77 temp used on Interstate 77 in South Carolina. Hope you guys can fix, thank you. --WashuOtaku (talk) 21:27, 24 April 2014 (UTC)

(a) This is in the infobox, not the junction list, right?
(b) Are you sure that signs said TEMP and not TEMPORARY?
(c) If the answer to both of the above is yes, Template:Infobox road/banner is the one to change. SC, for whatever reason, has TEMP hardcoded (since this edit), while all other states have TEMPORARY. --NE2 22:50, 24 April 2014 (UTC)
Yes and yes. I asked someone to fix SC a while back, which used TEMP as well.  ;) --WashuOtaku (talk) 00:43, 25 April 2014 (UTC)

Any chance of getting a fifth shield?

For example:


US 17 / US 92 / US 441 to Florida's Turnpike / I-4 east --NE2 18:04, 4 January 2014 (UTC)

We had this discussion on IRC the other night, and it was determined that four will remain the max. Should you need 5+ you can hand-code the junction as {{jct}} is just there to make editing easier and not to handle every single contingency. --AdmrBoltz 18:07, 4 January 2014 (UTC)
Yay for Special:ExpandTemplates. But why does it generate a &#32 (escape code for space) in various places? --NE2 18:17, 4 January 2014 (UTC)
If it's between the US and the number, that should be a &nbsp. Could be a bug in ExpandTemplates; as far as I know jct emits &nbsps properly. —Scott5114 [EXACT CHANGE ONLY] 22:43, 4 January 2014 (UTC)
They're actually in the links, like "U.S. Route 17 in Florida". -happy5214 22:55, 4 January 2014 (UTC)

Bringing this back. I've had at least ten cases where I've had to expand five, but none with six or more (even in overlap-heavy Georgia!). So five is probably a good hard limit. --NE2 19:31, 23 April 2014 (UTC)

I think adding #5 would be infinitely easier than asking the state DOTs to get their shit together and not overlap so many routes. @Happy5214: How hard would it be to add a fifth in the Lua rollout? 19:34, 23 April 2014 (UTC)
It's not even all overlap-caused. For example: SR 858 east (Hallandale Beach Boulevard) / CR 858 west (Miramar Parkway) to I-95 / SR A1A / I-75 --NE2 19:53, 23 April 2014 (UTC)
The Lua version will allow an unlimited number of routes to be included. Sorry if I hadn't already made that clear. The above example (see source):




SR 858 east (Hallandale Beach Boulevard) / CR 858 west (Miramar Parkway) to I-95 / SR A1A / I-75 -happy5214 04:22, 24 April 2014 (UTC)
Oh, cool. I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / I-99 / US 220 --NE2 04:51, 24 April 2014 (UTC)
Just now I came across my first six-shield, and it's all overlap. --NE2 09:10, 24 April 2014 (UTC)
Georgia has many instances of four-, five-, and six-route concurrencies. They even have at least two seven-routers (one in Athens, one in Folkston–Homeland). The Athens one is US 29 / US 78 / US 129 / US 441 / SR 8 / SR 10 Loop / SR 422. The one in the southeast part of the state is US 1 / US 23 / US 301 / SR 4 / SR 15 / SR 23 / SR 121. Allen (Morriswa) (talk) 09:29, 24 April 2014 (UTC)
Sure, but for n shields to show up in a junction list you need the overlap to have n routes plus the ones you're already on. So the one in Folkston has five at most, since SR 23 / SR 121 and US 301 / SR 23 split together at each end. Well, not quite, since SR 40 Conn. intersects right in the middle, so if that gets a junction list it'll have a seven. (And SR 422 isn't signed, so it doesn't quite count.) --NE2 21:11, 24 April 2014 (UTC)
Can we use the "sandbox" version of the template on actual articles? Allen (Morriswa) (talk) 07:24, 25 April 2014 (UTC)
(edit conflict) Technically, you could, though it is generally poor practice and should be avoided. -happy5214 08:11, 25 April 2014 (UTC)
No, you should not. Template sandboxes are subject to testing, and they could be changed at any time in ways that would break their uses in the articles. Once testing and other work is done, the live template will be updated based on the sandbox. Imzadi 1979  08:08, 25 April 2014 (UTC)
Sure, though you should probably plug it into Special:ExpandTemplates. --NE2 01:11, 29 April 2014 (UTC)
How do you actually use that special page? I tried it, but I didn't understand it. Allen (Morriswa) (talk) 01:39, 29 April 2014 (UTC)
Put the template call (with curly braces and arguments) into the big box, then hit OK, and copy from the result box. If the sandbox version doesn't support the type you want you'll have to use the regular version and add in the other routes (or shift the arguments down so the others show and paste them in). --NE2 02:26, 29 April 2014 (UTC)
I don't want to sound like an idiot, but can you dumb that down a bit? I don't want to mess up the code or anything. I used to get the ire of the other people in USRD up when I used to edit templates using automated tools. Allen (Morriswa) (talk) 02:41, 29 April 2014 (UTC)

Say you want to do NE2's example above. If the sandbox version of the code is working properly for all the routes then you can just type that that into the big box labelled "Input text:"

{{jct/sandbox|state=FL|SR|858|name1=Hallandale Beach Boulevard|dir1=east|CR|858|name2=Miramar Parkway|dir2=west|I|95|to3=to|SR|A1A|I|75}}

Then push "OK". The page will the load the equivilent wikitext in another text box, which you can use in the article:

[[File:Florida 858.svg|x20px|link=|alt=]][[File:CR 858 jct.svg|x20px|link=|alt=]][[File:I-95.svg|x20px|link=|alt=]][[File:Florida A1A.svg|x20px|link=|alt=]][[File:I-75.svg|x20px|link=|alt=]] <span class="nowrap">[[Florida State Road 858|SR 858]]</span> east (Hallandale Beach Boulevard) / <span class="nowrap">[[County Road 858 (Florida)|CR 858]]</span> west (Miramar Parkway) to <span class="nowrap">[[Interstate 95 (Florida)|I‑95]]</span> / <span class="nowrap">[[Florida State Road A1A|SR A1A]]</span> / <span class="nowrap">[[Interstate 75 (Florida)|I‑75]]</span>

If for some reason the sandbox version isn't working correctly, you type the {{jct}} template with the first four routes into the input box:

{{jct|state=FL|SR|858|name1=Hallandale Beach Boulevard|dir1=east|CR|858|name2=Miramar Parkway|dir2=west|I|95|to3=to|SR|A1A}}

And then push the "OK" button, giving you the code with the first four routes:

[[File:Florida 858.svg|x20px|link=|alt=]][[File:CR 858 jct.svg|x20px|link=|alt=]][[File:I-95.svg|x20px|link=|alt=]][[File:Florida A1A.svg|x20px|link=|alt=]] <span class="nowrap">[[Florida State Road 858|SR 858]]</span> east (Hallandale Beach Boulevard) / <span class="nowrap">[[County Road 858 (Florida)|CR 858]]</span> west (Miramar Parkway) to <span class="nowrap">[[Interstate 95 (Florida)|I-95]]</span> / <span class="nowrap">[[Florida State Road A1A|SR A1A]]</span>

If you know the shield file name, size, and link for the subsequent route(s) you can then add them in by hand, or else do another expansion with the remaining route(s) and then combine the results by hand. Thus:

[[File:Florida 858.svg|x20px|link=|alt=]][[File:CR 858 jct.svg|x20px|link=|alt=]][[File:I-95.svg|x20px|link=|alt=]][[File:Florida A1A.svg|x20px|link=|alt=]][[File:I-75.svg|x20px|link=|alt=]] <span class="nowrap">[[Florida State Road 858|SR 858]]</span> east (Hallandale Beach Boulevard) / <span class="nowrap">[[County Road 858 (Florida)|CR 858]]</span> west (Miramar Parkway) to <span class="nowrap">[[Interstate 95 (Florida)|I-95]]</span> / <span class="nowrap">[[Florida State Road A1A|SR A1A]]</span> / <span class="nowrap">[[Interstate 75 (Florida)|I-75]]</span>

- Evad37 [talk] 03:24, 29 April 2014 (UTC)

I tried many different variations, but nothing shows up in the box underneath the input area. What gives? Are there extra settings that have to be entered? Allen (Morriswa) (talk) 03:48, 29 April 2014 (UTC)
Enter it in the BIG box. --NE2 03:55, 29 April 2014 (UTC)
Thanks. Should the instructions for using that page be listed somewhere on the USRD or HWY project pages? Allen (Morriswa) (talk) 03:24, 29 April 2014 (UTC)
At this time, and throughout this discussion, the sandbox has merely linked to the actual template... I'm not sure why the actual template can't do what NE2 demonstrated above, rendering this whole discussion moot. - Floydian τ ¢ 06:57, 29 April 2014 (UTC)
Um, because the sandbox uses Lua exclusively and the live template does not? If you look at the code for the sandbox, it invokes Module:Jct, whereas the live template does not. The Lua version is not ready for primetime quite yet IMHO. For one thing, I have to figure out how to solve the problem raised in the section above this one. I'm targeting next month for full deployment. -happy5214 09:23, 29 April 2014 (UTC)

The sandbox needs a period after abbreviations (Alt., Bus., etc.). --NE2 10:29, 9 May 2014 (UTC)

Deployment of Lua version

I plan on deploying the Lua version of this template this weekend. Any last-minute feature and bugfix requests should go below. Here is a detailed calendar:

  • Now until WednesdayThursday night: Feature requests will be accepted.
  • Thursday-FridayFriday-Saturday: Last-minute feature requests will be implemented; no new features will be accepted until after deployment.
  • Saturday-Sunday/MondaySunday-Monday: Intense testing, last-minute bugfixes, and deployment.

Fire away! -happy5214 00:23, 21 May 2014 (UTC)

Bugs

Features

I am requesting some sort of error checking features in Jct. Currently, we use Category:Jct template transclusions with missing shields to find missing shields, but it is not perfect. As I write this, I am aware that that category will not be used in the Lua version. I am also aware that all of the discussions have taken place off-wiki on IRC, which is bad, m'kay? Anyway, here a few things I would like to see:

  1. Missing shield reporting (category preferred or some other method)
  2. Missing shield location (use some sort of Jct-specific non-image)
  3. Invalid parameter notification
    Current functionality: I-80 / %route%
    Sandbox functionality: I-80 / %route%
    My proposal: I-80 / %route%
  4. Improved documentation

I hate the idea of not knowing when Jct is broken, so I hope these ideas can inspire something. –Fredddie 00:22, 21 May 2014 (UTC)

+1 to all of them. We have #1 and #3 in place now, and the Lua version should not lose those features. Imzadi 1979  00:29, 21 May 2014 (UTC)
The first two proposals are predicated on performing an automatic ifexists test on every shield. Does such a test need to be included? -happy5214 03:04, 21 May 2014 (UTC)
The third idea is partially implemented, but the whole thing dies as it's currently written. As for the last point, I'm not particularly skilled at writing documentation. Feel free to write some! -happy5214 03:33, 22 May 2014 (UTC)
Who decided to take it out? Where was the discussion? –Fredddie 11:48, 22 May 2014 (UTC)
Regardless, I've added the category back, and I've also implemented a proper error message for missing types. I-80 / %route% -happy5214 01:26, 23 May 2014 (UTC)
Thanks, this is great. So does this automatically kill the shield so it wouldn't flag the missing shield category? What I'm thinking is we should have a generic Jct error category sorted similarly to Category:Infobox road temporary tracking category 1, wherein shield errors flag under heading 1 and type errors under heading 2. –Fredddie 01:33, 23 May 2014 (UTC)
The results are different. If the shield doesn't exist, the category is added in place of the shield. If the type doesn't exist, the shield function returns an empty string. The "invalid type" error message is displayed in place of the link/abbreviation if the abbreviation returned by the parser is nil, which is equivalent to having a non-existent type. A merged category might work. -happy5214 01:44, 23 May 2014 (UTC)

This is probably impossible to add reasonably, but you can no longer determine which (if any) articles use obscure route types. For example, I could tell from Special:WhatLinksHere/Template:Infobox road/FL/link CR-Spur that nothing actually uses it. --NE2 03:09, 21 May 2014 (UTC)

Comments

I think I got all the types added to Module:Road data/strings/USA/FL. Otherwise it looks good, and seems significantly faster. --NE2 01:19, 21 May 2014 (UTC)

Would it be possible (at some in the future, post implementation) to copy and adapt the jct lua module into a version suitable for {{AUshield}}? Or perhaps even make {{AUshield}} a wrapper for the jct lua module (with suitable adjustments)? I don't really know enough about programming in lua to try anything myself. - Evad37 [talk] 15:11, 21 May 2014 (UTC)

It seems possible, but I haven't really looked into it. Maybe I'll try to figure something out during my next major break in August or so. -happy5214 03:33, 22 May 2014 (UTC)
I wonder where {{jctname}} fits in with this. I think the pair (jct/jctname) should be able to handle whatever we need, or we should be tweaking things to accomplish that. Imzadi 1979  03:46, 22 May 2014 (UTC)
{{jctname}} is already implemented in Module:Jct. -happy5214 03:55, 22 May 2014 (UTC)
(jct/jctname) should be able to handle whatever we need – The main problem was that jctname wasn't handling complicated cases, such as multiple concurrent routes for a named road, or the handling of directions, which may need to be inside the parentheses next to a route (when a route goes in one direction but the named road goes in both), or outside the parenthesis (the named road is only in one direction, the route may also go in another direction on another road)
eg, Great Northern Highway (National Highway 95 north / National Route 1) / Roe Highway (National Highway 95 / State Route 3) east – destinations
I tried writing some code using parser functions to handle the complicated cases, but it became a real mess (see here, and that didn't work for all cases – would have needed |noshield#=-type coding). Overall, it has been easier to consistently use AUshield and manually type the routes for all cases, rather than use a mix of jctname for easy cases and AUshield for complicated cases. - Evad37 [talk] 05:34, 22 May 2014 (UTC)
You missed the point of my comments: the template should be made to work as needed if it doesn't now. Imzadi 1979  05:37, 22 May 2014 (UTC)
I was just trying to explain what wasn't working – I'm all for making it work properly, but first you need to know what isn't working before you can fix it. - Evad37 [talk] 06:17, 22 May 2014 (UTC)

Not a major thing, and I'm not exactly sure what, if anything, can be done about it, but nothing really happens if you subst the sandboxed version. With the PF version, you get an ugly mass of code that produces the Jct output we know and love. However, if you subst the sandbox, this is what you get. The second line was the same code substituted. –Fredddie 01:28, 23 May 2014 (UTC)

US-Alt-Bus

Could someone code the template so that a double-bannered route can display in {{jct}}? I'm creating a jct list for US 58 Alternate and a US 58 Alternate Business exists in Norton, VA. See [1] for what this will be used on. Thanks in advance. —Mr. Matté (Talk/Contrib) 00:49, 27 May 2014 (UTC)

A hacky workaround: a single image with both banners. --NE2 00:51, 27 May 2014 (UTC)

Or you could simply hardcode it. -happy5214 01:27, 27 May 2014 (UTC)

Spot the difference

--NE2 17:36, 5 June 2014 (UTC)

Future and Interstate. :p --WashuOtaku (talk) 17:54, 5 June 2014 (UTC)

Banners Busted

Hey guys, you all may be aware or not, but I noticed that "Future" and "Connector" banners are error coding. Good example that shows both is US 19 in NC. Just want to bring to you all attention. --WashuOtaku (talk) 15:46, 5 June 2014 (UTC)

Future is ambiguous; perhaps I-Future should be used? I've added that and US-Conn to Module:Road data/strings/USA/NC. --NE2 16:48, 5 June 2014 (UTC)
Its not just in North Carolina; South Carolina lost all its connectors too, both state and US (example: SC 20). I'm sure other states that use the "connector" banner likely lost theirs as well. --WashuOtaku (talk) 17:01, 5 June 2014 (UTC)
SC fixed. --NE2 17:32, 5 June 2014 (UTC)
A couple of corrections. South Carolina uses only the abbreviated form of the word on banners, so it's US 29 CONN as well. Future Interstates in North Carolina do not use a banner, they use the Future in shield version (i.e. ; I did notice there is no Future I-26 shield, I'm requesting it now). --WashuOtaku (talk) 17:48, 5 June 2014 (UTC)
Eh? http://gribblenation.net/ncfutints/i295705g.jpg http://www.alpsroads.net/roads/nc/i-840/ http://www.wrx900.com/Future%20I-26%20shield.jpg http://www.interstate-guide.com/images/i-026_future.jpg http://www.milebymile.com/photos/photo_5677.jpg (I-73 and I-74 seem to be the only ones that don't have it on standalone shields) --NE2 18:02, 5 June 2014 (UTC)
I guess I have concede with you here, even the Future I-495 uses a banner above it (picture I took I-495 Future). --WashuOtaku (talk) 18:12, 5 June 2014 (UTC)
Just so you know I'm not making it up for US Routes in South Carolina using the abbreviated version, here is US 29 Conn in the wild. --WashuOtaku (talk) 18:20, 5 June 2014 (UTC)

Suffixed Alternate Route Brake

Hey guys, it appears suffixed alt routes are broken in the jct list as well. Examples can be seen in U.S. Route 1 in North Carolina, where there are two US 1A routes with dabs for Wake Forest–Youngsville and Franklinton, those don't work anymore. Can this be fixed? --WashuOtaku (talk) 13:09, 6 June 2014 (UTC)

Fiedx. --NE2 13:37, 6 June 2014 (UTC)

New Zealand fix needed

I created Module:Road data/strings/NZL, however it needs to match Template:Jct/shield/NZL. Since modules will not accept the {{lc:foo}} magic word, how do we go about that? –Fredddie 15:53, 7 June 2014 (UTC)

Image redirects? --NE2 17:35, 7 June 2014 (UTC)
This was  Fixed a few days ago. -happy5214 10:54, 17 June 2014 (UTC)

On Module:Road data/strings/USA/MN for type CSAH, I'd like to add an ifexists for the link. Basically, if the page exists, it would create the link, otherwise no link. With PF, it was fairly straight forward, but I am not so sure with Lua. This was fairly common behavior with county roads in many states, so I see no reason why we shouldn't include it in the new version. –Fredddie 01:19, 11 June 2014 (UTC)

I fully agree with this idea as we should not encourage users to create articles on CRs as well as cut down on redlinks. Dough4872 01:37, 11 June 2014 (UTC)
Redlinks are fine, but I can see the benefit of ifexisting where there will probably be no article on most. Pull the code from Alabama. --NE2 01:53, 11 June 2014 (UTC)
Looking at that module's history, it appears this issue has been solved. -happy5214 10:54, 17 June 2014 (UTC)

Localised versions of extra icons not displaying

Seems to have been lost in the migration to Lua

  • {{jct}}
  • {{jct}} instead of {{Jct/extra|airport|country=AUS}}
  • {{jct}} instead of {{Jct/extra|airport|country=GBR}}
  • {{jct}} instead of {{Jct/extra|airport|country=TWN}}
  • {{jct}} instead of {{Jct/extra|hospital|country=AUS}}

- Evad37 [talk] 16:58, 6 June 2014 (UTC)

It looks like the main template is no longer calling {{jct/extra}}, or the function of that subtemplate wasn't put into a Lua module. @Happy5214: any ideas? Imzadi 1979  21:34, 6 June 2014 (UTC)
First, I didn't get pinged. Luckily, I have this page on my watchlist. The localized icons were, for whatever reason, not included in the module. I'll put that in the first point release, which I'll try to deploy by the end of the month, time permitting. -happy5214 22:35, 6 June 2014 (UTC)
This bug has been added to the above to-do list. -happy5214 10:54, 17 June 2014 (UTC)
A fix has been added to the sandbox. -happy5214 12:16, 17 June 2014 (UTC)

denom field is no longer necessary for fractional routes

Thanks to image redirects: CR 73/12 --NE2 15:13, 27 June 2014 (UTC)

Dual shields

Is there a way possible to have dual shields display for one link and abbreviation in jct? I know Route 54 (Delaware–Maryland) could use it where it follows the state line along with the AA Highway alongside its route numbers and Texas highways that have both a free and toll section at the same point. We have "DE.DEMD", "MD.DEMD", "KY.AA", and "TX.Both" that display the links and abbreviations properly but the shields are not coming out. Dough4872 03:30, 8 July 2014 (UTC)

Adding support for S-routes (City routes) in the Netherlands

Hello,

S-routes are routes in the Netherlands that connect a highway that runs around a city to different parts within that city. There are currently five cities in the Netherlands using this type of route: Amsterdam, Rotterdam, The Hague, Almere and Nijmegen. In each of those cities there are multiple S-routes, some of them named the same. How do I differentiate between them? TheWombatGuru (talk) 22:46, 7 December 2014 (UTC)

Can you give some examples, being pictures or links to the Dutch Wikipedia? I have an idea how we can disambiguate them, but I'd like to know a little more about them first. –Fredddie 22:55, 7 December 2014 (UTC)
nl:S101 and nl:S100 on nl.wikipedia link you to four different S101 and S100 routes, in case of S100 two of which are in the same province (Den Haag (The Hague) and Rotterdam are both in South Holland). commons:File:Amsterdam_outline_S-roads_-_numbers.svg - a map of s routes in Amsterdam as used on nl:Amsterdamse_stadsroutes, the circle route is A10 motorway (Netherlands). Main article about S-routes (Stadsroute (en: City route) ) : nl:Stadsroute TheWombatGuru (talk) 23:52, 7 December 2014 (UTC)
The Dutch Wikipedia disambiguates them the way I would here. I added a way to disambiguate them. S 100 / S 100 / S 100Fredddie 00:06, 8 December 2014 (UTC)
You disambiguate them with the |dab#= parameter as demonstrated above. If you disambiguation is not required, then the dab# parameter can be omitted. –Fredddie 00:08, 8 December 2014 (UTC)
Thanks, that'll work. TheWombatGuru (talk) 08:40, 8 December 2014 (UTC)

rdt → size

Recently a special parameter was introduced (rdt=y) that reduces the size of the icons to x17px and permits them to be used in RDTs. However, in some circumstances that is still too much; for example, in {{Pittsburgh Light Rail}} I had to separate {{jct}} into simple pictures + {{Roadlink}} so that the images could be scaled down to x11px. So possibly it would be better to use a size parameter with custom values instead of that cryptic rdt=y? YLSS (talk) 09:38, 10 September 2014 (UTC)

Please put your proposed changes on the sandbox and get them tested. Need to think about backwards compatibility as well ... — Martin (MSGJ · talk) 11:00, 10 September 2014 (UTC)
@Happy5214: can we work this so {{{rdt}}} accepts a number? I'd keep it at x17px for when |rdt=y, but uses the number when given a number. –Fredddie 13:31, 10 September 2014 (UTC)
Why not... But are you sure that all present usage is precisely rdt=y and not rdt=yes or something? Maybe better to check for e.g. 10 or x10 or 15x10:
	if rdt then
		return mw.ustring.match(rdt, '(%d*x?%d+)') or 'x17'
Tested, results. -- YLSS (talk) 16:35, 10 September 2014 (UTC)

Off topic to the request, but looking at the examples where the icons are 11px tall, it would be better to just get rid of them altogether. 11 pixels is entirely too small to be of any use. –Fredddie 13:35, 10 September 2014 (UTC)

You know, quite possibly you're right. But I only cleaned up those things that I'm used to, and let those signs be because I'm not sure what they should be eaten with ;) YLSS (talk) 16:35, 10 September 2014 (UTC)
Oppose the proposed change in any proposed form on that basis. Also, {{roadlink}} is being deprecated and will eventually be deleted once it is out of use. Imzadi 1979  19:51, 10 September 2014 (UTC)
Quite peremptorily. Care to explain why? YLSS (talk) 20:20, 10 September 2014 (UTC)
Once the graphics are scaled smaller than 17 pixels or so in height*, they'll become illegible. Those little blobs are no longer useful for identification purposes, and you'd be better off not attempting to include the graphics at all. At that point, you shouldn't be using this template then, so the proposed change is meaningless. (The exact height could be 15 or 16 pixels, and it will vary as well with the exact design of the markers.)
So in short, if 17 pixels is too big, don't use the template and just hand code the requisite highway links. No change is necessary. Imzadi 1979  20:27, 10 September 2014 (UTC)
I don't argue with that. But there is a chance that this will be useful in some other situation, don't you think? And since this comes with less than minimal impact, why not? YLSS (talk) 20:50, 10 September 2014 (UTC)
I don't think so, thus my formalized opposition to making a change (to prevent an admin from applying a change from a re-activated edit request). Imzadi 1979  21:26, 10 September 2014 (UTC)
Well, let's leave this to their judgement. YLSS (talk) 05:05, 11 September 2014 (UTC)
There isn't consensus yet to make any changes. I'm formally opposed, and no one else here has supported the change. Reactivating the request is premature. Imzadi 1979  05:41, 11 September 2014 (UTC)

Why is x11px actually needed? Why not use the |name1= parameter, as would be used in an RJL? eg

PA-88.svg
PA 88
Library Road
 

- Evad37 [talk] 05:39, 11 September 2014 (UTC)

I some cases, that would bloat the line in width, and the whole template with it, as in US 19.svgPA-65.svg US 19 /
PA 65
65th Infantry Division Memorial Hwy
. YLSS (talk) 05:56, 11 September 2014 (UTC)
The official name that nobody in the real world uses bloats that line. --NE2 15:55, 11 September 2014 (UTC)
That's beside the point: it's an example of the potential problem. Useddenim (talk) 00:33, 13 September 2014 (UTC)

Support the proposed change. It's not absolutely necessary for the number to be 100% clear, as the overall shield design and color conveys the route type, and there's also the adjacent text. As for implementation and backwards compatibility, I would suggest rdt=anything defaults to x17px unless the argument is numeric. Besides, @Imzadi1979: unilaterally denying the request after less than 24 when there's only one objection is what is premature, IMHO. Useddenim (talk) 10:23, 11 September 2014 (UTC)

Judging by your behavior, it seems obvious to me that you have a personal beef with Imzadi as a result of a recent TfD. It is clear to me that this edit is controversial (I also oppose this change as currently constituted.) and that, consequently, discussion and consensus are needed before implementation. The edit request may be reopened once consensus is reached. -happy5214 14:33, 11 September 2014 (UTC)

Alternative proposal

As an alternative, how about implementing such a layout as is currently mocked up in {{WMATA Silver Line}}? So that the shield is x17px in size and takes up the whole of the line, while the alphanumeric designation and the alternative name are placed one above the other? @Imzadi1979: ? YLSS (talk) 06:07, 11 September 2014 (UTC)

Example

{{jctrdt|state=MD|US|1}}

 

{{jctrdt|state=VA|I|495|name1=Capital Beltway}}

Support, as RDTs are an adjunct to the main article, and space is often at a premium:
Useddenim (talk) 10:23, 11 September 2014 (UTC)
This seems alright to me in terms of visual design, but I'm not not sure how easy or hard it would be to code. - Evad37 [talk] 16:02, 11 September 2014 (UTC) (Note that my comment was in the context of RDTs only, not RJLs or road infoboxes – Evad37 [talk] 03:12, 12 September 2014 (UTC))
Strong oppose. This style of diagram is floated to replace WP:RJL perennially. Unfortunately, it is not an improvement on the current standard because:
  • It is difficult to combine location (county/municipality) and notes with this style of list.
  • It may not be as accessible to users which cannot view images (screen readers for the blind, etc.) The current standard is a standard HTML table and the only graphical content is the shields, which are duplicated in text form after the image.
  • It would burden the project with continued web-design maintenance, checking to make sure that the diagram continues to display as intended across all commonly used browsers as they are updated. This would also have to be done whenever WMF updates the design of the site, as with the upcoming Winter project.
  • It would require a substantial effort to convert the tens of thousands of articles using the existing table-based layout to the new one.
To this point I have never seen a statement of actual benefits of the graphical layout other than "well we could do this because the trains projects do" or "it looks nice". It would have to be a particularly strong set of benefits to overcome the drawbacks listed above. —Scott5114 [EXACT CHANGE ONLY] 19:24, 11 September 2014 (UTC)
Um. The RDT is used for railways, not roads. The example on the right is a rail line. But why is it important to show where the rail line crosses roads that are not important bridges and such? --NE2 19:29, 11 September 2014 (UTC)
@NE2: Everything depend on how detailed the diagram is. Some only show stations (especially if the article is about a service, not a physical line), some show nearly every physical aspect of a line. E.g. the construction of the rail line necessitated building a bridge over a small road; a small bridge, but it's still there, and an integral part of the whole affair. Or there was a level crossing that constantly led to problems, so an overpass was built, and the nearby station has to be relocated. But of course there is no need to show how many roads pass above a metro line in a tunnel! YLSS (talk) 20:16, 11 September 2014 (UTC)
@Scott5114: You know, we could have done pretty well with {{Highway}} as it was. But no, Imzadi1979 has literally forced {{jct}} upon us, without really caring if he disrupted the existent diagrams in the process. So yes, now we require {{jct}} to be made useful for us as well. Otherwise, we'll have to once again fall to using a separate template (but that, of course, would be cumbersome). YLSS (talk) 19:38, 11 September 2014 (UTC)
Apologies, I was recently involved in a discussion about converting road articles to this format and I must have got the two confused. —Scott5114 [EXACT CHANGE ONLY] 19:56, 11 September 2014 (UTC)
Accepted ;) Could you please link to that discussion? It would be interesting to read it (no intention to participate). There's a whole category of road icons that were originally only intended to be used for crossings in rail diagrams, but has also been used to create some road diagrams. So I'd like to know what awaits them. YLSS (talk) 20:06, 11 September 2014 (UTC)
I did not force anything upon anyone. Rather, I found a poorly coded template that was redundant to another template, so I nominated it for deletion, and the community had a lengthy discussion on the merits of that nomination.
As I noted above, displaying the graphics at too small of a size makes them illegible, and if they are illegible, they are not useful to anyone. In most cases, shrinking them to the 17px* size has worked out just fine to balance legibility with the fixed-row height limitations, but if they need to be shrunk much further in specific situations, the graphics should be skipped completely.
Skipping the graphics does not necessitate any change to this template, meaning no edit request is necessary. {{Roadlink}} uses {{jct}} with the shields turned off, but editors can use |noshieldn= in {{jct}} to turn off individual graphics (the n would correspond to which shield in order needs to be left out) or use |noshield= (no number) to shut all of the shields off at once. Imzadi 1979  20:10, 12 September 2014 (UTC)
  1. Tyranny of the majority, IMHO.
  2. To (partially) overcome the legibility issue, I would (again) suggest that the html &thinsp; character be inserted between multiple shields. Useddenim (talk) 00:33, 13 September 2014 (UTC)
    The thin spaces would not matter; the legibility concern is because at 11px the graphics are too small to read, whether they are spaced apart or not. If anything, adding thin spaces will take up more room where editors are already concerned that space is at a premium. Imzadi 1979  03:20, 13 September 2014 (UTC)
Tested, results. I included a call to {{BSsplit}} (which is customarily used in RDTs for such purposes), which will reduce the work if that template is changed somehow, but adds the risk that the present module will have to be rewritten if e.g. it gets deleted. So possibly it should be substituted with a table layout; but I leave that question to the judgement of more experienced users.
@Useddenim: pls check if anything needs to be added to that call. Note align=left: I think it would be better to align both rows closer to the shields even in the right column.
Looks fine, subject to my comment above about spacing. I agree about the alignment. Useddenim (talk) 00:33, 13 September 2014 (UTC)
@Imzadi1979: Does that sound OK?
To the original developers of the module: I hope you don't mind that I rearranged the code a little bit in the necessary places? If you do, please edit it as appropriate. BTW, why isn't the jctname parameter described in the doc?
-- YLSS (talk) 21:14, 12 September 2014 (UTC)
To answer your last question, {{jctname}} is a separate template that uses the same modules as this one.
To answer your other question, I still oppose any usage of graphics at 11px size and any ability to override the sizing. Your last example with stacking the names for the first highway followed by a slash and a full-height second name looks bad, so I oppose that as well. Imzadi 1979  21:32, 12 September 2014 (UTC)
Your sig looks bad, so I oppose you. --NE2 22:09, 12 September 2014 (UTC)
@Imzadi1979: Personal opinions about the aesthetics are not relevant to this discussion. We're talking about space constraints and legibility. Useddenim (talk) 00:33, 13 September 2014 (UTC)
Actually, they are germane because they are not purely aesthetics.. As noted elsewhere on this talk page, text sizes will vary from browser to browser. There are also accessibility issues with shrinking the text below a certain threshold to stack the two lines. To overcome the smaller size text, a reader will enlarge all of the text on the page, which will increase the issue with gaps in the RDT graphics. Stacking the text like that for one highway designation but not another creates oddities for readers parsing the text. No, for aesthetic and related accessibility reasons, I cannot support the proposed alteration to the template.
As NE2 has noted, in many cases, the roadway name can be dropped as less relevant than the highway's number; it's likely an extraneous detail in most cases. Dropping it will save space where space is at a premium. Imzadi 1979  03:20, 13 September 2014 (UTC)
@Imzadi1979: WRT the last example: I only included it to see if it's going to work at least somehow with additional parameters. But that syntax is only used in USRD tables, in RDT it would be quite enough to use just number + name. WRT smaller text size: please don't bother about that. Half of RDTs have some bits of text arranged that way. YLSS (talk) 05:08, 13 September 2014 (UTC)

What everyone seems to be losing sight of here is that YLSS and I are talking about changes that would only be in effect if |rdt= is activated. And other than Imzadi1979’s removal of {{hwy}}, I don’t think anyone else taking part in this discussion has done any editing of RDTs. Useddenim (talk) 00:33, 13 September 2014 (UTC)

I may have done some railway ones back in the day. I know I made Template:HCRH map for a highway that's kind of like a railway in that the bridges and tunnels are more important than the intersections. (I never finished the article, so the section links go nowhere.) --NE2 00:46, 13 September 2014 (UTC)
What do RDTs have to do with WikiProject Highways? I fail to see why functionality that will never be used by road articles should go in a template/module designed for road articles. Likewise, RDTs will never use several features found in {{jct}}. Seeing how controversial this topic has become, I'm starting to regret getting rid of {{highway}}. Maybe an RDT-specific fork of {{jct}} is in order? -happy5214 08:18, 15 September 2014 (UTC)
Agree wholeheartedly. Useddenim (talk) 21:45, 15 September 2014 (UTC)
  • I'm a bit disappointed in the accusations of bad faith here; please remember that we're all here to write an encyclopedia. Admittedly, I haven't been that active in the recent discussions. However, I oppose because it is not accessible for visually impaired readers (WP:ACCESS). I realize this is used on other language Wikipedias (I'm a m:steward after all) but here we have to follow English Wikipedia guidelines. --Rschen7754 02:36, 16 September 2014 (UTC)
So you're saying that because it won't be accessible to everybody (based on what? as I believe it was mentioned earlier that screen readers skip the icons but still sound out the text)), then it shouldn’t be available to anybody? Useddenim (talk) 10:11, 16 September 2014 (UTC)
Screen readers are only one part of the accessibility equation. They're used by those who can't see, but what about those who can't see well? Smaller font sizes create problems for them. As NE2 noted below, he's seeing gaps in one RDT which are likely caused by a setting he has to use a larger default font size. If you shrink the type size too small, it becomes hard to read, and readers will have to increase their font size in their browsers to compensate. Other variations in reader settings mean you can't guarantee that there will not be gaps in the graphics caused by rows with larger line heights.
The simplest solution is that if including the street name of a highway takes up too much room in the RDT, it's a minor detail that should be omitted. If the street name is the more important detail, then the highway designation should be omitted. If it's the highway marker graphics (the "shields") that are taking up too much room, then they should be omitted rather than shrunk. None of these options require changing this template. Imzadi 1979  17:59, 16 September 2014 (UTC)

Stupid question

I assume the problem is that this template, unmodified, will produce rows that are too tall, thus making it look like the rail line has gaps in it. Is it possible to add a background image to the left column to fill any gaps? --NE2 19:30, 11 September 2014 (UTC)

PS: {{highway}} had problems, but the deletion and this follow-up is typical USRD ignoring what they don't like. --NE2 19:41, 11 September 2014 (UTC)

In short: no. Something like this is implemented at pl.wp and de.wp, but it only works over there because they have quite simple diagrams, and in half of cases doesn't work at all. At en.wp the diagrams are sometimes really sophisticated, and there is no possibility to make a background for   (ftSTR),   (LLSTR2),   (LSTR2),   (u-SHI2rq) etc. etc. YLSS (talk) 19:45, 11 September 2014 (UTC)
How about adding the background only if it is a normal straight line? Is that something that can be determined easily from the code? Junctions and curves aren't going to have highway crossings. (But again: why is it useful to list highway crossings of a rail line?) --NE2 20:07, 11 September 2014 (UTC)
Hehe, you can believe me, things that seem impossible are prone to take shape one day (e.g. ru:Template:Крюково — Тверь). I did experiment with background at ru:Module:Routemap, but did not produce anything satisfactory. The reliance on the constant row height is too deep-rooted, I'm afraid. YLSS (talk) 20:28, 11 September 2014 (UTC)
Is that Крюково — Тверь supposed to have a number of gaps? If not, it's probably because I have my default font size set higher. Trying to force all browsers to render something identically is going to fail. --NE2 00:48, 13 September 2014 (UTC)

Even stupider question

What the heck is a RDT? --Rschen7754 02:25, 16 September 2014 (UTC)

It's the fancy train route diagrams. –Fredddie 02:26, 16 September 2014 (UTC)
See WP:RDT - Evad37 [talk] 02:58, 16 September 2014 (UTC)
See Template:HCRH map for an example for a highway. Useddenim (talk) 10:11, 16 September 2014 (UTC)