Card configuration confirm

Hi, I need some help to adjust the code below.

I want the pop up for confirm only on the turn on (open) , Not on turn off (close)

show_name: true
show_icon: true
type: custom:button-card
entity: input_boolean.gate_open_closed_switch
state:
  - value: 'on'
    color: red
    icon: mdi:gate-arrow-right
    styles:
      icon:
        - filter: opacity(100%)
        - animation: blink 2s ease infinite
  - value: 'off'
    color: green
    icon: mdi:gate
tap_action:
  action: toggle
  service: input_boolean.gate_open_closed_switch.switch.turn_on
  confirmation:
    text: Confirm Open?
  entity: input_boolean.gate_open_closed_switch
name: Front Gate

How would that work?

Thanks

You would need two buttons, one for open and one for close, instead of a single toggle button.

To add to @tom_l, you could easily create a conditional card to show only one of the two buttons depending on the state of the gate. I use this method of dual buttons with confirmations and conditional cards for several things and it works very well.

Is it possible to put the text confirm conditional on an entity status.