toosoon-utils 1.0.0 → 1.0.1
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/README.md +416 -0
- package/lib/index.d.ts +11 -11
- package/lib/index.js +22 -13
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/colors.ts +16 -16
- package/src/constants.ts +1 -1
- package/src/dom.ts +2 -2
- package/src/geometry.ts +1 -1
- package/src/index.ts +12 -11
- package/src/maths.ts +1 -1
- package/src/random.ts +6 -6
package/README.md
ADDED
|
@@ -0,0 +1,416 @@
|
|
|
1
|
+
# TOOSOON UTILS
|
|
2
|
+
|
|
3
|
+
##
|
|
4
|
+
|
|
5
|
+
TOOSOON utility functions.
|
|
6
|
+
|
|
7
|
+
## Installation
|
|
8
|
+
|
|
9
|
+
Yarn:
|
|
10
|
+
|
|
11
|
+
```properties
|
|
12
|
+
$ yarn add toosoon-utils
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
NPM:
|
|
16
|
+
|
|
17
|
+
```properties
|
|
18
|
+
$ $ npm install toosoon-utils
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Usage
|
|
22
|
+
|
|
23
|
+
```js
|
|
24
|
+
import { maths } from 'toosoon-utils';
|
|
25
|
+
|
|
26
|
+
console.log(maths.lerp(0.5, 0, 5)); // 2.5
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
```js
|
|
30
|
+
import { PI } from 'toosoon-utils/lib/constants';
|
|
31
|
+
|
|
32
|
+
console.log(PI); // 3.141592653589793
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## Functions
|
|
36
|
+
|
|
37
|
+
### Colors
|
|
38
|
+
|
|
39
|
+
```ts
|
|
40
|
+
// Normalize an hexadecimal string
|
|
41
|
+
normalizeHexString(hex: string) => string;
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
```ts
|
|
45
|
+
// Convert RGB to hexadecimal
|
|
46
|
+
rgbToHex([r, g, b]: [number, number, number]) => number;
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
```ts
|
|
50
|
+
// Convert RGB to hexadecimal string
|
|
51
|
+
rgbToHexString([r, g, b]: [number, number, number]) => string;
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
```ts
|
|
55
|
+
// Convert hexadecimal to RGB
|
|
56
|
+
hexToRgb(hex: number | string) => [number, number, number];
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
```ts
|
|
60
|
+
// Lighten a color
|
|
61
|
+
lighten(hex: string, amount?: number) => string;
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
```ts
|
|
65
|
+
// Darken a color
|
|
66
|
+
darken(hex: string, amount?: number) => string;
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
```ts
|
|
70
|
+
// Normalize an HSL string
|
|
71
|
+
normalizeHslString(hsl: string) => [number, number, number];
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
```ts
|
|
75
|
+
// Convert RGB to HSL
|
|
76
|
+
rgbToHsl([r, g, b]: [number, number, number]) => [number, number, number];
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
```ts
|
|
80
|
+
// Convert HSL to RGB
|
|
81
|
+
hslToRgb([h, s, l]: [number, number, number]) => [number, number, number];
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
```ts
|
|
85
|
+
// Convert RGB to HSB
|
|
86
|
+
rgbToHsb([r, g, b]: [number, number, number]) => [number, number, number];
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
```ts
|
|
90
|
+
// Convert HSB to RGB
|
|
91
|
+
hsbToRgb([h, s, b]: [number, number, number]) => [number, number, number];
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
```ts
|
|
95
|
+
// Convert LAB to HCL
|
|
96
|
+
labToHcl([l, a, b]: [number, number, number]) => [number, number, number];
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
```ts
|
|
100
|
+
// Convert HCL to LAB
|
|
101
|
+
hclToLab([h, c, l]: [number, number, number]) => [number, number, number];
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
```ts
|
|
105
|
+
// Convert LAB to RGB
|
|
106
|
+
labToRgb([l, a, b]: [number, number, number]) => [number, number, number];
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
```ts
|
|
110
|
+
// Convert RGB to LAB
|
|
111
|
+
rgbToLab([r, g, b]: [number, number, number]) => [number, number, number];
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
```ts
|
|
115
|
+
// Get the delta from two LAB colors
|
|
116
|
+
deltaE(labA: [number, number, number], labB: [number, number, number]) => number;
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
```ts
|
|
120
|
+
// Convert RGB to HCL
|
|
121
|
+
rgbToHcl([r, g, b]: [number, number, number]) => [number, number, number];
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
```ts
|
|
125
|
+
// Convert HCL to RGB
|
|
126
|
+
hclToRgb([h, c, l]: [number, number, number]) => [number, number, number];
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
### DOM
|
|
130
|
+
|
|
131
|
+
```ts
|
|
132
|
+
// Find the closest parent that matches a selector
|
|
133
|
+
closest(element: Element, selector: Element | string) => Element | null;
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
```ts
|
|
137
|
+
// Create a canvas and 2d context
|
|
138
|
+
createCanvas(width: number, height: number) => { canvas: HTMLCanvasElement; ctx: CanvasRenderingContext2D };
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
```ts
|
|
142
|
+
// Inject CSS styles in `document.head`
|
|
143
|
+
injectStyles(cssContent: string) => void;
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
### FILES
|
|
147
|
+
|
|
148
|
+
```ts
|
|
149
|
+
// Download a Blob object into user files
|
|
150
|
+
download(blob: Blob, filename: string) => void;
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
```ts
|
|
154
|
+
// Upload a file from user files
|
|
155
|
+
upload(onLoad: (dataUrl: string) => void, accept?: string) => void;
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
### FUNCTIONS
|
|
159
|
+
|
|
160
|
+
```ts
|
|
161
|
+
// No-op function
|
|
162
|
+
noop() => void;
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
```ts
|
|
166
|
+
// Promise wrapped setTimeout
|
|
167
|
+
wait(timeout: number) => Promise<void>;
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
```ts
|
|
171
|
+
// Deferred promise implementation
|
|
172
|
+
defer<T>() => Deferred<T>;
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
### GEOMETRY
|
|
176
|
+
|
|
177
|
+
```ts
|
|
178
|
+
// Convert a radians value into degrees
|
|
179
|
+
toDegrees(radians: number) => number;
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
```ts
|
|
183
|
+
// Convert a degrees value into radians
|
|
184
|
+
toRadians(degrees: number) => number;
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
```ts
|
|
188
|
+
// Calculate the angle from a point to another
|
|
189
|
+
angle(x1: number, y1: number, x2: number, y2: number) => number;
|
|
190
|
+
```
|
|
191
|
+
|
|
192
|
+
```ts
|
|
193
|
+
// Find the closest angle between to angles
|
|
194
|
+
closestAngle(source: number, target: number) => number;
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
```ts
|
|
198
|
+
// Calculate the distance between two points
|
|
199
|
+
distance(x1: number, y1: number, x2: number, y2: number) => number;
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
```ts
|
|
203
|
+
// Calculate the length of the diagonal of a rectangle
|
|
204
|
+
diagonal(width: number, height: number) => number;
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
```ts
|
|
208
|
+
// Convert radians to a 3D point on the surface of a unit sphere
|
|
209
|
+
radToSphere(radius: number, phi: number, theta: number, target?: Vector3) => Vector3;
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
```ts
|
|
213
|
+
// Make a target fit a container (cover mode)
|
|
214
|
+
cover(target: FitInput, container: FitInput) => FitOutput;
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
```ts
|
|
218
|
+
// Make a target fit a container (contain mode)
|
|
219
|
+
contain(target: FitInput, container: FitInput) => FitOutput;
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
### MATHS
|
|
223
|
+
|
|
224
|
+
```ts
|
|
225
|
+
// Check if a number is even
|
|
226
|
+
isEven(value: number) => boolean;
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
```ts
|
|
230
|
+
// Check if a number is odd
|
|
231
|
+
isOdd(value: number) => boolean;
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
```ts
|
|
235
|
+
// Check if a number is a power of 2
|
|
236
|
+
isPowerOf2(value: number) => boolean;
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
```ts
|
|
240
|
+
// Find closest power of 2 that fits a number
|
|
241
|
+
toPowerOf2(value: number, mode?: 'floor' | 'ceil' | 'round') => number;
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
```ts
|
|
245
|
+
// Return the sign (positive or negative) of a number
|
|
246
|
+
sign(number: number) => number;
|
|
247
|
+
```
|
|
248
|
+
|
|
249
|
+
```ts
|
|
250
|
+
// Clamp a value between two bounds
|
|
251
|
+
clamp(value: number, min?: number, max?: number) => number;
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
```ts
|
|
255
|
+
// Linear interpolation between two values (lerping)
|
|
256
|
+
lerp(value: number, min: number, max: number) => number;
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
```ts
|
|
260
|
+
// Triangular interpolation between two values
|
|
261
|
+
triLerp(value: number, min: number, max: number, target: number) => number;
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
```ts
|
|
265
|
+
// Exponential interpolation between two values
|
|
266
|
+
expLerp(value: number, min: number, max: number) => number;
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
```ts
|
|
270
|
+
// Normalize a value between two bounds
|
|
271
|
+
normalize(value: number, min: number, max: number) => number;
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
```ts
|
|
275
|
+
// Re-map a number from one range to another
|
|
276
|
+
map(value: number, currentMin: number, currentMax: number, targetMin: number, targetMax: number) => number;
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
```ts
|
|
280
|
+
// Round a number up to a nearest multiple
|
|
281
|
+
roundTo(value: number, multiple?: number) => number;
|
|
282
|
+
```
|
|
283
|
+
|
|
284
|
+
```ts
|
|
285
|
+
// Modulo absolute a value based on a length
|
|
286
|
+
modAbs(value: number, length: number) => number;
|
|
287
|
+
```
|
|
288
|
+
|
|
289
|
+
```ts
|
|
290
|
+
// Move back and forth a value between 0 and length, so that it is never larger than length and never smaller than 0
|
|
291
|
+
pingPong(value: number, length: number) => number;
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
```ts
|
|
295
|
+
// Smooth a value using cubic Hermite interpolation
|
|
296
|
+
smoothstep(value: number, min?: number, max?: number) => number;
|
|
297
|
+
```
|
|
298
|
+
|
|
299
|
+
```ts
|
|
300
|
+
// Re-map the [0, 1] interval into [0, 1] parabola, such that corners are remaped to 0 and the center to 1
|
|
301
|
+
parabola(x: number, power?: number) => number;
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
```ts
|
|
305
|
+
// Return the sum of numbers
|
|
306
|
+
sum(array: number[]) => number;
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
```ts
|
|
310
|
+
// Return the average of numbers
|
|
311
|
+
average(array: number[]) => number;
|
|
312
|
+
```
|
|
313
|
+
|
|
314
|
+
```ts
|
|
315
|
+
// Smoothly interpolate a number toward another
|
|
316
|
+
damp(value: number, target: number, damping: number, delta: number) => number;
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
### NOW
|
|
320
|
+
|
|
321
|
+
```ts
|
|
322
|
+
// Polyfill for "now()" functions
|
|
323
|
+
now() => number;
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
### RANDOM
|
|
327
|
+
|
|
328
|
+
```ts
|
|
329
|
+
// Generate a random boolean (true or false)
|
|
330
|
+
randomBoolean(probability?: number) => boolean;
|
|
331
|
+
```
|
|
332
|
+
|
|
333
|
+
```ts
|
|
334
|
+
// Generate a random sign (1 or -1)
|
|
335
|
+
randomSign(probability?: number) => number;
|
|
336
|
+
```
|
|
337
|
+
|
|
338
|
+
```ts
|
|
339
|
+
// Generate a random float number
|
|
340
|
+
randomFloat(min?: number, max?: number, precision?: number) => number;
|
|
341
|
+
```
|
|
342
|
+
|
|
343
|
+
```ts
|
|
344
|
+
// Generate a random integer number
|
|
345
|
+
randomInt(min: number, max: number) => number;
|
|
346
|
+
```
|
|
347
|
+
|
|
348
|
+
```ts
|
|
349
|
+
// Generate a random hexadecimal color
|
|
350
|
+
randomHexColor() => string;
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
```ts
|
|
354
|
+
// Pick a random item from an array
|
|
355
|
+
randomItem<I>(array: I[] = []) => I | undefined;
|
|
356
|
+
```
|
|
357
|
+
|
|
358
|
+
```ts
|
|
359
|
+
// Pick a random property from an object
|
|
360
|
+
randomObjectProperty(object: object) => unknown | undefined;
|
|
361
|
+
```
|
|
362
|
+
|
|
363
|
+
```ts
|
|
364
|
+
// Return a random index from an array of weights
|
|
365
|
+
randomIndex(weights?: number[]) => number;
|
|
366
|
+
```
|
|
367
|
+
|
|
368
|
+
```ts
|
|
369
|
+
// Produce a random 2D point around the perimiter of a unit circle
|
|
370
|
+
onCircle(radius?: number, target?: Vector2) => Vector2;
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
```ts
|
|
374
|
+
// Produce a random 2D point inside a unit circle
|
|
375
|
+
insideCircle(radius?: number, target?: Vector2) => Vector2;
|
|
376
|
+
```
|
|
377
|
+
|
|
378
|
+
```ts
|
|
379
|
+
// Produce a random 3D point on the surface of a unit sphere
|
|
380
|
+
onSphere(radius?: number, target?: Vector3) => Vector3;
|
|
381
|
+
```
|
|
382
|
+
|
|
383
|
+
```ts
|
|
384
|
+
// Produce a random 3D point inside a unit sphere
|
|
385
|
+
insideSphere(radius?: number, target?: Vector3) => Vector3;
|
|
386
|
+
```
|
|
387
|
+
|
|
388
|
+
### STRINGS
|
|
389
|
+
|
|
390
|
+
```ts
|
|
391
|
+
// Capitalize a string
|
|
392
|
+
capitalize(string: string) => string;
|
|
393
|
+
```
|
|
394
|
+
|
|
395
|
+
```ts
|
|
396
|
+
// Clean a path by removing params
|
|
397
|
+
cleanPath(path: string) => string;
|
|
398
|
+
```
|
|
399
|
+
|
|
400
|
+
## Constants
|
|
401
|
+
|
|
402
|
+
`EPSILON`
|
|
403
|
+
|
|
404
|
+
`PI`
|
|
405
|
+
|
|
406
|
+
`TWO_PI`
|
|
407
|
+
|
|
408
|
+
`HALF_PI`
|
|
409
|
+
|
|
410
|
+
`QUARTER_PI`
|
|
411
|
+
|
|
412
|
+
`W3CX11`
|
|
413
|
+
|
|
414
|
+
## License
|
|
415
|
+
|
|
416
|
+
MIT License, see [LICENSE](https://github.com/toosoon-dev/toosoon-utils/tree/master/LICENSE) for details
|
package/lib/index.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export * from './colors';
|
|
2
|
-
export * from './dom';
|
|
3
|
-
export * from './files';
|
|
4
|
-
export * from './functions';
|
|
5
|
-
export * from './geometry';
|
|
6
|
-
export * from './maths';
|
|
7
|
-
export * from './now';
|
|
8
|
-
export * from './random';
|
|
9
|
-
export * from './strings';
|
|
10
|
-
export * from './constants';
|
|
11
|
-
export * from './types';
|
|
1
|
+
export * as colors from './colors';
|
|
2
|
+
export * as dom from './dom';
|
|
3
|
+
export * as files from './files';
|
|
4
|
+
export * as functions from './functions';
|
|
5
|
+
export * as geometry from './geometry';
|
|
6
|
+
export * as maths from './maths';
|
|
7
|
+
export * as now from './now';
|
|
8
|
+
export * as random from './random';
|
|
9
|
+
export * as strings from './strings';
|
|
10
|
+
export * as constants from './constants';
|
|
11
|
+
export type * as types from './types';
|
package/lib/index.js
CHANGED
|
@@ -10,18 +10,27 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
|
|
|
10
10
|
if (k2 === undefined) k2 = k;
|
|
11
11
|
o[k2] = m[k];
|
|
12
12
|
}));
|
|
13
|
-
var
|
|
14
|
-
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
15
24
|
};
|
|
16
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
exports.constants = exports.strings = exports.random = exports.now = exports.maths = exports.geometry = exports.functions = exports.files = exports.dom = exports.colors = void 0;
|
|
27
|
+
exports.colors = __importStar(require("./colors"));
|
|
28
|
+
exports.dom = __importStar(require("./dom"));
|
|
29
|
+
exports.files = __importStar(require("./files"));
|
|
30
|
+
exports.functions = __importStar(require("./functions"));
|
|
31
|
+
exports.geometry = __importStar(require("./geometry"));
|
|
32
|
+
exports.maths = __importStar(require("./maths"));
|
|
33
|
+
exports.now = __importStar(require("./now"));
|
|
34
|
+
exports.random = __importStar(require("./random"));
|
|
35
|
+
exports.strings = __importStar(require("./strings"));
|
|
36
|
+
exports.constants = __importStar(require("./constants"));
|
package/lib/tsconfig.tsbuildinfo
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"program":{"fileNames":["../node_modules/typescript/lib/lib.d.ts","../node_modules/typescript/lib/lib.es5.d.ts","../node_modules/typescript/lib/lib.es2015.d.ts","../node_modules/typescript/lib/lib.es2016.d.ts","../node_modules/typescript/lib/lib.es2017.d.ts","../node_modules/typescript/lib/lib.es2018.d.ts","../node_modules/typescript/lib/lib.es2019.d.ts","../node_modules/typescript/lib/lib.es2020.d.ts","../node_modules/typescript/lib/lib.dom.d.ts","../node_modules/typescript/lib/lib.webworker.importscripts.d.ts","../node_modules/typescript/lib/lib.scripthost.d.ts","../node_modules/typescript/lib/lib.es2015.core.d.ts","../node_modules/typescript/lib/lib.es2015.collection.d.ts","../node_modules/typescript/lib/lib.es2015.generator.d.ts","../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../node_modules/typescript/lib/lib.es2015.promise.d.ts","../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../node_modules/typescript/lib/lib.es2017.date.d.ts","../node_modules/typescript/lib/lib.es2017.object.d.ts","../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../node_modules/typescript/lib/lib.es2017.string.d.ts","../node_modules/typescript/lib/lib.es2017.intl.d.ts","../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../node_modules/typescript/lib/lib.es2018.intl.d.ts","../node_modules/typescript/lib/lib.es2018.promise.d.ts","../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../node_modules/typescript/lib/lib.es2019.array.d.ts","../node_modules/typescript/lib/lib.es2019.object.d.ts","../node_modules/typescript/lib/lib.es2019.string.d.ts","../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../node_modules/typescript/lib/lib.es2019.intl.d.ts","../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../node_modules/typescript/lib/lib.es2020.date.d.ts","../node_modules/typescript/lib/lib.es2020.promise.d.ts","../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../node_modules/typescript/lib/lib.es2020.string.d.ts","../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../node_modules/typescript/lib/lib.es2020.intl.d.ts","../node_modules/typescript/lib/lib.es2020.number.d.ts","../node_modules/typescript/lib/lib.esnext.intl.d.ts","../node_modules/typescript/lib/lib.decorators.d.ts","../node_modules/typescript/lib/lib.decorators.legacy.d.ts","../src/constants.ts","../src/types.ts","../src/geometry.ts","../src/maths.ts","../src/colors.ts","../src/dom.ts","../src/files.ts","../src/functions.ts","../src/now.ts","../src/random.ts","../src/strings.ts","../src/index.ts","../node_modules/@types/node/assert.d.ts","../node_modules/@types/node/assert/strict.d.ts","../node_modules/undici-types/header.d.ts","../node_modules/undici-types/readable.d.ts","../node_modules/undici-types/file.d.ts","../node_modules/undici-types/fetch.d.ts","../node_modules/undici-types/formdata.d.ts","../node_modules/undici-types/connector.d.ts","../node_modules/undici-types/client.d.ts","../node_modules/undici-types/errors.d.ts","../node_modules/undici-types/dispatcher.d.ts","../node_modules/undici-types/global-dispatcher.d.ts","../node_modules/undici-types/global-origin.d.ts","../node_modules/undici-types/pool-stats.d.ts","../node_modules/undici-types/pool.d.ts","../node_modules/undici-types/handlers.d.ts","../node_modules/undici-types/balanced-pool.d.ts","../node_modules/undici-types/agent.d.ts","../node_modules/undici-types/mock-interceptor.d.ts","../node_modules/undici-types/mock-agent.d.ts","../node_modules/undici-types/mock-client.d.ts","../node_modules/undici-types/mock-pool.d.ts","../node_modules/undici-types/mock-errors.d.ts","../node_modules/undici-types/proxy-agent.d.ts","../node_modules/undici-types/api.d.ts","../node_modules/undici-types/cookies.d.ts","../node_modules/undici-types/patch.d.ts","../node_modules/undici-types/filereader.d.ts","../node_modules/undici-types/diagnostics-channel.d.ts","../node_modules/undici-types/websocket.d.ts","../node_modules/undici-types/content-type.d.ts","../node_modules/undici-types/cache.d.ts","../node_modules/undici-types/interceptors.d.ts","../node_modules/undici-types/index.d.ts","../node_modules/@types/node/globals.d.ts","../node_modules/@types/node/async_hooks.d.ts","../node_modules/@types/node/buffer.d.ts","../node_modules/@types/node/child_process.d.ts","../node_modules/@types/node/cluster.d.ts","../node_modules/@types/node/console.d.ts","../node_modules/@types/node/constants.d.ts","../node_modules/@types/node/crypto.d.ts","../node_modules/@types/node/dgram.d.ts","../node_modules/@types/node/diagnostics_channel.d.ts","../node_modules/@types/node/dns.d.ts","../node_modules/@types/node/dns/promises.d.ts","../node_modules/@types/node/domain.d.ts","../node_modules/@types/node/dom-events.d.ts","../node_modules/@types/node/events.d.ts","../node_modules/@types/node/fs.d.ts","../node_modules/@types/node/fs/promises.d.ts","../node_modules/@types/node/http.d.ts","../node_modules/@types/node/http2.d.ts","../node_modules/@types/node/https.d.ts","../node_modules/@types/node/inspector.d.ts","../node_modules/@types/node/module.d.ts","../node_modules/@types/node/net.d.ts","../node_modules/@types/node/os.d.ts","../node_modules/@types/node/path.d.ts","../node_modules/@types/node/perf_hooks.d.ts","../node_modules/@types/node/process.d.ts","../node_modules/@types/node/punycode.d.ts","../node_modules/@types/node/querystring.d.ts","../node_modules/@types/node/readline.d.ts","../node_modules/@types/node/readline/promises.d.ts","../node_modules/@types/node/repl.d.ts","../node_modules/@types/node/stream.d.ts","../node_modules/@types/node/stream/promises.d.ts","../node_modules/@types/node/stream/consumers.d.ts","../node_modules/@types/node/stream/web.d.ts","../node_modules/@types/node/string_decoder.d.ts","../node_modules/@types/node/test.d.ts","../node_modules/@types/node/timers.d.ts","../node_modules/@types/node/timers/promises.d.ts","../node_modules/@types/node/tls.d.ts","../node_modules/@types/node/trace_events.d.ts","../node_modules/@types/node/tty.d.ts","../node_modules/@types/node/url.d.ts","../node_modules/@types/node/util.d.ts","../node_modules/@types/node/v8.d.ts","../node_modules/@types/node/vm.d.ts","../node_modules/@types/node/wasi.d.ts","../node_modules/@types/node/worker_threads.d.ts","../node_modules/@types/node/zlib.d.ts","../node_modules/@types/node/globals.global.d.ts","../node_modules/@types/node/index.d.ts"],"fileInfos":["a7297ff837fcdf174a9524925966429eb8e5feecc2cc55cc06574e6b092c1eaa",{"version":"f33e5332b24c3773e930e212cbb8b6867c8ba3ec4492064ea78e55a524d57450","affectsGlobalScope":true},"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","26f2f787e82c4222710f3b676b4d83eb5ad0a72fa7b746f03449e7a026ce5073","9a68c0c07ae2fa71b44384a839b7b8d81662a236d4b9ac30916718f7510b1b2d","5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4",{"version":"21e41a76098aa7a191028256e52a726baafd45a925ea5cf0222eb430c96c1d83","affectsGlobalScope":true},{"version":"80e18897e5884b6723488d4f5652167e7bb5024f946743134ecc4aa4ee731f89","affectsGlobalScope":true},{"version":"cd034f499c6cdca722b60c04b5b1b78e058487a7085a8e0d6fb50809947ee573","affectsGlobalScope":true},{"version":"138fb588d26538783b78d1e3b2c2cc12d55840b97bf5e08bca7f7a174fbe2f17","affectsGlobalScope":true},{"version":"dc2df20b1bcdc8c2d34af4926e2c3ab15ffe1160a63e58b7e09833f616efff44","affectsGlobalScope":true},{"version":"4443e68b35f3332f753eacc66a04ac1d2053b8b035a0e0ac1d455392b5e243b3","affectsGlobalScope":true},{"version":"bc47685641087c015972a3f072480889f0d6c65515f12bd85222f49a98952ed7","affectsGlobalScope":true},{"version":"0dc1e7ceda9b8b9b455c3a2d67b0412feab00bd2f66656cd8850e8831b08b537","affectsGlobalScope":true},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true},{"version":"4ff2a353abf8a80ee399af572debb8faab2d33ad38c4b4474cff7f26e7653b8d","affectsGlobalScope":true},{"version":"93495ff27b8746f55d19fcbcdbaccc99fd95f19d057aed1bd2c0cafe1335fbf0","affectsGlobalScope":true},{"version":"6fc23bb8c3965964be8c597310a2878b53a0306edb71d4b5a4dfe760186bcc01","affectsGlobalScope":true},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true},{"version":"bb42a7797d996412ecdc5b2787720de477103a0b2e53058569069a0e2bae6c7e","affectsGlobalScope":true},{"version":"4738f2420687fd85629c9efb470793bb753709c2379e5f85bc1815d875ceadcd","affectsGlobalScope":true},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true},{"version":"4de680d5bb41c17f7f68e0419412ca23c98d5749dcaaea1896172f06435891fc","affectsGlobalScope":true},{"version":"9fc46429fbe091ac5ad2608c657201eb68b6f1b8341bd6d670047d32ed0a88fa","affectsGlobalScope":true},{"version":"61c37c1de663cf4171e1192466e52c7a382afa58da01b1dc75058f032ddf0839","affectsGlobalScope":true},{"version":"b541a838a13f9234aba650a825393ffc2292dc0fc87681a5d81ef0c96d281e7a","affectsGlobalScope":true},{"version":"e0275cd0e42990dc3a16f0b7c8bca3efe87f1c8ad404f80c6db1c7c0b828c59f","affectsGlobalScope":true},{"version":"811ec78f7fefcabbda4bfa93b3eb67d9ae166ef95f9bff989d964061cbf81a0c","affectsGlobalScope":true},{"version":"717937616a17072082152a2ef351cb51f98802fb4b2fdabd32399843875974ca","affectsGlobalScope":true},{"version":"d7e7d9b7b50e5f22c915b525acc5a49a7a6584cf8f62d0569e557c5cfc4b2ac2","affectsGlobalScope":true},{"version":"71c37f4c9543f31dfced6c7840e068c5a5aacb7b89111a4364b1d5276b852557","affectsGlobalScope":true},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true},{"version":"49ed889be54031e1044af0ad2c603d627b8bda8b50c1a68435fe85583901d072","affectsGlobalScope":true},{"version":"e93d098658ce4f0c8a0779e6cab91d0259efb88a318137f686ad76f8410ca270","affectsGlobalScope":true},{"version":"063600664504610fe3e99b717a1223f8b1900087fab0b4cad1496a114744f8df","affectsGlobalScope":true},{"version":"934019d7e3c81950f9a8426d093458b65d5aff2c7c1511233c0fd5b941e608ab","affectsGlobalScope":true},{"version":"bf14a426dbbf1022d11bd08d6b8e709a2e9d246f0c6c1032f3b2edb9a902adbe","affectsGlobalScope":true},{"version":"ec0104fee478075cb5171e5f4e3f23add8e02d845ae0165bfa3f1099241fa2aa","affectsGlobalScope":true},{"version":"2b72d528b2e2fe3c57889ca7baef5e13a56c957b946906d03767c642f386bbc3","affectsGlobalScope":true},{"version":"acae90d417bee324b1372813b5a00829d31c7eb670d299cd7f8f9a648ac05688","affectsGlobalScope":true},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true},{"version":"13f6e6380c78e15e140243dc4be2fa546c287c6d61f4729bc2dd7cf449605471","affectsGlobalScope":true},{"version":"33358442698bb565130f52ba79bfd3d4d484ac85fe33f3cb1759c54d18201393","affectsGlobalScope":true},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true},{"version":"c10f64b494e9a37f8bd983e874a03a17670d8405d98c7a065821921c545a48f7","signature":"8375cf161a0f21acd9ff0b3bc4c00780dfdfe6b508f312dd839702d8c4251c68"},{"version":"223745a7683ea5a3522e0d6419b0e639e10e5408aff27b86568901fef768f591","signature":"50c69a2b59e87e2aebdd6294b41cf6d9896ce198d05b4c1691d832a48c5393f4"},{"version":"cc859cf585321ba13306b886bcf6970f5745db282e886226da571d148fdcbb46","signature":"600074017fd954caf6d25d3111edb02aaa24bd91074d928cd02a2d713d6ea757"},{"version":"bcbd63cc0e57b35308858e624267b68ee6d9c9d02cb0a2d847fad074a33efd30","signature":"0ee705cedd747b89444ca301c710e45a43fa2f46be6eee021c204e677485b2da"},{"version":"6a7bca3c2a73ac500fce173f0af0491cd3dbb8c80196fa39dab02a47ac91fc95","signature":"3510aeb3423ac8b327be41d4bbd7cb499f66d8e0fbeb9066602a7436dbc45d51"},{"version":"5fca568d9fe91b3c1d6928a962bd8874ceaad50d8ce7355efb333dfc9e7b087a","signature":"3de595b5b4fe6c50f526b62dc9536c54ba6f97f7c7652d5730914de3be6cdaac"},{"version":"cdac34b1bfa8c5301a99aae634399581b07d441a342b2e99af272efacd28bf33","signature":"aefd19e3ecee790394b8e83bef9e0edb96417d603367ac43459bebad63de0048"},{"version":"704ae5b207e9e2554a1fbfea2e5055d23a1e9735819c868ccf7935d05080bfc8","signature":"7a629cbd546b33944f330f69db11c17a1121dad8ba23b6d232ff8c5d9ef28e58"},{"version":"07b66ab5b8a992f40130fe16efd6874a337ea4a651762bd169181ad15043ee1d","signature":"d43b3a78108cb3511d734b51e03e24ac5dc922e9791dded3ded9dc567629c838"},{"version":"52cbd1c8d55a99cb3f58c09f4537890345baba3e4913a0afcd962ac8916ed799","signature":"661d17747fcf18e933f4f73cea2589d144d39499e7686abb665335f6b01ddeab"},{"version":"7ff1ac0e7aebca773d04dda761bca41d14320e0622ef69f6f2447e7b000f4fa7","signature":"399d115998e6ee77790354467a58babe1c7ee7caba7eed1bf471f4ec8a9a365f"},{"version":"c9aff01f7720775b1365489a4a3aed910bca1c6420ed71dea163cbd67906d850","signature":"5c8e49206787be9b02bf3e581c239d9cf71efbb8e82834ecd1b159936f1277c7"},"efc7d584a33fe3422847783d228f315c4cd1afe74bd7cf8e3f0e4c1125129fef","7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419","5929864ce17fba74232584d90cb721a89b7ad277220627cc97054ba15a98ea8f","7180c03fd3cb6e22f911ce9ba0f8a7008b1a6ddbe88ccf16a9c8140ef9ac1686","25c8056edf4314820382a5fdb4bb7816999acdcb929c8f75e3f39473b87e85bc","54cb85a47d760da1c13c00add10d26b5118280d44d58e6908d8e89abbd9d7725","3e4825171442666d31c845aeb47fcd34b62e14041bb353ae2b874285d78482aa","c6fd2c5a395f2432786c9cb8deb870b9b0e8ff7e22c029954fabdd692bff6195","a967bfe3ad4e62243eb604bf956101e4c740f5921277c60debaf325c1320bf88","e9775e97ac4877aebf963a0289c81abe76d1ec9a2a7778dbe637e5151f25c5f3","471e1da5a78350bc55ef8cef24eb3aca6174143c281b8b214ca2beda51f5e04a","cadc8aced301244057c4e7e73fbcae534b0f5b12a37b150d80e5a45aa4bebcbd","385aab901643aa54e1c36f5ef3107913b10d1b5bb8cbcd933d4263b80a0d7f20","9670d44354bab9d9982eca21945686b5c24a3f893db73c0dae0fd74217a4c219","db3435f3525cd785bf21ec6769bf8da7e8a776be1a99e2e7efb5f244a2ef5fee","c3b170c45fc031db31f782e612adf7314b167e60439d304b49e704010e7bafe5","40383ebef22b943d503c6ce2cb2e060282936b952a01bea5f9f493d5fb487cc7","4893a895ea92c85345017a04ed427cbd6a1710453338df26881a6019432febdd","3a84b7cb891141824bd00ef8a50b6a44596aded4075da937f180c90e362fe5f6","13f6f39e12b1518c6650bbb220c8985999020fe0f21d818e28f512b7771d00f9","9b5369969f6e7175740bf51223112ff209f94ba43ecd3bb09eefff9fd675624a","4fe9e626e7164748e8769bbf74b538e09607f07ed17c2f20af8d680ee49fc1da","24515859bc0b836719105bb6cc3d68255042a9f02a6022b3187948b204946bd2","33203609eba548914dc83ddf6cadbc0bcb6e8ef89f6d648ca0908ae887f9fcc5","0db18c6e78ea846316c012478888f33c11ffadab9efd1cc8bcc12daded7a60b6","89167d696a849fce5ca508032aabfe901c0868f833a8625d5a9c6e861ef935d2","e53a3c2a9f624d90f24bf4588aacd223e7bec1b9d0d479b68d2f4a9e6011147f","339dc5265ee5ed92e536a93a04c4ebbc2128f45eeec6ed29f379e0085283542c","9f0a92164925aa37d4a5d9dd3e0134cff8177208dba55fd2310cd74beea40ee2","8bfdb79bf1a9d435ec48d9372dc93291161f152c0865b81fc0b2694aedb4578d","2e85db9e6fd73cfa3d7f28e0ab6b55417ea18931423bd47b409a96e4a169e8e6","c46e079fe54c76f95c67fb89081b3e399da2c7d109e7dca8e4b58d83e332e605","d32275be3546f252e3ad33976caf8c5e842c09cb87d468cb40d5f4cf092d1acc","4a0c3504813a3289f7fb1115db13967c8e004aa8e4f8a9021b95285502221bd1",{"version":"a14ed46fa3f5ffc7a8336b497cd07b45c2084213aaca933a22443fcb2eef0d07","affectsGlobalScope":true},"cce1f5f86974c1e916ec4a8cab6eec9aa8e31e8148845bf07fbaa8e1d97b1a2c",{"version":"e2eb1ce13a9c0fa7ab62c63909d81973ef4b707292667c64f1e25e6e53fa7afa","affectsGlobalScope":true},"16d74fe4d8e183344d3beb15d48b123c5980ff32ff0cc8c3b96614ddcdf9b239","7b43160a49cf2c6082da0465876c4a0b164e160b81187caeb0a6ca7a281e85ba",{"version":"41fb2a1c108fbf46609ce5a451b7ec78eb9b5ada95fd5b94643e4b26397de0b3","affectsGlobalScope":true},"a40826e8476694e90da94aa008283a7de50d1dafd37beada623863f1901cb7fb",{"version":"a1d2988ad9d2aef7b9915a22b5e52c165c83a878f2851c35621409046bbe3c05","affectsGlobalScope":true},"bd3f5d05b6b5e4bfcea7739a45f3ffb4a7f4a3442ba7baf93e0200799285b8f1","4c775c2fccabf49483c03cd5e3673f87c1ffb6079d98e7b81089c3def79e29c6","8806ae97308ef26363bd7ec8071bca4d07fb575f905ee3d8a91aff226df6d618","af5bf1db6f1804fb0069039ae77a05d60133c77a2158d9635ea27b6bb2828a8f","b7fe70be794e13d1b7940e318b8770cd1fb3eced7707805318a2e3aaac2c3e9e",{"version":"2c71199d1fc83bf17636ad5bf63a945633406b7b94887612bba4ef027c662b3e","affectsGlobalScope":true},{"version":"7ae9dc7dbb58cd843065639707815df85c044babaa0947116f97bdb824d07204","affectsGlobalScope":true},"fe1fd6afdfe77976d4c702f3746c05fb05a7e566845c890e0e970fe9376d6a90","313a0b063f5188037db113509de1b934a0e286f14e9479af24fada241435e707","f1ace2d2f98429e007d017c7a445efad2aaebf8233135abdb2c88b8c0fef91ab","87ef1a23caa071b07157c72077fa42b86d30568f9dc9e31eed24d5d14fc30ba8","396a8939b5e177542bdf9b5262b4eee85d29851b2d57681fa9d7eae30e225830","21773f5ac69ddf5a05636ba1f50b5239f4f2d27e4420db147fc2f76a5ae598ac",{"version":"ea455cc68871b049bcecd9f56d4cf27b852d6dafd5e3b54468ca87cc11604e4d","affectsGlobalScope":true},"c07146dbbbd8b347241b5df250a51e48f2d7bef19b1e187b1a3f20c849988ff1","45b1053e691c5af9bfe85060a3e1542835f8d84a7e6e2e77ca305251eda0cb3c","0f05c06ff6196958d76b865ae17245b52d8fe01773626ac3c43214a2458ea7b7",{"version":"ae5507fc333d637dec9f37c6b3f4d423105421ea2820a64818de55db85214d66","affectsGlobalScope":true},{"version":"0666f4c99b8688c7be5956df8fecf5d1779d3b22f8f2a88258ae7072c7b6026f","affectsGlobalScope":true},"8abd0566d2854c4bd1c5e48e05df5c74927187f1541e6770001d9637ac41542e","54e854615c4eafbdd3fd7688bd02a3aafd0ccf0e87c98f79d3e9109f047ce6b8","d8dba11dc34d50cb4202de5effa9a1b296d7a2f4a029eec871f894bddfb6430d","8b71dd18e7e63b6f991b511a201fad7c3bf8d1e0dd98acb5e3d844f335a73634","01d8e1419c84affad359cc240b2b551fb9812b450b4d3d456b64cda8102d4f60","8221b00f271cf7f535a8eeec03b0f80f0929c7a16116e2d2df089b41066de69b","269929a24b2816343a178008ac9ae9248304d92a8ba8e233055e0ed6dbe6ef71","93452d394fdd1dc551ec62f5042366f011a00d342d36d50793b3529bfc9bd633","7424817d5eb498771e6d1808d726ec38f75d2eaf3fa359edd5c0c540c52725c1","9a9634296cca836c3308923ba7aa094fa6ed76bb1e366d8ddcf5c65888ab1024",{"version":"bddce945d552a963c9733db106b17a25474eefcab7fc990157a2134ef55d4954","affectsGlobalScope":true},{"version":"7052b7b0c3829df3b4985bab2fd74531074b4835d5a7b263b75c82f0916ad62f","affectsGlobalScope":true},"aa34c3aa493d1c699601027c441b9664547c3024f9dbab1639df7701d63d18fa","4b55240c2a03b2c71e98a7fc528b16136faa762211c92e781a01c37821915ea6","7c651f8dce91a927ab62925e73f190763574c46098f2b11fb8ddc1b147a6709a","7440ab60f4cb031812940cc38166b8bb6fbf2540cfe599f87c41c08011f0c1df",{"version":"94c086dff8dbc5998749326bc69b520e8e4273fb5b7b58b50e0210e0885dfcde","affectsGlobalScope":true},{"version":"f5b5dc128973498b75f52b1b8c2d5f8629869104899733ae485100c2309b4c12","affectsGlobalScope":true},"ebe5facd12fd7745cda5f4bc3319f91fb29dc1f96e57e9c6f8b260a7cc5b67ee","79bad8541d5779c85e82a9fb119c1fe06af77a71cc40f869d62ad379473d4b75","37dc027f781c75f0f546e329cfac7cf92a6b289f42458f47a9adc25e516b6839",{"version":"629d20681ca284d9e38c0a019f647108f5fe02f9c59ac164d56f5694fc3faf4d","affectsGlobalScope":true},"e7dbf5716d76846c7522e910896c5747b6df1abd538fee8f5291bdc843461795",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"b510d0a18e3db42ac9765d26711083ec1e8b4e21caaca6dc4d25ae6e8623f447"],"root":[[49,60]],"options":{"allowJs":true,"allowSyntheticDefaultImports":true,"declaration":true,"esModuleInterop":true,"experimentalDecorators":true,"module":1,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","skipLibCheck":true,"strict":true,"target":1},"fileIdsList":[[61],[96],[97,102,130],[98,109,110,117,127,138],[98,99,109,117],[100,139],[101,102,110,118],[102,127,135],[103,105,109,117],[96,104],[105,106],[109],[107,109],[96,109],[109,110,111,127,138],[109,110,111,124,127,130],[94,97,143],[105,109,112,117,127,138],[109,110,112,113,117,127,135,138],[112,114,127,135,138],[61,62,95,96,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],[109,115],[116,138,143],[105,109,117,127],[118],[119],[96,120],[121,137,143],[122],[123],[109,124,125],[124,126,139,141],[97,109,127,128,129,130],[97,127,129],[127,128],[130],[131],[96,127],[109,133,134],[133,134],[102,117,127,135],[136],[117,137],[97,112,123,138],[102,139],[127,140],[116,141],[142],[97,102,109,111,120,127,138,141,143],[127,144],[71,75,138],[71,127,138],[66],[68,71,135,138],[117,135],[146],[66,146],[68,71,117,138],[63,64,67,70,97,109,127,138],[63,69],[67,71,97,130,138,146],[97,146],[87,97,146],[65,66,146],[71],[65,66,67,68,69,70,71,72,73,75,76,77,78,79,80,81,82,83,84,85,86,88,89,90,91,92,93],[71,78,79],[69,71,79,80],[70],[63,66,71],[71,75,79,80],[75],[69,71,74,138],[63,68,69,71,75,78],[97,127],[66,71,87,97,143,146],[51,52],[50],[49,50],[49,50,51,52,53,54,55,56,57,58,59],[50,51]],"referencedMap":[[61,1],[62,1],[96,2],[97,3],[98,4],[99,5],[100,6],[101,7],[102,8],[103,9],[104,10],[105,11],[106,11],[108,12],[107,13],[109,14],[110,15],[111,16],[95,17],[112,18],[113,19],[114,20],[146,21],[115,22],[116,23],[117,24],[118,25],[119,26],[120,27],[121,28],[122,29],[123,30],[124,31],[125,31],[126,32],[127,33],[129,34],[128,35],[130,36],[131,37],[132,38],[133,39],[134,40],[135,41],[136,42],[137,43],[138,44],[139,45],[140,46],[141,47],[142,48],[143,49],[144,50],[78,51],[85,52],[77,51],[92,53],[69,54],[68,55],[91,56],[86,57],[89,58],[71,59],[70,60],[66,61],[65,62],[88,63],[67,64],[72,65],[76,65],[94,66],[93,65],[80,67],[81,68],[83,69],[79,70],[82,71],[87,56],[74,72],[75,73],[84,74],[64,75],[90,76],[53,77],[56,78],[51,79],[60,80],[58,81]],"exportedModulesMap":[[61,1],[62,1],[96,2],[97,3],[98,4],[99,5],[100,6],[101,7],[102,8],[103,9],[104,10],[105,11],[106,11],[108,12],[107,13],[109,14],[110,15],[111,16],[95,17],[112,18],[113,19],[114,20],[146,21],[115,22],[116,23],[117,24],[118,25],[119,26],[120,27],[121,28],[122,29],[123,30],[124,31],[125,31],[126,32],[127,33],[129,34],[128,35],[130,36],[131,37],[132,38],[133,39],[134,40],[135,41],[136,42],[137,43],[138,44],[139,45],[140,46],[141,47],[142,48],[143,49],[144,50],[78,51],[85,52],[77,51],[92,53],[69,54],[68,55],[91,56],[86,57],[89,58],[71,59],[70,60],[66,61],[65,62],[88,63],[67,64],[72,65],[76,65],[94,66],[93,65],[80,67],[81,68],[83,69],[79,70],[82,71],[87,56],[74,72],[75,73],[84,74],[64,75],[90,76],[56,78],[51,78],[60,80],[58,78]],"semanticDiagnosticsPerFile":[61,62,96,97,98,99,100,101,102,103,104,105,106,108,107,109,110,111,95,145,112,113,114,146,115,116,117,118,119,120,121,122,123,124,125,126,127,129,128,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,1,47,48,9,13,12,3,14,15,16,17,18,19,20,21,4,5,22,26,23,24,25,27,28,29,6,30,31,32,33,7,37,34,35,36,38,8,39,44,45,40,41,42,43,2,46,11,10,78,85,77,92,69,68,91,86,89,71,70,66,65,88,67,72,73,76,63,94,93,80,81,83,79,82,87,74,75,84,64,90,53,49,54,55,56,51,60,52,57,58,59,50]},"version":"5.3.3"}
|
|
1
|
+
{"program":{"fileNames":["../node_modules/typescript/lib/lib.d.ts","../node_modules/typescript/lib/lib.es5.d.ts","../node_modules/typescript/lib/lib.es2015.d.ts","../node_modules/typescript/lib/lib.es2016.d.ts","../node_modules/typescript/lib/lib.es2017.d.ts","../node_modules/typescript/lib/lib.es2018.d.ts","../node_modules/typescript/lib/lib.es2019.d.ts","../node_modules/typescript/lib/lib.es2020.d.ts","../node_modules/typescript/lib/lib.dom.d.ts","../node_modules/typescript/lib/lib.webworker.importscripts.d.ts","../node_modules/typescript/lib/lib.scripthost.d.ts","../node_modules/typescript/lib/lib.es2015.core.d.ts","../node_modules/typescript/lib/lib.es2015.collection.d.ts","../node_modules/typescript/lib/lib.es2015.generator.d.ts","../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../node_modules/typescript/lib/lib.es2015.promise.d.ts","../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../node_modules/typescript/lib/lib.es2017.date.d.ts","../node_modules/typescript/lib/lib.es2017.object.d.ts","../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../node_modules/typescript/lib/lib.es2017.string.d.ts","../node_modules/typescript/lib/lib.es2017.intl.d.ts","../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../node_modules/typescript/lib/lib.es2018.intl.d.ts","../node_modules/typescript/lib/lib.es2018.promise.d.ts","../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../node_modules/typescript/lib/lib.es2019.array.d.ts","../node_modules/typescript/lib/lib.es2019.object.d.ts","../node_modules/typescript/lib/lib.es2019.string.d.ts","../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../node_modules/typescript/lib/lib.es2019.intl.d.ts","../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../node_modules/typescript/lib/lib.es2020.date.d.ts","../node_modules/typescript/lib/lib.es2020.promise.d.ts","../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../node_modules/typescript/lib/lib.es2020.string.d.ts","../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../node_modules/typescript/lib/lib.es2020.intl.d.ts","../node_modules/typescript/lib/lib.es2020.number.d.ts","../node_modules/typescript/lib/lib.esnext.intl.d.ts","../node_modules/typescript/lib/lib.decorators.d.ts","../node_modules/typescript/lib/lib.decorators.legacy.d.ts","../src/constants.ts","../src/types.ts","../src/geometry.ts","../src/maths.ts","../src/colors.ts","../src/dom.ts","../src/files.ts","../src/functions.ts","../src/now.ts","../src/random.ts","../src/strings.ts","../src/index.ts","../node_modules/@types/node/assert.d.ts","../node_modules/@types/node/assert/strict.d.ts","../node_modules/undici-types/header.d.ts","../node_modules/undici-types/readable.d.ts","../node_modules/undici-types/file.d.ts","../node_modules/undici-types/fetch.d.ts","../node_modules/undici-types/formdata.d.ts","../node_modules/undici-types/connector.d.ts","../node_modules/undici-types/client.d.ts","../node_modules/undici-types/errors.d.ts","../node_modules/undici-types/dispatcher.d.ts","../node_modules/undici-types/global-dispatcher.d.ts","../node_modules/undici-types/global-origin.d.ts","../node_modules/undici-types/pool-stats.d.ts","../node_modules/undici-types/pool.d.ts","../node_modules/undici-types/handlers.d.ts","../node_modules/undici-types/balanced-pool.d.ts","../node_modules/undici-types/agent.d.ts","../node_modules/undici-types/mock-interceptor.d.ts","../node_modules/undici-types/mock-agent.d.ts","../node_modules/undici-types/mock-client.d.ts","../node_modules/undici-types/mock-pool.d.ts","../node_modules/undici-types/mock-errors.d.ts","../node_modules/undici-types/proxy-agent.d.ts","../node_modules/undici-types/api.d.ts","../node_modules/undici-types/cookies.d.ts","../node_modules/undici-types/patch.d.ts","../node_modules/undici-types/filereader.d.ts","../node_modules/undici-types/diagnostics-channel.d.ts","../node_modules/undici-types/websocket.d.ts","../node_modules/undici-types/content-type.d.ts","../node_modules/undici-types/cache.d.ts","../node_modules/undici-types/interceptors.d.ts","../node_modules/undici-types/index.d.ts","../node_modules/@types/node/globals.d.ts","../node_modules/@types/node/async_hooks.d.ts","../node_modules/@types/node/buffer.d.ts","../node_modules/@types/node/child_process.d.ts","../node_modules/@types/node/cluster.d.ts","../node_modules/@types/node/console.d.ts","../node_modules/@types/node/constants.d.ts","../node_modules/@types/node/crypto.d.ts","../node_modules/@types/node/dgram.d.ts","../node_modules/@types/node/diagnostics_channel.d.ts","../node_modules/@types/node/dns.d.ts","../node_modules/@types/node/dns/promises.d.ts","../node_modules/@types/node/domain.d.ts","../node_modules/@types/node/dom-events.d.ts","../node_modules/@types/node/events.d.ts","../node_modules/@types/node/fs.d.ts","../node_modules/@types/node/fs/promises.d.ts","../node_modules/@types/node/http.d.ts","../node_modules/@types/node/http2.d.ts","../node_modules/@types/node/https.d.ts","../node_modules/@types/node/inspector.d.ts","../node_modules/@types/node/module.d.ts","../node_modules/@types/node/net.d.ts","../node_modules/@types/node/os.d.ts","../node_modules/@types/node/path.d.ts","../node_modules/@types/node/perf_hooks.d.ts","../node_modules/@types/node/process.d.ts","../node_modules/@types/node/punycode.d.ts","../node_modules/@types/node/querystring.d.ts","../node_modules/@types/node/readline.d.ts","../node_modules/@types/node/readline/promises.d.ts","../node_modules/@types/node/repl.d.ts","../node_modules/@types/node/stream.d.ts","../node_modules/@types/node/stream/promises.d.ts","../node_modules/@types/node/stream/consumers.d.ts","../node_modules/@types/node/stream/web.d.ts","../node_modules/@types/node/string_decoder.d.ts","../node_modules/@types/node/test.d.ts","../node_modules/@types/node/timers.d.ts","../node_modules/@types/node/timers/promises.d.ts","../node_modules/@types/node/tls.d.ts","../node_modules/@types/node/trace_events.d.ts","../node_modules/@types/node/tty.d.ts","../node_modules/@types/node/url.d.ts","../node_modules/@types/node/util.d.ts","../node_modules/@types/node/v8.d.ts","../node_modules/@types/node/vm.d.ts","../node_modules/@types/node/wasi.d.ts","../node_modules/@types/node/worker_threads.d.ts","../node_modules/@types/node/zlib.d.ts","../node_modules/@types/node/globals.global.d.ts","../node_modules/@types/node/index.d.ts"],"fileInfos":["a7297ff837fcdf174a9524925966429eb8e5feecc2cc55cc06574e6b092c1eaa",{"version":"f33e5332b24c3773e930e212cbb8b6867c8ba3ec4492064ea78e55a524d57450","affectsGlobalScope":true},"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","26f2f787e82c4222710f3b676b4d83eb5ad0a72fa7b746f03449e7a026ce5073","9a68c0c07ae2fa71b44384a839b7b8d81662a236d4b9ac30916718f7510b1b2d","5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4",{"version":"21e41a76098aa7a191028256e52a726baafd45a925ea5cf0222eb430c96c1d83","affectsGlobalScope":true},{"version":"80e18897e5884b6723488d4f5652167e7bb5024f946743134ecc4aa4ee731f89","affectsGlobalScope":true},{"version":"cd034f499c6cdca722b60c04b5b1b78e058487a7085a8e0d6fb50809947ee573","affectsGlobalScope":true},{"version":"138fb588d26538783b78d1e3b2c2cc12d55840b97bf5e08bca7f7a174fbe2f17","affectsGlobalScope":true},{"version":"dc2df20b1bcdc8c2d34af4926e2c3ab15ffe1160a63e58b7e09833f616efff44","affectsGlobalScope":true},{"version":"4443e68b35f3332f753eacc66a04ac1d2053b8b035a0e0ac1d455392b5e243b3","affectsGlobalScope":true},{"version":"bc47685641087c015972a3f072480889f0d6c65515f12bd85222f49a98952ed7","affectsGlobalScope":true},{"version":"0dc1e7ceda9b8b9b455c3a2d67b0412feab00bd2f66656cd8850e8831b08b537","affectsGlobalScope":true},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true},{"version":"4ff2a353abf8a80ee399af572debb8faab2d33ad38c4b4474cff7f26e7653b8d","affectsGlobalScope":true},{"version":"93495ff27b8746f55d19fcbcdbaccc99fd95f19d057aed1bd2c0cafe1335fbf0","affectsGlobalScope":true},{"version":"6fc23bb8c3965964be8c597310a2878b53a0306edb71d4b5a4dfe760186bcc01","affectsGlobalScope":true},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true},{"version":"bb42a7797d996412ecdc5b2787720de477103a0b2e53058569069a0e2bae6c7e","affectsGlobalScope":true},{"version":"4738f2420687fd85629c9efb470793bb753709c2379e5f85bc1815d875ceadcd","affectsGlobalScope":true},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true},{"version":"4de680d5bb41c17f7f68e0419412ca23c98d5749dcaaea1896172f06435891fc","affectsGlobalScope":true},{"version":"9fc46429fbe091ac5ad2608c657201eb68b6f1b8341bd6d670047d32ed0a88fa","affectsGlobalScope":true},{"version":"61c37c1de663cf4171e1192466e52c7a382afa58da01b1dc75058f032ddf0839","affectsGlobalScope":true},{"version":"b541a838a13f9234aba650a825393ffc2292dc0fc87681a5d81ef0c96d281e7a","affectsGlobalScope":true},{"version":"e0275cd0e42990dc3a16f0b7c8bca3efe87f1c8ad404f80c6db1c7c0b828c59f","affectsGlobalScope":true},{"version":"811ec78f7fefcabbda4bfa93b3eb67d9ae166ef95f9bff989d964061cbf81a0c","affectsGlobalScope":true},{"version":"717937616a17072082152a2ef351cb51f98802fb4b2fdabd32399843875974ca","affectsGlobalScope":true},{"version":"d7e7d9b7b50e5f22c915b525acc5a49a7a6584cf8f62d0569e557c5cfc4b2ac2","affectsGlobalScope":true},{"version":"71c37f4c9543f31dfced6c7840e068c5a5aacb7b89111a4364b1d5276b852557","affectsGlobalScope":true},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true},{"version":"49ed889be54031e1044af0ad2c603d627b8bda8b50c1a68435fe85583901d072","affectsGlobalScope":true},{"version":"e93d098658ce4f0c8a0779e6cab91d0259efb88a318137f686ad76f8410ca270","affectsGlobalScope":true},{"version":"063600664504610fe3e99b717a1223f8b1900087fab0b4cad1496a114744f8df","affectsGlobalScope":true},{"version":"934019d7e3c81950f9a8426d093458b65d5aff2c7c1511233c0fd5b941e608ab","affectsGlobalScope":true},{"version":"bf14a426dbbf1022d11bd08d6b8e709a2e9d246f0c6c1032f3b2edb9a902adbe","affectsGlobalScope":true},{"version":"ec0104fee478075cb5171e5f4e3f23add8e02d845ae0165bfa3f1099241fa2aa","affectsGlobalScope":true},{"version":"2b72d528b2e2fe3c57889ca7baef5e13a56c957b946906d03767c642f386bbc3","affectsGlobalScope":true},{"version":"acae90d417bee324b1372813b5a00829d31c7eb670d299cd7f8f9a648ac05688","affectsGlobalScope":true},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true},{"version":"13f6e6380c78e15e140243dc4be2fa546c287c6d61f4729bc2dd7cf449605471","affectsGlobalScope":true},{"version":"33358442698bb565130f52ba79bfd3d4d484ac85fe33f3cb1759c54d18201393","affectsGlobalScope":true},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true},{"version":"c10f64b494e9a37f8bd983e874a03a17670d8405d98c7a065821921c545a48f7","signature":"8375cf161a0f21acd9ff0b3bc4c00780dfdfe6b508f312dd839702d8c4251c68"},{"version":"223745a7683ea5a3522e0d6419b0e639e10e5408aff27b86568901fef768f591","signature":"50c69a2b59e87e2aebdd6294b41cf6d9896ce198d05b4c1691d832a48c5393f4"},{"version":"cc859cf585321ba13306b886bcf6970f5745db282e886226da571d148fdcbb46","signature":"600074017fd954caf6d25d3111edb02aaa24bd91074d928cd02a2d713d6ea757"},{"version":"bcbd63cc0e57b35308858e624267b68ee6d9c9d02cb0a2d847fad074a33efd30","signature":"0ee705cedd747b89444ca301c710e45a43fa2f46be6eee021c204e677485b2da"},{"version":"6a7bca3c2a73ac500fce173f0af0491cd3dbb8c80196fa39dab02a47ac91fc95","signature":"3510aeb3423ac8b327be41d4bbd7cb499f66d8e0fbeb9066602a7436dbc45d51"},{"version":"5fca568d9fe91b3c1d6928a962bd8874ceaad50d8ce7355efb333dfc9e7b087a","signature":"3de595b5b4fe6c50f526b62dc9536c54ba6f97f7c7652d5730914de3be6cdaac"},{"version":"cdac34b1bfa8c5301a99aae634399581b07d441a342b2e99af272efacd28bf33","signature":"aefd19e3ecee790394b8e83bef9e0edb96417d603367ac43459bebad63de0048"},{"version":"704ae5b207e9e2554a1fbfea2e5055d23a1e9735819c868ccf7935d05080bfc8","signature":"7a629cbd546b33944f330f69db11c17a1121dad8ba23b6d232ff8c5d9ef28e58"},{"version":"07b66ab5b8a992f40130fe16efd6874a337ea4a651762bd169181ad15043ee1d","signature":"d43b3a78108cb3511d734b51e03e24ac5dc922e9791dded3ded9dc567629c838"},{"version":"52cbd1c8d55a99cb3f58c09f4537890345baba3e4913a0afcd962ac8916ed799","signature":"661d17747fcf18e933f4f73cea2589d144d39499e7686abb665335f6b01ddeab"},{"version":"7ff1ac0e7aebca773d04dda761bca41d14320e0622ef69f6f2447e7b000f4fa7","signature":"399d115998e6ee77790354467a58babe1c7ee7caba7eed1bf471f4ec8a9a365f"},{"version":"3471de7852d822a29c5c4ec7fa12cd5bc88efeacd43814e226cd937b2cb45bb3","signature":"f900f5b11bddbfb5972a0845bc2abab3ac1476b82282a43c7cd99db84fefbd5f"},"efc7d584a33fe3422847783d228f315c4cd1afe74bd7cf8e3f0e4c1125129fef","7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419","5929864ce17fba74232584d90cb721a89b7ad277220627cc97054ba15a98ea8f","7180c03fd3cb6e22f911ce9ba0f8a7008b1a6ddbe88ccf16a9c8140ef9ac1686","25c8056edf4314820382a5fdb4bb7816999acdcb929c8f75e3f39473b87e85bc","54cb85a47d760da1c13c00add10d26b5118280d44d58e6908d8e89abbd9d7725","3e4825171442666d31c845aeb47fcd34b62e14041bb353ae2b874285d78482aa","c6fd2c5a395f2432786c9cb8deb870b9b0e8ff7e22c029954fabdd692bff6195","a967bfe3ad4e62243eb604bf956101e4c740f5921277c60debaf325c1320bf88","e9775e97ac4877aebf963a0289c81abe76d1ec9a2a7778dbe637e5151f25c5f3","471e1da5a78350bc55ef8cef24eb3aca6174143c281b8b214ca2beda51f5e04a","cadc8aced301244057c4e7e73fbcae534b0f5b12a37b150d80e5a45aa4bebcbd","385aab901643aa54e1c36f5ef3107913b10d1b5bb8cbcd933d4263b80a0d7f20","9670d44354bab9d9982eca21945686b5c24a3f893db73c0dae0fd74217a4c219","db3435f3525cd785bf21ec6769bf8da7e8a776be1a99e2e7efb5f244a2ef5fee","c3b170c45fc031db31f782e612adf7314b167e60439d304b49e704010e7bafe5","40383ebef22b943d503c6ce2cb2e060282936b952a01bea5f9f493d5fb487cc7","4893a895ea92c85345017a04ed427cbd6a1710453338df26881a6019432febdd","3a84b7cb891141824bd00ef8a50b6a44596aded4075da937f180c90e362fe5f6","13f6f39e12b1518c6650bbb220c8985999020fe0f21d818e28f512b7771d00f9","9b5369969f6e7175740bf51223112ff209f94ba43ecd3bb09eefff9fd675624a","4fe9e626e7164748e8769bbf74b538e09607f07ed17c2f20af8d680ee49fc1da","24515859bc0b836719105bb6cc3d68255042a9f02a6022b3187948b204946bd2","33203609eba548914dc83ddf6cadbc0bcb6e8ef89f6d648ca0908ae887f9fcc5","0db18c6e78ea846316c012478888f33c11ffadab9efd1cc8bcc12daded7a60b6","89167d696a849fce5ca508032aabfe901c0868f833a8625d5a9c6e861ef935d2","e53a3c2a9f624d90f24bf4588aacd223e7bec1b9d0d479b68d2f4a9e6011147f","339dc5265ee5ed92e536a93a04c4ebbc2128f45eeec6ed29f379e0085283542c","9f0a92164925aa37d4a5d9dd3e0134cff8177208dba55fd2310cd74beea40ee2","8bfdb79bf1a9d435ec48d9372dc93291161f152c0865b81fc0b2694aedb4578d","2e85db9e6fd73cfa3d7f28e0ab6b55417ea18931423bd47b409a96e4a169e8e6","c46e079fe54c76f95c67fb89081b3e399da2c7d109e7dca8e4b58d83e332e605","d32275be3546f252e3ad33976caf8c5e842c09cb87d468cb40d5f4cf092d1acc","4a0c3504813a3289f7fb1115db13967c8e004aa8e4f8a9021b95285502221bd1",{"version":"a14ed46fa3f5ffc7a8336b497cd07b45c2084213aaca933a22443fcb2eef0d07","affectsGlobalScope":true},"cce1f5f86974c1e916ec4a8cab6eec9aa8e31e8148845bf07fbaa8e1d97b1a2c",{"version":"e2eb1ce13a9c0fa7ab62c63909d81973ef4b707292667c64f1e25e6e53fa7afa","affectsGlobalScope":true},"16d74fe4d8e183344d3beb15d48b123c5980ff32ff0cc8c3b96614ddcdf9b239","7b43160a49cf2c6082da0465876c4a0b164e160b81187caeb0a6ca7a281e85ba",{"version":"41fb2a1c108fbf46609ce5a451b7ec78eb9b5ada95fd5b94643e4b26397de0b3","affectsGlobalScope":true},"a40826e8476694e90da94aa008283a7de50d1dafd37beada623863f1901cb7fb",{"version":"a1d2988ad9d2aef7b9915a22b5e52c165c83a878f2851c35621409046bbe3c05","affectsGlobalScope":true},"bd3f5d05b6b5e4bfcea7739a45f3ffb4a7f4a3442ba7baf93e0200799285b8f1","4c775c2fccabf49483c03cd5e3673f87c1ffb6079d98e7b81089c3def79e29c6","8806ae97308ef26363bd7ec8071bca4d07fb575f905ee3d8a91aff226df6d618","af5bf1db6f1804fb0069039ae77a05d60133c77a2158d9635ea27b6bb2828a8f","b7fe70be794e13d1b7940e318b8770cd1fb3eced7707805318a2e3aaac2c3e9e",{"version":"2c71199d1fc83bf17636ad5bf63a945633406b7b94887612bba4ef027c662b3e","affectsGlobalScope":true},{"version":"7ae9dc7dbb58cd843065639707815df85c044babaa0947116f97bdb824d07204","affectsGlobalScope":true},"fe1fd6afdfe77976d4c702f3746c05fb05a7e566845c890e0e970fe9376d6a90","313a0b063f5188037db113509de1b934a0e286f14e9479af24fada241435e707","f1ace2d2f98429e007d017c7a445efad2aaebf8233135abdb2c88b8c0fef91ab","87ef1a23caa071b07157c72077fa42b86d30568f9dc9e31eed24d5d14fc30ba8","396a8939b5e177542bdf9b5262b4eee85d29851b2d57681fa9d7eae30e225830","21773f5ac69ddf5a05636ba1f50b5239f4f2d27e4420db147fc2f76a5ae598ac",{"version":"ea455cc68871b049bcecd9f56d4cf27b852d6dafd5e3b54468ca87cc11604e4d","affectsGlobalScope":true},"c07146dbbbd8b347241b5df250a51e48f2d7bef19b1e187b1a3f20c849988ff1","45b1053e691c5af9bfe85060a3e1542835f8d84a7e6e2e77ca305251eda0cb3c","0f05c06ff6196958d76b865ae17245b52d8fe01773626ac3c43214a2458ea7b7",{"version":"ae5507fc333d637dec9f37c6b3f4d423105421ea2820a64818de55db85214d66","affectsGlobalScope":true},{"version":"0666f4c99b8688c7be5956df8fecf5d1779d3b22f8f2a88258ae7072c7b6026f","affectsGlobalScope":true},"8abd0566d2854c4bd1c5e48e05df5c74927187f1541e6770001d9637ac41542e","54e854615c4eafbdd3fd7688bd02a3aafd0ccf0e87c98f79d3e9109f047ce6b8","d8dba11dc34d50cb4202de5effa9a1b296d7a2f4a029eec871f894bddfb6430d","8b71dd18e7e63b6f991b511a201fad7c3bf8d1e0dd98acb5e3d844f335a73634","01d8e1419c84affad359cc240b2b551fb9812b450b4d3d456b64cda8102d4f60","8221b00f271cf7f535a8eeec03b0f80f0929c7a16116e2d2df089b41066de69b","269929a24b2816343a178008ac9ae9248304d92a8ba8e233055e0ed6dbe6ef71","93452d394fdd1dc551ec62f5042366f011a00d342d36d50793b3529bfc9bd633","7424817d5eb498771e6d1808d726ec38f75d2eaf3fa359edd5c0c540c52725c1","9a9634296cca836c3308923ba7aa094fa6ed76bb1e366d8ddcf5c65888ab1024",{"version":"bddce945d552a963c9733db106b17a25474eefcab7fc990157a2134ef55d4954","affectsGlobalScope":true},{"version":"7052b7b0c3829df3b4985bab2fd74531074b4835d5a7b263b75c82f0916ad62f","affectsGlobalScope":true},"aa34c3aa493d1c699601027c441b9664547c3024f9dbab1639df7701d63d18fa","4b55240c2a03b2c71e98a7fc528b16136faa762211c92e781a01c37821915ea6","7c651f8dce91a927ab62925e73f190763574c46098f2b11fb8ddc1b147a6709a","7440ab60f4cb031812940cc38166b8bb6fbf2540cfe599f87c41c08011f0c1df",{"version":"94c086dff8dbc5998749326bc69b520e8e4273fb5b7b58b50e0210e0885dfcde","affectsGlobalScope":true},{"version":"f5b5dc128973498b75f52b1b8c2d5f8629869104899733ae485100c2309b4c12","affectsGlobalScope":true},"ebe5facd12fd7745cda5f4bc3319f91fb29dc1f96e57e9c6f8b260a7cc5b67ee","79bad8541d5779c85e82a9fb119c1fe06af77a71cc40f869d62ad379473d4b75","37dc027f781c75f0f546e329cfac7cf92a6b289f42458f47a9adc25e516b6839",{"version":"629d20681ca284d9e38c0a019f647108f5fe02f9c59ac164d56f5694fc3faf4d","affectsGlobalScope":true},"e7dbf5716d76846c7522e910896c5747b6df1abd538fee8f5291bdc843461795",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"b510d0a18e3db42ac9765d26711083ec1e8b4e21caaca6dc4d25ae6e8623f447"],"root":[[49,60]],"options":{"allowJs":true,"allowSyntheticDefaultImports":true,"declaration":true,"esModuleInterop":true,"experimentalDecorators":true,"module":1,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","skipLibCheck":true,"strict":true,"target":1},"fileIdsList":[[61],[96],[97,102,130],[98,109,110,117,127,138],[98,99,109,117],[100,139],[101,102,110,118],[102,127,135],[103,105,109,117],[96,104],[105,106],[109],[107,109],[96,109],[109,110,111,127,138],[109,110,111,124,127,130],[94,97,143],[105,109,112,117,127,138],[109,110,112,113,117,127,135,138],[112,114,127,135,138],[61,62,95,96,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],[109,115],[116,138,143],[105,109,117,127],[118],[119],[96,120],[121,137,143],[122],[123],[109,124,125],[124,126,139,141],[97,109,127,128,129,130],[97,127,129],[127,128],[130],[131],[96,127],[109,133,134],[133,134],[102,117,127,135],[136],[117,137],[97,112,123,138],[102,139],[127,140],[116,141],[142],[97,102,109,111,120,127,138,141,143],[127,144],[71,75,138],[71,127,138],[66],[68,71,135,138],[117,135],[146],[66,146],[68,71,117,138],[63,64,67,70,97,109,127,138],[63,69],[67,71,97,130,138,146],[97,146],[87,97,146],[65,66,146],[71],[65,66,67,68,69,70,71,72,73,75,76,77,78,79,80,81,82,83,84,85,86,88,89,90,91,92,93],[71,78,79],[69,71,79,80],[70],[63,66,71],[71,75,79,80],[75],[69,71,74,138],[63,68,69,71,75,78],[97,127],[66,71,87,97,143,146],[51,52],[50],[49,50],[49,50,51,52,53,54,55,56,57,58,59],[50,51]],"referencedMap":[[61,1],[62,1],[96,2],[97,3],[98,4],[99,5],[100,6],[101,7],[102,8],[103,9],[104,10],[105,11],[106,11],[108,12],[107,13],[109,14],[110,15],[111,16],[95,17],[112,18],[113,19],[114,20],[146,21],[115,22],[116,23],[117,24],[118,25],[119,26],[120,27],[121,28],[122,29],[123,30],[124,31],[125,31],[126,32],[127,33],[129,34],[128,35],[130,36],[131,37],[132,38],[133,39],[134,40],[135,41],[136,42],[137,43],[138,44],[139,45],[140,46],[141,47],[142,48],[143,49],[144,50],[78,51],[85,52],[77,51],[92,53],[69,54],[68,55],[91,56],[86,57],[89,58],[71,59],[70,60],[66,61],[65,62],[88,63],[67,64],[72,65],[76,65],[94,66],[93,65],[80,67],[81,68],[83,69],[79,70],[82,71],[87,56],[74,72],[75,73],[84,74],[64,75],[90,76],[53,77],[56,78],[51,79],[60,80],[58,81]],"exportedModulesMap":[[61,1],[62,1],[96,2],[97,3],[98,4],[99,5],[100,6],[101,7],[102,8],[103,9],[104,10],[105,11],[106,11],[108,12],[107,13],[109,14],[110,15],[111,16],[95,17],[112,18],[113,19],[114,20],[146,21],[115,22],[116,23],[117,24],[118,25],[119,26],[120,27],[121,28],[122,29],[123,30],[124,31],[125,31],[126,32],[127,33],[129,34],[128,35],[130,36],[131,37],[132,38],[133,39],[134,40],[135,41],[136,42],[137,43],[138,44],[139,45],[140,46],[141,47],[142,48],[143,49],[144,50],[78,51],[85,52],[77,51],[92,53],[69,54],[68,55],[91,56],[86,57],[89,58],[71,59],[70,60],[66,61],[65,62],[88,63],[67,64],[72,65],[76,65],[94,66],[93,65],[80,67],[81,68],[83,69],[79,70],[82,71],[87,56],[74,72],[75,73],[84,74],[64,75],[90,76],[56,78],[51,78],[60,80],[58,78]],"semanticDiagnosticsPerFile":[61,62,96,97,98,99,100,101,102,103,104,105,106,108,107,109,110,111,95,145,112,113,114,146,115,116,117,118,119,120,121,122,123,124,125,126,127,129,128,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,1,47,48,9,13,12,3,14,15,16,17,18,19,20,21,4,5,22,26,23,24,25,27,28,29,6,30,31,32,33,7,37,34,35,36,38,8,39,44,45,40,41,42,43,2,46,11,10,78,85,77,92,69,68,91,86,89,71,70,66,65,88,67,72,73,76,63,94,93,80,81,83,79,82,87,74,75,84,64,90,53,49,54,55,56,51,60,52,57,58,59,50]},"version":"5.3.3"}
|
package/package.json
CHANGED
package/src/colors.ts
CHANGED
|
@@ -6,7 +6,7 @@ import { clamp } from './maths';
|
|
|
6
6
|
// ******************************************
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
|
-
* Normalize hexadecimal string
|
|
9
|
+
* Normalize an hexadecimal string
|
|
10
10
|
*
|
|
11
11
|
* @param {string} hex Hexadecimal string
|
|
12
12
|
* @returns {string} Normalized hexadecimal string
|
|
@@ -31,7 +31,7 @@ export function normalizeHexString(hex: string): string {
|
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
/**
|
|
34
|
-
* Convert RGB
|
|
34
|
+
* Convert RGB to hexadecimal
|
|
35
35
|
* Note: rgb values are contained in the interval [0, 1]
|
|
36
36
|
*
|
|
37
37
|
* @param {[number, number, number]} rgb RGB color
|
|
@@ -42,7 +42,7 @@ export function rgbToHex([r, g, b]: [number, number, number]): number {
|
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
/**
|
|
45
|
-
* Convert RGB
|
|
45
|
+
* Convert RGB to hexadecimal string
|
|
46
46
|
* Note: rgb values are contained in the interval [0, 1]
|
|
47
47
|
*
|
|
48
48
|
* @param {[number, number, number]} rgb RGB color
|
|
@@ -58,7 +58,7 @@ export function rgbToHexString([r, g, b]: [number, number, number]): string {
|
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
/**
|
|
61
|
-
* Convert hexadecimal
|
|
61
|
+
* Convert hexadecimal to RGB
|
|
62
62
|
* Note: rgb values are contained in the interval [0, 1]
|
|
63
63
|
*
|
|
64
64
|
* @param {(number|string)} hex Hexadecimal color
|
|
@@ -129,7 +129,7 @@ export function darken(hex: string, amount: number = 0): string {
|
|
|
129
129
|
// ***************************************************
|
|
130
130
|
|
|
131
131
|
/**
|
|
132
|
-
* Normalize HSL string
|
|
132
|
+
* Normalize an HSL string
|
|
133
133
|
* Note: hsl values are contained in the intervals H: [0, 360], S: [0, 1], L: [0, 1]
|
|
134
134
|
*
|
|
135
135
|
* @param {string} hsl HSL string (format: 'hsl(360, 100%, 100%)')
|
|
@@ -141,7 +141,7 @@ export function normalizeHslString(hsl: string): [number, number, number] {
|
|
|
141
141
|
}
|
|
142
142
|
|
|
143
143
|
/**
|
|
144
|
-
* Convert RGB
|
|
144
|
+
* Convert RGB to HSL
|
|
145
145
|
* Notes:
|
|
146
146
|
* - rgb values are contained in the interval [0, 1]
|
|
147
147
|
* - hsl values are contained in the intervals H: [0, 360], S: [0, 1], L: [0, 1]
|
|
@@ -162,7 +162,7 @@ export function rgbToHsl([r, g, b]: [number, number, number]): [number, number,
|
|
|
162
162
|
}
|
|
163
163
|
|
|
164
164
|
/**
|
|
165
|
-
* Convert HSL
|
|
165
|
+
* Convert HSL to RGB
|
|
166
166
|
* Notes:
|
|
167
167
|
* - rgb values are contained in the interval [0, 1]
|
|
168
168
|
* - hsl values are contained in the intervals H: [0, 360], S: [0, 1], L: [0, 1]
|
|
@@ -182,7 +182,7 @@ export function hslToRgb([h, s, l]: [number, number, number]): [number, number,
|
|
|
182
182
|
// ***************************************************
|
|
183
183
|
|
|
184
184
|
/**
|
|
185
|
-
* Convert RGB
|
|
185
|
+
* Convert RGB to HSB
|
|
186
186
|
* Notes:
|
|
187
187
|
* - rgb values are contained in the interval [0, 1]
|
|
188
188
|
* - hsb values are contained in the intervals H: [0, 360], S: [0, 1], B: [0, 1]
|
|
@@ -200,7 +200,7 @@ export function rgbToHsb([r, g, b]: [number, number, number]): [number, number,
|
|
|
200
200
|
}
|
|
201
201
|
|
|
202
202
|
/**
|
|
203
|
-
* Convert HSB
|
|
203
|
+
* Convert HSB to RGB
|
|
204
204
|
* Notes:
|
|
205
205
|
* - rgb values are contained in the interval [0, 1]
|
|
206
206
|
* - hsb values are contained in the intervals H: [0, 360], S: [0, 1], B: [0, 1]
|
|
@@ -219,7 +219,7 @@ export function hsbToRgb([h, s, b]: [number, number, number]): [number, number,
|
|
|
219
219
|
// *********************************************
|
|
220
220
|
|
|
221
221
|
/**
|
|
222
|
-
* Convert LAB
|
|
222
|
+
* Convert LAB to HCL
|
|
223
223
|
* -> http://www.brucelindbloom.com/index.html?Eqn_Lab_to_LCH.html
|
|
224
224
|
*
|
|
225
225
|
* @param {[number, number, number]} lab LAB color
|
|
@@ -232,7 +232,7 @@ export function labToHcl([l, a, b]: [number, number, number]): [number, number,
|
|
|
232
232
|
}
|
|
233
233
|
|
|
234
234
|
/**
|
|
235
|
-
* Convert HCL
|
|
235
|
+
* Convert HCL to LAB
|
|
236
236
|
* -> http://www.brucelindbloom.com/index.html?Eqn_LCH_to_Lab.html
|
|
237
237
|
*
|
|
238
238
|
* @param {[number, number, number]} hcl HCL color
|
|
@@ -245,7 +245,7 @@ export function hclToLab([h, c, l]: [number, number, number]): [number, number,
|
|
|
245
245
|
}
|
|
246
246
|
|
|
247
247
|
/**
|
|
248
|
-
* Convert A and B of LAB
|
|
248
|
+
* Convert A and B of LAB to Hue of LCH
|
|
249
249
|
* -> https://stackoverflow.com/questions/53733379/conversion-of-cielab-to-cielchab-not-yielding-correct-result
|
|
250
250
|
*
|
|
251
251
|
* @param {number} a A value of LAB color
|
|
@@ -287,7 +287,7 @@ const f3 = (v: number) => (v > 0.04045 ? Math.pow((v + 0.055) / 1.055, 2.4) : v
|
|
|
287
287
|
const f4 = (v: number) => (v > 0.008856 ? Math.pow(v, 1 / 3) : 7.787 * v + 16 / 116);
|
|
288
288
|
|
|
289
289
|
/**
|
|
290
|
-
* Converts LAB
|
|
290
|
+
* Converts LAB to RGB
|
|
291
291
|
*
|
|
292
292
|
* @param {[number, number, number]} lab LAB color
|
|
293
293
|
* @returns {[number, number, number]} RGB color
|
|
@@ -309,7 +309,7 @@ export function labToRgb([l, a, b]: [number, number, number]): [number, number,
|
|
|
309
309
|
}
|
|
310
310
|
|
|
311
311
|
/**
|
|
312
|
-
* Converts RGB
|
|
312
|
+
* Converts RGB to LAB
|
|
313
313
|
*
|
|
314
314
|
* @param {[number, number, number]} rgb RGB color
|
|
315
315
|
* @returns {[number, number, number]} LAB color
|
|
@@ -356,7 +356,7 @@ export function deltaE(labA: [number, number, number], labB: [number, number, nu
|
|
|
356
356
|
// *********************************************
|
|
357
357
|
|
|
358
358
|
/**
|
|
359
|
-
*
|
|
359
|
+
* Convert RGB to HCL
|
|
360
360
|
*
|
|
361
361
|
* @param {[number, number, number]} rgb RGB color
|
|
362
362
|
* @returns {[number, number, number]} HCL color
|
|
@@ -366,7 +366,7 @@ export function rgbToHcl([r, g, b]: [number, number, number]): [number, number,
|
|
|
366
366
|
}
|
|
367
367
|
|
|
368
368
|
/**
|
|
369
|
-
* Converts HCL
|
|
369
|
+
* Converts HCL to RGB
|
|
370
370
|
*
|
|
371
371
|
* @param {[number, number, number]} hcl RGB color
|
|
372
372
|
* @returns {[number, number, number]} RGB color
|
package/src/constants.ts
CHANGED
package/src/dom.ts
CHANGED
|
@@ -37,11 +37,11 @@ export function createCanvas(
|
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
/**
|
|
40
|
-
* Inject CSS
|
|
40
|
+
* Inject CSS styles in `document.head`
|
|
41
41
|
*
|
|
42
42
|
* @param {string} cssContent CSS style to inject
|
|
43
43
|
*/
|
|
44
|
-
export function injectStyles(cssContent: string) {
|
|
44
|
+
export function injectStyles(cssContent: string): void {
|
|
45
45
|
const $style = document.createElement('style');
|
|
46
46
|
$style.innerHTML = cssContent;
|
|
47
47
|
const $before = document.querySelector('head link[rel=stylesheet], head style');
|
package/src/geometry.ts
CHANGED
|
@@ -35,7 +35,7 @@ export function angle(x1: number, y1: number, x2: number, y2: number): number {
|
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
/**
|
|
38
|
-
* Find the closest angle
|
|
38
|
+
* Find the closest angle between to angles
|
|
39
39
|
*
|
|
40
40
|
* @param {number} source Source angle in radians
|
|
41
41
|
* @param {number} target Target angle in radians
|
package/src/index.ts
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
export * from './colors';
|
|
2
|
-
export * from './dom';
|
|
3
|
-
export * from './files';
|
|
4
|
-
export * from './functions';
|
|
5
|
-
export * from './geometry';
|
|
6
|
-
export * from './maths';
|
|
7
|
-
export * from './now';
|
|
8
|
-
export * from './random';
|
|
9
|
-
export * from './strings';
|
|
1
|
+
export * as colors from './colors';
|
|
2
|
+
export * as dom from './dom';
|
|
3
|
+
export * as files from './files';
|
|
4
|
+
export * as functions from './functions';
|
|
5
|
+
export * as geometry from './geometry';
|
|
6
|
+
export * as maths from './maths';
|
|
7
|
+
export * as now from './now';
|
|
8
|
+
export * as random from './random';
|
|
9
|
+
export * as strings from './strings';
|
|
10
10
|
|
|
11
|
-
export * from './constants';
|
|
12
|
-
|
|
11
|
+
export * as constants from './constants';
|
|
12
|
+
|
|
13
|
+
export type * as types from './types';
|
package/src/maths.ts
CHANGED
|
@@ -29,7 +29,7 @@ export function isPowerOf2(value: number): boolean {
|
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
/**
|
|
32
|
-
* Find
|
|
32
|
+
* Find closest power of 2 that fits a number
|
|
33
33
|
*
|
|
34
34
|
* @param {number} value Incoming value
|
|
35
35
|
* @param {string} [mode='ceil'] Can be 'floor' | 'ceil' | 'round'
|
package/src/random.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { radToSphere } from './geometry';
|
|
|
2
2
|
import { Vector2, Vector3 } from './types';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
|
-
* Generate random boolean (true or false)
|
|
5
|
+
* Generate a random boolean (true or false)
|
|
6
6
|
*
|
|
7
7
|
* @param {number} [probability=0.5] Probability to get true
|
|
8
8
|
* @returns {boolean} Either true or false
|
|
@@ -12,7 +12,7 @@ export function randomBoolean(probability: number = 0.5): boolean {
|
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
|
-
* Generate random sign (1 or -1)
|
|
15
|
+
* Generate a random sign (1 or -1)
|
|
16
16
|
*
|
|
17
17
|
* @param {number} [probability=0.5] Probability to get 1
|
|
18
18
|
* @returns {number} Either 1 or -1
|
|
@@ -22,7 +22,7 @@ export function randomSign(probability: number = 0.5): number {
|
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
/**
|
|
25
|
-
* Generate a random float
|
|
25
|
+
* Generate a random float number
|
|
26
26
|
*
|
|
27
27
|
* @param {number} [min=0] Minimum boundary
|
|
28
28
|
* @param {number} [max=1] Maximum boundary
|
|
@@ -34,7 +34,7 @@ export function randomFloat(min: number = 0, max: number = 1, precision: number
|
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
/**
|
|
37
|
-
* Generate a random integer
|
|
37
|
+
* Generate a random integer number
|
|
38
38
|
*
|
|
39
39
|
* @param {number} min Minimum boundary
|
|
40
40
|
* @param {number} max Maximum boundary
|
|
@@ -67,10 +67,10 @@ export function randomItem<I = unknown>(array: I[] = []): I | undefined {
|
|
|
67
67
|
/**
|
|
68
68
|
* Pick a random property from an object
|
|
69
69
|
*
|
|
70
|
-
* @param {object}
|
|
70
|
+
* @param {object} object Object to pick the property from
|
|
71
71
|
* @returns {unknown|undefined} Random item picked
|
|
72
72
|
*/
|
|
73
|
-
export function randomObjectProperty(object: object
|
|
73
|
+
export function randomObjectProperty(object: object): unknown | undefined {
|
|
74
74
|
const keys = Object.keys(object);
|
|
75
75
|
const key = randomItem(keys);
|
|
76
76
|
if (key && object.hasOwnProperty(key)) {
|