@alxxsck/ai-assistant 3.4.0 → 3.4.3
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/{Avatar-BNNzmt88.js → Avatar-wXovvIDQ.js} +1 -1
- package/dist/{ChatWidgetContent-DSWsoPbu.js → ChatWidgetContent-BICh_AXq.js} +1742 -1655
- package/dist/api/messages.api.d.ts +3 -0
- package/dist/api/messages.api.types.d.ts +5 -0
- package/dist/bridge-ai-chat-widget.es.js +2 -2
- package/dist/config/assistant-ui-version.d.ts +2 -0
- package/dist/{index-DhJtrjs7.js → index-Bxit2PO-.js} +38 -38
- package/dist/{mount-CAjO8nWS.js → mount-B4WZondG.js} +19394 -19293
- package/dist/ui/AssistantUi.d.ts +2 -0
- package/dist/ui/active/AssistantUiPresentation.d.ts +1 -0
- package/dist/ui/components/ChatWidget.d.ts +29 -1
- package/dist/ui/hooks/useMessageHistoryRecovery.d.ts +7 -0
- package/dist/ui/hooks/useVisibleMessageReceipts.d.ts +12 -0
- package/dist/ui/new/AssistantUiPresentation.d.ts +1 -0
- package/dist/ui/new/NewAssistantUiPresentation.d.ts +2 -0
- package/package.json +4 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AssistantUiPresentation } from "@/ui/new/AssistantUiPresentation";
|
|
@@ -1,2 +1,30 @@
|
|
|
1
|
+
import { type ComponentType, type ReactNode } from "react";
|
|
2
|
+
import type { AssistantOpenSurfaceMode, AssistantSurfaceMode } from "@/domain/ui/assistant-surface";
|
|
3
|
+
import type { SurfaceFocusDisposition } from "@/domain/scenario-interaction/scenario-interaction.types";
|
|
1
4
|
export { CHAT_PATHS, ChatMode } from "@/ui/chat-routes";
|
|
2
|
-
export
|
|
5
|
+
export type ChatWidgetPresentationProps = {
|
|
6
|
+
open: boolean;
|
|
7
|
+
surfaceMode: AssistantSurfaceMode;
|
|
8
|
+
lastOpenSurfaceMode: AssistantOpenSurfaceMode;
|
|
9
|
+
isMobile: boolean;
|
|
10
|
+
hideOpenButton: boolean;
|
|
11
|
+
loadingProgress: number;
|
|
12
|
+
closeFocusDisposition: SurfaceFocusDisposition;
|
|
13
|
+
chromeVisible: boolean;
|
|
14
|
+
contentActivated: boolean;
|
|
15
|
+
launcherUnreadDescriptionId: string;
|
|
16
|
+
compactUnreadDescriptionId: string;
|
|
17
|
+
compactPreview: ReactNode;
|
|
18
|
+
compactPreviewAnnouncement: string;
|
|
19
|
+
compactPreviewCollapsible: boolean;
|
|
20
|
+
compactPreviewSuspended: boolean;
|
|
21
|
+
onRestore: () => void;
|
|
22
|
+
onOpenFull: () => void;
|
|
23
|
+
onClose: () => void;
|
|
24
|
+
onLauncherDragSuspended: (suspended: boolean) => void;
|
|
25
|
+
onCompactPreviewCollapse: () => void;
|
|
26
|
+
};
|
|
27
|
+
export type ChatWidgetProps = {
|
|
28
|
+
presentation: ComponentType<ChatWidgetPresentationProps>;
|
|
29
|
+
};
|
|
30
|
+
export declare function ChatWidget({ presentation: Presentation }: ChatWidgetProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare function useMessageHistoryRecovery({ open, conversationId, accessToken, latestCompletedMessageId, fetchThreadMessages, }: {
|
|
2
|
+
open: boolean;
|
|
3
|
+
conversationId?: string;
|
|
4
|
+
accessToken?: string;
|
|
5
|
+
latestCompletedMessageId?: string;
|
|
6
|
+
fetchThreadMessages: (conversationId: string) => Promise<void>;
|
|
7
|
+
}): void;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type RefObject } from "react";
|
|
2
|
+
import { type MessageData } from "@/api/messages.api.types";
|
|
3
|
+
import type { WidgetConfig } from "@/index.types";
|
|
4
|
+
import type { AppApi } from "@/App";
|
|
5
|
+
export declare function useVisibleMessageReceipts(input: {
|
|
6
|
+
open: boolean;
|
|
7
|
+
conversationId?: string;
|
|
8
|
+
messages: readonly MessageData[];
|
|
9
|
+
root: RefObject<HTMLElement | null>;
|
|
10
|
+
config: WidgetConfig;
|
|
11
|
+
api: AppApi;
|
|
12
|
+
}): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { NewAssistantUiPresentation as AssistantUiPresentation } from "./NewAssistantUiPresentation";
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import type { ChatWidgetPresentationProps } from "@/ui/components/ChatWidget";
|
|
2
|
+
export declare function NewAssistantUiPresentation({ open, surfaceMode, lastOpenSurfaceMode, isMobile, hideOpenButton, loadingProgress, closeFocusDisposition, chromeVisible, contentActivated, launcherUnreadDescriptionId, compactUnreadDescriptionId, compactPreview, compactPreviewAnnouncement, compactPreviewCollapsible, compactPreviewSuspended, onRestore, onClose, onLauncherDragSuspended, onCompactPreviewCollapse, }: ChatWidgetPresentationProps): import("react/jsx-runtime").JSX.Element;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alxxsck/ai-assistant",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "3.4.
|
|
4
|
+
"version": "3.4.3",
|
|
5
5
|
"description": "Embeddable Lola AI assistant library",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "dist/bridge-ai-chat-widget.es.js",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
"format:check": "prettier --check .",
|
|
35
35
|
"test": "vitest run",
|
|
36
36
|
"test:browser": "playwright test",
|
|
37
|
+
"test:assistant-ui-build-variants": "node scripts/verify-assistant-ui-build-variants.mjs",
|
|
37
38
|
"test:support-presentations:real-backend": "node scripts/run-support-presentations-real-backend.mjs",
|
|
38
39
|
"typecheck": "tsc -p tsconfig.typecheck.json --noEmit",
|
|
39
40
|
"build-lib": "vite build --config vite.config.lib.ts --mode production && tsc -p tsconfig.build.json && npm run verify:release-bundle",
|
|
@@ -94,6 +95,7 @@
|
|
|
94
95
|
"typescript": "~5.9.3",
|
|
95
96
|
"typescript-eslint": "^8.46.4",
|
|
96
97
|
"vite": "^7.2.4",
|
|
97
|
-
"vitest": "^4.1.10"
|
|
98
|
+
"vitest": "^4.1.10",
|
|
99
|
+
"yaml": "^2.4.2"
|
|
98
100
|
}
|
|
99
101
|
}
|