@bitbybit-dev/base 1.2.0-rc.2 → 1.3.0-rc.0
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/lib/api/GlobalCDNProvider.js +1 -1
- package/lib/api/inputs/base-inputs.d.ts +13 -12
- package/lib/api/inputs/color-inputs.d.ts +97 -48
- package/lib/api/inputs/color-inputs.js +95 -46
- package/lib/api/inputs/dates-inputs.d.ts +67 -26
- package/lib/api/inputs/dates-inputs.js +57 -16
- package/lib/api/inputs/io-inputs.d.ts +13 -15
- package/lib/api/inputs/io-inputs.js +7 -8
- package/lib/api/inputs/line-inputs.d.ts +88 -33
- package/lib/api/inputs/line-inputs.js +61 -11
- package/lib/api/inputs/lists-inputs.d.ts +207 -96
- package/lib/api/inputs/lists-inputs.js +153 -45
- package/lib/api/inputs/logic-inputs.d.ts +52 -22
- package/lib/api/inputs/logic-inputs.js +41 -12
- package/lib/api/inputs/math-inputs.d.ts +113 -52
- package/lib/api/inputs/math-inputs.js +112 -51
- package/lib/api/inputs/mesh-inputs.d.ts +30 -11
- package/lib/api/inputs/mesh-inputs.js +21 -3
- package/lib/api/inputs/point-inputs.d.ts +240 -107
- package/lib/api/inputs/point-inputs.js +199 -73
- package/lib/api/inputs/polyline-inputs.d.ts +68 -28
- package/lib/api/inputs/polyline-inputs.js +48 -13
- package/lib/api/inputs/text-inputs.d.ts +117 -46
- package/lib/api/inputs/text-inputs.js +111 -41
- package/lib/api/inputs/transforms-inputs.d.ts +65 -23
- package/lib/api/inputs/transforms-inputs.js +64 -22
- package/lib/api/inputs/vector-inputs.d.ts +154 -76
- package/lib/api/inputs/vector-inputs.js +132 -57
- package/lib/api/models/point/hex-grid-data.d.ts +1 -1
- package/lib/api/models/point/hex-grid-data.js +1 -1
- package/lib/api/services/color.d.ts +149 -70
- package/lib/api/services/color.js +149 -70
- package/lib/api/services/dates.d.ts +313 -150
- package/lib/api/services/dates.js +313 -150
- package/lib/api/services/line.d.ts +138 -68
- package/lib/api/services/line.js +138 -68
- package/lib/api/services/lists.d.ts +357 -177
- package/lib/api/services/lists.js +357 -177
- package/lib/api/services/logic.d.ts +98 -45
- package/lib/api/services/logic.js +98 -45
- package/lib/api/services/math.d.ts +363 -211
- package/lib/api/services/math.js +363 -211
- package/lib/api/services/mesh.d.ts +73 -31
- package/lib/api/services/mesh.js +73 -31
- package/lib/api/services/point.d.ts +367 -147
- package/lib/api/services/point.js +367 -147
- package/lib/api/services/polyline.d.ts +146 -71
- package/lib/api/services/polyline.js +146 -71
- package/lib/api/services/text.d.ts +320 -165
- package/lib/api/services/text.js +320 -165
- package/lib/api/services/transforms.d.ts +145 -58
- package/lib/api/services/transforms.js +145 -58
- package/lib/api/services/vector.d.ts +381 -156
- package/lib/api/services/vector.js +381 -156
- package/package.json +1 -1
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
// tslint:disable-next-line: no-namespace
|
|
2
2
|
/**
|
|
3
|
-
* Parameters for
|
|
4
|
-
* the settings for blending, inverting and generating ranges of
|
|
3
|
+
* Parameters for color handling: hex, RGB and HSL values, the components to combine or extract, and
|
|
4
|
+
* the settings for blending, inverting and generating ranges of colors.
|
|
5
5
|
*/
|
|
6
6
|
export var Color;
|
|
7
7
|
(function (Color) {
|
|
8
|
+
/**
|
|
9
|
+
* A hex color for `color.hexColor` and `color.hexToRgb`.
|
|
10
|
+
*/
|
|
8
11
|
class HexDto {
|
|
9
12
|
constructor(color) {
|
|
10
13
|
/**
|
|
11
|
-
*
|
|
14
|
+
* The color as a hex text such as `#ff5733`, with or without the `#`.
|
|
12
15
|
* @default #0000ff
|
|
13
16
|
*/
|
|
14
17
|
this.color = "#0000ff";
|
|
@@ -18,13 +21,16 @@ export var Color;
|
|
|
18
21
|
}
|
|
19
22
|
}
|
|
20
23
|
Color.HexDto = HexDto;
|
|
24
|
+
/**
|
|
25
|
+
* An `{ r, g, b }` color with channels from 0 to 255, for `color.rgb255Color`.
|
|
26
|
+
*/
|
|
21
27
|
class Rgb255Dto {
|
|
22
28
|
constructor(colorRgb) {
|
|
23
29
|
/**
|
|
24
|
-
*
|
|
30
|
+
* The color object; each channel from 0 to 255.
|
|
25
31
|
* @default { "r": 0, "g": 0, "b": 255 }
|
|
26
|
-
* @
|
|
27
|
-
* @
|
|
32
|
+
* @minimum 0
|
|
33
|
+
* @maximum 255
|
|
28
34
|
*/
|
|
29
35
|
this.colorRgb = { r: 0, g: 0, b: 255 };
|
|
30
36
|
if (colorRgb !== undefined) {
|
|
@@ -33,13 +39,16 @@ export var Color;
|
|
|
33
39
|
}
|
|
34
40
|
}
|
|
35
41
|
Color.Rgb255Dto = Rgb255Dto;
|
|
42
|
+
/**
|
|
43
|
+
* An `{ r, g, b }` color with channels from 0 to 1, for `color.rgb1Color`.
|
|
44
|
+
*/
|
|
36
45
|
class Rgb1Dto {
|
|
37
46
|
constructor(colorRgb) {
|
|
38
47
|
/**
|
|
39
|
-
*
|
|
48
|
+
* The color object; each channel from 0 to 1.
|
|
40
49
|
* @default { "r": 0, "g": 0, "b": 1 }
|
|
41
|
-
* @
|
|
42
|
-
* @
|
|
50
|
+
* @minimum 0
|
|
51
|
+
* @maximum 1
|
|
43
52
|
*/
|
|
44
53
|
this.colorRgb = { r: 0, g: 0, b: 1 };
|
|
45
54
|
if (colorRgb !== undefined) {
|
|
@@ -48,13 +57,18 @@ export var Color;
|
|
|
48
57
|
}
|
|
49
58
|
}
|
|
50
59
|
Color.Rgb1Dto = Rgb1Dto;
|
|
60
|
+
/**
|
|
61
|
+
* An `{ r, g, b, a }` color with color channels from 0 to 255 and opacity from 0 to 1, for
|
|
62
|
+
* `color.rgba255Color`.
|
|
63
|
+
*/
|
|
51
64
|
class Rgba255Dto {
|
|
52
65
|
constructor(colorRgba) {
|
|
53
66
|
/**
|
|
54
|
-
*
|
|
67
|
+
* The color object; `r`, `g` and `b` from 0 to 255 and `a` from 0 (transparent) to 1
|
|
68
|
+
* (opaque).
|
|
55
69
|
* @default { "r": 0, "g": 0, "b": 255, "a": 1 }
|
|
56
|
-
* @
|
|
57
|
-
* @
|
|
70
|
+
* @minimum 0
|
|
71
|
+
* @maximum 255
|
|
58
72
|
*/
|
|
59
73
|
this.colorRgba = { r: 0, g: 0, b: 255, a: 1 };
|
|
60
74
|
if (colorRgba !== undefined) {
|
|
@@ -63,13 +77,17 @@ export var Color;
|
|
|
63
77
|
}
|
|
64
78
|
}
|
|
65
79
|
Color.Rgba255Dto = Rgba255Dto;
|
|
80
|
+
/**
|
|
81
|
+
* An `{ r, g, b, a }` color with every channel from 0 to 1, for `color.rgba1Color`.
|
|
82
|
+
*/
|
|
66
83
|
class Rgba1Dto {
|
|
67
84
|
constructor(colorRgba) {
|
|
68
85
|
/**
|
|
69
|
-
*
|
|
86
|
+
* The color object; every channel from 0 to 1, `a` being 0 for transparent and 1 for
|
|
87
|
+
* opaque.
|
|
70
88
|
* @default { "r": 0, "g": 0, "b": 1, "a": 1 }
|
|
71
|
-
* @
|
|
72
|
-
* @
|
|
89
|
+
* @minimum 0
|
|
90
|
+
* @maximum 1
|
|
73
91
|
*/
|
|
74
92
|
this.colorRgba = { r: 0, g: 0, b: 1, a: 1 };
|
|
75
93
|
if (colorRgba !== undefined) {
|
|
@@ -78,24 +96,27 @@ export var Color;
|
|
|
78
96
|
}
|
|
79
97
|
}
|
|
80
98
|
Color.Rgba1Dto = Rgba1Dto;
|
|
99
|
+
/**
|
|
100
|
+
* Separate red, green and blue values from 0 to 255, for color.rgbAtomic255Color.
|
|
101
|
+
*/
|
|
81
102
|
class RgbAttomic255Dto {
|
|
82
103
|
constructor(r, g, b) {
|
|
83
104
|
/**
|
|
84
|
-
*
|
|
105
|
+
* The red channel, from 0 to 255.
|
|
85
106
|
* @default 0
|
|
86
107
|
* @minimum 0
|
|
87
108
|
* @maximum 255
|
|
88
109
|
*/
|
|
89
110
|
this.r = 0;
|
|
90
111
|
/**
|
|
91
|
-
*
|
|
112
|
+
* The green channel, from 0 to 255.
|
|
92
113
|
* @default 0
|
|
93
114
|
* @minimum 0
|
|
94
115
|
* @maximum 255
|
|
95
116
|
*/
|
|
96
117
|
this.g = 0;
|
|
97
118
|
/**
|
|
98
|
-
*
|
|
119
|
+
* The blue channel, from 0 to 255.
|
|
99
120
|
* @default 255
|
|
100
121
|
* @minimum 0
|
|
101
122
|
* @maximum 255
|
|
@@ -113,31 +134,34 @@ export var Color;
|
|
|
113
134
|
}
|
|
114
135
|
}
|
|
115
136
|
Color.RgbAttomic255Dto = RgbAttomic255Dto;
|
|
137
|
+
/**
|
|
138
|
+
* Separate red, green, blue and alpha values from 0 to 255, for building a color.
|
|
139
|
+
*/
|
|
116
140
|
class RgbaAttomic255Dto {
|
|
117
141
|
constructor(r, g, b, a) {
|
|
118
142
|
/**
|
|
119
|
-
*
|
|
143
|
+
* The red channel, from 0 to 255.
|
|
120
144
|
* @default 0
|
|
121
145
|
* @minimum 0
|
|
122
146
|
* @maximum 255
|
|
123
147
|
*/
|
|
124
148
|
this.r = 0;
|
|
125
149
|
/**
|
|
126
|
-
*
|
|
150
|
+
* The green channel, from 0 to 255.
|
|
127
151
|
* @default 0
|
|
128
152
|
* @minimum 0
|
|
129
153
|
* @maximum 255
|
|
130
154
|
*/
|
|
131
155
|
this.g = 0;
|
|
132
156
|
/**
|
|
133
|
-
*
|
|
157
|
+
* The blue channel, from 0 to 255.
|
|
134
158
|
* @default 255
|
|
135
159
|
* @minimum 0
|
|
136
160
|
* @maximum 255
|
|
137
161
|
*/
|
|
138
162
|
this.b = 255;
|
|
139
163
|
/**
|
|
140
|
-
*
|
|
164
|
+
* The opacity, from 0 (transparent) to 1 (opaque).
|
|
141
165
|
* @default 1
|
|
142
166
|
* @minimum 0
|
|
143
167
|
* @maximum 1
|
|
@@ -158,24 +182,27 @@ export var Color;
|
|
|
158
182
|
}
|
|
159
183
|
}
|
|
160
184
|
Color.RgbaAttomic255Dto = RgbaAttomic255Dto;
|
|
185
|
+
/**
|
|
186
|
+
* Separate red, green and blue values from 0 to 1, for color.rgbAtomic1Color.
|
|
187
|
+
*/
|
|
161
188
|
class RgbAttomic1Dto {
|
|
162
189
|
constructor(r, g, b) {
|
|
163
190
|
/**
|
|
164
|
-
*
|
|
191
|
+
* The red channel, from 0 to 1.
|
|
165
192
|
* @default 0
|
|
166
193
|
* @minimum 0
|
|
167
194
|
* @maximum 1
|
|
168
195
|
*/
|
|
169
196
|
this.r = 0;
|
|
170
197
|
/**
|
|
171
|
-
*
|
|
198
|
+
* The green channel, from 0 to 1.
|
|
172
199
|
* @default 0
|
|
173
200
|
* @minimum 0
|
|
174
201
|
* @maximum 1
|
|
175
202
|
*/
|
|
176
203
|
this.g = 0;
|
|
177
204
|
/**
|
|
178
|
-
*
|
|
205
|
+
* The blue channel, from 0 to 1.
|
|
179
206
|
* @default 1
|
|
180
207
|
* @minimum 0
|
|
181
208
|
* @maximum 1
|
|
@@ -193,31 +220,34 @@ export var Color;
|
|
|
193
220
|
}
|
|
194
221
|
}
|
|
195
222
|
Color.RgbAttomic1Dto = RgbAttomic1Dto;
|
|
223
|
+
/**
|
|
224
|
+
* Separate red, green, blue and alpha values from 0 to 1, for building a color.
|
|
225
|
+
*/
|
|
196
226
|
class RgbaAttomic1Dto {
|
|
197
227
|
constructor(r, g, b, a) {
|
|
198
228
|
/**
|
|
199
|
-
*
|
|
229
|
+
* The red channel, from 0 to 1.
|
|
200
230
|
* @default 0
|
|
201
231
|
* @minimum 0
|
|
202
232
|
* @maximum 1
|
|
203
233
|
*/
|
|
204
234
|
this.r = 0;
|
|
205
235
|
/**
|
|
206
|
-
*
|
|
236
|
+
* The green channel, from 0 to 1.
|
|
207
237
|
* @default 0
|
|
208
238
|
* @minimum 0
|
|
209
239
|
* @maximum 1
|
|
210
240
|
*/
|
|
211
241
|
this.g = 0;
|
|
212
242
|
/**
|
|
213
|
-
*
|
|
243
|
+
* The blue channel, from 0 to 1.
|
|
214
244
|
* @default 1
|
|
215
245
|
* @minimum 0
|
|
216
246
|
* @maximum 1
|
|
217
247
|
*/
|
|
218
248
|
this.b = 1;
|
|
219
249
|
/**
|
|
220
|
-
*
|
|
250
|
+
* The opacity, from 0 (transparent) to 1 (opaque).
|
|
221
251
|
* @default 1
|
|
222
252
|
* @minimum 0
|
|
223
253
|
* @maximum 1
|
|
@@ -238,15 +268,19 @@ export var Color;
|
|
|
238
268
|
}
|
|
239
269
|
}
|
|
240
270
|
Color.RgbaAttomic1Dto = RgbaAttomic1Dto;
|
|
271
|
+
/**
|
|
272
|
+
* A hex color and a mode for `color.invert`.
|
|
273
|
+
*/
|
|
241
274
|
class InvertHexDto {
|
|
242
275
|
constructor(color) {
|
|
243
276
|
/**
|
|
244
|
-
*
|
|
277
|
+
* The color to invert, as a hex text such as `#ff5733`.
|
|
245
278
|
* @default #0000ff
|
|
246
279
|
*/
|
|
247
280
|
this.color = "#0000ff";
|
|
248
281
|
/**
|
|
249
|
-
*
|
|
282
|
+
* When true, the result is black for a light color and white for a dark one instead of the
|
|
283
|
+
* exact inverse; useful for readable text.
|
|
250
284
|
*/
|
|
251
285
|
this.blackAndWhite = false;
|
|
252
286
|
if (color !== undefined) {
|
|
@@ -255,15 +289,19 @@ export var Color;
|
|
|
255
289
|
}
|
|
256
290
|
}
|
|
257
291
|
Color.InvertHexDto = InvertHexDto;
|
|
292
|
+
/**
|
|
293
|
+
* A hex color and a target range for `color.hexToRgbMapped`, `color.getRedParam`,
|
|
294
|
+
* `color.getGreenParam` and `color.getBlueParam`.
|
|
295
|
+
*/
|
|
258
296
|
class HexDtoMapped {
|
|
259
297
|
constructor(color, from, to) {
|
|
260
298
|
/**
|
|
261
|
-
*
|
|
299
|
+
* The color as a hex text such as `#ff5733`.
|
|
262
300
|
* @default #0000ff
|
|
263
301
|
*/
|
|
264
302
|
this.color = "#0000ff";
|
|
265
303
|
/**
|
|
266
|
-
*
|
|
304
|
+
* The value a channel of 0 maps to.
|
|
267
305
|
* @default 0
|
|
268
306
|
* @minimum -Infinity
|
|
269
307
|
* @maximum Infinity
|
|
@@ -271,7 +309,7 @@ export var Color;
|
|
|
271
309
|
*/
|
|
272
310
|
this.from = 0;
|
|
273
311
|
/**
|
|
274
|
-
*
|
|
312
|
+
* The value a channel of 255 maps to; 1 gives channels from 0 to 1.
|
|
275
313
|
* @default 255
|
|
276
314
|
* @minimum -Infinity
|
|
277
315
|
* @maximum Infinity
|
|
@@ -290,10 +328,13 @@ export var Color;
|
|
|
290
328
|
}
|
|
291
329
|
}
|
|
292
330
|
Color.HexDtoMapped = HexDtoMapped;
|
|
331
|
+
/**
|
|
332
|
+
* An `{ r, g, b }` color and the range its channels use, for `color.rgbObjToHex`.
|
|
333
|
+
*/
|
|
293
334
|
class RGBObjectMaxDto {
|
|
294
335
|
constructor(rgb, max) {
|
|
295
336
|
/**
|
|
296
|
-
*
|
|
337
|
+
* The lowest value a channel can have in this object, usually 0.
|
|
297
338
|
* @default 0
|
|
298
339
|
* @minimum 0
|
|
299
340
|
* @maximum 255
|
|
@@ -301,7 +342,8 @@ export var Color;
|
|
|
301
342
|
*/
|
|
302
343
|
this.min = 0;
|
|
303
344
|
/**
|
|
304
|
-
*
|
|
345
|
+
* The highest value a channel can have in this object: 255 or 1; anything else is remapped
|
|
346
|
+
* to 0 to 255 first.
|
|
305
347
|
* @default 255
|
|
306
348
|
* @minimum 0
|
|
307
349
|
* @maximum 255
|
|
@@ -317,10 +359,13 @@ export var Color;
|
|
|
317
359
|
}
|
|
318
360
|
}
|
|
319
361
|
Color.RGBObjectMaxDto = RGBObjectMaxDto;
|
|
362
|
+
/**
|
|
363
|
+
* Three channel values and the range they use, for `color.rgbToHex`.
|
|
364
|
+
*/
|
|
320
365
|
class RGBMinMaxDto {
|
|
321
366
|
constructor(r, g, b, min, max) {
|
|
322
367
|
/**
|
|
323
|
-
*
|
|
368
|
+
* The red channel, within `min` to `max`.
|
|
324
369
|
* @default 255
|
|
325
370
|
* @minimum 0
|
|
326
371
|
* @maximum 255
|
|
@@ -328,7 +373,7 @@ export var Color;
|
|
|
328
373
|
*/
|
|
329
374
|
this.r = 255;
|
|
330
375
|
/**
|
|
331
|
-
*
|
|
376
|
+
* The green channel, within `min` to `max`.
|
|
332
377
|
* @default 255
|
|
333
378
|
* @minimum 0
|
|
334
379
|
* @maximum 255
|
|
@@ -336,15 +381,15 @@ export var Color;
|
|
|
336
381
|
*/
|
|
337
382
|
this.g = 255;
|
|
338
383
|
/**
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
384
|
+
* The blue channel, within `min` to `max`.
|
|
385
|
+
* @default 255
|
|
386
|
+
* @minimum 0
|
|
387
|
+
* @maximum 255
|
|
388
|
+
* @step 1
|
|
389
|
+
*/
|
|
345
390
|
this.b = 255;
|
|
346
391
|
/**
|
|
347
|
-
*
|
|
392
|
+
* The lowest value a channel can have, usually 0.
|
|
348
393
|
* @default 0
|
|
349
394
|
* @minimum 0
|
|
350
395
|
* @maximum 255
|
|
@@ -352,7 +397,8 @@ export var Color;
|
|
|
352
397
|
*/
|
|
353
398
|
this.min = 0;
|
|
354
399
|
/**
|
|
355
|
-
*
|
|
400
|
+
* The highest value a channel can have: 255 or 1; anything else is remapped to 0 to 255
|
|
401
|
+
* first.
|
|
356
402
|
* @default 255
|
|
357
403
|
* @minimum 0
|
|
358
404
|
* @maximum 255
|
|
@@ -377,6 +423,9 @@ export var Color;
|
|
|
377
423
|
}
|
|
378
424
|
}
|
|
379
425
|
Color.RGBMinMaxDto = RGBMinMaxDto;
|
|
426
|
+
/**
|
|
427
|
+
* An `{ r, g, b }` color for `color.rgbToRed`, `color.rgbToGreen` and `color.rgbToBlue`.
|
|
428
|
+
*/
|
|
380
429
|
class RGBObjectDto {
|
|
381
430
|
constructor(rgb) {
|
|
382
431
|
if (rgb !== undefined) {
|
|
@@ -3,31 +3,41 @@
|
|
|
3
3
|
* format and locale used when parsing or printing one.
|
|
4
4
|
*/
|
|
5
5
|
export declare namespace Dates {
|
|
6
|
+
/**
|
|
7
|
+
* One date for the reading and formatting methods of `dates`: `getYear`, `getMonth`,
|
|
8
|
+
* `toISOString` and the rest.
|
|
9
|
+
*/
|
|
6
10
|
class DateDto {
|
|
7
11
|
constructor(date?: Date);
|
|
8
12
|
/**
|
|
9
|
-
* The date
|
|
13
|
+
* The date to read or format.
|
|
10
14
|
* @default undefined
|
|
11
15
|
*/
|
|
12
16
|
date: Date;
|
|
13
17
|
}
|
|
18
|
+
/**
|
|
19
|
+
* A date written as text for `dates.parseDate`.
|
|
20
|
+
*/
|
|
14
21
|
class DateStringDto {
|
|
15
22
|
constructor(dateString?: string);
|
|
16
23
|
/**
|
|
17
|
-
* The
|
|
24
|
+
* The text to read, ideally in ISO 8601 form such as `2024-01-15T14:30:00Z`.
|
|
18
25
|
* @default undefined
|
|
19
26
|
*/
|
|
20
27
|
dateString: string;
|
|
21
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* A date and a new value for its seconds, for `dates.setSeconds` and `dates.setUTCSeconds`.
|
|
31
|
+
*/
|
|
22
32
|
class DateSecondsDto {
|
|
23
33
|
constructor(date?: Date, seconds?: number);
|
|
24
34
|
/**
|
|
25
|
-
* The date to
|
|
35
|
+
* The date to copy; it is not changed.
|
|
26
36
|
* @default undefined
|
|
27
37
|
*/
|
|
28
38
|
date: Date;
|
|
29
39
|
/**
|
|
30
|
-
* The seconds
|
|
40
|
+
* The new seconds from 0 to 59; a value outside the range rolls the date over.
|
|
31
41
|
* @default 30
|
|
32
42
|
* @minimum 0
|
|
33
43
|
* @maximum Infinity
|
|
@@ -35,15 +45,18 @@ export declare namespace Dates {
|
|
|
35
45
|
*/
|
|
36
46
|
seconds: number;
|
|
37
47
|
}
|
|
48
|
+
/**
|
|
49
|
+
* A date and a new value for its day, for `dates.setDayOfMonth` and `dates.setUTCDay`.
|
|
50
|
+
*/
|
|
38
51
|
class DateDayDto {
|
|
39
52
|
constructor(date?: Date, day?: number);
|
|
40
53
|
/**
|
|
41
|
-
* The date
|
|
54
|
+
* The date to copy; it is not changed.
|
|
42
55
|
* @default undefined
|
|
43
56
|
*/
|
|
44
57
|
date: Date;
|
|
45
58
|
/**
|
|
46
|
-
* The day of the date
|
|
59
|
+
* The new day of the month, from 1 to 31; a value outside the range rolls the date over.
|
|
47
60
|
* @default 1
|
|
48
61
|
* @minimum 0
|
|
49
62
|
* @maximum Infinity
|
|
@@ -51,15 +64,19 @@ export declare namespace Dates {
|
|
|
51
64
|
*/
|
|
52
65
|
day: number;
|
|
53
66
|
}
|
|
67
|
+
/**
|
|
68
|
+
* A date and a new value for its year, for `dates.setYear` and `dates.setUTCYear`.
|
|
69
|
+
*/
|
|
54
70
|
class DateYearDto {
|
|
55
71
|
constructor(date?: Date, year?: number);
|
|
56
72
|
/**
|
|
57
|
-
* The date
|
|
73
|
+
* The date to copy; it is not changed.
|
|
58
74
|
* @default undefined
|
|
59
75
|
*/
|
|
60
76
|
date: Date;
|
|
61
77
|
/**
|
|
62
|
-
* The year
|
|
78
|
+
* The new year as a full number such as 2024; a value outside the range rolls the date
|
|
79
|
+
* over.
|
|
63
80
|
* @default 1
|
|
64
81
|
* @minimum 0
|
|
65
82
|
* @maximum Infinity
|
|
@@ -67,15 +84,19 @@ export declare namespace Dates {
|
|
|
67
84
|
*/
|
|
68
85
|
year: number;
|
|
69
86
|
}
|
|
87
|
+
/**
|
|
88
|
+
* A date and a new value for its month, for `dates.setMonth` and `dates.setUTCMonth`.
|
|
89
|
+
*/
|
|
70
90
|
class DateMonthDto {
|
|
71
91
|
constructor(date?: Date, month?: number);
|
|
72
92
|
/**
|
|
73
|
-
* The date
|
|
93
|
+
* The date to copy; it is not changed.
|
|
74
94
|
* @default undefined
|
|
75
95
|
*/
|
|
76
96
|
date: Date;
|
|
77
97
|
/**
|
|
78
|
-
* The month
|
|
98
|
+
* The new month counting from 0: 0 is January, 11 December; a value outside the range rolls
|
|
99
|
+
* the date over.
|
|
79
100
|
* @default 1
|
|
80
101
|
* @minimum 0
|
|
81
102
|
* @maximum Infinity
|
|
@@ -83,15 +104,18 @@ export declare namespace Dates {
|
|
|
83
104
|
*/
|
|
84
105
|
month: number;
|
|
85
106
|
}
|
|
107
|
+
/**
|
|
108
|
+
* A date and a new value for its hours, for `dates.setHours` and `dates.setUTCHours`.
|
|
109
|
+
*/
|
|
86
110
|
class DateHoursDto {
|
|
87
111
|
constructor(date?: Date, hours?: number);
|
|
88
112
|
/**
|
|
89
|
-
* The date
|
|
113
|
+
* The date to copy; it is not changed.
|
|
90
114
|
* @default undefined
|
|
91
115
|
*/
|
|
92
116
|
date: Date;
|
|
93
117
|
/**
|
|
94
|
-
* The hours
|
|
118
|
+
* The new hours from 0 to 23; a value outside the range rolls the date over.
|
|
95
119
|
* @default 1
|
|
96
120
|
* @minimum 0
|
|
97
121
|
* @maximum Infinity
|
|
@@ -99,15 +123,18 @@ export declare namespace Dates {
|
|
|
99
123
|
*/
|
|
100
124
|
hours: number;
|
|
101
125
|
}
|
|
126
|
+
/**
|
|
127
|
+
* A date and a new value for its minutes, for `dates.setMinutes` and `dates.setUTCMinutes`.
|
|
128
|
+
*/
|
|
102
129
|
class DateMinutesDto {
|
|
103
130
|
constructor(date?: Date, minutes?: number);
|
|
104
131
|
/**
|
|
105
|
-
* The date
|
|
132
|
+
* The date to copy; it is not changed.
|
|
106
133
|
* @default undefined
|
|
107
134
|
*/
|
|
108
135
|
date: Date;
|
|
109
136
|
/**
|
|
110
|
-
* The minutes
|
|
137
|
+
* The new minutes from 0 to 59; a value outside the range rolls the date over.
|
|
111
138
|
* @default 1
|
|
112
139
|
* @minimum 0
|
|
113
140
|
* @maximum Infinity
|
|
@@ -115,15 +142,19 @@ export declare namespace Dates {
|
|
|
115
142
|
*/
|
|
116
143
|
minutes: number;
|
|
117
144
|
}
|
|
145
|
+
/**
|
|
146
|
+
* A date and a new value for its milliseconds, for `dates.setMilliseconds` and
|
|
147
|
+
* `dates.setUTCMilliseconds`.
|
|
148
|
+
*/
|
|
118
149
|
class DateMillisecondsDto {
|
|
119
150
|
constructor(date?: Date, milliseconds?: number);
|
|
120
151
|
/**
|
|
121
|
-
* The date
|
|
152
|
+
* The date to copy; it is not changed.
|
|
122
153
|
* @default undefined
|
|
123
154
|
*/
|
|
124
155
|
date: Date;
|
|
125
156
|
/**
|
|
126
|
-
* The milliseconds
|
|
157
|
+
* The new milliseconds from 0 to 999; a value outside the range rolls the date over.
|
|
127
158
|
* @default 1
|
|
128
159
|
* @minimum 0
|
|
129
160
|
* @maximum Infinity
|
|
@@ -131,15 +162,18 @@ export declare namespace Dates {
|
|
|
131
162
|
*/
|
|
132
163
|
milliseconds: number;
|
|
133
164
|
}
|
|
165
|
+
/**
|
|
166
|
+
* A date and a Unix timestamp for `dates.setTime`.
|
|
167
|
+
*/
|
|
134
168
|
class DateTimeDto {
|
|
135
169
|
constructor(date?: Date, time?: number);
|
|
136
170
|
/**
|
|
137
|
-
* The date
|
|
171
|
+
* The date to copy; it is not changed.
|
|
138
172
|
* @default undefined
|
|
139
173
|
*/
|
|
140
174
|
date: Date;
|
|
141
175
|
/**
|
|
142
|
-
* The
|
|
176
|
+
* The new moment as milliseconds since 1 January 1970 at 00:00 UTC.
|
|
143
177
|
* @default 1
|
|
144
178
|
* @minimum 0
|
|
145
179
|
* @maximum Infinity
|
|
@@ -147,10 +181,13 @@ export declare namespace Dates {
|
|
|
147
181
|
*/
|
|
148
182
|
time: number;
|
|
149
183
|
}
|
|
184
|
+
/**
|
|
185
|
+
* A Unix timestamp for `dates.createFromUnixTimeStamp`, which turns it into a date.
|
|
186
|
+
*/
|
|
150
187
|
class CreateFromUnixTimeStampDto {
|
|
151
188
|
constructor(unixTimeStamp?: number);
|
|
152
189
|
/**
|
|
153
|
-
*
|
|
190
|
+
* Milliseconds since 1 January 1970 at 00:00 UTC.
|
|
154
191
|
* @default 1
|
|
155
192
|
* @minimum 0
|
|
156
193
|
* @maximum Infinity
|
|
@@ -158,10 +195,14 @@ export declare namespace Dates {
|
|
|
158
195
|
*/
|
|
159
196
|
unixTimeStamp: number;
|
|
160
197
|
}
|
|
198
|
+
/**
|
|
199
|
+
* The parts of a date for `dates.createDate` and `dates.createDateUTC`; a part outside its
|
|
200
|
+
* range rolls the date over.
|
|
201
|
+
*/
|
|
161
202
|
class CreateDateDto {
|
|
162
203
|
constructor(year?: number, month?: number, day?: number, hours?: number, minutes?: number, seconds?: number, milliseconds?: number);
|
|
163
204
|
/**
|
|
164
|
-
* The year
|
|
205
|
+
* The full year, such as 2024.
|
|
165
206
|
* @default 1
|
|
166
207
|
* @minimum 0
|
|
167
208
|
* @maximum Infinity
|
|
@@ -169,7 +210,7 @@ export declare namespace Dates {
|
|
|
169
210
|
*/
|
|
170
211
|
year: number;
|
|
171
212
|
/**
|
|
172
|
-
* The month
|
|
213
|
+
* The month counting from 0: 0 is January, 11 December.
|
|
173
214
|
* @default 1
|
|
174
215
|
* @minimum 0
|
|
175
216
|
* @maximum Infinity
|
|
@@ -177,7 +218,7 @@ export declare namespace Dates {
|
|
|
177
218
|
*/
|
|
178
219
|
month: number;
|
|
179
220
|
/**
|
|
180
|
-
* The day of the month
|
|
221
|
+
* The day of the month, from 1 to 31.
|
|
181
222
|
* @default 1
|
|
182
223
|
* @minimum 0
|
|
183
224
|
* @maximum Infinity
|
|
@@ -185,7 +226,7 @@ export declare namespace Dates {
|
|
|
185
226
|
*/
|
|
186
227
|
day: number;
|
|
187
228
|
/**
|
|
188
|
-
* The
|
|
229
|
+
* The hour, from 0 to 23.
|
|
189
230
|
* @default 1
|
|
190
231
|
* @minimum 0
|
|
191
232
|
* @maximum Infinity
|
|
@@ -193,7 +234,7 @@ export declare namespace Dates {
|
|
|
193
234
|
*/
|
|
194
235
|
hours: number;
|
|
195
236
|
/**
|
|
196
|
-
* The minutes
|
|
237
|
+
* The minutes, from 0 to 59.
|
|
197
238
|
* @default 1
|
|
198
239
|
* @minimum 0
|
|
199
240
|
* @maximum Infinity
|
|
@@ -201,7 +242,7 @@ export declare namespace Dates {
|
|
|
201
242
|
*/
|
|
202
243
|
minutes: number;
|
|
203
244
|
/**
|
|
204
|
-
* The seconds
|
|
245
|
+
* The seconds, from 0 to 59.
|
|
205
246
|
* @default 1
|
|
206
247
|
* @minimum 0
|
|
207
248
|
* @maximum Infinity
|
|
@@ -209,7 +250,7 @@ export declare namespace Dates {
|
|
|
209
250
|
*/
|
|
210
251
|
seconds: number;
|
|
211
252
|
/**
|
|
212
|
-
* The milliseconds
|
|
253
|
+
* The milliseconds, from 0 to 999.
|
|
213
254
|
* @default 1
|
|
214
255
|
* @minimum 0
|
|
215
256
|
* @maximum Infinity
|