@btst/stack 4.5.0 → 4.6.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 +2 -2
- package/dist/components/markdown/index.d.cts +4 -2
- package/dist/components/markdown/index.d.mts +4 -2
- package/dist/components/markdown/index.d.ts +4 -2
- package/dist/packages/stack/src/plugins/ai-chat/api/compaction.cjs +102 -15
- package/dist/packages/stack/src/plugins/ai-chat/api/compaction.mjs +102 -15
- package/dist/packages/stack/src/plugins/ai-chat/api/operations.cjs +8 -4
- package/dist/packages/stack/src/plugins/ai-chat/api/operations.mjs +8 -4
- package/dist/packages/stack/src/plugins/ai-chat/api/plugin.cjs +5 -0
- package/dist/packages/stack/src/plugins/ai-chat/api/plugin.mjs +5 -0
- package/dist/packages/stack/src/plugins/ai-chat/client/components/chat-input.cjs +3 -2
- package/dist/packages/stack/src/plugins/ai-chat/client/components/chat-input.mjs +3 -2
- package/dist/packages/stack/src/plugins/ai-chat/client/components/chat-interface.cjs +0 -1
- package/dist/packages/stack/src/plugins/ai-chat/client/components/chat-interface.mjs +0 -1
- package/dist/packages/stack/src/plugins/blog/client/components/pages/post-page.internal.cjs +7 -1
- package/dist/packages/stack/src/plugins/blog/client/components/pages/post-page.internal.mjs +7 -1
- package/dist/packages/stack/src/plugins/blog/client/components/shared/markdown-content.cjs +6 -1
- package/dist/packages/stack/src/plugins/blog/client/components/shared/markdown-content.mjs +6 -1
- package/dist/packages/ui/src/components/markdown-content.cjs +23 -3
- package/dist/packages/ui/src/components/markdown-content.mjs +25 -5
- package/dist/plugins/ai-chat/api/index.d.cts +2 -2
- package/dist/plugins/ai-chat/api/index.d.mts +2 -2
- package/dist/plugins/ai-chat/api/index.d.ts +2 -2
- package/dist/plugins/ai-chat/client/hooks/index.d.cts +2 -2
- package/dist/plugins/ai-chat/client/hooks/index.d.mts +2 -2
- package/dist/plugins/ai-chat/client/hooks/index.d.ts +2 -2
- package/dist/plugins/ai-chat/client/index.d.cts +1 -1
- package/dist/plugins/ai-chat/client/index.d.mts +1 -1
- package/dist/plugins/ai-chat/client/index.d.ts +1 -1
- package/dist/plugins/ai-chat/query-keys.d.cts +1 -1
- package/dist/plugins/ai-chat/query-keys.d.mts +1 -1
- package/dist/plugins/ai-chat/query-keys.d.ts +1 -1
- 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/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 +4 -2
- package/dist/plugins/blog/client/index.d.mts +4 -2
- package/dist/plugins/blog/client/index.d.ts +4 -2
- 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/cms/api/index.d.cts +1 -1
- package/dist/plugins/cms/api/index.d.mts +1 -1
- package/dist/plugins/cms/api/index.d.ts +1 -1
- package/dist/plugins/cms/query-keys.d.cts +1 -1
- package/dist/plugins/cms/query-keys.d.mts +1 -1
- package/dist/plugins/cms/query-keys.d.ts +1 -1
- 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/plugins/ui-builder/client/hooks/index.d.cts +1 -1
- package/dist/plugins/ui-builder/client/hooks/index.d.mts +1 -1
- package/dist/plugins/ui-builder/client/hooks/index.d.ts +1 -1
- package/dist/plugins/ui-builder/client/index.d.cts +1 -1
- package/dist/plugins/ui-builder/client/index.d.mts +1 -1
- package/dist/plugins/ui-builder/client/index.d.ts +1 -1
- package/dist/plugins/ui-builder/query-keys.d.cts +1 -1
- package/dist/plugins/ui-builder/query-keys.d.mts +1 -1
- package/dist/plugins/ui-builder/query-keys.d.ts +1 -1
- package/dist/shared/{stack.BTStHVTy.d.cts → stack.BGzgFx3R.d.cts} +5 -5
- package/dist/shared/{stack.CtrnoQgH.d.cts → stack.BOZRaVpu.d.cts} +35 -35
- package/dist/shared/{stack.94kN3pEK.d.mts → stack.CjCSDfWy.d.mts} +5 -5
- package/dist/shared/{stack.B2EYZyh_.d.ts → stack.DDQTbADz.d.ts} +4 -2
- package/dist/shared/{stack.lPKwd_v0.d.ts → stack.DlBoNqYu.d.ts} +35 -35
- package/dist/shared/{stack.DfrRYOIl.d.ts → stack.Dpg_JjIo.d.ts} +5 -5
- package/dist/shared/{stack.BggTHKlo.d.mts → stack.Dvy7FmaA.d.mts} +35 -35
- package/dist/shared/{stack.fF273jws.d.cts → stack.IY-ngxuw.d.cts} +4 -2
- package/dist/shared/{stack.DivuAnNI.d.mts → stack.mU9iMF2j.d.mts} +4 -2
- package/package.json +1 -1
- package/src/plugins/ai-chat/__tests__/chat-input-authorization.test.tsx +42 -0
- package/src/plugins/ai-chat/__tests__/compaction.test.ts +79 -19
- package/src/plugins/ai-chat/__tests__/persisted-compaction.test.ts +129 -0
- package/src/plugins/ai-chat/api/compaction.ts +137 -13
- package/src/plugins/ai-chat/api/operations.ts +18 -4
- package/src/plugins/ai-chat/api/plugin.ts +10 -1
- package/src/plugins/ai-chat/client/components/chat-input.tsx +3 -3
- package/src/plugins/ai-chat/client/components/chat-interface.tsx +0 -1
- package/src/plugins/blog/__tests__/introduction-slot.test.tsx +86 -0
- package/src/plugins/blog/client/components/pages/post-page.internal.tsx +4 -1
- package/src/plugins/blog/client/components/shared/markdown-content.tsx +8 -1
- package/src/plugins/blog/client/overrides.ts +3 -0
- package/dist/shared/{stack.CyalJ0j6.d.ts → stack.BMlTZnZp.d.ts} +16 -16
- package/dist/shared/{stack.D6Pg-ufX.d.cts → stack.BV0uNV4f.d.cts} +16 -16
- package/dist/shared/{stack.BuxUQqL8.d.ts → stack.CGmh-Lpe.d.ts} +12 -12
- 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.Egr3RWhA.d.mts → stack.Doy2_wgl.d.mts} +12 -12
- package/dist/shared/{stack.B8PG21zX.d.mts → stack.lsbdKRj7.d.mts} +16 -16
- package/dist/shared/{stack.CX83YNuS.d.cts → stack.zch70Loj.d.cts} +12 -12
|
@@ -8,7 +8,7 @@ import '@btst/stack/context';
|
|
|
8
8
|
import '../../permissions.cjs';
|
|
9
9
|
import 'zod';
|
|
10
10
|
import '@btst/stack/plugins/client';
|
|
11
|
-
import '../../../../shared/stack.
|
|
11
|
+
import '../../../../shared/stack.zch70Loj.cjs';
|
|
12
12
|
import '@btst/db';
|
|
13
13
|
import 'zod/v4/core';
|
|
14
14
|
import 'better-call';
|
|
@@ -8,7 +8,7 @@ import '@btst/stack/context';
|
|
|
8
8
|
import '../../permissions.mjs';
|
|
9
9
|
import 'zod';
|
|
10
10
|
import '@btst/stack/plugins/client';
|
|
11
|
-
import '../../../../shared/stack.
|
|
11
|
+
import '../../../../shared/stack.Doy2_wgl.mjs';
|
|
12
12
|
import '@btst/db';
|
|
13
13
|
import 'zod/v4/core';
|
|
14
14
|
import 'better-call';
|
|
@@ -8,7 +8,7 @@ import '@btst/stack/context';
|
|
|
8
8
|
import '../../permissions.js';
|
|
9
9
|
import 'zod';
|
|
10
10
|
import '@btst/stack/plugins/client';
|
|
11
|
-
import '../../../../shared/stack.
|
|
11
|
+
import '../../../../shared/stack.CGmh-Lpe.js';
|
|
12
12
|
import '@btst/db';
|
|
13
13
|
import 'zod/v4/core';
|
|
14
14
|
import 'better-call';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
|
-
import { F as FormsListDiscriminator, S as SubmissionsListDiscriminator, a as FormBuilderApiRouter } from '../../shared/stack.
|
|
3
|
+
import { F as FormsListDiscriminator, S as SubmissionsListDiscriminator, a as FormBuilderApiRouter } from '../../shared/stack.zch70Loj.cjs';
|
|
4
4
|
import { P as PaginatedForms, S as SerializedForm, a as SerializedFormSubmission, e as PaginatedFormSubmissions, d as SerializedFormSubmissionWithData } from '../../shared/stack.v2O65JqF.cjs';
|
|
5
5
|
import { StackIdentity } from '@btst/stack/context';
|
|
6
6
|
import '@btst/stack/plugins/api';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
|
-
import { F as FormsListDiscriminator, S as SubmissionsListDiscriminator, a as FormBuilderApiRouter } from '../../shared/stack.
|
|
3
|
+
import { F as FormsListDiscriminator, S as SubmissionsListDiscriminator, a as FormBuilderApiRouter } from '../../shared/stack.Doy2_wgl.mjs';
|
|
4
4
|
import { P as PaginatedForms, S as SerializedForm, a as SerializedFormSubmission, e as PaginatedFormSubmissions, d as SerializedFormSubmissionWithData } from '../../shared/stack.OYT8WU4n.mjs';
|
|
5
5
|
import { StackIdentity } from '@btst/stack/context';
|
|
6
6
|
import '@btst/stack/plugins/api';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
|
-
import { F as FormsListDiscriminator, S as SubmissionsListDiscriminator, a as FormBuilderApiRouter } from '../../shared/stack.
|
|
3
|
+
import { F as FormsListDiscriminator, S as SubmissionsListDiscriminator, a as FormBuilderApiRouter } from '../../shared/stack.CGmh-Lpe.js';
|
|
4
4
|
import { P as PaginatedForms, S as SerializedForm, a as SerializedFormSubmission, e as PaginatedFormSubmissions, d as SerializedFormSubmissionWithData } from '../../shared/stack.C3bU9w6L.js';
|
|
5
5
|
import { StackIdentity } from '@btst/stack/context';
|
|
6
6
|
import '@btst/stack/plugins/api';
|
|
@@ -9,7 +9,7 @@ import '../../../../shared/stack.fdi94T4S.cjs';
|
|
|
9
9
|
import 'react-hook-form';
|
|
10
10
|
import 'react/jsx-runtime';
|
|
11
11
|
import '@btst/stack/plugins/client';
|
|
12
|
-
import '../../../../shared/stack.
|
|
12
|
+
import '../../../../shared/stack.BV0uNV4f.cjs';
|
|
13
13
|
import '@btst/stack/plugins/api';
|
|
14
14
|
import '../../../../authorization/index.cjs';
|
|
15
15
|
import 'better-call';
|
|
@@ -9,7 +9,7 @@ import '../../../../shared/stack.fdi94T4S.mjs';
|
|
|
9
9
|
import 'react-hook-form';
|
|
10
10
|
import 'react/jsx-runtime';
|
|
11
11
|
import '@btst/stack/plugins/client';
|
|
12
|
-
import '../../../../shared/stack.
|
|
12
|
+
import '../../../../shared/stack.lsbdKRj7.mjs';
|
|
13
13
|
import '@btst/stack/plugins/api';
|
|
14
14
|
import '../../../../authorization/index.mjs';
|
|
15
15
|
import 'better-call';
|
|
@@ -9,7 +9,7 @@ import '../../../../shared/stack.fdi94T4S.js';
|
|
|
9
9
|
import 'react-hook-form';
|
|
10
10
|
import 'react/jsx-runtime';
|
|
11
11
|
import '@btst/stack/plugins/client';
|
|
12
|
-
import '../../../../shared/stack.
|
|
12
|
+
import '../../../../shared/stack.BMlTZnZp.js';
|
|
13
13
|
import '@btst/stack/plugins/api';
|
|
14
14
|
import '../../../../authorization/index.js';
|
|
15
15
|
import 'better-call';
|
|
@@ -15,7 +15,7 @@ import '../../../shared/stack.B3_aDcYL.cjs';
|
|
|
15
15
|
import 'react-hook-form';
|
|
16
16
|
import '@tanstack/react-query';
|
|
17
17
|
import '@btst/stack/plugins/client/hooks';
|
|
18
|
-
import '../../../shared/stack.
|
|
18
|
+
import '../../../shared/stack.BV0uNV4f.cjs';
|
|
19
19
|
import '@btst/stack/plugins/api';
|
|
20
20
|
import '../../../authorization/index.cjs';
|
|
21
21
|
import 'better-call';
|
|
@@ -15,7 +15,7 @@ import '../../../shared/stack.B3_aDcYL.mjs';
|
|
|
15
15
|
import 'react-hook-form';
|
|
16
16
|
import '@tanstack/react-query';
|
|
17
17
|
import '@btst/stack/plugins/client/hooks';
|
|
18
|
-
import '../../../shared/stack.
|
|
18
|
+
import '../../../shared/stack.lsbdKRj7.mjs';
|
|
19
19
|
import '@btst/stack/plugins/api';
|
|
20
20
|
import '../../../authorization/index.mjs';
|
|
21
21
|
import 'better-call';
|
|
@@ -15,7 +15,7 @@ import '../../../shared/stack.B3_aDcYL.js';
|
|
|
15
15
|
import 'react-hook-form';
|
|
16
16
|
import '@tanstack/react-query';
|
|
17
17
|
import '@btst/stack/plugins/client/hooks';
|
|
18
|
-
import '../../../shared/stack.
|
|
18
|
+
import '../../../shared/stack.BMlTZnZp.js';
|
|
19
19
|
import '@btst/stack/plugins/api';
|
|
20
20
|
import '../../../authorization/index.js';
|
|
21
21
|
import 'better-call';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
|
-
import { a as ContentListDiscriminator, C as CMSApiRouter } from '../../shared/stack.
|
|
3
|
+
import { a as ContentListDiscriminator, C as CMSApiRouter } from '../../shared/stack.BV0uNV4f.cjs';
|
|
4
4
|
import { C as ComponentLayer, V as Variable } from '../../shared/stack.DmpPDPxA.cjs';
|
|
5
5
|
import { P as PaginatedContentItems, a as SerializedContentItemWithType } from '../../shared/stack.B3_aDcYL.cjs';
|
|
6
6
|
import { UIBuilderPageSchemaType, PaginatedUIBuilderPages, SerializedUIBuilderPage } from './index.cjs';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
|
-
import { a as ContentListDiscriminator, C as CMSApiRouter } from '../../shared/stack.
|
|
3
|
+
import { a as ContentListDiscriminator, C as CMSApiRouter } from '../../shared/stack.lsbdKRj7.mjs';
|
|
4
4
|
import { C as ComponentLayer, V as Variable } from '../../shared/stack.B1srlBud.mjs';
|
|
5
5
|
import { P as PaginatedContentItems, a as SerializedContentItemWithType } from '../../shared/stack.B3_aDcYL.mjs';
|
|
6
6
|
import { UIBuilderPageSchemaType, PaginatedUIBuilderPages, SerializedUIBuilderPage } from './index.mjs';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
|
-
import { a as ContentListDiscriminator, C as CMSApiRouter } from '../../shared/stack.
|
|
3
|
+
import { a as ContentListDiscriminator, C as CMSApiRouter } from '../../shared/stack.BMlTZnZp.js';
|
|
4
4
|
import { C as ComponentLayer, V as Variable } from '../../shared/stack.BK9Z2dcL.js';
|
|
5
5
|
import { P as PaginatedContentItems, a as SerializedContentItemWithType } from '../../shared/stack.B3_aDcYL.js';
|
|
6
6
|
import { UIBuilderPageSchemaType, PaginatedUIBuilderPages, SerializedUIBuilderPage } from './index.js';
|
|
@@ -2,7 +2,7 @@ import * as _tanstack_react_query from '@tanstack/react-query';
|
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { ResourceFormConfig, ResourceFormResult } from '@btst/stack/plugins/client/hooks';
|
|
4
4
|
import { S as SerializedPost, a as SerializedTag } from './stack.Dsatjh0B.cjs';
|
|
5
|
-
import { c as createPostSchema, u as updatePostSchema } from './stack.
|
|
5
|
+
import { c as createPostSchema, u as updatePostSchema } from './stack.Csi-4Mgz.cjs';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Options for the usePosts hook
|
|
@@ -136,10 +136,6 @@ declare function useSuspenseTags(): {
|
|
|
136
136
|
declare function usePostForm<TValues>(config: ResourceFormConfig<TValues, SerializedPost | null, SerializedPost | null>): ResourceFormResult<TValues, SerializedPost | null, SerializedPost | null>;
|
|
137
137
|
/** Create a new post */
|
|
138
138
|
declare function useCreatePost(): _tanstack_react_query.UseMutationResult<SerializedPost | null, Error, {
|
|
139
|
-
title: string;
|
|
140
|
-
content: string;
|
|
141
|
-
excerpt: string;
|
|
142
|
-
published: boolean;
|
|
143
139
|
tags: ({
|
|
144
140
|
name: string;
|
|
145
141
|
} | {
|
|
@@ -147,6 +143,10 @@ declare function useCreatePost(): _tanstack_react_query.UseMutationResult<Serial
|
|
|
147
143
|
name: string;
|
|
148
144
|
slug: string;
|
|
149
145
|
})[];
|
|
146
|
+
title: string;
|
|
147
|
+
content: string;
|
|
148
|
+
excerpt: string;
|
|
149
|
+
published: boolean;
|
|
150
150
|
slug?: string | undefined;
|
|
151
151
|
publishedAt?: Date | undefined;
|
|
152
152
|
createdAt?: Date | undefined;
|
|
@@ -2,7 +2,7 @@ import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
3
|
import * as zod from 'zod';
|
|
4
4
|
import { z } from 'zod';
|
|
5
|
-
import { c as createPostSchema, u as updatePostSchema } from './stack.
|
|
5
|
+
import { c as createPostSchema, u as updatePostSchema } from './stack.Csi-4Mgz.cjs';
|
|
6
6
|
import { P as Post, T as Tag, S as SerializedPost, a as SerializedTag } from './stack.Dsatjh0B.cjs';
|
|
7
7
|
import * as _btst_stack_plugins_api from '@btst/stack/plugins/api';
|
|
8
8
|
import { DeepReadonly, OperationContext, OperationErrorContext } from '@btst/stack/plugins/api';
|
|
@@ -89,12 +89,6 @@ declare const NextPreviousPostsQuerySchema: z.ZodObject<{
|
|
|
89
89
|
date: z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>;
|
|
90
90
|
}, z.core.$strip>;
|
|
91
91
|
declare const CreatePostOperationInputSchema: z.ZodObject<{
|
|
92
|
-
slug: z.ZodOptional<z.ZodString>;
|
|
93
|
-
title: z.ZodString;
|
|
94
|
-
content: z.ZodString;
|
|
95
|
-
excerpt: z.ZodString;
|
|
96
|
-
image: z.ZodOptional<z.ZodString>;
|
|
97
|
-
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
98
92
|
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
99
93
|
name: z.ZodString;
|
|
100
94
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -102,6 +96,12 @@ declare const CreatePostOperationInputSchema: z.ZodObject<{
|
|
|
102
96
|
name: z.ZodString;
|
|
103
97
|
slug: z.ZodString;
|
|
104
98
|
}, z.core.$strip>]>>>>;
|
|
99
|
+
slug: z.ZodOptional<z.ZodString>;
|
|
100
|
+
title: z.ZodString;
|
|
101
|
+
content: z.ZodString;
|
|
102
|
+
excerpt: z.ZodString;
|
|
103
|
+
image: z.ZodOptional<z.ZodString>;
|
|
104
|
+
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
105
105
|
publishedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
106
106
|
createdAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
107
107
|
updatedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
@@ -109,12 +109,6 @@ declare const CreatePostOperationInputSchema: z.ZodObject<{
|
|
|
109
109
|
declare const UpdatePostOperationInputSchema: z.ZodObject<{
|
|
110
110
|
id: z.ZodString;
|
|
111
111
|
data: z.ZodObject<{
|
|
112
|
-
slug: z.ZodString;
|
|
113
|
-
title: z.ZodString;
|
|
114
|
-
content: z.ZodString;
|
|
115
|
-
excerpt: z.ZodString;
|
|
116
|
-
image: z.ZodOptional<z.ZodString>;
|
|
117
|
-
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
118
112
|
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
119
113
|
name: z.ZodString;
|
|
120
114
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -122,6 +116,12 @@ declare const UpdatePostOperationInputSchema: z.ZodObject<{
|
|
|
122
116
|
name: z.ZodString;
|
|
123
117
|
slug: z.ZodString;
|
|
124
118
|
}, z.core.$strip>]>>>>;
|
|
119
|
+
slug: z.ZodString;
|
|
120
|
+
title: z.ZodString;
|
|
121
|
+
content: z.ZodString;
|
|
122
|
+
excerpt: z.ZodString;
|
|
123
|
+
image: z.ZodOptional<z.ZodString>;
|
|
124
|
+
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
125
125
|
publishedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
126
126
|
createdAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
127
127
|
updatedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
@@ -386,9 +386,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
386
386
|
title: string;
|
|
387
387
|
content: string;
|
|
388
388
|
excerpt: string;
|
|
389
|
-
slug?: string | undefined;
|
|
390
|
-
image?: string | undefined;
|
|
391
|
-
published?: boolean | undefined;
|
|
392
389
|
tags?: ({
|
|
393
390
|
name: string;
|
|
394
391
|
} | {
|
|
@@ -396,6 +393,9 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
396
393
|
name: string;
|
|
397
394
|
slug: string;
|
|
398
395
|
})[] | undefined;
|
|
396
|
+
slug?: string | undefined;
|
|
397
|
+
image?: string | undefined;
|
|
398
|
+
published?: boolean | undefined;
|
|
399
399
|
publishedAt?: unknown;
|
|
400
400
|
createdAt?: unknown;
|
|
401
401
|
updatedAt?: unknown;
|
|
@@ -403,9 +403,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
403
403
|
title: string;
|
|
404
404
|
content: string;
|
|
405
405
|
excerpt: string;
|
|
406
|
-
slug?: string | undefined;
|
|
407
|
-
image?: string | undefined;
|
|
408
|
-
published?: boolean | undefined;
|
|
409
406
|
tags?: ({
|
|
410
407
|
name: string;
|
|
411
408
|
} | {
|
|
@@ -413,6 +410,9 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
413
410
|
name: string;
|
|
414
411
|
slug: string;
|
|
415
412
|
})[] | undefined;
|
|
413
|
+
slug?: string | undefined;
|
|
414
|
+
image?: string | undefined;
|
|
415
|
+
published?: boolean | undefined;
|
|
416
416
|
publishedAt?: unknown;
|
|
417
417
|
createdAt?: unknown;
|
|
418
418
|
updatedAt?: unknown;
|
|
@@ -448,8 +448,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
448
448
|
title: string;
|
|
449
449
|
content: string;
|
|
450
450
|
excerpt: string;
|
|
451
|
-
image?: string | undefined;
|
|
452
|
-
published?: boolean | undefined;
|
|
453
451
|
tags?: ({
|
|
454
452
|
name: string;
|
|
455
453
|
} | {
|
|
@@ -457,6 +455,8 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
457
455
|
name: string;
|
|
458
456
|
slug: string;
|
|
459
457
|
})[] | undefined;
|
|
458
|
+
image?: string | undefined;
|
|
459
|
+
published?: boolean | undefined;
|
|
460
460
|
publishedAt?: unknown;
|
|
461
461
|
createdAt?: unknown;
|
|
462
462
|
updatedAt?: unknown;
|
|
@@ -465,8 +465,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
465
465
|
title: string;
|
|
466
466
|
content: string;
|
|
467
467
|
excerpt: string;
|
|
468
|
-
image?: string | undefined;
|
|
469
|
-
published?: boolean | undefined;
|
|
470
468
|
tags?: ({
|
|
471
469
|
name: string;
|
|
472
470
|
} | {
|
|
@@ -474,6 +472,8 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
474
472
|
name: string;
|
|
475
473
|
slug: string;
|
|
476
474
|
})[] | undefined;
|
|
475
|
+
image?: string | undefined;
|
|
476
|
+
published?: boolean | undefined;
|
|
477
477
|
publishedAt?: unknown;
|
|
478
478
|
createdAt?: unknown;
|
|
479
479
|
updatedAt?: unknown;
|
|
@@ -627,12 +627,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
627
627
|
total: number;
|
|
628
628
|
}, false>;
|
|
629
629
|
readonly createPost: _btst_stack_plugins_api.Operation<zod.ZodObject<{
|
|
630
|
-
slug: zod.ZodOptional<zod.ZodString>;
|
|
631
|
-
title: zod.ZodString;
|
|
632
|
-
content: zod.ZodString;
|
|
633
|
-
excerpt: zod.ZodString;
|
|
634
|
-
image: zod.ZodOptional<zod.ZodString>;
|
|
635
|
-
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
636
630
|
tags: zod.ZodDefault<zod.ZodOptional<zod.ZodArray<zod.ZodUnion<readonly [zod.ZodObject<{
|
|
637
631
|
name: zod.ZodString;
|
|
638
632
|
}, zod_v4_core.$strip>, zod.ZodObject<{
|
|
@@ -640,6 +634,12 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
640
634
|
name: zod.ZodString;
|
|
641
635
|
slug: zod.ZodString;
|
|
642
636
|
}, zod_v4_core.$strip>]>>>>;
|
|
637
|
+
slug: zod.ZodOptional<zod.ZodString>;
|
|
638
|
+
title: zod.ZodString;
|
|
639
|
+
content: zod.ZodString;
|
|
640
|
+
excerpt: zod.ZodString;
|
|
641
|
+
image: zod.ZodOptional<zod.ZodString>;
|
|
642
|
+
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
643
643
|
publishedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
644
644
|
createdAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
645
645
|
updatedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
@@ -673,12 +673,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
673
673
|
readonly updatePost: _btst_stack_plugins_api.Operation<zod.ZodObject<{
|
|
674
674
|
id: zod.ZodString;
|
|
675
675
|
data: zod.ZodObject<{
|
|
676
|
-
slug: zod.ZodString;
|
|
677
|
-
title: zod.ZodString;
|
|
678
|
-
content: zod.ZodString;
|
|
679
|
-
excerpt: zod.ZodString;
|
|
680
|
-
image: zod.ZodOptional<zod.ZodString>;
|
|
681
|
-
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
682
676
|
tags: zod.ZodDefault<zod.ZodOptional<zod.ZodArray<zod.ZodUnion<readonly [zod.ZodObject<{
|
|
683
677
|
name: zod.ZodString;
|
|
684
678
|
}, zod_v4_core.$strip>, zod.ZodObject<{
|
|
@@ -686,6 +680,12 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
686
680
|
name: zod.ZodString;
|
|
687
681
|
slug: zod.ZodString;
|
|
688
682
|
}, zod_v4_core.$strip>]>>>>;
|
|
683
|
+
slug: zod.ZodString;
|
|
684
|
+
title: zod.ZodString;
|
|
685
|
+
content: zod.ZodString;
|
|
686
|
+
excerpt: zod.ZodString;
|
|
687
|
+
image: zod.ZodOptional<zod.ZodString>;
|
|
688
|
+
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
689
689
|
publishedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
690
690
|
createdAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
691
691
|
updatedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
@@ -2,7 +2,7 @@ import * as _tanstack_react_query from '@tanstack/react-query';
|
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { ResourceFormConfig, ResourceFormResult } from '@btst/stack/plugins/client/hooks';
|
|
4
4
|
import { S as SerializedPost, a as SerializedTag } from './stack.Dsatjh0B.mjs';
|
|
5
|
-
import { c as createPostSchema, u as updatePostSchema } from './stack.
|
|
5
|
+
import { c as createPostSchema, u as updatePostSchema } from './stack.Csi-4Mgz.mjs';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Options for the usePosts hook
|
|
@@ -136,10 +136,6 @@ declare function useSuspenseTags(): {
|
|
|
136
136
|
declare function usePostForm<TValues>(config: ResourceFormConfig<TValues, SerializedPost | null, SerializedPost | null>): ResourceFormResult<TValues, SerializedPost | null, SerializedPost | null>;
|
|
137
137
|
/** Create a new post */
|
|
138
138
|
declare function useCreatePost(): _tanstack_react_query.UseMutationResult<SerializedPost | null, Error, {
|
|
139
|
-
title: string;
|
|
140
|
-
content: string;
|
|
141
|
-
excerpt: string;
|
|
142
|
-
published: boolean;
|
|
143
139
|
tags: ({
|
|
144
140
|
name: string;
|
|
145
141
|
} | {
|
|
@@ -147,6 +143,10 @@ declare function useCreatePost(): _tanstack_react_query.UseMutationResult<Serial
|
|
|
147
143
|
name: string;
|
|
148
144
|
slug: string;
|
|
149
145
|
})[];
|
|
146
|
+
title: string;
|
|
147
|
+
content: string;
|
|
148
|
+
excerpt: string;
|
|
149
|
+
published: boolean;
|
|
150
150
|
slug?: string | undefined;
|
|
151
151
|
publishedAt?: Date | undefined;
|
|
152
152
|
createdAt?: Date | undefined;
|
|
@@ -57,10 +57,12 @@ interface AiChatPageContentConfig {
|
|
|
57
57
|
description?: string;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
/** Opt-in context compaction for text
|
|
60
|
+
/** Opt-in context compaction for conversations containing text and images. */
|
|
61
61
|
interface AiChatCompactionConfig {
|
|
62
62
|
/** Actual context window. Configure the model's output limit at or below 20% of this. */
|
|
63
63
|
contextWindowTokens: number;
|
|
64
|
+
/** Estimated tokens per image, excluding encoded bytes. Default: 4096. Increase for models with higher image token costs. */
|
|
65
|
+
imageTokenEstimate?: number;
|
|
64
66
|
}
|
|
65
67
|
|
|
66
68
|
type AiChatAccess = "authorized" | "public";
|
|
@@ -230,7 +232,7 @@ interface AiChatBackendConfig {
|
|
|
230
232
|
*/
|
|
231
233
|
access?: AiChatAccess;
|
|
232
234
|
systemPrompt?: string;
|
|
233
|
-
/** Automatically summarize older
|
|
235
|
+
/** Automatically summarize older text and image context; off by default. */
|
|
234
236
|
compaction?: AiChatCompactionConfig;
|
|
235
237
|
tools?: Record<string, Tool>;
|
|
236
238
|
/** Enable the standard readPage server tool for full page content. Reserves the readPage tool name. */
|
|
@@ -2,7 +2,7 @@ import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
|
2
2
|
import { createApiClient } from '@btst/stack/plugins/client';
|
|
3
3
|
import * as zod from 'zod';
|
|
4
4
|
import { z } from 'zod';
|
|
5
|
-
import { c as createPostSchema, u as updatePostSchema } from './stack.
|
|
5
|
+
import { c as createPostSchema, u as updatePostSchema } from './stack.Csi-4Mgz.js';
|
|
6
6
|
import { P as Post, T as Tag, S as SerializedPost, a as SerializedTag } from './stack.Dsatjh0B.js';
|
|
7
7
|
import * as _btst_stack_plugins_api from '@btst/stack/plugins/api';
|
|
8
8
|
import { DeepReadonly, OperationContext, OperationErrorContext } from '@btst/stack/plugins/api';
|
|
@@ -89,12 +89,6 @@ declare const NextPreviousPostsQuerySchema: z.ZodObject<{
|
|
|
89
89
|
date: z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>;
|
|
90
90
|
}, z.core.$strip>;
|
|
91
91
|
declare const CreatePostOperationInputSchema: z.ZodObject<{
|
|
92
|
-
slug: z.ZodOptional<z.ZodString>;
|
|
93
|
-
title: z.ZodString;
|
|
94
|
-
content: z.ZodString;
|
|
95
|
-
excerpt: z.ZodString;
|
|
96
|
-
image: z.ZodOptional<z.ZodString>;
|
|
97
|
-
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
98
92
|
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
99
93
|
name: z.ZodString;
|
|
100
94
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -102,6 +96,12 @@ declare const CreatePostOperationInputSchema: z.ZodObject<{
|
|
|
102
96
|
name: z.ZodString;
|
|
103
97
|
slug: z.ZodString;
|
|
104
98
|
}, z.core.$strip>]>>>>;
|
|
99
|
+
slug: z.ZodOptional<z.ZodString>;
|
|
100
|
+
title: z.ZodString;
|
|
101
|
+
content: z.ZodString;
|
|
102
|
+
excerpt: z.ZodString;
|
|
103
|
+
image: z.ZodOptional<z.ZodString>;
|
|
104
|
+
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
105
105
|
publishedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
106
106
|
createdAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
107
107
|
updatedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
@@ -109,12 +109,6 @@ declare const CreatePostOperationInputSchema: z.ZodObject<{
|
|
|
109
109
|
declare const UpdatePostOperationInputSchema: z.ZodObject<{
|
|
110
110
|
id: z.ZodString;
|
|
111
111
|
data: z.ZodObject<{
|
|
112
|
-
slug: z.ZodString;
|
|
113
|
-
title: z.ZodString;
|
|
114
|
-
content: z.ZodString;
|
|
115
|
-
excerpt: z.ZodString;
|
|
116
|
-
image: z.ZodOptional<z.ZodString>;
|
|
117
|
-
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
118
112
|
tags: z.ZodDefault<z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
|
|
119
113
|
name: z.ZodString;
|
|
120
114
|
}, z.core.$strip>, z.ZodObject<{
|
|
@@ -122,6 +116,12 @@ declare const UpdatePostOperationInputSchema: z.ZodObject<{
|
|
|
122
116
|
name: z.ZodString;
|
|
123
117
|
slug: z.ZodString;
|
|
124
118
|
}, z.core.$strip>]>>>>;
|
|
119
|
+
slug: z.ZodString;
|
|
120
|
+
title: z.ZodString;
|
|
121
|
+
content: z.ZodString;
|
|
122
|
+
excerpt: z.ZodString;
|
|
123
|
+
image: z.ZodOptional<z.ZodString>;
|
|
124
|
+
published: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
125
125
|
publishedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
126
126
|
createdAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
127
127
|
updatedAt: z.ZodOptional<z.ZodPipe<z.ZodCoercedDate<unknown>, z.ZodTransform<string, Date>>>;
|
|
@@ -386,9 +386,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
386
386
|
title: string;
|
|
387
387
|
content: string;
|
|
388
388
|
excerpt: string;
|
|
389
|
-
slug?: string | undefined;
|
|
390
|
-
image?: string | undefined;
|
|
391
|
-
published?: boolean | undefined;
|
|
392
389
|
tags?: ({
|
|
393
390
|
name: string;
|
|
394
391
|
} | {
|
|
@@ -396,6 +393,9 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
396
393
|
name: string;
|
|
397
394
|
slug: string;
|
|
398
395
|
})[] | undefined;
|
|
396
|
+
slug?: string | undefined;
|
|
397
|
+
image?: string | undefined;
|
|
398
|
+
published?: boolean | undefined;
|
|
399
399
|
publishedAt?: unknown;
|
|
400
400
|
createdAt?: unknown;
|
|
401
401
|
updatedAt?: unknown;
|
|
@@ -403,9 +403,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
403
403
|
title: string;
|
|
404
404
|
content: string;
|
|
405
405
|
excerpt: string;
|
|
406
|
-
slug?: string | undefined;
|
|
407
|
-
image?: string | undefined;
|
|
408
|
-
published?: boolean | undefined;
|
|
409
406
|
tags?: ({
|
|
410
407
|
name: string;
|
|
411
408
|
} | {
|
|
@@ -413,6 +410,9 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
413
410
|
name: string;
|
|
414
411
|
slug: string;
|
|
415
412
|
})[] | undefined;
|
|
413
|
+
slug?: string | undefined;
|
|
414
|
+
image?: string | undefined;
|
|
415
|
+
published?: boolean | undefined;
|
|
416
416
|
publishedAt?: unknown;
|
|
417
417
|
createdAt?: unknown;
|
|
418
418
|
updatedAt?: unknown;
|
|
@@ -448,8 +448,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
448
448
|
title: string;
|
|
449
449
|
content: string;
|
|
450
450
|
excerpt: string;
|
|
451
|
-
image?: string | undefined;
|
|
452
|
-
published?: boolean | undefined;
|
|
453
451
|
tags?: ({
|
|
454
452
|
name: string;
|
|
455
453
|
} | {
|
|
@@ -457,6 +455,8 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
457
455
|
name: string;
|
|
458
456
|
slug: string;
|
|
459
457
|
})[] | undefined;
|
|
458
|
+
image?: string | undefined;
|
|
459
|
+
published?: boolean | undefined;
|
|
460
460
|
publishedAt?: unknown;
|
|
461
461
|
createdAt?: unknown;
|
|
462
462
|
updatedAt?: unknown;
|
|
@@ -465,8 +465,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
465
465
|
title: string;
|
|
466
466
|
content: string;
|
|
467
467
|
excerpt: string;
|
|
468
|
-
image?: string | undefined;
|
|
469
|
-
published?: boolean | undefined;
|
|
470
468
|
tags?: ({
|
|
471
469
|
name: string;
|
|
472
470
|
} | {
|
|
@@ -474,6 +472,8 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
474
472
|
name: string;
|
|
475
473
|
slug: string;
|
|
476
474
|
})[] | undefined;
|
|
475
|
+
image?: string | undefined;
|
|
476
|
+
published?: boolean | undefined;
|
|
477
477
|
publishedAt?: unknown;
|
|
478
478
|
createdAt?: unknown;
|
|
479
479
|
updatedAt?: unknown;
|
|
@@ -627,12 +627,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
627
627
|
total: number;
|
|
628
628
|
}, false>;
|
|
629
629
|
readonly createPost: _btst_stack_plugins_api.Operation<zod.ZodObject<{
|
|
630
|
-
slug: zod.ZodOptional<zod.ZodString>;
|
|
631
|
-
title: zod.ZodString;
|
|
632
|
-
content: zod.ZodString;
|
|
633
|
-
excerpt: zod.ZodString;
|
|
634
|
-
image: zod.ZodOptional<zod.ZodString>;
|
|
635
|
-
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
636
630
|
tags: zod.ZodDefault<zod.ZodOptional<zod.ZodArray<zod.ZodUnion<readonly [zod.ZodObject<{
|
|
637
631
|
name: zod.ZodString;
|
|
638
632
|
}, zod_v4_core.$strip>, zod.ZodObject<{
|
|
@@ -640,6 +634,12 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
640
634
|
name: zod.ZodString;
|
|
641
635
|
slug: zod.ZodString;
|
|
642
636
|
}, zod_v4_core.$strip>]>>>>;
|
|
637
|
+
slug: zod.ZodOptional<zod.ZodString>;
|
|
638
|
+
title: zod.ZodString;
|
|
639
|
+
content: zod.ZodString;
|
|
640
|
+
excerpt: zod.ZodString;
|
|
641
|
+
image: zod.ZodOptional<zod.ZodString>;
|
|
642
|
+
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
643
643
|
publishedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
644
644
|
createdAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
645
645
|
updatedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
@@ -673,12 +673,6 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
673
673
|
readonly updatePost: _btst_stack_plugins_api.Operation<zod.ZodObject<{
|
|
674
674
|
id: zod.ZodString;
|
|
675
675
|
data: zod.ZodObject<{
|
|
676
|
-
slug: zod.ZodString;
|
|
677
|
-
title: zod.ZodString;
|
|
678
|
-
content: zod.ZodString;
|
|
679
|
-
excerpt: zod.ZodString;
|
|
680
|
-
image: zod.ZodOptional<zod.ZodString>;
|
|
681
|
-
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
682
676
|
tags: zod.ZodDefault<zod.ZodOptional<zod.ZodArray<zod.ZodUnion<readonly [zod.ZodObject<{
|
|
683
677
|
name: zod.ZodString;
|
|
684
678
|
}, zod_v4_core.$strip>, zod.ZodObject<{
|
|
@@ -686,6 +680,12 @@ declare const blogBackendPlugin: (options?: BlogBackendOptions) => _btst_stack_p
|
|
|
686
680
|
name: zod.ZodString;
|
|
687
681
|
slug: zod.ZodString;
|
|
688
682
|
}, zod_v4_core.$strip>]>>>>;
|
|
683
|
+
slug: zod.ZodString;
|
|
684
|
+
title: zod.ZodString;
|
|
685
|
+
content: zod.ZodString;
|
|
686
|
+
excerpt: zod.ZodString;
|
|
687
|
+
image: zod.ZodOptional<zod.ZodString>;
|
|
688
|
+
published: zod.ZodDefault<zod.ZodOptional<zod.ZodBoolean>>;
|
|
689
689
|
publishedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
690
690
|
createdAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
691
691
|
updatedAt: zod.ZodOptional<zod.ZodPipe<zod.ZodCoercedDate<unknown>, zod.ZodTransform<string, Date>>>;
|
|
@@ -2,7 +2,7 @@ import * as _tanstack_react_query from '@tanstack/react-query';
|
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
import { ResourceFormConfig, ResourceFormResult } from '@btst/stack/plugins/client/hooks';
|
|
4
4
|
import { S as SerializedPost, a as SerializedTag } from './stack.Dsatjh0B.js';
|
|
5
|
-
import { c as createPostSchema, u as updatePostSchema } from './stack.
|
|
5
|
+
import { c as createPostSchema, u as updatePostSchema } from './stack.Csi-4Mgz.js';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Options for the usePosts hook
|
|
@@ -136,10 +136,6 @@ declare function useSuspenseTags(): {
|
|
|
136
136
|
declare function usePostForm<TValues>(config: ResourceFormConfig<TValues, SerializedPost | null, SerializedPost | null>): ResourceFormResult<TValues, SerializedPost | null, SerializedPost | null>;
|
|
137
137
|
/** Create a new post */
|
|
138
138
|
declare function useCreatePost(): _tanstack_react_query.UseMutationResult<SerializedPost | null, Error, {
|
|
139
|
-
title: string;
|
|
140
|
-
content: string;
|
|
141
|
-
excerpt: string;
|
|
142
|
-
published: boolean;
|
|
143
139
|
tags: ({
|
|
144
140
|
name: string;
|
|
145
141
|
} | {
|
|
@@ -147,6 +143,10 @@ declare function useCreatePost(): _tanstack_react_query.UseMutationResult<Serial
|
|
|
147
143
|
name: string;
|
|
148
144
|
slug: string;
|
|
149
145
|
})[];
|
|
146
|
+
title: string;
|
|
147
|
+
content: string;
|
|
148
|
+
excerpt: string;
|
|
149
|
+
published: boolean;
|
|
150
150
|
slug?: string | undefined;
|
|
151
151
|
publishedAt?: Date | undefined;
|
|
152
152
|
createdAt?: Date | undefined;
|