import{r as a,h as e,g as s}from"./p-dfbe004d.js";import{o as r}from"./p-d63f2554.js";import{_ as t}from"./p-8415f806.js";import"./p-fd56940f.js";import"./p-9a7a47e8.js";const i=class{constructor(e){a(this,e)}componentWillLoad(){this.handleSlotChange()}handleSlotChange(){this.hasTitleSlot=!!this.el.querySelector('[slot="title"]')}render(){return e(this.href?"a":"div",{part:"base",class:{card:!0,"card--borderless":this.borderless,"card--no-padding":this.noPadding}},e("slot",null))}get el(){return s(this)}};r(i,["loading"],!1),i.style=":host{display:block;--overflow:visible}.card{font-family:var(--sc-font-sans);overflow:var(--overflow);display:block}.card:not(.card--borderless){padding:var(--sc-card-padding, var(--sc-spacing-large));background:var(--sc-card-background-color, var(--sc-color-white));border:1px solid var(--sc-card-border-color, var(--sc-color-gray-300));border-radius:var(--sc-input-border-radius-medium);box-shadow:var(--sc-shadow-small)}.card:not(.card--borderless).card--no-padding{padding:0}.title--divider{display:none}.card--has-title-slot .card--title{font-weight:var(--sc-font-weight-bold);line-height:var(--sc-line-height-dense)}.card--has-title-slot .title--divider{display:block}::slotted(*){margin-bottom:var(--sc-form-row-spacing)}::slotted(*:first-child){margin-top:0}::slotted(*:last-child){margin-bottom:0 !important}";const d=class{constructor(e){a(this,e)}render(){return e("div",{class:"dashboard-module",part:"base"},!!this.error&&e("sc-alert",{exportparts:"base:error__base, icon:error__icon, text:error__text, title:error__title, message:error__message",open:!!this.error,type:"danger"},e("span",{slot:"title"},t("Error","surecart")),this.error),e("div",{class:"heading",part:"heading"},e("div",{class:"heading__text",part:"heading-text"},e("div",{class:"heading__title",part:"heading-title"},e("slot",{name:"heading"},this.heading)),e("div",{class:"heading__description",part:"heading-description"},e("slot",{name:"description"}))),e("slot",{name:"end"})),e("slot",null))}};d.style=":host{display:block;position:relative}.dashboard-module{display:grid;gap:var(--sc-dashboard-module-spacing, 1em)}.heading{font-family:var(--sc-font-sans);display:flex;flex-wrap:wrap;gap:1em;align-items:center;justify-content:space-between}.heading__text{display:grid;flex:1;gap:calc(var(--sc-dashboard-module-spacing, 1em) / 2)}@media screen and (min-width: 720px){.heading{gap:2em}}.heading__title{font-size:var(--sc-dashbaord-module-heading-size, var(--sc-font-size-x-large));font-weight:var(--sc-dashbaord-module-heading-weight, var(--sc-font-weight-bold));line-height:var(--sc-dashbaord-module-heading-line-height, var(--sc-line-height-dense));white-space:nowrap}.heading__description{font-size:var(--sc-font-size-normal);line-height:var(--sc-line-height-dense);opacity:0.5}";export{i as sc_card,d as sc_dashboard_module}