-- DreamStack Dialog Component
-- Modal with overlay, title, slot content, and close button

import { Button } from "./button"

export component Dialog(title, open, onClose) =
  when open ->
    column [
      column [
        row [
          text title { variant: "title" }
          Button { label: "✕", variant: "ghost", onClick: onClose }
        ]
        slot
      ] { variant: "dialog-panel" }
    ] { variant: "dialog-overlay" }
