simple-strapi 1.0.0-alpha.21 → 1.0.0-alpha.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/client.d.ts +2 -0
- package/dist/client.js +3 -0
- package/dist/fields/media.d.ts +2 -2
- package/dist/fields/media.js +1 -0
- package/package.json +1 -1
package/dist/client.d.ts
CHANGED
|
@@ -94,6 +94,7 @@ declare class Client {
|
|
|
94
94
|
page?: number;
|
|
95
95
|
pageSize?: number;
|
|
96
96
|
};
|
|
97
|
+
sort?: string | string[];
|
|
97
98
|
populate?: any;
|
|
98
99
|
filters?: Record<string, any>;
|
|
99
100
|
}>): Promise<{
|
|
@@ -105,6 +106,7 @@ declare class Client {
|
|
|
105
106
|
page?: number;
|
|
106
107
|
pageSize?: number;
|
|
107
108
|
};
|
|
109
|
+
sort?: string | string[];
|
|
108
110
|
populate?: any;
|
|
109
111
|
filters?: Record<string, any>;
|
|
110
112
|
}>): Promise<{
|
package/dist/client.js
CHANGED
|
@@ -208,6 +208,9 @@ class Client {
|
|
|
208
208
|
else if ("populate" in options) {
|
|
209
209
|
params.populate = options.populate;
|
|
210
210
|
}
|
|
211
|
+
if ("sort" in options) {
|
|
212
|
+
params.sort = options.sort;
|
|
213
|
+
}
|
|
211
214
|
const fetchPage = async (page = 1, acc = []) => {
|
|
212
215
|
params.pagination = { page, pageSize: 100 };
|
|
213
216
|
params.filters = options.filters;
|
package/dist/fields/media.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ export declare const zodMediaSchema: z.ZodObject<{
|
|
|
6
6
|
caption: z.ZodNullable<z.ZodString>;
|
|
7
7
|
width: z.ZodNullable<z.ZodNumber>;
|
|
8
8
|
height: z.ZodNullable<z.ZodNumber>;
|
|
9
|
-
formats: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
9
|
+
formats: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
10
10
|
name: z.ZodString;
|
|
11
11
|
hash: z.ZodOptional<z.ZodString>;
|
|
12
12
|
ext: z.ZodOptional<z.ZodString>;
|
|
@@ -16,7 +16,7 @@ export declare const zodMediaSchema: z.ZodObject<{
|
|
|
16
16
|
url: z.ZodString;
|
|
17
17
|
width: z.ZodNumber;
|
|
18
18
|
height: z.ZodNumber;
|
|
19
|
-
}, z.core.$strip
|
|
19
|
+
}, z.core.$strip>>>>;
|
|
20
20
|
hash: z.ZodString;
|
|
21
21
|
ext: z.ZodString;
|
|
22
22
|
mime: z.ZodString;
|
package/dist/fields/media.js
CHANGED