Wiki source code of Available Skins
Last modified by superadmin on 2026/11/25 21:34
Show last authors
| author | version | line-number | content |
|---|---|---|---|
| 1 | To choose which skin a wiki, a page or a user gets, see [[Skin Levels>>doc:documentation.xs.admin.look-feel.skins.levels.WebHome]]; for the files each skin is built from, see [[Skin Files>>doc:documentation.xs.admin.look-feel.skins.files.WebHome]]. | ||
| 2 | |||
| 3 | == The skins shipped with XWiki == | ||
| 4 | |||
| 5 | XWiki ships one skin, **Flamingo**, and one wiki skin page built on it, **XWiki.DefaultSkin**. | ||
| 6 | |||
| 7 | An out-of-the-box wiki does not use ##flamingo## directly. Its //Skin// setting holds ##XWiki.DefaultSkin##, a page shipped with the wiki whose //Base Skin// is ##flamingo##. That is what the //Customize// button in the administration opens, and what the //Skin// field already contains before anyone changes it. | ||
| 8 | |||
| 9 | Other skins are distributed as extensions: the [[All Extensions>>doc:extensions:ExtensionCode.AllExtensions.WebHome]] listing on the Extensions wiki has a //Category// filter whose //Skin// value shows them. You may also [[Create a Skin Extension>>documentation.xs.dev.skin-extensions.create.WebHome]]. | ||
| 10 | |||
| 11 | {{info}} | ||
| 12 | The themes you manage in Themes are Flamingo variations. They only affect Flamingo, and skins that are ultimately based on Flamingo through their Base Skin setting. Skins based on something else won’t use them. | ||
| 13 | {{/info}} | ||
| 14 | |||
| 15 | == The three kinds of skin == | ||
| 16 | |||
| 17 | |=Kind |=Where it lives |=How it is named | ||
| 18 | |Filesystem skin |One directory per skin, under ##webapps/xwiki/skins/## on the server |By its directory name, for example ##flamingo## | ||
| 19 | |Wiki skin |A wiki page holding an ##XWiki.XWikiSkins## object |By its page reference, for example ##XWiki.DefaultSkin## | ||
| 20 | |Extension skin |A ##skins## folder inside a JAR installed on the wiki, with one directory per skin |By its directory name | ||
| 21 | |||
| 22 | A skin does not have to define everything. Its //Base Skin// names the skin it falls back to for every template, stylesheet or image it does not provide itself, which is how ##XWiki.DefaultSkin## can consist of almost nothing and still render a complete interface. | ||
| 23 | |||
| 24 | A wiki skin reaches an instance the way any other pages do: by importing a XAR, or by installing it with the Extension Manager. | ||
| 25 | |||
| 26 | == The settings of a wiki skin == | ||
| 27 | |||
| 28 | A wiki skin holds the equivalent of ##skin.properties## in the ##XWiki.XWikiSkins## object on its page, shown as //Skin Properties// when the skin page is opened for editing: | ||
| 29 | |||
| 30 | {{image reference="skin-document-properties.png" size="extra" alt="The Skin Properties block of the XWiki.DefaultSkin page, holding the Name, Base Skin, Logo and Output Syntax fields"/}} | ||
| 31 | |||
| 32 | |=Setting |=What it holds | ||
| 33 | |Name |The name of the skin. It is the title the skin page is displayed under. | ||
| 34 | |Base Skin |The skin this one falls back to. It holds ##flamingo## on ##XWiki.DefaultSkin##. | ||
| 35 | |Logo |An attachment of the skin page to use as the logo, picked with the //Choose an attachment// button. | ||
| 36 | |Output Syntax |The syntax the skin produces, either //HTML 5// for a recent skin or //XHTML 1.0// for an old one. XWiki reads it to pair the skin with the renderer that produces valid markup for it. | ||
| 37 | |||
| 38 | //Output Syntax// is left unset on ##XWiki.DefaultSkin##, and a skin that sets none takes the one its //Base Skin// declares. | ||
| 39 | |||
| 40 | {{info}} | ||
| 41 | The //Logo// setting is used only when the color theme in use declares no logo of its own. The color theme an out-of-the-box wiki uses declares one, so the logo displayed comes from the color theme and this setting has no visible effect. Change the logo in the color theme instead. | ||
| 42 | {{/info}} | ||
| 43 | |||
| 44 | The same object carries six more properties, listed under //Deprecated properties// on the skin page: an older way of replacing a template, which [[Customize a Skin>>doc:documentation.xs.admin.look-feel.skins.customize.WebHome]] explains why not to use. | ||
| 45 | |||
| 46 | == How a skin is identified == | ||
| 47 | |||
| 48 | The //Skin// field in the administration and the ##skin## property of a user both take the same kind of value: either the **directory name** of a filesystem skin, such as ##flamingo##, or the **page reference** of a wiki skin, such as ##XWiki.DefaultSkin##. | ||
| 49 | |||
| 50 | {{info}} | ||
| 51 | Skin names are case-sensitive. The value is used exactly as written, either as a path under ##webapps/xwiki/skins/## or as a page reference, and both are case-sensitive. | ||
| 52 | {{/info}} |