import{h,Host}from"@stencil/core";import{__}from"@wordpress/i18n";export class ScUpgradeRequired{constructor(){this.size="small",this.required=!0,this.open=!1}render(){var e;return this.required?h(Host,{onClick:()=>this.open=!0},h("span",{class:"trigger"},h("span",{class:"trigger__disabled"},h("slot",null,h("sc-premium-badge",null)))),h("sc-dialog",{label:__("Boost Your Revenue","surecart"),open:this.open,onScRequestClose:()=>(this.open=!1,!0),style:{"--width":"21rem",fontSize:"15px","--body-spacing":"2rem"}},h("span",{class:"dialog__title",slot:"label"},h("sc-icon",{name:"zap"}),h("span",null,__("Boost Your Revenue","surecart"))),h("slot",{name:"content"},h("p",null,__("Unlock revenue boosting features when you upgrade your plan!","surecart"))),h("sc-button",{href:`https://app.surecart.com/plans?switch_account_id=${null===(e=null===window||void 0===window?void 0:window.scData)||void 0===e?void 0:e.account_id}`,type:"primary",target:"_blank",full:!0},__("Upgrade Now","surecart"),h("sc-icon",{name:"arrow-right",slot:"suffix"})))):h(Host,null,h("slot",null))}static get is(){return"sc-upgrade-required"}static get encapsulation(){return"shadow"}static get originalStyleUrls(){return{$:["sc-upgrade-required.scss"]}}static get styleUrls(){return{$:["sc-upgrade-required.css"]}}static get properties(){return{size:{type:"string",mutable:!1,complexType:{original:"'small' | 'medium' | 'large'",resolved:'"large" | "medium" | "small"',references:{}},required:!1,optional:!1,docs:{tags:[],text:"The tag's size."},attribute:"size",reflect:!0,defaultValue:"'small'"},required:{type:"boolean",mutable:!1,complexType:{original:"boolean",resolved:"boolean",references:{}},required:!1,optional:!1,docs:{tags:[],text:"Is this required?"},attribute:"required",reflect:!0,defaultValue:"true"},open:{type:"boolean",mutable:!0,complexType:{original:"boolean",resolved:"boolean",references:{}},required:!1,optional:!1,docs:{tags:[],text:"Whether to render upgrade modal by default"},attribute:"open",reflect:!1,defaultValue:"false"}}}}