{{!
  Copyright (c) HashiCorp, Inc.
  SPDX-License-Identifier: BUSL-1.1
}}

<div class={{concat "with-confirmation" (if this.confirming " confirming" "")}} ...attributes>
{{yield}}
<YieldSlot @name="action" @params={{block-params (action "confirm") (action "cancel")}}>
{{#if (or this.permanent (not this.confirming))}}
    {{yield}}
{{/if}}
</YieldSlot>
<YieldSlot @name="dialog" @params={{block-params (action "execute") (action "cancel") @message this.actionName}}>
{{#if this.confirming }}
    {{yield}}
{{/if}}
</YieldSlot>
</div>