@btst/stack 1.1.3 → 1.1.4
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/plugins/blog/api/index.d.cts +1 -1
- package/dist/plugins/blog/api/index.d.mts +1 -1
- package/dist/plugins/blog/api/index.d.ts +1 -1
- package/dist/plugins/blog/client/hooks/index.d.cts +3 -3
- package/dist/plugins/blog/client/hooks/index.d.mts +3 -3
- package/dist/plugins/blog/client/hooks/index.d.ts +3 -3
- package/dist/plugins/blog/client/index.d.cts +178 -165
- package/dist/plugins/blog/client/index.d.mts +178 -165
- package/dist/plugins/blog/client/index.d.ts +178 -165
- package/dist/plugins/blog/query-keys.d.cts +5 -5
- package/dist/plugins/blog/query-keys.d.mts +5 -5
- package/dist/plugins/blog/query-keys.d.ts +5 -5
- package/dist/plugins/client/index.d.cts +3 -8
- package/dist/plugins/client/index.d.mts +3 -8
- package/dist/plugins/client/index.d.ts +3 -8
- package/package.json +1 -1
- package/src/plugins/client/index.ts +5 -15
- package/dist/shared/{stack.CoPoHVfV.d.cts → stack.CbuN2zVV.d.cts} +2 -2
- package/dist/shared/{stack.CoPoHVfV.d.mts → stack.CbuN2zVV.d.mts} +2 -2
- package/dist/shared/{stack.CoPoHVfV.d.ts → stack.CbuN2zVV.d.ts} +2 -2
|
@@ -2,6 +2,6 @@ export { B as BlogApiContext, c as BlogApiRouter, a as BlogBackendHooks, N as Ne
|
|
|
2
2
|
import '@btst/stack/plugins/api';
|
|
3
3
|
import 'better-call';
|
|
4
4
|
import 'zod';
|
|
5
|
-
import '../../../shared/stack.
|
|
5
|
+
import '../../../shared/stack.CbuN2zVV.cjs';
|
|
6
6
|
import '@tanstack/react-query';
|
|
7
7
|
import '@btst/stack/plugins/client';
|
|
@@ -2,6 +2,6 @@ export { B as BlogApiContext, c as BlogApiRouter, a as BlogBackendHooks, N as Ne
|
|
|
2
2
|
import '@btst/stack/plugins/api';
|
|
3
3
|
import 'better-call';
|
|
4
4
|
import 'zod';
|
|
5
|
-
import '../../../shared/stack.
|
|
5
|
+
import '../../../shared/stack.CbuN2zVV.mjs';
|
|
6
6
|
import '@tanstack/react-query';
|
|
7
7
|
import '@btst/stack/plugins/client';
|
|
@@ -2,6 +2,6 @@ export { B as BlogApiContext, c as BlogApiRouter, a as BlogBackendHooks, N as Ne
|
|
|
2
2
|
import '@btst/stack/plugins/api';
|
|
3
3
|
import 'better-call';
|
|
4
4
|
import 'zod';
|
|
5
|
-
import '../../../shared/stack.
|
|
5
|
+
import '../../../shared/stack.CbuN2zVV.js';
|
|
6
6
|
import '@tanstack/react-query';
|
|
7
7
|
import '@btst/stack/plugins/client';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
|
-
import { S as SerializedPost, c as createPostSchema, u as updatePostSchema, a as SerializedTag } from '../../../../shared/stack.
|
|
2
|
+
import { S as SerializedPost, c as createPostSchema, u as updatePostSchema, a as SerializedTag } from '../../../../shared/stack.CbuN2zVV.cjs';
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
|
|
5
5
|
interface UsePostsOptions {
|
|
@@ -81,10 +81,10 @@ declare function useSuspenseTags(): {
|
|
|
81
81
|
};
|
|
82
82
|
/** Create a new post */
|
|
83
83
|
declare function useCreatePost(): _tanstack_react_query.UseMutationResult<SerializedPost | null, Error, {
|
|
84
|
-
published: boolean;
|
|
85
84
|
title: string;
|
|
86
85
|
content: string;
|
|
87
86
|
excerpt: string;
|
|
87
|
+
published: boolean;
|
|
88
88
|
tags: ({
|
|
89
89
|
name: string;
|
|
90
90
|
} | {
|
|
@@ -93,8 +93,8 @@ declare function useCreatePost(): _tanstack_react_query.UseMutationResult<Serial
|
|
|
93
93
|
slug: string;
|
|
94
94
|
})[];
|
|
95
95
|
slug?: string | undefined;
|
|
96
|
-
createdAt?: Date | undefined;
|
|
97
96
|
publishedAt?: Date | undefined;
|
|
97
|
+
createdAt?: Date | undefined;
|
|
98
98
|
updatedAt?: Date | undefined;
|
|
99
99
|
image?: string | undefined;
|
|
100
100
|
}, unknown>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
|
-
import { S as SerializedPost, c as createPostSchema, u as updatePostSchema, a as SerializedTag } from '../../../../shared/stack.
|
|
2
|
+
import { S as SerializedPost, c as createPostSchema, u as updatePostSchema, a as SerializedTag } from '../../../../shared/stack.CbuN2zVV.mjs';
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
|
|
5
5
|
interface UsePostsOptions {
|
|
@@ -81,10 +81,10 @@ declare function useSuspenseTags(): {
|
|
|
81
81
|
};
|
|
82
82
|
/** Create a new post */
|
|
83
83
|
declare function useCreatePost(): _tanstack_react_query.UseMutationResult<SerializedPost | null, Error, {
|
|
84
|
-
published: boolean;
|
|
85
84
|
title: string;
|
|
86
85
|
content: string;
|
|
87
86
|
excerpt: string;
|
|
87
|
+
published: boolean;
|
|
88
88
|
tags: ({
|
|
89
89
|
name: string;
|
|
90
90
|
} | {
|
|
@@ -93,8 +93,8 @@ declare function useCreatePost(): _tanstack_react_query.UseMutationResult<Serial
|
|
|
93
93
|
slug: string;
|
|
94
94
|
})[];
|
|
95
95
|
slug?: string | undefined;
|
|
96
|
-
createdAt?: Date | undefined;
|
|
97
96
|
publishedAt?: Date | undefined;
|
|
97
|
+
createdAt?: Date | undefined;
|
|
98
98
|
updatedAt?: Date | undefined;
|
|
99
99
|
image?: string | undefined;
|
|
100
100
|
}, unknown>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
|
-
import { S as SerializedPost, c as createPostSchema, u as updatePostSchema, a as SerializedTag } from '../../../../shared/stack.
|
|
2
|
+
import { S as SerializedPost, c as createPostSchema, u as updatePostSchema, a as SerializedTag } from '../../../../shared/stack.CbuN2zVV.js';
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
|
|
5
5
|
interface UsePostsOptions {
|
|
@@ -81,10 +81,10 @@ declare function useSuspenseTags(): {
|
|
|
81
81
|
};
|
|
82
82
|
/** Create a new post */
|
|
83
83
|
declare function useCreatePost(): _tanstack_react_query.UseMutationResult<SerializedPost | null, Error, {
|
|
84
|
-
published: boolean;
|
|
85
84
|
title: string;
|
|
86
85
|
content: string;
|
|
87
86
|
excerpt: string;
|
|
87
|
+
published: boolean;
|
|
88
88
|
tags: ({
|
|
89
89
|
name: string;
|
|
90
90
|
} | {
|
|
@@ -93,8 +93,8 @@ declare function useCreatePost(): _tanstack_react_query.UseMutationResult<Serial
|
|
|
93
93
|
slug: string;
|
|
94
94
|
})[];
|
|
95
95
|
slug?: string | undefined;
|
|
96
|
-
createdAt?: Date | undefined;
|
|
97
96
|
publishedAt?: Date | undefined;
|
|
97
|
+
createdAt?: Date | undefined;
|
|
98
98
|
updatedAt?: Date | undefined;
|
|
99
99
|
image?: string | undefined;
|
|
100
100
|
}, unknown>;
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
2
1
|
import * as react from 'react';
|
|
3
2
|
import { ComponentType } from 'react';
|
|
4
3
|
import * as _btst_yar from '@btst/yar';
|
|
5
4
|
import { QueryClient } from '@tanstack/react-query';
|
|
6
|
-
import { P as Post, S as SerializedPost } from '../../../shared/stack.
|
|
5
|
+
import { P as Post, S as SerializedPost } from '../../../shared/stack.CbuN2zVV.cjs';
|
|
7
6
|
export { UsePostsOptions, UsePostsResult } from './hooks/index.cjs';
|
|
8
7
|
import 'zod';
|
|
9
8
|
|
|
@@ -67,176 +66,190 @@ interface BlogClientHooks {
|
|
|
67
66
|
*
|
|
68
67
|
* @param config - Configuration including queryClient, baseURL, and optional hooks
|
|
69
68
|
*/
|
|
70
|
-
declare const blogClientPlugin: (config: BlogClientConfig) =>
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
69
|
+
declare const blogClientPlugin: (config: BlogClientConfig) => {
|
|
70
|
+
name: string;
|
|
71
|
+
routes: () => {
|
|
72
|
+
posts: {
|
|
73
|
+
(inputCtx_0?: _btst_yar.InputContext<"/blog", _btst_yar.RouteOptions> | undefined): {
|
|
74
|
+
PageComponent?: react.ComponentType<unknown> | undefined;
|
|
75
|
+
LoadingComponent?: react.ComponentType<unknown> | undefined;
|
|
76
|
+
ErrorComponent?: react.ComponentType<unknown> | undefined;
|
|
77
|
+
loader?: (() => Promise<void>) | undefined;
|
|
78
|
+
meta?: (() => ({
|
|
79
|
+
title: string;
|
|
80
|
+
name?: undefined;
|
|
81
|
+
content?: undefined;
|
|
82
|
+
property?: undefined;
|
|
83
|
+
} | {
|
|
84
|
+
name: string;
|
|
85
|
+
content: string;
|
|
86
|
+
title?: undefined;
|
|
87
|
+
property?: undefined;
|
|
88
|
+
} | {
|
|
89
|
+
property: string;
|
|
90
|
+
content: string;
|
|
91
|
+
title?: undefined;
|
|
92
|
+
name?: undefined;
|
|
93
|
+
})[]) | undefined;
|
|
94
|
+
extra?: (() => any) | undefined;
|
|
95
|
+
};
|
|
96
|
+
options: _btst_yar.RouteOptions | undefined;
|
|
97
|
+
path: "/blog";
|
|
98
|
+
meta: _btst_yar.RouteMeta | undefined;
|
|
94
99
|
};
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
100
|
+
drafts: {
|
|
101
|
+
(inputCtx_0?: _btst_yar.InputContext<"/blog/drafts", _btst_yar.RouteOptions> | undefined): {
|
|
102
|
+
PageComponent?: react.ComponentType<unknown> | undefined;
|
|
103
|
+
LoadingComponent?: react.ComponentType<unknown> | undefined;
|
|
104
|
+
ErrorComponent?: react.ComponentType<unknown> | undefined;
|
|
105
|
+
loader?: (() => Promise<void>) | undefined;
|
|
106
|
+
meta?: (() => ({
|
|
107
|
+
title: string;
|
|
108
|
+
name?: undefined;
|
|
109
|
+
content?: undefined;
|
|
110
|
+
property?: undefined;
|
|
111
|
+
} | {
|
|
112
|
+
name: string;
|
|
113
|
+
content: string;
|
|
114
|
+
title?: undefined;
|
|
115
|
+
property?: undefined;
|
|
116
|
+
} | {
|
|
117
|
+
property: string;
|
|
118
|
+
content: string;
|
|
119
|
+
title?: undefined;
|
|
120
|
+
name?: undefined;
|
|
121
|
+
})[]) | undefined;
|
|
122
|
+
extra?: (() => any) | undefined;
|
|
123
|
+
};
|
|
124
|
+
options: _btst_yar.RouteOptions | undefined;
|
|
125
|
+
path: "/blog/drafts";
|
|
126
|
+
meta: _btst_yar.RouteMeta | undefined;
|
|
122
127
|
};
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
128
|
+
newPost: {
|
|
129
|
+
(inputCtx_0?: _btst_yar.InputContext<"/blog/new", _btst_yar.RouteOptions> | undefined): {
|
|
130
|
+
PageComponent?: react.ComponentType<unknown> | undefined;
|
|
131
|
+
LoadingComponent?: react.ComponentType<unknown> | undefined;
|
|
132
|
+
ErrorComponent?: react.ComponentType<unknown> | undefined;
|
|
133
|
+
loader?: (() => any) | undefined;
|
|
134
|
+
meta?: (() => ({
|
|
135
|
+
title: string;
|
|
136
|
+
name?: undefined;
|
|
137
|
+
content?: undefined;
|
|
138
|
+
property?: undefined;
|
|
139
|
+
} | {
|
|
140
|
+
name: string;
|
|
141
|
+
content: string;
|
|
142
|
+
title?: undefined;
|
|
143
|
+
property?: undefined;
|
|
144
|
+
} | {
|
|
145
|
+
property: string;
|
|
146
|
+
content: string;
|
|
147
|
+
title?: undefined;
|
|
148
|
+
name?: undefined;
|
|
149
|
+
})[]) | undefined;
|
|
150
|
+
extra?: (() => any) | undefined;
|
|
151
|
+
};
|
|
152
|
+
options: _btst_yar.RouteOptions | undefined;
|
|
153
|
+
path: "/blog/new";
|
|
154
|
+
meta: _btst_yar.RouteMeta | undefined;
|
|
150
155
|
};
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
156
|
+
editPost: {
|
|
157
|
+
(inputCtx_0: _btst_yar.InputContext<"/blog/:slug/edit", _btst_yar.RouteOptions>): {
|
|
158
|
+
PageComponent?: react.ComponentType<unknown> | undefined;
|
|
159
|
+
LoadingComponent?: react.ComponentType<unknown> | undefined;
|
|
160
|
+
ErrorComponent?: react.ComponentType<unknown> | undefined;
|
|
161
|
+
loader?: (() => Promise<void>) | undefined;
|
|
162
|
+
meta?: (() => ({
|
|
163
|
+
title: string;
|
|
164
|
+
name?: undefined;
|
|
165
|
+
content?: undefined;
|
|
166
|
+
property?: undefined;
|
|
167
|
+
} | {
|
|
168
|
+
name: string;
|
|
169
|
+
content: string;
|
|
170
|
+
title?: undefined;
|
|
171
|
+
property?: undefined;
|
|
172
|
+
} | {
|
|
173
|
+
property: string;
|
|
174
|
+
content: string;
|
|
175
|
+
title?: undefined;
|
|
176
|
+
name?: undefined;
|
|
177
|
+
})[]) | undefined;
|
|
178
|
+
extra?: (() => any) | undefined;
|
|
179
|
+
};
|
|
180
|
+
options: _btst_yar.RouteOptions | undefined;
|
|
181
|
+
path: "/blog/:slug/edit";
|
|
182
|
+
meta: _btst_yar.RouteMeta | undefined;
|
|
178
183
|
};
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
184
|
+
tag: {
|
|
185
|
+
(inputCtx_0: _btst_yar.InputContext<"/blog/tag/:tagSlug", _btst_yar.RouteOptions>): {
|
|
186
|
+
PageComponent?: react.ComponentType<unknown> | undefined;
|
|
187
|
+
LoadingComponent?: react.ComponentType<unknown> | undefined;
|
|
188
|
+
ErrorComponent?: react.ComponentType<unknown> | undefined;
|
|
189
|
+
loader?: (() => Promise<void>) | undefined;
|
|
190
|
+
meta?: (() => ({
|
|
191
|
+
title: string;
|
|
192
|
+
name?: undefined;
|
|
193
|
+
content?: undefined;
|
|
194
|
+
property?: undefined;
|
|
195
|
+
} | {
|
|
196
|
+
name: string;
|
|
197
|
+
content: string;
|
|
198
|
+
title?: undefined;
|
|
199
|
+
property?: undefined;
|
|
200
|
+
} | {
|
|
201
|
+
property: string;
|
|
202
|
+
content: string;
|
|
203
|
+
title?: undefined;
|
|
204
|
+
name?: undefined;
|
|
205
|
+
})[]) | undefined;
|
|
206
|
+
extra?: (() => any) | undefined;
|
|
207
|
+
};
|
|
208
|
+
options: _btst_yar.RouteOptions | undefined;
|
|
209
|
+
path: "/blog/tag/:tagSlug";
|
|
210
|
+
meta: _btst_yar.RouteMeta | undefined;
|
|
206
211
|
};
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
212
|
+
post: {
|
|
213
|
+
(inputCtx_0: _btst_yar.InputContext<"/blog/:slug", _btst_yar.RouteOptions>): {
|
|
214
|
+
PageComponent?: react.ComponentType<unknown> | undefined;
|
|
215
|
+
LoadingComponent?: react.ComponentType<unknown> | undefined;
|
|
216
|
+
ErrorComponent?: react.ComponentType<unknown> | undefined;
|
|
217
|
+
loader?: (() => Promise<void>) | undefined;
|
|
218
|
+
meta?: (() => ({
|
|
219
|
+
title: string;
|
|
220
|
+
name?: undefined;
|
|
221
|
+
content?: undefined;
|
|
222
|
+
property?: undefined;
|
|
223
|
+
} | {
|
|
224
|
+
name: string;
|
|
225
|
+
content: string | undefined;
|
|
226
|
+
title?: undefined;
|
|
227
|
+
property?: undefined;
|
|
228
|
+
} | {
|
|
229
|
+
property: string;
|
|
230
|
+
content: string;
|
|
231
|
+
title?: undefined;
|
|
232
|
+
name?: undefined;
|
|
233
|
+
})[]) | undefined;
|
|
234
|
+
extra?: (() => any) | undefined;
|
|
235
|
+
};
|
|
236
|
+
options: _btst_yar.RouteOptions | undefined;
|
|
237
|
+
path: "/blog/:slug";
|
|
238
|
+
meta: _btst_yar.RouteMeta | undefined;
|
|
234
239
|
};
|
|
235
|
-
options: _btst_yar.RouteOptions | undefined;
|
|
236
|
-
path: "/blog/:slug";
|
|
237
|
-
meta: _btst_yar.RouteMeta | undefined;
|
|
238
240
|
};
|
|
239
|
-
|
|
241
|
+
sitemap: () => Promise<({
|
|
242
|
+
url: string;
|
|
243
|
+
lastModified: Date | undefined;
|
|
244
|
+
changeFrequency: "monthly";
|
|
245
|
+
priority: number;
|
|
246
|
+
} | {
|
|
247
|
+
url: string;
|
|
248
|
+
lastModified: Date | undefined;
|
|
249
|
+
changeFrequency: "daily";
|
|
250
|
+
priority: number;
|
|
251
|
+
})[]>;
|
|
252
|
+
};
|
|
240
253
|
|
|
241
254
|
declare const BLOG_LOCALIZATION: {
|
|
242
255
|
BLOG_FORMS_TITLE_LABEL: string;
|