"use strict";const A=require("../../../../../../../_virtual/processPlugins.js");require("../../../../../lodash@4.17.21/node_modules/lodash/lodash.js");const N=require("../../../../../postcss@8.4.14/node_modules/postcss/lib/postcss.js"),W=require("../../../../../postcss@8.4.14/node_modules/postcss/lib/node.js"),K=require("../../../../../lodash@4.17.21/node_modules/lodash/isFunction.js");require("./escapeClassName.js");require("./generateVariantFunction.js");require("./parseObjectStyles.js");require("./prefixSelector.js");require("./wrapWithVariants.js");require("./cloneNodes.js");require("./transformThemeValue.js");require("./nameClass.js");require("./isKeyframeRule.js");const M=require("../../../../../../../_virtual/escapeClassName.js"),T=require("../../../../../../../_virtual/generateVariantFunction.js"),B=require("../../../../../../../_virtual/parseObjectStyles.js"),U=require("../../../../../../../_virtual/prefixSelector.js"),k=require("../../../../../../../_virtual/wrapWithVariants.js"),G=require("../../../../../../../_virtual/cloneNodes.js"),I=require("../../../../../../../_virtual/transformThemeValue.js"),$=require("../../../../../../../_virtual/nameClass.js"),D=require("../../../../../../../_virtual/isKeyframeRule.js"),E=require("../../../../../../../_virtual/lodash.js");Object.defineProperty(A.__exports,"__esModule",{value:!0});A.__exports.default=re;var c=i(E.lodash.exports),f=i(N),L=i(W),z=i(K),H=i(M.__exports),J=i(T.__exports),Q=i(B.__exports),X=i(U.__exports),V=i(k.__exports),Y=i(G.__exports),Z=i(I.__exports),ee=i($.__exports),P=i(D.__exports);function i(a){return a&&a.__esModule?a:{default:a}}function _(a){return Array.isArray(a)?c.default.flatMap(a,t=>t instanceof L.default?t:(0,Q.default)(t)):_([a])}function v(a,t){return f.default.atRule({name:"layer",params:t}).append((0,Y.default)(Array.isArray(a)?a:[a]))}function re(a,t){const j=[],h=[],q=[],y={},p=n=>(0,X.default)(t.prefix,n);function m(n,u){const e={variants:[],respectPrefix:!0,respectImportant:!0};u=Array.isArray(u)?Object.assign({},e,{variants:u}):c.default.defaults(u,e);const r=f.default.root({nodes:_(n)});r.walkRules(s=>{u.respectPrefix&&!(0,P.default)(s)&&(s.selector=p(s.selector)),u.respectImportant&&t.important&&(s.__tailwind={...s.__tailwind,important:t.important})}),q.push(v((0,V.default)(r.nodes,u.variants),"utilities"))}const d=(n,u)=>n?c.default.get(t,n,u):t;return a.forEach(n=>{n.__isOptionsFunction&&(n=n()),((0,z.default)(n)?n:c.default.get(n,"handler",()=>{}))({postcss:f.default,config:d,theme:(e,r)=>{const[s,...o]=c.default.toPath(e),l=d(["theme",s,...o],r);return(0,Z.default)(s)(l)},corePlugins:e=>Array.isArray(t.corePlugins)?t.corePlugins.includes(e):d(`corePlugins.${e}`,!0),variants:(e,r)=>Array.isArray(t.variants)?t.variants:d(`variants.${e}`,r),e:H.default,prefix:p,addUtilities:m,matchUtilities:(e,{values:r,variants:s,respectPrefix:o,respectImportant:l})=>{let C=Object.entries(r||{}),O=Object.entries(e).flatMap(([b,R])=>C.map(([S,g])=>{let x=R(g,{includeRules(w,F){m(w,F)}});return x?{[(0,ee.default)(b,S)]:x}:null}).filter(Boolean));m(O,{variants:s,respectPrefix:o,respectImportant:l})},addComponents:(e,r)=>{const s={variants:[],respectPrefix:!0};r=Array.isArray(r)?Object.assign({},s,{variants:r}):c.default.defaults(r,s);const o=f.default.root({nodes:_(e)});o.walkRules(l=>{r.respectPrefix&&!(0,P.default)(l)&&(l.selector=p(l.selector))}),h.push(v((0,V.default)(o.nodes,r.variants),"components"))},addBase:e=>{j.push(v(_(e),"base"))},addVariant:(e,r,s={})=>{y[e]=(0,J.default)(r,s)}})}),{base:j,components:h,utilities:q,variantGenerators:y}}
//# sourceMappingURL=processPlugins.js.map
