Difference between revisions of "Template:Floruit/sandbox"
(Param name changes.) |
(WIP 2.) |
||
| Line 1: | Line 1: | ||
| − | <!--Begin {{floruit/sandbox}}--><includeonly> | + | <!--Begin {{floruit/sandbox}}--><includeonly>{{#ifeq:{{{pre1|}}}|italics|<em>}}{{#switch:{{{pre2|{{{lk|}}}}}}|no|off=fl.|abbr={{abbr|fl.|floruit}}|#default=[[Floruit|fl.]]}}{{#ifeq:{{{pre1|}}}|italics|</em>}}{{#ifeq:{{{ca|}}}|yes| c.}}{{#if:{{{1|{{{era|}}}}}}| {{#ifeq:{{{sortable|}}}|yes|{{dts|{{{1|{{{era}}}}}}}}|{{{1|{{{era}}}}}}}}}}</includeonly><!--End {{floruit/sandbox}}--><noinclude> |
| − | {{#ifeq:{{{pre1|}}}| | + | {{floruit/sandbox|2010s}} |
| − | {{#switch:{{{pre2|{{{lk|}}}}}} | + | |
| − | |no|off=fl. | + | ==Documentation== |
| − | |abbr={{abbr|fl.|floruit}} | + | The template {{tl|floruit/sandbox}} or [[#Redirects|its aliases]] formats the display of {{em|approximate}} time periods or eras during which people, ideas, or movements may have been active or popular. It utilizes "fl.", an abbreviation of ''[[floruit]]'' or "flourished" (in [[Latin]]), as a prefix to the relevant date(s). The prefix abbreviation is wikilinked to ''floruit'' by default, but users may employ different or additional display options. |
| − | |#default=[[ | + | |
| − | }}{{#ifeq:{{{pre1|}}}| | + | ==Usage== |
| − | :{{floruit/sandbox|era= | + | {{csdoc|usage full}} |
| − | :{{floruit/sandbox| | + | :<code><nowiki>{{floruit/sandbox|era= </nowiki>{{bxt|or}} {{var|[some-date(s)]}}<nowiki>|ca= |sortable= |pre1= |pre2= }}</nowiki></code> |
| − | :{{floruit/sandbox|era= | + | {{end}} |
| − | :{{floruit/sandbox| | + | |
| − | :{{floruit/sandbox|era= | + | Use the template to signify time periods during which people, concepts, scientific theories, or political, cultural, artistic or religious movements etc. were active or popular. [[Floruit|By definition]], the date(s) of such periods may be inexact or approximate. |
| − | :{{floruit/sandbox| | + | |
| − | :{{floruit/sandbox|era= | + | Normally, this template should not be used when {{em|exact dates}} are known, or when such dates should be indicated. For example, this template should not be used for a person's birth and/or death dates, or for an organization's founding and/or dissolution dates; however, it may be used in similar cases when there is no reliable or exact dating information regarding a person's (or organization's etc.) lifespan. |
| − | :{{floruit | + | |
| − | :{{floruit | + | ==Examples== |
| − | </noinclude> | + | *{{strong|Prefix only, wikilinked}} |
| + | :<code><nowiki>{{floruit/sandbox}} 2016</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox}} 2016 | ||
| + | *{{strong|Single year, prefix in plain text}} | ||
| + | :<code><nowiki>{{floruit/sandbox|era=2016|pre2=off}}</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox|era=2016|pre2=off}} | ||
| + | *{{strong|Circa decade, prefix in plain text}} | ||
| + | :<code><nowiki>{{floruit/sandbox|era=2010s|ca=yes|pre2=off}}</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox|era=2010s|ca=yes|pre2=off}} | ||
| + | *{{strong|Year range, prefix with tooltip}} | ||
| + | :<code><nowiki>{{floruit/sandbox|era={{dash year|2010|2016}}|pre2=abbr}}</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox|era={{dash year|2010|2016}}|pre2=abbr}} | ||
| + | :{{en dash}}{{nbsp}}{{em|Uses}} {{tl|dash year}} {{em|to format year range}} | ||
| + | *{{strong|Circa century, prefix wikilinked}} | ||
| + | :<code><nowiki>{{floruit/sandbox|era=21st century CE|ca=yes}}</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox|era=21st century CE|ca=yes}} | ||
| + | *{{strong|Decade range, prefix italicized & wikilinked}} | ||
| + | :<code><nowiki>{{floruit/sandbox|era={{daterange|1990s|2010s}}|pre1=italics}}</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox|era={{daterange|1990s|2010s}}|pre1=italics}} | ||
| + | :{{en dash}}{{nbsp}}{{em|Uses}} {{tl|daterange}} {{em|to format decade range}} | ||
| + | *{{strong|Single year sortable, prefix italicized with tooltip}} | ||
| + | :<code><nowiki>{{floruit/sandbox|era=2016|sortable=yes|pre1=italics|pre2=abbr}}</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox|era=2016|sortable=yes|pre1=italics|pre2=abbr}} | ||
| + | *{{strong|Single year (extracted), prefix italicized & wikilink}} | ||
| + | :<code><nowiki>{{floruit/sandbox|era={{YEAR|1 January 2016}}|pre1=italics}}</nowiki></code> | ||
| + | :Generates: {{floruit/sandbox|era={{YEAR|1 January 2016}}|pre1=italics}} | ||
| + | :{{en dash}}{{nbsp}}{{em|Uses}} {{tl|YEAR}} {{em|to extract year from date}} | ||
| + | |||
| + | ==Parameters== | ||
| + | None of the parameters is required. | ||
| + | |||
| + | ===Date formatting parameters=== | ||
| + | *{{bxtn|era}}{{spaced en dash}}the time period during which the subject is known to have been active or popular. Dated in year(s), decade(s), centuries or other time units. Do not wikilink. Not checked for date-formatting errors. May be any one of Wikipedia's [[MOS:DATEFORMAT|acceptable date formats]], but please follow the relevant format established in the article, if any. The display of this parameter's value is preceded by a [[non-breaking space#NARROW NON BREAKING SPACE|non-breaking thin space]]. | ||
| + | :{{em|Optionally}}, you may insert only the parameter's desired value instead; in such cases, this should be the {{em|first entry}} in the template. | ||
| + | *{{bxtn|ca}}{{spaced en dash}}set {{para|ca|yes}} for [[circa]] dates; adds a [[non-breaking space|non-breaking]] [[thin space]] and the additional prefix "c." before the time period. | ||
| + | *{{bxtn|sortable}}{{spaced en dash}}set {{para|sortable|yes}} to format the time period so that it displays properly within [[WP:TABLESORT|sortable table]]s. | ||
| + | :{{em|Note:}} in order to do proper sorting, this parameter wraps template {{tl|dts}} around the date(s); it works best with single-year dates. | ||
| + | |||
| + | ===Prefix formatting parameters=== | ||
| + | *{{bxtn|pre1}}{{spaced en dash}}use this parameter to {{em|italicize}} the display of the prefix "fl.", by setting {{para|pre1|italics}}. | ||
| + | *{{bxtn|pre2}}{{spaced en dash}}alias {{bxtn|lk}}. By default, the prefix is wikilinked to ''[[floruit]]''. Use this parameter to change the default prefix display, by inserting one of the following options: | ||
| + | **Set {{para|pre2|abbr}} to display a [[tooltip]] when the cursor hovers over "fl.", expanding it to "floruit". | ||
| + | **Set {{para|pre2|no}} or {{para|pre2|off}} to display "fl." as plain text; use to avoid [[WP:Overlinking|overlinking]] when this template is used repeatedly in the body of an article. | ||
| + | |||
| + | ==Redirects== | ||
| + | <!--This section is linked from within this document ([[MOS:HEAD]])--> | ||
| + | {{tl|floruit}} can be replaced with the redirects: | ||
| + | *{{tl|fl.}} | ||
| + | *{{tl|flor}} | ||
| + | *{{tl|flor.}} | ||
| + | *{{tl|flr}} | ||
| + | |||
| + | ==See also== | ||
| + | *{{tl|Circa}} | ||
| + | *{{tl|Reign}} | ||
| + | </noinclude><includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox|| | ||
| + | <!-- Categories go here and interwikis go in Wikidata. --> | ||
| + | [[Category:Internal link templates]] | ||
| + | [[Category:Time, date and calendar templates]] | ||
| + | }}</includeonly> | ||
Revision as of 22:07, 18 February 2016
fl. 2010s
Contents
Documentation
The template {{floruit/sandbox}} or its aliases formats the display of approximate time periods or eras during which people, ideas, or movements may have been active or popular. It utilizes "fl.", an abbreviation of floruit or "flourished" (in Latin), as a prefix to the relevant date(s). The prefix abbreviation is wikilinked to floruit by default, but users may employ different or additional display options.
Usage
|
Use the template to signify time periods during which people, concepts, scientific theories, or political, cultural, artistic or religious movements etc. were active or popular. By definition, the date(s) of such periods may be inexact or approximate.
Normally, this template should not be used when exact dates are known, or when such dates should be indicated. For example, this template should not be used for a person's birth and/or death dates, or for an organization's founding and/or dissolution dates; however, it may be used in similar cases when there is no reliable or exact dating information regarding a person's (or organization's etc.) lifespan.
Examples
- Prefix only, wikilinked
{{floruit/sandbox}} 2016- Generates: fl. 2016
- Single year, prefix in plain text
{{floruit/sandbox|era=2016|pre2=off}}- Generates: fl. 2016
- Circa decade, prefix in plain text
{{floruit/sandbox|era=2010s|ca=yes|pre2=off}}- Generates: fl. c. 2010s
- Year range, prefix with tooltip
{{floruit/sandbox|era={{dash year|2010|2016}}|pre2=abbr}}- Generates: fl. 2010–16
- – Uses {{dash year}} to format year range
- Circa century, prefix wikilinked
{{floruit/sandbox|era=21st century CE|ca=yes}}- Generates: fl. c. 21st century CE
- Decade range, prefix italicized & wikilinked
{{floruit/sandbox|era={{daterange|1990s|2010s}}|pre1=italics}}- Generates: fl. 1990s to 2010s
- – Uses {{daterange}} to format decade range
- Single year sortable, prefix italicized with tooltip
{{floruit/sandbox|era=2016|sortable=yes|pre1=italics|pre2=abbr}}- Generates: fl. 2016
- Single year (extracted), prefix italicized & wikilink
{{floruit/sandbox|era={{YEAR|1 January 2016}}|pre1=italics}}- Generates: fl. Template:YEAR
- – Uses {{YEAR}} to extract year from date
Parameters
None of the parameters is required.
Date formatting parameters
- eraTemplate:Spaced en dashthe time period during which the subject is known to have been active or popular. Dated in year(s), decade(s), centuries or other time units. Do not wikilink. Not checked for date-formatting errors. May be any one of Wikipedia's acceptable date formats, but please follow the relevant format established in the article, if any. The display of this parameter's value is preceded by a non-breaking thin space.
- Optionally, you may insert only the parameter's desired value instead; in such cases, this should be the first entry in the template.
- caTemplate:Spaced en dashset
|ca=yesfor circa dates; adds a non-breaking thin space and the additional prefix "c." before the time period. - sortableTemplate:Spaced en dashset
|sortable=yesto format the time period so that it displays properly within sortable tables.
- Note: in order to do proper sorting, this parameter wraps template {{dts}} around the date(s); it works best with single-year dates.
Prefix formatting parameters
- pre1Template:Spaced en dashuse this parameter to italicize the display of the prefix "fl.", by setting
|pre1=italics. - pre2Template:Spaced en dashalias lk. By default, the prefix is wikilinked to floruit. Use this parameter to change the default prefix display, by inserting one of the following options:
- Set
|pre2=abbrto display a tooltip when the cursor hovers over "fl.", expanding it to "floruit". - Set
|pre2=noor|pre2=offto display "fl." as plain text; use to avoid overlinking when this template is used repeatedly in the body of an article.
- Set
Redirects
{{floruit}} can be replaced with the redirects: