@unocss/runtime 66.3.2 → 66.4.0
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/attributify.global.js +4 -4
- package/core.global.js +2 -2
- package/full.global.js +10 -10
- package/mini.global.js +10 -10
- package/package.json +5 -5
- package/preset-icons.global.js +1 -1
- package/preset-mini.global.js +4 -4
- package/preset-tagify.global.js +1 -1
- package/preset-typography.global.js +1 -1
- package/preset-uno.global.js +7 -7
- package/preset-web-fonts.global.js +6 -33
- package/preset-wind.global.js +7 -7
- package/uno.global.js +4 -4
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unocss/runtime",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "66.
|
|
4
|
+
"version": "66.4.0",
|
|
5
5
|
"description": "CSS-in-JS Runtime for UnoCSS",
|
|
6
6
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"homepage": "https://unocss.dev",
|
|
10
10
|
"repository": {
|
|
11
11
|
"type": "git",
|
|
12
|
-
"url": "git+https://github.com/unocss/unocss",
|
|
12
|
+
"url": "git+https://github.com/unocss/unocss.git",
|
|
13
13
|
"directory": "packages-integrations/runtime"
|
|
14
14
|
},
|
|
15
15
|
"bugs": {
|
|
@@ -35,9 +35,9 @@
|
|
|
35
35
|
"dist"
|
|
36
36
|
],
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@unocss/
|
|
39
|
-
"@unocss/preset-
|
|
40
|
-
"@unocss/
|
|
38
|
+
"@unocss/preset-attributify": "66.4.0",
|
|
39
|
+
"@unocss/preset-uno": "66.4.0",
|
|
40
|
+
"@unocss/core": "66.4.0"
|
|
41
41
|
},
|
|
42
42
|
"scripts": {
|
|
43
43
|
"build": "pnpm run build:node && pnpm run build:cdn && pnpm run build:presets",
|
package/preset-icons.global.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
`).join(`
|
|
3
3
|
`+i),e.push(r+"m+"+Y.exports.humanize(this.diff)+"\x1B[0m")}else e[0]=kt()+o+" "+e[0]}function kt(){return w.inspectOpts.hideDate?"":new Date().toISOString()+" "}function jt(...e){return process.stderr.write(Z.formatWithOptions(w.inspectOpts,...e)+`
|
|
4
4
|
`)}function Et(e){e?process.env.DEBUG=e:delete process.env.DEBUG}function Tt(){return process.env.DEBUG}function Lt(e){e.inspectOpts={};let o=Object.keys(w.inspectOpts);for(let t=0;t<o.length;t++)e.inspectOpts[o[t]]=w.inspectOpts[o[t]]}Y.exports=se()(w);var{formatters:De}=Y.exports;De.o=function(e){return this.inspectOpts.colors=this.useColors,Z.inspect(e,this.inspectOpts).split(`
|
|
5
|
-
`).map(o=>o.trim()).join(" ")};De.O=function(e){return this.inspectOpts.colors=this.useColors,Z.inspect(e,this.inspectOpts)}});var D=T((mo,le)=>{"use strict";typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?le.exports=Re():le.exports=Ue()});async function ue(e,o,t,n){let r;$t(`${o}:${t}`);try{if(typeof e=="function")r=await e(t);else{let i=e[t];r=typeof i=="function"?await i():i}}catch(i){console.warn(`Failed to load custom icon "${t}" in "${o}":`,i);return}if(r){let i=r.indexOf("<svg");i>0&&(r=r.slice(i));let{transform:c}=n?.customizations??{};return r=typeof c=="function"?await c(r,o,t):r,r.startsWith("<svg")?await K(n?.customizations?.trimCustomSvg===!0?je(r):r,o,t,n,void 0):(console.warn(`Custom icon "${t}" in "${o}" is not a valid SVG`),r)}}var Me,$t,Ve=v(()=>{"use strict";Me=G(D(),1);ie();Ee();$t=(0,Me.default)("@iconify-loader:custom")});async function X(e,o,t,n){let r,{customize:i}=n?.customizations??{};for(let c of t)if(r=Ie(e,c),r){Rt(`${o}:${c}`);let u={...B};typeof i=="function"&&(r=Object.assign({},r),u=i(u,r,`${o}:${c}`)??u);let{attributes:{width:d,height:g,...s},body:f}=Oe(r,u),m=n?.scale;return await K(`<svg >${f}</svg>`,o,c,n,()=>({...s}),p=>{let C=(a,l)=>{let y=p[a],b;if(!N(y)){if(y)return;typeof m=="number"?m&&(b=L(l??"1em",m)):b=l}b?p[a]=b:delete p[a]};C("width",d),C("height",g)})}}var Ge,Rt,fe=v(()=>{"use strict";oe();ve();W();ie();Ge=G(D(),1);ee();Rt=(0,Ge.default)("@iconify-loader:icon")});var So,U,me=v(()=>{"use strict";Ve();fe();So=G(D(),1),U=async(e,o,t)=>{let n=t?.customCollections?.[e];if(n)if(typeof n=="function"){let r;try{r=await n(o)}catch(i){console.warn(`Failed to load custom icon "${o}" in "${e}":`,i);return}if(r){if(typeof r=="string")return await ue(()=>r,e,o,t);if("icons"in r){let i=[o,o.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),o.replace(/([a-z])(\d+)/g,"$1-$2")];return await X(r,e,i,t)}}}else return await ue(n,e,o,t)}});function ke(e){return e.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function re(e){let o=e.startsWith("<svg>")?e.replace("<svg>","<svg >"):e;return!o.includes(" xmlns:xlink=")&&o.includes(" xlink:")&&(o=o.replace("<svg ",'<svg xmlns:xlink="http://www.w3.org/1999/xlink" ')),o.includes(" xmlns=")||(o=o.replace("<svg ",'<svg xmlns="http://www.w3.org/2000/svg" ')),ke(o)}me();var ko=G(D(),1);var qe=new Set;function Be(e){qe.has(e)||(console.warn("[unocss]",e),qe.add(e))}me();fe();var pe=["academicons","akar-icons","ant-design","arcticons","
|
|
5
|
+
`).map(o=>o.trim()).join(" ")};De.O=function(e){return this.inspectOpts.colors=this.useColors,Z.inspect(e,this.inspectOpts)}});var D=T((mo,le)=>{"use strict";typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?le.exports=Re():le.exports=Ue()});async function ue(e,o,t,n){let r;$t(`${o}:${t}`);try{if(typeof e=="function")r=await e(t);else{let i=e[t];r=typeof i=="function"?await i():i}}catch(i){console.warn(`Failed to load custom icon "${t}" in "${o}":`,i);return}if(r){let i=r.indexOf("<svg");i>0&&(r=r.slice(i));let{transform:c}=n?.customizations??{};return r=typeof c=="function"?await c(r,o,t):r,r.startsWith("<svg")?await K(n?.customizations?.trimCustomSvg===!0?je(r):r,o,t,n,void 0):(console.warn(`Custom icon "${t}" in "${o}" is not a valid SVG`),r)}}var Me,$t,Ve=v(()=>{"use strict";Me=G(D(),1);ie();Ee();$t=(0,Me.default)("@iconify-loader:custom")});async function X(e,o,t,n){let r,{customize:i}=n?.customizations??{};for(let c of t)if(r=Ie(e,c),r){Rt(`${o}:${c}`);let u={...B};typeof i=="function"&&(r=Object.assign({},r),u=i(u,r,`${o}:${c}`)??u);let{attributes:{width:d,height:g,...s},body:f}=Oe(r,u),m=n?.scale;return await K(`<svg >${f}</svg>`,o,c,n,()=>({...s}),p=>{let C=(a,l)=>{let y=p[a],b;if(!N(y)){if(y)return;typeof m=="number"?m&&(b=L(l??"1em",m)):b=l}b?p[a]=b:delete p[a]};C("width",d),C("height",g)})}}var Ge,Rt,fe=v(()=>{"use strict";oe();ve();W();ie();Ge=G(D(),1);ee();Rt=(0,Ge.default)("@iconify-loader:icon")});var So,U,me=v(()=>{"use strict";Ve();fe();So=G(D(),1),U=async(e,o,t)=>{let n=t?.customCollections?.[e];if(n)if(typeof n=="function"){let r;try{r=await n(o)}catch(i){console.warn(`Failed to load custom icon "${o}" in "${e}":`,i);return}if(r){if(typeof r=="string")return await ue(()=>r,e,o,t);if("icons"in r){let i=[o,o.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),o.replace(/([a-z])(\d+)/g,"$1-$2")];return await X(r,e,i,t)}}}else return await ue(n,e,o,t)}});function ke(e){return e.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function re(e){let o=e.startsWith("<svg>")?e.replace("<svg>","<svg >"):e;return!o.includes(" xmlns:xlink=")&&o.includes(" xlink:")&&(o=o.replace("<svg ",'<svg xmlns:xlink="http://www.w3.org/1999/xlink" ')),o.includes(" xmlns=")||(o=o.replace("<svg ",'<svg xmlns="http://www.w3.org/2000/svg" ')),ke(o)}me();var ko=G(D(),1);var qe=new Set;function Be(e){qe.has(e)||(console.warn("[unocss]",e),qe.add(e))}me();fe();var pe=["academicons","akar-icons","ant-design","arcticons","basil","bi","bitcoin-icons","bpmn","brandico","bubbles","bx","bxl","bxs","bytesize","carbon","catppuccin","cbi","charm","ci","cib","cif","cil","circle-flags","circum","clarity","codex","codicon","covid","cryptocurrency-color","cryptocurrency","cuida","dashicons","devicon-line","devicon-original","devicon-plain","devicon","dinkie-icons","duo-icons","ei","el","emblemicons","emojione-monotone","emojione-v1","emojione","entypo-social","entypo","eos-icons","ep","et","eva","f7","fa-brands","fa-regular","fa-solid","fa","fa6-brands","fa6-regular","fa6-solid","fa7-brands","fa7-regular","fa7-solid","fad","famicons","fe","feather","file-icons","flag","flagpack","flat-color-icons","flat-ui","flowbite","fluent-color","fluent-emoji-flat","fluent-emoji-high-contrast","fluent-emoji","fluent-mdl2","fluent","fontelico","fontisto","formkit","foundation","fxemoji","gala","game-icons","garden","geo","gg","gis","gravity-ui","gridicons","grommet-icons","guidance","healthicons","heroicons-outline","heroicons-solid","heroicons","hugeicons","humbleicons","ic","icomoon-free","icon-park-outline","icon-park-solid","icon-park-twotone","icon-park","iconamoon","iconoir","icons8","il","ion","iwwa","ix","jam","la","lets-icons","line-md","lineicons","logos","ls","lsicon","lucide-lab","lucide","mage","majesticons","maki","map","marketeq","material-icon-theme","material-symbols-light","material-symbols","mdi-light","mdi","medical-icon","memory","meteocons","meteor-icons","mi","mingcute","mono-icons","mynaui","nimbus","nonicons","noto-v1","noto","nrk","octicon","oi","ooui","openmoji","oui","pajamas","pepicons-pencil","pepicons-pop","pepicons-print","pepicons","ph","picon","pixel","pixelarticons","prime","proicons","ps","qlementine-icons","quill","radix-icons","raphael","ri","rivet-icons","si-glyph","si","sidekickicons","simple-icons","simple-line-icons","skill-icons","solar","stash","streamline-block","streamline-color","streamline-cyber-color","streamline-cyber","streamline-emojis","streamline-flex-color","streamline-flex","streamline-freehand-color","streamline-freehand","streamline-guidance","streamline-kameleon-color","streamline-logos","streamline-pixel","streamline-plump-color","streamline-plump","streamline-sharp-color","streamline-sharp","streamline-stickies-color","streamline-ultimate-color","streamline-ultimate","streamline","subway","svg-spinners","system-uicons","tabler","tdesign","teenyicons","token-branded","token","topcoat","twemoji","typcn","uil","uim","uis","uit","uiw","unjs","vaadin","vs","vscode-icons","websymbol","weui","whh","wi","wpf","zmdi","zondicons"];var At=3;function Ke(e){return(o={})=>{let{scale:t=1,mode:n="auto",prefix:r="i-",warn:i=!1,iconifyCollectionsNames:c,collections:u,extraProperties:d={},customizations:g={},autoInstall:s=!1,collectionsNodeResolvePath:f,layer:m="icons",unit:p,processor:C}=o,a=Pt(),l={addXmlNs:!0,scale:t,customCollections:u,autoInstall:s,cwd:f,warn:void 0,customizations:{...g,additionalProps:{...d},trimCustomSvg:!0,async iconCustomizer(b,I,h){await g.iconCustomizer?.(b,I,h),p&&(h.width||(h.width=`${t}${p}`),h.height||(h.height=`${t}${p}`))}}},y;return{name:"@unocss/preset-icons",enforce:"pre",options:o,layers:{icons:-30},api:{encodeSvgForCss:re,parseIconWithLoader:We},rules:[[/^([\w:-]+)(?:\?(mask|bg|auto))?$/,async b=>{let[I,h,_=n]=b;y=y||await e(o);let k={},j=await We(h,y,{...l,usedProps:k},c);if(!j){i&&!a.isESLint&&Be(`failed to load icon "${I}"`);return}let E,M=`url("data:image/svg+xml;utf8,${re(j.svg)}")`;return _==="auto"&&(_=j.svg.includes("currentColor")?"mask":"bg"),_==="mask"?E={"--un-icon":M,"-webkit-mask":"var(--un-icon) no-repeat",mask:"var(--un-icon) no-repeat","-webkit-mask-size":"100% 100%","mask-size":"100% 100%","background-color":"currentColor",color:"inherit",...k}:E={background:`${M} no-repeat`,"background-size":"100% 100%","background-color":"transparent",...k},C?.(E,{...j,icon:j.name,mode:_}),E},{layer:m,prefix:r}]]}}}function He(e,o,t=new Map){function n(r){if(pe.includes(r))return t.has(r)||t.set(r,e(`${o}@iconify-json/${r}/icons.json`)),t.get(r)}return async(r,i,c)=>{let u=await U(r,i,c);if(u)return u;let d=await n(r);if(d){let g=[i,i.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),i.replace(/([a-z])(\d+)/g,"$1-$2")];u=await X(d,r,g,c)}return u}}function Pt(){let e=typeof process<"u"&&process.stdout,o=e&&!!process.env.VSCODE_CWD,t=e&&!!process.env.ESLINT;return{isNode:e,isVSCode:o,isESLint:t}}async function We(e,o,t={},n=[]){let r="",i="",c,u=new Set([...pe,...n,...Object.keys(t.customCollections||{})]);if(e.includes(":")){if([r,i]=e.split(":"),!u.has(r))return;c=await o(r,i,t)}else{let d=e.split(/-/g);for(let g=At;g>=1&&(r=d.slice(0,g).join("-"),!(!!u.has(r)&&(i=d.slice(g).join("-"),c=await o(r,i,t),c)));g--);}if(c)return{collection:r,name:i,svg:c}}window.__unocss_runtime=window.__unocss_runtime??{};window.__unocss_runtime.presets=Object.assign(window.__unocss_runtime?.presets??{},(()=>{let e=Ke(async o=>{let t=o?.customFetch??(r=>fetch(r).then(i=>i.json())),n=o?.cdn;return n?He(t,n):U});return{presetIcons:o=>e(o)}})());})();
|