TabView – Template
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Lou Montana moved page Template:Tabs to Template:TabView without leaving a redirect: Name standard) |
Lou Montana (talk | contribs) (Add 6..10 support) |
||
(One intermediate revision by the same user not shown) | |||
Line 4: | Line 4: | ||
}}{{#if:{{{title4|}}} | <div class="biki-tab-title">{{{title4|}}}</div> | }}{{#if:{{{title4|}}} | <div class="biki-tab-title">{{{title4|}}}</div> | ||
}}{{#if:{{{title5|}}} | <div class="biki-tab-title">{{{title5|}}}</div> | }}{{#if:{{{title5|}}} | <div class="biki-tab-title">{{{title5|}}}</div> | ||
}}{{#if:{{{title6|}}} | <div class="biki-tab-title">{{{title6|}}}</div> | |||
}}{{#if:{{{title7|}}} | <div class="biki-tab-title">{{{title7|}}}</div> | |||
}}{{#if:{{{title8|}}} | <div class="biki-tab-title">{{{title8|}}}</div> | |||
}}{{#if:{{{title9|}}} | <div class="biki-tab-title">{{{title9|}}}</div> | |||
}}{{#if:{{{title10|}}} | <div class="biki-tab-title">{{{title10|}}}</div> | |||
}}{{#if:{{{content1|}}} | <div class="biki-tab-content">{{{content1|}}}</div> | }}{{#if:{{{content1|}}} | <div class="biki-tab-content">{{{content1|}}}</div> | ||
}}{{#if:{{{content2|}}} | <div class="biki-tab-content">{{{content2|}}}</div> | }}{{#if:{{{content2|}}} | <div class="biki-tab-content">{{{content2|}}}</div> | ||
Line 9: | Line 14: | ||
}}{{#if:{{{content4|}}} | <div class="biki-tab-content">{{{content4|}}}</div> | }}{{#if:{{{content4|}}} | <div class="biki-tab-content">{{{content4|}}}</div> | ||
}}{{#if:{{{content5|}}} | <div class="biki-tab-content">{{{content5|}}}</div> | }}{{#if:{{{content5|}}} | <div class="biki-tab-content">{{{content5|}}}</div> | ||
}}{{#if:{{{content6|}}} | <div class="biki-tab-content">{{{content6|}}}</div> | |||
}}{{#if:{{{content7|}}} | <div class="biki-tab-content">{{{content7|}}}</div> | |||
}}{{#if:{{{content8|}}} | <div class="biki-tab-content">{{{content8|}}}</div> | |||
}}{{#if:{{{content9|}}} | <div class="biki-tab-content">{{{content9|}}}</div> | |||
}}{{#if:{{{content10|}}} | <div class="biki-tab-content">{{{content10|}}}</div> | |||
}}</div></includeonly><noinclude>{{Doc/Template | }}</div></includeonly><noinclude>{{Doc/Template | ||
|descr= This template allows for ''horizontal'' tabs. | |descr= This template allows for ''horizontal'' tabs. | ||
|param1= title1.. | |param1= title1..10 | ||
|descr1= named parameter - tab #'s title | |descr1= named parameter - tab #'s title | ||
|param2= content1.. | |param2= content1..10 | ||
|descr2= named parameter - tab #'s content | |descr2= named parameter - tab #'s content | ||
|param3= selected | |param3= selected | ||
Line 19: | Line 29: | ||
|example1= <nowiki>{{Tabs}}</nowiki> | |example1= <nowiki>{{Tabs}}</nowiki> | ||
|result1= {{ {{FULLPAGENAME}} }} | |result1= {{ {{FULLPAGENAME}} }} | ||
|example2= <nowiki>{{ | |example2= <nowiki>{{TabView |title1= Tab 1 title}}</nowiki> | ||
|result2= {{ {{FULLPAGENAME}} |title1= Tab 1 title}} | |result2= {{ {{FULLPAGENAME}} |title1= Tab 1 title}} | ||
|example3= <nowiki>{{ | |example3= <nowiki>{{TabView |title1= Tab 1 title |content1= First tab content, yay!}}</nowiki> | ||
|result3= {{ {{FULLPAGENAME}} |title1= Tab 1 title |content1= First tab content, yay!}} | |result3= {{ {{FULLPAGENAME}} |title1= Tab 1 title |content1= First tab content, yay!}} | ||
|example4= <nowiki>{{Tabs |title1= Tab 1 title |title2= Tab 2 title}}</nowiki> | |example4= <nowiki>{{Tabs |title1= Tab 1 title |title2= Tab 2 title}}</nowiki> | ||
|result4= {{ {{FULLPAGENAME}} |title1= Tab 1 title |title2= Tab 2 title}} | |result4= {{ {{FULLPAGENAME}} |title1= Tab 1 title |title2= Tab 2 title}} | ||
|example5= <nowiki>{{ | |example5= <nowiki>{{TabView |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}}</nowiki> | ||
|result5= {{ {{FULLPAGENAME}} |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}} | |result5= {{ {{FULLPAGENAME}} |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}} | ||
|example6= <nowiki>{{ | |example6= <nowiki>{{TabView |selected= 2 |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}}</nowiki> | ||
|result6= {{ {{FULLPAGENAME}} |selected= 2 |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}} | |result6= {{ {{FULLPAGENAME}} |selected= 2 |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}} | ||
}}</noinclude> | }}</noinclude> |
Latest revision as of 14:41, 16 November 2021
This template allows for horizontal tabs.
This template is used on these pages.
Usage
{{TabView|title1..10|content1..10|selected}}
- title1..10: named parameter - tab #'s title
- content1..10: named parameter - tab #'s content
- selected: named parameter - selected tab (not 0-based index, e.g 1 = first tab, 2 = second etc)
Code | Result |
---|---|
{{Tabs}} | |
{{TabView |title1= Tab 1 title}} | Tab 1 title |
{{TabView |title1= Tab 1 title |content1= First tab content, yay!}} | Tab 1 title First tab content, yay! |
{{Tabs |title1= Tab 1 title |title2= Tab 2 title}} | Tab 1 title Tab 2 title |
{{TabView |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}} | Tab 1 title Tab 2 title First tab content... Second tab content, yay! |
{{TabView |selected= 2 |title1= Tab 1 title |content1= First tab content... |title2= Tab 2 title |content2= Second tab content, yay!}} | Tab 1 title Tab 2 title First tab content... Second tab content, yay! |