コンテンツにスキップ

「Template:Navbox with collapsible groups/doc」の版間の差分

削除された内容 追加された内容
Template:翻訳中途内:|subpage=yes|name=Template:Navbox with collapsible groups/docを追加
外部リンクの修正 en.wikipedia.org
 
(15人の利用者による、間の23版が非表示)
1行目: 1行目:
<noinclude>{{Documentation subpage|種類=[[H:T|テンプレート]]}}</noinclude>
{{翻訳中途|1=[http://en.wikipedia.org/w/index.php?title=Template:Navbox_with_collapsible_groups/doc&oldid=225723430 英語版 "Template:Navbox with collapsible groups/doc" 02:25, 15 July 2008 (UTC)]|date=2008年8月|subpage=yes|name=Template:Navbox with collapsible groups/doc}}
<includeonly>{{pp-template}}{{使用箇所の多いテンプレート|10,000以上}}{{翻訳直後|1=[https://en.wikipedia.org/w/index.php?title=Template:Navbox_with_collapsible_groups/doc&oldid=225723430 英語版 "Template:Navbox with collapsible groups/doc" 02:25, 15 July 2008 (UTC)]|date=2010年4月|subpage=yes|name=Template:Navbox with collapsible groups/doc}}</includeonly>
{{Documentation subpage}}
{{Lua|Module:Navbox/former}}
<includeonly>{{複雑なテンプレート}}</includeonly>
{{Navbox suite}}
{{Navbox suite}}
このテンプレートは特定の記事に関連のある記事のグループがあるナビゲーションテンプレートをつくります。全てのグループはデフォルトで隠されています。しかしながらパラメータを呼び出すことによって、同じグループで他の記事のある個々のグループを表示させることができます。
This template produces a navigational template that has groups of relevant articles on a certain topic. All groups are hidden by default. However, with a parameter call, an individual group can be shown that has the other articles in the same group.


== 使用法 ==
== 使用法 ==
空白のままにされるパラメータは削除してください。このテンプレートは現在10グループ/リストまで対応していますが、必要ならばより加えられます。このテンプレートでは最低2組のグループ/リストを使うべきです。そうでない場合は、代わりに {{tl|Navbox}} を使ってください。
Please remove the parameters that are left blank. The template currently supports up to 10 groups/lists but more can be added if needed. You should use a minimum of two groups/lists; otherwise, use {{tl|Navbox}} instead.


<pre>{{Navbox with collapsible groups
<pre>{{Navbox with collapsible groups
|name = {{subst:PAGENAME}}
| name = {{subst:PAGENAME}}
|state =
| state =
|selected = {{{1|}}}
| selected = {{{1|}}}
| title =
| titlestyle =
| groupstyle =
| image =


|title =
| group1 =
|titlestyle =
| abbr1 =
|groupstyle =
| list1 =
|image =


|group1 =
| group2 =
|abbr1 =
| abbr2 =
|list1 =
| list2 =

|group2 =
|abbr2 =
|list2 =


...
...


|group10 =
|group10 =
|abbr10 =
| abbr10 =
|list10 =
| list10 =
}}</pre>
}}</pre>


== パラメータ ==
== パラメータ ==
このテンプレートは姉妹テンプレートである {{tl|Navbox}} や {{tl|Navbox with columns}} と多くのパラメータを共有します。その共通のパラメータは短剣符<sup>'''†'''</sup>でマークされています。より多くの詳細な説明やそれらのパラメータの例がある {{tl|Navbox}} の解説も参照してください。
This template shares many common parameters with its sister templates {{tl|Navbox}} and {{tl|Navbox with columns}}. The common parameters are marked with a cross<sup>'''†'''</sup>. Please refer to the documentation of {{tl|Navbox}} for more in depth descriptions and examples of those parameters.


=== パラメータ ===
=== パラメータ ===
:; name<sup>†</sup>
:; name<sup>†</sup>
:: テンプレートの名前は、テンプレートが使われている全てのページで「表・話・編・歴」("表示・会話・編集・履歴")リンクが正しく機能するために必須です。値には<code><nowiki>{{subst:PAGENAME}}</nowiki></code>を用いると便利です。
:: The name of the template. The name of this template, for example, is "Navbox with collapsible groups".
:; ''state''<sup>†</sup> <span style="font-weight:normal;">[<code>autocollapse, uncollapsed, collapsed, plain, off</code>]</span>
:; ''state''<sup>†</sup> <span style="font-weight:normal;">[<code>autocollapse, uncollapsed, collapsed, plain, off</code>]</span>
:* デフォルトは <code>autocollapse</code> です。<code>autocollapse</code> を設定すると、同一ページに折り畳み可能な表 ([隠す] リンクありの表、すなわち <code>plain, off</code> 以外を指定) が複数ある場合には折り畳んで初期表示されますが、それ以外の場合は展開した状態で初期表示されます。技術的詳細は[[MediaWiki:Common.js]]をご覧ください。
:: The initial state of the show/hide feature. See {{tl|Navbox}} for more information.
:* <code>collapsed</code> を設定すると、Navbox は折り畳んだ状態で初期表示されます。
:* <code>plain</code> を設定すると、Navbox は右端に [隠す] リンクなしで展開された状態で表示され、タイトルはセンタリングされます。
:* <code>off</code> を設定すると、Navbox は右端に [隠す] リンクなしで展開された状態で表示されますが、タイトルはセンタリングされません。これは上級者向けのオプションで、多くの場合 <code>plain</code> の使用で十分です。
:* <code>autocollapse</code>, <code>collapsed</code>, <code>plain</code>, <code>off</code> 以外の値(例: <code>uncollapsed</code>)を設定すると、Navbox は [隠す] リンクありで展開された状態で初期表示されます。

:: 初期状態をテンプレート作者の期待する Navbox の初期状態を記事で上書きできる様にする場合は、テンプレートに "state" という名前のパラメータを作成し、次の様にパススルーにします。
:: <tt><nowiki>| state = {{{state<includeonly>|希望する初期状態</includeonly>}}}</nowiki></tt>
:: 例: {{tl|建築}} のデフォルト状態は autocollapse です。 [[建築家]]には Navbox が1つしかないので、展開表示されます。一方、 [[都市計画]] には autocollapse な Navbox が2つあるので、閉じた状態で表示されます。<!-- テンプレートの使用状況が変わると例にならなくなるので時々チェックと差し替えが必要そうです。-->
:; ''navbar''<sup>†</sup>
:; ''navbar''<sup>†</sup>
:: Possible values are <code>plain</code>, <code>off</code>, and the default value of blank. See {{tl|Navbox}} for more information.
:: デフォルトは <code>Tnavbar</code> です。<code>plain</code> を設定すると、タイトルバー左の {{Tnavbar|Navbox|mini=1|nodiv=1}} リンクは表示されません。
:; ''border''<sup>†</sup>
:; ''border''<sup>†</sup>
:: 指定可能な値には<code>child</code>と<code>none</code>があります。既定値は空白です。<code>child</code>と指定するとテンプレート全体の罫線が非表示になります。任意のNavboxテンプレートを{{tl|Navbox subgroup}}のように別のNavboxテンプレート(親Navbox)の中におけるリストの一つをしてネストしたい場合に<code>child</code>と指定し、親Navboxの<code>list</code>の部分にテンプレートを置きます。
:: Possible values are <code>child</code>, <code>none</code>, and the default value of blank. Set to <code>child</code> if you wish to use the navbox inside of another navbox; with this option, the child navbox is borderless and fits snuggly inside of its parent navbox. The parent navbox may be the list area of {{tl|Navbox}}, the columns of a {{tl|Navbox with columns}}, or a list area of {{tl|Navbox with collapsible groups}}. See {{tl|Navbox}} for more information and examples.


=== 基本的なパラメータ ===
=== 基本的なパラメータ ===
:; '''''title'''''<sup>†</sup>
:; '''''title'''''<sup>†</sup>
:: 表の最上部中央に表示されるテキストです。通常はテンプレートの主題、つまり表本体の簡潔な説明です。これは一行でなければなりませんが、二行目が必要な場合は、センタリングが正しく行われる様、<code><nowiki>{{-}}</nowiki></code>を使ってください。
:: The title of the template, displayed centered in the titlebar at the top of the template.
:; ''above''<sup>†</sup>
:; ''above''<sup>†</sup>
:: タイトルバーと最初の group/list との間、すなわちテンプレート本体(group、list または image)の ''above'' (上)に表示される全幅セルです。画像のないテンプレートの場合、''above''は''group1''パラメータなしの''list1''と同様に表示されます。
:: Text or other elements to appear above groups/lists.
:; ''image''<sup>†</sup>
:; ''image''<sup>†</sup>
:: タイトルバーの下、本体 (group/list) の右に指定された画像を表示します。''list1''の指定は適切な表示に必須です。画像の指定には、
:: Image to the right of all of the groups/lists.
::: <code><nowiki>[[ファイル:Example.jpg|100px]]</nowiki></code>
:: といった、画像表示に用いられる標準的ウィキコードを用います。
:; ''imageleft''<sup>†</sup>
:; ''imageleft''<sup>†</sup>
:: タイトルバーの下、本体 (group/list) の左に指定された画像を表示します。''list1''の指定は適切な表示に必須です。画像の指定には、
:: Image to the left of all of the groups/lists.
::: <code><nowiki>[[ファイル:Example.jpg|100px]]</nowiki></code>
:: といった、画像表示に用いられる標準的ウィキコードを用います。
:; ''below''<sup>†</sup>
:; ''below''<sup>†</sup>
:: テンプレート本体(group、list または image)の ''below'' (下)に表示される全幅セルです。画像のないテンプレートの場合、''below''は''group<sub>n</sub>''パラメータなしの最後の''list<sub>n</sub>''と同様に表示されます。''below'' パラメータの使用例は{{tl|イギリス国鉄の蒸気機関車}}を参照。
:: Text or other elements to appear below the groups/lists.


=== group/list パラメータ ===
=== group/list パラメータ ===
:; ''group<sub>n</sub>''<sup>†</sup>
:; ''group<sub>n</sub>''<sup>†</sup>
:: (''group1''、''group2''、など)指定されたテキストが''list<sub>n</sub>''の左、ヘッダセルに表示されます。指定がなければ、''list<sub>n</sub>''は表の全幅を使います。
:: The title of each section.
:; ''list<sub>n</sub>''<sup>†</sup>
:; ''list<sub>n</sub>''<sup>†</sup>
:: (''list1''、''list2''、など)テンプレート本体、通常はリンク先のリストです。書式はインラインですが、<code><nowiki><div> </div></nowiki></code>でリスト全体を囲めば複数行での入力もできます。最低でも''list''パラメータは一つ必要です。以降の''list''は、それぞれ表の別の行に表示されます。 ''group<sub>n</sub>''パラメータが指定されていると、個々の ''list<sub>n</sub>'' の前にそのグループが表示されます。
:: The content/wikilinks that will be shown in the group. Use dots or bullets as separators (see the [[#See also|See also]] section). A {{tl|Navbox}} or {{tl|Navbox with columns}} can optionally be used here with its <code>border = child</code> parameter set. If this is done, leave the corresponding group<sub>n</sub> blank, as the child navbox will already provide the collapsible feature.
:; ''abbr<sub>n</sub>''
:; ''abbr<sub>n</sub>''
:: <code>selected</code>で指定するgroupの値の略称。
:: This is the abbreviation of the group. See <code>selected</code> parameter below to see how to use this parameter. This parameter is optional, but recommended.
:; ''selected''
:; ''selected''
:: <code>abbr</code>の値を指定すると該当するgroupのみが常時表示されます。<tt><nowiki>{{{1|}}}</nowiki></tt>と記述すると、記事に<nowiki>{{Navbox名|abbrの値}}</nowiki>を指定することで記事によって常時表示させるgroupを選ぶことができます。
:: If the value of <code>selected</code> equals the value of <code>abbr<sub>n</sub></code>, then list<sub>n</sub> is uncollapsed and all other lists are collapsed. If <code>selected</code> is left blank, or if it does not match any <code>abbr<sub>n</sub></code>, then all groups are collapsed. Usually this parameter should be set to <tt><nowiki>{{{1|}}}</nowiki></tt>. Since this template is a base template for others, there has to be a way to pass the group parameter from the article, to the secondary template to this one.
:; ''state<sub>n</sub>'' <span style="font-weight:normal;">[<code>autocollapse, uncollapsed, collapsed, plain, off</code>]</span>
:; ''state<sub>n</sub>'' <span style="font-weight:normal;">[<code>autocollapse, uncollapsed, collapsed, plain, off</code>]</span>
:: The initial collapsible state of list<sub>n</sub>. Set to collapsed by default. Overridden to uncollapsed if <code>selected</code> equals <code>abbr<sub>n</sub></code>.
:: list<sub>n</sub>個別の折りたたみの状態を上記の4つから選べます。既定値は<code>collapsed</code>です。<code>selected</code>で指定した<code>abbr<sub>n</sub></code>に該当するlist<sub>n</sub>は常時表示されます。
:; ''image<sub>n</sub>''
:; ''image<sub>n</sub>''
:: An image to appear in the list<sub>n</sub> content area on the right side.
:: list<sub>n</sub>の右側に表示する画像。
:; ''imageleft<sub>n</sub>''
:; ''imageleft<sub>n</sub>''
:: An image to appear in the list<sub>n</sub> content area on the left side.
:: list<sub>n</sub>の左側に表示する画像。


=== スタイルパラメータ ===
=== スタイルパラメータ ===
:; ''bodystyle''<sup>†</sup>
:; ''bodystyle''<sup>†</sup>
:: テンプレート全体に適用されるCSS属性。
:: CSS style/s to apply to the entire template
:; ''titlestyle''<sup>†</sup>
:; ''titlestyle''<sup>†</sup>
:: [[Wikipedia:CSS|CSS]] style/s to apply to titlebar; usually <code>background:''color''</code>. The color of wikilink text must be manually changed using span tags. For example use <code><nowiki>title = [[Scouting|<span style="color:ivory;">Scouting</span>]]</nowiki></code> to change the color of the link to ivory. The [show]/[hide] button and the vde link button use the color set in the titlestyle parameter. Here is an example of setting the titlestyle:
:: タイトルバーに適用されるCSS属性。通常<code>background:''色名''</code>のように背景色の指定に使用します。内部リンクのテキスト色を変更したい場合は<code><nowiki>title = [[Scouting|<span style="color:ivory;">Scouting</span>]]</nowiki></code> のように指定します。[隠す]/[表示]ボタンのテキスト色も変更したい場合もbodystyleで指定します。
::: <code>titlestyle = background:darkgreen;color:ivory;</code>
::: <code>titlestyle = background:darkgreen;color:ivory;</code>
:; ''abovestyle''<sup>†</sup>
:; ''abovestyle''<sup>†</sup>
:; ''belowstyle''<sup>†</sup>
:; ''belowstyle''<sup>†</sup>
:: CSS style/s to apply to the ''above'' and ''below'' parameters, respectively.
:: ''above''''below''それぞれに適用されるCSS属性。
:; ''basestyle''<sup>†</sup>
:; ''basestyle''<sup>†</sup>
:: CSS style/s to apply to the ''title'', ''above'', ''below'', and ''group<sub>n</sub>'' parameters, all at the same time.
:: ''title''''above''''below''''group<sub>n</sub>''に適用されるCSS属性。
:; ''imagestyle''<sup>†</sup>
:; ''imagestyle''<sup>†</sup>
:: CSS style/s to apply to the ''image'' parameter. Does not get applied to the image<sub>n</sub> parameters.
:: ''image''に適用されるCSS属性。image<sub>n</sub>には適用されません。
:; ''imageleftstyle''<sup>†</sup>
:; ''imageleftstyle''<sup>†</sup>
:: CSS style/s to apply to the ''imageleft'' parameter. Does not get applied to the imageleft<sub>n</sub> parameters.
:: ''imageleft''に適用されるCSS属性。imageleft<sub>n</sub>には適用されません。
:; ''groupstyle''<sup>†</sup>
:; ''groupstyle''<sup>†</sup>
:: groupに適用されるCSS属性。例:
:: CSS style/s to apply to all group heading parameters. Visit [http://meyerweb.com/eric/tools/color-blend/ this website] to get a lighter color similar to the title background color. Example:
::: <code>groupstyle = background:lightgreen;</code>
::: <code>groupstyle = background:lightgreen;</code>
:; ''group<sub>n</sub>''style<sup>†</sup>
:; ''group<sub>n</sub>''style<sup>†</sup>
:: 特定のgroupに適用されるCSS属性。''groupstyle''の設定を上書きします。
:: CSS style/s to apply to a specific group heading; overrides any CSS styles set in ''groupstyle''.
:; ''liststyle''<sup>†</sup>
:; ''liststyle''<sup>†</sup>
:: listに適用されるCSS属性。
:: CSS style/s to apply to all list content parameters.
:; ''list<sub>n</sub>''style<sup>†</sup>
:; ''list<sub>n</sub>''style<sup>†</sup>
:: 特定のlistに適用されるCSS属性。''liststyle''の設定を上書きします。
:: CSS style/s to apply to specific list content parameters; overrides any CSS styles set in ''liststyle''.
:; ''listpadding''<sup>†</sup>
:; ''listpadding''<sup>†</sup>
:: listの上下左右の余白を設定します。
:: Padding to have in each list cell; defaults to 0.25em on the left/right and 0em on the top/bottom.


== 例 ==
== 例 ==
106行目: 117行目:
{{Navbox with collapsible groups
{{Navbox with collapsible groups
|name = University of Michigan
|name = University of Michigan
|state = uncollapsed
|title = [[University of Michigan|<span style="color:#FFD700;">The University of Michigan, Ann Arbor</span>]]
|title = [[University of Michigan|<span style="color:#FFD700;">The University of Michigan, Ann Arbor</span>]]
|titlestyle = background:#00008B;color:#FFD700;
|titlestyle = background:#00008B;color:#FFD700;
|listclass = hlist
|groupstyle = background:#FFD700;color:#00008B;
|groupstyle = background:#FFD700;color:#00008B;
|image =
|image =
|selected = {{{1|}}}
|selected = {{{1|}}}
|state = collapsed


|group1 = [[University of Michigan#Academic profile|<span style="color:#00008B;">Academics</span>]]
|group1 = [[University of Michigan#Academic profile|<span style="color:#00008B;">Academics</span>]]
|abbr1 = academics
|abbr1 = academics
|list1 =
|list1 = [[University of Michigan College of Engineering|College of Engineering]]{{·}} [[University of Michigan College of Literature, Science, and the Arts|College of Literature, Science and the Arts]]{{·}} [[Gerald R. Ford School of Public Policy]]{{·}} [[University of Michigan Law School|Law School]]{{·}} [[University of Michigan Health System|Medical School]]{{·}} [[Ross School of Business]]{{·}} [[University of Michigan School of Education|School of Education]]{{·}} [[University of Michigan School of Information|School of Information]]{{·}} [[University of Michigan School of Music, Theatre & Dance|School of Music, Theatre & Dance]]{{·}}[[University of Michigan School of Natural Resources and Environment|School of Natural Resources and Environment]]{{·}} [[University of Michigan School of Public Health|School of Public Health]]{{·}} [[Taubman College of Architecture and Urban Planning]]
*[[University of Michigan College of Engineering|College of Engineering]]
*[[University of Michigan College of Literature, Science, and the Arts|College of Literature, Science and the Arts]]
*[[Gerald R. Ford School of Public Policy]]
*[[University of Michigan Law School|Law School]]
*[[University of Michigan Health System|Medical School]]
*[[Ross School of Business]]
*[[University of Michigan School of Education|School of Education]]
*[[University of Michigan School of Information|School of Information]]
*[[University of Michigan School of Music, Theatre & Dance|School of Music, Theatre & Dance]]
*[[University of Michigan School of Natural Resources and Environment|School of Natural Resources and Environment]]
*[[University of Michigan School of Public Health|School of Public Health]]
*[[Taubman College of Architecture and Urban Planning]]


|group2 = [[Michigan Wolverines|<span style="color:#00008B;">Athletics</span>]]
|group2 = [[Michigan Wolverines|<span style="color:#00008B;">Athletics</span>]]
|abbr2 = athletics
|abbr2 = athletics
|state2 = uncollapsed
|list2 = [[Michigan Stadium|Michigan Stadium]]{{·}} [[Crisler Arena|Crisler Arena]]{{·}} [[Yost Ice Arena|Yost Ice Arena]]{{·}} [[Michigan Wolverines|Michigan Wolverines]]{{·}} [[Michigan Wolverines football|Football]]{{·}} [[Michigan-Ohio State rivalry|UM-OSU Rivalry]]{{·}} [[Little Brown Jug (football)|Little Brown Jug]]{{·}} [[Paul Bunyan Trophy]]{{·}} [[Cold War (ice hockey)|Cold War]]
|list2 =
*[[Michigan Stadium]]
*[[Crisler Arena]]
*[[Yost Ice Arena]]
*[[Michigan Wolverines]]
*[[Michigan Wolverines football|Football]]
*[[Michigan – Ohio State football rivalry|UM-OSU Rivalry]]
*[[Little Brown Jug (American football)|Little Brown Jug]]
*[[Paul Bunyan Trophy]]
*[[Cold War (ice hockey)|Cold War]]


|group3 = Campus
|group3 = Campus
|abbr3 = campus
|abbr3 = campus
|list3 =
|list3 = [[Angell Hall Observatory]]{{·}} [[Burton Tower]]{{·}} [[The Diag]]{{·}} [[David M. Dennison Building|Dennison Building]]{{·}} [[Gerald R. Ford Presidential Library]]{{·}} [[Hill Auditorium|Hill Auditorium]]{{·}} [[Lurie Tower]]{{·}} [[Matthaei Botanical Gardens]]{{·}} [[Michigan Union]]{{·}} [[Museums at the University of Michigan|Museums]]{{·}} [[Nichols Arboretum]]{{·}} [[University of Michigan Health System|UM Health System]]{{·}} [[University of Michigan Library|University Library]]
*[[Angell Hall Observatory]]

*[[Burton Memorial Tower|Burton Tower]]
*[[The Diag]]
*[[David M. Dennison Building|Dennison Building]]
*[[Gerald R. Ford Presidential Library]]
*[[Hill Auditorium]]
*[[Lurie Tower]]
*[[Matthaei Botanical Gardens]]
*[[Michigan Union]]
*[[Museums at the University of Michigan|Museums]]
*[[Nichols Arboretum]]
*[[University of Michigan Health System|UM Health System]]
*[[University of Michigan Library|University Library]]
}}
}}
</pre>
</pre>
132行目: 178行目:
|title = [[University of Michigan|<span style="color:#FFD700;">The University of Michigan, Ann Arbor</span>]]
|title = [[University of Michigan|<span style="color:#FFD700;">The University of Michigan, Ann Arbor</span>]]
|titlestyle = background:#00008B;color:#FFD700;
|titlestyle = background:#00008B;color:#FFD700;
|listclass = hlist
|groupstyle = background:#FFD700;color:#00008B;
|groupstyle = background:#FFD700;color:#00008B;
|image =
|image =
138行目: 185行目:
|group1 = [[University of Michigan#Academic profile|<span style="color:#00008B;">Academics</span>]]
|group1 = [[University of Michigan#Academic profile|<span style="color:#00008B;">Academics</span>]]
|abbr1 = academics
|abbr1 = academics
|list1 =
|list1 = [[University of Michigan College of Engineering|College of Engineering]]{{·}} [[University of Michigan College of Literature, Science, and the Arts|College of Literature, Science and the Arts]]{{·}} [[Gerald R. Ford School of Public Policy]]{{·}} [[University of Michigan Law School|Law School]]{{·}} [[University of Michigan Health System|Medical School]]{{·}} [[Ross School of Business]]{{·}} [[University of Michigan School of Education|School of Education]]{{·}} [[University of Michigan School of Information|School of Information]]{{·}} [[University of Michigan School of Music, Theatre & Dance|School of Music, Theatre & Dance]]{{·}}[[University of Michigan School of Natural Resources and Environment|School of Natural Resources and Environment]]{{·}} [[University of Michigan School of Public Health|School of Public Health]]{{·}} [[Taubman College of Architecture and Urban Planning]]
*[[University of Michigan College of Engineering|College of Engineering]]
*[[University of Michigan College of Literature, Science, and the Arts|College of Literature, Science and the Arts]]
*[[Gerald R. Ford School of Public Policy]]
*[[University of Michigan Law School|Law School]]
*[[University of Michigan Health System|Medical School]]
*[[Ross School of Business]]
*[[University of Michigan School of Education|School of Education]]
*[[University of Michigan School of Information|School of Information]]
*[[University of Michigan School of Music, Theatre & Dance|School of Music, Theatre & Dance]]
*[[University of Michigan School of Natural Resources and Environment|School of Natural Resources and Environment]]
*[[University of Michigan School of Public Health|School of Public Health]]
*[[Taubman College of Architecture and Urban Planning]]


|group2 = [[Michigan Wolverines|<span style="color:#00008B;">Athletics</span>]]
|group2 = [[Michigan Wolverines|<span style="color:#00008B;">Athletics</span>]]
|abbr2 = athletics
|abbr2 = athletics
|state2 = uncollapsed
|list2 = [[Michigan Stadium|Michigan Stadium]]{{·}} [[Crisler Arena|Crisler Arena]]{{·}} [[Yost Ice Arena|Yost Ice Arena]]{{·}} [[Michigan Wolverines|Michigan Wolverines]]{{·}} [[Michigan Wolverines football|Football]]{{·}} [[Michigan-Ohio State rivalry|UM-OSU Rivalry]]{{·}} [[Little Brown Jug (football)|Little Brown Jug]]{{·}} [[Paul Bunyan Trophy]]{{·}} [[Cold War (ice hockey)|Cold War]]
|list2 =
*[[Michigan Stadium]]
*[[Crisler Arena]]
*[[Yost Ice Arena]]
*[[Michigan Wolverines]]
*[[Michigan Wolverines football|Football]]
*[[Michigan – Ohio State football rivalry|UM-OSU Rivalry]]
*[[Little Brown Jug (American football)|Little Brown Jug]]
*[[Paul Bunyan Trophy]]
*[[Cold War (ice hockey)|Cold War]]


|group3 = Campus
|group3 = Campus
|abbr3 = campus
|abbr3 = campus
|list3 =
|list3 = [[Angell Hall Observatory]]{{·}} [[Burton Tower]]{{·}} [[The Diag]]{{·}} [[David M. Dennison Building|Dennison Building]]{{·}} [[Gerald R. Ford Presidential Library]]{{·}} [[Hill Auditorium|Hill Auditorium]]{{·}} [[Lurie Tower]]{{·}} [[Matthaei Botanical Gardens]]{{·}} [[Michigan Union]]{{·}} [[Museums at the University of Michigan|Museums]]{{·}} [[Nichols Arboretum]]{{·}} [[University of Michigan Health System|UM Health System]]{{·}} [[University of Michigan Library|University Library]]
*[[Angell Hall Observatory]]

*[[Burton Memorial Tower|Burton Tower]]
*[[The Diag]]
*[[David M. Dennison Building|Dennison Building]]
*[[Gerald R. Ford Presidential Library]]
*[[Hill Auditorium]]
*[[Lurie Tower]]
*[[Matthaei Botanical Gardens]]
*[[Michigan Union]]
*[[Museums at the University of Michigan|Museums]]
*[[Nichols Arboretum]]
*[[University of Michigan Health System|UM Health System]]
*[[University of Michigan Library|University Library]]
}}
}}


=== Nesting other Navbox forms ===
=== 他の形式のNavboxをネストした場合 ===
This example shows {{tl|Navbox}}, {{tl|Navbox with collapsible groups}} and {{tl|Navbox with columns}} all working together. Press the edit button for the section to view the code. Note that each of the child navboxes has the first parameter set to <code>child</code>
この使用例では{{tl|Navbox with collapsible groups}}{{tl|Navbox}}{{tl|Navbox with columns}}を使用しています。 サブグループとして使用しているNavboxで最初のパラメータとして<code>child</code>を指定しています。
{{Navbox with collapsible groups
{{Navbox with collapsible groups
|name = Navbox with collapsible groups
|name = Navbox with collapsible groups/doc#他の形式のNavboxをネストした場合
|title = Navbox, Navbox with columns, and Navbox with collapsible groups together
|title = Navbox, Navbox with columns, and Navbox with collapsible groups together
|selected = {{{1|}}}
|selected = {{{1|}}}
|listclass = hlist


|group1 = [[:Category:Scouting|The Scouting Movement]]
|group1 = [[:Category:Scouting|The Scouting Movement]]
|abbr1 = movement
|abbr1 = movement
|list1 =
|list1 = [[Scouting]]{{·}}''[[Scouting for Boys]]''{{·}}[[Scout method]]{{·}}[[Scout Law]]{{·}}[[Scout Promise]]{{·}}[[Scout Motto]]{{·}}[[Wood Badge]]{{·}}[[Age groups in Scouting and Guiding]]{{·}}[[Cub Scout]]{{·}}[[Boy Scout]]{{·}}[[Rover Scout]]{{·}}[[Brownie (Girl Guides)|Brownie]]{{·}}[[Girl Guiding and Girl Scouting]]{{·}}[[Ranger (Girl Guide)]]{{·}}[[Jamboree (Scouting)|Jamboree]]{{·}}[[Scout Leader]]{{·}}[[World Organization of the Scout Movement|WOSM]]{{·}}[[World Association of Girl Guides and Girl Scouts|WAGGGS]]{{·}}[[Non-aligned Scouting and Scout-like organisations|Non-aligned organisations]]{{·}}[[Scouting controversy and conflict]]{{·}}[[Scouting in popular culture]]{{·}}[[List of Scouts]]{{·}}[[List of highest awards in Scouting]]
*[[Scouting]]
*''[[Scouting for Boys]]''
*[[Scout method]]
*[[Scout Law]]
*[[Scout Promise]]
*[[Scout Motto]]
*[[Wood Badge]]
*[[Age groups in Scouting and Guiding]]
*[[Cub Scout]]
*[[Scout (Scouting)|Boy Scout]]
*[[Rover Scout]]
*[[Brownie (Girl Guides)|Brownie]]
*[[Girl Guiding and Girl Scouting]]
*[[Ranger (Girl Guide)]]
*[[Jamboree (Scouting)|Jamboree]]
*[[Scout Leader]]
*[[World Organization of the Scout Movement|WOSM]]
*[[World Association of Girl Guides and Girl Scouts|WAGGGS]]
*[[Non-aligned Scouting and Scout-like organisations|Non-aligned organisations]]
*[[Scouting controversy and conflict]]
*[[Scouting in popular culture]]
*[[List of Scouts]]
*[[List of highest awards in Scouting]]


|list2 = {{Navbox|child
|list2 = {{Navbox|child
|title = [[French colonial empires|Former French colonies]] in [[Africa]] and the [[Indian Ocean]]
|title = [[French colonial empire|Former French colonies]] in [[Africa]] and the [[Indian Ocean]]
|state = {{#ifeq:{{{1|}}}|french|uncollapsed|collapsed}}
|state = {{#ifeq:{{{1|}}}|french|uncollapsed|collapsed}}
|titlestyle = background#
|titlestyle = background#
|groupstyle = background:lavender;
|groupstyle = background:lavender;


|group1 = [[Mahgreb]]
|group1 = [[Maghreb|Mahgreb]]
|list1 =
|list1 = [[French rule in Algeria|Algeria]]{{·}} [[French Morocco|Morocco]]&nbsp;<small>([[Arguin|Arguin Island]])</small>{{·}} [[History of Tunisia|Tunisia]]
*[[French Algeria|Algeria]]
*[[French protectorate of Morocco|Morocco]]&nbsp;<small>([[Arguin|Arguin Island]])</small>
*[[History of Tunisia|Tunisia]]


|group2 = [[French West Africa]]
|group2 = [[French West Africa]]
|list2 =
|list2 = [[History of Côte d'Ivoire#French Period|Côte d'Ivoire]]{{·}} [[French Dahomey|Dahomey]]{{·}} [[French Sudan]]{{·}} [[French Guinea|Guinea]]{{·}} [[History of Mauritania#French colonization and post-colonial history|Mauritania]]{{·}} [[History of Niger#Colonization|Niger]]{{·}} [[History of Senegal|Senegal]]{{·}} [[French Upper Volta|Upper Volta]]
*[[History of Côte d'Ivoire#French Period|Côte d'Ivoire]]
*[[French Dahomey|Dahomey]]
*[[French Sudan]]
*[[French Guinea|Guinea]]
*[[History of Mauritania#French colonization and post-colonial history|Mauritania]]
*[[History of Niger#Colonization|Niger]]
*[[History of Senegal|Senegal]]
*[[French Upper Volta|Upper Volta]]


|group3 = &nbsp;
|group3 = &nbsp;
|list3 = [[French Togoland]]{{·}} [[James Island (The Gambia)|James Island]]
|list3 =
*[[French Togoland]]
*[[James Island (Gambia)|James Island]]


|group4 = [[French Equatorial Africa]]
|group4 = [[French Equatorial Africa]]
|list4 =
|list4 = [[Colonial Chad|Chad]]{{·}} [[History of Gabon|Gabon]]{{·}} [[History of the Republic of the Congo|Middle Congo]]{{·}} [[Oubangui-Chari]]
*[[Colonial Chad|Chad]]
*[[History of Gabon|Gabon]]
*[[History of the Republic of the Congo|Middle Congo]]
*[[Ubangi-Shari|Oubangui-Chari]]


|group5 = [[Comoros]]
|group5 = [[Comoros]]
|list5 = [[Anjouan]]{{·}} [[Grande Comore]]{{·}} [[Mohéli]]
|list5 =
*[[Anjouan]]
*[[Grande Comore]]
*[[Mohéli]]


|group6 = &nbsp;
|group6 = &nbsp;
|list6 =
|list6 = [[History of Djibouti#French Interest|French Somaliland (Djibouti)]]{{·}} [[History of Madagascar#French Control|Madagascar]]{{·}} [[Mauritius|Ile de France]]{{·}} [[Seychelles]]
*[[History of Djibouti#French interest|French Somaliland (Djibouti)]]
*[[History of Madagascar#French control|Madagascar]]
*[[Mauritius|Ile de France]]
*[[Seychelles]]


}}
}}


|group3 = [[:Category:Scouting in the United Kingdom|Scouting in the United Kingdom]]
|group3 = [[:Category:Scouting and Guiding in the United Kingdom|Scouting and Guiding in the United Kingdom]]
|abbr3 = Scouting
|abbr3 = Scouting
|list3 =
|list3 = [[The Scout Association]]{{·}}[[Girlguiding UK]]{{·}}[[Beaver Scouts]]{{·}}[[Cub Section (UK)]]{{·}}[[Venture Scout]]{{·}}[[Explorer Scouts]]{{·}}[[Brownie (Girl Guides)]]{{·}}[[Ranger (Girl Guide)]]{{·}}[[Rainbow (Girl Guides)]]{{·}}[[Scout Network]]{{·}}[[Chief Scout (United Kingdom)]]{{·}}[[Scout Counties]]{{·}}[[Scout District]]{{·}}[[Scout Section (UK)]]{{·}}[[Scout Activity Centre]]{{·}}[[Young Leaders (The Scout Association)|Young Leaders]]
*[[The Scout Association]]
*[[Girlguiding UK]]
*[[Beaver Scouts]]
*[[Cub Scouts (The Scout Association)|Cub Section (UK)]]
*[[Venture Scout]]
*[[Explorer Scouts (The Scout Association)|Explorer Scouts]]
*[[Brownie (Girl Guides)]]
*[[Ranger (Girl Guide)]]
*[[Rainbow (Girl Guides)]]
*[[Scout Network]]
*[[Chief Scout (The Scout Association)|Chief Scout (United Kingdom)]]
*[[Scout Counties (The Scout Association)|Scout Counties]]
*[[Scout District]]
*[[Scouts (The Scout Association)|Scout Section (UK)]]
*[[Scout Activity Centre (The Scout Association)|Scout Activity Centre]]
*[[Young Leaders (The Scout Association)|Young Leaders]]


|list4 = {{Navbox with columns|child
|list4 = {{Navbox with columns|child
234行目: 379行目:
|col4 = Col4
|col4 = Col4
}}
}}

}}
}}


== 関連項目 ==
== 関連項目 ==
* {{tl|Navbox}} - 基本的なナビゲーションボックステンプレート。
* {{tl|Nowrap begin}} - Provides and explanation of the preferred method of using bullets or pipes to delimit list items.
* {{tl|Navbox with columns}} - 列表示にするための姉妹ナビゲーションボックステンプレート。
* {{tl|Navbox}} - Basic navbox.
* {{tl|Navbox subgroup}} - {{tl|Navbox}}内にサブグループを置くためのナビゲーションボックステンプレート。
* {{tl|Navbox with columns}} - Sister template that provides columns in a navbox
* {{tl|Navbox subgroup}} - Allows the creation of subgroups within {{tl|Navbox}}.


{{Navigational templates}}
{{Navigational templates}}

<includeonly>
<includeonly>
<!--カテゴリ-->
<!--カテゴリ-->
[[Category:ナビゲーションテンプレート|*]]
[[Category:ナビゲーションテンプレート|*]]
[[Category:メタテンプレート|{{PAGENAME}}]]
[[Category:メタテンプレート]]
[[Category:条件文|{{PAGENAME}}]]

[[en:Template:Navbox with collapsible groups]]
[[ka:თარგი:ნავდაფა გაშლადი ჯგუფებით]]
[[id:Templat:Templat:Navbox with collapsible groups]]
[[pl:Szablon:Navbox ze zwijanymi grupami]]
</includeonly>
</includeonly>

2022年12月2日 (金) 03:26時点における最新版

このテンプレートは特定の記事に関連のある記事のグループがあるナビゲーションテンプレートをつくります。全てのグループはデフォルトで隠されています。しかしながらパラメータを呼び出すことによって、同じグループで他の記事のある個々のグループを表示させることができます。

使用法[編集]

空白のままにされるパラメータは削除してください。このテンプレートは現在10グループ/リストまで対応していますが、必要ならばより加えられます。このテンプレートでは最低2組のグループ/リストを使うべきです。そうでない場合は、代わりに {{Navbox}} を使ってください。

{{Navbox with collapsible groups
|  name  = {{subst:PAGENAME}}
| state  = 
| selected = {{{1|}}}
| title  = 
| titlestyle = 
| groupstyle = 
| image  = 

| group1 = 
|  abbr1 = 
|  list1 = 

| group2 = 
|  abbr2 = 
|  list2 = 

 ...

|group10 = 
| abbr10 = 
| list10 = 
}}

パラメータ[編集]

このテンプレートは姉妹テンプレートである {{Navbox}} や {{Navbox with columns}} と多くのパラメータを共有します。その共通のパラメータは短剣符でマークされています。より多くの詳細な説明やそれらのパラメータの例がある {{Navbox}} の解説も参照してください。

パラメータ[編集]

name
テンプレートの名前は、テンプレートが使われている全てのページで「表・話・編・歴」("表示・会話・編集・履歴")リンクが正しく機能するために必須です。値には{{subst:PAGENAME}}を用いると便利です。
state [autocollapse, uncollapsed, collapsed, plain, off]
  • デフォルトは autocollapse です。autocollapse を設定すると、同一ページに折り畳み可能な表 ([隠す] リンクありの表、すなわち plain, off 以外を指定) が複数ある場合には折り畳んで初期表示されますが、それ以外の場合は展開した状態で初期表示されます。技術的詳細はMediaWiki:Common.jsをご覧ください。
  • collapsed を設定すると、Navbox は折り畳んだ状態で初期表示されます。
  • plain を設定すると、Navbox は右端に [隠す] リンクなしで展開された状態で表示され、タイトルはセンタリングされます。
  • off を設定すると、Navbox は右端に [隠す] リンクなしで展開された状態で表示されますが、タイトルはセンタリングされません。これは上級者向けのオプションで、多くの場合 plain の使用で十分です。
  • autocollapse, collapsed, plain, off 以外の値(例: uncollapsed)を設定すると、Navbox は [隠す] リンクありで展開された状態で初期表示されます。
初期状態をテンプレート作者の期待する Navbox の初期状態を記事で上書きできる様にする場合は、テンプレートに "state" という名前のパラメータを作成し、次の様にパススルーにします。
| state = {{{state<includeonly>|希望する初期状態</includeonly>}}}
例: {{建築}} のデフォルト状態は autocollapse です。 建築家には Navbox が1つしかないので、展開表示されます。一方、 都市計画 には autocollapse な Navbox が2つあるので、閉じた状態で表示されます。
navbar
デフォルトは Tnavbar です。plain を設定すると、タイトルバー左の リンクは表示されません。
border
指定可能な値にはchildnoneがあります。既定値は空白です。childと指定するとテンプレート全体の罫線が非表示になります。任意のNavboxテンプレートを{{Navbox subgroup}}のように別のNavboxテンプレート(親Navbox)の中におけるリストの一つをしてネストしたい場合にchildと指定し、親Navboxのlistの部分にテンプレートを置きます。

基本的なパラメータ[編集]

title
表の最上部中央に表示されるテキストです。通常はテンプレートの主題、つまり表本体の簡潔な説明です。これは一行でなければなりませんが、二行目が必要な場合は、センタリングが正しく行われる様、{{-}}を使ってください。
above
タイトルバーと最初の group/list との間、すなわちテンプレート本体(group、list または image)の above (上)に表示される全幅セルです。画像のないテンプレートの場合、abovegroup1パラメータなしのlist1と同様に表示されます。
image
タイトルバーの下、本体 (group/list) の右に指定された画像を表示します。list1の指定は適切な表示に必須です。画像の指定には、
[[ファイル:Example.jpg|100px]]
といった、画像表示に用いられる標準的ウィキコードを用います。
imageleft
タイトルバーの下、本体 (group/list) の左に指定された画像を表示します。list1の指定は適切な表示に必須です。画像の指定には、
[[ファイル:Example.jpg|100px]]
といった、画像表示に用いられる標準的ウィキコードを用います。
below
テンプレート本体(group、list または image)の below (下)に表示される全幅セルです。画像のないテンプレートの場合、belowgroupnパラメータなしの最後のlistnと同様に表示されます。below パラメータの使用例は{{イギリス国鉄の蒸気機関車}}を参照。

group/list パラメータ[編集]

groupn
group1group2、など)指定されたテキストがlistnの左、ヘッダセルに表示されます。指定がなければ、listnは表の全幅を使います。
listn
list1list2、など)テンプレート本体、通常はリンク先のリストです。書式はインラインですが、<div> </div>でリスト全体を囲めば複数行での入力もできます。最低でもlistパラメータは一つ必要です。以降のlistは、それぞれ表の別の行に表示されます。 groupnパラメータが指定されていると、個々の listn の前にそのグループが表示されます。
abbrn
selectedで指定するgroupの値の略称。
selected
abbrの値を指定すると該当するgroupのみが常時表示されます。{{{1|}}}と記述すると、記事に{{Navbox名|abbrの値}}を指定することで記事によって常時表示させるgroupを選ぶことができます。
staten [autocollapse, uncollapsed, collapsed, plain, off]
listn個別の折りたたみの状態を上記の4つから選べます。既定値はcollapsedです。selectedで指定したabbrnに該当するlistnは常時表示されます。
imagen
listnの右側に表示する画像。
imageleftn
listnの左側に表示する画像。

スタイルパラメータ[編集]

bodystyle
テンプレート全体に適用されるCSS属性。
titlestyle
タイトルバーに適用されるCSS属性。通常background:色名のように背景色の指定に使用します。内部リンクのテキスト色を変更したい場合はtitle = [[Scouting|<span style="color:ivory;">Scouting</span>]] のように指定します。[隠す]/[表示]ボタンのテキスト色も変更したい場合もbodystyleで指定します。
titlestyle = background:darkgreen;color:ivory;
abovestyle
belowstyle
abovebelowそれぞれに適用されるCSS属性。
basestyle
titleabovebelowgroupnに適用されるCSS属性。
imagestyle
imageに適用されるCSS属性。imagenには適用されません。
imageleftstyle
imageleftに適用されるCSS属性。imageleftnには適用されません。
groupstyle
groupに適用されるCSS属性。例:
groupstyle = background:lightgreen;
groupnstyle
特定のgroupに適用されるCSS属性。groupstyleの設定を上書きします。
liststyle
listに適用されるCSS属性。
listnstyle
特定のlistに適用されるCSS属性。liststyleの設定を上書きします。
listpadding
listの上下左右の余白を設定します。

[編集]

基本的な例[編集]

{{Navbox with collapsible groups
|name = University of Michigan
|state = uncollapsed
|title = [[University of Michigan|<span style="color:#FFD700;">The University of Michigan, Ann Arbor</span>]]
|titlestyle = background:#00008B;color:#FFD700;
|listclass = hlist
|groupstyle = background:#FFD700;color:#00008B;
|image = 
|selected = {{{1|}}}

|group1 = [[University of Michigan#Academic profile|<span style="color:#00008B;">Academics</span>]]
|abbr1 = academics
|list1 =
*[[University of Michigan College of Engineering|College of Engineering]]
*[[University of Michigan College of Literature, Science, and the Arts|College of Literature, Science and the Arts]]
*[[Gerald R. Ford School of Public Policy]]
*[[University of Michigan Law School|Law School]]
*[[University of Michigan Health System|Medical School]]
*[[Ross School of Business]]
*[[University of Michigan School of Education|School of Education]]
*[[University of Michigan School of Information|School of Information]]
*[[University of Michigan School of Music, Theatre & Dance|School of Music, Theatre & Dance]]
*[[University of Michigan School of Natural Resources and Environment|School of Natural Resources and Environment]]
*[[University of Michigan School of Public Health|School of Public Health]]
*[[Taubman College of Architecture and Urban Planning]]

|group2 = [[Michigan Wolverines|<span style="color:#00008B;">Athletics</span>]]
|abbr2 = athletics
|state2 = uncollapsed
|list2 =
*[[Michigan Stadium]]
*[[Crisler Arena]]
*[[Yost Ice Arena]]
*[[Michigan Wolverines]]
*[[Michigan Wolverines football|Football]]
*[[Michigan – Ohio State football rivalry|UM-OSU Rivalry]]
*[[Little Brown Jug (American football)|Little Brown Jug]]
*[[Paul Bunyan Trophy]]
*[[Cold War (ice hockey)|Cold War]]

|group3 = Campus
|abbr3 = campus
|list3 =
*[[Angell Hall Observatory]]
*[[Burton Memorial Tower|Burton Tower]]
*[[The Diag]]
*[[David M. Dennison Building|Dennison Building]]
*[[Gerald R. Ford Presidential Library]]
*[[Hill Auditorium]]
*[[Lurie Tower]]
*[[Matthaei Botanical Gardens]]
*[[Michigan Union]]
*[[Museums at the University of Michigan|Museums]]
*[[Nichols Arboretum]]
*[[University of Michigan Health System|UM Health System]]
*[[University of Michigan Library|University Library]]
}}

他の形式のNavboxをネストした場合[編集]

この使用例では{{Navbox with collapsible groups}}に{{Navbox}}、{{Navbox with columns}}を使用しています。 サブグループとして使用しているNavboxで最初のパラメータとしてchildを指定しています。

関連項目[編集]

  • {{Navbox}} - 基本的なナビゲーションボックステンプレート。
  • {{Navbox with columns}} - 列表示にするための姉妹ナビゲーションボックステンプレート。
  • {{Navbox subgroup}} - {{Navbox}}内にサブグループを置くためのナビゲーションボックステンプレート。
ナビゲーションテンプレート対照
折畳モード タイトル色 画像 グループ スタイル
パラメータ
例テンプレート
{{Navbox}} collapsible navbox Left/Right of body Yes Yes {{イギリスの電車}}
{{Navbox with columns}} collapsible navbox Left/right of columns No Yes {{都道府県知事}}
{{Navbox with collapsible groups}} collapsible navbox Left/right of body and/or in each list Yes Yes {{日本近代地震}}
{{Navbox subgroup}} collapsible navbox No Yes Yes {{日本百名山}}
{{NavboxYears}}
{{NavboxYears2}}
collapsible navbox No No No {{全豪オープン}}
折畳属性
種類 CSSクラス Javascript 畳まれるとき Custom
initial state
ネスト タイトル色 フォントサイズ
Collapsible table collapsible, navbox Common.jsにて定義 2個以上 Yes No #ccccff 90%