Template talk:Flagg
Template:Flagg is permanently protected from editing because it is a heavily used or highly visible template. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported by consensus, editors may use {{edit template-protected}} to notify an administrator or template editor to make the requested edit. Usually, any contributor may edit the template's documentation to add usage notes or categories.
Any contributor may edit the template's sandbox. Functionality of the template can be checked using test cases. |
Suggestion: add a table-alignment parameter
editAt Special:Diff/1028180415, I had to swap out {{flaglist+link}} for {{flagg|unpe}} for WP:PEIS reasons, but that did mean losing the style="text-align: left"
. Could I add a "T" option (table, but different to "t") that causes the alignment setting to be output at the start of the template? This would default to left but be controlled by the existing align= parameter if needed. User:GKFXtalk 17:19, 17 June 2021 (UTC)
Asterisk optionality
editIs it possible _not_ to display the asterisk in a case, such as with the article, list of European countries by population. I find it very distracting and redundant. --Mahmudmasri (talk) 15:07, 3 June 2022 (UTC)
Flagg|cxxlo for BLR/RUS players
editWhat is the four-letter abbreviation parameter for Belarus/Russian sports athletes for {{flagg}}
, similar to {{flagg|cxxlo}}, equivalent to {{flagicon|}}? Qwerty284651 (talk) 12:15, 12 May 2023 (UTC)
- You can use {{#invoke:flag|althlete}}, which is a wrapper for Module:flagg, as an alternative to {{flagathlete}}. --Ahecht (TALK
PAGE) 21:00, 21 January 2024 (UTC)
Does not work with colspan
editSee: User:Timeshifter/Sandbox205 and its file history.
Instead of
| colspan=4 |{{flagg|us*eft|pref=Economy of
I had to use:
| colspan=4 style=text-align:left |{{flag+link|Economy of
Here below is what shows up with
| colspan=4 |{{flagg|us*eft|pref=Economy of
All people in poverty (2020) | Children ages 0-17 in poverty (2020) | |||||||||
---|---|---|---|---|---|---|---|---|---|---|
90% confidence interval of estimate | 90% confidence interval of estimate | |||||||||
States and D.C. | Percent | Lower Bound | Upper Bound | Percent | Lower Bound | Upper Bound | ||||
National | 11.9 | 11.9 | 11.9 | 15.7 | 15.7 | 15.7 | ||||
style="text-align:left"| Alabama * | 14.9 | 14.5 | 15.3 | 20.9 | 20 | 21.8 | ||||
style="text-align:left"| Alaska * | 9.6 | 9.1 | 10.1 | 12.3 | 11.3 | 13.3 |
Substituting {{flagg|uspeft
for {{flagg|us*eft
does not help.
See bottom of section here: Help:Table#Adding links to specialized country, state, etc. articles. With asterisk. --Timeshifter (talk) 10:20, 17 June 2023 (UTC)
Flag of Martinique
editEven though Martinique has a new flag as of 2023, the French flag still erroneously displays. As well as that, emojis depicting the flag have the racist snake flag (🇲🇶). OMGShay 92 (talk) 15:26, 30 June 2023 (UTC)
- @OMGShay 92 You should raise this at Template talk:Country data Martinique --Ahecht (TALK
PAGE) 21:02, 21 January 2024 (UTC)
Row moving over one cell. Table bug using Flagg template
editCopied from Wikipedia:Village pump (technical)#Row moving over one cell. Table bug using Flagg template (and others):
I am using Firefox on Windows 10 Pro PC. Latest standard versions on both. This does not happen to me on the Edge browser. Whether I am logged in or not. I logged out of Wikipedia and I still have the problem with Firefox. So it is not my JS and CSS files. I also disabled all my Firefox addons and then closed all my Firefox windows. I launched Firefox and I still have the problem with Firefox. No addons and not logged in.
The problem tables all use templates within the table. But it is not a problem with tables using {{flaglist}}. See List of countries by total health expenditure per capita. Both tables there use {{flagg}}. Open visual editor. Click to the right of the either of the 2 tables. Note the bizarre result of the row moving over one cell. Click to the right of a different row and note that row moving over one cell. If you click above or below the table the problem goes away. I opened visual editor for Help:Table and tried clicking to the right of many tables. Closer and farther away. I have noted the problem there with only one table so far. Have to go there to use visual editor on this table:
I see the problem only with the middle row there. Click to the right of it, and click closer until the row moves over one cell. It doesn't happen all the time. I removed the templates from a few rows of one of the tables in the list article. This solved the problem. And the small table above only has the bug in the middle row using templates. --Timeshifter (talk) 15:00, 14 August 2023 (UTC)
|
Edit request 8 October 2023 for adding new "i" option to use IOC country code resolution Reply Suggestion
editThis edit request to Module:Flagg has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Add an extra "i" option, to use the IOC country codes for resolving the entity string to country data, using Module:Country alias/data. This is useful primary in Olympic contexts, where codes like "BRN" always refer to Bahrain rather than Brunei as they currently do with the default resolution options.
- Testcase added to {{Flagg/testcases}} and tested
- Documentation added to {{Flagg/doc}}
The edit is uncontroversial because it does not change the existing template/module behavior at all, unless the new "i" option is added.
Description of suggested change: See Module:Flagg/sandbox, where the change is completed.
Add this code after line 52 local country = args[2] or ""
:
local countryDataCountry = country if string.find(me, "i") then local titleIocCountryData = mw.title.new[[Module:Country alias/data]] local IocCountryData = require(tostring(titleIocCountryData)) local iocCountryAlias = IocCountryData.countryAliases[country] or country countryDataCountry = IocCountryData.countries[iocCountryAlias]["name"] end
Also, change line 73:
− | data = CountryData.getcachedtable(frame, | + | data = CountryData.getcachedtable(frame, countryDataCountry, apar) |
Also, change line 77:
− | data = (args["nodata"] and {}) or CountryData.getcachedtable(frame, | + | data = (args["nodata"] and {}) or CountryData.getcachedtable(frame, countryDataCountry, {variant=args["variant"] or args[3]}) |
--Habst (talk) 16:08, 8 October 2023 (UTC)
- Completed. P.I. Ellsworth , ed. put'er there 20:01, 8 October 2023 (UTC)
Washington, D.C.
editWashington, D.C. is correct spelling according to the Wikipedia page.
Can {{flagg}} be fixed so that "Washington, D.C." shows up instead of just "Washington":
Washington * |
{{flagg|us*eft|pref=Crime in|Washington, D.C.}}
I would prefer not having to add another parameter (more work) to force the addition of D.C. to the link:
Washington, D.C. * |
{{flagg|us*eft|pref=Crime in|Washington, D.C.|name=Washington, D.C.}}