@marketrix.ai/widget 3.8.10 → 3.8.53
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 +158 -169
- package/dist/src/components/MarketrixWidget.d.ts +0 -1
- package/dist/src/components/base/Avatar.d.ts +0 -1
- package/dist/src/components/base/Badge.d.ts +0 -1
- package/dist/src/components/base/Button.d.ts +0 -1
- package/dist/src/components/base/Card.d.ts +0 -1
- package/dist/src/components/base/Dialog.d.ts +9 -12
- package/dist/src/components/base/Flex.d.ts +0 -1
- package/dist/src/components/base/Icon.d.ts +0 -1
- package/dist/src/components/base/IconButton.d.ts +0 -1
- package/dist/src/components/base/Indicator.d.ts +0 -1
- package/dist/src/components/base/Menu.d.ts +4 -5
- package/dist/src/components/base/Pill.d.ts +0 -1
- package/dist/src/components/base/Spinner.d.ts +0 -1
- package/dist/src/components/base/Stack.d.ts +0 -1
- package/dist/src/components/base/Surface.d.ts +0 -1
- package/dist/src/components/base/Text.d.ts +0 -1
- package/dist/src/components/base/Textarea.d.ts +0 -1
- package/dist/src/components/base/Video.d.ts +0 -1
- package/dist/src/components/base/icons.d.ts +0 -256
- package/dist/src/components/base/layoutProps.d.ts +0 -1
- package/dist/src/components/base/tokens.d.ts +0 -1
- package/dist/src/components/base/useDisclosure.d.ts +0 -1
- package/dist/src/components/blocks/ChatInput.d.ts +0 -1
- package/dist/src/components/blocks/HeaderBar.d.ts +0 -1
- package/dist/src/components/blocks/NotificationToast.d.ts +0 -1
- package/dist/src/components/blocks/WidgetDialog.d.ts +0 -13
- package/dist/src/components/blocks/WidgetFab.d.ts +0 -1
- package/dist/src/components/chat/MessageContent.d.ts +0 -1
- package/dist/src/components/chat/MessageItem.d.ts +0 -1
- package/dist/src/components/chat/MessageList.d.ts +1 -2
- package/dist/src/components/chat/ProgressLine.d.ts +0 -1
- package/dist/src/components/chat/SuggestedActions.d.ts +0 -1
- package/dist/src/components/chat/TaskStatusIcon.d.ts +0 -1
- package/dist/src/components/chat/ThinkingIndicator.d.ts +0 -1
- package/dist/src/components/chat/VideoStreamDisplay.d.ts +0 -1
- package/dist/src/components/navigation/MessengerShell.d.ts +1 -3
- package/dist/src/components/navigation/ResizeHandles.d.ts +0 -1
- package/dist/src/components/navigation/ShellTabBar.d.ts +0 -1
- package/dist/src/components/navigation/ViewTransition.d.ts +0 -1
- package/dist/src/components/ui/StateMessage.d.ts +0 -1
- package/dist/src/components/ui/WidgetSettingsLoader.d.ts +1 -2
- package/dist/src/components/views/ChatView.d.ts +1 -3
- package/dist/src/components/views/HomeView.d.ts +0 -1
- package/dist/src/constants/theme.d.ts +0 -1
- package/dist/src/context/ConversationContext.d.ts +56 -0
- package/dist/src/context/UIStateContext.d.ts +0 -1
- package/dist/src/context/WidgetProviders.d.ts +8 -7
- package/dist/src/context/sseReducer.d.ts +3 -4
- package/dist/src/design-system/component-tokens.d.ts +0 -1
- package/dist/src/design-system/layers.d.ts +0 -1
- package/dist/src/design-system/semantic-tokens.d.ts +0 -1
- package/dist/src/design-system/shadows.d.ts +0 -1
- package/dist/src/design-system/token-adapter.d.ts +0 -1
- package/dist/src/hooks/useDragSnap.d.ts +0 -1
- package/dist/src/hooks/useFocusTrap.d.ts +0 -1
- package/dist/src/hooks/useResize.d.ts +0 -1
- package/dist/src/hooks/useScreenShare.d.ts +0 -1
- package/dist/src/hooks/useScrollLock.d.ts +0 -1
- package/dist/src/hooks/useWidget.d.ts +2 -6
- package/dist/src/index.d.ts +0 -1
- package/dist/src/lib/utils.d.ts +0 -1
- package/dist/src/sdk/contract.d.ts +0 -371
- package/dist/src/sdk/contracts/activityLog.d.ts +0 -25
- package/dist/src/sdk/contracts/application.d.ts +54 -5
- package/dist/src/sdk/contracts/chat.d.ts +0 -1
- package/dist/src/sdk/contracts/common.d.ts +10 -14
- package/dist/src/sdk/contracts/entities.d.ts +12 -271
- package/dist/src/sdk/contracts/widget.d.ts +0 -973
- package/dist/src/sdk/index.d.ts +1 -372
- package/dist/src/services/ApiService.d.ts +1 -3
- package/dist/src/services/ChatService.d.ts +3 -6
- package/dist/src/services/ConfigManager.d.ts +0 -1
- package/dist/src/services/DomService.d.ts +3 -33
- package/dist/src/services/ScreenShareService.d.ts +0 -6
- package/dist/src/services/SessionManager.d.ts +0 -1
- package/dist/src/services/SessionRecorder.d.ts +0 -1
- package/dist/src/services/ShowModeService.d.ts +0 -1
- package/dist/src/services/StorageService.d.ts +3 -5
- package/dist/src/services/StreamClient.d.ts +0 -2
- package/dist/src/services/ToolService.d.ts +3 -4
- package/dist/src/services/ValidationService.d.ts +9 -12
- package/dist/src/services/WidgetService.d.ts +0 -2
- package/dist/src/test/a11y-utils.d.ts +0 -1
- package/dist/src/test/fixtures.d.ts +0 -1
- package/dist/src/test/setup.d.ts +0 -1
- package/dist/src/types/browserTools.d.ts +2 -9
- package/dist/src/types/index.d.ts +3 -19
- package/dist/src/utils/apiUtils.d.ts +0 -1
- package/dist/src/utils/bootstrap.d.ts +0 -11
- package/dist/src/utils/chat.d.ts +0 -11
- package/dist/src/utils/common.d.ts +0 -1
- package/dist/src/utils/dom.d.ts +0 -13
- package/dist/src/utils/format.d.ts +0 -1
- package/dist/src/utils/suggestedActions.d.ts +0 -1
- package/dist/src/utils/validation.d.ts +0 -9
- package/dist/src/utils/widgetPositioning.d.ts +0 -1
- package/dist/widget.mjs +62 -65
- package/dist/widget.mjs.map +1 -1
- package/package.json +15 -15
- package/dist/index.html +0 -1697
- package/dist/src/components/MarketrixWidget.d.ts.map +0 -1
- package/dist/src/components/base/Avatar.d.ts.map +0 -1
- package/dist/src/components/base/Badge.d.ts.map +0 -1
- package/dist/src/components/base/Button.d.ts.map +0 -1
- package/dist/src/components/base/Card.d.ts.map +0 -1
- package/dist/src/components/base/Dialog.d.ts.map +0 -1
- package/dist/src/components/base/Flex.d.ts.map +0 -1
- package/dist/src/components/base/Icon.d.ts.map +0 -1
- package/dist/src/components/base/IconButton.d.ts.map +0 -1
- package/dist/src/components/base/Indicator.d.ts.map +0 -1
- package/dist/src/components/base/Menu.d.ts.map +0 -1
- package/dist/src/components/base/Pill.d.ts.map +0 -1
- package/dist/src/components/base/Spinner.d.ts.map +0 -1
- package/dist/src/components/base/Stack.d.ts.map +0 -1
- package/dist/src/components/base/Surface.d.ts.map +0 -1
- package/dist/src/components/base/Text.d.ts.map +0 -1
- package/dist/src/components/base/Textarea.d.ts.map +0 -1
- package/dist/src/components/base/Video.d.ts.map +0 -1
- package/dist/src/components/base/icons.d.ts.map +0 -1
- package/dist/src/components/base/index.d.ts +0 -22
- package/dist/src/components/base/index.d.ts.map +0 -1
- package/dist/src/components/base/layoutProps.d.ts.map +0 -1
- package/dist/src/components/base/tokens.d.ts.map +0 -1
- package/dist/src/components/base/useDisclosure.d.ts.map +0 -1
- package/dist/src/components/blocks/ChatInput.d.ts.map +0 -1
- package/dist/src/components/blocks/HeaderBar.d.ts.map +0 -1
- package/dist/src/components/blocks/NotificationToast.d.ts.map +0 -1
- package/dist/src/components/blocks/TabBar.d.ts +0 -13
- package/dist/src/components/blocks/TabBar.d.ts.map +0 -1
- package/dist/src/components/blocks/WidgetDialog.d.ts.map +0 -1
- package/dist/src/components/blocks/WidgetFab.d.ts.map +0 -1
- package/dist/src/components/blocks/index.d.ts +0 -7
- package/dist/src/components/blocks/index.d.ts.map +0 -1
- package/dist/src/components/chat/MessageContent.d.ts.map +0 -1
- package/dist/src/components/chat/MessageItem.d.ts.map +0 -1
- package/dist/src/components/chat/MessageList.d.ts.map +0 -1
- package/dist/src/components/chat/ProgressLine.d.ts.map +0 -1
- package/dist/src/components/chat/SuggestedActions.d.ts.map +0 -1
- package/dist/src/components/chat/TaskStatusIcon.d.ts.map +0 -1
- package/dist/src/components/chat/ThinkingIndicator.d.ts.map +0 -1
- package/dist/src/components/chat/VideoStreamDisplay.d.ts.map +0 -1
- package/dist/src/components/navigation/MessengerShell.d.ts.map +0 -1
- package/dist/src/components/navigation/ResizeHandles.d.ts.map +0 -1
- package/dist/src/components/navigation/ShellTabBar.d.ts.map +0 -1
- package/dist/src/components/navigation/ViewTransition.d.ts.map +0 -1
- package/dist/src/components/ui/StateMessage.d.ts.map +0 -1
- package/dist/src/components/ui/WidgetSettingsLoader.d.ts.map +0 -1
- package/dist/src/components/views/ChatView.d.ts.map +0 -1
- package/dist/src/components/views/HomeView.d.ts.map +0 -1
- package/dist/src/constants/config.d.ts +0 -8
- package/dist/src/constants/config.d.ts.map +0 -1
- package/dist/src/constants/theme.d.ts.map +0 -1
- package/dist/src/context/ChatContext.d.ts +0 -34
- package/dist/src/context/ChatContext.d.ts.map +0 -1
- package/dist/src/context/TaskContext.d.ts +0 -39
- package/dist/src/context/TaskContext.d.ts.map +0 -1
- package/dist/src/context/UIStateContext.d.ts.map +0 -1
- package/dist/src/context/WidgetProviders.d.ts.map +0 -1
- package/dist/src/context/sseReducer.d.ts.map +0 -1
- package/dist/src/design-system/component-tokens.d.ts.map +0 -1
- package/dist/src/design-system/layers.d.ts.map +0 -1
- package/dist/src/design-system/semantic-tokens.d.ts.map +0 -1
- package/dist/src/design-system/shadows.d.ts.map +0 -1
- package/dist/src/design-system/themes/default.d.ts +0 -7
- package/dist/src/design-system/themes/default.d.ts.map +0 -1
- package/dist/src/design-system/themes/high-contrast.d.ts +0 -4
- package/dist/src/design-system/themes/high-contrast.d.ts.map +0 -1
- package/dist/src/design-system/themes/index.d.ts +0 -3
- package/dist/src/design-system/themes/index.d.ts.map +0 -1
- package/dist/src/design-system/token-adapter.d.ts.map +0 -1
- package/dist/src/hooks/useDragSnap.d.ts.map +0 -1
- package/dist/src/hooks/useFocusTrap.d.ts.map +0 -1
- package/dist/src/hooks/useResize.d.ts.map +0 -1
- package/dist/src/hooks/useScreenShare.d.ts.map +0 -1
- package/dist/src/hooks/useScrollLock.d.ts.map +0 -1
- package/dist/src/hooks/useWidget.d.ts.map +0 -1
- package/dist/src/index.d.ts.map +0 -1
- package/dist/src/lib/utils.d.ts.map +0 -1
- package/dist/src/sdk/contract.d.ts.map +0 -1
- package/dist/src/sdk/contracts/activityLog.d.ts.map +0 -1
- package/dist/src/sdk/contracts/agent.d.ts +0 -3243
- package/dist/src/sdk/contracts/agent.d.ts.map +0 -1
- package/dist/src/sdk/contracts/application.d.ts.map +0 -1
- package/dist/src/sdk/contracts/chat.d.ts.map +0 -1
- package/dist/src/sdk/contracts/common.d.ts.map +0 -1
- package/dist/src/sdk/contracts/entities.d.ts.map +0 -1
- package/dist/src/sdk/contracts/widget.d.ts.map +0 -1
- package/dist/src/sdk/index.d.ts.map +0 -1
- package/dist/src/services/ApiService.d.ts.map +0 -1
- package/dist/src/services/ChatService.d.ts.map +0 -1
- package/dist/src/services/ConfigManager.d.ts.map +0 -1
- package/dist/src/services/DomService.d.ts.map +0 -1
- package/dist/src/services/ScreenShareService.d.ts.map +0 -1
- package/dist/src/services/SessionManager.d.ts.map +0 -1
- package/dist/src/services/SessionRecorder.d.ts.map +0 -1
- package/dist/src/services/ShowModeService.d.ts.map +0 -1
- package/dist/src/services/StorageService.d.ts.map +0 -1
- package/dist/src/services/StreamClient.d.ts.map +0 -1
- package/dist/src/services/ToolService.d.ts.map +0 -1
- package/dist/src/services/ValidationService.d.ts.map +0 -1
- package/dist/src/services/WidgetService.d.ts.map +0 -1
- package/dist/src/test/a11y-utils.d.ts.map +0 -1
- package/dist/src/test/fixtures.d.ts.map +0 -1
- package/dist/src/test/setup.d.ts.map +0 -1
- package/dist/src/types/browserTools.d.ts.map +0 -1
- package/dist/src/types/index.d.ts.map +0 -1
- package/dist/src/utils/apiUtils.d.ts.map +0 -1
- package/dist/src/utils/bootstrap.d.ts.map +0 -1
- package/dist/src/utils/chat.d.ts.map +0 -1
- package/dist/src/utils/common.d.ts.map +0 -1
- package/dist/src/utils/dom.d.ts.map +0 -1
- package/dist/src/utils/format.d.ts.map +0 -1
- package/dist/src/utils/suggestedActions.d.ts.map +0 -1
- package/dist/src/utils/validation.d.ts.map +0 -1
- package/dist/src/utils/widgetPositioning.d.ts.map +0 -1
|
@@ -78,10 +78,10 @@ export interface ExtractParams {
|
|
|
78
78
|
extract_links?: boolean;
|
|
79
79
|
start_from_char?: number;
|
|
80
80
|
}
|
|
81
|
-
export declare class
|
|
81
|
+
export declare class ToolService {
|
|
82
82
|
private static instance;
|
|
83
83
|
private constructor();
|
|
84
|
-
static getInstance():
|
|
84
|
+
static getInstance(): ToolService;
|
|
85
85
|
executeTool(toolName: string, args: Record<string, unknown>, mode?: string, explanation?: string): Promise<ToolExecutionResult<unknown>>;
|
|
86
86
|
private requiresHighlight;
|
|
87
87
|
private navigate;
|
|
@@ -110,5 +110,4 @@ export declare class ToolExecutionService {
|
|
|
110
110
|
private getInteractableElements;
|
|
111
111
|
private getScreenshot;
|
|
112
112
|
}
|
|
113
|
-
export declare const
|
|
114
|
-
//# sourceMappingURL=ToolService.d.ts.map
|
|
113
|
+
export declare const toolService: ToolService;
|
|
@@ -1,24 +1,23 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type ApplicationData, type WidgetData } from '../sdk';
|
|
2
2
|
import type { MarketrixConfig } from '../types';
|
|
3
3
|
export interface WidgetValidationResult {
|
|
4
4
|
isValid: boolean;
|
|
5
5
|
error?: string;
|
|
6
6
|
widget?: WidgetData;
|
|
7
|
-
agent?: AgentData;
|
|
8
7
|
application?: ApplicationData;
|
|
9
8
|
}
|
|
10
9
|
/**
|
|
11
|
-
*
|
|
10
|
+
* ValidationService
|
|
12
11
|
*
|
|
13
12
|
* Validates widget configuration by checking:
|
|
14
|
-
* 1. Widget exists (via marketrix_id and marketrix_key) OR
|
|
15
|
-
* 2.
|
|
13
|
+
* 1. Widget exists (via marketrix_id and marketrix_key) and its application exists, OR
|
|
14
|
+
* 2. The application ID exists
|
|
16
15
|
*/
|
|
17
|
-
export declare class
|
|
16
|
+
export declare class ValidationService {
|
|
18
17
|
private config?;
|
|
19
18
|
/**
|
|
20
19
|
* Validate widget configuration
|
|
21
|
-
* Handles both mtxId+mtxKey and mtxApp
|
|
20
|
+
* Handles both mtxId+mtxKey and mtxApp cases
|
|
22
21
|
*/
|
|
23
22
|
validateConfig(config: MarketrixConfig): Promise<WidgetValidationResult>;
|
|
24
23
|
/**
|
|
@@ -26,10 +25,8 @@ export declare class WidgetValidationService {
|
|
|
26
25
|
*/
|
|
27
26
|
private validateByMarketrixId;
|
|
28
27
|
/**
|
|
29
|
-
* Validate by mtxApp
|
|
30
|
-
* Validates application
|
|
28
|
+
* Validate by mtxApp directly
|
|
29
|
+
* Validates the application by ID
|
|
31
30
|
*/
|
|
32
|
-
private
|
|
31
|
+
private validateByApplication;
|
|
33
32
|
}
|
|
34
|
-
export default WidgetValidationService;
|
|
35
|
-
//# sourceMappingURL=ValidationService.d.ts.map
|
package/dist/src/test/setup.d.ts
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
* Browser Use Tools - widget tool registry.
|
|
3
3
|
*
|
|
4
4
|
* IMPORTANT: This file is the single source of truth for widget tool metadata.
|
|
5
|
-
* ALLOWED_TOOLS in
|
|
6
|
-
* from BROWSER_TOOLS below.
|
|
5
|
+
* ALLOWED_TOOLS in ConversationContext.tsx and TOOL_NAME_MAPPING in chat.ts are
|
|
6
|
+
* derived from BROWSER_TOOLS below.
|
|
7
7
|
*/
|
|
8
8
|
interface BrowserToolMetadata {
|
|
9
9
|
id: string;
|
|
@@ -14,12 +14,5 @@ interface BrowserToolMetadata {
|
|
|
14
14
|
category: 'navigation' | 'interaction' | 'extraction' | 'utility';
|
|
15
15
|
actionType: string;
|
|
16
16
|
}
|
|
17
|
-
export declare const BROWSER_TOOL_CATEGORIES: {
|
|
18
|
-
readonly navigation: "Navigation";
|
|
19
|
-
readonly interaction: "Interaction";
|
|
20
|
-
readonly extraction: "Extraction";
|
|
21
|
-
readonly utility: "Utility";
|
|
22
|
-
};
|
|
23
17
|
export declare const BROWSER_TOOLS: BrowserToolMetadata[];
|
|
24
18
|
export {};
|
|
25
|
-
//# sourceMappingURL=browserTools.d.ts.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { InstructionType, WidgetSettingsData } from '../sdk';
|
|
2
|
-
export type {
|
|
2
|
+
export type { ApplicationData, InstructionType, UserData, WidgetChip, WidgetData, WidgetSettingsData, WorkspaceData, } from '../sdk';
|
|
3
3
|
/**
|
|
4
4
|
* MarketrixConfig - Single source of truth for all widget configuration
|
|
5
5
|
*
|
|
@@ -20,7 +20,6 @@ export type MarketrixConfig = Partial<WidgetSettingsData> & {
|
|
|
20
20
|
mtxId?: string;
|
|
21
21
|
mtxKey?: string;
|
|
22
22
|
mtxApp?: number;
|
|
23
|
-
mtxAgent?: number;
|
|
24
23
|
userId?: number;
|
|
25
24
|
mtxApiHost?: string;
|
|
26
25
|
widget_position_offset?: {
|
|
@@ -33,8 +32,6 @@ export type MarketrixConfig = Partial<WidgetSettingsData> & {
|
|
|
33
32
|
show_widget?: boolean;
|
|
34
33
|
/** Controls screen sharing prompts and button. When false, screen access requests are auto-denied and Share Screen button is hidden. Default: true */
|
|
35
34
|
use_screenshare?: boolean;
|
|
36
|
-
agent_name?: string;
|
|
37
|
-
agent_description?: string;
|
|
38
35
|
};
|
|
39
36
|
export interface ChatMessage {
|
|
40
37
|
id: string;
|
|
@@ -59,15 +56,7 @@ export interface MessagePart {
|
|
|
59
56
|
hideIcon?: boolean;
|
|
60
57
|
textStyle?: 'default' | 'muted';
|
|
61
58
|
}
|
|
62
|
-
export
|
|
63
|
-
tool_name: string;
|
|
64
|
-
tool_params: Record<string, unknown>;
|
|
65
|
-
step: number;
|
|
66
|
-
explanation: string;
|
|
67
|
-
mode: string;
|
|
68
|
-
timestamp: number;
|
|
69
|
-
}
|
|
70
|
-
export type WidgetView = 'home' | 'chat' | 'help' | 'news';
|
|
59
|
+
export type WidgetView = 'home' | 'chat';
|
|
71
60
|
export interface WidgetState {
|
|
72
61
|
isOpen: boolean;
|
|
73
62
|
isMinimized: boolean;
|
|
@@ -78,7 +67,6 @@ export interface WidgetState {
|
|
|
78
67
|
error?: string;
|
|
79
68
|
activeTaskId: string | null;
|
|
80
69
|
isTaskRunning: boolean;
|
|
81
|
-
taskProgress: TaskProgress[];
|
|
82
70
|
activeView: WidgetView;
|
|
83
71
|
}
|
|
84
72
|
export interface SendMessageRequest {
|
|
@@ -107,19 +95,16 @@ export type AddWidgetConfig = ({
|
|
|
107
95
|
mtxId?: never;
|
|
108
96
|
mtxKey?: never;
|
|
109
97
|
mtxApp?: never;
|
|
110
|
-
mtxAgent?: never;
|
|
111
98
|
} | {
|
|
112
99
|
settings?: never;
|
|
113
100
|
mtxId: string;
|
|
114
101
|
mtxKey: string;
|
|
115
102
|
mtxApp?: never;
|
|
116
|
-
mtxAgent?: never;
|
|
117
103
|
} | {
|
|
118
104
|
settings?: never;
|
|
119
105
|
mtxId?: never;
|
|
120
106
|
mtxKey?: never;
|
|
121
107
|
mtxApp: number;
|
|
122
|
-
mtxAgent: number;
|
|
123
108
|
}) & {
|
|
124
109
|
container?: HTMLElement;
|
|
125
110
|
mtxApiHost?: string;
|
|
@@ -144,5 +129,4 @@ export interface MarketrixWidgetProps {
|
|
|
144
129
|
mtxKey?: string;
|
|
145
130
|
mtxApiHost?: string;
|
|
146
131
|
}
|
|
147
|
-
export {
|
|
148
|
-
//# sourceMappingURL=index.d.ts.map
|
|
132
|
+
export { BROWSER_TOOLS } from './browserTools';
|
|
@@ -62,16 +62,6 @@ export declare const setProgrammaticInitInProgress: (inProgress: boolean) => voi
|
|
|
62
62
|
* Check if programmatic initialization is in progress
|
|
63
63
|
*/
|
|
64
64
|
export declare const isProgrammaticInitInProgress: () => boolean;
|
|
65
|
-
/**
|
|
66
|
-
* Check if a production widget is already active on this page
|
|
67
|
-
* Production widgets (non-preview) should be singletons - only one per page
|
|
68
|
-
*/
|
|
69
|
-
export declare const isProductionWidgetActive: () => boolean;
|
|
70
|
-
/**
|
|
71
|
-
* Set production widget active state
|
|
72
|
-
* Call with true when initializing a production widget, false when unmounting
|
|
73
|
-
*/
|
|
74
|
-
export declare const setProductionWidgetActive: (active: boolean) => void;
|
|
75
65
|
/**
|
|
76
66
|
* Show widget settings loader with optional message
|
|
77
67
|
*/
|
|
@@ -91,4 +81,3 @@ export declare const autoInitializeWidget: (retryCount?: number) => void;
|
|
|
91
81
|
* @param initWidget - Function to initialize the widget (passed to avoid circular dependency)
|
|
92
82
|
*/
|
|
93
83
|
export declare const registerAutoInit: (initWidget: (config: MarketrixConfig) => Promise<void>) => void;
|
|
94
|
-
//# sourceMappingURL=bootstrap.d.ts.map
|
package/dist/src/utils/chat.d.ts
CHANGED
|
@@ -21,10 +21,6 @@ export declare function hasThinkingMarker(content: string): boolean;
|
|
|
21
21
|
* Add thinking marker to content
|
|
22
22
|
*/
|
|
23
23
|
export declare function addThinkingMarker(content: string): string;
|
|
24
|
-
/**
|
|
25
|
-
* Find the index of the last task message (agent message that's not system/placeholder/screen access)
|
|
26
|
-
*/
|
|
27
|
-
export declare function findTaskMessageIndex(messages: ChatMessage[]): number;
|
|
28
24
|
/**
|
|
29
25
|
* Message Finder Utility
|
|
30
26
|
*
|
|
@@ -54,12 +50,6 @@ export declare function findMessageForProgress(options: FindMessageOptions): {
|
|
|
54
50
|
index: number;
|
|
55
51
|
message: ChatMessage;
|
|
56
52
|
} | null;
|
|
57
|
-
/**
|
|
58
|
-
* Tools that should show an icon and standard text style.
|
|
59
|
-
* These are "mouse and keyboard" interactions.
|
|
60
|
-
* All other tools will have hidden icons and muted text.
|
|
61
|
-
*/
|
|
62
|
-
export declare const INTERACTIVE_TOOLS: Set<string>;
|
|
63
53
|
/**
|
|
64
54
|
* Tools that, in `show` mode, pause for the user to perform the action
|
|
65
55
|
* themselves (DOM-mutating "mouse and keyboard" actions, minus `scroll`).
|
|
@@ -92,4 +82,3 @@ export declare const TOOL_NAME_MAPPING: Record<string, string>;
|
|
|
92
82
|
* Converts snake_case to Title Case if no mapping exists
|
|
93
83
|
*/
|
|
94
84
|
export declare function getFriendlyToolName(toolName: string): string;
|
|
95
|
-
//# sourceMappingURL=chat.d.ts.map
|
package/dist/src/utils/dom.d.ts
CHANGED
|
@@ -4,17 +4,4 @@
|
|
|
4
4
|
* Centralized utilities for common DOM operations to reduce code duplication
|
|
5
5
|
* and ensure consistent error handling.
|
|
6
6
|
*/
|
|
7
|
-
/**
|
|
8
|
-
* Get all interactive elements on the page, ordered by DOM position.
|
|
9
|
-
* Interactive elements include: buttons, inputs, links, select elements, etc.
|
|
10
|
-
*/
|
|
11
|
-
export declare function getAllInteractiveElements(): HTMLElement[];
|
|
12
|
-
/**
|
|
13
|
-
* Get an interactive element by its index.
|
|
14
|
-
* First tries to use data-id from get_html indexing, then falls back to current behavior.
|
|
15
|
-
* @param index The zero-based index of the element
|
|
16
|
-
* @returns The element at the given index, or null if not found
|
|
17
|
-
*/
|
|
18
|
-
export declare function getElementByIndex(index: number): HTMLElement | null;
|
|
19
7
|
export declare function isInteractable(el: Element | null): boolean;
|
|
20
|
-
//# sourceMappingURL=dom.d.ts.map
|
|
@@ -24,4 +24,3 @@ export declare function addOpacity(color: string, opacity: number): string;
|
|
|
24
24
|
export declare function darkenColor(color: string, amount: number): string;
|
|
25
25
|
export declare const formatMessageTime: (date: Date | undefined) => string;
|
|
26
26
|
export declare const getModeDisplayName: (mode: "show" | "tell" | "do") => string;
|
|
27
|
-
//# sourceMappingURL=format.d.ts.map
|
|
@@ -5,14 +5,6 @@
|
|
|
5
5
|
* These are shared utilities used across the codebase.
|
|
6
6
|
*/
|
|
7
7
|
import type { WidgetSettingsData } from '../sdk';
|
|
8
|
-
/**
|
|
9
|
-
* Check if an object has a specific property
|
|
10
|
-
*/
|
|
11
|
-
export declare function hasProperty<K extends string>(obj: unknown, key: K): obj is Record<K, unknown>;
|
|
12
|
-
/**
|
|
13
|
-
* Check if a value is a non-null object
|
|
14
|
-
*/
|
|
15
|
-
export declare function isNonNullObject(value: unknown): value is Record<string, unknown>;
|
|
16
8
|
/**
|
|
17
9
|
* Type guard for WidgetSettingsData
|
|
18
10
|
*/
|
|
@@ -25,4 +17,3 @@ export declare function isHTMLElement(element: Element | null): element is HTMLE
|
|
|
25
17
|
* Type guard for HTMLScriptElement
|
|
26
18
|
*/
|
|
27
19
|
export declare function isHTMLScriptElement(element: Element | null): element is HTMLScriptElement;
|
|
28
|
-
//# sourceMappingURL=validation.d.ts.map
|