@a_ng_d/utils-ui-color-palette 1.3.13 → 1.3.15
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.
|
@@ -13,7 +13,7 @@ export default class Data {
|
|
|
13
13
|
meta?: MetaConfiguration;
|
|
14
14
|
});
|
|
15
15
|
makePaletteData: () => PaletteData;
|
|
16
|
-
makeLibraryData: (options?: Array<"collection_id" | "mode_id" | "variable_id" | "style_id" | "gl" | "hex" | "description">, previousData?: Array<LibraryData>) => LibraryData[];
|
|
17
|
-
makePaletteFullData: (
|
|
16
|
+
makeLibraryData: (options?: Array<"collection_id" | "mode_id" | "variable_id" | "style_id" | "gl" | "hex" | "description" | "alpha">, previousData?: Array<LibraryData>) => LibraryData[];
|
|
17
|
+
makePaletteFullData: () => FullConfiguration;
|
|
18
18
|
}
|
|
19
19
|
//# sourceMappingURL=data.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../src/modules/data/data.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,WAAW,EACX,WAAW,EAGZ,MAAM,iBAAiB,CAAA;AACxB,OAAO,EACL,iBAAiB,EACjB,iBAAiB,EAEjB,kBAAkB,EAClB,iBAAiB,EAClB,MAAM,0BAA0B,CAAA;AAIjC,MAAM,CAAC,OAAO,OAAO,IAAI;IACvB,OAAO,CAAC,IAAI,CAAmB;IAC/B,OAAO,CAAC,MAAM,CAA2B;IACzC,OAAO,CAAC,IAAI,CAAC,CAAmB;IAChC,OAAO,CAAC,WAAW,CAAa;IAChC,OAAO,CAAC,YAAY,CAAoB;gBAE5B,EACV,IAAI,EACJ,MAAM,EACN,IAAI,GACL,EAAE;QACD,IAAI,EAAE,iBAAiB,CAAA;QACvB,MAAM,EAAE,KAAK,CAAC,kBAAkB,CAAC,CAAA;QACjC,IAAI,CAAC,EAAE,iBAAiB,CAAA;KACzB;IAeD,eAAe,oBAmUd;IAED,eAAe,aACH,KAAK,CACX,eAAe,GACf,SAAS,GACT,aAAa,GACb,UAAU,GACV,IAAI,GACJ,KAAK,GACL,aAAa,
|
|
1
|
+
{"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../src/modules/data/data.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,WAAW,EACX,WAAW,EAGZ,MAAM,iBAAiB,CAAA;AACxB,OAAO,EACL,iBAAiB,EACjB,iBAAiB,EAEjB,kBAAkB,EAClB,iBAAiB,EAClB,MAAM,0BAA0B,CAAA;AAIjC,MAAM,CAAC,OAAO,OAAO,IAAI;IACvB,OAAO,CAAC,IAAI,CAAmB;IAC/B,OAAO,CAAC,MAAM,CAA2B;IACzC,OAAO,CAAC,IAAI,CAAC,CAAmB;IAChC,OAAO,CAAC,WAAW,CAAa;IAChC,OAAO,CAAC,YAAY,CAAoB;gBAE5B,EACV,IAAI,EACJ,MAAM,EACN,IAAI,GACL,EAAE;QACD,IAAI,EAAE,iBAAiB,CAAA;QACvB,MAAM,EAAE,KAAK,CAAC,kBAAkB,CAAC,CAAA;QACjC,IAAI,CAAC,EAAE,iBAAiB,CAAA;KACzB;IAeD,eAAe,oBAmUd;IAED,eAAe,aACH,KAAK,CACX,eAAe,GACf,SAAS,GACT,aAAa,GACb,UAAU,GACV,IAAI,GACJ,KAAK,GACL,aAAa,GACb,OAAO,CACV,iBACc,KAAK,CAAC,WAAW,CAAC,mBA4ClC;IAED,mBAAmB,0BAWlB;CACF"}
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
var v = Object.defineProperty;
|
|
2
|
-
var E = (m,
|
|
3
|
-
var
|
|
4
|
-
import { C as S, H as
|
|
2
|
+
var E = (m, a, i) => a in m ? v(m, a, { enumerable: !0, configurable: !0, writable: !0, value: i }) : m[a] = i;
|
|
3
|
+
var d = (m, a, i) => E(m, typeof a != "symbol" ? a + "" : a, i);
|
|
4
|
+
import { C as S, H as f } from "../../color-1CXTuV84.js";
|
|
5
5
|
import { c as t } from "../../index-Beb8qoyd.js";
|
|
6
6
|
class A {
|
|
7
7
|
constructor({
|
|
8
|
-
base:
|
|
9
|
-
themes:
|
|
8
|
+
base: a,
|
|
9
|
+
themes: i,
|
|
10
10
|
meta: r
|
|
11
11
|
}) {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
const
|
|
19
|
-
id:
|
|
20
|
-
name:
|
|
21
|
-
description:
|
|
12
|
+
d(this, "base");
|
|
13
|
+
d(this, "themes");
|
|
14
|
+
d(this, "meta");
|
|
15
|
+
d(this, "paletteData");
|
|
16
|
+
d(this, "currentScale");
|
|
17
|
+
d(this, "makePaletteData", () => (this.themes.forEach((a) => {
|
|
18
|
+
const i = {
|
|
19
|
+
id: a.id,
|
|
20
|
+
name: a.name,
|
|
21
|
+
description: a.description,
|
|
22
22
|
colors: [],
|
|
23
|
-
type:
|
|
23
|
+
type: a.type
|
|
24
24
|
};
|
|
25
25
|
this.base.colors.forEach((r) => {
|
|
26
|
-
const g = Object.entries(
|
|
26
|
+
const g = Object.entries(a.scale).reverse().map((e) => {
|
|
27
27
|
if (r.alpha.isEnabled) {
|
|
28
28
|
const s = new S({
|
|
29
29
|
render: "RGB",
|
|
@@ -32,80 +32,80 @@ class A {
|
|
|
32
32
|
r.rgb.g * 255,
|
|
33
33
|
r.rgb.b * 255
|
|
34
34
|
],
|
|
35
|
-
alpha: parseFloat((
|
|
35
|
+
alpha: parseFloat((e[1] / 100).toFixed(2)),
|
|
36
36
|
hueShifting: r.hue.shift !== void 0 ? r.hue.shift : 0,
|
|
37
37
|
chromaShifting: r.chroma.shift !== void 0 ? r.chroma.shift : 100,
|
|
38
38
|
algorithmVersion: this.base.algorithmVersion,
|
|
39
|
-
visionSimulationMode:
|
|
39
|
+
visionSimulationMode: a.visionSimulationMode
|
|
40
40
|
}), b = new S({
|
|
41
41
|
render: "RGB",
|
|
42
42
|
sourceColor: t(r.alpha.backgroundColor).rgb(),
|
|
43
43
|
algorithmVersion: this.base.algorithmVersion,
|
|
44
|
-
visionSimulationMode:
|
|
44
|
+
visionSimulationMode: a.visionSimulationMode
|
|
45
45
|
});
|
|
46
46
|
switch (this.base.colorSpace) {
|
|
47
47
|
case "LCH":
|
|
48
48
|
return this.base.areSourceColorsLocked ? [
|
|
49
|
-
|
|
49
|
+
e,
|
|
50
50
|
s.setColorWithAlpha(),
|
|
51
51
|
b.setColorWithAlpha()
|
|
52
52
|
] : [
|
|
53
|
-
|
|
53
|
+
e,
|
|
54
54
|
s.lcha(),
|
|
55
55
|
b.lcha()
|
|
56
56
|
];
|
|
57
57
|
case "OKLCH":
|
|
58
58
|
return this.base.areSourceColorsLocked ? [
|
|
59
|
-
|
|
59
|
+
e,
|
|
60
60
|
s.setColorWithAlpha(),
|
|
61
61
|
b.setColorWithAlpha()
|
|
62
62
|
] : [
|
|
63
|
-
|
|
63
|
+
e,
|
|
64
64
|
s.oklcha(),
|
|
65
65
|
b.oklcha()
|
|
66
66
|
];
|
|
67
67
|
case "LAB":
|
|
68
68
|
return this.base.areSourceColorsLocked ? [
|
|
69
|
-
|
|
69
|
+
e,
|
|
70
70
|
s.setColorWithAlpha(),
|
|
71
71
|
b.setColorWithAlpha()
|
|
72
72
|
] : [
|
|
73
|
-
|
|
73
|
+
e,
|
|
74
74
|
s.laba(),
|
|
75
75
|
b.laba()
|
|
76
76
|
];
|
|
77
77
|
case "OKLAB":
|
|
78
78
|
return this.base.areSourceColorsLocked ? [
|
|
79
|
-
|
|
79
|
+
e,
|
|
80
80
|
s.setColorWithAlpha(),
|
|
81
81
|
b.setColorWithAlpha()
|
|
82
82
|
] : [
|
|
83
|
-
|
|
83
|
+
e,
|
|
84
84
|
s.oklaba(),
|
|
85
85
|
b.oklaba()
|
|
86
86
|
];
|
|
87
87
|
case "HSL":
|
|
88
88
|
return this.base.areSourceColorsLocked ? [
|
|
89
|
-
|
|
89
|
+
e,
|
|
90
90
|
s.setColorWithAlpha(),
|
|
91
91
|
b.setColorWithAlpha()
|
|
92
92
|
] : [
|
|
93
|
-
|
|
93
|
+
e,
|
|
94
94
|
s.hsla(),
|
|
95
95
|
b.hsla()
|
|
96
96
|
];
|
|
97
97
|
case "HSLUV":
|
|
98
98
|
return this.base.areSourceColorsLocked ? [
|
|
99
|
-
|
|
99
|
+
e,
|
|
100
100
|
s.setColorWithAlpha(),
|
|
101
101
|
b.setColorWithAlpha()
|
|
102
102
|
] : [
|
|
103
|
-
|
|
103
|
+
e,
|
|
104
104
|
s.hsluva(),
|
|
105
105
|
b.hsluva()
|
|
106
106
|
];
|
|
107
107
|
default:
|
|
108
|
-
return [
|
|
108
|
+
return [e, [0, 0, 0], [255, 255, 255]];
|
|
109
109
|
}
|
|
110
110
|
} else {
|
|
111
111
|
const s = new S({
|
|
@@ -115,145 +115,144 @@ class A {
|
|
|
115
115
|
r.rgb.g * 255,
|
|
116
116
|
r.rgb.b * 255
|
|
117
117
|
],
|
|
118
|
-
lightness:
|
|
118
|
+
lightness: e[1],
|
|
119
119
|
hueShifting: r.hue.shift !== void 0 ? r.hue.shift : 0,
|
|
120
120
|
chromaShifting: r.chroma.shift !== void 0 ? r.chroma.shift : 100,
|
|
121
121
|
algorithmVersion: this.base.algorithmVersion,
|
|
122
|
-
visionSimulationMode:
|
|
122
|
+
visionSimulationMode: a.visionSimulationMode
|
|
123
123
|
});
|
|
124
124
|
switch (this.base.colorSpace) {
|
|
125
125
|
case "LCH":
|
|
126
|
-
return [
|
|
126
|
+
return [e, s.lch()];
|
|
127
127
|
case "OKLCH":
|
|
128
|
-
return [
|
|
128
|
+
return [e, s.oklch()];
|
|
129
129
|
case "LAB":
|
|
130
|
-
return [
|
|
130
|
+
return [e, s.lab()];
|
|
131
131
|
case "OKLAB":
|
|
132
|
-
return [
|
|
132
|
+
return [e, s.oklab()];
|
|
133
133
|
case "HSL":
|
|
134
|
-
return [
|
|
134
|
+
return [e, s.hsl()];
|
|
135
135
|
case "HSLUV":
|
|
136
|
-
return [
|
|
136
|
+
return [e, s.hsluv()];
|
|
137
137
|
default:
|
|
138
|
-
return [
|
|
138
|
+
return [e, [0, 0, 0]];
|
|
139
139
|
}
|
|
140
140
|
}
|
|
141
|
-
}),
|
|
141
|
+
}), u = {
|
|
142
142
|
id: r.id,
|
|
143
143
|
name: r.name,
|
|
144
144
|
description: r.description,
|
|
145
145
|
shades: [],
|
|
146
146
|
type: "color"
|
|
147
|
-
},
|
|
147
|
+
}, h = [
|
|
148
148
|
r.rgb.r * 255,
|
|
149
149
|
r.rgb.g * 255,
|
|
150
150
|
r.rgb.b * 255
|
|
151
|
-
],
|
|
152
|
-
|
|
151
|
+
], c = new f();
|
|
152
|
+
c.rgb_r = r.rgb.r, c.rgb_g = r.rgb.g, c.rgb_b = r.rgb.b, c.rgbToHsluv(), u.shades.push({
|
|
153
153
|
name: "source",
|
|
154
154
|
description: "Source color",
|
|
155
|
-
hex: t(
|
|
156
|
-
rgb:
|
|
157
|
-
gl: t(
|
|
158
|
-
lch: t(
|
|
159
|
-
oklch: t(
|
|
160
|
-
lab: t(
|
|
161
|
-
oklab: t(
|
|
162
|
-
hsl: t(
|
|
155
|
+
hex: t(h).hex(),
|
|
156
|
+
rgb: h,
|
|
157
|
+
gl: t(h).gl(),
|
|
158
|
+
lch: t(h).lch(),
|
|
159
|
+
oklch: t(h).oklch(),
|
|
160
|
+
lab: t(h).lab(),
|
|
161
|
+
oklab: t(h).oklab(),
|
|
162
|
+
hsl: t(h).hsl(),
|
|
163
163
|
hsluv: [
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
164
|
+
c.hsluv_h,
|
|
165
|
+
c.hsluv_s,
|
|
166
|
+
c.hsluv_l
|
|
167
167
|
],
|
|
168
168
|
type: "source color"
|
|
169
169
|
});
|
|
170
170
|
const k = g.map(
|
|
171
|
-
(
|
|
172
|
-
t(
|
|
173
|
-
t(
|
|
171
|
+
(e) => t.distance(
|
|
172
|
+
t(h).hex(),
|
|
173
|
+
t(e[1]).hex(),
|
|
174
174
|
"rgb"
|
|
175
175
|
)
|
|
176
176
|
), l = k.indexOf(Math.min(...k));
|
|
177
|
-
g.forEach((
|
|
177
|
+
g.forEach((e, s) => {
|
|
178
178
|
const b = t.distance(
|
|
179
|
-
t(
|
|
180
|
-
t(
|
|
179
|
+
t(h).hex(),
|
|
180
|
+
t(e[1]).hex(),
|
|
181
181
|
"rgb"
|
|
182
|
-
),
|
|
183
|
-
(
|
|
184
|
-
) ?? "0",
|
|
182
|
+
), L = Object.keys(this.currentScale).find(
|
|
183
|
+
(p) => p === e[0][0]
|
|
184
|
+
) ?? "0", o = new f(), C = new S({
|
|
185
185
|
render: "RGB",
|
|
186
|
-
sourceColor: t(
|
|
187
|
-
visionSimulationMode:
|
|
188
|
-
}).setColor(),
|
|
186
|
+
sourceColor: t(h).rgb(),
|
|
187
|
+
visionSimulationMode: a.visionSimulationMode
|
|
188
|
+
}).setColor(), n = new S({
|
|
189
189
|
render: "HEX",
|
|
190
|
-
sourceColor: t(
|
|
191
|
-
visionSimulationMode:
|
|
190
|
+
sourceColor: t(h).rgb(),
|
|
191
|
+
visionSimulationMode: a.visionSimulationMode
|
|
192
192
|
}).setColor();
|
|
193
|
-
s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? (
|
|
194
|
-
name:
|
|
195
|
-
description: `Shade color with ${typeof
|
|
196
|
-
hex: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
197
|
-
rgb: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
198
|
-
gl: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
199
|
-
lch: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
200
|
-
oklch: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
201
|
-
lab: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
202
|
-
oklab: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
203
|
-
hsl: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(
|
|
204
|
-
hsluv: [
|
|
205
|
-
alpha: r.alpha.isEnabled ? parseFloat((
|
|
206
|
-
backgroundColor: r.alpha.isEnabled && r.alpha.backgroundColor ? t(
|
|
193
|
+
s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? (o.rgb_r = Number(C[0]) / 255, o.rgb_g = Number(C[1]) / 255, o.rgb_b = Number(C[2]) / 255) : (o.rgb_r = Number(e[1][0]) / 255, o.rgb_g = Number(e[1][1]) / 255, o.rgb_b = Number(e[1][2]) / 255), o.rgbToHsluv(), u.shades.push({
|
|
194
|
+
name: L,
|
|
195
|
+
description: `Shade color with ${typeof e[0][1] == "number" ? e[0][1].toFixed(1) : e[0][1]}% of ${r.alpha.isEnabled ? "opacity" : "lightness"}`,
|
|
196
|
+
hex: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).hex() : t(e[1]).hex(),
|
|
197
|
+
rgb: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).rgb() : t(e[1]).rgb(),
|
|
198
|
+
gl: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).gl() : t(e[1]).gl(),
|
|
199
|
+
lch: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).lch() : t(e[1]).lch(),
|
|
200
|
+
oklch: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).oklch() : t(e[1]).oklch(),
|
|
201
|
+
lab: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).lab() : t(e[1]).lab(),
|
|
202
|
+
oklab: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).oklab() : t(e[1]).oklab(),
|
|
203
|
+
hsl: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled ? t(n).hsl() : t(e[1]).hsl(),
|
|
204
|
+
hsluv: [o.hsluv_h, o.hsluv_s, o.hsluv_l],
|
|
205
|
+
alpha: r.alpha.isEnabled ? parseFloat((e[0][1] / 100).toFixed(2)) : void 0,
|
|
206
|
+
backgroundColor: r.alpha.isEnabled && r.alpha.backgroundColor ? t(e[2]).rgb() : void 0,
|
|
207
207
|
mixedColor: r.alpha.isEnabled && r.alpha.backgroundColor ? new S({
|
|
208
|
-
visionSimulationMode:
|
|
208
|
+
visionSimulationMode: a.visionSimulationMode
|
|
209
209
|
}).mixColorsRgb(
|
|
210
210
|
[
|
|
211
|
-
...
|
|
211
|
+
...e[1],
|
|
212
212
|
parseFloat(
|
|
213
|
-
(
|
|
213
|
+
(e[0][1] / 100).toFixed(2)
|
|
214
214
|
)
|
|
215
215
|
],
|
|
216
|
-
[...
|
|
216
|
+
[...e[2], 1]
|
|
217
217
|
) : void 0,
|
|
218
218
|
isClosestToRef: b < 4 && !this.base.areSourceColorsLocked,
|
|
219
219
|
isSourceColorLocked: s === l && this.base.areSourceColorsLocked && !r.alpha.isEnabled,
|
|
220
220
|
isTransparent: r.alpha.isEnabled,
|
|
221
221
|
type: "color shade"
|
|
222
222
|
});
|
|
223
|
-
}),
|
|
224
|
-
}), this.paletteData.themes.push(
|
|
223
|
+
}), i.colors.push(u);
|
|
224
|
+
}), this.paletteData.themes.push(i);
|
|
225
225
|
}), this.paletteData));
|
|
226
|
-
|
|
226
|
+
d(this, "makeLibraryData", (a, i) => {
|
|
227
227
|
const r = this.makePaletteData();
|
|
228
228
|
return r.themes.flatMap(
|
|
229
|
-
(
|
|
230
|
-
(
|
|
231
|
-
const k = `${
|
|
232
|
-
(
|
|
229
|
+
(u) => u.colors.flatMap(
|
|
230
|
+
(h) => h.shades.flatMap((c) => {
|
|
231
|
+
const k = `${u.id}:${h.id}:${c.name}`, l = i == null ? void 0 : i.find(
|
|
232
|
+
(e) => e.id === k
|
|
233
233
|
);
|
|
234
234
|
return {
|
|
235
235
|
id: k,
|
|
236
236
|
paletteName: r.name,
|
|
237
|
-
themeName:
|
|
238
|
-
colorName:
|
|
239
|
-
shadeName:
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
...(
|
|
243
|
-
...(
|
|
244
|
-
|
|
245
|
-
description: i.description
|
|
237
|
+
themeName: u.name,
|
|
238
|
+
colorName: h.name,
|
|
239
|
+
shadeName: c.name,
|
|
240
|
+
...(a == null ? void 0 : a.includes("hex")) && { alpha: c.alpha ?? 1 },
|
|
241
|
+
...(a == null ? void 0 : a.includes("hex")) && { hex: c.hex },
|
|
242
|
+
...(a == null ? void 0 : a.includes("gl")) && { gl: c.gl },
|
|
243
|
+
...(a == null ? void 0 : a.includes("description")) && {
|
|
244
|
+
description: h.description
|
|
246
245
|
},
|
|
247
|
-
...(
|
|
246
|
+
...(a == null ? void 0 : a.includes("collection_id")) && {
|
|
248
247
|
collectionId: l == null ? void 0 : l.collectionId
|
|
249
248
|
},
|
|
250
|
-
...(
|
|
249
|
+
...(a == null ? void 0 : a.includes("mode_id")) && {
|
|
251
250
|
modeId: l == null ? void 0 : l.modeId
|
|
252
251
|
},
|
|
253
|
-
...(
|
|
252
|
+
...(a == null ? void 0 : a.includes("variable_id")) && {
|
|
254
253
|
variableId: l == null ? void 0 : l.variableId
|
|
255
254
|
},
|
|
256
|
-
...(
|
|
255
|
+
...(a == null ? void 0 : a.includes("style_id")) && {
|
|
257
256
|
styleId: l == null ? void 0 : l.styleId
|
|
258
257
|
}
|
|
259
258
|
};
|
|
@@ -261,21 +260,21 @@ class A {
|
|
|
261
260
|
)
|
|
262
261
|
);
|
|
263
262
|
});
|
|
264
|
-
|
|
263
|
+
d(this, "makePaletteFullData", () => ({
|
|
265
264
|
base: this.base,
|
|
266
265
|
themes: this.themes,
|
|
267
|
-
libraryData: this.makeLibraryData(
|
|
266
|
+
libraryData: this.makeLibraryData(),
|
|
268
267
|
meta: this.meta,
|
|
269
268
|
version: "2025.06",
|
|
270
269
|
type: "UI_COLOR_PALETTE"
|
|
271
270
|
}));
|
|
272
271
|
var g;
|
|
273
|
-
this.base =
|
|
274
|
-
name:
|
|
275
|
-
description:
|
|
272
|
+
this.base = a, this.themes = i, this.meta = r, this.paletteData = {
|
|
273
|
+
name: a.name ?? "UI Color Palette",
|
|
274
|
+
description: a.description,
|
|
276
275
|
themes: [],
|
|
277
276
|
type: "palette"
|
|
278
|
-
}, this.currentScale = ((g =
|
|
277
|
+
}, this.currentScale = ((g = i.find((u) => u.isEnabled)) == null ? void 0 : g.scale) ?? {};
|
|
279
278
|
}
|
|
280
279
|
}
|
|
281
280
|
export {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data.js","sources":["../../../src/modules/data/data.ts"],"sourcesContent":["import { Hsluv } from 'hsluv'\nimport chroma from 'chroma-js'\nimport {\n LibraryData,\n PaletteData,\n PaletteDataColorItem,\n PaletteDataThemeItem,\n} from '@tps/data.types'\nimport {\n MetaConfiguration,\n BaseConfiguration,\n ScaleConfiguration,\n ThemeConfiguration,\n FullConfiguration,\n} from '@tps/configuration.types'\nimport { Channel, HexModel } from '@tps/color.types'\nimport Color from '@modules/color/color'\n\nexport default class Data {\n private base: BaseConfiguration\n private themes: Array<ThemeConfiguration>\n private meta?: MetaConfiguration\n private paletteData: PaletteData\n private currentScale: ScaleConfiguration\n\n constructor({\n base,\n themes,\n meta,\n }: {\n base: BaseConfiguration\n themes: Array<ThemeConfiguration>\n meta?: MetaConfiguration\n }) {\n this.base = base\n this.themes = themes\n this.meta = meta\n this.paletteData = {\n name: base.name ?? 'UI Color Palette',\n description: base.description,\n themes: [],\n type: 'palette',\n }\n this.currentScale =\n themes.find((theme) => theme.isEnabled)?.scale ??\n ({} as ScaleConfiguration)\n }\n\n makePaletteData = () => {\n this.themes.forEach((theme) => {\n const paletteDataThemeItem: PaletteDataThemeItem = {\n id: theme.id,\n name: theme.name,\n description: theme.description,\n colors: [],\n type: theme.type,\n }\n this.base.colors.forEach((color) => {\n const scaledColors = Object.entries(theme.scale)\n .reverse()\n .map((lightness) => {\n if (color.alpha.isEnabled) {\n const foregroundColorData = new Color({\n render: 'RGB',\n sourceColor: [\n color.rgb.r * 255,\n color.rgb.g * 255,\n color.rgb.b * 255,\n ],\n alpha: parseFloat((lightness[1] / 100).toFixed(2)),\n hueShifting:\n color.hue.shift !== undefined ? color.hue.shift : 0,\n chromaShifting:\n color.chroma.shift !== undefined ? color.chroma.shift : 100,\n algorithmVersion: this.base.algorithmVersion,\n visionSimulationMode: theme.visionSimulationMode,\n })\n const backgroundColorData = new Color({\n render: 'RGB',\n sourceColor: chroma(color.alpha.backgroundColor).rgb(),\n algorithmVersion: this.base.algorithmVersion,\n visionSimulationMode: theme.visionSimulationMode,\n })\n\n switch (this.base.colorSpace) {\n case 'LCH':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.lcha(),\n backgroundColorData.lcha(),\n ]\n case 'OKLCH':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.oklcha(),\n backgroundColorData.oklcha(),\n ]\n case 'LAB':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.laba(),\n backgroundColorData.laba(),\n ]\n case 'OKLAB':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.oklaba(),\n backgroundColorData.oklaba(),\n ]\n case 'HSL':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.hsla(),\n backgroundColorData.hsla(),\n ]\n case 'HSLUV':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.hsluva(),\n backgroundColorData.hsluva(),\n ]\n default:\n return [lightness, [0, 0, 0], [255, 255, 255]]\n }\n } else {\n const colorData = new Color({\n render: 'RGB',\n sourceColor: [\n color.rgb.r * 255,\n color.rgb.g * 255,\n color.rgb.b * 255,\n ],\n lightness: lightness[1],\n hueShifting:\n color.hue.shift !== undefined ? color.hue.shift : 0,\n chromaShifting:\n color.chroma.shift !== undefined ? color.chroma.shift : 100,\n algorithmVersion: this.base.algorithmVersion,\n visionSimulationMode: theme.visionSimulationMode,\n })\n\n switch (this.base.colorSpace) {\n case 'LCH':\n return [lightness, colorData.lch()]\n case 'OKLCH':\n return [lightness, colorData.oklch()]\n case 'LAB':\n return [lightness, colorData.lab()]\n case 'OKLAB':\n return [lightness, colorData.oklab()]\n case 'HSL':\n return [lightness, colorData.hsl()]\n case 'HSLUV':\n return [lightness, colorData.hsluv()]\n default:\n return [lightness, [0, 0, 0]]\n }\n }\n })\n\n const paletteDataColorItem: PaletteDataColorItem = {\n id: color.id,\n name: color.name,\n description: color.description,\n shades: [],\n type: 'color',\n },\n sourceColor: Channel = [\n color.rgb.r * 255,\n color.rgb.g * 255,\n color.rgb.b * 255,\n ]\n\n const sourceHsluv = new Hsluv()\n sourceHsluv.rgb_r = color.rgb.r\n sourceHsluv.rgb_g = color.rgb.g\n sourceHsluv.rgb_b = color.rgb.b\n sourceHsluv.rgbToHsluv()\n\n paletteDataColorItem.shades.push({\n name: 'source',\n description: 'Source color',\n hex: chroma(sourceColor).hex(),\n rgb: sourceColor,\n gl: chroma(sourceColor).gl(),\n lch: chroma(sourceColor).lch(),\n oklch: chroma(sourceColor).oklch(),\n lab: chroma(sourceColor).lab(),\n oklab: chroma(sourceColor).oklab(),\n hsl: chroma(sourceColor).hsl(),\n hsluv: [\n sourceHsluv.hsluv_h,\n sourceHsluv.hsluv_s,\n sourceHsluv.hsluv_l,\n ],\n type: 'source color',\n })\n\n const distances = scaledColors.map((shade) =>\n chroma.distance(\n chroma(sourceColor).hex(),\n chroma(shade[1] as Channel).hex(),\n 'rgb'\n )\n )\n const minDistanceIndex = distances.indexOf(Math.min(...distances))\n\n scaledColors.forEach((scaledColor, index) => {\n const distance: number = chroma.distance(\n chroma(sourceColor).hex(),\n chroma(scaledColor[1] as Channel).hex(),\n 'rgb'\n )\n const scaleName: string =\n Object.keys(this.currentScale).find(\n (key) => key === scaledColor[0][0]\n ) ?? '0'\n const newHsluv = new Hsluv()\n const simulatedSourceColorRgb = new Color({\n render: 'RGB',\n sourceColor: chroma(sourceColor).rgb(),\n visionSimulationMode: theme.visionSimulationMode,\n }).setColor() as Channel\n const simulatedSourceColorHex = new Color({\n render: 'HEX',\n sourceColor: chroma(sourceColor).rgb(),\n visionSimulationMode: theme.visionSimulationMode,\n }).setColor() as HexModel\n\n if (\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ) {\n newHsluv.rgb_r = Number(simulatedSourceColorRgb[0]) / 255\n newHsluv.rgb_g = Number(simulatedSourceColorRgb[1]) / 255\n newHsluv.rgb_b = Number(simulatedSourceColorRgb[2]) / 255\n } else {\n newHsluv.rgb_r = Number(scaledColor[1][0]) / 255\n newHsluv.rgb_g = Number(scaledColor[1][1]) / 255\n newHsluv.rgb_b = Number(scaledColor[1][2]) / 255\n }\n newHsluv.rgbToHsluv()\n\n paletteDataColorItem.shades.push({\n name: scaleName,\n description: `Shade color with ${typeof scaledColor[0][1] === 'number' ? scaledColor[0][1].toFixed(1) : scaledColor[0][1]}% of ${\n color.alpha.isEnabled ? 'opacity' : 'lightness'\n }`,\n hex:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).hex()\n : chroma(scaledColor[1] as Channel).hex(),\n rgb:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).rgb()\n : chroma(scaledColor[1] as Channel).rgb(),\n gl:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).gl()\n : chroma(scaledColor[1] as Channel).gl(),\n lch:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).lch()\n : chroma(scaledColor[1] as Channel).lch(),\n oklch:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).oklch()\n : chroma(scaledColor[1] as Channel).oklch(),\n lab:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).lab()\n : chroma(scaledColor[1] as Channel).lab(),\n oklab:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).oklab()\n : chroma(scaledColor[1] as Channel).oklab(),\n hsl:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).hsl()\n : chroma(scaledColor[1] as Channel).hsl(),\n hsluv: [newHsluv.hsluv_h, newHsluv.hsluv_s, newHsluv.hsluv_l],\n alpha: color.alpha.isEnabled\n ? parseFloat(((scaledColor[0][1] as number) / 100).toFixed(2))\n : undefined,\n backgroundColor:\n color.alpha.isEnabled && color.alpha.backgroundColor\n ? chroma(scaledColor[2] as Channel).rgb()\n : undefined,\n mixedColor:\n color.alpha.isEnabled && color.alpha.backgroundColor\n ? new Color({\n visionSimulationMode: theme.visionSimulationMode,\n }).mixColorsRgb(\n [\n ...(scaledColor[1] as Channel),\n parseFloat(\n ((scaledColor[0][1] as number) / 100).toFixed(2)\n ),\n ],\n [...(scaledColor[2] as Channel), 1]\n )\n : undefined,\n isClosestToRef: distance < 4 && !this.base.areSourceColorsLocked,\n isSourceColorLocked:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled,\n isTransparent: color.alpha.isEnabled,\n type: 'color shade',\n })\n })\n\n paletteDataThemeItem.colors.push(paletteDataColorItem)\n })\n this.paletteData.themes.push(paletteDataThemeItem)\n })\n\n return this.paletteData\n }\n\n makeLibraryData = (\n options?: Array<\n | 'collection_id'\n | 'mode_id'\n | 'variable_id'\n | 'style_id'\n | 'gl'\n | 'hex'\n | 'description'\n >,\n previousData?: Array<LibraryData>\n ) => {\n const paletteData = this.makePaletteData()\n\n const libraryData: Array<LibraryData> = paletteData.themes.flatMap(\n (theme) => {\n return theme.colors.flatMap((color) =>\n color.shades.flatMap((shade) => {\n const generatedId = `${theme.id}:${color.id}:${shade.name}`\n const previousItem = previousData?.find(\n (item) => item.id === generatedId\n )\n\n return {\n id: generatedId,\n paletteName: paletteData.name,\n themeName: theme.name,\n colorName: color.name,\n shadeName: shade.name,\n type: theme.type,\n alpha: shade.alpha ?? 1,\n ...(options?.includes('hex') && { hex: shade.hex }),\n ...(options?.includes('gl') && { gl: shade.gl }),\n ...(options?.includes('description') && {\n description: color.description,\n }),\n ...(options?.includes('collection_id') && {\n collectionId: previousItem?.collectionId,\n }),\n ...(options?.includes('mode_id') && {\n modeId: previousItem?.modeId,\n }),\n ...(options?.includes('variable_id') && {\n variableId: previousItem?.variableId,\n }),\n ...(options?.includes('style_id') && {\n styleId: previousItem?.styleId,\n }),\n }\n })\n )\n }\n )\n\n return libraryData\n }\n\n makePaletteFullData = (model: ['hex' | 'gl'] = ['hex']) => {\n const fullPaletteData = {\n base: this.base,\n themes: this.themes,\n libraryData: this.makeLibraryData(model),\n meta: this.meta,\n version: '2025.06',\n type: 'UI_COLOR_PALETTE',\n } as FullConfiguration\n\n return fullPaletteData\n }\n}\n"],"names":["Data","base","themes","meta","__publicField","theme","paletteDataThemeItem","color","scaledColors","lightness","foregroundColorData","Color","backgroundColorData","chroma","colorData","paletteDataColorItem","sourceColor","sourceHsluv","Hsluv","distances","shade","minDistanceIndex","scaledColor","index","distance","scaleName","key","newHsluv","simulatedSourceColorRgb","simulatedSourceColorHex","options","previousData","paletteData","generatedId","previousItem","item","model","_a"],"mappings":";;;;;AAkBA,MAAqBA,EAAK;AAAA,EAOxB,YAAY;AAAA,IACV,MAAAC;AAAA,IACA,QAAAC;AAAA,IACA,MAAAC;AAAA,EAAA,GAKC;AAdK,IAAAC,EAAA;AACA,IAAAA,EAAA;AACA,IAAAA,EAAA;AACA,IAAAA,EAAA;AACA,IAAAA,EAAA;AAyBR,IAAAA,EAAA,yBAAkB,OACX,KAAA,OAAO,QAAQ,CAACC,MAAU;AAC7B,YAAMC,IAA6C;AAAA,QACjD,IAAID,EAAM;AAAA,QACV,MAAMA,EAAM;AAAA,QACZ,aAAaA,EAAM;AAAA,QACnB,QAAQ,CAAC;AAAA,QACT,MAAMA,EAAM;AAAA,MACd;AACA,WAAK,KAAK,OAAO,QAAQ,CAACE,MAAU;AAC5B,cAAAC,IAAe,OAAO,QAAQH,EAAM,KAAK,EAC5C,QAAQ,EACR,IAAI,CAACI,MAAc;AACd,cAAAF,EAAM,MAAM,WAAW;AACnB,kBAAAG,IAAsB,IAAIC,EAAM;AAAA,cACpC,QAAQ;AAAA,cACR,aAAa;AAAA,gBACXJ,EAAM,IAAI,IAAI;AAAA,gBACdA,EAAM,IAAI,IAAI;AAAA,gBACdA,EAAM,IAAI,IAAI;AAAA,cAChB;AAAA,cACA,OAAO,YAAYE,EAAU,CAAC,IAAI,KAAK,QAAQ,CAAC,CAAC;AAAA,cACjD,aACEF,EAAM,IAAI,UAAU,SAAYA,EAAM,IAAI,QAAQ;AAAA,cACpD,gBACEA,EAAM,OAAO,UAAU,SAAYA,EAAM,OAAO,QAAQ;AAAA,cAC1D,kBAAkB,KAAK,KAAK;AAAA,cAC5B,sBAAsBF,EAAM;AAAA,YAAA,CAC7B,GACKO,IAAsB,IAAID,EAAM;AAAA,cACpC,QAAQ;AAAA,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Q;AAAA,MACnB,aAAaA,EAAK;AAAA,MAClB,QAAQ,CAAC;AAAA,MACT,MAAM;AAAA,IACR,GACK,KAAA,iBACHoC,IAAAnC,EAAO,KAAK,CAACG,MAAUA,EAAM,SAAS,MAAtC,gBAAAgC,EAAyC,UACxC,CAAC;AAAA,EAAA;AA6YR;"}
|
|
1
|
+
{"version":3,"file":"data.js","sources":["../../../src/modules/data/data.ts"],"sourcesContent":["import { Hsluv } from 'hsluv'\nimport chroma from 'chroma-js'\nimport {\n LibraryData,\n PaletteData,\n PaletteDataColorItem,\n PaletteDataThemeItem,\n} from '@tps/data.types'\nimport {\n MetaConfiguration,\n BaseConfiguration,\n ScaleConfiguration,\n ThemeConfiguration,\n FullConfiguration,\n} from '@tps/configuration.types'\nimport { Channel, HexModel } from '@tps/color.types'\nimport Color from '@modules/color/color'\n\nexport default class Data {\n private base: BaseConfiguration\n private themes: Array<ThemeConfiguration>\n private meta?: MetaConfiguration\n private paletteData: PaletteData\n private currentScale: ScaleConfiguration\n\n constructor({\n base,\n themes,\n meta,\n }: {\n base: BaseConfiguration\n themes: Array<ThemeConfiguration>\n meta?: MetaConfiguration\n }) {\n this.base = base\n this.themes = themes\n this.meta = meta\n this.paletteData = {\n name: base.name ?? 'UI Color Palette',\n description: base.description,\n themes: [],\n type: 'palette',\n }\n this.currentScale =\n themes.find((theme) => theme.isEnabled)?.scale ??\n ({} as ScaleConfiguration)\n }\n\n makePaletteData = () => {\n this.themes.forEach((theme) => {\n const paletteDataThemeItem: PaletteDataThemeItem = {\n id: theme.id,\n name: theme.name,\n description: theme.description,\n colors: [],\n type: theme.type,\n }\n this.base.colors.forEach((color) => {\n const scaledColors = Object.entries(theme.scale)\n .reverse()\n .map((lightness) => {\n if (color.alpha.isEnabled) {\n const foregroundColorData = new Color({\n render: 'RGB',\n sourceColor: [\n color.rgb.r * 255,\n color.rgb.g * 255,\n color.rgb.b * 255,\n ],\n alpha: parseFloat((lightness[1] / 100).toFixed(2)),\n hueShifting:\n color.hue.shift !== undefined ? color.hue.shift : 0,\n chromaShifting:\n color.chroma.shift !== undefined ? color.chroma.shift : 100,\n algorithmVersion: this.base.algorithmVersion,\n visionSimulationMode: theme.visionSimulationMode,\n })\n const backgroundColorData = new Color({\n render: 'RGB',\n sourceColor: chroma(color.alpha.backgroundColor).rgb(),\n algorithmVersion: this.base.algorithmVersion,\n visionSimulationMode: theme.visionSimulationMode,\n })\n\n switch (this.base.colorSpace) {\n case 'LCH':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.lcha(),\n backgroundColorData.lcha(),\n ]\n case 'OKLCH':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.oklcha(),\n backgroundColorData.oklcha(),\n ]\n case 'LAB':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.laba(),\n backgroundColorData.laba(),\n ]\n case 'OKLAB':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.oklaba(),\n backgroundColorData.oklaba(),\n ]\n case 'HSL':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.hsla(),\n backgroundColorData.hsla(),\n ]\n case 'HSLUV':\n return this.base.areSourceColorsLocked\n ? [\n lightness,\n foregroundColorData.setColorWithAlpha(),\n backgroundColorData.setColorWithAlpha(),\n ]\n : [\n lightness,\n foregroundColorData.hsluva(),\n backgroundColorData.hsluva(),\n ]\n default:\n return [lightness, [0, 0, 0], [255, 255, 255]]\n }\n } else {\n const colorData = new Color({\n render: 'RGB',\n sourceColor: [\n color.rgb.r * 255,\n color.rgb.g * 255,\n color.rgb.b * 255,\n ],\n lightness: lightness[1],\n hueShifting:\n color.hue.shift !== undefined ? color.hue.shift : 0,\n chromaShifting:\n color.chroma.shift !== undefined ? color.chroma.shift : 100,\n algorithmVersion: this.base.algorithmVersion,\n visionSimulationMode: theme.visionSimulationMode,\n })\n\n switch (this.base.colorSpace) {\n case 'LCH':\n return [lightness, colorData.lch()]\n case 'OKLCH':\n return [lightness, colorData.oklch()]\n case 'LAB':\n return [lightness, colorData.lab()]\n case 'OKLAB':\n return [lightness, colorData.oklab()]\n case 'HSL':\n return [lightness, colorData.hsl()]\n case 'HSLUV':\n return [lightness, colorData.hsluv()]\n default:\n return [lightness, [0, 0, 0]]\n }\n }\n })\n\n const paletteDataColorItem: PaletteDataColorItem = {\n id: color.id,\n name: color.name,\n description: color.description,\n shades: [],\n type: 'color',\n },\n sourceColor: Channel = [\n color.rgb.r * 255,\n color.rgb.g * 255,\n color.rgb.b * 255,\n ]\n\n const sourceHsluv = new Hsluv()\n sourceHsluv.rgb_r = color.rgb.r\n sourceHsluv.rgb_g = color.rgb.g\n sourceHsluv.rgb_b = color.rgb.b\n sourceHsluv.rgbToHsluv()\n\n paletteDataColorItem.shades.push({\n name: 'source',\n description: 'Source color',\n hex: chroma(sourceColor).hex(),\n rgb: sourceColor,\n gl: chroma(sourceColor).gl(),\n lch: chroma(sourceColor).lch(),\n oklch: chroma(sourceColor).oklch(),\n lab: chroma(sourceColor).lab(),\n oklab: chroma(sourceColor).oklab(),\n hsl: chroma(sourceColor).hsl(),\n hsluv: [\n sourceHsluv.hsluv_h,\n sourceHsluv.hsluv_s,\n sourceHsluv.hsluv_l,\n ],\n type: 'source color',\n })\n\n const distances = scaledColors.map((shade) =>\n chroma.distance(\n chroma(sourceColor).hex(),\n chroma(shade[1] as Channel).hex(),\n 'rgb'\n )\n )\n const minDistanceIndex = distances.indexOf(Math.min(...distances))\n\n scaledColors.forEach((scaledColor, index) => {\n const distance: number = chroma.distance(\n chroma(sourceColor).hex(),\n chroma(scaledColor[1] as Channel).hex(),\n 'rgb'\n )\n const scaleName: string =\n Object.keys(this.currentScale).find(\n (key) => key === scaledColor[0][0]\n ) ?? '0'\n const newHsluv = new Hsluv()\n const simulatedSourceColorRgb = new Color({\n render: 'RGB',\n sourceColor: chroma(sourceColor).rgb(),\n visionSimulationMode: theme.visionSimulationMode,\n }).setColor() as Channel\n const simulatedSourceColorHex = new Color({\n render: 'HEX',\n sourceColor: chroma(sourceColor).rgb(),\n visionSimulationMode: theme.visionSimulationMode,\n }).setColor() as HexModel\n\n if (\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ) {\n newHsluv.rgb_r = Number(simulatedSourceColorRgb[0]) / 255\n newHsluv.rgb_g = Number(simulatedSourceColorRgb[1]) / 255\n newHsluv.rgb_b = Number(simulatedSourceColorRgb[2]) / 255\n } else {\n newHsluv.rgb_r = Number(scaledColor[1][0]) / 255\n newHsluv.rgb_g = Number(scaledColor[1][1]) / 255\n newHsluv.rgb_b = Number(scaledColor[1][2]) / 255\n }\n newHsluv.rgbToHsluv()\n\n paletteDataColorItem.shades.push({\n name: scaleName,\n description: `Shade color with ${typeof scaledColor[0][1] === 'number' ? scaledColor[0][1].toFixed(1) : scaledColor[0][1]}% of ${\n color.alpha.isEnabled ? 'opacity' : 'lightness'\n }`,\n hex:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).hex()\n : chroma(scaledColor[1] as Channel).hex(),\n rgb:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).rgb()\n : chroma(scaledColor[1] as Channel).rgb(),\n gl:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).gl()\n : chroma(scaledColor[1] as Channel).gl(),\n lch:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).lch()\n : chroma(scaledColor[1] as Channel).lch(),\n oklch:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).oklch()\n : chroma(scaledColor[1] as Channel).oklch(),\n lab:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).lab()\n : chroma(scaledColor[1] as Channel).lab(),\n oklab:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).oklab()\n : chroma(scaledColor[1] as Channel).oklab(),\n hsl:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled\n ? chroma(simulatedSourceColorHex).hsl()\n : chroma(scaledColor[1] as Channel).hsl(),\n hsluv: [newHsluv.hsluv_h, newHsluv.hsluv_s, newHsluv.hsluv_l],\n alpha: color.alpha.isEnabled\n ? parseFloat(((scaledColor[0][1] as number) / 100).toFixed(2))\n : undefined,\n backgroundColor:\n color.alpha.isEnabled && color.alpha.backgroundColor\n ? chroma(scaledColor[2] as Channel).rgb()\n : undefined,\n mixedColor:\n color.alpha.isEnabled && color.alpha.backgroundColor\n ? new Color({\n visionSimulationMode: theme.visionSimulationMode,\n }).mixColorsRgb(\n [\n ...(scaledColor[1] as Channel),\n parseFloat(\n ((scaledColor[0][1] as number) / 100).toFixed(2)\n ),\n ],\n [...(scaledColor[2] as Channel), 1]\n )\n : undefined,\n isClosestToRef: distance < 4 && !this.base.areSourceColorsLocked,\n isSourceColorLocked:\n index === minDistanceIndex &&\n this.base.areSourceColorsLocked &&\n !color.alpha.isEnabled,\n isTransparent: color.alpha.isEnabled,\n type: 'color shade',\n })\n })\n\n paletteDataThemeItem.colors.push(paletteDataColorItem)\n })\n this.paletteData.themes.push(paletteDataThemeItem)\n })\n\n return this.paletteData\n }\n\n makeLibraryData = (\n options?: Array<\n | 'collection_id'\n | 'mode_id'\n | 'variable_id'\n | 'style_id'\n | 'gl'\n | 'hex'\n | 'description'\n | 'alpha'\n >,\n previousData?: Array<LibraryData>\n ) => {\n const paletteData = this.makePaletteData()\n\n const libraryData: Array<LibraryData> = paletteData.themes.flatMap(\n (theme) => {\n return theme.colors.flatMap((color) =>\n color.shades.flatMap((shade) => {\n const generatedId = `${theme.id}:${color.id}:${shade.name}`\n const previousItem = previousData?.find(\n (item) => item.id === generatedId\n )\n\n return {\n id: generatedId,\n paletteName: paletteData.name,\n themeName: theme.name,\n colorName: color.name,\n shadeName: shade.name,\n ...(options?.includes('hex') && { alpha: shade.alpha ?? 1 }),\n ...(options?.includes('hex') && { hex: shade.hex }),\n ...(options?.includes('gl') && { gl: shade.gl }),\n ...(options?.includes('description') && {\n description: color.description,\n }),\n ...(options?.includes('collection_id') && {\n collectionId: previousItem?.collectionId,\n }),\n ...(options?.includes('mode_id') && {\n modeId: previousItem?.modeId,\n }),\n ...(options?.includes('variable_id') && {\n variableId: previousItem?.variableId,\n }),\n ...(options?.includes('style_id') && {\n styleId: previousItem?.styleId,\n }),\n }\n })\n )\n }\n )\n\n return libraryData\n }\n\n makePaletteFullData = () => {\n const fullPaletteData = {\n base: this.base,\n themes: this.themes,\n libraryData: this.makeLibraryData(),\n meta: this.meta,\n version: '2025.06',\n type: 'UI_COLOR_PALETTE',\n } as FullConfiguration\n\n return fullPaletteData\n }\n}\n"],"names":["Data","base","themes","meta","__publicField","theme","paletteDataThemeItem","color","scaledColors","lightness","foregroundColorData","Color","backgroundColorData","chroma","colorData","paletteDataColorItem","sourceColor","sourceHsluv","Hsluv","distances","shade","minDistanceIndex","scaledColor","index","distance","scaleName","key","newHsluv","simulatedSourceColorRgb","simulatedSourceColorHex","options","previousData","paletteData","generatedId","previousItem","item","_a"],"mappings":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C,gBAAA+B,EAAyC,UACxC,CAAC;AAAA,EAAA;AA6YR;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data.types.d.ts","sourceRoot":"","sources":["../../src/types/data.types.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,6BAA6B,EAC7B,kBAAkB,EAClB,uBAAuB,EACvB,+BAA+B,EAC/B,mBAAmB,EACnB,kBAAkB,EAClB,kBAAkB,EACnB,MAAM,uBAAuB,CAAA;AAC9B,OAAO,EAAE,OAAO,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAEnE,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAA;IACZ,WAAW,EAAE,MAAM,CAAA;IACnB,MAAM,EAAE,KAAK,CAAC,oBAAoB,CAAC,CAAA;IACnC,IAAI,EAAE,SAAS,CAAA;CAChB;AAED,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAA;IACV,WAAW,EAAE,MAAM,CAAA;IACnB,SAAS,EAAE,MAAM,CAAA;IACjB,SAAS,EAAE,MAAM,CAAA;IACjB,SAAS,EAAE,MAAM,CAAA;IACjB,
|
|
1
|
+
{"version":3,"file":"data.types.d.ts","sourceRoot":"","sources":["../../src/types/data.types.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,6BAA6B,EAC7B,kBAAkB,EAClB,uBAAuB,EACvB,+BAA+B,EAC/B,mBAAmB,EACnB,kBAAkB,EAClB,kBAAkB,EACnB,MAAM,uBAAuB,CAAA;AAC9B,OAAO,EAAE,OAAO,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAEnE,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAA;IACZ,WAAW,EAAE,MAAM,CAAA;IACnB,MAAM,EAAE,KAAK,CAAC,oBAAoB,CAAC,CAAA;IACnC,IAAI,EAAE,SAAS,CAAA;CAChB;AAED,MAAM,WAAW,WAAW;IAC1B,EA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IAClB,SAAS,EAAE,OAAO,CAAA;CACnB"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@a_ng_d/utils-ui-color-palette",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.3.
|
|
4
|
+
"version": "1.3.15",
|
|
5
5
|
"description": "Core utilities library for UI Color Palette - a color management plugin for design tools. This library provides the foundational color manipulation, contrast calculation, and palette generation features used in the plugin.",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|