@daysnap/utils 0.0.87 → 0.0.89
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/docs/interfaces/StorageManager.md +4 -4
- package/docs/interfaces/Trap.md +5 -5
- package/docs/modules.md +200 -118
- package/es/decode.d.ts +2 -0
- package/es/decode.js +47 -0
- package/es/getScrollTop.d.ts +4 -0
- package/es/getScrollTop.js +9 -0
- package/es/index.d.ts +3 -0
- package/es/index.js +3 -0
- package/es/setScrollTop.d.ts +4 -0
- package/es/setScrollTop.js +9 -0
- package/lib/decode.d.ts +2 -0
- package/lib/decode.js +52 -0
- package/lib/getScrollTop.d.ts +4 -0
- package/lib/getScrollTop.js +13 -0
- package/lib/index.d.ts +3 -0
- package/lib/index.js +3 -0
- package/lib/setScrollTop.d.ts +4 -0
- package/lib/setScrollTop.js +13 -0
- package/package.json +1 -1
package/docs/modules.md
CHANGED
|
@@ -16,8 +16,10 @@
|
|
|
16
16
|
### Functions
|
|
17
17
|
|
|
18
18
|
- [ato](modules.md#ato)
|
|
19
|
+
- [atob](modules.md#atob)
|
|
19
20
|
- [base64ToBlob](modules.md#base64toblob)
|
|
20
21
|
- [blobToBase64](modules.md#blobtobase64)
|
|
22
|
+
- [btoa](modules.md#btoa)
|
|
21
23
|
- [cached](modules.md#cached)
|
|
22
24
|
- [camelCase](modules.md#camelcase)
|
|
23
25
|
- [canvasToBlob](modules.md#canvastoblob)
|
|
@@ -58,6 +60,7 @@
|
|
|
58
60
|
- [getRandom](modules.md#getrandom)
|
|
59
61
|
- [getRandomColor](modules.md#getrandomcolor)
|
|
60
62
|
- [getRandomNumber](modules.md#getrandomnumber)
|
|
63
|
+
- [getScrollTop](modules.md#getscrolltop)
|
|
61
64
|
- [getVideoInfo](modules.md#getvideoinfo)
|
|
62
65
|
- [inBrowser](modules.md#inbrowser)
|
|
63
66
|
- [insertLink](modules.md#insertlink)
|
|
@@ -117,6 +120,7 @@
|
|
|
117
120
|
- [rgbToHex](modules.md#rgbtohex)
|
|
118
121
|
- [round](modules.md#round)
|
|
119
122
|
- [scrollToTop](modules.md#scrolltotop)
|
|
123
|
+
- [setScrollTop](modules.md#setscrolltop)
|
|
120
124
|
- [sleep](modules.md#sleep)
|
|
121
125
|
- [splitArray](modules.md#splitarray)
|
|
122
126
|
- [stringTrim](modules.md#stringtrim)
|
|
@@ -138,7 +142,7 @@
|
|
|
138
142
|
|
|
139
143
|
#### Defined in
|
|
140
144
|
|
|
141
|
-
[trap.ts:15](https://github.com/daysnap/utils/blob/
|
|
145
|
+
[trap.ts:15](https://github.com/daysnap/utils/blob/fb256c2/src/trap.ts#L15)
|
|
142
146
|
|
|
143
147
|
## Functions
|
|
144
148
|
|
|
@@ -176,7 +180,7 @@ res = { '1': '男', '2': '女' }
|
|
|
176
180
|
|
|
177
181
|
#### Defined in
|
|
178
182
|
|
|
179
|
-
[ato.ts:12](https://github.com/daysnap/utils/blob/
|
|
183
|
+
[ato.ts:12](https://github.com/daysnap/utils/blob/fb256c2/src/ato.ts#L12)
|
|
180
184
|
|
|
181
185
|
▸ **ato**<`T`, `K`\>(`options`, `labelKey`, `valueKey`): `Record`<`T`[`K`], `any`\>
|
|
182
186
|
|
|
@@ -201,7 +205,27 @@ res = { '1': '男', '2': '女' }
|
|
|
201
205
|
|
|
202
206
|
#### Defined in
|
|
203
207
|
|
|
204
|
-
[ato.ts:16](https://github.com/daysnap/utils/blob/
|
|
208
|
+
[ato.ts:16](https://github.com/daysnap/utils/blob/fb256c2/src/ato.ts#L16)
|
|
209
|
+
|
|
210
|
+
___
|
|
211
|
+
|
|
212
|
+
### atob
|
|
213
|
+
|
|
214
|
+
▸ **atob**(`string`): `string`
|
|
215
|
+
|
|
216
|
+
#### Parameters
|
|
217
|
+
|
|
218
|
+
| Name | Type |
|
|
219
|
+
| :------ | :------ |
|
|
220
|
+
| `string` | `string` |
|
|
221
|
+
|
|
222
|
+
#### Returns
|
|
223
|
+
|
|
224
|
+
`string`
|
|
225
|
+
|
|
226
|
+
#### Defined in
|
|
227
|
+
|
|
228
|
+
[decode.ts:41](https://github.com/daysnap/utils/blob/fb256c2/src/decode.ts#L41)
|
|
205
229
|
|
|
206
230
|
___
|
|
207
231
|
|
|
@@ -224,7 +248,7 @@ base64 转 blob
|
|
|
224
248
|
|
|
225
249
|
#### Defined in
|
|
226
250
|
|
|
227
|
-
[base64ToBlob.ts:6](https://github.com/daysnap/utils/blob/
|
|
251
|
+
[base64ToBlob.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/base64ToBlob.ts#L6)
|
|
228
252
|
|
|
229
253
|
___
|
|
230
254
|
|
|
@@ -246,7 +270,27 @@ blob 转 base64
|
|
|
246
270
|
|
|
247
271
|
#### Defined in
|
|
248
272
|
|
|
249
|
-
[blobToBase64.ts:4](https://github.com/daysnap/utils/blob/
|
|
273
|
+
[blobToBase64.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/blobToBase64.ts#L4)
|
|
274
|
+
|
|
275
|
+
___
|
|
276
|
+
|
|
277
|
+
### btoa
|
|
278
|
+
|
|
279
|
+
▸ **btoa**(`string`): `string`
|
|
280
|
+
|
|
281
|
+
#### Parameters
|
|
282
|
+
|
|
283
|
+
| Name | Type |
|
|
284
|
+
| :------ | :------ |
|
|
285
|
+
| `string` | `string` |
|
|
286
|
+
|
|
287
|
+
#### Returns
|
|
288
|
+
|
|
289
|
+
`string`
|
|
290
|
+
|
|
291
|
+
#### Defined in
|
|
292
|
+
|
|
293
|
+
[decode.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/decode.ts#L8)
|
|
250
294
|
|
|
251
295
|
___
|
|
252
296
|
|
|
@@ -287,7 +331,7 @@ ___
|
|
|
287
331
|
|
|
288
332
|
#### Defined in
|
|
289
333
|
|
|
290
|
-
[cached.ts:5](https://github.com/daysnap/utils/blob/
|
|
334
|
+
[cached.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/cached.ts#L5)
|
|
291
335
|
|
|
292
336
|
___
|
|
293
337
|
|
|
@@ -310,7 +354,7 @@ camelCase('hello-world') => helloWorld
|
|
|
310
354
|
|
|
311
355
|
#### Defined in
|
|
312
356
|
|
|
313
|
-
[camelCase.ts:5](https://github.com/daysnap/utils/blob/
|
|
357
|
+
[camelCase.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/camelCase.ts#L5)
|
|
314
358
|
|
|
315
359
|
___
|
|
316
360
|
|
|
@@ -334,7 +378,7 @@ canvas 转 blob 文件
|
|
|
334
378
|
|
|
335
379
|
#### Defined in
|
|
336
380
|
|
|
337
|
-
[canvasToBlob.ts:4](https://github.com/daysnap/utils/blob/
|
|
381
|
+
[canvasToBlob.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/canvasToBlob.ts#L4)
|
|
338
382
|
|
|
339
383
|
___
|
|
340
384
|
|
|
@@ -357,7 +401,7 @@ capitalize('hello world') => Hello world
|
|
|
357
401
|
|
|
358
402
|
#### Defined in
|
|
359
403
|
|
|
360
|
-
[capitalize.ts:5](https://github.com/daysnap/utils/blob/
|
|
404
|
+
[capitalize.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/capitalize.ts#L5)
|
|
361
405
|
|
|
362
406
|
___
|
|
363
407
|
|
|
@@ -381,7 +425,7 @@ ___
|
|
|
381
425
|
|
|
382
426
|
#### Defined in
|
|
383
427
|
|
|
384
|
-
[clamp.ts:7](https://github.com/daysnap/utils/blob/
|
|
428
|
+
[clamp.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/clamp.ts#L7)
|
|
385
429
|
|
|
386
430
|
___
|
|
387
431
|
|
|
@@ -409,7 +453,7 @@ ___
|
|
|
409
453
|
|
|
410
454
|
#### Defined in
|
|
411
455
|
|
|
412
|
-
[clone.ts:8](https://github.com/daysnap/utils/blob/
|
|
456
|
+
[clone.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/clone.ts#L8)
|
|
413
457
|
|
|
414
458
|
___
|
|
415
459
|
|
|
@@ -437,7 +481,7 @@ ___
|
|
|
437
481
|
|
|
438
482
|
#### Defined in
|
|
439
483
|
|
|
440
|
-
[cloneSimple.ts:7](https://github.com/daysnap/utils/blob/
|
|
484
|
+
[cloneSimple.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/cloneSimple.ts#L7)
|
|
441
485
|
|
|
442
486
|
___
|
|
443
487
|
|
|
@@ -459,7 +503,7 @@ ___
|
|
|
459
503
|
|
|
460
504
|
#### Defined in
|
|
461
505
|
|
|
462
|
-
[createHexColorByHash.ts:4](https://github.com/daysnap/utils/blob/
|
|
506
|
+
[createHexColorByHash.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/createHexColorByHash.ts#L4)
|
|
463
507
|
|
|
464
508
|
___
|
|
465
509
|
|
|
@@ -485,7 +529,7 @@ ___
|
|
|
485
529
|
|
|
486
530
|
#### Defined in
|
|
487
531
|
|
|
488
|
-
[compareVersion.ts:9](https://github.com/daysnap/utils/blob/
|
|
532
|
+
[compareVersion.ts:9](https://github.com/daysnap/utils/blob/fb256c2/src/compareVersion.ts#L9)
|
|
489
533
|
|
|
490
534
|
___
|
|
491
535
|
|
|
@@ -507,7 +551,7 @@ ___
|
|
|
507
551
|
|
|
508
552
|
#### Defined in
|
|
509
553
|
|
|
510
|
-
[compressImage.ts:6](https://github.com/daysnap/utils/blob/
|
|
554
|
+
[compressImage.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/compressImage.ts#L6)
|
|
511
555
|
|
|
512
556
|
___
|
|
513
557
|
|
|
@@ -545,7 +589,7 @@ ___
|
|
|
545
589
|
|
|
546
590
|
#### Defined in
|
|
547
591
|
|
|
548
|
-
[createLinearFunction.ts:9](https://github.com/daysnap/utils/blob/
|
|
592
|
+
[createLinearFunction.ts:9](https://github.com/daysnap/utils/blob/fb256c2/src/createLinearFunction.ts#L9)
|
|
549
593
|
|
|
550
594
|
___
|
|
551
595
|
|
|
@@ -577,7 +621,7 @@ ___
|
|
|
577
621
|
|
|
578
622
|
#### Defined in
|
|
579
623
|
|
|
580
|
-
[trap.ts:49](https://github.com/daysnap/utils/blob/
|
|
624
|
+
[trap.ts:49](https://github.com/daysnap/utils/blob/fb256c2/src/trap.ts#L49)
|
|
581
625
|
|
|
582
626
|
___
|
|
583
627
|
|
|
@@ -640,7 +684,7 @@ fn() 执行的时候就会执行showLoading
|
|
|
640
684
|
|
|
641
685
|
#### Defined in
|
|
642
686
|
|
|
643
|
-
[createWithLoading.ts:9](https://github.com/daysnap/utils/blob/
|
|
687
|
+
[createWithLoading.ts:9](https://github.com/daysnap/utils/blob/fb256c2/src/createWithLoading.ts#L9)
|
|
644
688
|
|
|
645
689
|
___
|
|
646
690
|
|
|
@@ -683,7 +727,7 @@ ___
|
|
|
683
727
|
|
|
684
728
|
#### Defined in
|
|
685
729
|
|
|
686
|
-
[debounce.ts:5](https://github.com/daysnap/utils/blob/
|
|
730
|
+
[debounce.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/debounce.ts#L5)
|
|
687
731
|
|
|
688
732
|
___
|
|
689
733
|
|
|
@@ -707,7 +751,7 @@ ___
|
|
|
707
751
|
|
|
708
752
|
#### Defined in
|
|
709
753
|
|
|
710
|
-
[downloadFile.ts:4](https://github.com/daysnap/utils/blob/
|
|
754
|
+
[downloadFile.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/downloadFile.ts#L4)
|
|
711
755
|
|
|
712
756
|
___
|
|
713
757
|
|
|
@@ -736,7 +780,7 @@ ___
|
|
|
736
780
|
|
|
737
781
|
#### Defined in
|
|
738
782
|
|
|
739
|
-
[each.ts:4](https://github.com/daysnap/utils/blob/
|
|
783
|
+
[each.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/each.ts#L4)
|
|
740
784
|
|
|
741
785
|
▸ **each**<`T`\>(`data`, `callback`): `void`
|
|
742
786
|
|
|
@@ -759,7 +803,7 @@ ___
|
|
|
759
803
|
|
|
760
804
|
#### Defined in
|
|
761
805
|
|
|
762
|
-
[each.ts:8](https://github.com/daysnap/utils/blob/
|
|
806
|
+
[each.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/each.ts#L8)
|
|
763
807
|
|
|
764
808
|
___
|
|
765
809
|
|
|
@@ -777,7 +821,7 @@ ___
|
|
|
777
821
|
|
|
778
822
|
#### Defined in
|
|
779
823
|
|
|
780
|
-
[exitFullscreen.ts:6](https://github.com/daysnap/utils/blob/
|
|
824
|
+
[exitFullscreen.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/exitFullscreen.ts#L6)
|
|
781
825
|
|
|
782
826
|
___
|
|
783
827
|
|
|
@@ -806,7 +850,7 @@ ___
|
|
|
806
850
|
|
|
807
851
|
#### Defined in
|
|
808
852
|
|
|
809
|
-
[storage/factory.ts:8](https://github.com/daysnap/utils/blob/
|
|
853
|
+
[storage/factory.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/storage/factory.ts#L8)
|
|
810
854
|
|
|
811
855
|
___
|
|
812
856
|
|
|
@@ -828,7 +872,7 @@ ___
|
|
|
828
872
|
|
|
829
873
|
#### Defined in
|
|
830
874
|
|
|
831
|
-
[filterBankCardNo.ts:4](https://github.com/daysnap/utils/blob/
|
|
875
|
+
[filterBankCardNo.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/filterBankCardNo.ts#L4)
|
|
832
876
|
|
|
833
877
|
___
|
|
834
878
|
|
|
@@ -850,7 +894,7 @@ ___
|
|
|
850
894
|
|
|
851
895
|
#### Defined in
|
|
852
896
|
|
|
853
|
-
[filterCRLF.ts:4](https://github.com/daysnap/utils/blob/
|
|
897
|
+
[filterCRLF.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/filterCRLF.ts#L4)
|
|
854
898
|
|
|
855
899
|
___
|
|
856
900
|
|
|
@@ -872,7 +916,7 @@ ___
|
|
|
872
916
|
|
|
873
917
|
#### Defined in
|
|
874
918
|
|
|
875
|
-
[filterEmoji.ts:4](https://github.com/daysnap/utils/blob/
|
|
919
|
+
[filterEmoji.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/filterEmoji.ts#L4)
|
|
876
920
|
|
|
877
921
|
___
|
|
878
922
|
|
|
@@ -895,7 +939,7 @@ ___
|
|
|
895
939
|
|
|
896
940
|
#### Defined in
|
|
897
941
|
|
|
898
|
-
[filterEmptyValue.ts:12](https://github.com/daysnap/utils/blob/
|
|
942
|
+
[filterEmptyValue.ts:12](https://github.com/daysnap/utils/blob/fb256c2/src/filterEmptyValue.ts#L12)
|
|
899
943
|
|
|
900
944
|
___
|
|
901
945
|
|
|
@@ -918,7 +962,7 @@ ___
|
|
|
918
962
|
|
|
919
963
|
#### Defined in
|
|
920
964
|
|
|
921
|
-
[filterIdCard.ts:5](https://github.com/daysnap/utils/blob/
|
|
965
|
+
[filterIdCard.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/filterIdCard.ts#L5)
|
|
922
966
|
|
|
923
967
|
___
|
|
924
968
|
|
|
@@ -940,7 +984,7 @@ ___
|
|
|
940
984
|
|
|
941
985
|
#### Defined in
|
|
942
986
|
|
|
943
|
-
[filterName.ts:4](https://github.com/daysnap/utils/blob/
|
|
987
|
+
[filterName.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/filterName.ts#L4)
|
|
944
988
|
|
|
945
989
|
___
|
|
946
990
|
|
|
@@ -965,7 +1009,7 @@ filterPhone('13177778888', ' ') => 131 **** 8888
|
|
|
965
1009
|
|
|
966
1010
|
#### Defined in
|
|
967
1011
|
|
|
968
|
-
[filterPhone.ts:6](https://github.com/daysnap/utils/blob/
|
|
1012
|
+
[filterPhone.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/filterPhone.ts#L6)
|
|
969
1013
|
|
|
970
1014
|
___
|
|
971
1015
|
|
|
@@ -992,7 +1036,7 @@ str = '131****8888'
|
|
|
992
1036
|
|
|
993
1037
|
#### Defined in
|
|
994
1038
|
|
|
995
|
-
[filterString.ts:6](https://github.com/daysnap/utils/blob/
|
|
1039
|
+
[filterString.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/filterString.ts#L6)
|
|
996
1040
|
|
|
997
1041
|
___
|
|
998
1042
|
|
|
@@ -1015,7 +1059,7 @@ ___
|
|
|
1015
1059
|
|
|
1016
1060
|
#### Defined in
|
|
1017
1061
|
|
|
1018
|
-
[formatAmount.ts:4](https://github.com/daysnap/utils/blob/
|
|
1062
|
+
[formatAmount.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/formatAmount.ts#L4)
|
|
1019
1063
|
|
|
1020
1064
|
___
|
|
1021
1065
|
|
|
@@ -1039,7 +1083,7 @@ ___
|
|
|
1039
1083
|
|
|
1040
1084
|
#### Defined in
|
|
1041
1085
|
|
|
1042
|
-
[formatDate.ts:8](https://github.com/daysnap/utils/blob/
|
|
1086
|
+
[formatDate.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/formatDate.ts#L8)
|
|
1043
1087
|
|
|
1044
1088
|
___
|
|
1045
1089
|
|
|
@@ -1062,7 +1106,7 @@ fix iOS 日期时间格式如果是 - 就会报错的问题
|
|
|
1062
1106
|
|
|
1063
1107
|
#### Defined in
|
|
1064
1108
|
|
|
1065
|
-
[formatDateStr.ts:5](https://github.com/daysnap/utils/blob/
|
|
1109
|
+
[formatDateStr.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/formatDateStr.ts#L5)
|
|
1066
1110
|
|
|
1067
1111
|
___
|
|
1068
1112
|
|
|
@@ -1082,7 +1126,7 @@ ___
|
|
|
1082
1126
|
|
|
1083
1127
|
#### Defined in
|
|
1084
1128
|
|
|
1085
|
-
[formartDateToZN.ts:3](https://github.com/daysnap/utils/blob/
|
|
1129
|
+
[formartDateToZN.ts:3](https://github.com/daysnap/utils/blob/fb256c2/src/formartDateToZN.ts#L3)
|
|
1086
1130
|
|
|
1087
1131
|
___
|
|
1088
1132
|
|
|
@@ -1107,7 +1151,7 @@ formatMessage({ a: '123', b: { ba: '456' } }, ['b.ba']) => '456'
|
|
|
1107
1151
|
|
|
1108
1152
|
#### Defined in
|
|
1109
1153
|
|
|
1110
|
-
[formatMessage.ts:11](https://github.com/daysnap/utils/blob/
|
|
1154
|
+
[formatMessage.ts:11](https://github.com/daysnap/utils/blob/fb256c2/src/formatMessage.ts#L11)
|
|
1111
1155
|
|
|
1112
1156
|
___
|
|
1113
1157
|
|
|
@@ -1139,7 +1183,7 @@ rest = { xxx: 1 }
|
|
|
1139
1183
|
|
|
1140
1184
|
#### Defined in
|
|
1141
1185
|
|
|
1142
|
-
[formatPathParams.ts:8](https://github.com/daysnap/utils/blob/
|
|
1186
|
+
[formatPathParams.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/formatPathParams.ts#L8)
|
|
1143
1187
|
|
|
1144
1188
|
___
|
|
1145
1189
|
|
|
@@ -1161,7 +1205,7 @@ ___
|
|
|
1161
1205
|
|
|
1162
1206
|
#### Defined in
|
|
1163
1207
|
|
|
1164
|
-
[getBlobByUrl.ts:4](https://github.com/daysnap/utils/blob/
|
|
1208
|
+
[getBlobByUrl.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/getBlobByUrl.ts#L4)
|
|
1165
1209
|
|
|
1166
1210
|
___
|
|
1167
1211
|
|
|
@@ -1184,7 +1228,7 @@ ___
|
|
|
1184
1228
|
|
|
1185
1229
|
#### Defined in
|
|
1186
1230
|
|
|
1187
|
-
[storage/index.ts:9](https://github.com/daysnap/utils/blob/
|
|
1231
|
+
[storage/index.ts:9](https://github.com/daysnap/utils/blob/fb256c2/src/storage/index.ts#L9)
|
|
1188
1232
|
|
|
1189
1233
|
___
|
|
1190
1234
|
|
|
@@ -1206,7 +1250,7 @@ ___
|
|
|
1206
1250
|
|
|
1207
1251
|
#### Defined in
|
|
1208
1252
|
|
|
1209
|
-
[getDayMillisecond.ts:4](https://github.com/daysnap/utils/blob/
|
|
1253
|
+
[getDayMillisecond.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/getDayMillisecond.ts#L4)
|
|
1210
1254
|
|
|
1211
1255
|
___
|
|
1212
1256
|
|
|
@@ -1228,7 +1272,7 @@ ___
|
|
|
1228
1272
|
|
|
1229
1273
|
#### Defined in
|
|
1230
1274
|
|
|
1231
|
-
[getImageInfo.ts:4](https://github.com/daysnap/utils/blob/
|
|
1275
|
+
[getImageInfo.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/getImageInfo.ts#L4)
|
|
1232
1276
|
|
|
1233
1277
|
___
|
|
1234
1278
|
|
|
@@ -1251,7 +1295,7 @@ ___
|
|
|
1251
1295
|
|
|
1252
1296
|
#### Defined in
|
|
1253
1297
|
|
|
1254
|
-
[storage/index.ts:9](https://github.com/daysnap/utils/blob/
|
|
1298
|
+
[storage/index.ts:9](https://github.com/daysnap/utils/blob/fb256c2/src/storage/index.ts#L9)
|
|
1255
1299
|
|
|
1256
1300
|
___
|
|
1257
1301
|
|
|
@@ -1274,7 +1318,7 @@ ___
|
|
|
1274
1318
|
|
|
1275
1319
|
#### Defined in
|
|
1276
1320
|
|
|
1277
|
-
[getRandom.ts:7](https://github.com/daysnap/utils/blob/
|
|
1321
|
+
[getRandom.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/getRandom.ts#L7)
|
|
1278
1322
|
|
|
1279
1323
|
___
|
|
1280
1324
|
|
|
@@ -1290,7 +1334,7 @@ ___
|
|
|
1290
1334
|
|
|
1291
1335
|
#### Defined in
|
|
1292
1336
|
|
|
1293
|
-
[getRandomColor.ts:4](https://github.com/daysnap/utils/blob/
|
|
1337
|
+
[getRandomColor.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/getRandomColor.ts#L4)
|
|
1294
1338
|
|
|
1295
1339
|
___
|
|
1296
1340
|
|
|
@@ -1312,7 +1356,23 @@ ___
|
|
|
1312
1356
|
|
|
1313
1357
|
#### Defined in
|
|
1314
1358
|
|
|
1315
|
-
[getRandomNumber.ts:7](https://github.com/daysnap/utils/blob/
|
|
1359
|
+
[getRandomNumber.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/getRandomNumber.ts#L7)
|
|
1360
|
+
|
|
1361
|
+
___
|
|
1362
|
+
|
|
1363
|
+
### getScrollTop
|
|
1364
|
+
|
|
1365
|
+
▸ **getScrollTop**(): `number`
|
|
1366
|
+
|
|
1367
|
+
获取 scrollTop
|
|
1368
|
+
|
|
1369
|
+
#### Returns
|
|
1370
|
+
|
|
1371
|
+
`number`
|
|
1372
|
+
|
|
1373
|
+
#### Defined in
|
|
1374
|
+
|
|
1375
|
+
[getScrollTop.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/getScrollTop.ts#L4)
|
|
1316
1376
|
|
|
1317
1377
|
___
|
|
1318
1378
|
|
|
@@ -1334,7 +1394,7 @@ ___
|
|
|
1334
1394
|
|
|
1335
1395
|
#### Defined in
|
|
1336
1396
|
|
|
1337
|
-
[getVideoInfo.ts:4](https://github.com/daysnap/utils/blob/
|
|
1397
|
+
[getVideoInfo.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/getVideoInfo.ts#L4)
|
|
1338
1398
|
|
|
1339
1399
|
___
|
|
1340
1400
|
|
|
@@ -1350,7 +1410,7 @@ ___
|
|
|
1350
1410
|
|
|
1351
1411
|
#### Defined in
|
|
1352
1412
|
|
|
1353
|
-
[inBrowser.ts:4](https://github.com/daysnap/utils/blob/
|
|
1413
|
+
[inBrowser.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/inBrowser.ts#L4)
|
|
1354
1414
|
|
|
1355
1415
|
___
|
|
1356
1416
|
|
|
@@ -1372,7 +1432,7 @@ ___
|
|
|
1372
1432
|
|
|
1373
1433
|
#### Defined in
|
|
1374
1434
|
|
|
1375
|
-
[insertLink.ts:4](https://github.com/daysnap/utils/blob/
|
|
1435
|
+
[insertLink.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/insertLink.ts#L4)
|
|
1376
1436
|
|
|
1377
1437
|
▸ **insertLink**(`href`, `callback`): `void`
|
|
1378
1438
|
|
|
@@ -1389,7 +1449,7 @@ ___
|
|
|
1389
1449
|
|
|
1390
1450
|
#### Defined in
|
|
1391
1451
|
|
|
1392
|
-
[insertLink.ts:5](https://github.com/daysnap/utils/blob/
|
|
1452
|
+
[insertLink.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/insertLink.ts#L5)
|
|
1393
1453
|
|
|
1394
1454
|
___
|
|
1395
1455
|
|
|
@@ -1411,7 +1471,7 @@ ___
|
|
|
1411
1471
|
|
|
1412
1472
|
#### Defined in
|
|
1413
1473
|
|
|
1414
|
-
[insertScript.ts:4](https://github.com/daysnap/utils/blob/
|
|
1474
|
+
[insertScript.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/insertScript.ts#L4)
|
|
1415
1475
|
|
|
1416
1476
|
▸ **insertScript**(`src`, `callback`): `void`
|
|
1417
1477
|
|
|
@@ -1428,7 +1488,7 @@ ___
|
|
|
1428
1488
|
|
|
1429
1489
|
#### Defined in
|
|
1430
1490
|
|
|
1431
|
-
[insertScript.ts:5](https://github.com/daysnap/utils/blob/
|
|
1491
|
+
[insertScript.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/insertScript.ts#L5)
|
|
1432
1492
|
|
|
1433
1493
|
___
|
|
1434
1494
|
|
|
@@ -1450,7 +1510,7 @@ ___
|
|
|
1450
1510
|
|
|
1451
1511
|
#### Defined in
|
|
1452
1512
|
|
|
1453
|
-
[insertStyle.ts:4](https://github.com/daysnap/utils/blob/
|
|
1513
|
+
[insertStyle.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/insertStyle.ts#L4)
|
|
1454
1514
|
|
|
1455
1515
|
___
|
|
1456
1516
|
|
|
@@ -1479,7 +1539,7 @@ isAmount('1.123') => false
|
|
|
1479
1539
|
|
|
1480
1540
|
#### Defined in
|
|
1481
1541
|
|
|
1482
|
-
[isAmount.ts:11](https://github.com/daysnap/utils/blob/
|
|
1542
|
+
[isAmount.ts:11](https://github.com/daysnap/utils/blob/fb256c2/src/isAmount.ts#L11)
|
|
1483
1543
|
|
|
1484
1544
|
___
|
|
1485
1545
|
|
|
@@ -1495,7 +1555,7 @@ ___
|
|
|
1495
1555
|
|
|
1496
1556
|
#### Defined in
|
|
1497
1557
|
|
|
1498
|
-
[isAndroid.ts:4](https://github.com/daysnap/utils/blob/
|
|
1558
|
+
[isAndroid.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isAndroid.ts#L4)
|
|
1499
1559
|
|
|
1500
1560
|
___
|
|
1501
1561
|
|
|
@@ -1519,7 +1579,7 @@ val is any[]
|
|
|
1519
1579
|
|
|
1520
1580
|
#### Defined in
|
|
1521
1581
|
|
|
1522
|
-
[isArray.ts:6](https://github.com/daysnap/utils/blob/
|
|
1582
|
+
[isArray.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/isArray.ts#L6)
|
|
1523
1583
|
|
|
1524
1584
|
___
|
|
1525
1585
|
|
|
@@ -1541,7 +1601,7 @@ val is boolean
|
|
|
1541
1601
|
|
|
1542
1602
|
#### Defined in
|
|
1543
1603
|
|
|
1544
|
-
[isBoolean.ts:5](https://github.com/daysnap/utils/blob/
|
|
1604
|
+
[isBoolean.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/isBoolean.ts#L5)
|
|
1545
1605
|
|
|
1546
1606
|
___
|
|
1547
1607
|
|
|
@@ -1563,7 +1623,7 @@ ___
|
|
|
1563
1623
|
|
|
1564
1624
|
#### Defined in
|
|
1565
1625
|
|
|
1566
|
-
[isChinese.ts:4](https://github.com/daysnap/utils/blob/
|
|
1626
|
+
[isChinese.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isChinese.ts#L4)
|
|
1567
1627
|
|
|
1568
1628
|
___
|
|
1569
1629
|
|
|
@@ -1585,7 +1645,7 @@ val is Date
|
|
|
1585
1645
|
|
|
1586
1646
|
#### Defined in
|
|
1587
1647
|
|
|
1588
|
-
[isDate.ts:4](https://github.com/daysnap/utils/blob/
|
|
1648
|
+
[isDate.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isDate.ts#L4)
|
|
1589
1649
|
|
|
1590
1650
|
___
|
|
1591
1651
|
|
|
@@ -1607,7 +1667,7 @@ ___
|
|
|
1607
1667
|
|
|
1608
1668
|
#### Defined in
|
|
1609
1669
|
|
|
1610
|
-
[isEmail.ts:4](https://github.com/daysnap/utils/blob/
|
|
1670
|
+
[isEmail.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isEmail.ts#L4)
|
|
1611
1671
|
|
|
1612
1672
|
___
|
|
1613
1673
|
|
|
@@ -1629,7 +1689,7 @@ ___
|
|
|
1629
1689
|
|
|
1630
1690
|
#### Defined in
|
|
1631
1691
|
|
|
1632
|
-
[isEmpty.ts:6](https://github.com/daysnap/utils/blob/
|
|
1692
|
+
[isEmpty.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/isEmpty.ts#L6)
|
|
1633
1693
|
|
|
1634
1694
|
___
|
|
1635
1695
|
|
|
@@ -1651,7 +1711,7 @@ ___
|
|
|
1651
1711
|
|
|
1652
1712
|
#### Defined in
|
|
1653
1713
|
|
|
1654
|
-
[isEmptyArray.ts:6](https://github.com/daysnap/utils/blob/
|
|
1714
|
+
[isEmptyArray.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/isEmptyArray.ts#L6)
|
|
1655
1715
|
|
|
1656
1716
|
___
|
|
1657
1717
|
|
|
@@ -1673,7 +1733,7 @@ ___
|
|
|
1673
1733
|
|
|
1674
1734
|
#### Defined in
|
|
1675
1735
|
|
|
1676
|
-
[isEmptyObject.ts:5](https://github.com/daysnap/utils/blob/
|
|
1736
|
+
[isEmptyObject.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/isEmptyObject.ts#L5)
|
|
1677
1737
|
|
|
1678
1738
|
___
|
|
1679
1739
|
|
|
@@ -1695,7 +1755,7 @@ val is Error
|
|
|
1695
1755
|
|
|
1696
1756
|
#### Defined in
|
|
1697
1757
|
|
|
1698
|
-
[isError.ts:4](https://github.com/daysnap/utils/blob/
|
|
1758
|
+
[isError.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isError.ts#L4)
|
|
1699
1759
|
|
|
1700
1760
|
___
|
|
1701
1761
|
|
|
@@ -1717,7 +1777,7 @@ val is Function
|
|
|
1717
1777
|
|
|
1718
1778
|
#### Defined in
|
|
1719
1779
|
|
|
1720
|
-
[isFunction.ts:4](https://github.com/daysnap/utils/blob/
|
|
1780
|
+
[isFunction.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isFunction.ts#L4)
|
|
1721
1781
|
|
|
1722
1782
|
___
|
|
1723
1783
|
|
|
@@ -1735,7 +1795,7 @@ ___
|
|
|
1735
1795
|
|
|
1736
1796
|
#### Defined in
|
|
1737
1797
|
|
|
1738
|
-
[isIE.ts:6](https://github.com/daysnap/utils/blob/
|
|
1798
|
+
[isIE.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/isIE.ts#L6)
|
|
1739
1799
|
|
|
1740
1800
|
___
|
|
1741
1801
|
|
|
@@ -1751,7 +1811,7 @@ ___
|
|
|
1751
1811
|
|
|
1752
1812
|
#### Defined in
|
|
1753
1813
|
|
|
1754
|
-
[isIOS.ts:4](https://github.com/daysnap/utils/blob/
|
|
1814
|
+
[isIOS.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isIOS.ts#L4)
|
|
1755
1815
|
|
|
1756
1816
|
___
|
|
1757
1817
|
|
|
@@ -1773,7 +1833,7 @@ ___
|
|
|
1773
1833
|
|
|
1774
1834
|
#### Defined in
|
|
1775
1835
|
|
|
1776
|
-
[isIdCard.ts:4](https://github.com/daysnap/utils/blob/
|
|
1836
|
+
[isIdCard.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isIdCard.ts#L4)
|
|
1777
1837
|
|
|
1778
1838
|
___
|
|
1779
1839
|
|
|
@@ -1795,7 +1855,7 @@ ___
|
|
|
1795
1855
|
|
|
1796
1856
|
#### Defined in
|
|
1797
1857
|
|
|
1798
|
-
[isJSONString.ts:7](https://github.com/daysnap/utils/blob/
|
|
1858
|
+
[isJSONString.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/isJSONString.ts#L7)
|
|
1799
1859
|
|
|
1800
1860
|
___
|
|
1801
1861
|
|
|
@@ -1817,7 +1877,7 @@ ___
|
|
|
1817
1877
|
|
|
1818
1878
|
#### Defined in
|
|
1819
1879
|
|
|
1820
|
-
[isLan.ts:5](https://github.com/daysnap/utils/blob/
|
|
1880
|
+
[isLan.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/isLan.ts#L5)
|
|
1821
1881
|
|
|
1822
1882
|
___
|
|
1823
1883
|
|
|
@@ -1839,7 +1899,7 @@ ___
|
|
|
1839
1899
|
|
|
1840
1900
|
#### Defined in
|
|
1841
1901
|
|
|
1842
|
-
[isLicenseCode.ts:5](https://github.com/daysnap/utils/blob/
|
|
1902
|
+
[isLicenseCode.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/isLicenseCode.ts#L5)
|
|
1843
1903
|
|
|
1844
1904
|
___
|
|
1845
1905
|
|
|
@@ -1855,7 +1915,7 @@ ___
|
|
|
1855
1915
|
|
|
1856
1916
|
#### Defined in
|
|
1857
1917
|
|
|
1858
|
-
[isMobile.ts:4](https://github.com/daysnap/utils/blob/
|
|
1918
|
+
[isMobile.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isMobile.ts#L4)
|
|
1859
1919
|
|
|
1860
1920
|
___
|
|
1861
1921
|
|
|
@@ -1878,7 +1938,7 @@ ___
|
|
|
1878
1938
|
|
|
1879
1939
|
#### Defined in
|
|
1880
1940
|
|
|
1881
|
-
[isNativeFunction.ts:7](https://github.com/daysnap/utils/blob/
|
|
1941
|
+
[isNativeFunction.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/isNativeFunction.ts#L7)
|
|
1882
1942
|
|
|
1883
1943
|
___
|
|
1884
1944
|
|
|
@@ -1900,7 +1960,7 @@ val is null
|
|
|
1900
1960
|
|
|
1901
1961
|
#### Defined in
|
|
1902
1962
|
|
|
1903
|
-
[isNull.ts:4](https://github.com/daysnap/utils/blob/
|
|
1963
|
+
[isNull.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isNull.ts#L4)
|
|
1904
1964
|
|
|
1905
1965
|
___
|
|
1906
1966
|
|
|
@@ -1922,7 +1982,7 @@ val is number
|
|
|
1922
1982
|
|
|
1923
1983
|
#### Defined in
|
|
1924
1984
|
|
|
1925
|
-
[isNumber.ts:5](https://github.com/daysnap/utils/blob/
|
|
1985
|
+
[isNumber.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/isNumber.ts#L5)
|
|
1926
1986
|
|
|
1927
1987
|
___
|
|
1928
1988
|
|
|
@@ -1944,7 +2004,7 @@ val is Record<string, any\>
|
|
|
1944
2004
|
|
|
1945
2005
|
#### Defined in
|
|
1946
2006
|
|
|
1947
|
-
[isObject.ts:4](https://github.com/daysnap/utils/blob/
|
|
2007
|
+
[isObject.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isObject.ts#L4)
|
|
1948
2008
|
|
|
1949
2009
|
___
|
|
1950
2010
|
|
|
@@ -1966,7 +2026,7 @@ ___
|
|
|
1966
2026
|
|
|
1967
2027
|
#### Defined in
|
|
1968
2028
|
|
|
1969
|
-
[isPhone.ts:4](https://github.com/daysnap/utils/blob/
|
|
2029
|
+
[isPhone.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isPhone.ts#L4)
|
|
1970
2030
|
|
|
1971
2031
|
___
|
|
1972
2032
|
|
|
@@ -1994,7 +2054,7 @@ val is Promise<T\>
|
|
|
1994
2054
|
|
|
1995
2055
|
#### Defined in
|
|
1996
2056
|
|
|
1997
|
-
[isPromise.ts:4](https://github.com/daysnap/utils/blob/
|
|
2057
|
+
[isPromise.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isPromise.ts#L4)
|
|
1998
2058
|
|
|
1999
2059
|
___
|
|
2000
2060
|
|
|
@@ -2016,7 +2076,7 @@ val is RegExp
|
|
|
2016
2076
|
|
|
2017
2077
|
#### Defined in
|
|
2018
2078
|
|
|
2019
|
-
[isRegExp.ts:4](https://github.com/daysnap/utils/blob/
|
|
2079
|
+
[isRegExp.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isRegExp.ts#L4)
|
|
2020
2080
|
|
|
2021
2081
|
___
|
|
2022
2082
|
|
|
@@ -2038,7 +2098,7 @@ val is string
|
|
|
2038
2098
|
|
|
2039
2099
|
#### Defined in
|
|
2040
2100
|
|
|
2041
|
-
[isString.ts:4](https://github.com/daysnap/utils/blob/
|
|
2101
|
+
[isString.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isString.ts#L4)
|
|
2042
2102
|
|
|
2043
2103
|
___
|
|
2044
2104
|
|
|
@@ -2060,7 +2120,7 @@ val is undefined
|
|
|
2060
2120
|
|
|
2061
2121
|
#### Defined in
|
|
2062
2122
|
|
|
2063
|
-
[isUndefined.ts:4](https://github.com/daysnap/utils/blob/
|
|
2123
|
+
[isUndefined.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isUndefined.ts#L4)
|
|
2064
2124
|
|
|
2065
2125
|
___
|
|
2066
2126
|
|
|
@@ -2098,7 +2158,7 @@ ___
|
|
|
2098
2158
|
|
|
2099
2159
|
#### Defined in
|
|
2100
2160
|
|
|
2101
|
-
[isWeChat.ts:4](https://github.com/daysnap/utils/blob/
|
|
2161
|
+
[isWeChat.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/isWeChat.ts#L4)
|
|
2102
2162
|
|
|
2103
2163
|
___
|
|
2104
2164
|
|
|
@@ -2115,7 +2175,7 @@ https://developers.weixin.qq.com/miniprogram/dev/component/web-view.html
|
|
|
2115
2175
|
|
|
2116
2176
|
#### Defined in
|
|
2117
2177
|
|
|
2118
|
-
[isWeChatMiniProgram.ts:5](https://github.com/daysnap/utils/blob/
|
|
2178
|
+
[isWeChatMiniProgram.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/isWeChatMiniProgram.ts#L5)
|
|
2119
2179
|
|
|
2120
2180
|
___
|
|
2121
2181
|
|
|
@@ -2135,7 +2195,7 @@ ___
|
|
|
2135
2195
|
|
|
2136
2196
|
#### Defined in
|
|
2137
2197
|
|
|
2138
|
-
[isWeChat.ts:12](https://github.com/daysnap/utils/blob/
|
|
2198
|
+
[isWeChat.ts:12](https://github.com/daysnap/utils/blob/fb256c2/src/isWeChat.ts#L12)
|
|
2139
2199
|
|
|
2140
2200
|
___
|
|
2141
2201
|
|
|
@@ -2157,7 +2217,7 @@ val is Window
|
|
|
2157
2217
|
|
|
2158
2218
|
#### Defined in
|
|
2159
2219
|
|
|
2160
|
-
[isWindow.ts:5](https://github.com/daysnap/utils/blob/
|
|
2220
|
+
[isWindow.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/isWindow.ts#L5)
|
|
2161
2221
|
|
|
2162
2222
|
___
|
|
2163
2223
|
|
|
@@ -2180,7 +2240,7 @@ kebabCase('helloWorld') => hello-world
|
|
|
2180
2240
|
|
|
2181
2241
|
#### Defined in
|
|
2182
2242
|
|
|
2183
|
-
[kebabCase.ts:5](https://github.com/daysnap/utils/blob/
|
|
2243
|
+
[kebabCase.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/kebabCase.ts#L5)
|
|
2184
2244
|
|
|
2185
2245
|
___
|
|
2186
2246
|
|
|
@@ -2209,7 +2269,7 @@ list 生成器,快速生成数据
|
|
|
2209
2269
|
|
|
2210
2270
|
#### Defined in
|
|
2211
2271
|
|
|
2212
|
-
[listGenerator.ts:5](https://github.com/daysnap/utils/blob/
|
|
2272
|
+
[listGenerator.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/listGenerator.ts#L5)
|
|
2213
2273
|
|
|
2214
2274
|
___
|
|
2215
2275
|
|
|
@@ -2234,7 +2294,7 @@ ___
|
|
|
2234
2294
|
|
|
2235
2295
|
#### Defined in
|
|
2236
2296
|
|
|
2237
|
-
[mousewheel.ts:22](https://github.com/daysnap/utils/blob/
|
|
2297
|
+
[mousewheel.ts:22](https://github.com/daysnap/utils/blob/fb256c2/src/mousewheel.ts#L22)
|
|
2238
2298
|
|
|
2239
2299
|
___
|
|
2240
2300
|
|
|
@@ -2250,7 +2310,7 @@ ___
|
|
|
2250
2310
|
|
|
2251
2311
|
#### Defined in
|
|
2252
2312
|
|
|
2253
|
-
[nf.ts:4](https://github.com/daysnap/utils/blob/
|
|
2313
|
+
[nf.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/nf.ts#L4)
|
|
2254
2314
|
|
|
2255
2315
|
___
|
|
2256
2316
|
|
|
@@ -2272,7 +2332,7 @@ ___
|
|
|
2272
2332
|
|
|
2273
2333
|
#### Defined in
|
|
2274
2334
|
|
|
2275
|
-
[normalizePath.ts:4](https://github.com/daysnap/utils/blob/
|
|
2335
|
+
[normalizePath.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/normalizePath.ts#L4)
|
|
2276
2336
|
|
|
2277
2337
|
___
|
|
2278
2338
|
|
|
@@ -2302,7 +2362,7 @@ ___
|
|
|
2302
2362
|
|
|
2303
2363
|
#### Defined in
|
|
2304
2364
|
|
|
2305
|
-
[omit.ts:4](https://github.com/daysnap/utils/blob/
|
|
2365
|
+
[omit.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/omit.ts#L4)
|
|
2306
2366
|
|
|
2307
2367
|
___
|
|
2308
2368
|
|
|
@@ -2326,7 +2386,7 @@ ___
|
|
|
2326
2386
|
|
|
2327
2387
|
#### Defined in
|
|
2328
2388
|
|
|
2329
|
-
[padding.ts:7](https://github.com/daysnap/utils/blob/
|
|
2389
|
+
[padding.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/padding.ts#L7)
|
|
2330
2390
|
|
|
2331
2391
|
___
|
|
2332
2392
|
|
|
@@ -2348,7 +2408,7 @@ ___
|
|
|
2348
2408
|
|
|
2349
2409
|
#### Defined in
|
|
2350
2410
|
|
|
2351
|
-
[parseDate.ts:4](https://github.com/daysnap/utils/blob/
|
|
2411
|
+
[parseDate.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/parseDate.ts#L4)
|
|
2352
2412
|
|
|
2353
2413
|
___
|
|
2354
2414
|
|
|
@@ -2371,7 +2431,7 @@ ___
|
|
|
2371
2431
|
|
|
2372
2432
|
#### Defined in
|
|
2373
2433
|
|
|
2374
|
-
[parseError.ts:8](https://github.com/daysnap/utils/blob/
|
|
2434
|
+
[parseError.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/parseError.ts#L8)
|
|
2375
2435
|
|
|
2376
2436
|
___
|
|
2377
2437
|
|
|
@@ -2401,7 +2461,7 @@ parseObject('a.b.c', 1) => { a: { b: { c: 1 } } }
|
|
|
2401
2461
|
|
|
2402
2462
|
#### Defined in
|
|
2403
2463
|
|
|
2404
|
-
[parseObject.ts:5](https://github.com/daysnap/utils/blob/
|
|
2464
|
+
[parseObject.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/parseObject.ts#L5)
|
|
2405
2465
|
|
|
2406
2466
|
___
|
|
2407
2467
|
|
|
@@ -2430,7 +2490,7 @@ ___
|
|
|
2430
2490
|
|
|
2431
2491
|
#### Defined in
|
|
2432
2492
|
|
|
2433
|
-
[parsePath.ts:6](https://github.com/daysnap/utils/blob/
|
|
2493
|
+
[parsePath.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/parsePath.ts#L6)
|
|
2434
2494
|
|
|
2435
2495
|
___
|
|
2436
2496
|
|
|
@@ -2453,7 +2513,7 @@ ___
|
|
|
2453
2513
|
|
|
2454
2514
|
#### Defined in
|
|
2455
2515
|
|
|
2456
|
-
[parseQuery.ts:8](https://github.com/daysnap/utils/blob/
|
|
2516
|
+
[parseQuery.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/parseQuery.ts#L8)
|
|
2457
2517
|
|
|
2458
2518
|
___
|
|
2459
2519
|
|
|
@@ -2483,7 +2543,7 @@ ___
|
|
|
2483
2543
|
|
|
2484
2544
|
#### Defined in
|
|
2485
2545
|
|
|
2486
|
-
[parseQueryString.ts:6](https://github.com/daysnap/utils/blob/
|
|
2546
|
+
[parseQueryString.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/parseQueryString.ts#L6)
|
|
2487
2547
|
|
|
2488
2548
|
___
|
|
2489
2549
|
|
|
@@ -2506,7 +2566,7 @@ pascalCase('hello-world') => HelloWorld
|
|
|
2506
2566
|
|
|
2507
2567
|
#### Defined in
|
|
2508
2568
|
|
|
2509
|
-
[pascalCase.ts:8](https://github.com/daysnap/utils/blob/
|
|
2569
|
+
[pascalCase.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/pascalCase.ts#L8)
|
|
2510
2570
|
|
|
2511
2571
|
___
|
|
2512
2572
|
|
|
@@ -2536,7 +2596,7 @@ ___
|
|
|
2536
2596
|
|
|
2537
2597
|
#### Defined in
|
|
2538
2598
|
|
|
2539
|
-
[pick.ts:4](https://github.com/daysnap/utils/blob/
|
|
2599
|
+
[pick.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/pick.ts#L4)
|
|
2540
2600
|
|
|
2541
2601
|
___
|
|
2542
2602
|
|
|
@@ -2559,7 +2619,7 @@ ___
|
|
|
2559
2619
|
|
|
2560
2620
|
#### Defined in
|
|
2561
2621
|
|
|
2562
|
-
[replaceCrlf.ts:4](https://github.com/daysnap/utils/blob/
|
|
2622
|
+
[replaceCrlf.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/replaceCrlf.ts#L4)
|
|
2563
2623
|
|
|
2564
2624
|
___
|
|
2565
2625
|
|
|
@@ -2583,7 +2643,7 @@ ___
|
|
|
2583
2643
|
|
|
2584
2644
|
#### Defined in
|
|
2585
2645
|
|
|
2586
|
-
[requestFullScreen.ts:6](https://github.com/daysnap/utils/blob/
|
|
2646
|
+
[requestFullScreen.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/requestFullScreen.ts#L6)
|
|
2587
2647
|
|
|
2588
2648
|
___
|
|
2589
2649
|
|
|
@@ -2609,7 +2669,7 @@ reserve(0, '--') => 0
|
|
|
2609
2669
|
|
|
2610
2670
|
#### Defined in
|
|
2611
2671
|
|
|
2612
|
-
[reserve.ts:8](https://github.com/daysnap/utils/blob/
|
|
2672
|
+
[reserve.ts:8](https://github.com/daysnap/utils/blob/fb256c2/src/reserve.ts#L8)
|
|
2613
2673
|
|
|
2614
2674
|
___
|
|
2615
2675
|
|
|
@@ -2633,7 +2693,7 @@ ___
|
|
|
2633
2693
|
|
|
2634
2694
|
#### Defined in
|
|
2635
2695
|
|
|
2636
|
-
[rgbToHex.ts:4](https://github.com/daysnap/utils/blob/
|
|
2696
|
+
[rgbToHex.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/rgbToHex.ts#L4)
|
|
2637
2697
|
|
|
2638
2698
|
___
|
|
2639
2699
|
|
|
@@ -2656,7 +2716,7 @@ ___
|
|
|
2656
2716
|
|
|
2657
2717
|
#### Defined in
|
|
2658
2718
|
|
|
2659
|
-
[round.ts:6](https://github.com/daysnap/utils/blob/
|
|
2719
|
+
[round.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/round.ts#L6)
|
|
2660
2720
|
|
|
2661
2721
|
___
|
|
2662
2722
|
|
|
@@ -2672,7 +2732,29 @@ ___
|
|
|
2672
2732
|
|
|
2673
2733
|
#### Defined in
|
|
2674
2734
|
|
|
2675
|
-
[scrollToTop.ts:4](https://github.com/daysnap/utils/blob/
|
|
2735
|
+
[scrollToTop.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/scrollToTop.ts#L4)
|
|
2736
|
+
|
|
2737
|
+
___
|
|
2738
|
+
|
|
2739
|
+
### setScrollTop
|
|
2740
|
+
|
|
2741
|
+
▸ **setScrollTop**(`scrollTop?`): `void`
|
|
2742
|
+
|
|
2743
|
+
设置 scrollTop
|
|
2744
|
+
|
|
2745
|
+
#### Parameters
|
|
2746
|
+
|
|
2747
|
+
| Name | Type | Default value |
|
|
2748
|
+
| :------ | :------ | :------ |
|
|
2749
|
+
| `scrollTop` | `number` | `0` |
|
|
2750
|
+
|
|
2751
|
+
#### Returns
|
|
2752
|
+
|
|
2753
|
+
`void`
|
|
2754
|
+
|
|
2755
|
+
#### Defined in
|
|
2756
|
+
|
|
2757
|
+
[setScrollTop.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/setScrollTop.ts#L4)
|
|
2676
2758
|
|
|
2677
2759
|
___
|
|
2678
2760
|
|
|
@@ -2695,7 +2777,7 @@ ___
|
|
|
2695
2777
|
|
|
2696
2778
|
#### Defined in
|
|
2697
2779
|
|
|
2698
|
-
[sleep.ts:6](https://github.com/daysnap/utils/blob/
|
|
2780
|
+
[sleep.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/sleep.ts#L6)
|
|
2699
2781
|
|
|
2700
2782
|
___
|
|
2701
2783
|
|
|
@@ -2724,7 +2806,7 @@ ___
|
|
|
2724
2806
|
|
|
2725
2807
|
#### Defined in
|
|
2726
2808
|
|
|
2727
|
-
[splitArray.ts:4](https://github.com/daysnap/utils/blob/
|
|
2809
|
+
[splitArray.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/splitArray.ts#L4)
|
|
2728
2810
|
|
|
2729
2811
|
___
|
|
2730
2812
|
|
|
@@ -2747,7 +2829,7 @@ ___
|
|
|
2747
2829
|
|
|
2748
2830
|
#### Defined in
|
|
2749
2831
|
|
|
2750
|
-
[stringTrim.ts:6](https://github.com/daysnap/utils/blob/
|
|
2832
|
+
[stringTrim.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/stringTrim.ts#L6)
|
|
2751
2833
|
|
|
2752
2834
|
___
|
|
2753
2835
|
|
|
@@ -2769,7 +2851,7 @@ ___
|
|
|
2769
2851
|
|
|
2770
2852
|
#### Defined in
|
|
2771
2853
|
|
|
2772
|
-
[stringifyQuery.ts:7](https://github.com/daysnap/utils/blob/
|
|
2854
|
+
[stringifyQuery.ts:7](https://github.com/daysnap/utils/blob/fb256c2/src/stringifyQuery.ts#L7)
|
|
2773
2855
|
|
|
2774
2856
|
___
|
|
2775
2857
|
|
|
@@ -2793,7 +2875,7 @@ ___
|
|
|
2793
2875
|
|
|
2794
2876
|
#### Defined in
|
|
2795
2877
|
|
|
2796
|
-
[stringifyQueryString.ts:6](https://github.com/daysnap/utils/blob/
|
|
2878
|
+
[stringifyQueryString.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/stringifyQueryString.ts#L6)
|
|
2797
2879
|
|
|
2798
2880
|
___
|
|
2799
2881
|
|
|
@@ -2837,7 +2919,7 @@ ___
|
|
|
2837
2919
|
|
|
2838
2920
|
#### Defined in
|
|
2839
2921
|
|
|
2840
|
-
[throttle.ts:48](https://github.com/daysnap/utils/blob/
|
|
2922
|
+
[throttle.ts:48](https://github.com/daysnap/utils/blob/fb256c2/src/throttle.ts#L48)
|
|
2841
2923
|
|
|
2842
2924
|
___
|
|
2843
2925
|
|
|
@@ -2880,7 +2962,7 @@ ___
|
|
|
2880
2962
|
|
|
2881
2963
|
#### Defined in
|
|
2882
2964
|
|
|
2883
|
-
[throttle.ts:5](https://github.com/daysnap/utils/blob/
|
|
2965
|
+
[throttle.ts:5](https://github.com/daysnap/utils/blob/fb256c2/src/throttle.ts#L5)
|
|
2884
2966
|
|
|
2885
2967
|
___
|
|
2886
2968
|
|
|
@@ -2923,7 +3005,7 @@ ___
|
|
|
2923
3005
|
|
|
2924
3006
|
#### Defined in
|
|
2925
3007
|
|
|
2926
|
-
[throttle.ts:25](https://github.com/daysnap/utils/blob/
|
|
3008
|
+
[throttle.ts:25](https://github.com/daysnap/utils/blob/fb256c2/src/throttle.ts#L25)
|
|
2927
3009
|
|
|
2928
3010
|
___
|
|
2929
3011
|
|
|
@@ -2945,7 +3027,7 @@ ___
|
|
|
2945
3027
|
|
|
2946
3028
|
#### Defined in
|
|
2947
3029
|
|
|
2948
|
-
[toCDB.ts:4](https://github.com/daysnap/utils/blob/
|
|
3030
|
+
[toCDB.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/toCDB.ts#L4)
|
|
2949
3031
|
|
|
2950
3032
|
___
|
|
2951
3033
|
|
|
@@ -2967,7 +3049,7 @@ ___
|
|
|
2967
3049
|
|
|
2968
3050
|
#### Defined in
|
|
2969
3051
|
|
|
2970
|
-
[toDBC.ts:4](https://github.com/daysnap/utils/blob/
|
|
3052
|
+
[toDBC.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/toDBC.ts#L4)
|
|
2971
3053
|
|
|
2972
3054
|
___
|
|
2973
3055
|
|
|
@@ -2991,7 +3073,7 @@ ___
|
|
|
2991
3073
|
|
|
2992
3074
|
#### Defined in
|
|
2993
3075
|
|
|
2994
|
-
[typeOf.ts:6](https://github.com/daysnap/utils/blob/
|
|
3076
|
+
[typeOf.ts:6](https://github.com/daysnap/utils/blob/fb256c2/src/typeOf.ts#L6)
|
|
2995
3077
|
|
|
2996
3078
|
___
|
|
2997
3079
|
|
|
@@ -3020,4 +3102,4 @@ ___
|
|
|
3020
3102
|
|
|
3021
3103
|
#### Defined in
|
|
3022
3104
|
|
|
3023
|
-
[withPreventConsecutiveClicks.ts:4](https://github.com/daysnap/utils/blob/
|
|
3105
|
+
[withPreventConsecutiveClicks.ts:4](https://github.com/daysnap/utils/blob/fb256c2/src/withPreventConsecutiveClicks.ts#L4)
|