@puq/type 0.0.15 → 0.0.23
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/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -1
- package/dist/lib/common/package-json.d.ts +72 -0
- package/dist/lib/common/package-json.d.ts.map +1 -0
- package/dist/lib/common/package-json.js +3 -0
- package/dist/lib/common/package-json.js.map +1 -0
- package/dist/lib/dto/count-result.d.ts +4 -0
- package/dist/lib/dto/count-result.d.ts.map +1 -0
- package/dist/lib/dto/count-result.js +3 -0
- package/dist/lib/dto/count-result.js.map +1 -0
- package/dist/lib/dto/delete-result.d.ts +4 -0
- package/dist/lib/dto/delete-result.d.ts.map +1 -0
- package/dist/lib/dto/delete-result.js +3 -0
- package/dist/lib/dto/delete-result.js.map +1 -0
- package/dist/lib/dto/relation-param.d.ts +10 -0
- package/dist/lib/dto/relation-param.d.ts.map +1 -0
- package/dist/lib/dto/relation-param.js +3 -0
- package/dist/lib/dto/relation-param.js.map +1 -0
- package/dist/lib/dto/update-result.d.ts +4 -0
- package/dist/lib/dto/update-result.d.ts.map +1 -0
- package/dist/lib/dto/update-result.js +3 -0
- package/dist/lib/dto/update-result.js.map +1 -0
- package/dist/lib/property/array.d.ts +4 -1
- package/dist/lib/property/array.d.ts.map +1 -1
- package/dist/lib/property/array.js.map +1 -1
- package/dist/lib/property/big-integer.d.ts +1 -1
- package/dist/lib/property/big-integer.js.map +1 -1
- package/dist/lib/property/common-number.d.ts +2 -2
- package/dist/lib/property/common-number.d.ts.map +1 -1
- package/dist/lib/property/common-number.js.map +1 -1
- package/dist/lib/property/common.d.ts +20 -2
- package/dist/lib/property/common.d.ts.map +1 -1
- package/dist/lib/property/common.js.map +1 -1
- package/dist/lib/property/database-type.d.ts +6 -0
- package/dist/lib/property/database-type.d.ts.map +1 -0
- package/dist/lib/property/database-type.js +6 -0
- package/dist/lib/property/database-type.js.map +1 -0
- package/dist/lib/property/date.d.ts +1 -1
- package/dist/lib/property/date.d.ts.map +1 -1
- package/dist/lib/property/date.js.map +1 -1
- package/dist/lib/property/string-format.d.ts +1 -1
- package/dist/lib/property/string-format.d.ts.map +1 -1
- package/dist/lib/property/string-format.js.map +1 -1
- package/dist/lib/property/string.d.ts +4 -4
- package/dist/lib/property/string.d.ts.map +1 -1
- package/dist/lib/property/string.js.map +1 -1
- package/dist/lib/utils/keys.d.ts +4 -1
- package/dist/lib/utils/keys.d.ts.map +1 -1
- package/dist/lib/utils/keys.js +3 -1
- package/dist/lib/utils/keys.js.map +1 -1
- package/dist/lib/utils/type.d.ts.map +1 -1
- package/dist/lib/utils/type.js +1 -0
- package/dist/lib/utils/type.js.map +1 -1
- package/package.json +1 -2
package/dist/index.d.ts
CHANGED
@@ -1,10 +1,17 @@
|
|
1
|
+
export * from './lib/common/package-json.js';
|
2
|
+
export * from './lib/dto/count-result.js';
|
3
|
+
export * from './lib/dto/delete-result.js';
|
4
|
+
export * from './lib/dto/relation-param.js';
|
5
|
+
export * from './lib/dto/update-result.js';
|
1
6
|
export * from './lib/model/base.js';
|
2
7
|
export * from './lib/model/id.js';
|
3
8
|
export * from './lib/model/timestamp.js';
|
4
9
|
export * from './lib/property/array.js';
|
5
10
|
export * from './lib/property/big-integer.js';
|
6
11
|
export * from './lib/property/boolean.js';
|
12
|
+
export * from './lib/property/common-number.js';
|
7
13
|
export * from './lib/property/common.js';
|
14
|
+
export * from './lib/property/database-type.js';
|
8
15
|
export * from './lib/property/date.js';
|
9
16
|
export * from './lib/property/integer-format.js';
|
10
17
|
export * from './lib/property/integer.js';
|
package/dist/index.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,0BAA0B,CAAC;AACzC,cAAc,yBA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CAAC;AACtC,cAAc,qBAAqB,CAAC;AACpC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,qBAAqB,CAAC"}
|
package/dist/index.js
CHANGED
@@ -1,11 +1,18 @@
|
|
1
1
|
// @index('./**/*.ts', f => `export * from '${f.path}.js'`)
|
2
|
+
export * from './lib/common/package-json.js';
|
3
|
+
export * from './lib/dto/count-result.js';
|
4
|
+
export * from './lib/dto/delete-result.js';
|
5
|
+
export * from './lib/dto/relation-param.js';
|
6
|
+
export * from './lib/dto/update-result.js';
|
2
7
|
export * from './lib/model/base.js';
|
3
8
|
export * from './lib/model/id.js';
|
4
9
|
export * from './lib/model/timestamp.js';
|
5
10
|
export * from './lib/property/array.js';
|
6
11
|
export * from './lib/property/big-integer.js';
|
7
12
|
export * from './lib/property/boolean.js';
|
13
|
+
export * from './lib/property/common-number.js';
|
8
14
|
export * from './lib/property/common.js';
|
15
|
+
export * from './lib/property/database-type.js';
|
9
16
|
export * from './lib/property/date.js';
|
10
17
|
export * from './lib/property/integer-format.js';
|
11
18
|
export * from './lib/property/integer.js';
|
package/dist/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// @index('./**/*.ts', f => `export * from '${f.path}.js'`)\nexport * from './lib/model/base.js';\nexport * from './lib/model/id.js';\nexport * from './lib/model/timestamp.js';\nexport * from './lib/property/array.js';\nexport * from './lib/property/big-integer.js';\nexport * from './lib/property/boolean.js';\nexport * from './lib/property/common.js';\nexport * from './lib/property/date.js';\nexport * from './lib/property/integer-format.js';\nexport * from './lib/property/integer.js';\nexport * from './lib/property/number-format.js';\nexport * from './lib/property/number.js';\nexport * from './lib/property/object.js';\nexport * from './lib/property/property-type.js';\nexport * from './lib/property/property.js';\nexport * from './lib/property/string-format.js';\nexport * from './lib/property/string.js';\nexport * from './lib/utils/key-of.js';\nexport * from './lib/utils/keys.js';\nexport * from './lib/utils/pick-optional.js';\nexport * from './lib/utils/pick-required.js';\nexport * from './lib/utils/type.js';\n"],"names":[],"rangeMappings":"
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// @index('./**/*.ts', f => `export * from '${f.path}.js'`)\nexport * from './lib/common/package-json.js';\nexport * from './lib/dto/count-result.js';\nexport * from './lib/dto/delete-result.js';\nexport * from './lib/dto/relation-param.js';\nexport * from './lib/dto/update-result.js';\nexport * from './lib/model/base.js';\nexport * from './lib/model/id.js';\nexport * from './lib/model/timestamp.js';\nexport * from './lib/property/array.js';\nexport * from './lib/property/big-integer.js';\nexport * from './lib/property/boolean.js';\nexport * from './lib/property/common-number.js';\nexport * from './lib/property/common.js';\nexport * from './lib/property/database-type.js';\nexport * from './lib/property/date.js';\nexport * from './lib/property/integer-format.js';\nexport * from './lib/property/integer.js';\nexport * from './lib/property/number-format.js';\nexport * from './lib/property/number.js';\nexport * from './lib/property/object.js';\nexport * from './lib/property/property-type.js';\nexport * from './lib/property/property.js';\nexport * from './lib/property/string-format.js';\nexport * from './lib/property/string.js';\nexport * from './lib/utils/key-of.js';\nexport * from './lib/utils/keys.js';\nexport * from './lib/utils/pick-optional.js';\nexport * from './lib/utils/pick-required.js';\nexport * from './lib/utils/type.js';\n"],"names":[],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,2DAA2D;AAC3D,cAAc,+BAA+B;AAC7C,cAAc,4BAA4B;AAC1C,cAAc,6BAA6B;AAC3C,cAAc,8BAA8B;AAC5C,cAAc,6BAA6B;AAC3C,cAAc,sBAAsB;AACpC,cAAc,oBAAoB;AAClC,cAAc,2BAA2B;AACzC,cAAc,0BAA0B;AACxC,cAAc,gCAAgC;AAC9C,cAAc,4BAA4B;AAC1C,cAAc,kCAAkC;AAChD,cAAc,2BAA2B;AACzC,cAAc,kCAAkC;AAChD,cAAc,yBAAyB;AACvC,cAAc,mCAAmC;AACjD,cAAc,4BAA4B;AAC1C,cAAc,kCAAkC;AAChD,cAAc,2BAA2B;AACzC,cAAc,2BAA2B;AACzC,cAAc,kCAAkC;AAChD,cAAc,6BAA6B;AAC3C,cAAc,kCAAkC;AAChD,cAAc,2BAA2B;AACzC,cAAc,wBAAwB;AACtC,cAAc,sBAAsB;AACpC,cAAc,+BAA+B;AAC7C,cAAc,+BAA+B;AAC7C,cAAc,sBAAsB"}
|
@@ -0,0 +1,72 @@
|
|
1
|
+
export type PackageJSON = {
|
2
|
+
name: string;
|
3
|
+
version: string;
|
4
|
+
license: string;
|
5
|
+
description: string;
|
6
|
+
keywords: string[];
|
7
|
+
homepage: string;
|
8
|
+
categories: string[];
|
9
|
+
funding: string[];
|
10
|
+
icon: string;
|
11
|
+
type: string;
|
12
|
+
main: string;
|
13
|
+
module: string;
|
14
|
+
types: string;
|
15
|
+
author: {
|
16
|
+
email: string;
|
17
|
+
name: string;
|
18
|
+
url: string;
|
19
|
+
};
|
20
|
+
repository: {
|
21
|
+
directory: string;
|
22
|
+
url: string;
|
23
|
+
type: string;
|
24
|
+
};
|
25
|
+
bugs: {
|
26
|
+
email: string;
|
27
|
+
url: string;
|
28
|
+
};
|
29
|
+
publishConfig: {
|
30
|
+
access: string;
|
31
|
+
tag: string;
|
32
|
+
};
|
33
|
+
files: string[];
|
34
|
+
contributors: [
|
35
|
+
{
|
36
|
+
email: string;
|
37
|
+
name: string;
|
38
|
+
url: string;
|
39
|
+
}
|
40
|
+
];
|
41
|
+
exports: {
|
42
|
+
'./package.json': string;
|
43
|
+
'.': {
|
44
|
+
types: string;
|
45
|
+
import: string;
|
46
|
+
default: string;
|
47
|
+
};
|
48
|
+
};
|
49
|
+
nx: {
|
50
|
+
sourceRoot: string;
|
51
|
+
targets: {
|
52
|
+
build: {
|
53
|
+
executor: string;
|
54
|
+
outputs: string[];
|
55
|
+
options: {
|
56
|
+
outputPath: string;
|
57
|
+
main: string;
|
58
|
+
tsConfig: string;
|
59
|
+
skipTypeCheck: true;
|
60
|
+
stripLeadingPaths: true;
|
61
|
+
};
|
62
|
+
};
|
63
|
+
doc: {
|
64
|
+
command: string;
|
65
|
+
};
|
66
|
+
};
|
67
|
+
};
|
68
|
+
dependencies: Record<string, string>;
|
69
|
+
devDependencies: Record<string, string>;
|
70
|
+
peerDependencies: Record<string, string>;
|
71
|
+
};
|
72
|
+
//# sourceMappingURL=package-json.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"package-json.d.ts","sourceRoot":"","sources":["../../../src/lib/common/package-json.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE;QACN,KAAK,EAAE,MAAM,CAAC;QACd,IAAI,EAAE,MAAM,CAAC;QACb,GAAG,EAAE,MAAM,CAAC;KACb,CAAC;IACF,UAAU,EAAE;QACV,SAAS,EAAE,MAAM,CAAC;QAClB,GAAG,EAAE,MAAM,CAAC;QACZ,IAAI,EAAE,MAAM,CAAC;KACd,CAAC;IACF,IAAI,EAAE;QACJ,KAAK,EAAE,MAAM,CAAC;QACd,GAAG,EAAE,MAAM,CAAC;KACb,CAAC;IACF,aAAa,EAAE;QACb,MAAM,EAAE,MAAM,CAAC;QACf,GAAG,EAAE,MAAM,CAAC;KACb,CAAC;IACF,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,YAAY,EAAE;QACZ;YACE,KAAK,EAAE,MAAM,CAAC;YACd,IAAI,EAAE,MAAM,CAAC;YACb,GAAG,EAAE,MAAM,CAAC;SACb;KACF,CAAC;IACF,OAAO,EAAE;QACP,gBAAgB,EAAE,MAAM,CAAC;QACzB,GAAG,EAAE;YACH,KAAK,EAAE,MAAM,CAAC;YACd,MAAM,EAAE,MAAM,CAAC;YACf,OAAO,EAAE,MAAM,CAAC;SACjB,CAAC;KACH,CAAC;IACF,EAAE,EAAE;QACF,UAAU,EAAE,MAAM,CAAC;QACnB,OAAO,EAAE;YACP,KAAK,EAAE;gBACL,QAAQ,EAAE,MAAM,CAAC;gBACjB,OAAO,EAAE,MAAM,EAAE,CAAC;gBAClB,OAAO,EAAE;oBACP,UAAU,EAAE,MAAM,CAAC;oBACnB,IAAI,EAAE,MAAM,CAAC;oBACb,QAAQ,EAAE,MAAM,CAAC;oBACjB,aAAa,EAAE,IAAI,CAAC;oBACpB,iBAAiB,EAAE,IAAI,CAAC;iBACzB,CAAC;aACH,CAAC;YACF,GAAG,EAAE;gBACH,OAAO,EAAE,MAAM,CAAC;aACjB,CAAC;SACH,CAAC;KACH,CAAC;IACF,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACrC,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACxC,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC1C,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/lib/common/package-json.ts"],"sourcesContent":["export type PackageJSON = {\r\n name: string;\r\n version: string;\r\n license: string;\r\n description: string;\r\n keywords: string[];\r\n homepage: string;\r\n categories: string[];\r\n funding: string[];\r\n icon: string;\r\n type: string;\r\n main: string;\r\n module: string;\r\n types: string;\r\n author: {\r\n email: string;\r\n name: string;\r\n url: string;\r\n };\r\n repository: {\r\n directory: string;\r\n url: string;\r\n type: string;\r\n };\r\n bugs: {\r\n email: string;\r\n url: string;\r\n };\r\n publishConfig: {\r\n access: string;\r\n tag: string;\r\n };\r\n files: string[];\r\n contributors: [\r\n {\r\n email: string;\r\n name: string;\r\n url: string;\r\n }\r\n ];\r\n exports: {\r\n './package.json': string;\r\n '.': {\r\n types: string;\r\n import: string;\r\n default: string;\r\n };\r\n };\r\n nx: {\r\n sourceRoot: string;\r\n targets: {\r\n build: {\r\n executor: string;\r\n outputs: string[];\r\n options: {\r\n outputPath: string;\r\n main: string;\r\n tsConfig: string;\r\n skipTypeCheck: true;\r\n stripLeadingPaths: true;\r\n };\r\n };\r\n doc: {\r\n command: string;\r\n };\r\n };\r\n };\r\n dependencies: Record<string, string>;\r\n devDependencies: Record<string, string>;\r\n peerDependencies: Record<string, string>;\r\n};\r\n"],"names":[],"rangeMappings":"","mappings":"AAAA,WAsEE"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"count-result.d.ts","sourceRoot":"","sources":["../../../src/lib/dto/count-result.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/lib/dto/count-result.ts"],"sourcesContent":["export type CountResult = {\r\n count: number;\r\n};\r\n"],"names":[],"rangeMappings":"","mappings":"AAAA,WAEE"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"delete-result.d.ts","sourceRoot":"","sources":["../../../src/lib/dto/delete-result.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG;IACzB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/lib/dto/delete-result.ts"],"sourcesContent":["export type DeleteResult = {\r\n affected: number;\r\n};\r\n"],"names":[],"rangeMappings":"","mappings":"AAAA,WAEE"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"relation-param.d.ts","sourceRoot":"","sources":["../../../src/lib/dto/relation-param.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,aAAa,GAAG;IAC1B,GAAG,EAAE,MAAM,CAAC;IACZ,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;CACZ,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;CACZ,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/lib/dto/relation-param.ts"],"sourcesContent":["export type RelationParam = {\r\n rid: number;\r\n rn: string;\r\n id: number;\r\n};\r\n\r\nexport type UnsetRelationParam = {\r\n id: number;\r\n rn: string;\r\n};\r\n"],"names":[],"rangeMappings":"","mappings":"AAMA,WAGE"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"update-result.d.ts","sourceRoot":"","sources":["../../../src/lib/dto/update-result.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG;IACzB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/lib/dto/update-result.ts"],"sourcesContent":["export type UpdateResult = {\r\n affected: number;\r\n};\r\n"],"names":[],"rangeMappings":"","mappings":"AAAA,WAEE"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"array.d.ts","sourceRoot":"","sources":["../../../src/lib/property/array.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI;IAC9B,IAAI,EAAE,OAAO,CAAC;
|
1
|
+
{"version":3,"file":"array.d.ts","sourceRoot":"","sources":["../../../src/lib/property/array.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI;IAC9B,IAAI,EAAE,OAAO,CAAC;IAEd;;OAEG;IACH,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;IAEnB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI,QAAQ,CACpC,aAAa,CAAC,GAAG,EAAE,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CACzC,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/property/array.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\n\r\nexport type __ArrayOptions<P> = {\r\n type: 'array';\r\n items: P
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/array.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\n\r\nexport type __ArrayOptions<P> = {\r\n type: 'array';\r\n\r\n /**\r\n * Items options\r\n */\r\n items: Readonly<P>;\r\n\r\n /**\r\n * Maximumm allowed size of the array\r\n */\r\n minSize?: number;\r\n\r\n /**\r\n * Minimum allowed size of the array\r\n */\r\n maxSize?: number;\r\n\r\n /**\r\n * Check the array has unique items\r\n */\r\n uniqueItems?: boolean;\r\n};\r\n\r\nexport type ArrayOptions<P> = Readonly<\r\n CommonOptions<any[]> & __ArrayOptions<P>\r\n>;\r\n"],"names":[],"rangeMappings":"","mappings":"AA0BA,WAEE"}
|
@@ -2,5 +2,5 @@ import { CommonOptions } from './common.js';
|
|
2
2
|
export type __BigIntegerOptions = {
|
3
3
|
type: 'bigint';
|
4
4
|
};
|
5
|
-
export type BigIntegerOptions = Readonly<CommonOptions<
|
5
|
+
export type BigIntegerOptions = Readonly<CommonOptions<bigint> & __BigIntegerOptions>;
|
6
6
|
//# sourceMappingURL=big-integer.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/property/big-integer.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\n\r\nexport type __BigIntegerOptions = {\r\n type: 'bigint';\r\n};\r\n\r\nexport type BigIntegerOptions = Readonly<\r\n CommonOptions<
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/big-integer.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\n\r\nexport type __BigIntegerOptions = {\r\n type: 'bigint';\r\n};\r\n\r\nexport type BigIntegerOptions = Readonly<\r\n CommonOptions<bigint> & __BigIntegerOptions\r\n>;\r\n"],"names":[],"rangeMappings":"","mappings":"AAMA,WAEE"}
|
@@ -10,11 +10,11 @@ export type CommonNumberOptions = {
|
|
10
10
|
/**
|
11
11
|
* Allowed numbers
|
12
12
|
*/
|
13
|
-
enum?: number[]
|
13
|
+
enum?: Readonly<number[] | Record<string, unknown>>;
|
14
14
|
/**
|
15
15
|
* Not allowed numbers
|
16
16
|
*/
|
17
|
-
notIn?: number[]
|
17
|
+
notIn?: Readonly<number[]>;
|
18
18
|
/**
|
19
19
|
* Check the value is more than the property's value
|
20
20
|
*/
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"common-number.d.ts","sourceRoot":"","sources":["../../../src/lib/property/common-number.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,mBAAmB,GAAG;IAChC;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;
|
1
|
+
{"version":3,"file":"common-number.d.ts","sourceRoot":"","sources":["../../../src/lib/property/common-number.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,mBAAmB,GAAG;IAChC;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,IAAI,CAAC,EAAE,QAAQ,CAAC,MAAM,EAAE,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IAEpD;;OAEG;IACH,KAAK,CAAC,EAAE,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC;IAE3B;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/property/common-number.ts"],"sourcesContent":["export type CommonNumberOptions = {\r\n /**\r\n * Minimum allowed number\r\n */\r\n minimum?: number;\r\n\r\n /**\r\n * Maximum allowed number\r\n */\r\n maximum?: number;\r\n\r\n /**\r\n * Allowed numbers\r\n */\r\n enum?: number[]
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/common-number.ts"],"sourcesContent":["export type CommonNumberOptions = {\r\n /**\r\n * Minimum allowed number\r\n */\r\n minimum?: number;\r\n\r\n /**\r\n * Maximum allowed number\r\n */\r\n maximum?: number;\r\n\r\n /**\r\n * Allowed numbers\r\n */\r\n enum?: Readonly<number[] | Record<string, unknown>>;\r\n\r\n /**\r\n * Not allowed numbers\r\n */\r\n notIn?: Readonly<number[]>;\r\n\r\n /**\r\n * Check the value is more than the property's value\r\n */\r\n moreThanProperty?: string;\r\n\r\n /**\r\n * Check the value is less than the property's value\r\n */\r\n lessThanProperty?: string;\r\n};\r\n"],"names":[],"rangeMappings":"","mappings":"AAAA,WA8BE"}
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import { DatabaseType } from './database-type.js';
|
1
2
|
import { PropertyType } from './property-type.js';
|
2
3
|
/**
|
3
4
|
* Common property options
|
@@ -7,6 +8,7 @@ export type CommonOptions<T> = {
|
|
7
8
|
* Property type
|
8
9
|
*/
|
9
10
|
type: PropertyType;
|
11
|
+
name?: string;
|
10
12
|
/**
|
11
13
|
* Check the value is not undefined
|
12
14
|
*/
|
@@ -15,6 +17,10 @@ export type CommonOptions<T> = {
|
|
15
17
|
* Check the property is unique or not
|
16
18
|
*/
|
17
19
|
unique?: boolean;
|
20
|
+
/**
|
21
|
+
*
|
22
|
+
*/
|
23
|
+
readonly?: boolean;
|
18
24
|
/**
|
19
25
|
* Property description
|
20
26
|
*/
|
@@ -34,7 +40,7 @@ export type CommonOptions<T> = {
|
|
34
40
|
/**
|
35
41
|
* Example values
|
36
42
|
*/
|
37
|
-
examples?: T[]
|
43
|
+
examples?: Readonly<T[]>;
|
38
44
|
/**
|
39
45
|
* If ture, the string values are accepted and transformed
|
40
46
|
*/
|
@@ -46,7 +52,7 @@ export type CommonOptions<T> = {
|
|
46
52
|
/**
|
47
53
|
* Check the value is not equal to property
|
48
54
|
*/
|
49
|
-
|
55
|
+
notEqualToProperty?: string;
|
50
56
|
/**
|
51
57
|
* If set, the value is ignored unless the target property is set
|
52
58
|
*/
|
@@ -55,5 +61,17 @@ export type CommonOptions<T> = {
|
|
55
61
|
* If set, the property only exist if the provided property does not
|
56
62
|
*/
|
57
63
|
notWithProperty?: string;
|
64
|
+
/**
|
65
|
+
* Hash the data
|
66
|
+
*/
|
67
|
+
hash?: boolean;
|
68
|
+
/**
|
69
|
+
* Encrypt the data
|
70
|
+
*/
|
71
|
+
encrypt?: boolean;
|
72
|
+
/**
|
73
|
+
* Allows us to pick the right column type for the data
|
74
|
+
*/
|
75
|
+
databaseType?: DatabaseType;
|
58
76
|
};
|
59
77
|
//# sourceMappingURL=common.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../../src/lib/property/common.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD;;GAEG;AACH,MAAM,MAAM,aAAa,CAAC,CAAC,IAAI;IAC7B;;OAEG;IACH,IAAI,EAAE,YAAY,CAAC;IAEnB;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAE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AAC;IAE1B;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,CAAC;IAEf;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;OAEG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;CAC7B,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/property/common.ts"],"sourcesContent":["import { PropertyType } from './property-type.js';\r\n\r\n/**\r\n * Common property options\r\n */\r\nexport type CommonOptions<T> = {\r\n /**\r\n * Property type\r\n */\r\n type: PropertyType;\r\n\r\n /**\r\n * Check the value is not undefined\r\n */\r\n required?: boolean;\r\n\r\n /**\r\n * Check the property is unique or not\r\n */\r\n unique?: boolean;\r\n\r\n /**\r\n * Property description\r\n */\r\n description?: string;\r\n\r\n /**\r\n * If set false, the property is excluded.\r\n */\r\n expose?: boolean;\r\n\r\n /**\r\n * Default value in case the input is undefined\r\n */\r\n default?: T;\r\n\r\n /**\r\n * Example value\r\n */\r\n example?: T;\r\n\r\n /**\r\n * Example values\r\n */\r\n examples?: T[]
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/common.ts"],"sourcesContent":["import { DatabaseType } from './database-type.js';\r\nimport { PropertyType } from './property-type.js';\r\n\r\n/**\r\n * Common property options\r\n */\r\nexport type CommonOptions<T> = {\r\n /**\r\n * Property type\r\n */\r\n type: PropertyType;\r\n\r\n name?: string;\r\n\r\n /**\r\n * Check the value is not undefined\r\n */\r\n required?: boolean;\r\n\r\n /**\r\n * Check the property is unique or not\r\n */\r\n unique?: boolean;\r\n\r\n /**\r\n *\r\n */\r\n readonly?: boolean;\r\n\r\n /**\r\n * Property description\r\n */\r\n description?: string;\r\n\r\n /**\r\n * If set false, the property is excluded.\r\n */\r\n expose?: boolean;\r\n\r\n /**\r\n * Default value in case the input is undefined\r\n */\r\n default?: T;\r\n\r\n /**\r\n * Example value\r\n */\r\n example?: T;\r\n\r\n /**\r\n * Example values\r\n */\r\n examples?: Readonly<T[]>;\r\n\r\n /**\r\n * If ture, the string values are accepted and transformed\r\n */\r\n acceptString?: boolean;\r\n\r\n /**\r\n * Check the value is equal to property\r\n */\r\n equalToProperty?: string;\r\n\r\n /**\r\n * Check the value is not equal to property\r\n */\r\n notEqualToProperty?: string;\r\n\r\n /**\r\n * If set, the value is ignored unless the target property is set\r\n */\r\n dependOnProperty?: string;\r\n\r\n /**\r\n * If set, the property only exist if the provided property does not\r\n */\r\n notWithProperty?: string;\r\n\r\n /**\r\n * Hash the data\r\n */\r\n hash?: boolean;\r\n\r\n /**\r\n * Encrypt the data\r\n */\r\n encrypt?: boolean;\r\n\r\n /**\r\n * Allows us to pick the right column type for the data\r\n */\r\n databaseType?: DatabaseType;\r\n};\r\n"],"names":[],"rangeMappings":";;","mappings":"AAGA;;CAEC,GACD,WAuFE"}
|
@@ -0,0 +1,6 @@
|
|
1
|
+
/**
|
2
|
+
* Represents the database driver types supported by TypeORM.
|
3
|
+
* Used in the `type` field of a TypeORM connection configuration.
|
4
|
+
*/
|
5
|
+
export type DatabaseType = 'postgres' | 'mysql' | 'mariadb' | 'sqlite' | 'better-sqlite3' | 'oracle' | 'mssql' | 'cockroachdb' | 'mongodb' | 'sqljs' | 'cordova' | 'react-native' | 'expo' | 'aurora-data-api' | 'aurora-data-api-pg' | 'sap' | 'spanner';
|
6
|
+
//# sourceMappingURL=database-type.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"database-type.d.ts","sourceRoot":"","sources":["../../../src/lib/property/database-type.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,MAAM,YAAY,GAEpB,UAAU,GACV,OAAO,GACP,SAAS,GACT,QAAQ,GACR,gBAAgB,GAChB,QAAQ,GACR,OAAO,GACP,aAAa,GAGb,SAAS,GAGT,OAAO,GACP,SAAS,GACT,cAAc,GACd,MAAM,GACN,iBAAiB,GACjB,oBAAoB,GACpB,KAAK,GACL,SAAS,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/database-type.ts"],"sourcesContent":["/**\r\n * Represents the database driver types supported by TypeORM.\r\n * Used in the `type` field of a TypeORM connection configuration.\r\n */\r\nexport type DatabaseType =\r\n // Relational Databases\r\n | 'postgres' // PostgreSQL using `pg`\r\n | 'mysql' // MySQL using `mysql` or `mysql2`\r\n | 'mariadb' // MariaDB using `mysql` or `mysql2`\r\n | 'sqlite' // SQLite using `sqlite3`\r\n | 'better-sqlite3' // SQLite using `better-sqlite3`\r\n | 'oracle' // Oracle using `oracledb`\r\n | 'mssql' // Microsoft SQL Server using `mssql`\r\n | 'cockroachdb' // CockroachDB using `pg` (PostgreSQL-compatible)\r\n\r\n // NoSQL Databases\r\n | 'mongodb' // MongoDB using `mongodb`\r\n\r\n // Other/Experimental\r\n | 'sqljs' // SQL.js (SQLite in JavaScript)\r\n | 'cordova' // Cordova SQLite plugin\r\n | 'react-native' // React Native SQLite plugin\r\n | 'expo' // Expo SQLite plugin\r\n | 'aurora-data-api' // AWS Aurora Data API (MySQL/PostgreSQL)\r\n | 'aurora-data-api-pg' // AWS Aurora Data API (PostgreSQL-specific)\r\n | 'sap' // SAP HANA using `@sap/hana-client`\r\n | 'spanner'; // Google Cloud Spanner using `@google-cloud/spanner`\r\n"],"names":[],"rangeMappings":";;;","mappings":"AAAA;;;CAGC,GACD,WAsBc,CAAC,qDAAqD"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"date.d.ts","sourceRoot":"","sources":["../../../src/lib/property/date.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,OAAO,CAAC,EAAE,IAAI,CAAC;IAEf;;OAEG;IACH,OAAO,CAAC,EAAE,IAAI,CAAC;IAEf;;OAEG;IACH,MAAM,C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C;IAE3B;;OAEG;IACH,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAE/B;;OAEG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG,QAAQ,CAAC,aAAa,CAAC,MAAM,CAAC,GAAG,aAAa,CAAC,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/property/date.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\n\r\nexport type __DateOptions = {\r\n type: 'date';\r\n\r\n /**\r\n * Check the date is after the date\r\n */\r\n minDate?: Date;\r\n\r\n /**\r\n * Check the date is before the date\r\n */\r\n maxDate?: Date;\r\n\r\n /**\r\n * Check the date is future date\r\n */\r\n future?: boolean;\r\n\r\n /**\r\n * Check the date is past date\r\n */\r\n past?: boolean;\r\n\r\n /**\r\n * Check the property comes before the target property\r\n */\r\n beforeProperty?: string;\r\n\r\n /**\r\n * Check the property comes after the target property\r\n */\r\n afterProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are in the same month\r\n */\r\n sameMonthAsProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are in the same year\r\n */\r\n sameWeekAsProperty?: string;\r\n\r\n /**\r\n * Check the date's year value is the same as the named property's year value\r\n */\r\n sameYearAsProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are on the same day\r\n */\r\n sameDayAsProperty?: string;\r\n\r\n /**\r\n * Check the property and the target property are weekend or week day\r\n */\r\n sameDayTypeAsProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are in the same hour\r\n */\r\n sameHourAsProperty?: string;\r\n};\r\n\r\nexport type DateOptions = Readonly<CommonOptions<
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/date.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\n\r\nexport type __DateOptions = {\r\n type: 'date';\r\n\r\n /**\r\n * Check the date is after the date\r\n */\r\n minDate?: Date;\r\n\r\n /**\r\n * Check the date is before the date\r\n */\r\n maxDate?: Date;\r\n\r\n /**\r\n * Check the date is future date\r\n */\r\n future?: boolean;\r\n\r\n /**\r\n * Check the date is past date\r\n */\r\n past?: boolean;\r\n\r\n /**\r\n * Check the property comes before the target property\r\n */\r\n beforeProperty?: string;\r\n\r\n /**\r\n * Check the property comes after the target property\r\n */\r\n afterProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are in the same month\r\n */\r\n sameMonthAsProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are in the same year\r\n */\r\n sameWeekAsProperty?: string;\r\n\r\n /**\r\n * Check the date's year value is the same as the named property's year value\r\n */\r\n sameYearAsProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are on the same day\r\n */\r\n sameDayAsProperty?: string;\r\n\r\n /**\r\n * Check the property and the target property are weekend or week day\r\n */\r\n sameDayTypeAsProperty?: string;\r\n\r\n /**\r\n * Check the property and targer property are in the same hour\r\n */\r\n sameHourAsProperty?: string;\r\n};\r\n\r\nexport type DateOptions = Readonly<CommonOptions<string> & __DateOptions>;\r\n"],"names":[],"rangeMappings":"","mappings":"AAkEA,WAA0E"}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
export type StringFormat = 'email' | 'phone' | 'password' | '
|
1
|
+
export type StringFormat = 'alpha' | 'alphanumeric' | 'ascii' | 'base32' | 'base58' | 'base64' | 'bic' | 'boolean-string' | 'byte-length' | 'credit-card' | 'currency' | 'data-uri' | 'date-string' | 'decimal' | 'ean' | 'email' | 'ethereum-address' | 'firebase-push-id' | 'hash' | 'hex-color' | 'hsl' | 'iban' | 'identity-card' | 'imei' | 'ip-range' | 'ip' | 'isbn' | 'isin' | 'iso31661-alpha2' | 'iso31661-alpha3' | 'iso4217' | 'iso8601' | 'isrc' | 'issn' | 'json' | 'jwt' | 'lat-long' | 'locale' | 'mac-address' | 'magnet-uri' | 'mime-type' | 'mobile-phone' | 'mongo-id' | 'number-string' | 'octal' | 'passport-number' | 'phone-number' | 'port' | 'postal-code' | 'rgb-color' | 'sem-ver' | 'slug' | 'strong-password' | 'time-zone' | 'url' | 'uuid' | 'variable-width';
|
2
2
|
//# sourceMappingURL=string-format.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"string-format.d.ts","sourceRoot":"","sources":["../../../src/lib/property/string-format.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GACpB,OAAO,GACP,OAAO,GACP,UAAU,GACV,MAAM,GACN,KAAK,GACL,KAAK,CAAC"}
|
1
|
+
{"version":3,"file":"string-format.d.ts","sourceRoot":"","sources":["../../../src/lib/property/string-format.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GACpB,OAAO,GACP,cAAc,GACd,OAAO,GACP,QAAQ,GACR,QAAQ,GACR,QAAQ,GACR,KAAK,GACL,gBAAgB,GAChB,aAAa,GACb,aAAa,GACb,UAAU,GACV,UAAU,GACV,aAAa,GACb,SAAS,GACT,KAAK,GACL,OAAO,GACP,kBAAkB,GAClB,kBAAkB,GAClB,MAAM,GACN,WAAW,GACX,KAAK,GACL,MAAM,GACN,eAAe,GACf,MAAM,GACN,UAAU,GACV,IAAI,GACJ,MAAM,GACN,MAAM,GACN,iBAAiB,GACjB,iBAAiB,GACjB,SAAS,GACT,SAAS,GACT,MAAM,GACN,MAAM,GACN,MAAM,GACN,KAAK,GACL,UAAU,GACV,QAAQ,GACR,aAAa,GACb,YAAY,GACZ,WAAW,GACX,cAAc,GACd,UAAU,GACV,eAAe,GACf,OAAO,GACP,iBAAiB,GACjB,cAAc,GACd,MAAM,GACN,aAAa,GACb,WAAW,GACX,SAAS,GACT,MAAM,GACN,iBAAiB,GACjB,WAAW,GACX,KAAK,GACL,MAAM,GACN,gBAAgB,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/property/string-format.ts"],"sourcesContent":["export type StringFormat =\r\n | 'email'\r\n | 'phone'\r\n | 'password'\r\n | '
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/string-format.ts"],"sourcesContent":["export type StringFormat =\r\n | 'alpha'\r\n | 'alphanumeric'\r\n | 'ascii'\r\n | 'base32'\r\n | 'base58'\r\n | 'base64'\r\n | 'bic'\r\n | 'boolean-string'\r\n | 'byte-length'\r\n | 'credit-card'\r\n | 'currency'\r\n | 'data-uri'\r\n | 'date-string'\r\n | 'decimal'\r\n | 'ean'\r\n | 'email'\r\n | 'ethereum-address'\r\n | 'firebase-push-id'\r\n | 'hash'\r\n | 'hex-color'\r\n | 'hsl'\r\n | 'iban'\r\n | 'identity-card'\r\n | 'imei'\r\n | 'ip-range'\r\n | 'ip'\r\n | 'isbn'\r\n | 'isin'\r\n | 'iso31661-alpha2'\r\n | 'iso31661-alpha3'\r\n | 'iso4217'\r\n | 'iso8601'\r\n | 'isrc'\r\n | 'issn'\r\n | 'json'\r\n | 'jwt'\r\n | 'lat-long'\r\n | 'locale'\r\n | 'mac-address'\r\n | 'magnet-uri'\r\n | 'mime-type'\r\n | 'mobile-phone'\r\n | 'mongo-id'\r\n | 'number-string'\r\n | 'octal'\r\n | 'passport-number'\r\n | 'phone-number'\r\n | 'port'\r\n | 'postal-code'\r\n | 'rgb-color'\r\n | 'sem-ver'\r\n | 'slug'\r\n | 'strong-password'\r\n | 'time-zone'\r\n | 'url'\r\n | 'uuid'\r\n | 'variable-width';\r\n"],"names":[],"rangeMappings":"","mappings":"AAAA,WAyDqB"}
|
@@ -17,11 +17,11 @@ export type __StringOptions = {
|
|
17
17
|
/**
|
18
18
|
* Allowed strings
|
19
19
|
*/
|
20
|
-
enum?:
|
20
|
+
enum?: Readonly<unknown[] | Record<string, unknown>>;
|
21
21
|
/**
|
22
22
|
* Not allowed strings
|
23
23
|
*/
|
24
|
-
notIn?: string[]
|
24
|
+
notIn?: Readonly<string[]>;
|
25
25
|
/**
|
26
26
|
* string starts with
|
27
27
|
*/
|
@@ -33,11 +33,11 @@ export type __StringOptions = {
|
|
33
33
|
/**
|
34
34
|
* check the string contains
|
35
35
|
*/
|
36
|
-
contain?: string;
|
36
|
+
contain?: string[];
|
37
37
|
/**
|
38
38
|
* Check the string not contain
|
39
39
|
*/
|
40
|
-
notContain?: string;
|
40
|
+
notContain?: string[];
|
41
41
|
};
|
42
42
|
export type StringOptions = Readonly<CommonOptions<string> & __StringOptions>;
|
43
43
|
//# sourceMappingURL=string.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"string.d.ts","sourceRoot":"","sources":["../../../src/lib/property/string.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD,MAAM,MAAM,eAAe,GAAG;IAC5B,IAAI,EAAE,QAAQ,CAAC;IAEf;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;IAE5B;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;
|
1
|
+
{"version":3,"file":"string.d.ts","sourceRoot":"","sources":["../../../src/lib/property/string.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD,MAAM,MAAM,eAAe,GAAG;IAC5B,IAAI,EAAE,QAAQ,CAAC;IAEf;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,YAAY,CAAC,EAAE,YAAY,CAAC;IAE5B;;OAEG;IACH,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,EAAE,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IAErD;;OAEG;IACH,KAAK,CAAC,EAAE,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC;IAE3B;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IAEnB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG,QAAQ,CAAC,aAAa,CAAC,MAAM,CAAC,GAAG,eAAe,CAAC,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/property/string.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\nimport { StringFormat } from './string-format.js';\r\n\r\nexport type __StringOptions = {\r\n type: 'string';\r\n\r\n /**\r\n * Minimum allowed string length\r\n */\r\n minLength?: number;\r\n /**\r\n * Maximum allowed string length\r\n */\r\n maxLength?: number;\r\n\r\n /**\r\n * String format such as email, password.\r\n */\r\n stringFormat?: StringFormat;\r\n\r\n /**\r\n * Allowed strings\r\n */\r\n enum?:
|
1
|
+
{"version":3,"sources":["../../../src/lib/property/string.ts"],"sourcesContent":["import { CommonOptions } from './common.js';\r\nimport { StringFormat } from './string-format.js';\r\n\r\nexport type __StringOptions = {\r\n type: 'string';\r\n\r\n /**\r\n * Minimum allowed string length\r\n */\r\n minLength?: number;\r\n /**\r\n * Maximum allowed string length\r\n */\r\n maxLength?: number;\r\n\r\n /**\r\n * String format such as email, password.\r\n */\r\n stringFormat?: StringFormat;\r\n\r\n /**\r\n * Allowed strings\r\n */\r\n enum?: Readonly<unknown[] | Record<string, unknown>>;\r\n\r\n /**\r\n * Not allowed strings\r\n */\r\n notIn?: Readonly<string[]>;\r\n\r\n /**\r\n * string starts with\r\n */\r\n startWith?: string;\r\n\r\n /**\r\n * string ends with\r\n */\r\n endWith?: string;\r\n\r\n /**\r\n * check the string contains\r\n */\r\n contain?: string[];\r\n\r\n /**\r\n * Check the string not contain\r\n */\r\n notContain?: string[];\r\n};\r\n\r\nexport type StringOptions = Readonly<CommonOptions<string> & __StringOptions>;\r\n"],"names":[],"rangeMappings":"","mappings":"AAmDA,WAA8E"}
|
package/dist/lib/utils/keys.d.ts
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"keys.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/keys.ts"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"keys.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/keys.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAEpC,MAAM,MAAM,IAAI,CAAC,CAAC,GAAG,GAAG,IAAI,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;AAEvC,wBAAgB,IAAI,CAAC,CAAC,SAAS;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CAAE,EAAE,QAAQ,EAAE,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,CAE3E"}
|
package/dist/lib/utils/keys.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/utils/keys.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../../../src/lib/utils/keys.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\r\nimport { KeyOf } from './key-of.js';\r\n\r\nexport type Keys<T = any> = KeyOf<T>[];\r\n\r\nexport function keys<T extends { [key: string]: any }>(instance: T): Keys<T> {\r\n return Object.keys(instance) as Keys<T>;\r\n}\r\n"],"names":["keys","instance","Object"],"rangeMappings":";;","mappings":"AAAA,qDAAqD,GAKrD,OAAO,SAASA,KAAuCC,QAAW;IAChE,OAAOC,OAAOF,IAAI,CAACC;AACrB"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/type.ts"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/type.ts"],"names":[],"mappings":"AACA,MAAM,WAAW,IAAI,CAAC,CAAC,GAAG,GAAG,CAAE,SAAQ,QAAQ;IAC7C,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC;CACzB"}
|
package/dist/lib/utils/type.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../src/lib/utils/type.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../../../src/lib/utils/type.ts"],"sourcesContent":["// eslint-disable-next-line @typescript-eslint/no-unsafe-function-type\r\nexport interface Type<T = any> extends Function {\r\n new (...args: any[]): T;\r\n}\r\n"],"names":[],"rangeMappings":";","mappings":"AAAA,sEAAsE;AACtE,WAEC"}
|