@burdenoff/microfe-botmanor 2026.1108.1 → 2026.1109.2
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/botlit/BotlitRoutes.d.ts +2 -0
- package/dist/botlit/BotlitRoutes.js +40 -52
- package/dist/botlit/BotlitRoutes.js.map +1 -1
- package/dist/botlit/BotmanorRoot.d.ts +3 -0
- package/dist/botlit/BotmanorRoot.js +1 -2
- package/dist/botlit/BotmanorRoot.js.map +1 -1
- package/dist/botlit/BotmanorRootInner.d.ts +3 -0
- package/dist/botlit/BotmanorRootInner.js +9 -10
- package/dist/botlit/BotmanorRootInner.js.map +1 -1
- package/dist/botlit/components/AgentApprovalPanel.d.ts +20 -0
- package/dist/botlit/components/AgentApprovalPanel.js +49 -50
- package/dist/botlit/components/AgentApprovalPanel.js.map +1 -1
- package/dist/botlit/components/AiOperationsPanel.d.ts +14 -0
- package/dist/botlit/components/AiOperationsPanel.js +54 -55
- package/dist/botlit/components/AiOperationsPanel.js.map +1 -1
- package/dist/botlit/components/AssistantChannelPanel.d.ts +3 -0
- package/dist/botlit/components/AssistantChannelPanel.js +12 -13
- package/dist/botlit/components/AssistantChannelPanel.js.map +1 -1
- package/dist/botlit/components/AssistantRuntimeSetupPanel.d.ts +4 -0
- package/dist/botlit/components/AssistantRuntimeSetupPanel.js +14 -14
- package/dist/botlit/components/AssistantRuntimeSetupPanel.js.map +1 -1
- package/dist/botlit/components/AssistantWebsitePanel.d.ts +5 -0
- package/dist/botlit/components/AssistantWebsitePanel.js +15 -16
- package/dist/botlit/components/AssistantWebsitePanel.js.map +1 -1
- package/dist/botlit/components/Badge.d.ts +9 -0
- package/dist/botlit/components/Badge.js +1 -2
- package/dist/botlit/components/Badge.js.map +1 -1
- package/dist/botlit/components/Button.d.ts +10 -0
- package/dist/botlit/components/Button.js +1 -2
- package/dist/botlit/components/Button.js.map +1 -1
- package/dist/botlit/components/Card.d.ts +16 -0
- package/dist/botlit/components/Card.js +1 -2
- package/dist/botlit/components/Card.js.map +1 -1
- package/dist/botlit/components/ChannelSelectorSheet.d.ts +23 -0
- package/dist/botlit/components/ChannelSelectorSheet.js +1 -2
- package/dist/botlit/components/ChannelSelectorSheet.js.map +1 -1
- package/dist/botlit/components/EmptyState.d.ts +12 -0
- package/dist/botlit/components/EmptyState.js +1 -2
- package/dist/botlit/components/EmptyState.js.map +1 -1
- package/dist/botlit/components/ErrorState.d.ts +10 -0
- package/dist/botlit/components/ErrorState.js +5 -6
- package/dist/botlit/components/ErrorState.js.map +1 -1
- package/dist/botlit/components/Input.d.ts +27 -0
- package/dist/botlit/components/Input.js +1 -2
- package/dist/botlit/components/Input.js.map +1 -1
- package/dist/botlit/components/KnowledgeSourceImportPanel.d.ts +3 -0
- package/dist/botlit/components/KnowledgeSourceImportPanel.js +12 -13
- package/dist/botlit/components/KnowledgeSourceImportPanel.js.map +1 -1
- package/dist/botlit/components/ModelRegistrationPanel.d.ts +5 -0
- package/dist/botlit/components/ModelRegistrationPanel.js +1 -2
- package/dist/botlit/components/ModelRegistrationPanel.js.map +1 -1
- package/dist/botlit/components/PageLayout.d.ts +12 -0
- package/dist/botlit/components/PageLayout.js +1 -2
- package/dist/botlit/components/PageLayout.js.map +1 -1
- package/dist/botlit/components/QuotaExhaustedDialog.d.ts +9 -0
- package/dist/botlit/components/QuotaExhaustedDialog.js +1 -2
- package/dist/botlit/components/QuotaExhaustedDialog.js.map +1 -1
- package/dist/botlit/components/RetentionStatusPanel.d.ts +2 -0
- package/dist/botlit/components/RetentionStatusPanel.js +18 -19
- package/dist/botlit/components/RetentionStatusPanel.js.map +1 -1
- package/dist/botlit/components/RouteLoader.d.ts +23 -0
- package/dist/botlit/components/RouteLoader.js +1 -2
- package/dist/botlit/components/RouteLoader.js.map +1 -1
- package/dist/botlit/components/VersionHistoryPanel.d.ts +12 -0
- package/dist/botlit/components/VersionHistoryPanel.js +23 -24
- package/dist/botlit/components/VersionHistoryPanel.js.map +1 -1
- package/dist/botlit/components/WorkspaceRequired.d.ts +18 -0
- package/dist/botlit/components/WorkspaceRequired.js +1 -2
- package/dist/botlit/components/WorkspaceRequired.js.map +1 -1
- package/dist/botlit/components/index.d.ts +14 -0
- package/dist/botlit/hooks/index.d.ts +35 -0
- package/dist/botlit/hooks/index.js +16 -16
- package/dist/botlit/hooks/internal/mutationInput.d.ts +56 -0
- package/dist/botlit/hooks/internal/mutationInput.js +1 -2
- package/dist/botlit/hooks/internal/mutationInput.js.map +1 -1
- package/dist/botlit/hooks/internal/workspaceGateway.d.ts +54 -0
- package/dist/botlit/hooks/internal/workspaceGateway.js +17 -19
- package/dist/botlit/hooks/internal/workspaceGateway.js.map +1 -1
- package/dist/botlit/hooks/useA2A.d.ts +104 -0
- package/dist/botlit/hooks/useA2A.js +45 -45
- package/dist/botlit/hooks/useA2A.js.map +1 -1
- package/dist/botlit/hooks/useAgentApprovals.d.ts +62 -0
- package/dist/botlit/hooks/useAgentApprovals.js +38 -39
- package/dist/botlit/hooks/useAgentApprovals.js.map +1 -1
- package/dist/botlit/hooks/useAgents.d.ts +105 -0
- package/dist/botlit/hooks/useAgents.js +53 -54
- package/dist/botlit/hooks/useAgents.js.map +1 -1
- package/dist/botlit/hooks/useAiOperations.d.ts +95 -0
- package/dist/botlit/hooks/useAiOperations.js +20 -19
- package/dist/botlit/hooks/useAiOperations.js.map +1 -1
- package/dist/botlit/hooks/useAssistantChannels.d.ts +16 -0
- package/dist/botlit/hooks/useAssistantChannels.js +1 -2
- package/dist/botlit/hooks/useAssistantChannels.js.map +1 -1
- package/dist/botlit/hooks/useAssistantRuntimeSetup.d.ts +17 -0
- package/dist/botlit/hooks/useAssistantRuntimeSetup.js +1 -2
- package/dist/botlit/hooks/useAssistantRuntimeSetup.js.map +1 -1
- package/dist/botlit/hooks/useAssistantWebsites.d.ts +18 -0
- package/dist/botlit/hooks/useAssistantWebsites.js +1 -2
- package/dist/botlit/hooks/useAssistantWebsites.js.map +1 -1
- package/dist/botlit/hooks/useBotWorkflow.d.ts +22 -0
- package/dist/botlit/hooks/useBotWorkflow.js +1 -2
- package/dist/botlit/hooks/useBotWorkflow.js.map +1 -1
- package/dist/botlit/hooks/useBots.d.ts +68 -0
- package/dist/botlit/hooks/useBots.js +32 -33
- package/dist/botlit/hooks/useBots.js.map +1 -1
- package/dist/botlit/hooks/useBuckets.d.ts +62 -0
- package/dist/botlit/hooks/useBuckets.js +91 -58
- package/dist/botlit/hooks/useBuckets.js.map +1 -1
- package/dist/botlit/hooks/useChannels.d.ts +87 -0
- package/dist/botlit/hooks/useChannels.js +73 -73
- package/dist/botlit/hooks/useChannels.js.map +1 -1
- package/dist/botlit/hooks/useExecutions.d.ts +87 -0
- package/dist/botlit/hooks/useExecutions.js +37 -37
- package/dist/botlit/hooks/useExecutions.js.map +1 -1
- package/dist/botlit/hooks/useKnowledgeBases.d.ts +79 -0
- package/dist/botlit/hooks/useKnowledgeBases.js +40 -39
- package/dist/botlit/hooks/useKnowledgeBases.js.map +1 -1
- package/dist/botlit/hooks/useKnowledgeSourceImports.d.ts +21 -0
- package/dist/botlit/hooks/useKnowledgeSourceImports.js +1 -2
- package/dist/botlit/hooks/useKnowledgeSourceImports.js.map +1 -1
- package/dist/botlit/hooks/useLLMProviders.d.ts +66 -0
- package/dist/botlit/hooks/useLLMProviders.js +25 -26
- package/dist/botlit/hooks/useLLMProviders.js.map +1 -1
- package/dist/botlit/hooks/useMCPServers.d.ts +71 -0
- package/dist/botlit/hooks/useMCPServers.js +40 -38
- package/dist/botlit/hooks/useMCPServers.js.map +1 -1
- package/dist/botlit/hooks/usePolicies.d.ts +60 -0
- package/dist/botlit/hooks/usePolicies.js +49 -49
- package/dist/botlit/hooks/usePolicies.js.map +1 -1
- package/dist/botlit/hooks/usePromptTemplates.d.ts +88 -0
- package/dist/botlit/hooks/usePromptTemplates.js +57 -57
- package/dist/botlit/hooks/usePromptTemplates.js.map +1 -1
- package/dist/botlit/hooks/useRetention.d.ts +26 -0
- package/dist/botlit/hooks/useRetention.js +3 -3
- package/dist/botlit/hooks/useRetention.js.map +1 -1
- package/dist/botlit/hooks/useRetrievalProfiles.d.ts +75 -0
- package/dist/botlit/hooks/useRetrievalProfiles.js +47 -47
- package/dist/botlit/hooks/useRetrievalProfiles.js.map +1 -1
- package/dist/botlit/hooks/useSkills.d.ts +64 -0
- package/dist/botlit/hooks/useSkills.js +53 -53
- package/dist/botlit/hooks/useSkills.js.map +1 -1
- package/dist/botlit/hooks/useStore.d.ts +112 -0
- package/dist/botlit/hooks/useStore.js +55 -55
- package/dist/botlit/hooks/useStore.js.map +1 -1
- package/dist/botlit/hooks/useUserPlatformConnection.d.ts +80 -0
- package/dist/botlit/hooks/useUserPlatformConnection.js +19 -19
- package/dist/botlit/hooks/useUserPlatformConnection.js.map +1 -1
- package/dist/botlit/index.d.ts +15 -0
- package/dist/botlit/index.js +11 -11
- package/dist/botlit/pages/A2AAgentDetailPage.d.ts +6 -0
- package/dist/botlit/pages/A2AAgentDetailPage.js +171 -178
- package/dist/botlit/pages/A2AAgentDetailPage.js.map +1 -1
- package/dist/botlit/pages/A2ARegistryPage.d.ts +2 -0
- package/dist/botlit/pages/A2ARegistryPage.js +25 -26
- package/dist/botlit/pages/A2ARegistryPage.js.map +1 -1
- package/dist/botlit/pages/AgentApprovalsPage.d.ts +2 -0
- package/dist/botlit/pages/AgentApprovalsPage.js +32 -33
- package/dist/botlit/pages/AgentApprovalsPage.js.map +1 -1
- package/dist/botlit/pages/AgentBuilderPage.d.ts +2 -0
- package/dist/botlit/pages/AgentBuilderPage.js +59 -60
- package/dist/botlit/pages/AgentBuilderPage.js.map +1 -1
- package/dist/botlit/pages/AgentDetailPage.d.ts +2 -0
- package/dist/botlit/pages/AgentDetailPage.js +83 -84
- package/dist/botlit/pages/AgentDetailPage.js.map +1 -1
- package/dist/botlit/pages/AgentsListPage.d.ts +2 -0
- package/dist/botlit/pages/AgentsListPage.js +71 -72
- package/dist/botlit/pages/AgentsListPage.js.map +1 -1
- package/dist/botlit/pages/AiOperationsPage.d.ts +2 -0
- package/dist/botlit/pages/AiOperationsPage.js +52 -53
- package/dist/botlit/pages/AiOperationsPage.js.map +1 -1
- package/dist/botlit/pages/BotChannelsTab.d.ts +7 -0
- package/dist/botlit/pages/BotChannelsTab.js +120 -122
- package/dist/botlit/pages/BotChannelsTab.js.map +1 -1
- package/dist/botlit/pages/BotDetailPage.d.ts +7 -0
- package/dist/botlit/pages/BotDetailPage.js +353 -358
- package/dist/botlit/pages/BotDetailPage.js.map +1 -1
- package/dist/botlit/pages/BotWorkflowTab.d.ts +11 -0
- package/dist/botlit/pages/BotWorkflowTab.js +20 -21
- package/dist/botlit/pages/BotWorkflowTab.js.map +1 -1
- package/dist/botlit/pages/BotsListPage.d.ts +2 -0
- package/dist/botlit/pages/BotsListPage.js +52 -53
- package/dist/botlit/pages/BotsListPage.js.map +1 -1
- package/dist/botlit/pages/BucketDetailPage.d.ts +2 -0
- package/dist/botlit/pages/BucketDetailPage.js +251 -0
- package/dist/botlit/pages/BucketDetailPage.js.map +1 -0
- package/dist/botlit/pages/BucketsPage.d.ts +2 -0
- package/dist/botlit/pages/BucketsPage.js +260 -261
- package/dist/botlit/pages/BucketsPage.js.map +1 -1
- package/dist/botlit/pages/ChannelDetailPage.d.ts +6 -0
- package/dist/botlit/pages/ChannelDetailPage.js +97 -96
- package/dist/botlit/pages/ChannelDetailPage.js.map +1 -1
- package/dist/botlit/pages/ChannelRoutesPage.d.ts +2 -0
- package/dist/botlit/pages/ChannelRoutesPage.js +23 -24
- package/dist/botlit/pages/ChannelRoutesPage.js.map +1 -1
- package/dist/botlit/pages/ChannelsPage.d.ts +2 -0
- package/dist/botlit/pages/ChannelsPage.js +44 -45
- package/dist/botlit/pages/ChannelsPage.js.map +1 -1
- package/dist/botlit/pages/ChatPage.d.ts +1 -0
- package/dist/botlit/pages/ChatPage.js +10 -11
- package/dist/botlit/pages/ChatPage.js.map +1 -1
- package/dist/botlit/pages/DashboardPage.d.ts +2 -0
- package/dist/botlit/pages/DashboardPage.js +37 -38
- package/dist/botlit/pages/DashboardPage.js.map +1 -1
- package/dist/botlit/pages/ExecutionDetailPage.d.ts +2 -0
- package/dist/botlit/pages/ExecutionDetailPage.js +47 -48
- package/dist/botlit/pages/ExecutionDetailPage.js.map +1 -1
- package/dist/botlit/pages/ExecutionsPage.d.ts +2 -0
- package/dist/botlit/pages/ExecutionsPage.js +72 -70
- package/dist/botlit/pages/ExecutionsPage.js.map +1 -1
- package/dist/botlit/pages/InstalledPackagesPage.d.ts +2 -0
- package/dist/botlit/pages/InstalledPackagesPage.js +77 -78
- package/dist/botlit/pages/InstalledPackagesPage.js.map +1 -1
- package/dist/botlit/pages/KnowledgeBaseDetailPage.d.ts +6 -0
- package/dist/botlit/pages/KnowledgeBaseDetailPage.js +171 -181
- package/dist/botlit/pages/KnowledgeBaseDetailPage.js.map +1 -1
- package/dist/botlit/pages/KnowledgeBasesPage.d.ts +2 -0
- package/dist/botlit/pages/KnowledgeBasesPage.js +30 -31
- package/dist/botlit/pages/KnowledgeBasesPage.js.map +1 -1
- package/dist/botlit/pages/MCPServerDetailPage.d.ts +6 -0
- package/dist/botlit/pages/MCPServerDetailPage.js +82 -83
- package/dist/botlit/pages/MCPServerDetailPage.js.map +1 -1
- package/dist/botlit/pages/MCPServersPage.d.ts +2 -0
- package/dist/botlit/pages/MCPServersPage.js +54 -55
- package/dist/botlit/pages/MCPServersPage.js.map +1 -1
- package/dist/botlit/pages/PoliciesPage.d.ts +2 -0
- package/dist/botlit/pages/PoliciesPage.js +25 -26
- package/dist/botlit/pages/PoliciesPage.js.map +1 -1
- package/dist/botlit/pages/PolicyDetailPage.d.ts +6 -0
- package/dist/botlit/pages/PolicyDetailPage.js +257 -259
- package/dist/botlit/pages/PolicyDetailPage.js.map +1 -1
- package/dist/botlit/pages/PromptStudioPage.d.ts +2 -0
- package/dist/botlit/pages/PromptStudioPage.js +35 -35
- package/dist/botlit/pages/PromptStudioPage.js.map +1 -1
- package/dist/botlit/pages/PromptTemplateDetailPage.d.ts +6 -0
- package/dist/botlit/pages/PromptTemplateDetailPage.js +363 -362
- package/dist/botlit/pages/PromptTemplateDetailPage.js.map +1 -1
- package/dist/botlit/pages/PromptTemplatesPage.d.ts +2 -0
- package/dist/botlit/pages/PromptTemplatesPage.js +26 -27
- package/dist/botlit/pages/PromptTemplatesPage.js.map +1 -1
- package/dist/botlit/pages/RetrievalProfileDetailPage.d.ts +6 -0
- package/dist/botlit/pages/RetrievalProfileDetailPage.js +150 -158
- package/dist/botlit/pages/RetrievalProfileDetailPage.js.map +1 -1
- package/dist/botlit/pages/RetrievalProfilesPage.d.ts +2 -0
- package/dist/botlit/pages/RetrievalProfilesPage.js +24 -25
- package/dist/botlit/pages/RetrievalProfilesPage.js.map +1 -1
- package/dist/botlit/pages/SettingsPage.d.ts +2 -0
- package/dist/botlit/pages/SettingsPage.js +124 -125
- package/dist/botlit/pages/SettingsPage.js.map +1 -1
- package/dist/botlit/pages/SkillDetailPage.d.ts +6 -0
- package/dist/botlit/pages/SkillDetailPage.js +216 -217
- package/dist/botlit/pages/SkillDetailPage.js.map +1 -1
- package/dist/botlit/pages/SkillsPage.d.ts +2 -0
- package/dist/botlit/pages/SkillsPage.js +24 -25
- package/dist/botlit/pages/SkillsPage.js.map +1 -1
- package/dist/botlit/pages/StorePackageDetailPage.d.ts +2 -0
- package/dist/botlit/pages/StorePackageDetailPage.js +38 -39
- package/dist/botlit/pages/StorePackageDetailPage.js.map +1 -1
- package/dist/botlit/pages/StorePage.d.ts +2 -0
- package/dist/botlit/pages/StorePage.js +135 -136
- package/dist/botlit/pages/StorePage.js.map +1 -1
- package/dist/botlit/pages/index.d.ts +38 -0
- package/dist/botlit/permissions/PermissionRequired.d.ts +20 -0
- package/dist/botlit/permissions/PermissionRequired.js +10 -11
- package/dist/botlit/permissions/PermissionRequired.js.map +1 -1
- package/dist/botlit/permissions/botmanorPermissions.d.ts +82 -0
- package/dist/botlit/permissions/botmanorPermissions.js +1 -2
- package/dist/botlit/permissions/botmanorPermissions.js.map +1 -1
- package/dist/botlit/permissions/index.d.ts +7 -0
- package/dist/botlit/permissions/index.js +4 -3
- package/dist/botlit/permissions/useBotmanorPermissions.d.ts +41 -0
- package/dist/botlit/permissions/useBotmanorPermissions.js +1 -2
- package/dist/botlit/permissions/useBotmanorPermissions.js.map +1 -1
- package/dist/botlit/providers/BotlitProvider.d.ts +14 -0
- package/dist/botlit/providers/BotlitProvider.js +3 -3
- package/dist/botlit/providers/BotlitProvider.js.map +1 -1
- package/dist/botlit/store/botlitStore.d.ts +85 -0
- package/dist/botlit/store/botlitStore.js +1 -2
- package/dist/botlit/store/botlitStore.js.map +1 -1
- package/dist/botlit/store/renamedKeyStorage.d.ts +13 -0
- package/dist/botlit/store/renamedKeyStorage.js +1 -2
- package/dist/botlit/store/renamedKeyStorage.js.map +1 -1
- package/dist/botlit/types/index.d.ts +1008 -0
- package/dist/botlit/utils/cn.d.ts +2 -0
- package/dist/botlit/utils/cn.js +1 -2
- package/dist/botlit/utils/cn.js.map +1 -1
- package/dist/botlit/utils/embedding-models.d.ts +9 -0
- package/dist/botlit/utils/embedding-models.js +1 -2
- package/dist/botlit/utils/embedding-models.js.map +1 -1
- package/dist/botlit/utils/errors.d.ts +19 -0
- package/dist/botlit/utils/errors.js +1 -2
- package/dist/botlit/utils/errors.js.map +1 -1
- package/dist/botlit/utils/formatters.d.ts +38 -0
- package/dist/botlit/utils/formatters.js +0 -1
- package/dist/botlit/utils/formatters.js.map +1 -1
- package/dist/botlit/utils/navigation.d.ts +19 -0
- package/dist/botlit/utils/navigation.js +1 -2
- package/dist/botlit/utils/navigation.js.map +1 -1
- package/dist/botlit/utils/policyConfig.d.ts +68 -0
- package/dist/botlit/utils/policyConfig.js +2 -3
- package/dist/botlit/utils/policyConfig.js.map +1 -1
- package/dist/botlit/utils/unions.d.ts +25 -0
- package/dist/botlit/utils/unions.js +1 -2
- package/dist/botlit/utils/unions.js.map +1 -1
- package/dist/dev/App.d.ts +2 -0
- package/dist/dev/main.d.ts +0 -0
- package/dist/generated/global-operations.d.ts +197 -0
- package/dist/generated/global-operations.js +1 -2
- package/dist/generated/global-operations.js.map +1 -1
- package/dist/generated/global-types.d.ts +27678 -0
- package/dist/generated/global-types.js +1 -2
- package/dist/generated/global-types.js.map +1 -1
- package/dist/generated/wspace-operations.d.ts +5489 -0
- package/dist/generated/wspace-operations.js +88 -84
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.d.ts +152017 -0
- package/dist/generated/wspace-types.js +1 -2
- package/dist/generated/wspace-types.js.map +1 -1
- package/dist/index.d.ts +5 -0
- package/dist/index.js +5 -6
- package/dist/shared/hooks/useTr.d.ts +16 -0
- package/dist/shared/hooks/useTr.js +1 -2
- package/dist/shared/hooks/useTr.js.map +1 -1
- package/dist/stories/Badge.stories.d.ts +11 -0
- package/dist/stories/Button.stories.d.ts +13 -0
- package/dist/stories/EmptyState.stories.d.ts +8 -0
- package/dist/stories/StatusBadge.stories.d.ts +9 -0
- package/dist/test/fixtures.d.ts +39 -0
- package/dist/test/happydom.d.ts +1 -0
- package/dist/test/renderPage.d.ts +18 -0
- package/dist/test/setup.d.ts +9 -0
- package/dist/utils/nativeBridge.d.ts +2 -0
- package/dist/utils/nativeBridge.js +1 -2
- package/package.json +87 -60
- package/dist/botlit/hooks/useConversations.js +0 -64
- package/dist/botlit/hooks/useConversations.js.map +0 -1
package/dist/index.d.ts
ADDED
package/dist/index.js
CHANGED
|
@@ -4,10 +4,9 @@ import { useBotlitStore as r } from "./botlit/store/botlitStore.js";
|
|
|
4
4
|
import { useBot as i, useBots as a, useCreateBot as o, useDeleteBot as s, useUpdateBot as c } from "./botlit/hooks/useBots.js";
|
|
5
5
|
import { useAgent as l, useAgents as u, useCreateAgent as d, useDeleteAgent as f, useUpdateAgent as p } from "./botlit/hooks/useAgents.js";
|
|
6
6
|
import { useCreateKnowledgeBase as m, useKnowledgeBase as h, useKnowledgeBases as g, useKnowledgeDocuments as _ } from "./botlit/hooks/useKnowledgeBases.js";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { formatDate as E, formatRelativeTime as D } from "./botlit/utils/formatters.js";
|
|
7
|
+
import { useConfigureLLMProvider as v, useLLMProviders as y } from "./botlit/hooks/useLLMProviders.js";
|
|
8
|
+
import { useCreateMCPServer as b, useMCPServers as x } from "./botlit/hooks/useMCPServers.js";
|
|
9
|
+
import { cn as S } from "./botlit/utils/cn.js";
|
|
10
|
+
import { formatDate as C, formatRelativeTime as w } from "./botlit/utils/formatters.js";
|
|
12
11
|
import "./botlit/index.js";
|
|
13
|
-
export { t as BotlitProvider, e as BotmanorRoot,
|
|
12
|
+
export { t as BotlitProvider, e as BotmanorRoot, S as cn, C as formatDate, w as formatRelativeTime, l as useAgent, u as useAgents, i as useBot, n as useBotlit, r as useBotlitStore, a as useBots, v as useConfigureLLMProvider, d as useCreateAgent, o as useCreateBot, m as useCreateKnowledgeBase, b as useCreateMCPServer, f as useDeleteAgent, s as useDeleteBot, h as useKnowledgeBase, g as useKnowledgeBases, _ as useKnowledgeDocuments, y as useLLMProviders, x as useMCPServers, p as useUpdateAgent, c as useUpdateBot };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* useTr — translation hook with fallback semantics.
|
|
3
|
+
*
|
|
4
|
+
* Wraps `useI18n().t()` so that when a key has no translation (i.e. the
|
|
5
|
+
* provider returns the key itself), the caller's English fallback is used
|
|
6
|
+
* instead. This keeps consumer call sites consistent and avoids leaking
|
|
7
|
+
* untranslated keys into the UI.
|
|
8
|
+
*
|
|
9
|
+
* Supports optional interpolation params using `{{key}}` placeholders.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* const tr = useTr();
|
|
13
|
+
* return <h1>{tr('botlit.dashboard.title', 'Dashboard')}</h1>;
|
|
14
|
+
* return <p>{tr('botlit.delete.confirm', 'Delete {{count}} items?', { count: 5 })}</p>;
|
|
15
|
+
*/
|
|
16
|
+
export declare function useTr(): (key: string, fallback: string, params?: Record<string, string | number>) => string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useCallback as e } from "react";
|
|
2
2
|
import { useI18n as t } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
3
|
-
|
|
3
|
+
// src/shared/hooks/useTr.ts
|
|
4
4
|
function n() {
|
|
5
5
|
let { t: n } = t();
|
|
6
6
|
return e((e, t, r) => {
|
|
@@ -8,7 +8,6 @@ function n() {
|
|
|
8
8
|
return r ? Object.entries(r).reduce((e, [t, n]) => e.replace(RegExp(`\\{\\{${t}\\}\\}`, "g"), String(n)), a) : a;
|
|
9
9
|
}, [n]);
|
|
10
10
|
}
|
|
11
|
-
//#endregion
|
|
12
11
|
export { n as useTr };
|
|
13
12
|
|
|
14
13
|
//# sourceMappingURL=useTr.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useTr.js","names":[],"sources":["../../../src/shared/hooks/useTr.ts"],"sourcesContent":["import { useCallback } from 'react';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\n\n/**\n * useTr — translation hook with fallback semantics.\n *\n * Wraps `useI18n().t()` so that when a key has no translation (i.e. the\n * provider returns the key itself), the caller's English fallback is used\n * instead. This keeps consumer call sites consistent and avoids leaking\n * untranslated keys into the UI.\n *\n * Supports optional interpolation params using `{{key}}` placeholders.\n *\n * @example\n * const tr = useTr();\n * return <h1>{tr('botlit.dashboard.title', 'Dashboard')}</h1>;\n * return <p>{tr('botlit.delete.confirm', 'Delete {{count}} items?', { count: 5 })}</p>;\n */\nexport function useTr(): (\n key: string,\n fallback: string,\n params?: Record<string, string | number>\n) => string {\n const { t } = useI18n();\n return useCallback(\n (key: string, fallback: string, params?: Record<string, string | number>): string => {\n const translated = t(key);\n const raw = translated === key ? fallback : translated;\n if (!params) return raw;\n return Object.entries(params).reduce(\n (str, [k, v]) => str.replace(new RegExp(`\\\\{\\\\{${k}\\\\}\\\\}`, 'g'), String(v)),\n raw\n );\n },\n [t]\n );\n}\n"],"mappings":";;;AAkBA,
|
|
1
|
+
{"version":3,"file":"useTr.js","names":["useTr","useI18n","useCallback","translated","t","key","raw","fallback","params","k","v","str"],"sources":["../../../src/shared/hooks/useTr.ts"],"sourcesContent":["import { useCallback } from 'react';\nimport { useI18n } from '@burdenoff/fe-libs/shared/providers/shell/I18nProvider';\n\n/**\n * useTr — translation hook with fallback semantics.\n *\n * Wraps `useI18n().t()` so that when a key has no translation (i.e. the\n * provider returns the key itself), the caller's English fallback is used\n * instead. This keeps consumer call sites consistent and avoids leaking\n * untranslated keys into the UI.\n *\n * Supports optional interpolation params using `{{key}}` placeholders.\n *\n * @example\n * const tr = useTr();\n * return <h1>{tr('botlit.dashboard.title', 'Dashboard')}</h1>;\n * return <p>{tr('botlit.delete.confirm', 'Delete {{count}} items?', { count: 5 })}</p>;\n */\nexport function useTr(): (\n key: string,\n fallback: string,\n params?: Record<string, string | number>\n) => string {\n const { t } = useI18n();\n return useCallback(\n (key: string, fallback: string, params?: Record<string, string | number>): string => {\n const translated = t(key);\n const raw = translated === key ? fallback : translated;\n if (!params) return raw;\n return Object.entries(params).reduce(\n (str, [k, v]) => str.replace(new RegExp(`\\\\{\\\\{${k}\\\\}\\\\}`, 'g'), String(v)),\n raw\n );\n },\n [t]\n );\n}\n"],"mappings":";;;AAkBA,SAAgBA,IAIJ;CACV,IAAM,EAAE,SAAMC,EAAQ;CACtB,OAAOC,GACJ,GAAa,GAAkB,MAAqD;EACnF,IAAMC,IAAaC,EAAEC,CAAG,GAClBC,IAAMH,MAAeE,IAAME,IAAWJ;EAE5C,OADKK,IACE,OAAO,QAAQA,CAAM,CAAC,CAAC,QAC3B,GAAK,CAACC,GAAGC,OAAOC,EAAI,QAAY,OAAO,SAASF,EAAE,SAAS,GAAG,GAAG,OAAOC,CAAC,CAAC,GAC3EJ,CACF,IAJoBA;CAKtB,GACA,CAACF,CAAC,CACJ;AACF"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Badge } from '../botlit/components/Badge';
|
|
3
|
+
declare const meta: Meta<typeof Badge>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof meta>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const Secondary: Story;
|
|
8
|
+
export declare const Success: Story;
|
|
9
|
+
export declare const Warning: Story;
|
|
10
|
+
export declare const Destructive: Story;
|
|
11
|
+
export declare const Outline: Story;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Button } from '../botlit/components/Button';
|
|
3
|
+
declare const meta: Meta<typeof Button>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof meta>;
|
|
6
|
+
export declare const Primary: Story;
|
|
7
|
+
export declare const Secondary: Story;
|
|
8
|
+
export declare const Outline: Story;
|
|
9
|
+
export declare const Destructive: Story;
|
|
10
|
+
export declare const WithIcon: Story;
|
|
11
|
+
export declare const Loading: Story;
|
|
12
|
+
export declare const Small: Story;
|
|
13
|
+
export declare const Large: Story;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { EmptyState } from '../botlit/components/EmptyState';
|
|
3
|
+
declare const meta: Meta<typeof EmptyState>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof meta>;
|
|
6
|
+
export declare const IconOnly: Story;
|
|
7
|
+
export declare const WithAction: Story;
|
|
8
|
+
export declare const Illustrated: Story;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { StatusBadge } from '../botlit/components/Badge';
|
|
3
|
+
declare const meta: Meta<typeof StatusBadge>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof meta>;
|
|
6
|
+
export declare const Active: Story;
|
|
7
|
+
export declare const Training: Story;
|
|
8
|
+
export declare const Error: Story;
|
|
9
|
+
export declare const Paused: Story;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { A2AAgentRecord } from '../botlit/hooks/useA2A';
|
|
2
|
+
import { AgentRecord } from '../botlit/hooks/useAgents';
|
|
3
|
+
import { BotAppRecord } from '../botlit/hooks/useBots';
|
|
4
|
+
import { BucketRecord } from '../botlit/hooks/useBuckets';
|
|
5
|
+
import { ChannelConnectorRecord, ChannelRouteRecord } from '../botlit/hooks/useChannels';
|
|
6
|
+
import { ExecutionRecord, ExecutionMetricsRecord } from '../botlit/hooks/useExecutions';
|
|
7
|
+
import { KnowledgeBaseRecord, KnowledgeDocumentRecord } from '../botlit/hooks/useKnowledgeBases';
|
|
8
|
+
import { MCPResourceRecord, MCPServerRecord, MCPToolRecord } from '../botlit/hooks/useMCPServers';
|
|
9
|
+
import { PolicyRecord } from '../botlit/hooks/usePolicies';
|
|
10
|
+
import { PromptTemplateRecord } from '../botlit/hooks/usePromptTemplates';
|
|
11
|
+
import { RetrievalProfileRecord } from '../botlit/hooks/useRetrievalProfiles';
|
|
12
|
+
import { SkillRecord } from '../botlit/hooks/useSkills';
|
|
13
|
+
import { InstalledPackageRecord, StorePackageRecord } from '../botlit/hooks/useStore';
|
|
14
|
+
export declare const WORKSPACE_ID = "ws-test";
|
|
15
|
+
export declare const knowledgeBase: KnowledgeBaseRecord;
|
|
16
|
+
export declare const knowledgeDocument: KnowledgeDocumentRecord;
|
|
17
|
+
export declare const retrievalProfile: RetrievalProfileRecord;
|
|
18
|
+
export declare const mcpServer: MCPServerRecord;
|
|
19
|
+
export declare const mcpTool: MCPToolRecord;
|
|
20
|
+
export declare const mcpResource: MCPResourceRecord;
|
|
21
|
+
export declare const a2aAgent: A2AAgentRecord;
|
|
22
|
+
export declare const policy: PolicyRecord;
|
|
23
|
+
export declare const skill: SkillRecord;
|
|
24
|
+
export declare const promptTemplate: PromptTemplateRecord;
|
|
25
|
+
export declare const channelConnector: ChannelConnectorRecord;
|
|
26
|
+
export declare const channelRoute: ChannelRouteRecord;
|
|
27
|
+
export declare const execution: ExecutionRecord;
|
|
28
|
+
export declare const executionMetrics: ExecutionMetricsRecord;
|
|
29
|
+
export declare const bucket: BucketRecord;
|
|
30
|
+
export declare const storePackage: StorePackageRecord;
|
|
31
|
+
export declare const installedPackage: InstalledPackageRecord;
|
|
32
|
+
export declare const botApp: BotAppRecord;
|
|
33
|
+
export declare const agent: AgentRecord;
|
|
34
|
+
/**
|
|
35
|
+
* Payload returned for each GraphQL operation the MFE issues, keyed by
|
|
36
|
+
* operation name. Anything absent resolves to an empty payload, which every
|
|
37
|
+
* hook maps onto its declared fallback.
|
|
38
|
+
*/
|
|
39
|
+
export declare const OPERATION_PAYLOADS: Record<string, Record<string, unknown>>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { DocumentNode } from '../../node_modules/@apollo/client';
|
|
2
|
+
import { RenderResult } from '@testing-library/react';
|
|
3
|
+
import { ReactElement } from 'react';
|
|
4
|
+
/** Reads the operation name off a parsed GraphQL document. */
|
|
5
|
+
export declare function operationName(document: DocumentNode): string | undefined;
|
|
6
|
+
/** The payload the fake gateway serves for a document, or an empty one. */
|
|
7
|
+
export declare function payloadFor(document: DocumentNode): Record<string, unknown>;
|
|
8
|
+
export interface RenderPageOptions {
|
|
9
|
+
/** Route pattern the page is mounted at, e.g. `knowledge/:kbId`. */
|
|
10
|
+
path: string;
|
|
11
|
+
/** Concrete URL to render, e.g. `/knowledge/kb-1`. */
|
|
12
|
+
url: string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Renders `element` at `url`. Throws if the page throws during render, which
|
|
16
|
+
* is the assertion the whole suite exists for.
|
|
17
|
+
*/
|
|
18
|
+
export declare function renderPage(element: ReactElement, options: RenderPageOptions): RenderResult;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* bun test preload: stubs layout APIs and resets mocks after each test. Runs
|
|
3
|
+
* after src/test/happydom.ts has registered the DOM.
|
|
4
|
+
* @module test
|
|
5
|
+
*
|
|
6
|
+
* happy-dom does not implement the layout/observer APIs the fe-libs primitives
|
|
7
|
+
* touch on mount, so they are stubbed once here rather than per suite.
|
|
8
|
+
*/
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { getPlatform, isNative, isIOS, isAndroid, isWeb, nativeImpact, nativeNotify, nativeToast, nativeConfirm, nativeCopyText, nativeShare, nativeOpenUrl, useNativePlatform, useSafeArea, useNativeKeyboard, useAppState, useDeviceInfo, useHaptics, useStatusBar, } from '@burdenoff/fe-libs/shared/native';
|
|
2
|
+
export type { BurdenoffNativePlatform, BurdenoffNativeBridge, SafeAreaInsets, DeviceInfo, HapticImpactStyle, HapticNotificationType, ToastDuration, ConfirmOptions, ShareOptions, AppState, StatusBarTheme, } from '@burdenoff/fe-libs/shared/native';
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export { e as isNative, t as nativeConfirm, n as nativeCopyText, r as nativeImpact, i as nativeNotify, a as nativeOpenUrl, o as nativeToast };
|
|
1
|
+
export { isNative, nativeConfirm, nativeCopyText, nativeImpact, nativeNotify, nativeOpenUrl, nativeToast } from "@burdenoff/fe-libs/shared/native";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@burdenoff/microfe-botmanor",
|
|
3
|
-
"version": "2026.
|
|
3
|
+
"version": "2026.1109.2",
|
|
4
4
|
"description": "Burdenoff BotManor Microfrontend - AI Agent platform interface for building, deploying and managing AI agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
@@ -22,78 +22,79 @@
|
|
|
22
22
|
"types": "./dist/index.d.ts",
|
|
23
23
|
"scripts": {
|
|
24
24
|
"dev": "vite",
|
|
25
|
-
"build": "
|
|
26
|
-
"
|
|
25
|
+
"build": "boff gate -- vite build && bun scripts/verify-dts.ts",
|
|
26
|
+
"build:fast": "MFE_DTS=0 boff gate -- vite build",
|
|
27
|
+
"verify:dts": "bun scripts/verify-dts.ts",
|
|
27
28
|
"codegen": "graphql-codegen --project wspace && graphql-codegen --project global",
|
|
28
29
|
"codegen:all": "bun run schema:pull && bun run codegen",
|
|
30
|
+
"schema:pull": "graphql-codegen --project schema-wspace && graphql-codegen --project schema-global",
|
|
29
31
|
"lint": "eslint .",
|
|
30
|
-
"
|
|
31
|
-
"format": "
|
|
32
|
-
"type:check": "
|
|
33
|
-
"
|
|
34
|
-
"
|
|
32
|
+
"format": "bun fmt 'src/**/*.{ts,tsx}'",
|
|
33
|
+
"format:check": "bun fmt --check 'src/**/*.{ts,tsx}'",
|
|
34
|
+
"type:check": "boff gate -- bun check --no-pretty -b",
|
|
35
|
+
"test": "bun test --isolate",
|
|
36
|
+
"test:watch": "bun test --isolate --watch",
|
|
37
|
+
"test:coverage": "bun test --isolate --coverage",
|
|
38
|
+
"sanity": "boff sanity",
|
|
39
|
+
"sanity:force": "boff sanity --force",
|
|
40
|
+
"audit": "bun audit --audit-level=high",
|
|
35
41
|
"build-storybook": "storybook build",
|
|
36
|
-
"test:storybook": "test-storybook",
|
|
37
|
-
"switch:status": "bun scripts/deps-mode.ts status",
|
|
38
|
-
"switch:remote": "bun scripts/deps-mode.ts remote",
|
|
39
|
-
"switch:local": "bun scripts/deps-mode.ts local",
|
|
40
|
-
"switch:check": "bun scripts/deps-mode.ts check",
|
|
41
42
|
"prepare": "lefthook install || true",
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
"
|
|
43
|
+
"storybook": "storybook dev -p 6006",
|
|
44
|
+
"switch:check": "boff deps-mode check",
|
|
45
|
+
"switch:local": "boff deps-mode local",
|
|
46
|
+
"switch:remote": "boff deps-mode remote",
|
|
47
|
+
"switch:status": "boff deps-mode status",
|
|
48
|
+
"test:storybook": "test-storybook",
|
|
49
|
+
"test:dependency-security": "node scripts/test-graphql-utils-security.mjs"
|
|
45
50
|
},
|
|
46
51
|
"dependencies": {
|
|
47
|
-
"@apollo/client": "^4.
|
|
52
|
+
"@apollo/client": "^4.3.7",
|
|
48
53
|
"@burdenoff/fe-libs": "2026.1006.1",
|
|
49
|
-
"@tanstack/react-query": "^5.
|
|
54
|
+
"@tanstack/react-query": "^5.106.1",
|
|
50
55
|
"clsx": "^2.1.1",
|
|
51
|
-
"graphql": "^16.
|
|
56
|
+
"graphql": "^16.15.0",
|
|
52
57
|
"lucide-react": "^0.468.0",
|
|
53
|
-
"react": "^19.
|
|
54
|
-
"react-dom": "^19.
|
|
58
|
+
"react": "^19.3.1",
|
|
59
|
+
"react-dom": "^19.3.1",
|
|
55
60
|
"sonner": "^2.0.7",
|
|
56
|
-
"tailwind-merge": "^3.
|
|
57
|
-
"zustand": "^5.0.
|
|
61
|
+
"tailwind-merge": "^3.7.0",
|
|
62
|
+
"zustand": "^5.0.16"
|
|
58
63
|
},
|
|
59
64
|
"devDependencies": {
|
|
60
|
-
"@
|
|
61
|
-
"@graphql-codegen/add": "^
|
|
62
|
-
"@graphql-codegen/cli": "^
|
|
63
|
-
"@graphql-codegen/import-types-preset": "^
|
|
64
|
-
"@graphql-codegen/schema-ast": "^
|
|
65
|
-
"@graphql-codegen/typescript": "^
|
|
66
|
-
"@graphql-codegen/typescript-operations": "^
|
|
67
|
-
"@graphql-codegen/typescript-react-apollo": "^
|
|
68
|
-
"@
|
|
69
|
-
"@storybook/addon-
|
|
70
|
-
"@storybook/
|
|
71
|
-
"@storybook/react
|
|
72
|
-
"@storybook/
|
|
65
|
+
"@burdenoff/toolchain": "2026.1107.14",
|
|
66
|
+
"@graphql-codegen/add": "^7.1.1",
|
|
67
|
+
"@graphql-codegen/cli": "^7.4.6",
|
|
68
|
+
"@graphql-codegen/import-types-preset": "^4.0.1",
|
|
69
|
+
"@graphql-codegen/schema-ast": "^6.1.1",
|
|
70
|
+
"@graphql-codegen/typescript": "^6.1.2",
|
|
71
|
+
"@graphql-codegen/typescript-operations": "^6.2.0",
|
|
72
|
+
"@graphql-codegen/typescript-react-apollo": "^5.0.0",
|
|
73
|
+
"@happy-dom/global-registrator": "^21.0.4",
|
|
74
|
+
"@storybook/addon-essentials": "^8.6.14",
|
|
75
|
+
"@storybook/addon-interactions": "^8.6.14",
|
|
76
|
+
"@storybook/react": "^8.6.19",
|
|
77
|
+
"@storybook/react-vite": "^8.6.19",
|
|
78
|
+
"@storybook/test": "^8.6.15",
|
|
73
79
|
"@storybook/test-runner": "0.22.0",
|
|
74
|
-
"@tailwindcss/vite": "^4.3.
|
|
75
|
-
"@testing-library/react": "^16.3.
|
|
76
|
-
"@types/
|
|
77
|
-
"@types/
|
|
78
|
-
"@
|
|
79
|
-
"
|
|
80
|
+
"@tailwindcss/vite": "^4.3.4",
|
|
81
|
+
"@testing-library/react": "^16.3.3",
|
|
82
|
+
"@types/bun": "^1.4.4",
|
|
83
|
+
"@types/node": "^24.19.2",
|
|
84
|
+
"@types/react": "^19.3.0",
|
|
85
|
+
"@types/react-dom": "^19.3.0",
|
|
86
|
+
"@vitejs/plugin-react": "^6.2.1",
|
|
87
|
+
"autoprefixer": "^10.6.2",
|
|
80
88
|
"change-case-all": "1.0.15",
|
|
81
|
-
"eslint": "^9.
|
|
82
|
-
"
|
|
83
|
-
"
|
|
84
|
-
"
|
|
85
|
-
"
|
|
86
|
-
"
|
|
87
|
-
"
|
|
88
|
-
"
|
|
89
|
-
"
|
|
90
|
-
"storybook": "^8.6.0",
|
|
91
|
-
"tailwindcss": "^4.0.0",
|
|
92
|
-
"typescript": "^5.9.0",
|
|
93
|
-
"typescript-eslint": "^8.56.0",
|
|
94
|
-
"vite": "^8.3.5",
|
|
95
|
-
"vite-plugin-dts": "3.9.1",
|
|
96
|
-
"vitest": "^4.1.12"
|
|
89
|
+
"eslint": "^9.39.5",
|
|
90
|
+
"lefthook": "^2.2.2",
|
|
91
|
+
"postcss": "^8.5.32",
|
|
92
|
+
"sonner": "^2.0.8",
|
|
93
|
+
"storybook": "^8.6.19",
|
|
94
|
+
"tailwindcss": "^4.3.4",
|
|
95
|
+
"typescript": "6.0.3",
|
|
96
|
+
"unplugin-dts": "1.1.2",
|
|
97
|
+
"vite": "^8.3.6"
|
|
97
98
|
},
|
|
98
99
|
"peerDependencies": {
|
|
99
100
|
"@apollo/client": "^4.0.11",
|
|
@@ -104,7 +105,7 @@
|
|
|
104
105
|
"lucide-react": "^0.468.0",
|
|
105
106
|
"react": "^19.2.4",
|
|
106
107
|
"react-dom": "^19.2.4",
|
|
107
|
-
"react-router": "^8.
|
|
108
|
+
"react-router": "^8.5.1",
|
|
108
109
|
"sonner": "^2.0.7",
|
|
109
110
|
"tailwind-merge": "^3.4.0",
|
|
110
111
|
"zustand": "^5.0.7"
|
|
@@ -150,7 +151,33 @@
|
|
|
150
151
|
"ip-address": ">=10.3.1",
|
|
151
152
|
"tmp": ">=0.2.4",
|
|
152
153
|
"xlsx": ">=0.19.3",
|
|
153
|
-
"ajv": "
|
|
154
|
+
"ajv": "^6.15.0",
|
|
154
155
|
"playwright": ">=1.55.1"
|
|
156
|
+
},
|
|
157
|
+
"packageManager": "bun@1.4.4",
|
|
158
|
+
"engines": {
|
|
159
|
+
"bun": ">=1.4.4"
|
|
160
|
+
},
|
|
161
|
+
"boff": {
|
|
162
|
+
"type": "mfe",
|
|
163
|
+
"sanity": {
|
|
164
|
+
"formatPaths": [
|
|
165
|
+
"src/**/*.{ts,tsx}"
|
|
166
|
+
],
|
|
167
|
+
"extra": [
|
|
168
|
+
"build-storybook",
|
|
169
|
+
"test:dependency-security"
|
|
170
|
+
]
|
|
171
|
+
},
|
|
172
|
+
"scripts": {
|
|
173
|
+
"unmanaged": [
|
|
174
|
+
"test",
|
|
175
|
+
"test:watch",
|
|
176
|
+
"test:coverage"
|
|
177
|
+
]
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"patchedDependencies": {
|
|
181
|
+
"@graphql-tools/utils@11.2.2": "patches/@graphql-tools%2Futils@11.2.2.patch"
|
|
155
182
|
}
|
|
156
183
|
}
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import { useCallback as e, useState as t } from "react";
|
|
2
|
-
import { gql as n } from "@apollo/client";
|
|
3
|
-
import { useGatewayClient as r } from "@burdenoff/fe-libs/shared/graphql";
|
|
4
|
-
//#region src/botlit/hooks/useConversations.ts
|
|
5
|
-
var i = n`
|
|
6
|
-
mutation ChatWithAgent($input: ChatWithAgentInput!) {
|
|
7
|
-
chatWithAgent(input: $input) {
|
|
8
|
-
executionId
|
|
9
|
-
message
|
|
10
|
-
tokensUsed
|
|
11
|
-
model
|
|
12
|
-
conversationId
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
`;
|
|
16
|
-
function a(e) {
|
|
17
|
-
return e;
|
|
18
|
-
}
|
|
19
|
-
var o = [];
|
|
20
|
-
function s(e) {
|
|
21
|
-
return {
|
|
22
|
-
data: o,
|
|
23
|
-
loading: !1,
|
|
24
|
-
error: void 0
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
function c(e) {
|
|
28
|
-
return {
|
|
29
|
-
data: null,
|
|
30
|
-
loading: !1,
|
|
31
|
-
error: void 0
|
|
32
|
-
};
|
|
33
|
-
}
|
|
34
|
-
function l() {
|
|
35
|
-
let n = a(r("workspace")), [o, s] = t(!1), [c, l] = t(null);
|
|
36
|
-
return {
|
|
37
|
-
sendMessage: e(async (e) => {
|
|
38
|
-
s(!0), l(null);
|
|
39
|
-
try {
|
|
40
|
-
let t = (await n.mutate({
|
|
41
|
-
mutation: i,
|
|
42
|
-
variables: { input: {
|
|
43
|
-
conversationId: e.conversationId ?? null,
|
|
44
|
-
agentId: e.agentId,
|
|
45
|
-
message: e.content
|
|
46
|
-
} }
|
|
47
|
-
})).data?.chatWithAgent;
|
|
48
|
-
if (!t) throw Error("Failed to send message");
|
|
49
|
-
return t;
|
|
50
|
-
} catch (e) {
|
|
51
|
-
let t = e instanceof Error ? e : /* @__PURE__ */ Error("Failed to send message");
|
|
52
|
-
throw l(t), t;
|
|
53
|
-
} finally {
|
|
54
|
-
s(!1);
|
|
55
|
-
}
|
|
56
|
-
}, [n]),
|
|
57
|
-
isSending: o,
|
|
58
|
-
error: c
|
|
59
|
-
};
|
|
60
|
-
}
|
|
61
|
-
//#endregion
|
|
62
|
-
export { c as useConversation, s as useConversations, l as useSendMessage };
|
|
63
|
-
|
|
64
|
-
//# sourceMappingURL=useConversations.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"useConversations.js","names":[],"sources":["../../../src/botlit/hooks/useConversations.ts"],"sourcesContent":["import { gql, type ApolloClient } from '@apollo/client';\nimport { useCallback, useState } from 'react';\nimport { useGatewayClient } from '@burdenoff/fe-libs/shared/graphql';\n\nconst CHAT_WITH_AGENT_DOCUMENT = gql`\n mutation ChatWithAgent($input: ChatWithAgentInput!) {\n chatWithAgent(input: $input) {\n executionId\n message\n tokensUsed\n model\n conversationId\n }\n }\n`;\n\ntype WorkspaceClient = ApolloClient;\n\ninterface ChatResponse {\n executionId: string;\n message: string;\n tokensUsed?: number | null;\n model?: string | null;\n conversationId?: string | null;\n}\n\ninterface ChatWithAgentData {\n chatWithAgent: ChatResponse;\n}\n\nfunction getWorkspaceClient(client: unknown): WorkspaceClient {\n return client as WorkspaceClient;\n}\n\nexport const conversationKeys = {\n all: ['conversations'] as const,\n lists: () => [...conversationKeys.all, 'list'] as const,\n list: (filter?: Record<string, unknown>) => [...conversationKeys.lists(), filter] as const,\n details: () => [...conversationKeys.all, 'detail'] as const,\n detail: (id: string) => [...conversationKeys.details(), id] as const,\n};\n\n/**\n * Conversations moved to `microfe-conversations`; the BotManor routes redirect\n * there. These stubs keep the (unrouted) legacy pages compiling without\n * pretending to fetch anything.\n */\nconst NO_CONVERSATIONS: ConversationSummary[] = [];\n\nexport interface ConversationSummary {\n id: string;\n title: string;\n status: string;\n agentId?: string | null;\n messages: unknown[];\n updatedAt: string;\n}\n\nexport function useConversations(_filter?: Record<string, unknown>) {\n return { data: NO_CONVERSATIONS, loading: false, error: undefined };\n}\n\nexport function useConversation(_conversationId: string | undefined) {\n return { data: null, loading: false, error: undefined };\n}\n\nexport function useSendMessage() {\n const client = getWorkspaceClient(useGatewayClient('workspace'));\n const [isSending, setIsSending] = useState(false);\n const [error, setError] = useState<Error | null>(null);\n\n const sendMessage = useCallback(\n async (input: { conversationId?: string; agentId: string; content: string }) => {\n setIsSending(true);\n setError(null);\n try {\n const result = await client.mutate<ChatWithAgentData>({\n mutation: CHAT_WITH_AGENT_DOCUMENT,\n variables: {\n input: {\n conversationId: input.conversationId ?? null,\n agentId: input.agentId,\n message: input.content,\n },\n },\n });\n\n const response = result.data?.chatWithAgent;\n if (!response) {\n throw new Error('Failed to send message');\n }\n\n return response;\n } catch (mutationError) {\n const nextError =\n mutationError instanceof Error ? mutationError : new Error('Failed to send message');\n setError(nextError);\n throw nextError;\n } finally {\n setIsSending(false);\n }\n },\n [client]\n );\n\n return {\n sendMessage,\n isSending,\n error,\n };\n}\n"],"mappings":";;;;AAIA,IAAM,IAA2B,CAAG;;;;;;;;;;;AA0BpC,SAAS,EAAmB,GAAkC;AAC5D,QAAO;;AAgBT,IAAM,IAA0C,EAAE;AAWlD,SAAgB,EAAiB,GAAmC;AAClE,QAAO;EAAE,MAAM;EAAkB,SAAS;EAAO,OAAO,KAAA;EAAW;;AAGrE,SAAgB,EAAgB,GAAqC;AACnE,QAAO;EAAE,MAAM;EAAM,SAAS;EAAO,OAAO,KAAA;EAAW;;AAGzD,SAAgB,IAAiB;CAC/B,IAAM,IAAS,EAAmB,EAAiB,YAAY,CAAC,EAC1D,CAAC,GAAW,KAAgB,EAAS,GAAM,EAC3C,CAAC,GAAO,KAAY,EAAuB,KAAK;AAoCtD,QAAO;EACL,aAnCkB,EAClB,OAAO,MAAyE;AAE9E,GADA,EAAa,GAAK,EAClB,EAAS,KAAK;AACd,OAAI;IAYF,IAAM,KAXS,MAAM,EAAO,OAA0B;KACpD,UAAU;KACV,WAAW,EACT,OAAO;MACL,gBAAgB,EAAM,kBAAkB;MACxC,SAAS,EAAM;MACf,SAAS,EAAM;MAChB,EACF;KACF,CAAC,EAEsB,MAAM;AAC9B,QAAI,CAAC,EACH,OAAU,MAAM,yBAAyB;AAG3C,WAAO;YACA,GAAe;IACtB,IAAM,IACJ,aAAyB,QAAQ,IAAgB,gBAAI,MAAM,yBAAyB;AAEtF,UADA,EAAS,EAAU,EACb;aACE;AACR,MAAa,GAAM;;KAGvB,CAAC,EAAO,CACT;EAIC;EACA;EACD"}
|