import{p as t,H as e,c as o,h as s,d as n,t as i}from"./p-yZBlG3YQ.js";const c=()=>`verdocs-toggle-button{font-family:"Inter", "Barlow", sans-serif}verdocs-toggle-button button{border:none;outline:none;cursor:pointer;-ms-flex-align:center;align-items:center;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-pack:center;justify-content:center;background:#cccccc;color:#33364b}verdocs-toggle-button button svg{max-width:100%;max-height:100%;fill:#33364b}verdocs-toggle-button button.active{background:#55bc81;color:#f5f5fa}verdocs-toggle-button button.active svg{fill:#f5f5fa}verdocs-toggle-button button:focus{border:none;outline:none}verdocs-toggle-button.size-normal button{width:40px;height:40px;padding:6px;border-radius:4px}verdocs-toggle-button.size-small button{width:34px;height:34px;padding:4px;border-radius:2px}`;const l=t(class t extends e{constructor(t){super();if(t!==false){this.__registerHost()}this.toggle=o(this,"toggle");this.active=false;this.icon=null;this.label=null;this.size="normal";this._active=false}componentWillLoad(){this._active=this.active}handleToggle(t){var e;t.stopPropagation();const o=!this._active;this._active=o;(e=this.toggle)===null||e===void 0?void 0:e.emit({active:o})}render(){return s(n,{key:"6e03f5ae53b791fabe539534349763c1cd550852",class:`size-${this.size}`},this.icon?s("button",{innerHTML:this.icon,class:{active:this._active},onClick:t=>this.handleToggle(t)}):s("button",{class:{active:this._active},onClick:t=>this.handleToggle(t)},this.label))}static get style(){return c()}},[0,"verdocs-toggle-button",{active:[4],icon:[1],label:[1],size:[1],_active:[32]}]);function r(){if(typeof customElements==="undefined"){return}const t=["verdocs-toggle-button"];t.forEach((t=>{switch(t){case"verdocs-toggle-button":if(!customElements.get(i(t))){customElements.define(i(t),l)}break}}))}const a=l;const u=r;export{a as VerdocsToggleButton,u as defineCustomElement};
//# sourceMappingURL=verdocs-toggle-button.js.map