这是Template:Badge的一个文档子页面。它包含了使用信息、分类和其他不属于 原始 template 页面.的内容
Template:Badge invokes
This template is used to style text as a badge.
Usage
{{Badge|Lando's favourite ship}}
gives Lando's favourite ship
{{Badge|Lando's favourite ship|inverted=true}}
gives Lando's favourite ship
{{Badge|Lando's favourite ship|bg=#d0817d}}
gives Lando's favourite ship
{{Badge|Lando's favourite ship|bg=#d0817d|inverted=true}}
gives Lando's favourite ship
TemplateData
Style text as a badge
参数 | 描述 | 类型 | 状态 | |
---|---|---|---|---|
Text | 1 | Text in the badge | 字符串 | 必需 |
Background color | bg | Background color of the badge (HEX/RGB(A)/HSL(A)) | 字符串 | 可选 |
Invert color | inverted | Dark text and light background color
| 布尔 | 可选 |
HTML class | class | Additional HTML class | 字符串 | 可选 |
See also
- {{Transit}} - used for transit lines