Popup bei Toröffnung

Hallo, ich komm leider nicht weiter hier, bei einer Rasterkonfiguration funktioniert der Code nicht für ein Popup mit einer Bestätigung für Tor 2. Kann mir bitte jemand sagen wie ich das konfigurieren muss? Vielen Dank!

square: false
type: grid
cards:
  - show_name: true
    show_icon: true
    type: button
    tap_action:
      action: toggle
    entity: lock.hauseingang
    show_state: true
    icon_height: '-8px'
    name: Haus
    hold_action:
      action: none
  - show_name: true
    show_icon: true
    type: button
    tap_action:
      action: toggle
    entity: lock.kellereingang
    name: Keller
    show_state: true
    hold_action:
      action: none
  - show_name: true
    show_icon: true
    type: button
    entity: switch.tor_1
    show_state: true
    hold_action:
      action: none
  - show_name: true
    show_icon: true
    type: button
    entity: switch.tor_2
    name: Tor 2
    show_state: true
    tap_action:
      action: call-service
      service: switch.turn_on
      service_data:
        entity_id: switch.tor_2
    confirmation:
      text: Sicher Tor 2 öffnen?
    hold_action:
      action: none
columns: 4

ChatGPT hat ein paar kleinere Korrekturen vorgenommen und ich hab die Abfrage für bei Tor 2 getestet bei mir, geht (ich hab mir eine Lampe nach Nachfrage einschalten lassen). Mein Tipp bei Syntaxfragen: Einmal kurz von ChatGPT Homeassistant durchprüfen lassen und dann vor- und nachher vergleichen.

square: false
type: grid
columns: 4
cards:
  - show_name: true
    show_icon: true
    type: button
    tap_action:
      action: toggle
    entity: lock.hauseingang
    show_state: true
    icon_height: '-8px'
    name: Haus
    hold_action:
      action: none
  - show_name: true
    show_icon: true
    type: button
    tap_action:
      action: toggle
    entity: lock.kellereingang
    name: Keller
    show_state: true
    hold_action:
      action: none
  - show_name: true
    show_icon: true
    type: button
    entity: switch.tor_1
    show_state: true
    hold_action:
      action: none
  - show_name: true
    show_icon: true
    type: button
    entity: switch.tor_2
    name: Tor 2
    show_state: true
    tap_action:
      action: call-service
      service: switch.turn_on
      service_data:
        entity_id: switch.tor_2
      confirmation:
        text: Sicher Tor 2 öffnen?
    hold_action:
      action: none

super danke es funktioniert, aber meine Frage was war der Fehler??

Freut mich aber ich schaus mir nicht mehr im Detail an, geh mal den Hinweisen von ChatGPT nach:

Summary:

  • Corrected square: false to be outside the card configuration.
  • Fixed the indentation and format.
  • Adjusted the icon_height value to be a positive number.

Ich nehme gern das Tool WinMerge und lasse vorher/nachher vergleichen und so sehe ich die Änderungen.