Template:Infobox medal templates: Difference between revisions

Jump to navigation Jump to search
m (1 revision imported)
No edit summary
Line 1: Line 1:
{{#if:{{{medals|}}}|<div class="NavFrame {{#if:{{{expand|}}}||collapsed}}" style="border: none; padding: 0;">
{{Documentation subpage}}
    <div class="NavHead" style="font-size:105%; text-align: center; {{{titlestyle|background-color: transparent;}}}"><!--
<!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see [[Wikipedia:Wikidata]]) -->
     -->{{#if:{{{title|}}}|{{{title}}}|Medal record}}<!--
{{high-use}}
--></div>
This template is used to add a collapsible medal templates section in an infobox.  It is meant to be used in the infobox code, and not in the article directly.
    <div class="NavContent" style="font-size:105%; font-weight: normal; width: 100%;">
 
{{{!}} style="width:100%; background-color: #f9f9f9; color: #000000;"
== Usage ==
{{!}}-
{{Infobox
{{!}}  
| above = Athlete
{{{medals}}}
| label1 = Sport
{{!}}}
| data1  = Foo
</div></div>
| header5 = {{Parameter names example|medals|expand|title|titlestyle}}
}}{{#ifeq:{{str left|{{{medal_templates|}}}|2}}|{{{!}}|[[Category:Infobox medal templates requiring repair]]|}}<noinclude>{{documentation}}</noinclude>
}}
 
<syntaxhighlight lang="wikitext">
{{Infobox
| above = Athlete
| label1 = Sport
| data1  = Foo
 
...
 
| header5 = {{Infobox medal templates
  | medals = {{{medaltemplates|}}}
  | expand = {{{medaltemplates-expand|}}}
  | title = <!-- optional; default is "Medal record" -->
  | titlestyle = <!-- optional; default is "background-color: transparent;" -->
}}
 
}}
</syntaxhighlight>
 
== Note ==
Do not enclose the medal templates with {{tl|MedalTop}}, {{tl|MedalBottom}}, or any other table header/footer templates, as this will cause the template to break.  Most instances of this misuse are tracked in [[:Category:Infobox medal templates requiring repair]].
 
==TemplateData==
{{TemplateData header}}
<templatedata>
{
"description": "This template is used to add a collapsible medal templates section in an infobox.  It is meant to be used in the infobox code, and not in the article directly.",
"params": {
"medals": {
"label": "Medals",
"description": "Medal templates",
"type": "string",
"required": true
},
"expand": {
"label": "Expand",
"description": "Any value here will expand (display) the medal templates section. It is collapsed by default.",
"type": "boolean",
"suggested": true
},
"title": {
"label": "Title",
"description": "Customize the title",
"type": "string",
"default": "Medal record"
},
"titlestyle": {
"label": "Title style",
"description": "CSS style rules for the title",
"type": "string",
"default": "background-color:transparent;"
}
}
}
</templatedata>
 
==Example==
{{Infobox sportsperson
| name            = Kaori Icho
| birth_date      = {{Birth-date and age|13 June 1984}}
| birth_place     = [[Hachinohe, Aomori]], Japan
| height          = 166 cm (2016)
| medaltemplates  =
{{MedalSport | Women's [[freestyle wrestling]] }}
{{MedalCountry | {{JPN}} }}
{{MedalCount | total = yes
| [[Summer Olympic Games|Olympic Games]] | 4 | – | –
| [[World Wrestling Championships|World Championships]] | 10 | – | –
| [[Asian Games]] | 1 | 1 | –
}}
{{MedalCompetition | [[Wrestling at the Summer Olympics|Olympic Games]] }}
{{MedalGold | [[2004 Summer Olympics|2004 Athens]] | [[Wrestling at the 2004 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2008 Summer Olympics|2008 Beijing]] | [[Wrestling at the 2008 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2012 Summer Olympics|2012 London]] | [[Wrestling at the 2012 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2016 Summer Olympics|2016 Rio de Janeiro]] | [[Wrestling at the 2016 Summer Olympics – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[World Wrestling Championships|World Championships]] }}
{{MedalGold | [[2002 World Wrestling Championships|2002 Chalkida]] | 63&nbsp;kg }}
{{MedalGold | [[2003 World Wrestling Championships|2003 New York]] | 63&nbsp;kg }}
{{MedalGold | [[2005 World Wrestling Championships|2005 Budapest]] | 63&nbsp;kg }}
{{MedalGold | [[2006 World Wrestling Championships|2006 Guangzhou]] | 63&nbsp;kg }}
{{MedalGold | [[2007 World Wrestling Championships|2007 Baku]] | 63&nbsp;kg }}
{{MedalGold | [[2010 World Wrestling Championships|2010 Moscow]] | [[2010 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2011 World Wrestling Championships|2011 Istanbul]] | [[2011 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2013 World Wrestling Championships|2013 Budapest]] | [[2013 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2014 World Wrestling Championships|2014 Tashkent]] | [[2014 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalGold | [[2015 World Wrestling Championships|2015 Las Vegas]] | [[2015 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[Asian Games]] }}
{{MedalSilver | [[Wrestling at the 2002 Asian Games|2002 Busan]] | [[Wrestling at the 2002 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[Wrestling at the 2006 Asian Games|2006 Doha]] | [[Wrestling at the 2006 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
| show-medals      = yes
}}
As implemented in {{tl|Infobox sportsperson}}.
 
<syntaxhighlight lang="wikitext" style="white-space:pre>
{{Infobox sportsperson
| name            = Kaori Icho
| birth_date      = {{Birth-date and age|13 June 1984}}
| birth_place      = [[Hachinohe, Aomori]], Japan
| height          = 166 cm (2016)
| medaltemplates  =
{{MedalSport | Women's [[freestyle wrestling]] }}
{{MedalCountry | {{JPN}} }}
{{MedalCount | total = yes
| [[Summer Olympic Games|Olympic Games]] | 4 | – | –
| [[World Wrestling Championships|World Championships]] | 10 | – | –
| [[Asian Games]] | 1 | 1 | –
}}
{{MedalCompetition | [[Wrestling at the Summer Olympics|Olympic Games]] }}
{{MedalGold | [[2004 Summer Olympics|2004 Athens]] | [[Wrestling at the 2004 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2008 Summer Olympics|2008 Beijing]] | [[Wrestling at the 2008 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2012 Summer Olympics|2012 London]] | [[Wrestling at the 2012 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2016 Summer Olympics|2016 Rio de Janeiro]] | [[Wrestling at the 2016 Summer Olympics – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[World Wrestling Championships|World Championships]] }}
{{MedalGold | [[2002 World Wrestling Championships|2002 Chalkida]] | 63&nbsp;kg }}
{{MedalGold | [[2003 World Wrestling Championships|2003 New York]] | 63&nbsp;kg }}
{{MedalGold | [[2005 World Wrestling Championships|2005 Budapest]] | 63&nbsp;kg }}
{{MedalGold | [[2006 World Wrestling Championships|2006 Guangzhou]] | 63&nbsp;kg }}
{{MedalGold | [[2007 World Wrestling Championships|2007 Baku]] | 63&nbsp;kg }}
{{MedalGold | [[2010 World Wrestling Championships|2010 Moscow]] | [[2010 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2011 World Wrestling Championships|2011 Istanbul]] | [[2011 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2013 World Wrestling Championships|2013 Budapest]] | [[2013 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2014 World Wrestling Championships|2014 Tashkent]] | [[2014 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalGold | [[2015 World Wrestling Championships|2015 Las Vegas]] | [[2015 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[Asian Games]] }}
{{MedalSilver | [[Wrestling at the 2002 Asian Games|2002 Busan]] | [[Wrestling at the 2002 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[Wrestling at the 2006 Asian Games|2006 Doha]] | [[Wrestling at the 2006 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
| show-medals      = yes
}}
</syntaxhighlight>
{{clear}}
 
== Templates using this template ==
{| class="wikitable sortable"
|+ List of templates which implement <nowiki>{{Infobox medal templates}}</nowiki>
|-
! Template name !! Default !! Accept 'no'? !! Show param !! Title !! Title param
|-
| {{tlx|Infobox alpine ski racer}} || collapsed || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox amateur wrestler}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox badminton player}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox bandy biography}} || expanded || N || medaltemplates-expand || Honours || medaltemplates-title
|-
| {{tlx|Infobox basketball biography}} || expanded || Y || show-medals<br />medaltemplates-expand<br />medal_templates-expand || Medals || ''none''
|-
| {{tlx|Infobox biathlete}}<br />&nbsp;&nbsp;''via Infobox sportsperson (* = different behavior)'' || collapsed* || N* || show-medals || Medal record || ''none''*
|-
| {{tlx|Infobox boxer}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox boxer (amateur)}}<br />&nbsp;&nbsp;''via Infobox sportsperson (* = different behavior)'' || collapsed* || N* || show-medals || Medal record || ''none''*
|-
| {{tlx|Infobox climber}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox college coach}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox curler}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox cyclist}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox darts player}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox equestrian}} || collapsed || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox fencer}} || collapsed || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox field hockey player}} || expanded || N || medaltemplates-expand || Medal record || ''none''
|-
| {{tlx|Infobox figure skater}} || collapsed || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox football biography}} || collapsed || N || medaltemplates-expand || Honours || medaltemplates-title
|-
| {{tlx|Infobox go player}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox gymnast}} || collapsed || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox ice hockey player}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox lacrosse player}} || collapsed || N || medaltemplates-expand<br />medal_templates-expand || Medal record || ''none''
|-
| {{tlx|Infobox martial artist}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox national basketball team}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox national football team}} || collapsed || N || medaltemplates-expand || Honours || ''none''
|-
| {{tlx|Infobox cricket team}} || expanded || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox national volleyball team}} || collapsed || N || medaltemplates-expand || Honours || medaltemplates-title
|-
| {{tlx|Infobox NCAA athlete}} || collapsed || N || medaltemplates-expand<br />medal_templates-expand || Medal record || ''none''
|-
| {{tlx|Infobox netball biography}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox sailor}}<br />&nbsp;&nbsp;''via Infobox sportsperson (* = different behavior)'' || collapsed* || N* || show-medals || Medal record || medaltemplates-title
|-
| {{tlx|Infobox skier}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox speed skater}}<br />&nbsp;&nbsp;''via Infobox sportsperson (* = different behavior)'' || expanded || Y || show-medals || Medal record || ''none''*
|-
| {{tlx|Infobox sport wrestler}}<br />&nbsp;&nbsp;''via Infobox sportsperson (* = different behavior)'' || expanded || Y || show-medals || Medal record || ''none''*
|-
| {{tlx|Infobox sportsperson}} || expanded || Y || show-medals || Medal record || medaltemplates-title
|-
| {{tlx|Infobox squash player}} || expanded || Y || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox swimmer}}<br />&nbsp;&nbsp;''via Infobox sportsperson (* = different behavior)'' || collapsed* || N* || show-medals || Medal record || ''none''*
|-
| {{tlx|Infobox synchronized skating team}} || collapsed || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox table tennis player}} || collapsed || N || show-medals || Medal record || ''none''
|-
| {{tlx|Infobox tennis biography}} || collapsed || N || medaltemplates-expand || Medal record || medaltemplates-title
|-
| {{tlx|Infobox volleyball biography}} || expanded || N || medaltemplates-expand || Honours || medaltemplates-title
|}
 
== Tracking category ==
* {{clc|Infobox medal templates requiring repair}}
 
== See also ==
* {{tl|MedalBox}}
* {{tl|MedalTableTop}}, {{tl|MedalTop}}, {{tl|MedalBottom}}
* {{tl|CompetitionRecordTableTop}}, {{tl|CompetitionRecordBottom}}
 
<includeonly>{{Sandbox other||
<!-- Categories below this line, please; interwikis at Wikidata -->
[[Category:Medal infobox templates|Medal templates]]
[[Category:Templates that add a tracking category]]
}}</includeonly>

Revision as of 06:23, 14 February 2024

This template is used to add a collapsible medal templates section in an infobox. It is meant to be used in the infobox code, and not in the article directly.

Usage

Athlete
SportFoo

This template is used to add a collapsible medal templates section in an infobox. It is meant to be used in the infobox code, and not in the article directly.

Usage

Athlete
SportFoo
Template loop detected: Template:Parameter names example
{{Infobox
| above = Athlete
| label1 = Sport
| data1  = Foo

...

| header5 = {{Infobox medal templates
  | medals = {{{medaltemplates|}}}
  | expand = {{{medaltemplates-expand|}}} 
  | title = <!-- optional; default is "Medal record" -->
  | titlestyle = <!-- optional; default is "background-color: transparent;" -->
 }}

}}

Note

Do not enclose the medal templates with {{MedalTop}}, {{MedalBottom}}, or any other table header/footer templates, as this will cause the template to break. Most instances of this misuse are tracked in Category:Infobox medal templates requiring repair.

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for Infobox medal templates

This template is used to add a collapsible medal templates section in an infobox. It is meant to be used in the infobox code, and not in the article directly.

Template parameters

ParameterDescriptionTypeStatus
Medalsmedals

Medal templates

Stringrequired
Expandexpand

Any value here will expand (display) the medal templates section. It is collapsed by default.

Booleansuggested
Titletitle

Customize the title

Default
Medal record
Stringoptional
Title styletitlestyle

CSS style rules for the title

Default
background-color:transparent;
Stringoptional

Example

Kaori Icho
Personal information
Born13 June 1984 (1984-06-13) (age 40)
Hachinohe, Aomori, Japan
Height166 cm (5 ft 5 in) (2016)
Template loop detected: Template:Infobox medal templates

As implemented in {{Infobox sportsperson}}.

{{Infobox sportsperson
| name             = Kaori Icho
| birth_date       = {{Birth-date and age|13 June 1984}}
| birth_place      = [[Hachinohe, Aomori]], Japan
| height           = 166 cm (2016)
| medaltemplates   = 
{{MedalSport | Women's [[freestyle wrestling]] }}
{{MedalCountry | {{JPN}} }}
{{MedalCount | total = yes
| [[Summer Olympic Games|Olympic Games]] | 4 | – | – 
| [[World Wrestling Championships|World Championships]] | 10 | – | – 
| [[Asian Games]] | 1 | 1 | – 
}}
{{MedalCompetition | [[Wrestling at the Summer Olympics|Olympic Games]] }}
{{MedalGold | [[2004 Summer Olympics|2004 Athens]] | [[Wrestling at the 2004 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2008 Summer Olympics|2008 Beijing]] | [[Wrestling at the 2008 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2012 Summer Olympics|2012 London]] | [[Wrestling at the 2012 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2016 Summer Olympics|2016 Rio de Janeiro]] | [[Wrestling at the 2016 Summer Olympics – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[World Wrestling Championships|World Championships]] }}
{{MedalGold | [[2002 World Wrestling Championships|2002 Chalkida]] | 63&nbsp;kg }}
{{MedalGold | [[2003 World Wrestling Championships|2003 New York]] | 63&nbsp;kg }}
{{MedalGold | [[2005 World Wrestling Championships|2005 Budapest]] | 63&nbsp;kg }}
{{MedalGold | [[2006 World Wrestling Championships|2006 Guangzhou]] | 63&nbsp;kg }}
{{MedalGold | [[2007 World Wrestling Championships|2007 Baku]] | 63&nbsp;kg }}
{{MedalGold | [[2010 World Wrestling Championships|2010 Moscow]] | [[2010 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2011 World Wrestling Championships|2011 Istanbul]] | [[2011 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2013 World Wrestling Championships|2013 Budapest]] | [[2013 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2014 World Wrestling Championships|2014 Tashkent]] | [[2014 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalGold | [[2015 World Wrestling Championships|2015 Las Vegas]] | [[2015 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[Asian Games]] }}
{{MedalSilver | [[Wrestling at the 2002 Asian Games|2002 Busan]] | [[Wrestling at the 2002 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[Wrestling at the 2006 Asian Games|2006 Doha]] | [[Wrestling at the 2006 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
| show-medals      = yes
}}

Templates using this template

List of templates which implement {{Infobox medal templates}}
Template name Default Accept 'no'? Show param Title Title param
{{Infobox alpine ski racer}} collapsed N show-medals Medal record none
{{Infobox amateur wrestler}} expanded Y show-medals Medal record none
{{Infobox badminton player}} expanded Y show-medals Medal record none
{{Infobox bandy biography}} expanded N medaltemplates-expand Honours medaltemplates-title
{{Infobox basketball biography}} expanded Y show-medals
medaltemplates-expand
medal_templates-expand
Medals none
{{Infobox biathlete}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox boxer}} expanded Y show-medals Medal record none
{{Infobox boxer (amateur)}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox climber}} expanded Y show-medals Medal record none
{{Infobox college coach}} expanded Y show-medals Medal record none
{{Infobox curler}} expanded Y show-medals Medal record none
{{Infobox cyclist}} expanded Y show-medals Medal record none
{{Infobox darts player}} expanded Y show-medals Medal record none
{{Infobox equestrian}} collapsed N show-medals Medal record none
{{Infobox fencer}} collapsed N show-medals Medal record none
{{Infobox field hockey player}} expanded N medaltemplates-expand Medal record none
{{Infobox figure skater}} collapsed N show-medals Medal record none
{{Infobox football biography}} collapsed N medaltemplates-expand Honours medaltemplates-title
{{Infobox go player}} expanded Y show-medals Medal record none
{{Infobox gymnast}} collapsed N show-medals Medal record none
{{Infobox ice hockey player}} expanded Y show-medals Medal record none
{{Infobox lacrosse player}} collapsed N medaltemplates-expand
medal_templates-expand
Medal record none
{{Infobox martial artist}} expanded Y show-medals Medal record none
{{Infobox national basketball team}} expanded Y show-medals Medal record none
{{Infobox national football team}} collapsed N medaltemplates-expand Honours none
{{Infobox cricket team}} expanded N show-medals Medal record none
{{Infobox national volleyball team}} collapsed N medaltemplates-expand Honours medaltemplates-title
{{Infobox NCAA athlete}} collapsed N medaltemplates-expand
medal_templates-expand
Medal record none
{{Infobox netball biography}} expanded Y show-medals Medal record none
{{Infobox sailor}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record medaltemplates-title
{{Infobox skier}} expanded Y show-medals Medal record none
{{Infobox speed skater}}
  via Infobox sportsperson (* = different behavior)
expanded Y show-medals Medal record none*
{{Infobox sport wrestler}}
  via Infobox sportsperson (* = different behavior)
expanded Y show-medals Medal record none*
{{Infobox sportsperson}} expanded Y show-medals Medal record medaltemplates-title
{{Infobox squash player}} expanded Y show-medals Medal record none
{{Infobox swimmer}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox synchronized skating team}} collapsed N show-medals Medal record none
{{Infobox table tennis player}} collapsed N show-medals Medal record none
{{Infobox tennis biography}} collapsed N medaltemplates-expand Medal record medaltemplates-title
{{Infobox volleyball biography}} expanded N medaltemplates-expand Honours medaltemplates-title

Tracking category

See also

{{Infobox
| above = Athlete
| label1 = Sport
| data1  = Foo

...

| header5 = {{Infobox medal templates
  | medals = {{{medaltemplates|}}}
  | expand = {{{medaltemplates-expand|}}} 
  | title = <!-- optional; default is "Medal record" -->
  | titlestyle = <!-- optional; default is "background-color: transparent;" -->
 }}

}}

Note

Do not enclose the medal templates with {{MedalTop}}, {{MedalBottom}}, or any other table header/footer templates, as this will cause the template to break. Most instances of this misuse are tracked in Category:Infobox medal templates requiring repair.

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for Infobox medal templates

This template is used to add a collapsible medal templates section in an infobox. It is meant to be used in the infobox code, and not in the article directly.

Template parameters

ParameterDescriptionTypeStatus
Medalsmedals

Medal templates

Stringrequired
Expandexpand

Any value here will expand (display) the medal templates section. It is collapsed by default.

Booleansuggested
Titletitle

Customize the title

Default
Medal record
Stringoptional
Title styletitlestyle

CSS style rules for the title

Default
background-color:transparent;
Stringoptional

Example

Kaori Icho
Personal information
Born13 June 1984 (1984-06-13) (age 40)
Hachinohe, Aomori, Japan
Height166 cm (5 ft 5 in) (2016)

This template is used to add a collapsible medal templates section in an infobox. It is meant to be used in the infobox code, and not in the article directly.

Usage

Athlete
SportFoo
{{Infobox
| above = Athlete
| label1 = Sport
| data1  = Foo

...

| header5 = {{Infobox medal templates
  | medals = {{{medaltemplates|}}}
  | expand = {{{medaltemplates-expand|}}} 
  | title = <!-- optional; default is "Medal record" -->
  | titlestyle = <!-- optional; default is "background-color: transparent;" -->
 }}

}}

Note

Do not enclose the medal templates with {{MedalTop}}, {{MedalBottom}}, or any other table header/footer templates, as this will cause the template to break. Most instances of this misuse are tracked in Category:Infobox medal templates requiring repair.

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for Infobox medal templates

This template is used to add a collapsible medal templates section in an infobox. It is meant to be used in the infobox code, and not in the article directly.

Template parameters

ParameterDescriptionTypeStatus
Medalsmedals

Medal templates

Stringrequired
Expandexpand

Any value here will expand (display) the medal templates section. It is collapsed by default.

Booleansuggested
Titletitle

Customize the title

Default
Medal record
Stringoptional
Title styletitlestyle

CSS style rules for the title

Default
background-color:transparent;
Stringoptional

Example

Template loop detected: Template:Infobox sportsperson As implemented in {{Infobox sportsperson}}.

{{Infobox sportsperson
| name             = Kaori Icho
| birth_date       = {{Birth-date and age|13 June 1984}}
| birth_place      = [[Hachinohe, Aomori]], Japan
| height           = 166 cm (2016)
| medaltemplates   = 
{{MedalSport | Women's [[freestyle wrestling]] }}
{{MedalCountry | {{JPN}} }}
{{MedalCount | total = yes
| [[Summer Olympic Games|Olympic Games]] | 4 | – | – 
| [[World Wrestling Championships|World Championships]] | 10 | – | – 
| [[Asian Games]] | 1 | 1 | – 
}}
{{MedalCompetition | [[Wrestling at the Summer Olympics|Olympic Games]] }}
{{MedalGold | [[2004 Summer Olympics|2004 Athens]] | [[Wrestling at the 2004 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2008 Summer Olympics|2008 Beijing]] | [[Wrestling at the 2008 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2012 Summer Olympics|2012 London]] | [[Wrestling at the 2012 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2016 Summer Olympics|2016 Rio de Janeiro]] | [[Wrestling at the 2016 Summer Olympics – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[World Wrestling Championships|World Championships]] }}
{{MedalGold | [[2002 World Wrestling Championships|2002 Chalkida]] | 63&nbsp;kg }}
{{MedalGold | [[2003 World Wrestling Championships|2003 New York]] | 63&nbsp;kg }}
{{MedalGold | [[2005 World Wrestling Championships|2005 Budapest]] | 63&nbsp;kg }}
{{MedalGold | [[2006 World Wrestling Championships|2006 Guangzhou]] | 63&nbsp;kg }}
{{MedalGold | [[2007 World Wrestling Championships|2007 Baku]] | 63&nbsp;kg }}
{{MedalGold | [[2010 World Wrestling Championships|2010 Moscow]] | [[2010 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2011 World Wrestling Championships|2011 Istanbul]] | [[2011 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2013 World Wrestling Championships|2013 Budapest]] | [[2013 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2014 World Wrestling Championships|2014 Tashkent]] | [[2014 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalGold | [[2015 World Wrestling Championships|2015 Las Vegas]] | [[2015 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[Asian Games]] }}
{{MedalSilver | [[Wrestling at the 2002 Asian Games|2002 Busan]] | [[Wrestling at the 2002 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[Wrestling at the 2006 Asian Games|2006 Doha]] | [[Wrestling at the 2006 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
| show-medals      = yes
}}

Templates using this template

List of templates which implement {{Infobox medal templates}}
Template name Default Accept 'no'? Show param Title Title param
{{Infobox alpine ski racer}} collapsed N show-medals Medal record none
{{Infobox amateur wrestler}} expanded Y show-medals Medal record none
{{Infobox badminton player}} expanded Y show-medals Medal record none
{{Infobox bandy biography}} expanded N medaltemplates-expand Honours medaltemplates-title
{{Infobox basketball biography}} expanded Y show-medals
medaltemplates-expand
medal_templates-expand
Medals none
{{Infobox biathlete}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox boxer}} expanded Y show-medals Medal record none
{{Infobox boxer (amateur)}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox climber}} expanded Y show-medals Medal record none
{{Infobox college coach}} expanded Y show-medals Medal record none
{{Infobox curler}} expanded Y show-medals Medal record none
{{Infobox cyclist}} expanded Y show-medals Medal record none
{{Infobox darts player}} expanded Y show-medals Medal record none
{{Infobox equestrian}} collapsed N show-medals Medal record none
{{Infobox fencer}} collapsed N show-medals Medal record none
{{Infobox field hockey player}} expanded N medaltemplates-expand Medal record none
{{Infobox figure skater}} collapsed N show-medals Medal record none
{{Infobox football biography}} collapsed N medaltemplates-expand Honours medaltemplates-title
{{Infobox go player}} expanded Y show-medals Medal record none
{{Infobox gymnast}} collapsed N show-medals Medal record none
{{Infobox ice hockey player}} expanded Y show-medals Medal record none
{{Infobox lacrosse player}} collapsed N medaltemplates-expand
medal_templates-expand
Medal record none
{{Infobox martial artist}} expanded Y show-medals Medal record none
{{Infobox national basketball team}} expanded Y show-medals Medal record none
{{Infobox national football team}} collapsed N medaltemplates-expand Honours none
{{Infobox cricket team}} expanded N show-medals Medal record none
{{Infobox national volleyball team}} collapsed N medaltemplates-expand Honours medaltemplates-title
{{Infobox NCAA athlete}} collapsed N medaltemplates-expand
medal_templates-expand
Medal record none
{{Infobox netball biography}} expanded Y show-medals Medal record none
{{Infobox sailor}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record medaltemplates-title
{{Infobox skier}} expanded Y show-medals Medal record none
{{Infobox speed skater}}
  via Infobox sportsperson (* = different behavior)
expanded Y show-medals Medal record none*
{{Infobox sport wrestler}}
  via Infobox sportsperson (* = different behavior)
expanded Y show-medals Medal record none*
{{Infobox sportsperson}} expanded Y show-medals Medal record medaltemplates-title
{{Infobox squash player}} expanded Y show-medals Medal record none
{{Infobox swimmer}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox synchronized skating team}} collapsed N show-medals Medal record none
{{Infobox table tennis player}} collapsed N show-medals Medal record none
{{Infobox tennis biography}} collapsed N medaltemplates-expand Medal record medaltemplates-title
{{Infobox volleyball biography}} expanded N medaltemplates-expand Honours medaltemplates-title

Tracking category

See also

As implemented in {{Infobox sportsperson}}.

{{Infobox sportsperson
| name             = Kaori Icho
| birth_date       = {{Birth-date and age|13 June 1984}}
| birth_place      = [[Hachinohe, Aomori]], Japan
| height           = 166 cm (2016)
| medaltemplates   = 
{{MedalSport | Women's [[freestyle wrestling]] }}
{{MedalCountry | {{JPN}} }}
{{MedalCount | total = yes
| [[Summer Olympic Games|Olympic Games]] | 4 | – | – 
| [[World Wrestling Championships|World Championships]] | 10 | – | – 
| [[Asian Games]] | 1 | 1 | – 
}}
{{MedalCompetition | [[Wrestling at the Summer Olympics|Olympic Games]] }}
{{MedalGold | [[2004 Summer Olympics|2004 Athens]] | [[Wrestling at the 2004 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2008 Summer Olympics|2008 Beijing]] | [[Wrestling at the 2008 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2012 Summer Olympics|2012 London]] | [[Wrestling at the 2012 Summer Olympics – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2016 Summer Olympics|2016 Rio de Janeiro]] | [[Wrestling at the 2016 Summer Olympics – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[World Wrestling Championships|World Championships]] }}
{{MedalGold | [[2002 World Wrestling Championships|2002 Chalkida]] | 63&nbsp;kg }}
{{MedalGold | [[2003 World Wrestling Championships|2003 New York]] | 63&nbsp;kg }}
{{MedalGold | [[2005 World Wrestling Championships|2005 Budapest]] | 63&nbsp;kg }}
{{MedalGold | [[2006 World Wrestling Championships|2006 Guangzhou]] | 63&nbsp;kg }}
{{MedalGold | [[2007 World Wrestling Championships|2007 Baku]] | 63&nbsp;kg }}
{{MedalGold | [[2010 World Wrestling Championships|2010 Moscow]] | [[2010 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2011 World Wrestling Championships|2011 Istanbul]] | [[2011 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2013 World Wrestling Championships|2013 Budapest]] | [[2013 World Wrestling Championships – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[2014 World Wrestling Championships|2014 Tashkent]] | [[2014 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalGold | [[2015 World Wrestling Championships|2015 Las Vegas]] | [[2015 World Wrestling Championships – Women's freestyle 58 kg|58&nbsp;kg]] }}
{{MedalCompetition | [[Asian Games]] }}
{{MedalSilver | [[Wrestling at the 2002 Asian Games|2002 Busan]] | [[Wrestling at the 2002 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
{{MedalGold | [[Wrestling at the 2006 Asian Games|2006 Doha]] | [[Wrestling at the 2006 Asian Games – Women's freestyle 63 kg|63&nbsp;kg]] }}
| show-medals      = yes
}}

Templates using this template

List of templates which implement {{Infobox medal templates}}
Template name Default Accept 'no'? Show param Title Title param
{{Infobox alpine ski racer}} collapsed N show-medals Medal record none
{{Infobox amateur wrestler}} expanded Y show-medals Medal record none
{{Infobox badminton player}} expanded Y show-medals Medal record none
{{Infobox bandy biography}} expanded N medaltemplates-expand Honours medaltemplates-title
{{Infobox basketball biography}} expanded Y show-medals
medaltemplates-expand
medal_templates-expand
Medals none
{{Infobox biathlete}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox boxer}} expanded Y show-medals Medal record none
{{Infobox boxer (amateur)}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox climber}} expanded Y show-medals Medal record none
{{Infobox college coach}} expanded Y show-medals Medal record none
{{Infobox curler}} expanded Y show-medals Medal record none
{{Infobox cyclist}} expanded Y show-medals Medal record none
{{Infobox darts player}} expanded Y show-medals Medal record none
{{Infobox equestrian}} collapsed N show-medals Medal record none
{{Infobox fencer}} collapsed N show-medals Medal record none
{{Infobox field hockey player}} expanded N medaltemplates-expand Medal record none
{{Infobox figure skater}} collapsed N show-medals Medal record none
{{Infobox football biography}} collapsed N medaltemplates-expand Honours medaltemplates-title
{{Infobox go player}} expanded Y show-medals Medal record none
{{Infobox gymnast}} collapsed N show-medals Medal record none
{{Infobox ice hockey player}} expanded Y show-medals Medal record none
{{Infobox lacrosse player}} collapsed N medaltemplates-expand
medal_templates-expand
Medal record none
{{Infobox martial artist}} expanded Y show-medals Medal record none
{{Infobox national basketball team}} expanded Y show-medals Medal record none
{{Infobox national football team}} collapsed N medaltemplates-expand Honours none
{{Infobox cricket team}} expanded N show-medals Medal record none
{{Infobox national volleyball team}} collapsed N medaltemplates-expand Honours medaltemplates-title
{{Infobox NCAA athlete}} collapsed N medaltemplates-expand
medal_templates-expand
Medal record none
{{Infobox netball biography}} expanded Y show-medals Medal record none
{{Infobox sailor}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record medaltemplates-title
{{Infobox skier}} expanded Y show-medals Medal record none
{{Infobox speed skater}}
  via Infobox sportsperson (* = different behavior)
expanded Y show-medals Medal record none*
{{Infobox sport wrestler}}
  via Infobox sportsperson (* = different behavior)
expanded Y show-medals Medal record none*
{{Infobox sportsperson}} expanded Y show-medals Medal record medaltemplates-title
{{Infobox squash player}} expanded Y show-medals Medal record none
{{Infobox swimmer}}
  via Infobox sportsperson (* = different behavior)
collapsed* N* show-medals Medal record none*
{{Infobox synchronized skating team}} collapsed N show-medals Medal record none
{{Infobox table tennis player}} collapsed N show-medals Medal record none
{{Infobox tennis biography}} collapsed N medaltemplates-expand Medal record medaltemplates-title
{{Infobox volleyball biography}} expanded N medaltemplates-expand Honours medaltemplates-title

Tracking category

See also