background-color: transparent; color: var( --color-base ); border-collapse:collapse; border-spacing:0px; border:none; width:100%; margin:0px; font-size:100%; clear:none; float:none
此Template被引用於約34,000個頁面 。為了避免造成大規模的影響,所有對此Template的編輯應先於沙盒 、測試樣例 或您的沙盒 上測試。 測試後無誤的版本可以一次性地加入此Template中,但是修改前請務必於討論頁 發起討論。
模板引用數量會自動更新。
此模板提供恰当的CSS样式 ,用于将{{Infobox }}或{{Sidebar }}嵌入到另一个模板(通常是另一个信息框或侧边栏)中。
用法
与Infobox一起使用
{{Infobox/Sidebar/etc <!--(即父模板)-->
........
| dataN/contentN/etc =
{{Infobox
| bodystyle = {{subinfobox bodystyle}}
........
}}
........
}}
(Technical note: Using {{subinfobox bodystyle }} rather than Infobox's child parameter to embed an {{Infobox }} means that the outermost table used to contain the (otherwise typical stand-alone) Infobox is retained.)
当使用{{subinfobox bodystyle}} (或其重定向{{subsidebar bodystyle }})来嵌入{{Sidebar }}时,被嵌入的Sidebar的“navbar”参数需要设置为“off”(|navbar=off):
{{Sidebar/Infobox/etc <!--(即父模板)-->
........
| contentN/dataN/etc =
{{Sidebar |navbar=off
| style = {{subsidebar bodystyle}}
........
}}
........
}}
示例
Infobox内嵌于Infobox
{{ Infobox
| label1 = label1
| data1 = data1
| data2 =
{{ Infobox
| bodystyle = {{ subinfobox bodystyle }}
| label1 = label1a
| data1 = data1a
| data2 = ……
}}
| label3 = label3
| data3 = data3
| data4 = ……
}}
{{ Sidebar
| heading1 = heading1
| content1 = content1
| heading2 = heading2
| content2 =
{{ Infobox
| bodystyle = {{ subinfobox bodystyle }}
| label1 = label2a
| data1 = data2a
| label2 = label2b
| data2 = data2b
| data3 = ……
}}
| heading3 = heading3
| content3 = content3
| content4 = ……
}}
Infobox3cols内嵌于Infobox
label1 data1 label1
data1a
data1b
data1c label2
data2a
data2c
……
label3 data3 ……
{{ Infobox
| label1 = label1
| data1 = data1
| data2 =
{{ Infobox3cols
| bodystyle = {{ subinfobox bodystyle }}
| label1 = label1a
| data1a = data1aa
| data1b = data1ab
| data1c = data1ac
| label2 = label2a
| data2a = data2aa
| data2c = data2ac
| data3 = ……
}}
| label3 = label3
| data3 = data3
| data4 = ……
}}
{{ Sidebar
| heading1 = heading1
| content1 = content1
| heading2 = heading2
| content2 =
{{ Sidebar | navbar = off
| style = {{ subsidebar bodystyle }}
| heading1 = heading2a
| content1 = content2a
| heading2 = heading2b
| content2 = content2b
| content3 = ……
}}
| heading3 = heading3
| content3 = content3
| content4 = ……
}}
可折叠Infobox内嵌于Infobox
label1 data1 Collapsed information label1a data1a ……
label3 data3 ……
{{ Infobox
| label1 = label1
| data1 = data1
| data2 =
{{ Infobox
| bodyclass = mw-collapsible mw-collapsed
| abovestyle = font-size:88%; padding-left:2em;
| above = {{ resize | 114%| Collapsed information}}
| bodystyle = {{ subinfobox bodystyle }}
| label1 = label1a
| data1 = data1a
| data2 = ……
}}
| label3 = label3
| data3 = data3
| data4 = ……
}}