Module talk:Infobox road/color: Difference between revisions
→PHL colours: Please be more specific. |
→PHL colours: more tagging |
||
Line 190: | Line 190: | ||
Can someone change the colours for Philippine road articles? Thanks! --<span style="font-size:12pt;font-family:Tw Cen MT;color:black">[[User:HueMan1|hueman1]] [[User talk:HueMan1|<small>(talk)</small>]]</span> 10:43, 23 August 2018 (UTC) |
Can someone change the colours for Philippine road articles? Thanks! --<span style="font-size:12pt;font-family:Tw Cen MT;color:black">[[User:HueMan1|hueman1]] [[User talk:HueMan1|<small>(talk)</small>]]</span> 10:43, 23 August 2018 (UTC) |
||
:{{ping|HueMan1}} Can you please be more specific? Are there certain types that need to be changed? What do you want the new colors to be? -[[User:Happy5214|happy]][[User talk:Happy5214|5214]] 11:58, 23 August 2018 (UTC) |
:{{ping|HueMan1}} Can you please be more specific? Are there certain types that need to be changed? What do you want the new colors to be? -[[User:Happy5214|happy]][[User talk:Happy5214|5214]] 11:58, 23 August 2018 (UTC) |
||
::{{ping|HueMan1|TagaSanPedroAko}} There was a thread right above this one and a message on my talk page regarding Philippine road articles. Which one is correct? –[[User:Fredddie|Fredddie]][[User talk:Fredddie|™]] 13:06, 23 August 2018 (UTC) |
Revision as of 13:07, 23 August 2018
Can someone add appropriate colors for Poland, please? Mkmk101 (talk) 23:50, 24 April 2013 (UTC)
- What are the appropriate colors? --Rschen7754 02:16, 25 April 2013 (UTC)
Request to change "colors" subtable
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
This module was the subject of a recent bugzilla defect.
A future change may cause invocations of this module to break. The line at issue is "p.colors = colors". As per comment #6
...the proper fix is to not place that "colors" subtable in the table of functions being returned to PHP for #invoke.
The recommended fixes are any one of the following:
- separate the entire "colors" table into a different module
- change p.colors to an accessor function
- before
p.colors = colors
- after: "p.colors = colors" removed; accessor added in its place
function p.colors(frame) return colors end
- remove the "p.colors = colors" line. The module does not need it in order to work.
The accessor function seems like the best course of action. Let me know if you need more info. Thanks.
gnosygnu 02:15, 16 May 2013 (UTC)
- Done by User:Legoktm. -happy5214 08:24, 16 May 2013 (UTC)
Edit request on 18 August 2013
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Here is the snippet of code needed for Poland:
do -- Poland local POL = Country:new{default = "background:#006A4D; color:#fff;"} POL:addTypesAsColor({"A", "S"}, "background:#0079C1; color:#fff;") colors.POL = POL
–Fredddie™ 23:43, 18 August 2013 (UTC)
Done --Rschen7754 02:05, 19 August 2013 (UTC)
Edit request on 22 August 2013
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Here is the snippet of code needed for Sri Lanka:
do -- Sri Lanka local LKA = Country:new{default = "background:#006A4D; color:#fff;"} LKA:addTypesAsColor({"E"}, "background:#0000CD; color:#fff;") LKA:addTypesAsColor({"A"}, "background:#006A4D; color:#fff;") colors.LKA = LKA
–Chamath237 12:11, 22 August 2013 (UTC)
- Isn't defining the A color redundant to the default? –Fredddie™ 00:24, 23 August 2013 (UTC)
Canada colours broke
I'm not good with Lua, and so I don't want to go making cascading changes without a clue. The header type argument doesn't seem to work in Canada anymore with the recent change to Lua. Articles such as Don Valley Parkway are reverting to the default colours (normally used only for county and city roads). A header type of "Freeway" and "freeway" should return the dark blue colour used by the 400-series highways, for our unnumbered municipal expressways - #003F87.
This is what tried adding, but it doesn't seem to have any effect:
do -- Canada local CAN = Country:new{default = "background:#006A4D; color:white;"} CAN:addTypesAsColor({"Freeway", "freeway", "FWY", "Fwy", "fwy"}, "background:#003F87; color:white;") colors.CAN = CAN end -- Canada
-- Floydian τ ¢ 17:20, 13 December 2013 (UTC)
- Fixed There were a few issues. First of all, the
addTypesAsColor
method refers to highway types, not header types. And by adding that code, it disabled the already-existent submodule for Canada. Lastly and most importantly, the module was written to not calculate the country when a header_type value was present. That has been fixed so that only "built-in" header types cause this behavior. -happy5214 06:25, 14 December 2013 (UTC)
- Awesome. Is there a page that lays out the heirarchy of all these modules? Can be difficult to find things going through layer upon layer of code. - Floydian τ ¢ 19:35, 14 December 2013 (UTC)
- The best option is probably Special:PrefixIndex/Module:Infobox road/color. The UK is the only other country with a separate submodule. -happy5214 20:16, 14 December 2013 (UTC)
- Awesome. Is there a page that lays out the heirarchy of all these modules? Can be difficult to find things going through layer upon layer of code. - Floydian τ ¢ 19:35, 14 December 2013 (UTC)
Template-protected edit request on 3 March 2014
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Please add the following section
do -- Iran local IRN = Country:new{default = "background:#cedff2;"} IRN:addTypesAsColor({"freeway"}, "background:#06c; color:#fff;") IRN:addTypesAsColor({"expressway"}, "background:#22B14C; color:#fff;") IRN:addTypesAsColor({"road"}, "background:#22B14C; color:#fff;") IRN:addTypesAsColor({"boulevard"}, "background:#fff; color:#000;") IRN:addTypesAsColor({"street"}, "background:#fff; color:#000;") colors.IRN = IRN end -- Iran
Nima Farid (talk) 02:32, 3 March 2014 (UTC)
Template-protected edit request on 7 December 2014
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Please make it so the color is the same as EUR when country is set to NLD and type is set to E. TheWombatGuru (talk) 23:29, 7 December 2014 (UTC)
- Should be good to go. –Fredddie™ 23:39, 7 December 2014 (UTC)
- Thanks, but I think the colour for E roads in NLD should be #08842C just like EUR in single colour countries. TheWombatGuru (talk) 23:43, 7 December 2014 (UTC)
Template-protected edit request on 16 December 2014
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
- Please make it so the color is the same as EUR when country is set to DEU, CHE or ITA, and type is set to E.
- Fix white space at NLD entry.
- Fix note in line 105 "end -- Germany" should be "end -- Denmark".
TheWombatGuru (talk) 15:14, 16 December 2014 (UTC)
- Was there a discussion where these changes were discussed and agreed upon someplace you can link to? Thanks. — {{U|Technical 13}} (e • t • c) 15:55, 16 December 2014 (UTC)
- No, points 2 and 3 are fixes, I don't think they have to be discussed first. The first point, is an edit similar to one I requested a few days ago, that one was accepted. TheWombatGuru (talk) 16:39, 16 December 2014 (UTC)
- Done 2 and 3. I think you are going to need to explain point 1 more thoroughly, as I don't understand it (and judging by how long this request has been waiting, others are having trouble as well). — This, that and the other (talk) 03:27, 23 December 2014 (UTC)
- Done #1. @Happy5214: can you get double check CHE? @TheWombatGuru: if there are any issues, let me know. Imzadi 1979 → 03:56, 23 December 2014 (UTC)
- Yeah, they're all green now, also CHE: European route E35 in Switzerland. TheWombatGuru (talk) 11:39, 23 December 2014 (UTC)
- No, points 2 and 3 are fixes, I don't think they have to be discussed first. The first point, is an edit similar to one I requested a few days ago, that one was accepted. TheWombatGuru (talk) 16:39, 16 December 2014 (UTC)
Template-protected edit request on 4 September 2016
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Hello, I'm working on Roads in Pakistan and there seems to be lack of detail for the Pakistan section. Only M (motorways) are noted, not N (national highways) or E (expressways). Also the colours are wrongly noted. Kindly please update the colours and headings for Pakistan section as follows:
- National Highways (N) uses colour = #06c - Motorways (M) uses colour = #22B14C - Expressways (E) uses colour = #F5C31D
The same colours are being used for our Roads in Pakistan template Template:Motorways of Pakistan
Thank You, PAKHIGHWAY, 2016.9.4 18:45 PM (PST)
PAKHIGHWAY (talk) 13:48, 4 September 2016 (UTC)
Template-protected edit request on 11 May 2017
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
I am working on articles about expressways and highways in the Philippines, but there is no distinguishing header color for infoboxes if I add "E" (or "Expressway", for expressways), "N" (or "National Road" or "National Highway", for national roads), or "AH" (or "Asian Highway", for Asian Highway routes, with the only route in the Philippines is AH26 or Pan-Philippine Highway) in the type parameter of infobox road, with PHL as country parameter. The header color by the type set will be:
- E, Expressway: #fc3
- N, National Road, National Highway: #3C9
- AH, Asian Highway: #039.
The code is:
do -- Philippines local PHL = Country:new{default = "background:#cedff2;"} PHL:addTypesAsColor({"E", "Expressway"}, "background:#FC3; color:black") PHL:addTypesAsColor({"N", "National Road", "National Highway"}, "background:#3C9; color:#fff;") PHL:addTypesAsColor({"AH", "Asian Highway"}, "background:#039; color:#fff;") colors.PHL= PHL end -- Philippines
TagaSanPedroAko (talk) 06:50, 11 May 2017 (UTC)
@TagaSanPedroAko: I asked you a question the other day about this at Template talk:Infobox road, but you haven't answered. –Fredddie™ 13:01, 11 May 2017 (UTC)
- I haven't noticed the question there, as I am busy editing articles about Philippine roads. But I left a reply there, that I will use green ( #093) as default, and blue ( #039) for Asian Highway, over my previous proposal. I revised the code to be added (see below)
do -- Philippines local PHL = Country:new{default = "background:#093; color:white;"} PHL:addTypesAsColor({"AH", "Asian Highway"}, "background:#039; color:white;") colors.PHL = PHL end -- Philippines
--TagaSanPedroAko (talk) 13:56, 11 May 2017 (UTC)
PHL colours
Can someone change the colours for Philippine road articles? Thanks! --hueman1 (talk) 10:43, 23 August 2018 (UTC)
- @HueMan1: Can you please be more specific? Are there certain types that need to be changed? What do you want the new colors to be? -happy5214 11:58, 23 August 2018 (UTC)
- @HueMan1 and TagaSanPedroAko: There was a thread right above this one and a message on my talk page regarding Philippine road articles. Which one is correct? –Fredddie™ 13:06, 23 August 2018 (UTC)