@burdenoff/microfe-botmanor 2026.1108.1 → 2026.1109.1

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.
Files changed (334) hide show
  1. package/dist/botlit/BotlitRoutes.d.ts +2 -0
  2. package/dist/botlit/BotlitRoutes.js +24 -25
  3. package/dist/botlit/BotlitRoutes.js.map +1 -1
  4. package/dist/botlit/BotmanorRoot.d.ts +3 -0
  5. package/dist/botlit/BotmanorRoot.js +1 -2
  6. package/dist/botlit/BotmanorRoot.js.map +1 -1
  7. package/dist/botlit/BotmanorRootInner.d.ts +3 -0
  8. package/dist/botlit/BotmanorRootInner.js +9 -10
  9. package/dist/botlit/BotmanorRootInner.js.map +1 -1
  10. package/dist/botlit/components/AgentApprovalPanel.d.ts +20 -0
  11. package/dist/botlit/components/AgentApprovalPanel.js +49 -50
  12. package/dist/botlit/components/AgentApprovalPanel.js.map +1 -1
  13. package/dist/botlit/components/AiOperationsPanel.d.ts +14 -0
  14. package/dist/botlit/components/AiOperationsPanel.js +54 -55
  15. package/dist/botlit/components/AiOperationsPanel.js.map +1 -1
  16. package/dist/botlit/components/AssistantChannelPanel.d.ts +3 -0
  17. package/dist/botlit/components/AssistantChannelPanel.js +12 -13
  18. package/dist/botlit/components/AssistantChannelPanel.js.map +1 -1
  19. package/dist/botlit/components/AssistantRuntimeSetupPanel.d.ts +4 -0
  20. package/dist/botlit/components/AssistantRuntimeSetupPanel.js +14 -14
  21. package/dist/botlit/components/AssistantRuntimeSetupPanel.js.map +1 -1
  22. package/dist/botlit/components/AssistantWebsitePanel.d.ts +5 -0
  23. package/dist/botlit/components/AssistantWebsitePanel.js +15 -16
  24. package/dist/botlit/components/AssistantWebsitePanel.js.map +1 -1
  25. package/dist/botlit/components/Badge.d.ts +9 -0
  26. package/dist/botlit/components/Badge.js +1 -2
  27. package/dist/botlit/components/Badge.js.map +1 -1
  28. package/dist/botlit/components/Button.d.ts +10 -0
  29. package/dist/botlit/components/Button.js +1 -2
  30. package/dist/botlit/components/Button.js.map +1 -1
  31. package/dist/botlit/components/Card.d.ts +16 -0
  32. package/dist/botlit/components/Card.js +1 -2
  33. package/dist/botlit/components/Card.js.map +1 -1
  34. package/dist/botlit/components/ChannelSelectorSheet.d.ts +23 -0
  35. package/dist/botlit/components/ChannelSelectorSheet.js +1 -2
  36. package/dist/botlit/components/ChannelSelectorSheet.js.map +1 -1
  37. package/dist/botlit/components/EmptyState.d.ts +12 -0
  38. package/dist/botlit/components/EmptyState.js +1 -2
  39. package/dist/botlit/components/EmptyState.js.map +1 -1
  40. package/dist/botlit/components/ErrorState.d.ts +10 -0
  41. package/dist/botlit/components/ErrorState.js +5 -6
  42. package/dist/botlit/components/ErrorState.js.map +1 -1
  43. package/dist/botlit/components/Input.d.ts +27 -0
  44. package/dist/botlit/components/Input.js +1 -2
  45. package/dist/botlit/components/Input.js.map +1 -1
  46. package/dist/botlit/components/KnowledgeSourceImportPanel.d.ts +3 -0
  47. package/dist/botlit/components/KnowledgeSourceImportPanel.js +12 -13
  48. package/dist/botlit/components/KnowledgeSourceImportPanel.js.map +1 -1
  49. package/dist/botlit/components/ModelRegistrationPanel.d.ts +5 -0
  50. package/dist/botlit/components/ModelRegistrationPanel.js +1 -2
  51. package/dist/botlit/components/ModelRegistrationPanel.js.map +1 -1
  52. package/dist/botlit/components/PageLayout.d.ts +12 -0
  53. package/dist/botlit/components/PageLayout.js +1 -2
  54. package/dist/botlit/components/PageLayout.js.map +1 -1
  55. package/dist/botlit/components/QuotaExhaustedDialog.d.ts +9 -0
  56. package/dist/botlit/components/QuotaExhaustedDialog.js +1 -2
  57. package/dist/botlit/components/QuotaExhaustedDialog.js.map +1 -1
  58. package/dist/botlit/components/RetentionStatusPanel.d.ts +2 -0
  59. package/dist/botlit/components/RetentionStatusPanel.js +18 -19
  60. package/dist/botlit/components/RetentionStatusPanel.js.map +1 -1
  61. package/dist/botlit/components/RouteLoader.d.ts +23 -0
  62. package/dist/botlit/components/RouteLoader.js +1 -2
  63. package/dist/botlit/components/RouteLoader.js.map +1 -1
  64. package/dist/botlit/components/VersionHistoryPanel.d.ts +12 -0
  65. package/dist/botlit/components/VersionHistoryPanel.js +23 -24
  66. package/dist/botlit/components/VersionHistoryPanel.js.map +1 -1
  67. package/dist/botlit/components/WorkspaceRequired.d.ts +18 -0
  68. package/dist/botlit/components/WorkspaceRequired.js +1 -2
  69. package/dist/botlit/components/WorkspaceRequired.js.map +1 -1
  70. package/dist/botlit/components/index.d.ts +14 -0
  71. package/dist/botlit/hooks/index.d.ts +36 -0
  72. package/dist/botlit/hooks/index.js +15 -14
  73. package/dist/botlit/hooks/internal/mutationInput.d.ts +56 -0
  74. package/dist/botlit/hooks/internal/mutationInput.js +1 -2
  75. package/dist/botlit/hooks/internal/mutationInput.js.map +1 -1
  76. package/dist/botlit/hooks/internal/workspaceGateway.d.ts +54 -0
  77. package/dist/botlit/hooks/internal/workspaceGateway.js +17 -19
  78. package/dist/botlit/hooks/internal/workspaceGateway.js.map +1 -1
  79. package/dist/botlit/hooks/useA2A.d.ts +104 -0
  80. package/dist/botlit/hooks/useA2A.js +45 -45
  81. package/dist/botlit/hooks/useA2A.js.map +1 -1
  82. package/dist/botlit/hooks/useAgentApprovals.d.ts +62 -0
  83. package/dist/botlit/hooks/useAgentApprovals.js +38 -39
  84. package/dist/botlit/hooks/useAgentApprovals.js.map +1 -1
  85. package/dist/botlit/hooks/useAgents.d.ts +105 -0
  86. package/dist/botlit/hooks/useAgents.js +53 -54
  87. package/dist/botlit/hooks/useAgents.js.map +1 -1
  88. package/dist/botlit/hooks/useAiOperations.d.ts +95 -0
  89. package/dist/botlit/hooks/useAiOperations.js +20 -19
  90. package/dist/botlit/hooks/useAiOperations.js.map +1 -1
  91. package/dist/botlit/hooks/useAssistantChannels.d.ts +16 -0
  92. package/dist/botlit/hooks/useAssistantChannels.js +1 -2
  93. package/dist/botlit/hooks/useAssistantChannels.js.map +1 -1
  94. package/dist/botlit/hooks/useAssistantRuntimeSetup.d.ts +17 -0
  95. package/dist/botlit/hooks/useAssistantRuntimeSetup.js +1 -2
  96. package/dist/botlit/hooks/useAssistantRuntimeSetup.js.map +1 -1
  97. package/dist/botlit/hooks/useAssistantWebsites.d.ts +18 -0
  98. package/dist/botlit/hooks/useAssistantWebsites.js +1 -2
  99. package/dist/botlit/hooks/useAssistantWebsites.js.map +1 -1
  100. package/dist/botlit/hooks/useBotWorkflow.d.ts +22 -0
  101. package/dist/botlit/hooks/useBotWorkflow.js +1 -2
  102. package/dist/botlit/hooks/useBotWorkflow.js.map +1 -1
  103. package/dist/botlit/hooks/useBots.d.ts +68 -0
  104. package/dist/botlit/hooks/useBots.js +32 -33
  105. package/dist/botlit/hooks/useBots.js.map +1 -1
  106. package/dist/botlit/hooks/useBuckets.d.ts +57 -0
  107. package/dist/botlit/hooks/useBuckets.js +38 -39
  108. package/dist/botlit/hooks/useBuckets.js.map +1 -1
  109. package/dist/botlit/hooks/useChannels.d.ts +87 -0
  110. package/dist/botlit/hooks/useChannels.js +73 -73
  111. package/dist/botlit/hooks/useChannels.js.map +1 -1
  112. package/dist/botlit/hooks/useConversations.d.ts +42 -0
  113. package/dist/botlit/hooks/useConversations.js +1 -2
  114. package/dist/botlit/hooks/useConversations.js.map +1 -1
  115. package/dist/botlit/hooks/useExecutions.d.ts +87 -0
  116. package/dist/botlit/hooks/useExecutions.js +37 -37
  117. package/dist/botlit/hooks/useExecutions.js.map +1 -1
  118. package/dist/botlit/hooks/useKnowledgeBases.d.ts +79 -0
  119. package/dist/botlit/hooks/useKnowledgeBases.js +40 -39
  120. package/dist/botlit/hooks/useKnowledgeBases.js.map +1 -1
  121. package/dist/botlit/hooks/useKnowledgeSourceImports.d.ts +21 -0
  122. package/dist/botlit/hooks/useKnowledgeSourceImports.js +1 -2
  123. package/dist/botlit/hooks/useKnowledgeSourceImports.js.map +1 -1
  124. package/dist/botlit/hooks/useLLMProviders.d.ts +66 -0
  125. package/dist/botlit/hooks/useLLMProviders.js +25 -26
  126. package/dist/botlit/hooks/useLLMProviders.js.map +1 -1
  127. package/dist/botlit/hooks/useMCPServers.d.ts +71 -0
  128. package/dist/botlit/hooks/useMCPServers.js +40 -38
  129. package/dist/botlit/hooks/useMCPServers.js.map +1 -1
  130. package/dist/botlit/hooks/usePolicies.d.ts +60 -0
  131. package/dist/botlit/hooks/usePolicies.js +49 -49
  132. package/dist/botlit/hooks/usePolicies.js.map +1 -1
  133. package/dist/botlit/hooks/usePromptTemplates.d.ts +88 -0
  134. package/dist/botlit/hooks/usePromptTemplates.js +57 -57
  135. package/dist/botlit/hooks/usePromptTemplates.js.map +1 -1
  136. package/dist/botlit/hooks/useRetention.d.ts +26 -0
  137. package/dist/botlit/hooks/useRetention.js +3 -3
  138. package/dist/botlit/hooks/useRetention.js.map +1 -1
  139. package/dist/botlit/hooks/useRetrievalProfiles.d.ts +75 -0
  140. package/dist/botlit/hooks/useRetrievalProfiles.js +47 -47
  141. package/dist/botlit/hooks/useRetrievalProfiles.js.map +1 -1
  142. package/dist/botlit/hooks/useSkills.d.ts +64 -0
  143. package/dist/botlit/hooks/useSkills.js +53 -53
  144. package/dist/botlit/hooks/useSkills.js.map +1 -1
  145. package/dist/botlit/hooks/useStore.d.ts +112 -0
  146. package/dist/botlit/hooks/useStore.js +55 -55
  147. package/dist/botlit/hooks/useStore.js.map +1 -1
  148. package/dist/botlit/hooks/useUserPlatformConnection.d.ts +80 -0
  149. package/dist/botlit/hooks/useUserPlatformConnection.js +19 -19
  150. package/dist/botlit/hooks/useUserPlatformConnection.js.map +1 -1
  151. package/dist/botlit/index.d.ts +16 -0
  152. package/dist/botlit/index.js +12 -11
  153. package/dist/botlit/pages/A2AAgentDetailPage.d.ts +6 -0
  154. package/dist/botlit/pages/A2AAgentDetailPage.js +171 -178
  155. package/dist/botlit/pages/A2AAgentDetailPage.js.map +1 -1
  156. package/dist/botlit/pages/A2ARegistryPage.d.ts +2 -0
  157. package/dist/botlit/pages/A2ARegistryPage.js +25 -26
  158. package/dist/botlit/pages/A2ARegistryPage.js.map +1 -1
  159. package/dist/botlit/pages/AgentApprovalsPage.d.ts +2 -0
  160. package/dist/botlit/pages/AgentApprovalsPage.js +32 -33
  161. package/dist/botlit/pages/AgentApprovalsPage.js.map +1 -1
  162. package/dist/botlit/pages/AgentBuilderPage.d.ts +2 -0
  163. package/dist/botlit/pages/AgentBuilderPage.js +59 -60
  164. package/dist/botlit/pages/AgentBuilderPage.js.map +1 -1
  165. package/dist/botlit/pages/AgentDetailPage.d.ts +2 -0
  166. package/dist/botlit/pages/AgentDetailPage.js +83 -84
  167. package/dist/botlit/pages/AgentDetailPage.js.map +1 -1
  168. package/dist/botlit/pages/AgentsListPage.d.ts +2 -0
  169. package/dist/botlit/pages/AgentsListPage.js +71 -72
  170. package/dist/botlit/pages/AgentsListPage.js.map +1 -1
  171. package/dist/botlit/pages/AiOperationsPage.d.ts +2 -0
  172. package/dist/botlit/pages/AiOperationsPage.js +52 -53
  173. package/dist/botlit/pages/AiOperationsPage.js.map +1 -1
  174. package/dist/botlit/pages/BotChannelsTab.d.ts +7 -0
  175. package/dist/botlit/pages/BotChannelsTab.js +120 -122
  176. package/dist/botlit/pages/BotChannelsTab.js.map +1 -1
  177. package/dist/botlit/pages/BotDetailPage.d.ts +7 -0
  178. package/dist/botlit/pages/BotDetailPage.js +353 -358
  179. package/dist/botlit/pages/BotDetailPage.js.map +1 -1
  180. package/dist/botlit/pages/BotWorkflowTab.d.ts +11 -0
  181. package/dist/botlit/pages/BotWorkflowTab.js +20 -21
  182. package/dist/botlit/pages/BotWorkflowTab.js.map +1 -1
  183. package/dist/botlit/pages/BotsListPage.d.ts +2 -0
  184. package/dist/botlit/pages/BotsListPage.js +52 -53
  185. package/dist/botlit/pages/BotsListPage.js.map +1 -1
  186. package/dist/botlit/pages/BucketsPage.d.ts +2 -0
  187. package/dist/botlit/pages/BucketsPage.js +260 -261
  188. package/dist/botlit/pages/BucketsPage.js.map +1 -1
  189. package/dist/botlit/pages/ChannelDetailPage.d.ts +6 -0
  190. package/dist/botlit/pages/ChannelDetailPage.js +97 -96
  191. package/dist/botlit/pages/ChannelDetailPage.js.map +1 -1
  192. package/dist/botlit/pages/ChannelRoutesPage.d.ts +2 -0
  193. package/dist/botlit/pages/ChannelRoutesPage.js +23 -24
  194. package/dist/botlit/pages/ChannelRoutesPage.js.map +1 -1
  195. package/dist/botlit/pages/ChannelsPage.d.ts +2 -0
  196. package/dist/botlit/pages/ChannelsPage.js +44 -45
  197. package/dist/botlit/pages/ChannelsPage.js.map +1 -1
  198. package/dist/botlit/pages/ChatPage.d.ts +1 -0
  199. package/dist/botlit/pages/ChatPage.js +10 -11
  200. package/dist/botlit/pages/ChatPage.js.map +1 -1
  201. package/dist/botlit/pages/ConversationDetailPage.d.ts +2 -0
  202. package/dist/botlit/pages/ConversationsPage.d.ts +2 -0
  203. package/dist/botlit/pages/DashboardPage.d.ts +2 -0
  204. package/dist/botlit/pages/DashboardPage.js +37 -38
  205. package/dist/botlit/pages/DashboardPage.js.map +1 -1
  206. package/dist/botlit/pages/ExecutionDetailPage.d.ts +2 -0
  207. package/dist/botlit/pages/ExecutionDetailPage.js +47 -48
  208. package/dist/botlit/pages/ExecutionDetailPage.js.map +1 -1
  209. package/dist/botlit/pages/ExecutionsPage.d.ts +2 -0
  210. package/dist/botlit/pages/ExecutionsPage.js +72 -70
  211. package/dist/botlit/pages/ExecutionsPage.js.map +1 -1
  212. package/dist/botlit/pages/InstalledPackagesPage.d.ts +2 -0
  213. package/dist/botlit/pages/InstalledPackagesPage.js +77 -78
  214. package/dist/botlit/pages/InstalledPackagesPage.js.map +1 -1
  215. package/dist/botlit/pages/KnowledgeBaseDetailPage.d.ts +6 -0
  216. package/dist/botlit/pages/KnowledgeBaseDetailPage.js +171 -181
  217. package/dist/botlit/pages/KnowledgeBaseDetailPage.js.map +1 -1
  218. package/dist/botlit/pages/KnowledgeBasesPage.d.ts +2 -0
  219. package/dist/botlit/pages/KnowledgeBasesPage.js +30 -31
  220. package/dist/botlit/pages/KnowledgeBasesPage.js.map +1 -1
  221. package/dist/botlit/pages/MCPServerDetailPage.d.ts +6 -0
  222. package/dist/botlit/pages/MCPServerDetailPage.js +82 -83
  223. package/dist/botlit/pages/MCPServerDetailPage.js.map +1 -1
  224. package/dist/botlit/pages/MCPServersPage.d.ts +2 -0
  225. package/dist/botlit/pages/MCPServersPage.js +54 -55
  226. package/dist/botlit/pages/MCPServersPage.js.map +1 -1
  227. package/dist/botlit/pages/PoliciesPage.d.ts +2 -0
  228. package/dist/botlit/pages/PoliciesPage.js +25 -26
  229. package/dist/botlit/pages/PoliciesPage.js.map +1 -1
  230. package/dist/botlit/pages/PolicyDetailPage.d.ts +6 -0
  231. package/dist/botlit/pages/PolicyDetailPage.js +257 -259
  232. package/dist/botlit/pages/PolicyDetailPage.js.map +1 -1
  233. package/dist/botlit/pages/PromptStudioPage.d.ts +2 -0
  234. package/dist/botlit/pages/PromptStudioPage.js +35 -35
  235. package/dist/botlit/pages/PromptStudioPage.js.map +1 -1
  236. package/dist/botlit/pages/PromptTemplateDetailPage.d.ts +6 -0
  237. package/dist/botlit/pages/PromptTemplateDetailPage.js +363 -362
  238. package/dist/botlit/pages/PromptTemplateDetailPage.js.map +1 -1
  239. package/dist/botlit/pages/PromptTemplatesPage.d.ts +2 -0
  240. package/dist/botlit/pages/PromptTemplatesPage.js +26 -27
  241. package/dist/botlit/pages/PromptTemplatesPage.js.map +1 -1
  242. package/dist/botlit/pages/RetrievalProfileDetailPage.d.ts +6 -0
  243. package/dist/botlit/pages/RetrievalProfileDetailPage.js +150 -158
  244. package/dist/botlit/pages/RetrievalProfileDetailPage.js.map +1 -1
  245. package/dist/botlit/pages/RetrievalProfilesPage.d.ts +2 -0
  246. package/dist/botlit/pages/RetrievalProfilesPage.js +24 -25
  247. package/dist/botlit/pages/RetrievalProfilesPage.js.map +1 -1
  248. package/dist/botlit/pages/SettingsPage.d.ts +2 -0
  249. package/dist/botlit/pages/SettingsPage.js +124 -125
  250. package/dist/botlit/pages/SettingsPage.js.map +1 -1
  251. package/dist/botlit/pages/SkillDetailPage.d.ts +6 -0
  252. package/dist/botlit/pages/SkillDetailPage.js +216 -217
  253. package/dist/botlit/pages/SkillDetailPage.js.map +1 -1
  254. package/dist/botlit/pages/SkillsPage.d.ts +2 -0
  255. package/dist/botlit/pages/SkillsPage.js +24 -25
  256. package/dist/botlit/pages/SkillsPage.js.map +1 -1
  257. package/dist/botlit/pages/StorePackageDetailPage.d.ts +2 -0
  258. package/dist/botlit/pages/StorePackageDetailPage.js +38 -39
  259. package/dist/botlit/pages/StorePackageDetailPage.js.map +1 -1
  260. package/dist/botlit/pages/StorePage.d.ts +2 -0
  261. package/dist/botlit/pages/StorePage.js +135 -136
  262. package/dist/botlit/pages/StorePage.js.map +1 -1
  263. package/dist/botlit/pages/index.d.ts +39 -0
  264. package/dist/botlit/permissions/PermissionRequired.d.ts +20 -0
  265. package/dist/botlit/permissions/PermissionRequired.js +10 -11
  266. package/dist/botlit/permissions/PermissionRequired.js.map +1 -1
  267. package/dist/botlit/permissions/botmanorPermissions.d.ts +82 -0
  268. package/dist/botlit/permissions/botmanorPermissions.js +1 -2
  269. package/dist/botlit/permissions/botmanorPermissions.js.map +1 -1
  270. package/dist/botlit/permissions/index.d.ts +7 -0
  271. package/dist/botlit/permissions/index.js +4 -3
  272. package/dist/botlit/permissions/useBotmanorPermissions.d.ts +41 -0
  273. package/dist/botlit/permissions/useBotmanorPermissions.js +1 -2
  274. package/dist/botlit/permissions/useBotmanorPermissions.js.map +1 -1
  275. package/dist/botlit/providers/BotlitProvider.d.ts +14 -0
  276. package/dist/botlit/providers/BotlitProvider.js +3 -3
  277. package/dist/botlit/providers/BotlitProvider.js.map +1 -1
  278. package/dist/botlit/store/botlitStore.d.ts +85 -0
  279. package/dist/botlit/store/botlitStore.js +1 -2
  280. package/dist/botlit/store/botlitStore.js.map +1 -1
  281. package/dist/botlit/store/renamedKeyStorage.d.ts +13 -0
  282. package/dist/botlit/store/renamedKeyStorage.js +1 -2
  283. package/dist/botlit/store/renamedKeyStorage.js.map +1 -1
  284. package/dist/botlit/types/index.d.ts +1008 -0
  285. package/dist/botlit/utils/cn.d.ts +2 -0
  286. package/dist/botlit/utils/cn.js +1 -2
  287. package/dist/botlit/utils/cn.js.map +1 -1
  288. package/dist/botlit/utils/embedding-models.d.ts +9 -0
  289. package/dist/botlit/utils/embedding-models.js +1 -2
  290. package/dist/botlit/utils/embedding-models.js.map +1 -1
  291. package/dist/botlit/utils/errors.d.ts +19 -0
  292. package/dist/botlit/utils/errors.js +1 -2
  293. package/dist/botlit/utils/errors.js.map +1 -1
  294. package/dist/botlit/utils/formatters.d.ts +38 -0
  295. package/dist/botlit/utils/formatters.js +0 -1
  296. package/dist/botlit/utils/formatters.js.map +1 -1
  297. package/dist/botlit/utils/navigation.d.ts +19 -0
  298. package/dist/botlit/utils/navigation.js +1 -2
  299. package/dist/botlit/utils/navigation.js.map +1 -1
  300. package/dist/botlit/utils/policyConfig.d.ts +68 -0
  301. package/dist/botlit/utils/policyConfig.js +2 -3
  302. package/dist/botlit/utils/policyConfig.js.map +1 -1
  303. package/dist/botlit/utils/unions.d.ts +25 -0
  304. package/dist/botlit/utils/unions.js +1 -2
  305. package/dist/botlit/utils/unions.js.map +1 -1
  306. package/dist/dev/App.d.ts +2 -0
  307. package/dist/dev/main.d.ts +0 -0
  308. package/dist/generated/global-operations.d.ts +197 -0
  309. package/dist/generated/global-operations.js +1 -2
  310. package/dist/generated/global-operations.js.map +1 -1
  311. package/dist/generated/global-types.d.ts +27678 -0
  312. package/dist/generated/global-types.js +1 -2
  313. package/dist/generated/global-types.js.map +1 -1
  314. package/dist/generated/wspace-operations.d.ts +5489 -0
  315. package/dist/generated/wspace-operations.js +64 -60
  316. package/dist/generated/wspace-operations.js.map +1 -1
  317. package/dist/generated/wspace-types.d.ts +152017 -0
  318. package/dist/generated/wspace-types.js +1 -2
  319. package/dist/generated/wspace-types.js.map +1 -1
  320. package/dist/index.d.ts +5 -0
  321. package/dist/shared/hooks/useTr.d.ts +16 -0
  322. package/dist/shared/hooks/useTr.js +1 -2
  323. package/dist/shared/hooks/useTr.js.map +1 -1
  324. package/dist/stories/Badge.stories.d.ts +11 -0
  325. package/dist/stories/Button.stories.d.ts +13 -0
  326. package/dist/stories/EmptyState.stories.d.ts +8 -0
  327. package/dist/stories/StatusBadge.stories.d.ts +9 -0
  328. package/dist/test/fixtures.d.ts +39 -0
  329. package/dist/test/happydom.d.ts +1 -0
  330. package/dist/test/renderPage.d.ts +18 -0
  331. package/dist/test/setup.d.ts +9 -0
  332. package/dist/utils/nativeBridge.d.ts +2 -0
  333. package/dist/utils/nativeBridge.js +1 -2
  334. package/package.json +87 -60
@@ -1,28 +1,28 @@
1
- import { useBotlit as e } from "../providers/BotlitProvider.js";
2
- import { BOTMANOR_PERMISSIONS as t } from "../permissions/botmanorPermissions.js";
3
- import { BotmanorPermissionGate as n } from "../permissions/useBotmanorPermissions.js";
4
- import { Button as r } from "../components/Button.js";
5
- import "../permissions/index.js";
6
- import { Card as i, CardContent as a, CardHeader as o, CardTitle as s } from "../components/Card.js";
7
- import { Badge as c } from "../components/Badge.js";
8
- import { isNative as l, nativeCopyText as u, nativeNotify as d, nativeOpenUrl as f, nativeToast as p } from "../../utils/nativeBridge.js";
9
- import { EmptyState as m } from "../components/EmptyState.js";
10
- import { Input as h } from "../components/Input.js";
11
- import { useBotChannelRoutes as g, useChannelConnector as _, useCreateChannelRoute as v, useDeleteChannelRoute as y } from "../hooks/useChannels.js";
12
- import { useGlobalChannels as b, useLinkIntegrationConnection as x, useMyUserPlatformConnection as S, useRevokeSlackConnection as C, useToggleSlackNotifications as w } from "../hooks/useUserPlatformConnection.js";
1
+ import { Card as e, CardContent as t, CardHeader as n, CardTitle as r } from "../components/Card.js";
2
+ import { BOTMANOR_PERMISSIONS as i } from "../permissions/botmanorPermissions.js";
3
+ import { BotmanorPermissionGate as a } from "../permissions/useBotmanorPermissions.js";
4
+ import { Button as o } from "../components/Button.js";
5
+ import { Badge as s } from "../components/Badge.js";
6
+ import { EmptyState as c } from "../components/EmptyState.js";
7
+ import { Input as l } from "../components/Input.js";
8
+ import { ChannelSelectorSheet as u } from "../components/ChannelSelectorSheet.js";
9
+ import { useBotlit as d } from "../providers/BotlitProvider.js";
10
+ import { isNative as f, nativeCopyText as p, nativeNotify as m, nativeOpenUrl as h, nativeToast as g } from "../../utils/nativeBridge.js";
11
+ import { useBotChannelRoutes as _, useChannelConnector as v, useCreateChannelRoute as y, useDeleteChannelRoute as b } from "../hooks/useChannels.js";
13
12
  import "../hooks/index.js";
14
- import { ChannelSelectorSheet as T } from "../components/ChannelSelectorSheet.js";
13
+ import { useGlobalChannels as x, useLinkIntegrationConnection as S, useMyUserPlatformConnection as C, useRevokeSlackConnection as w, useToggleSlackNotifications as T } from "../hooks/useUserPlatformConnection.js";
14
+ import "../permissions/index.js";
15
15
  import { useCallback as E, useState as D } from "react";
16
16
  import { Fragment as O, jsx as k, jsxs as A } from "react/jsx-runtime";
17
17
  import { Bell as j, BellOff as M, CheckCircle2 as N, Loader2 as P, Mail as F, MessageCircle as I, MessageSquare as L, Plus as R, Radio as z, Slack as B, Trash2 as V, Unlink as H, Users as U } from "lucide-react";
18
18
  import { toast as W } from "sonner";
19
- //#region src/botlit/pages/BotChannelsTab.tsx
19
+ // src/botlit/pages/BotChannelsTab.tsx
20
20
  var G = {
21
21
  SLACK: "slack-user",
22
22
  TEAMS: "teams-user",
23
23
  DISCORD: "discord-user",
24
24
  WHATSAPP: "whatsapp-user"
25
- }, K = new Set([
25
+ }, K = /* @__PURE__ */ new Set([
26
26
  "SLACK",
27
27
  "TEAMS",
28
28
  "DISCORD"
@@ -106,25 +106,25 @@ function J(e) {
106
106
  };
107
107
  }
108
108
  }
109
- var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s, onReconnect: f }) => {
110
- let { data: m, loading: g } = _(i), v = m?.credentialsRefId ?? a, { data: b, loading: T, refetch: E } = S(v), { toggle: O, loading: F } = w(), { revoke: I, loading: L } = C(), { link: R } = x(), [z] = y(), [B, U] = D(""), [G, K] = D(!1), q = J(o);
111
- return g ? /* @__PURE__ */ k("div", { className: "h-32 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" }) : /* @__PURE__ */ A("div", {
109
+ var Y = ({ routeId: e, connectorId: t, channelId: n, platform: r, onRemoved: c, onReconnect: u }) => {
110
+ let { data: d, loading: h } = v(t), _ = d?.credentialsRefId ?? n, { data: y, loading: x, refetch: E } = C(_), { toggle: O, loading: F } = T(), { revoke: I, loading: L } = w(), { link: R } = S(), [z] = b(), [B, U] = D(""), [G, K] = D(!1), q = J(r);
111
+ return h ? /* @__PURE__ */ k("div", { className: "h-32 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" }) : /* @__PURE__ */ A("div", {
112
112
  className: "rounded-lg border border-border-subtle bg-bg-sunken/30 p-4 space-y-3",
113
113
  children: [/* @__PURE__ */ A("div", {
114
114
  className: "flex items-center justify-between",
115
115
  children: [/* @__PURE__ */ k("span", {
116
116
  className: "text-xs text-text-secondary font-medium uppercase tracking-wide",
117
117
  children: "Connected workspace"
118
- }), /* @__PURE__ */ k(n, {
119
- permission: t.CHANNEL_DELETE,
120
- children: /* @__PURE__ */ k(r, {
118
+ }), /* @__PURE__ */ k(a, {
119
+ permission: i.CHANNEL_DELETE,
120
+ children: /* @__PURE__ */ k(o, {
121
121
  variant: "ghost",
122
122
  size: "icon",
123
123
  onClick: async () => {
124
124
  if (confirm(`Remove this ${q.label} channel from the bot?`)) try {
125
- await z(e), s(), W.success(`${q.label} channel removed`), l() && d("success");
125
+ await z(e), c(), W.success(`${q.label} channel removed`), f() && m("success");
126
126
  } catch (e) {
127
- W.error(e instanceof Error ? e.message : "Failed to remove"), l() && d("error");
127
+ W.error(e instanceof Error ? e.message : "Failed to remove"), f() && m("error");
128
128
  }
129
129
  },
130
130
  className: "h-7 w-7 text-text-secondary hover:text-status-error-text",
@@ -132,7 +132,7 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
132
132
  children: /* @__PURE__ */ k(V, { size: 13 })
133
133
  })
134
134
  })]
135
- }), T ? /* @__PURE__ */ A("div", {
135
+ }), x ? /* @__PURE__ */ A("div", {
136
136
  className: "flex items-center gap-2 py-2 text-text-secondary",
137
137
  children: [/* @__PURE__ */ k(P, {
138
138
  size: 14,
@@ -145,7 +145,7 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
145
145
  " connection…"
146
146
  ]
147
147
  })]
148
- }) : b?.dmAllowed ? /* @__PURE__ */ A("div", {
148
+ }) : y?.dmAllowed ? /* @__PURE__ */ A("div", {
149
149
  className: "space-y-2",
150
150
  children: [
151
151
  /* @__PURE__ */ A("div", {
@@ -160,36 +160,36 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
160
160
  children: [
161
161
  /* @__PURE__ */ k("p", {
162
162
  className: "font-medium text-sm",
163
- children: b.externalDisplayName || b.externalUsername || b.externalUserId
163
+ children: y.externalDisplayName || y.externalUsername || y.externalUserId
164
164
  }),
165
- b.externalUsername && /* @__PURE__ */ A("p", {
165
+ y.externalUsername && /* @__PURE__ */ A("p", {
166
166
  className: "text-xs text-text-secondary",
167
- children: ["@", b.externalUsername]
167
+ children: ["@", y.externalUsername]
168
168
  }),
169
- b.connectedAt && /* @__PURE__ */ A("p", {
169
+ y.connectedAt && /* @__PURE__ */ A("p", {
170
170
  className: "text-xs text-text-secondary",
171
- children: ["Connected ", new Date(b.connectedAt).toLocaleDateString()]
171
+ children: ["Connected ", new Date(y.connectedAt).toLocaleDateString()]
172
172
  })
173
173
  ]
174
174
  }),
175
- b.isTokenExpired && /* @__PURE__ */ k(c, {
175
+ y.isTokenExpired && /* @__PURE__ */ k(s, {
176
176
  variant: "outline",
177
177
  className: "text-xs text-amber-600 border-amber-400",
178
178
  children: "Token expired"
179
179
  })
180
180
  ]
181
181
  }),
182
- b.integrationConnectionId && /* @__PURE__ */ A("div", {
182
+ y.integrationConnectionId && /* @__PURE__ */ A("div", {
183
183
  className: "space-y-1.5",
184
184
  children: [/* @__PURE__ */ k("label", {
185
185
  className: "text-xs font-medium text-text-secondary",
186
186
  children: "Integration Connection ID"
187
- }), /* @__PURE__ */ k(h, {
188
- value: b.integrationConnectionId,
187
+ }), /* @__PURE__ */ k(l, {
188
+ value: y.integrationConnectionId,
189
189
  readOnly: !0,
190
190
  className: "text-xs font-mono bg-bg-sunken/50 cursor-default",
191
191
  onClick: (e) => {
192
- e.currentTarget.select(), u(b.integrationConnectionId), W.success("Connection ID copied to clipboard"), l() && p("Copied");
192
+ e.currentTarget.select(), p(y.integrationConnectionId), W.success("Connection ID copied to clipboard"), f() && g("Copied");
193
193
  },
194
194
  title: "Click to copy"
195
195
  })]
@@ -198,7 +198,7 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
198
198
  className: "flex items-center justify-between p-3 border border-border-subtle rounded-lg bg-bg-surface",
199
199
  children: [/* @__PURE__ */ A("div", {
200
200
  className: "flex items-center gap-2",
201
- children: [b.notificationsEnabled ? /* @__PURE__ */ k(j, {
201
+ children: [y.notificationsEnabled ? /* @__PURE__ */ k(j, {
202
202
  size: 14,
203
203
  className: "text-primary"
204
204
  }) : /* @__PURE__ */ k(M, {
@@ -209,33 +209,33 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
209
209
  children: "DM Notifications"
210
210
  }), /* @__PURE__ */ k("p", {
211
211
  className: "text-xs text-text-secondary",
212
- children: b.notificationsEnabled ? `Bot will DM you on ${q.label}` : "DM notifications paused"
212
+ children: y.notificationsEnabled ? `Bot will DM you on ${q.label}` : "DM notifications paused"
213
213
  })] })]
214
- }), /* @__PURE__ */ k(r, {
214
+ }), /* @__PURE__ */ k(o, {
215
215
  variant: "outline",
216
216
  size: "sm",
217
217
  isLoading: F,
218
218
  onClick: async () => {
219
- await O(b.id, !b.notificationsEnabled) && await E();
219
+ await O(y.id, !y.notificationsEnabled) && await E();
220
220
  },
221
- children: b.notificationsEnabled ? "Disable" : "Enable"
221
+ children: y.notificationsEnabled ? "Disable" : "Enable"
222
222
  })]
223
223
  }),
224
224
  /* @__PURE__ */ A("div", {
225
225
  className: "flex gap-2 justify-end pt-1",
226
- children: [b.isTokenExpired && /* @__PURE__ */ k(r, {
226
+ children: [y.isTokenExpired && /* @__PURE__ */ k(o, {
227
227
  variant: "outline",
228
228
  size: "sm",
229
229
  leftIcon: q.icon,
230
- onClick: f,
230
+ onClick: u,
231
231
  children: "Reconnect"
232
- }), /* @__PURE__ */ k(r, {
232
+ }), /* @__PURE__ */ k(o, {
233
233
  variant: "destructive",
234
234
  size: "sm",
235
235
  leftIcon: /* @__PURE__ */ k(H, { size: 13 }),
236
236
  isLoading: L,
237
237
  onClick: async () => {
238
- await I(b.id) && await E();
238
+ await I(y.id) && await E();
239
239
  },
240
240
  children: "Disconnect"
241
241
  })]
@@ -286,36 +286,35 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
286
286
  ]
287
287
  })]
288
288
  }),
289
- /* @__PURE__ */ k(r, {
289
+ /* @__PURE__ */ k(o, {
290
290
  variant: "outline",
291
291
  size: "sm",
292
292
  leftIcon: q.icon,
293
- onClick: f,
293
+ onClick: u,
294
294
  className: "w-full",
295
295
  children: "Open Integrations →"
296
296
  }),
297
297
  /* @__PURE__ */ A("div", {
298
298
  className: "flex gap-2",
299
- children: [/* @__PURE__ */ k(h, {
299
+ children: [/* @__PURE__ */ k(l, {
300
300
  placeholder: "Paste integration connection ID...",
301
301
  value: B,
302
302
  onChange: (e) => U(e.target.value),
303
303
  className: "flex-1 text-sm"
304
- }), /* @__PURE__ */ k(r, {
304
+ }), /* @__PURE__ */ k(o, {
305
305
  size: "sm",
306
306
  onClick: async () => {
307
- if (!B.trim()) {
308
- W.error("Please enter an integration connection ID");
309
- return;
310
- }
311
- K(!0);
312
- try {
313
- let e = await R(B.trim(), v);
314
- e ? (W.success(`${e.externalDisplayName ?? e.externalUsername ?? "Account"} connected! The bot can now send you direct messages.`), await E(), U("")) : W.error("Failed to link connection. Please verify the ID and try again.");
315
- } catch (e) {
316
- W.error(e instanceof Error ? e.message : "Failed to link connection");
317
- } finally {
318
- K(!1);
307
+ if (!B.trim()) W.error("Please enter an integration connection ID");
308
+ else {
309
+ K(!0);
310
+ try {
311
+ let e = await R(B.trim(), _);
312
+ e ? (W.success(`${e.externalDisplayName ?? e.externalUsername ?? "Account"} connected! The bot can now send you direct messages.`), await E(), U("")) : W.error("Failed to link connection. Please verify the ID and try again.");
313
+ } catch (e) {
314
+ W.error(e instanceof Error ? e.message : "Failed to link connection");
315
+ } finally {
316
+ K(!1);
317
+ }
319
318
  }
320
319
  },
321
320
  isLoading: G,
@@ -326,8 +325,8 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
326
325
  ]
327
326
  })]
328
327
  });
329
- }, X = ({ channel: u, routes: d, botId: p, botName: m, onRoutesChanged: h }) => {
330
- let { basePath: g } = e(), [_] = v(), [y, b] = D(!1), x = u.platform, S = J(x), C = q(u.adapterType), w = y, T = E((e) => {
328
+ }, X = ({ channel: c, routes: l, botId: u, botName: p, onRoutesChanged: m }) => {
329
+ let { basePath: g } = d(), [_] = y(), [v, b] = D(!1), x = c.platform, S = J(x), C = q(c.adapterType), w = v, T = E((e) => {
331
330
  let t = G[x];
332
331
  if (!t) return;
333
332
  let n = window.location.origin + window.location.pathname + window.location.search, r = `${g ? g.replace(/\/(botmanor|botlit)(\/.*)?$/, "/integrations") : "/integrations"}/connections/add?${new URLSearchParams({
@@ -335,34 +334,34 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
335
334
  returnTo: n,
336
335
  channelId: e
337
336
  }).toString()}`;
338
- l() && /^https?:\/\//.test(r) ? f(r) : window.open(r, "_blank");
337
+ f() && /^https?:\/\//.test(r) ? h(r) : window.open(r, "_blank");
339
338
  }, [x, g]), O = E(async () => {
340
339
  b(!0);
341
340
  try {
342
341
  await _({
343
- connectorId: u.id,
344
- appId: p,
342
+ connectorId: c.id,
343
+ appId: u,
345
344
  locationId: "*",
346
345
  metadata: {
347
346
  locationName: "All channels & DMs",
348
- appName: m
347
+ appName: p
349
348
  }
350
- }), await h(), T(u.id);
349
+ }), await m(), T(c.id);
351
350
  } catch (e) {
352
351
  W.error(e instanceof Error ? e.message : `Failed to connect ${S.label}`), b(!1);
353
352
  }
354
353
  }, [
354
+ u,
355
355
  p,
356
- m,
357
- u.id,
356
+ c.id,
358
357
  _,
359
358
  S.label,
360
359
  T,
361
- h
360
+ m
362
361
  ]), j = E(() => {
363
- T(u.id);
364
- }, [u.id, T]);
365
- return /* @__PURE__ */ A(i, { children: [/* @__PURE__ */ A(o, {
362
+ T(c.id);
363
+ }, [c.id, T]);
364
+ return /* @__PURE__ */ A(e, { children: [/* @__PURE__ */ A(n, {
366
365
  className: "flex flex-row items-center justify-between pb-3",
367
366
  children: [/* @__PURE__ */ A("div", {
368
367
  className: "flex items-center gap-2.5",
@@ -372,9 +371,9 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
372
371
  className: S.accentText,
373
372
  children: S.icon
374
373
  })
375
- }), /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k(s, {
374
+ }), /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k(r, {
376
375
  className: "text-base",
377
- children: u.name
376
+ children: c.name
378
377
  }), C && /* @__PURE__ */ k("p", {
379
378
  className: "text-xs text-text-secondary mt-0.5",
380
379
  children: C
@@ -384,20 +383,20 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
384
383
  children: [/* @__PURE__ */ k("span", {
385
384
  className: `px-2 py-0.5 text-xs font-semibold rounded-full ${S.badgeClass}`,
386
385
  children: S.label
387
- }), d.length > 0 && /* @__PURE__ */ k(c, {
386
+ }), l.length > 0 && /* @__PURE__ */ k(s, {
388
387
  variant: "outline",
389
388
  className: "text-xs text-green-600 border-green-400 bg-green-50",
390
389
  children: "Active"
391
390
  })]
392
391
  })]
393
- }), /* @__PURE__ */ k(a, { children: d.length > 0 ? /* @__PURE__ */ k("div", {
392
+ }), /* @__PURE__ */ k(t, { children: l.length > 0 ? /* @__PURE__ */ k("div", {
394
393
  className: "space-y-3",
395
- children: d.map((e) => /* @__PURE__ */ k(Y, {
394
+ children: l.map((e) => /* @__PURE__ */ k(Y, {
396
395
  routeId: e.id,
397
396
  connectorId: e.connectorId,
398
- channelId: u.id,
397
+ channelId: c.id,
399
398
  platform: x,
400
- onRemoved: h,
399
+ onRemoved: m,
401
400
  onReconnect: j
402
401
  }, e.id))
403
402
  }) : /* @__PURE__ */ A("div", {
@@ -421,9 +420,9 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
421
420
  " for this bot. Users will connect their personal accounts separately."
422
421
  ]
423
422
  })] }),
424
- /* @__PURE__ */ k(n, {
425
- permission: t.CHANNEL_CREATE,
426
- children: /* @__PURE__ */ A(r, {
423
+ /* @__PURE__ */ k(a, {
424
+ permission: i.CHANNEL_CREATE,
425
+ children: /* @__PURE__ */ A(o, {
427
426
  leftIcon: S.icon,
428
427
  onClick: O,
429
428
  isLoading: w,
@@ -437,7 +436,7 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
437
436
  ]
438
437
  }) })] });
439
438
  }, Z = ({ route: e, oauthChannels: t, botId: n, botName: r, onRoutesChanged: i }) => {
440
- let { data: a } = _(e.connectorId), o = t.find((e) => e.id === a?.credentialsRefId);
439
+ let { data: a } = v(e.connectorId), o = t.find((e) => e.id === a?.credentialsRefId);
441
440
  return !a || !o || !K.has(o.platform) ? null : /* @__PURE__ */ k(X, {
442
441
  channel: o,
443
442
  routes: [e],
@@ -445,22 +444,22 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
445
444
  botName: r,
446
445
  onRoutesChanged: i
447
446
  });
448
- }, Q = ({ botId: e, botName: o }) => {
449
- let { data: s, loading: c, error: l } = b(), { data: u, loading: d, refetch: f } = g(e), [p, h] = D(!1), [_, v] = D(null), y = E(async () => {
450
- await f();
451
- }, [f]), x = s.filter((e) => K.has(e.platform)), S = new Set(u.map((e) => x.find((e) => u.some((e) => e.connectorId))?.platform).filter(Boolean)), C = x.filter((e) => !S.has(e.platform)), w = {
447
+ }, Q = ({ botId: n, botName: r }) => {
448
+ let { data: s, loading: l, error: d } = x(), { data: f, loading: p, refetch: m } = _(n), [h, g] = D(!1), [v, y] = D(null), b = E(async () => {
449
+ await m();
450
+ }, [m]), S = s.filter((e) => K.has(e.platform)), C = new Set(f.map((e) => S.find((e) => f.some((e) => e.connectorId))?.platform).filter(Boolean)), w = S.filter((e) => !C.has(e.platform)), T = {
452
451
  SLACK: /* @__PURE__ */ k(B, { size: 18 }),
453
452
  TEAMS: /* @__PURE__ */ k(U, { size: 18 }),
454
453
  DISCORD: /* @__PURE__ */ k(I, { size: 18 })
455
454
  }, j = {};
456
- x.forEach((e) => {
455
+ S.forEach((e) => {
457
456
  let t = e.platform;
458
457
  j[t] = J(t);
459
458
  });
460
459
  let M = E((e, t) => {
461
- v(e);
460
+ y(e);
462
461
  }, []);
463
- if (c || d) return /* @__PURE__ */ A("div", {
462
+ if (l || p) return /* @__PURE__ */ A("div", {
464
463
  className: "space-y-4",
465
464
  children: [
466
465
  /* @__PURE__ */ k("div", { className: "h-10 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg w-52" }),
@@ -468,7 +467,7 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
468
467
  /* @__PURE__ */ k("div", { className: "h-48 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
469
468
  ]
470
469
  });
471
- let N = u.length > 0;
470
+ let N = f.length > 0;
472
471
  return /* @__PURE__ */ A("div", {
473
472
  className: "space-y-4",
474
473
  children: [
@@ -479,64 +478,63 @@ var Y = ({ routeId: e, connectorId: i, channelId: a, platform: o, onRemoved: s,
479
478
  className: "text-sm text-text-secondary mt-0.5",
480
479
  children: "Communication platforms available for this bot"
481
480
  })] }),
482
- l && /* @__PURE__ */ k("div", {
481
+ d && /* @__PURE__ */ k("div", {
483
482
  className: "flex items-start gap-2 rounded-lg border border-status-error-border/40 bg-status-error-bg/10 px-3 py-2 text-sm text-status-error-text",
484
- children: /* @__PURE__ */ A("span", { children: ["Failed to load channels: ", l.message] })
483
+ children: /* @__PURE__ */ A("span", { children: ["Failed to load channels: ", d.message] })
485
484
  }),
486
- !l && x.length === 0 && /* @__PURE__ */ k(i, { children: /* @__PURE__ */ k(a, {
485
+ !d && S.length === 0 && /* @__PURE__ */ k(e, { children: /* @__PURE__ */ k(t, {
487
486
  className: "py-12",
488
- children: /* @__PURE__ */ k(m, {
487
+ children: /* @__PURE__ */ k(c, {
489
488
  illustration: "empty-notifications",
490
489
  title: "No channels available",
491
490
  description: "No active communication channels have been configured yet. Contact your administrator to set up channels."
492
491
  })
493
492
  }) }),
494
- !l && x.length > 0 && !N && !_ && /* @__PURE__ */ k(i, { children: /* @__PURE__ */ k(a, {
493
+ !d && S.length > 0 && !N && !v && /* @__PURE__ */ k(e, { children: /* @__PURE__ */ k(t, {
495
494
  className: "py-12",
496
- children: /* @__PURE__ */ k(m, {
495
+ children: /* @__PURE__ */ k(c, {
497
496
  illustration: "empty-notifications",
498
497
  title: "No channels connected",
499
498
  description: "Connect a communication channel to enable bot conversations on platforms like Slack, Teams, or Discord.",
500
- action: /* @__PURE__ */ k(n, {
501
- permission: t.CHANNEL_CREATE,
502
- children: /* @__PURE__ */ k(r, {
499
+ action: /* @__PURE__ */ k(a, {
500
+ permission: i.CHANNEL_CREATE,
501
+ children: /* @__PURE__ */ k(o, {
503
502
  leftIcon: /* @__PURE__ */ k(R, { size: 16 }),
504
- onClick: () => h(!0),
503
+ onClick: () => g(!0),
505
504
  children: "Connect Channel"
506
505
  })
507
506
  })
508
507
  })
509
508
  }) }),
510
- x.length > 0 && (N || _) && /* @__PURE__ */ A("div", {
509
+ S.length > 0 && (N || v) && /* @__PURE__ */ A("div", {
511
510
  className: "space-y-4",
512
- children: [u.map((t) => /* @__PURE__ */ k(Z, {
513
- route: t,
514
- oauthChannels: x,
515
- botId: e,
516
- botName: o,
517
- onRoutesChanged: y
518
- }, t.id)), _ && /* @__PURE__ */ k(O, { children: x.filter((e) => e.id === _).map((t) => /* @__PURE__ */ k(X, {
519
- channel: t,
520
- routes: u.filter((e) => !1),
521
- botId: e,
522
- botName: o,
511
+ children: [f.map((e) => /* @__PURE__ */ k(Z, {
512
+ route: e,
513
+ oauthChannels: S,
514
+ botId: n,
515
+ botName: r,
516
+ onRoutesChanged: b
517
+ }, e.id)), v && /* @__PURE__ */ k(O, { children: S.filter((e) => e.id === v).map((e) => /* @__PURE__ */ k(X, {
518
+ channel: e,
519
+ routes: f.filter((e) => !1),
520
+ botId: n,
521
+ botName: r,
523
522
  onRoutesChanged: async () => {
524
- await y(), v(null);
523
+ await b(), y(null);
525
524
  }
526
- }, t.id)) })]
525
+ }, e.id)) })]
527
526
  }),
528
- /* @__PURE__ */ k(T, {
529
- open: p,
530
- onClose: () => h(!1),
527
+ /* @__PURE__ */ k(u, {
528
+ open: h,
529
+ onClose: () => g(!1),
531
530
  onSelectChannel: M,
532
- availableChannels: C,
533
- platformIcons: w,
531
+ availableChannels: w,
532
+ platformIcons: T,
534
533
  platformMeta: j
535
534
  })
536
535
  ]
537
536
  });
538
537
  };
539
- //#endregion
540
538
  export { Q as BotChannelsTab };
541
539
 
542
540
  //# sourceMappingURL=BotChannelsTab.js.map