Difference between revisions of "Template:CBB game log section entry"

From blackwiki
Jump to navigation Jump to search
imported>McVahl
m
imported>McVahl
Line 1: Line 1:
 
<noinclude>{{Game log start|title=}}
 
<noinclude>{{Game log start|title=}}
 
{{CBB game log section header|format=compact|first=yes}}
 
{{CBB game log section header|format=compact|first=yes}}
</noinclude>|-{{#switch: {{lc:{{{status|}}}}}
+
</noinclude>|-{{#switch: {{lc:{{{status|{{check winner by scores|sc={{{score}}}}} }}}}}
 
   | c | cancelled
 
   | c | cancelled
 
   | p | postponed = style="background:#cccccc;"
 
   | p | postponed = style="background:#cccccc;"
 
   | w | win  = style="background:#ddffdd;"
 
   | w | win  = style="background:#ddffdd;"
 
   | l | loss = style="background:#ffdddd;"
 
   | l | loss = style="background:#ffdddd;"
  | #default = {{#iferror:{{#ifexpr:{{str number/trim|{{{score|}}}}} > {{str right|{{{score|}}}|{{strfind short|{{{score}}}|{{#ifexpr:{{str find|{{{score|}}}|-}}>0|-|–}}}}}} | style="background:#ddffdd;" | style="background:#ffdddd;" }} | <!-- default: no background --> }}
 
 
}}
 
}}
 
| {{{game|1}}}
 
| {{{game|1}}}
Line 12: Line 11:
 
{{#ifeq:{{{rank|}}}|no||{{!}} {{nowrap|{{#if:{{{seed|}}}|(#{{{seed}}}) }} }} }} {{#ifeq:{{{rank|}}}|no||{{#if:{{{rank|}}}|{{nowrap|&#8470; {{{rank}}} }} }} }}
 
{{#ifeq:{{{rank|}}}|no||{{!}} {{nowrap|{{#if:{{{seed|}}}|(#{{{seed}}}) }} }} }} {{#ifeq:{{{rank|}}}|no||{{#if:{{{rank|}}}|{{nowrap|&#8470; {{{rank}}} }} }} }}
 
| align="left"|{{#if:{{{away|}}}|at&nbsp;}}{{#if:{{{neutral|}}}|vs.&nbsp;}}{{#if:{{{oppseed|}}}|(#{{{oppseed}}})&nbsp;}}{{#if:{{{opprank|}}}|&#8470; {{{opprank}}}&nbsp;}}{{nowrap|{{{opponent}}}}} {{#if:{{{gamename|}}}|<br/>{{nowrap|<small>''{{{gamename}}}''</small>}}}}
 
| align="left"|{{#if:{{{away|}}}|at&nbsp;}}{{#if:{{{neutral|}}}|vs.&nbsp;}}{{#if:{{{oppseed|}}}|(#{{{oppseed}}})&nbsp;}}{{#if:{{{opprank|}}}|&#8470; {{{opprank}}}&nbsp;}}{{nowrap|{{{opponent}}}}} {{#if:{{{gamename|}}}|<br/>{{nowrap|<small>''{{{gamename}}}''</small>}}}}
{{#switch: {{lc:{{{score|{{{status|tbd}}}}}}}}
+
{{#switch: {{lc:{{{status|{{check winner by scores|sc={{{score}}}}} }}}}}
 
   | c | cancelled = {{!}} colspan="5" {{!}} ''{{{status_detail|Cancelled}}}''
 
   | c | cancelled = {{!}} colspan="5" {{!}} ''{{{status_detail|Cancelled}}}''
 
   | p | postponed = {{!}} colspan="5" {{!}} ''{{{status_detail|Postponed}}}''
 
   | p | postponed = {{!}} colspan="5" {{!}} ''{{{status_detail|Postponed}}}''
   | tbd = {{!}} colspan="5" {{!}} {{TBD}}
+
   | w | win
   | #default = {{!}} align="left" {{!}} {{#switch: {{lc:{{{status|}}}}}
+
   | l | loss = {{!}} align="left" {{!}} <span style="display:inline-block; width:1em">'''{{uc:{{str index|{{{status|{{check winner by scores|sc={{{score}}}}}}}}|1}}}}'''</span> {{ifnotempty|{{{score|}}}|{{ifnotempty|{{{boxscore|}}}|[{{{boxscore}}} {{replace|{{{score}}}|-|–}}]|{{replace|{{{score}}}|-|–}}}}{{ifnotempty|{{{overtime|}}}|<sup>{{{overtime}}}</sup>}}}}
      | w | win  = '''W''' {{!!}} {{replace|{{{record|}}}|-|–}}
+
{{!}} {{replace|{{{record|}}}|-|–}}
      | l | loss = '''L''' {{!!}} {{replace|{{{record|}}}|-|–}}
 
      | #default = {{#iferror:{{#ifexpr:{{str number/trim|{{{score}}}}} > {{str right|{{{score}}}|{{strfind short|{{{score}}}|{{#ifexpr:{{str find|{{{score}}}|-}}>0|-|–}}}}}}
 
| <span style="display:inline-block; width:1em">'''W'''</span>
 
| <span style="display:inline-block; width:1em">'''L'''</span>}} {{ifnotempty|{{{boxscore|}}}|[{{{boxscore}}} {{replace|{{{score}}}|-|–}}]|{{replace|{{{score}}}|-|–}}}}{{ifnotempty|{{{overtime|}}}|<sup>{{{overtime}}}</sup>}}
 
| {{spaces}}<!-- parse error --> }}
 
{{!}} {{replace|{{{record|}}}|-|–}} }}
 
 
{{!}} {{{highscorer|}}} {{ifnotempty|{{{points|}}}|({{{points}}})}}
 
{{!}} {{{highscorer|}}} {{ifnotempty|{{{points|}}}|({{{points}}})}}
 
{{!}} {{{highrebounder|}}} {{ifnotempty|{{{rebounds|}}}|({{{rebounds}}})}}
 
{{!}} {{{highrebounder|}}} {{ifnotempty|{{{rebounds|}}}|({{{rebounds}}})}}
{{!}} {{{highassister|}}} {{ifnotempty|{{{assists|}}}|({{{assists}}})}} }}
+
{{!}} {{{highassister|}}} {{ifnotempty|{{{assists|}}}|({{{assists}}})}}
 +
  | tbd
 +
  | #default =  {{!}} colspan="5" {{!}} {{TBD}}
 +
}}
 
| {{{site_stadium}}}<noinclude>
 
| {{{site_stadium}}}<noinclude>
 
{{end}}
 
{{end}}

Revision as of 09:27, 4 June 2020

{{{2}}}
Game Date • Time Rank Opponent Result Record High points High rebounds High assists Location
1 {{{date}}} {{{opponent}}} Template:TBD {{{site_stadium}}}
50px Template documentation[view] [edit] [history] [purge]


Usage

Table format

Default

For default format, the game log templates Template:Tltt and Template:Tltt are backward compatible to schedule templates Template:Tltt and Template:Tltt, respectively—i.e. the parameters of Template:Tltt are reused in Template:Tltt. Meanwhile, template Template:Tltt is recommended to be used for entries in game log sections.

Default format syntax
Exhibitions and regular season
{{CBB game log start         |TEAM_NAME|season=|year=|end_year=|tournament=|record=}}
{{CBB game log section header|TEAM_NAME|Exhibition|first=yes|team_wins=|team_losses=}}
{{CBB schedule entry}}
...
{{CBB game log section header|TEAM_NAME|Non-conference regular season|team_wins=|team_losses=}}
{{CBB schedule entry}}
...
{{CBB game log section header|TEAM_NAME|ACC regular season|team_wins=|team_losses=}}
{{CBB schedule entry}}
...
{{CBB game log end}}
Playoffs
{{CBB game log start         |TEAM_NAME|playoff=yes|season=|year=|end_year=|tournament=|record=}}
{{CBB game log section header|TEAM_NAME|ACC Tournament|playoff=yes|first=yes|team_wins=|team_losses=}}
{{CBB schedule entry}}
...
{{CBB game log section header|TEAM_NAME|NCAA Tournament|playoff=yes|team_wins=|team_losses=}}
{{CBB schedule entry}}
...
{{CBB game log end}}

Compact

For compact format, template Template:Tltt is recommended to be used for entries in game log sections.

Compact format syntax
Exhibitions and regular season
{{CBB game log start         |TEAM_NAME|season=|year=|end_year=|tournament=|record=}}
{{CBB game log section header|TEAM_NAME|Exhibition|format=compact|first=yes|team_wins=|team_losses=}}
{{CBB game log section entry}}
...
{{CBB game log section header|TEAM_NAME|Non-conference regular season|format=compact|team_wins=|team_losses=}}
{{CBB game log section entry}}
...
{{CBB game log section header|TEAM_NAME|ACC regular season|format=compact|team_wins=|team_losses=}}
{{CBB game log section entry}}
...
{{CBB game log end}}
Playoffs
{{CBB game log start         |TEAM_NAME|playoff=yes|season=|year=|end_year=|tournament=|record=}}
{{CBB game log section header|TEAM_NAME|ACC Tournament|format=compact|playoff=yes|first=yes|team_wins=|team_losses=}}
{{CBB game log section entry}}
...
{{CBB game log section header|TEAM_NAME|NCAA Tournament|format=compact|playoff=yes|team_wins=|team_losses=}}
{{CBB game log section entry}}
...
{{CBB game log end}}

Colors

By default, the table utilizes Template:Tltt and Template:Tltt templates for team colors. Team's name and colors must be listed in Module:College color for colors to take effect, e.g. for Harvard Crimson appearing on the teams list:

{{CBB game log start         |Harvard Crimson|..}} <!-- primary color is applied -->
{{CBB game log section header|Harvard Crimson|..}} <!-- secondary color is applied -->

If team does not appear in Module:College color list, custom colors can be supplied as follows:

{{CBB game log start |color=#000000|..}}
{{CBB game log start |color=black  |..}}

Examples

Default format

For default format, the game log templates Template:Tltt and Template:Tltt are backward compatible to schedule templates Template:Tltt and Template:Tltt, respectively—i.e. the parameters of Template:Tltt are reused in Template:Tltt. Meanwhile, template Template:Tltt is recommended to be used for entries in game log sections.

Default column display

Template:Nowiki template demo

Game high columns shown, rank column hidden

Template:Nowiki template demo

Compact format

For compact format, template Template:Tltt is recommended to be used for entries in game log sections.

Full, rank column shown

Template:Nowiki template demo

Rank column hidden

Simply set |rank=no in all instances of Template:Tltt and Template:Tltt.

Template:Nowiki template demo

Custom team colors

Template:Nowiki template demo

See also