Template:Chart
外观
| 本模板使用以下模板样式: |
注:{{Chart}}曾是系谱图模板,已于2019年同英维移动至{{Tree chart}}。之后英维将{{Chart}}提删,但其在中维被保留,故此后很长一段时间其为{{Tree chart}}的重定向。2025年,英维将{{Chart}}重建为图表模板,如今中维也已同步。故若您想要绘制系谱图,请使用{{Tree chart}},不要再误用本模板。
Copy templates
Standard
{{Chart|chart=.chart}}
Full
{{Chart
| chart =
| data =
| thumb =
| align =
| width =
| border =
| style =
| caption =
| source =
}}
or
{{Chart|thumb|align|width|caption|chart=.chart|data=.tab|border=|style=|source=.tab}}
Examples
full width
{{Chart
| chart = Autobahn network length.Line.chart
}}
查看图表定义。
other data source and border
{{Chart
| chart = Monthly stream discharges.chart
| data = GRDC-1530100 monthly discharge.tab
| border = 1
}}
查看源数据。
thumbnail, caption, and source
{{Chart
| thumb
| caption = Autobahn network length.
| source = Autobahn network length.tab
| chart = Autobahn network length.Line.chart
}}
Autobahn network length. 查看源数据。
aligned and fixed width
{{Chart
| chart = Autobahn network length.Line.chart
| align = right
| width = 400px
}}
查看图表定义。
aligned and fixed width thumbnail
{{Chart
| thumb
| chart = Autobahn network length.Line.chart
| align = left
| width = 400px
}}
查看图表定义。
centered, fixed width, border, caption and source
{{Chart
| chart = Autobahn network length.Line.chart
| align = center
| width = 400px
| caption = Autobahn network length.
| source = Autobahn network length.tab
}}
Autobahn network length. 查看源数据。
TemplateData
Includes a chart ([[Help:Charts]]) with source attribution and allows adjusting alignment, width, and border.
| 参数 | 描述 | 类型 | 状态 | |
|---|---|---|---|---|
| Display as thumbnail | thumb 1 | Set to any value to display in a gray box like an image thumbnail
| 单行文本 | 可选 |
| Alignment | align 2 | Chart alignment, either "left", "right", or "center"
| 单行文本 | 可选 |
| Width | width 3 | Width in pixels or percent
| 单行文本 | 可选 |
| Caption | caption 4 | Caption to display before the source information. Make sure to use ending punctuation.
| 字符串 | 可选 |
| Chart definition | chart definition | Chart on Wikimedia Commons, without the "Data:" prefix
| 单行文本 | 必需 |
| Chart data | data | .tab on Wikimedia Commons, without the "Data:" prefix (overrides the specification in the chart definition)
| 单行文本 | 推荐 |
| Source attribution | source | Source .tab file to be linked at the bottom, without the "Data:" prefix. If not specified, it will fallback to displaying the value of "data" or "chart".
| 单行文本 | 推荐 |
| Border | border | Set to "1" to enable a border
| 布尔 | 可选 |
| CSS styles | style | Additional CSS styles (beyond width and border)
| 单行文本 | 可选 |
| Hide source | hideSource | Set to any value to disable linking to the source
| 布尔 | 可选 |