HTML Variants Syntaxes
Last modified by Vincent Massol on 2018/10/14 11:54
This page gathers the documentation about the HTML variants syntaxes and their specificities.
Annotated XHTML
This syntax puts supplementary information in the rendered XHTML in order to be used by the CKEditor.
Metadata Annotation
Metadata provided in the page structure (XDOM) are now output when using the Annotated XHTML renderer, using the following rules:
- it produces a container with the class xwiki-metadata-container
- the container is a div or a span depending if the metadata is an inline context or not
- all metadata are provided in dedicated attribute named on the schema data-xwiki-key where key is the metadata name.
Then the following XDOM:
beginDocument
beginMetaData [[syntax]=[xwiki/2.0]]
beginParagraph
onWord [Heading]
endParagraph
endMetaData [[syntax]=[xwiki/2.0]]
endDocument
beginMetaData [[syntax]=[xwiki/2.0]]
beginParagraph
onWord [Heading]
endParagraph
endMetaData [[syntax]=[xwiki/2.0]]
endDocument
will be interpreted like this:
<div class="xwiki-metadata-container" data-xwiki-syntax="xwiki/2.0">
<span>Heading</span>
</div>
<span>Heading</span>
</div>
Macro Annotation