Hello,
Following Vertical Layout standards [1], I've written the following to
display a form (XE 4.3 standalone):
#set($class = $obj.xWikiClass)
{{html wiki="true"}}
<form action="." class="xform" name="form_server">
#foreach($prop in $class.properties)
<dl>
<dt><label for="MySpave.MyClass_0_$prop.name
">$prop.prettyName</label></dt>
<dd>$doc.display($prop.getName())</dd>
</dl>
#end
</form>
{{/html}}
In view mode, labels are correctly displayed uppercase, but in inline edit
mode, they switch to lowercase bold, which is not very nice.
I investigated, and in inline mode my <form> is removed, and replaced by
the encapsulating "inline" <form>. So to fix that, I decorated my form
with
a div with class "xform". Is it the right way to do that ?
If so, I think the comment from [1] is not complete:
"Obs: The CSS classes have as parent the .xform class. This is supposed to
be used on the form tag, but if the styling is done inside dynamically
generated structures it can be used on other elements, like divs, as long
as the element remains the parent for the other form components."
It would not really be limited to dynamically generated structures, but
also to inline edit mode.
BR,
Jeremie
[1] -
http://platform.xwiki.org/xwiki/bin/view/DevGuide/VerticalForms