@nsshunt/stsrunnerframework 2.0.10 → 2.0.11
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 +348 -2061
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +348 -2061
- package/dist/index.mjs.map +1 -1
- package/package.json +6 -6
package/dist/index.cjs
CHANGED
|
@@ -92,2056 +92,343 @@ var PublishMessageCommandsTestRunner = {
|
|
|
92
92
|
ExecuteRefreshTokenResponse: "__ExecuteRefreshTokenResponse"
|
|
93
93
|
};
|
|
94
94
|
//#endregion
|
|
95
|
-
//#region node_modules/
|
|
96
|
-
var
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
],
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
],
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
],
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
],
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
],
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
],
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
],
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
],
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
226
|
|
152
|
-
],
|
|
153
|
-
"brown": [
|
|
154
|
-
165,
|
|
155
|
-
42,
|
|
156
|
-
42
|
|
157
|
-
],
|
|
158
|
-
"burlywood": [
|
|
159
|
-
222,
|
|
160
|
-
184,
|
|
161
|
-
135
|
|
162
|
-
],
|
|
163
|
-
"cadetblue": [
|
|
164
|
-
95,
|
|
165
|
-
158,
|
|
166
|
-
160
|
|
167
|
-
],
|
|
168
|
-
"chartreuse": [
|
|
169
|
-
127,
|
|
170
|
-
255,
|
|
171
|
-
0
|
|
172
|
-
],
|
|
173
|
-
"chocolate": [
|
|
174
|
-
210,
|
|
175
|
-
105,
|
|
176
|
-
30
|
|
177
|
-
],
|
|
178
|
-
"coral": [
|
|
179
|
-
255,
|
|
180
|
-
127,
|
|
181
|
-
80
|
|
182
|
-
],
|
|
183
|
-
"cornflowerblue": [
|
|
184
|
-
100,
|
|
185
|
-
149,
|
|
186
|
-
237
|
|
187
|
-
],
|
|
188
|
-
"cornsilk": [
|
|
189
|
-
255,
|
|
190
|
-
248,
|
|
191
|
-
220
|
|
192
|
-
],
|
|
193
|
-
"crimson": [
|
|
194
|
-
220,
|
|
195
|
-
20,
|
|
196
|
-
60
|
|
197
|
-
],
|
|
198
|
-
"cyan": [
|
|
199
|
-
0,
|
|
200
|
-
255,
|
|
201
|
-
255
|
|
202
|
-
],
|
|
203
|
-
"darkblue": [
|
|
204
|
-
0,
|
|
205
|
-
0,
|
|
206
|
-
139
|
|
207
|
-
],
|
|
208
|
-
"darkcyan": [
|
|
209
|
-
0,
|
|
210
|
-
139,
|
|
211
|
-
139
|
|
212
|
-
],
|
|
213
|
-
"darkgoldenrod": [
|
|
214
|
-
184,
|
|
215
|
-
134,
|
|
216
|
-
11
|
|
217
|
-
],
|
|
218
|
-
"darkgray": [
|
|
219
|
-
169,
|
|
220
|
-
169,
|
|
221
|
-
169
|
|
222
|
-
],
|
|
223
|
-
"darkgreen": [
|
|
224
|
-
0,
|
|
225
|
-
100,
|
|
226
|
-
0
|
|
227
|
-
],
|
|
228
|
-
"darkgrey": [
|
|
229
|
-
169,
|
|
230
|
-
169,
|
|
231
|
-
169
|
|
232
|
-
],
|
|
233
|
-
"darkkhaki": [
|
|
234
|
-
189,
|
|
235
|
-
183,
|
|
236
|
-
107
|
|
237
|
-
],
|
|
238
|
-
"darkmagenta": [
|
|
239
|
-
139,
|
|
240
|
-
0,
|
|
241
|
-
139
|
|
242
|
-
],
|
|
243
|
-
"darkolivegreen": [
|
|
244
|
-
85,
|
|
245
|
-
107,
|
|
246
|
-
47
|
|
247
|
-
],
|
|
248
|
-
"darkorange": [
|
|
249
|
-
255,
|
|
250
|
-
140,
|
|
251
|
-
0
|
|
252
|
-
],
|
|
253
|
-
"darkorchid": [
|
|
254
|
-
153,
|
|
255
|
-
50,
|
|
256
|
-
204
|
|
257
|
-
],
|
|
258
|
-
"darkred": [
|
|
259
|
-
139,
|
|
260
|
-
0,
|
|
261
|
-
0
|
|
262
|
-
],
|
|
263
|
-
"darksalmon": [
|
|
264
|
-
233,
|
|
265
|
-
150,
|
|
266
|
-
122
|
|
267
|
-
],
|
|
268
|
-
"darkseagreen": [
|
|
269
|
-
143,
|
|
270
|
-
188,
|
|
271
|
-
143
|
|
272
|
-
],
|
|
273
|
-
"darkslateblue": [
|
|
274
|
-
72,
|
|
275
|
-
61,
|
|
276
|
-
139
|
|
277
|
-
],
|
|
278
|
-
"darkslategray": [
|
|
279
|
-
47,
|
|
280
|
-
79,
|
|
281
|
-
79
|
|
282
|
-
],
|
|
283
|
-
"darkslategrey": [
|
|
284
|
-
47,
|
|
285
|
-
79,
|
|
286
|
-
79
|
|
287
|
-
],
|
|
288
|
-
"darkturquoise": [
|
|
289
|
-
0,
|
|
290
|
-
206,
|
|
291
|
-
209
|
|
292
|
-
],
|
|
293
|
-
"darkviolet": [
|
|
294
|
-
148,
|
|
295
|
-
0,
|
|
296
|
-
211
|
|
297
|
-
],
|
|
298
|
-
"deeppink": [
|
|
299
|
-
255,
|
|
300
|
-
20,
|
|
301
|
-
147
|
|
302
|
-
],
|
|
303
|
-
"deepskyblue": [
|
|
304
|
-
0,
|
|
305
|
-
191,
|
|
306
|
-
255
|
|
307
|
-
],
|
|
308
|
-
"dimgray": [
|
|
309
|
-
105,
|
|
310
|
-
105,
|
|
311
|
-
105
|
|
312
|
-
],
|
|
313
|
-
"dimgrey": [
|
|
314
|
-
105,
|
|
315
|
-
105,
|
|
316
|
-
105
|
|
317
|
-
],
|
|
318
|
-
"dodgerblue": [
|
|
319
|
-
30,
|
|
320
|
-
144,
|
|
321
|
-
255
|
|
322
|
-
],
|
|
323
|
-
"firebrick": [
|
|
324
|
-
178,
|
|
325
|
-
34,
|
|
326
|
-
34
|
|
327
|
-
],
|
|
328
|
-
"floralwhite": [
|
|
329
|
-
255,
|
|
330
|
-
250,
|
|
331
|
-
240
|
|
332
|
-
],
|
|
333
|
-
"forestgreen": [
|
|
334
|
-
34,
|
|
335
|
-
139,
|
|
336
|
-
34
|
|
337
|
-
],
|
|
338
|
-
"fuchsia": [
|
|
339
|
-
255,
|
|
340
|
-
0,
|
|
341
|
-
255
|
|
342
|
-
],
|
|
343
|
-
"gainsboro": [
|
|
344
|
-
220,
|
|
345
|
-
220,
|
|
346
|
-
220
|
|
347
|
-
],
|
|
348
|
-
"ghostwhite": [
|
|
349
|
-
248,
|
|
350
|
-
248,
|
|
351
|
-
255
|
|
352
|
-
],
|
|
353
|
-
"gold": [
|
|
354
|
-
255,
|
|
355
|
-
215,
|
|
356
|
-
0
|
|
357
|
-
],
|
|
358
|
-
"goldenrod": [
|
|
359
|
-
218,
|
|
360
|
-
165,
|
|
361
|
-
32
|
|
362
|
-
],
|
|
363
|
-
"gray": [
|
|
364
|
-
128,
|
|
365
|
-
128,
|
|
366
|
-
128
|
|
367
|
-
],
|
|
368
|
-
"green": [
|
|
369
|
-
0,
|
|
370
|
-
128,
|
|
371
|
-
0
|
|
372
|
-
],
|
|
373
|
-
"greenyellow": [
|
|
374
|
-
173,
|
|
375
|
-
255,
|
|
376
|
-
47
|
|
377
|
-
],
|
|
378
|
-
"grey": [
|
|
379
|
-
128,
|
|
380
|
-
128,
|
|
381
|
-
128
|
|
382
|
-
],
|
|
383
|
-
"honeydew": [
|
|
384
|
-
240,
|
|
385
|
-
255,
|
|
386
|
-
240
|
|
387
|
-
],
|
|
388
|
-
"hotpink": [
|
|
389
|
-
255,
|
|
390
|
-
105,
|
|
391
|
-
180
|
|
392
|
-
],
|
|
393
|
-
"indianred": [
|
|
394
|
-
205,
|
|
395
|
-
92,
|
|
396
|
-
92
|
|
397
|
-
],
|
|
398
|
-
"indigo": [
|
|
399
|
-
75,
|
|
400
|
-
0,
|
|
401
|
-
130
|
|
402
|
-
],
|
|
403
|
-
"ivory": [
|
|
404
|
-
255,
|
|
405
|
-
255,
|
|
406
|
-
240
|
|
407
|
-
],
|
|
408
|
-
"khaki": [
|
|
409
|
-
240,
|
|
410
|
-
230,
|
|
411
|
-
140
|
|
412
|
-
],
|
|
413
|
-
"lavender": [
|
|
414
|
-
230,
|
|
415
|
-
230,
|
|
416
|
-
250
|
|
417
|
-
],
|
|
418
|
-
"lavenderblush": [
|
|
419
|
-
255,
|
|
420
|
-
240,
|
|
421
|
-
245
|
|
422
|
-
],
|
|
423
|
-
"lawngreen": [
|
|
424
|
-
124,
|
|
425
|
-
252,
|
|
426
|
-
0
|
|
427
|
-
],
|
|
428
|
-
"lemonchiffon": [
|
|
429
|
-
255,
|
|
430
|
-
250,
|
|
431
|
-
205
|
|
432
|
-
],
|
|
433
|
-
"lightblue": [
|
|
434
|
-
173,
|
|
435
|
-
216,
|
|
436
|
-
230
|
|
437
|
-
],
|
|
438
|
-
"lightcoral": [
|
|
439
|
-
240,
|
|
440
|
-
128,
|
|
441
|
-
128
|
|
442
|
-
],
|
|
443
|
-
"lightcyan": [
|
|
444
|
-
224,
|
|
445
|
-
255,
|
|
446
|
-
255
|
|
447
|
-
],
|
|
448
|
-
"lightgoldenrodyellow": [
|
|
449
|
-
250,
|
|
450
|
-
250,
|
|
451
|
-
210
|
|
452
|
-
],
|
|
453
|
-
"lightgray": [
|
|
454
|
-
211,
|
|
455
|
-
211,
|
|
456
|
-
211
|
|
457
|
-
],
|
|
458
|
-
"lightgreen": [
|
|
459
|
-
144,
|
|
460
|
-
238,
|
|
461
|
-
144
|
|
462
|
-
],
|
|
463
|
-
"lightgrey": [
|
|
464
|
-
211,
|
|
465
|
-
211,
|
|
466
|
-
211
|
|
467
|
-
],
|
|
468
|
-
"lightpink": [
|
|
469
|
-
255,
|
|
470
|
-
182,
|
|
471
|
-
193
|
|
472
|
-
],
|
|
473
|
-
"lightsalmon": [
|
|
474
|
-
255,
|
|
475
|
-
160,
|
|
476
|
-
122
|
|
477
|
-
],
|
|
478
|
-
"lightseagreen": [
|
|
479
|
-
32,
|
|
480
|
-
178,
|
|
481
|
-
170
|
|
482
|
-
],
|
|
483
|
-
"lightskyblue": [
|
|
484
|
-
135,
|
|
485
|
-
206,
|
|
486
|
-
250
|
|
487
|
-
],
|
|
488
|
-
"lightslategray": [
|
|
489
|
-
119,
|
|
490
|
-
136,
|
|
491
|
-
153
|
|
492
|
-
],
|
|
493
|
-
"lightslategrey": [
|
|
494
|
-
119,
|
|
495
|
-
136,
|
|
496
|
-
153
|
|
497
|
-
],
|
|
498
|
-
"lightsteelblue": [
|
|
499
|
-
176,
|
|
500
|
-
196,
|
|
501
|
-
222
|
|
502
|
-
],
|
|
503
|
-
"lightyellow": [
|
|
504
|
-
255,
|
|
505
|
-
255,
|
|
506
|
-
224
|
|
507
|
-
],
|
|
508
|
-
"lime": [
|
|
509
|
-
0,
|
|
510
|
-
255,
|
|
511
|
-
0
|
|
512
|
-
],
|
|
513
|
-
"limegreen": [
|
|
514
|
-
50,
|
|
515
|
-
205,
|
|
516
|
-
50
|
|
517
|
-
],
|
|
518
|
-
"linen": [
|
|
519
|
-
250,
|
|
520
|
-
240,
|
|
521
|
-
230
|
|
522
|
-
],
|
|
523
|
-
"magenta": [
|
|
524
|
-
255,
|
|
525
|
-
0,
|
|
526
|
-
255
|
|
527
|
-
],
|
|
528
|
-
"maroon": [
|
|
529
|
-
128,
|
|
530
|
-
0,
|
|
531
|
-
0
|
|
532
|
-
],
|
|
533
|
-
"mediumaquamarine": [
|
|
534
|
-
102,
|
|
535
|
-
205,
|
|
536
|
-
170
|
|
537
|
-
],
|
|
538
|
-
"mediumblue": [
|
|
539
|
-
0,
|
|
540
|
-
0,
|
|
541
|
-
205
|
|
542
|
-
],
|
|
543
|
-
"mediumorchid": [
|
|
544
|
-
186,
|
|
545
|
-
85,
|
|
546
|
-
211
|
|
547
|
-
],
|
|
548
|
-
"mediumpurple": [
|
|
549
|
-
147,
|
|
550
|
-
112,
|
|
551
|
-
219
|
|
552
|
-
],
|
|
553
|
-
"mediumseagreen": [
|
|
554
|
-
60,
|
|
555
|
-
179,
|
|
556
|
-
113
|
|
557
|
-
],
|
|
558
|
-
"mediumslateblue": [
|
|
559
|
-
123,
|
|
560
|
-
104,
|
|
561
|
-
238
|
|
562
|
-
],
|
|
563
|
-
"mediumspringgreen": [
|
|
564
|
-
0,
|
|
565
|
-
250,
|
|
566
|
-
154
|
|
567
|
-
],
|
|
568
|
-
"mediumturquoise": [
|
|
569
|
-
72,
|
|
570
|
-
209,
|
|
571
|
-
204
|
|
572
|
-
],
|
|
573
|
-
"mediumvioletred": [
|
|
574
|
-
199,
|
|
575
|
-
21,
|
|
576
|
-
133
|
|
577
|
-
],
|
|
578
|
-
"midnightblue": [
|
|
579
|
-
25,
|
|
580
|
-
25,
|
|
581
|
-
112
|
|
582
|
-
],
|
|
583
|
-
"mintcream": [
|
|
584
|
-
245,
|
|
585
|
-
255,
|
|
586
|
-
250
|
|
587
|
-
],
|
|
588
|
-
"mistyrose": [
|
|
589
|
-
255,
|
|
590
|
-
228,
|
|
591
|
-
225
|
|
592
|
-
],
|
|
593
|
-
"moccasin": [
|
|
594
|
-
255,
|
|
595
|
-
228,
|
|
596
|
-
181
|
|
597
|
-
],
|
|
598
|
-
"navajowhite": [
|
|
599
|
-
255,
|
|
600
|
-
222,
|
|
601
|
-
173
|
|
602
|
-
],
|
|
603
|
-
"navy": [
|
|
604
|
-
0,
|
|
605
|
-
0,
|
|
606
|
-
128
|
|
607
|
-
],
|
|
608
|
-
"oldlace": [
|
|
609
|
-
253,
|
|
610
|
-
245,
|
|
611
|
-
230
|
|
612
|
-
],
|
|
613
|
-
"olive": [
|
|
614
|
-
128,
|
|
615
|
-
128,
|
|
616
|
-
0
|
|
617
|
-
],
|
|
618
|
-
"olivedrab": [
|
|
619
|
-
107,
|
|
620
|
-
142,
|
|
621
|
-
35
|
|
622
|
-
],
|
|
623
|
-
"orange": [
|
|
624
|
-
255,
|
|
625
|
-
165,
|
|
626
|
-
0
|
|
627
|
-
],
|
|
628
|
-
"orangered": [
|
|
629
|
-
255,
|
|
630
|
-
69,
|
|
631
|
-
0
|
|
632
|
-
],
|
|
633
|
-
"orchid": [
|
|
634
|
-
218,
|
|
635
|
-
112,
|
|
636
|
-
214
|
|
637
|
-
],
|
|
638
|
-
"palegoldenrod": [
|
|
639
|
-
238,
|
|
640
|
-
232,
|
|
641
|
-
170
|
|
642
|
-
],
|
|
643
|
-
"palegreen": [
|
|
644
|
-
152,
|
|
645
|
-
251,
|
|
646
|
-
152
|
|
647
|
-
],
|
|
648
|
-
"paleturquoise": [
|
|
649
|
-
175,
|
|
650
|
-
238,
|
|
651
|
-
238
|
|
652
|
-
],
|
|
653
|
-
"palevioletred": [
|
|
654
|
-
219,
|
|
655
|
-
112,
|
|
656
|
-
147
|
|
657
|
-
],
|
|
658
|
-
"papayawhip": [
|
|
659
|
-
255,
|
|
660
|
-
239,
|
|
661
|
-
213
|
|
662
|
-
],
|
|
663
|
-
"peachpuff": [
|
|
664
|
-
255,
|
|
665
|
-
218,
|
|
666
|
-
185
|
|
667
|
-
],
|
|
668
|
-
"peru": [
|
|
669
|
-
205,
|
|
670
|
-
133,
|
|
671
|
-
63
|
|
672
|
-
],
|
|
673
|
-
"pink": [
|
|
674
|
-
255,
|
|
675
|
-
192,
|
|
676
|
-
203
|
|
677
|
-
],
|
|
678
|
-
"plum": [
|
|
679
|
-
221,
|
|
680
|
-
160,
|
|
681
|
-
221
|
|
682
|
-
],
|
|
683
|
-
"powderblue": [
|
|
684
|
-
176,
|
|
685
|
-
224,
|
|
686
|
-
230
|
|
687
|
-
],
|
|
688
|
-
"purple": [
|
|
689
|
-
128,
|
|
690
|
-
0,
|
|
691
|
-
128
|
|
692
|
-
],
|
|
693
|
-
"rebeccapurple": [
|
|
694
|
-
102,
|
|
695
|
-
51,
|
|
696
|
-
153
|
|
697
|
-
],
|
|
698
|
-
"red": [
|
|
699
|
-
255,
|
|
700
|
-
0,
|
|
701
|
-
0
|
|
702
|
-
],
|
|
703
|
-
"rosybrown": [
|
|
704
|
-
188,
|
|
705
|
-
143,
|
|
706
|
-
143
|
|
707
|
-
],
|
|
708
|
-
"royalblue": [
|
|
709
|
-
65,
|
|
710
|
-
105,
|
|
711
|
-
225
|
|
712
|
-
],
|
|
713
|
-
"saddlebrown": [
|
|
714
|
-
139,
|
|
715
|
-
69,
|
|
716
|
-
19
|
|
717
|
-
],
|
|
718
|
-
"salmon": [
|
|
719
|
-
250,
|
|
720
|
-
128,
|
|
721
|
-
114
|
|
722
|
-
],
|
|
723
|
-
"sandybrown": [
|
|
724
|
-
244,
|
|
725
|
-
164,
|
|
726
|
-
96
|
|
727
|
-
],
|
|
728
|
-
"seagreen": [
|
|
729
|
-
46,
|
|
730
|
-
139,
|
|
731
|
-
87
|
|
732
|
-
],
|
|
733
|
-
"seashell": [
|
|
734
|
-
255,
|
|
735
|
-
245,
|
|
736
|
-
238
|
|
737
|
-
],
|
|
738
|
-
"sienna": [
|
|
739
|
-
160,
|
|
740
|
-
82,
|
|
741
|
-
45
|
|
742
|
-
],
|
|
743
|
-
"silver": [
|
|
744
|
-
192,
|
|
745
|
-
192,
|
|
746
|
-
192
|
|
747
|
-
],
|
|
748
|
-
"skyblue": [
|
|
749
|
-
135,
|
|
750
|
-
206,
|
|
751
|
-
235
|
|
752
|
-
],
|
|
753
|
-
"slateblue": [
|
|
754
|
-
106,
|
|
755
|
-
90,
|
|
756
|
-
205
|
|
757
|
-
],
|
|
758
|
-
"slategray": [
|
|
759
|
-
112,
|
|
760
|
-
128,
|
|
761
|
-
144
|
|
762
|
-
],
|
|
763
|
-
"slategrey": [
|
|
764
|
-
112,
|
|
765
|
-
128,
|
|
766
|
-
144
|
|
767
|
-
],
|
|
768
|
-
"snow": [
|
|
769
|
-
255,
|
|
770
|
-
250,
|
|
771
|
-
250
|
|
772
|
-
],
|
|
773
|
-
"springgreen": [
|
|
774
|
-
0,
|
|
775
|
-
255,
|
|
776
|
-
127
|
|
777
|
-
],
|
|
778
|
-
"steelblue": [
|
|
779
|
-
70,
|
|
780
|
-
130,
|
|
781
|
-
180
|
|
782
|
-
],
|
|
783
|
-
"tan": [
|
|
784
|
-
210,
|
|
785
|
-
180,
|
|
786
|
-
140
|
|
787
|
-
],
|
|
788
|
-
"teal": [
|
|
789
|
-
0,
|
|
790
|
-
128,
|
|
791
|
-
128
|
|
792
|
-
],
|
|
793
|
-
"thistle": [
|
|
794
|
-
216,
|
|
795
|
-
191,
|
|
796
|
-
216
|
|
797
|
-
],
|
|
798
|
-
"tomato": [
|
|
799
|
-
255,
|
|
800
|
-
99,
|
|
801
|
-
71
|
|
802
|
-
],
|
|
803
|
-
"turquoise": [
|
|
804
|
-
64,
|
|
805
|
-
224,
|
|
806
|
-
208
|
|
807
|
-
],
|
|
808
|
-
"violet": [
|
|
809
|
-
238,
|
|
810
|
-
130,
|
|
811
|
-
238
|
|
812
|
-
],
|
|
813
|
-
"wheat": [
|
|
814
|
-
245,
|
|
815
|
-
222,
|
|
816
|
-
179
|
|
817
|
-
],
|
|
818
|
-
"white": [
|
|
819
|
-
255,
|
|
820
|
-
255,
|
|
821
|
-
255
|
|
822
|
-
],
|
|
823
|
-
"whitesmoke": [
|
|
824
|
-
245,
|
|
825
|
-
245,
|
|
826
|
-
245
|
|
827
|
-
],
|
|
828
|
-
"yellow": [
|
|
829
|
-
255,
|
|
830
|
-
255,
|
|
831
|
-
0
|
|
832
|
-
],
|
|
833
|
-
"yellowgreen": [
|
|
834
|
-
154,
|
|
835
|
-
205,
|
|
836
|
-
50
|
|
837
|
-
]
|
|
838
|
-
};
|
|
839
|
-
}));
|
|
840
|
-
//#endregion
|
|
841
|
-
//#region node_modules/color-convert/conversions.js
|
|
842
|
-
var require_conversions = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
843
|
-
var cssKeywords = require_color_name();
|
|
844
|
-
var reverseKeywords = {};
|
|
845
|
-
for (const key of Object.keys(cssKeywords)) reverseKeywords[cssKeywords[key]] = key;
|
|
846
|
-
var convert = {
|
|
847
|
-
rgb: {
|
|
848
|
-
channels: 3,
|
|
849
|
-
labels: "rgb"
|
|
850
|
-
},
|
|
851
|
-
hsl: {
|
|
852
|
-
channels: 3,
|
|
853
|
-
labels: "hsl"
|
|
854
|
-
},
|
|
855
|
-
hsv: {
|
|
856
|
-
channels: 3,
|
|
857
|
-
labels: "hsv"
|
|
858
|
-
},
|
|
859
|
-
hwb: {
|
|
860
|
-
channels: 3,
|
|
861
|
-
labels: "hwb"
|
|
862
|
-
},
|
|
863
|
-
cmyk: {
|
|
864
|
-
channels: 4,
|
|
865
|
-
labels: "cmyk"
|
|
866
|
-
},
|
|
867
|
-
xyz: {
|
|
868
|
-
channels: 3,
|
|
869
|
-
labels: "xyz"
|
|
870
|
-
},
|
|
871
|
-
lab: {
|
|
872
|
-
channels: 3,
|
|
873
|
-
labels: "lab"
|
|
874
|
-
},
|
|
875
|
-
lch: {
|
|
876
|
-
channels: 3,
|
|
877
|
-
labels: "lch"
|
|
878
|
-
},
|
|
879
|
-
hex: {
|
|
880
|
-
channels: 1,
|
|
881
|
-
labels: ["hex"]
|
|
882
|
-
},
|
|
883
|
-
keyword: {
|
|
884
|
-
channels: 1,
|
|
885
|
-
labels: ["keyword"]
|
|
886
|
-
},
|
|
887
|
-
ansi16: {
|
|
888
|
-
channels: 1,
|
|
889
|
-
labels: ["ansi16"]
|
|
890
|
-
},
|
|
891
|
-
ansi256: {
|
|
892
|
-
channels: 1,
|
|
893
|
-
labels: ["ansi256"]
|
|
894
|
-
},
|
|
895
|
-
hcg: {
|
|
896
|
-
channels: 3,
|
|
897
|
-
labels: [
|
|
898
|
-
"h",
|
|
899
|
-
"c",
|
|
900
|
-
"g"
|
|
901
|
-
]
|
|
902
|
-
},
|
|
903
|
-
apple: {
|
|
904
|
-
channels: 3,
|
|
905
|
-
labels: [
|
|
906
|
-
"r16",
|
|
907
|
-
"g16",
|
|
908
|
-
"b16"
|
|
909
|
-
]
|
|
910
|
-
},
|
|
911
|
-
gray: {
|
|
912
|
-
channels: 1,
|
|
913
|
-
labels: ["gray"]
|
|
914
|
-
}
|
|
915
|
-
};
|
|
916
|
-
module.exports = convert;
|
|
917
|
-
for (const model of Object.keys(convert)) {
|
|
918
|
-
if (!("channels" in convert[model])) throw new Error("missing channels property: " + model);
|
|
919
|
-
if (!("labels" in convert[model])) throw new Error("missing channel labels property: " + model);
|
|
920
|
-
if (convert[model].labels.length !== convert[model].channels) throw new Error("channel and label counts mismatch: " + model);
|
|
921
|
-
const { channels, labels } = convert[model];
|
|
922
|
-
delete convert[model].channels;
|
|
923
|
-
delete convert[model].labels;
|
|
924
|
-
Object.defineProperty(convert[model], "channels", { value: channels });
|
|
925
|
-
Object.defineProperty(convert[model], "labels", { value: labels });
|
|
926
|
-
}
|
|
927
|
-
convert.rgb.hsl = function(rgb) {
|
|
928
|
-
const r = rgb[0] / 255;
|
|
929
|
-
const g = rgb[1] / 255;
|
|
930
|
-
const b = rgb[2] / 255;
|
|
931
|
-
const min = Math.min(r, g, b);
|
|
932
|
-
const max = Math.max(r, g, b);
|
|
933
|
-
const delta = max - min;
|
|
934
|
-
let h;
|
|
935
|
-
let s;
|
|
936
|
-
if (max === min) h = 0;
|
|
937
|
-
else if (r === max) h = (g - b) / delta;
|
|
938
|
-
else if (g === max) h = 2 + (b - r) / delta;
|
|
939
|
-
else if (b === max) h = 4 + (r - g) / delta;
|
|
940
|
-
h = Math.min(h * 60, 360);
|
|
941
|
-
if (h < 0) h += 360;
|
|
942
|
-
const l = (min + max) / 2;
|
|
943
|
-
if (max === min) s = 0;
|
|
944
|
-
else if (l <= .5) s = delta / (max + min);
|
|
945
|
-
else s = delta / (2 - max - min);
|
|
946
|
-
return [
|
|
947
|
-
h,
|
|
948
|
-
s * 100,
|
|
949
|
-
l * 100
|
|
950
|
-
];
|
|
951
|
-
};
|
|
952
|
-
convert.rgb.hsv = function(rgb) {
|
|
953
|
-
let rdif;
|
|
954
|
-
let gdif;
|
|
955
|
-
let bdif;
|
|
956
|
-
let h;
|
|
957
|
-
let s;
|
|
958
|
-
const r = rgb[0] / 255;
|
|
959
|
-
const g = rgb[1] / 255;
|
|
960
|
-
const b = rgb[2] / 255;
|
|
961
|
-
const v = Math.max(r, g, b);
|
|
962
|
-
const diff = v - Math.min(r, g, b);
|
|
963
|
-
const diffc = function(c) {
|
|
964
|
-
return (v - c) / 6 / diff + 1 / 2;
|
|
965
|
-
};
|
|
966
|
-
if (diff === 0) {
|
|
967
|
-
h = 0;
|
|
968
|
-
s = 0;
|
|
969
|
-
} else {
|
|
970
|
-
s = diff / v;
|
|
971
|
-
rdif = diffc(r);
|
|
972
|
-
gdif = diffc(g);
|
|
973
|
-
bdif = diffc(b);
|
|
974
|
-
if (r === v) h = bdif - gdif;
|
|
975
|
-
else if (g === v) h = 1 / 3 + rdif - bdif;
|
|
976
|
-
else if (b === v) h = 2 / 3 + gdif - rdif;
|
|
977
|
-
if (h < 0) h += 1;
|
|
978
|
-
else if (h > 1) h -= 1;
|
|
979
|
-
}
|
|
980
|
-
return [
|
|
981
|
-
h * 360,
|
|
982
|
-
s * 100,
|
|
983
|
-
v * 100
|
|
984
|
-
];
|
|
985
|
-
};
|
|
986
|
-
convert.rgb.hwb = function(rgb) {
|
|
987
|
-
const r = rgb[0];
|
|
988
|
-
const g = rgb[1];
|
|
989
|
-
let b = rgb[2];
|
|
990
|
-
const h = convert.rgb.hsl(rgb)[0];
|
|
991
|
-
const w = 1 / 255 * Math.min(r, Math.min(g, b));
|
|
992
|
-
b = 1 - 1 / 255 * Math.max(r, Math.max(g, b));
|
|
993
|
-
return [
|
|
994
|
-
h,
|
|
995
|
-
w * 100,
|
|
996
|
-
b * 100
|
|
997
|
-
];
|
|
998
|
-
};
|
|
999
|
-
convert.rgb.cmyk = function(rgb) {
|
|
1000
|
-
const r = rgb[0] / 255;
|
|
1001
|
-
const g = rgb[1] / 255;
|
|
1002
|
-
const b = rgb[2] / 255;
|
|
1003
|
-
const k = Math.min(1 - r, 1 - g, 1 - b);
|
|
1004
|
-
const c = (1 - r - k) / (1 - k) || 0;
|
|
1005
|
-
const m = (1 - g - k) / (1 - k) || 0;
|
|
1006
|
-
const y = (1 - b - k) / (1 - k) || 0;
|
|
1007
|
-
return [
|
|
1008
|
-
c * 100,
|
|
1009
|
-
m * 100,
|
|
1010
|
-
y * 100,
|
|
1011
|
-
k * 100
|
|
1012
|
-
];
|
|
1013
|
-
};
|
|
1014
|
-
function comparativeDistance(x, y) {
|
|
1015
|
-
return (x[0] - y[0]) ** 2 + (x[1] - y[1]) ** 2 + (x[2] - y[2]) ** 2;
|
|
1016
|
-
}
|
|
1017
|
-
convert.rgb.keyword = function(rgb) {
|
|
1018
|
-
const reversed = reverseKeywords[rgb];
|
|
1019
|
-
if (reversed) return reversed;
|
|
1020
|
-
let currentClosestDistance = Infinity;
|
|
1021
|
-
let currentClosestKeyword;
|
|
1022
|
-
for (const keyword of Object.keys(cssKeywords)) {
|
|
1023
|
-
const value = cssKeywords[keyword];
|
|
1024
|
-
const distance = comparativeDistance(rgb, value);
|
|
1025
|
-
if (distance < currentClosestDistance) {
|
|
1026
|
-
currentClosestDistance = distance;
|
|
1027
|
-
currentClosestKeyword = keyword;
|
|
1028
|
-
}
|
|
1029
|
-
}
|
|
1030
|
-
return currentClosestKeyword;
|
|
1031
|
-
};
|
|
1032
|
-
convert.keyword.rgb = function(keyword) {
|
|
1033
|
-
return cssKeywords[keyword];
|
|
1034
|
-
};
|
|
1035
|
-
convert.rgb.xyz = function(rgb) {
|
|
1036
|
-
let r = rgb[0] / 255;
|
|
1037
|
-
let g = rgb[1] / 255;
|
|
1038
|
-
let b = rgb[2] / 255;
|
|
1039
|
-
r = r > .04045 ? ((r + .055) / 1.055) ** 2.4 : r / 12.92;
|
|
1040
|
-
g = g > .04045 ? ((g + .055) / 1.055) ** 2.4 : g / 12.92;
|
|
1041
|
-
b = b > .04045 ? ((b + .055) / 1.055) ** 2.4 : b / 12.92;
|
|
1042
|
-
const x = r * .4124 + g * .3576 + b * .1805;
|
|
1043
|
-
const y = r * .2126 + g * .7152 + b * .0722;
|
|
1044
|
-
const z = r * .0193 + g * .1192 + b * .9505;
|
|
1045
|
-
return [
|
|
1046
|
-
x * 100,
|
|
1047
|
-
y * 100,
|
|
1048
|
-
z * 100
|
|
1049
|
-
];
|
|
1050
|
-
};
|
|
1051
|
-
convert.rgb.lab = function(rgb) {
|
|
1052
|
-
const xyz = convert.rgb.xyz(rgb);
|
|
1053
|
-
let x = xyz[0];
|
|
1054
|
-
let y = xyz[1];
|
|
1055
|
-
let z = xyz[2];
|
|
1056
|
-
x /= 95.047;
|
|
1057
|
-
y /= 100;
|
|
1058
|
-
z /= 108.883;
|
|
1059
|
-
x = x > .008856 ? x ** (1 / 3) : 7.787 * x + 16 / 116;
|
|
1060
|
-
y = y > .008856 ? y ** (1 / 3) : 7.787 * y + 16 / 116;
|
|
1061
|
-
z = z > .008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116;
|
|
1062
|
-
return [
|
|
1063
|
-
116 * y - 16,
|
|
1064
|
-
500 * (x - y),
|
|
1065
|
-
200 * (y - z)
|
|
1066
|
-
];
|
|
1067
|
-
};
|
|
1068
|
-
convert.hsl.rgb = function(hsl) {
|
|
1069
|
-
const h = hsl[0] / 360;
|
|
1070
|
-
const s = hsl[1] / 100;
|
|
1071
|
-
const l = hsl[2] / 100;
|
|
1072
|
-
let t2;
|
|
1073
|
-
let t3;
|
|
1074
|
-
let val;
|
|
1075
|
-
if (s === 0) {
|
|
1076
|
-
val = l * 255;
|
|
1077
|
-
return [
|
|
1078
|
-
val,
|
|
1079
|
-
val,
|
|
1080
|
-
val
|
|
1081
|
-
];
|
|
1082
|
-
}
|
|
1083
|
-
if (l < .5) t2 = l * (1 + s);
|
|
1084
|
-
else t2 = l + s - l * s;
|
|
1085
|
-
const t1 = 2 * l - t2;
|
|
1086
|
-
const rgb = [
|
|
1087
|
-
0,
|
|
1088
|
-
0,
|
|
1089
|
-
0
|
|
1090
|
-
];
|
|
1091
|
-
for (let i = 0; i < 3; i++) {
|
|
1092
|
-
t3 = h + 1 / 3 * -(i - 1);
|
|
1093
|
-
if (t3 < 0) t3++;
|
|
1094
|
-
if (t3 > 1) t3--;
|
|
1095
|
-
if (6 * t3 < 1) val = t1 + (t2 - t1) * 6 * t3;
|
|
1096
|
-
else if (2 * t3 < 1) val = t2;
|
|
1097
|
-
else if (3 * t3 < 2) val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;
|
|
1098
|
-
else val = t1;
|
|
1099
|
-
rgb[i] = val * 255;
|
|
1100
|
-
}
|
|
1101
|
-
return rgb;
|
|
1102
|
-
};
|
|
1103
|
-
convert.hsl.hsv = function(hsl) {
|
|
1104
|
-
const h = hsl[0];
|
|
1105
|
-
let s = hsl[1] / 100;
|
|
1106
|
-
let l = hsl[2] / 100;
|
|
1107
|
-
let smin = s;
|
|
1108
|
-
const lmin = Math.max(l, .01);
|
|
1109
|
-
l *= 2;
|
|
1110
|
-
s *= l <= 1 ? l : 2 - l;
|
|
1111
|
-
smin *= lmin <= 1 ? lmin : 2 - lmin;
|
|
1112
|
-
const v = (l + s) / 2;
|
|
1113
|
-
return [
|
|
1114
|
-
h,
|
|
1115
|
-
(l === 0 ? 2 * smin / (lmin + smin) : 2 * s / (l + s)) * 100,
|
|
1116
|
-
v * 100
|
|
1117
|
-
];
|
|
1118
|
-
};
|
|
1119
|
-
convert.hsv.rgb = function(hsv) {
|
|
1120
|
-
const h = hsv[0] / 60;
|
|
1121
|
-
const s = hsv[1] / 100;
|
|
1122
|
-
let v = hsv[2] / 100;
|
|
1123
|
-
const hi = Math.floor(h) % 6;
|
|
1124
|
-
const f = h - Math.floor(h);
|
|
1125
|
-
const p = 255 * v * (1 - s);
|
|
1126
|
-
const q = 255 * v * (1 - s * f);
|
|
1127
|
-
const t = 255 * v * (1 - s * (1 - f));
|
|
1128
|
-
v *= 255;
|
|
1129
|
-
switch (hi) {
|
|
1130
|
-
case 0: return [
|
|
1131
|
-
v,
|
|
1132
|
-
t,
|
|
1133
|
-
p
|
|
1134
|
-
];
|
|
1135
|
-
case 1: return [
|
|
1136
|
-
q,
|
|
1137
|
-
v,
|
|
1138
|
-
p
|
|
1139
|
-
];
|
|
1140
|
-
case 2: return [
|
|
1141
|
-
p,
|
|
1142
|
-
v,
|
|
1143
|
-
t
|
|
1144
|
-
];
|
|
1145
|
-
case 3: return [
|
|
1146
|
-
p,
|
|
1147
|
-
q,
|
|
1148
|
-
v
|
|
1149
|
-
];
|
|
1150
|
-
case 4: return [
|
|
1151
|
-
t,
|
|
1152
|
-
p,
|
|
1153
|
-
v
|
|
1154
|
-
];
|
|
1155
|
-
case 5: return [
|
|
1156
|
-
v,
|
|
1157
|
-
p,
|
|
1158
|
-
q
|
|
1159
|
-
];
|
|
1160
|
-
}
|
|
1161
|
-
};
|
|
1162
|
-
convert.hsv.hsl = function(hsv) {
|
|
1163
|
-
const h = hsv[0];
|
|
1164
|
-
const s = hsv[1] / 100;
|
|
1165
|
-
const v = hsv[2] / 100;
|
|
1166
|
-
const vmin = Math.max(v, .01);
|
|
1167
|
-
let sl;
|
|
1168
|
-
let l;
|
|
1169
|
-
l = (2 - s) * v;
|
|
1170
|
-
const lmin = (2 - s) * vmin;
|
|
1171
|
-
sl = s * vmin;
|
|
1172
|
-
sl /= lmin <= 1 ? lmin : 2 - lmin;
|
|
1173
|
-
sl = sl || 0;
|
|
1174
|
-
l /= 2;
|
|
1175
|
-
return [
|
|
1176
|
-
h,
|
|
1177
|
-
sl * 100,
|
|
1178
|
-
l * 100
|
|
1179
|
-
];
|
|
1180
|
-
};
|
|
1181
|
-
convert.hwb.rgb = function(hwb) {
|
|
1182
|
-
const h = hwb[0] / 360;
|
|
1183
|
-
let wh = hwb[1] / 100;
|
|
1184
|
-
let bl = hwb[2] / 100;
|
|
1185
|
-
const ratio = wh + bl;
|
|
1186
|
-
let f;
|
|
1187
|
-
if (ratio > 1) {
|
|
1188
|
-
wh /= ratio;
|
|
1189
|
-
bl /= ratio;
|
|
1190
|
-
}
|
|
1191
|
-
const i = Math.floor(6 * h);
|
|
1192
|
-
const v = 1 - bl;
|
|
1193
|
-
f = 6 * h - i;
|
|
1194
|
-
if ((i & 1) !== 0) f = 1 - f;
|
|
1195
|
-
const n = wh + f * (v - wh);
|
|
1196
|
-
let r;
|
|
1197
|
-
let g;
|
|
1198
|
-
let b;
|
|
1199
|
-
switch (i) {
|
|
1200
|
-
default:
|
|
1201
|
-
case 6:
|
|
1202
|
-
case 0:
|
|
1203
|
-
r = v;
|
|
1204
|
-
g = n;
|
|
1205
|
-
b = wh;
|
|
1206
|
-
break;
|
|
1207
|
-
case 1:
|
|
1208
|
-
r = n;
|
|
1209
|
-
g = v;
|
|
1210
|
-
b = wh;
|
|
1211
|
-
break;
|
|
1212
|
-
case 2:
|
|
1213
|
-
r = wh;
|
|
1214
|
-
g = v;
|
|
1215
|
-
b = n;
|
|
1216
|
-
break;
|
|
1217
|
-
case 3:
|
|
1218
|
-
r = wh;
|
|
1219
|
-
g = n;
|
|
1220
|
-
b = v;
|
|
1221
|
-
break;
|
|
1222
|
-
case 4:
|
|
1223
|
-
r = n;
|
|
1224
|
-
g = wh;
|
|
1225
|
-
b = v;
|
|
1226
|
-
break;
|
|
1227
|
-
case 5:
|
|
1228
|
-
r = v;
|
|
1229
|
-
g = wh;
|
|
1230
|
-
b = n;
|
|
1231
|
-
break;
|
|
1232
|
-
}
|
|
1233
|
-
return [
|
|
1234
|
-
r * 255,
|
|
1235
|
-
g * 255,
|
|
1236
|
-
b * 255
|
|
1237
|
-
];
|
|
1238
|
-
};
|
|
1239
|
-
convert.cmyk.rgb = function(cmyk) {
|
|
1240
|
-
const c = cmyk[0] / 100;
|
|
1241
|
-
const m = cmyk[1] / 100;
|
|
1242
|
-
const y = cmyk[2] / 100;
|
|
1243
|
-
const k = cmyk[3] / 100;
|
|
1244
|
-
const r = 1 - Math.min(1, c * (1 - k) + k);
|
|
1245
|
-
const g = 1 - Math.min(1, m * (1 - k) + k);
|
|
1246
|
-
const b = 1 - Math.min(1, y * (1 - k) + k);
|
|
1247
|
-
return [
|
|
1248
|
-
r * 255,
|
|
1249
|
-
g * 255,
|
|
1250
|
-
b * 255
|
|
1251
|
-
];
|
|
1252
|
-
};
|
|
1253
|
-
convert.xyz.rgb = function(xyz) {
|
|
1254
|
-
const x = xyz[0] / 100;
|
|
1255
|
-
const y = xyz[1] / 100;
|
|
1256
|
-
const z = xyz[2] / 100;
|
|
1257
|
-
let r;
|
|
1258
|
-
let g;
|
|
1259
|
-
let b;
|
|
1260
|
-
r = x * 3.2406 + y * -1.5372 + z * -.4986;
|
|
1261
|
-
g = x * -.9689 + y * 1.8758 + z * .0415;
|
|
1262
|
-
b = x * .0557 + y * -.204 + z * 1.057;
|
|
1263
|
-
r = r > .0031308 ? 1.055 * r ** (1 / 2.4) - .055 : r * 12.92;
|
|
1264
|
-
g = g > .0031308 ? 1.055 * g ** (1 / 2.4) - .055 : g * 12.92;
|
|
1265
|
-
b = b > .0031308 ? 1.055 * b ** (1 / 2.4) - .055 : b * 12.92;
|
|
1266
|
-
r = Math.min(Math.max(0, r), 1);
|
|
1267
|
-
g = Math.min(Math.max(0, g), 1);
|
|
1268
|
-
b = Math.min(Math.max(0, b), 1);
|
|
1269
|
-
return [
|
|
1270
|
-
r * 255,
|
|
1271
|
-
g * 255,
|
|
1272
|
-
b * 255
|
|
1273
|
-
];
|
|
1274
|
-
};
|
|
1275
|
-
convert.xyz.lab = function(xyz) {
|
|
1276
|
-
let x = xyz[0];
|
|
1277
|
-
let y = xyz[1];
|
|
1278
|
-
let z = xyz[2];
|
|
1279
|
-
x /= 95.047;
|
|
1280
|
-
y /= 100;
|
|
1281
|
-
z /= 108.883;
|
|
1282
|
-
x = x > .008856 ? x ** (1 / 3) : 7.787 * x + 16 / 116;
|
|
1283
|
-
y = y > .008856 ? y ** (1 / 3) : 7.787 * y + 16 / 116;
|
|
1284
|
-
z = z > .008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116;
|
|
1285
|
-
return [
|
|
1286
|
-
116 * y - 16,
|
|
1287
|
-
500 * (x - y),
|
|
1288
|
-
200 * (y - z)
|
|
1289
|
-
];
|
|
1290
|
-
};
|
|
1291
|
-
convert.lab.xyz = function(lab) {
|
|
1292
|
-
const l = lab[0];
|
|
1293
|
-
const a = lab[1];
|
|
1294
|
-
const b = lab[2];
|
|
1295
|
-
let x;
|
|
1296
|
-
let y;
|
|
1297
|
-
let z;
|
|
1298
|
-
y = (l + 16) / 116;
|
|
1299
|
-
x = a / 500 + y;
|
|
1300
|
-
z = y - b / 200;
|
|
1301
|
-
const y2 = y ** 3;
|
|
1302
|
-
const x2 = x ** 3;
|
|
1303
|
-
const z2 = z ** 3;
|
|
1304
|
-
y = y2 > .008856 ? y2 : (y - 16 / 116) / 7.787;
|
|
1305
|
-
x = x2 > .008856 ? x2 : (x - 16 / 116) / 7.787;
|
|
1306
|
-
z = z2 > .008856 ? z2 : (z - 16 / 116) / 7.787;
|
|
1307
|
-
x *= 95.047;
|
|
1308
|
-
y *= 100;
|
|
1309
|
-
z *= 108.883;
|
|
1310
|
-
return [
|
|
1311
|
-
x,
|
|
1312
|
-
y,
|
|
1313
|
-
z
|
|
1314
|
-
];
|
|
1315
|
-
};
|
|
1316
|
-
convert.lab.lch = function(lab) {
|
|
1317
|
-
const l = lab[0];
|
|
1318
|
-
const a = lab[1];
|
|
1319
|
-
const b = lab[2];
|
|
1320
|
-
let h;
|
|
1321
|
-
h = Math.atan2(b, a) * 360 / 2 / Math.PI;
|
|
1322
|
-
if (h < 0) h += 360;
|
|
1323
|
-
return [
|
|
1324
|
-
l,
|
|
1325
|
-
Math.sqrt(a * a + b * b),
|
|
1326
|
-
h
|
|
1327
|
-
];
|
|
1328
|
-
};
|
|
1329
|
-
convert.lch.lab = function(lch) {
|
|
1330
|
-
const l = lch[0];
|
|
1331
|
-
const c = lch[1];
|
|
1332
|
-
const hr = lch[2] / 360 * 2 * Math.PI;
|
|
1333
|
-
return [
|
|
1334
|
-
l,
|
|
1335
|
-
c * Math.cos(hr),
|
|
1336
|
-
c * Math.sin(hr)
|
|
1337
|
-
];
|
|
1338
|
-
};
|
|
1339
|
-
convert.rgb.ansi16 = function(args, saturation = null) {
|
|
1340
|
-
const [r, g, b] = args;
|
|
1341
|
-
let value = saturation === null ? convert.rgb.hsv(args)[2] : saturation;
|
|
1342
|
-
value = Math.round(value / 50);
|
|
1343
|
-
if (value === 0) return 30;
|
|
1344
|
-
let ansi = 30 + (Math.round(b / 255) << 2 | Math.round(g / 255) << 1 | Math.round(r / 255));
|
|
1345
|
-
if (value === 2) ansi += 60;
|
|
1346
|
-
return ansi;
|
|
1347
|
-
};
|
|
1348
|
-
convert.hsv.ansi16 = function(args) {
|
|
1349
|
-
return convert.rgb.ansi16(convert.hsv.rgb(args), args[2]);
|
|
1350
|
-
};
|
|
1351
|
-
convert.rgb.ansi256 = function(args) {
|
|
1352
|
-
const r = args[0];
|
|
1353
|
-
const g = args[1];
|
|
1354
|
-
const b = args[2];
|
|
1355
|
-
if (r === g && g === b) {
|
|
1356
|
-
if (r < 8) return 16;
|
|
1357
|
-
if (r > 248) return 231;
|
|
1358
|
-
return Math.round((r - 8) / 247 * 24) + 232;
|
|
1359
|
-
}
|
|
1360
|
-
return 16 + 36 * Math.round(r / 255 * 5) + 6 * Math.round(g / 255 * 5) + Math.round(b / 255 * 5);
|
|
1361
|
-
};
|
|
1362
|
-
convert.ansi16.rgb = function(args) {
|
|
1363
|
-
let color = args % 10;
|
|
1364
|
-
if (color === 0 || color === 7) {
|
|
1365
|
-
if (args > 50) color += 3.5;
|
|
1366
|
-
color = color / 10.5 * 255;
|
|
1367
|
-
return [
|
|
1368
|
-
color,
|
|
1369
|
-
color,
|
|
1370
|
-
color
|
|
1371
|
-
];
|
|
1372
|
-
}
|
|
1373
|
-
const mult = (~~(args > 50) + 1) * .5;
|
|
1374
|
-
return [
|
|
1375
|
-
(color & 1) * mult * 255,
|
|
1376
|
-
(color >> 1 & 1) * mult * 255,
|
|
1377
|
-
(color >> 2 & 1) * mult * 255
|
|
1378
|
-
];
|
|
1379
|
-
};
|
|
1380
|
-
convert.ansi256.rgb = function(args) {
|
|
1381
|
-
if (args >= 232) {
|
|
1382
|
-
const c = (args - 232) * 10 + 8;
|
|
1383
|
-
return [
|
|
1384
|
-
c,
|
|
1385
|
-
c,
|
|
1386
|
-
c
|
|
1387
|
-
];
|
|
1388
|
-
}
|
|
1389
|
-
args -= 16;
|
|
1390
|
-
let rem;
|
|
1391
|
-
return [
|
|
1392
|
-
Math.floor(args / 36) / 5 * 255,
|
|
1393
|
-
Math.floor((rem = args % 36) / 6) / 5 * 255,
|
|
1394
|
-
rem % 6 / 5 * 255
|
|
1395
|
-
];
|
|
1396
|
-
};
|
|
1397
|
-
convert.rgb.hex = function(args) {
|
|
1398
|
-
const string = (((Math.round(args[0]) & 255) << 16) + ((Math.round(args[1]) & 255) << 8) + (Math.round(args[2]) & 255)).toString(16).toUpperCase();
|
|
1399
|
-
return "000000".substring(string.length) + string;
|
|
1400
|
-
};
|
|
1401
|
-
convert.hex.rgb = function(args) {
|
|
1402
|
-
const match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);
|
|
1403
|
-
if (!match) return [
|
|
1404
|
-
0,
|
|
1405
|
-
0,
|
|
1406
|
-
0
|
|
1407
|
-
];
|
|
1408
|
-
let colorString = match[0];
|
|
1409
|
-
if (match[0].length === 3) colorString = colorString.split("").map((char) => {
|
|
1410
|
-
return char + char;
|
|
1411
|
-
}).join("");
|
|
1412
|
-
const integer = parseInt(colorString, 16);
|
|
1413
|
-
return [
|
|
1414
|
-
integer >> 16 & 255,
|
|
1415
|
-
integer >> 8 & 255,
|
|
1416
|
-
integer & 255
|
|
1417
|
-
];
|
|
1418
|
-
};
|
|
1419
|
-
convert.rgb.hcg = function(rgb) {
|
|
1420
|
-
const r = rgb[0] / 255;
|
|
1421
|
-
const g = rgb[1] / 255;
|
|
1422
|
-
const b = rgb[2] / 255;
|
|
1423
|
-
const max = Math.max(Math.max(r, g), b);
|
|
1424
|
-
const min = Math.min(Math.min(r, g), b);
|
|
1425
|
-
const chroma = max - min;
|
|
1426
|
-
let grayscale;
|
|
1427
|
-
let hue;
|
|
1428
|
-
if (chroma < 1) grayscale = min / (1 - chroma);
|
|
1429
|
-
else grayscale = 0;
|
|
1430
|
-
if (chroma <= 0) hue = 0;
|
|
1431
|
-
else if (max === r) hue = (g - b) / chroma % 6;
|
|
1432
|
-
else if (max === g) hue = 2 + (b - r) / chroma;
|
|
1433
|
-
else hue = 4 + (r - g) / chroma;
|
|
1434
|
-
hue /= 6;
|
|
1435
|
-
hue %= 1;
|
|
1436
|
-
return [
|
|
1437
|
-
hue * 360,
|
|
1438
|
-
chroma * 100,
|
|
1439
|
-
grayscale * 100
|
|
1440
|
-
];
|
|
1441
|
-
};
|
|
1442
|
-
convert.hsl.hcg = function(hsl) {
|
|
1443
|
-
const s = hsl[1] / 100;
|
|
1444
|
-
const l = hsl[2] / 100;
|
|
1445
|
-
const c = l < .5 ? 2 * s * l : 2 * s * (1 - l);
|
|
1446
|
-
let f = 0;
|
|
1447
|
-
if (c < 1) f = (l - .5 * c) / (1 - c);
|
|
1448
|
-
return [
|
|
1449
|
-
hsl[0],
|
|
1450
|
-
c * 100,
|
|
1451
|
-
f * 100
|
|
1452
|
-
];
|
|
1453
|
-
};
|
|
1454
|
-
convert.hsv.hcg = function(hsv) {
|
|
1455
|
-
const s = hsv[1] / 100;
|
|
1456
|
-
const v = hsv[2] / 100;
|
|
1457
|
-
const c = s * v;
|
|
1458
|
-
let f = 0;
|
|
1459
|
-
if (c < 1) f = (v - c) / (1 - c);
|
|
1460
|
-
return [
|
|
1461
|
-
hsv[0],
|
|
1462
|
-
c * 100,
|
|
1463
|
-
f * 100
|
|
1464
|
-
];
|
|
1465
|
-
};
|
|
1466
|
-
convert.hcg.rgb = function(hcg) {
|
|
1467
|
-
const h = hcg[0] / 360;
|
|
1468
|
-
const c = hcg[1] / 100;
|
|
1469
|
-
const g = hcg[2] / 100;
|
|
1470
|
-
if (c === 0) return [
|
|
1471
|
-
g * 255,
|
|
1472
|
-
g * 255,
|
|
1473
|
-
g * 255
|
|
1474
|
-
];
|
|
1475
|
-
const pure = [
|
|
1476
|
-
0,
|
|
1477
|
-
0,
|
|
1478
|
-
0
|
|
1479
|
-
];
|
|
1480
|
-
const hi = h % 1 * 6;
|
|
1481
|
-
const v = hi % 1;
|
|
1482
|
-
const w = 1 - v;
|
|
1483
|
-
let mg = 0;
|
|
1484
|
-
switch (Math.floor(hi)) {
|
|
1485
|
-
case 0:
|
|
1486
|
-
pure[0] = 1;
|
|
1487
|
-
pure[1] = v;
|
|
1488
|
-
pure[2] = 0;
|
|
1489
|
-
break;
|
|
1490
|
-
case 1:
|
|
1491
|
-
pure[0] = w;
|
|
1492
|
-
pure[1] = 1;
|
|
1493
|
-
pure[2] = 0;
|
|
1494
|
-
break;
|
|
1495
|
-
case 2:
|
|
1496
|
-
pure[0] = 0;
|
|
1497
|
-
pure[1] = 1;
|
|
1498
|
-
pure[2] = v;
|
|
1499
|
-
break;
|
|
1500
|
-
case 3:
|
|
1501
|
-
pure[0] = 0;
|
|
1502
|
-
pure[1] = w;
|
|
1503
|
-
pure[2] = 1;
|
|
1504
|
-
break;
|
|
1505
|
-
case 4:
|
|
1506
|
-
pure[0] = v;
|
|
1507
|
-
pure[1] = 0;
|
|
1508
|
-
pure[2] = 1;
|
|
1509
|
-
break;
|
|
1510
|
-
default:
|
|
1511
|
-
pure[0] = 1;
|
|
1512
|
-
pure[1] = 0;
|
|
1513
|
-
pure[2] = w;
|
|
1514
|
-
}
|
|
1515
|
-
mg = (1 - c) * g;
|
|
1516
|
-
return [
|
|
1517
|
-
(c * pure[0] + mg) * 255,
|
|
1518
|
-
(c * pure[1] + mg) * 255,
|
|
1519
|
-
(c * pure[2] + mg) * 255
|
|
1520
|
-
];
|
|
1521
|
-
};
|
|
1522
|
-
convert.hcg.hsv = function(hcg) {
|
|
1523
|
-
const c = hcg[1] / 100;
|
|
1524
|
-
const v = c + hcg[2] / 100 * (1 - c);
|
|
1525
|
-
let f = 0;
|
|
1526
|
-
if (v > 0) f = c / v;
|
|
1527
|
-
return [
|
|
1528
|
-
hcg[0],
|
|
1529
|
-
f * 100,
|
|
1530
|
-
v * 100
|
|
1531
|
-
];
|
|
1532
|
-
};
|
|
1533
|
-
convert.hcg.hsl = function(hcg) {
|
|
1534
|
-
const c = hcg[1] / 100;
|
|
1535
|
-
const l = hcg[2] / 100 * (1 - c) + .5 * c;
|
|
1536
|
-
let s = 0;
|
|
1537
|
-
if (l > 0 && l < .5) s = c / (2 * l);
|
|
1538
|
-
else if (l >= .5 && l < 1) s = c / (2 * (1 - l));
|
|
1539
|
-
return [
|
|
1540
|
-
hcg[0],
|
|
1541
|
-
s * 100,
|
|
1542
|
-
l * 100
|
|
1543
|
-
];
|
|
1544
|
-
};
|
|
1545
|
-
convert.hcg.hwb = function(hcg) {
|
|
1546
|
-
const c = hcg[1] / 100;
|
|
1547
|
-
const v = c + hcg[2] / 100 * (1 - c);
|
|
1548
|
-
return [
|
|
1549
|
-
hcg[0],
|
|
1550
|
-
(v - c) * 100,
|
|
1551
|
-
(1 - v) * 100
|
|
1552
|
-
];
|
|
1553
|
-
};
|
|
1554
|
-
convert.hwb.hcg = function(hwb) {
|
|
1555
|
-
const w = hwb[1] / 100;
|
|
1556
|
-
const v = 1 - hwb[2] / 100;
|
|
1557
|
-
const c = v - w;
|
|
1558
|
-
let g = 0;
|
|
1559
|
-
if (c < 1) g = (v - c) / (1 - c);
|
|
1560
|
-
return [
|
|
1561
|
-
hwb[0],
|
|
1562
|
-
c * 100,
|
|
1563
|
-
g * 100
|
|
1564
|
-
];
|
|
1565
|
-
};
|
|
1566
|
-
convert.apple.rgb = function(apple) {
|
|
1567
|
-
return [
|
|
1568
|
-
apple[0] / 65535 * 255,
|
|
1569
|
-
apple[1] / 65535 * 255,
|
|
1570
|
-
apple[2] / 65535 * 255
|
|
1571
|
-
];
|
|
1572
|
-
};
|
|
1573
|
-
convert.rgb.apple = function(rgb) {
|
|
1574
|
-
return [
|
|
1575
|
-
rgb[0] / 255 * 65535,
|
|
1576
|
-
rgb[1] / 255 * 65535,
|
|
1577
|
-
rgb[2] / 255 * 65535
|
|
1578
|
-
];
|
|
1579
|
-
};
|
|
1580
|
-
convert.gray.rgb = function(args) {
|
|
1581
|
-
return [
|
|
1582
|
-
args[0] / 100 * 255,
|
|
1583
|
-
args[0] / 100 * 255,
|
|
1584
|
-
args[0] / 100 * 255
|
|
1585
|
-
];
|
|
1586
|
-
};
|
|
1587
|
-
convert.gray.hsl = function(args) {
|
|
1588
|
-
return [
|
|
1589
|
-
0,
|
|
1590
|
-
0,
|
|
1591
|
-
args[0]
|
|
1592
|
-
];
|
|
1593
|
-
};
|
|
1594
|
-
convert.gray.hsv = convert.gray.hsl;
|
|
1595
|
-
convert.gray.hwb = function(gray) {
|
|
1596
|
-
return [
|
|
1597
|
-
0,
|
|
1598
|
-
100,
|
|
1599
|
-
gray[0]
|
|
1600
|
-
];
|
|
1601
|
-
};
|
|
1602
|
-
convert.gray.cmyk = function(gray) {
|
|
1603
|
-
return [
|
|
1604
|
-
0,
|
|
1605
|
-
0,
|
|
1606
|
-
0,
|
|
1607
|
-
gray[0]
|
|
1608
|
-
];
|
|
1609
|
-
};
|
|
1610
|
-
convert.gray.lab = function(gray) {
|
|
1611
|
-
return [
|
|
1612
|
-
gray[0],
|
|
1613
|
-
0,
|
|
1614
|
-
0
|
|
1615
|
-
];
|
|
1616
|
-
};
|
|
1617
|
-
convert.gray.hex = function(gray) {
|
|
1618
|
-
const val = Math.round(gray[0] / 100 * 255) & 255;
|
|
1619
|
-
const string = ((val << 16) + (val << 8) + val).toString(16).toUpperCase();
|
|
1620
|
-
return "000000".substring(string.length) + string;
|
|
1621
|
-
};
|
|
1622
|
-
convert.rgb.gray = function(rgb) {
|
|
1623
|
-
return [(rgb[0] + rgb[1] + rgb[2]) / 3 / 255 * 100];
|
|
1624
|
-
};
|
|
1625
|
-
}));
|
|
1626
|
-
//#endregion
|
|
1627
|
-
//#region node_modules/color-convert/route.js
|
|
1628
|
-
var require_route = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
1629
|
-
var conversions = require_conversions();
|
|
1630
|
-
function buildGraph() {
|
|
1631
|
-
const graph = {};
|
|
1632
|
-
const models = Object.keys(conversions);
|
|
1633
|
-
for (let len = models.length, i = 0; i < len; i++) graph[models[i]] = {
|
|
1634
|
-
distance: -1,
|
|
1635
|
-
parent: null
|
|
1636
|
-
};
|
|
1637
|
-
return graph;
|
|
1638
|
-
}
|
|
1639
|
-
function deriveBFS(fromModel) {
|
|
1640
|
-
const graph = buildGraph();
|
|
1641
|
-
const queue = [fromModel];
|
|
1642
|
-
graph[fromModel].distance = 0;
|
|
1643
|
-
while (queue.length) {
|
|
1644
|
-
const current = queue.pop();
|
|
1645
|
-
const adjacents = Object.keys(conversions[current]);
|
|
1646
|
-
for (let len = adjacents.length, i = 0; i < len; i++) {
|
|
1647
|
-
const adjacent = adjacents[i];
|
|
1648
|
-
const node = graph[adjacent];
|
|
1649
|
-
if (node.distance === -1) {
|
|
1650
|
-
node.distance = graph[current].distance + 1;
|
|
1651
|
-
node.parent = current;
|
|
1652
|
-
queue.unshift(adjacent);
|
|
1653
|
-
}
|
|
1654
|
-
}
|
|
1655
|
-
}
|
|
1656
|
-
return graph;
|
|
1657
|
-
}
|
|
1658
|
-
function link(from, to) {
|
|
1659
|
-
return function(args) {
|
|
1660
|
-
return to(from(args));
|
|
1661
|
-
};
|
|
95
|
+
//#region node_modules/chalk/source/vendor/ansi-styles/index.js
|
|
96
|
+
var ANSI_BACKGROUND_OFFSET = 10;
|
|
97
|
+
var wrapAnsi16 = (offset = 0) => (code) => `\u001B[${code + offset}m`;
|
|
98
|
+
var wrapAnsi256 = (offset = 0) => (code) => `\u001B[${38 + offset};5;${code}m`;
|
|
99
|
+
var wrapAnsi16m = (offset = 0) => (red, green, blue) => `\u001B[${38 + offset};2;${red};${green};${blue}m`;
|
|
100
|
+
var styles$1 = {
|
|
101
|
+
modifier: {
|
|
102
|
+
reset: [0, 0],
|
|
103
|
+
bold: [1, 22],
|
|
104
|
+
dim: [2, 22],
|
|
105
|
+
italic: [3, 23],
|
|
106
|
+
underline: [4, 24],
|
|
107
|
+
overline: [53, 55],
|
|
108
|
+
inverse: [7, 27],
|
|
109
|
+
hidden: [8, 28],
|
|
110
|
+
strikethrough: [9, 29]
|
|
111
|
+
},
|
|
112
|
+
color: {
|
|
113
|
+
black: [30, 39],
|
|
114
|
+
red: [31, 39],
|
|
115
|
+
green: [32, 39],
|
|
116
|
+
yellow: [33, 39],
|
|
117
|
+
blue: [34, 39],
|
|
118
|
+
magenta: [35, 39],
|
|
119
|
+
cyan: [36, 39],
|
|
120
|
+
white: [37, 39],
|
|
121
|
+
blackBright: [90, 39],
|
|
122
|
+
gray: [90, 39],
|
|
123
|
+
grey: [90, 39],
|
|
124
|
+
redBright: [91, 39],
|
|
125
|
+
greenBright: [92, 39],
|
|
126
|
+
yellowBright: [93, 39],
|
|
127
|
+
blueBright: [94, 39],
|
|
128
|
+
magentaBright: [95, 39],
|
|
129
|
+
cyanBright: [96, 39],
|
|
130
|
+
whiteBright: [97, 39]
|
|
131
|
+
},
|
|
132
|
+
bgColor: {
|
|
133
|
+
bgBlack: [40, 49],
|
|
134
|
+
bgRed: [41, 49],
|
|
135
|
+
bgGreen: [42, 49],
|
|
136
|
+
bgYellow: [43, 49],
|
|
137
|
+
bgBlue: [44, 49],
|
|
138
|
+
bgMagenta: [45, 49],
|
|
139
|
+
bgCyan: [46, 49],
|
|
140
|
+
bgWhite: [47, 49],
|
|
141
|
+
bgBlackBright: [100, 49],
|
|
142
|
+
bgGray: [100, 49],
|
|
143
|
+
bgGrey: [100, 49],
|
|
144
|
+
bgRedBright: [101, 49],
|
|
145
|
+
bgGreenBright: [102, 49],
|
|
146
|
+
bgYellowBright: [103, 49],
|
|
147
|
+
bgBlueBright: [104, 49],
|
|
148
|
+
bgMagentaBright: [105, 49],
|
|
149
|
+
bgCyanBright: [106, 49],
|
|
150
|
+
bgWhiteBright: [107, 49]
|
|
1662
151
|
}
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
const models = Object.keys(graph);
|
|
1679
|
-
for (let len = models.length, i = 0; i < len; i++) {
|
|
1680
|
-
const toModel = models[i];
|
|
1681
|
-
if (graph[toModel].parent === null) continue;
|
|
1682
|
-
conversion[toModel] = wrapConversion(toModel, graph);
|
|
152
|
+
};
|
|
153
|
+
Object.keys(styles$1.modifier);
|
|
154
|
+
var foregroundColorNames = Object.keys(styles$1.color);
|
|
155
|
+
var backgroundColorNames = Object.keys(styles$1.bgColor);
|
|
156
|
+
[...foregroundColorNames, ...backgroundColorNames];
|
|
157
|
+
function assembleStyles() {
|
|
158
|
+
const codes = /* @__PURE__ */ new Map();
|
|
159
|
+
for (const [groupName, group] of Object.entries(styles$1)) {
|
|
160
|
+
for (const [styleName, style] of Object.entries(group)) {
|
|
161
|
+
styles$1[styleName] = {
|
|
162
|
+
open: `\u001B[${style[0]}m`,
|
|
163
|
+
close: `\u001B[${style[1]}m`
|
|
164
|
+
};
|
|
165
|
+
group[styleName] = styles$1[styleName];
|
|
166
|
+
codes.set(style[0], style[1]);
|
|
1683
167
|
}
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
//#endregion
|
|
1688
|
-
//#region node_modules/color-convert/index.js
|
|
1689
|
-
var require_color_convert = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
1690
|
-
var conversions = require_conversions();
|
|
1691
|
-
var route = require_route();
|
|
1692
|
-
var convert = {};
|
|
1693
|
-
var models = Object.keys(conversions);
|
|
1694
|
-
function wrapRaw(fn) {
|
|
1695
|
-
const wrappedFn = function(...args) {
|
|
1696
|
-
const arg0 = args[0];
|
|
1697
|
-
if (arg0 === void 0 || arg0 === null) return arg0;
|
|
1698
|
-
if (arg0.length > 1) args = arg0;
|
|
1699
|
-
return fn(args);
|
|
1700
|
-
};
|
|
1701
|
-
if ("conversion" in fn) wrappedFn.conversion = fn.conversion;
|
|
1702
|
-
return wrappedFn;
|
|
1703
|
-
}
|
|
1704
|
-
function wrapRounded(fn) {
|
|
1705
|
-
const wrappedFn = function(...args) {
|
|
1706
|
-
const arg0 = args[0];
|
|
1707
|
-
if (arg0 === void 0 || arg0 === null) return arg0;
|
|
1708
|
-
if (arg0.length > 1) args = arg0;
|
|
1709
|
-
const result = fn(args);
|
|
1710
|
-
if (typeof result === "object") for (let len = result.length, i = 0; i < len; i++) result[i] = Math.round(result[i]);
|
|
1711
|
-
return result;
|
|
1712
|
-
};
|
|
1713
|
-
if ("conversion" in fn) wrappedFn.conversion = fn.conversion;
|
|
1714
|
-
return wrappedFn;
|
|
1715
|
-
}
|
|
1716
|
-
models.forEach((fromModel) => {
|
|
1717
|
-
convert[fromModel] = {};
|
|
1718
|
-
Object.defineProperty(convert[fromModel], "channels", { value: conversions[fromModel].channels });
|
|
1719
|
-
Object.defineProperty(convert[fromModel], "labels", { value: conversions[fromModel].labels });
|
|
1720
|
-
const routes = route(fromModel);
|
|
1721
|
-
Object.keys(routes).forEach((toModel) => {
|
|
1722
|
-
const fn = routes[toModel];
|
|
1723
|
-
convert[fromModel][toModel] = wrapRounded(fn);
|
|
1724
|
-
convert[fromModel][toModel].raw = wrapRaw(fn);
|
|
168
|
+
Object.defineProperty(styles$1, groupName, {
|
|
169
|
+
value: group,
|
|
170
|
+
enumerable: false
|
|
1725
171
|
});
|
|
172
|
+
}
|
|
173
|
+
Object.defineProperty(styles$1, "codes", {
|
|
174
|
+
value: codes,
|
|
175
|
+
enumerable: false
|
|
1726
176
|
});
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
var rgb2rgb = (r, g, b) => [
|
|
1745
|
-
r,
|
|
1746
|
-
g,
|
|
1747
|
-
b
|
|
1748
|
-
];
|
|
1749
|
-
var setLazyProperty = (object, property, get) => {
|
|
1750
|
-
Object.defineProperty(object, property, {
|
|
1751
|
-
get: () => {
|
|
1752
|
-
const value = get();
|
|
1753
|
-
Object.defineProperty(object, property, {
|
|
1754
|
-
value,
|
|
1755
|
-
enumerable: true,
|
|
1756
|
-
configurable: true
|
|
1757
|
-
});
|
|
1758
|
-
return value;
|
|
177
|
+
styles$1.color.close = "\x1B[39m";
|
|
178
|
+
styles$1.bgColor.close = "\x1B[49m";
|
|
179
|
+
styles$1.color.ansi = wrapAnsi16();
|
|
180
|
+
styles$1.color.ansi256 = wrapAnsi256();
|
|
181
|
+
styles$1.color.ansi16m = wrapAnsi16m();
|
|
182
|
+
styles$1.bgColor.ansi = wrapAnsi16(ANSI_BACKGROUND_OFFSET);
|
|
183
|
+
styles$1.bgColor.ansi256 = wrapAnsi256(ANSI_BACKGROUND_OFFSET);
|
|
184
|
+
styles$1.bgColor.ansi16m = wrapAnsi16m(ANSI_BACKGROUND_OFFSET);
|
|
185
|
+
Object.defineProperties(styles$1, {
|
|
186
|
+
rgbToAnsi256: {
|
|
187
|
+
value(red, green, blue) {
|
|
188
|
+
if (red === green && green === blue) {
|
|
189
|
+
if (red < 8) return 16;
|
|
190
|
+
if (red > 248) return 231;
|
|
191
|
+
return Math.round((red - 8) / 247 * 24) + 232;
|
|
192
|
+
}
|
|
193
|
+
return 16 + 36 * Math.round(red / 255 * 5) + 6 * Math.round(green / 255 * 5) + Math.round(blue / 255 * 5);
|
|
1759
194
|
},
|
|
1760
|
-
enumerable:
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
const codes = /* @__PURE__ */ new Map();
|
|
1779
|
-
const styles = {
|
|
1780
|
-
modifier: {
|
|
1781
|
-
reset: [0, 0],
|
|
1782
|
-
bold: [1, 22],
|
|
1783
|
-
dim: [2, 22],
|
|
1784
|
-
italic: [3, 23],
|
|
1785
|
-
underline: [4, 24],
|
|
1786
|
-
inverse: [7, 27],
|
|
1787
|
-
hidden: [8, 28],
|
|
1788
|
-
strikethrough: [9, 29]
|
|
195
|
+
enumerable: false
|
|
196
|
+
},
|
|
197
|
+
hexToRgb: {
|
|
198
|
+
value(hex) {
|
|
199
|
+
const matches = /[a-f\d]{6}|[a-f\d]{3}/i.exec(hex.toString(16));
|
|
200
|
+
if (!matches) return [
|
|
201
|
+
0,
|
|
202
|
+
0,
|
|
203
|
+
0
|
|
204
|
+
];
|
|
205
|
+
let [colorString] = matches;
|
|
206
|
+
if (colorString.length === 3) colorString = [...colorString].map((character) => character + character).join("");
|
|
207
|
+
const integer = Number.parseInt(colorString, 16);
|
|
208
|
+
return [
|
|
209
|
+
integer >> 16 & 255,
|
|
210
|
+
integer >> 8 & 255,
|
|
211
|
+
integer & 255
|
|
212
|
+
];
|
|
1789
213
|
},
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
214
|
+
enumerable: false
|
|
215
|
+
},
|
|
216
|
+
hexToAnsi256: {
|
|
217
|
+
value: (hex) => styles$1.rgbToAnsi256(...styles$1.hexToRgb(hex)),
|
|
218
|
+
enumerable: false
|
|
219
|
+
},
|
|
220
|
+
ansi256ToAnsi: {
|
|
221
|
+
value(code) {
|
|
222
|
+
if (code < 8) return 30 + code;
|
|
223
|
+
if (code < 16) return 90 + (code - 8);
|
|
224
|
+
let red;
|
|
225
|
+
let green;
|
|
226
|
+
let blue;
|
|
227
|
+
if (code >= 232) {
|
|
228
|
+
red = ((code - 232) * 10 + 8) / 255;
|
|
229
|
+
green = red;
|
|
230
|
+
blue = red;
|
|
231
|
+
} else {
|
|
232
|
+
code -= 16;
|
|
233
|
+
const remainder = code % 36;
|
|
234
|
+
red = Math.floor(code / 36) / 5;
|
|
235
|
+
green = Math.floor(remainder / 6) / 5;
|
|
236
|
+
blue = remainder % 6 / 5;
|
|
237
|
+
}
|
|
238
|
+
const value = Math.max(red, green, blue) * 2;
|
|
239
|
+
if (value === 0) return 30;
|
|
240
|
+
let result = 30 + (Math.round(blue) << 2 | Math.round(green) << 1 | Math.round(red));
|
|
241
|
+
if (value === 2) result += 60;
|
|
242
|
+
return result;
|
|
1807
243
|
},
|
|
1808
|
-
bgColor: {
|
|
1809
|
-
bgBlack: [40, 49],
|
|
1810
|
-
bgRed: [41, 49],
|
|
1811
|
-
bgGreen: [42, 49],
|
|
1812
|
-
bgYellow: [43, 49],
|
|
1813
|
-
bgBlue: [44, 49],
|
|
1814
|
-
bgMagenta: [45, 49],
|
|
1815
|
-
bgCyan: [46, 49],
|
|
1816
|
-
bgWhite: [47, 49],
|
|
1817
|
-
bgBlackBright: [100, 49],
|
|
1818
|
-
bgRedBright: [101, 49],
|
|
1819
|
-
bgGreenBright: [102, 49],
|
|
1820
|
-
bgYellowBright: [103, 49],
|
|
1821
|
-
bgBlueBright: [104, 49],
|
|
1822
|
-
bgMagentaBright: [105, 49],
|
|
1823
|
-
bgCyanBright: [106, 49],
|
|
1824
|
-
bgWhiteBright: [107, 49]
|
|
1825
|
-
}
|
|
1826
|
-
};
|
|
1827
|
-
styles.color.gray = styles.color.blackBright;
|
|
1828
|
-
styles.bgColor.bgGray = styles.bgColor.bgBlackBright;
|
|
1829
|
-
styles.color.grey = styles.color.blackBright;
|
|
1830
|
-
styles.bgColor.bgGrey = styles.bgColor.bgBlackBright;
|
|
1831
|
-
for (const [groupName, group] of Object.entries(styles)) {
|
|
1832
|
-
for (const [styleName, style] of Object.entries(group)) {
|
|
1833
|
-
styles[styleName] = {
|
|
1834
|
-
open: `\u001B[${style[0]}m`,
|
|
1835
|
-
close: `\u001B[${style[1]}m`
|
|
1836
|
-
};
|
|
1837
|
-
group[styleName] = styles[styleName];
|
|
1838
|
-
codes.set(style[0], style[1]);
|
|
1839
|
-
}
|
|
1840
|
-
Object.defineProperty(styles, groupName, {
|
|
1841
|
-
value: group,
|
|
1842
|
-
enumerable: false
|
|
1843
|
-
});
|
|
1844
|
-
}
|
|
1845
|
-
Object.defineProperty(styles, "codes", {
|
|
1846
|
-
value: codes,
|
|
1847
244
|
enumerable: false
|
|
1848
|
-
}
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
return styles;
|
|
1858
|
-
}
|
|
1859
|
-
Object.defineProperty(module, "exports", {
|
|
1860
|
-
enumerable: true,
|
|
1861
|
-
get: assembleStyles
|
|
245
|
+
},
|
|
246
|
+
rgbToAnsi: {
|
|
247
|
+
value: (red, green, blue) => styles$1.ansi256ToAnsi(styles$1.rgbToAnsi256(red, green, blue)),
|
|
248
|
+
enumerable: false
|
|
249
|
+
},
|
|
250
|
+
hexToAnsi: {
|
|
251
|
+
value: (hex) => styles$1.ansi256ToAnsi(styles$1.hexToAnsi256(hex)),
|
|
252
|
+
enumerable: false
|
|
253
|
+
}
|
|
1862
254
|
});
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
var require_browser = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
1867
|
-
module.exports = {
|
|
1868
|
-
stdout: false,
|
|
1869
|
-
stderr: false
|
|
1870
|
-
};
|
|
1871
|
-
}));
|
|
255
|
+
return styles$1;
|
|
256
|
+
}
|
|
257
|
+
var ansiStyles = assembleStyles();
|
|
1872
258
|
//#endregion
|
|
1873
|
-
//#region node_modules/chalk/source/
|
|
1874
|
-
var
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
const gotCR = string[index - 1] === "\r";
|
|
1894
|
-
returnValue += string.substr(endIndex, (gotCR ? index - 1 : index) - endIndex) + prefix + (gotCR ? "\r\n" : "\n") + postfix;
|
|
1895
|
-
endIndex = index + 1;
|
|
1896
|
-
index = string.indexOf("\n", endIndex);
|
|
1897
|
-
} while (index !== -1);
|
|
1898
|
-
returnValue += string.substr(endIndex);
|
|
1899
|
-
return returnValue;
|
|
1900
|
-
};
|
|
1901
|
-
module.exports = {
|
|
1902
|
-
stringReplaceAll,
|
|
1903
|
-
stringEncaseCRLFWithFirstIndex
|
|
1904
|
-
};
|
|
1905
|
-
}));
|
|
259
|
+
//#region node_modules/chalk/source/vendor/supports-color/browser.js
|
|
260
|
+
var level = (() => {
|
|
261
|
+
if (!("navigator" in globalThis)) return 0;
|
|
262
|
+
if (globalThis.navigator.userAgentData) {
|
|
263
|
+
const brand = navigator.userAgentData.brands.find(({ brand }) => brand === "Chromium");
|
|
264
|
+
if (brand && brand.version > 93) return 3;
|
|
265
|
+
}
|
|
266
|
+
if (/\b(Chrome|Chromium)\//.test(globalThis.navigator.userAgent)) return 1;
|
|
267
|
+
return 0;
|
|
268
|
+
})();
|
|
269
|
+
var colorSupport = level !== 0 && {
|
|
270
|
+
level,
|
|
271
|
+
hasBasic: true,
|
|
272
|
+
has256: level >= 2,
|
|
273
|
+
has16m: level >= 3
|
|
274
|
+
};
|
|
275
|
+
var supportsColor = {
|
|
276
|
+
stdout: colorSupport,
|
|
277
|
+
stderr: colorSupport
|
|
278
|
+
};
|
|
1906
279
|
//#endregion
|
|
1907
|
-
//#region node_modules/chalk/source/
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
const
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
const chunks = arguments_.trim().split(/\s*,\s*/g);
|
|
1935
|
-
let matches;
|
|
1936
|
-
for (const chunk of chunks) {
|
|
1937
|
-
const number = Number(chunk);
|
|
1938
|
-
if (!Number.isNaN(number)) results.push(number);
|
|
1939
|
-
else if (matches = chunk.match(STRING_REGEX)) results.push(matches[2].replace(ESCAPE_REGEX, (m, escape, character) => escape ? unescape(escape) : character));
|
|
1940
|
-
else throw new Error(`Invalid Chalk template style argument: ${chunk} (in style '${name}')`);
|
|
1941
|
-
}
|
|
1942
|
-
return results;
|
|
1943
|
-
}
|
|
1944
|
-
function parseStyle(style) {
|
|
1945
|
-
STYLE_REGEX.lastIndex = 0;
|
|
1946
|
-
const results = [];
|
|
1947
|
-
let matches;
|
|
1948
|
-
while ((matches = STYLE_REGEX.exec(style)) !== null) {
|
|
1949
|
-
const name = matches[1];
|
|
1950
|
-
if (matches[2]) {
|
|
1951
|
-
const args = parseArguments(name, matches[2]);
|
|
1952
|
-
results.push([name].concat(args));
|
|
1953
|
-
} else results.push([name]);
|
|
1954
|
-
}
|
|
1955
|
-
return results;
|
|
1956
|
-
}
|
|
1957
|
-
function buildStyle(chalk, styles) {
|
|
1958
|
-
const enabled = {};
|
|
1959
|
-
for (const layer of styles) for (const style of layer.styles) enabled[style[0]] = layer.inverse ? null : style.slice(1);
|
|
1960
|
-
let current = chalk;
|
|
1961
|
-
for (const [styleName, styles] of Object.entries(enabled)) {
|
|
1962
|
-
if (!Array.isArray(styles)) continue;
|
|
1963
|
-
if (!(styleName in current)) throw new Error(`Unknown Chalk style: ${styleName}`);
|
|
1964
|
-
current = styles.length > 0 ? current[styleName](...styles) : current[styleName];
|
|
1965
|
-
}
|
|
1966
|
-
return current;
|
|
1967
|
-
}
|
|
1968
|
-
module.exports = (chalk, temporary) => {
|
|
1969
|
-
const styles = [];
|
|
1970
|
-
const chunks = [];
|
|
1971
|
-
let chunk = [];
|
|
1972
|
-
temporary.replace(TEMPLATE_REGEX, (m, escapeCharacter, inverse, style, close, character) => {
|
|
1973
|
-
if (escapeCharacter) chunk.push(unescape(escapeCharacter));
|
|
1974
|
-
else if (style) {
|
|
1975
|
-
const string = chunk.join("");
|
|
1976
|
-
chunk = [];
|
|
1977
|
-
chunks.push(styles.length === 0 ? string : buildStyle(chalk, styles)(string));
|
|
1978
|
-
styles.push({
|
|
1979
|
-
inverse,
|
|
1980
|
-
styles: parseStyle(style)
|
|
1981
|
-
});
|
|
1982
|
-
} else if (close) {
|
|
1983
|
-
if (styles.length === 0) throw new Error("Found extraneous } in Chalk template literal");
|
|
1984
|
-
chunks.push(buildStyle(chalk, styles)(chunk.join("")));
|
|
1985
|
-
chunk = [];
|
|
1986
|
-
styles.pop();
|
|
1987
|
-
} else chunk.push(character);
|
|
1988
|
-
});
|
|
1989
|
-
chunks.push(chunk.join(""));
|
|
1990
|
-
if (styles.length > 0) {
|
|
1991
|
-
const errMessage = `Chalk template literal is missing ${styles.length} closing bracket${styles.length === 1 ? "" : "s"} (\`}\`)`;
|
|
1992
|
-
throw new Error(errMessage);
|
|
1993
|
-
}
|
|
1994
|
-
return chunks.join("");
|
|
1995
|
-
};
|
|
1996
|
-
}));
|
|
280
|
+
//#region node_modules/chalk/source/utilities.js
|
|
281
|
+
function stringReplaceAll(string, substring, replacer) {
|
|
282
|
+
let index = string.indexOf(substring);
|
|
283
|
+
if (index === -1) return string;
|
|
284
|
+
const substringLength = substring.length;
|
|
285
|
+
let endIndex = 0;
|
|
286
|
+
let returnValue = "";
|
|
287
|
+
do {
|
|
288
|
+
returnValue += string.slice(endIndex, index) + substring + replacer;
|
|
289
|
+
endIndex = index + substringLength;
|
|
290
|
+
index = string.indexOf(substring, endIndex);
|
|
291
|
+
} while (index !== -1);
|
|
292
|
+
returnValue += string.slice(endIndex);
|
|
293
|
+
return returnValue;
|
|
294
|
+
}
|
|
295
|
+
function stringEncaseCRLFWithFirstIndex(string, prefix, postfix, index) {
|
|
296
|
+
let endIndex = 0;
|
|
297
|
+
let returnValue = "";
|
|
298
|
+
do {
|
|
299
|
+
const gotCR = string[index - 1] === "\r";
|
|
300
|
+
returnValue += string.slice(endIndex, gotCR ? index - 1 : index) + prefix + (gotCR ? "\r\n" : "\n") + postfix;
|
|
301
|
+
endIndex = index + 1;
|
|
302
|
+
index = string.indexOf("\n", endIndex);
|
|
303
|
+
} while (index !== -1);
|
|
304
|
+
returnValue += string.slice(endIndex);
|
|
305
|
+
return returnValue;
|
|
306
|
+
}
|
|
1997
307
|
//#endregion
|
|
1998
|
-
//#region
|
|
1999
|
-
var
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
308
|
+
//#region node_modules/chalk/source/index.js
|
|
309
|
+
var { stdout: stdoutColor, stderr: stderrColor } = supportsColor;
|
|
310
|
+
var GENERATOR = Symbol("GENERATOR");
|
|
311
|
+
var STYLER = Symbol("STYLER");
|
|
312
|
+
var IS_EMPTY = Symbol("IS_EMPTY");
|
|
313
|
+
var levelMapping = [
|
|
314
|
+
"ansi",
|
|
315
|
+
"ansi",
|
|
316
|
+
"ansi256",
|
|
317
|
+
"ansi16m"
|
|
318
|
+
];
|
|
319
|
+
var styles = Object.create(null);
|
|
320
|
+
var applyOptions = (object, options = {}) => {
|
|
321
|
+
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");
|
|
322
|
+
const colorLevel = stdoutColor ? stdoutColor.level : 0;
|
|
323
|
+
object.level = options.level === void 0 ? colorLevel : options.level;
|
|
324
|
+
};
|
|
325
|
+
var chalkFactory = (options) => {
|
|
326
|
+
const chalk = (...strings) => strings.join(" ");
|
|
327
|
+
applyOptions(chalk, options);
|
|
328
|
+
Object.setPrototypeOf(chalk, createChalk.prototype);
|
|
329
|
+
return chalk;
|
|
330
|
+
};
|
|
331
|
+
function createChalk(options) {
|
|
332
|
+
return chalkFactory(options);
|
|
333
|
+
}
|
|
334
|
+
Object.setPrototypeOf(createChalk.prototype, Function.prototype);
|
|
335
|
+
for (const [styleName, style] of Object.entries(ansiStyles)) styles[styleName] = { get() {
|
|
336
|
+
const builder = createBuilder(this, createStyler(style.open, style.close, this[STYLER]), this[IS_EMPTY]);
|
|
337
|
+
Object.defineProperty(this, styleName, { value: builder });
|
|
338
|
+
return builder;
|
|
339
|
+
} };
|
|
340
|
+
styles.visible = { get() {
|
|
341
|
+
const builder = createBuilder(this, this[STYLER], true);
|
|
342
|
+
Object.defineProperty(this, "visible", { value: builder });
|
|
343
|
+
return builder;
|
|
344
|
+
} };
|
|
345
|
+
var getModelAnsi = (model, level, type, ...arguments_) => {
|
|
346
|
+
if (model === "rgb") {
|
|
347
|
+
if (level === "ansi16m") return ansiStyles[type].ansi16m(...arguments_);
|
|
348
|
+
if (level === "ansi256") return ansiStyles[type].ansi256(ansiStyles.rgbToAnsi256(...arguments_));
|
|
349
|
+
return ansiStyles[type].ansi(ansiStyles.rgbToAnsi(...arguments_));
|
|
350
|
+
}
|
|
351
|
+
if (model === "hex") return getModelAnsi("rgb", level, type, ...ansiStyles.hexToRgb(...arguments_));
|
|
352
|
+
return ansiStyles[type][model](...arguments_);
|
|
353
|
+
};
|
|
354
|
+
for (const model of [
|
|
355
|
+
"rgb",
|
|
356
|
+
"hex",
|
|
357
|
+
"ansi256"
|
|
358
|
+
]) {
|
|
359
|
+
styles[model] = { get() {
|
|
360
|
+
const { level } = this;
|
|
361
|
+
return function(...arguments_) {
|
|
362
|
+
const styler = createStyler(getModelAnsi(model, levelMapping[level], "color", ...arguments_), ansiStyles.color.close, this[STYLER]);
|
|
363
|
+
return createBuilder(this, styler, this[IS_EMPTY]);
|
|
2029
364
|
};
|
|
2030
|
-
chalk.template.Instance = ChalkClass;
|
|
2031
|
-
return chalk.template;
|
|
2032
|
-
};
|
|
2033
|
-
function Chalk(options) {
|
|
2034
|
-
return chalkFactory(options);
|
|
2035
|
-
}
|
|
2036
|
-
for (const [styleName, style] of Object.entries(ansiStyles)) styles[styleName] = { get() {
|
|
2037
|
-
const builder = createBuilder(this, createStyler(style.open, style.close, this._styler), this._isEmpty);
|
|
2038
|
-
Object.defineProperty(this, styleName, { value: builder });
|
|
2039
|
-
return builder;
|
|
2040
365
|
} };
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
Object.defineProperty(this, "visible", { value: builder });
|
|
2044
|
-
return builder;
|
|
2045
|
-
} };
|
|
2046
|
-
var usedModels = [
|
|
2047
|
-
"rgb",
|
|
2048
|
-
"hex",
|
|
2049
|
-
"keyword",
|
|
2050
|
-
"hsl",
|
|
2051
|
-
"hsv",
|
|
2052
|
-
"hwb",
|
|
2053
|
-
"ansi",
|
|
2054
|
-
"ansi256"
|
|
2055
|
-
];
|
|
2056
|
-
for (const model of usedModels) styles[model] = { get() {
|
|
366
|
+
const bgModel = "bg" + model[0].toUpperCase() + model.slice(1);
|
|
367
|
+
styles[bgModel] = { get() {
|
|
2057
368
|
const { level } = this;
|
|
2058
369
|
return function(...arguments_) {
|
|
2059
|
-
const styler = createStyler(
|
|
2060
|
-
return createBuilder(this, styler, this
|
|
370
|
+
const styler = createStyler(getModelAnsi(model, levelMapping[level], "bgColor", ...arguments_), ansiStyles.bgColor.close, this[STYLER]);
|
|
371
|
+
return createBuilder(this, styler, this[IS_EMPTY]);
|
|
2061
372
|
};
|
|
2062
373
|
} };
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
var proto = Object.defineProperties(() => {}, {
|
|
2074
|
-
...styles,
|
|
2075
|
-
level: {
|
|
2076
|
-
enumerable: true,
|
|
2077
|
-
get() {
|
|
2078
|
-
return this._generator.level;
|
|
2079
|
-
},
|
|
2080
|
-
set(level) {
|
|
2081
|
-
this._generator.level = level;
|
|
2082
|
-
}
|
|
2083
|
-
}
|
|
2084
|
-
});
|
|
2085
|
-
var createStyler = (open, close, parent) => {
|
|
2086
|
-
let openAll;
|
|
2087
|
-
let closeAll;
|
|
2088
|
-
if (parent === void 0) {
|
|
2089
|
-
openAll = open;
|
|
2090
|
-
closeAll = close;
|
|
2091
|
-
} else {
|
|
2092
|
-
openAll = parent.openAll + open;
|
|
2093
|
-
closeAll = close + parent.closeAll;
|
|
2094
|
-
}
|
|
2095
|
-
return {
|
|
2096
|
-
open,
|
|
2097
|
-
close,
|
|
2098
|
-
openAll,
|
|
2099
|
-
closeAll,
|
|
2100
|
-
parent
|
|
2101
|
-
};
|
|
2102
|
-
};
|
|
2103
|
-
var createBuilder = (self, _styler, _isEmpty) => {
|
|
2104
|
-
const builder = (...arguments_) => {
|
|
2105
|
-
if (isArray(arguments_[0]) && isArray(arguments_[0].raw)) return applyStyle(builder, chalkTag(builder, ...arguments_));
|
|
2106
|
-
return applyStyle(builder, arguments_.length === 1 ? "" + arguments_[0] : arguments_.join(" "));
|
|
2107
|
-
};
|
|
2108
|
-
Object.setPrototypeOf(builder, proto);
|
|
2109
|
-
builder._generator = self;
|
|
2110
|
-
builder._styler = _styler;
|
|
2111
|
-
builder._isEmpty = _isEmpty;
|
|
2112
|
-
return builder;
|
|
2113
|
-
};
|
|
2114
|
-
var applyStyle = (self, string) => {
|
|
2115
|
-
if (self.level <= 0 || !string) return self._isEmpty ? "" : string;
|
|
2116
|
-
let styler = self._styler;
|
|
2117
|
-
if (styler === void 0) return string;
|
|
2118
|
-
const { openAll, closeAll } = styler;
|
|
2119
|
-
if (string.indexOf("\x1B") !== -1) while (styler !== void 0) {
|
|
2120
|
-
string = stringReplaceAll(string, styler.close, styler.open);
|
|
2121
|
-
styler = styler.parent;
|
|
374
|
+
}
|
|
375
|
+
var proto = Object.defineProperties(() => {}, {
|
|
376
|
+
...styles,
|
|
377
|
+
level: {
|
|
378
|
+
enumerable: true,
|
|
379
|
+
get() {
|
|
380
|
+
return this[GENERATOR].level;
|
|
381
|
+
},
|
|
382
|
+
set(level) {
|
|
383
|
+
this[GENERATOR].level = level;
|
|
2122
384
|
}
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
385
|
+
}
|
|
386
|
+
});
|
|
387
|
+
var createStyler = (open, close, parent) => {
|
|
388
|
+
let openAll;
|
|
389
|
+
let closeAll;
|
|
390
|
+
if (parent === void 0) {
|
|
391
|
+
openAll = open;
|
|
392
|
+
closeAll = close;
|
|
393
|
+
} else {
|
|
394
|
+
openAll = parent.openAll + open;
|
|
395
|
+
closeAll = close + parent.closeAll;
|
|
396
|
+
}
|
|
397
|
+
return {
|
|
398
|
+
open,
|
|
399
|
+
close,
|
|
400
|
+
openAll,
|
|
401
|
+
closeAll,
|
|
402
|
+
parent
|
|
2136
403
|
};
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
404
|
+
};
|
|
405
|
+
var createBuilder = (self, _styler, _isEmpty) => {
|
|
406
|
+
const builder = (...arguments_) => applyStyle(builder, arguments_.length === 1 ? "" + arguments_[0] : arguments_.join(" "));
|
|
407
|
+
Object.setPrototypeOf(builder, proto);
|
|
408
|
+
builder[GENERATOR] = self;
|
|
409
|
+
builder[STYLER] = _styler;
|
|
410
|
+
builder[IS_EMPTY] = _isEmpty;
|
|
411
|
+
return builder;
|
|
412
|
+
};
|
|
413
|
+
var applyStyle = (self, string) => {
|
|
414
|
+
if (self.level <= 0 || !string) return self[IS_EMPTY] ? "" : string;
|
|
415
|
+
let styler = self[STYLER];
|
|
416
|
+
if (styler === void 0) return string;
|
|
417
|
+
const { openAll, closeAll } = styler;
|
|
418
|
+
if (string.includes("\x1B")) while (styler !== void 0) {
|
|
419
|
+
string = stringReplaceAll(string, styler.close, styler.open);
|
|
420
|
+
styler = styler.parent;
|
|
421
|
+
}
|
|
422
|
+
const lfIndex = string.indexOf("\n");
|
|
423
|
+
if (lfIndex !== -1) string = stringEncaseCRLFWithFirstIndex(string, closeAll, openAll, lfIndex);
|
|
424
|
+
return openAll + string + closeAll;
|
|
425
|
+
};
|
|
426
|
+
Object.defineProperties(createChalk.prototype, styles);
|
|
427
|
+
var chalk = createChalk();
|
|
428
|
+
createChalk({ level: stderrColor ? stderrColor.level : 0 });
|
|
429
|
+
//#endregion
|
|
430
|
+
//#region src/abstractRunnerExecutionWorker.ts
|
|
431
|
+
chalk.level = 3;
|
|
2145
432
|
/**
|
|
2146
433
|
* Abstract worker-runtime base class.
|
|
2147
434
|
*
|
|
@@ -2284,14 +571,14 @@ var AbstractRunnerExecutionWorker = class {
|
|
|
2284
571
|
const removeList = [];
|
|
2285
572
|
for (const [, runner] of Object.entries(this.#runners)) if (runner.archived === false && (runner.runner.state === IRunnerState.completed || runner.runner.state === IRunnerState.error || runner.runner.state === IRunnerState.stopped || runner.runner.state === IRunnerState.terminated)) removeList.push(runner.runner.id);
|
|
2286
573
|
if (removeList.length > 0) setTimeout(() => {
|
|
2287
|
-
this.#debug(
|
|
574
|
+
this.#debug(chalk.grey(`WorkerInstance:#processLoopExecutor(): Removing runners from collection: [${removeList}]`));
|
|
2288
575
|
for (let i = 0; i < removeList.length; i++) {
|
|
2289
576
|
this.#runners[removeList[i]].archived = true;
|
|
2290
577
|
if (this.#archiveDeleteTimeout !== 0) if (detect_node.default) setTimeout(() => delete this.#runners[removeList[i]], this.#archiveDeleteTimeout * 1e3).unref();
|
|
2291
578
|
else setTimeout(() => delete this.#runners[removeList[i]], this.#archiveDeleteTimeout * 1e3);
|
|
2292
579
|
}
|
|
2293
580
|
const message = `WorkerInstance:#processLoopExecutor(): Remaining Runner Count: [${Object.keys(this.#runners).length}]`;
|
|
2294
|
-
this.#debug(
|
|
581
|
+
this.#debug(chalk.magenta(message));
|
|
2295
582
|
setTimeout(this.#processLoopExecutor, 1e3);
|
|
2296
583
|
}, 100);
|
|
2297
584
|
else setTimeout(this.#processLoopExecutor, 1e3);
|
|
@@ -3061,10 +1348,10 @@ var AbstractRunnerExecutionWorker = class {
|
|
|
3061
1348
|
const { state } = this.#runners[runnerId].runner;
|
|
3062
1349
|
if (state === IRunnerState.paused || state === IRunnerState.created) {
|
|
3063
1350
|
const currentIteration = this.#GetRunnerIterationByRunnerId(runnerId);
|
|
3064
|
-
this.#debug(`${
|
|
1351
|
+
this.#debug(`${chalk.magenta(`runner: [${runnerId}]`)} ExecuteRunner(${currentIteration})`);
|
|
3065
1352
|
result = await this.#GetRunnerInstanceByRunnerId(runnerId)?.ExecuteRunner();
|
|
3066
1353
|
const newIteration = this.#IncRunnerIterationByRunnerId(runnerId);
|
|
3067
|
-
this.#debug(`${
|
|
1354
|
+
this.#debug(`${chalk.magenta(` --> runner: [${runnerId}]`)} Next iteration number: [${newIteration}] for next Execute or Resume.`);
|
|
3068
1355
|
this.#UpdateRunnerStateByRunnerId("#ExecuteRunner", runnerId, IRunnerState.paused);
|
|
3069
1356
|
}
|
|
3070
1357
|
} else this.#warn(`#ExecuteRunner(): Runner: [${runnerId}] not found`);
|
|
@@ -3097,9 +1384,9 @@ var AbstractRunnerExecutionWorker = class {
|
|
|
3097
1384
|
if (this.#runners[runnerId]) {
|
|
3098
1385
|
const { state } = this.#runners[runnerId].runner;
|
|
3099
1386
|
if (state === IRunnerState.paused || state === IRunnerState.created || state === IRunnerState.running) {
|
|
3100
|
-
this.#debug(
|
|
1387
|
+
this.#debug(chalk.cyan(`before: [${JSON.stringify(this.#GetRunnerOptionsByRunnerId(runnerId))}]`));
|
|
3101
1388
|
this.#SetRunnerOptionsByRunnerId(runnerId, testRunnerTelemetryPayload.runner.options);
|
|
3102
|
-
this.#debug(
|
|
1389
|
+
this.#debug(chalk.cyan(`after: [${JSON.stringify(this.#GetRunnerOptionsByRunnerId(runnerId))}]`));
|
|
3103
1390
|
result = await this.#GetRunnerInstanceByRunnerId(runnerId)?.UpdateRunner(testRunnerTelemetryPayload.runner.options);
|
|
3104
1391
|
}
|
|
3105
1392
|
} else this.#warn(`#UpdateRunner(): Runner: [${runnerId}] not found`);
|
|
@@ -4768,8 +3055,8 @@ var import_lodash_merge = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin
|
|
|
4768
3055
|
return false;
|
|
4769
3056
|
}
|
|
4770
3057
|
module.exports = merge;
|
|
4771
|
-
})))());
|
|
4772
|
-
|
|
3058
|
+
})))(), 1);
|
|
3059
|
+
chalk.level = 3;
|
|
4773
3060
|
/**
|
|
4774
3061
|
* Message broker used to coordinate request/response and push-style messaging
|
|
4775
3062
|
* between the manager/runtime and worker instances.
|
|
@@ -5402,7 +3689,7 @@ var RunnerInstance = class {
|
|
|
5402
3689
|
};
|
|
5403
3690
|
//#endregion
|
|
5404
3691
|
//#region src/asyncRunnerInstanceManager.ts
|
|
5405
|
-
|
|
3692
|
+
chalk.level = 3;
|
|
5406
3693
|
/**
|
|
5407
3694
|
* Factory/manager used to construct new live asynchronous runner instances.
|
|
5408
3695
|
*
|
|
@@ -5534,7 +3821,7 @@ ${runnerId}`,
|
|
|
5534
3821
|
* - This class owns only the archive list and loop scheduling; live worker/runner
|
|
5535
3822
|
* ownership remains with the {@link WorkerRegistry}.
|
|
5536
3823
|
*/
|
|
5537
|
-
|
|
3824
|
+
chalk.level = 3;
|
|
5538
3825
|
/**
|
|
5539
3826
|
* Archive manager for completed/stopped/failed runner instances.
|
|
5540
3827
|
*/
|
|
@@ -5640,7 +3927,7 @@ var ArchiveManager = class {
|
|
|
5640
3927
|
*/
|
|
5641
3928
|
if (removeList.length > 0) {
|
|
5642
3929
|
const startTimeout = setTimeout(async () => {
|
|
5643
|
-
this.options.logger.debug(
|
|
3930
|
+
this.options.logger.debug(chalk.grey(`STSWorkerManager:_processLoopExecutor(): Removing runners from collection: [${JSON.stringify(removeList)}]`));
|
|
5644
3931
|
/**
|
|
5645
3932
|
* Process each matched runner from the temporary remove list.
|
|
5646
3933
|
*/
|
|
@@ -5656,7 +3943,7 @@ var ArchiveManager = class {
|
|
|
5656
3943
|
* publishing occurs after the runner is considered retired.
|
|
5657
3944
|
*/
|
|
5658
3945
|
if (runnerEx.publishInstrumentController) {
|
|
5659
|
-
this.options.logger.debug(
|
|
3946
|
+
this.options.logger.debug(chalk.grey(`Ending publish for runner: [${JSON.stringify(runnerEx.asyncRunnerContext)}]`));
|
|
5660
3947
|
runnerEx.publishInstrumentController.EndPublish();
|
|
5661
3948
|
}
|
|
5662
3949
|
/**
|
|
@@ -5665,14 +3952,14 @@ var ArchiveManager = class {
|
|
|
5665
3952
|
* Terminated runners are treated as retired/removed but not archived.
|
|
5666
3953
|
*/
|
|
5667
3954
|
if (runnerEx.state !== IRunnerState.terminated) {
|
|
5668
|
-
this.options.logger.debug(
|
|
3955
|
+
this.options.logger.debug(chalk.grey(`Archive runner: [${JSON.stringify(runnerEx.asyncRunnerContext)}]`));
|
|
5669
3956
|
const runner = runnerEx.toRunner();
|
|
5670
3957
|
this.archiveList.push(runner);
|
|
5671
3958
|
/**
|
|
5672
3959
|
* Enforce archive list size cap by discarding the oldest item.
|
|
5673
3960
|
*/
|
|
5674
3961
|
if (this.archiveList.length > this.options.maxArchiveListLength) this.archiveList.shift();
|
|
5675
|
-
} else this.options.logger.debug(
|
|
3962
|
+
} else this.options.logger.debug(chalk.grey(`Runner has been terminated and will not be archived, runner: [${JSON.stringify(runnerEx.asyncRunnerContext)}]`));
|
|
5676
3963
|
/**
|
|
5677
3964
|
* Mark as archived regardless of whether it was actually added
|
|
5678
3965
|
* to the archive list. This prevents the runner from being
|
|
@@ -5709,7 +3996,7 @@ var ArchiveManager = class {
|
|
|
5709
3996
|
*/
|
|
5710
3997
|
for (const [, workerEx] of Object.entries(this.options.workerRegistry.GetWorkersEx([]))) {
|
|
5711
3998
|
const message = `STSWorkerManager:_processLoopExecutor(): Remaining runners from worker: [${workerEx.id}]: [${workerEx.GetAllRunnersEx().length}]`;
|
|
5712
|
-
this.options.logger.debug(
|
|
3999
|
+
this.options.logger.debug(chalk.magenta(message));
|
|
5713
4000
|
}
|
|
5714
4001
|
/**
|
|
5715
4002
|
* Schedule the next archive scan.
|
|
@@ -6249,8 +4536,8 @@ var WorkerInstance = class {
|
|
|
6249
4536
|
const runnerEx = this.#asyncRunnerInstanceManager.CreateAsyncRunner(this, runnerOptions);
|
|
6250
4537
|
this.AddRunnerEx(runnerEx);
|
|
6251
4538
|
const retVal = await this.#messageBroker.SendMessageToWorkerForRunnerWithCallBack(this, runnerEx, eIWMessageCommands.AddRunner);
|
|
6252
|
-
if (runnerEx.publishInstrumentController) runnerEx.publishInstrumentController.LogEx(
|
|
6253
|
-
if (retVal) this.#logger.debug(
|
|
4539
|
+
if (runnerEx.publishInstrumentController) runnerEx.publishInstrumentController.LogEx(chalk.green(`Added runner: [${runnerEx.id}] into worker: [${this.id}]`));
|
|
4540
|
+
if (retVal) this.#logger.debug(chalk.green(`Added runner: [${runnerEx.id}] into worker: [${this.id}] result: [${JSON.stringify(retVal)}]`));
|
|
6254
4541
|
return runnerEx;
|
|
6255
4542
|
} catch (error) {
|
|
6256
4543
|
this.#logger.error(`AddRunnerToWorker(): Error: [${error}]`);
|
|
@@ -6260,7 +4547,7 @@ var WorkerInstance = class {
|
|
|
6260
4547
|
};
|
|
6261
4548
|
//#endregion
|
|
6262
4549
|
//#region src/workerInstanceMannager.ts
|
|
6263
|
-
|
|
4550
|
+
chalk.level = 3;
|
|
6264
4551
|
/**
|
|
6265
4552
|
* Manager-side factory/helper for worker instances.
|
|
6266
4553
|
*
|
|
@@ -6362,11 +4649,11 @@ var WorkerInstanceManager = class {
|
|
|
6362
4649
|
*/
|
|
6363
4650
|
stsWorkerEx.worker.on("exit", (code) => {
|
|
6364
4651
|
try {
|
|
6365
|
-
this.options.logger.debug(
|
|
4652
|
+
this.options.logger.debug(chalk.magenta(`STSWorkerManager:stsWorkerEx.worker.on(exit): Worker exited with code: ${code}`));
|
|
6366
4653
|
this._EmitWorkerEvent("exit", stsWorkerEx);
|
|
6367
4654
|
this.options.workerRegistry.DeleteWorker(stsWorkerEx.id);
|
|
6368
4655
|
} catch (error) {
|
|
6369
|
-
this.options.logger.error(
|
|
4656
|
+
this.options.logger.error(chalk.red(`STSWorkerManager:stsWorkerEx.worker.on(exit): Error: [${error}] Worker: [${stsWorkerEx.id}]`));
|
|
6370
4657
|
}
|
|
6371
4658
|
});
|
|
6372
4659
|
/**
|
|
@@ -6378,10 +4665,10 @@ var WorkerInstanceManager = class {
|
|
|
6378
4665
|
*/
|
|
6379
4666
|
stsWorkerEx.worker.on("error", (error) => {
|
|
6380
4667
|
try {
|
|
6381
|
-
this.options.logger.error(
|
|
4668
|
+
this.options.logger.error(chalk.red(`STSWorkerManager:stsWorkerEx.worker.on(error): Worker error: ${error}`));
|
|
6382
4669
|
this._EmitWorkerEvent("error", stsWorkerEx);
|
|
6383
4670
|
} catch (error) {
|
|
6384
|
-
this.options.logger.error(
|
|
4671
|
+
this.options.logger.error(chalk.red(`STSWorkerManager:stsWorkerEx.worker.on(error): Error: [${error}] Worker: [${stsWorkerEx.id}]`));
|
|
6385
4672
|
}
|
|
6386
4673
|
});
|
|
6387
4674
|
} else {
|
|
@@ -6392,11 +4679,11 @@ var WorkerInstanceManager = class {
|
|
|
6392
4679
|
*/
|
|
6393
4680
|
stsWorkerEx.worker.onerror = (error) => {
|
|
6394
4681
|
try {
|
|
6395
|
-
this.options.logger.error(
|
|
4682
|
+
this.options.logger.error(chalk.red("STSWorkerManager:stsWorkerEx.worker.onerror(): Error in worker:", error));
|
|
6396
4683
|
this._EmitWorkerEvent("onerror", stsWorkerEx);
|
|
6397
4684
|
this.options.workerRegistry.DeleteWorker(stsWorkerEx.id);
|
|
6398
4685
|
} catch (error) {
|
|
6399
|
-
this.options.logger.error(
|
|
4686
|
+
this.options.logger.error(chalk.red(`STSWorkerManager:stsWorkerEx.worker.onerror(error): Error: [${error}] Worker: [${stsWorkerEx.id}]`));
|
|
6400
4687
|
}
|
|
6401
4688
|
};
|
|
6402
4689
|
/**
|
|
@@ -6407,10 +4694,10 @@ var WorkerInstanceManager = class {
|
|
|
6407
4694
|
*/
|
|
6408
4695
|
stsWorkerEx.worker.onmessageerror = (error) => {
|
|
6409
4696
|
try {
|
|
6410
|
-
this.options.logger.error(
|
|
4697
|
+
this.options.logger.error(chalk.red("STSWorkerManager:stsWorkerEx.worker.onmessageerror(): Message error in worker:", error));
|
|
6411
4698
|
this._EmitWorkerEvent("onmessageerror", stsWorkerEx);
|
|
6412
4699
|
} catch (error) {
|
|
6413
|
-
this.options.logger.error(
|
|
4700
|
+
this.options.logger.error(chalk.red(`STSWorkerManager:stsWorkerEx.worker.onmessageerror(error): Error: [${error}] Worker: [${stsWorkerEx.id}]`));
|
|
6414
4701
|
}
|
|
6415
4702
|
};
|
|
6416
4703
|
}
|
|
@@ -7478,7 +5765,7 @@ var WorkerStateSynchroniser = class {
|
|
|
7478
5765
|
};
|
|
7479
5766
|
//#endregion
|
|
7480
5767
|
//#region src/workerCommandCoordinator.ts
|
|
7481
|
-
|
|
5768
|
+
chalk.level = 3;
|
|
7482
5769
|
/**
|
|
7483
5770
|
* Central coordinator for worker-level and runner-level command execution.
|
|
7484
5771
|
*
|
|
@@ -7724,7 +6011,7 @@ var WorkerCommandCoordinator = class {
|
|
|
7724
6011
|
* - Most public methods are intentionally thin façade methods delegating to
|
|
7725
6012
|
* more specialised collaborators.
|
|
7726
6013
|
*/
|
|
7727
|
-
|
|
6014
|
+
chalk.level = 3;
|
|
7728
6015
|
/**
|
|
7729
6016
|
* Main manager/coordinator for workers and runners.
|
|
7730
6017
|
*
|
|
@@ -7951,7 +6238,7 @@ var STSWorkerManager = class {
|
|
|
7951
6238
|
*/
|
|
7952
6239
|
CreateAndWireWorker = (workerOptions, workerFactory, port1, port2) => {
|
|
7953
6240
|
const stsWorkerEx = this.#workerInstanceManager.CreateWorkerInstance(workerOptions, port1, workerFactory);
|
|
7954
|
-
if (this.#STSInstrumentController) this.#STSInstrumentController.LogEx(
|
|
6241
|
+
if (this.#STSInstrumentController) this.#STSInstrumentController.LogEx(chalk.yellow(`pid: [${process.pid}] Creating new worker: [${stsWorkerEx.id}]`));
|
|
7955
6242
|
this.#debug(`AddWorker::workerThreadWorkerOptions: Worker ID: [${stsWorkerEx.id}] Options: [${stsWorkerEx.options}]`);
|
|
7956
6243
|
this.#messageBroker.SetupMessagePort(stsWorkerEx, port2);
|
|
7957
6244
|
return stsWorkerEx;
|
|
@@ -8021,8 +6308,8 @@ var STSWorkerManager = class {
|
|
|
8021
6308
|
const runnerEx = this.#asyncRunnerInstanceManager.CreateAsyncRunner(stsWorkerEx, runnerOptions);
|
|
8022
6309
|
this.#workerRegistry.AddRunner(stsWorkerEx.id, runnerEx);
|
|
8023
6310
|
const retVal = await this.#messageBroker.SendMessageToWorkerForRunnerWithCallBack(stsWorkerEx, runnerEx, eIWMessageCommands.AddRunner);
|
|
8024
|
-
if (runnerEx.publishInstrumentController) runnerEx.publishInstrumentController.LogEx(
|
|
8025
|
-
if (retVal) this.#debug(
|
|
6311
|
+
if (runnerEx.publishInstrumentController) runnerEx.publishInstrumentController.LogEx(chalk.green(`Added runner: [${runnerEx.id}] into worker: [${stsWorkerEx.id}]`));
|
|
6312
|
+
if (retVal) this.#debug(chalk.green(`Added runner: [${runnerEx.id}] into worker: [${stsWorkerEx.id}] result: [${JSON.stringify(retVal)}]`));
|
|
8026
6313
|
return runnerEx;
|
|
8027
6314
|
} catch (error) {
|
|
8028
6315
|
this.#error(`AddRunnerToWorker(): Error: [${error}]`);
|