模板:Team roster navbox
此模板使用Lua语言: |
This template is a helper template for implementing the roster navboxes for baseball teams, such as {{Toronto Blue Jays roster navbox}}, as well as award navboxes, such as {{NLCS MVP}}. At present, it parses any list<number> arguments to the template and replaces spaces in each list item with in order to prevent wrapping.
Potential future tasks that this navbox could perform include setting the colours for a given team based on a configuration page.
Roster example
{{Team roster navbox |name=Toronto Blue Jays roster |title=[[多倫多藍鳥|{{color|#FFFFFF|Toronto Blue Jays}}]] current roster |listclass = hlist |state = {{{state|autocollapse}}} |titlestyle=background:#003DA5; color:#FFFFFF; |groupstyle=background:#041E42; color:#FFFFFF; |group1=Active roster |list1= * 3 [[梅西爾·伊茲圖里斯]] * 4 [[Kyle Drabek]] * 6 [[A. J. Jiménez]] * 7 [[何塞·雷耶斯 (棒球运动员)|何塞·雷耶斯]] * 8 [[Anthony Gose]] * 9 [[J. P. Arencibia]] * 10 [[埃德溫·恩卡納西翁]] * 13 [[Brett Lawrie]] * 14 [[Moisés Sierra]] * 17 [[Ryan Goins]] * 19 [[荷西·包提斯塔]] * 21 [[Sergio Santos]] * 22 [[Kevin Pillar]] * 23 [[Brandon Morrow]] * 24 [[Ricky Romero]] * 26 [[亞當·林德]] * 27 [[布雷特·塞西尔]] * 28 [[Colby Rasmus]] * 29 [[Dustin McGowan]] * 30 [[Josh Thole]] * 32 [[Esmil Rogers]] * 33 [[Jeremy Jeffress]] * 35 [[Sean Nolin]] * 36 [[Drew Hutchison]] * 37 [[Mickey Storey]] * 43 [[R·A·迪奇]] * 44 [[Casey Janssen]] * 45 [[Neil Wagner (baseball)|Neil Wagner]] * 47 [[Luis Pérez (baseball)|Luis Pérez]] * 48 [[J·A·哈普]] * 49 [[Brad Lincoln]] * 50 [[Steve Delabar]] * 51 [[Thad Weber]] * 53 [[梅基·卡布瑞拉]] * 56 [[马克·伯尔利]] * 57 [[Juan Pérez (pitcher)|Juan Pérez]] * 58 [[Todd Redmond]] * 62 [[Aaron Loup]] * 64 [[Chad Jenkins]] * — [[Deck McGuire]] * — [[Kenny Wilson (baseball)|Kenny Wilson]] |group2=Inactive roster |list2= |group3=Disabled list |list3= |group4=Paternity list |list4= |group5=Coaching staff |list5= * Manager 5 [[John Gibbons]] * Bench 20 [[德马罗·黑尔]] * First base — * Third Base 2 [[Luis Rivera (infielder)|Luis Rivera]] * Hitting — [[Kevin Seitzer]] * Pitching 40 [[Pete Walker]] * Bullpen 41 [[Pat Hentgen]] * Bullpen catcher 61 [[Alex Andreopoulos]] }}
Resulting output:
Award example
{{Team roster navbox |name = NLCS MVP |title = [[League Championship Series Most Valuable Player Award|National League Championship Series MVP Award]] |state = {{{state|autocollapse}}} |listclass = hlist |list1 = * 1977: [[Dusty Baker|Baker]] * 1978: [[Steve Garvey|Garvey]] * 1979: [[Willie Stargell|Stargell]] * 1980: [[Manny Trillo|Trillo]] * 1981: [[Burt Hooton|Hooton]] * 1982: [[Darrell Porter|Porter]] * 1983: [[Gary Matthews|Matthews]] * 1984: [[Steve Garvey|Garvey]] * 1985: [[Ozzie Smith|Smith]] * 1986: [[Mike Scott (baseball)|Scott]] * 1987: [[Jeffrey Leonard|Leonard]] * 1988: [[Orel Hershiser|Hershiser]] * 1989: [[Will Clark|Clark]] * 1990: [[Rob Dibble|Dibble]], [[Randy Myers|Myers]] * 1991: [[Steve Avery|Avery]] * 1992: [[約翰·史摩茲|Smoltz]] * 1993: [[柯特·席林]] * 1994: ''Not played'' * 1995: [[Mike Devereaux|Devereaux]] * 1996: [[Javy López|López]] * 1997: [[Liván Hernández|Hernández]] * 1998: [[Sterling Hitchcock|Hitchcock]] * 1999: [[Eddie Pérez (baseball)|Pérez]] * 2000: [[Mike Hampton|Hampton]] * 2001: [[Craig Counsell|Counsell]] * 2002: [[Benito Santiago|Santiago]] * 2003: [[伊凡·羅德里奎茲]] * 2004: [[亞伯特·普荷斯]] * 2005: [[洛伊·奧斯華]] * 2006: [[傑夫·蘇潘]] * 2007: [[麥特·哈勒戴]] * 2008: [[科爾·漢梅爾斯]] * 2009: [[萊恩·霍華德]] * 2010: [[科迪·羅斯]] * 2011: [[大衛·佛里斯]] * 2012: [[马可·斯库塔罗]] * 2013: [[Michael Wacha|Wacha]] }}
Resulting output: