import{r as registerInstance,h as h$1}from"./index-38ad4957.js";import{n as h}from"./dom-context-hooks.module-50442785.js";var sqmFormMessageCss="sl-alert::part(base){border:var(--sqm-border-thickness) solid;border-radius:var(--sqm-border-radius-normal);font-family:var(--sqm-primary-font)}.Error::part(base){color:var(--sqm-danger-color-text);background-color:var(--sqm-danger-color-background);border-color:var(--sqm-danger-color-border);font-size:14px}.Error #icon{color:var(--sqm-danger-color-icon);font-size:24px}.Warning::part(base){color:var(--sqm-warning-color-text);background-color:var(--sqm-warning-color-background);border-color:var(--sqm-warning-color-border)}.Warning #icon{color:var(--sqm-warning-color-icon);font-size:24px}.Success::part(base){color:var(--sqm-success-color-text);background-color:var(--sqm-success-color-background);border-color:var(--sqm-success-color-border)}.Success #icon{color:var(--sqm-success-color-icon);font-size:24px}.Info::part(base){color:var(--sqm-informative-color-text);background-color:var(--sqm-informative-color-background);border-color:var(--sqm-informative-color-border)}.Info #icon{color:var(--sqm-informative-color-icon);font-size:24px}.Transparent::part(base){background-color:transparent;border:none;color:var(--sqm-text);margin-left:-20px}::slotted(*){margin:0}::slotted(*[part=alert-title]){font-size:16px;font-weight:bold}::slotted(*[part=alert-description]),::slotted(*[part=erroralert-text]){font-size:14px}";var FormMessage=function(){function r(r){registerInstance(this,r);this.ignored=true;this.loading=false;this.transparent=false;h(this)}r.prototype.disconnectedCallback=function(){};r.prototype.render=function(){if(this.loading){return h$1("sqm-skeleton",{height:"90px",width:"100%"})}if(this.type==="error"){return h$1("sl-alert",{exportparts:"base: erroralert-base, icon:erroralert-icon",class:"Error "+(this.transparent?"Transparent":""),type:"danger",open:true},h$1("sl-icon",{id:"icon",slot:"icon",name:""+(this.icon?this.icon:"exclamation-octagon")}),h$1("slot",null))}else if(this.type==="info"){return h$1("sl-alert",{id:"icon",exportparts:"base: infoalert-base, icon:infoalert-icon",class:"Info "+(this.transparent?"Transparent":""),type:"info",open:true},h$1("sl-icon",{id:"icon",slot:"icon",name:""+(this.icon?this.icon:"info-circle")}),h$1("slot",null))}else if(this.type==="warning"){return h$1("sl-alert",{exportparts:"base: warningalert-base, icon:warningalert-icon",class:"Warning "+(this.transparent?"Transparent":""),type:"warning",open:true},h$1("sl-icon",{id:"icon",slot:"icon",name:""+(this.icon?this.icon:"exclamation-triangle")}),h$1("slot",null))}else{return h$1("sl-alert",{exportparts:"base: successalert-base, icon:successalert-icon",class:"Success "+(this.transparent?"Transparent":""),type:"success",open:true},h$1("sl-icon",{id:"icon",slot:"icon",name:""+(this.icon?this.icon:"check2-circle")}),h$1("slot",null))}};return r}();FormMessage.style=sqmFormMessageCss;var Skeleton=function(){function r(r){registerInstance(this,r);this.ignored=true;this.height="100%";this.width="100%";this.vanillaStyle="\n  sl-skeleton::part(indicator) {\n    --sheen-color: var(--sqm-skeleton-animation-background);\n    --color: var(--sqm-skeleton-background);\n    border-radius: var(--sqm-border-radius-normal);\n  }\n\n  sl-skeleton::part(base) {\n    height:"+this.height+";\n    width:"+this.width+";\n  }\n\n  :host{\n    display: block;\n  }\n\n  :host([hidden]) {\n    display: none;\n  }\n  "}r.prototype.disconnectedCallback=function(){};r.prototype.render=function(){return h$1("div",null,h$1("style",{type:"text/css"},this.vanillaStyle),h$1("sl-skeleton",null))};return r}();export{FormMessage as sqm_form_message,Skeleton as sqm_skeleton};