「Template:Infobox/row」修訂間的差異
跳至導覽
跳至搜尋
小 |
|||
行 1: | 行 1: | ||
<includeonly>|- | <includeonly>|- | ||
{{#if: {{{header|}}} | {{#if: {{{header|}}} | ||
− | |! colspan="2" class="{{{headerclass|theme | + | |! colspan="2" class="{{#if:{{{headerclass|}}}|{{{headerclass}}}|theme}}" style="text-align: center; {{{headerstyle|}}}" {{!}} {{{header}}} |
|{{#if: {{{2|}}} | |{{#if: {{{2|}}} | ||
− | |{{!}} class="{{{labelclass|theme-light | + | |{{!}} class="{{#if:{{{labelclass|}}}|{{{labelclass}}}|theme-light}}" style="text-align: left; padding-left:2px; padding-right:2px; {{{labelstyle|}}}" nowrap {{!}} {{#if: {{{1|}}} | '''{{{1|}}}'''}} |
{{!}} class="{{{dataclass|}}}" style="text-align: left; padding-left:1px; padding-right:1px; {{{datastyle|}}}" {{!}} {{{2}}} | {{!}} class="{{{dataclass|}}}" style="text-align: left; padding-left:1px; padding-right:1px; {{{datastyle|}}}" {{!}} {{{2}}} | ||
|{{#ifeq: {{{force|}}} | <!-- empty --> | <!-- then show nothing because {{{2}}} empty --> | |{{#ifeq: {{{force|}}} | <!-- empty --> | <!-- then show nothing because {{{2}}} empty --> | ||
|{{#if: {{{1|}}} <!-- else --> | |{{#if: {{{1|}}} <!-- else --> | ||
− | |{{!}} class="{{{labelclass|theme-light | + | |{{!}} class="{{#if:{{{labelclass|}}}|{{{labelclass}}}|theme-light}}" style="text-align: left; padding-left:2px; padding-right:2px; {{{labelstyle|}}}" nowrap {{!}} '''{{{1}}}''' |
{{!}} class="{{{dataclass|}}}" style="text-align: left; padding-left:1px; padding-right:1px; {{{datastyle|}}}" {{!}} {{{2|}}} | {{!}} class="{{{dataclass|}}}" style="text-align: left; padding-left:1px; padding-right:1px; {{{datastyle|}}}" {{!}} {{{2|}}} | ||
}} | }} |
於 2016年10月29日 (六) 01:03 的修訂
- 來源
- http://zh.moegirl.org/index.php?title=Template:Infobox/row
- 用處
- 配合其他infobox系列模板使用,拓展其他infobox系列模板
- 語法
- 用法一:
{{infobox/row|header=小标题|headerclass=小标题类|headerstyle=小标题样式}}
- 用法二:
{{infobox/row|标签|数据|labelclass=标签类|labelstyle=标签样式|dataclass=数据类|datastyle=数据样式|force=即使数据为空,依然显示}}
- 範例
{{infobox/话| |name=魔法少女小圆 |episode=3 |image=Episode3.jpg |title=已经没什么好怕的了 |japtitle=もう何も怖くない |脚本=虚渊玄 |previous = [[魔法少女小圆 第2话「それはとっても嬉しいなって」|第2话 「那真是太令人高兴了」]] |next = [[魔法少女小圆 第4话「奇跡も、魔法も、あるんだよ」|第4话 「奇迹和魔法都是存在的」]] |other={{infobox/row|header=额外章节}} {{infobox/row|额外职位1|魔法少女贞德}} {{infobox/row|2=魔法少女杨贵妃|labelstyle=background-color:transparent !important;}} {{infobox/row|2=魔法少女奥巴马|labelstyle=background-color:transparent !important;|dataclass=theme-light|force=true}} {{infobox/row|额外职位2|force=NoMatterWhatHere}} {{infobox/row|额外职位3}} }}
- 將產生如下效果
魔法少女小圓 | |||
---|---|---|---|
第3話 | |||
250px ' | |||
標題 | 已經沒什麼好怕的了 | ||
日文標題 | もう何も怖くない | ||
腳本 | 虛淵玄 | ||
跳轉 | |||
| |||
額外章節 | |||
額外職位1 | 魔法少女貞德 | ||
魔法少女楊貴妃 | |||
魔法少女奧巴馬 | |||
額外職位2 |