@btst/stack 4.1.1 → 4.2.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/packages/stack/src/plugins/ai-chat/api/operations.cjs +15 -9
- package/dist/packages/stack/src/plugins/ai-chat/api/operations.mjs +16 -10
- package/dist/packages/stack/src/plugins/ai-chat/api/page-tools.cjs +28 -0
- package/dist/packages/stack/src/plugins/ai-chat/api/page-tools.mjs +29 -2
- 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-interface.cjs +91 -8
- package/dist/packages/stack/src/plugins/ai-chat/client/components/chat-interface.mjs +91 -8
- package/dist/packages/stack/src/plugins/ai-chat/client/components/chat-layout.cjs +76 -3
- package/dist/packages/stack/src/plugins/ai-chat/client/components/chat-layout.mjs +80 -7
- package/dist/packages/stack/src/plugins/ai-chat/client/components/tool-call-display.cjs +17 -0
- package/dist/packages/stack/src/plugins/ai-chat/client/components/tool-call-display.mjs +18 -1
- package/dist/packages/stack/src/plugins/ai-chat/client/context/chat-analytics.cjs +42 -0
- package/dist/packages/stack/src/plugins/ai-chat/client/context/chat-analytics.mjs +39 -0
- package/dist/packages/stack/src/plugins/ai-chat/client/plugin.cjs +2 -1
- package/dist/packages/stack/src/plugins/ai-chat/client/plugin.mjs +2 -1
- 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/components/index.d.cts +2 -1
- package/dist/plugins/ai-chat/client/components/index.d.mts +2 -1
- package/dist/plugins/ai-chat/client/components/index.d.ts +2 -1
- package/dist/plugins/ai-chat/client/context/page-ai-context.cjs +4 -0
- package/dist/plugins/ai-chat/client/context/page-ai-context.d.cts +6 -2
- package/dist/plugins/ai-chat/client/context/page-ai-context.d.mts +6 -2
- package/dist/plugins/ai-chat/client/context/page-ai-context.d.ts +6 -2
- package/dist/plugins/ai-chat/client/context/page-ai-context.mjs +4 -1
- 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 +7 -3
- package/dist/plugins/ai-chat/client/index.d.mts +7 -3
- package/dist/plugins/ai-chat/client/index.d.ts +7 -3
- 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 +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/query-keys.d.cts +1 -1
- package/dist/plugins/blog/query-keys.d.mts +1 -1
- package/dist/plugins/blog/query-keys.d.ts +1 -1
- 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.B5yPgHsp.d.mts → stack.B7Mj74BQ.d.mts} +18 -2
- package/dist/shared/{stack.rVF0f509.d.mts → stack.C-eQN_Jt.d.ts} +60 -4
- package/dist/shared/{stack.rVF0f509.d.ts → stack.C5FZr-jJ.d.mts} +60 -4
- package/dist/shared/{stack.3Sr6qRtT.d.ts → stack.DBH1Bjko.d.ts} +18 -2
- package/dist/shared/{stack.C4oVW2qK.d.cts → stack.Dgt3MCtW.d.cts} +18 -2
- package/dist/shared/{stack.rVF0f509.d.cts → stack.xAiy2VtO.d.cts} +60 -4
- package/package.json +1 -1
- package/src/plugins/ai-chat/__tests__/authorization.test.ts +106 -1
- package/src/plugins/ai-chat/__tests__/classnames-overrides.test.tsx +4 -1
- package/src/plugins/ai-chat/__tests__/page-content.test.ts +177 -0
- package/src/plugins/ai-chat/__tests__/page-widget.test.tsx +573 -0
- package/src/plugins/ai-chat/api/operations.ts +29 -13
- package/src/plugins/ai-chat/api/page-tools.ts +56 -2
- package/src/plugins/ai-chat/api/plugin.ts +13 -0
- package/src/plugins/ai-chat/client/analytics.ts +35 -0
- package/src/plugins/ai-chat/client/components/chat-interface.tsx +113 -10
- package/src/plugins/ai-chat/client/components/chat-layout.tsx +118 -7
- package/src/plugins/ai-chat/client/components/tool-call-display.tsx +29 -1
- package/src/plugins/ai-chat/client/context/chat-analytics.tsx +46 -0
- package/src/plugins/ai-chat/client/context/page-ai-context.tsx +9 -1
- package/src/plugins/ai-chat/client/index.ts +2 -0
- package/src/plugins/ai-chat/client/localization/index.ts +8 -0
- package/src/plugins/ai-chat/client/overrides.ts +5 -0
- package/src/plugins/ai-chat/client/plugin.tsx +3 -0
- package/dist/shared/{stack.lsbdKRj7.d.mts → stack.B8PG21zX.d.mts} +16 -16
- package/dist/shared/{stack.BuxUQqL8.d.ts → stack.CGmh-Lpe.d.ts} +12 -12
- package/dist/shared/{stack.BggTHKlo.d.mts → stack.CTneIW0u.d.mts} +2 -2
- package/dist/shared/{stack.CtrnoQgH.d.cts → stack.Ce6V7eDj.d.cts} +2 -2
- package/dist/shared/{stack.BMlTZnZp.d.ts → stack.CyalJ0j6.d.ts} +16 -16
- package/dist/shared/{stack.lPKwd_v0.d.ts → stack.D5b9l24t.d.ts} +2 -2
- package/dist/shared/{stack.BV0uNV4f.d.cts → stack.D6Pg-ufX.d.cts} +16 -16
- package/dist/shared/{stack.Egr3RWhA.d.mts → stack.Doy2_wgl.d.mts} +12 -12
- package/dist/shared/{stack.CX83YNuS.d.cts → stack.zch70Loj.d.cts} +12 -12
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { createContext, useContext, useRef, useCallback } from 'react';
|
|
3
|
+
import { usePluginOverrides, useStack } from '@btst/stack/context';
|
|
4
|
+
import { usePageAIContext } from '../../../../../../../plugins/ai-chat/client/context/page-ai-context.mjs';
|
|
5
|
+
import { resolveAiChatMode } from '../overrides.mjs';
|
|
6
|
+
|
|
7
|
+
const ChatAnalyticsPageKey = createContext(
|
|
8
|
+
void 0
|
|
9
|
+
);
|
|
10
|
+
function useChatAnalytics() {
|
|
11
|
+
const { onAnalyticsEvent } = usePluginOverrides("aiChat", {});
|
|
12
|
+
const { plugins } = useStack();
|
|
13
|
+
const pageKey = useContext(ChatAnalyticsPageKey);
|
|
14
|
+
const routeName = usePageAIContext()?.routeName;
|
|
15
|
+
const latest = useRef({
|
|
16
|
+
onAnalyticsEvent,
|
|
17
|
+
pageKey,
|
|
18
|
+
routeName,
|
|
19
|
+
mode: resolveAiChatMode(plugins?.aiChat?.config)
|
|
20
|
+
});
|
|
21
|
+
latest.current = {
|
|
22
|
+
onAnalyticsEvent,
|
|
23
|
+
pageKey,
|
|
24
|
+
routeName,
|
|
25
|
+
mode: resolveAiChatMode(plugins?.aiChat?.config)
|
|
26
|
+
};
|
|
27
|
+
return useCallback((event) => {
|
|
28
|
+
const { onAnalyticsEvent: callback, ...context } = latest.current;
|
|
29
|
+
try {
|
|
30
|
+
void Promise.resolve(callback?.({ ...context, ...event })).catch(
|
|
31
|
+
() => {
|
|
32
|
+
}
|
|
33
|
+
);
|
|
34
|
+
} catch {
|
|
35
|
+
}
|
|
36
|
+
}, []);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export { ChatAnalyticsPageKey, useChatAnalytics };
|
|
@@ -307,7 +307,8 @@ function resolveAiChatClientPlugin(config) {
|
|
|
307
307
|
const aiChatClientPlugin = (config = {}) => client.defineClientPlugin()({
|
|
308
308
|
id: "aiChat",
|
|
309
309
|
providerConfig: {
|
|
310
|
-
mode: config.mode ?? "authenticated"
|
|
310
|
+
mode: config.mode ?? "authenticated",
|
|
311
|
+
...config.pageContent ? { pageContent: true } : {}
|
|
311
312
|
},
|
|
312
313
|
resolve: (runtime) => resolveAiChatClientPlugin({ ...config, runtime })
|
|
313
314
|
});
|
|
@@ -305,7 +305,8 @@ function resolveAiChatClientPlugin(config) {
|
|
|
305
305
|
const aiChatClientPlugin = (config = {}) => defineClientPlugin()({
|
|
306
306
|
id: "aiChat",
|
|
307
307
|
providerConfig: {
|
|
308
|
-
mode: config.mode ?? "authenticated"
|
|
308
|
+
mode: config.mode ?? "authenticated",
|
|
309
|
+
...config.pageContent ? { pageContent: true } : {}
|
|
309
310
|
},
|
|
310
311
|
resolve: (runtime) => resolveAiChatClientPlugin({ ...config, runtime })
|
|
311
312
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as Conversation, M as Message } from '../../../shared/stack.
|
|
2
|
-
export {
|
|
1
|
+
import { c as Conversation, M as Message } from '../../../shared/stack.Dgt3MCtW.cjs';
|
|
2
|
+
export { o as AI_CHAT_OPERATION_INVENTORY, p as AI_CHAT_RAW_ESCAPE_HATCH_INVENTORY, l as AiChatAccess, j as AiChatApiRouter, h as AiChatBackendConfig, m as AiChatBackendHooks, A as AiChatIdentityPartition, q as AiChatOperationError, k as AiChatPageContentConfig, g as AiChatQueryKeys, n as ChatApiContext, r as ChatOperationInputSchema, s as ConversationOperationInputSchema, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, U as UpdateConversationOperationInputSchema, i as aiChatBackendPlugin, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../../shared/stack.Dgt3MCtW.cjs';
|
|
3
3
|
import { DBAdapter } from '@btst/db';
|
|
4
4
|
import '@btst/stack/plugins/client';
|
|
5
5
|
import '@btst/stack/plugins/api';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as Conversation, M as Message } from '../../../shared/stack.
|
|
2
|
-
export {
|
|
1
|
+
import { c as Conversation, M as Message } from '../../../shared/stack.B7Mj74BQ.mjs';
|
|
2
|
+
export { o as AI_CHAT_OPERATION_INVENTORY, p as AI_CHAT_RAW_ESCAPE_HATCH_INVENTORY, l as AiChatAccess, j as AiChatApiRouter, h as AiChatBackendConfig, m as AiChatBackendHooks, A as AiChatIdentityPartition, q as AiChatOperationError, k as AiChatPageContentConfig, g as AiChatQueryKeys, n as ChatApiContext, r as ChatOperationInputSchema, s as ConversationOperationInputSchema, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, U as UpdateConversationOperationInputSchema, i as aiChatBackendPlugin, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../../shared/stack.B7Mj74BQ.mjs';
|
|
3
3
|
import { DBAdapter } from '@btst/db';
|
|
4
4
|
import '@btst/stack/plugins/client';
|
|
5
5
|
import '@btst/stack/plugins/api';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as Conversation, M as Message } from '../../../shared/stack.
|
|
2
|
-
export {
|
|
1
|
+
import { c as Conversation, M as Message } from '../../../shared/stack.DBH1Bjko.js';
|
|
2
|
+
export { o as AI_CHAT_OPERATION_INVENTORY, p as AI_CHAT_RAW_ESCAPE_HATCH_INVENTORY, l as AiChatAccess, j as AiChatApiRouter, h as AiChatBackendConfig, m as AiChatBackendHooks, A as AiChatIdentityPartition, q as AiChatOperationError, k as AiChatPageContentConfig, g as AiChatQueryKeys, n as ChatApiContext, r as ChatOperationInputSchema, s as ConversationOperationInputSchema, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, U as UpdateConversationOperationInputSchema, i as aiChatBackendPlugin, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../../shared/stack.DBH1Bjko.js';
|
|
3
3
|
import { DBAdapter } from '@btst/db';
|
|
4
4
|
import '@btst/stack/plugins/client';
|
|
5
5
|
import '@btst/stack/plugins/api';
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
export { j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, k as ToolCallDisplay } from '../../../../shared/stack.
|
|
1
|
+
export { j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, k as ToolCallDisplay } from '../../../../shared/stack.xAiy2VtO.cjs';
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
3
|
import { FallbackProps } from 'react-error-boundary';
|
|
4
4
|
import 'ai';
|
|
5
5
|
import 'react';
|
|
6
|
+
import '../context/page-ai-context.cjs';
|
|
6
7
|
|
|
7
8
|
interface ChatPageComponentProps {
|
|
8
9
|
conversationId?: string;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
export { j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, k as ToolCallDisplay } from '../../../../shared/stack.
|
|
1
|
+
export { j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, k as ToolCallDisplay } from '../../../../shared/stack.C5FZr-jJ.mjs';
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
3
|
import { FallbackProps } from 'react-error-boundary';
|
|
4
4
|
import 'ai';
|
|
5
5
|
import 'react';
|
|
6
|
+
import '../context/page-ai-context.mjs';
|
|
6
7
|
|
|
7
8
|
interface ChatPageComponentProps {
|
|
8
9
|
conversationId?: string;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
export { j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, k as ToolCallDisplay } from '../../../../shared/stack.
|
|
1
|
+
export { j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, k as ToolCallDisplay } from '../../../../shared/stack.C-eQN_Jt.js';
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
3
|
import { FallbackProps } from 'react-error-boundary';
|
|
4
4
|
import 'ai';
|
|
5
5
|
import 'react';
|
|
6
|
+
import '../context/page-ai-context.js';
|
|
6
7
|
|
|
7
8
|
interface ChatPageComponentProps {
|
|
8
9
|
conversationId?: string;
|
|
@@ -6,6 +6,7 @@ const React = require('react');
|
|
|
6
6
|
|
|
7
7
|
const PageAIAPIContext = React.createContext(null);
|
|
8
8
|
const PageAIVersionContext = React.createContext(0);
|
|
9
|
+
const PageAIContextScope = React.createContext(void 0);
|
|
9
10
|
function PageAIContextProvider({
|
|
10
11
|
children
|
|
11
12
|
}) {
|
|
@@ -83,10 +84,13 @@ function useRegisterPageAIContext(config) {
|
|
|
83
84
|
function usePageAIContext() {
|
|
84
85
|
React.useContext(PageAIVersionContext);
|
|
85
86
|
const ctx = React.useContext(PageAIAPIContext);
|
|
87
|
+
const scoped = React.useContext(PageAIContextScope);
|
|
88
|
+
if (scoped !== void 0) return scoped;
|
|
86
89
|
if (!ctx) return null;
|
|
87
90
|
return ctx.getActive();
|
|
88
91
|
}
|
|
89
92
|
|
|
90
93
|
exports.PageAIContextProvider = PageAIContextProvider;
|
|
94
|
+
exports.PageAIContextScope = PageAIContextScope;
|
|
91
95
|
exports.usePageAIContext = usePageAIContext;
|
|
92
96
|
exports.useRegisterPageAIContext = useRegisterPageAIContext;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React$1 from 'react';
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* A client-side tool handler — receives the AI's tool call args and returns a result.
|
|
@@ -21,7 +22,8 @@ interface PageAIContextConfig {
|
|
|
21
22
|
/**
|
|
22
23
|
* Human-readable description of the current page and its content.
|
|
23
24
|
* Injected into the AI system prompt so it understands what the user is looking at.
|
|
24
|
-
*
|
|
25
|
+
* Limited to 16,000 characters server-side. For longer content, pass a page
|
|
26
|
+
* path and configure the backend pageContent resolver.
|
|
25
27
|
*/
|
|
26
28
|
pageDescription: string;
|
|
27
29
|
/**
|
|
@@ -39,6 +41,8 @@ interface PageAIContextConfig {
|
|
|
39
41
|
*/
|
|
40
42
|
clientTools?: Record<string, PageAIClientTool>;
|
|
41
43
|
}
|
|
44
|
+
/** Instance-local context used by ChatLayout; undefined inherits page registrations. */
|
|
45
|
+
declare const PageAIContextScope: React$1.Context<PageAIContextConfig | null | undefined>;
|
|
42
46
|
/**
|
|
43
47
|
* Provider that enables route-aware AI context across the app.
|
|
44
48
|
*
|
|
@@ -80,5 +84,5 @@ declare function useRegisterPageAIContext(config: PageAIContextConfig | null): v
|
|
|
80
84
|
*/
|
|
81
85
|
declare function usePageAIContext(): PageAIContextConfig | null;
|
|
82
86
|
|
|
83
|
-
export { PageAIContextProvider, usePageAIContext, useRegisterPageAIContext };
|
|
87
|
+
export { PageAIContextProvider, PageAIContextScope, usePageAIContext, useRegisterPageAIContext };
|
|
84
88
|
export type { PageAIClientTool, PageAIContextConfig };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React$1 from 'react';
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* A client-side tool handler — receives the AI's tool call args and returns a result.
|
|
@@ -21,7 +22,8 @@ interface PageAIContextConfig {
|
|
|
21
22
|
/**
|
|
22
23
|
* Human-readable description of the current page and its content.
|
|
23
24
|
* Injected into the AI system prompt so it understands what the user is looking at.
|
|
24
|
-
*
|
|
25
|
+
* Limited to 16,000 characters server-side. For longer content, pass a page
|
|
26
|
+
* path and configure the backend pageContent resolver.
|
|
25
27
|
*/
|
|
26
28
|
pageDescription: string;
|
|
27
29
|
/**
|
|
@@ -39,6 +41,8 @@ interface PageAIContextConfig {
|
|
|
39
41
|
*/
|
|
40
42
|
clientTools?: Record<string, PageAIClientTool>;
|
|
41
43
|
}
|
|
44
|
+
/** Instance-local context used by ChatLayout; undefined inherits page registrations. */
|
|
45
|
+
declare const PageAIContextScope: React$1.Context<PageAIContextConfig | null | undefined>;
|
|
42
46
|
/**
|
|
43
47
|
* Provider that enables route-aware AI context across the app.
|
|
44
48
|
*
|
|
@@ -80,5 +84,5 @@ declare function useRegisterPageAIContext(config: PageAIContextConfig | null): v
|
|
|
80
84
|
*/
|
|
81
85
|
declare function usePageAIContext(): PageAIContextConfig | null;
|
|
82
86
|
|
|
83
|
-
export { PageAIContextProvider, usePageAIContext, useRegisterPageAIContext };
|
|
87
|
+
export { PageAIContextProvider, PageAIContextScope, usePageAIContext, useRegisterPageAIContext };
|
|
84
88
|
export type { PageAIClientTool, PageAIContextConfig };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React$1 from 'react';
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* A client-side tool handler — receives the AI's tool call args and returns a result.
|
|
@@ -21,7 +22,8 @@ interface PageAIContextConfig {
|
|
|
21
22
|
/**
|
|
22
23
|
* Human-readable description of the current page and its content.
|
|
23
24
|
* Injected into the AI system prompt so it understands what the user is looking at.
|
|
24
|
-
*
|
|
25
|
+
* Limited to 16,000 characters server-side. For longer content, pass a page
|
|
26
|
+
* path and configure the backend pageContent resolver.
|
|
25
27
|
*/
|
|
26
28
|
pageDescription: string;
|
|
27
29
|
/**
|
|
@@ -39,6 +41,8 @@ interface PageAIContextConfig {
|
|
|
39
41
|
*/
|
|
40
42
|
clientTools?: Record<string, PageAIClientTool>;
|
|
41
43
|
}
|
|
44
|
+
/** Instance-local context used by ChatLayout; undefined inherits page registrations. */
|
|
45
|
+
declare const PageAIContextScope: React$1.Context<PageAIContextConfig | null | undefined>;
|
|
42
46
|
/**
|
|
43
47
|
* Provider that enables route-aware AI context across the app.
|
|
44
48
|
*
|
|
@@ -80,5 +84,5 @@ declare function useRegisterPageAIContext(config: PageAIContextConfig | null): v
|
|
|
80
84
|
*/
|
|
81
85
|
declare function usePageAIContext(): PageAIContextConfig | null;
|
|
82
86
|
|
|
83
|
-
export { PageAIContextProvider, usePageAIContext, useRegisterPageAIContext };
|
|
87
|
+
export { PageAIContextProvider, PageAIContextScope, usePageAIContext, useRegisterPageAIContext };
|
|
84
88
|
export type { PageAIClientTool, PageAIContextConfig };
|
|
@@ -4,6 +4,7 @@ import { createContext, useRef, useState, useCallback, useMemo, useContext, useI
|
|
|
4
4
|
|
|
5
5
|
const PageAIAPIContext = createContext(null);
|
|
6
6
|
const PageAIVersionContext = createContext(0);
|
|
7
|
+
const PageAIContextScope = createContext(void 0);
|
|
7
8
|
function PageAIContextProvider({
|
|
8
9
|
children
|
|
9
10
|
}) {
|
|
@@ -81,8 +82,10 @@ function useRegisterPageAIContext(config) {
|
|
|
81
82
|
function usePageAIContext() {
|
|
82
83
|
useContext(PageAIVersionContext);
|
|
83
84
|
const ctx = useContext(PageAIAPIContext);
|
|
85
|
+
const scoped = useContext(PageAIContextScope);
|
|
86
|
+
if (scoped !== void 0) return scoped;
|
|
84
87
|
if (!ctx) return null;
|
|
85
88
|
return ctx.getActive();
|
|
86
89
|
}
|
|
87
90
|
|
|
88
|
-
export { PageAIContextProvider, usePageAIContext, useRegisterPageAIContext };
|
|
91
|
+
export { PageAIContextProvider, PageAIContextScope, usePageAIContext, useRegisterPageAIContext };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { UseMutationResult } from '@tanstack/react-query';
|
|
2
2
|
import { ResourceFormResult } from '@btst/stack/plugins/client/hooks';
|
|
3
|
-
import { A as AiChatIdentityPartition, S as SerializedConversation, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput } from '../../../../shared/stack.
|
|
4
|
-
export { a as SerializedMessage } from '../../../../shared/stack.
|
|
3
|
+
import { A as AiChatIdentityPartition, S as SerializedConversation, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput } from '../../../../shared/stack.Dgt3MCtW.cjs';
|
|
4
|
+
export { a as SerializedMessage } from '../../../../shared/stack.Dgt3MCtW.cjs';
|
|
5
5
|
import '@btst/stack/plugins/client';
|
|
6
6
|
import '@btst/stack/plugins/api';
|
|
7
7
|
import '@btst/stack/authorization';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { UseMutationResult } from '@tanstack/react-query';
|
|
2
2
|
import { ResourceFormResult } from '@btst/stack/plugins/client/hooks';
|
|
3
|
-
import { A as AiChatIdentityPartition, S as SerializedConversation, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput } from '../../../../shared/stack.
|
|
4
|
-
export { a as SerializedMessage } from '../../../../shared/stack.
|
|
3
|
+
import { A as AiChatIdentityPartition, S as SerializedConversation, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput } from '../../../../shared/stack.B7Mj74BQ.mjs';
|
|
4
|
+
export { a as SerializedMessage } from '../../../../shared/stack.B7Mj74BQ.mjs';
|
|
5
5
|
import '@btst/stack/plugins/client';
|
|
6
6
|
import '@btst/stack/plugins/api';
|
|
7
7
|
import '@btst/stack/authorization';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { UseMutationResult } from '@tanstack/react-query';
|
|
2
2
|
import { ResourceFormResult } from '@btst/stack/plugins/client/hooks';
|
|
3
|
-
import { A as AiChatIdentityPartition, S as SerializedConversation, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput } from '../../../../shared/stack.
|
|
4
|
-
export { a as SerializedMessage } from '../../../../shared/stack.
|
|
3
|
+
import { A as AiChatIdentityPartition, S as SerializedConversation, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput } from '../../../../shared/stack.DBH1Bjko.js';
|
|
4
|
+
export { a as SerializedMessage } from '../../../../shared/stack.DBH1Bjko.js';
|
|
5
5
|
import '@btst/stack/plugins/client';
|
|
6
6
|
import '@btst/stack/plugins/api';
|
|
7
7
|
import '@btst/stack/authorization';
|
|
@@ -2,9 +2,9 @@ import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
|
2
2
|
import * as _btst_yar from '@btst/yar';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import { ComponentType } from 'react';
|
|
5
|
-
import { S as SerializedConversation, a as SerializedMessage, A as AiChatIdentityPartition } from '../../../shared/stack.
|
|
6
|
-
import { A as AiChatMode, a as AiChatPluginOverrides } from '../../../shared/stack.
|
|
7
|
-
export { b as AiChatProviderConfig, c as AllowedFileType, j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, D as DEFAULT_ALLOWED_FILE_TYPES, k as ToolCallDisplay, T as ToolCallProps, e as ToolCallRenderer, d as ToolCallState } from '../../../shared/stack.
|
|
5
|
+
import { S as SerializedConversation, a as SerializedMessage, A as AiChatIdentityPartition } from '../../../shared/stack.Dgt3MCtW.cjs';
|
|
6
|
+
import { A as AiChatMode, a as AiChatPluginOverrides } from '../../../shared/stack.xAiy2VtO.cjs';
|
|
7
|
+
export { l as AiChatAnalyticsEvent, b as AiChatProviderConfig, c as AllowedFileType, j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, D as DEFAULT_ALLOWED_FILE_TYPES, k as ToolCallDisplay, T as ToolCallProps, e as ToolCallRenderer, d as ToolCallState } from '../../../shared/stack.xAiy2VtO.cjs';
|
|
8
8
|
export { UIMessage } from 'ai';
|
|
9
9
|
import '@btst/stack/plugins/api';
|
|
10
10
|
import '@btst/stack/authorization';
|
|
@@ -13,6 +13,7 @@ import '../permissions.cjs';
|
|
|
13
13
|
import 'zod/v4/core';
|
|
14
14
|
import 'better-call';
|
|
15
15
|
import '@btst/stack/context';
|
|
16
|
+
import './context/page-ai-context.cjs';
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Context passed to route hooks
|
|
@@ -57,6 +58,8 @@ interface AiChatClientConfig {
|
|
|
57
58
|
* @default 'authenticated'
|
|
58
59
|
*/
|
|
59
60
|
mode?: AiChatMode;
|
|
61
|
+
/** Enable built-in readPage permission checks and compact status alongside backend pageContent. */
|
|
62
|
+
pageContent?: boolean;
|
|
60
63
|
/** Optional SEO configuration for meta tags */
|
|
61
64
|
seo?: {
|
|
62
65
|
/** Site name for Open Graph tags */
|
|
@@ -152,6 +155,7 @@ declare const aiChatClientPlugin: (config?: AiChatClientConfig) => _btst_stack_p
|
|
|
152
155
|
})[];
|
|
153
156
|
}, _btst_yar.RouteMeta>;
|
|
154
157
|
}, "aiChat", {
|
|
158
|
+
pageContent?: true | undefined;
|
|
155
159
|
mode: AiChatMode;
|
|
156
160
|
}, never>;
|
|
157
161
|
|
|
@@ -2,9 +2,9 @@ import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
|
2
2
|
import * as _btst_yar from '@btst/yar';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import { ComponentType } from 'react';
|
|
5
|
-
import { S as SerializedConversation, a as SerializedMessage, A as AiChatIdentityPartition } from '../../../shared/stack.
|
|
6
|
-
import { A as AiChatMode, a as AiChatPluginOverrides } from '../../../shared/stack.
|
|
7
|
-
export { b as AiChatProviderConfig, c as AllowedFileType, j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, D as DEFAULT_ALLOWED_FILE_TYPES, k as ToolCallDisplay, T as ToolCallProps, e as ToolCallRenderer, d as ToolCallState } from '../../../shared/stack.
|
|
5
|
+
import { S as SerializedConversation, a as SerializedMessage, A as AiChatIdentityPartition } from '../../../shared/stack.B7Mj74BQ.mjs';
|
|
6
|
+
import { A as AiChatMode, a as AiChatPluginOverrides } from '../../../shared/stack.C5FZr-jJ.mjs';
|
|
7
|
+
export { l as AiChatAnalyticsEvent, b as AiChatProviderConfig, c as AllowedFileType, j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, D as DEFAULT_ALLOWED_FILE_TYPES, k as ToolCallDisplay, T as ToolCallProps, e as ToolCallRenderer, d as ToolCallState } from '../../../shared/stack.C5FZr-jJ.mjs';
|
|
8
8
|
export { UIMessage } from 'ai';
|
|
9
9
|
import '@btst/stack/plugins/api';
|
|
10
10
|
import '@btst/stack/authorization';
|
|
@@ -13,6 +13,7 @@ import '../permissions.mjs';
|
|
|
13
13
|
import 'zod/v4/core';
|
|
14
14
|
import 'better-call';
|
|
15
15
|
import '@btst/stack/context';
|
|
16
|
+
import './context/page-ai-context.mjs';
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Context passed to route hooks
|
|
@@ -57,6 +58,8 @@ interface AiChatClientConfig {
|
|
|
57
58
|
* @default 'authenticated'
|
|
58
59
|
*/
|
|
59
60
|
mode?: AiChatMode;
|
|
61
|
+
/** Enable built-in readPage permission checks and compact status alongside backend pageContent. */
|
|
62
|
+
pageContent?: boolean;
|
|
60
63
|
/** Optional SEO configuration for meta tags */
|
|
61
64
|
seo?: {
|
|
62
65
|
/** Site name for Open Graph tags */
|
|
@@ -152,6 +155,7 @@ declare const aiChatClientPlugin: (config?: AiChatClientConfig) => _btst_stack_p
|
|
|
152
155
|
})[];
|
|
153
156
|
}, _btst_yar.RouteMeta>;
|
|
154
157
|
}, "aiChat", {
|
|
158
|
+
pageContent?: true | undefined;
|
|
155
159
|
mode: AiChatMode;
|
|
156
160
|
}, never>;
|
|
157
161
|
|
|
@@ -2,9 +2,9 @@ import * as _btst_stack_plugins_client from '@btst/stack/plugins/client';
|
|
|
2
2
|
import * as _btst_yar from '@btst/yar';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
4
|
import { ComponentType } from 'react';
|
|
5
|
-
import { S as SerializedConversation, a as SerializedMessage, A as AiChatIdentityPartition } from '../../../shared/stack.
|
|
6
|
-
import { A as AiChatMode, a as AiChatPluginOverrides } from '../../../shared/stack.
|
|
7
|
-
export { b as AiChatProviderConfig, c as AllowedFileType, j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, D as DEFAULT_ALLOWED_FILE_TYPES, k as ToolCallDisplay, T as ToolCallProps, e as ToolCallRenderer, d as ToolCallState } from '../../../shared/stack.
|
|
5
|
+
import { S as SerializedConversation, a as SerializedMessage, A as AiChatIdentityPartition } from '../../../shared/stack.DBH1Bjko.js';
|
|
6
|
+
import { A as AiChatMode, a as AiChatPluginOverrides } from '../../../shared/stack.C-eQN_Jt.js';
|
|
7
|
+
export { l as AiChatAnalyticsEvent, b as AiChatProviderConfig, c as AllowedFileType, j as ChatInput, C as ChatInterface, f as ChatLayout, g as ChatLayoutProps, i as ChatMessage, h as ChatSidebar, D as DEFAULT_ALLOWED_FILE_TYPES, k as ToolCallDisplay, T as ToolCallProps, e as ToolCallRenderer, d as ToolCallState } from '../../../shared/stack.C-eQN_Jt.js';
|
|
8
8
|
export { UIMessage } from 'ai';
|
|
9
9
|
import '@btst/stack/plugins/api';
|
|
10
10
|
import '@btst/stack/authorization';
|
|
@@ -13,6 +13,7 @@ import '../permissions.js';
|
|
|
13
13
|
import 'zod/v4/core';
|
|
14
14
|
import 'better-call';
|
|
15
15
|
import '@btst/stack/context';
|
|
16
|
+
import './context/page-ai-context.js';
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
19
|
* Context passed to route hooks
|
|
@@ -57,6 +58,8 @@ interface AiChatClientConfig {
|
|
|
57
58
|
* @default 'authenticated'
|
|
58
59
|
*/
|
|
59
60
|
mode?: AiChatMode;
|
|
61
|
+
/** Enable built-in readPage permission checks and compact status alongside backend pageContent. */
|
|
62
|
+
pageContent?: boolean;
|
|
60
63
|
/** Optional SEO configuration for meta tags */
|
|
61
64
|
seo?: {
|
|
62
65
|
/** Site name for Open Graph tags */
|
|
@@ -152,6 +155,7 @@ declare const aiChatClientPlugin: (config?: AiChatClientConfig) => _btst_stack_p
|
|
|
152
155
|
})[];
|
|
153
156
|
}, _btst_yar.RouteMeta>;
|
|
154
157
|
}, "aiChat", {
|
|
158
|
+
pageContent?: true | undefined;
|
|
155
159
|
mode: AiChatMode;
|
|
156
160
|
}, never>;
|
|
157
161
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@btst/stack/plugins/client';
|
|
2
|
-
export { A as AiChatIdentityPartition, g as AiChatQueryKeys, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../shared/stack.
|
|
2
|
+
export { A as AiChatIdentityPartition, g as AiChatQueryKeys, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../shared/stack.Dgt3MCtW.cjs';
|
|
3
3
|
import '@btst/stack/context';
|
|
4
4
|
import '@btst/stack/plugins/api';
|
|
5
5
|
import '@btst/stack/authorization';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@btst/stack/plugins/client';
|
|
2
|
-
export { A as AiChatIdentityPartition, g as AiChatQueryKeys, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../shared/stack.
|
|
2
|
+
export { A as AiChatIdentityPartition, g as AiChatQueryKeys, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../shared/stack.B7Mj74BQ.mjs';
|
|
3
3
|
import '@btst/stack/context';
|
|
4
4
|
import '@btst/stack/plugins/api';
|
|
5
5
|
import '@btst/stack/authorization';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@btst/stack/plugins/client';
|
|
2
|
-
export { A as AiChatIdentityPartition, g as AiChatQueryKeys, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../shared/stack.
|
|
2
|
+
export { A as AiChatIdentityPartition, g as AiChatQueryKeys, C as ConversationWithMessages, b as CreateConversationInput, R as RenameConversationInput, d as aiChatIdentityKey, e as aiChatResources, f as createAiChatQueryKeys } from '../../shared/stack.DBH1Bjko.js';
|
|
3
3
|
import '@btst/stack/context';
|
|
4
4
|
import '@btst/stack/plugins/api';
|
|
5
5
|
import '@btst/stack/authorization';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { B as BLOG_QUERY_KEYS, i as BlogApiRouter, k as BlogBackendHooks, f as BlogBackendOptions, l as BlogCreateErrorContext, m as BlogCreateOperationContext, n as BlogCreateResultContext, o as BlogDeleteErrorContext, p as BlogDeleteOperationContext, q as BlogDeleteResultContext, r as BlogListErrorContext, s as BlogListOperationContext, t as BlogListResultContext, u as BlogNextPreviousErrorContext, v as BlogNextPreviousOperationContext, w as BlogNextPreviousResultContext, e as BlogRouteKey, x as BlogUpdateErrorContext, y as BlogUpdateOperationContext, z as BlogUpdateResultContext, C as CreatePostOperationInputSchema, N as NextPreviousPostsQuerySchema, P as PostListParams, j as PostListQuerySchema, c as PostListResult, S as SerializedNextPreviousPostsResult, A as SerializedPostListResult, U as UpdatePostOperationInputSchema, h as blogBackendPlugin, d as createBlogQueryKeys, g as getAllPosts, b as getAllTags, a as getPostBySlug } from '../../../shared/stack.
|
|
1
|
+
export { B as BLOG_QUERY_KEYS, i as BlogApiRouter, k as BlogBackendHooks, f as BlogBackendOptions, l as BlogCreateErrorContext, m as BlogCreateOperationContext, n as BlogCreateResultContext, o as BlogDeleteErrorContext, p as BlogDeleteOperationContext, q as BlogDeleteResultContext, r as BlogListErrorContext, s as BlogListOperationContext, t as BlogListResultContext, u as BlogNextPreviousErrorContext, v as BlogNextPreviousOperationContext, w as BlogNextPreviousResultContext, e as BlogRouteKey, x as BlogUpdateErrorContext, y as BlogUpdateOperationContext, z as BlogUpdateResultContext, C as CreatePostOperationInputSchema, N as NextPreviousPostsQuerySchema, P as PostListParams, j as PostListQuerySchema, c as PostListResult, S as SerializedNextPreviousPostsResult, A as SerializedPostListResult, U as UpdatePostOperationInputSchema, h as blogBackendPlugin, d as createBlogQueryKeys, g as getAllPosts, b as getAllTags, a as getPostBySlug } from '../../../shared/stack.Ce6V7eDj.cjs';
|
|
2
2
|
import { DBAdapter } from '@btst/db';
|
|
3
3
|
import { P as Post, T as Tag, S as SerializedPost, a as SerializedTag } from '../../../shared/stack.Dsatjh0B.cjs';
|
|
4
4
|
export { blogPermissions } from '../permissions.cjs';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { B as BLOG_QUERY_KEYS, i as BlogApiRouter, k as BlogBackendHooks, f as BlogBackendOptions, l as BlogCreateErrorContext, m as BlogCreateOperationContext, n as BlogCreateResultContext, o as BlogDeleteErrorContext, p as BlogDeleteOperationContext, q as BlogDeleteResultContext, r as BlogListErrorContext, s as BlogListOperationContext, t as BlogListResultContext, u as BlogNextPreviousErrorContext, v as BlogNextPreviousOperationContext, w as BlogNextPreviousResultContext, e as BlogRouteKey, x as BlogUpdateErrorContext, y as BlogUpdateOperationContext, z as BlogUpdateResultContext, C as CreatePostOperationInputSchema, N as NextPreviousPostsQuerySchema, P as PostListParams, j as PostListQuerySchema, c as PostListResult, S as SerializedNextPreviousPostsResult, A as SerializedPostListResult, U as UpdatePostOperationInputSchema, h as blogBackendPlugin, d as createBlogQueryKeys, g as getAllPosts, b as getAllTags, a as getPostBySlug } from '../../../shared/stack.
|
|
1
|
+
export { B as BLOG_QUERY_KEYS, i as BlogApiRouter, k as BlogBackendHooks, f as BlogBackendOptions, l as BlogCreateErrorContext, m as BlogCreateOperationContext, n as BlogCreateResultContext, o as BlogDeleteErrorContext, p as BlogDeleteOperationContext, q as BlogDeleteResultContext, r as BlogListErrorContext, s as BlogListOperationContext, t as BlogListResultContext, u as BlogNextPreviousErrorContext, v as BlogNextPreviousOperationContext, w as BlogNextPreviousResultContext, e as BlogRouteKey, x as BlogUpdateErrorContext, y as BlogUpdateOperationContext, z as BlogUpdateResultContext, C as CreatePostOperationInputSchema, N as NextPreviousPostsQuerySchema, P as PostListParams, j as PostListQuerySchema, c as PostListResult, S as SerializedNextPreviousPostsResult, A as SerializedPostListResult, U as UpdatePostOperationInputSchema, h as blogBackendPlugin, d as createBlogQueryKeys, g as getAllPosts, b as getAllTags, a as getPostBySlug } from '../../../shared/stack.CTneIW0u.mjs';
|
|
2
2
|
import { DBAdapter } from '@btst/db';
|
|
3
3
|
import { P as Post, T as Tag, S as SerializedPost, a as SerializedTag } from '../../../shared/stack.Dsatjh0B.mjs';
|
|
4
4
|
export { blogPermissions } from '../permissions.mjs';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { B as BLOG_QUERY_KEYS, i as BlogApiRouter, k as BlogBackendHooks, f as BlogBackendOptions, l as BlogCreateErrorContext, m as BlogCreateOperationContext, n as BlogCreateResultContext, o as BlogDeleteErrorContext, p as BlogDeleteOperationContext, q as BlogDeleteResultContext, r as BlogListErrorContext, s as BlogListOperationContext, t as BlogListResultContext, u as BlogNextPreviousErrorContext, v as BlogNextPreviousOperationContext, w as BlogNextPreviousResultContext, e as BlogRouteKey, x as BlogUpdateErrorContext, y as BlogUpdateOperationContext, z as BlogUpdateResultContext, C as CreatePostOperationInputSchema, N as NextPreviousPostsQuerySchema, P as PostListParams, j as PostListQuerySchema, c as PostListResult, S as SerializedNextPreviousPostsResult, A as SerializedPostListResult, U as UpdatePostOperationInputSchema, h as blogBackendPlugin, d as createBlogQueryKeys, g as getAllPosts, b as getAllTags, a as getPostBySlug } from '../../../shared/stack.
|
|
1
|
+
export { B as BLOG_QUERY_KEYS, i as BlogApiRouter, k as BlogBackendHooks, f as BlogBackendOptions, l as BlogCreateErrorContext, m as BlogCreateOperationContext, n as BlogCreateResultContext, o as BlogDeleteErrorContext, p as BlogDeleteOperationContext, q as BlogDeleteResultContext, r as BlogListErrorContext, s as BlogListOperationContext, t as BlogListResultContext, u as BlogNextPreviousErrorContext, v as BlogNextPreviousOperationContext, w as BlogNextPreviousResultContext, e as BlogRouteKey, x as BlogUpdateErrorContext, y as BlogUpdateOperationContext, z as BlogUpdateResultContext, C as CreatePostOperationInputSchema, N as NextPreviousPostsQuerySchema, P as PostListParams, j as PostListQuerySchema, c as PostListResult, S as SerializedNextPreviousPostsResult, A as SerializedPostListResult, U as UpdatePostOperationInputSchema, h as blogBackendPlugin, d as createBlogQueryKeys, g as getAllPosts, b as getAllTags, a as getPostBySlug } from '../../../shared/stack.D5b9l24t.js';
|
|
2
2
|
import { DBAdapter } from '@btst/db';
|
|
3
3
|
import { P as Post, T as Tag, S as SerializedPost, a as SerializedTag } from '../../../shared/stack.Dsatjh0B.js';
|
|
4
4
|
export { blogPermissions } from '../permissions.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@btst/stack/plugins/client';
|
|
2
|
-
export { D as blogResources, d as createBlogQueryKeys } from '../../shared/stack.
|
|
2
|
+
export { D as blogResources, d as createBlogQueryKeys } from '../../shared/stack.Ce6V7eDj.cjs';
|
|
3
3
|
import 'zod';
|
|
4
4
|
import '../../shared/stack.CKc_Bais.cjs';
|
|
5
5
|
import '../../shared/stack.Dsatjh0B.cjs';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@btst/stack/plugins/client';
|
|
2
|
-
export { D as blogResources, d as createBlogQueryKeys } from '../../shared/stack.
|
|
2
|
+
export { D as blogResources, d as createBlogQueryKeys } from '../../shared/stack.CTneIW0u.mjs';
|
|
3
3
|
import 'zod';
|
|
4
4
|
import '../../shared/stack.CKc_Bais.mjs';
|
|
5
5
|
import '../../shared/stack.Dsatjh0B.mjs';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@btst/stack/plugins/client';
|
|
2
|
-
export { D as blogResources, d as createBlogQueryKeys } from '../../shared/stack.
|
|
2
|
+
export { D as blogResources, d as createBlogQueryKeys } from '../../shared/stack.D5b9l24t.js';
|
|
3
3
|
import 'zod';
|
|
4
4
|
import '../../shared/stack.CKc_Bais.js';
|
|
5
5
|
import '../../shared/stack.Dsatjh0B.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { C as CMSApiRouter, b as CMSRouteKey, d as CMS_QUERY_KEYS, c as cmsBackendPlugin } from '../../../shared/stack.
|
|
1
|
+
export { C as CMSApiRouter, b as CMSRouteKey, d as CMS_QUERY_KEYS, c as cmsBackendPlugin } from '../../../shared/stack.D6Pg-ufX.cjs';
|
|
2
2
|
import { DBAdapter } from '@btst/db';
|
|
3
3
|
import { S as SerializedContentType, a as SerializedContentItemWithType, b as ContentType, c as ContentItem, d as SerializedContentItem, e as ContentItemWithType } from '../../../shared/stack.B3_aDcYL.cjs';
|
|
4
4
|
export { C as CMSBackendConfig, f as CMSBackendHooks, g as CMSCreateOperationContext, h as CMSCreateResultContext, i as CMSDeleteOperationContext, j as CMSDeleteResultContext, k as CMSOperationErrorContext, l as CMSOperationLifecycleContext, m as CMSUpdateOperationContext, n as CMSUpdateResultContext, o as ContentTypeConfig } from '../../../shared/stack.B3_aDcYL.cjs';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { C as CMSApiRouter, b as CMSRouteKey, d as CMS_QUERY_KEYS, c as cmsBackendPlugin } from '../../../shared/stack.
|
|
1
|
+
export { C as CMSApiRouter, b as CMSRouteKey, d as CMS_QUERY_KEYS, c as cmsBackendPlugin } from '../../../shared/stack.B8PG21zX.mjs';
|
|
2
2
|
import { DBAdapter } from '@btst/db';
|
|
3
3
|
import { S as SerializedContentType, a as SerializedContentItemWithType, b as ContentType, c as ContentItem, d as SerializedContentItem, e as ContentItemWithType } from '../../../shared/stack.B3_aDcYL.mjs';
|
|
4
4
|
export { C as CMSBackendConfig, f as CMSBackendHooks, g as CMSCreateOperationContext, h as CMSCreateResultContext, i as CMSDeleteOperationContext, j as CMSDeleteResultContext, k as CMSOperationErrorContext, l as CMSOperationLifecycleContext, m as CMSUpdateOperationContext, n as CMSUpdateResultContext, o as ContentTypeConfig } from '../../../shared/stack.B3_aDcYL.mjs';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { C as CMSApiRouter, b as CMSRouteKey, d as CMS_QUERY_KEYS, c as cmsBackendPlugin } from '../../../shared/stack.
|
|
1
|
+
export { C as CMSApiRouter, b as CMSRouteKey, d as CMS_QUERY_KEYS, c as cmsBackendPlugin } from '../../../shared/stack.CyalJ0j6.js';
|
|
2
2
|
import { DBAdapter } from '@btst/db';
|
|
3
3
|
import { S as SerializedContentType, a as SerializedContentItemWithType, b as ContentType, c as ContentItem, d as SerializedContentItem, e as ContentItemWithType } from '../../../shared/stack.B3_aDcYL.js';
|
|
4
4
|
export { C as CMSBackendConfig, f as CMSBackendHooks, g as CMSCreateOperationContext, h as CMSCreateResultContext, i as CMSDeleteOperationContext, j as CMSDeleteResultContext, k as CMSOperationErrorContext, l as CMSOperationLifecycleContext, m as CMSUpdateOperationContext, n as CMSUpdateResultContext, o as ContentTypeConfig } from '../../../shared/stack.B3_aDcYL.js';
|
|
@@ -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 { C as CMSApiRouter, a as ContentListDiscriminator } from '../../shared/stack.
|
|
3
|
+
import { C as CMSApiRouter, a as ContentListDiscriminator } from '../../shared/stack.D6Pg-ufX.cjs';
|
|
4
4
|
import { S as SerializedContentType, I as InverseRelation, a as SerializedContentItemWithType, P as PaginatedContentItems } from '../../shared/stack.B3_aDcYL.cjs';
|
|
5
5
|
import '@btst/stack/plugins/api';
|
|
6
6
|
import '../../authorization/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 { C as CMSApiRouter, a as ContentListDiscriminator } from '../../shared/stack.
|
|
3
|
+
import { C as CMSApiRouter, a as ContentListDiscriminator } from '../../shared/stack.B8PG21zX.mjs';
|
|
4
4
|
import { S as SerializedContentType, I as InverseRelation, a as SerializedContentItemWithType, P as PaginatedContentItems } from '../../shared/stack.B3_aDcYL.mjs';
|
|
5
5
|
import '@btst/stack/plugins/api';
|
|
6
6
|
import '../../authorization/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 { C as CMSApiRouter, a as ContentListDiscriminator } from '../../shared/stack.
|
|
3
|
+
import { C as CMSApiRouter, a as ContentListDiscriminator } from '../../shared/stack.CyalJ0j6.js';
|
|
4
4
|
import { S as SerializedContentType, I as InverseRelation, a as SerializedContentItemWithType, P as PaginatedContentItems } from '../../shared/stack.B3_aDcYL.js';
|
|
5
5
|
import '@btst/stack/plugins/api';
|
|
6
6
|
import '../../authorization/index.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { k as FORM_QUERY_KEYS, a as FormBuilderApiRouter, c as FormBuilderOperationError, e as FormBuilderOperations, b as FormBuilderRouteKey, g as FormListOperationResult, h as SubmissionDetailOperationResult, i as SubmissionListOperationResult, j as SubmitOperationResult, d as createFormBuilderOperations, f as formBuilderBackendPlugin } from '../../../shared/stack.
|
|
1
|
+
export { k as FORM_QUERY_KEYS, a as FormBuilderApiRouter, c as FormBuilderOperationError, e as FormBuilderOperations, b as FormBuilderRouteKey, g as FormListOperationResult, h as SubmissionDetailOperationResult, i as SubmissionListOperationResult, j as SubmitOperationResult, d as createFormBuilderOperations, f as formBuilderBackendPlugin } from '../../../shared/stack.zch70Loj.cjs';
|
|
2
2
|
export { formBuilderPermissions } from '../permissions.cjs';
|
|
3
3
|
import { S as SerializedForm, d as SerializedFormSubmissionWithData, F as Form, f as FormSubmission, a as SerializedFormSubmission, c as SerializedFormSubmissionSummary, g as FormSubmissionWithForm } from '../../../shared/stack.v2O65JqF.cjs';
|
|
4
4
|
export { h as FormBuilderBackendConfig, i as FormBuilderBackendHooks, j as FormBuilderHookContext, k as FormBuilderOperationHookContext, l as FormCreateOperationContext, m as FormDeleteOperationContext, o as FormGetForUpdateOperationContext, n as FormGetOperationContext, p as FormListOperationContext, q as FormUpdateOperationContext, r as SubmissionCreateOperationContext, s as SubmissionDeleteOperationContext, t as SubmissionGetOperationContext, v as SubmissionHookContext, b as SubmissionListFormContext, u as SubmissionListOperationContext } from '../../../shared/stack.v2O65JqF.cjs';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { k as FORM_QUERY_KEYS, a as FormBuilderApiRouter, c as FormBuilderOperationError, e as FormBuilderOperations, b as FormBuilderRouteKey, g as FormListOperationResult, h as SubmissionDetailOperationResult, i as SubmissionListOperationResult, j as SubmitOperationResult, d as createFormBuilderOperations, f as formBuilderBackendPlugin } from '../../../shared/stack.
|
|
1
|
+
export { k as FORM_QUERY_KEYS, a as FormBuilderApiRouter, c as FormBuilderOperationError, e as FormBuilderOperations, b as FormBuilderRouteKey, g as FormListOperationResult, h as SubmissionDetailOperationResult, i as SubmissionListOperationResult, j as SubmitOperationResult, d as createFormBuilderOperations, f as formBuilderBackendPlugin } from '../../../shared/stack.Doy2_wgl.mjs';
|
|
2
2
|
export { formBuilderPermissions } from '../permissions.mjs';
|
|
3
3
|
import { S as SerializedForm, d as SerializedFormSubmissionWithData, F as Form, f as FormSubmission, a as SerializedFormSubmission, c as SerializedFormSubmissionSummary, g as FormSubmissionWithForm } from '../../../shared/stack.OYT8WU4n.mjs';
|
|
4
4
|
export { h as FormBuilderBackendConfig, i as FormBuilderBackendHooks, j as FormBuilderHookContext, k as FormBuilderOperationHookContext, l as FormCreateOperationContext, m as FormDeleteOperationContext, o as FormGetForUpdateOperationContext, n as FormGetOperationContext, p as FormListOperationContext, q as FormUpdateOperationContext, r as SubmissionCreateOperationContext, s as SubmissionDeleteOperationContext, t as SubmissionGetOperationContext, v as SubmissionHookContext, b as SubmissionListFormContext, u as SubmissionListOperationContext } from '../../../shared/stack.OYT8WU4n.mjs';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { k as FORM_QUERY_KEYS, a as FormBuilderApiRouter, c as FormBuilderOperationError, e as FormBuilderOperations, b as FormBuilderRouteKey, g as FormListOperationResult, h as SubmissionDetailOperationResult, i as SubmissionListOperationResult, j as SubmitOperationResult, d as createFormBuilderOperations, f as formBuilderBackendPlugin } from '../../../shared/stack.
|
|
1
|
+
export { k as FORM_QUERY_KEYS, a as FormBuilderApiRouter, c as FormBuilderOperationError, e as FormBuilderOperations, b as FormBuilderRouteKey, g as FormListOperationResult, h as SubmissionDetailOperationResult, i as SubmissionListOperationResult, j as SubmitOperationResult, d as createFormBuilderOperations, f as formBuilderBackendPlugin } from '../../../shared/stack.CGmh-Lpe.js';
|
|
2
2
|
export { formBuilderPermissions } from '../permissions.js';
|
|
3
3
|
import { S as SerializedForm, d as SerializedFormSubmissionWithData, F as Form, f as FormSubmission, a as SerializedFormSubmission, c as SerializedFormSubmissionSummary, g as FormSubmissionWithForm } from '../../../shared/stack.C3bU9w6L.js';
|
|
4
4
|
export { h as FormBuilderBackendConfig, i as FormBuilderBackendHooks, j as FormBuilderHookContext, k as FormBuilderOperationHookContext, l as FormCreateOperationContext, m as FormDeleteOperationContext, o as FormGetForUpdateOperationContext, n as FormGetOperationContext, p as FormListOperationContext, q as FormUpdateOperationContext, r as SubmissionCreateOperationContext, s as SubmissionDeleteOperationContext, t as SubmissionGetOperationContext, v as SubmissionHookContext, b as SubmissionListFormContext, u as SubmissionListOperationContext } from '../../../shared/stack.C3bU9w6L.js';
|
|
@@ -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';
|