Template talk:Box-header
{{Talk header|archive=yes}}
{{WikiProject banner shell|
{{WikiProject Portals}}
}}
{{User:ClueBot III/ArchiveThis
|archiveprefix=Template talk:Box-header/Archive
|format= %%i
|age=2190
|maxarchsize=150000
|numberstart=1
|minkeepthreads=5
}}
:You may have been redirected to this page from another template page. This is normal. All related template talk pages should redirect here.
Note: This page contains NOEDITSECTION and NOTOC, and is therefore in general not suitable for use in articles. (See Template talk:Box-header/Archive 1#Fixes for an explanation on how to circumnavigate this and other problems.)
For an explanation on how to use this template, please see Wikipedia:Portal.
Please add a
#REDIRECT Template talk:Box-header
to the talk pages of both newly created templates.
Template-protected edit request on 5 June 2018
{{edit template-protected|Template:Box-header|answered=y}}
The line:
needs to be changed to:
this ensures the semi-colon is always included. At the moment it not being included will cause errors when a custom padding-top is provided.
See example:
{{Box-header
|EDIT=yes
|TOC=no
|SPAN=yes
| padding-top=1em
}}
{{Box-footer}}
| padding-top=1em
}}
{{Box-footer}}
produces in the source:
... padding-top: 1em-moz-border-radius: 0; ...
Thanks,
Dreamy Jazz (talk) 21:15, 5 June 2018 (UTC)
:File:Yes check.svg Done Cabayi (talk) 07:04, 6 June 2018 (UTC)
Template and edit link not working properly
In [https://en.wikipedia.org/w/index.php?title=Portal:Earth_sciences&oldid=844661367 this version of the Earth sciences portal], a couple of things aren't working. The edit link at the top of the box reads
: {{ping|RockMagnetist}} One of the problems is fixed (the In the News section did not have an edit link). The other problem is best asked at the talk page for {{tl|Transclude selected current events}}, as this is the template that included the news onto the portal. Thanks Dreamy Jazz talk | contribs 20:44, 6 June 2018 (UTC)
::The broken edit link is something to do with [//en.wikipedia.org/wiki/Special:Contributions/Evad37?offset=20180604090000&limit=44 these edits] by {{user|Evad37}}. --Redrose64 🌹 (talk) 21:12, 6 June 2018 (UTC)
:::Nah, nothing to do with those edits, which were only to the numbered subpages of Template:Box-header (which in turn call Template:Box-header with specific style values). Portal:Earth sciences uses Portal:Earth sciences/box-header, which calls Box-header directly, not a numbered subpage. The problem came from [https://en.wikipedia.org/w/index.php?title=Portal:Earth_sciences&diff=843416756&oldid=843257382 this edit] which added a
in Portal:Earth sciences/box-header became the literal text
:: {{ping|RockMagnetist}} Fixed the {{tld|Transclude selected current events}} template, or rather its module, which now properly expands any templates found in the items it transcludes - Evad37 [talk] 02:40, 7 June 2018 (UTC)
::: {{ping|Evad37}} Thanks for fixing the problems! RockMagnetist(talk) 04:19, 7 June 2018 (UTC)
Switch to Module:Box-header?
Should this template be switched to use Module:Box-header (i.e. the code currently at Template:Box-header/lua)? It would take the same parameters and produce the same output, but would have the advantage of checking colour combinations for accessibility, per MOS:COLOUR, and reporting uses of inaccessible colours in :Category:Box-header with insufficient title contrast and :Category:Box-header with insufficient body contrast. It would also mean that this template and {{tl|Box-header colour}} would be using the same code, reducing redundancy and allowing any future improvements to be made to both templates. - Evad37 [talk] 07:19, 13 August 2018 (UTC)
Remove production of NOTOC and NOEDITSECTION
I suggest that the magic words NOTOC and NOEDITSECTION are removed from output of this module to allow usage of the template on the pages, where table of contents and edit links are needed. For example: subpages of portals, like Portal:United Kingdom/Featured picture, and talk pages of portals. The overwhelming majority of usages of {{tl|Box-header}} are in portals, and to that end the magic words were added to template {{tl|Portal styles}}, which is transcluded to all portal pages via {{tl|Portal maintenance status}}. Ping {{u|wbm1058}}, who objected to this change. —andrybak (talk) 12:57, 27 February 2021 (UTC)
:See {{section link|Template:Box-header#Behaviour options}} and the guidance just above the TOC at the top of this page. – wbm1058 (talk) 14:28, 27 February 2021 (UTC)
::{{u|Wbm1058}}, I suggest that these parameters are not needed at all and this functionality should be removed from the template. Presence of {{tl|Box-header}}, which produces a part of a page layout, should not affect the layout of the page as a whole. —andrybak (talk) 15:47, 27 February 2021 (UTC)
:::Digging into the edit history, I found this discussion:
{{collapse top|Template talk:Box-header/Archive 1 §Accessibility Issue}}
{{#section-h:Template talk:Box-header/Archive 1|Accessibility Issue}}
{{collapse bottom}}
:::I don't know whether these concerns from 2006 are still valid, and if they are, whether there is a better work-around. Please make your proposed changes in Module:Box-header/sandbox so that they may be reviewed (which you didn't do in December, when these changes surprised me). I think it's likely other editors will be surprised too as this is longstanding behavior in a widely-used template, which you are proposing to change. – wbm1058 (talk) 16:37, 27 February 2021 (UTC)
::::{{tl|Box-header}} is a decorative template for wrapping some content. It is usually used on portals to wrap a section of the page, like selected article, selected picture, etc. My argument is: because it is a part of the page, it should not affect the page-wide formatting. All portals already transclude the template {{tl|Portal styles}}, which adds
to them.
::::Template {{tl|Box-header}} is also used on talk pages of portals in discussions of portal layouts. Affecting the layout of these pages is undesirable. But even without these usages on pages, that are not main portal pages, I claim that production of NOTOC and NOEDITSECTION is illogical for {{tl|Box-header}}.
::::The proposed change in the sandbox: Special:Diff/997693614/1046377628. The template is also fairly widely used for formatting of WikiProject pages – if the suggested change is applied, I'll check the formatting of WikiProject pages to make sure that WikiProjects that use {{tl|Box-header}} have the appropriate formatting of table of contents. —andrybak (talk) 10:59, 25 September 2021 (UTC)
:::::I'm not really a portal user; I noticed this change at Wikipedia:WikiProject Merge. Testing your sandbox version on that project page I saw a TOC where it was suppressed previously, and the "section 1" in the TOC has no heading – what is "section 1" and why is it there? OK I added NOTOC to that page, which is apparently redundant now but is needed if your sandbox goes live. Section editing isn't disabled on that page. wbm1058 (talk) 15:25, 25 September 2021 (UTC)
::::::{{re|wbm1058}} {{tq|the "section 1" in the TOC has no heading – what is "section 1" and why is it there?}} – this is because on page Wikipedia:WikiProject Merge, the first usage of {{tl|Box-header}} has {{para|title|
Forces light mode by default which is an accessibility issue
Black text on white background should never be forced on Wikipedia overriding "dark mode" settings whether in Wikipedia or in the user's browser. This is a major accessibility issue. Can we make this template compatible with dark mode at least by default? —DIYeditor (talk) 22:04, 2 April 2025 (UTC)