import{r as t,d as i,h as o,a as r}from"./p-a599f720.js";import{c as s,e as a,i as e}from"./p-9811c98c.js";import{S as n}from"./p-af705ed1.js";var c=function(t,i,o,r){var s,a=arguments.length,e=a<3?i:null===r?r=Object.getOwnPropertyDescriptor(i,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)e=Reflect.decorate(t,i,o,r);else for(var n=t.length-1;n>=0;n--)(s=t[n])&&(e=(a<3?s(e):a>3?s(i,o,e):s(i,o))||e);return a>3&&e&&Object.defineProperty(i,o,e),e};const l=class{constructor(o){t(this,o),this.onClose=i(this,"rtkDialogClose",7),this.hideCloseButton=!1,this.disableEscapeKey=!1,this.config=s(),this.iconPack=a,this.t=e(),this.open=!0,this.close=()=>{this.open=!1,this.onClose.emit()},this.keydownListener=t=>{!this.disableEscapeKey&&"Escape"===t.key&&this.open&&this.close()}}connectedCallback(){document.addEventListener("keydown",this.keydownListener)}disconnectedCallback(){document.removeEventListener("keydown",this.keydownListener)}componentDidRender(){this.open&&!this.dialogEl.open&&this.dialogEl.showModal()}render(){return this.open?o(r,null,o("dialog",{ref:t=>this.dialogEl=t,id:"dialog",part:"container",onClose:this.close,onClick:t=>{this.disableEscapeKey||t.target!==this.dialogEl||this.close()},onKeyDown:t=>{this.disableEscapeKey&&"Escape"===t.key&&t.preventDefault()}},o("slot",null),!this.hideCloseButton&&o("rtk-button",{part:"close-button",id:"dismiss-btn",kind:"icon",variant:"ghost",onClick:()=>this.close(),type:"button","aria-label":this.t("dialog.close"),role:"button"},o("rtk-icon",{icon:this.iconPack.dismiss})))):null}};c([n()],l.prototype,"meeting",void 0),c([n()],l.prototype,"config",void 0),c([n()],l.prototype,"states",void 0),c([n()],l.prototype,"iconPack",void 0),c([n()],l.prototype,"t",void 0),l.style=":host{line-height:initial;font-family:var(--rtk-font-family, sans-serif);font-feature-settings:normal;font-variation-settings:normal}p{margin:var(--rtk-space-0, 0px);padding:var(--rtk-space-0, 0px)}:host{word-wrap:break-word;overflow-wrap:break-word}#dialog{position:relative;max-height:100%;max-width:100%;padding:var(--rtk-space-0, 0px);border-width:var(--rtk-border-width-none, 0);border-style:none;background-color:transparent;color:rgb(var(--rtk-colors-text-1000, 255 255 255))}#dialog::backdrop{background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / 0.5);backdrop-filter:blur(12px) saturate(180%)}#dismiss-btn{position:absolute;top:var(--rtk-space-3, 12px);right:var(--rtk-space-3, 12px);z-index:50}::slotted(*){max-width:100%;height:auto;min-height:-moz-fit-content;min-height:fit-content}";export{l as rtk_dialog}