{{model.id}} {{#if model.enforcementLevel}} {{model.enforcementLevel}} {{/if}}

{{message-error model=model}}
{{#if (and (not-eq model.id "root") (or capabilities.canUpdate capabilities.canDelete))}}
{{input id="edit" type="checkbox" name="navToEdit" class="switch is-rounded is-success is-small" checked=true change=(action (nav-to-route 'vault.cluster.policy.show' model.id replace=true) ) data-test-policy-edit-toggle=true }}
{{/if}}
{{ivy-codemirror value=model.policy valueUpdated=(action (mut model.policy)) options=(hash lineNumbers=true tabSize=2 mode='ruby' theme='hashi' extraKeys=(hash Shift-Enter=(action "savePolicy" model) ) ) }}

You can use Alt+Tab (Option+Tab on MacOS) in the code editor to skip to the next field

{{#each model.additionalAttrs as |attr|}} {{form-field data-test-field attr=attr model=model}} {{/each}}
{{#if capabilities.canUpdate}}
{{/if}}
{{#link-to "vault.cluster.policy.show" model.id replace=true class="button"}} Cancel {{/link-to}}
{{#if (and (not-eq model.id "default") capabilities.canDelete)}} {{#confirm-action buttonClasses="button is-ghost" onConfirmAction=(action "deletePolicy" model) confirmMessage=(concat "Are you sure you want to delete " model.id "?") data-test-policy-delete=true }} Delete {{/confirm-action}} {{/if}}