Misplaced Pages

Template talk:Taxobox: Difference between revisions

Article snapshot taken from Wikipedia with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.
Browse history interactively← Previous editNext edit →Content deleted Content addedVisualWikitext
Revision as of 15:23, 13 July 2024 editLowercase sigmabot III (talk | contribs)Bots, Template editors2,304,779 editsm Archiving 2 discussion(s) to Template talk:Taxobox/Archive 31) (bot← Previous edit Revision as of 08:07, 25 July 2024 edit undoGoszei (talk | contribs)Extended confirmed users, Pending changes reviewers, Template editors86,957 edits Template-protected edit request on 29 June 2024: ReplyTag: ReplyNext edit →
Line 36: Line 36:
: What advantage is there in converting to using {{tl|infobox}}? The {{tl|taxobox}} template predates the infobox system and works effectively. &nbsp;—&nbsp;<span style="white-space: nowrap;font-family:Arial;background:#d6ffe6;border:solid 1px;border-radius:5px;box-shadow:darkcyan 0px 1px 1px;"> ] &#124;]&nbsp;</span> 12:20, 29 June 2024 (UTC) : What advantage is there in converting to using {{tl|infobox}}? The {{tl|taxobox}} template predates the infobox system and works effectively. &nbsp;—&nbsp;<span style="white-space: nowrap;font-family:Arial;background:#d6ffe6;border:solid 1px;border-radius:5px;box-shadow:darkcyan 0px 1px 1px;"> ] &#124;]&nbsp;</span> 12:20, 29 June 2024 (UTC)
::One potential DISadvantage is that text in infoboxes is smaller than text in the body of the article. Most text in taxoboxes is the same size as text in the body of the article, but authorities are usually rendered in smaller text (either via code in the taxobox template for parameters such as {{para|binomial_authority}}, code in other templates such as {{tl|Species list}}, or HTML &lt;small&gt; tags). If taxoboxes used the default smaller text of infoboxes, the authorities would be "double smalled", a size which violates accessibility guidelines. ] (]) 14:27, 29 June 2024 (UTC) ::One potential DISadvantage is that text in infoboxes is smaller than text in the body of the article. Most text in taxoboxes is the same size as text in the body of the article, but authorities are usually rendered in smaller text (either via code in the taxobox template for parameters such as {{para|binomial_authority}}, code in other templates such as {{tl|Species list}}, or HTML &lt;small&gt; tags). If taxoboxes used the default smaller text of infoboxes, the authorities would be "double smalled", a size which violates accessibility guidelines. ] (]) 14:27, 29 June 2024 (UTC)
::I support the suggested conversion to infobox style for the sake of achieving visual consistency across the encyclopedia. I agree with Plantdrew that any ] issues should be resolved before such a change is implemented. — ] (]) 08:07, 25 July 2024 (UTC)


:] '''Not done for now:''' Your work in the sandbox is appreciated and looks very challenging. For now, it appears that a ] needs to be established for this major change. Please garner the needed consensus ''']''' using the {{tlx|edit template-protected}} template again. Thank you very much for your work''!'' ''''']'''''&thinsp;,&nbsp;]&nbsp;]&nbsp;<small>14:27, 29 June 2024 (UTC)</small> :] '''Not done for now:''' Your work in the sandbox is appreciated and looks very challenging. For now, it appears that a ] needs to be established for this major change. Please garner the needed consensus ''']''' using the {{tlx|edit template-protected}} template again. Thank you very much for your work''!'' ''''']'''''&thinsp;,&nbsp;]&nbsp;]&nbsp;<small>14:27, 29 June 2024 (UTC)</small>

Revision as of 08:07, 25 July 2024

To help centralize discussions and keep related topics together, all Taxobox subpage talk pages should redirect here.
Template:Taxobox 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.


This template does not require a rating on Misplaced Pages's content assessment scale.
It is of interest to the following WikiProjects:
WikiProject iconTree of Life
WikiProject iconThis template is within the scope of WikiProject Tree of Life, a collaborative effort to improve the coverage of taxonomy and the phylogenetic tree of life on Misplaced Pages. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.Tree of LifeWikipedia:WikiProject Tree of LifeTemplate:WikiProject Tree of Lifetaxonomic
Microformats
Taxobox is part of, or of interest to, WikiProject Microformats, which encourages the deployment of microformats in Misplaced Pages, and documents them in the article space. If you would like to participate, visit the project page.MicroformatsWikipedia:WikiProject MicroformatsTemplate:WikiProject MicroformatsMicroformats

Archiving icon
Archives
Archive 1Archive 2Archive 3
Archive 4Archive 5Archive 6
Archive 7Archive 8Archive 9
Archive 10Archive 11Archive 12
Archive 13Archive 14Archive 15
Archive 16Archive 17Archive 18
Archive 19Archive 20Archive 21
Archive 22Archive 23Archive 24
Archive 25Archive 26Archive 27
Archive 28Archive 29Archive 30
Archive 31


This page has archives. Sections older than 30 days may be automatically archived by Lowercase sigmabot III when more than 4 sections are present.

Template-protected edit request on 1 May 2024

This edit request to Template:Taxobox/core has been answered. Set the |answered= or |ans= parameter to no to reactivate your request.

Move <templatestyles src="Template:Taxobox/core/styles.css" /> from the top of the template to the bottom, immediately after |}, with no intervening characters.

This will prevent taxoboxes from adding an empty paragraph tag that contains an empty style tag (<p><style data-mw-deduplicate="...">...</style></p>) which is visible as extra space before the lede. The ExpandTemplates link in #TemplateStyles tag generates empty paragraph demonstrates that the placement right after the close of the table works. — Eru·tuon 23:08, 1 May 2024 (UTC)

 Done. The effect can be seen both in Blue petrel and in the testcases. For previewing the sandbox version in Blue petrel, a change in Template:Speciesbox/sandbox was required. —⁠andrybak (talk) 23:45, 1 May 2024 (UTC)
Iirc, placing the templatestyles before the taxobox would allow us to remove the nowiki due parser bug T18700.—  Jts1882 | talk  06:06, 2 May 2024 (UTC)

Conversion of this template to use {{infobox}}

I converted the sandbox version of this template to use {{infobox}} to the best of my abilities, but I couldn't figure out how to make {{taxobox/species}} and {{taxonomy}} look and function exactly the same on the sandbox version of this template as on the original version. PK2 (talk) 05:50, 10 June 2024 (UTC)

Template-protected edit request on 29 June 2024

This edit request to Template:Taxobox/core has been answered. Set the |answered= or |ans= parameter to no to reactivate your request.

Can someone please convert {{taxobox/core}} to use {{infobox}}, like on the majority of other infobox templates? I converted the sandbox version of that template to use {{infobox}} to the best of my abilities three weeks ago on revision 1228241665, but I couldn't figure out how to make {{taxobox/species}} and {{taxonomy}} look and function exactly the same on the sandbox version of that template as on the original version. PK2 (talk; contributions) 11:02, 29 June 2024 (UTC)

What advantage is there in converting to using {{infobox}}? The {{taxobox}} template predates the infobox system and works effectively.  —  Jts1882 | talk  12:20, 29 June 2024 (UTC)
One potential DISadvantage is that text in infoboxes is smaller than text in the body of the article. Most text in taxoboxes is the same size as text in the body of the article, but authorities are usually rendered in smaller text (either via code in the taxobox template for parameters such as |binomial_authority=, code in other templates such as {{Species list}}, or HTML <small> tags). If taxoboxes used the default smaller text of infoboxes, the authorities would be "double smalled", a size which violates accessibility guidelines. Plantdrew (talk) 14:27, 29 June 2024 (UTC)
I support the suggested conversion to infobox style for the sake of achieving visual consistency across the encyclopedia. I agree with Plantdrew that any MOS:SMALL issues should be resolved before such a change is implemented. — Goszei (talk) 08:07, 25 July 2024 (UTC)
 Not done for now: Your work in the sandbox is appreciated and looks very challenging. For now, it appears that a consensus needs to be established for this major change. Please garner the needed consensus before using the {{edit template-protected}} template again. Thank you very much for your work! P.I. Ellsworth , ed.  14:27, 29 June 2024 (UTC)

Why is there no header above the second conservation status?

I don't mean there should be one, but I can't understand why the code doesn't produce one.

If you look at {{taxobox/species}}, it generates the code for the header cell on line 2.

{{#if:{{{2|}}}|
! colspan = 2 {{!}} <div style = "text-align: center">]</div>

This is not conditional (the #if statement in line 1 wraps the whole template), so you'd expect the header each time the template is called.

If you look {{taxobox/core}}, the calls of {{taxobox/species}} are on lines 22 and 23:

|- style="text-align: center{{#if:{{{colour|}}}|{{;}} background-color: {{{colour}}} }}"
{{#if:{{{status|}}}|{{taxobox/species|{{{status_system|}}}|{{{status|}}}|{{{status_ref|}}}|extinction_date={{{extinct|}}} }} }}
|-{{#if:{{{status2|}}}|{{taxobox/species|{{{status2_system|}}}|{{{status2|}}}|{{{status2_ref|}}}|extinction_date={{{extinct|}}} }} }}

The wikitext for the header in {{taxobox/species}} is placed on a new line, but I don't think that new line is output in the wikitext, as if it was the header would appear on the second conservation status. It seems that line 23 generates the following wikitext:

|-! colspan = 2 {{!}} <div style = "text-align: center">]</div>

The header doesn't appear as its wikitext doesn't start on a new line and is ignored. Two tests in edit preview (test with lion) seems to confirm this:

{{#if:{{{2|}}}|! colspan = 2 {{!}} <div style = "text-align: center">]</div>
  • But adding a new line after |- in line 23 of {{taxobox/core}} produces a header for the second conservation status.
|- style="text-align: center{{#if:{{{colour|}}}|{{;}} background-color: {{{colour}}} }}"
{{#if:{{{status|}}}|{{taxobox/species|{{{status_system|}}}|{{{status|}}}|{{{status_ref|}}}|extinction_date={{{extinct|}}} }} }}
|-
{{#if:{{{status2|}}}|{{taxobox/species|{{{status2_system|}}}|{{{status2|}}}|{{{status2_ref|}}}|extinction_date={{{extinct|}}} }} }}

Does this matter? Possibly not if it works. I only discovered this because I added a second conservation status to Ungava brown bear, which uses {{population taxobox}} that uses Module:Biota infobox, and I was surprised to see the second header. In that code I'd added the newlines to generate the proper table wikitext. The fix was to remove the new line so the header doesn't appear, which isn't entirely satisfactory.  —  Jts1882 | talk  13:14, 13 July 2024 (UTC)

Categories: