Jump to content
 







Main menu
   


Navigation  



Main page
Contents
Current events
Random article
About Wikipedia
Contact us
Donate
 




Contribute  



Help
Learn to edit
Community portal
Recent changes
Upload file
 








Search  

































Create account

Log in
 









Create account
 Log in
 




Pages for logged out editors learn more  



Contributions
Talk
 



















Contents

   



(Top)
 


1 Indicating optional use of state name  





2 Changing the default state  





3 Slashes and the nobase parameter  





4 See also  














Template:Collapsible option






Afrikaans
Аԥсшәа
العربية
Արեւմտահայերէն

Авар
Azərbaycanca
تۆرکجه
Basa Bali

Banjar
 / Bân-lâm-gú
Беларуская

Български
Bosanski
Буряад
Català
Cebuano
Chi-Chewa
ChiTumbuka
Corsu
Cymraeg
Dansk
الدارجة
Ελληνικά
Español
Esperanto
Euskara
فارسی
Fiji Hindi
Føroyskt
Français
Gaeilge
Gaelg
Galego
ГӀалгӀай


  / Gõychi Konknni
/Hak-kâ-ngî

Հայերեն
ि
Ilokano
Bahasa Indonesia
Jawa


Қазақша
Ikirundi
Kurdî
Ladin
Ladino

Latviešu
Lëtzebuergesch
Luganda
Македонски



مصرى
Bahasa Melayu
Minangkabau
Mirandés
Мокшень


 

Нохчийн
Norsk bokmål
Norsk nynorsk
Occitan
ି
Oʻzbekcha / ўзбекча

Pangasinan
پنجابی
پښتو

Tok Pisin
Português
Română
Русский

سرائیکی
Scots
Shqip

Simple English
سنڌي
Slovenščina
Soomaaliga
کوردی
Српски / srpski
Srpskohrvatski / српскохрватски
Sunda
Svenska
Tagalog
ி
Татарча / tatarça
 


Тоҷикӣ
Türkçe
Türkmençe
Українська
اردو
Vahcuengh
Tiếng Vit


Yorùbá

Zazaki

Batak Toba
 

Edit links
 









Template
Talk
 

















Read
View source
View history
 








Tools
   


Actions  



Read
View source
View history
 




General  



What links here
Related changes
Upload file
Special pages
Permanent link
Page information
Get shortened URL
Download QR code
Wikidata item
 




Print/export  



Download as PDF
Printable version
 




In other projects  



Wikimedia Commons
Wikibooks
Wikiquote
Wikiversity
 
















Appearance
   

 





Permanently protected template

From Wikipedia, the free encyclopedia
 


This template's initial visibility currently defaults to autocollapse, meaning that if there is another collapsible item on the page (anavbox, sidebar, or table with the collapsible attribute), it is hidden apart from its title bar; if not, it is fully visible.

To change this template's initial visibility, the |state= parameter may be used:

{{Collapsible option}} is a utility template provides a standardised message for transclusionontemplate documentaion pages for templates whose collapsibility may be managed by the parameter |state=.

It can be used on either the template page itself (wrapped within <noinclude>...</noinclude> tags), but it is almost always better to place it in the template's {{documentation subpage}}.

Indicating optional use of state name

The |state= parameter used to manage collapsible templates need not always be named explicitly, i.e. {{Template name|state}} can be the same as {{Template name|state=state}}, if the template is coded that way. To indicate this in the {{Collapsible option}} message, add the parameter |statename=optional. This modifies the message so that it reads (if it were used for itself):

This template's initial visibility currently defaults to autocollapse, meaning that if there is another collapsible item on the page (anavbox, sidebar, or table with the collapsible attribute), it is hidden apart from its title bar; if not, it is fully visible.

To change this template's initial visibility, the |state= parameter may be used:

This possibility is enabled by including:

If, however, the template includes collapsible sections within itself (e.g. {{Navbox with collapsible groups}}), then enabling this possibility may introduce ambiguity as regards what is to be collapsed or expanded. In those instances, therefore, the requirement to use |state= should be retained.

Changing the default state

To change the default state {{Collapsible option}} uses, add the parameter |default=collapsedor|default=expanded accordingly. To restore the default, remove any |default= previously included.

The |default=collapsed option must not be used in main article content in mainspace, e.g. to hide tables of information, or to cram extraneous details into infoboxes. (For more information, see Wikipedia:Manual of Style § Scrolling lists and collapsible content.) This option is permissible in navboxes, which are not part of the article content per se.

Slashes and the nobase parameter

If the template name given to {{Collapsible option}} includes a forward-slash (virgule) character – / – then the parameter |nobase= (set to on, true, etc.) will need to be added so that the name is displayed correctly (i.e., so that {{PAGENAME}} rather than the default {{BASEPAGENAME}} is used to display it).

See also


Retrieved from "https://en.wikipedia.org/w/index.php?title=Template:Collapsible_option&oldid=1210815075"

Categories: 
Documentation shared content templates
Wikipedia metatemplates
Hidden category: 
Wikipedia template-protected templates
 



This page was last edited on 28 February 2024, at 13:22 (UTC).

Text is available under the Creative Commons Attribution-ShareAlike License 4.0; additional terms may apply. By using this site, you agree to the Terms of Use and Privacy Policy. Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc., a non-profit organization.



Privacy policy

About Wikipedia

Disclaimers

Contact Wikipedia

Code of Conduct

Developers

Statistics

Cookie statement

Mobile view



Wikimedia Foundation
Powered by MediaWiki