@bgord/tools 0.4.0 → 0.6.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/dist/api-key.vo.d.ts +3 -0
- package/dist/api-key.vo.js +2 -0
- package/dist/build-version.vo.d.ts +3 -0
- package/dist/build-version.vo.js +2 -0
- package/dist/etags.vo.d.ts +4 -4
- package/dist/etags.vo.js +1 -1
- package/dist/index.d.ts +6 -0
- package/dist/index.js +6 -0
- package/dist/language.vo.d.ts +3 -0
- package/dist/language.vo.js +5 -0
- package/dist/package-version.vo.d.ts +20 -0
- package/dist/package-version.vo.js +69 -0
- package/dist/size.vo.d.ts +2 -2
- package/dist/size.vo.js +2 -2
- package/dist/time-zone-offset-value.vo.d.ts +3 -0
- package/dist/time-zone-offset-value.vo.js +7 -0
- package/dist/time.service.d.ts +10 -0
- package/dist/time.service.js +1 -1
- package/dist/timezone.vo.d.ts +3 -0
- package/dist/timezone.vo.js +19 -0
- package/package.json +2 -2
- package/src/api-key.vo.ts +4 -0
- package/src/build-version.vo.ts +5 -0
- package/src/etags.vo.ts +4 -4
- package/src/index.ts +6 -0
- package/src/language.vo.ts +8 -0
- package/src/package-version.vo.ts +92 -0
- package/src/size.vo.ts +3 -3
- package/src/time-zone-offset-value.vo.ts +10 -0
- package/src/time.service.ts +1 -1
- package/src/timezone.vo.ts +26 -0
package/dist/etags.vo.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { z } from "zod/v4";
|
|
2
|
-
declare const
|
|
3
|
-
type
|
|
2
|
+
declare const RevisionValue: z.ZodNumber;
|
|
3
|
+
type RevisionValueType = z.infer<typeof RevisionValue>;
|
|
4
4
|
type ETagValueType = string;
|
|
5
5
|
export declare class ETag {
|
|
6
|
-
readonly revision:
|
|
6
|
+
readonly revision: RevisionValueType;
|
|
7
7
|
static HEADER_NAME: string;
|
|
8
8
|
static IF_MATCH_HEADER_NAME: string;
|
|
9
9
|
readonly value: ETagValueType;
|
|
@@ -12,7 +12,7 @@ export declare class ETag {
|
|
|
12
12
|
}
|
|
13
13
|
export type WeakETagValueType = string;
|
|
14
14
|
export declare class WeakETag {
|
|
15
|
-
readonly revision:
|
|
15
|
+
readonly revision: RevisionValueType;
|
|
16
16
|
static HEADER_NAME: string;
|
|
17
17
|
static IF_MATCH_HEADER_NAME: string;
|
|
18
18
|
readonly value: WeakETagValueType;
|
package/dist/etags.vo.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
|
+
export * from "./api-key.vo";
|
|
2
|
+
export * from "./build-version.vo";
|
|
1
3
|
export * from "./date-calculator.service";
|
|
2
4
|
export * from "./date-formatter.service";
|
|
3
5
|
export * from "./dates-of-the-week.vo";
|
|
4
6
|
export * from "./etags.vo";
|
|
7
|
+
export * from "./language.vo";
|
|
5
8
|
export * from "./mime.vo";
|
|
6
9
|
export * from "./noop.service";
|
|
10
|
+
export * from "./package-version.vo";
|
|
7
11
|
export * from "./rate-limiter.service";
|
|
8
12
|
export * from "./relative-date.vo";
|
|
9
13
|
export * from "./rounding.service";
|
|
10
14
|
export * from "./size.vo";
|
|
11
15
|
export * from "./sleep.service";
|
|
12
16
|
export * from "./stopwatch.service";
|
|
17
|
+
export * from "./time-zone-offset-value.vo";
|
|
13
18
|
export * from "./time.service";
|
|
14
19
|
export * from "./timestamp.vo";
|
|
20
|
+
export * from "./timezone.vo";
|
|
15
21
|
export * from "./ts-utils";
|
package/dist/index.js
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
|
+
export * from "./api-key.vo";
|
|
2
|
+
export * from "./build-version.vo";
|
|
1
3
|
export * from "./date-calculator.service";
|
|
2
4
|
export * from "./date-formatter.service";
|
|
3
5
|
export * from "./dates-of-the-week.vo";
|
|
4
6
|
export * from "./etags.vo";
|
|
7
|
+
export * from "./language.vo";
|
|
5
8
|
export * from "./mime.vo";
|
|
6
9
|
export * from "./noop.service";
|
|
10
|
+
export * from "./package-version.vo";
|
|
7
11
|
export * from "./rate-limiter.service";
|
|
8
12
|
export * from "./relative-date.vo";
|
|
9
13
|
export * from "./rounding.service";
|
|
10
14
|
export * from "./size.vo";
|
|
11
15
|
export * from "./sleep.service";
|
|
12
16
|
export * from "./stopwatch.service";
|
|
17
|
+
export * from "./time-zone-offset-value.vo";
|
|
13
18
|
export * from "./time.service";
|
|
14
19
|
export * from "./timestamp.vo";
|
|
20
|
+
export * from "./timezone.vo";
|
|
15
21
|
export * from "./ts-utils";
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { z } from "zod/v4";
|
|
2
|
+
type MajorType = number;
|
|
3
|
+
type MinorType = number;
|
|
4
|
+
type PatchType = number;
|
|
5
|
+
export declare const PackageVersionValue: z.ZodPipe<z.ZodString, z.ZodTransform<{
|
|
6
|
+
major: number;
|
|
7
|
+
minor: number;
|
|
8
|
+
patch: number;
|
|
9
|
+
}, string>>;
|
|
10
|
+
export type PackageVersionValueType = z.infer<typeof PackageVersionValue>;
|
|
11
|
+
export declare class PackageVersion {
|
|
12
|
+
readonly major: MajorType;
|
|
13
|
+
readonly minor: MinorType;
|
|
14
|
+
readonly patch: PatchType;
|
|
15
|
+
constructor(major: MajorType, minor: MinorType, patch: PatchType);
|
|
16
|
+
isGreaterThanOrEqual(another: PackageVersion): boolean;
|
|
17
|
+
static fromStringWithV(value: string): PackageVersion;
|
|
18
|
+
static fromString(value: string): PackageVersion;
|
|
19
|
+
}
|
|
20
|
+
export {};
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { z } from "zod/v4";
|
|
2
|
+
export const PackageVersionValue = z
|
|
3
|
+
.string()
|
|
4
|
+
.min(1)
|
|
5
|
+
.refine((value) => {
|
|
6
|
+
try {
|
|
7
|
+
if (!value.startsWith("v"))
|
|
8
|
+
return false;
|
|
9
|
+
const [, version] = value.split("v");
|
|
10
|
+
if (!version)
|
|
11
|
+
return false;
|
|
12
|
+
const [major, minor, patch] = version.split(".");
|
|
13
|
+
if (!(major && minor && patch))
|
|
14
|
+
return false;
|
|
15
|
+
if (!(Number.isInteger(Number(major)) &&
|
|
16
|
+
Number.isInteger(Number(minor)) &&
|
|
17
|
+
Number.isInteger(Number(patch)))) {
|
|
18
|
+
return false;
|
|
19
|
+
}
|
|
20
|
+
if (!(Number.isInteger(Number(major)) &&
|
|
21
|
+
Number.isInteger(Number(minor)) &&
|
|
22
|
+
Number.isInteger(Number(patch)))) {
|
|
23
|
+
return false;
|
|
24
|
+
}
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
catch (error) {
|
|
28
|
+
return false;
|
|
29
|
+
}
|
|
30
|
+
}, { message: "package.version.error" })
|
|
31
|
+
.transform((value) => {
|
|
32
|
+
const [, version] = value.split("v");
|
|
33
|
+
const [major, minor, patch] = version.split(".");
|
|
34
|
+
return {
|
|
35
|
+
major: Number(major),
|
|
36
|
+
minor: Number(minor),
|
|
37
|
+
patch: Number(patch),
|
|
38
|
+
};
|
|
39
|
+
});
|
|
40
|
+
export class PackageVersion {
|
|
41
|
+
constructor(major, minor, patch) {
|
|
42
|
+
this.major = major;
|
|
43
|
+
this.minor = minor;
|
|
44
|
+
this.patch = patch;
|
|
45
|
+
}
|
|
46
|
+
isGreaterThanOrEqual(another) {
|
|
47
|
+
if (this.major > another.major)
|
|
48
|
+
return true;
|
|
49
|
+
if (this.major < another.major)
|
|
50
|
+
return false;
|
|
51
|
+
if (this.minor > another.minor)
|
|
52
|
+
return true;
|
|
53
|
+
if (this.minor < another.minor)
|
|
54
|
+
return false;
|
|
55
|
+
if (this.patch > another.patch)
|
|
56
|
+
return true;
|
|
57
|
+
if (this.patch < another.patch)
|
|
58
|
+
return false;
|
|
59
|
+
return true;
|
|
60
|
+
}
|
|
61
|
+
static fromStringWithV(value) {
|
|
62
|
+
const version = PackageVersionValue.parse(value);
|
|
63
|
+
return new PackageVersion(version.major, version.minor, version.patch);
|
|
64
|
+
}
|
|
65
|
+
static fromString(value) {
|
|
66
|
+
const version = PackageVersionValue.parse(`v${value}`);
|
|
67
|
+
return new PackageVersion(version.major, version.minor, version.patch);
|
|
68
|
+
}
|
|
69
|
+
}
|
package/dist/size.vo.d.ts
CHANGED
|
@@ -5,8 +5,8 @@ export declare enum SizeUnit {
|
|
|
5
5
|
MB = "MB",
|
|
6
6
|
GB = "GB"
|
|
7
7
|
}
|
|
8
|
-
declare const
|
|
9
|
-
export type SizeValueType = z.infer<typeof
|
|
8
|
+
declare const SizeValue: z.ZodNumber;
|
|
9
|
+
export type SizeValueType = z.infer<typeof SizeValue>;
|
|
10
10
|
type SizeConfigType = {
|
|
11
11
|
unit: SizeUnit;
|
|
12
12
|
value: SizeValueType;
|
package/dist/size.vo.js
CHANGED
|
@@ -7,11 +7,11 @@ export var SizeUnit;
|
|
|
7
7
|
SizeUnit["MB"] = "MB";
|
|
8
8
|
SizeUnit["GB"] = "GB";
|
|
9
9
|
})(SizeUnit || (SizeUnit = {}));
|
|
10
|
-
const
|
|
10
|
+
const SizeValue = z.number().positive();
|
|
11
11
|
export class Size {
|
|
12
12
|
constructor(config) {
|
|
13
13
|
this.unit = config.unit;
|
|
14
|
-
this.value =
|
|
14
|
+
this.value = SizeValue.parse(config.value);
|
|
15
15
|
this.bytes = this.calculateBytes(config);
|
|
16
16
|
}
|
|
17
17
|
toString() {
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { z } from "zod/v4";
|
|
2
|
+
export declare const TimeZoneOffsetValue: z.ZodPipe<z.ZodPipe<z.ZodUnion<[z.ZodString, z.ZodUndefined]>, z.ZodTransform<number, string | undefined>>, z.ZodTransform<number, number>>;
|
|
3
|
+
export type TimeZoneOffsetValueType = z.infer<typeof TimeZoneOffsetValue>;
|
package/dist/time.service.d.ts
CHANGED
|
@@ -7,6 +7,16 @@ interface TimeResultInterface {
|
|
|
7
7
|
isAfter(another: TimeResultInterface): boolean;
|
|
8
8
|
isBefore(another: TimeResultInterface): boolean;
|
|
9
9
|
}
|
|
10
|
+
export declare class TimeResult implements TimeResultInterface {
|
|
11
|
+
readonly days: number;
|
|
12
|
+
readonly hours: number;
|
|
13
|
+
readonly minutes: number;
|
|
14
|
+
readonly seconds: number;
|
|
15
|
+
readonly ms: number;
|
|
16
|
+
constructor(days: number, hours: number, minutes: number, seconds: number, ms: number);
|
|
17
|
+
isAfter(another: TimeResultInterface): boolean;
|
|
18
|
+
isBefore(another: TimeResultInterface): boolean;
|
|
19
|
+
}
|
|
10
20
|
export declare class Time {
|
|
11
21
|
static Days(value: number): TimeResultInterface;
|
|
12
22
|
static Hours(value: number): TimeResultInterface;
|
package/dist/time.service.js
CHANGED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { z } from "zod/v4";
|
|
2
|
+
export const Timezone = z
|
|
3
|
+
.string()
|
|
4
|
+
.min(1)
|
|
5
|
+
.refine((value) => {
|
|
6
|
+
try {
|
|
7
|
+
// Create a dummy date and time format using the specified timezone
|
|
8
|
+
const dummyDate = new Date();
|
|
9
|
+
const formatter = new Intl.DateTimeFormat("en-US", { timeZone: value });
|
|
10
|
+
// Format the dummy date
|
|
11
|
+
formatter.format(dummyDate);
|
|
12
|
+
// If the formatting succeeds without throwing an error, the timezone is valid
|
|
13
|
+
return true;
|
|
14
|
+
}
|
|
15
|
+
catch (error) {
|
|
16
|
+
// An error occurred, indicating an invalid timezone
|
|
17
|
+
return false;
|
|
18
|
+
}
|
|
19
|
+
}, { message: "timezone.invalid" });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bgord/tools",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Bartosz Gordon",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"date-fns": "4.1.0",
|
|
33
|
-
"zod": "3.25.
|
|
33
|
+
"zod": "3.25.51"
|
|
34
34
|
},
|
|
35
35
|
"sideEffects": false
|
|
36
36
|
}
|
package/src/etags.vo.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from "zod/v4";
|
|
2
2
|
|
|
3
|
-
const
|
|
3
|
+
const RevisionValue = z.number().int().min(0);
|
|
4
4
|
|
|
5
|
-
type
|
|
5
|
+
type RevisionValueType = z.infer<typeof RevisionValue>;
|
|
6
6
|
|
|
7
7
|
type ETagValueType = string;
|
|
8
8
|
|
|
@@ -13,7 +13,7 @@ export class ETag {
|
|
|
13
13
|
|
|
14
14
|
readonly value: ETagValueType;
|
|
15
15
|
|
|
16
|
-
private constructor(readonly revision:
|
|
16
|
+
private constructor(readonly revision: RevisionValueType) {
|
|
17
17
|
this.value = revision.toString();
|
|
18
18
|
}
|
|
19
19
|
|
|
@@ -36,7 +36,7 @@ export class WeakETag {
|
|
|
36
36
|
|
|
37
37
|
readonly value: WeakETagValueType;
|
|
38
38
|
|
|
39
|
-
private constructor(readonly revision:
|
|
39
|
+
private constructor(readonly revision: RevisionValueType) {
|
|
40
40
|
this.value = `W/${revision.toString()}`;
|
|
41
41
|
}
|
|
42
42
|
|
package/src/index.ts
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
|
+
export * from "./api-key.vo";
|
|
2
|
+
export * from "./build-version.vo";
|
|
1
3
|
export * from "./date-calculator.service";
|
|
2
4
|
export * from "./date-formatter.service";
|
|
3
5
|
export * from "./dates-of-the-week.vo";
|
|
4
6
|
export * from "./etags.vo";
|
|
7
|
+
export * from "./language.vo";
|
|
5
8
|
export * from "./mime.vo";
|
|
6
9
|
export * from "./noop.service";
|
|
10
|
+
export * from "./package-version.vo";
|
|
7
11
|
export * from "./rate-limiter.service";
|
|
8
12
|
export * from "./relative-date.vo";
|
|
9
13
|
export * from "./rounding.service";
|
|
10
14
|
export * from "./size.vo";
|
|
11
15
|
export * from "./sleep.service";
|
|
12
16
|
export * from "./stopwatch.service";
|
|
17
|
+
export * from "./time-zone-offset-value.vo";
|
|
13
18
|
export * from "./time.service";
|
|
14
19
|
export * from "./timestamp.vo";
|
|
20
|
+
export * from "./timezone.vo";
|
|
15
21
|
export * from "./ts-utils";
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { z } from "zod/v4";
|
|
2
|
+
|
|
3
|
+
type MajorType = number;
|
|
4
|
+
type MinorType = number;
|
|
5
|
+
type PatchType = number;
|
|
6
|
+
|
|
7
|
+
export const PackageVersionValue = z
|
|
8
|
+
.string()
|
|
9
|
+
.min(1)
|
|
10
|
+
.refine(
|
|
11
|
+
(value) => {
|
|
12
|
+
try {
|
|
13
|
+
if (!value.startsWith("v")) return false;
|
|
14
|
+
|
|
15
|
+
const [, version] = value.split("v");
|
|
16
|
+
if (!version) return false;
|
|
17
|
+
|
|
18
|
+
const [major, minor, patch] = version.split(".");
|
|
19
|
+
if (!(major && minor && patch)) return false;
|
|
20
|
+
|
|
21
|
+
if (
|
|
22
|
+
!(
|
|
23
|
+
Number.isInteger(Number(major)) &&
|
|
24
|
+
Number.isInteger(Number(minor)) &&
|
|
25
|
+
Number.isInteger(Number(patch))
|
|
26
|
+
)
|
|
27
|
+
) {
|
|
28
|
+
return false;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
if (
|
|
32
|
+
!(
|
|
33
|
+
Number.isInteger(Number(major)) &&
|
|
34
|
+
Number.isInteger(Number(minor)) &&
|
|
35
|
+
Number.isInteger(Number(patch))
|
|
36
|
+
)
|
|
37
|
+
) {
|
|
38
|
+
return false;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
return true;
|
|
42
|
+
} catch (error) {
|
|
43
|
+
return false;
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
{ message: "package.version.error" },
|
|
47
|
+
)
|
|
48
|
+
.transform((value) => {
|
|
49
|
+
const [, version] = value.split("v");
|
|
50
|
+
|
|
51
|
+
const [major, minor, patch] = (version as string).split(".");
|
|
52
|
+
|
|
53
|
+
return {
|
|
54
|
+
major: Number(major),
|
|
55
|
+
minor: Number(minor),
|
|
56
|
+
patch: Number(patch),
|
|
57
|
+
};
|
|
58
|
+
});
|
|
59
|
+
export type PackageVersionValueType = z.infer<typeof PackageVersionValue>;
|
|
60
|
+
|
|
61
|
+
export class PackageVersion {
|
|
62
|
+
constructor(
|
|
63
|
+
readonly major: MajorType,
|
|
64
|
+
readonly minor: MinorType,
|
|
65
|
+
readonly patch: PatchType,
|
|
66
|
+
) {}
|
|
67
|
+
|
|
68
|
+
isGreaterThanOrEqual(another: PackageVersion) {
|
|
69
|
+
if (this.major > another.major) return true;
|
|
70
|
+
if (this.major < another.major) return false;
|
|
71
|
+
|
|
72
|
+
if (this.minor > another.minor) return true;
|
|
73
|
+
if (this.minor < another.minor) return false;
|
|
74
|
+
|
|
75
|
+
if (this.patch > another.patch) return true;
|
|
76
|
+
if (this.patch < another.patch) return false;
|
|
77
|
+
|
|
78
|
+
return true;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
static fromStringWithV(value: string) {
|
|
82
|
+
const version = PackageVersionValue.parse(value);
|
|
83
|
+
|
|
84
|
+
return new PackageVersion(version.major, version.minor, version.patch);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
static fromString(value: string) {
|
|
88
|
+
const version = PackageVersionValue.parse(`v${value}`);
|
|
89
|
+
|
|
90
|
+
return new PackageVersion(version.major, version.minor, version.patch);
|
|
91
|
+
}
|
|
92
|
+
}
|
package/src/size.vo.ts
CHANGED
|
@@ -9,9 +9,9 @@ export enum SizeUnit {
|
|
|
9
9
|
GB = "GB",
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
-
const
|
|
12
|
+
const SizeValue = z.number().positive();
|
|
13
13
|
|
|
14
|
-
export type SizeValueType = z.infer<typeof
|
|
14
|
+
export type SizeValueType = z.infer<typeof SizeValue>;
|
|
15
15
|
|
|
16
16
|
type SizeConfigType = { unit: SizeUnit; value: SizeValueType };
|
|
17
17
|
|
|
@@ -30,7 +30,7 @@ export class Size {
|
|
|
30
30
|
|
|
31
31
|
constructor(config: SizeConfigType) {
|
|
32
32
|
this.unit = config.unit;
|
|
33
|
-
this.value =
|
|
33
|
+
this.value = SizeValue.parse(config.value);
|
|
34
34
|
this.bytes = this.calculateBytes(config);
|
|
35
35
|
}
|
|
36
36
|
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from "zod/v4";
|
|
2
|
+
|
|
3
|
+
export const TimeZoneOffsetValue = z
|
|
4
|
+
.string()
|
|
5
|
+
.trim()
|
|
6
|
+
.or(z.undefined())
|
|
7
|
+
.transform((value) => Number(value))
|
|
8
|
+
.transform((value) => (Number.isNaN(value) ? 0 : value));
|
|
9
|
+
|
|
10
|
+
export type TimeZoneOffsetValueType = z.infer<typeof TimeZoneOffsetValue>;
|
package/src/time.service.ts
CHANGED
|
@@ -13,7 +13,7 @@ interface TimeResultInterface {
|
|
|
13
13
|
isBefore(another: TimeResultInterface): boolean;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
class TimeResult implements TimeResultInterface {
|
|
16
|
+
export class TimeResult implements TimeResultInterface {
|
|
17
17
|
constructor(
|
|
18
18
|
readonly days: number,
|
|
19
19
|
readonly hours: number,
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { z } from "zod/v4";
|
|
2
|
+
|
|
3
|
+
export const Timezone = z
|
|
4
|
+
.string()
|
|
5
|
+
.min(1)
|
|
6
|
+
.refine(
|
|
7
|
+
(value) => {
|
|
8
|
+
try {
|
|
9
|
+
// Create a dummy date and time format using the specified timezone
|
|
10
|
+
const dummyDate = new Date();
|
|
11
|
+
const formatter = new Intl.DateTimeFormat("en-US", { timeZone: value });
|
|
12
|
+
|
|
13
|
+
// Format the dummy date
|
|
14
|
+
formatter.format(dummyDate);
|
|
15
|
+
|
|
16
|
+
// If the formatting succeeds without throwing an error, the timezone is valid
|
|
17
|
+
return true;
|
|
18
|
+
} catch (error) {
|
|
19
|
+
// An error occurred, indicating an invalid timezone
|
|
20
|
+
return false;
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
{ message: "timezone.invalid" },
|
|
24
|
+
);
|
|
25
|
+
|
|
26
|
+
export type TimezoneType = z.infer<typeof Timezone>;
|