<tal:block i18n:domain="nive">

<div tal:condition="field.widget.hidden"
     tal:content="structure field.serialize(cstruct)">
</div>

<div tal:condition="not field.widget.hidden"
     id="item-${field.name}"
     class="${field.error and (field.widget.form.widget.error_class or field.widget.error_class)} control-group">

    <label tal:condition="field.widget.category != 'structural'"
           tal:content="field.title"
           class="control-label ${'required' if field.required else ''} ${field.error and (field.widget.form.widget.error_class or field.widget.error_class)}"
           for="${field.oid}"></label>

    <div tal:on-error="nothing"
            tal:condition="field.schema.configuration.settings.preface"
            tal:content="structure field.schema.configuration.settings.preface" class="preface"></div>

    <span tal:replace="structure field.serialize(cstruct)"/>
    <div tal:condition="field.error"
         tal:repeat="msg field.error.messages()"
         class="help-block">
         <span class="glyphicon glyphicon-remove form-control-feedback"></span>
         ${msg}</div>

    <p tal:content="structure field.description" class="help-block"></p>
    
</div>

</tal:block>