@daysnap/utils 0.1.16 → 0.1.18

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.
Files changed (94) hide show
  1. package/docs/classes/Storage.md +13 -13
  2. package/docs/interfaces/EventBusCallback.md +1 -1
  3. package/docs/interfaces/StorageManager.md +4 -4
  4. package/docs/interfaces/Trap.md +5 -5
  5. package/docs/modules.md +144 -340
  6. package/es/blobToBase64.d.ts +1 -1
  7. package/es/blobToBase64.js +1 -1
  8. package/es/{chunk-2ZSZ4GDI.js → chunk-65FBSULU.js} +1 -2
  9. package/es/{chunk-WXD7J2FR.js → chunk-DW5GIB4A.js} +1 -2
  10. package/es/chunk-HRKQWKOJ.js +21 -0
  11. package/es/chunk-S2FOFDX4.js +8 -0
  12. package/es/{chunk-D5O4LXN3.js → chunk-YLHA5VH3.js} +1 -1
  13. package/es/filterCRLF.d.ts +6 -0
  14. package/es/filterCRLF.js +6 -0
  15. package/es/filterEmptyValue.js +3 -3
  16. package/es/formartDateToZN.js +1 -1
  17. package/es/formatFileSize.js +1 -1
  18. package/es/getDateBoundsByMonths.d.ts +1 -1
  19. package/es/getMonthBounds.d.ts +1 -1
  20. package/es/index.d.ts +2 -8
  21. package/es/index.js +95 -121
  22. package/es/{isUrl.js → isURL.js} +1 -1
  23. package/es/stringifyQuery.js +2 -2
  24. package/lib/blobToBase64.cjs +2 -2
  25. package/lib/blobToBase64.d.cts +1 -1
  26. package/lib/{chunk-YIW4PW4Q.cjs → chunk-CDHFRZQM.cjs} +8 -2
  27. package/lib/chunk-CXDOHSIF.cjs +8 -0
  28. package/lib/{chunk-KT3FWGJG.cjs → chunk-DIJ3MI2T.cjs} +1 -2
  29. package/lib/{chunk-EDVQTNLJ.cjs → chunk-LJD6E7O5.cjs} +1 -2
  30. package/lib/{chunk-I6VB2D7C.cjs → chunk-YMGGMXZL.cjs} +1 -1
  31. package/lib/filterCRLF.cjs +6 -0
  32. package/lib/filterCRLF.d.cts +6 -0
  33. package/lib/filterEmptyValue.cjs +4 -4
  34. package/lib/formartDateToZN.cjs +2 -2
  35. package/lib/formatFileSize.cjs +2 -2
  36. package/lib/getDateBoundsByMonths.d.cts +1 -1
  37. package/lib/getMonthBounds.d.cts +1 -1
  38. package/lib/index.cjs +71 -97
  39. package/lib/index.d.cts +2 -8
  40. package/lib/isURL.cjs +6 -0
  41. package/lib/stringifyQuery.cjs +3 -3
  42. package/package.json +1 -1
  43. package/docs/classes/Poller.md +0 -151
  44. package/docs/interfaces/PollerOptions.md +0 -19
  45. package/es/chunk-AAKGIVZB.js +0 -21
  46. package/es/chunk-BZ6JSRMY.js +0 -8
  47. package/es/chunk-GLJALZRT.js +0 -43
  48. package/es/chunk-KH7MPMQF.js +0 -15
  49. package/es/chunk-MOZPLBC3.js +0 -8
  50. package/es/chunk-OOWZEABP.js +0 -8
  51. package/es/chunk-PXMH56CM.js +0 -8
  52. package/es/chunk-UDRRKKBB.js +0 -12
  53. package/es/crToBr.d.ts +0 -6
  54. package/es/crToBr.js +0 -6
  55. package/es/crlfToBr.d.ts +0 -11
  56. package/es/crlfToBr.js +0 -8
  57. package/es/getDaysOfMonth.d.ts +0 -6
  58. package/es/getDaysOfMonth.js +0 -6
  59. package/es/getWeekBounds.d.ts +0 -7
  60. package/es/getWeekBounds.js +0 -9
  61. package/es/isLeapYear.d.ts +0 -7
  62. package/es/isLeapYear.js +0 -6
  63. package/es/lfToBr.d.ts +0 -6
  64. package/es/lfToBr.js +0 -6
  65. package/es/poller.d.ts +0 -20
  66. package/es/poller.js +0 -7
  67. package/lib/chunk-4WWOJSX3.cjs +0 -21
  68. package/lib/chunk-EUH2FDMT.cjs +0 -8
  69. package/lib/chunk-TDUDOSU4.cjs +0 -43
  70. package/lib/chunk-TMCJ3HTA.cjs +0 -12
  71. package/lib/chunk-UTUKZLEN.cjs +0 -8
  72. package/lib/chunk-XSCXPGEI.cjs +0 -8
  73. package/lib/chunk-ZSDKKWIQ.cjs +0 -8
  74. package/lib/crToBr.cjs +0 -6
  75. package/lib/crToBr.d.cts +0 -6
  76. package/lib/crlfToBr.cjs +0 -8
  77. package/lib/crlfToBr.d.cts +0 -11
  78. package/lib/getDaysOfMonth.cjs +0 -6
  79. package/lib/getDaysOfMonth.d.cts +0 -6
  80. package/lib/getWeekBounds.cjs +0 -9
  81. package/lib/getWeekBounds.d.cts +0 -7
  82. package/lib/isLeapYear.cjs +0 -6
  83. package/lib/isLeapYear.d.cts +0 -7
  84. package/lib/isUrl.cjs +0 -6
  85. package/lib/lfToBr.cjs +0 -6
  86. package/lib/lfToBr.d.cts +0 -6
  87. package/lib/poller.cjs +0 -7
  88. package/lib/poller.d.cts +0 -20
  89. package/es/{chunk-SMNIKKYG.js → chunk-NXEL6RMI.js} +6 -6
  90. package/es/{chunk-WXXFRKUS.js → chunk-VDXSQKQF.js} +3 -3
  91. package/es/{isUrl.d.ts → isURL.d.ts} +0 -0
  92. package/lib/{chunk-4USHGA4P.cjs → chunk-73AXP7FD.cjs} +2 -2
  93. package/lib/{chunk-4P4EJVBW.cjs → chunk-PYFTXKFI.cjs} +4 -4
  94. /package/lib/{isUrl.d.cts → isURL.d.cts} +0 -0
@@ -1,151 +0,0 @@
1
- [@daysnap/utils](../README.md) / [Exports](../modules.md) / Poller
2
-
3
- # Class: Poller
4
-
5
- ## Table of contents
6
-
7
- ### Constructors
8
-
9
- - [constructor](Poller.md#constructor)
10
-
11
- ### Properties
12
-
13
- - [count](Poller.md#count)
14
- - [currentCount](Poller.md#currentcount)
15
- - [options](Poller.md#options)
16
- - [task](Poller.md#task)
17
-
18
- ### Accessors
19
-
20
- - [isRunning](Poller.md#isrunning)
21
-
22
- ### Methods
23
-
24
- - [run](Poller.md#run)
25
- - [start](Poller.md#start)
26
- - [stop](Poller.md#stop)
27
-
28
- ## Constructors
29
-
30
- ### constructor
31
-
32
- • **new Poller**(`task`, `options?`)
33
-
34
- #### Parameters
35
-
36
- | Name | Type |
37
- | :------ | :------ |
38
- | `task` | [`PollerTask`](../modules.md#pollertask) |
39
- | `options` | `Partial`<[`PollerOptions`](../interfaces/PollerOptions.md)\> |
40
-
41
- #### Defined in
42
-
43
- [poller.ts:23](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L23)
44
-
45
- ## Properties
46
-
47
- ### count
48
-
49
- • `Private` **count**: `number` = `0`
50
-
51
- #### Defined in
52
-
53
- [poller.ts:14](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L14)
54
-
55
- ___
56
-
57
- ### currentCount
58
-
59
- • `Private` **currentCount**: `number` = `-1`
60
-
61
- #### Defined in
62
-
63
- [poller.ts:17](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L17)
64
-
65
- ___
66
-
67
- ### options
68
-
69
- • `Private` **options**: [`PollerOptions`](../interfaces/PollerOptions.md)
70
-
71
- #### Defined in
72
-
73
- [poller.ts:16](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L16)
74
-
75
- ___
76
-
77
- ### task
78
-
79
- • `Private` **task**: [`PollerTask`](../modules.md#pollertask)
80
-
81
- #### Defined in
82
-
83
- [poller.ts:15](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L15)
84
-
85
- ## Accessors
86
-
87
- ### isRunning
88
-
89
- • `get` **isRunning**(): `boolean`
90
-
91
- #### Returns
92
-
93
- `boolean`
94
-
95
- #### Defined in
96
-
97
- [poller.ts:19](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L19)
98
-
99
- ## Methods
100
-
101
- ### run
102
-
103
- ▸ `Private` **run**(`count`): `Promise`<`void`\>
104
-
105
- #### Parameters
106
-
107
- | Name | Type |
108
- | :------ | :------ |
109
- | `count` | `number` |
110
-
111
- #### Returns
112
-
113
- `Promise`<`void`\>
114
-
115
- #### Defined in
116
-
117
- [poller.ts:28](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L28)
118
-
119
- ___
120
-
121
- ### start
122
-
123
- ▸ **start**(`forceUpdate?`): [`Poller`](Poller.md)
124
-
125
- #### Parameters
126
-
127
- | Name | Type | Default value |
128
- | :------ | :------ | :------ |
129
- | `forceUpdate` | `boolean` | `true` |
130
-
131
- #### Returns
132
-
133
- [`Poller`](Poller.md)
134
-
135
- #### Defined in
136
-
137
- [poller.ts:46](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L46)
138
-
139
- ___
140
-
141
- ### stop
142
-
143
- ▸ **stop**(): [`Poller`](Poller.md)
144
-
145
- #### Returns
146
-
147
- [`Poller`](Poller.md)
148
-
149
- #### Defined in
150
-
151
- [poller.ts:41](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L41)
@@ -1,19 +0,0 @@
1
- [@daysnap/utils](../README.md) / [Exports](../modules.md) / PollerOptions
2
-
3
- # Interface: PollerOptions
4
-
5
- ## Table of contents
6
-
7
- ### Properties
8
-
9
- - [delay](PollerOptions.md#delay)
10
-
11
- ## Properties
12
-
13
- ### delay
14
-
15
- • **delay**: `number`
16
-
17
- #### Defined in
18
-
19
- [poller.ts:10](https://github.com/daysnap/utils/blob/585cbee/src/poller.ts#L10)
@@ -1,21 +0,0 @@
1
- import {
2
- formatDate
3
- } from "./chunk-UMJU7UF2.js";
4
- import {
5
- normalizeDate
6
- } from "./chunk-A3YS6665.js";
7
-
8
- // src/getWeekBounds.ts
9
- function getWeekBounds(value, sundayIsFirstDay = true, fmt) {
10
- const start = normalizeDate(value);
11
- const end = new Date(start);
12
- const day = start.getDay();
13
- const diffDay = sundayIsFirstDay ? day * -1 : day === 0 ? -6 : 1 - day;
14
- start.setDate(start.getDate() + diffDay);
15
- end.setDate(start.getDate() + 6);
16
- return fmt ? [formatDate(start, fmt), formatDate(end, fmt)] : [start, end];
17
- }
18
-
19
- export {
20
- getWeekBounds
21
- };
@@ -1,8 +0,0 @@
1
- // src/crToBr.ts
2
- function crToBr(v) {
3
- return v ? v.replace(/\r/gi, "<br/>") : v;
4
- }
5
-
6
- export {
7
- crToBr
8
- };
@@ -1,43 +0,0 @@
1
- import {
2
- sleep
3
- } from "./chunk-TNIIDDN4.js";
4
-
5
- // src/poller.ts
6
- var Poller = class {
7
- count = 0;
8
- task;
9
- options;
10
- currentCount = -1;
11
- get isRunning() {
12
- return this.count === this.currentCount;
13
- }
14
- constructor(task, options = {}) {
15
- this.task = task;
16
- this.options = Object.assign({ delay: 1e3 }, options);
17
- }
18
- async run(count) {
19
- this.currentCount = count;
20
- while (this.count === count) {
21
- try {
22
- await this.task(this);
23
- } catch {
24
- } finally {
25
- await sleep(this.options.delay);
26
- }
27
- }
28
- }
29
- stop() {
30
- this.count++;
31
- return this;
32
- }
33
- start(forceUpdate = true) {
34
- if (forceUpdate || !this.isRunning) {
35
- this.run(++this.count);
36
- }
37
- return this;
38
- }
39
- };
40
-
41
- export {
42
- Poller
43
- };
@@ -1,15 +0,0 @@
1
- // src/blobToBase64.ts
2
- function blobToBase64(blob) {
3
- return new Promise((resolve, reject) => {
4
- const fileReader = new FileReader();
5
- fileReader.onload = (res) => {
6
- resolve(res.target?.result ?? "");
7
- };
8
- fileReader.onerror = reject;
9
- fileReader.readAsDataURL(blob);
10
- });
11
- }
12
-
13
- export {
14
- blobToBase64
15
- };
@@ -1,8 +0,0 @@
1
- // src/isLeapYear.ts
2
- function isLeapYear(year) {
3
- return year % 400 === 0 || year % 100 !== 0 && year % 4 === 0;
4
- }
5
-
6
- export {
7
- isLeapYear
8
- };
@@ -1,8 +0,0 @@
1
- // src/getDaysOfMonth.ts
2
- function getDaysOfMonth(year, month) {
3
- return new Date(year, month, 0).getDate();
4
- }
5
-
6
- export {
7
- getDaysOfMonth
8
- };
@@ -1,8 +0,0 @@
1
- // src/lfToBr.ts
2
- function lfToBr(v) {
3
- return v ? v.replace(/\n/gi, "<br/>") : v;
4
- }
5
-
6
- export {
7
- lfToBr
8
- };
@@ -1,12 +0,0 @@
1
- // src/crlfToBr.ts
2
- function crlfToBr(v) {
3
- return v ? v.replace(/\r|\n/gi, "<br/>") : v;
4
- }
5
- function filterCRLF(v) {
6
- return v.replace(/\r|\n/gi, "<br/>");
7
- }
8
-
9
- export {
10
- crlfToBr,
11
- filterCRLF
12
- };
package/es/crToBr.d.ts DELETED
@@ -1,6 +0,0 @@
1
- /**
2
- * \r to <br/>
3
- */
4
- declare function crToBr(v: string): string;
5
-
6
- export { crToBr };
package/es/crToBr.js DELETED
@@ -1,6 +0,0 @@
1
- import {
2
- crToBr
3
- } from "./chunk-BZ6JSRMY.js";
4
- export {
5
- crToBr
6
- };
package/es/crlfToBr.d.ts DELETED
@@ -1,11 +0,0 @@
1
- /**
2
- * \r \n to <br/>
3
- */
4
- declare function crlfToBr(v: string): string;
5
- /**
6
- * 替换字符串里面的回车换行符
7
- * @deprecated 请使用 @see {@link crlfToBr}.
8
- */
9
- declare function filterCRLF(v: string): string;
10
-
11
- export { crlfToBr, filterCRLF };
package/es/crlfToBr.js DELETED
@@ -1,8 +0,0 @@
1
- import {
2
- crlfToBr,
3
- filterCRLF
4
- } from "./chunk-UDRRKKBB.js";
5
- export {
6
- crlfToBr,
7
- filterCRLF
8
- };
@@ -1,6 +0,0 @@
1
- /**
2
- * 获取一个月当中的天数
3
- */
4
- declare function getDaysOfMonth(year: number, month: number): number;
5
-
6
- export { getDaysOfMonth };
@@ -1,6 +0,0 @@
1
- import {
2
- getDaysOfMonth
3
- } from "./chunk-OOWZEABP.js";
4
- export {
5
- getDaysOfMonth
6
- };
@@ -1,7 +0,0 @@
1
- /**
2
- * 获取一周的开始时间和结束时间
3
- */
4
- declare function getWeekBounds(value: string | number | Date, sundayIsFirstDay: boolean): [Date, Date];
5
- declare function getWeekBounds(value: string | number | Date, sundayIsFirstDay: boolean, fmt: string): [string, string];
6
-
7
- export { getWeekBounds };
@@ -1,9 +0,0 @@
1
- import {
2
- getWeekBounds
3
- } from "./chunk-AAKGIVZB.js";
4
- import "./chunk-UMJU7UF2.js";
5
- import "./chunk-A3YS6665.js";
6
- import "./chunk-F4QMON2N.js";
7
- export {
8
- getWeekBounds
9
- };
@@ -1,7 +0,0 @@
1
- /**
2
- * 判断是否是闰年
3
- * 规则:四年一闰,百年不闰,四百年再闰
4
- */
5
- declare function isLeapYear(year: number): boolean;
6
-
7
- export { isLeapYear };
package/es/isLeapYear.js DELETED
@@ -1,6 +0,0 @@
1
- import {
2
- isLeapYear
3
- } from "./chunk-MOZPLBC3.js";
4
- export {
5
- isLeapYear
6
- };
package/es/lfToBr.d.ts DELETED
@@ -1,6 +0,0 @@
1
- /**
2
- * \n to <br/>
3
- */
4
- declare function lfToBr(v: string): string;
5
-
6
- export { lfToBr };
package/es/lfToBr.js DELETED
@@ -1,6 +0,0 @@
1
- import {
2
- lfToBr
3
- } from "./chunk-PXMH56CM.js";
4
- export {
5
- lfToBr
6
- };
package/es/poller.d.ts DELETED
@@ -1,20 +0,0 @@
1
- /**
2
- * 说明
3
- */
4
- type PollerTask = (poller: Poller) => void | Promise<void>;
5
- interface PollerOptions {
6
- delay: number;
7
- }
8
- declare class Poller {
9
- private count;
10
- private task;
11
- private options;
12
- private currentCount;
13
- get isRunning(): boolean;
14
- constructor(task: PollerTask, options?: Partial<PollerOptions>);
15
- private run;
16
- stop(): this;
17
- start(forceUpdate?: boolean): this;
18
- }
19
-
20
- export { Poller, type PollerOptions, type PollerTask };
package/es/poller.js DELETED
@@ -1,7 +0,0 @@
1
- import {
2
- Poller
3
- } from "./chunk-GLJALZRT.js";
4
- import "./chunk-TNIIDDN4.js";
5
- export {
6
- Poller
7
- };
@@ -1,21 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunkBQ7SLF6Ccjs = require('./chunk-BQ7SLF6C.cjs');
4
-
5
-
6
- var _chunkHEVW5ZN2cjs = require('./chunk-HEVW5ZN2.cjs');
7
-
8
- // src/getWeekBounds.ts
9
- function getWeekBounds(value, sundayIsFirstDay = true, fmt) {
10
- const start = _chunkHEVW5ZN2cjs.normalizeDate.call(void 0, value);
11
- const end = new Date(start);
12
- const day = start.getDay();
13
- const diffDay = sundayIsFirstDay ? day * -1 : day === 0 ? -6 : 1 - day;
14
- start.setDate(start.getDate() + diffDay);
15
- end.setDate(start.getDate() + 6);
16
- return fmt ? [_chunkBQ7SLF6Ccjs.formatDate.call(void 0, start, fmt), _chunkBQ7SLF6Ccjs.formatDate.call(void 0, end, fmt)] : [start, end];
17
- }
18
-
19
-
20
-
21
- exports.getWeekBounds = getWeekBounds;
@@ -1,8 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/getDaysOfMonth.ts
2
- function getDaysOfMonth(year, month) {
3
- return new Date(year, month, 0).getDate();
4
- }
5
-
6
-
7
-
8
- exports.getDaysOfMonth = getDaysOfMonth;
@@ -1,43 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); var _class;
2
-
3
- var _chunkXL3QSME6cjs = require('./chunk-XL3QSME6.cjs');
4
-
5
- // src/poller.ts
6
- var Poller = (_class = class {
7
- __init() {this.count = 0}
8
-
9
-
10
- __init2() {this.currentCount = -1}
11
- get isRunning() {
12
- return this.count === this.currentCount;
13
- }
14
- constructor(task, options = {}) {;_class.prototype.__init.call(this);_class.prototype.__init2.call(this);
15
- this.task = task;
16
- this.options = Object.assign({ delay: 1e3 }, options);
17
- }
18
- async run(count) {
19
- this.currentCount = count;
20
- while (this.count === count) {
21
- try {
22
- await this.task(this);
23
- } catch (e) {
24
- } finally {
25
- await _chunkXL3QSME6cjs.sleep.call(void 0, this.options.delay);
26
- }
27
- }
28
- }
29
- stop() {
30
- this.count++;
31
- return this;
32
- }
33
- start(forceUpdate = true) {
34
- if (forceUpdate || !this.isRunning) {
35
- this.run(++this.count);
36
- }
37
- return this;
38
- }
39
- }, _class);
40
-
41
-
42
-
43
- exports.Poller = Poller;
@@ -1,12 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/crlfToBr.ts
2
- function crlfToBr(v) {
3
- return v ? v.replace(/\r|\n/gi, "<br/>") : v;
4
- }
5
- function filterCRLF(v) {
6
- return v.replace(/\r|\n/gi, "<br/>");
7
- }
8
-
9
-
10
-
11
-
12
- exports.crlfToBr = crlfToBr; exports.filterCRLF = filterCRLF;
@@ -1,8 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/isLeapYear.ts
2
- function isLeapYear(year) {
3
- return year % 400 === 0 || year % 100 !== 0 && year % 4 === 0;
4
- }
5
-
6
-
7
-
8
- exports.isLeapYear = isLeapYear;
@@ -1,8 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/lfToBr.ts
2
- function lfToBr(v) {
3
- return v ? v.replace(/\n/gi, "<br/>") : v;
4
- }
5
-
6
-
7
-
8
- exports.lfToBr = lfToBr;
@@ -1,8 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/crToBr.ts
2
- function crToBr(v) {
3
- return v ? v.replace(/\r/gi, "<br/>") : v;
4
- }
5
-
6
-
7
-
8
- exports.crToBr = crToBr;
package/lib/crToBr.cjs DELETED
@@ -1,6 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunkZSDKKWIQcjs = require('./chunk-ZSDKKWIQ.cjs');
4
-
5
-
6
- exports.crToBr = _chunkZSDKKWIQcjs.crToBr;
package/lib/crToBr.d.cts DELETED
@@ -1,6 +0,0 @@
1
- /**
2
- * \r to <br/>
3
- */
4
- declare function crToBr(v: string): string;
5
-
6
- export { crToBr };
package/lib/crlfToBr.cjs DELETED
@@ -1,8 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
-
4
- var _chunkTMCJ3HTAcjs = require('./chunk-TMCJ3HTA.cjs');
5
-
6
-
7
-
8
- exports.crlfToBr = _chunkTMCJ3HTAcjs.crlfToBr; exports.filterCRLF = _chunkTMCJ3HTAcjs.filterCRLF;
@@ -1,11 +0,0 @@
1
- /**
2
- * \r \n to <br/>
3
- */
4
- declare function crlfToBr(v: string): string;
5
- /**
6
- * 替换字符串里面的回车换行符
7
- * @deprecated 请使用 @see {@link crlfToBr}.
8
- */
9
- declare function filterCRLF(v: string): string;
10
-
11
- export { crlfToBr, filterCRLF };
@@ -1,6 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunkEUH2FDMTcjs = require('./chunk-EUH2FDMT.cjs');
4
-
5
-
6
- exports.getDaysOfMonth = _chunkEUH2FDMTcjs.getDaysOfMonth;
@@ -1,6 +0,0 @@
1
- /**
2
- * 获取一个月当中的天数
3
- */
4
- declare function getDaysOfMonth(year: number, month: number): number;
5
-
6
- export { getDaysOfMonth };
@@ -1,9 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunk4WWOJSX3cjs = require('./chunk-4WWOJSX3.cjs');
4
- require('./chunk-BQ7SLF6C.cjs');
5
- require('./chunk-HEVW5ZN2.cjs');
6
- require('./chunk-T5JI3MEC.cjs');
7
-
8
-
9
- exports.getWeekBounds = _chunk4WWOJSX3cjs.getWeekBounds;
@@ -1,7 +0,0 @@
1
- /**
2
- * 获取一周的开始时间和结束时间
3
- */
4
- declare function getWeekBounds(value: string | number | Date, sundayIsFirstDay: boolean): [Date, Date];
5
- declare function getWeekBounds(value: string | number | Date, sundayIsFirstDay: boolean, fmt: string): [string, string];
6
-
7
- export { getWeekBounds };
@@ -1,6 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunkUTUKZLENcjs = require('./chunk-UTUKZLEN.cjs');
4
-
5
-
6
- exports.isLeapYear = _chunkUTUKZLENcjs.isLeapYear;
@@ -1,7 +0,0 @@
1
- /**
2
- * 判断是否是闰年
3
- * 规则:四年一闰,百年不闰,四百年再闰
4
- */
5
- declare function isLeapYear(year: number): boolean;
6
-
7
- export { isLeapYear };
package/lib/isUrl.cjs DELETED
@@ -1,6 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunkI6VB2D7Ccjs = require('./chunk-I6VB2D7C.cjs');
4
-
5
-
6
- exports.isUrl = _chunkI6VB2D7Ccjs.isUrl;
package/lib/lfToBr.cjs DELETED
@@ -1,6 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
- var _chunkXSCXPGEIcjs = require('./chunk-XSCXPGEI.cjs');
4
-
5
-
6
- exports.lfToBr = _chunkXSCXPGEIcjs.lfToBr;
package/lib/lfToBr.d.cts DELETED
@@ -1,6 +0,0 @@
1
- /**
2
- * \n to <br/>
3
- */
4
- declare function lfToBr(v: string): string;
5
-
6
- export { lfToBr };