@btst/stack 3.0.2 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/context/index.d.cts +3 -1
- package/dist/context/index.d.mts +3 -1
- package/dist/context/index.d.ts +3 -1
- package/dist/packages/stack/src/context/auth.cjs +20 -14
- package/dist/packages/stack/src/context/auth.mjs +20 -14
- package/dist/packages/stack/src/context/provider.cjs +42 -22
- package/dist/packages/stack/src/context/provider.mjs +43 -23
- package/dist/packages/stack/src/plugins/blog/client/components/pages/home-page.cjs +32 -28
- package/dist/packages/stack/src/plugins/blog/client/components/pages/home-page.mjs +32 -29
- package/dist/packages/stack/src/plugins/blog/client/components/pages/post-page.cjs +53 -47
- package/dist/packages/stack/src/plugins/blog/client/components/pages/post-page.mjs +53 -48
- package/dist/packages/stack/src/plugins/blog/client/components/pages/tag-page.cjs +30 -24
- package/dist/packages/stack/src/plugins/blog/client/components/pages/tag-page.mjs +30 -25
- package/dist/plugins/blog/api/index.d.cts +2 -2
- package/dist/plugins/blog/api/index.d.mts +2 -2
- package/dist/plugins/blog/api/index.d.ts +2 -2
- package/dist/plugins/blog/client/components/index.d.cts +6 -10
- package/dist/plugins/blog/client/components/index.d.mts +6 -10
- package/dist/plugins/blog/client/components/index.d.ts +6 -10
- package/dist/plugins/blog/client/hooks/index.d.cts +2 -2
- package/dist/plugins/blog/client/hooks/index.d.mts +2 -2
- package/dist/plugins/blog/client/hooks/index.d.ts +2 -2
- package/dist/plugins/blog/client/index.d.cts +2 -2
- package/dist/plugins/blog/client/index.d.mts +2 -2
- package/dist/plugins/blog/client/index.d.ts +2 -2
- package/dist/plugins/blog/client/pages/post.cjs +9 -0
- package/dist/plugins/blog/client/pages/post.d.cts +8 -0
- package/dist/plugins/blog/client/pages/post.d.mts +8 -0
- package/dist/plugins/blog/client/pages/post.d.ts +8 -0
- package/dist/plugins/blog/client/pages/post.mjs +7 -0
- package/dist/plugins/blog/client/pages/posts.cjs +9 -0
- package/dist/plugins/blog/client/pages/posts.d.cts +8 -0
- package/dist/plugins/blog/client/pages/posts.d.mts +8 -0
- package/dist/plugins/blog/client/pages/posts.d.ts +8 -0
- package/dist/plugins/blog/client/pages/posts.mjs +7 -0
- package/dist/plugins/blog/client/pages/tag.cjs +9 -0
- package/dist/plugins/blog/client/pages/tag.d.cts +8 -0
- package/dist/plugins/blog/client/pages/tag.d.mts +8 -0
- package/dist/plugins/blog/client/pages/tag.d.ts +8 -0
- package/dist/plugins/blog/client/pages/tag.mjs +7 -0
- package/dist/plugins/blog/query-keys.d.cts +2 -2
- package/dist/plugins/blog/query-keys.d.mts +2 -2
- package/dist/plugins/blog/query-keys.d.ts +2 -2
- package/dist/plugins/form-builder/api/index.d.cts +1 -1
- package/dist/plugins/form-builder/api/index.d.mts +1 -1
- package/dist/plugins/form-builder/api/index.d.ts +1 -1
- package/dist/plugins/form-builder/client/hooks/index.d.cts +1 -1
- package/dist/plugins/form-builder/client/hooks/index.d.mts +1 -1
- package/dist/plugins/form-builder/client/hooks/index.d.ts +1 -1
- package/dist/plugins/form-builder/query-keys.d.cts +1 -1
- package/dist/plugins/form-builder/query-keys.d.mts +1 -1
- package/dist/plugins/form-builder/query-keys.d.ts +1 -1
- package/dist/shared/{stack.BTStHVTy.d.cts → stack.BGzgFx3R.d.cts} +5 -5
- package/dist/shared/{stack.94kN3pEK.d.mts → stack.CjCSDfWy.d.mts} +5 -5
- package/dist/shared/{stack.lPKwd_v0.d.ts → stack.Clil75lW.d.ts} +37 -37
- package/dist/shared/{stack.CtrnoQgH.d.cts → stack.DNw6Hv5o.d.cts} +37 -37
- package/dist/shared/{stack.BggTHKlo.d.mts → stack.DhZtP2JZ.d.mts} +37 -37
- package/dist/shared/{stack.DfrRYOIl.d.ts → stack.Dpg_JjIo.d.ts} +5 -5
- package/package.json +41 -2
- package/src/__tests__/provider-hydration.test.tsx +164 -0
- package/src/context/auth.tsx +21 -14
- package/src/context/provider.tsx +51 -28
- package/src/plugins/blog/__tests__/page-load-error.test.tsx +53 -0
- package/src/plugins/blog/__tests__/page-loading.test.tsx +106 -0
- package/src/plugins/blog/client/components/pages/home-page.tsx +39 -35
- package/src/plugins/blog/client/components/pages/post-page.tsx +62 -54
- package/src/plugins/blog/client/components/pages/tag-page.tsx +35 -29
- package/src/plugins/blog/client/pages/post.tsx +7 -0
- package/src/plugins/blog/client/pages/posts.tsx +7 -0
- package/src/plugins/blog/client/pages/tag.tsx +7 -0
- package/dist/shared/{stack.D20bOqfr.d.ts → stack.BuxUQqL8.d.ts} +20 -20
- package/dist/shared/{stack.AWSs6TXN.d.cts → stack.CX83YNuS.d.cts} +20 -20
- package/dist/shared/{stack.CKc_Bais.d.cts → stack.Csi-4Mgz.d.cts} +7 -7
- package/dist/shared/{stack.CKc_Bais.d.mts → stack.Csi-4Mgz.d.mts} +7 -7
- package/dist/shared/{stack.CKc_Bais.d.ts → stack.Csi-4Mgz.d.ts} +7 -7
- package/dist/shared/{stack.HB5uGLpE.d.mts → stack.Egr3RWhA.d.mts} +20 -20
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
|
|
3
3
|
declare const createPostSchema: z.ZodObject<{
|
|
4
|
+
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
5
|
+
name: z.ZodString;
|
|
6
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
7
|
+
id: z.ZodString;
|
|
8
|
+
name: z.ZodString;
|
|
9
|
+
slug: z.ZodString;
|
|
10
|
+
}, z.core.$strip>]>>>>;
|
|
4
11
|
slug: z.ZodOptional<z.ZodString>;
|
|
5
12
|
publishedAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
6
13
|
createdAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
@@ -10,13 +17,6 @@ declare const createPostSchema: z.ZodObject<{
|
|
|
10
17
|
excerpt: z.ZodString;
|
|
11
18
|
image: z.ZodOptional<z.ZodString>;
|
|
12
19
|
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
13
|
-
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
14
|
-
name: z.ZodString;
|
|
15
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
16
|
-
id: z.ZodString;
|
|
17
|
-
name: z.ZodString;
|
|
18
|
-
slug: z.ZodString;
|
|
19
|
-
}, z.core.$strip>]>>>>;
|
|
20
20
|
}, z.core.$strip>;
|
|
21
21
|
declare const updatePostSchema: z.ZodObject<{
|
|
22
22
|
publishedAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
|
|
3
3
|
declare const createPostSchema: z.ZodObject<{
|
|
4
|
+
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
5
|
+
name: z.ZodString;
|
|
6
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
7
|
+
id: z.ZodString;
|
|
8
|
+
name: z.ZodString;
|
|
9
|
+
slug: z.ZodString;
|
|
10
|
+
}, z.core.$strip>]>>>>;
|
|
4
11
|
slug: z.ZodOptional<z.ZodString>;
|
|
5
12
|
publishedAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
6
13
|
createdAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
@@ -10,13 +17,6 @@ declare const createPostSchema: z.ZodObject<{
|
|
|
10
17
|
excerpt: z.ZodString;
|
|
11
18
|
image: z.ZodOptional<z.ZodString>;
|
|
12
19
|
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
13
|
-
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
14
|
-
name: z.ZodString;
|
|
15
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
16
|
-
id: z.ZodString;
|
|
17
|
-
name: z.ZodString;
|
|
18
|
-
slug: z.ZodString;
|
|
19
|
-
}, z.core.$strip>]>>>>;
|
|
20
20
|
}, z.core.$strip>;
|
|
21
21
|
declare const updatePostSchema: z.ZodObject<{
|
|
22
22
|
publishedAt: z.ZodOptional<z.ZodCoercedDate<unknown>>;
|
|
@@ -127,11 +127,11 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
127
127
|
readonly status: Form["status"];
|
|
128
128
|
readonly createdAt: string;
|
|
129
129
|
readonly updatedAt: string;
|
|
130
|
-
readonly
|
|
130
|
+
readonly schema: string;
|
|
131
131
|
readonly id: string;
|
|
132
|
-
readonly name: string;
|
|
133
132
|
readonly description?: string | undefined;
|
|
134
|
-
readonly
|
|
133
|
+
readonly slug: string;
|
|
134
|
+
readonly name: string;
|
|
135
135
|
readonly successMessage?: string | undefined;
|
|
136
136
|
readonly redirectUrl?: string | undefined;
|
|
137
137
|
readonly createdBy?: string | undefined;
|
|
@@ -151,11 +151,11 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
151
151
|
readonly status: Form["status"];
|
|
152
152
|
readonly createdAt: string;
|
|
153
153
|
readonly updatedAt: string;
|
|
154
|
-
readonly
|
|
154
|
+
readonly schema: string;
|
|
155
155
|
readonly id: string;
|
|
156
|
-
readonly name: string;
|
|
157
156
|
readonly description?: string | undefined;
|
|
158
|
-
readonly
|
|
157
|
+
readonly slug: string;
|
|
158
|
+
readonly name: string;
|
|
159
159
|
readonly successMessage?: string | undefined;
|
|
160
160
|
readonly redirectUrl?: string | undefined;
|
|
161
161
|
readonly createdBy?: string | undefined;
|
|
@@ -171,11 +171,11 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
171
171
|
readonly status: Form["status"];
|
|
172
172
|
readonly createdAt: string;
|
|
173
173
|
readonly updatedAt: string;
|
|
174
|
-
readonly
|
|
174
|
+
readonly schema: string;
|
|
175
175
|
readonly id: string;
|
|
176
|
-
readonly name: string;
|
|
177
176
|
readonly description?: string | undefined;
|
|
178
|
-
readonly
|
|
177
|
+
readonly slug: string;
|
|
178
|
+
readonly name: string;
|
|
179
179
|
readonly successMessage?: string | undefined;
|
|
180
180
|
readonly redirectUrl?: string | undefined;
|
|
181
181
|
readonly createdBy?: string | undefined;
|
|
@@ -191,11 +191,11 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
191
191
|
readonly status: Form["status"];
|
|
192
192
|
readonly createdAt: string;
|
|
193
193
|
readonly updatedAt: string;
|
|
194
|
-
readonly
|
|
194
|
+
readonly schema: string;
|
|
195
195
|
readonly id: string;
|
|
196
|
-
readonly name: string;
|
|
197
196
|
readonly description?: string | undefined;
|
|
198
|
-
readonly
|
|
197
|
+
readonly slug: string;
|
|
198
|
+
readonly name: string;
|
|
199
199
|
readonly successMessage?: string | undefined;
|
|
200
200
|
readonly redirectUrl?: string | undefined;
|
|
201
201
|
readonly createdBy?: string | undefined;
|
|
@@ -225,11 +225,11 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
225
225
|
readonly status: Form["status"];
|
|
226
226
|
readonly createdAt: string;
|
|
227
227
|
readonly updatedAt: string;
|
|
228
|
-
readonly
|
|
228
|
+
readonly schema: string;
|
|
229
229
|
readonly id: string;
|
|
230
|
-
readonly name: string;
|
|
231
230
|
readonly description?: string | undefined;
|
|
232
|
-
readonly
|
|
231
|
+
readonly slug: string;
|
|
232
|
+
readonly name: string;
|
|
233
233
|
readonly successMessage?: string | undefined;
|
|
234
234
|
readonly redirectUrl?: string | undefined;
|
|
235
235
|
readonly createdBy?: string | undefined;
|
|
@@ -259,11 +259,11 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
259
259
|
readonly status: Form["status"];
|
|
260
260
|
readonly createdAt: string;
|
|
261
261
|
readonly updatedAt: string;
|
|
262
|
-
readonly
|
|
262
|
+
readonly schema: string;
|
|
263
263
|
readonly id: string;
|
|
264
|
-
readonly name: string;
|
|
265
264
|
readonly description?: string | undefined;
|
|
266
|
-
readonly
|
|
265
|
+
readonly slug: string;
|
|
266
|
+
readonly name: string;
|
|
267
267
|
readonly successMessage?: string | undefined;
|
|
268
268
|
readonly redirectUrl?: string | undefined;
|
|
269
269
|
readonly createdBy?: string | undefined;
|
|
@@ -291,10 +291,10 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
291
291
|
readonly redirectUrl?: string | undefined;
|
|
292
292
|
};
|
|
293
293
|
readonly submittedAt: string;
|
|
294
|
-
readonly data: string;
|
|
295
294
|
readonly id: string;
|
|
296
295
|
readonly formId: string;
|
|
297
296
|
readonly submittedBy?: string | undefined;
|
|
297
|
+
readonly data: string;
|
|
298
298
|
readonly ipAddress?: string | undefined;
|
|
299
299
|
readonly userAgent?: string | undefined;
|
|
300
300
|
}>;
|
|
@@ -335,10 +335,10 @@ declare const formBuilderBackendPlugin: (config?: FormBuilderBackendConfig) => _
|
|
|
335
335
|
readonly [x: string]: any;
|
|
336
336
|
} | null;
|
|
337
337
|
readonly submittedAt: string;
|
|
338
|
-
readonly data: string;
|
|
339
338
|
readonly id: string;
|
|
340
339
|
readonly formId: string;
|
|
341
340
|
readonly submittedBy?: string | undefined;
|
|
341
|
+
readonly data: string;
|
|
342
342
|
readonly ipAddress?: string | undefined;
|
|
343
343
|
readonly userAgent?: string | undefined;
|
|
344
344
|
}>;
|