@nxtedition/types 1.6.8 → 1.6.10
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/common/file.d.ts +1 -0
- package/dist/common/file.js +111 -74
- package/dist/common/settings.d.ts +16 -4
- package/dist/common/settings.js +808 -706
- package/dist/domains/asset.d.ts +10 -0
- package/dist/domains/asset.js +124 -0
- package/dist/domains/event.d.ts +22 -0
- package/dist/domains/event.js +179 -6
- package/dist/domains/file.d.ts +26 -0
- package/dist/domains/file.js +971 -0
- package/dist/domains/index.d.ts +3 -1
- package/dist/domains/index.js +1 -0
- package/dist/domains/settings.js +866 -761
- package/package.json +1 -1
package/dist/domains/asset.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ export interface AssetDomainRecords {
|
|
|
5
5
|
":asset.assignees?": AssetAssigneesRecord;
|
|
6
6
|
":asset.refs?": AssetRefsRecord;
|
|
7
7
|
":asset.tags?": AssetTagsRecord;
|
|
8
|
+
":asset.fileRefs?": AssetFileRefsRecord;
|
|
8
9
|
}
|
|
9
10
|
export interface AssetTitleRecord {
|
|
10
11
|
value?: string;
|
|
@@ -56,4 +57,13 @@ export declare const randomAssetTagsRecord: () => AssetTagsRecord;
|
|
|
56
57
|
export declare const assertGuardAssetTagsRecord: __AssertionGuard<AssetTagsRecord>;
|
|
57
58
|
export declare const stringifyAssetTagsRecord: (input: AssetTagsRecord) => string;
|
|
58
59
|
export declare const assertStringifyAssetTagsRecord: (input: unknown) => string;
|
|
60
|
+
export interface AssetFileRefsRecord {
|
|
61
|
+
value?: string[];
|
|
62
|
+
}
|
|
63
|
+
export declare const isAssetFileRefsRecord: (input: unknown) => input is AssetFileRefsRecord;
|
|
64
|
+
export declare const assertAssetFileRefsRecord: (input: unknown) => AssetFileRefsRecord;
|
|
65
|
+
export declare const randomAssetFileRefsRecord: () => AssetFileRefsRecord;
|
|
66
|
+
export declare const assertGuardAssetFileRefsRecord: __AssertionGuard<AssetFileRefsRecord>;
|
|
67
|
+
export declare const stringifyAssetFileRefsRecord: (input: AssetFileRefsRecord) => string;
|
|
68
|
+
export declare const assertStringifyAssetFileRefsRecord: (input: unknown) => string;
|
|
59
69
|
export {};
|
package/dist/domains/asset.js
CHANGED
|
@@ -657,3 +657,127 @@ export const assertStringifyAssetTagsRecord = (input, errorFactory) => { const a
|
|
|
657
657
|
const $so0 = input => `{${$tail(`${undefined === input.value ? "" : `"value":${undefined !== input.value ? `[${input.value.map(elem => $string(elem)).join(",")}]` : undefined}`}`)}}`;
|
|
658
658
|
return $so0(input);
|
|
659
659
|
}; return stringify(assert(input, errorFactory)); };
|
|
660
|
+
export const isAssetFileRefsRecord = input => {
|
|
661
|
+
const $io0 = input => undefined === input.value || Array.isArray(input.value) && input.value.every(elem => "string" === typeof elem);
|
|
662
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
663
|
+
};
|
|
664
|
+
export const assertAssetFileRefsRecord = (input, errorFactory) => {
|
|
665
|
+
const __is = input => {
|
|
666
|
+
const $io0 = input => undefined === input.value || Array.isArray(input.value) && input.value.every(elem => "string" === typeof elem);
|
|
667
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
668
|
+
};
|
|
669
|
+
if (false === __is(input))
|
|
670
|
+
((input, _path, _exceptionable = true) => {
|
|
671
|
+
const $guard = __typia.createAssert.guard;
|
|
672
|
+
const $ao0 = (input, _path, _exceptionable = true) => undefined === input.value || (Array.isArray(input.value) || $guard(_exceptionable, {
|
|
673
|
+
path: _path + ".value",
|
|
674
|
+
expected: "(Array<string> | undefined)",
|
|
675
|
+
value: input.value
|
|
676
|
+
}, errorFactory)) && input.value.every((elem, _index1) => "string" === typeof elem || $guard(_exceptionable, {
|
|
677
|
+
path: _path + ".value[" + _index1 + "]",
|
|
678
|
+
expected: "string",
|
|
679
|
+
value: elem
|
|
680
|
+
}, errorFactory)) || $guard(_exceptionable, {
|
|
681
|
+
path: _path + ".value",
|
|
682
|
+
expected: "(Array<string> | undefined)",
|
|
683
|
+
value: input.value
|
|
684
|
+
}, errorFactory);
|
|
685
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
686
|
+
path: _path + "",
|
|
687
|
+
expected: "AssetFileRefsRecord",
|
|
688
|
+
value: input
|
|
689
|
+
}, errorFactory)) && $ao0(input, _path + "", true) || $guard(true, {
|
|
690
|
+
path: _path + "",
|
|
691
|
+
expected: "AssetFileRefsRecord",
|
|
692
|
+
value: input
|
|
693
|
+
}, errorFactory);
|
|
694
|
+
})(input, "$input", true);
|
|
695
|
+
return input;
|
|
696
|
+
};
|
|
697
|
+
export const randomAssetFileRefsRecord = generator => {
|
|
698
|
+
const $generator = __typia.createRandom.generator;
|
|
699
|
+
const $pick = __typia.createRandom.pick;
|
|
700
|
+
const $ro0 = (_recursive = false, _depth = 0) => ({
|
|
701
|
+
value: $pick([
|
|
702
|
+
() => undefined,
|
|
703
|
+
() => (generator?.array ?? $generator.array)(() => (generator?.customs ?? $generator.customs)?.string?.([]) ?? (generator?.string ?? $generator.string)())
|
|
704
|
+
])()
|
|
705
|
+
});
|
|
706
|
+
return $ro0();
|
|
707
|
+
};
|
|
708
|
+
export const assertGuardAssetFileRefsRecord = (input, errorFactory) => {
|
|
709
|
+
const __is = input => {
|
|
710
|
+
const $io0 = input => undefined === input.value || Array.isArray(input.value) && input.value.every(elem => "string" === typeof elem);
|
|
711
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
712
|
+
};
|
|
713
|
+
if (false === __is(input))
|
|
714
|
+
((input, _path, _exceptionable = true) => {
|
|
715
|
+
const $guard = __typia.createAssertGuard.guard;
|
|
716
|
+
const $ao0 = (input, _path, _exceptionable = true) => undefined === input.value || (Array.isArray(input.value) || $guard(_exceptionable, {
|
|
717
|
+
path: _path + ".value",
|
|
718
|
+
expected: "(Array<string> | undefined)",
|
|
719
|
+
value: input.value
|
|
720
|
+
}, errorFactory)) && input.value.every((elem, _index1) => "string" === typeof elem || $guard(_exceptionable, {
|
|
721
|
+
path: _path + ".value[" + _index1 + "]",
|
|
722
|
+
expected: "string",
|
|
723
|
+
value: elem
|
|
724
|
+
}, errorFactory)) || $guard(_exceptionable, {
|
|
725
|
+
path: _path + ".value",
|
|
726
|
+
expected: "(Array<string> | undefined)",
|
|
727
|
+
value: input.value
|
|
728
|
+
}, errorFactory);
|
|
729
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
730
|
+
path: _path + "",
|
|
731
|
+
expected: "AssetFileRefsRecord",
|
|
732
|
+
value: input
|
|
733
|
+
}, errorFactory)) && $ao0(input, _path + "", true) || $guard(true, {
|
|
734
|
+
path: _path + "",
|
|
735
|
+
expected: "AssetFileRefsRecord",
|
|
736
|
+
value: input
|
|
737
|
+
}, errorFactory);
|
|
738
|
+
})(input, "$input", true);
|
|
739
|
+
};
|
|
740
|
+
export const stringifyAssetFileRefsRecord = input => {
|
|
741
|
+
const $string = __typia.json.createStringify.string;
|
|
742
|
+
const $tail = __typia.json.createStringify.tail;
|
|
743
|
+
const $so0 = input => `{${$tail(`${undefined === input.value ? "" : `"value":${undefined !== input.value ? `[${input.value.map(elem => $string(elem)).join(",")}]` : undefined}`}`)}}`;
|
|
744
|
+
return $so0(input);
|
|
745
|
+
};
|
|
746
|
+
export const assertStringifyAssetFileRefsRecord = (input, errorFactory) => { const assert = (input, errorFactory) => {
|
|
747
|
+
const __is = input => {
|
|
748
|
+
const $io0 = input => undefined === input.value || Array.isArray(input.value) && input.value.every(elem => "string" === typeof elem);
|
|
749
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
750
|
+
};
|
|
751
|
+
if (false === __is(input))
|
|
752
|
+
((input, _path, _exceptionable = true) => {
|
|
753
|
+
const $guard = __typia.json.createAssertStringify.guard;
|
|
754
|
+
const $ao0 = (input, _path, _exceptionable = true) => undefined === input.value || (Array.isArray(input.value) || $guard(_exceptionable, {
|
|
755
|
+
path: _path + ".value",
|
|
756
|
+
expected: "(Array<string> | undefined)",
|
|
757
|
+
value: input.value
|
|
758
|
+
}, errorFactory)) && input.value.every((elem, _index1) => "string" === typeof elem || $guard(_exceptionable, {
|
|
759
|
+
path: _path + ".value[" + _index1 + "]",
|
|
760
|
+
expected: "string",
|
|
761
|
+
value: elem
|
|
762
|
+
}, errorFactory)) || $guard(_exceptionable, {
|
|
763
|
+
path: _path + ".value",
|
|
764
|
+
expected: "(Array<string> | undefined)",
|
|
765
|
+
value: input.value
|
|
766
|
+
}, errorFactory);
|
|
767
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
768
|
+
path: _path + "",
|
|
769
|
+
expected: "AssetFileRefsRecord",
|
|
770
|
+
value: input
|
|
771
|
+
}, errorFactory)) && $ao0(input, _path + "", true) || $guard(true, {
|
|
772
|
+
path: _path + "",
|
|
773
|
+
expected: "AssetFileRefsRecord",
|
|
774
|
+
value: input
|
|
775
|
+
}, errorFactory);
|
|
776
|
+
})(input, "$input", true);
|
|
777
|
+
return input;
|
|
778
|
+
}; const stringify = input => {
|
|
779
|
+
const $string = __typia.json.createAssertStringify.string;
|
|
780
|
+
const $tail = __typia.json.createAssertStringify.tail;
|
|
781
|
+
const $so0 = input => `{${$tail(`${undefined === input.value ? "" : `"value":${undefined !== input.value ? `[${input.value.map(elem => $string(elem)).join(",")}]` : undefined}`}`)}}`;
|
|
782
|
+
return $so0(input);
|
|
783
|
+
}; return stringify(assert(input, errorFactory)); };
|
package/dist/domains/event.d.ts
CHANGED
|
@@ -9,6 +9,8 @@ export interface EventRecord {
|
|
|
9
9
|
duration?: number;
|
|
10
10
|
text?: string;
|
|
11
11
|
lang?: string;
|
|
12
|
+
style?: string;
|
|
13
|
+
styleOverrides?: EventSubtitleStyle;
|
|
12
14
|
}
|
|
13
15
|
export declare const isEventRecord: (input: unknown) => input is EventRecord;
|
|
14
16
|
export declare const assertEventRecord: (input: unknown) => EventRecord;
|
|
@@ -16,3 +18,23 @@ export declare const randomEventRecord: () => EventRecord;
|
|
|
16
18
|
export declare const assertGuardEventRecord: __AssertionGuard<EventRecord>;
|
|
17
19
|
export declare const stringifyEventRecord: (input: EventRecord) => string;
|
|
18
20
|
export declare const assertStringifyEventRecord: (input: unknown) => string;
|
|
21
|
+
export interface EventSubtitleStyle {
|
|
22
|
+
/**
|
|
23
|
+
* 1 - bottom left
|
|
24
|
+
* 2 - bottom center
|
|
25
|
+
* 3 - bottom right
|
|
26
|
+
* 4 - center left
|
|
27
|
+
* 5 - center center
|
|
28
|
+
* 6 - center right
|
|
29
|
+
* 7 - top left
|
|
30
|
+
* 8 - top center
|
|
31
|
+
* 9 - top right
|
|
32
|
+
*/
|
|
33
|
+
alignment?: string;
|
|
34
|
+
}
|
|
35
|
+
export declare const isEventSubtitleStyle: (input: unknown) => input is EventSubtitleStyle;
|
|
36
|
+
export declare const assertEventSubtitleStyle: (input: unknown) => EventSubtitleStyle;
|
|
37
|
+
export declare const randomEventSubtitleStyle: () => EventSubtitleStyle;
|
|
38
|
+
export declare const assertGuardEventSubtitleStyle: __AssertionGuard<EventSubtitleStyle>;
|
|
39
|
+
export declare const stringifyEventSubtitleStyle: (input: EventSubtitleStyle) => string;
|
|
40
|
+
export declare const assertStringifyEventSubtitleStyle: (input: unknown) => string;
|
package/dist/domains/event.js
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import __typia from "typia";
|
|
2
2
|
export const isEventRecord = input => {
|
|
3
|
-
const $io0 = input => (undefined === input.start || "number" === typeof input.start) && (undefined === input.end || "number" === typeof input.end) && (undefined === input.duration || "number" === typeof input.duration) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang);
|
|
3
|
+
const $io0 = input => (undefined === input.start || "number" === typeof input.start) && (undefined === input.end || "number" === typeof input.end) && (undefined === input.duration || "number" === typeof input.duration) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang) && (undefined === input.style || "string" === typeof input.style) && (undefined === input.styleOverrides || "object" === typeof input.styleOverrides && null !== input.styleOverrides && false === Array.isArray(input.styleOverrides) && $io1(input.styleOverrides));
|
|
4
|
+
const $io1 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
4
5
|
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
5
6
|
};
|
|
6
7
|
export const assertEventRecord = (input, errorFactory) => {
|
|
7
8
|
const __is = input => {
|
|
8
|
-
const $io0 = input => (undefined === input.start || "number" === typeof input.start) && (undefined === input.end || "number" === typeof input.end) && (undefined === input.duration || "number" === typeof input.duration) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang);
|
|
9
|
+
const $io0 = input => (undefined === input.start || "number" === typeof input.start) && (undefined === input.end || "number" === typeof input.end) && (undefined === input.duration || "number" === typeof input.duration) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang) && (undefined === input.style || "string" === typeof input.style) && (undefined === input.styleOverrides || "object" === typeof input.styleOverrides && null !== input.styleOverrides && false === Array.isArray(input.styleOverrides) && $io1(input.styleOverrides));
|
|
10
|
+
const $io1 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
9
11
|
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
10
12
|
};
|
|
11
13
|
if (false === __is(input))
|
|
@@ -31,7 +33,24 @@ export const assertEventRecord = (input, errorFactory) => {
|
|
|
31
33
|
path: _path + ".lang",
|
|
32
34
|
expected: "(string | undefined)",
|
|
33
35
|
value: input.lang
|
|
36
|
+
}, errorFactory)) && (undefined === input.style || "string" === typeof input.style || $guard(_exceptionable, {
|
|
37
|
+
path: _path + ".style",
|
|
38
|
+
expected: "(string | undefined)",
|
|
39
|
+
value: input.style
|
|
40
|
+
}, errorFactory)) && (undefined === input.styleOverrides || ("object" === typeof input.styleOverrides && null !== input.styleOverrides && false === Array.isArray(input.styleOverrides) || $guard(_exceptionable, {
|
|
41
|
+
path: _path + ".styleOverrides",
|
|
42
|
+
expected: "(EventSubtitleStyle | undefined)",
|
|
43
|
+
value: input.styleOverrides
|
|
44
|
+
}, errorFactory)) && $ao1(input.styleOverrides, _path + ".styleOverrides", true && _exceptionable) || $guard(_exceptionable, {
|
|
45
|
+
path: _path + ".styleOverrides",
|
|
46
|
+
expected: "(EventSubtitleStyle | undefined)",
|
|
47
|
+
value: input.styleOverrides
|
|
34
48
|
}, errorFactory));
|
|
49
|
+
const $ao1 = (input, _path, _exceptionable = true) => undefined === input.alignment || "string" === typeof input.alignment || $guard(_exceptionable, {
|
|
50
|
+
path: _path + ".alignment",
|
|
51
|
+
expected: "(string | undefined)",
|
|
52
|
+
value: input.alignment
|
|
53
|
+
}, errorFactory);
|
|
35
54
|
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
36
55
|
path: _path + "",
|
|
37
56
|
expected: "EventRecord",
|
|
@@ -67,13 +86,28 @@ export const randomEventRecord = generator => {
|
|
|
67
86
|
lang: $pick([
|
|
68
87
|
() => undefined,
|
|
69
88
|
() => (generator?.customs ?? $generator.customs)?.string?.([]) ?? (generator?.string ?? $generator.string)()
|
|
89
|
+
])(),
|
|
90
|
+
style: $pick([
|
|
91
|
+
() => undefined,
|
|
92
|
+
() => (generator?.customs ?? $generator.customs)?.string?.([]) ?? (generator?.string ?? $generator.string)()
|
|
93
|
+
])(),
|
|
94
|
+
styleOverrides: $pick([
|
|
95
|
+
() => undefined,
|
|
96
|
+
() => $ro1(_recursive, _recursive ? 1 + _depth : _depth)
|
|
97
|
+
])()
|
|
98
|
+
});
|
|
99
|
+
const $ro1 = (_recursive = false, _depth = 0) => ({
|
|
100
|
+
alignment: $pick([
|
|
101
|
+
() => undefined,
|
|
102
|
+
() => (generator?.customs ?? $generator.customs)?.string?.([]) ?? (generator?.string ?? $generator.string)()
|
|
70
103
|
])()
|
|
71
104
|
});
|
|
72
105
|
return $ro0();
|
|
73
106
|
};
|
|
74
107
|
export const assertGuardEventRecord = (input, errorFactory) => {
|
|
75
108
|
const __is = input => {
|
|
76
|
-
const $io0 = input => (undefined === input.start || "number" === typeof input.start) && (undefined === input.end || "number" === typeof input.end) && (undefined === input.duration || "number" === typeof input.duration) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang);
|
|
109
|
+
const $io0 = input => (undefined === input.start || "number" === typeof input.start) && (undefined === input.end || "number" === typeof input.end) && (undefined === input.duration || "number" === typeof input.duration) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang) && (undefined === input.style || "string" === typeof input.style) && (undefined === input.styleOverrides || "object" === typeof input.styleOverrides && null !== input.styleOverrides && false === Array.isArray(input.styleOverrides) && $io1(input.styleOverrides));
|
|
110
|
+
const $io1 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
77
111
|
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
78
112
|
};
|
|
79
113
|
if (false === __is(input))
|
|
@@ -99,7 +133,24 @@ export const assertGuardEventRecord = (input, errorFactory) => {
|
|
|
99
133
|
path: _path + ".lang",
|
|
100
134
|
expected: "(string | undefined)",
|
|
101
135
|
value: input.lang
|
|
136
|
+
}, errorFactory)) && (undefined === input.style || "string" === typeof input.style || $guard(_exceptionable, {
|
|
137
|
+
path: _path + ".style",
|
|
138
|
+
expected: "(string | undefined)",
|
|
139
|
+
value: input.style
|
|
140
|
+
}, errorFactory)) && (undefined === input.styleOverrides || ("object" === typeof input.styleOverrides && null !== input.styleOverrides && false === Array.isArray(input.styleOverrides) || $guard(_exceptionable, {
|
|
141
|
+
path: _path + ".styleOverrides",
|
|
142
|
+
expected: "(EventSubtitleStyle | undefined)",
|
|
143
|
+
value: input.styleOverrides
|
|
144
|
+
}, errorFactory)) && $ao1(input.styleOverrides, _path + ".styleOverrides", true && _exceptionable) || $guard(_exceptionable, {
|
|
145
|
+
path: _path + ".styleOverrides",
|
|
146
|
+
expected: "(EventSubtitleStyle | undefined)",
|
|
147
|
+
value: input.styleOverrides
|
|
102
148
|
}, errorFactory));
|
|
149
|
+
const $ao1 = (input, _path, _exceptionable = true) => undefined === input.alignment || "string" === typeof input.alignment || $guard(_exceptionable, {
|
|
150
|
+
path: _path + ".alignment",
|
|
151
|
+
expected: "(string | undefined)",
|
|
152
|
+
value: input.alignment
|
|
153
|
+
}, errorFactory);
|
|
103
154
|
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
104
155
|
path: _path + "",
|
|
105
156
|
expected: "EventRecord",
|
|
@@ -112,14 +163,17 @@ export const assertGuardEventRecord = (input, errorFactory) => {
|
|
|
112
163
|
})(input, "$input", true);
|
|
113
164
|
};
|
|
114
165
|
export const stringifyEventRecord = input => {
|
|
166
|
+
const $io1 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
115
167
|
const $string = __typia.json.createStringify.string;
|
|
116
168
|
const $tail = __typia.json.createStringify.tail;
|
|
117
|
-
const $so0 = input => `{${$tail(`${undefined === input.start ? "" : `"start":${undefined !== input.start ? input.start : undefined},`}${undefined === input.end ? "" : `"end":${undefined !== input.end ? input.end : undefined},`}${undefined === input.duration ? "" : `"duration":${undefined !== input.duration ? input.duration : undefined},`}${undefined === input.text ? "" : `"text":${undefined !== input.text ? $string(input.text) : undefined},`}${undefined === input.lang ? "" : `"lang":${undefined !== input.lang ? $string(input.lang) : undefined}`}`)}}`;
|
|
169
|
+
const $so0 = input => `{${$tail(`${undefined === input.start ? "" : `"start":${undefined !== input.start ? input.start : undefined},`}${undefined === input.end ? "" : `"end":${undefined !== input.end ? input.end : undefined},`}${undefined === input.duration ? "" : `"duration":${undefined !== input.duration ? input.duration : undefined},`}${undefined === input.text ? "" : `"text":${undefined !== input.text ? $string(input.text) : undefined},`}${undefined === input.lang ? "" : `"lang":${undefined !== input.lang ? $string(input.lang) : undefined},`}${undefined === input.style ? "" : `"style":${undefined !== input.style ? $string(input.style) : undefined},`}${undefined === input.styleOverrides ? "" : `"styleOverrides":${undefined !== input.styleOverrides ? $so1(input.styleOverrides) : undefined}`}`)}}`;
|
|
170
|
+
const $so1 = input => `{${$tail(`${undefined === input.alignment ? "" : `"alignment":${undefined !== input.alignment ? $string(input.alignment) : undefined}`}`)}}`;
|
|
118
171
|
return $so0(input);
|
|
119
172
|
};
|
|
120
173
|
export const assertStringifyEventRecord = (input, errorFactory) => { const assert = (input, errorFactory) => {
|
|
121
174
|
const __is = input => {
|
|
122
|
-
const $io0 = input => (undefined === input.start || "number" === typeof input.start && !Number.isNaN(input.start)) && (undefined === input.end || "number" === typeof input.end && !Number.isNaN(input.end)) && (undefined === input.duration || "number" === typeof input.duration && !Number.isNaN(input.duration)) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang);
|
|
175
|
+
const $io0 = input => (undefined === input.start || "number" === typeof input.start && !Number.isNaN(input.start)) && (undefined === input.end || "number" === typeof input.end && !Number.isNaN(input.end)) && (undefined === input.duration || "number" === typeof input.duration && !Number.isNaN(input.duration)) && (undefined === input.text || "string" === typeof input.text) && (undefined === input.lang || "string" === typeof input.lang) && (undefined === input.style || "string" === typeof input.style) && (undefined === input.styleOverrides || "object" === typeof input.styleOverrides && null !== input.styleOverrides && false === Array.isArray(input.styleOverrides) && $io1(input.styleOverrides));
|
|
176
|
+
const $io1 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
123
177
|
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
124
178
|
};
|
|
125
179
|
if (false === __is(input))
|
|
@@ -145,7 +199,24 @@ export const assertStringifyEventRecord = (input, errorFactory) => { const asser
|
|
|
145
199
|
path: _path + ".lang",
|
|
146
200
|
expected: "(string | undefined)",
|
|
147
201
|
value: input.lang
|
|
202
|
+
}, errorFactory)) && (undefined === input.style || "string" === typeof input.style || $guard(_exceptionable, {
|
|
203
|
+
path: _path + ".style",
|
|
204
|
+
expected: "(string | undefined)",
|
|
205
|
+
value: input.style
|
|
206
|
+
}, errorFactory)) && (undefined === input.styleOverrides || ("object" === typeof input.styleOverrides && null !== input.styleOverrides && false === Array.isArray(input.styleOverrides) || $guard(_exceptionable, {
|
|
207
|
+
path: _path + ".styleOverrides",
|
|
208
|
+
expected: "(EventSubtitleStyle | undefined)",
|
|
209
|
+
value: input.styleOverrides
|
|
210
|
+
}, errorFactory)) && $ao1(input.styleOverrides, _path + ".styleOverrides", true && _exceptionable) || $guard(_exceptionable, {
|
|
211
|
+
path: _path + ".styleOverrides",
|
|
212
|
+
expected: "(EventSubtitleStyle | undefined)",
|
|
213
|
+
value: input.styleOverrides
|
|
148
214
|
}, errorFactory));
|
|
215
|
+
const $ao1 = (input, _path, _exceptionable = true) => undefined === input.alignment || "string" === typeof input.alignment || $guard(_exceptionable, {
|
|
216
|
+
path: _path + ".alignment",
|
|
217
|
+
expected: "(string | undefined)",
|
|
218
|
+
value: input.alignment
|
|
219
|
+
}, errorFactory);
|
|
149
220
|
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
150
221
|
path: _path + "",
|
|
151
222
|
expected: "EventRecord",
|
|
@@ -157,9 +228,111 @@ export const assertStringifyEventRecord = (input, errorFactory) => { const asser
|
|
|
157
228
|
}, errorFactory);
|
|
158
229
|
})(input, "$input", true);
|
|
159
230
|
return input;
|
|
231
|
+
}; const stringify = input => {
|
|
232
|
+
const $io1 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
233
|
+
const $string = __typia.json.createAssertStringify.string;
|
|
234
|
+
const $tail = __typia.json.createAssertStringify.tail;
|
|
235
|
+
const $so0 = input => `{${$tail(`${undefined === input.start ? "" : `"start":${undefined !== input.start ? input.start : undefined},`}${undefined === input.end ? "" : `"end":${undefined !== input.end ? input.end : undefined},`}${undefined === input.duration ? "" : `"duration":${undefined !== input.duration ? input.duration : undefined},`}${undefined === input.text ? "" : `"text":${undefined !== input.text ? $string(input.text) : undefined},`}${undefined === input.lang ? "" : `"lang":${undefined !== input.lang ? $string(input.lang) : undefined},`}${undefined === input.style ? "" : `"style":${undefined !== input.style ? $string(input.style) : undefined},`}${undefined === input.styleOverrides ? "" : `"styleOverrides":${undefined !== input.styleOverrides ? $so1(input.styleOverrides) : undefined}`}`)}}`;
|
|
236
|
+
const $so1 = input => `{${$tail(`${undefined === input.alignment ? "" : `"alignment":${undefined !== input.alignment ? $string(input.alignment) : undefined}`}`)}}`;
|
|
237
|
+
return $so0(input);
|
|
238
|
+
}; return stringify(assert(input, errorFactory)); };
|
|
239
|
+
export const isEventSubtitleStyle = input => {
|
|
240
|
+
const $io0 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
241
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
242
|
+
};
|
|
243
|
+
export const assertEventSubtitleStyle = (input, errorFactory) => {
|
|
244
|
+
const __is = input => {
|
|
245
|
+
const $io0 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
246
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
247
|
+
};
|
|
248
|
+
if (false === __is(input))
|
|
249
|
+
((input, _path, _exceptionable = true) => {
|
|
250
|
+
const $guard = __typia.createAssert.guard;
|
|
251
|
+
const $ao0 = (input, _path, _exceptionable = true) => undefined === input.alignment || "string" === typeof input.alignment || $guard(_exceptionable, {
|
|
252
|
+
path: _path + ".alignment",
|
|
253
|
+
expected: "(string | undefined)",
|
|
254
|
+
value: input.alignment
|
|
255
|
+
}, errorFactory);
|
|
256
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
257
|
+
path: _path + "",
|
|
258
|
+
expected: "EventSubtitleStyle",
|
|
259
|
+
value: input
|
|
260
|
+
}, errorFactory)) && $ao0(input, _path + "", true) || $guard(true, {
|
|
261
|
+
path: _path + "",
|
|
262
|
+
expected: "EventSubtitleStyle",
|
|
263
|
+
value: input
|
|
264
|
+
}, errorFactory);
|
|
265
|
+
})(input, "$input", true);
|
|
266
|
+
return input;
|
|
267
|
+
};
|
|
268
|
+
export const randomEventSubtitleStyle = generator => {
|
|
269
|
+
const $generator = __typia.createRandom.generator;
|
|
270
|
+
const $pick = __typia.createRandom.pick;
|
|
271
|
+
const $ro0 = (_recursive = false, _depth = 0) => ({
|
|
272
|
+
alignment: $pick([
|
|
273
|
+
() => undefined,
|
|
274
|
+
() => (generator?.customs ?? $generator.customs)?.string?.([]) ?? (generator?.string ?? $generator.string)()
|
|
275
|
+
])()
|
|
276
|
+
});
|
|
277
|
+
return $ro0();
|
|
278
|
+
};
|
|
279
|
+
export const assertGuardEventSubtitleStyle = (input, errorFactory) => {
|
|
280
|
+
const __is = input => {
|
|
281
|
+
const $io0 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
282
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
283
|
+
};
|
|
284
|
+
if (false === __is(input))
|
|
285
|
+
((input, _path, _exceptionable = true) => {
|
|
286
|
+
const $guard = __typia.createAssertGuard.guard;
|
|
287
|
+
const $ao0 = (input, _path, _exceptionable = true) => undefined === input.alignment || "string" === typeof input.alignment || $guard(_exceptionable, {
|
|
288
|
+
path: _path + ".alignment",
|
|
289
|
+
expected: "(string | undefined)",
|
|
290
|
+
value: input.alignment
|
|
291
|
+
}, errorFactory);
|
|
292
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
293
|
+
path: _path + "",
|
|
294
|
+
expected: "EventSubtitleStyle",
|
|
295
|
+
value: input
|
|
296
|
+
}, errorFactory)) && $ao0(input, _path + "", true) || $guard(true, {
|
|
297
|
+
path: _path + "",
|
|
298
|
+
expected: "EventSubtitleStyle",
|
|
299
|
+
value: input
|
|
300
|
+
}, errorFactory);
|
|
301
|
+
})(input, "$input", true);
|
|
302
|
+
};
|
|
303
|
+
export const stringifyEventSubtitleStyle = input => {
|
|
304
|
+
const $string = __typia.json.createStringify.string;
|
|
305
|
+
const $tail = __typia.json.createStringify.tail;
|
|
306
|
+
const $so0 = input => `{${$tail(`${undefined === input.alignment ? "" : `"alignment":${undefined !== input.alignment ? $string(input.alignment) : undefined}`}`)}}`;
|
|
307
|
+
return $so0(input);
|
|
308
|
+
};
|
|
309
|
+
export const assertStringifyEventSubtitleStyle = (input, errorFactory) => { const assert = (input, errorFactory) => {
|
|
310
|
+
const __is = input => {
|
|
311
|
+
const $io0 = input => undefined === input.alignment || "string" === typeof input.alignment;
|
|
312
|
+
return "object" === typeof input && null !== input && false === Array.isArray(input) && $io0(input);
|
|
313
|
+
};
|
|
314
|
+
if (false === __is(input))
|
|
315
|
+
((input, _path, _exceptionable = true) => {
|
|
316
|
+
const $guard = __typia.json.createAssertStringify.guard;
|
|
317
|
+
const $ao0 = (input, _path, _exceptionable = true) => undefined === input.alignment || "string" === typeof input.alignment || $guard(_exceptionable, {
|
|
318
|
+
path: _path + ".alignment",
|
|
319
|
+
expected: "(string | undefined)",
|
|
320
|
+
value: input.alignment
|
|
321
|
+
}, errorFactory);
|
|
322
|
+
return ("object" === typeof input && null !== input && false === Array.isArray(input) || $guard(true, {
|
|
323
|
+
path: _path + "",
|
|
324
|
+
expected: "EventSubtitleStyle",
|
|
325
|
+
value: input
|
|
326
|
+
}, errorFactory)) && $ao0(input, _path + "", true) || $guard(true, {
|
|
327
|
+
path: _path + "",
|
|
328
|
+
expected: "EventSubtitleStyle",
|
|
329
|
+
value: input
|
|
330
|
+
}, errorFactory);
|
|
331
|
+
})(input, "$input", true);
|
|
332
|
+
return input;
|
|
160
333
|
}; const stringify = input => {
|
|
161
334
|
const $string = __typia.json.createAssertStringify.string;
|
|
162
335
|
const $tail = __typia.json.createAssertStringify.tail;
|
|
163
|
-
const $so0 = input => `{${$tail(`${undefined === input.
|
|
336
|
+
const $so0 = input => `{${$tail(`${undefined === input.alignment ? "" : `"alignment":${undefined !== input.alignment ? $string(input.alignment) : undefined}`}`)}}`;
|
|
164
337
|
return $so0(input);
|
|
165
338
|
}; return stringify(assert(input, errorFactory)); };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { type AssertionGuard as __AssertionGuard } from "typia";
|
|
2
|
+
import { NxtError } from '../common/error.js';
|
|
3
|
+
export interface FileDomainRecords {
|
|
4
|
+
":file.replicate": FileReplicateRecord;
|
|
5
|
+
}
|
|
6
|
+
export interface FileReplicateRecord {
|
|
7
|
+
replicas: string[];
|
|
8
|
+
error: NxtError | null;
|
|
9
|
+
}
|
|
10
|
+
export declare const isFileReplicateRecord: (input: unknown) => input is FileReplicateRecord;
|
|
11
|
+
export declare const assertFileReplicateRecord: (input: unknown) => FileReplicateRecord;
|
|
12
|
+
export declare const randomFileReplicateRecord: () => FileReplicateRecord;
|
|
13
|
+
export declare const assertGuardFileReplicateRecord: __AssertionGuard<FileReplicateRecord>;
|
|
14
|
+
export declare const stringifyFileReplicateRecord: (input: FileReplicateRecord) => string;
|
|
15
|
+
export declare const assertStringifyFileReplicateRecord: (input: unknown) => string;
|
|
16
|
+
export interface FileReplica {
|
|
17
|
+
name: string;
|
|
18
|
+
status: "ok" | "error";
|
|
19
|
+
error: NxtError | null;
|
|
20
|
+
}
|
|
21
|
+
export declare const isFileReplica: (input: unknown) => input is FileReplica;
|
|
22
|
+
export declare const assertFileReplica: (input: unknown) => FileReplica;
|
|
23
|
+
export declare const randomFileReplica: () => FileReplica;
|
|
24
|
+
export declare const assertGuardFileReplica: __AssertionGuard<FileReplica>;
|
|
25
|
+
export declare const stringifyFileReplica: (input: FileReplica) => string;
|
|
26
|
+
export declare const assertStringifyFileReplica: (input: unknown) => string;
|