<fieldset class="one-column" data-key="cost">
    <legend>
        Cost
        <a><i class="fa-solid fa-plus icon-button" data-action="addElement"></i></a>
    </legend>
    {{#each source as |cost index|}}
        <div class="nest-inputs">
            {{formField ../fields.scalable label="Scalable" value=cost.scalable name=(concat "cost." index ".scalable") classes="checkbox"}}
            {{formField ../fields.key choices=(@root.disableOption index @root.costOptions ../source) label="Resource" value=cost.key name=(concat "cost." index ".key") localize=true blank=false}}
            {{formField ../fields.value label="Amount" value=cost.value name=(concat "cost." index ".value")}}
            {{formField ../fields.step label="Step" value=cost.step name=(concat "cost." index ".step") disabled=(not cost.scalable)}}
            <a class="btn" data-tooltip="{{localize "CONTROLS.CommonDelete"}}" data-action="removeElement" data-index="{{index}}"><i class="fas fa-trash"></i></a>
        </div>
    {{/each}}
</fieldset>