Forum:Reworking TitleAnchor backgrounds ⚓
Hello people of the Wiki, I would like to run by you a somewhat impactful change that I am proposing to.
I have been bold and added a sandbox version of the TitleAnchor template, which automatically calculates its text contrast to both the dark and light theme of the wiki and adds a class to the title if the contrast is poor, to automatically add a background in order to make it legible. You can find a comparison of the old and new behaviour on User:ThePsionic/Sandbox 4. This change also completely removes the old
bg parameter, so only the new background logic will be used.
(For the nerds amoung you (and I know that you're out there), a title is deemed "illegible" if the contrast ratio between the background and the text is 3:1, which is equal to level AA for large text in the Web Content Accessibility Guidelines version 2.1. I have chosen for the 3:1 ratio rather than the recommended 4.5:1 ratio for these titles as otherwise pretty much every single title would get a background and that would just be a bit ugly.)
As this is quite a significant change that would impact every single use of Titles and all s, I would like your opinion on the proposed changes. Feel free to play around with the sandbox version ( ) on your own sandbox pages, and let me know what you think!across the wiki, including the giant table on
Support - as nominator and part-time Lua ninja.19:11, 7 June 2021 (UTC)
Harbour - Looks good.20:46, 7 June 2021 (UTC)
Shore - Looks good.21:56, 7 June 2021 (UTC)
Pier - Looks good. Regarding "otherwise pretty much every single title would get a background and that would just be a bit ugly", I think applying the background consistently to all titles wouldn't be that ugly (since that'd just be another kind of consistency). So while I do like this approach more, I don't think that being "a bit ugly" is necessarily true. − Joeytje50 talk 22:33, 7 June 2021 (UTC)
Support02:42, 8 June 2021 (UTC)
Marina - Looks good. Ruud10K 12:35, 8 June 2021 (UTC)
Starboard - I like it.06:54, 9 June 2021 (UTC)