@nsshunt/stsfhirpg 1.2.15 → 1.2.16
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/dist/index.cjs +343 -2059
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +343 -2059
- package/dist/index.mjs.map +1 -1
- package/package.json +8 -7
- package/types/fhir-database/dbsearchindextesthelpers.d.ts +20 -21
- package/types/fhir-database/dbsearchindextesthelpers.d.ts.map +1 -1
package/dist/index.cjs
CHANGED
|
@@ -7186,2055 +7186,340 @@ var ResourceHelper = class ResourceHelper {
|
|
|
7186
7186
|
};
|
|
7187
7187
|
};
|
|
7188
7188
|
//#endregion
|
|
7189
|
-
//#region node_modules/
|
|
7190
|
-
var
|
|
7191
|
-
|
|
7192
|
-
|
|
7193
|
-
|
|
7194
|
-
|
|
7195
|
-
|
|
7196
|
-
],
|
|
7197
|
-
|
|
7198
|
-
|
|
7199
|
-
|
|
7200
|
-
|
|
7201
|
-
],
|
|
7202
|
-
|
|
7203
|
-
|
|
7204
|
-
|
|
7205
|
-
|
|
7206
|
-
|
|
7207
|
-
|
|
7208
|
-
|
|
7209
|
-
|
|
7210
|
-
|
|
7211
|
-
],
|
|
7212
|
-
|
|
7213
|
-
|
|
7214
|
-
|
|
7215
|
-
|
|
7216
|
-
],
|
|
7217
|
-
|
|
7218
|
-
|
|
7219
|
-
|
|
7220
|
-
|
|
7221
|
-
],
|
|
7222
|
-
|
|
7223
|
-
|
|
7224
|
-
|
|
7225
|
-
|
|
7226
|
-
|
|
7227
|
-
|
|
7228
|
-
|
|
7229
|
-
|
|
7230
|
-
|
|
7231
|
-
],
|
|
7232
|
-
|
|
7233
|
-
|
|
7234
|
-
|
|
7235
|
-
|
|
7236
|
-
],
|
|
7237
|
-
|
|
7238
|
-
|
|
7239
|
-
|
|
7240
|
-
|
|
7241
|
-
],
|
|
7242
|
-
|
|
7243
|
-
|
|
7244
|
-
|
|
7245
|
-
226
|
|
7246
|
-
],
|
|
7247
|
-
"brown": [
|
|
7248
|
-
165,
|
|
7249
|
-
42,
|
|
7250
|
-
42
|
|
7251
|
-
],
|
|
7252
|
-
"burlywood": [
|
|
7253
|
-
222,
|
|
7254
|
-
184,
|
|
7255
|
-
135
|
|
7256
|
-
],
|
|
7257
|
-
"cadetblue": [
|
|
7258
|
-
95,
|
|
7259
|
-
158,
|
|
7260
|
-
160
|
|
7261
|
-
],
|
|
7262
|
-
"chartreuse": [
|
|
7263
|
-
127,
|
|
7264
|
-
255,
|
|
7265
|
-
0
|
|
7266
|
-
],
|
|
7267
|
-
"chocolate": [
|
|
7268
|
-
210,
|
|
7269
|
-
105,
|
|
7270
|
-
30
|
|
7271
|
-
],
|
|
7272
|
-
"coral": [
|
|
7273
|
-
255,
|
|
7274
|
-
127,
|
|
7275
|
-
80
|
|
7276
|
-
],
|
|
7277
|
-
"cornflowerblue": [
|
|
7278
|
-
100,
|
|
7279
|
-
149,
|
|
7280
|
-
237
|
|
7281
|
-
],
|
|
7282
|
-
"cornsilk": [
|
|
7283
|
-
255,
|
|
7284
|
-
248,
|
|
7285
|
-
220
|
|
7286
|
-
],
|
|
7287
|
-
"crimson": [
|
|
7288
|
-
220,
|
|
7289
|
-
20,
|
|
7290
|
-
60
|
|
7291
|
-
],
|
|
7292
|
-
"cyan": [
|
|
7293
|
-
0,
|
|
7294
|
-
255,
|
|
7295
|
-
255
|
|
7296
|
-
],
|
|
7297
|
-
"darkblue": [
|
|
7298
|
-
0,
|
|
7299
|
-
0,
|
|
7300
|
-
139
|
|
7301
|
-
],
|
|
7302
|
-
"darkcyan": [
|
|
7303
|
-
0,
|
|
7304
|
-
139,
|
|
7305
|
-
139
|
|
7306
|
-
],
|
|
7307
|
-
"darkgoldenrod": [
|
|
7308
|
-
184,
|
|
7309
|
-
134,
|
|
7310
|
-
11
|
|
7311
|
-
],
|
|
7312
|
-
"darkgray": [
|
|
7313
|
-
169,
|
|
7314
|
-
169,
|
|
7315
|
-
169
|
|
7316
|
-
],
|
|
7317
|
-
"darkgreen": [
|
|
7318
|
-
0,
|
|
7319
|
-
100,
|
|
7320
|
-
0
|
|
7321
|
-
],
|
|
7322
|
-
"darkgrey": [
|
|
7323
|
-
169,
|
|
7324
|
-
169,
|
|
7325
|
-
169
|
|
7326
|
-
],
|
|
7327
|
-
"darkkhaki": [
|
|
7328
|
-
189,
|
|
7329
|
-
183,
|
|
7330
|
-
107
|
|
7331
|
-
],
|
|
7332
|
-
"darkmagenta": [
|
|
7333
|
-
139,
|
|
7334
|
-
0,
|
|
7335
|
-
139
|
|
7336
|
-
],
|
|
7337
|
-
"darkolivegreen": [
|
|
7338
|
-
85,
|
|
7339
|
-
107,
|
|
7340
|
-
47
|
|
7341
|
-
],
|
|
7342
|
-
"darkorange": [
|
|
7343
|
-
255,
|
|
7344
|
-
140,
|
|
7345
|
-
0
|
|
7346
|
-
],
|
|
7347
|
-
"darkorchid": [
|
|
7348
|
-
153,
|
|
7349
|
-
50,
|
|
7350
|
-
204
|
|
7351
|
-
],
|
|
7352
|
-
"darkred": [
|
|
7353
|
-
139,
|
|
7354
|
-
0,
|
|
7355
|
-
0
|
|
7356
|
-
],
|
|
7357
|
-
"darksalmon": [
|
|
7358
|
-
233,
|
|
7359
|
-
150,
|
|
7360
|
-
122
|
|
7361
|
-
],
|
|
7362
|
-
"darkseagreen": [
|
|
7363
|
-
143,
|
|
7364
|
-
188,
|
|
7365
|
-
143
|
|
7366
|
-
],
|
|
7367
|
-
"darkslateblue": [
|
|
7368
|
-
72,
|
|
7369
|
-
61,
|
|
7370
|
-
139
|
|
7371
|
-
],
|
|
7372
|
-
"darkslategray": [
|
|
7373
|
-
47,
|
|
7374
|
-
79,
|
|
7375
|
-
79
|
|
7376
|
-
],
|
|
7377
|
-
"darkslategrey": [
|
|
7378
|
-
47,
|
|
7379
|
-
79,
|
|
7380
|
-
79
|
|
7381
|
-
],
|
|
7382
|
-
"darkturquoise": [
|
|
7383
|
-
0,
|
|
7384
|
-
206,
|
|
7385
|
-
209
|
|
7386
|
-
],
|
|
7387
|
-
"darkviolet": [
|
|
7388
|
-
148,
|
|
7389
|
-
0,
|
|
7390
|
-
211
|
|
7391
|
-
],
|
|
7392
|
-
"deeppink": [
|
|
7393
|
-
255,
|
|
7394
|
-
20,
|
|
7395
|
-
147
|
|
7396
|
-
],
|
|
7397
|
-
"deepskyblue": [
|
|
7398
|
-
0,
|
|
7399
|
-
191,
|
|
7400
|
-
255
|
|
7401
|
-
],
|
|
7402
|
-
"dimgray": [
|
|
7403
|
-
105,
|
|
7404
|
-
105,
|
|
7405
|
-
105
|
|
7406
|
-
],
|
|
7407
|
-
"dimgrey": [
|
|
7408
|
-
105,
|
|
7409
|
-
105,
|
|
7410
|
-
105
|
|
7411
|
-
],
|
|
7412
|
-
"dodgerblue": [
|
|
7413
|
-
30,
|
|
7414
|
-
144,
|
|
7415
|
-
255
|
|
7416
|
-
],
|
|
7417
|
-
"firebrick": [
|
|
7418
|
-
178,
|
|
7419
|
-
34,
|
|
7420
|
-
34
|
|
7421
|
-
],
|
|
7422
|
-
"floralwhite": [
|
|
7423
|
-
255,
|
|
7424
|
-
250,
|
|
7425
|
-
240
|
|
7426
|
-
],
|
|
7427
|
-
"forestgreen": [
|
|
7428
|
-
34,
|
|
7429
|
-
139,
|
|
7430
|
-
34
|
|
7431
|
-
],
|
|
7432
|
-
"fuchsia": [
|
|
7433
|
-
255,
|
|
7434
|
-
0,
|
|
7435
|
-
255
|
|
7436
|
-
],
|
|
7437
|
-
"gainsboro": [
|
|
7438
|
-
220,
|
|
7439
|
-
220,
|
|
7440
|
-
220
|
|
7441
|
-
],
|
|
7442
|
-
"ghostwhite": [
|
|
7443
|
-
248,
|
|
7444
|
-
248,
|
|
7445
|
-
255
|
|
7446
|
-
],
|
|
7447
|
-
"gold": [
|
|
7448
|
-
255,
|
|
7449
|
-
215,
|
|
7450
|
-
0
|
|
7451
|
-
],
|
|
7452
|
-
"goldenrod": [
|
|
7453
|
-
218,
|
|
7454
|
-
165,
|
|
7455
|
-
32
|
|
7456
|
-
],
|
|
7457
|
-
"gray": [
|
|
7458
|
-
128,
|
|
7459
|
-
128,
|
|
7460
|
-
128
|
|
7461
|
-
],
|
|
7462
|
-
"green": [
|
|
7463
|
-
0,
|
|
7464
|
-
128,
|
|
7465
|
-
0
|
|
7466
|
-
],
|
|
7467
|
-
"greenyellow": [
|
|
7468
|
-
173,
|
|
7469
|
-
255,
|
|
7470
|
-
47
|
|
7471
|
-
],
|
|
7472
|
-
"grey": [
|
|
7473
|
-
128,
|
|
7474
|
-
128,
|
|
7475
|
-
128
|
|
7476
|
-
],
|
|
7477
|
-
"honeydew": [
|
|
7478
|
-
240,
|
|
7479
|
-
255,
|
|
7480
|
-
240
|
|
7481
|
-
],
|
|
7482
|
-
"hotpink": [
|
|
7483
|
-
255,
|
|
7484
|
-
105,
|
|
7485
|
-
180
|
|
7486
|
-
],
|
|
7487
|
-
"indianred": [
|
|
7488
|
-
205,
|
|
7489
|
-
92,
|
|
7490
|
-
92
|
|
7491
|
-
],
|
|
7492
|
-
"indigo": [
|
|
7493
|
-
75,
|
|
7494
|
-
0,
|
|
7495
|
-
130
|
|
7496
|
-
],
|
|
7497
|
-
"ivory": [
|
|
7498
|
-
255,
|
|
7499
|
-
255,
|
|
7500
|
-
240
|
|
7501
|
-
],
|
|
7502
|
-
"khaki": [
|
|
7503
|
-
240,
|
|
7504
|
-
230,
|
|
7505
|
-
140
|
|
7506
|
-
],
|
|
7507
|
-
"lavender": [
|
|
7508
|
-
230,
|
|
7509
|
-
230,
|
|
7510
|
-
250
|
|
7511
|
-
],
|
|
7512
|
-
"lavenderblush": [
|
|
7513
|
-
255,
|
|
7514
|
-
240,
|
|
7515
|
-
245
|
|
7516
|
-
],
|
|
7517
|
-
"lawngreen": [
|
|
7518
|
-
124,
|
|
7519
|
-
252,
|
|
7520
|
-
0
|
|
7521
|
-
],
|
|
7522
|
-
"lemonchiffon": [
|
|
7523
|
-
255,
|
|
7524
|
-
250,
|
|
7525
|
-
205
|
|
7526
|
-
],
|
|
7527
|
-
"lightblue": [
|
|
7528
|
-
173,
|
|
7529
|
-
216,
|
|
7530
|
-
230
|
|
7531
|
-
],
|
|
7532
|
-
"lightcoral": [
|
|
7533
|
-
240,
|
|
7534
|
-
128,
|
|
7535
|
-
128
|
|
7536
|
-
],
|
|
7537
|
-
"lightcyan": [
|
|
7538
|
-
224,
|
|
7539
|
-
255,
|
|
7540
|
-
255
|
|
7541
|
-
],
|
|
7542
|
-
"lightgoldenrodyellow": [
|
|
7543
|
-
250,
|
|
7544
|
-
250,
|
|
7545
|
-
210
|
|
7546
|
-
],
|
|
7547
|
-
"lightgray": [
|
|
7548
|
-
211,
|
|
7549
|
-
211,
|
|
7550
|
-
211
|
|
7551
|
-
],
|
|
7552
|
-
"lightgreen": [
|
|
7553
|
-
144,
|
|
7554
|
-
238,
|
|
7555
|
-
144
|
|
7556
|
-
],
|
|
7557
|
-
"lightgrey": [
|
|
7558
|
-
211,
|
|
7559
|
-
211,
|
|
7560
|
-
211
|
|
7561
|
-
],
|
|
7562
|
-
"lightpink": [
|
|
7563
|
-
255,
|
|
7564
|
-
182,
|
|
7565
|
-
193
|
|
7566
|
-
],
|
|
7567
|
-
"lightsalmon": [
|
|
7568
|
-
255,
|
|
7569
|
-
160,
|
|
7570
|
-
122
|
|
7571
|
-
],
|
|
7572
|
-
"lightseagreen": [
|
|
7573
|
-
32,
|
|
7574
|
-
178,
|
|
7575
|
-
170
|
|
7576
|
-
],
|
|
7577
|
-
"lightskyblue": [
|
|
7578
|
-
135,
|
|
7579
|
-
206,
|
|
7580
|
-
250
|
|
7581
|
-
],
|
|
7582
|
-
"lightslategray": [
|
|
7583
|
-
119,
|
|
7584
|
-
136,
|
|
7585
|
-
153
|
|
7586
|
-
],
|
|
7587
|
-
"lightslategrey": [
|
|
7588
|
-
119,
|
|
7589
|
-
136,
|
|
7590
|
-
153
|
|
7591
|
-
],
|
|
7592
|
-
"lightsteelblue": [
|
|
7593
|
-
176,
|
|
7594
|
-
196,
|
|
7595
|
-
222
|
|
7596
|
-
],
|
|
7597
|
-
"lightyellow": [
|
|
7598
|
-
255,
|
|
7599
|
-
255,
|
|
7600
|
-
224
|
|
7601
|
-
],
|
|
7602
|
-
"lime": [
|
|
7603
|
-
0,
|
|
7604
|
-
255,
|
|
7605
|
-
0
|
|
7606
|
-
],
|
|
7607
|
-
"limegreen": [
|
|
7608
|
-
50,
|
|
7609
|
-
205,
|
|
7610
|
-
50
|
|
7611
|
-
],
|
|
7612
|
-
"linen": [
|
|
7613
|
-
250,
|
|
7614
|
-
240,
|
|
7615
|
-
230
|
|
7616
|
-
],
|
|
7617
|
-
"magenta": [
|
|
7618
|
-
255,
|
|
7619
|
-
0,
|
|
7620
|
-
255
|
|
7621
|
-
],
|
|
7622
|
-
"maroon": [
|
|
7623
|
-
128,
|
|
7624
|
-
0,
|
|
7625
|
-
0
|
|
7626
|
-
],
|
|
7627
|
-
"mediumaquamarine": [
|
|
7628
|
-
102,
|
|
7629
|
-
205,
|
|
7630
|
-
170
|
|
7631
|
-
],
|
|
7632
|
-
"mediumblue": [
|
|
7633
|
-
0,
|
|
7634
|
-
0,
|
|
7635
|
-
205
|
|
7636
|
-
],
|
|
7637
|
-
"mediumorchid": [
|
|
7638
|
-
186,
|
|
7639
|
-
85,
|
|
7640
|
-
211
|
|
7641
|
-
],
|
|
7642
|
-
"mediumpurple": [
|
|
7643
|
-
147,
|
|
7644
|
-
112,
|
|
7645
|
-
219
|
|
7646
|
-
],
|
|
7647
|
-
"mediumseagreen": [
|
|
7648
|
-
60,
|
|
7649
|
-
179,
|
|
7650
|
-
113
|
|
7651
|
-
],
|
|
7652
|
-
"mediumslateblue": [
|
|
7653
|
-
123,
|
|
7654
|
-
104,
|
|
7655
|
-
238
|
|
7656
|
-
],
|
|
7657
|
-
"mediumspringgreen": [
|
|
7658
|
-
0,
|
|
7659
|
-
250,
|
|
7660
|
-
154
|
|
7661
|
-
],
|
|
7662
|
-
"mediumturquoise": [
|
|
7663
|
-
72,
|
|
7664
|
-
209,
|
|
7665
|
-
204
|
|
7666
|
-
],
|
|
7667
|
-
"mediumvioletred": [
|
|
7668
|
-
199,
|
|
7669
|
-
21,
|
|
7670
|
-
133
|
|
7671
|
-
],
|
|
7672
|
-
"midnightblue": [
|
|
7673
|
-
25,
|
|
7674
|
-
25,
|
|
7675
|
-
112
|
|
7676
|
-
],
|
|
7677
|
-
"mintcream": [
|
|
7678
|
-
245,
|
|
7679
|
-
255,
|
|
7680
|
-
250
|
|
7681
|
-
],
|
|
7682
|
-
"mistyrose": [
|
|
7683
|
-
255,
|
|
7684
|
-
228,
|
|
7685
|
-
225
|
|
7686
|
-
],
|
|
7687
|
-
"moccasin": [
|
|
7688
|
-
255,
|
|
7689
|
-
228,
|
|
7690
|
-
181
|
|
7691
|
-
],
|
|
7692
|
-
"navajowhite": [
|
|
7693
|
-
255,
|
|
7694
|
-
222,
|
|
7695
|
-
173
|
|
7696
|
-
],
|
|
7697
|
-
"navy": [
|
|
7698
|
-
0,
|
|
7699
|
-
0,
|
|
7700
|
-
128
|
|
7701
|
-
],
|
|
7702
|
-
"oldlace": [
|
|
7703
|
-
253,
|
|
7704
|
-
245,
|
|
7705
|
-
230
|
|
7706
|
-
],
|
|
7707
|
-
"olive": [
|
|
7708
|
-
128,
|
|
7709
|
-
128,
|
|
7710
|
-
0
|
|
7711
|
-
],
|
|
7712
|
-
"olivedrab": [
|
|
7713
|
-
107,
|
|
7714
|
-
142,
|
|
7715
|
-
35
|
|
7716
|
-
],
|
|
7717
|
-
"orange": [
|
|
7718
|
-
255,
|
|
7719
|
-
165,
|
|
7720
|
-
0
|
|
7721
|
-
],
|
|
7722
|
-
"orangered": [
|
|
7723
|
-
255,
|
|
7724
|
-
69,
|
|
7725
|
-
0
|
|
7726
|
-
],
|
|
7727
|
-
"orchid": [
|
|
7728
|
-
218,
|
|
7729
|
-
112,
|
|
7730
|
-
214
|
|
7731
|
-
],
|
|
7732
|
-
"palegoldenrod": [
|
|
7733
|
-
238,
|
|
7734
|
-
232,
|
|
7735
|
-
170
|
|
7736
|
-
],
|
|
7737
|
-
"palegreen": [
|
|
7738
|
-
152,
|
|
7739
|
-
251,
|
|
7740
|
-
152
|
|
7741
|
-
],
|
|
7742
|
-
"paleturquoise": [
|
|
7743
|
-
175,
|
|
7744
|
-
238,
|
|
7745
|
-
238
|
|
7746
|
-
],
|
|
7747
|
-
"palevioletred": [
|
|
7748
|
-
219,
|
|
7749
|
-
112,
|
|
7750
|
-
147
|
|
7751
|
-
],
|
|
7752
|
-
"papayawhip": [
|
|
7753
|
-
255,
|
|
7754
|
-
239,
|
|
7755
|
-
213
|
|
7756
|
-
],
|
|
7757
|
-
"peachpuff": [
|
|
7758
|
-
255,
|
|
7759
|
-
218,
|
|
7760
|
-
185
|
|
7761
|
-
],
|
|
7762
|
-
"peru": [
|
|
7763
|
-
205,
|
|
7764
|
-
133,
|
|
7765
|
-
63
|
|
7766
|
-
],
|
|
7767
|
-
"pink": [
|
|
7768
|
-
255,
|
|
7769
|
-
192,
|
|
7770
|
-
203
|
|
7771
|
-
],
|
|
7772
|
-
"plum": [
|
|
7773
|
-
221,
|
|
7774
|
-
160,
|
|
7775
|
-
221
|
|
7776
|
-
],
|
|
7777
|
-
"powderblue": [
|
|
7778
|
-
176,
|
|
7779
|
-
224,
|
|
7780
|
-
230
|
|
7781
|
-
],
|
|
7782
|
-
"purple": [
|
|
7783
|
-
128,
|
|
7784
|
-
0,
|
|
7785
|
-
128
|
|
7786
|
-
],
|
|
7787
|
-
"rebeccapurple": [
|
|
7788
|
-
102,
|
|
7789
|
-
51,
|
|
7790
|
-
153
|
|
7791
|
-
],
|
|
7792
|
-
"red": [
|
|
7793
|
-
255,
|
|
7794
|
-
0,
|
|
7795
|
-
0
|
|
7796
|
-
],
|
|
7797
|
-
"rosybrown": [
|
|
7798
|
-
188,
|
|
7799
|
-
143,
|
|
7800
|
-
143
|
|
7801
|
-
],
|
|
7802
|
-
"royalblue": [
|
|
7803
|
-
65,
|
|
7804
|
-
105,
|
|
7805
|
-
225
|
|
7806
|
-
],
|
|
7807
|
-
"saddlebrown": [
|
|
7808
|
-
139,
|
|
7809
|
-
69,
|
|
7810
|
-
19
|
|
7811
|
-
],
|
|
7812
|
-
"salmon": [
|
|
7813
|
-
250,
|
|
7814
|
-
128,
|
|
7815
|
-
114
|
|
7816
|
-
],
|
|
7817
|
-
"sandybrown": [
|
|
7818
|
-
244,
|
|
7819
|
-
164,
|
|
7820
|
-
96
|
|
7821
|
-
],
|
|
7822
|
-
"seagreen": [
|
|
7823
|
-
46,
|
|
7824
|
-
139,
|
|
7825
|
-
87
|
|
7826
|
-
],
|
|
7827
|
-
"seashell": [
|
|
7828
|
-
255,
|
|
7829
|
-
245,
|
|
7830
|
-
238
|
|
7831
|
-
],
|
|
7832
|
-
"sienna": [
|
|
7833
|
-
160,
|
|
7834
|
-
82,
|
|
7835
|
-
45
|
|
7836
|
-
],
|
|
7837
|
-
"silver": [
|
|
7838
|
-
192,
|
|
7839
|
-
192,
|
|
7840
|
-
192
|
|
7841
|
-
],
|
|
7842
|
-
"skyblue": [
|
|
7843
|
-
135,
|
|
7844
|
-
206,
|
|
7845
|
-
235
|
|
7846
|
-
],
|
|
7847
|
-
"slateblue": [
|
|
7848
|
-
106,
|
|
7849
|
-
90,
|
|
7850
|
-
205
|
|
7851
|
-
],
|
|
7852
|
-
"slategray": [
|
|
7853
|
-
112,
|
|
7854
|
-
128,
|
|
7855
|
-
144
|
|
7856
|
-
],
|
|
7857
|
-
"slategrey": [
|
|
7858
|
-
112,
|
|
7859
|
-
128,
|
|
7860
|
-
144
|
|
7861
|
-
],
|
|
7862
|
-
"snow": [
|
|
7863
|
-
255,
|
|
7864
|
-
250,
|
|
7865
|
-
250
|
|
7866
|
-
],
|
|
7867
|
-
"springgreen": [
|
|
7868
|
-
0,
|
|
7869
|
-
255,
|
|
7870
|
-
127
|
|
7871
|
-
],
|
|
7872
|
-
"steelblue": [
|
|
7873
|
-
70,
|
|
7874
|
-
130,
|
|
7875
|
-
180
|
|
7876
|
-
],
|
|
7877
|
-
"tan": [
|
|
7878
|
-
210,
|
|
7879
|
-
180,
|
|
7880
|
-
140
|
|
7881
|
-
],
|
|
7882
|
-
"teal": [
|
|
7883
|
-
0,
|
|
7884
|
-
128,
|
|
7885
|
-
128
|
|
7886
|
-
],
|
|
7887
|
-
"thistle": [
|
|
7888
|
-
216,
|
|
7889
|
-
191,
|
|
7890
|
-
216
|
|
7891
|
-
],
|
|
7892
|
-
"tomato": [
|
|
7893
|
-
255,
|
|
7894
|
-
99,
|
|
7895
|
-
71
|
|
7896
|
-
],
|
|
7897
|
-
"turquoise": [
|
|
7898
|
-
64,
|
|
7899
|
-
224,
|
|
7900
|
-
208
|
|
7901
|
-
],
|
|
7902
|
-
"violet": [
|
|
7903
|
-
238,
|
|
7904
|
-
130,
|
|
7905
|
-
238
|
|
7906
|
-
],
|
|
7907
|
-
"wheat": [
|
|
7908
|
-
245,
|
|
7909
|
-
222,
|
|
7910
|
-
179
|
|
7911
|
-
],
|
|
7912
|
-
"white": [
|
|
7913
|
-
255,
|
|
7914
|
-
255,
|
|
7915
|
-
255
|
|
7916
|
-
],
|
|
7917
|
-
"whitesmoke": [
|
|
7918
|
-
245,
|
|
7919
|
-
245,
|
|
7920
|
-
245
|
|
7921
|
-
],
|
|
7922
|
-
"yellow": [
|
|
7923
|
-
255,
|
|
7924
|
-
255,
|
|
7925
|
-
0
|
|
7926
|
-
],
|
|
7927
|
-
"yellowgreen": [
|
|
7928
|
-
154,
|
|
7929
|
-
205,
|
|
7930
|
-
50
|
|
7931
|
-
]
|
|
7932
|
-
};
|
|
7933
|
-
}));
|
|
7934
|
-
//#endregion
|
|
7935
|
-
//#region node_modules/color-convert/conversions.js
|
|
7936
|
-
var require_conversions = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
7937
|
-
var cssKeywords = require_color_name();
|
|
7938
|
-
var reverseKeywords = {};
|
|
7939
|
-
for (const key of Object.keys(cssKeywords)) reverseKeywords[cssKeywords[key]] = key;
|
|
7940
|
-
var convert = {
|
|
7941
|
-
rgb: {
|
|
7942
|
-
channels: 3,
|
|
7943
|
-
labels: "rgb"
|
|
7944
|
-
},
|
|
7945
|
-
hsl: {
|
|
7946
|
-
channels: 3,
|
|
7947
|
-
labels: "hsl"
|
|
7948
|
-
},
|
|
7949
|
-
hsv: {
|
|
7950
|
-
channels: 3,
|
|
7951
|
-
labels: "hsv"
|
|
7952
|
-
},
|
|
7953
|
-
hwb: {
|
|
7954
|
-
channels: 3,
|
|
7955
|
-
labels: "hwb"
|
|
7956
|
-
},
|
|
7957
|
-
cmyk: {
|
|
7958
|
-
channels: 4,
|
|
7959
|
-
labels: "cmyk"
|
|
7960
|
-
},
|
|
7961
|
-
xyz: {
|
|
7962
|
-
channels: 3,
|
|
7963
|
-
labels: "xyz"
|
|
7964
|
-
},
|
|
7965
|
-
lab: {
|
|
7966
|
-
channels: 3,
|
|
7967
|
-
labels: "lab"
|
|
7968
|
-
},
|
|
7969
|
-
lch: {
|
|
7970
|
-
channels: 3,
|
|
7971
|
-
labels: "lch"
|
|
7972
|
-
},
|
|
7973
|
-
hex: {
|
|
7974
|
-
channels: 1,
|
|
7975
|
-
labels: ["hex"]
|
|
7976
|
-
},
|
|
7977
|
-
keyword: {
|
|
7978
|
-
channels: 1,
|
|
7979
|
-
labels: ["keyword"]
|
|
7980
|
-
},
|
|
7981
|
-
ansi16: {
|
|
7982
|
-
channels: 1,
|
|
7983
|
-
labels: ["ansi16"]
|
|
7984
|
-
},
|
|
7985
|
-
ansi256: {
|
|
7986
|
-
channels: 1,
|
|
7987
|
-
labels: ["ansi256"]
|
|
7988
|
-
},
|
|
7989
|
-
hcg: {
|
|
7990
|
-
channels: 3,
|
|
7991
|
-
labels: [
|
|
7992
|
-
"h",
|
|
7993
|
-
"c",
|
|
7994
|
-
"g"
|
|
7995
|
-
]
|
|
7996
|
-
},
|
|
7997
|
-
apple: {
|
|
7998
|
-
channels: 3,
|
|
7999
|
-
labels: [
|
|
8000
|
-
"r16",
|
|
8001
|
-
"g16",
|
|
8002
|
-
"b16"
|
|
8003
|
-
]
|
|
8004
|
-
},
|
|
8005
|
-
gray: {
|
|
8006
|
-
channels: 1,
|
|
8007
|
-
labels: ["gray"]
|
|
8008
|
-
}
|
|
8009
|
-
};
|
|
8010
|
-
module.exports = convert;
|
|
8011
|
-
for (const model of Object.keys(convert)) {
|
|
8012
|
-
if (!("channels" in convert[model])) throw new Error("missing channels property: " + model);
|
|
8013
|
-
if (!("labels" in convert[model])) throw new Error("missing channel labels property: " + model);
|
|
8014
|
-
if (convert[model].labels.length !== convert[model].channels) throw new Error("channel and label counts mismatch: " + model);
|
|
8015
|
-
const { channels, labels } = convert[model];
|
|
8016
|
-
delete convert[model].channels;
|
|
8017
|
-
delete convert[model].labels;
|
|
8018
|
-
Object.defineProperty(convert[model], "channels", { value: channels });
|
|
8019
|
-
Object.defineProperty(convert[model], "labels", { value: labels });
|
|
8020
|
-
}
|
|
8021
|
-
convert.rgb.hsl = function(rgb) {
|
|
8022
|
-
const r = rgb[0] / 255;
|
|
8023
|
-
const g = rgb[1] / 255;
|
|
8024
|
-
const b = rgb[2] / 255;
|
|
8025
|
-
const min = Math.min(r, g, b);
|
|
8026
|
-
const max = Math.max(r, g, b);
|
|
8027
|
-
const delta = max - min;
|
|
8028
|
-
let h;
|
|
8029
|
-
let s;
|
|
8030
|
-
if (max === min) h = 0;
|
|
8031
|
-
else if (r === max) h = (g - b) / delta;
|
|
8032
|
-
else if (g === max) h = 2 + (b - r) / delta;
|
|
8033
|
-
else if (b === max) h = 4 + (r - g) / delta;
|
|
8034
|
-
h = Math.min(h * 60, 360);
|
|
8035
|
-
if (h < 0) h += 360;
|
|
8036
|
-
const l = (min + max) / 2;
|
|
8037
|
-
if (max === min) s = 0;
|
|
8038
|
-
else if (l <= .5) s = delta / (max + min);
|
|
8039
|
-
else s = delta / (2 - max - min);
|
|
8040
|
-
return [
|
|
8041
|
-
h,
|
|
8042
|
-
s * 100,
|
|
8043
|
-
l * 100
|
|
8044
|
-
];
|
|
8045
|
-
};
|
|
8046
|
-
convert.rgb.hsv = function(rgb) {
|
|
8047
|
-
let rdif;
|
|
8048
|
-
let gdif;
|
|
8049
|
-
let bdif;
|
|
8050
|
-
let h;
|
|
8051
|
-
let s;
|
|
8052
|
-
const r = rgb[0] / 255;
|
|
8053
|
-
const g = rgb[1] / 255;
|
|
8054
|
-
const b = rgb[2] / 255;
|
|
8055
|
-
const v = Math.max(r, g, b);
|
|
8056
|
-
const diff = v - Math.min(r, g, b);
|
|
8057
|
-
const diffc = function(c) {
|
|
8058
|
-
return (v - c) / 6 / diff + 1 / 2;
|
|
8059
|
-
};
|
|
8060
|
-
if (diff === 0) {
|
|
8061
|
-
h = 0;
|
|
8062
|
-
s = 0;
|
|
8063
|
-
} else {
|
|
8064
|
-
s = diff / v;
|
|
8065
|
-
rdif = diffc(r);
|
|
8066
|
-
gdif = diffc(g);
|
|
8067
|
-
bdif = diffc(b);
|
|
8068
|
-
if (r === v) h = bdif - gdif;
|
|
8069
|
-
else if (g === v) h = 1 / 3 + rdif - bdif;
|
|
8070
|
-
else if (b === v) h = 2 / 3 + gdif - rdif;
|
|
8071
|
-
if (h < 0) h += 1;
|
|
8072
|
-
else if (h > 1) h -= 1;
|
|
8073
|
-
}
|
|
8074
|
-
return [
|
|
8075
|
-
h * 360,
|
|
8076
|
-
s * 100,
|
|
8077
|
-
v * 100
|
|
8078
|
-
];
|
|
8079
|
-
};
|
|
8080
|
-
convert.rgb.hwb = function(rgb) {
|
|
8081
|
-
const r = rgb[0];
|
|
8082
|
-
const g = rgb[1];
|
|
8083
|
-
let b = rgb[2];
|
|
8084
|
-
const h = convert.rgb.hsl(rgb)[0];
|
|
8085
|
-
const w = 1 / 255 * Math.min(r, Math.min(g, b));
|
|
8086
|
-
b = 1 - 1 / 255 * Math.max(r, Math.max(g, b));
|
|
8087
|
-
return [
|
|
8088
|
-
h,
|
|
8089
|
-
w * 100,
|
|
8090
|
-
b * 100
|
|
8091
|
-
];
|
|
8092
|
-
};
|
|
8093
|
-
convert.rgb.cmyk = function(rgb) {
|
|
8094
|
-
const r = rgb[0] / 255;
|
|
8095
|
-
const g = rgb[1] / 255;
|
|
8096
|
-
const b = rgb[2] / 255;
|
|
8097
|
-
const k = Math.min(1 - r, 1 - g, 1 - b);
|
|
8098
|
-
const c = (1 - r - k) / (1 - k) || 0;
|
|
8099
|
-
const m = (1 - g - k) / (1 - k) || 0;
|
|
8100
|
-
const y = (1 - b - k) / (1 - k) || 0;
|
|
8101
|
-
return [
|
|
8102
|
-
c * 100,
|
|
8103
|
-
m * 100,
|
|
8104
|
-
y * 100,
|
|
8105
|
-
k * 100
|
|
8106
|
-
];
|
|
8107
|
-
};
|
|
8108
|
-
function comparativeDistance(x, y) {
|
|
8109
|
-
return (x[0] - y[0]) ** 2 + (x[1] - y[1]) ** 2 + (x[2] - y[2]) ** 2;
|
|
8110
|
-
}
|
|
8111
|
-
convert.rgb.keyword = function(rgb) {
|
|
8112
|
-
const reversed = reverseKeywords[rgb];
|
|
8113
|
-
if (reversed) return reversed;
|
|
8114
|
-
let currentClosestDistance = Infinity;
|
|
8115
|
-
let currentClosestKeyword;
|
|
8116
|
-
for (const keyword of Object.keys(cssKeywords)) {
|
|
8117
|
-
const value = cssKeywords[keyword];
|
|
8118
|
-
const distance = comparativeDistance(rgb, value);
|
|
8119
|
-
if (distance < currentClosestDistance) {
|
|
8120
|
-
currentClosestDistance = distance;
|
|
8121
|
-
currentClosestKeyword = keyword;
|
|
8122
|
-
}
|
|
8123
|
-
}
|
|
8124
|
-
return currentClosestKeyword;
|
|
8125
|
-
};
|
|
8126
|
-
convert.keyword.rgb = function(keyword) {
|
|
8127
|
-
return cssKeywords[keyword];
|
|
8128
|
-
};
|
|
8129
|
-
convert.rgb.xyz = function(rgb) {
|
|
8130
|
-
let r = rgb[0] / 255;
|
|
8131
|
-
let g = rgb[1] / 255;
|
|
8132
|
-
let b = rgb[2] / 255;
|
|
8133
|
-
r = r > .04045 ? ((r + .055) / 1.055) ** 2.4 : r / 12.92;
|
|
8134
|
-
g = g > .04045 ? ((g + .055) / 1.055) ** 2.4 : g / 12.92;
|
|
8135
|
-
b = b > .04045 ? ((b + .055) / 1.055) ** 2.4 : b / 12.92;
|
|
8136
|
-
const x = r * .4124 + g * .3576 + b * .1805;
|
|
8137
|
-
const y = r * .2126 + g * .7152 + b * .0722;
|
|
8138
|
-
const z = r * .0193 + g * .1192 + b * .9505;
|
|
8139
|
-
return [
|
|
8140
|
-
x * 100,
|
|
8141
|
-
y * 100,
|
|
8142
|
-
z * 100
|
|
8143
|
-
];
|
|
8144
|
-
};
|
|
8145
|
-
convert.rgb.lab = function(rgb) {
|
|
8146
|
-
const xyz = convert.rgb.xyz(rgb);
|
|
8147
|
-
let x = xyz[0];
|
|
8148
|
-
let y = xyz[1];
|
|
8149
|
-
let z = xyz[2];
|
|
8150
|
-
x /= 95.047;
|
|
8151
|
-
y /= 100;
|
|
8152
|
-
z /= 108.883;
|
|
8153
|
-
x = x > .008856 ? x ** (1 / 3) : 7.787 * x + 16 / 116;
|
|
8154
|
-
y = y > .008856 ? y ** (1 / 3) : 7.787 * y + 16 / 116;
|
|
8155
|
-
z = z > .008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116;
|
|
8156
|
-
return [
|
|
8157
|
-
116 * y - 16,
|
|
8158
|
-
500 * (x - y),
|
|
8159
|
-
200 * (y - z)
|
|
8160
|
-
];
|
|
8161
|
-
};
|
|
8162
|
-
convert.hsl.rgb = function(hsl) {
|
|
8163
|
-
const h = hsl[0] / 360;
|
|
8164
|
-
const s = hsl[1] / 100;
|
|
8165
|
-
const l = hsl[2] / 100;
|
|
8166
|
-
let t2;
|
|
8167
|
-
let t3;
|
|
8168
|
-
let val;
|
|
8169
|
-
if (s === 0) {
|
|
8170
|
-
val = l * 255;
|
|
8171
|
-
return [
|
|
8172
|
-
val,
|
|
8173
|
-
val,
|
|
8174
|
-
val
|
|
8175
|
-
];
|
|
8176
|
-
}
|
|
8177
|
-
if (l < .5) t2 = l * (1 + s);
|
|
8178
|
-
else t2 = l + s - l * s;
|
|
8179
|
-
const t1 = 2 * l - t2;
|
|
8180
|
-
const rgb = [
|
|
8181
|
-
0,
|
|
8182
|
-
0,
|
|
8183
|
-
0
|
|
8184
|
-
];
|
|
8185
|
-
for (let i = 0; i < 3; i++) {
|
|
8186
|
-
t3 = h + 1 / 3 * -(i - 1);
|
|
8187
|
-
if (t3 < 0) t3++;
|
|
8188
|
-
if (t3 > 1) t3--;
|
|
8189
|
-
if (6 * t3 < 1) val = t1 + (t2 - t1) * 6 * t3;
|
|
8190
|
-
else if (2 * t3 < 1) val = t2;
|
|
8191
|
-
else if (3 * t3 < 2) val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;
|
|
8192
|
-
else val = t1;
|
|
8193
|
-
rgb[i] = val * 255;
|
|
8194
|
-
}
|
|
8195
|
-
return rgb;
|
|
8196
|
-
};
|
|
8197
|
-
convert.hsl.hsv = function(hsl) {
|
|
8198
|
-
const h = hsl[0];
|
|
8199
|
-
let s = hsl[1] / 100;
|
|
8200
|
-
let l = hsl[2] / 100;
|
|
8201
|
-
let smin = s;
|
|
8202
|
-
const lmin = Math.max(l, .01);
|
|
8203
|
-
l *= 2;
|
|
8204
|
-
s *= l <= 1 ? l : 2 - l;
|
|
8205
|
-
smin *= lmin <= 1 ? lmin : 2 - lmin;
|
|
8206
|
-
const v = (l + s) / 2;
|
|
8207
|
-
return [
|
|
8208
|
-
h,
|
|
8209
|
-
(l === 0 ? 2 * smin / (lmin + smin) : 2 * s / (l + s)) * 100,
|
|
8210
|
-
v * 100
|
|
8211
|
-
];
|
|
8212
|
-
};
|
|
8213
|
-
convert.hsv.rgb = function(hsv) {
|
|
8214
|
-
const h = hsv[0] / 60;
|
|
8215
|
-
const s = hsv[1] / 100;
|
|
8216
|
-
let v = hsv[2] / 100;
|
|
8217
|
-
const hi = Math.floor(h) % 6;
|
|
8218
|
-
const f = h - Math.floor(h);
|
|
8219
|
-
const p = 255 * v * (1 - s);
|
|
8220
|
-
const q = 255 * v * (1 - s * f);
|
|
8221
|
-
const t = 255 * v * (1 - s * (1 - f));
|
|
8222
|
-
v *= 255;
|
|
8223
|
-
switch (hi) {
|
|
8224
|
-
case 0: return [
|
|
8225
|
-
v,
|
|
8226
|
-
t,
|
|
8227
|
-
p
|
|
8228
|
-
];
|
|
8229
|
-
case 1: return [
|
|
8230
|
-
q,
|
|
8231
|
-
v,
|
|
8232
|
-
p
|
|
8233
|
-
];
|
|
8234
|
-
case 2: return [
|
|
8235
|
-
p,
|
|
8236
|
-
v,
|
|
8237
|
-
t
|
|
8238
|
-
];
|
|
8239
|
-
case 3: return [
|
|
8240
|
-
p,
|
|
8241
|
-
q,
|
|
8242
|
-
v
|
|
8243
|
-
];
|
|
8244
|
-
case 4: return [
|
|
8245
|
-
t,
|
|
8246
|
-
p,
|
|
8247
|
-
v
|
|
8248
|
-
];
|
|
8249
|
-
case 5: return [
|
|
8250
|
-
v,
|
|
8251
|
-
p,
|
|
8252
|
-
q
|
|
8253
|
-
];
|
|
8254
|
-
}
|
|
8255
|
-
};
|
|
8256
|
-
convert.hsv.hsl = function(hsv) {
|
|
8257
|
-
const h = hsv[0];
|
|
8258
|
-
const s = hsv[1] / 100;
|
|
8259
|
-
const v = hsv[2] / 100;
|
|
8260
|
-
const vmin = Math.max(v, .01);
|
|
8261
|
-
let sl;
|
|
8262
|
-
let l;
|
|
8263
|
-
l = (2 - s) * v;
|
|
8264
|
-
const lmin = (2 - s) * vmin;
|
|
8265
|
-
sl = s * vmin;
|
|
8266
|
-
sl /= lmin <= 1 ? lmin : 2 - lmin;
|
|
8267
|
-
sl = sl || 0;
|
|
8268
|
-
l /= 2;
|
|
8269
|
-
return [
|
|
8270
|
-
h,
|
|
8271
|
-
sl * 100,
|
|
8272
|
-
l * 100
|
|
8273
|
-
];
|
|
8274
|
-
};
|
|
8275
|
-
convert.hwb.rgb = function(hwb) {
|
|
8276
|
-
const h = hwb[0] / 360;
|
|
8277
|
-
let wh = hwb[1] / 100;
|
|
8278
|
-
let bl = hwb[2] / 100;
|
|
8279
|
-
const ratio = wh + bl;
|
|
8280
|
-
let f;
|
|
8281
|
-
if (ratio > 1) {
|
|
8282
|
-
wh /= ratio;
|
|
8283
|
-
bl /= ratio;
|
|
8284
|
-
}
|
|
8285
|
-
const i = Math.floor(6 * h);
|
|
8286
|
-
const v = 1 - bl;
|
|
8287
|
-
f = 6 * h - i;
|
|
8288
|
-
if ((i & 1) !== 0) f = 1 - f;
|
|
8289
|
-
const n = wh + f * (v - wh);
|
|
8290
|
-
let r;
|
|
8291
|
-
let g;
|
|
8292
|
-
let b;
|
|
8293
|
-
switch (i) {
|
|
8294
|
-
default:
|
|
8295
|
-
case 6:
|
|
8296
|
-
case 0:
|
|
8297
|
-
r = v;
|
|
8298
|
-
g = n;
|
|
8299
|
-
b = wh;
|
|
8300
|
-
break;
|
|
8301
|
-
case 1:
|
|
8302
|
-
r = n;
|
|
8303
|
-
g = v;
|
|
8304
|
-
b = wh;
|
|
8305
|
-
break;
|
|
8306
|
-
case 2:
|
|
8307
|
-
r = wh;
|
|
8308
|
-
g = v;
|
|
8309
|
-
b = n;
|
|
8310
|
-
break;
|
|
8311
|
-
case 3:
|
|
8312
|
-
r = wh;
|
|
8313
|
-
g = n;
|
|
8314
|
-
b = v;
|
|
8315
|
-
break;
|
|
8316
|
-
case 4:
|
|
8317
|
-
r = n;
|
|
8318
|
-
g = wh;
|
|
8319
|
-
b = v;
|
|
8320
|
-
break;
|
|
8321
|
-
case 5:
|
|
8322
|
-
r = v;
|
|
8323
|
-
g = wh;
|
|
8324
|
-
b = n;
|
|
8325
|
-
break;
|
|
8326
|
-
}
|
|
8327
|
-
return [
|
|
8328
|
-
r * 255,
|
|
8329
|
-
g * 255,
|
|
8330
|
-
b * 255
|
|
8331
|
-
];
|
|
8332
|
-
};
|
|
8333
|
-
convert.cmyk.rgb = function(cmyk) {
|
|
8334
|
-
const c = cmyk[0] / 100;
|
|
8335
|
-
const m = cmyk[1] / 100;
|
|
8336
|
-
const y = cmyk[2] / 100;
|
|
8337
|
-
const k = cmyk[3] / 100;
|
|
8338
|
-
const r = 1 - Math.min(1, c * (1 - k) + k);
|
|
8339
|
-
const g = 1 - Math.min(1, m * (1 - k) + k);
|
|
8340
|
-
const b = 1 - Math.min(1, y * (1 - k) + k);
|
|
8341
|
-
return [
|
|
8342
|
-
r * 255,
|
|
8343
|
-
g * 255,
|
|
8344
|
-
b * 255
|
|
8345
|
-
];
|
|
8346
|
-
};
|
|
8347
|
-
convert.xyz.rgb = function(xyz) {
|
|
8348
|
-
const x = xyz[0] / 100;
|
|
8349
|
-
const y = xyz[1] / 100;
|
|
8350
|
-
const z = xyz[2] / 100;
|
|
8351
|
-
let r;
|
|
8352
|
-
let g;
|
|
8353
|
-
let b;
|
|
8354
|
-
r = x * 3.2406 + y * -1.5372 + z * -.4986;
|
|
8355
|
-
g = x * -.9689 + y * 1.8758 + z * .0415;
|
|
8356
|
-
b = x * .0557 + y * -.204 + z * 1.057;
|
|
8357
|
-
r = r > .0031308 ? 1.055 * r ** (1 / 2.4) - .055 : r * 12.92;
|
|
8358
|
-
g = g > .0031308 ? 1.055 * g ** (1 / 2.4) - .055 : g * 12.92;
|
|
8359
|
-
b = b > .0031308 ? 1.055 * b ** (1 / 2.4) - .055 : b * 12.92;
|
|
8360
|
-
r = Math.min(Math.max(0, r), 1);
|
|
8361
|
-
g = Math.min(Math.max(0, g), 1);
|
|
8362
|
-
b = Math.min(Math.max(0, b), 1);
|
|
8363
|
-
return [
|
|
8364
|
-
r * 255,
|
|
8365
|
-
g * 255,
|
|
8366
|
-
b * 255
|
|
8367
|
-
];
|
|
8368
|
-
};
|
|
8369
|
-
convert.xyz.lab = function(xyz) {
|
|
8370
|
-
let x = xyz[0];
|
|
8371
|
-
let y = xyz[1];
|
|
8372
|
-
let z = xyz[2];
|
|
8373
|
-
x /= 95.047;
|
|
8374
|
-
y /= 100;
|
|
8375
|
-
z /= 108.883;
|
|
8376
|
-
x = x > .008856 ? x ** (1 / 3) : 7.787 * x + 16 / 116;
|
|
8377
|
-
y = y > .008856 ? y ** (1 / 3) : 7.787 * y + 16 / 116;
|
|
8378
|
-
z = z > .008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116;
|
|
8379
|
-
return [
|
|
8380
|
-
116 * y - 16,
|
|
8381
|
-
500 * (x - y),
|
|
8382
|
-
200 * (y - z)
|
|
8383
|
-
];
|
|
8384
|
-
};
|
|
8385
|
-
convert.lab.xyz = function(lab) {
|
|
8386
|
-
const l = lab[0];
|
|
8387
|
-
const a = lab[1];
|
|
8388
|
-
const b = lab[2];
|
|
8389
|
-
let x;
|
|
8390
|
-
let y;
|
|
8391
|
-
let z;
|
|
8392
|
-
y = (l + 16) / 116;
|
|
8393
|
-
x = a / 500 + y;
|
|
8394
|
-
z = y - b / 200;
|
|
8395
|
-
const y2 = y ** 3;
|
|
8396
|
-
const x2 = x ** 3;
|
|
8397
|
-
const z2 = z ** 3;
|
|
8398
|
-
y = y2 > .008856 ? y2 : (y - 16 / 116) / 7.787;
|
|
8399
|
-
x = x2 > .008856 ? x2 : (x - 16 / 116) / 7.787;
|
|
8400
|
-
z = z2 > .008856 ? z2 : (z - 16 / 116) / 7.787;
|
|
8401
|
-
x *= 95.047;
|
|
8402
|
-
y *= 100;
|
|
8403
|
-
z *= 108.883;
|
|
8404
|
-
return [
|
|
8405
|
-
x,
|
|
8406
|
-
y,
|
|
8407
|
-
z
|
|
8408
|
-
];
|
|
8409
|
-
};
|
|
8410
|
-
convert.lab.lch = function(lab) {
|
|
8411
|
-
const l = lab[0];
|
|
8412
|
-
const a = lab[1];
|
|
8413
|
-
const b = lab[2];
|
|
8414
|
-
let h;
|
|
8415
|
-
h = Math.atan2(b, a) * 360 / 2 / Math.PI;
|
|
8416
|
-
if (h < 0) h += 360;
|
|
8417
|
-
return [
|
|
8418
|
-
l,
|
|
8419
|
-
Math.sqrt(a * a + b * b),
|
|
8420
|
-
h
|
|
8421
|
-
];
|
|
8422
|
-
};
|
|
8423
|
-
convert.lch.lab = function(lch) {
|
|
8424
|
-
const l = lch[0];
|
|
8425
|
-
const c = lch[1];
|
|
8426
|
-
const hr = lch[2] / 360 * 2 * Math.PI;
|
|
8427
|
-
return [
|
|
8428
|
-
l,
|
|
8429
|
-
c * Math.cos(hr),
|
|
8430
|
-
c * Math.sin(hr)
|
|
8431
|
-
];
|
|
8432
|
-
};
|
|
8433
|
-
convert.rgb.ansi16 = function(args, saturation = null) {
|
|
8434
|
-
const [r, g, b] = args;
|
|
8435
|
-
let value = saturation === null ? convert.rgb.hsv(args)[2] : saturation;
|
|
8436
|
-
value = Math.round(value / 50);
|
|
8437
|
-
if (value === 0) return 30;
|
|
8438
|
-
let ansi = 30 + (Math.round(b / 255) << 2 | Math.round(g / 255) << 1 | Math.round(r / 255));
|
|
8439
|
-
if (value === 2) ansi += 60;
|
|
8440
|
-
return ansi;
|
|
8441
|
-
};
|
|
8442
|
-
convert.hsv.ansi16 = function(args) {
|
|
8443
|
-
return convert.rgb.ansi16(convert.hsv.rgb(args), args[2]);
|
|
8444
|
-
};
|
|
8445
|
-
convert.rgb.ansi256 = function(args) {
|
|
8446
|
-
const r = args[0];
|
|
8447
|
-
const g = args[1];
|
|
8448
|
-
const b = args[2];
|
|
8449
|
-
if (r === g && g === b) {
|
|
8450
|
-
if (r < 8) return 16;
|
|
8451
|
-
if (r > 248) return 231;
|
|
8452
|
-
return Math.round((r - 8) / 247 * 24) + 232;
|
|
8453
|
-
}
|
|
8454
|
-
return 16 + 36 * Math.round(r / 255 * 5) + 6 * Math.round(g / 255 * 5) + Math.round(b / 255 * 5);
|
|
8455
|
-
};
|
|
8456
|
-
convert.ansi16.rgb = function(args) {
|
|
8457
|
-
let color = args % 10;
|
|
8458
|
-
if (color === 0 || color === 7) {
|
|
8459
|
-
if (args > 50) color += 3.5;
|
|
8460
|
-
color = color / 10.5 * 255;
|
|
8461
|
-
return [
|
|
8462
|
-
color,
|
|
8463
|
-
color,
|
|
8464
|
-
color
|
|
8465
|
-
];
|
|
8466
|
-
}
|
|
8467
|
-
const mult = (~~(args > 50) + 1) * .5;
|
|
8468
|
-
return [
|
|
8469
|
-
(color & 1) * mult * 255,
|
|
8470
|
-
(color >> 1 & 1) * mult * 255,
|
|
8471
|
-
(color >> 2 & 1) * mult * 255
|
|
8472
|
-
];
|
|
8473
|
-
};
|
|
8474
|
-
convert.ansi256.rgb = function(args) {
|
|
8475
|
-
if (args >= 232) {
|
|
8476
|
-
const c = (args - 232) * 10 + 8;
|
|
8477
|
-
return [
|
|
8478
|
-
c,
|
|
8479
|
-
c,
|
|
8480
|
-
c
|
|
8481
|
-
];
|
|
8482
|
-
}
|
|
8483
|
-
args -= 16;
|
|
8484
|
-
let rem;
|
|
8485
|
-
return [
|
|
8486
|
-
Math.floor(args / 36) / 5 * 255,
|
|
8487
|
-
Math.floor((rem = args % 36) / 6) / 5 * 255,
|
|
8488
|
-
rem % 6 / 5 * 255
|
|
8489
|
-
];
|
|
8490
|
-
};
|
|
8491
|
-
convert.rgb.hex = function(args) {
|
|
8492
|
-
const string = (((Math.round(args[0]) & 255) << 16) + ((Math.round(args[1]) & 255) << 8) + (Math.round(args[2]) & 255)).toString(16).toUpperCase();
|
|
8493
|
-
return "000000".substring(string.length) + string;
|
|
8494
|
-
};
|
|
8495
|
-
convert.hex.rgb = function(args) {
|
|
8496
|
-
const match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);
|
|
8497
|
-
if (!match) return [
|
|
8498
|
-
0,
|
|
8499
|
-
0,
|
|
8500
|
-
0
|
|
8501
|
-
];
|
|
8502
|
-
let colorString = match[0];
|
|
8503
|
-
if (match[0].length === 3) colorString = colorString.split("").map((char) => {
|
|
8504
|
-
return char + char;
|
|
8505
|
-
}).join("");
|
|
8506
|
-
const integer = parseInt(colorString, 16);
|
|
8507
|
-
return [
|
|
8508
|
-
integer >> 16 & 255,
|
|
8509
|
-
integer >> 8 & 255,
|
|
8510
|
-
integer & 255
|
|
8511
|
-
];
|
|
8512
|
-
};
|
|
8513
|
-
convert.rgb.hcg = function(rgb) {
|
|
8514
|
-
const r = rgb[0] / 255;
|
|
8515
|
-
const g = rgb[1] / 255;
|
|
8516
|
-
const b = rgb[2] / 255;
|
|
8517
|
-
const max = Math.max(Math.max(r, g), b);
|
|
8518
|
-
const min = Math.min(Math.min(r, g), b);
|
|
8519
|
-
const chroma = max - min;
|
|
8520
|
-
let grayscale;
|
|
8521
|
-
let hue;
|
|
8522
|
-
if (chroma < 1) grayscale = min / (1 - chroma);
|
|
8523
|
-
else grayscale = 0;
|
|
8524
|
-
if (chroma <= 0) hue = 0;
|
|
8525
|
-
else if (max === r) hue = (g - b) / chroma % 6;
|
|
8526
|
-
else if (max === g) hue = 2 + (b - r) / chroma;
|
|
8527
|
-
else hue = 4 + (r - g) / chroma;
|
|
8528
|
-
hue /= 6;
|
|
8529
|
-
hue %= 1;
|
|
8530
|
-
return [
|
|
8531
|
-
hue * 360,
|
|
8532
|
-
chroma * 100,
|
|
8533
|
-
grayscale * 100
|
|
8534
|
-
];
|
|
8535
|
-
};
|
|
8536
|
-
convert.hsl.hcg = function(hsl) {
|
|
8537
|
-
const s = hsl[1] / 100;
|
|
8538
|
-
const l = hsl[2] / 100;
|
|
8539
|
-
const c = l < .5 ? 2 * s * l : 2 * s * (1 - l);
|
|
8540
|
-
let f = 0;
|
|
8541
|
-
if (c < 1) f = (l - .5 * c) / (1 - c);
|
|
8542
|
-
return [
|
|
8543
|
-
hsl[0],
|
|
8544
|
-
c * 100,
|
|
8545
|
-
f * 100
|
|
8546
|
-
];
|
|
8547
|
-
};
|
|
8548
|
-
convert.hsv.hcg = function(hsv) {
|
|
8549
|
-
const s = hsv[1] / 100;
|
|
8550
|
-
const v = hsv[2] / 100;
|
|
8551
|
-
const c = s * v;
|
|
8552
|
-
let f = 0;
|
|
8553
|
-
if (c < 1) f = (v - c) / (1 - c);
|
|
8554
|
-
return [
|
|
8555
|
-
hsv[0],
|
|
8556
|
-
c * 100,
|
|
8557
|
-
f * 100
|
|
8558
|
-
];
|
|
8559
|
-
};
|
|
8560
|
-
convert.hcg.rgb = function(hcg) {
|
|
8561
|
-
const h = hcg[0] / 360;
|
|
8562
|
-
const c = hcg[1] / 100;
|
|
8563
|
-
const g = hcg[2] / 100;
|
|
8564
|
-
if (c === 0) return [
|
|
8565
|
-
g * 255,
|
|
8566
|
-
g * 255,
|
|
8567
|
-
g * 255
|
|
8568
|
-
];
|
|
8569
|
-
const pure = [
|
|
8570
|
-
0,
|
|
8571
|
-
0,
|
|
8572
|
-
0
|
|
8573
|
-
];
|
|
8574
|
-
const hi = h % 1 * 6;
|
|
8575
|
-
const v = hi % 1;
|
|
8576
|
-
const w = 1 - v;
|
|
8577
|
-
let mg = 0;
|
|
8578
|
-
switch (Math.floor(hi)) {
|
|
8579
|
-
case 0:
|
|
8580
|
-
pure[0] = 1;
|
|
8581
|
-
pure[1] = v;
|
|
8582
|
-
pure[2] = 0;
|
|
8583
|
-
break;
|
|
8584
|
-
case 1:
|
|
8585
|
-
pure[0] = w;
|
|
8586
|
-
pure[1] = 1;
|
|
8587
|
-
pure[2] = 0;
|
|
8588
|
-
break;
|
|
8589
|
-
case 2:
|
|
8590
|
-
pure[0] = 0;
|
|
8591
|
-
pure[1] = 1;
|
|
8592
|
-
pure[2] = v;
|
|
8593
|
-
break;
|
|
8594
|
-
case 3:
|
|
8595
|
-
pure[0] = 0;
|
|
8596
|
-
pure[1] = w;
|
|
8597
|
-
pure[2] = 1;
|
|
8598
|
-
break;
|
|
8599
|
-
case 4:
|
|
8600
|
-
pure[0] = v;
|
|
8601
|
-
pure[1] = 0;
|
|
8602
|
-
pure[2] = 1;
|
|
8603
|
-
break;
|
|
8604
|
-
default:
|
|
8605
|
-
pure[0] = 1;
|
|
8606
|
-
pure[1] = 0;
|
|
8607
|
-
pure[2] = w;
|
|
8608
|
-
}
|
|
8609
|
-
mg = (1 - c) * g;
|
|
8610
|
-
return [
|
|
8611
|
-
(c * pure[0] + mg) * 255,
|
|
8612
|
-
(c * pure[1] + mg) * 255,
|
|
8613
|
-
(c * pure[2] + mg) * 255
|
|
8614
|
-
];
|
|
8615
|
-
};
|
|
8616
|
-
convert.hcg.hsv = function(hcg) {
|
|
8617
|
-
const c = hcg[1] / 100;
|
|
8618
|
-
const v = c + hcg[2] / 100 * (1 - c);
|
|
8619
|
-
let f = 0;
|
|
8620
|
-
if (v > 0) f = c / v;
|
|
8621
|
-
return [
|
|
8622
|
-
hcg[0],
|
|
8623
|
-
f * 100,
|
|
8624
|
-
v * 100
|
|
8625
|
-
];
|
|
8626
|
-
};
|
|
8627
|
-
convert.hcg.hsl = function(hcg) {
|
|
8628
|
-
const c = hcg[1] / 100;
|
|
8629
|
-
const l = hcg[2] / 100 * (1 - c) + .5 * c;
|
|
8630
|
-
let s = 0;
|
|
8631
|
-
if (l > 0 && l < .5) s = c / (2 * l);
|
|
8632
|
-
else if (l >= .5 && l < 1) s = c / (2 * (1 - l));
|
|
8633
|
-
return [
|
|
8634
|
-
hcg[0],
|
|
8635
|
-
s * 100,
|
|
8636
|
-
l * 100
|
|
8637
|
-
];
|
|
8638
|
-
};
|
|
8639
|
-
convert.hcg.hwb = function(hcg) {
|
|
8640
|
-
const c = hcg[1] / 100;
|
|
8641
|
-
const v = c + hcg[2] / 100 * (1 - c);
|
|
8642
|
-
return [
|
|
8643
|
-
hcg[0],
|
|
8644
|
-
(v - c) * 100,
|
|
8645
|
-
(1 - v) * 100
|
|
8646
|
-
];
|
|
8647
|
-
};
|
|
8648
|
-
convert.hwb.hcg = function(hwb) {
|
|
8649
|
-
const w = hwb[1] / 100;
|
|
8650
|
-
const v = 1 - hwb[2] / 100;
|
|
8651
|
-
const c = v - w;
|
|
8652
|
-
let g = 0;
|
|
8653
|
-
if (c < 1) g = (v - c) / (1 - c);
|
|
8654
|
-
return [
|
|
8655
|
-
hwb[0],
|
|
8656
|
-
c * 100,
|
|
8657
|
-
g * 100
|
|
8658
|
-
];
|
|
8659
|
-
};
|
|
8660
|
-
convert.apple.rgb = function(apple) {
|
|
8661
|
-
return [
|
|
8662
|
-
apple[0] / 65535 * 255,
|
|
8663
|
-
apple[1] / 65535 * 255,
|
|
8664
|
-
apple[2] / 65535 * 255
|
|
8665
|
-
];
|
|
8666
|
-
};
|
|
8667
|
-
convert.rgb.apple = function(rgb) {
|
|
8668
|
-
return [
|
|
8669
|
-
rgb[0] / 255 * 65535,
|
|
8670
|
-
rgb[1] / 255 * 65535,
|
|
8671
|
-
rgb[2] / 255 * 65535
|
|
8672
|
-
];
|
|
8673
|
-
};
|
|
8674
|
-
convert.gray.rgb = function(args) {
|
|
8675
|
-
return [
|
|
8676
|
-
args[0] / 100 * 255,
|
|
8677
|
-
args[0] / 100 * 255,
|
|
8678
|
-
args[0] / 100 * 255
|
|
8679
|
-
];
|
|
8680
|
-
};
|
|
8681
|
-
convert.gray.hsl = function(args) {
|
|
8682
|
-
return [
|
|
8683
|
-
0,
|
|
8684
|
-
0,
|
|
8685
|
-
args[0]
|
|
8686
|
-
];
|
|
8687
|
-
};
|
|
8688
|
-
convert.gray.hsv = convert.gray.hsl;
|
|
8689
|
-
convert.gray.hwb = function(gray) {
|
|
8690
|
-
return [
|
|
8691
|
-
0,
|
|
8692
|
-
100,
|
|
8693
|
-
gray[0]
|
|
8694
|
-
];
|
|
8695
|
-
};
|
|
8696
|
-
convert.gray.cmyk = function(gray) {
|
|
8697
|
-
return [
|
|
8698
|
-
0,
|
|
8699
|
-
0,
|
|
8700
|
-
0,
|
|
8701
|
-
gray[0]
|
|
8702
|
-
];
|
|
8703
|
-
};
|
|
8704
|
-
convert.gray.lab = function(gray) {
|
|
8705
|
-
return [
|
|
8706
|
-
gray[0],
|
|
8707
|
-
0,
|
|
8708
|
-
0
|
|
8709
|
-
];
|
|
8710
|
-
};
|
|
8711
|
-
convert.gray.hex = function(gray) {
|
|
8712
|
-
const val = Math.round(gray[0] / 100 * 255) & 255;
|
|
8713
|
-
const string = ((val << 16) + (val << 8) + val).toString(16).toUpperCase();
|
|
8714
|
-
return "000000".substring(string.length) + string;
|
|
8715
|
-
};
|
|
8716
|
-
convert.rgb.gray = function(rgb) {
|
|
8717
|
-
return [(rgb[0] + rgb[1] + rgb[2]) / 3 / 255 * 100];
|
|
8718
|
-
};
|
|
8719
|
-
}));
|
|
8720
|
-
//#endregion
|
|
8721
|
-
//#region node_modules/color-convert/route.js
|
|
8722
|
-
var require_route = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
8723
|
-
var conversions = require_conversions();
|
|
8724
|
-
function buildGraph() {
|
|
8725
|
-
const graph = {};
|
|
8726
|
-
const models = Object.keys(conversions);
|
|
8727
|
-
for (let len = models.length, i = 0; i < len; i++) graph[models[i]] = {
|
|
8728
|
-
distance: -1,
|
|
8729
|
-
parent: null
|
|
8730
|
-
};
|
|
8731
|
-
return graph;
|
|
8732
|
-
}
|
|
8733
|
-
function deriveBFS(fromModel) {
|
|
8734
|
-
const graph = buildGraph();
|
|
8735
|
-
const queue = [fromModel];
|
|
8736
|
-
graph[fromModel].distance = 0;
|
|
8737
|
-
while (queue.length) {
|
|
8738
|
-
const current = queue.pop();
|
|
8739
|
-
const adjacents = Object.keys(conversions[current]);
|
|
8740
|
-
for (let len = adjacents.length, i = 0; i < len; i++) {
|
|
8741
|
-
const adjacent = adjacents[i];
|
|
8742
|
-
const node = graph[adjacent];
|
|
8743
|
-
if (node.distance === -1) {
|
|
8744
|
-
node.distance = graph[current].distance + 1;
|
|
8745
|
-
node.parent = current;
|
|
8746
|
-
queue.unshift(adjacent);
|
|
8747
|
-
}
|
|
8748
|
-
}
|
|
8749
|
-
}
|
|
8750
|
-
return graph;
|
|
8751
|
-
}
|
|
8752
|
-
function link(from, to) {
|
|
8753
|
-
return function(args) {
|
|
8754
|
-
return to(from(args));
|
|
8755
|
-
};
|
|
7189
|
+
//#region node_modules/chalk/source/vendor/ansi-styles/index.js
|
|
7190
|
+
var ANSI_BACKGROUND_OFFSET = 10;
|
|
7191
|
+
var wrapAnsi16 = (offset = 0) => (code) => `\u001B[${code + offset}m`;
|
|
7192
|
+
var wrapAnsi256 = (offset = 0) => (code) => `\u001B[${38 + offset};5;${code}m`;
|
|
7193
|
+
var wrapAnsi16m = (offset = 0) => (red, green, blue) => `\u001B[${38 + offset};2;${red};${green};${blue}m`;
|
|
7194
|
+
var styles$1 = {
|
|
7195
|
+
modifier: {
|
|
7196
|
+
reset: [0, 0],
|
|
7197
|
+
bold: [1, 22],
|
|
7198
|
+
dim: [2, 22],
|
|
7199
|
+
italic: [3, 23],
|
|
7200
|
+
underline: [4, 24],
|
|
7201
|
+
overline: [53, 55],
|
|
7202
|
+
inverse: [7, 27],
|
|
7203
|
+
hidden: [8, 28],
|
|
7204
|
+
strikethrough: [9, 29]
|
|
7205
|
+
},
|
|
7206
|
+
color: {
|
|
7207
|
+
black: [30, 39],
|
|
7208
|
+
red: [31, 39],
|
|
7209
|
+
green: [32, 39],
|
|
7210
|
+
yellow: [33, 39],
|
|
7211
|
+
blue: [34, 39],
|
|
7212
|
+
magenta: [35, 39],
|
|
7213
|
+
cyan: [36, 39],
|
|
7214
|
+
white: [37, 39],
|
|
7215
|
+
blackBright: [90, 39],
|
|
7216
|
+
gray: [90, 39],
|
|
7217
|
+
grey: [90, 39],
|
|
7218
|
+
redBright: [91, 39],
|
|
7219
|
+
greenBright: [92, 39],
|
|
7220
|
+
yellowBright: [93, 39],
|
|
7221
|
+
blueBright: [94, 39],
|
|
7222
|
+
magentaBright: [95, 39],
|
|
7223
|
+
cyanBright: [96, 39],
|
|
7224
|
+
whiteBright: [97, 39]
|
|
7225
|
+
},
|
|
7226
|
+
bgColor: {
|
|
7227
|
+
bgBlack: [40, 49],
|
|
7228
|
+
bgRed: [41, 49],
|
|
7229
|
+
bgGreen: [42, 49],
|
|
7230
|
+
bgYellow: [43, 49],
|
|
7231
|
+
bgBlue: [44, 49],
|
|
7232
|
+
bgMagenta: [45, 49],
|
|
7233
|
+
bgCyan: [46, 49],
|
|
7234
|
+
bgWhite: [47, 49],
|
|
7235
|
+
bgBlackBright: [100, 49],
|
|
7236
|
+
bgGray: [100, 49],
|
|
7237
|
+
bgGrey: [100, 49],
|
|
7238
|
+
bgRedBright: [101, 49],
|
|
7239
|
+
bgGreenBright: [102, 49],
|
|
7240
|
+
bgYellowBright: [103, 49],
|
|
7241
|
+
bgBlueBright: [104, 49],
|
|
7242
|
+
bgMagentaBright: [105, 49],
|
|
7243
|
+
bgCyanBright: [106, 49],
|
|
7244
|
+
bgWhiteBright: [107, 49]
|
|
8756
7245
|
}
|
|
8757
|
-
|
|
8758
|
-
|
|
8759
|
-
|
|
8760
|
-
|
|
8761
|
-
|
|
8762
|
-
|
|
8763
|
-
|
|
8764
|
-
|
|
8765
|
-
|
|
8766
|
-
|
|
8767
|
-
|
|
8768
|
-
|
|
8769
|
-
|
|
8770
|
-
|
|
8771
|
-
|
|
8772
|
-
|
|
8773
|
-
|
|
8774
|
-
|
|
8775
|
-
|
|
8776
|
-
conversion[toModel] = wrapConversion(toModel, graph);
|
|
8777
|
-
}
|
|
8778
|
-
return conversion;
|
|
8779
|
-
};
|
|
8780
|
-
}));
|
|
8781
|
-
//#endregion
|
|
8782
|
-
//#region node_modules/color-convert/index.js
|
|
8783
|
-
var require_color_convert = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
8784
|
-
var conversions = require_conversions();
|
|
8785
|
-
var route = require_route();
|
|
8786
|
-
var convert = {};
|
|
8787
|
-
var models = Object.keys(conversions);
|
|
8788
|
-
function wrapRaw(fn) {
|
|
8789
|
-
const wrappedFn = function(...args) {
|
|
8790
|
-
const arg0 = args[0];
|
|
8791
|
-
if (arg0 === void 0 || arg0 === null) return arg0;
|
|
8792
|
-
if (arg0.length > 1) args = arg0;
|
|
8793
|
-
return fn(args);
|
|
8794
|
-
};
|
|
8795
|
-
if ("conversion" in fn) wrappedFn.conversion = fn.conversion;
|
|
8796
|
-
return wrappedFn;
|
|
8797
|
-
}
|
|
8798
|
-
function wrapRounded(fn) {
|
|
8799
|
-
const wrappedFn = function(...args) {
|
|
8800
|
-
const arg0 = args[0];
|
|
8801
|
-
if (arg0 === void 0 || arg0 === null) return arg0;
|
|
8802
|
-
if (arg0.length > 1) args = arg0;
|
|
8803
|
-
const result = fn(args);
|
|
8804
|
-
if (typeof result === "object") for (let len = result.length, i = 0; i < len; i++) result[i] = Math.round(result[i]);
|
|
8805
|
-
return result;
|
|
8806
|
-
};
|
|
8807
|
-
if ("conversion" in fn) wrappedFn.conversion = fn.conversion;
|
|
8808
|
-
return wrappedFn;
|
|
8809
|
-
}
|
|
8810
|
-
models.forEach((fromModel) => {
|
|
8811
|
-
convert[fromModel] = {};
|
|
8812
|
-
Object.defineProperty(convert[fromModel], "channels", { value: conversions[fromModel].channels });
|
|
8813
|
-
Object.defineProperty(convert[fromModel], "labels", { value: conversions[fromModel].labels });
|
|
8814
|
-
const routes = route(fromModel);
|
|
8815
|
-
Object.keys(routes).forEach((toModel) => {
|
|
8816
|
-
const fn = routes[toModel];
|
|
8817
|
-
convert[fromModel][toModel] = wrapRounded(fn);
|
|
8818
|
-
convert[fromModel][toModel].raw = wrapRaw(fn);
|
|
7246
|
+
};
|
|
7247
|
+
Object.keys(styles$1.modifier);
|
|
7248
|
+
var foregroundColorNames = Object.keys(styles$1.color);
|
|
7249
|
+
var backgroundColorNames = Object.keys(styles$1.bgColor);
|
|
7250
|
+
[...foregroundColorNames, ...backgroundColorNames];
|
|
7251
|
+
function assembleStyles() {
|
|
7252
|
+
const codes = /* @__PURE__ */ new Map();
|
|
7253
|
+
for (const [groupName, group] of Object.entries(styles$1)) {
|
|
7254
|
+
for (const [styleName, style] of Object.entries(group)) {
|
|
7255
|
+
styles$1[styleName] = {
|
|
7256
|
+
open: `\u001B[${style[0]}m`,
|
|
7257
|
+
close: `\u001B[${style[1]}m`
|
|
7258
|
+
};
|
|
7259
|
+
group[styleName] = styles$1[styleName];
|
|
7260
|
+
codes.set(style[0], style[1]);
|
|
7261
|
+
}
|
|
7262
|
+
Object.defineProperty(styles$1, groupName, {
|
|
7263
|
+
value: group,
|
|
7264
|
+
enumerable: false
|
|
8819
7265
|
});
|
|
7266
|
+
}
|
|
7267
|
+
Object.defineProperty(styles$1, "codes", {
|
|
7268
|
+
value: codes,
|
|
7269
|
+
enumerable: false
|
|
8820
7270
|
});
|
|
8821
|
-
|
|
8822
|
-
|
|
8823
|
-
|
|
8824
|
-
|
|
8825
|
-
|
|
8826
|
-
|
|
8827
|
-
|
|
8828
|
-
|
|
8829
|
-
|
|
8830
|
-
|
|
8831
|
-
|
|
8832
|
-
|
|
8833
|
-
|
|
8834
|
-
|
|
8835
|
-
|
|
8836
|
-
|
|
8837
|
-
|
|
8838
|
-
var rgb2rgb = (r, g, b) => [
|
|
8839
|
-
r,
|
|
8840
|
-
g,
|
|
8841
|
-
b
|
|
8842
|
-
];
|
|
8843
|
-
var setLazyProperty = (object, property, get) => {
|
|
8844
|
-
Object.defineProperty(object, property, {
|
|
8845
|
-
get: () => {
|
|
8846
|
-
const value = get();
|
|
8847
|
-
Object.defineProperty(object, property, {
|
|
8848
|
-
value,
|
|
8849
|
-
enumerable: true,
|
|
8850
|
-
configurable: true
|
|
8851
|
-
});
|
|
8852
|
-
return value;
|
|
7271
|
+
styles$1.color.close = "\x1B[39m";
|
|
7272
|
+
styles$1.bgColor.close = "\x1B[49m";
|
|
7273
|
+
styles$1.color.ansi = wrapAnsi16();
|
|
7274
|
+
styles$1.color.ansi256 = wrapAnsi256();
|
|
7275
|
+
styles$1.color.ansi16m = wrapAnsi16m();
|
|
7276
|
+
styles$1.bgColor.ansi = wrapAnsi16(ANSI_BACKGROUND_OFFSET);
|
|
7277
|
+
styles$1.bgColor.ansi256 = wrapAnsi256(ANSI_BACKGROUND_OFFSET);
|
|
7278
|
+
styles$1.bgColor.ansi16m = wrapAnsi16m(ANSI_BACKGROUND_OFFSET);
|
|
7279
|
+
Object.defineProperties(styles$1, {
|
|
7280
|
+
rgbToAnsi256: {
|
|
7281
|
+
value(red, green, blue) {
|
|
7282
|
+
if (red === green && green === blue) {
|
|
7283
|
+
if (red < 8) return 16;
|
|
7284
|
+
if (red > 248) return 231;
|
|
7285
|
+
return Math.round((red - 8) / 247 * 24) + 232;
|
|
7286
|
+
}
|
|
7287
|
+
return 16 + 36 * Math.round(red / 255 * 5) + 6 * Math.round(green / 255 * 5) + Math.round(blue / 255 * 5);
|
|
8853
7288
|
},
|
|
8854
|
-
enumerable:
|
|
8855
|
-
|
|
8856
|
-
|
|
8857
|
-
|
|
8858
|
-
|
|
8859
|
-
|
|
8860
|
-
|
|
8861
|
-
|
|
8862
|
-
|
|
8863
|
-
|
|
8864
|
-
|
|
8865
|
-
|
|
8866
|
-
|
|
8867
|
-
|
|
8868
|
-
|
|
8869
|
-
|
|
8870
|
-
|
|
8871
|
-
|
|
8872
|
-
const codes = /* @__PURE__ */ new Map();
|
|
8873
|
-
const styles = {
|
|
8874
|
-
modifier: {
|
|
8875
|
-
reset: [0, 0],
|
|
8876
|
-
bold: [1, 22],
|
|
8877
|
-
dim: [2, 22],
|
|
8878
|
-
italic: [3, 23],
|
|
8879
|
-
underline: [4, 24],
|
|
8880
|
-
inverse: [7, 27],
|
|
8881
|
-
hidden: [8, 28],
|
|
8882
|
-
strikethrough: [9, 29]
|
|
7289
|
+
enumerable: false
|
|
7290
|
+
},
|
|
7291
|
+
hexToRgb: {
|
|
7292
|
+
value(hex) {
|
|
7293
|
+
const matches = /[a-f\d]{6}|[a-f\d]{3}/i.exec(hex.toString(16));
|
|
7294
|
+
if (!matches) return [
|
|
7295
|
+
0,
|
|
7296
|
+
0,
|
|
7297
|
+
0
|
|
7298
|
+
];
|
|
7299
|
+
let [colorString] = matches;
|
|
7300
|
+
if (colorString.length === 3) colorString = [...colorString].map((character) => character + character).join("");
|
|
7301
|
+
const integer = Number.parseInt(colorString, 16);
|
|
7302
|
+
return [
|
|
7303
|
+
integer >> 16 & 255,
|
|
7304
|
+
integer >> 8 & 255,
|
|
7305
|
+
integer & 255
|
|
7306
|
+
];
|
|
8883
7307
|
},
|
|
8884
|
-
|
|
8885
|
-
|
|
8886
|
-
|
|
8887
|
-
|
|
8888
|
-
|
|
8889
|
-
|
|
8890
|
-
|
|
8891
|
-
|
|
8892
|
-
|
|
8893
|
-
|
|
8894
|
-
|
|
8895
|
-
|
|
8896
|
-
|
|
8897
|
-
|
|
8898
|
-
|
|
8899
|
-
|
|
8900
|
-
|
|
7308
|
+
enumerable: false
|
|
7309
|
+
},
|
|
7310
|
+
hexToAnsi256: {
|
|
7311
|
+
value: (hex) => styles$1.rgbToAnsi256(...styles$1.hexToRgb(hex)),
|
|
7312
|
+
enumerable: false
|
|
7313
|
+
},
|
|
7314
|
+
ansi256ToAnsi: {
|
|
7315
|
+
value(code) {
|
|
7316
|
+
if (code < 8) return 30 + code;
|
|
7317
|
+
if (code < 16) return 90 + (code - 8);
|
|
7318
|
+
let red;
|
|
7319
|
+
let green;
|
|
7320
|
+
let blue;
|
|
7321
|
+
if (code >= 232) {
|
|
7322
|
+
red = ((code - 232) * 10 + 8) / 255;
|
|
7323
|
+
green = red;
|
|
7324
|
+
blue = red;
|
|
7325
|
+
} else {
|
|
7326
|
+
code -= 16;
|
|
7327
|
+
const remainder = code % 36;
|
|
7328
|
+
red = Math.floor(code / 36) / 5;
|
|
7329
|
+
green = Math.floor(remainder / 6) / 5;
|
|
7330
|
+
blue = remainder % 6 / 5;
|
|
7331
|
+
}
|
|
7332
|
+
const value = Math.max(red, green, blue) * 2;
|
|
7333
|
+
if (value === 0) return 30;
|
|
7334
|
+
let result = 30 + (Math.round(blue) << 2 | Math.round(green) << 1 | Math.round(red));
|
|
7335
|
+
if (value === 2) result += 60;
|
|
7336
|
+
return result;
|
|
8901
7337
|
},
|
|
8902
|
-
bgColor: {
|
|
8903
|
-
bgBlack: [40, 49],
|
|
8904
|
-
bgRed: [41, 49],
|
|
8905
|
-
bgGreen: [42, 49],
|
|
8906
|
-
bgYellow: [43, 49],
|
|
8907
|
-
bgBlue: [44, 49],
|
|
8908
|
-
bgMagenta: [45, 49],
|
|
8909
|
-
bgCyan: [46, 49],
|
|
8910
|
-
bgWhite: [47, 49],
|
|
8911
|
-
bgBlackBright: [100, 49],
|
|
8912
|
-
bgRedBright: [101, 49],
|
|
8913
|
-
bgGreenBright: [102, 49],
|
|
8914
|
-
bgYellowBright: [103, 49],
|
|
8915
|
-
bgBlueBright: [104, 49],
|
|
8916
|
-
bgMagentaBright: [105, 49],
|
|
8917
|
-
bgCyanBright: [106, 49],
|
|
8918
|
-
bgWhiteBright: [107, 49]
|
|
8919
|
-
}
|
|
8920
|
-
};
|
|
8921
|
-
styles.color.gray = styles.color.blackBright;
|
|
8922
|
-
styles.bgColor.bgGray = styles.bgColor.bgBlackBright;
|
|
8923
|
-
styles.color.grey = styles.color.blackBright;
|
|
8924
|
-
styles.bgColor.bgGrey = styles.bgColor.bgBlackBright;
|
|
8925
|
-
for (const [groupName, group] of Object.entries(styles)) {
|
|
8926
|
-
for (const [styleName, style] of Object.entries(group)) {
|
|
8927
|
-
styles[styleName] = {
|
|
8928
|
-
open: `\u001B[${style[0]}m`,
|
|
8929
|
-
close: `\u001B[${style[1]}m`
|
|
8930
|
-
};
|
|
8931
|
-
group[styleName] = styles[styleName];
|
|
8932
|
-
codes.set(style[0], style[1]);
|
|
8933
|
-
}
|
|
8934
|
-
Object.defineProperty(styles, groupName, {
|
|
8935
|
-
value: group,
|
|
8936
|
-
enumerable: false
|
|
8937
|
-
});
|
|
8938
|
-
}
|
|
8939
|
-
Object.defineProperty(styles, "codes", {
|
|
8940
|
-
value: codes,
|
|
8941
7338
|
enumerable: false
|
|
8942
|
-
}
|
|
8943
|
-
|
|
8944
|
-
|
|
8945
|
-
|
|
8946
|
-
|
|
8947
|
-
|
|
8948
|
-
|
|
8949
|
-
|
|
8950
|
-
|
|
8951
|
-
return styles;
|
|
8952
|
-
}
|
|
8953
|
-
Object.defineProperty(module, "exports", {
|
|
8954
|
-
enumerable: true,
|
|
8955
|
-
get: assembleStyles
|
|
7339
|
+
},
|
|
7340
|
+
rgbToAnsi: {
|
|
7341
|
+
value: (red, green, blue) => styles$1.ansi256ToAnsi(styles$1.rgbToAnsi256(red, green, blue)),
|
|
7342
|
+
enumerable: false
|
|
7343
|
+
},
|
|
7344
|
+
hexToAnsi: {
|
|
7345
|
+
value: (hex) => styles$1.ansi256ToAnsi(styles$1.hexToAnsi256(hex)),
|
|
7346
|
+
enumerable: false
|
|
7347
|
+
}
|
|
8956
7348
|
});
|
|
8957
|
-
|
|
8958
|
-
|
|
8959
|
-
|
|
8960
|
-
var require_browser = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
8961
|
-
module.exports = {
|
|
8962
|
-
stdout: false,
|
|
8963
|
-
stderr: false
|
|
8964
|
-
};
|
|
8965
|
-
}));
|
|
7349
|
+
return styles$1;
|
|
7350
|
+
}
|
|
7351
|
+
var ansiStyles = assembleStyles();
|
|
8966
7352
|
//#endregion
|
|
8967
|
-
//#region node_modules/chalk/source/
|
|
8968
|
-
var
|
|
8969
|
-
|
|
8970
|
-
|
|
8971
|
-
|
|
8972
|
-
|
|
8973
|
-
|
|
8974
|
-
|
|
8975
|
-
|
|
8976
|
-
|
|
8977
|
-
|
|
8978
|
-
|
|
8979
|
-
|
|
8980
|
-
|
|
8981
|
-
|
|
8982
|
-
|
|
8983
|
-
|
|
8984
|
-
|
|
8985
|
-
|
|
8986
|
-
|
|
8987
|
-
const gotCR = string[index - 1] === "\r";
|
|
8988
|
-
returnValue += string.substr(endIndex, (gotCR ? index - 1 : index) - endIndex) + prefix + (gotCR ? "\r\n" : "\n") + postfix;
|
|
8989
|
-
endIndex = index + 1;
|
|
8990
|
-
index = string.indexOf("\n", endIndex);
|
|
8991
|
-
} while (index !== -1);
|
|
8992
|
-
returnValue += string.substr(endIndex);
|
|
8993
|
-
return returnValue;
|
|
8994
|
-
};
|
|
8995
|
-
module.exports = {
|
|
8996
|
-
stringReplaceAll,
|
|
8997
|
-
stringEncaseCRLFWithFirstIndex
|
|
8998
|
-
};
|
|
8999
|
-
}));
|
|
7353
|
+
//#region node_modules/chalk/source/vendor/supports-color/browser.js
|
|
7354
|
+
var level = (() => {
|
|
7355
|
+
if (!("navigator" in globalThis)) return 0;
|
|
7356
|
+
if (globalThis.navigator.userAgentData) {
|
|
7357
|
+
const brand = navigator.userAgentData.brands.find(({ brand }) => brand === "Chromium");
|
|
7358
|
+
if (brand && brand.version > 93) return 3;
|
|
7359
|
+
}
|
|
7360
|
+
if (/\b(Chrome|Chromium)\//.test(globalThis.navigator.userAgent)) return 1;
|
|
7361
|
+
return 0;
|
|
7362
|
+
})();
|
|
7363
|
+
var colorSupport = level !== 0 && {
|
|
7364
|
+
level,
|
|
7365
|
+
hasBasic: true,
|
|
7366
|
+
has256: level >= 2,
|
|
7367
|
+
has16m: level >= 3
|
|
7368
|
+
};
|
|
7369
|
+
var supportsColor = {
|
|
7370
|
+
stdout: colorSupport,
|
|
7371
|
+
stderr: colorSupport
|
|
7372
|
+
};
|
|
9000
7373
|
//#endregion
|
|
9001
|
-
//#region node_modules/chalk/source/
|
|
9002
|
-
|
|
9003
|
-
|
|
9004
|
-
|
|
9005
|
-
|
|
9006
|
-
|
|
9007
|
-
|
|
9008
|
-
|
|
9009
|
-
|
|
9010
|
-
|
|
9011
|
-
|
|
9012
|
-
|
|
9013
|
-
|
|
9014
|
-
|
|
9015
|
-
|
|
9016
|
-
|
|
9017
|
-
|
|
9018
|
-
|
|
9019
|
-
|
|
9020
|
-
const
|
|
9021
|
-
|
|
9022
|
-
|
|
9023
|
-
|
|
9024
|
-
|
|
9025
|
-
|
|
9026
|
-
|
|
9027
|
-
|
|
9028
|
-
const chunks = arguments_.trim().split(/\s*,\s*/g);
|
|
9029
|
-
let matches;
|
|
9030
|
-
for (const chunk of chunks) {
|
|
9031
|
-
const number = Number(chunk);
|
|
9032
|
-
if (!Number.isNaN(number)) results.push(number);
|
|
9033
|
-
else if (matches = chunk.match(STRING_REGEX)) results.push(matches[2].replace(ESCAPE_REGEX, (m, escape, character) => escape ? unescape(escape) : character));
|
|
9034
|
-
else throw new Error(`Invalid Chalk template style argument: ${chunk} (in style '${name}')`);
|
|
9035
|
-
}
|
|
9036
|
-
return results;
|
|
9037
|
-
}
|
|
9038
|
-
function parseStyle(style) {
|
|
9039
|
-
STYLE_REGEX.lastIndex = 0;
|
|
9040
|
-
const results = [];
|
|
9041
|
-
let matches;
|
|
9042
|
-
while ((matches = STYLE_REGEX.exec(style)) !== null) {
|
|
9043
|
-
const name = matches[1];
|
|
9044
|
-
if (matches[2]) {
|
|
9045
|
-
const args = parseArguments(name, matches[2]);
|
|
9046
|
-
results.push([name].concat(args));
|
|
9047
|
-
} else results.push([name]);
|
|
9048
|
-
}
|
|
9049
|
-
return results;
|
|
9050
|
-
}
|
|
9051
|
-
function buildStyle(chalk, styles) {
|
|
9052
|
-
const enabled = {};
|
|
9053
|
-
for (const layer of styles) for (const style of layer.styles) enabled[style[0]] = layer.inverse ? null : style.slice(1);
|
|
9054
|
-
let current = chalk;
|
|
9055
|
-
for (const [styleName, styles] of Object.entries(enabled)) {
|
|
9056
|
-
if (!Array.isArray(styles)) continue;
|
|
9057
|
-
if (!(styleName in current)) throw new Error(`Unknown Chalk style: ${styleName}`);
|
|
9058
|
-
current = styles.length > 0 ? current[styleName](...styles) : current[styleName];
|
|
9059
|
-
}
|
|
9060
|
-
return current;
|
|
9061
|
-
}
|
|
9062
|
-
module.exports = (chalk, temporary) => {
|
|
9063
|
-
const styles = [];
|
|
9064
|
-
const chunks = [];
|
|
9065
|
-
let chunk = [];
|
|
9066
|
-
temporary.replace(TEMPLATE_REGEX, (m, escapeCharacter, inverse, style, close, character) => {
|
|
9067
|
-
if (escapeCharacter) chunk.push(unescape(escapeCharacter));
|
|
9068
|
-
else if (style) {
|
|
9069
|
-
const string = chunk.join("");
|
|
9070
|
-
chunk = [];
|
|
9071
|
-
chunks.push(styles.length === 0 ? string : buildStyle(chalk, styles)(string));
|
|
9072
|
-
styles.push({
|
|
9073
|
-
inverse,
|
|
9074
|
-
styles: parseStyle(style)
|
|
9075
|
-
});
|
|
9076
|
-
} else if (close) {
|
|
9077
|
-
if (styles.length === 0) throw new Error("Found extraneous } in Chalk template literal");
|
|
9078
|
-
chunks.push(buildStyle(chalk, styles)(chunk.join("")));
|
|
9079
|
-
chunk = [];
|
|
9080
|
-
styles.pop();
|
|
9081
|
-
} else chunk.push(character);
|
|
9082
|
-
});
|
|
9083
|
-
chunks.push(chunk.join(""));
|
|
9084
|
-
if (styles.length > 0) {
|
|
9085
|
-
const errMessage = `Chalk template literal is missing ${styles.length} closing bracket${styles.length === 1 ? "" : "s"} (\`}\`)`;
|
|
9086
|
-
throw new Error(errMessage);
|
|
9087
|
-
}
|
|
9088
|
-
return chunks.join("");
|
|
9089
|
-
};
|
|
9090
|
-
}));
|
|
7374
|
+
//#region node_modules/chalk/source/utilities.js
|
|
7375
|
+
function stringReplaceAll(string, substring, replacer) {
|
|
7376
|
+
let index = string.indexOf(substring);
|
|
7377
|
+
if (index === -1) return string;
|
|
7378
|
+
const substringLength = substring.length;
|
|
7379
|
+
let endIndex = 0;
|
|
7380
|
+
let returnValue = "";
|
|
7381
|
+
do {
|
|
7382
|
+
returnValue += string.slice(endIndex, index) + substring + replacer;
|
|
7383
|
+
endIndex = index + substringLength;
|
|
7384
|
+
index = string.indexOf(substring, endIndex);
|
|
7385
|
+
} while (index !== -1);
|
|
7386
|
+
returnValue += string.slice(endIndex);
|
|
7387
|
+
return returnValue;
|
|
7388
|
+
}
|
|
7389
|
+
function stringEncaseCRLFWithFirstIndex(string, prefix, postfix, index) {
|
|
7390
|
+
let endIndex = 0;
|
|
7391
|
+
let returnValue = "";
|
|
7392
|
+
do {
|
|
7393
|
+
const gotCR = string[index - 1] === "\r";
|
|
7394
|
+
returnValue += string.slice(endIndex, gotCR ? index - 1 : index) + prefix + (gotCR ? "\r\n" : "\n") + postfix;
|
|
7395
|
+
endIndex = index + 1;
|
|
7396
|
+
index = string.indexOf("\n", endIndex);
|
|
7397
|
+
} while (index !== -1);
|
|
7398
|
+
returnValue += string.slice(endIndex);
|
|
7399
|
+
return returnValue;
|
|
7400
|
+
}
|
|
9091
7401
|
//#endregion
|
|
9092
7402
|
//#region node_modules/chalk/source/index.js
|
|
9093
|
-
var
|
|
9094
|
-
|
|
9095
|
-
|
|
9096
|
-
|
|
9097
|
-
|
|
9098
|
-
|
|
9099
|
-
|
|
9100
|
-
|
|
9101
|
-
|
|
9102
|
-
|
|
9103
|
-
|
|
9104
|
-
|
|
9105
|
-
|
|
9106
|
-
|
|
9107
|
-
|
|
9108
|
-
|
|
9109
|
-
|
|
9110
|
-
|
|
9111
|
-
|
|
9112
|
-
|
|
9113
|
-
|
|
9114
|
-
|
|
9115
|
-
|
|
9116
|
-
|
|
9117
|
-
|
|
9118
|
-
|
|
9119
|
-
|
|
9120
|
-
|
|
9121
|
-
|
|
9122
|
-
|
|
7403
|
+
var { stdout: stdoutColor, stderr: stderrColor } = supportsColor;
|
|
7404
|
+
var GENERATOR = Symbol("GENERATOR");
|
|
7405
|
+
var STYLER = Symbol("STYLER");
|
|
7406
|
+
var IS_EMPTY = Symbol("IS_EMPTY");
|
|
7407
|
+
var levelMapping = [
|
|
7408
|
+
"ansi",
|
|
7409
|
+
"ansi",
|
|
7410
|
+
"ansi256",
|
|
7411
|
+
"ansi16m"
|
|
7412
|
+
];
|
|
7413
|
+
var styles = Object.create(null);
|
|
7414
|
+
var applyOptions = (object, options = {}) => {
|
|
7415
|
+
if (options.level && !(Number.isInteger(options.level) && options.level >= 0 && options.level <= 3)) throw new Error("The `level` option should be an integer from 0 to 3");
|
|
7416
|
+
const colorLevel = stdoutColor ? stdoutColor.level : 0;
|
|
7417
|
+
object.level = options.level === void 0 ? colorLevel : options.level;
|
|
7418
|
+
};
|
|
7419
|
+
var chalkFactory = (options) => {
|
|
7420
|
+
const chalk = (...strings) => strings.join(" ");
|
|
7421
|
+
applyOptions(chalk, options);
|
|
7422
|
+
Object.setPrototypeOf(chalk, createChalk.prototype);
|
|
7423
|
+
return chalk;
|
|
7424
|
+
};
|
|
7425
|
+
function createChalk(options) {
|
|
7426
|
+
return chalkFactory(options);
|
|
7427
|
+
}
|
|
7428
|
+
Object.setPrototypeOf(createChalk.prototype, Function.prototype);
|
|
7429
|
+
for (const [styleName, style] of Object.entries(ansiStyles)) styles[styleName] = { get() {
|
|
7430
|
+
const builder = createBuilder(this, createStyler(style.open, style.close, this[STYLER]), this[IS_EMPTY]);
|
|
7431
|
+
Object.defineProperty(this, styleName, { value: builder });
|
|
7432
|
+
return builder;
|
|
7433
|
+
} };
|
|
7434
|
+
styles.visible = { get() {
|
|
7435
|
+
const builder = createBuilder(this, this[STYLER], true);
|
|
7436
|
+
Object.defineProperty(this, "visible", { value: builder });
|
|
7437
|
+
return builder;
|
|
7438
|
+
} };
|
|
7439
|
+
var getModelAnsi = (model, level, type, ...arguments_) => {
|
|
7440
|
+
if (model === "rgb") {
|
|
7441
|
+
if (level === "ansi16m") return ansiStyles[type].ansi16m(...arguments_);
|
|
7442
|
+
if (level === "ansi256") return ansiStyles[type].ansi256(ansiStyles.rgbToAnsi256(...arguments_));
|
|
7443
|
+
return ansiStyles[type].ansi(ansiStyles.rgbToAnsi(...arguments_));
|
|
7444
|
+
}
|
|
7445
|
+
if (model === "hex") return getModelAnsi("rgb", level, type, ...ansiStyles.hexToRgb(...arguments_));
|
|
7446
|
+
return ansiStyles[type][model](...arguments_);
|
|
7447
|
+
};
|
|
7448
|
+
for (const model of [
|
|
7449
|
+
"rgb",
|
|
7450
|
+
"hex",
|
|
7451
|
+
"ansi256"
|
|
7452
|
+
]) {
|
|
7453
|
+
styles[model] = { get() {
|
|
7454
|
+
const { level } = this;
|
|
7455
|
+
return function(...arguments_) {
|
|
7456
|
+
const styler = createStyler(getModelAnsi(model, levelMapping[level], "color", ...arguments_), ansiStyles.color.close, this[STYLER]);
|
|
7457
|
+
return createBuilder(this, styler, this[IS_EMPTY]);
|
|
9123
7458
|
};
|
|
9124
|
-
chalk.template.Instance = ChalkClass;
|
|
9125
|
-
return chalk.template;
|
|
9126
|
-
};
|
|
9127
|
-
function Chalk(options) {
|
|
9128
|
-
return chalkFactory(options);
|
|
9129
|
-
}
|
|
9130
|
-
for (const [styleName, style] of Object.entries(ansiStyles)) styles[styleName] = { get() {
|
|
9131
|
-
const builder = createBuilder(this, createStyler(style.open, style.close, this._styler), this._isEmpty);
|
|
9132
|
-
Object.defineProperty(this, styleName, { value: builder });
|
|
9133
|
-
return builder;
|
|
9134
7459
|
} };
|
|
9135
|
-
|
|
9136
|
-
|
|
9137
|
-
Object.defineProperty(this, "visible", { value: builder });
|
|
9138
|
-
return builder;
|
|
9139
|
-
} };
|
|
9140
|
-
var usedModels = [
|
|
9141
|
-
"rgb",
|
|
9142
|
-
"hex",
|
|
9143
|
-
"keyword",
|
|
9144
|
-
"hsl",
|
|
9145
|
-
"hsv",
|
|
9146
|
-
"hwb",
|
|
9147
|
-
"ansi",
|
|
9148
|
-
"ansi256"
|
|
9149
|
-
];
|
|
9150
|
-
for (const model of usedModels) styles[model] = { get() {
|
|
7460
|
+
const bgModel = "bg" + model[0].toUpperCase() + model.slice(1);
|
|
7461
|
+
styles[bgModel] = { get() {
|
|
9151
7462
|
const { level } = this;
|
|
9152
7463
|
return function(...arguments_) {
|
|
9153
|
-
const styler = createStyler(
|
|
9154
|
-
return createBuilder(this, styler, this
|
|
7464
|
+
const styler = createStyler(getModelAnsi(model, levelMapping[level], "bgColor", ...arguments_), ansiStyles.bgColor.close, this[STYLER]);
|
|
7465
|
+
return createBuilder(this, styler, this[IS_EMPTY]);
|
|
9155
7466
|
};
|
|
9156
7467
|
} };
|
|
9157
|
-
|
|
9158
|
-
|
|
9159
|
-
|
|
9160
|
-
|
|
9161
|
-
|
|
9162
|
-
|
|
9163
|
-
|
|
9164
|
-
|
|
9165
|
-
|
|
9166
|
-
|
|
9167
|
-
var proto = Object.defineProperties(() => {}, {
|
|
9168
|
-
...styles,
|
|
9169
|
-
level: {
|
|
9170
|
-
enumerable: true,
|
|
9171
|
-
get() {
|
|
9172
|
-
return this._generator.level;
|
|
9173
|
-
},
|
|
9174
|
-
set(level) {
|
|
9175
|
-
this._generator.level = level;
|
|
9176
|
-
}
|
|
9177
|
-
}
|
|
9178
|
-
});
|
|
9179
|
-
var createStyler = (open, close, parent) => {
|
|
9180
|
-
let openAll;
|
|
9181
|
-
let closeAll;
|
|
9182
|
-
if (parent === void 0) {
|
|
9183
|
-
openAll = open;
|
|
9184
|
-
closeAll = close;
|
|
9185
|
-
} else {
|
|
9186
|
-
openAll = parent.openAll + open;
|
|
9187
|
-
closeAll = close + parent.closeAll;
|
|
7468
|
+
}
|
|
7469
|
+
var proto = Object.defineProperties(() => {}, {
|
|
7470
|
+
...styles,
|
|
7471
|
+
level: {
|
|
7472
|
+
enumerable: true,
|
|
7473
|
+
get() {
|
|
7474
|
+
return this[GENERATOR].level;
|
|
7475
|
+
},
|
|
7476
|
+
set(level) {
|
|
7477
|
+
this[GENERATOR].level = level;
|
|
9188
7478
|
}
|
|
9189
|
-
|
|
9190
|
-
|
|
9191
|
-
|
|
9192
|
-
|
|
9193
|
-
|
|
9194
|
-
|
|
9195
|
-
|
|
7479
|
+
}
|
|
7480
|
+
});
|
|
7481
|
+
var createStyler = (open, close, parent) => {
|
|
7482
|
+
let openAll;
|
|
7483
|
+
let closeAll;
|
|
7484
|
+
if (parent === void 0) {
|
|
7485
|
+
openAll = open;
|
|
7486
|
+
closeAll = close;
|
|
7487
|
+
} else {
|
|
7488
|
+
openAll = parent.openAll + open;
|
|
7489
|
+
closeAll = close + parent.closeAll;
|
|
7490
|
+
}
|
|
7491
|
+
return {
|
|
7492
|
+
open,
|
|
7493
|
+
close,
|
|
7494
|
+
openAll,
|
|
7495
|
+
closeAll,
|
|
7496
|
+
parent
|
|
9196
7497
|
};
|
|
9197
|
-
|
|
9198
|
-
|
|
9199
|
-
|
|
9200
|
-
|
|
9201
|
-
|
|
9202
|
-
|
|
9203
|
-
|
|
9204
|
-
|
|
9205
|
-
|
|
9206
|
-
|
|
9207
|
-
|
|
9208
|
-
|
|
9209
|
-
|
|
9210
|
-
|
|
9211
|
-
|
|
9212
|
-
|
|
9213
|
-
|
|
9214
|
-
|
|
9215
|
-
|
|
9216
|
-
|
|
9217
|
-
|
|
9218
|
-
|
|
9219
|
-
|
|
9220
|
-
|
|
9221
|
-
|
|
9222
|
-
var chalkTag = (chalk, ...strings) => {
|
|
9223
|
-
const [firstString] = strings;
|
|
9224
|
-
if (!isArray(firstString) || !isArray(firstString.raw)) return strings.join(" ");
|
|
9225
|
-
const arguments_ = strings.slice(1);
|
|
9226
|
-
const parts = [firstString.raw[0]];
|
|
9227
|
-
for (let i = 1; i < firstString.length; i++) parts.push(String(arguments_[i - 1]).replace(/[{}\\]/g, "\\$&"), String(firstString.raw[i]));
|
|
9228
|
-
if (template === void 0) template = require_templates();
|
|
9229
|
-
return template(chalk, parts.join(""));
|
|
9230
|
-
};
|
|
9231
|
-
Object.defineProperties(Chalk.prototype, styles);
|
|
9232
|
-
var chalk = Chalk();
|
|
9233
|
-
chalk.supportsColor = stdoutColor;
|
|
9234
|
-
chalk.stderr = Chalk({ level: stderrColor ? stderrColor.level : 0 });
|
|
9235
|
-
chalk.stderr.supportsColor = stderrColor;
|
|
9236
|
-
module.exports = chalk;
|
|
9237
|
-
}));
|
|
7498
|
+
};
|
|
7499
|
+
var createBuilder = (self, _styler, _isEmpty) => {
|
|
7500
|
+
const builder = (...arguments_) => applyStyle(builder, arguments_.length === 1 ? "" + arguments_[0] : arguments_.join(" "));
|
|
7501
|
+
Object.setPrototypeOf(builder, proto);
|
|
7502
|
+
builder[GENERATOR] = self;
|
|
7503
|
+
builder[STYLER] = _styler;
|
|
7504
|
+
builder[IS_EMPTY] = _isEmpty;
|
|
7505
|
+
return builder;
|
|
7506
|
+
};
|
|
7507
|
+
var applyStyle = (self, string) => {
|
|
7508
|
+
if (self.level <= 0 || !string) return self[IS_EMPTY] ? "" : string;
|
|
7509
|
+
let styler = self[STYLER];
|
|
7510
|
+
if (styler === void 0) return string;
|
|
7511
|
+
const { openAll, closeAll } = styler;
|
|
7512
|
+
if (string.includes("\x1B")) while (styler !== void 0) {
|
|
7513
|
+
string = stringReplaceAll(string, styler.close, styler.open);
|
|
7514
|
+
styler = styler.parent;
|
|
7515
|
+
}
|
|
7516
|
+
const lfIndex = string.indexOf("\n");
|
|
7517
|
+
if (lfIndex !== -1) string = stringEncaseCRLFWithFirstIndex(string, closeAll, openAll, lfIndex);
|
|
7518
|
+
return openAll + string + closeAll;
|
|
7519
|
+
};
|
|
7520
|
+
Object.defineProperties(createChalk.prototype, styles);
|
|
7521
|
+
var chalk = createChalk();
|
|
7522
|
+
createChalk({ level: stderrColor ? stderrColor.level : 0 });
|
|
9238
7523
|
//#endregion
|
|
9239
7524
|
//#region node_modules/valid-url/index.js
|
|
9240
7525
|
var require_valid_url = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
@@ -10702,9 +8987,8 @@ var require_jmespath = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
10702
8987
|
}));
|
|
10703
8988
|
//#endregion
|
|
10704
8989
|
//#region src/fhir-database/dbsearchindexbase.ts
|
|
10705
|
-
var
|
|
10706
|
-
var
|
|
10707
|
-
var import_jmespath = /* @__PURE__ */ __toESM(require_jmespath());
|
|
8990
|
+
var import_valid_url = /* @__PURE__ */ __toESM(require_valid_url(), 1);
|
|
8991
|
+
var import_jmespath = /* @__PURE__ */ __toESM(require_jmespath(), 1);
|
|
10708
8992
|
var DBSearchIndexBase = class {
|
|
10709
8993
|
#ops = {
|
|
10710
8994
|
"==": (a, b) => a == b,
|
|
@@ -11056,8 +9340,8 @@ var DBSearchIndexDates = class extends DBSearchIndexBase {
|
|
|
11056
9340
|
return retVal;
|
|
11057
9341
|
};
|
|
11058
9342
|
OutputIndexRecordToConsole = (tir) => {
|
|
11059
|
-
const datesPromptColour =
|
|
11060
|
-
const datesColour =
|
|
9343
|
+
const datesPromptColour = chalk.rgb(200, 200, 255);
|
|
9344
|
+
const datesColour = chalk.rgb(200, 150, 10);
|
|
11061
9345
|
let retVal = "";
|
|
11062
9346
|
let sep = "";
|
|
11063
9347
|
if (tir) for (let i = 0; i < tir.length; i++) {
|
|
@@ -11076,7 +9360,7 @@ var DBSearchIndexDates = class extends DBSearchIndexBase {
|
|
|
11076
9360
|
retVal = `${retVal}${sep}${outputText}`;
|
|
11077
9361
|
sep = "\n";
|
|
11078
9362
|
}
|
|
11079
|
-
if (retVal === "") this.#debug(
|
|
9363
|
+
if (retVal === "") this.#debug(chalk.rgb(250, 50, 100)` --> *** DATE: Search Param Not Found *** <--`);
|
|
11080
9364
|
else this.#debug(retVal);
|
|
11081
9365
|
return retVal;
|
|
11082
9366
|
};
|
|
@@ -11479,7 +9763,7 @@ var DBSearchIndex = class DBSearchIndex {
|
|
|
11479
9763
|
await this.resourceHelper.Stop();
|
|
11480
9764
|
};
|
|
11481
9765
|
#OutputSearchDetails = (resourceName, resourceId, searchFieldRecord) => {
|
|
11482
|
-
const hl =
|
|
9766
|
+
const hl = chalk.yellow.bold.italic;
|
|
11483
9767
|
this.#debug("------------------");
|
|
11484
9768
|
this.#debug(`resource: [${hl(resourceName)}] \
|
|
11485
9769
|
resourceId: [${hl(resourceId)}] \
|
|
@@ -14266,7 +12550,7 @@ var require_connection = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
14266
12550
|
module.exports = Connection$1;
|
|
14267
12551
|
}));
|
|
14268
12552
|
//#endregion
|
|
14269
|
-
//#region node_modules/safe-buffer/index.js
|
|
12553
|
+
//#region node_modules/string_decoder/node_modules/safe-buffer/index.js
|
|
14270
12554
|
var require_safe_buffer = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
14271
12555
|
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
14272
12556
|
var buffer = require("buffer");
|
|
@@ -16113,15 +14397,15 @@ var PGPoolManager = class extends import_tiny_emitter.TinyEmitter {
|
|
|
16113
14397
|
safeConnectionString,
|
|
16114
14398
|
pool
|
|
16115
14399
|
};
|
|
16116
|
-
if (cluster.default.isPrimary) this.#LogDebugMessage(
|
|
16117
|
-
else this.#LogDebugMessage(
|
|
16118
|
-
this.#LogDebugMessage(
|
|
16119
|
-
this.#LogDebugMessage(
|
|
16120
|
-
this.#LogDebugMessage(
|
|
16121
|
-
this.#LogDebugMessage(
|
|
14400
|
+
if (cluster.default.isPrimary) this.#LogDebugMessage(chalk.yellow(`Created Database Pool with Master Thread, PID: [${process.pid}]`));
|
|
14401
|
+
else this.#LogDebugMessage(chalk.yellow(`Created Database Pool with Worker Thread, PID: [${process.pid}]`));
|
|
14402
|
+
this.#LogDebugMessage(chalk.yellow(`Created Database Pool: Master Thread`));
|
|
14403
|
+
this.#LogDebugMessage(chalk.yellow(` Connection URI: [${safeConnectionString}]`));
|
|
14404
|
+
this.#LogDebugMessage(chalk.yellow(` Maximum Pool Size: [${poolSize}]`));
|
|
14405
|
+
this.#LogDebugMessage(chalk.yellow(` SSL Connection: [${isProduction}]`));
|
|
16122
14406
|
pool.on("error", (error) => {
|
|
16123
|
-
this.#LogDebugMessage(
|
|
16124
|
-
this.#LogErrorMessage(
|
|
14407
|
+
this.#LogDebugMessage(chalk.red(`[${safeConnectionString}]: pool error`));
|
|
14408
|
+
this.#LogErrorMessage(chalk.red(`Unexpected error on idle client: [${error}], connection: [${safeConnectionString}]`));
|
|
16125
14409
|
});
|
|
16126
14410
|
pool.on("connect", () => {
|
|
16127
14411
|
this.#UpdateInstruments();
|
|
@@ -16131,8 +14415,8 @@ var PGPoolManager = class extends import_tiny_emitter.TinyEmitter {
|
|
|
16131
14415
|
});
|
|
16132
14416
|
pool.on("release", (error) => {
|
|
16133
14417
|
if (error) {
|
|
16134
|
-
this.#LogDebugMessage(
|
|
16135
|
-
this.#LogErrorMessage(
|
|
14418
|
+
this.#LogDebugMessage(chalk.red(`[${safeConnectionString}]: pool release`));
|
|
14419
|
+
this.#LogErrorMessage(chalk.red(`Unexpected error on client release from pool: [${error}], connection: [${safeConnectionString}]`));
|
|
16136
14420
|
}
|
|
16137
14421
|
this.#UpdateInstruments();
|
|
16138
14422
|
});
|
|
@@ -16141,19 +14425,19 @@ var PGPoolManager = class extends import_tiny_emitter.TinyEmitter {
|
|
|
16141
14425
|
});
|
|
16142
14426
|
}
|
|
16143
14427
|
async EndPool(poolItem) {
|
|
16144
|
-
this.#LogDebugMessage(
|
|
14428
|
+
this.#LogDebugMessage(chalk.cyan(`Ending database for process PID: ${process.pid}`));
|
|
16145
14429
|
if (poolItem) {
|
|
16146
|
-
this.#LogDebugMessage(
|
|
16147
|
-
this.#LogDebugMessage(
|
|
14430
|
+
this.#LogDebugMessage(chalk.cyan(`ending pool with connection string: [${poolItem.safeConnectionString}]`));
|
|
14431
|
+
this.#LogDebugMessage(chalk.cyan(`pool details (before end), Total: [${poolItem.pool.totalCount}], Idle: [${poolItem.pool.idleCount}], Waiting: [${poolItem.pool.waitingCount}]`));
|
|
16148
14432
|
await poolItem.pool.end();
|
|
16149
|
-
this.#LogDebugMessage(
|
|
16150
|
-
this.#LogDebugMessage(
|
|
14433
|
+
this.#LogDebugMessage(chalk.cyan(`pool details (after end), Total: [${poolItem.pool.totalCount}], Idle: [${poolItem.pool.idleCount}], Waiting: [${poolItem.pool.waitingCount}]`));
|
|
14434
|
+
this.#LogDebugMessage(chalk.green(`Database pool ended for PID: ${process.pid}`));
|
|
16151
14435
|
poolItem.pool.removeAllListeners();
|
|
16152
|
-
this.#LogDebugMessage(
|
|
16153
|
-
} else this.#LogDebugMessage(
|
|
14436
|
+
this.#LogDebugMessage(chalk.green(`Removed all listeners: ${process.pid}`));
|
|
14437
|
+
} else this.#LogDebugMessage(chalk.yellow(`Database pool was not defined - not ended for PID: ${process.pid}`));
|
|
16154
14438
|
}
|
|
16155
14439
|
async End() {
|
|
16156
|
-
this.#LogDebugMessage(
|
|
14440
|
+
this.#LogDebugMessage(chalk.cyan(`Ending database for process PID: ${process.pid}`));
|
|
16157
14441
|
for (const [, pool] of Object.entries(this.#pools)) await this.EndPool(pool);
|
|
16158
14442
|
this.#DetachInstruments();
|
|
16159
14443
|
}
|
|
@@ -17201,7 +15485,7 @@ var DBSTSCombo = class {
|
|
|
17201
15485
|
};
|
|
17202
15486
|
//#endregion
|
|
17203
15487
|
//#region src/fhir-database/pg/pgfhiraccesslayer.ts
|
|
17204
|
-
|
|
15488
|
+
chalk.level = 3;
|
|
17205
15489
|
var PGFhirAccessLayer = class extends import_tiny_emitter.TinyEmitter {
|
|
17206
15490
|
#options;
|
|
17207
15491
|
#poolManager = null;
|
|
@@ -17355,9 +15639,9 @@ var PGFhirAccessLayer = class extends import_tiny_emitter.TinyEmitter {
|
|
|
17355
15639
|
}
|
|
17356
15640
|
const lap3 = performance.now() - start;
|
|
17357
15641
|
const total = performance.now() - oa;
|
|
17358
|
-
if (total > 100) console.log(
|
|
17359
|
-
else if (total > 75) console.log(
|
|
17360
|
-
else if (total > 50) console.log(
|
|
15642
|
+
if (total > 100) console.log(chalk.hex("#E33A36")`--> Slow: O/A:[${total.toFixed(2)}] Index Calc:[${lap1.toFixed(2)}] Delete:[${lap2.toFixed(2)}] Insert:[${lap3.toFixed(2)}]`);
|
|
15643
|
+
else if (total > 75) console.log(chalk.hex("#e27270")`--> Slow: O/A:[${total.toFixed(2)}] Index Calc:[${lap1.toFixed(2)}] Delete:[${lap2.toFixed(2)}] Insert:[${lap3.toFixed(2)}]`);
|
|
15644
|
+
else if (total > 50) console.log(chalk.hex("#e2c3c2")`--> Slow: O/A:[${total.toFixed(2)}] Index Calc:[${lap1.toFixed(2)}] Delete:[${lap2.toFixed(2)}] Insert:[${lap3.toFixed(2)}]`);
|
|
17361
15645
|
};
|
|
17362
15646
|
#isInTransaction = async (client) => {
|
|
17363
15647
|
return (await client.query(`
|