inferred-types 1.2.1 → 1.2.3
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/modules/constants/dist/index.cjs +151 -0
- package/modules/constants/dist/index.cjs.map +1 -1
- package/modules/constants/dist/index.d.cts +151 -2
- package/modules/constants/dist/index.d.cts.map +1 -1
- package/modules/constants/dist/index.d.ts +151 -2
- package/modules/constants/dist/index.d.ts.map +1 -1
- package/modules/constants/dist/index.js +151 -1
- package/modules/constants/dist/index.js.map +1 -1
- package/modules/inferred-types/dist/index.cjs +512 -0
- package/modules/inferred-types/dist/index.cjs.map +1 -1
- package/modules/inferred-types/dist/index.d.cts +505 -18
- package/modules/inferred-types/dist/index.d.cts.map +1 -1
- package/modules/inferred-types/dist/index.d.ts +505 -18
- package/modules/inferred-types/dist/index.d.ts.map +1 -1
- package/modules/inferred-types/dist/index.js +507 -1
- package/modules/inferred-types/dist/index.js.map +1 -1
- package/modules/runtime/dist/index.cjs +373 -0
- package/modules/runtime/dist/index.cjs.map +1 -1
- package/modules/runtime/dist/index.d.cts +112 -8
- package/modules/runtime/dist/index.d.cts.map +1 -1
- package/modules/runtime/dist/index.d.ts +112 -8
- package/modules/runtime/dist/index.d.ts.map +1 -1
- package/modules/runtime/dist/index.js +369 -1
- package/modules/runtime/dist/index.js.map +1 -1
- package/modules/types/dist/index.d.cts +244 -10
- package/modules/types/dist/index.d.cts.map +1 -1
- package/modules/types/dist/index.d.ts +244 -10
- package/modules/types/dist/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -233,6 +233,156 @@ const CSS_NAMED_COLORS = [
|
|
|
233
233
|
"yellow",
|
|
234
234
|
"yellowgreen"
|
|
235
235
|
];
|
|
236
|
+
const CSS_COLOR_LOOKUP = {
|
|
237
|
+
aliceblue: "rgb(240,248,255)",
|
|
238
|
+
antiquewhite: "rgb(250,235,215)",
|
|
239
|
+
aqua: "rgb(0,255,255)",
|
|
240
|
+
aquamarine: "rgb(127,255,212)",
|
|
241
|
+
azure: "rgb(240,255,255)",
|
|
242
|
+
beige: "rgb(245,245,220)",
|
|
243
|
+
bisque: "rgb(255,228,196)",
|
|
244
|
+
black: "rgb(0,0,0)",
|
|
245
|
+
blanchedalmond: "rgb(255,235,205)",
|
|
246
|
+
blue: "rgb(0,0,255)",
|
|
247
|
+
blueviolet: "rgb(138,43,226)",
|
|
248
|
+
brown: "rgb(165,42,42)",
|
|
249
|
+
burlywood: "rgb(222,184,135)",
|
|
250
|
+
cadetblue: "rgb(95,158,160)",
|
|
251
|
+
chartreuse: "rgb(127,255,0)",
|
|
252
|
+
chocolate: "rgb(210,105,30)",
|
|
253
|
+
coral: "rgb(255,127,80)",
|
|
254
|
+
cornflowerblue: "rgb(100,149,237)",
|
|
255
|
+
cornsilk: "rgb(255,248,220)",
|
|
256
|
+
crimson: "rgb(220,20,60)",
|
|
257
|
+
cyan: "rgb(0,255,255)",
|
|
258
|
+
darkblue: "rgb(0,0,139)",
|
|
259
|
+
darkcyan: "rgb(0,139,139)",
|
|
260
|
+
darkgoldenrod: "rgb(184,134,11)",
|
|
261
|
+
darkgray: "rgb(169,169,169)",
|
|
262
|
+
darkgreen: "rgb(0,100,0)",
|
|
263
|
+
darkgrey: "rgb(169,169,169)",
|
|
264
|
+
darkkhaki: "rgb(189,183,107)",
|
|
265
|
+
darkmagenta: "rgb(139,0,139)",
|
|
266
|
+
darkolivegreen: "rgb(85,107,47)",
|
|
267
|
+
darkorange: "rgb(255,140,0)",
|
|
268
|
+
darkorchid: "rgb(153,50,204)",
|
|
269
|
+
darkred: "rgb(139,0,0)",
|
|
270
|
+
darksalmon: "rgb(233,150,122)",
|
|
271
|
+
darkseagreen: "rgb(143,188,143)",
|
|
272
|
+
darkslateblue: "rgb(72,61,139)",
|
|
273
|
+
darkslategray: "rgb(47,79,79)",
|
|
274
|
+
darkslategrey: "rgb(47,79,79)",
|
|
275
|
+
darkturquoise: "rgb(0,206,209)",
|
|
276
|
+
darkviolet: "rgb(148,0,211)",
|
|
277
|
+
deeppink: "rgb(255,20,147)",
|
|
278
|
+
deepskyblue: "rgb(0,191,255)",
|
|
279
|
+
dimgray: "rgb(105,105,105)",
|
|
280
|
+
dimgrey: "rgb(105,105,105)",
|
|
281
|
+
dodgerblue: "rgb(30,144,255)",
|
|
282
|
+
firebrick: "rgb(178,34,34)",
|
|
283
|
+
floralwhite: "rgb(255,250,240)",
|
|
284
|
+
forestgreen: "rgb(34,139,34)",
|
|
285
|
+
fuchsia: "rgb(255,0,255)",
|
|
286
|
+
gainsboro: "rgb(220,220,220)",
|
|
287
|
+
ghostwhite: "rgb(248,248,255)",
|
|
288
|
+
gold: "rgb(255,215,0)",
|
|
289
|
+
goldenrod: "rgb(218,165,32)",
|
|
290
|
+
gray: "rgb(128,128,128)",
|
|
291
|
+
green: "rgb(0,128,0)",
|
|
292
|
+
greenyellow: "rgb(173,255,47)",
|
|
293
|
+
grey: "rgb(128,128,128)",
|
|
294
|
+
honeydew: "rgb(240,255,240)",
|
|
295
|
+
hotpink: "rgb(255,105,180)",
|
|
296
|
+
indianred: "rgb(205,92,92)",
|
|
297
|
+
indigo: "rgb(75,0,130)",
|
|
298
|
+
ivory: "rgb(255,255,240)",
|
|
299
|
+
khaki: "rgb(240,230,140)",
|
|
300
|
+
lavender: "rgb(230,230,250)",
|
|
301
|
+
lavenderblush: "rgb(255,240,245)",
|
|
302
|
+
lawngreen: "rgb(124,252,0)",
|
|
303
|
+
lemonchiffon: "rgb(255,250,205)",
|
|
304
|
+
lightblue: "rgb(173,216,230)",
|
|
305
|
+
lightcoral: "rgb(240,128,128)",
|
|
306
|
+
lightcyan: "rgb(224,255,255)",
|
|
307
|
+
lightgoldenrodyellow: "rgb(250,250,210)",
|
|
308
|
+
lightgray: "rgb(211,211,211)",
|
|
309
|
+
lightgreen: "rgb(144,238,144)",
|
|
310
|
+
lightgrey: "rgb(211,211,211)",
|
|
311
|
+
lightpink: "rgb(255,182,193)",
|
|
312
|
+
lightsalmon: "rgb(255,160,122)",
|
|
313
|
+
lightseagreen: "rgb(32,178,170)",
|
|
314
|
+
lightskyblue: "rgb(135,206,250)",
|
|
315
|
+
lightslategray: "rgb(119,136,153)",
|
|
316
|
+
lightslategrey: "rgb(119,136,153)",
|
|
317
|
+
lightsteelblue: "rgb(176,196,222)",
|
|
318
|
+
lightyellow: "rgb(255,255,224)",
|
|
319
|
+
lime: "rgb(0,255,0)",
|
|
320
|
+
limegreen: "rgb(50,205,50)",
|
|
321
|
+
linen: "rgb(250,240,230)",
|
|
322
|
+
magenta: "rgb(255,0,255)",
|
|
323
|
+
maroon: "rgb(128,0,0)",
|
|
324
|
+
mediumaquamarine: "rgb(102,205,170)",
|
|
325
|
+
mediumblue: "rgb(0,0,205)",
|
|
326
|
+
mediumorchid: "rgb(186,85,211)",
|
|
327
|
+
mediumpurple: "rgb(147,112,219)",
|
|
328
|
+
mediumseagreen: "rgb(60,179,113)",
|
|
329
|
+
mediumslateblue: "rgb(123,104,238)",
|
|
330
|
+
mediumspringgreen: "rgb(0,250,154)",
|
|
331
|
+
mediumturquoise: "rgb(72,209,204)",
|
|
332
|
+
mediumvioletred: "rgb(199,21,133)",
|
|
333
|
+
midnightblue: "rgb(25,25,112)",
|
|
334
|
+
mintcream: "rgb(245,255,250)",
|
|
335
|
+
mistyrose: "rgb(255,228,225)",
|
|
336
|
+
moccasin: "rgb(255,228,181)",
|
|
337
|
+
navajowhite: "rgb(255,222,173)",
|
|
338
|
+
navy: "rgb(0,0,128)",
|
|
339
|
+
oldlace: "rgb(253,245,230)",
|
|
340
|
+
olive: "rgb(128,128,0)",
|
|
341
|
+
olivedrab: "rgb(107,142,35)",
|
|
342
|
+
orange: "rgb(255,165,0)",
|
|
343
|
+
orangered: "rgb(255,69,0)",
|
|
344
|
+
orchid: "rgb(218,112,214)",
|
|
345
|
+
palegoldenrod: "rgb(238,232,170)",
|
|
346
|
+
palegreen: "rgb(152,251,152)",
|
|
347
|
+
paleturquoise: "rgb(175,238,238)",
|
|
348
|
+
palevioletred: "rgb(219,112,147)",
|
|
349
|
+
papayawhip: "rgb(255,239,213)",
|
|
350
|
+
peachpuff: "rgb(255,218,185)",
|
|
351
|
+
peru: "rgb(205,133,63)",
|
|
352
|
+
pink: "rgb(255,192,203)",
|
|
353
|
+
plum: "rgb(221,160,221)",
|
|
354
|
+
powderblue: "rgb(176,224,230)",
|
|
355
|
+
purple: "rgb(128,0,128)",
|
|
356
|
+
rebeccapurple: "rgb(102,51,153)",
|
|
357
|
+
red: "rgb(255,0,0)",
|
|
358
|
+
rosybrown: "rgb(188,143,143)",
|
|
359
|
+
royalblue: "rgb(65,105,225)",
|
|
360
|
+
saddlebrown: "rgb(139,69,19)",
|
|
361
|
+
salmon: "rgb(250,128,114)",
|
|
362
|
+
sandybrown: "rgb(244,164,96)",
|
|
363
|
+
seagreen: "rgb(46,139,87)",
|
|
364
|
+
seashell: "rgb(255,245,238)",
|
|
365
|
+
sienna: "rgb(160,82,45)",
|
|
366
|
+
silver: "rgb(192,192,192)",
|
|
367
|
+
skyblue: "rgb(135,206,235)",
|
|
368
|
+
slateblue: "rgb(106,90,205)",
|
|
369
|
+
slategray: "rgb(112,128,144)",
|
|
370
|
+
slategrey: "rgb(112,128,144)",
|
|
371
|
+
snow: "rgb(255,250,250)",
|
|
372
|
+
springgreen: "rgb(0,255,127)",
|
|
373
|
+
steelblue: "rgb(70,130,180)",
|
|
374
|
+
tan: "rgb(210,180,140)",
|
|
375
|
+
teal: "rgb(0,128,128)",
|
|
376
|
+
thistle: "rgb(216,191,216)",
|
|
377
|
+
tomato: "rgb(255,99,71)",
|
|
378
|
+
turquoise: "rgb(64,224,208)",
|
|
379
|
+
violet: "rgb(238,130,238)",
|
|
380
|
+
wheat: "rgb(245,222,179)",
|
|
381
|
+
white: "rgb(255,255,255)",
|
|
382
|
+
whitesmoke: "rgb(245,245,245)",
|
|
383
|
+
yellow: "rgb(255,255,0)",
|
|
384
|
+
yellowgreen: "rgb(154,205,50)"
|
|
385
|
+
};
|
|
236
386
|
/**
|
|
237
387
|
* **createConstant**(kind)
|
|
238
388
|
*
|
|
@@ -8489,6 +8639,306 @@ const WHITESPACE_CHARS$1 = [
|
|
|
8489
8639
|
" ",
|
|
8490
8640
|
"\b"
|
|
8491
8641
|
];
|
|
8642
|
+
const CSS_NAMED_COLORS$1 = [
|
|
8643
|
+
"aliceblue",
|
|
8644
|
+
"antiquewhite",
|
|
8645
|
+
"aqua",
|
|
8646
|
+
"aquamarine",
|
|
8647
|
+
"azure",
|
|
8648
|
+
"beige",
|
|
8649
|
+
"bisque",
|
|
8650
|
+
"black",
|
|
8651
|
+
"blanchedalmond",
|
|
8652
|
+
"blue",
|
|
8653
|
+
"blueviolet",
|
|
8654
|
+
"brown",
|
|
8655
|
+
"burlywood",
|
|
8656
|
+
"cadetblue",
|
|
8657
|
+
"chartreuse",
|
|
8658
|
+
"chocolate",
|
|
8659
|
+
"coral",
|
|
8660
|
+
"cornflowerblue",
|
|
8661
|
+
"cornsilk",
|
|
8662
|
+
"crimson",
|
|
8663
|
+
"cyan",
|
|
8664
|
+
"darkblue",
|
|
8665
|
+
"darkcyan",
|
|
8666
|
+
"darkgoldenrod",
|
|
8667
|
+
"darkgray",
|
|
8668
|
+
"darkgreen",
|
|
8669
|
+
"darkgrey",
|
|
8670
|
+
"darkkhaki",
|
|
8671
|
+
"darkmagenta",
|
|
8672
|
+
"darkolivegreen",
|
|
8673
|
+
"darkorange",
|
|
8674
|
+
"darkorchid",
|
|
8675
|
+
"darkred",
|
|
8676
|
+
"darksalmon",
|
|
8677
|
+
"darkseagreen",
|
|
8678
|
+
"darkslateblue",
|
|
8679
|
+
"darkslategray",
|
|
8680
|
+
"darkslategrey",
|
|
8681
|
+
"darkturquoise",
|
|
8682
|
+
"darkviolet",
|
|
8683
|
+
"deeppink",
|
|
8684
|
+
"deepskyblue",
|
|
8685
|
+
"dimgray",
|
|
8686
|
+
"dimgrey",
|
|
8687
|
+
"dodgerblue",
|
|
8688
|
+
"firebrick",
|
|
8689
|
+
"floralwhite",
|
|
8690
|
+
"forestgreen",
|
|
8691
|
+
"fuchsia",
|
|
8692
|
+
"gainsboro",
|
|
8693
|
+
"ghostwhite",
|
|
8694
|
+
"gold",
|
|
8695
|
+
"goldenrod",
|
|
8696
|
+
"gray",
|
|
8697
|
+
"green",
|
|
8698
|
+
"greenyellow",
|
|
8699
|
+
"grey",
|
|
8700
|
+
"honeydew",
|
|
8701
|
+
"hotpink",
|
|
8702
|
+
"indianred",
|
|
8703
|
+
"indigo",
|
|
8704
|
+
"ivory",
|
|
8705
|
+
"khaki",
|
|
8706
|
+
"lavender",
|
|
8707
|
+
"lavenderblush",
|
|
8708
|
+
"lawngreen",
|
|
8709
|
+
"lemonchiffon",
|
|
8710
|
+
"lightblue",
|
|
8711
|
+
"lightcoral",
|
|
8712
|
+
"lightcyan",
|
|
8713
|
+
"lightgoldenrodyellow",
|
|
8714
|
+
"lightgray",
|
|
8715
|
+
"lightgreen",
|
|
8716
|
+
"lightgrey",
|
|
8717
|
+
"lightpink",
|
|
8718
|
+
"lightsalmon",
|
|
8719
|
+
"lightseagreen",
|
|
8720
|
+
"lightskyblue",
|
|
8721
|
+
"lightslategray",
|
|
8722
|
+
"lightslategrey",
|
|
8723
|
+
"lightsteelblue",
|
|
8724
|
+
"lightyellow",
|
|
8725
|
+
"lime",
|
|
8726
|
+
"limegreen",
|
|
8727
|
+
"linen",
|
|
8728
|
+
"magenta",
|
|
8729
|
+
"maroon",
|
|
8730
|
+
"mediumaquamarine",
|
|
8731
|
+
"mediumblue",
|
|
8732
|
+
"mediumorchid",
|
|
8733
|
+
"mediumpurple",
|
|
8734
|
+
"mediumseagreen",
|
|
8735
|
+
"mediumslateblue",
|
|
8736
|
+
"mediumspringgreen",
|
|
8737
|
+
"mediumturquoise",
|
|
8738
|
+
"mediumvioletred",
|
|
8739
|
+
"midnightblue",
|
|
8740
|
+
"mintcream",
|
|
8741
|
+
"mistyrose",
|
|
8742
|
+
"moccasin",
|
|
8743
|
+
"navajowhite",
|
|
8744
|
+
"navy",
|
|
8745
|
+
"oldlace",
|
|
8746
|
+
"olive",
|
|
8747
|
+
"olivedrab",
|
|
8748
|
+
"orange",
|
|
8749
|
+
"orangered",
|
|
8750
|
+
"orchid",
|
|
8751
|
+
"palegoldenrod",
|
|
8752
|
+
"palegreen",
|
|
8753
|
+
"paleturquoise",
|
|
8754
|
+
"palevioletred",
|
|
8755
|
+
"papayawhip",
|
|
8756
|
+
"peachpuff",
|
|
8757
|
+
"peru",
|
|
8758
|
+
"pink",
|
|
8759
|
+
"plum",
|
|
8760
|
+
"powderblue",
|
|
8761
|
+
"purple",
|
|
8762
|
+
"rebeccapurple",
|
|
8763
|
+
"red",
|
|
8764
|
+
"rosybrown",
|
|
8765
|
+
"royalblue",
|
|
8766
|
+
"saddlebrown",
|
|
8767
|
+
"salmon",
|
|
8768
|
+
"sandybrown",
|
|
8769
|
+
"seagreen",
|
|
8770
|
+
"seashell",
|
|
8771
|
+
"sienna",
|
|
8772
|
+
"silver",
|
|
8773
|
+
"skyblue",
|
|
8774
|
+
"slateblue",
|
|
8775
|
+
"slategray",
|
|
8776
|
+
"slategrey",
|
|
8777
|
+
"snow",
|
|
8778
|
+
"springgreen",
|
|
8779
|
+
"steelblue",
|
|
8780
|
+
"tan",
|
|
8781
|
+
"teal",
|
|
8782
|
+
"thistle",
|
|
8783
|
+
"tomato",
|
|
8784
|
+
"turquoise",
|
|
8785
|
+
"violet",
|
|
8786
|
+
"wheat",
|
|
8787
|
+
"white",
|
|
8788
|
+
"whitesmoke",
|
|
8789
|
+
"yellow",
|
|
8790
|
+
"yellowgreen"
|
|
8791
|
+
];
|
|
8792
|
+
const CSS_COLOR_LOOKUP$1 = {
|
|
8793
|
+
aliceblue: "rgb(240,248,255)",
|
|
8794
|
+
antiquewhite: "rgb(250,235,215)",
|
|
8795
|
+
aqua: "rgb(0,255,255)",
|
|
8796
|
+
aquamarine: "rgb(127,255,212)",
|
|
8797
|
+
azure: "rgb(240,255,255)",
|
|
8798
|
+
beige: "rgb(245,245,220)",
|
|
8799
|
+
bisque: "rgb(255,228,196)",
|
|
8800
|
+
black: "rgb(0,0,0)",
|
|
8801
|
+
blanchedalmond: "rgb(255,235,205)",
|
|
8802
|
+
blue: "rgb(0,0,255)",
|
|
8803
|
+
blueviolet: "rgb(138,43,226)",
|
|
8804
|
+
brown: "rgb(165,42,42)",
|
|
8805
|
+
burlywood: "rgb(222,184,135)",
|
|
8806
|
+
cadetblue: "rgb(95,158,160)",
|
|
8807
|
+
chartreuse: "rgb(127,255,0)",
|
|
8808
|
+
chocolate: "rgb(210,105,30)",
|
|
8809
|
+
coral: "rgb(255,127,80)",
|
|
8810
|
+
cornflowerblue: "rgb(100,149,237)",
|
|
8811
|
+
cornsilk: "rgb(255,248,220)",
|
|
8812
|
+
crimson: "rgb(220,20,60)",
|
|
8813
|
+
cyan: "rgb(0,255,255)",
|
|
8814
|
+
darkblue: "rgb(0,0,139)",
|
|
8815
|
+
darkcyan: "rgb(0,139,139)",
|
|
8816
|
+
darkgoldenrod: "rgb(184,134,11)",
|
|
8817
|
+
darkgray: "rgb(169,169,169)",
|
|
8818
|
+
darkgreen: "rgb(0,100,0)",
|
|
8819
|
+
darkgrey: "rgb(169,169,169)",
|
|
8820
|
+
darkkhaki: "rgb(189,183,107)",
|
|
8821
|
+
darkmagenta: "rgb(139,0,139)",
|
|
8822
|
+
darkolivegreen: "rgb(85,107,47)",
|
|
8823
|
+
darkorange: "rgb(255,140,0)",
|
|
8824
|
+
darkorchid: "rgb(153,50,204)",
|
|
8825
|
+
darkred: "rgb(139,0,0)",
|
|
8826
|
+
darksalmon: "rgb(233,150,122)",
|
|
8827
|
+
darkseagreen: "rgb(143,188,143)",
|
|
8828
|
+
darkslateblue: "rgb(72,61,139)",
|
|
8829
|
+
darkslategray: "rgb(47,79,79)",
|
|
8830
|
+
darkslategrey: "rgb(47,79,79)",
|
|
8831
|
+
darkturquoise: "rgb(0,206,209)",
|
|
8832
|
+
darkviolet: "rgb(148,0,211)",
|
|
8833
|
+
deeppink: "rgb(255,20,147)",
|
|
8834
|
+
deepskyblue: "rgb(0,191,255)",
|
|
8835
|
+
dimgray: "rgb(105,105,105)",
|
|
8836
|
+
dimgrey: "rgb(105,105,105)",
|
|
8837
|
+
dodgerblue: "rgb(30,144,255)",
|
|
8838
|
+
firebrick: "rgb(178,34,34)",
|
|
8839
|
+
floralwhite: "rgb(255,250,240)",
|
|
8840
|
+
forestgreen: "rgb(34,139,34)",
|
|
8841
|
+
fuchsia: "rgb(255,0,255)",
|
|
8842
|
+
gainsboro: "rgb(220,220,220)",
|
|
8843
|
+
ghostwhite: "rgb(248,248,255)",
|
|
8844
|
+
gold: "rgb(255,215,0)",
|
|
8845
|
+
goldenrod: "rgb(218,165,32)",
|
|
8846
|
+
gray: "rgb(128,128,128)",
|
|
8847
|
+
green: "rgb(0,128,0)",
|
|
8848
|
+
greenyellow: "rgb(173,255,47)",
|
|
8849
|
+
grey: "rgb(128,128,128)",
|
|
8850
|
+
honeydew: "rgb(240,255,240)",
|
|
8851
|
+
hotpink: "rgb(255,105,180)",
|
|
8852
|
+
indianred: "rgb(205,92,92)",
|
|
8853
|
+
indigo: "rgb(75,0,130)",
|
|
8854
|
+
ivory: "rgb(255,255,240)",
|
|
8855
|
+
khaki: "rgb(240,230,140)",
|
|
8856
|
+
lavender: "rgb(230,230,250)",
|
|
8857
|
+
lavenderblush: "rgb(255,240,245)",
|
|
8858
|
+
lawngreen: "rgb(124,252,0)",
|
|
8859
|
+
lemonchiffon: "rgb(255,250,205)",
|
|
8860
|
+
lightblue: "rgb(173,216,230)",
|
|
8861
|
+
lightcoral: "rgb(240,128,128)",
|
|
8862
|
+
lightcyan: "rgb(224,255,255)",
|
|
8863
|
+
lightgoldenrodyellow: "rgb(250,250,210)",
|
|
8864
|
+
lightgray: "rgb(211,211,211)",
|
|
8865
|
+
lightgreen: "rgb(144,238,144)",
|
|
8866
|
+
lightgrey: "rgb(211,211,211)",
|
|
8867
|
+
lightpink: "rgb(255,182,193)",
|
|
8868
|
+
lightsalmon: "rgb(255,160,122)",
|
|
8869
|
+
lightseagreen: "rgb(32,178,170)",
|
|
8870
|
+
lightskyblue: "rgb(135,206,250)",
|
|
8871
|
+
lightslategray: "rgb(119,136,153)",
|
|
8872
|
+
lightslategrey: "rgb(119,136,153)",
|
|
8873
|
+
lightsteelblue: "rgb(176,196,222)",
|
|
8874
|
+
lightyellow: "rgb(255,255,224)",
|
|
8875
|
+
lime: "rgb(0,255,0)",
|
|
8876
|
+
limegreen: "rgb(50,205,50)",
|
|
8877
|
+
linen: "rgb(250,240,230)",
|
|
8878
|
+
magenta: "rgb(255,0,255)",
|
|
8879
|
+
maroon: "rgb(128,0,0)",
|
|
8880
|
+
mediumaquamarine: "rgb(102,205,170)",
|
|
8881
|
+
mediumblue: "rgb(0,0,205)",
|
|
8882
|
+
mediumorchid: "rgb(186,85,211)",
|
|
8883
|
+
mediumpurple: "rgb(147,112,219)",
|
|
8884
|
+
mediumseagreen: "rgb(60,179,113)",
|
|
8885
|
+
mediumslateblue: "rgb(123,104,238)",
|
|
8886
|
+
mediumspringgreen: "rgb(0,250,154)",
|
|
8887
|
+
mediumturquoise: "rgb(72,209,204)",
|
|
8888
|
+
mediumvioletred: "rgb(199,21,133)",
|
|
8889
|
+
midnightblue: "rgb(25,25,112)",
|
|
8890
|
+
mintcream: "rgb(245,255,250)",
|
|
8891
|
+
mistyrose: "rgb(255,228,225)",
|
|
8892
|
+
moccasin: "rgb(255,228,181)",
|
|
8893
|
+
navajowhite: "rgb(255,222,173)",
|
|
8894
|
+
navy: "rgb(0,0,128)",
|
|
8895
|
+
oldlace: "rgb(253,245,230)",
|
|
8896
|
+
olive: "rgb(128,128,0)",
|
|
8897
|
+
olivedrab: "rgb(107,142,35)",
|
|
8898
|
+
orange: "rgb(255,165,0)",
|
|
8899
|
+
orangered: "rgb(255,69,0)",
|
|
8900
|
+
orchid: "rgb(218,112,214)",
|
|
8901
|
+
palegoldenrod: "rgb(238,232,170)",
|
|
8902
|
+
palegreen: "rgb(152,251,152)",
|
|
8903
|
+
paleturquoise: "rgb(175,238,238)",
|
|
8904
|
+
palevioletred: "rgb(219,112,147)",
|
|
8905
|
+
papayawhip: "rgb(255,239,213)",
|
|
8906
|
+
peachpuff: "rgb(255,218,185)",
|
|
8907
|
+
peru: "rgb(205,133,63)",
|
|
8908
|
+
pink: "rgb(255,192,203)",
|
|
8909
|
+
plum: "rgb(221,160,221)",
|
|
8910
|
+
powderblue: "rgb(176,224,230)",
|
|
8911
|
+
purple: "rgb(128,0,128)",
|
|
8912
|
+
rebeccapurple: "rgb(102,51,153)",
|
|
8913
|
+
red: "rgb(255,0,0)",
|
|
8914
|
+
rosybrown: "rgb(188,143,143)",
|
|
8915
|
+
royalblue: "rgb(65,105,225)",
|
|
8916
|
+
saddlebrown: "rgb(139,69,19)",
|
|
8917
|
+
salmon: "rgb(250,128,114)",
|
|
8918
|
+
sandybrown: "rgb(244,164,96)",
|
|
8919
|
+
seagreen: "rgb(46,139,87)",
|
|
8920
|
+
seashell: "rgb(255,245,238)",
|
|
8921
|
+
sienna: "rgb(160,82,45)",
|
|
8922
|
+
silver: "rgb(192,192,192)",
|
|
8923
|
+
skyblue: "rgb(135,206,235)",
|
|
8924
|
+
slateblue: "rgb(106,90,205)",
|
|
8925
|
+
slategray: "rgb(112,128,144)",
|
|
8926
|
+
slategrey: "rgb(112,128,144)",
|
|
8927
|
+
snow: "rgb(255,250,250)",
|
|
8928
|
+
springgreen: "rgb(0,255,127)",
|
|
8929
|
+
steelblue: "rgb(70,130,180)",
|
|
8930
|
+
tan: "rgb(210,180,140)",
|
|
8931
|
+
teal: "rgb(0,128,128)",
|
|
8932
|
+
thistle: "rgb(216,191,216)",
|
|
8933
|
+
tomato: "rgb(255,99,71)",
|
|
8934
|
+
turquoise: "rgb(64,224,208)",
|
|
8935
|
+
violet: "rgb(238,130,238)",
|
|
8936
|
+
wheat: "rgb(245,222,179)",
|
|
8937
|
+
white: "rgb(255,255,255)",
|
|
8938
|
+
whitesmoke: "rgb(245,245,245)",
|
|
8939
|
+
yellow: "rgb(255,255,0)",
|
|
8940
|
+
yellowgreen: "rgb(154,205,50)"
|
|
8941
|
+
};
|
|
8492
8942
|
/**
|
|
8493
8943
|
* **createConstant**(kind)
|
|
8494
8944
|
*
|
|
@@ -15283,6 +15733,25 @@ function isValidComparisonParams(op, params) {
|
|
|
15283
15733
|
return !!isComparisonOperation(op);
|
|
15284
15734
|
}
|
|
15285
15735
|
/**
|
|
15736
|
+
* **isNamedColor**`(val) -> is CssNamedColor`
|
|
15737
|
+
*
|
|
15738
|
+
* Typeguard to validate that `val` is a CSS/HTML Named Color.
|
|
15739
|
+
*
|
|
15740
|
+
* - to match you must make sure the string name is lowercase
|
|
15741
|
+
*/
|
|
15742
|
+
function isNamedColor(val) {
|
|
15743
|
+
return isString(val) && CSS_NAMED_COLORS$1.includes(val);
|
|
15744
|
+
}
|
|
15745
|
+
/**
|
|
15746
|
+
* **isRgbColor**`(val) -> is RgbColor`
|
|
15747
|
+
*
|
|
15748
|
+
* Typeguard that validates that `val` is a valid RbgColor (e.g.,
|
|
15749
|
+
* `rgb(127,0,0)`)
|
|
15750
|
+
*/
|
|
15751
|
+
function isRgbColor(val) {
|
|
15752
|
+
return isString(val) && val.startsWith("rgb(") && val.endsWith(")");
|
|
15753
|
+
}
|
|
15754
|
+
/**
|
|
15286
15755
|
* A type guard which validates whether the passed in value is a JavaScript Date object.
|
|
15287
15756
|
*/
|
|
15288
15757
|
function isDate(val) {
|
|
@@ -20233,6 +20702,43 @@ function defineCss(defn) {
|
|
|
20233
20702
|
};
|
|
20234
20703
|
return createFnWithProps(fn$1, { defn });
|
|
20235
20704
|
}
|
|
20705
|
+
function parseRgbColor(color) {
|
|
20706
|
+
if (isRgbColor(color)) {
|
|
20707
|
+
const [r, g, b] = stripTrailing(stripLeading(color, "rgb("), ")").split(",").map((i) => i.trim().toLowerCase());
|
|
20708
|
+
return [
|
|
20709
|
+
r,
|
|
20710
|
+
g,
|
|
20711
|
+
b
|
|
20712
|
+
].every((i) => isNumberLike(i)) ? {
|
|
20713
|
+
r: asNumber(r),
|
|
20714
|
+
g: asNumber(g),
|
|
20715
|
+
b: asNumber(b)
|
|
20716
|
+
} : err(`invalid-color/rgb`, `Some of the values assigned to the RGB colors are unable to be parsed to a numeric value: ${color}`, {
|
|
20717
|
+
color,
|
|
20718
|
+
r,
|
|
20719
|
+
g,
|
|
20720
|
+
b
|
|
20721
|
+
});
|
|
20722
|
+
}
|
|
20723
|
+
return err(`invalid-color/rgb`, `Could not parse the string passed in -- '${color}' -- as an RGB color. Must look something like: rgb(#,#,#)`, { color });
|
|
20724
|
+
}
|
|
20725
|
+
function parseNamedColor(color) {
|
|
20726
|
+
return Object.keys(CSS_COLOR_LOOKUP$1).includes(color) ? parseRgbColor(CSS_COLOR_LOOKUP$1[color]) : err(`invalid-color/named`, `The string -- ${color} -- is not a valid "named color" recognized by HTML and CSS. Make sure you have no whitespace or uppercase characters.`, { color });
|
|
20727
|
+
}
|
|
20728
|
+
/**
|
|
20729
|
+
* **parseColor**`(color) -> RGB`
|
|
20730
|
+
*
|
|
20731
|
+
* Extracts the discrete RGB values from both `CssRgb` strings and
|
|
20732
|
+
* _named colors_ recognized by HTML and CSS.
|
|
20733
|
+
*
|
|
20734
|
+
* = Note: all strings are trimmed and forced to lowercase to help
|
|
20735
|
+
* with matching.
|
|
20736
|
+
*/
|
|
20737
|
+
function parseColor(color) {
|
|
20738
|
+
if (isRgbColor(color)) return parseRgbColor(color);
|
|
20739
|
+
else if (isNamedColor(color)) return parseNamedColor(color);
|
|
20740
|
+
else return err("invalid-color", `The string passed in -- ${color} -- could not be parsed as either a CSS RGB Color or a CSS Named Color.`, { color });
|
|
20741
|
+
}
|
|
20236
20742
|
/**
|
|
20237
20743
|
* **asDate**`(input)`
|
|
20238
20744
|
*
|
|
@@ -23429,6 +23935,7 @@ exports.COMPARISON_OPERATIONS = COMPARISON_OPERATIONS;
|
|
|
23429
23935
|
exports.CONSONANTS = CONSONANTS;
|
|
23430
23936
|
exports.CONTINENTS = CONTINENTS;
|
|
23431
23937
|
exports.COSTCO_DNS = COSTCO_DNS;
|
|
23938
|
+
exports.CSS_COLOR_LOOKUP = CSS_COLOR_LOOKUP;
|
|
23432
23939
|
exports.CSS_NAMED_COLORS = CSS_NAMED_COLORS;
|
|
23433
23940
|
exports.CURRENT_METRICS_LOOKUP = CURRENT_METRICS_LOOKUP;
|
|
23434
23941
|
exports.CVS_DNS = CVS_DNS;
|
|
@@ -23978,6 +24485,7 @@ exports.isMinimalDigitDate = isMinimalDigitDate;
|
|
|
23978
24485
|
exports.isMoment = isMoment;
|
|
23979
24486
|
exports.isMonthAbbrev = isMonthAbbrev;
|
|
23980
24487
|
exports.isMonthName = isMonthName;
|
|
24488
|
+
exports.isNamedColor = isNamedColor;
|
|
23981
24489
|
exports.isNarrowable = isNarrowable;
|
|
23982
24490
|
exports.isNarrowableArray = isNarrowableArray;
|
|
23983
24491
|
exports.isNarrowableDictionary = isNarrowableDictionary;
|
|
@@ -24023,6 +24531,7 @@ exports.isRepoUrl = isRepoUrl;
|
|
|
24023
24531
|
exports.isResistanceMetric = isResistanceMetric;
|
|
24024
24532
|
exports.isResistanceUom = isResistanceUom;
|
|
24025
24533
|
exports.isRetailUrl = isRetailUrl;
|
|
24534
|
+
exports.isRgbColor = isRgbColor;
|
|
24026
24535
|
exports.isSameDay = isSameDay;
|
|
24027
24536
|
exports.isSameMonth = isSameMonth;
|
|
24028
24537
|
exports.isSameMonthYear = isSameMonthYear;
|
|
@@ -24170,10 +24679,13 @@ exports.optional = optional;
|
|
|
24170
24679
|
exports.optionalOrNull = optionalOrNull;
|
|
24171
24680
|
exports.or = or;
|
|
24172
24681
|
exports.orNull = orNull;
|
|
24682
|
+
exports.parseColor = parseColor;
|
|
24173
24683
|
exports.parseDate = parseDate;
|
|
24174
24684
|
exports.parseDateObject = parseDateObject;
|
|
24175
24685
|
exports.parseIsoDate = parseIsoDate;
|
|
24686
|
+
exports.parseNamedColor = parseNamedColor;
|
|
24176
24687
|
exports.parseNumericDate = parseNumericDate;
|
|
24688
|
+
exports.parseRgbColor = parseRgbColor;
|
|
24177
24689
|
exports.pathJoin = pathJoin;
|
|
24178
24690
|
exports.pluralize = pluralize;
|
|
24179
24691
|
exports.pop = pop;
|