import { r as registerInstance, h, H as Host } from './index-fd4790f6.js';
import { _ as __ } from './default-i18n-2e663329.js';
import './index-53ddb833.js';
import './index-6db066f7.js';

const scUpgradeRequiredCss = ":host{display:inline-block;color:var(--sc-color-gray-900);cursor:pointer}p{font-size:var(--sc-font-size-medium);font-weight:var(--sc-font-weight-normal);margin:0 0 var(--sc-spacing-medium) 0;line-height:var(--sc-line-height-dense);white-space:normal}.trigger{pointer-events:auto}.trigger__disabled{pointer-events:none}.dialog__title{display:flex;gap:0.5em;align-items:center}.dialog__title sc-icon{font-size:18px;width:22px;stroke-width:4;color:var(--sc-color-primary-500)}";

const ScUpgradeRequired = class {
  constructor(hostRef) {
    registerInstance(this, hostRef);
    /** The tag's size. */
    this.size = 'small';
    this.required = true;
    this.open = false;
  }
  render() {
    if (!this.required) {
      return (h(Host, null, h("slot", null)));
    }
    return (h(Host, { onClick: () => (this.open = true) }, 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 = false), 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("p", null, __('Unlock revenue boosting features when you upgrade your plan!', 'surecart')), h("sc-button", { href: "https://app.surecart.com/billing", type: "primary", target: "_blank", full: true }, __('Upgrade Now', 'surecart'), h("sc-icon", { name: "arrow-right", slot: "suffix" })))));
  }
};
ScUpgradeRequired.style = scUpgradeRequiredCss;

export { ScUpgradeRequired as sc_upgrade_required };
