Difference between revisions of "Template:Infobox season"

From Golly.Life Wiki

Line 24: Line 24:
 
  | header5 = Pennants
 
  | header5 = Pennants
 
  |  data6 = {{Infobox | subbox = yes
 
  |  data6 = {{Infobox | subbox = yes
     | label1 = Cold League | data1 = {{Main Page Thumbnail|{{{cold_league_winner_abbr|GollyLogoTransparent}}}.png|{{TeamAbbrToName|{{{cold_league_winner_abbr}}}}} logo|{{TeamAbbrToName|{{{cold_league_winner_abbr}}}}}|size=60}}{{clear}}[[{{TeamAbbrToName|{{{cold_league_winner_abbr|}}}}}]]
+
     | label1 = Cold League | data1 = {#if:{{{cold_league_winner_abbr|}}}|{{Main Page Thumbnail|{{{cold_league_winner_abbr|GollyLogoTransparent}}}.png|{{TeamAbbrToName|{{{cold_league_winner_abbr}}}}} logo|{{TeamAbbrToName|{{{cold_league_winner_abbr}}}}}|size=60}}{{clear}}[[{{TeamAbbrToName|{{{cold_league_winner_abbr|}}}}}]]|}}
 
     | label2 = Hot League  | data2 = {{Main Page Thumbnail|{{{hot_league_winner_abbr|GollyLogoTransparent}}}.png|{{TeamAbbrToName|{{{hot_league_winner_abbr}}}}} logo|{{TeamAbbrToName|{{{hot_league_winner_abbr}}}}}|size=60}}{{clear}}[[{{TeamAbbrToName|{{{hot_league_winner_abbr|}}}}}]]
 
     | label2 = Hot League  | data2 = {{Main Page Thumbnail|{{{hot_league_winner_abbr|GollyLogoTransparent}}}.png|{{TeamAbbrToName|{{{hot_league_winner_abbr}}}}} logo|{{TeamAbbrToName|{{{hot_league_winner_abbr}}}}}|size=60}}{{clear}}[[{{TeamAbbrToName|{{{hot_league_winner_abbr|}}}}}]]
 
   }}
 
   }}

Revision as of 23:51, 6 February 2021

The {{Infobox season}} template is used to define an infobox for a Golly season.

Here is how you use it:


{{Infobox season
| season = 1
| era = Indifference
| start_date = January 1, 2020
| end_date = January 1, 2021

| champion_abbr = LBFB

| hot_league_winner_abbr = SFBS
| cold_league_winner_abbr = LBFB

| hot_league_seed1_abbr = SFBS
| hot_league_seed2_abbr = DET
| hot_league_seed3_abbr = DECO
| hot_league_seed4_abbr = SAC

| cold_league_seed1_abbr = LBFB
| cold_league_seed2_abbr = SDBA
| cold_league_seed3_abbr = TB
| cold_league_seed4_abbr = SS

| arcana = Knight of Cups
| title = Lord of Waves and Waters
}}

The {{Infobox season}} template will pass these arguments to the {{Infobox}} template, inserting the right bits of information in the right places to produce this:

Golly Season 1
Golly logo
Season 1
Season Dates
Hot League

San Francisco Boat Shoes logo

San Francisco Boat Shoes
Championship
Golly Champion

Long Beach Flightless Birds logo

Long Beach Flightless Birds
Pennants
Cold League {#if:LBFB
| header7 = Cold League Seeds

| data8 =

Seed 1

Long Beach Flightless Birds logo

Long Beach Flightless Birds
Seed 2

San Diego Balloon Animals logo

San Diego Balloon Animals
Seed 3

Tucson Butchers logo

Tucson Butchers
Seed 4

Seattle Sneakers logo

Seattle Sneakers
| header9 = Hot League Seeds

| data10 =

Seed 1

San Francisco Boat Shoes logo

San Francisco Boat Shoes
Seed 2

Detroit Grape Chews logo

Detroit Grape Chews
Seed 3

Delaware Corporate Shells logo

Delaware Corporate Shells
Seed 4

Sacramento Boot Lickers logo

Sacramento Boot Lickers
| header11 = Timeline

| data12 =

Next Season ▶▶ Season 2
| header13 = Divination

| data14 =

Arcana Knight of Cups
Title Lord of Waves and Waters
|belowstyle = background:#122; color: #eee;

|below =

 
Template:Infobox season   •   edit
 

}}


Now if we leave out some team abbreviations, it should be gracefully handled:


Golly Season 1
Golly logo
Season 1
Season Dates
Hot League

logo

[[]]
Championship
Golly Champion

logo

[[]]
Pennants
Cold League {#if:
| header7 = Cold League Seeds

| data8 =

Seed 1

Long Beach Flightless Birds logo

Long Beach Flightless Birds
Seed 2

San Diego Balloon Animals logo

San Diego Balloon Animals
Seed 3

Tucson Butchers logo

Tucson Butchers
Seed 4

Seattle Sneakers logo

Seattle Sneakers
| header9 = Hot League Seeds

| data10 =

Seed 1

San Francisco Boat Shoes logo

San Francisco Boat Shoes
Seed 2

Detroit Grape Chews logo

Detroit Grape Chews
Seed 3

Delaware Corporate Shells logo

Delaware Corporate Shells
Seed 4

Sacramento Boot Lickers logo

Sacramento Boot Lickers
| header11 = Timeline

| data12 =

Next Season ▶▶ Season 2
| header13 = Divination

| data14 =

Arcana Knight of Cups
Title Lord of Waves and Waters
|belowstyle = background:#122; color: #eee;

|below =

 
Template:Infobox season   •   edit
 

}}