Module talk:WikiProject banner
![]() | If you wish to discuss the behaviour of the project banner inside the banner shell, then you may wish to post at Template talk:WikiProject banner shell instead. |
![]() | This module does not require a rating on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | |||||||
|
|
![]() |
|
This page has archives. Sections older than 60 days may be automatically archived by Lowercase sigmabot III when more than 4 sections are present. |
Syntax highlighting in automatic documentation
editCould syntax highlighting be added to the automatic documentation (i.e. when |DOC=auto
)?
Current display (e.g. Template:WikiProject AfroCreatives#Full usage):
{{WikiProject AfroCreatives |category= |listas= |class= |importance= |auto= |attention= |needs-image= |type= |details= |location= |topic= }}
Proposed:
{{WikiProject AfroCreatives |category= |listas= |class= |importance= |auto= |attention= |needs-image= |type= |details= |location= |topic= }}
Only applicable in the #Basic usage & #Full usage sections (I think). ~ Tom.Reding (talk ⋅dgaf) 17:42, 30 May 2024 (UTC)
- That sounds good (and uncontroversial) to me, but after some searching, I have been unable to figure out where the relevant code is. Sdkb talk 18:31, 30 May 2024 (UTC)
- It seems like it might be at Module:WikiProject banner/templatepage from lines 833-863. Someone who knows Lua would need to implement. Sdkb talk 18:35, 30 May 2024 (UTC)
- Excellent idea. I will do it shortly unless someone else has already done it — Martin (MSGJ · talk) 15:33, 2 June 2024 (UTC)
- Please check Template:WikiProject Cycling/sandbox and feed back? I notice you used the "inline" option but I don't know what difference that makes — Martin (MSGJ · talk) 08:36, 4 June 2024 (UTC)
- Compare this:
{{WikiProject AfroCreatives |category= |listas= |class= |importance= |auto= |attention= |needs-image= |type= |details= |location= |topic= }}
which uses inline, with this:which doesn't. --Redrose64 🌹 (talk) 12:37, 4 June 2024 (UTC){{WikiProject AfroCreatives |category= |listas= |class= |importance= |auto= |attention= |needs-image= |type= |details= |location= |topic= }}
- Got it. So I think in this case we do not want "inline", so this should be good to go — Martin (MSGJ · talk) 17:15, 4 June 2024 (UTC)
- Any luck with this? ~ Tom.Reding (talk ⋅dgaf) 12:42, 26 July 2024 (UTC)
- Think it was deployed ages ago - are you not seeing it? — Martin (MSGJ · talk) 19:54, 5 August 2024 (UTC)
- Seems Pppery reverted the edits here. Gonnym (talk) 19:59, 5 August 2024 (UTC)
- Ah, didn't realise that. My understanding is that all these category issues were resolved so I have redeployed the code. — Martin (MSGJ · talk) 20:18, 5 August 2024 (UTC)
{{Looks |great=!}}
~ Tom.Reding (talk ⋅dgaf) 10:29, 6 August 2024 (UTC)- Reverted again by Timrollpickering. Please can you explain what problems you are seeing? — Martin (MSGJ · talk) 15:04, 7 August 2024 (UTC)
- See Wikipedia:Village pump (technical)#WikiProject templates category redirect mess for the various category redirects this has impacted. Several are being fixed through renames. Timrollpickering (talk) 14:13, 8 August 2024 (UTC)
- Thanks for the note. I think I will redeploy the code but populate a tracking category instead of non-existent category so we can check for issues. — Martin (MSGJ · talk) 20:25, 8 August 2024 (UTC)
- See Wikipedia:Village pump (technical)#WikiProject templates category redirect mess for the various category redirects this has impacted. Several are being fixed through renames. Timrollpickering (talk) 14:13, 8 August 2024 (UTC)
- Reverted again by Timrollpickering. Please can you explain what problems you are seeing? — Martin (MSGJ · talk) 15:04, 7 August 2024 (UTC)
- Ah, didn't realise that. My understanding is that all these category issues were resolved so I have redeployed the code. — Martin (MSGJ · talk) 20:18, 5 August 2024 (UTC)
- Seems Pppery reverted the edits here. Gonnym (talk) 19:59, 5 August 2024 (UTC)
- Think it was deployed ages ago - are you not seeing it? — Martin (MSGJ · talk) 19:54, 5 August 2024 (UTC)
- Any luck with this? ~ Tom.Reding (talk ⋅dgaf) 12:42, 26 July 2024 (UTC)
- Got it. So I think in this case we do not want "inline", so this should be good to go — Martin (MSGJ · talk) 17:15, 4 June 2024 (UTC)
- Compare this:
- Does the olive text-to-background contrast really pass accessibility here, let alone on the gray background? — HELLKNOWZ ∣ TALK 15:20, 7 August 2024 (UTC)
- If you think this is an issue, then I would suggest you discuss at mw:Extension talk:SyntaxHighlight — Martin (MSGJ · talk) 07:00, 9 August 2024 (UTC)
Warnings
editI would like to add some prominent warnings when people try to use the |class=
parameter in a project banner instead of in the banner shell template
- If {{WikiProject banner shell}} is already on the page (but without a
|class=
parameter), then the message will say something like Please add the quality rating to the WikiProject banner shell instead of this project banner - If {{WikiProject banner shell}} is not on the page yet, then the message will say something like Please add the WikiProject banner shell template to this page and then add the quality rating to that template
I'm sure the wording could be improved. What do you think? — Martin (MSGJ · talk) 12:08, 10 June 2024 (UTC)
Please add {{WikiProject banner shell}} to this page and add the quality rating to it.
maybe something like this? Regardless, link the banner shell template. I'm in favor of the warning. Gonnym (talk) 21:38, 10 June 2024 (UTC)- Yep, probably a link a WP:PIQA somewhere in there too — Martin (MSGJ · talk) 21:39, 10 June 2024 (UTC)
- This should be expended to any parameter we migrate to the shell, like
|listas=
do deal with redundant, duplicate or conflicting data. Gonnym (talk) 16:20, 11 June 2024 (UTC)- This is now coded on the sandbox. Example of the first message can be seen at Module talk:WikiProject banner/testcases#Globally unassessed. the second message below — Martin (MSGJ · talk) 10:24, 3 July 2024 (UTC)
- This should be expended to any parameter we migrate to the shell, like
- Yep, probably a link a WP:PIQA somewhere in there too — Martin (MSGJ · talk) 21:39, 10 June 2024 (UTC)
Cycling B‑class | |||||||
|
Okay this is ready to go, but I will wait for Category:Pages using WikiProject banner shell without a project-independent quality rating (0) and Category:Articles with WikiProject banners but without a banner shell (66) to be emptied first to avoid ugly warnings on so many pages — Martin (MSGJ · talk) 09:35, 4 July 2024 (UTC)
- Note: this is now deployed — Martin (MSGJ · talk) 12:17, 16 August 2024 (UTC)
- Is it too late for me to object to this? As I said at the template talk page, something like this is just dumb; if we are going to force people to use the banner shell, then we should integrate it into every WikiProject banner automatically. I don't mind giving a warning if there's already a WPBS on the page, since it's a "hey, this is here, please put your banner in the right place", but for a page with no shell it shouldn't have a warning. (please do not ping on reply) Primefac (talk) 21:26, 17 August 2024 (UTC)
- What Primefac said. On talk pages other than the main Talk: space, people should not be forced to use a WPBS, particularly when there is only one WP banner, because the autodetection of class is pretty much universal. --Redrose64 🌹 (talk) 07:29, 18 August 2024 (UTC)
- The error can probably be removed from the user space. Other than in user space (which the updated code isn't placing in Category:WikiProject banners without banner shells (pages there need to be purged to reflect the update), so will not be relevant here), almost all pages have already been placed inside the banner shell, so any change at this point is purely disruptive, in addition of course, to the fact that no ones owns project pages so no one is forced into anything. Having the shell, even for one template, provides a consistent look across the entire project and allows any future update (which might be relevant to pages with a single template), to have an immediate effect. Gonnym (talk) 07:43, 18 August 2024 (UTC)
no ones owns project pages so no one is forced into anything
- by that logic, we should not be forced to use WPBS for a single banner by having big warning sign about it. And just to reiterate (and expand) on what I said above - I don't mind the warning if WPBS is already there (because that makes sense) and I don't care if a bot goes around adding WPBS (even for pages that have a single banner), my only concern is the massive warning given if WPBS isn't on the page already. Primefac (talk) 10:40, 18 August 2024 (UTC)- (No it's not too late to object!) We certainly can (and should) remove the message from non-article pages. For a start the message is incorrect, because these pages are detected automatically so don't even have a
|class=
parameter that needs transferring. What about mainspace though? We have no efficient method (that I know of) to detect the number of banners on a page, so we have to treat one banner the same as 8 banners. In mainspace we absolutely do want WPBS on every talk page. We are now 18 months into the new system, and it seems that a little editor education is needed, which is what the warning is trying to do. — Martin (MSGJ · talk) 19:26, 18 August 2024 (UTC)- We also have a bot that, once the backlog is cleared, will fix/update any new pages that aren't following PIQA. Just a thought. It probably makes editors complacent (look how many dated maintenance tags get tagged by AnomieBOT every day instead of folks just putting the date, which is piss-easy) but that's why we have bots like this in the first place. Primefac (talk) 20:10, 18 August 2024 (UTC)
- Yeah, the bot is good when it works. For some reason it is not clearing Category:Articles with WikiProject banners but without a banner shell very quickly — Martin (MSGJ · talk) 17:30, 19 August 2024 (UTC)
- I have removed the warning (numbered 2 above) in the sandbox. Hopefully the bot will catch up with these soon — Martin (MSGJ · talk) 17:41, 19 August 2024 (UTC)
- We also have a bot that, once the backlog is cleared, will fix/update any new pages that aren't following PIQA. Just a thought. It probably makes editors complacent (look how many dated maintenance tags get tagged by AnomieBOT every day instead of folks just putting the date, which is piss-easy) but that's why we have bots like this in the first place. Primefac (talk) 20:10, 18 August 2024 (UTC)
- (No it's not too late to object!) We certainly can (and should) remove the message from non-article pages. For a start the message is incorrect, because these pages are detected automatically so don't even have a
- The error can probably be removed from the user space. Other than in user space (which the updated code isn't placing in Category:WikiProject banners without banner shells (pages there need to be purged to reflect the update), so will not be relevant here), almost all pages have already been placed inside the banner shell, so any change at this point is purely disruptive, in addition of course, to the fact that no ones owns project pages so no one is forced into anything. Having the shell, even for one template, provides a consistent look across the entire project and allows any future update (which might be relevant to pages with a single template), to have an immediate effect. Gonnym (talk) 07:43, 18 August 2024 (UTC)
Tracking category proposed
editThere is a proposal to track uses of WikiProject banners which are placed outside the banner shell. The coding might be complex but I think this would be really useful — Martin (MSGJ · talk) 17:38, 29 June 2024 (UTC)
- Originating discussion @ User talk:Kanashimi/Archive 1#Cewbot is moving WikiProject banners outside of WPBS. ~ Tom.Reding (talk ⋅dgaf) 18:12, 9 July 2024 (UTC)
- If there is such a tracking category, my bots will automatically repair them by default. Kanashimi (talk) 08:50, 10 July 2024 (UTC)
- No progress on this, because I haven't figured out the code needed to achieve it — Martin (MSGJ · talk) 07:11, 28 August 2024 (UTC)
Redirects not being added to PIQA category
editI notice that on Talk:Mount Gorton (Mount Gorton redirects to Wilson Hills), all 3 WikiProjects are classified via 3 |class=Stub
, {{WPBS}} is not, and Talk:Mount Gorton is not added to Category:Pages using WikiProject banner shell without a project-independent quality rating (0). Could redirects be made to be included in the category, and eventually corrected? And any/all other page types also being omitted? ~ Tom.Reding (talk ⋅dgaf) 13:28, 1 July 2024 (UTC)
- It is not in that category because it is a redirect and doesn't need a quality rating. The
|class=stub
is just ignored on such pages. What needs to be corrected? — Martin (MSGJ · talk) 14:15, 1 July 2024 (UTC)- Since Talk:Mount Gorton refers to a redirect,
|class=Stub
should be removed from the 3 WikiProjects. - I see now that Pages using WikiProject banner shell without a project-independent quality rating is not an appropriate category name for such cases (as it implies they need a rating), but I still think it would be worth tracking these pages that use unnecessary quality ratings. ~ Tom.Reding (talk ⋅dgaf) 14:53, 1 July 2024 (UTC)
- In that case it should probably be in Category:WikiProject banners with redundant class parameter as the class stub is redundant (and incorrect, as redirects don't have ratings). Gonnym (talk) 15:01, 1 July 2024 (UTC)
- Perhaps we could rename to Category:WikiProject banners with ignored class parameter? — Martin (MSGJ · talk) 15:06, 1 July 2024 (UTC)
- "Redundant" seems most appropriate for proper articles which have a rating both inside a WikiProject and the shell.
- "Ignored" seems most appropriate for these redirects (and other similar pages) which have irrelevant class parameters. ~ Tom.Reding (talk ⋅dgaf) 15:15, 1 July 2024 (UTC)
- They are the same in that the class parameter may safely be removed without having any effect. Do we need two separate categories? — Martin (MSGJ · talk) 15:42, 1 July 2024 (UTC)
- With the speed at which these categories are being cleared, I'd say we don't. Less categories to watch. Gonnym (talk) 16:13, 1 July 2024 (UTC)
- The way that the pages in these 2 would-be categories are fixed is different. In 1, WPBS's
|class=
is kept. In the other, WPBS's|class=
, if found, is removed. Someone working on these categories in the future might not know to check the redirect-status of the page before proceeding, and perform the wrong operation. - But, if there is to be only 1 category to contain both of these cases, then I think "unnecessary" is better, as it can describe both "redundant" & "ignored" ~ Category:WikiProject banners with unnecessary class parameter. 2nd choice would be "ignored". With category text describing this distinction, regardless of the chosen descriptor. ~ Tom.Reding (talk ⋅dgaf) 16:27, 1 July 2024 (UTC) ~ Tom.Reding (talk ⋅dgaf) 16:42, 26 August 2024 (UTC)
- They are the same in that the class parameter may safely be removed without having any effect. Do we need two separate categories? — Martin (MSGJ · talk) 15:42, 1 July 2024 (UTC)
- Perhaps we could rename to Category:WikiProject banners with ignored class parameter? — Martin (MSGJ · talk) 15:06, 1 July 2024 (UTC)
- In that case it should probably be in Category:WikiProject banners with redundant class parameter as the class stub is redundant (and incorrect, as redirects don't have ratings). Gonnym (talk) 15:01, 1 July 2024 (UTC)
- Since Talk:Mount Gorton refers to a redirect,
Preview warning: unexpected parameter "attention"
editI'm getting a red warning saying, unexpected parameter "attention" while attempting the following:
{{WikiProject Intertranswiki/OKA|attention=yes}}
The interesting thing is, that in preview mode it is properly generating the notice with the diamond caution sign and "immediate attention needed", as well as displaying the name of the hidden attention-needed category in the footer that would be populated if I hit Publish, but all of that with the Preview error at the same time.
Not sure if it's relevant, but the PROJECT param is Intertranswiki/OKA task force
, and a couple of redirects are involved:
- the project page WP:WikiProject Intertranswiki/OKA task force is a redirect, pointing to WP:WikiProject Intertranswiki/OKA
- the template Template:WikiProject Intertranswiki/OKA task force is a redirect, targeting {{WikiProject Intertranswiki/OKA}}.
Have I bolloxed it all up with the redirects, somehow? Can someone help me understand what's going on? Mathglot (talk) 07:25, 2 July 2024 (UTC)
- Further data: I went ahead and saved the page with the Preview error anyway, at Draft talk:Contravention in French criminal law with the intention of pointing to the error here, but after publication the error was gone, and the banner message and hidden category look good. So far, so good; but
|attention=
is a valid parameter, so why does it say that it isn't in Preview? Preview mode still displays the error message now, if you edit it. Mathglot (talk) 07:36, 2 July 2024 (UTC) - It's because you did not define the
|BANNER_NAME=
parameter, and so it uses by default Template:WikiProject+PROJECT which in this case yields Template:WikiProject Intertranswiki/OKA task force which is not the template but a redirect. I have added|BANNER_NAME=
which I think has fixed it — Martin (MSGJ · talk) 08:07, 2 July 2024 (UTC)- MSGJ, Yes, it has! Thank you. Given the complexity of this Module, and the type of situations that might arise, I am considering adding a Troubleshooting section to the doc page, and this would be a good entry there. Or at least, where to look if you get that error message, would be a good start. Such a section might expand to cover other situations, as well. Thanks for your fixes to that template. Mathglot (talk) 10:35, 2 July 2024 (UTC)
- In general though, this error should be a very rare edge case, as task forces should not have standalone banners as they should use the one of the project they belong to. In this situation, there isn't a project one at this moment. Gonnym (talk) 10:57, 2 July 2024 (UTC)
- Gonnym, thank you for your comment I did notice that the module had params like
|tfN=
for handling task forces, and I wondered how to proceed with that, given that the parent WikiProject didn't have its own banner, so I did the best I could. What I'm hearing, is, maybe this is too rare a case to be worth writing up as a troubleshooting case, and I accept that. But, what is the right path forward, here? Should Intertranswiki have its own banner, and then */OKA would use the|tfN=
params? Or, is it good enough, the way things are, now? Mathglot (talk) 11:06, 2 July 2024 (UTC)- I think that if there are not going to be any other task forces needing one, then don't bother changing it as it's already working. If another task force will need one then yes, they should be combined into one template. Gonnym (talk) 11:09, 2 July 2024 (UTC)
- Gonnym, thank you for your comment I did notice that the module had params like
- In general though, this error should be a very rare edge case, as task forces should not have standalone banners as they should use the one of the project they belong to. In this situation, there isn't a project one at this moment. Gonnym (talk) 10:57, 2 July 2024 (UTC)
- MSGJ, Yes, it has! Thank you. Given the complexity of this Module, and the type of situations that might arise, I am considering adding a Troubleshooting section to the doc page, and this would be a good entry there. Or at least, where to look if you get that error message, would be a good start. Such a section might expand to cover other situations, as well. Thanks for your fixes to that template. Mathglot (talk) 10:35, 2 July 2024 (UTC)
Dark mode support
editI implemented dark mode support for the banners in these sandbox edits, without those on dark mode the banners are showing white text on light yellow background which is not great. The test cases seem good to me, but I would still appreciate a second set of eyes on the change before deploying it. Taavi (talk!) 22:20, 4 July 2024 (UTC)
- Also Done for the non-sandbox version. Taavi (talk!) 11:58, 7 July 2024 (UTC)
- Thanks. Maybe coordinate with User:Jdlrobson as he was working on this also — Martin (MSGJ · talk) 02:57, 8 July 2024 (UTC)
Military history articles with no associated task force
editCategory:Military history articles with no associated task force is full of articles from the Draft talk namespace. Could the module be adjusted to only add talk namespace articles to the category? Hawkeye7 (discuss) 02:46, 1 August 2024 (UTC)
- That isn't a module fix. You'll have to edit the note_2 of the banner itself. Gonnym (talk) 03:08, 1 August 2024 (UTC)
Urgent: Please fix this template for printed content Module:WikiProject banner/sandbox/styles.css.
editFirstly, apologies for writing in English if this is not your first language (this is an automated message).
This template has been detected as one of 436 pages using styles that break the page when printed when the user is using dark mode. The fix is very straightforward - all your styles relating to dark mode must be scoped to. Since there is a high risk of this templates being copied to other wikis it is important this notice is acted on ASAP.
To fix this:
- Update `@media (prefers-color-scheme: dark` to `@media screen and (prefers-color-scheme: dark`
- Wrap any styles relating to `html.skin-theme-clientpref-night` in `@media screen`
If this message has not been acted on in 7 days, this will be fixed by an automated script. Thank you for your help fixing this important issue.
For any questions feel free to ask them at phab:T369874.
Jon (WMF) (talk) 18:22, 2 August 2024 (UTC) on behalf of the web team.
- I've syncrhonised this sandbox with the live version, which should have fixed these issues. Gonnym: you may want to reapply your changes to the sandbox at some point — Martin (MSGJ · talk) 10:29, 6 August 2024 (UTC)
- I'll pass. Gonnym (talk) 10:31, 6 August 2024 (UTC)
- I've added back the css code to the styles sheet. Perhaps you wouldn't mind checking the code and making sure everything looks okay, and I will deploy — Martin (MSGJ · talk) 20:43, 11 August 2024 (UTC)
- The examples at Module talk:WikiProject banner/testcases look the same between the live and sandbox versions, so it seems so. The Class mask tests have some fails but I'm assuming that is from something else. Gonnym (talk) 21:03, 11 August 2024 (UTC)
- Yeah, the class mask tests were all copied from Template:Class mask and there have been many changes since then. So the tests are outdated and probably need removing. — Martin (MSGJ · talk) 08:37, 16 August 2024 (UTC)
- The examples at Module talk:WikiProject banner/testcases look the same between the live and sandbox versions, so it seems so. The Class mask tests have some fails but I'm assuming that is from something else. Gonnym (talk) 21:03, 11 August 2024 (UTC)
- I've added back the css code to the styles sheet. Perhaps you wouldn't mind checking the code and making sure everything looks okay, and I will deploy — Martin (MSGJ · talk) 20:43, 11 August 2024 (UTC)
- I'll pass. Gonnym (talk) 10:31, 6 August 2024 (UTC)
auto doc category
editCan |DOC=auto
also add the template to the project category? Either Category:WikiProject project
or Category:WikiProject project templates
category. Gonnym (talk) 11:27, 28 May 2024 (UTC)
- Don't see any reason not to do this. Will sort in the next couple of days — Martin (MSGJ · talk) 15:35, 2 June 2024 (UTC)
- Do you want it to check to see if
Category:WikiProject project templates
exists first. If so use it, otherwise useCategory:WikiProject project
? — Martin (MSGJ · talk) 08:24, 4 June 2024 (UTC)- Yes, I think it's best to place it in the templates category if it exists. Gonnym (talk) 08:30, 4 June 2024 (UTC)
- I agree. That is now coded in the sandbox, and will currently appear on sandbox templates for testing. When deployed it will only categorise the live templates. You can check Template:WikiProject Deaf/sandbox (which does not have a templates category) and Template:WikiProject Cycling/sandbox (which does have a templates category) — Martin (MSGJ · talk) 08:52, 4 June 2024 (UTC)
- Great, looks good! Gonnym (talk) 09:19, 4 June 2024 (UTC)
- I agree. That is now coded in the sandbox, and will currently appear on sandbox templates for testing. When deployed it will only categorise the live templates. You can check Template:WikiProject Deaf/sandbox (which does not have a templates category) and Template:WikiProject Cycling/sandbox (which does have a templates category) — Martin (MSGJ · talk) 08:52, 4 June 2024 (UTC)
- Yes, I think it's best to place it in the templates category if it exists. Gonnym (talk) 08:30, 4 June 2024 (UTC)
Gonnym there are about 80 templates (see Category:WikiProject banners with errors) which are not able to populate the project category, because it either doesn't exist or because it is a category redirect. Would you like to review these? — Martin (MSGJ · talk) 12:09, 10 August 2024 (UTC)
- Yeah I'm taking a look at these. So far some sent to CfD, RM, or MfD. Gonnym (talk) 12:20, 10 August 2024 (UTC)
- @MSGJ most of the GLAM sub projects have a category titled: Category:Wikipedia-<project name> collaboration" (such as Category:Wikipedia-Philadelphia Museum of Art collaboration). So a template like Template:WikiProject Philadelphia Museum of Art that has a
|PROJECT_LINK=Wikipedia:GLAM/Philadelphia Museum of Art
can be placed there. That should remove most pages in the category. Gonnym (talk) 11:35, 11 August 2024 (UTC)- Or we can just leave them to add the categories manually, as they are currently doing? When you are done reviewing those, I can turn off the tracking — Martin (MSGJ · talk) 20:00, 11 August 2024 (UTC)
Responsible editing
editCan we please reduce the churn on a module with 11 million transclusions? I pushed back when @Pppery wanted to fully protect the module because I thought template editors could be trusted to edit responsibly, but now I'm thinking he was right. Can all edits be sandboxed and tested prior to deploying. Anything less than urgent should wait in the sandbox for a more substantive edit. We should be at the point where we can make an update to the live module once every 2-3 months — Martin (MSGJ · talk) 08:59, 20 August 2024 (UTC)
CSS background colors need corresponding colors for dark mode compliance
editCSS background colors need corresponding colors for dark mode. I inserted a fix for at least some of them, but apparently I did not follow process. Sorry about that. I'll leave it to others. If you are sandboxing and troubleshooting, you can see if you have resolved the problems by checking the bottom of the "Page information" page for "Background color inline style rule exists without a corresponding text color" Lint errors. To verify the visual appearance, you can go to the "Appearance" section of the right-hand sidebar in Vector 2022 and choose "Dark" under "Color (beta)". Using Special:ExpandTemplates is helpful for locating stray instances of CSS background-color defined without a color. – Jonesey95 (talk) 14:05, 20 August 2024 (UTC)
- I don't know much about this, but I added this to Module:WikiProject banner/sandbox/styles.css and then checked at Template:WikiProject France/testcases but it is still showing as having 2 lint errors, so not sure if that has helped or not. I am using Vector 2022 but I don't see the Appearance section in my browser so can't check that. I notice that there are several other styles which define background-color but not color. Is it safe to use black for all these? — Martin (MSGJ · talk) 12:09, 21 August 2024 (UTC)
- Thanks. If you copy the template call into Special:ExpandTemplates and then search the resulting wikicode for "back", you should see (which renders the box to the left of "This article has not yet received a rating"). That background needs a corresponding color. There are many instances like this in the code, though some of them exist only with specific combinations of parameters and values. I don't think that all of the background colors are in the templatestyles page, but I could be wrong. Here are a couple of places in the code where I matched a "background" assignment with a "color" assignment and was reverted. Assigning "color:black" should be fine until someone wants something more sophisticated in dark mode. – Jonesey95 (talk) 14:13, 21 August 2024 (UTC)
<td class="assess import import-Unknown" style="background:#DCDCDC">[[:Category:Unknown-importance France articles|???]]</td>
- Yes but I added color:black to the assess class so that should cover that particular part — Martin (MSGJ · talk) 18:14, 21 August 2024 (UTC)
- I expect that the Linter is confused about
|style=
defining the background-color while the color is defined in the class. Can the background color be moved to the CSS, or the color be moved to the style? I will also ask our WMF staffer who has been communicating with us about this new Linter flag, because it looks to me as if the td element has both a color and background-color and should not register as an error. – Jonesey95 (talk) 20:39, 21 August 2024 (UTC)- Yes I expect we could define all the background colours in the stylesheet rather than in the config file. We would just need to define each class/importance as a separate class. I could look at this if you think it would help — Martin (MSGJ · talk) 15:50, 22 August 2024 (UTC)
- I haven't had a response yet at WT:Linter, but it has been less than 24 hours, so some patience is still in order. If you think that moving more styles to the CSS stylesheet is a good long-term move anyway, your development time probably won't be wasted. – Jonesey95 (talk) 18:07, 22 August 2024 (UTC)
- Yes I expect we could define all the background colours in the stylesheet rather than in the config file. We would just need to define each class/importance as a separate class. I could look at this if you think it would help — Martin (MSGJ · talk) 15:50, 22 August 2024 (UTC)
- I expect that the Linter is confused about
- Yes but I added color:black to the assess class so that should cover that particular part — Martin (MSGJ · talk) 18:14, 21 August 2024 (UTC)
- Thanks. If you copy the template call into Special:ExpandTemplates and then search the resulting wikicode for "back", you should see
Renaming categories
editAfter a request at WP:CFDS, Category:Top-importance Start-Class Palaeontology articles is supposed to be renamed to Category:Start-Class Palaeontology articles of Top-importance. Am I correct that this module automatically handles categorizing the pages? I feel like it did at one point? When I attempted to move the category, Talk:Paleontological site was no longer in Category:Top-importance Start-Class Palaeontology articles (good) but was also not in Category:Start-Class Palaeontology articles of Top-importance (bad). There are also a bunch of similar categories at WP:CFDW in the same situation.
Courtesy link to {{WikiProject Palaeontology}}, if that helps.
Any help would be appreciated :) Best, HouseBlaster (talk · he/they) 20:19, 23 August 2024 (UTC)
- You will need to update
|QII_FORMAT=C T of I
in Template:WikiProject Palaeontology. Note that the module is set up so these categories are only populated when they exist, so once you move the category they should start filling up again — Martin (MSGJ · talk) 20:38, 23 August 2024 (UTC)- Thank you so much!! Not sure how I missed that… HouseBlaster (talk · he/they) 21:01, 23 August 2024 (UTC)