<fieldset>
    <legend>{{ localize "DND5E.ItemClassDetails" }}</legend>

    {{!-- Identifier --}}
    <div class="form-group">
        <label>{{ localize "DND5E.Identifier" }}</label>
        <div class="form-fields">
            {{ formInput fields.identifier value=source.identifier placeholder=item.identifier }}
        </div>
        <p class="hint">
            {{{ localize "DND5E.ClassIdentifierHint" identifier=item.identifier }}}
            {{ localize "DND5E.IdentifierError" }}
        </p>
    </div>

    {{!-- Hit Dice --}}
    <div class="form-group split-group">
        <label>{{ localize "DND5E.CLASS.FIELDS.hd.label" }}</label>
        <div class="form-fields">

            {{!-- Denomination --}}
            {{ formField fields.hd.fields.denomination value=source.hd.denomination options=hitDieOptions
                         label="DND5E.Denomination" localize=true classes="label-top" rootId=partId }}

            {{!-- Spent --}}
            {{ formField fields.hd.fields.spent value=source.hd.spent placeholder="0" localize=true label="DND5E.Spent"
                         classes="label-top" rootId=partId }}
        </div>
    </div>

    {{#if source.hd.additional}}
    {{ formField fields.hd.fields.additional value=source.hd.additional localize=true rootId=partId }}
    {{/if}}

    {{!-- Class Properties --}}
    {{ formField fields.properties options=properties.options input=inputs.createMultiCheckboxInput stacked=true
                 classes="checkbox-grid checkbox-grid-3" }}
</fieldset>

<fieldset>
    <legend>{{ localize "DND5E.CLASS.Multiclass.Title" }}</legend>

    {{!-- Primary Ability --}}
    {{ formField fields.primaryAbility.fields.value value=source.primaryAbility.value options=primaryAbilities
                 rootId=partId }}

    {{!-- All Required --}}
    {{#if (gt source.primaryAbility.value.length 1)}}
    {{ formField fields.primaryAbility.fields.all value=source.primaryAbility.all input=inputs.createCheckboxInput
                 rootId=partId }}
    {{/if}}
</fieldset>
