@salty-css/webpack 0.0.1-alpha.26 → 0.0.1-alpha.260
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +469 -26
- package/index-Cpurtg_y.js +706 -0
- package/index-DBDB_Jqo.cjs +46 -0
- package/index.cjs +1 -15
- package/index.d.ts +2 -1
- package/index.js +24 -214
- package/loader.cjs +1 -0
- package/loader.js +8 -0
- package/package.json +9 -4
@@ -0,0 +1,46 @@
|
|
1
|
+
"use strict";var Vt=Object.defineProperty;var Mt=(e,t,s)=>t in e?Vt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var et=(e,t,s)=>Mt(e,typeof t!="symbol"?t+"":t,s);const zt=require("esbuild"),Rt=require("child_process"),c=require("path"),p=require("fs"),bt=require("fs/promises"),Z=require("winston"),ft=require("typescript");var ut=typeof document<"u"?document.currentScript:null;function Wt(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const s in e)if(s!=="default"){const n=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(t,s,n.get?n:{enumerable:!0,get:()=>e[s]})}}return t.default=e,Object.freeze(t)}const jt=Wt(zt),$t=e=>String.fromCharCode(e+(e>25?39:97)),Jt=(e,t)=>{let s="",n;for(n=Math.abs(e);n>52;n=n/52|0)s=$t(n%52)+s;return s=$t(n%52)+s,s.length<t?s=s.padStart(t,"a"):s.length>t&&(s=s.slice(-t)),s},At=(e,t)=>{let s=t.length;for(;s;)e=e*33^t.charCodeAt(--s);return e},I=(e,t=5)=>{const s=At(5381,JSON.stringify(e))>>>0;return Jt(s,t)};function z(e){return e?typeof e!="string"?z(String(e)):e.replace(/[\s.]/g,"-").replace(/[A-Z](?:(?=[^A-Z])|[A-Z]*(?=[A-Z][^A-Z]|$))/g,(t,s)=>(s>0?"-":"")+t.toLowerCase()):""}const It=e=>t=>{if(typeof t!="string"||!e)return;let s=t;const n=[];return Object.values(e).forEach(o=>{const{pattern:r,transform:i}=o;s=s.replace(r,d=>{const{value:g,css:y}=i(d);return y&&n.push(y),g})}),{transformed:s,additionalCss:n}},Ft=e=>t=>typeof t!="string"||!/\{[^{}]+\}/g.test(t)?void 0:{transformed:t.replace(/\{([^{}]+)\}/g,(...o)=>{const r=z(o[1].replaceAll(".","-"));return r.startsWith("-")?`-${r}`:`var(--${r})`})},qt=Ft(),Gt=e=>t=>{const{screenSize:s,axis:n="horizontal",minMultiplier:o=.5,maxMultiplier:r=1.5}=e,i=Math.round(t/s*1e4)/100,d=n==="vertical"?"vh":"vw",g=Math.round(o*t),y=Math.round(r*t);return`clamp(${g}px, ${i}${d}, ${y}px)`},Ht=["top","right","bottom","left","min-width",/.*width.*/,/^[^line]*height.*/,/padding.*/,/margin.*/,/border.*/,/inset.*/,/.*radius.*/,/.*spacing.*/,/.*gap.*/,/.*indent.*/,/.*offset.*/,/.*size.*/,/.*thickness.*/,/.*font-size.*/],Lt=(e,t,s)=>{if(Ht.some(o=>typeof o=="string"?o===e:o.test(e))){const o="px";if(o.startsWith("viewport-clamp:"))try{const i=o.split(":")[1];return Gt({screenSize:parseInt(i)})(Number(t))}catch(i){throw console.error(i),new Error(`Invalid viewport-clamp value: ${o}`)}return`${t}${o}`}return`${t}`},Qt=["Webkit","Moz","ms","O"],Kt=e=>e.startsWith("-")?e:Qt.some(t=>e.startsWith(t))?`-${z(e)}`:z(e),st=async(e,t="",s,n=!1)=>{if(!e)throw new Error("No styles provided to parseStyles function!");const o=new Set,r=Object.entries(e),i=async([m,u])=>{const $=m.trim().replace(/^\?+/g,""),P=Kt($),v=(k,W=";")=>`${P}:${k}${W}`,O={scope:t,config:s};if(typeof u=="function")return i([m,u(O)]);if(u instanceof Promise)return i([m,await u]);if(typeof u=="object"){if(!u)return;if(u.isColor)return v(u.toString());if($==="defaultVariants")return;if($==="variants"){const N=Object.entries(u);for(const[V,f]of N){if(!f)continue;const S=Object.entries(f);for(const[F,a]of S){if(!a)continue;const C=`${t}.${V}-${F}`;(await st(a,C,s)).forEach(M=>o.add(M))}}return}if($==="compoundVariants"){for(const N of u){const{css:V,...f}=N,S=Object.entries(f).reduce((a,[C,x])=>`${a}.${C}-${x}`,t);(await st(V,S,s)).forEach(a=>o.add(a))}return}if($.startsWith("@")){const N=$,V=await X(u,t,s),f=`${N} { ${V} }`;o.add(f);return}const k=m.includes("&")?$.replaceAll("&",t):$.startsWith(":")?`${t}${$}`:`${t} ${$}`;(await st(u,k,s)).forEach(N=>o.add(N));return}if(typeof u=="number"){const k=Lt(P,u);return v(k)}if(typeof u!="string")if("toString"in u)u=u.toString();else throw new Error(`Invalid value type for property ${P}`);return v(u)},d=r.map(i),{modifiers:g}={},y=[Ft(),It(g)],w=(await Promise.all(d).then(m=>Promise.all(m.map(u=>y.reduce(async($,P)=>{const v=await $;if(!v)return v;const O=await P(v);if(!O)return v;const{transformed:k,additionalCss:W}=O;let N="";if(W)for(const V of W)N+=await X(V,"");return`${N}${k}`},Promise.resolve(u)))))).filter(m=>m!==void 0).join(`
|
2
|
+
`);if(!w.trim())return Array.from(o);const h=t?`${t} {
|
3
|
+
${w}
|
4
|
+
}`:w;return o.has(h)?Array.from(o):[h,...o]},X=async(e,t,s,n=!1)=>(await st(e,t,s,n)).join(`
|
5
|
+
`),Ct=async(e,t=[])=>{if(!e)return"";const s=[],n={};for(const[o,r]of Object.entries(e))if(typeof r!="function")if(r&&typeof r=="object"){const i=o.trim(),d=await Ct(r,[...t,i]);s.push(d)}else n[o]=r;if(Object.keys(n).length){const o=t.map(z).join("-"),r="t_"+I(o,4),i=await X(n,`.${o}, .${r}`);s.push(i)}return s.join(`
|
6
|
+
`)},Ut=e=>e?Object.entries(e).reduce((t,[s,n])=>(typeof n=="function"?t[s]="any":typeof n=="object"&&(t[s]=Pt(n).map(o=>`"${o}"`).join(" | ")),t),{}):{},Pt=(e,t="",s=new Set)=>e?(Object.entries(e).forEach(([n,o])=>{const r=t?`${t}.${n}`:n;return typeof o=="object"?Pt(o,r,s):s.add(t)}),[...s]):[],Nt=e=>{if(!e||e==="/")throw new Error("Could not find package.json file");const t=c.join(e,"package.json");return p.existsSync(t)?t:Nt(c.join(e,".."))},Bt=async e=>{const t=Nt(e);return await bt.readFile(t,"utf-8").then(JSON.parse).catch(()=>{})},Zt=async e=>{const t=await Bt(e);if(t)return t.type};let G;const xt=async e=>{if(G)return G;const t=await Zt(e);return t==="module"?G="esm":(t==="commonjs"||(typeof document>"u"?require("url").pathToFileURL(__filename).href:ut&&ut.tagName.toUpperCase()==="SCRIPT"&&ut.src||new URL("index-DBDB_Jqo.cjs",document.baseURI).href).endsWith(".cjs"))&&(G="cjs"),G||"esm"},pt=Z.createLogger({level:"debug",format:Z.format.combine(Z.format.colorize(),Z.format.cli()),transports:[new Z.transports.Console({})]});function _t(e){return e?typeof e!="string"?_t(String(e)):e.replace(/[^\d\w]/g,"."):""}const Xt={"*, *::before, *::after":{boxSizing:"border-box"},"*":{margin:0},html:{lineHeight:1.15,textSizeAdjust:"100%",WebkitFontSmoothing:"antialiased"},"img, picture, video, canvas, svg":{display:"block",maxWidth:"100%"},"p, h1, h2, h3, h4, h5, h6":{overflowWrap:"break-word"},p:{textWrap:"pretty"},"h1, h2, h3, h4, h5, h6":{textWrap:"balance"},a:{color:"currentColor"},button:{lineHeight:"1em",color:"currentColor"},"input, optgroup, select, textarea":{fontFamily:"inherit",fontSize:"100%",lineHeight:"1.15em"}},H=(...e)=>e.flat().reduce((t,s)=>s!=null&&s._current?{...t,...s._current}:{...t,...s},{}),Yt=(...e)=>e.flat().reduce((t,s)=>({...t,...s._children}),{});class te{constructor(t){et(this,"_path");this.params=t}get _current(){return this.params.template}get isDefineTemplate(){return!0}_setPath(t){return this._path=t,this}}class ee{constructor(t){et(this,"_path");et(this,"templates",[]);this.params=t,Object.entries(t).forEach(([s,n])=>{this.templates.push(new te({name:s,template:n}))})}get _current(){return this.params}get _children(){return Object.fromEntries(this.templates.map(t=>[t.params.name,t]))}get isDefineTemplates(){return!0}_setPath(t){return this._path=t,this.templates.forEach(s=>s._setPath(t)),this}}const se=e=>new ee(e),ne=(e,t)=>new Promise((s,n)=>{const o=setTimeout(()=>{n(new Error("Timeout"))},100),r=ft.createSourceFile("temp.ts",e,ft.ScriptTarget.Latest,!0);function i(d){if(ft.isVariableDeclaration(d)&&d.name.getText()===t){const g=d.getStart(),y=d.getEnd();clearTimeout(o),s([g,y])}d.forEachChild(i)}i(r)}),R={externalModules:[],rcFile:void 0,destDir:void 0},vt=e=>{if(R.externalModules.length>0)return R.externalModules;const s=p.readFileSync(e,"utf8").match(/externalModules:\s?\[(.*)\]/);if(!s)return[];const n=s[1].split(",").map(o=>o.replace(/['"`]/g,"").trim());return R.externalModules=n,n},q=async e=>{if(R.destDir)return R.destDir;const t=await mt(e),s=c.join(e,(t==null?void 0:t.saltygenDir)||"saltygen");return R.destDir=s,s},Tt=["salty","css","styles","styled"],kt=(e=[])=>new RegExp(`\\.(${[...Tt,...e].join("|")})\\.`),nt=(e,t=[])=>kt(t).test(e),Dt=async e=>{if(R.rcFile)return R.rcFile;if(e==="/")throw new Error("Could not find .saltyrc.json file");const t=c.join(e,".saltyrc.json"),s=await bt.readFile(t,"utf-8").then(JSON.parse).catch(()=>{});return s?(R.rcFile=s,s):Dt(c.join(e,".."))},mt=async e=>{var n,o;const t=await Dt(e),s=(n=t.projects)==null?void 0:n.find(r=>e.endsWith(r.dir||""));return s||((o=t.projects)==null?void 0:o.find(r=>r.dir===t.defaultProject))},oe=async e=>{const t=await mt(e),s=await q(e),n=c.join(e,(t==null?void 0:t.configDir)||"","salty.config.ts"),o=c.join(s,"salty.config.js"),r=await xt(e),i=vt(n);await jt.build({entryPoints:[n],minify:!0,treeShaking:!0,bundle:!0,outfile:o,format:r,external:i});const d=Date.now(),{config:g}=await import(`${o}?t=${d}`);return{config:g,path:o}},ie=async(e,t)=>{var ht,gt;const s=await q(e),n={mediaQueries:[],globalStyles:[],variables:[],templates:[]};await Promise.all([...t].map(async j=>{const{contents:_,outputFilePath:U}=await ot(e,j,s);Object.entries(_).forEach(([D,T])=>{T.isMedia?n.mediaQueries.push([D,T]):T.isGlobalDefine?n.globalStyles.push(T):T.isDefineVariables?n.variables.push(T):T.isDefineTemplates&&n.templates.push(T._setPath(`${D};;${U}`))})}));const{config:o,path:r}=await oe(e),i={...o},{mediaQueries:d}=n;i.mediaQueries=Object.fromEntries(d.map(([j,_])=>[`@${j}`,_]));const g=d.map(([j])=>`'@${j}'`).join(" | "),y=new Set,l=async(j,_=[])=>{if(!j)return[];const U=Object.entries(j).map(async([T,A])=>{const B=async E=>{if(!E)return;if(E instanceof Promise)return await B(await E);if(typeof E=="function")return await B(await E());if(typeof E=="object")return await l(E,[..._,T]);const at=_t(T),ct=z(T),lt=[..._,at].join(".");y.add(`"${lt}"`);const tt=[..._.map(z),ct].join("-"),wt=qt(E);return wt?`--${tt}: ${wt.transformed};`:`--${tt}: ${E};`};return await B(A)});return(await Promise.all(U)).flat()},w=async j=>{if(!j)return[];const _=Object.entries(j).map(async([D,T])=>{const A=await l(T);return D==="base"?A.join(""):i.mediaQueries[D]?`${i.mediaQueries[D]} { ${A.join("")} }`:`${D} { ${A.join("")} }`});return(await Promise.all(_)).flat()},h=async j=>{if(!j)return[];const _=Object.entries(j).map(async([D,T])=>{const A=Object.entries(T).map(async([E,at])=>{const ct=await l(at,[D]),lt=`.${D}-${E}, [data-${D}="${E}"]`,tt=ct.join("");return`${lt} { ${tt} }`});return(await Promise.all(A)).flat()});return(await Promise.all(_)).flat()},b=j=>({...j,responsive:void 0,conditional:void 0}),m=j=>n.variables.map(_=>j==="static"?b(_._current):_._current[j]),u=H(b(o.variables),m("static")),$=await l(u),P=H((ht=o.variables)==null?void 0:ht.responsive,m("responsive")),v=await w(P),O=H((gt=o.variables)==null?void 0:gt.conditional,m("conditional")),k=await h(O),W=c.join(s,"css/_variables.css"),N=`:root { ${$.join("")} ${v.join("")} } ${k.join("")}`;p.writeFileSync(W,N),i.staticVariables=u;const V=c.join(s,"css/_global.css"),f=H(o.global,n.globalStyles),S=await X(f,"");p.writeFileSync(V,`@layer global { ${S} }`);const F=c.join(s,"css/_reset.css"),C=o.reset==="none"?{}:typeof o.reset=="object"?o.reset:Xt,x=await X(C,"");p.writeFileSync(F,`@layer reset { ${x} }`);const M=c.join(s,"css/_templates.css"),J=H(o.templates,n.templates),L=await Ct(J),Q=Ut(J);p.writeFileSync(M,`@layer templates { ${L} }`),i.templates=J;const Y=o.templates?[se(o.templates)._setPath(`config;;${r}`)]:[],it=Yt(n.templates,Y);i.templatePaths=Object.fromEntries(Object.entries(it).map(([j,_])=>[j,_._path]));const K=c.join(s,"types/css-tokens.d.ts"),Et=`
|
7
|
+
// Variable types
|
8
|
+
type VariableTokens = ${[...y].join("|")};
|
9
|
+
type PropertyValueToken = \`{\${VariableTokens}}\`;
|
10
|
+
|
11
|
+
// Template types
|
12
|
+
type TemplateTokens = {
|
13
|
+
${Object.entries(Q).map(([j,_])=>`${j}?: ${_}`).join(`
|
14
|
+
`)}
|
15
|
+
}
|
16
|
+
|
17
|
+
// Media query types
|
18
|
+
type MediaQueryKeys = ${g||"''"};
|
19
|
+
`;p.writeFileSync(K,Et);const Ot=c.join(s,"cache/config-cache.json");p.writeFileSync(Ot,JSON.stringify(i,null,2))},St=e=>e.replace(/styled\(([^"'`{,]+),/g,(t,s)=>{if(/^['"`]/.test(s))return t;const o=new RegExp(`import[^;]*${s}[,\\s{][^;]*from\\s?([^{};]+);`);if(!o.test(e))return t;const i=o.exec(e);if(i){const d=i.at(1);if(Tt.some(y=>d==null?void 0:d.includes(y)))return t}return"styled('div',"}),re=(e,t)=>{try{const s=p.readFileSync(c.join(t,"saltygen/cache/config-cache.json"),"utf8");return s?`globalThis.saltyConfig = ${s};
|
20
|
+
|
21
|
+
${e}`:`globalThis.saltyConfig = {};
|
22
|
+
|
23
|
+
${e}`}catch{return e}},ot=async(e,t,s)=>{const n=I(t),o=c.join(s,"./temp");p.existsSync(o)||p.mkdirSync(o);const r=c.parse(t);let i=p.readFileSync(t,"utf8");i=St(i),i=re(i,e);const d=c.join(s,"js",n+".js"),g=await mt(e),y=c.join(e,(g==null?void 0:g.configDir)||"","salty.config.ts"),l=vt(y),w=await xt(e);await jt.build({stdin:{contents:i,sourcefile:r.base,resolveDir:r.dir,loader:"tsx"},minify:!1,treeShaking:!0,bundle:!0,outfile:d,format:w,target:["node20"],keepNames:!0,external:l,packages:"external",plugins:[{name:"test",setup:m=>{m.onLoad({filter:/.*\.css|salty|styles|styled\.ts/},u=>{const $=p.readFileSync(u.path,"utf8");return{contents:St($),loader:"ts"}})}}]});const h=Date.now();return{contents:await import(`${d}?t=${h}`),outputFilePath:d}},ae=async e=>{const t=await q(e),s=c.join(t,"cache/config-cache.json"),n=p.readFileSync(s,"utf8");if(!n)throw new Error("Could not find config cache file");return JSON.parse(n)},dt=async e=>{const t=await ae(e),s=await q(e),n=c.join(s,"salty.config.js"),o=Date.now(),{config:r}=await import(`${n}?t=${o}`);return H(r,t)},yt=()=>{try{return process.env.NODE_ENV==="production"}catch{return!1}},ce=async(e,t=yt(),s=!0)=>{try{const n=Date.now();t?pt.info("Generating CSS in production mode! 🔥"):pt.info("Generating CSS in development mode! 🚀");const o=[],r=[],i=await q(e),d=c.join(i,"index.css");s&&(()=>{p.existsSync(i)&&Rt.execSync("rm -rf "+i),p.mkdirSync(i,{recursive:!0}),p.mkdirSync(c.join(i,"css")),p.mkdirSync(c.join(i,"types")),p.mkdirSync(c.join(i,"js")),p.mkdirSync(c.join(i,"cache"))})();const y=new Set,l=new Set;async function w(f){const S=["node_modules","saltygen"],F=p.statSync(f);if(F.isDirectory()){const a=p.readdirSync(f);if(S.some(x=>f.includes(x)))return;await Promise.all(a.map(x=>w(c.join(f,x))))}else if(F.isFile()&&nt(f)){y.add(f);const C=p.readFileSync(f,"utf8");/define[\w\d]+\(/.test(C)&&l.add(f)}}await w(e),await ie(e,l);const h={keyframes:[],components:[],classNames:[]};await Promise.all([...y].map(async f=>{const{contents:S}=await ot(e,f,i);for(let[F,a]of Object.entries(S))a instanceof Promise&&(a=await a),a.isKeyframes?h.keyframes.push({value:a,src:f,name:F}):a.isClassName?h.classNames.push({...a,src:f,name:F}):a.generator&&h.components.push({...a,src:f,name:F})}));const b=await dt(e);for(const f of h.keyframes){const{value:S}=f,F=`a_${S.animationName}.css`,a=`css/${F}`,C=c.join(i,a);o.push(F),p.writeFileSync(C,S.css)}const m={};for(const f of h.components){const{src:S,name:F}=f;m[S]||(m[S]=[]);const a=f.generator._withBuildContext({callerName:F,isProduction:t,config:b});r[a.priority]||(r[a.priority]=[]);const C=await a.css;if(!C)continue;r[a.priority].push(a.cssFileName);const x=`css/${a.cssFileName}`,M=c.join(i,x);p.writeFileSync(M,C),b.importStrategy==="component"&&m[S].push(a.cssFileName)}for(const f of h.classNames){const{src:S,name:F}=f;m[S]||(m[S]=[]);const a=f.generator._withBuildContext({callerName:F,isProduction:t,config:b}),C=await a.css;if(!C)continue;r[a.priority]||(r[a.priority]=[]),r[a.priority].push(a.cssFileName);const x=`css/${a.cssFileName}`,M=c.join(i,x);p.writeFileSync(M,C),b.importStrategy==="component"&&m[S].push(a.cssFileName)}b.importStrategy==="component"&&Object.entries(m).forEach(([f,S])=>{const F=S.map(J=>`@import url('./${J}');`).join(`
|
24
|
+
`),a=I(f,6),C=c.parse(f),x=z(C.name),M=c.join(i,`css/f_${x}-${a}.css`);p.writeFileSync(M,F||"/* Empty file */")});const u=o.map(f=>`@import url('./css/${f}');`).join(`
|
25
|
+
`);let k=`/*!
|
26
|
+
* Generated with Salty CSS (https://salty-css.dev)
|
27
|
+
* Do not edit this file directly
|
28
|
+
*/
|
29
|
+
@layer reset, global, templates, l0, l1, l2, l3, l4, l5, l6, l7, l8;
|
30
|
+
|
31
|
+
${["_variables.css","_reset.css","_global.css","_templates.css"].filter(f=>{try{return p.readFileSync(c.join(i,"css",f),"utf8").length>0}catch{return!1}}).map(f=>`@import url('./css/${f}');`).join(`
|
32
|
+
`)}
|
33
|
+
${u}`;if(b.importStrategy!=="component"){const f=r.reduce((S,F,a)=>{const C=F.reduce((L,Q)=>{var rt;const Y=c.join(i,"css",Q),it=p.readFileSync(Y,"utf8"),K=((rt=/.*-([^-]+)-\d+.css/.exec(Q))==null?void 0:rt.at(1))||I(Y,6);return L.includes(K)?L:`${L}
|
34
|
+
/*start:${K}-${Q}*/
|
35
|
+
${it}
|
36
|
+
/*end:${K}*/
|
37
|
+
`},""),x=`l_${a}.css`,M=c.join(i,"css",x),J=`@layer l${a} { ${C}
|
38
|
+
}`;return p.writeFileSync(M,J),`${S}
|
39
|
+
@import url('./css/${x}');`},"");k+=f}p.writeFileSync(d,k);const N=Date.now()-n,V=N<200?"🔥":N<500?"🚀":N<1e3?"🎉":N<2e3?"🚗":N<5e3?"🤔":"🥴";pt.info(`Generated CSS in ${N}ms! ${V}`)}catch(n){console.error(n)}},le=async(e,t,s=yt())=>{try{const n=await q(e);if(nt(t)){const r=[],i=await dt(e),{contents:d}=await ot(e,t,n);for(const[g,y]of Object.entries(d)){if(y.isKeyframes&&y.css){const u=`css/${`a_${y.animationName}.css`}`,$=c.join(n,u);p.writeFileSync($,await y.css);continue}if(y.isClassName){const m=y.generator._withBuildContext({callerName:g,isProduction:s,config:i}),u=await m.css;if(!u)continue;r[m.priority]||(r[m.priority]=[]),r[m.priority].push(m.cssFileName);const $=`css/${m.cssFileName}`,P=c.join(n,$);p.writeFileSync(P,u);continue}if(!y.generator)continue;const l=y.generator._withBuildContext({callerName:g,isProduction:s,config:i}),w=await l.css;if(!w)continue;const h=`css/${l.cssFileName}`,b=c.join(n,h);p.writeFileSync(b,w),r[l.priority]||(r[l.priority]=[]),r[l.priority].push(l.cssFileName)}if(i.importStrategy!=="component")r.forEach((g,y)=>{const l=`l_${y}.css`,w=c.join(n,"css",l);let h=p.readFileSync(w,"utf8");g.forEach(b=>{var P;const m=c.join(n,"css",b),u=((P=/.*-([^-]+)-\d+.css/.exec(b))==null?void 0:P.at(1))||I(m,6);if(!h.includes(u)){const v=p.readFileSync(m,"utf8"),O=`/*start:${u}-${b}*/
|
40
|
+
${v}
|
41
|
+
/*end:${u}*/
|
42
|
+
`;h=`${h.replace(/\}$/,"")}
|
43
|
+
${O}
|
44
|
+
}`}}),p.writeFileSync(w,h)});else{const g=r.flat().map(b=>`@import url('./${b}');`).join(`
|
45
|
+
`),y=I(t,6),l=c.parse(t),w=z(l.name),h=c.join(n,`css/f_${w}-${y}.css`);p.writeFileSync(h,g||"/* Empty file */")}}}catch(n){console.error(n)}},fe=async(e,t,s=yt())=>{var n,o;try{const r=await q(e);if(nt(t)){const d=p.readFileSync(t,"utf8"),g=await dt(e),{contents:y}=await ot(e,t,r);let l=d;for(const[w,h]of Object.entries(y)){if(h.isKeyframes||!h.generator)continue;const b=h.generator._withBuildContext({callerName:w,isProduction:s,config:g}),[m,u]=await ne(l,w),$=l.slice(m,u);if(h.isClassName){const P=l,v=` ${w} = className("${b.classNames}")`;l=l.replace($,v),P===l&&console.error("Minimize file failed to change content",{name:w})}if($.includes("styled")){const P=(o=(n=/styled\(([^,]+),/.exec($))==null?void 0:n.at(1))==null?void 0:o.trim(),v=l,O=` ${w} = styled(${P}, "${b.classNames}", ${JSON.stringify(b.clientProps)})`;l=l.replace($,O),v===l&&console.error("Minimize file failed to change content",{name:w,tagName:P})}}if(g.importStrategy==="component"){const w=I(t,6),h=c.parse(t);l=`import '../../saltygen/css/${`f_${z(h.name)}-${w}.css`}';
|
46
|
+
${l}`}return l=l.replace("@salty-css/react/class-name","@salty-css/react/class-name-client"),l=l.replace("{ styled }","{ styledClient as styled }"),l=l.replace("@salty-css/react/styled","@salty-css/react/styled-client"),l}}catch(r){console.error("Error in minimizeFile:",r)}};exports.generateCss=ce;exports.generateFile=le;exports.isSaltyFile=nt;exports.minimizeFile=fe;exports.saltyFileRegExp=kt;
|
package/index.cjs
CHANGED
@@ -1,15 +1 @@
|
|
1
|
-
"use strict";Object.
|
2
|
-
${f.replace(`
|
3
|
-
`,`
|
4
|
-
`)}
|
5
|
-
}`;return r.push(i),l}const j=$.includes("&")?y.replace("&",s):y.startsWith(":")?`${s}${y}`:`${s} ${y}`,d=k(o,j);return r.push(d),l}const g=y.startsWith("-")?y:V(y),w=(j,d=";")=>l=`${l}${j}${d}`,O=j=>w(`${g}:${j}`);if(typeof o=="number")return O(o);if(typeof o!="string")if("toString"in o)o=o.toString();else return l;const{modifiers:C}={},D=function*(){yield M(o),yield G(o,C)}();for(const{result:j,additionalCss:d=[]}of D)o=j,d.forEach(f=>{const i=k(f,"");w(i,"")});return O(o)},"");if(!a)return r.join(`
|
6
|
-
`);if(!s)return a;let b="";return b=`${s} { ${a} }`,[b,...r].join(`
|
7
|
-
`)},_=(t,s=[])=>{if(!t)return"";const e=[],n={};if(Object.entries(t).forEach(([r,a])=>{if(typeof a=="object"){if(!a)return;const b=r.trim(),l=_(a,[...s,b]);e.push(l)}else n[r]=a}),Object.keys(n).length){const r=s.map(V).join("-"),a=k(n,`.${r}`);e.push(a)}return e.join(`
|
8
|
-
`)},N=t=>u.join(t,"./saltygen"),J=["salty","css","styles","styled"],q=(t=[])=>new RegExp(`\\.(${[...J,...t].join("|")})\\.`),K=(t,s=[])=>q(s).test(t),L=async t=>{const s=N(t),e=u.join(t,"salty.config.ts"),n=u.join(s,"salty.config.js");await x.build({entryPoints:[e],minify:!0,treeShaking:!0,bundle:!0,outfile:n,format:"esm",external:["react"]});const r=Date.now(),{config:a}=await import(`${n}?t=${r}`);return a},U=async t=>{const s=await L(t),e=new Set,n=(f,i=[])=>f?Object.entries(f).flatMap(([p,c])=>{if(!c)return;if(typeof c=="object")return n(c,[...i,p]);const h=[...i,p].join(".");e.add(`"${h}"`);const S=[...i.map(V),V(p)].join("-"),{result:P}=M(c);return`--${S}: ${P};`}):[],r=f=>f?Object.entries(f).flatMap(([i,p])=>{const c=n(p);return i==="base"?c.join(""):`${i} { ${c.join("")} }`}):[],a=f=>f?Object.entries(f).flatMap(([i,p])=>Object.entries(p).flatMap(([c,h])=>{const S=n(h,[i]),P=`.${i}-${c}, [data-${i}="${c}"]`,T=S.join("");return`${P} { ${T} }`})):[],b=n(s.variables),l=r(s.responsiveVariables),$=a(s.conditionalVariables),o=N(t),y=u.join(o,"css/variables.css"),g=`:root { ${b.join("")} ${l.join("")} } ${$.join("")}`;m.writeFileSync(y,g);const w=u.join(o,"types/css-tokens.d.ts"),C=`type VariableTokens = ${[...e].join("|")}; type PropertyValueToken = \`{\${VariableTokens}}\``;m.writeFileSync(w,C);const F=u.join(o,"css/global.css"),D=k(s.global,"");m.writeFileSync(F,D);const j=u.join(o,"css/templates.css"),d=_(s.templates);m.writeFileSync(j,d)},X=async(t,s)=>{const e=A(t),n=u.join(s,"js",e+".js");await x.build({entryPoints:[t],minify:!0,treeShaking:!0,bundle:!0,outfile:n,format:"esm",target:["es2022"],keepNames:!0,external:["react"]});const r=Date.now();return await import(`${n}?t=${r}`)},Y=async t=>{const s=N(t),e=u.join(s,"salty.config.js"),{config:n}=await import(e);return n},Q=async t=>{try{const s=[],e=[],n=N(t),r=u.join(n,"index.css");(()=>{m.existsSync(n)&&W.execSync("rm -rf "+n),m.mkdirSync(n),m.mkdirSync(u.join(n,"css")),m.mkdirSync(u.join(n,"types"))})(),await U(t);const b=await Y(t);async function l(g,w){const O=m.statSync(g);if(O.isDirectory()){const C=m.readdirSync(g);await Promise.all(C.map(F=>l(u.join(g,F),u.join(w,F))))}else if(O.isFile()&&K(g)){const F=await X(g,n),D=[];Object.entries(F).forEach(([i,p])=>{if(p.isKeyframes&&p.css){const T=`${p.animationName}.css`,Z=`css/${T}`,R=u.join(n,Z);s.push(T),m.writeFileSync(R,p.css);return}if(!p.generator)return;const c=p.generator._withBuildContext({name:i,config:b}),h=`${c.hash}-${c.priority}.css`;e[c.priority]||(e[c.priority]=[]),e[c.priority].push(h),D.push(h);const S=`css/${h}`,P=u.join(n,S);m.writeFileSync(P,c.css)});const j=D.map(i=>`@import url('./${i}');`).join(`
|
9
|
-
`),d=A(g,6),f=u.join(n,`css/${d}.css`);m.writeFileSync(f,j)}}await l(t,n);const $=s.map(g=>`@import url('./css/${g}');`).join(`
|
10
|
-
`);let y=`@layer l0, l1, l2, l3, l4, l5, l6, l7, l8;
|
11
|
-
|
12
|
-
${["@import url('./css/variables.css');","@import url('./css/global.css');","@import url('./css/templates.css');"].join(`
|
13
|
-
`)}
|
14
|
-
${$}`;if(b.importStrategy!=="component"){const g=e.flat().map(w=>`@import url('./css/${w}');`).join(`
|
15
|
-
`);y+=g}m.writeFileSync(r,y)}catch(s){console.error(s)}},v=(t,s)=>{var e,n,r;(n=(e=t.module)==null?void 0:e.rules)==null||n.push({test:q(),use:[{loader:u.resolve("./loader.js"),options:{dir:s}}]}),(r=t.plugins)==null||r.push({apply:a=>{a.hooks.afterPlugins.tap({name:"generateCss"},async()=>{await Q(s)})}})};exports.saltyPlugin=v;
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const d=require("path"),t=require("./index-DBDB_Jqo.cjs"),y=require("fs/promises"),g=require("fs"),p=async e=>{if(!e||e.includes("node_modules")||e.includes("saltygen"))return!1;if(e.includes("salty.config"))return!0;if(!t.isSaltyFile(e))return!1;const r=await y.readFile(e,"utf-8");return!!(/.+define[A-Z]\w+/.test(r)||/.+keyframes\(.+/.test(r))},c=(e,s,l=!1,r=!1)=>{var i,n,u;(n=(i=e.module)==null?void 0:i.rules)==null||n.push({test:t.saltyFileRegExp(),use:[{loader:d.resolve(__dirname,r?"./loader.cjs":"./loader.js"),options:{dir:s}}]}),l||(u=e.plugins)==null||u.push({apply:f=>{let o=!1;f.hooks.beforeCompile.tapPromise({name:"generateCss"},async()=>{o||(o=!0,await t.generateCss(s),g.watch(s,{recursive:!0},async(h,a)=>{await p(a)?await t.generateCss(s,!1,!1):t.isSaltyFile(a)&&await t.generateFile(s,a)}))})}})};exports.default=c;exports.saltyPlugin=c;
|
package/index.d.ts
CHANGED
package/index.js
CHANGED
@@ -1,225 +1,35 @@
|
|
1
|
-
import {
|
2
|
-
import
|
3
|
-
import {
|
4
|
-
import {
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
const e = L(5381, JSON.stringify(t)) >>> 0;
|
16
|
-
return K(e, s);
|
17
|
-
};
|
18
|
-
function T(t) {
|
19
|
-
return t ? typeof t != "string" ? T(String(t)) : t.replace(/\s/g, "-").replace(/[A-Z](?:(?=[^A-Z])|[A-Z]*(?=[A-Z][^A-Z]|$))/g, (s, e) => (e > 0 ? "-" : "") + s.toLowerCase()) : "";
|
20
|
-
}
|
21
|
-
const z = (t, s) => {
|
22
|
-
if (typeof t != "string") return { result: t };
|
23
|
-
if (!s) return { result: t };
|
24
|
-
const e = [];
|
25
|
-
return Object.values(s).forEach((n) => {
|
26
|
-
const { pattern: r, transform: a } = n;
|
27
|
-
t = t.replace(r, (g) => {
|
28
|
-
const { value: l, css: b } = a(g);
|
29
|
-
return b && e.push(b), l;
|
30
|
-
});
|
31
|
-
}), { result: t, additionalCss: e };
|
32
|
-
}, Z = (t) => typeof t != "string" ? { result: t } : /\{[^{}]+\}/g.test(t) ? { result: t.replace(/\{([^{}]+)\}/g, (...n) => `var(--${T(n[1].replaceAll(".", "-"))})`) } : { result: t }, k = (t, s, e, n) => {
|
33
|
-
if (!t) return "";
|
34
|
-
const r = [], a = Object.entries(t).reduce((l, [b, o]) => {
|
35
|
-
const u = b.trim();
|
36
|
-
if (typeof o == "function" && (o = o()), typeof o == "object") {
|
37
|
-
if (!o) return l;
|
38
|
-
if (u === "variants")
|
39
|
-
return Object.entries(o).forEach(([f, i]) => {
|
40
|
-
i && Object.entries(i).forEach(([p, c]) => {
|
41
|
-
if (!c) return;
|
42
|
-
const h = `${s}.${f}-${p}`, j = k(c, h);
|
43
|
-
r.push(j);
|
44
|
-
});
|
45
|
-
}), l;
|
46
|
-
if (u === "defaultVariants")
|
47
|
-
return l;
|
48
|
-
if (u === "compoundVariants")
|
49
|
-
return o.forEach((f) => {
|
50
|
-
const { css: i, ...p } = f, c = Object.entries(p).reduce((j, [C, O]) => `${j}.${C}-${O}`, s), h = k(i, c);
|
51
|
-
r.push(h);
|
52
|
-
}), l;
|
53
|
-
if (u.startsWith("@")) {
|
54
|
-
const f = k(o, s), i = `${u} {
|
55
|
-
${f.replace(`
|
56
|
-
`, `
|
57
|
-
`)}
|
58
|
-
}`;
|
59
|
-
return r.push(i), l;
|
60
|
-
}
|
61
|
-
const $ = b.includes("&") ? u.replace("&", s) : u.startsWith(":") ? `${s}${u}` : `${s} ${u}`, d = k(o, $);
|
62
|
-
return r.push(d), l;
|
63
|
-
}
|
64
|
-
const y = u.startsWith("-") ? u : T(u), S = ($, d = ";") => l = `${l}${$}${d}`, D = ($) => S(`${y}:${$}`);
|
65
|
-
if (typeof o == "number") return D(o);
|
66
|
-
if (typeof o != "string")
|
67
|
-
if ("toString" in o) o = o.toString();
|
68
|
-
else return l;
|
69
|
-
const { modifiers: F } = {}, V = function* () {
|
70
|
-
yield Z(o), yield z(o, F);
|
71
|
-
}();
|
72
|
-
for (const { result: $, additionalCss: d = [] } of V)
|
73
|
-
o = $, d.forEach((f) => {
|
74
|
-
const i = k(f, "");
|
75
|
-
S(i, "");
|
76
|
-
});
|
77
|
-
return D(o);
|
78
|
-
}, "");
|
79
|
-
if (!a) return r.join(`
|
80
|
-
`);
|
81
|
-
if (!s) return a;
|
82
|
-
let g = "";
|
83
|
-
return g = `${s} { ${a} }`, [g, ...r].join(`
|
84
|
-
`);
|
85
|
-
}, R = (t, s = []) => {
|
86
|
-
if (!t) return "";
|
87
|
-
const e = [], n = {};
|
88
|
-
if (Object.entries(t).forEach(([r, a]) => {
|
89
|
-
if (typeof a == "object") {
|
90
|
-
if (!a) return;
|
91
|
-
const g = r.trim(), l = R(a, [...s, g]);
|
92
|
-
e.push(l);
|
93
|
-
} else
|
94
|
-
n[r] = a;
|
95
|
-
}), Object.keys(n).length) {
|
96
|
-
const r = s.map(T).join("-"), a = k(n, `.${r}`);
|
97
|
-
e.push(a);
|
98
|
-
}
|
99
|
-
return e.join(`
|
100
|
-
`);
|
101
|
-
}, N = (t) => m(t, "./saltygen"), U = ["salty", "css", "styles", "styled"], I = (t = []) => new RegExp(`\\.(${[...U, ...t].join("|")})\\.`), X = (t, s = []) => I(s).test(t), Y = async (t) => {
|
102
|
-
const s = N(t), e = m(t, "salty.config.ts"), n = m(s, "salty.config.js");
|
103
|
-
await A.build({
|
104
|
-
entryPoints: [e],
|
105
|
-
minify: !0,
|
106
|
-
treeShaking: !0,
|
107
|
-
bundle: !0,
|
108
|
-
outfile: n,
|
109
|
-
format: "esm",
|
110
|
-
external: ["react"]
|
111
|
-
});
|
112
|
-
const r = Date.now(), { config: a } = await import(`${n}?t=${r}`);
|
113
|
-
return a;
|
114
|
-
}, Q = async (t) => {
|
115
|
-
const s = await Y(t), e = /* @__PURE__ */ new Set(), n = (f, i = []) => f ? Object.entries(f).flatMap(([p, c]) => {
|
116
|
-
if (!c) return;
|
117
|
-
if (typeof c == "object") return n(c, [...i, p]);
|
118
|
-
const h = [...i, p].join(".");
|
119
|
-
e.add(`"${h}"`);
|
120
|
-
const j = [...i.map(T), T(p)].join("-"), { result: C } = Z(c);
|
121
|
-
return `--${j}: ${C};`;
|
122
|
-
}) : [], r = (f) => f ? Object.entries(f).flatMap(([i, p]) => {
|
123
|
-
const c = n(p);
|
124
|
-
return i === "base" ? c.join("") : `${i} { ${c.join("")} }`;
|
125
|
-
}) : [], a = (f) => f ? Object.entries(f).flatMap(([i, p]) => Object.entries(p).flatMap(([c, h]) => {
|
126
|
-
const j = n(h, [i]), C = `.${i}-${c}, [data-${i}="${c}"]`, O = j.join("");
|
127
|
-
return `${C} { ${O} }`;
|
128
|
-
})) : [], g = n(s.variables), l = r(s.responsiveVariables), b = a(s.conditionalVariables), o = N(t), u = m(o, "css/variables.css"), y = `:root { ${g.join("")} ${l.join("")} } ${b.join("")}`;
|
129
|
-
w(u, y);
|
130
|
-
const S = m(o, "types/css-tokens.d.ts"), F = `type VariableTokens = ${[...e].join("|")}; type PropertyValueToken = \`{\${VariableTokens}}\``;
|
131
|
-
w(S, F);
|
132
|
-
const P = m(o, "css/global.css"), V = k(s.global, "");
|
133
|
-
w(P, V);
|
134
|
-
const $ = m(o, "css/templates.css"), d = R(s.templates);
|
135
|
-
w($, d);
|
136
|
-
}, v = async (t, s) => {
|
137
|
-
const e = M(t), n = m(s, "js", e + ".js");
|
138
|
-
await A.build({
|
139
|
-
entryPoints: [t],
|
140
|
-
minify: !0,
|
141
|
-
treeShaking: !0,
|
142
|
-
bundle: !0,
|
143
|
-
outfile: n,
|
144
|
-
format: "esm",
|
145
|
-
target: ["es2022"],
|
146
|
-
keepNames: !0,
|
147
|
-
external: ["react"]
|
148
|
-
});
|
149
|
-
const r = Date.now();
|
150
|
-
return await import(`${n}?t=${r}`);
|
151
|
-
}, tt = async (t) => {
|
152
|
-
const s = N(t), e = m(s, "salty.config.js"), { config: n } = await import(e);
|
153
|
-
return n;
|
154
|
-
}, st = async (t) => {
|
155
|
-
try {
|
156
|
-
const s = [], e = [], n = N(t), r = m(n, "index.css");
|
157
|
-
(() => {
|
158
|
-
B(n) && q("rm -rf " + n), x(n), x(m(n, "css")), x(m(n, "types"));
|
159
|
-
})(), await Q(t);
|
160
|
-
const g = await tt(t);
|
161
|
-
async function l(y, S) {
|
162
|
-
const D = G(y);
|
163
|
-
if (D.isDirectory()) {
|
164
|
-
const F = J(y);
|
165
|
-
await Promise.all(F.map((P) => l(m(y, P), m(S, P))));
|
166
|
-
} else if (D.isFile() && X(y)) {
|
167
|
-
const P = await v(y, n), V = [];
|
168
|
-
Object.entries(P).forEach(([i, p]) => {
|
169
|
-
if (p.isKeyframes && p.css) {
|
170
|
-
const O = `${p.animationName}.css`, W = `css/${O}`, _ = m(n, W);
|
171
|
-
s.push(O), w(_, p.css);
|
172
|
-
return;
|
173
|
-
}
|
174
|
-
if (!p.generator) return;
|
175
|
-
const c = p.generator._withBuildContext({
|
176
|
-
name: i,
|
177
|
-
config: g
|
178
|
-
}), h = `${c.hash}-${c.priority}.css`;
|
179
|
-
e[c.priority] || (e[c.priority] = []), e[c.priority].push(h), V.push(h);
|
180
|
-
const j = `css/${h}`, C = m(n, j);
|
181
|
-
w(C, c.css);
|
182
|
-
});
|
183
|
-
const $ = V.map((i) => `@import url('./${i}');`).join(`
|
184
|
-
`), d = M(y, 6), f = m(n, `css/${d}.css`);
|
185
|
-
w(f, $);
|
186
|
-
}
|
187
|
-
}
|
188
|
-
await l(t, n);
|
189
|
-
const b = s.map((y) => `@import url('./css/${y}');`).join(`
|
190
|
-
`);
|
191
|
-
let u = `@layer l0, l1, l2, l3, l4, l5, l6, l7, l8;
|
192
|
-
|
193
|
-
${["@import url('./css/variables.css');", "@import url('./css/global.css');", "@import url('./css/templates.css');"].join(`
|
194
|
-
`)}
|
195
|
-
${b}`;
|
196
|
-
if (g.importStrategy !== "component") {
|
197
|
-
const y = e.flat().map((S) => `@import url('./css/${S}');`).join(`
|
198
|
-
`);
|
199
|
-
u += y;
|
200
|
-
}
|
201
|
-
w(r, u);
|
202
|
-
} catch (s) {
|
203
|
-
console.error(s);
|
204
|
-
}
|
205
|
-
}, it = (t, s) => {
|
206
|
-
var e, n, r;
|
207
|
-
(n = (e = t.module) == null ? void 0 : e.rules) == null || n.push({
|
208
|
-
test: I(),
|
1
|
+
import { resolve as p } from "path";
|
2
|
+
import { i as f, s as y, g as u, a as d } from "./index-Cpurtg_y.js";
|
3
|
+
import { readFile as g } from "fs/promises";
|
4
|
+
import { watch as m } from "fs";
|
5
|
+
const w = async (e) => {
|
6
|
+
if (!e || e.includes("node_modules") || e.includes("saltygen")) return !1;
|
7
|
+
if (e.includes("salty.config")) return !0;
|
8
|
+
if (!f(e)) return !1;
|
9
|
+
const t = await g(e, "utf-8");
|
10
|
+
return !!(/.+define[A-Z]\w+/.test(t) || /.+keyframes\(.+/.test(t));
|
11
|
+
}, _ = (e, s, r = !1, t = !1) => {
|
12
|
+
var l, o, i;
|
13
|
+
(o = (l = e.module) == null ? void 0 : l.rules) == null || o.push({
|
14
|
+
test: y(),
|
209
15
|
use: [
|
210
16
|
{
|
211
|
-
loader:
|
17
|
+
loader: p(__dirname, t ? "./loader.cjs" : "./loader.js"),
|
212
18
|
options: { dir: s }
|
213
19
|
}
|
214
20
|
]
|
215
|
-
}),
|
216
|
-
apply: (
|
217
|
-
|
218
|
-
|
21
|
+
}), r || (i = e.plugins) == null || i.push({
|
22
|
+
apply: (c) => {
|
23
|
+
let n = !1;
|
24
|
+
c.hooks.beforeCompile.tapPromise({ name: "generateCss" }, async () => {
|
25
|
+
n || (n = !0, await u(s), m(s, { recursive: !0 }, async (h, a) => {
|
26
|
+
await w(a) ? await u(s, !1, !1) : f(a) && await d(s, a);
|
27
|
+
}));
|
219
28
|
});
|
220
29
|
}
|
221
30
|
});
|
222
31
|
};
|
223
32
|
export {
|
224
|
-
|
33
|
+
_ as default,
|
34
|
+
_ as saltyPlugin
|
225
35
|
};
|
package/loader.cjs
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
"use strict";const i=require("./index-DBDB_Jqo.cjs");async function n(){const{dir:e}=this.getOptions(),{resourcePath:t}=this;return await i.generateFile(e,t),await i.minimizeFile(e,t)}module.exports=n;
|
package/loader.js
ADDED
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@salty-css/webpack",
|
3
|
-
"version": "0.0.1-alpha.
|
3
|
+
"version": "0.0.1-alpha.260",
|
4
4
|
"main": "./dist/index.js",
|
5
5
|
"module": "./dist/index.mjs",
|
6
6
|
"typings": "./dist/index.d.ts",
|
@@ -10,7 +10,12 @@
|
|
10
10
|
"publishConfig": {
|
11
11
|
"access": "public"
|
12
12
|
},
|
13
|
-
"
|
13
|
+
"description": "Webpack plugin for Salty CSS",
|
14
|
+
"homepage": "https://salty-css.dev/",
|
15
|
+
"repository": {
|
16
|
+
"type": "git",
|
17
|
+
"url": "git+https://github.com/margarita-form/salty-css.git"
|
18
|
+
},
|
14
19
|
"bugs": {
|
15
20
|
"url": "https://github.com/margarita-form/salty-css/issues"
|
16
21
|
},
|
@@ -28,8 +33,8 @@
|
|
28
33
|
"require": "./index.cjs"
|
29
34
|
}
|
30
35
|
},
|
31
|
-
"
|
32
|
-
"@salty-css/core": "^0.0.1-alpha.
|
36
|
+
"dependencies": {
|
37
|
+
"@salty-css/core": "^0.0.1-alpha.260",
|
33
38
|
"webpack": ">=5.x"
|
34
39
|
}
|
35
40
|
}
|