@clipboard-health/json-api-nestjs 0.13.0 → 0.14.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/README.md +9 -3
- package/package.json +17 -6
- package/src/lib/query/cursorPaginationQuery.d.ts +8 -0
- package/src/lib/query/cursorPaginationQuery.js +8 -0
- package/src/lib/query/cursorPaginationQuery.js.map +1 -1
- package/src/lib/query/fieldsQuery.d.ts +8 -0
- package/src/lib/query/fieldsQuery.js +8 -0
- package/src/lib/query/fieldsQuery.js.map +1 -1
- package/src/lib/query/filterQuery.d.ts +9 -2
- package/src/lib/query/filterQuery.js +8 -0
- package/src/lib/query/filterQuery.js.map +1 -1
- package/src/lib/query/includeQuery.d.ts +8 -0
- package/src/lib/query/includeQuery.js +8 -0
- package/src/lib/query/includeQuery.js.map +1 -1
- package/src/lib/query/sortQuery.d.ts +8 -0
- package/src/lib/query/sortQuery.js +8 -0
- package/src/lib/query/sortQuery.js.map +1 -1
package/README.md
CHANGED
|
@@ -23,9 +23,7 @@ Create Zod schemas for your API's queries:
|
|
|
23
23
|
|
|
24
24
|
<!-- prettier-ignore -->
|
|
25
25
|
```ts
|
|
26
|
-
//
|
|
27
|
-
|
|
28
|
-
// packages/json-api-nestjs/src/lib/query/cursorPaginationQuery.ts,packages/json-api-nestjs/src/lib/query/fieldsQuery.ts,packages/json-api-nestjs/src/lib/query/filterQuery.ts,packages/json-api-nestjs/src/lib/query/includeQuery.ts,packages/json-api-nestjs/src/lib/query/sortQuery.ts
|
|
26
|
+
// packages/example-nestjs/examples/query.ts
|
|
29
27
|
import { booleanString } from "@clipboard-health/contract-core";
|
|
30
28
|
import {
|
|
31
29
|
cursorPaginationQuery,
|
|
@@ -64,6 +62,14 @@ const userFilterMap = {
|
|
|
64
62
|
},
|
|
65
63
|
} as const satisfies FilterMap<UserAttributeFields>;
|
|
66
64
|
|
|
65
|
+
/**
|
|
66
|
+
* Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
67
|
+
* implement them as they may require database indexes, which have a cost. **Implement only access
|
|
68
|
+
* patterns required by clients.**
|
|
69
|
+
*
|
|
70
|
+
* The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
71
|
+
* Bad Request, hence the `.strict()`.
|
|
72
|
+
*\/
|
|
67
73
|
export const query = z
|
|
68
74
|
.object({
|
|
69
75
|
...cursorPaginationQuery(),
|
package/package.json
CHANGED
|
@@ -1,24 +1,35 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@clipboard-health/json-api-nestjs",
|
|
3
3
|
"description": "TypeScript-friendly utilities for adhering to the JSON:API specification with NestJS.",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.14.0",
|
|
5
|
+
"bugs": "https://github.com/ClipboardHealth/core-utils/issues",
|
|
5
6
|
"dependencies": {
|
|
6
7
|
"@clipboard-health/contract-core": "0.3.0",
|
|
7
8
|
"tslib": "2.8.0",
|
|
8
|
-
"type-fest": "4.
|
|
9
|
+
"type-fest": "4.27.0",
|
|
9
10
|
"zod": "3.23.8"
|
|
10
11
|
},
|
|
11
12
|
"devDependencies": {
|
|
12
|
-
"@clipboard-health/testing-core": "0.
|
|
13
|
+
"@clipboard-health/testing-core": "0.10.0"
|
|
13
14
|
},
|
|
14
|
-
"keywords": [
|
|
15
|
+
"keywords": [
|
|
16
|
+
"api",
|
|
17
|
+
"json-api",
|
|
18
|
+
"json:api",
|
|
19
|
+
"jsonapi",
|
|
20
|
+
"nestjs",
|
|
21
|
+
"rest",
|
|
22
|
+
"typescript"
|
|
23
|
+
],
|
|
15
24
|
"license": "MIT",
|
|
16
25
|
"main": "./src/index.js",
|
|
17
26
|
"publishConfig": {
|
|
18
27
|
"access": "public"
|
|
19
28
|
},
|
|
20
|
-
"
|
|
21
|
-
"
|
|
29
|
+
"repository": {
|
|
30
|
+
"directory": "packages/json-api-nestjs",
|
|
31
|
+
"type": "git",
|
|
32
|
+
"url": "git+https://github.com/ClipboardHealth/core-utils.git"
|
|
22
33
|
},
|
|
23
34
|
"type": "commonjs",
|
|
24
35
|
"typings": "./src/index.d.ts",
|
|
@@ -49,6 +49,14 @@ export declare const PAGINATION: {
|
|
|
49
49
|
* },
|
|
50
50
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
51
51
|
*
|
|
52
|
+
* /**
|
|
53
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
54
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
55
|
+
* * patterns required by clients.**
|
|
56
|
+
* *
|
|
57
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
58
|
+
* * Bad Request, hence the `.strict()`.
|
|
59
|
+
* *\/
|
|
52
60
|
* export const query = z
|
|
53
61
|
* .object({
|
|
54
62
|
* ...cursorPaginationQuery(),
|
|
@@ -54,6 +54,14 @@ exports.PAGINATION = {
|
|
|
54
54
|
* },
|
|
55
55
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
56
56
|
*
|
|
57
|
+
* /**
|
|
58
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
59
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
60
|
+
* * patterns required by clients.**
|
|
61
|
+
* *
|
|
62
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
63
|
+
* * Bad Request, hence the `.strict()`.
|
|
64
|
+
* *\/
|
|
57
65
|
* export const query = z
|
|
58
66
|
* .object({
|
|
59
67
|
* ...cursorPaginationQuery(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cursorPaginationQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/cursorPaginationQuery.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"cursorPaginationQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/cursorPaginationQuery.ts"],"names":[],"mappings":";;;AA6EA,sDAeC;AA5FD,mEAAiE;AACjE,6BAAwB;AAEX,QAAA,UAAU,GAAG;IACxB,IAAI,EAAE;QACJ,OAAO,EAAE,EAAE;QACX,OAAO,EAAE,GAAG;KACb;CACO,CAAC;AAEX;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkEG;AACH,SAAgB,qBAAqB,CACnC,UAAuE;IAEvE,MAAM,EAAE,IAAI,EAAE,GAAG,kBAAU,CAAC;IAC5B,MAAM,EAAE,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC,OAAO,EAAE,GAAG,UAAU,EAAE,IAAI,IAAI,EAAE,CAAC;IAE/F,OAAO;QACL,IAAI,EAAE,OAAC;aACJ,MAAM,CAAC;YACN,MAAM,EAAE,8BAAc,CAAC,QAAQ,EAAE;YACjC,IAAI,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,OAAO,CAAC,WAAW,CAAC;SAC3E,CAAC;aACD,MAAM,EAAE;aACR,OAAO,CAAC,EAAE,IAAI,EAAE,WAAW,EAAE,CAAC;KAClC,CAAC;AACJ,CAAC"}
|
|
@@ -54,6 +54,14 @@ export type AttributeFields<DocumentT extends JsonApiDocument> = DocumentT["data
|
|
|
54
54
|
* },
|
|
55
55
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
56
56
|
*
|
|
57
|
+
* /**
|
|
58
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
59
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
60
|
+
* * patterns required by clients.**
|
|
61
|
+
* *
|
|
62
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
63
|
+
* * Bad Request, hence the `.strict()`.
|
|
64
|
+
* *\/
|
|
57
65
|
* export const query = z
|
|
58
66
|
* .object({
|
|
59
67
|
* ...cursorPaginationQuery(),
|
|
@@ -47,6 +47,14 @@ const splitString_1 = require("../internal/splitString");
|
|
|
47
47
|
* },
|
|
48
48
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
49
49
|
*
|
|
50
|
+
* /**
|
|
51
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
52
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
53
|
+
* * patterns required by clients.**
|
|
54
|
+
* *
|
|
55
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
56
|
+
* * Bad Request, hence the `.strict()`.
|
|
57
|
+
* *\/
|
|
50
58
|
* export const query = z
|
|
51
59
|
* .object({
|
|
52
60
|
* ...cursorPaginationQuery(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fieldsQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/fieldsQuery.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"fieldsQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/fieldsQuery.ts"],"names":[],"mappings":";;AA6FA,kCAYC;AAzGD,6BAAwB;AAExB,yDAAsD;AAyBtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiEG;AACH,SAAgB,WAAW,CAA+B,UAA0B;IAClF,MAAM,YAAY,GAAG,MAAM,CAAC,WAAW,CACrC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,OAAO,EAAE,MAAM,CAAiC,EAAE,EAAE,CAAC;QACpF,OAAO;QACP,OAAC,CAAC,UAAU,CAAC,yBAAW,EAAE,OAAC,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC;KAC7E,CAAC,CAEmB,CAAC;IAExB,OAAO;QACL,MAAM,EAAE,OAAC,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;KACnD,CAAC;AACJ,CAAC"}
|
|
@@ -6,7 +6,7 @@ export interface FilterValue {
|
|
|
6
6
|
filters: FilterTuple;
|
|
7
7
|
schema: z.ZodTypeAny;
|
|
8
8
|
}
|
|
9
|
-
type InternalFilterMap<FieldT extends Field = Field> = Record<FieldT, FilterValue>;
|
|
9
|
+
export type InternalFilterMap<FieldT extends Field = Field> = Record<FieldT, FilterValue>;
|
|
10
10
|
export type FilterMap<FieldT extends Field = Field> = Partial<InternalFilterMap<FieldT>>;
|
|
11
11
|
export type FilterSchema<MapT extends InternalFilterMap> = {
|
|
12
12
|
[K in keyof MapT]: z.ZodOptional<z.ZodEffects<z.ZodOptional<z.ZodObject<{
|
|
@@ -57,6 +57,14 @@ export type FilterSchema<MapT extends InternalFilterMap> = {
|
|
|
57
57
|
* },
|
|
58
58
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
59
59
|
*
|
|
60
|
+
* /**
|
|
61
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
62
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
63
|
+
* * patterns required by clients.**
|
|
64
|
+
* *
|
|
65
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
66
|
+
* * Bad Request, hence the `.strict()`.
|
|
67
|
+
* *\/
|
|
60
68
|
* export const query = z
|
|
61
69
|
* .object({
|
|
62
70
|
* ...cursorPaginationQuery(),
|
|
@@ -75,4 +83,3 @@ export type FilterSchema<MapT extends InternalFilterMap> = {
|
|
|
75
83
|
export declare function filterQuery<const MapT extends InternalFilterMap>(parameters: Readonly<MapT>): {
|
|
76
84
|
filter: z.ZodOptional<z.ZodObject<FilterSchema<MapT>, "strict", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<FilterSchema<MapT>>, any> extends infer T ? { [k in keyof T]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<FilterSchema<MapT>>, any>[k]; } : never, z.baseObjectInputType<FilterSchema<MapT>> extends infer T_1 ? { [k_1 in keyof T_1]: z.baseObjectInputType<FilterSchema<MapT>>[k_1]; } : never>>;
|
|
77
85
|
};
|
|
78
|
-
export {};
|
|
@@ -48,6 +48,14 @@ const splitString_1 = require("../internal/splitString");
|
|
|
48
48
|
* },
|
|
49
49
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
50
50
|
*
|
|
51
|
+
* /**
|
|
52
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
53
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
54
|
+
* * patterns required by clients.**
|
|
55
|
+
* *
|
|
56
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
57
|
+
* * Bad Request, hence the `.strict()`.
|
|
58
|
+
* *\/
|
|
51
59
|
* export const query = z
|
|
52
60
|
* .object({
|
|
53
61
|
* ...cursorPaginationQuery(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filterQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/filterQuery.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"filterQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/filterQuery.ts"],"names":[],"mappings":";;AAoGA,kCAcC;AAlHD,6BAAwB;AAExB,iFAA8E;AAC9E,yDAAsD;AA8BtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkEG;AACH,SAAgB,WAAW,CAAuC,UAA0B;IAC1F,OAAO;QACL,MAAM,EAAE,OAAC;aACN,MAAM,CACL,MAAM,CAAC,WAAW,CAChB,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,OAAO,EAAE,KAAK,CAAiC,EAAE,EAAE,CAAC;YACnF,OAAO;YACP,OAAC,CAAC,UAAU,CAAC,iDAAuB,EAAE,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC,QAAQ,EAAE;SACtE,CAAC,CACmB,CACxB;aACA,MAAM,EAAE;aACR,QAAQ,EAAE;KACd,CAAC;AACJ,CAAC;AAED,SAAS,YAAY,CAAC,UAAuB;IAC3C,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,UAAU,CAAC;IAEvC,OAAO,OAAC;SACL,MAAM,CACL,MAAM,CAAC,WAAW,CAChB,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC;QACtB,MAAM;QACN,OAAC,CAAC,UAAU,CAAC,yBAAW,EAAE,MAAM,CAAC,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC,QAAQ,EAAE;KACnF,CAAC,CACH,CACF;SACA,MAAM,EAAE;SACR,QAAQ,EAAE,CAAC;AAChB,CAAC"}
|
|
@@ -64,6 +64,14 @@ export type RelationshipPaths<MapT extends Record<string, z.ZodTypeAny>, Documen
|
|
|
64
64
|
* },
|
|
65
65
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
66
66
|
*
|
|
67
|
+
* /**
|
|
68
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
69
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
70
|
+
* * patterns required by clients.**
|
|
71
|
+
* *
|
|
72
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
73
|
+
* * Bad Request, hence the `.strict()`.
|
|
74
|
+
* *\/
|
|
67
75
|
* export const query = z
|
|
68
76
|
* .object({
|
|
69
77
|
* ...cursorPaginationQuery(),
|
|
@@ -47,6 +47,14 @@ const splitString_1 = require("../internal/splitString");
|
|
|
47
47
|
* },
|
|
48
48
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
49
49
|
*
|
|
50
|
+
* /**
|
|
51
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
52
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
53
|
+
* * patterns required by clients.**
|
|
54
|
+
* *
|
|
55
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
56
|
+
* * Bad Request, hence the `.strict()`.
|
|
57
|
+
* *\/
|
|
50
58
|
* export const query = z
|
|
51
59
|
* .object({
|
|
52
60
|
* ...cursorPaginationQuery(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"includeQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/includeQuery.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"includeQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/includeQuery.ts"],"names":[],"mappings":";;AAmHA,oCAuBC;AAzID,6BAAwB;AAExB,yDAAsD;AA8CtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiEG;AACH,SAAgB,YAAY,CAAyC,MAAc;IACjF,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAC;IAEjC,OAAO;QACL,OAAO,EAAE,OAAC;aACP,UAAU,CAAC,yBAAW,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC;aACtE,WAAW,CAAC,CAAC,KAAK,EAAE,OAAO,EAAE,EAAE;YAC9B,IAAI,CAAC,KAAK,EAAE,CAAC;gBACX,OAAO;YACT,CAAC;YAED,KAAK,MAAM,KAAK,IAAI,KAAK,EAAE,CAAC;gBAC1B,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC;oBACzB,OAAO,CAAC,QAAQ,CAAC;wBACf,IAAI,EAAE,OAAC,CAAC,YAAY,CAAC,MAAM;wBAC3B,OAAO,EAAE,2BAA2B,KAAK,GAAG;wBAC5C,IAAI,EAAE,CAAC,SAAS,EAAE,KAAK,CAAC;qBACzB,CAAC,CAAC;gBACL,CAAC;YACH,CAAC;QACH,CAAC,CAAC;aACD,SAAS,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAA0C,CAAC;KACpE,CAAC;AACJ,CAAC"}
|
|
@@ -44,6 +44,14 @@ import { type Field } from "../types";
|
|
|
44
44
|
* },
|
|
45
45
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
46
46
|
*
|
|
47
|
+
* /**
|
|
48
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
49
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
50
|
+
* * patterns required by clients.**
|
|
51
|
+
* *
|
|
52
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
53
|
+
* * Bad Request, hence the `.strict()`.
|
|
54
|
+
* *\/
|
|
47
55
|
* export const query = z
|
|
48
56
|
* .object({
|
|
49
57
|
* ...cursorPaginationQuery(),
|
|
@@ -47,6 +47,14 @@ const splitString_1 = require("../internal/splitString");
|
|
|
47
47
|
* },
|
|
48
48
|
* } as const satisfies FilterMap<UserAttributeFields>;
|
|
49
49
|
*
|
|
50
|
+
* /**
|
|
51
|
+
* * Disclaimer: Just because JSON:API supports robust querying doesn’t mean your service should
|
|
52
|
+
* * implement them as they may require database indexes, which have a cost. **Implement only access
|
|
53
|
+
* * patterns required by clients.**
|
|
54
|
+
* *
|
|
55
|
+
* * The spec says that if clients provide fields the server doesn’t support, it **MUST** return 400
|
|
56
|
+
* * Bad Request, hence the `.strict()`.
|
|
57
|
+
* *\/
|
|
50
58
|
* export const query = z
|
|
51
59
|
* .object({
|
|
52
60
|
* ...cursorPaginationQuery(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sortQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/sortQuery.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"sortQuery.js","sourceRoot":"","sources":["../../../../../../packages/json-api-nestjs/src/lib/query/sortQuery.ts"],"names":[],"mappings":";;AAuEA,8BAsBC;AA7FD,6BAAwB;AAExB,yDAAsD;AAGtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiEG;AACH,SAAgB,SAAS,CAAoD,MAAc;IACzF,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAC;IACjC,OAAO;QACL,IAAI,EAAE,OAAC;aACJ,UAAU,CAAC,yBAAW,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC;aACtE,WAAW,CAAC,CAAC,KAAK,EAAE,OAAO,EAAE,EAAE;YAC9B,IAAI,CAAC,KAAK,EAAE,CAAC;gBACX,OAAO;YACT,CAAC;YAED,KAAK,MAAM,KAAK,IAAI,KAAK,EAAE,CAAC;gBAC1B,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC;oBAClE,OAAO,CAAC,QAAQ,CAAC;wBACf,IAAI,EAAE,OAAC,CAAC,YAAY,CAAC,MAAM;wBAC3B,OAAO,EAAE,wBAAwB,KAAK,GAAG;wBACzC,IAAI,EAAE,CAAC,MAAM,EAAE,KAAK,CAAC;qBACtB,CAAC,CAAC;gBACL,CAAC;YACH,CAAC;QACH,CAAC,CAAC;aACD,SAAS,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAiE,CAAC;KAC3F,CAAC;AACJ,CAAC"}
|