模板:Card

維基百科,自由的百科全書

[[File:Playing card {{{1}}} {{{2}}}.svg|75px|{{{2}}} of {{{1}}}s ]]

文件圖示 模板文件[檢視] [編輯] [歷史] [清除快取]

這是一個和撲克牌有關的模板。

簡介[編輯]

這個模板有兩個參數。

{{card|suit|value}}

花色可以是:

  • heart
  • diamond
  • spade
  • club

點數可以是:

  • A
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • J
  • Q
  • K

例子[編輯]

一共有52張牌。

Wikicode Card Wikicode Card Wikicode Card Wikicode Card
{{card|heart|A}} Ace of hearts {{card|diamond|A}} Ace of diamonds {{card|spade|A}} Ace of spades {{card|club|A}} Ace of clubs
{{card|heart|2}} 2 of hearts {{card|diamond|2}} 2 of diamonds {{card|spade|2}} 2 of spades {{card|club|2}} 2 of clubs
{{card|heart|3}} 3 of hearts {{card|diamond|3}} 3 of diamonds {{card|spade|3}} 3 of spades {{card|club|3}} 3 of clubs
{{card|heart|4}} 4 of hearts {{card|diamond|4}} 4 of diamonds {{card|spade|4}} 4 of spades {{card|club|4}} 4 of clubs
{{card|heart|5}} 5 of hearts {{card|diamond|5}} 5 of diamonds {{card|spade|5}} 5 of spades {{card|club|5}} 5 of clubs
{{card|heart|6}} 6 of hearts {{card|diamond|6}} 6 of diamonds {{card|spade|6}} 6 of spades {{card|club|6}} 6 of clubs
{{card|heart|7}} 7 of hearts {{card|diamond|7}} 7 of diamonds {{card|spade|7}} 7 of spades {{card|club|7}} 7 of clubs
{{card|heart|8}} 8 of hearts {{card|diamond|8}} 8 of diamonds {{card|spade|8}} 8 of spades {{card|club|8}} 8 of clubs
{{card|heart|9}} 9 of hearts {{card|diamond|9}} 9 of diamonds {{card|spade|9}} 9 of spades {{card|club|9}} 9 of clubs
{{card|heart|10}} 10 of hearts {{card|diamond|10}} 10 of diamonds {{card|spade|10}} 10 of spades {{card|club|10}} 10 of clubs
{{card|heart|J}} Jack of hearts {{card|diamond|J}} Jack of diamonds {{card|spade|J}} Jack of spades {{card|club|J}} Jack of clubs
{{card|heart|Q}} Queen of hearts {{card|diamond|Q}} Queen of diamonds {{card|spade|Q}} Queen of spades {{card|club|Q}} Queen of clubs
{{card|heart|K}} King of hearts {{card|diamond|K}} King of diamonds {{card|spade|K}} King of spades {{card|club|K}} King of clubs

模板參數[編輯]

以下是該模板的模板資料,適用於視覺化編輯器等工具。

Card模板資料

用於顯示1張撲克牌

模板參數[編輯模板資料]

此模板以參數行內格式為優先。

參數描述類型狀態
花色1

撲克牌的花色,只能接受"heart"、"diamond"、"spade"與"club"

預設
{{{1}}}
範例
heart
自動值
{{{1}}}
字串必填
點數2

撲克牌的點數,只能接受"A"、"K"、"Q"、"J",以及正整數2到10

預設
{{{2}}}
範例
A
自動值
{{{2}}}
字串必填
撲克牌的大小3

顯示撲克牌的大小,單位為px

預設
75px
範例
60px
自動值
75px
字串非必填