const r=r=>!!r.shadowRoot&&!!r.attachShadow;const e=(r,e)=>{const t=r._original||r;return{_original:r,emit:n(t.emit.bind(t),e)}};const n=(r,e=0)=>{let n;return(...t)=>{clearTimeout(n);n=setTimeout(r,e,...t)}};const t=(r,e)=>{if(!r)return undefined;const n=r.trim();if(n==="")return undefined;if((e===null||e===void 0?void 0:e.semanticMap)&&e.semanticMap[n]){return e.semanticMap[n]}if(n.startsWith("var("))return n;if(n.startsWith("--"))return`var(${n})`;return n};const o=(r,e)=>{if(!r)return{};const n={primary:"var(--pine-color-text-primary)",secondary:"var(--pine-color-text-secondary)",neutral:"var(--pine-color-text-neutral)",accent:"var(--pine-color-text-accent)",danger:"var(--pine-color-text-danger)",info:"var(--pine-color-text-info)",success:"var(--pine-color-text-success)",warning:"var(--pine-color-text-warning)"};const o=Object.assign(Object.assign({},n),e||{});const c=t(r,{semanticMap:o});if(!c)return{};return{"--color":c}};export{e as d,r as h,t as n,o as s};
//# sourceMappingURL=p-tJa4KYNO.js.map