import{pseudoSelectors as r}from"./pseudos.js";import{systemProps as s}from"./system.js";import{expandResponsive as t}from"./utils/expand-responsive.js";import{runIfFn as i}from"../../../utils/dist/esm/function.js";import{isString as o,isCssVar as n,isObject as l}from"../../../utils/dist/esm/assertion.js";import e from"../../../../lodash.mergewith/index.js";var a=(r,s)=>r.startsWith("--")&&o(s)&&!n(s),u=(r,s)=>{var t,i;if(null==s)return s;var o=s=>{var t,i;return null==(t=r.__cssMap)||null==(i=t[s])?void 0:i.varRef},n=r=>{var s;return null!=(s=o(r))?s:r},l=s.split(",").map((r=>r.trim())),[e,a]=l;return s=null!=(t=null!=(i=o(e))?i:n(a))?t:n(s)};function m(r){var{configs:s={},pseudos:o={},theme:n}=r;return function r(m,v){void 0===v&&(v=!1);var f=i(m,n),p=t(f)(n),d={};for(var c in p){var j,h,y,g,x,A=p[c],R=i(A,n);c in o&&(c=o[c]),a(c,R)&&(R=u(n,R));var _=s[c];if(!0===_&&(_={property:c}),l(R)){var w;d[c]=null!=(w=d[c])?w:{},d[c]=e({},d[c],r(R,!0))}else{var M=null!=(j=null==(h=_)||null==h.transform?void 0:h.transform(R,n,f))?j:R;M=null!=(y=_)&&y.processResult?r(M,!0):M;var W=i(null==(g=_)?void 0:g.property,n);if(!v&&null!=(x=_)&&x.static){var b=i(_.static,n);d=e({},d,b)}if(W&&Array.isArray(W))for(var k of W)d[k]=M;else W?"&"===W&&l(M)?d=e({},d,M):d[W]=M:l(M)?d=e({},d,M):d[c]=M}}return d}}var v=t=>i=>m({theme:i,pseudos:r,configs:s})(t);export{v as css,m as getCss};
//# sourceMappingURL=css.js.map
