Template:H/doc

h, sh, and ssh are still experimental templates for managing chapter headings in texts. Their philosophy are to be as simple as possible, to mirror well the use of direct formatting (like c and xl), so that they can be second nature for 90% of texts. For the remainder there probably is no general solution, instead of trying to kinda sorta half-way make something, these templates simply do not even try.

The templates provide some simple basic styling that roughly corresponds to typical styling that is common in books, but you are expected to create a work-specific stylesheet to tweak the headings so they match the actual style of the book. The stylesheet can do anything that CSS permits (well, what MediaWiki's more limited Sanitized CSS subset permits), but if you do much more than tweak alignment, font size, and font style (bold, italic, underline, etc.) you should probably reconsider. That you can do arbitrarily complex things doesn't mean it's a good idea to do so.

Usage
If your text contains a single chapter heading then just slap a h around it.

If there are two levels, then add a subheading too:

And for texts with parts, chapters, and sections you can use a subsubheading:

Styling
Styling is done using page styles, targeting the three classes:,  , and. The basic style for the three headings is:

(The sizes correspond to the sizes used for regular text, larger, and x-larger respectively).

To override these you could use something like this:

This would make both h and sh extra large (144%, or xl) and bold; and the ssh merely large but aligned to the left instead of the center.

Multiple heading styles in one work
Some texts use multiple heading styles within a single published unit (i.e. the thing for which an Index: is created, and for which there is only one stylesheet in effect). In these instances you can call the templates with a custom class name.

If the template gets two arguments instead of one, the first one is treated as a custom class and added to the output. In the example above that would be  (the underscore is to avoid collisions with other templates).