{# @description A dialog laid out as a card, built around c-mvp.card inside daisy-cotton's c-modal. It holds no form of its own, so it works inside one. #} {# @prop id:text | description:"Dialog id, used to open/close it via showModal()/close()." #} {# @prop title:text | description:"The card's heading, and the dialog's accessible name." #} {# @prop size:select['sm','md','lg','xl','full'] | default:"md" | description:"Dialog width." #} {# @prop position:select['top','bottom','start','end'] | description:"Dialog placement; unset uses daisyUI's centred placement." #} {# @prop closable:boolean | description:"Show a close button in the top corner." #} {# @prop class:text | description:"Extra classes appended to the inner card surface." #} {# @slot The dialog's body content. — Forwarded to the inner card's default slot. #} {# @slot:actions — Forwarded to the inner card's actions slot. #} {# @slot:footer — Forwarded to the inner card's footer slot. #} {# @slot:footer_end — Forwarded to the inner card's footer_end slot. #} {% comment %} The title names the dialog through aria-label and is drawn once, by the card. Giving c-modal a title too would draw a second heading. c-modal draws its close button before the box's content, and the card is positioned, so without a stacking order the card paints over the button and takes its clicks: [&>.btn]:z-10 lifts the box's own button above it. {% endcomment %} {{ slot }} {% if actions %}{{ actions }}{% endif %} {% if footer %}{{ footer }}{% endif %} {% if footer_end %}{{ footer_end }}{% endif %}