import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
import { o as openWormhole } from './consumer.js';
import { d as defineCustomElement$4 } from './sc-button2.js';
import { d as defineCustomElement$3 } from './sc-icon2.js';
import { d as defineCustomElement$2 } from './sc-spinner2.js';

const scCartFormSubmitCss = "sc-order-submit{display:block;width:auto}";

const ScCartFormSubmit$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
  constructor() {
    super();
    this.__registerHost();
    /** The button type. */
    this.type = 'primary';
    /** The button's size. */
    this.size = 'medium';
    /** Show a full-width button. */
    this.full = true;
  }
  render() {
    return (h("sc-button", { submit: true, type: this.type, size: this.size, full: this.full, loading: this.busy, disabled: this.busy }, !!this.icon && h("sc-icon", { name: this.icon, slot: "prefix" }), h("slot", null)));
  }
  static get style() { return scCartFormSubmitCss; }
}, [4, "sc-cart-form-submit", {
    "busy": [4],
    "type": [513],
    "size": [513],
    "full": [4],
    "icon": [1]
  }]);
openWormhole(ScCartFormSubmit$1, ['busy'], false);
function defineCustomElement$1() {
  if (typeof customElements === "undefined") {
    return;
  }
  const components = ["sc-cart-form-submit", "sc-button", "sc-icon", "sc-spinner"];
  components.forEach(tagName => { switch (tagName) {
    case "sc-cart-form-submit":
      if (!customElements.get(tagName)) {
        customElements.define(tagName, ScCartFormSubmit$1);
      }
      break;
    case "sc-button":
      if (!customElements.get(tagName)) {
        defineCustomElement$4();
      }
      break;
    case "sc-icon":
      if (!customElements.get(tagName)) {
        defineCustomElement$3();
      }
      break;
    case "sc-spinner":
      if (!customElements.get(tagName)) {
        defineCustomElement$2();
      }
      break;
  } });
}
defineCustomElement$1();

const ScCartFormSubmit = ScCartFormSubmit$1;
const defineCustomElement = defineCustomElement$1;

export { ScCartFormSubmit, defineCustomElement };
