@soybeanjs/ui 0.29.0-beta.8 → 0.29.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.
Files changed (33) hide show
  1. package/dist/components/button/button-group.js +1 -1
  2. package/dist/components/button/button-link.vue.d.ts +1 -1
  3. package/dist/components/config-provider/config-provider.js +1 -1
  4. package/dist/components/config-provider/config-provider.vue.d.ts +2 -2
  5. package/dist/components/config-provider/context.js +1 -1
  6. package/dist/components/config-provider/types.d.ts +1 -2
  7. package/dist/components/date-picker/date-picker.js +1 -1
  8. package/dist/components/icon/icon.js +1 -1
  9. package/dist/components/link/link.vue.d.ts +1 -1
  10. package/dist/index.d.ts +3 -3
  11. package/dist/index.js +1 -1
  12. package/dist/resolver/index.js +1 -1
  13. package/dist/styles/alert.d.ts +1 -1
  14. package/dist/styles/button.d.ts +1 -1
  15. package/dist/styles/kbd.d.ts +1 -1
  16. package/dist/styles/pagination.d.ts +1 -1
  17. package/dist/styles/table.d.ts +1 -1
  18. package/dist/styles/tag.d.ts +1 -1
  19. package/dist/styles.css +1 -1
  20. package/package.json +6 -5
  21. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/colord-57U5oVaS.js +0 -1
  22. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/extend-FSiwKBP8.js +0 -1
  23. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/get-CPTLxI_d.js +0 -1
  24. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/hsv-BR8ExPO1.js +0 -1
  25. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/lab-M-Ilnq8I.js +0 -1
  26. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/manipulate-BArvqrxR.js +0 -1
  27. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/palette/index.js +0 -1
  28. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/plugins/lab.js +0 -1
  29. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/rgb-hUGfaW00.js +0 -1
  30. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/utils-Bs7Ugt69.js +0 -1
  31. package/dist/node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/xyz-B1MpSyur.js +0 -1
  32. package/dist/packages/shadcn-theme/src/constants.js +0 -1
  33. package/dist/packages/shadcn-theme/src/shared.js +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soybeanjs/ui",
3
- "version": "0.29.0-beta.8",
3
+ "version": "0.29.0",
4
4
  "description": "SoybeanUI is built on top of SoybeanHeadless, providing a collection of styled components for Vue 3.",
5
5
  "homepage": "https://github.com/soybeanjs/soybean-ui",
6
6
  "bugs": {
@@ -48,8 +48,8 @@
48
48
  "@soybeanjs/cva": "^0.0.9",
49
49
  "@soybeanjs/hooks": "^0.3.0",
50
50
  "@soybeanjs/utils": "^0.1.1",
51
- "@soybeanjs/headless": "^0.29.0-beta.8",
52
- "@soybeanjs/shadcn-theme": "^0.29.0-beta.8"
51
+ "@soybeanjs/headless": "^0.29.0",
52
+ "@soybeanjs/shadcn-theme": "^0.29.0"
53
53
  },
54
54
  "devDependencies": {
55
55
  "@nuxt/kit": "^4.4.8",
@@ -57,18 +57,19 @@
57
57
  "@unocss/cli": "^66.7.2",
58
58
  "@vue/test-utils": "^2.4.11",
59
59
  "axe-core": "^4.12.1",
60
- "happy-dom": "^20.10.3",
60
+ "happy-dom": "^20.10.5",
61
61
  "nuxt": "^4.4.8",
62
62
  "typescript": "^6.0.3",
63
63
  "unocss": "^66.7.2",
64
64
  "unocss-preset-animations": "^1.3.0",
65
65
  "unplugin-vue": "^7.2.0",
66
66
  "unplugin-vue-components": "^32.1.0",
67
+ "vite-plus": "^0.1.24",
67
68
  "vitest": "npm:@voidzero-dev/vite-plus-test@latest",
68
69
  "vue": "^3.5.38",
69
70
  "vue-router": "^5.1.0",
70
71
  "vue-tsc": "^3.3.5",
71
- "@soybeanjs/unocss-shadcn": "^0.29.0-beta.8"
72
+ "@soybeanjs/unocss-shadcn": "^0.29.0"
72
73
  },
73
74
  "peerDependencies": {
74
75
  "@nuxt/kit": "^4.3.0",
@@ -1 +0,0 @@
1
- import{OKLAB_M1 as e,OKLAB_M1_INV as t,OKLAB_M2 as n,OKLAB_M2_INV as r,clamp as i,clampHue as a,isPresent as o,mul3x3 as s,parseAlpha as c,parseHue as l,parseValueToDecimal as u,round as d}from"./utils-Bs7Ugt69.js";import{clampLinearRgb as ee,clampRgb as f,linearRgbToRgb as p,parseRgb as m,parseRgbString as h,rgbToLinearRgb as g,rgbToRgbString as _,roundRgb as v}from"./rgb-hUGfaW00.js";import{parseHsv as te,rgbToHsv as y,roundHsv as b}from"./hsv-BR8ExPO1.js";import{changeAlpha as x,invert as S,lighten as C,parseHsl as w,parseHslString as T,rgbToHsl as E,rgbToHslString as D,roundHsl as O,saturate as k}from"./manipulate-BArvqrxR.js";import{getBrightness as A}from"./get-CPTLxI_d.js";const ne=/^#([0-9a-f]{3,8})$/i,j=e=>{let t=ne.exec(e);if(!t)return null;let n=t[1];return n.length<=4?{r:Number.parseInt(n[0]+n[0],16),g:Number.parseInt(n[1]+n[1],16),b:Number.parseInt(n[2]+n[2],16),alpha:n.length===4?d(Number.parseInt(n[3]+n[3],16)/255,2):1}:n.length===6||n.length===8?{r:Number.parseInt(n.slice(0,2),16),g:Number.parseInt(n.slice(2,4),16),b:Number.parseInt(n.slice(4,6),16),alpha:n.length===8?d(Number.parseInt(n.slice(6,8),16)/255,2):1}:null},M=e=>{let t=Math.round(e).toString(16);return t.length<2?`0${t}`:t},N=e=>{let{r:t,g:n,b:r,alpha:i}=v(e),a=i<1?M(d(i*255)):``;return`#${M(t)}${M(n)}${M(r)}${a}`},P=e=>{let{l:t,c:n,h:r,alpha:o}=e;return{l:i(t,0,1),c:i(n,0,.37),h:a(r),alpha:i(o)}},F=e=>{let{l:t,c:n,h:r,alpha:i}=e;return{l:d(t,3),c:d(n,3),h:d(r,3),alpha:d(i,3)}},I=e=>{let{l:n,c:i,h:a,alpha:o}=e,c=a*Math.PI/180,[l,u,d]=s(t,s(r,[n,i*Math.cos(c),i*Math.sin(c)]).map(e=>e*e*e));return{r:l,g:u,b:d,alpha:o}},L=(e,t=1e-6)=>e.r>=-t&&e.r<=1+t&&e.g>=-t&&e.g<=1+t&&e.b>=-t&&e.b<=1+t,R=(e,t,n)=>{let r=0,i=.37,a=1e-5;if(L(I({l:e,c:i,h:t,alpha:n}),a))return i;for(;i-r>a;){let o=(r+i)/2;L(I({l:e,c:o,h:t,alpha:n}),a)?r=o:i=o}return r},z=e=>{let{l:t,h:n,alpha:r}=e,i=I(e);return L(i)||(i=I({l:t,c:R(t,n,r),h:n,alpha:r})),i=ee(i),f(p(i))},B=t=>{let r=g(t),[i,a,o]=s(n,s(e,[r.r,r.g,r.b]).map(e=>Math.cbrt(e))),c=Math.sqrt(a*a+o*o),l;return c<1e-4?l=0:(l=180/Math.PI*Math.atan2(o,a),l<0&&(l+=360)),P({l:i,c,h:l,alpha:t.alpha})},V=({l:e,c:t,h:n,alpha:r=1})=>!o(e)||!o(t)||!o(n)?null:P({l:Number(e),c:Number(t),h:Number(n),alpha:Number(r)}),H=e=>{let t=V(e);return t?z(t):null},U=/^oklch\(\s*([+-]?[\d.]+)%?\s+([+-]?[\d.]+)\s+([+-]?[\d.]+)(deg|grad|rad|turn)?(?:\s*\/\s*([+-]?[\d.]+%?))?\s*\)$/i,W=e=>{let t=U.exec(e);if(!t)return null;let[n,r,i,a,o,s]=t;return P({l:u(r),c:Number.parseFloat(i),h:l(a,o),alpha:c(s)})},G=e=>{let t=W(e);return t?z(t):null},K=e=>{let{l:t,c:n,h:r,alpha:i}=F(e),a=d(t*100,1);return i<1?`oklch(${a}% ${n} ${r} / ${i})`:`oklch(${a}% ${n} ${r})`},q=e=>K(B(e)),J=e=>{if(!e||e.format!==`oklch`)return null;let{input:t}=e;return typeof t==`string`?W(t):typeof t==`object`?V(t):null},Y=e=>{let t=J(e);return t?K(t):null},X={string:[[j,`hex`],[h,`rgb`],[T,`hsl`],[G,`oklch`]],object:[[m,`rgb`],[w,`hsl`],[te,`hsv`],[H,`oklch`]]},Z=(e,t)=>{for(let n=0;n<t.length;n+=1){let r=t[n][0](e);if(r)return[r,t[n][1]]}return[null,void 0]},re=e=>typeof e==`string`?Z(e.trim(),X.string):typeof e==`object`&&e?Z(e,X.object):[null,void 0],Q=e=>e instanceof $?e:new $(e);var $=class{parsed;rgb;source;constructor(e){let[t,n]=re(e);this.parsed=t,this.rgb=this.parsed||{r:0,g:0,b:0,alpha:1},n&&this.parsed&&(this.source={format:n,input:e})}getSource(){return this.source}isValid(){return this.parsed!==null}brightness(){return d(A(this.rgb),2)}isDark(){return A(this.rgb)<.5}isLight(){return A(this.rgb)>=.5}toHex(){return N(this.rgb)}toRgb(){return v(this.rgb)}toRgbString(){return _(this.rgb)}toHsl(){return O(E(this.rgb))}toHslString(){return D(this.rgb)}toHsv(){return b(y(this.rgb))}toOklch(){return F(J(this.getSource())||B(this.rgb))}toOklchString(){return Y(this.getSource())||q(this.rgb)}invert(){return Q(S(this.rgb))}saturate(e=.1){return Q(k(this.rgb,e))}desaturate(e=.1){return Q(k(this.rgb,-e))}grayscale(){return Q(k(this.rgb,-1))}lighten(e=.1){return Q(C(this.rgb,e))}darken(e=.1){return Q(C(this.rgb,-e))}rotate(e=15){return this.hue(this.hue()+e)}alpha(e){return typeof e==`number`?Q(x(this.rgb,e)):d(this.rgb.alpha,3)}hue(e){let t=E(this.rgb);return typeof e==`number`?Q({h:e,s:t.s,l:t.l,alpha:t.alpha}):d(t.h)}isEqual(e){return this.toHex()===Q(e).toHex()}};export{$ as Colord,X as parsers};
@@ -1 +0,0 @@
1
- import{Colord as e,parsers as t}from"./colord-57U5oVaS.js";const n=[],r=r=>{r.forEach(r=>{n.includes(r)||(r(e,t),n.push(r))})};export{r as extend};
@@ -1 +0,0 @@
1
- import"./rgb-hUGfaW00.js";const e=e=>(e.r*299+e.g*587+e.b*114)/1e3/255;function t(e,t){let{l:n,a:r,b:i}=e,{l:a,a:o,b:s}=t,c=180/Math.PI,l=Math.PI/180,u=((r**2+i**2)**.5+(o**2+s**2)**.5)/2,d=(n+a)/2,f=u**7,p=.5*(1-(f/(f+25**7))**.5),m=r*(1+p),h=o*(1+p),g=(m**2+i**2)**.5,_=(h**2+s**2)**.5,v=(g+_)/2,y=m===0&&i===0?0:Math.atan2(i,m)*c,b=h===0&&s===0?0:Math.atan2(s,h)*c;y<0&&(y+=360),b<0&&(b+=360);let x=b-y,S=Math.abs(b-y);S>180&&b<=y?x+=360:S>180&&b>y&&(x-=360);let C=y+b;S<=180?C/=2:C=(y+b<360?C+360:C-360)/2;let w=1-.17*Math.cos(l*(C-30))+.24*Math.cos(l*2*C)+.32*Math.cos(l*(3*C+6))-.2*Math.cos(l*(4*C-63)),T=a-n,E=_-g,D=2*Math.sin(l*x/2)*(g*_)**.5,O=1+.015*(d-50)**2/(20+(d-50)**2)**.5,k=1+.045*v,A=1+.015*v*w,j=30*Math.exp(-1*((C-275)/25)**2),M=-(2*(f/(f+25**7))**.5)*Math.sin(l*2*j);return((T/1/O)**2+(E/1/k)**2+(D/1/A)**2+M*E*D/(1*k*1*A))**.5}export{e as getBrightness,t as getDeltaE2000};
@@ -1 +0,0 @@
1
- import{clamp as e,clampHue as t,isPresent as n,round as r}from"./utils-Bs7Ugt69.js";const i=n=>({h:t(n.h),s:e(n.s,0,100),v:e(n.v,0,100),alpha:e(n.alpha)}),a=e=>({h:r(e.h,3),s:r(e.s,3),v:r(e.v,3),alpha:r(e.alpha,3)}),o=e=>{let t=e.h/360*6,n=e.s/100,r=e.v/100,i=Math.floor(t),a=r*(1-n),o=r*(1-(t-i)*n),s=r*(1-(1-t+i)*n),c=i%6;return{r:[r,o,a,a,s,r][c]*255,g:[s,r,r,o,a,a][c]*255,b:[a,a,s,r,r,o][c]*255,alpha:e.alpha}},s=({h:e,s:t,v:r,alpha:a=1})=>!n(e)||!n(t)||!n(r)?null:o(i({h:Number(e),s:Number(t),v:Number(r),alpha:Number(a)})),c=({r:e,g:t,b:n,alpha:r})=>{let i=Math.max(e,t,n),a=i-Math.min(e,t,n),o=0;return a&&(o=i===e?(t-n)/a:i===t?2+(n-e)/a:4+(e-t)/a),{h:60*(o<0?o+6:o),s:i?a/i*100:0,v:i/255*100,alpha:r}};export{o as hsvToRgb,s as parseHsv,c as rgbToHsv,a as roundHsv};
@@ -1 +0,0 @@
1
- import{D50 as e,M_D50_TO_D65 as t,M_D65_TO_D50 as n,clamp as r,isPresent as i,mul3x3 as a,parseAlpha as o,round as s}from"./utils-Bs7Ugt69.js";import{clampRgb as c}from"./rgb-hUGfaW00.js";import{rgbToXyz as l,xyzToRgb as u}from"./xyz-B1MpSyur.js";const d=216/24389,f=24389/27,p=e=>{let{l:t,a:n,b:i,alpha:a}=e;return{l:r(t,0,100),a:r(n,-160,160),b:r(i,-160,160),alpha:r(a)}},m=e=>{let{l:t,a:n,b:r,alpha:i}=e;return{l:s(t,3),a:s(n,3),b:s(r,3),alpha:s(i,3)}},h=e=>{let t=l(e),{alpha:r}=t,[i,o,s]=a(n,[t.x,t.y,t.z]);return b({x:i,y:o,z:s,alpha:r})},g=e=>{let n=x(e),[r,i,o]=a(t,[n.x,n.y,n.z]);return u({x:r,y:i,z:o,alpha:e.alpha})},_=(e,t=.01)=>e.r>=-t&&e.r<=255+t&&e.g>=-t&&e.g<=255+t&&e.b>=-t&&e.b<=255+t,v=(e,t,n)=>{let r=0,i=150;if(_(g({l:e,a:i*Math.cos(t),b:i*Math.sin(t),alpha:n})))return i;for(;i-r>.01;){let a=(r+i)/2;_(g({l:e,a:a*Math.cos(t),b:a*Math.sin(t),alpha:n}))?r=a:i=a}return r},y=e=>{let{l:t,a:n,b:r,alpha:i}=e,a=g(e);if(!_(a)&&Math.sqrt(n*n+r*r)>1e-4){let e=Math.atan2(r,n),o=v(t,e,i);a=g({l:t,a:o*Math.cos(e),b:o*Math.sin(e),alpha:i})}return c(a)};function b(t){let{x:n,y:r,z:i,alpha:a}=t,o=n/e.x,s=r/e.y,c=i/e.z,l=e=>e>d?Math.cbrt(e):(f*e+16)/116,u=l(o),p=l(s),m=l(c);return{l:116*p-16,a:500*(u-p),b:200*(p-m),alpha:a}}function x(t){let{l:n,a:r,b:i,alpha:a}=t,o=(n+16)/116,s=r/500+o,c=o-i/200,l=e=>e*e*e>d?e*e*e:(116*e-16)/f,u=l(s),p=n>f*d?((n+16)/116)**3:n/f,m=l(c);return{x:u*e.x,y:p*e.y,z:m*e.z,alpha:a}}const S=({l:e,a:t,b:n,alpha:r=1})=>!i(e)||!i(t)||!i(n)?null:p({l:Number(e),a:Number(t),b:Number(n),alpha:Number(r)}),C=e=>{let t=S(e);return t?y(t):null},w=/^lab\(\s*([+-]?[\d.]+)%?\s+([+-]?[\d.]+)\s+([+-]?[\d.]+)(?:\s*\/\s*([+-]?[\d.]+%?))?\s*\)$/i,T=e=>{let t=w.exec(e);if(!t)return null;let[n,r,i,a,s]=t;return p({l:Number.parseFloat(r),a:Number.parseFloat(i),b:Number.parseFloat(a),alpha:o(s)})},E=e=>{let t=T(e);return t?y(t):null},D=e=>{let{l:t,a:n,b:r,alpha:i}=m(e);return i<1?`lab(${t}% ${n} ${r} / ${i})`:`lab(${t}% ${n} ${r})`},O=e=>D(h(e)),k=e=>{if(!e||e.format!==`lab`)return null;let{input:t}=e;return typeof t==`string`?T(t):typeof t==`object`?S(t):null},A=e=>{let t=k(e);return t?D(t):null};export{C as parseLab,k as parseLabBySource,E as parseLabString,h as rgbToLab,O as rgbToLabString,m as roundLab,A as toLabStringBySource};
@@ -1 +0,0 @@
1
- import{clamp as e,clampHue as t,isPresent as n,parseAlpha as r,parseHue as i,round as a}from"./utils-Bs7Ugt69.js";import{hsvToRgb as o,rgbToHsv as s}from"./hsv-BR8ExPO1.js";import"./lab-M-Ilnq8I.js";const c=n=>{let{h:r,s:i,l:a,alpha:o}=n;return{h:t(r),s:e(i,0,100),l:e(a,0,100),alpha:e(o)}},l=e=>{let{h:t,s:n,l:r,alpha:i}=e;return{h:a(t,3),s:a(n,3),l:a(r,3),alpha:a(i,3)}},u=e=>{let{h:t,l:n,alpha:r}=e,i=e.s*(n<50?n:100-n)/100;return{h:t,s:i>0?2*i/(n+i)*100:0,v:n+i,alpha:r}},d=({h:e,s:t,v:n,alpha:r})=>{let i=(200-t)*n/100;return{h:e,s:i>0&&i<200?t*n/100/(i<=100?i:200-i)*100:0,l:i/2,alpha:r}},f=e=>o(u(e)),p=e=>d(s(e)),m=({h:e,s:t,l:r,alpha:i=1})=>!n(e)||!n(t)||!n(r)?null:f(c({h:Number(e),s:Number(t),l:Number(r),alpha:Number(i)})),h=e=>{let{h:t,s:n,l:r,alpha:i}=l(p(e));return i<1?`hsl(${t} ${n}% ${r}% / ${i})`:`hsl(${t} ${n}% ${r}%)`},g=/^hsl?\(\s*([+-]?[\d.]+)(deg|grad|rad|turn)?\s*[, ]\s*([+-]?[\d.]+)%\s*[, ]\s*([+-]?[\d.]+)%(?:\s*\/\s*([+-]?[\d.]+%?))?\s*\)$/i,_=e=>{let t=g.exec(e);if(!t)return null;let[,n,a,o,s,l]=t;return f(c({h:i(n,a),s:Number.parseFloat(o),l:Number.parseFloat(s),alpha:r(l)}))},v=(e,t)=>({r:e.r,g:e.g,b:e.b,alpha:t}),y=e=>({r:255-e.r,g:255-e.g,b:255-e.b,alpha:e.alpha}),b=(t,n)=>{let r=p(t);return{h:r.h,s:r.s,l:e(r.l+n*100,0,100),alpha:r.alpha}},x=(t,n)=>{let{h:r,s:i,l:a,alpha:o}=p(t);return{h:r,s:e(i+n*100,0,100),l:a,alpha:o}};export{v as changeAlpha,y as invert,b as lighten,m as parseHsl,_ as parseHslString,p as rgbToHsl,h as rgbToHslString,l as roundHsl,x as saturate};
@@ -1 +0,0 @@
1
- import"../colord-57U5oVaS.js";import{extend as e}from"../extend-FSiwKBP8.js";import{labPlugin as t}from"../plugins/lab.js";e([t]);
@@ -1 +0,0 @@
1
- import{clamp as e,round as t}from"../utils-Bs7Ugt69.js";import{parseLab as n,parseLabBySource as r,parseLabString as i,rgbToLab as a,rgbToLabString as o,roundLab as s,toLabStringBySource as c}from"../lab-M-Ilnq8I.js";import{getDeltaE2000 as l}from"../get-CPTLxI_d.js";const u=(u,d)=>{u.prototype.toLab=function(){return s(r(this.getSource())||a(this.rgb))},u.prototype.toLabString=function(){return c(this.getSource())||o(this.rgb)},u.prototype.delta=function(n=`#FFF`){let r=n instanceof u?n:new u(n);return e(t(l(this.toLab(),r.toLab())/100,3))},d.string.push([i,`lab`]),d.object.push([n,`lab`])};export{u as labPlugin};
@@ -1 +0,0 @@
1
- import{clamp as e,isPresent as t,parseAlpha as n,round as r}from"./utils-Bs7Ugt69.js";const i=t=>{let{r:n,g:r,b:i,alpha:a}=t;return{r:e(n,0,255),g:e(r,0,255),b:e(i,0,255),alpha:e(a)}},a=e=>{let{r:t,g:n,b:i,alpha:a}=e;return{r:r(t,2),g:r(n,2),b:r(i,2),alpha:r(a,3)}},o=t=>{let{r:n,g:r,b:i,alpha:a}=t;return{r:e(n),g:e(r),b:e(i),alpha:e(a)}},s=({r:e,g:n,b:r,alpha:a=1})=>!t(e)||!t(n)||!t(r)?null:i({r:Number(e),g:Number(n),b:Number(r),alpha:Number(a)}),c=e=>{let t=e/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4};function l(e){return(e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055)*255}function u(e){return{r:c(e.r),g:c(e.g),b:c(e.b),alpha:e.alpha}}function d(e){return{r:l(e.r),g:l(e.g),b:l(e.b),alpha:e.alpha}}const f=/^rgb?\(\s*([\d.]+%?)\s*[, ]\s*([\d.]+%?)\s*[, ]\s*([\d.]+%?)(?:\s*[,/]\s*([\d.]+%?))?\s*\)$/i,p=e=>{let t=f.exec(e);if(!t)return null;let[r,a,o,s,c]=t;return i({r:m(a),g:m(o),b:m(s),alpha:n(c)})};function m(e){if(e.endsWith(`%`)){let t=Number.parseFloat(e.slice(0,-1));return Math.round(t/100*255)}return Number.parseFloat(e)}const h=e=>{let{r:t,g:n,b:r,alpha:i}=a(e);return i<1?`rgb(${t} ${n} ${r} / ${i})`:`rgb(${t} ${n} ${r})`};export{o as clampLinearRgb,i as clampRgb,d as linearRgbToRgb,s as parseRgb,p as parseRgbString,u as rgbToLinearRgb,h as rgbToRgbString,a as roundRgb};
@@ -1 +0,0 @@
1
- const e={grad:360/400,turn:360,rad:360/(Math.PI*2)},t={x:.95047,y:1,z:1.08883},n={x:.96422,y:1,z:.82521},r=[[.4122214708,.5363325363,.0514459929],[.2119034982,.6806995451,.1073969566],[.0883024619,.2817188376,.6299787005]],i=[[4.076741661347993,-3.3077115904081937,.2309699287294278],[-1.2684380040921763,2.609757400663372,-.3413193963102196],[-.0041960865418371,-.7034186144594495,1.7076147009309446]],a=[[.2104542553,.793617785,-.0040720468],[1.9779984951,-2.428592205,.4505937099],[.0259040371,.7827717662,-.808675766]],o=[[.9999999984505198,.3963377921737678,.2158037580607588],[1.0000000088817607,-.1055613423236563,-.0638541747717059],[1.0000000546724108,-.0894841820949657,-1.2914855378640917]],s=[[.4124564391,.3575760776,.1804374833],[.2126728514,.7151521552,.0721749934],[.0193338956,.1191920259,.9503040785]],c=[[3.2404541621,-1.5371385127,-.4985314095],[-.9692660305,1.8760108454,.0415560175],[.055643431,-.2040259135,1.0572251882]],l=[[1.0478112,.0228866,-.050127],[.0295424,.9904844,-.0170491],[-.0092345,.0150436,.7521316]],u=[[.9555766,-.0230393,.0631636],[-.0282895,1.0099416,.0210077],[.0122982,-.020483,1.3299098]],d=e=>typeof e==`string`?e.length>0:typeof e==`number`,f=(e,t=0)=>{let n=10**t;return Math.round(n*e)/n+0},p=(e,t=0,n=1)=>e>n?n:e<t?t:e,m=e=>{let t=Number.isFinite(e)?e%360:0;return t>0?t:t+360},h=(t,n=`deg`)=>Number.parseFloat(t)*(e[n]||1);function g(e,t){return[e[0][0]*t[0]+e[0][1]*t[1]+e[0][2]*t[2],e[1][0]*t[0]+e[1][1]*t[1]+e[1][2]*t[2],e[2][0]*t[0]+e[2][1]*t[1]+e[2][2]*t[2]]}function _(e){if(!e)return 1;let t=Number.parseFloat(e);return e.endsWith(`%`)&&(t/=100),t}function v(e){let t=Number.parseFloat(e);return e.endsWith(`%`)||t>1?p(t/100):p(t)}export{n as D50,t as D65,u as M_D50_TO_D65,l as M_D65_TO_D50,s as M_SRGB_TO_XYZ_D65,c as M_XYZ_D65_TO_SRGB,r as OKLAB_M1,i as OKLAB_M1_INV,a as OKLAB_M2,o as OKLAB_M2_INV,p as clamp,m as clampHue,d as isPresent,g as mul3x3,_ as parseAlpha,h as parseHue,v as parseValueToDecimal,f as round};
@@ -1 +0,0 @@
1
- import{D65 as e,M_SRGB_TO_XYZ_D65 as t,M_XYZ_D65_TO_SRGB as n,clamp as r,mul3x3 as i}from"./utils-Bs7Ugt69.js";import{clampRgb as a,linearRgbToRgb as o,rgbToLinearRgb as s}from"./rgb-hUGfaW00.js";const c=t=>{let{x:n,y:i,z:a,alpha:o}=t;return{x:r(n,0,e.x*1.2),y:r(i,0,e.y*1.2),z:r(a,0,e.z*1.2),alpha:r(o)}},l=e=>{let{x:t,y:r,z:s,alpha:c}=e,[l,u,d]=i(n,[t,r,s]);return a(o({r:l,g:u,b:d,alpha:c}))},u=e=>{let{r:n,g:r,b:a,alpha:o}=s(e),[l,u,d]=i(t,[n,r,a]);return c({x:l,y:u,z:d,alpha:o})};export{u as rgbToXyz,l as xyzToRgb};
@@ -1 +0,0 @@
1
- import{keysOf as e}from"./shared.js";const t={size:`data-ui-size`,radius:`data-ui-radius`,menuColor:`data-ui-menu-color`,menuAccent:`data-ui-menu-accent`,base:`data-ui-base-color`,primary:`data-ui-primary-color`,feedback:`data-ui-feedback-color`},n={background:`--background`,foreground:`--foreground`,card:`--card`,cardForeground:`--card-foreground`,popover:`--popover`,popoverForeground:`--popover-foreground`,primary:`--primary`,primaryForeground:`--primary-foreground`,secondary:`--secondary`,secondaryForeground:`--secondary-foreground`,muted:`--muted`,mutedForeground:`--muted-foreground`,accent:`--accent`,accentForeground:`--accent-foreground`,destructive:`--destructive`,destructiveForeground:`--destructive-foreground`,border:`--border`,input:`--input`,ring:`--ring`,success:`--success`,successForeground:`--success-foreground`,warning:`--warning`,warningForeground:`--warning-foreground`,info:`--info`,infoForeground:`--info-foreground`,carbon:`--carbon`,carbonForeground:`--carbon-foreground`,sidebar:`--sidebar`,sidebarForeground:`--sidebar-foreground`,sidebarPrimary:`--sidebar-primary`,sidebarPrimaryForeground:`--sidebar-primary-foreground`,sidebarAccent:`--sidebar-accent`,sidebarAccentForeground:`--sidebar-accent-foreground`,sidebarBorder:`--sidebar-border`,sidebarRing:`--sidebar-ring`,chart1:`--chart-1`,chart2:`--chart-2`,chart3:`--chart-3`,chart4:`--chart-4`,chart5:`--chart-5`},r={bg:`--menu-bg`,bgAlpha:`--menu-bg-alpha`,dropBlur:`--menu-drop-blur`,backdropSaturate:`--menu-backdrop-saturate`,itemAccentBackground:`--menu-item-accent-background`,itemAccentForeground:`--menu-item-accent-foreground`},i={size:`md`,radius:`md`,base:`zinc`,primary:`indigo`,feedback:`classic`,menuColor:`default`,menuAccent:`subtle`,scope:`all`,styleTarget:`:root`,darkSelector:`class`,format:`hsl`},a=`oklch(100% 0 0 / 0.1)`,o=`oklch(100% 0 0 / 0.15)`;e({xs:12,sm:14,md:16,lg:18,xl:20,"2xl":24}),e({"2xs":`0.25rem`,xs:`0.375rem`,sm:`0.5rem`,md:`0.625rem`,lg:`0.75rem`,xl:`0.875rem`,"2xl":`1rem`}),r.bg,`${n.popover}`,r.bgAlpha,r.dropBlur,r.backdropSaturate,r.bg,`${n.popover}`,r.bgAlpha,r.dropBlur,r.backdropSaturate,r.bg,`${n.card}`,r.bgAlpha,r.dropBlur,r.backdropSaturate,r.bg,`${n.card}`,r.bgAlpha,r.dropBlur,r.backdropSaturate,r.itemAccentBackground,`${n.foreground}`,r.itemAccentForeground,`${n.foreground}`,r.itemAccentBackground,`${n.primary}`,r.itemAccentForeground,`${n.primary}`,`${n.background}`,`${n.foreground}`,`${n.primary}`,`${n.primaryForeground}`,`${n.accent}`,`${n.accentForeground}`,`${n.border}`,`${n.ring}`,`${n.card}`;const s={slate:{light:{background:`white`,foreground:`slate.950`,card:`white`,cardForeground:`slate.950`,popover:`white`,popoverForeground:`slate.950`,primaryForeground:`slate.50`,secondary:`slate.100`,secondaryForeground:`slate.900`,muted:`slate.100`,mutedForeground:`slate.500`,accent:`slate.100`,accentForeground:`slate.900`,destructiveForeground:`slate.50`,successForeground:`slate.50`,warningForeground:`slate.50`,infoForeground:`slate.50`,carbon:`slate.800`,carbonForeground:`slate.50`,border:`slate.200`,input:`slate.200`},dark:{background:`slate.950`,foreground:`slate.50`,card:`slate.900`,cardForeground:`slate.50`,popover:`slate.900`,popoverForeground:`slate.50`,primaryForeground:`slate.900`,secondary:`slate.800`,secondaryForeground:`slate.50`,muted:`slate.800`,mutedForeground:`slate.400`,accent:`slate.800`,accentForeground:`slate.50`,carbon:`slate.100`,destructiveForeground:`slate.900`,successForeground:`slate.900`,warningForeground:`slate.900`,infoForeground:`slate.900`,carbonForeground:`slate.900`,border:a,input:o}},mist:{light:{background:`white`,foreground:`mist.950`,card:`white`,cardForeground:`mist.950`,popover:`white`,popoverForeground:`mist.950`,primaryForeground:`mist.50`,secondary:`mist.100`,secondaryForeground:`mist.900`,muted:`mist.100`,mutedForeground:`mist.500`,accent:`mist.100`,accentForeground:`mist.900`,destructiveForeground:`mist.50`,successForeground:`mist.50`,warningForeground:`mist.50`,infoForeground:`mist.50`,carbon:`mist.800`,carbonForeground:`mist.50`,border:`mist.200`,input:`mist.200`},dark:{background:`mist.950`,foreground:`mist.50`,card:`mist.900`,cardForeground:`mist.50`,popover:`mist.900`,popoverForeground:`mist.50`,primaryForeground:`mist.900`,secondary:`mist.800`,secondaryForeground:`mist.50`,muted:`mist.800`,mutedForeground:`mist.400`,accent:`mist.800`,accentForeground:`mist.50`,carbon:`mist.100`,destructiveForeground:`mist.900`,successForeground:`mist.900`,warningForeground:`mist.900`,infoForeground:`mist.900`,carbonForeground:`mist.900`,border:a,input:o}},gray:{light:{background:`white`,foreground:`gray.950`,card:`white`,cardForeground:`gray.950`,popover:`white`,popoverForeground:`gray.950`,primaryForeground:`gray.50`,secondary:`gray.100`,secondaryForeground:`gray.900`,muted:`gray.100`,mutedForeground:`gray.500`,accent:`gray.100`,accentForeground:`gray.900`,carbon:`gray.800`,destructiveForeground:`gray.50`,successForeground:`gray.50`,warningForeground:`gray.50`,infoForeground:`gray.50`,carbonForeground:`gray.50`,border:`gray.200`,input:`gray.200`},dark:{background:`gray.950`,foreground:`gray.50`,card:`gray.900`,cardForeground:`gray.50`,popover:`gray.900`,popoverForeground:`gray.50`,primaryForeground:`gray.900`,secondary:`gray.800`,secondaryForeground:`gray.50`,muted:`gray.800`,mutedForeground:`gray.400`,accent:`gray.800`,accentForeground:`gray.50`,carbon:`gray.100`,destructiveForeground:`gray.900`,successForeground:`gray.900`,warningForeground:`gray.900`,infoForeground:`gray.900`,carbonForeground:`gray.900`,border:a,input:o}},zinc:{light:{background:`white`,foreground:`zinc.950`,card:`white`,cardForeground:`zinc.950`,popover:`white`,popoverForeground:`zinc.950`,primaryForeground:`zinc.50`,secondary:`zinc.100`,secondaryForeground:`zinc.900`,muted:`zinc.100`,mutedForeground:`zinc.500`,accent:`zinc.100`,accentForeground:`zinc.900`,destructiveForeground:`zinc.50`,successForeground:`zinc.50`,warningForeground:`zinc.50`,infoForeground:`zinc.50`,carbon:`zinc.800`,carbonForeground:`zinc.50`,border:`zinc.200`,input:`zinc.200`},dark:{background:`zinc.950`,foreground:`zinc.50`,card:`zinc.900`,cardForeground:`zinc.50`,popover:`zinc.900`,popoverForeground:`zinc.50`,primaryForeground:`zinc.900`,secondary:`zinc.800`,secondaryForeground:`zinc.50`,muted:`zinc.800`,mutedForeground:`zinc.400`,accent:`zinc.800`,accentForeground:`zinc.50`,destructiveForeground:`zinc.900`,successForeground:`zinc.900`,warningForeground:`zinc.900`,infoForeground:`zinc.900`,carbon:`zinc.100`,carbonForeground:`zinc.900`,border:a,input:o}},neutral:{light:{background:`white`,foreground:`neutral.950`,card:`white`,cardForeground:`neutral.950`,popover:`white`,popoverForeground:`neutral.950`,primaryForeground:`neutral.50`,secondary:`neutral.100`,secondaryForeground:`neutral.900`,muted:`neutral.100`,mutedForeground:`neutral.500`,accent:`neutral.100`,accentForeground:`neutral.900`,destructiveForeground:`neutral.50`,successForeground:`neutral.50`,warningForeground:`neutral.50`,infoForeground:`neutral.50`,carbon:`neutral.800`,carbonForeground:`neutral.50`,border:`neutral.200`,input:`neutral.200`},dark:{background:`neutral.950`,foreground:`neutral.50`,card:`neutral.900`,cardForeground:`neutral.50`,popover:`neutral.900`,popoverForeground:`neutral.50`,primaryForeground:`neutral.900`,secondary:`neutral.800`,secondaryForeground:`neutral.50`,muted:`neutral.800`,mutedForeground:`neutral.400`,accent:`neutral.800`,accentForeground:`neutral.50`,destructiveForeground:`neutral.900`,successForeground:`neutral.900`,warningForeground:`neutral.900`,infoForeground:`neutral.900`,carbon:`neutral.100`,carbonForeground:`neutral.900`,border:a,input:o}},stone:{light:{background:`white`,foreground:`stone.950`,card:`white`,cardForeground:`stone.950`,popover:`white`,popoverForeground:`stone.950`,primaryForeground:`stone.50`,secondary:`stone.100`,secondaryForeground:`stone.900`,muted:`stone.100`,mutedForeground:`stone.500`,accent:`stone.100`,accentForeground:`stone.900`,destructiveForeground:`stone.50`,successForeground:`stone.50`,warningForeground:`stone.50`,infoForeground:`stone.50`,carbon:`stone.800`,carbonForeground:`stone.50`,border:`stone.200`,input:`stone.200`},dark:{background:`stone.950`,foreground:`stone.50`,card:`stone.900`,cardForeground:`stone.50`,popover:`stone.900`,popoverForeground:`stone.50`,primaryForeground:`stone.900`,secondary:`stone.800`,secondaryForeground:`stone.50`,muted:`stone.800`,mutedForeground:`stone.400`,accent:`stone.800`,accentForeground:`stone.50`,destructiveForeground:`stone.900`,successForeground:`stone.900`,warningForeground:`stone.900`,infoForeground:`stone.900`,carbon:`stone.100`,carbonForeground:`stone.900`,border:a,input:o}},taupe:{light:{background:`white`,foreground:`taupe.950`,card:`white`,cardForeground:`taupe.950`,popover:`white`,popoverForeground:`taupe.950`,primaryForeground:`taupe.50`,secondary:`taupe.100`,secondaryForeground:`taupe.900`,muted:`taupe.100`,mutedForeground:`taupe.500`,accent:`taupe.100`,accentForeground:`taupe.900`,destructiveForeground:`taupe.50`,successForeground:`taupe.50`,warningForeground:`taupe.50`,infoForeground:`taupe.50`,carbon:`taupe.800`,carbonForeground:`taupe.50`,border:`taupe.200`,input:`taupe.200`},dark:{background:`taupe.950`,foreground:`taupe.50`,card:`taupe.900`,cardForeground:`taupe.50`,popover:`taupe.900`,popoverForeground:`taupe.50`,primaryForeground:`taupe.900`,secondary:`taupe.800`,secondaryForeground:`taupe.50`,muted:`taupe.800`,mutedForeground:`taupe.400`,accent:`taupe.800`,accentForeground:`taupe.50`,destructiveForeground:`taupe.900`,successForeground:`taupe.900`,warningForeground:`taupe.900`,infoForeground:`taupe.900`,carbon:`taupe.100`,carbonForeground:`taupe.900`,border:a,input:o}},olive:{light:{background:`white`,foreground:`olive.950`,card:`white`,cardForeground:`olive.950`,popover:`white`,popoverForeground:`olive.950`,primaryForeground:`olive.50`,secondary:`olive.100`,secondaryForeground:`olive.900`,muted:`olive.100`,mutedForeground:`olive.500`,accent:`olive.100`,accentForeground:`olive.900`,destructiveForeground:`olive.50`,successForeground:`olive.50`,warningForeground:`olive.50`,infoForeground:`olive.50`,carbon:`olive.800`,carbonForeground:`olive.50`,border:`olive.200`,input:`olive.200`},dark:{background:`olive.950`,foreground:`olive.50`,card:`olive.900`,cardForeground:`olive.50`,popover:`olive.900`,popoverForeground:`olive.50`,primaryForeground:`olive.900`,secondary:`olive.800`,secondaryForeground:`olive.50`,muted:`olive.800`,mutedForeground:`olive.400`,accent:`olive.800`,accentForeground:`olive.50`,destructiveForeground:`olive.900`,successForeground:`olive.900`,warningForeground:`olive.900`,infoForeground:`olive.900`,carbon:`olive.100`,carbonForeground:`olive.900`,border:a,input:o}},mauve:{light:{background:`white`,foreground:`mauve.950`,card:`white`,cardForeground:`mauve.950`,popover:`white`,popoverForeground:`mauve.950`,primaryForeground:`mauve.50`,secondary:`mauve.100`,secondaryForeground:`mauve.900`,muted:`mauve.100`,mutedForeground:`mauve.500`,accent:`mauve.100`,accentForeground:`mauve.900`,destructiveForeground:`mauve.50`,successForeground:`mauve.50`,warningForeground:`mauve.50`,infoForeground:`mauve.50`,carbon:`mauve.800`,carbonForeground:`mauve.50`,border:`mauve.200`,input:`mauve.200`},dark:{background:`mauve.950`,foreground:`mauve.50`,card:`mauve.900`,cardForeground:`mauve.50`,popover:`mauve.900`,popoverForeground:`mauve.50`,primaryForeground:`mauve.900`,secondary:`mauve.800`,secondaryForeground:`mauve.50`,muted:`mauve.800`,mutedForeground:`mauve.400`,accent:`mauve.800`,accentForeground:`mauve.50`,destructiveForeground:`mauve.900`,successForeground:`mauve.900`,warningForeground:`mauve.900`,infoForeground:`mauve.900`,carbon:`mauve.100`,carbonForeground:`mauve.900`,border:a,input:o}}},c={slate:{light:{primary:`slate.800`,ring:`slate.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`slate.200`,ring:`slate.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},mist:{light:{primary:`mist.800`,ring:`mist.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`mist.200`,ring:`mist.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},gray:{light:{primary:`gray.800`,ring:`gray.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`gray.200`,ring:`gray.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},zinc:{light:{primary:`zinc.800`,ring:`zinc.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`zinc.200`,ring:`zinc.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},neutral:{light:{primary:`neutral.800`,ring:`neutral.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`neutral.200`,ring:`neutral.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},stone:{light:{primary:`stone.800`,ring:`stone.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`stone.200`,ring:`stone.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},taupe:{light:{primary:`taupe.800`,ring:`taupe.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`taupe.200`,ring:`taupe.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},olive:{light:{primary:`olive.800`,ring:`olive.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`olive.200`,ring:`olive.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},mauve:{light:{primary:`mauve.800`,ring:`mauve.400`,chart1:`orange.600`,chart2:`teal.600`,chart3:`cyan.900`,chart4:`amber.400`,chart5:`amber.500`},dark:{primary:`mauve.200`,ring:`mauve.500`,chart1:`blue.700`,chart2:`emerald.500`,chart3:`amber.500`,chart4:`purple.500`,chart5:`rose.500`}},red:{light:{primary:`red.500`,ring:`red.400`,chart1:`red.300`,chart2:`red.500`,chart3:`red.600`,chart4:`red.700`,chart5:`red.800`},dark:{primary:`red.500`,ring:`red.900`,chart1:`red.300`,chart2:`red.500`,chart3:`red.600`,chart4:`red.700`,chart5:`red.800`}},orange:{light:{primary:`orange.500`,ring:`orange.400`,chart1:`orange.300`,chart2:`orange.500`,chart3:`orange.600`,chart4:`orange.700`,chart5:`orange.800`},dark:{primary:`orange.500`,ring:`orange.900`,chart1:`orange.300`,chart2:`orange.500`,chart3:`orange.600`,chart4:`orange.700`,chart5:`orange.800`}},amber:{light:{primary:`amber.500`,ring:`amber.400`,chart1:`amber.300`,chart2:`amber.500`,chart3:`amber.600`,chart4:`amber.700`,chart5:`amber.800`},dark:{primary:`amber.500`,ring:`amber.900`,chart1:`amber.300`,chart2:`amber.500`,chart3:`amber.600`,chart4:`amber.700`,chart5:`amber.800`}},yellow:{light:{primary:`yellow.500`,ring:`yellow.400`,chart1:`yellow.300`,chart2:`yellow.500`,chart3:`yellow.600`,chart4:`yellow.700`,chart5:`yellow.800`},dark:{primary:`yellow.500`,ring:`yellow.900`,chart1:`yellow.300`,chart2:`yellow.500`,chart3:`yellow.600`,chart4:`yellow.700`,chart5:`yellow.800`}},lime:{light:{primary:`lime.500`,ring:`lime.400`,chart1:`lime.300`,chart2:`lime.500`,chart3:`lime.600`,chart4:`lime.700`,chart5:`lime.800`},dark:{primary:`lime.600`,ring:`lime.900`,chart1:`lime.300`,chart2:`lime.500`,chart3:`lime.600`,chart4:`lime.700`,chart5:`lime.800`}},green:{light:{primary:`green.500`,ring:`green.400`,chart1:`green.300`,chart2:`green.500`,chart3:`green.600`,chart4:`green.700`,chart5:`green.800`},dark:{primary:`green.600`,ring:`green.900`,chart1:`green.300`,chart2:`green.500`,chart3:`green.600`,chart4:`green.700`,chart5:`green.800`}},emerald:{light:{primary:`emerald.500`,ring:`emerald.400`,chart1:`emerald.300`,chart2:`emerald.500`,chart3:`emerald.600`,chart4:`emerald.700`,chart5:`emerald.800`},dark:{primary:`emerald.600`,ring:`emerald.900`,chart1:`emerald.300`,chart2:`emerald.500`,chart3:`emerald.600`,chart4:`emerald.700`,chart5:`emerald.800`}},teal:{light:{primary:`teal.500`,ring:`teal.400`,chart1:`teal.300`,chart2:`teal.500`,chart3:`teal.600`,chart4:`teal.700`,chart5:`teal.800`},dark:{primary:`teal.500`,ring:`teal.900`,chart1:`teal.300`,chart2:`teal.500`,chart3:`teal.600`,chart4:`teal.700`,chart5:`teal.800`}},cyan:{light:{primary:`cyan.500`,ring:`cyan.400`,chart1:`cyan.300`,chart2:`cyan.500`,chart3:`cyan.600`,chart4:`cyan.700`,chart5:`cyan.800`},dark:{primary:`cyan.500`,ring:`cyan.900`,chart1:`cyan.300`,chart2:`cyan.500`,chart3:`cyan.600`,chart4:`cyan.700`,chart5:`cyan.800`}},sky:{light:{primary:`sky.500`,ring:`sky.400`,chart1:`sky.300`,chart2:`sky.500`,chart3:`sky.600`,chart4:`sky.700`,chart5:`sky.800`},dark:{primary:`sky.500`,ring:`sky.900`,chart1:`sky.300`,chart2:`sky.500`,chart3:`sky.600`,chart4:`sky.700`,chart5:`sky.800`}},blue:{light:{primary:`blue.500`,ring:`blue.400`,chart1:`blue.300`,chart2:`blue.500`,chart3:`blue.600`,chart4:`blue.700`,chart5:`blue.800`},dark:{primary:`blue.500`,ring:`blue.900`,chart1:`blue.300`,chart2:`blue.500`,chart3:`blue.600`,chart4:`blue.700`,chart5:`blue.800`}},indigo:{light:{primary:`indigo.500`,ring:`indigo.400`,chart1:`indigo.300`,chart2:`indigo.500`,chart3:`indigo.600`,chart4:`indigo.700`,chart5:`indigo.800`},dark:{primary:`indigo.500`,ring:`indigo.900`,chart1:`indigo.300`,chart2:`indigo.500`,chart3:`indigo.600`,chart4:`indigo.700`,chart5:`indigo.800`}},violet:{light:{primary:`violet.500`,ring:`violet.400`,chart1:`violet.300`,chart2:`violet.500`,chart3:`violet.600`,chart4:`violet.700`,chart5:`violet.800`},dark:{primary:`violet.500`,ring:`violet.900`,chart1:`violet.300`,chart2:`violet.500`,chart3:`violet.600`,chart4:`violet.700`,chart5:`violet.800`}},purple:{light:{primary:`purple.500`,ring:`purple.400`,chart1:`purple.300`,chart2:`purple.500`,chart3:`purple.600`,chart4:`purple.700`,chart5:`purple.800`},dark:{primary:`purple.500`,ring:`purple.900`,chart1:`purple.300`,chart2:`purple.500`,chart3:`purple.600`,chart4:`purple.700`,chart5:`purple.800`}},fuchsia:{light:{primary:`fuchsia.500`,ring:`fuchsia.400`,chart1:`fuchsia.300`,chart2:`fuchsia.500`,chart3:`fuchsia.600`,chart4:`fuchsia.700`,chart5:`fuchsia.800`},dark:{primary:`fuchsia.500`,ring:`fuchsia.900`,chart1:`fuchsia.300`,chart2:`fuchsia.500`,chart3:`fuchsia.600`,chart4:`fuchsia.700`,chart5:`fuchsia.800`}},pink:{light:{primary:`pink.500`,ring:`pink.400`,chart1:`pink.300`,chart2:`pink.500`,chart3:`pink.600`,chart4:`pink.700`,chart5:`pink.800`},dark:{primary:`pink.500`,ring:`pink.900`,chart1:`pink.300`,chart2:`pink.500`,chart3:`pink.600`,chart4:`pink.700`,chart5:`pink.800`}},rose:{light:{primary:`rose.500`,ring:`rose.400`,chart1:`rose.300`,chart2:`rose.500`,chart3:`rose.600`,chart4:`rose.700`,chart5:`rose.800`},dark:{primary:`rose.500`,ring:`rose.900`,chart1:`rose.300`,chart2:`rose.500`,chart3:`rose.600`,chart4:`rose.700`,chart5:`rose.800`}}},l={classic:{light:{destructive:`red.500`,success:`green.500`,warning:`amber.500`,info:`blue.500`},dark:{destructive:`red.400`,success:`green.400`,warning:`amber.400`,info:`blue.400`}},vivid:{light:{destructive:`red.500`,success:`emerald.500`,warning:`amber.500`,info:`sky.500`},dark:{destructive:`red.400`,success:`emerald.400`,warning:`amber.400`,info:`sky.400`}},subtle:{light:{destructive:`rose.500`,success:`emerald.500`,warning:`amber.500`,info:`indigo.500`},dark:{destructive:`rose.300`,success:`emerald.300`,warning:`amber.300`,info:`indigo.300`}},warm:{light:{destructive:`red.500`,success:`lime.500`,warning:`orange.500`,info:`amber.600`},dark:{destructive:`red.400`,success:`lime.400`,warning:`orange.400`,info:`amber.400`}},cool:{light:{destructive:`rose.500`,success:`teal.500`,warning:`cyan.600`,info:`blue.500`},dark:{destructive:`rose.400`,success:`teal.400`,warning:`cyan.400`,info:`blue.400`}},nature:{light:{destructive:`red.500`,success:`green.600`,warning:`lime.600`,info:`teal.600`},dark:{destructive:`red.300`,success:`green.300`,warning:`lime.300`,info:`teal.300`}},modern:{light:{destructive:`red.500`,success:`emerald.500`,warning:`orange.500`,info:`sky.500`},dark:{destructive:`red.400`,success:`emerald.400`,warning:`orange.400`,info:`sky.400`}},vibrant:{light:{destructive:`red.500`,success:`lime.500`,warning:`amber.500`,info:`cyan.500`},dark:{destructive:`pink.400`,success:`lime.400`,warning:`amber.400`,info:`cyan.400`}},professional:{light:{destructive:`red.500`,success:`green.600`,warning:`amber.600`,info:`blue.600`},dark:{destructive:`red.300`,success:`green.300`,warning:`amber.300`,info:`blue.300`}},soft:{light:{destructive:`rose.400`,success:`teal.400`,warning:`yellow.400`,info:`violet.400`},dark:{destructive:`rose.300`,success:`teal.300`,warning:`yellow.300`,info:`violet.300`}},bold:{light:{destructive:`red.600`,success:`emerald.600`,warning:`orange.600`,info:`blue.600`},dark:{destructive:`red.300`,success:`emerald.300`,warning:`orange.300`,info:`blue.300`}},calm:{light:{destructive:`rose.500`,success:`teal.500`,warning:`amber.500`,info:`slate.500`},dark:{destructive:`rose.400`,success:`teal.400`,warning:`amber.400`,info:`slate.400`}},candy:{light:{destructive:`pink.400`,success:`emerald.400`,warning:`yellow.400`,info:`sky.400`},dark:{destructive:`pink.300`,success:`emerald.300`,warning:`yellow.300`,info:`sky.300`}},deep:{light:{destructive:`red.600`,success:`green.700`,warning:`amber.700`,info:`blue.700`},dark:{destructive:`red.200`,success:`green.200`,warning:`amber.200`,info:`blue.200`}},light:{light:{destructive:`red.400`,success:`emerald.400`,warning:`amber.400`,info:`sky.400`},dark:{destructive:`red.400`,success:`emerald.400`,warning:`amber.400`,info:`sky.400`}}};e(s),e(c),e(l),e(s.zinc.light),e(c.indigo.light),e(l.classic.light);export{i as DEFAULT_PRESET_OPTIONS,t as UI_DATA_ATTRIBUTE};
@@ -1 +0,0 @@
1
- import"../../../node_modules/.pnpm/@soybeanjs_colord@0.6.2/node_modules/@soybeanjs/colord/dist/palette/index.js";import{DEFAULT_PRESET_OPTIONS as e,UI_DATA_ATTRIBUTE as t}from"./constants.js";import"@soybeanjs/colord";function n(e){return Object.keys(e)}function r(n,r){let i=[`size`,`radius`,`base`,`primary`,`feedback`,`menuColor`,`menuAccent`],a=document.documentElement;i.forEach(i=>{let o=t[i],s=n?.[i],c=e[i];if(!n||!s){a.setAttribute(o,c);return}s!==r?.[i]&&a.setAttribute(o,s||c)})}export{n as keysOf,r as updateUiAttribute};