@burdenoff/microfe-subscriberbot 2026.1107.8 → 2026.1110.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/generated/global-operations.d.ts +4 -2
- package/dist/generated/global-types.d.ts +2 -22
- package/dist/generated/wspace-operations.d.ts +4 -2
- package/dist/generated/wspace-types.d.ts +4 -24
- package/dist/index.d.ts +0 -1
- package/dist/node_modules/clsx/dist/clsx.js +8 -7
- package/dist/node_modules/clsx/dist/clsx.js.map +1 -1
- package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js +134 -151
- package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js.map +1 -1
- package/dist/stories/Accessibility.stories.d.ts +2 -4
- package/dist/stories/EmptyState.stories.d.ts +0 -2
- package/dist/stories/MetricsCard.stories.d.ts +0 -2
- package/dist/stories/StatusBadge.stories.d.ts +0 -2
- package/dist/stories/pages/AgentDetailPage.stories.d.ts +0 -2
- package/dist/stories/pages/AgentNewPage.stories.d.ts +0 -2
- package/dist/stories/pages/AgentsListPage.stories.d.ts +0 -2
- package/dist/stories/pages/AssetVaultPage.stories.d.ts +0 -2
- package/dist/stories/pages/BankConnectionsPage.stories.d.ts +0 -2
- package/dist/stories/pages/DashboardPage.stories.d.ts +0 -2
- package/dist/stories/pages/DecisionDetailPage.stories.d.ts +0 -2
- package/dist/stories/pages/DecisionsPage.stories.d.ts +0 -2
- package/dist/stories/pages/EnterpriseSpendPage.stories.d.ts +0 -2
- package/dist/stories/pages/InboxPage.stories.d.ts +0 -2
- package/dist/stories/pages/InboxReadState.stories.d.ts +1 -3
- package/dist/stories/pages/InsightsPage.stories.d.ts +0 -2
- package/dist/stories/pages/InvoicesPage.stories.d.ts +0 -2
- package/dist/stories/pages/NegotiationDetailPage.stories.d.ts +0 -2
- package/dist/stories/pages/NegotiationNewPage.stories.d.ts +0 -2
- package/dist/stories/pages/NegotiationsPage.stories.d.ts +0 -2
- package/dist/stories/pages/ProcurementDetailPage.stories.d.ts +0 -2
- package/dist/stories/pages/ProcurementNewPage.stories.d.ts +0 -2
- package/dist/stories/pages/ProcurementPage.stories.d.ts +0 -2
- package/dist/stories/pages/ProviderDetailPage.stories.d.ts +0 -2
- package/dist/stories/pages/ProviderNewPage.stories.d.ts +0 -2
- package/dist/stories/pages/ProvidersListPage.stories.d.ts +0 -2
- package/dist/stories/pages/RelationshipDetailPage.stories.d.ts +0 -2
- package/dist/stories/pages/RelationshipNewPage.stories.d.ts +0 -2
- package/dist/stories/pages/RelationshipsListPage.stories.d.ts +0 -2
- package/dist/stories/pages/RenewalsPage.stories.d.ts +0 -2
- package/dist/stories/pages/SavingsPage.stories.d.ts +0 -2
- package/dist/stories/pages/WorkflowBuilderPage.stories.d.ts +0 -2
- package/dist/stories/pages/WorkflowsPage.stories.d.ts +0 -2
- package/dist/stories/support/PageHarness.d.ts +0 -2
- package/dist/stories/support/bankingFixtures.d.ts +0 -2
- package/dist/stories/support/fixtures.d.ts +0 -2
- package/dist/stories/support/graphqlMock.d.ts +0 -2
- package/dist/stories/support/handlers.d.ts +0 -2
- package/dist/stories/support/negotiationFixtures.d.ts +0 -2
- package/dist/stories/support/phoneViewport.d.ts +0 -2
- package/dist/stories/support/play.d.ts +0 -2
- package/dist/stories/support/procurementFixtures.d.ts +0 -2
- package/dist/subscriberbot/SubscriberBotRoot.d.ts +0 -2
- package/dist/subscriberbot/SubscriberBotRoot.js +10 -7
- package/dist/subscriberbot/SubscriberBotRoot.js.map +1 -1
- package/dist/subscriberbot/SubscriberBotRoutes.d.ts +0 -2
- package/dist/subscriberbot/SubscriberBotRoutes.js +1 -2
- package/dist/subscriberbot/SubscriberBotRoutes.js.map +1 -1
- package/dist/subscriberbot/admin/AdminDashboardPage.d.ts +0 -2
- package/dist/subscriberbot/admin/AdminDashboardPage.js +9 -10
- package/dist/subscriberbot/admin/AdminDashboardPage.js.map +1 -1
- package/dist/subscriberbot/admin/AdminRoot.d.ts +0 -2
- package/dist/subscriberbot/admin/AdminRoot.js +2 -3
- package/dist/subscriberbot/admin/AdminRoot.js.map +1 -1
- package/dist/subscriberbot/admin/NegotiationDeskPanel.d.ts +0 -2
- package/dist/subscriberbot/admin/NegotiationDeskPanel.js +56 -57
- package/dist/subscriberbot/admin/NegotiationDeskPanel.js.map +1 -1
- package/dist/subscriberbot/admin/ProcurementDeskPanel.d.ts +0 -2
- package/dist/subscriberbot/admin/ProcurementDeskPanel.js +107 -108
- package/dist/subscriberbot/admin/ProcurementDeskPanel.js.map +1 -1
- package/dist/subscriberbot/admin/index.d.ts +0 -1
- package/dist/subscriberbot/admin/index.js +1 -1
- package/dist/subscriberbot/components/EmptyState.d.ts +0 -2
- package/dist/subscriberbot/components/EmptyState.js +1 -2
- package/dist/subscriberbot/components/EmptyState.js.map +1 -1
- package/dist/subscriberbot/components/MetricsCard.d.ts +0 -2
- package/dist/subscriberbot/components/MetricsCard.js +1 -2
- package/dist/subscriberbot/components/MetricsCard.js.map +1 -1
- package/dist/subscriberbot/components/Modal.d.ts +0 -2
- package/dist/subscriberbot/components/Modal.js +2 -3
- package/dist/subscriberbot/components/Modal.js.map +1 -1
- package/dist/subscriberbot/components/PageLayout.d.ts +0 -2
- package/dist/subscriberbot/components/PageLayout.js +1 -2
- package/dist/subscriberbot/components/PageLayout.js.map +1 -1
- package/dist/subscriberbot/components/PostureOptions.d.ts +1 -3
- package/dist/subscriberbot/components/PostureOptions.js +7 -8
- package/dist/subscriberbot/components/PostureOptions.js.map +1 -1
- package/dist/subscriberbot/components/StateViews.d.ts +0 -2
- package/dist/subscriberbot/components/StateViews.js +1 -2
- package/dist/subscriberbot/components/StateViews.js.map +1 -1
- package/dist/subscriberbot/components/StatusBadge.d.ts +0 -2
- package/dist/subscriberbot/components/StatusBadge.js +2 -3
- package/dist/subscriberbot/components/StatusBadge.js.map +1 -1
- package/dist/subscriberbot/components/decisions/DecisionBanners.d.ts +0 -2
- package/dist/subscriberbot/components/decisions/DecisionBanners.js +7 -8
- package/dist/subscriberbot/components/decisions/DecisionBanners.js.map +1 -1
- package/dist/subscriberbot/components/decisions/DecisionCard.d.ts +0 -2
- package/dist/subscriberbot/components/decisions/DecisionCard.js +65 -66
- package/dist/subscriberbot/components/decisions/DecisionCard.js.map +1 -1
- package/dist/subscriberbot/components/decisions/decisionModel.d.ts +0 -2
- package/dist/subscriberbot/components/decisions/decisionModel.js +2 -3
- package/dist/subscriberbot/components/decisions/decisionModel.js.map +1 -1
- package/dist/subscriberbot/components/decisions/index.d.ts +0 -1
- package/dist/subscriberbot/components/decisions/index.js +4 -3
- package/dist/subscriberbot/components/index.d.ts +0 -1
- package/dist/subscriberbot/components/index.js +8 -7
- package/dist/subscriberbot/components/mobile/MobileDashboard.d.ts +0 -2
- package/dist/subscriberbot/components/mobile/MobileDashboard.js +23 -24
- package/dist/subscriberbot/components/mobile/MobileDashboard.js.map +1 -1
- package/dist/subscriberbot/components/mobile/MobileRelationshipList.d.ts +0 -2
- package/dist/subscriberbot/components/mobile/MobileRelationshipList.js +40 -49
- package/dist/subscriberbot/components/mobile/MobileRelationshipList.js.map +1 -1
- package/dist/subscriberbot/components/mobile/MobileScreen.d.ts +0 -2
- package/dist/subscriberbot/components/mobile/MobileScreen.js +1 -2
- package/dist/subscriberbot/components/mobile/MobileScreen.js.map +1 -1
- package/dist/subscriberbot/components/mobile/RelationshipGlyph.d.ts +0 -2
- package/dist/subscriberbot/components/mobile/RelationshipGlyph.js +1 -2
- package/dist/subscriberbot/components/mobile/RelationshipGlyph.js.map +1 -1
- package/dist/subscriberbot/components/mobile/index.d.ts +0 -1
- package/dist/subscriberbot/components/mobile/index.js +4 -3
- package/dist/subscriberbot/components/negotiations/NegotiationStatusPill.d.ts +0 -2
- package/dist/subscriberbot/components/negotiations/NegotiationStatusPill.js +1 -2
- package/dist/subscriberbot/components/negotiations/NegotiationStatusPill.js.map +1 -1
- package/dist/subscriberbot/components/negotiations/NegotiationTimeline.d.ts +0 -2
- package/dist/subscriberbot/components/negotiations/NegotiationTimeline.js +4 -5
- package/dist/subscriberbot/components/negotiations/NegotiationTimeline.js.map +1 -1
- package/dist/subscriberbot/components/negotiations/OutcomeForm.d.ts +0 -2
- package/dist/subscriberbot/components/negotiations/OutcomeForm.js +4 -5
- package/dist/subscriberbot/components/negotiations/OutcomeForm.js.map +1 -1
- package/dist/subscriberbot/components/negotiations/index.d.ts +0 -1
- package/dist/subscriberbot/components/negotiations/index.js +5 -4
- package/dist/subscriberbot/components/negotiations/labels.d.ts +0 -2
- package/dist/subscriberbot/components/negotiations/labels.js +1 -2
- package/dist/subscriberbot/components/negotiations/labels.js.map +1 -1
- package/dist/subscriberbot/components/procurement/ProcurementOutcomeForm.d.ts +0 -2
- package/dist/subscriberbot/components/procurement/ProcurementOutcomeForm.js +4 -5
- package/dist/subscriberbot/components/procurement/ProcurementOutcomeForm.js.map +1 -1
- package/dist/subscriberbot/components/procurement/ProcurementStatusPill.d.ts +0 -2
- package/dist/subscriberbot/components/procurement/ProcurementStatusPill.js +1 -2
- package/dist/subscriberbot/components/procurement/ProcurementStatusPill.js.map +1 -1
- package/dist/subscriberbot/components/procurement/ProcurementThread.d.ts +0 -2
- package/dist/subscriberbot/components/procurement/ProcurementThread.js +4 -5
- package/dist/subscriberbot/components/procurement/ProcurementThread.js.map +1 -1
- package/dist/subscriberbot/components/procurement/index.d.ts +0 -1
- package/dist/subscriberbot/components/procurement/index.js +5 -4
- package/dist/subscriberbot/components/procurement/labels.d.ts +0 -2
- package/dist/subscriberbot/components/procurement/labels.js +1 -2
- package/dist/subscriberbot/components/procurement/labels.js.map +1 -1
- package/dist/subscriberbot/components/savings/SavingsCards.d.ts +0 -2
- package/dist/subscriberbot/components/savings/SavingsCards.js +90 -91
- package/dist/subscriberbot/components/savings/SavingsCards.js.map +1 -1
- package/dist/subscriberbot/components/savings/index.d.ts +0 -1
- package/dist/subscriberbot/components/savings/index.js +3 -2
- package/dist/subscriberbot/components/savings/savingsModel.d.ts +0 -2
- package/dist/subscriberbot/components/savings/savingsModel.js +2 -3
- package/dist/subscriberbot/components/savings/savingsModel.js.map +1 -1
- package/dist/subscriberbot/components/viz.d.ts +0 -2
- package/dist/subscriberbot/components/viz.js +2 -3
- package/dist/subscriberbot/components/viz.js.map +1 -1
- package/dist/subscriberbot/config/assistantUsecases.d.ts +0 -1
- package/dist/subscriberbot/context/SubscriberBotContext.d.ts +0 -2
- package/dist/subscriberbot/context/SubscriberBotContext.js +3 -3
- package/dist/subscriberbot/context/SubscriberBotContext.js.map +1 -1
- package/dist/subscriberbot/context/index.d.ts +0 -1
- package/dist/subscriberbot/context/index.js +1 -1
- package/dist/subscriberbot/hooks/index.d.ts +0 -1
- package/dist/subscriberbot/hooks/index.js +2 -2
- package/dist/subscriberbot/hooks/useAutonomousAgentMode.d.ts +0 -2
- package/dist/subscriberbot/hooks/useAutonomousAgentMode.js +2 -3
- package/dist/subscriberbot/hooks/useAutonomousAgentMode.js.map +1 -1
- package/dist/subscriberbot/hooks/useBankingApi.d.ts +0 -2
- package/dist/subscriberbot/hooks/useBankingApi.js +2 -3
- package/dist/subscriberbot/hooks/useBankingApi.js.map +1 -1
- package/dist/subscriberbot/hooks/useCompactViewport.d.ts +0 -1
- package/dist/subscriberbot/hooks/useCompactViewport.js +1 -2
- package/dist/subscriberbot/hooks/useCompactViewport.js.map +1 -1
- package/dist/subscriberbot/hooks/useFormError.d.ts +0 -1
- package/dist/subscriberbot/hooks/useFormError.js +1 -2
- package/dist/subscriberbot/hooks/useFormError.js.map +1 -1
- package/dist/subscriberbot/hooks/useFormatters.d.ts +0 -1
- package/dist/subscriberbot/hooks/useFormatters.js +1 -2
- package/dist/subscriberbot/hooks/useFormatters.js.map +1 -1
- package/dist/subscriberbot/hooks/useNegotiationApi.d.ts +0 -2
- package/dist/subscriberbot/hooks/useNegotiationApi.js +2 -3
- package/dist/subscriberbot/hooks/useNegotiationApi.js.map +1 -1
- package/dist/subscriberbot/hooks/useProcurementApi.d.ts +0 -2
- package/dist/subscriberbot/hooks/useProcurementApi.js +2 -3
- package/dist/subscriberbot/hooks/useProcurementApi.js.map +1 -1
- package/dist/subscriberbot/hooks/useRouteSelection.d.ts +0 -1
- package/dist/subscriberbot/hooks/useRouteSelection.js +3 -3
- package/dist/subscriberbot/hooks/useRouteSelection.js.map +1 -1
- package/dist/subscriberbot/hooks/useSubscriberBotApi.d.ts +0 -2
- package/dist/subscriberbot/hooks/useSubscriberBotApi.js +1 -2
- package/dist/subscriberbot/hooks/useSubscriberBotApi.js.map +1 -1
- package/dist/subscriberbot/hooks/useTr.d.ts +0 -1
- package/dist/subscriberbot/hooks/useTr.js +1 -2
- package/dist/subscriberbot/hooks/useTr.js.map +1 -1
- package/dist/subscriberbot/index.d.ts +0 -1
- package/dist/subscriberbot/index.js +9 -8
- package/dist/subscriberbot/pages/AssetVaultPage.d.ts +0 -2
- package/dist/subscriberbot/pages/AssetVaultPage.js +34 -35
- package/dist/subscriberbot/pages/AssetVaultPage.js.map +1 -1
- package/dist/subscriberbot/pages/DashboardPage.d.ts +1 -2
- package/dist/subscriberbot/pages/DashboardPage.js +86 -87
- package/dist/subscriberbot/pages/DashboardPage.js.map +1 -1
- package/dist/subscriberbot/pages/InboxPage.d.ts +1 -2
- package/dist/subscriberbot/pages/InboxPage.js +194 -199
- package/dist/subscriberbot/pages/InboxPage.js.map +1 -1
- package/dist/subscriberbot/pages/InsightsPage.d.ts +0 -2
- package/dist/subscriberbot/pages/InsightsPage.js +28 -29
- package/dist/subscriberbot/pages/InsightsPage.js.map +1 -1
- package/dist/subscriberbot/pages/InvoicesPage.d.ts +1 -2
- package/dist/subscriberbot/pages/InvoicesPage.js +179 -188
- package/dist/subscriberbot/pages/InvoicesPage.js.map +1 -1
- package/dist/subscriberbot/pages/RenewalsPage.d.ts +0 -2
- package/dist/subscriberbot/pages/RenewalsPage.js +293 -298
- package/dist/subscriberbot/pages/RenewalsPage.js.map +1 -1
- package/dist/subscriberbot/pages/SavingsPage.d.ts +0 -2
- package/dist/subscriberbot/pages/SavingsPage.js +25 -26
- package/dist/subscriberbot/pages/SavingsPage.js.map +1 -1
- package/dist/subscriberbot/pages/WorkflowsPage.d.ts +1 -2
- package/dist/subscriberbot/pages/WorkflowsPage.js +67 -68
- package/dist/subscriberbot/pages/WorkflowsPage.js.map +1 -1
- package/dist/subscriberbot/pages/agents/AgentDetailPage.d.ts +1 -2
- package/dist/subscriberbot/pages/agents/AgentDetailPage.js +126 -127
- package/dist/subscriberbot/pages/agents/AgentDetailPage.js.map +1 -1
- package/dist/subscriberbot/pages/agents/AgentNewPage.d.ts +1 -2
- package/dist/subscriberbot/pages/agents/AgentNewPage.js +10 -11
- package/dist/subscriberbot/pages/agents/AgentNewPage.js.map +1 -1
- package/dist/subscriberbot/pages/agents/AgentsListPage.d.ts +1 -2
- package/dist/subscriberbot/pages/agents/AgentsListPage.js +23 -24
- package/dist/subscriberbot/pages/agents/AgentsListPage.js.map +1 -1
- package/dist/subscriberbot/pages/banking/BankConnectionsPage.d.ts +1 -2
- package/dist/subscriberbot/pages/banking/BankConnectionsPage.js +337 -359
- package/dist/subscriberbot/pages/banking/BankConnectionsPage.js.map +1 -1
- package/dist/subscriberbot/pages/banking/ConnectBankModal.d.ts +1 -3
- package/dist/subscriberbot/pages/banking/ConnectBankModal.js +22 -27
- package/dist/subscriberbot/pages/banking/ConnectBankModal.js.map +1 -1
- package/dist/subscriberbot/pages/decisions/DecisionDetailPage.d.ts +1 -2
- package/dist/subscriberbot/pages/decisions/DecisionDetailPage.js +25 -26
- package/dist/subscriberbot/pages/decisions/DecisionDetailPage.js.map +1 -1
- package/dist/subscriberbot/pages/decisions/DecisionsPage.d.ts +1 -2
- package/dist/subscriberbot/pages/decisions/DecisionsPage.js +34 -35
- package/dist/subscriberbot/pages/decisions/DecisionsPage.js.map +1 -1
- package/dist/subscriberbot/pages/enterprise/EnterpriseSpendPage.d.ts +1 -2
- package/dist/subscriberbot/pages/enterprise/EnterpriseSpendPage.js +125 -130
- package/dist/subscriberbot/pages/enterprise/EnterpriseSpendPage.js.map +1 -1
- package/dist/subscriberbot/pages/negotiations/NegotiationDetailPage.d.ts +1 -2
- package/dist/subscriberbot/pages/negotiations/NegotiationDetailPage.js +94 -95
- package/dist/subscriberbot/pages/negotiations/NegotiationDetailPage.js.map +1 -1
- package/dist/subscriberbot/pages/negotiations/NegotiationNewPage.d.ts +1 -2
- package/dist/subscriberbot/pages/negotiations/NegotiationNewPage.js +15 -16
- package/dist/subscriberbot/pages/negotiations/NegotiationNewPage.js.map +1 -1
- package/dist/subscriberbot/pages/negotiations/NegotiationsPage.d.ts +1 -2
- package/dist/subscriberbot/pages/negotiations/NegotiationsPage.js +20 -21
- package/dist/subscriberbot/pages/negotiations/NegotiationsPage.js.map +1 -1
- package/dist/subscriberbot/pages/procurement/ProcurementDetailPage.d.ts +1 -2
- package/dist/subscriberbot/pages/procurement/ProcurementDetailPage.js +86 -87
- package/dist/subscriberbot/pages/procurement/ProcurementDetailPage.js.map +1 -1
- package/dist/subscriberbot/pages/procurement/ProcurementNewPage.d.ts +1 -2
- package/dist/subscriberbot/pages/procurement/ProcurementNewPage.js +164 -165
- package/dist/subscriberbot/pages/procurement/ProcurementNewPage.js.map +1 -1
- package/dist/subscriberbot/pages/procurement/ProcurementPage.d.ts +1 -2
- package/dist/subscriberbot/pages/procurement/ProcurementPage.js +20 -21
- package/dist/subscriberbot/pages/procurement/ProcurementPage.js.map +1 -1
- package/dist/subscriberbot/pages/providers/ProviderDetailPage.d.ts +1 -2
- package/dist/subscriberbot/pages/providers/ProviderDetailPage.js +350 -351
- package/dist/subscriberbot/pages/providers/ProviderDetailPage.js.map +1 -1
- package/dist/subscriberbot/pages/providers/ProviderInsights.d.ts +2 -3
- package/dist/subscriberbot/pages/providers/ProviderInsights.js +95 -96
- package/dist/subscriberbot/pages/providers/ProviderInsights.js.map +1 -1
- package/dist/subscriberbot/pages/providers/ProviderNewPage.d.ts +1 -2
- package/dist/subscriberbot/pages/providers/ProviderNewPage.js +11 -12
- package/dist/subscriberbot/pages/providers/ProviderNewPage.js.map +1 -1
- package/dist/subscriberbot/pages/providers/ProvidersListPage.d.ts +1 -2
- package/dist/subscriberbot/pages/providers/ProvidersListPage.js +62 -63
- package/dist/subscriberbot/pages/providers/ProvidersListPage.js.map +1 -1
- package/dist/subscriberbot/pages/relationships/RelationshipDetailPage.d.ts +1 -2
- package/dist/subscriberbot/pages/relationships/RelationshipDetailPage.js +166 -172
- package/dist/subscriberbot/pages/relationships/RelationshipDetailPage.js.map +1 -1
- package/dist/subscriberbot/pages/relationships/RelationshipNewPage.d.ts +1 -2
- package/dist/subscriberbot/pages/relationships/RelationshipNewPage.js +12 -13
- package/dist/subscriberbot/pages/relationships/RelationshipNewPage.js.map +1 -1
- package/dist/subscriberbot/pages/relationships/RelationshipsListPage.d.ts +1 -2
- package/dist/subscriberbot/pages/relationships/RelationshipsListPage.js +21 -22
- package/dist/subscriberbot/pages/relationships/RelationshipsListPage.js.map +1 -1
- package/dist/subscriberbot/pages/workflows/WorkflowBuilderPage.d.ts +1 -3
- package/dist/subscriberbot/pages/workflows/WorkflowBuilderPage.js +242 -255
- package/dist/subscriberbot/pages/workflows/WorkflowBuilderPage.js.map +1 -1
- package/dist/subscriberbot/pages/workflows/workflowBuilderGraph.d.ts +0 -2
- package/dist/subscriberbot/pages/workflows/workflowBuilderGraph.js +2 -3
- package/dist/subscriberbot/pages/workflows/workflowBuilderGraph.js.map +1 -1
- package/dist/subscriberbot/services/createSandboxAssistantTransport.d.ts +0 -1
- package/dist/subscriberbot/services/createSandboxAssistantTransport.js +1 -2
- package/dist/subscriberbot/services/createSandboxAssistantTransport.js.map +1 -1
- package/dist/subscriberbot/store/index.d.ts +0 -1
- package/dist/subscriberbot/store/index.js +1 -1
- package/dist/subscriberbot/store/subscriberbotStore.d.ts +1 -3
- package/dist/subscriberbot/store/subscriberbotStore.js +1 -2
- package/dist/subscriberbot/store/subscriberbotStore.js.map +1 -1
- package/dist/subscriberbot/types/assistant.d.ts +0 -2
- package/dist/subscriberbot/types/banking.d.ts +0 -2
- package/dist/subscriberbot/types/index.d.ts +0 -2
- package/dist/subscriberbot/types/negotiation.d.ts +0 -2
- package/dist/subscriberbot/types/procurement.d.ts +0 -1
- package/dist/subscriberbot/utils/bankRedirectLink.d.ts +0 -2
- package/dist/subscriberbot/utils/bankRedirectLink.js +18 -19
- package/dist/subscriberbot/utils/bankRedirectLink.js.map +1 -1
- package/dist/subscriberbot/utils/chartScale.d.ts +0 -1
- package/dist/subscriberbot/utils/chartScale.js +1 -2
- package/dist/subscriberbot/utils/chartScale.js.map +1 -1
- package/dist/subscriberbot/utils/cn.d.ts +0 -2
- package/dist/subscriberbot/utils/cn.js +2 -3
- package/dist/subscriberbot/utils/cn.js.map +1 -1
- package/dist/subscriberbot/utils/formatters.d.ts +0 -1
- package/dist/subscriberbot/utils/formatters.js +4 -5
- package/dist/subscriberbot/utils/formatters.js.map +1 -1
- package/dist/subscriberbot/utils/index.d.ts +0 -1
- package/dist/subscriberbot/utils/navigation.d.ts +0 -1
- package/dist/subscriberbot/utils/navigation.js +1 -2
- package/dist/subscriberbot/utils/navigation.js.map +1 -1
- package/dist/subscriberbot/utils/pageContext.d.ts +0 -1
- package/dist/subscriberbot/utils/pageContext.js +3 -4
- package/dist/subscriberbot/utils/pageContext.js.map +1 -1
- package/dist/subscriberbot/utils/plaidLink.d.ts +0 -1
- package/dist/subscriberbot/utils/plaidLink.js +21 -22
- package/dist/subscriberbot/utils/plaidLink.js.map +1 -1
- package/dist/subscriberbot/utils/portfolio.d.ts +0 -2
- package/dist/subscriberbot/utils/portfolio.js +5 -6
- package/dist/subscriberbot/utils/portfolio.js.map +1 -1
- package/dist/subscriberbot/utils/renewals.d.ts +0 -2
- package/dist/subscriberbot/utils/renewals.js +1 -2
- package/dist/subscriberbot/utils/renewals.js.map +1 -1
- package/package.json +73 -56
- package/dist/generated/global-operations.d.ts.map +0 -1
- package/dist/generated/global-types.d.ts.map +0 -1
- package/dist/generated/wspace-operations.d.ts.map +0 -1
- package/dist/generated/wspace-types.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/stories/Accessibility.stories.d.ts.map +0 -1
- package/dist/stories/EmptyState.stories.d.ts.map +0 -1
- package/dist/stories/MetricsCard.stories.d.ts.map +0 -1
- package/dist/stories/StatusBadge.stories.d.ts.map +0 -1
- package/dist/stories/pages/AgentDetailPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/AgentNewPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/AgentsListPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/AssetVaultPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/BankConnectionsPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/DashboardPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/DecisionDetailPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/DecisionsPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/EnterpriseSpendPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/InboxPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/InboxReadState.stories.d.ts.map +0 -1
- package/dist/stories/pages/InsightsPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/InvoicesPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/NegotiationDetailPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/NegotiationNewPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/NegotiationsPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/ProcurementDetailPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/ProcurementNewPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/ProcurementPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/ProviderDetailPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/ProviderNewPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/ProvidersListPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/RelationshipDetailPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/RelationshipNewPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/RelationshipsListPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/RenewalsPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/SavingsPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/WorkflowBuilderPage.stories.d.ts.map +0 -1
- package/dist/stories/pages/WorkflowsPage.stories.d.ts.map +0 -1
- package/dist/stories/support/PageHarness.d.ts.map +0 -1
- package/dist/stories/support/bankingFixtures.d.ts.map +0 -1
- package/dist/stories/support/fixtures.d.ts.map +0 -1
- package/dist/stories/support/graphqlMock.d.ts.map +0 -1
- package/dist/stories/support/handlers.d.ts.map +0 -1
- package/dist/stories/support/negotiationFixtures.d.ts.map +0 -1
- package/dist/stories/support/phoneViewport.d.ts.map +0 -1
- package/dist/stories/support/play.d.ts.map +0 -1
- package/dist/stories/support/procurementFixtures.d.ts.map +0 -1
- package/dist/subscriberbot/SubscriberBotRoot.d.ts.map +0 -1
- package/dist/subscriberbot/SubscriberBotRoutes.d.ts.map +0 -1
- package/dist/subscriberbot/admin/AdminDashboardPage.d.ts.map +0 -1
- package/dist/subscriberbot/admin/AdminRoot.d.ts.map +0 -1
- package/dist/subscriberbot/admin/NegotiationDeskPanel.d.ts.map +0 -1
- package/dist/subscriberbot/admin/ProcurementDeskPanel.d.ts.map +0 -1
- package/dist/subscriberbot/admin/index.d.ts.map +0 -1
- package/dist/subscriberbot/components/EmptyState.d.ts.map +0 -1
- package/dist/subscriberbot/components/MetricsCard.d.ts.map +0 -1
- package/dist/subscriberbot/components/Modal.d.ts.map +0 -1
- package/dist/subscriberbot/components/PageLayout.d.ts.map +0 -1
- package/dist/subscriberbot/components/PostureOptions.d.ts.map +0 -1
- package/dist/subscriberbot/components/StateViews.d.ts.map +0 -1
- package/dist/subscriberbot/components/StatusBadge.d.ts.map +0 -1
- package/dist/subscriberbot/components/decisions/DecisionBanners.d.ts.map +0 -1
- package/dist/subscriberbot/components/decisions/DecisionCard.d.ts.map +0 -1
- package/dist/subscriberbot/components/decisions/decisionModel.d.ts.map +0 -1
- package/dist/subscriberbot/components/decisions/index.d.ts.map +0 -1
- package/dist/subscriberbot/components/index.d.ts.map +0 -1
- package/dist/subscriberbot/components/mobile/MobileDashboard.d.ts.map +0 -1
- package/dist/subscriberbot/components/mobile/MobileRelationshipList.d.ts.map +0 -1
- package/dist/subscriberbot/components/mobile/MobileScreen.d.ts.map +0 -1
- package/dist/subscriberbot/components/mobile/RelationshipGlyph.d.ts.map +0 -1
- package/dist/subscriberbot/components/mobile/index.d.ts.map +0 -1
- package/dist/subscriberbot/components/negotiations/NegotiationStatusPill.d.ts.map +0 -1
- package/dist/subscriberbot/components/negotiations/NegotiationTimeline.d.ts.map +0 -1
- package/dist/subscriberbot/components/negotiations/OutcomeForm.d.ts.map +0 -1
- package/dist/subscriberbot/components/negotiations/index.d.ts.map +0 -1
- package/dist/subscriberbot/components/negotiations/labels.d.ts.map +0 -1
- package/dist/subscriberbot/components/procurement/ProcurementOutcomeForm.d.ts.map +0 -1
- package/dist/subscriberbot/components/procurement/ProcurementStatusPill.d.ts.map +0 -1
- package/dist/subscriberbot/components/procurement/ProcurementThread.d.ts.map +0 -1
- package/dist/subscriberbot/components/procurement/index.d.ts.map +0 -1
- package/dist/subscriberbot/components/procurement/labels.d.ts.map +0 -1
- package/dist/subscriberbot/components/savings/SavingsCards.d.ts.map +0 -1
- package/dist/subscriberbot/components/savings/index.d.ts.map +0 -1
- package/dist/subscriberbot/components/savings/savingsModel.d.ts.map +0 -1
- package/dist/subscriberbot/components/viz.d.ts.map +0 -1
- package/dist/subscriberbot/config/assistantUsecases.d.ts.map +0 -1
- package/dist/subscriberbot/context/SubscriberBotContext.d.ts.map +0 -1
- package/dist/subscriberbot/context/index.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/index.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useAutonomousAgentMode.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useBankingApi.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useCompactViewport.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useFormError.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useFormatters.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useNegotiationApi.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useProcurementApi.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useRouteSelection.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useSubscriberBotApi.d.ts.map +0 -1
- package/dist/subscriberbot/hooks/useTr.d.ts.map +0 -1
- package/dist/subscriberbot/index.d.ts.map +0 -1
- package/dist/subscriberbot/pages/AssetVaultPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/DashboardPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/InboxPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/InsightsPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/InvoicesPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/RenewalsPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/SavingsPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/WorkflowsPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/agents/AgentDetailPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/agents/AgentNewPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/agents/AgentsListPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/banking/BankConnectionsPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/banking/ConnectBankModal.d.ts.map +0 -1
- package/dist/subscriberbot/pages/decisions/DecisionDetailPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/decisions/DecisionsPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/enterprise/EnterpriseSpendPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/negotiations/NegotiationDetailPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/negotiations/NegotiationNewPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/negotiations/NegotiationsPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/procurement/ProcurementDetailPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/procurement/ProcurementNewPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/procurement/ProcurementPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/providers/ProviderDetailPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/providers/ProviderInsights.d.ts.map +0 -1
- package/dist/subscriberbot/pages/providers/ProviderNewPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/providers/ProvidersListPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/relationships/RelationshipDetailPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/relationships/RelationshipNewPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/relationships/RelationshipsListPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/workflows/WorkflowBuilderPage.d.ts.map +0 -1
- package/dist/subscriberbot/pages/workflows/workflowBuilderGraph.d.ts.map +0 -1
- package/dist/subscriberbot/services/createSandboxAssistantTransport.d.ts.map +0 -1
- package/dist/subscriberbot/store/index.d.ts.map +0 -1
- package/dist/subscriberbot/store/subscriberbotStore.d.ts.map +0 -1
- package/dist/subscriberbot/types/assistant.d.ts.map +0 -1
- package/dist/subscriberbot/types/banking.d.ts.map +0 -1
- package/dist/subscriberbot/types/index.d.ts.map +0 -1
- package/dist/subscriberbot/types/negotiation.d.ts.map +0 -1
- package/dist/subscriberbot/types/procurement.d.ts.map +0 -1
- package/dist/subscriberbot/utils/bankRedirectLink.d.ts.map +0 -1
- package/dist/subscriberbot/utils/chartScale.d.ts.map +0 -1
- package/dist/subscriberbot/utils/cn.d.ts.map +0 -1
- package/dist/subscriberbot/utils/formatters.d.ts.map +0 -1
- package/dist/subscriberbot/utils/index.d.ts.map +0 -1
- package/dist/subscriberbot/utils/navigation.d.ts.map +0 -1
- package/dist/subscriberbot/utils/pageContext.d.ts.map +0 -1
- package/dist/subscriberbot/utils/plaidLink.d.ts.map +0 -1
- package/dist/subscriberbot/utils/portfolio.d.ts.map +0 -1
- package/dist/subscriberbot/utils/renewals.d.ts.map +0 -1
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
import { useSubscriberBot as e } from "../../context/SubscriberBotContext.js";
|
|
2
|
-
import { useTr as t } from "../../hooks/useTr.js";
|
|
3
|
-
import { PageLayout as n } from "../../components/PageLayout.js";
|
|
4
|
-
import { StatusBadge as r } from "../../components/StatusBadge.js";
|
|
5
|
-
import { EmptyState as i } from "../../components/EmptyState.js";
|
|
6
|
-
import { ErrorView as a, LoadingView as o } from "../../components/StateViews.js";
|
|
7
1
|
import "../../components/index.js";
|
|
8
|
-
import { useActivateWorkflow as
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
2
|
+
import { useActivateWorkflow as e, usePauseWorkflow as t, useSaveWorkflowGraph as n, useWorkflow as r } from "../../hooks/useSubscriberBotApi.js";
|
|
3
|
+
import { PageLayout as i } from "../../components/PageLayout.js";
|
|
4
|
+
import { StatusBadge as a } from "../../components/StatusBadge.js";
|
|
5
|
+
import { EmptyState as o } from "../../components/EmptyState.js";
|
|
6
|
+
import { ErrorView as s, LoadingView as c } from "../../components/StateViews.js";
|
|
7
|
+
import { useTr as l } from "../../hooks/useTr.js";
|
|
8
|
+
import { useSubscriberBot as u } from "../../context/SubscriberBotContext.js";
|
|
9
|
+
import { ACTION_KINDS as d, NODE_KINDS as f, canAddKind as p, configSummary as ee, connectionError as te, defaultLabel as m, fromServerGraph as h, initialConfig as g, nextNodePosition as _, removeNode as v, toSaveInput as ne } from "./workflowBuilderGraph.js";
|
|
10
|
+
import { useCallback as y, useMemo as b, useState as x } from "react";
|
|
11
|
+
import { AlertTriangle as S, ArrowLeft as C, CheckCircle2 as w, Clock as T, GitBranch as E, GitFork as D, Pause as O, Play as k, Save as re, Sparkles as A, Trash2 as j, Zap as M } from "lucide-react";
|
|
12
|
+
import { useParams as N } from "react-router";
|
|
13
|
+
import { Fragment as P, jsx as F, jsxs as I } from "react/jsx-runtime";
|
|
14
|
+
import { GlassCard as L } from "@burdenoff/fe-libs/ui";
|
|
15
|
+
import { Background as ie, Controls as ae, Handle as R, MarkerType as oe, Position as z, ReactFlow as se, applyNodeChanges as ce } from "@xyflow/react";
|
|
16
16
|
import "@xyflow/react/dist/style.css";
|
|
17
|
-
|
|
17
|
+
// src/subscriberbot/pages/workflows/WorkflowBuilderPage.tsx
|
|
18
18
|
var B = "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)] disabled:opacity-60", V = "mb-1 block text-xs font-medium text-text-secondary", H = "inline-flex items-center gap-1.5 rounded-lg border border-border-subtle px-3 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken disabled:opacity-50", U = "inline-flex items-center gap-1.5 rounded-lg bg-action-primary-bg px-3 py-2 text-sm font-medium text-action-primary-text hover:opacity-90 disabled:opacity-50", W = {
|
|
19
19
|
TRIGGER: {
|
|
20
|
-
icon:
|
|
20
|
+
icon: M,
|
|
21
21
|
bar: "bg-[var(--color-accent-indigo)]",
|
|
22
22
|
labelKey: "workflows.builder.kind.trigger",
|
|
23
23
|
fallback: "Trigger",
|
|
24
24
|
hint: "The event that starts the workflow"
|
|
25
25
|
},
|
|
26
26
|
ACTION: {
|
|
27
|
-
icon:
|
|
27
|
+
icon: A,
|
|
28
28
|
bar: "bg-status-success-text",
|
|
29
29
|
labelKey: "workflows.builder.kind.action",
|
|
30
30
|
fallback: "Action",
|
|
31
31
|
hint: "Notify, alert, create a task, update, classify or call an adapter"
|
|
32
32
|
},
|
|
33
33
|
CONDITION: {
|
|
34
|
-
icon:
|
|
34
|
+
icon: D,
|
|
35
35
|
bar: "bg-status-warning-text",
|
|
36
36
|
labelKey: "workflows.builder.kind.condition",
|
|
37
37
|
fallback: "Condition",
|
|
38
38
|
hint: "Route through a true or false outlet"
|
|
39
39
|
},
|
|
40
40
|
DELAY: {
|
|
41
|
-
icon:
|
|
41
|
+
icon: T,
|
|
42
42
|
bar: "bg-text-secondary",
|
|
43
43
|
labelKey: "workflows.builder.kind.delay",
|
|
44
44
|
fallback: "Delay",
|
|
45
45
|
hint: "Wait before the next step"
|
|
46
46
|
},
|
|
47
47
|
BRANCH: {
|
|
48
|
-
icon:
|
|
48
|
+
icon: E,
|
|
49
49
|
bar: "bg-[var(--color-accent-indigo)]",
|
|
50
50
|
labelKey: "workflows.builder.kind.branch",
|
|
51
51
|
fallback: "Branch",
|
|
@@ -59,186 +59,178 @@ var B = "w-full rounded-lg border border-border-subtle bg-bg-surface px-3 py-2 t
|
|
|
59
59
|
CLASSIFY: "Classify with AI",
|
|
60
60
|
EVALUATE_POLICIES: "Evaluate agent policies",
|
|
61
61
|
CALL_ADAPTER: "Call the provider adapter"
|
|
62
|
-
},
|
|
63
|
-
"overflow-hidden rounded-lg border border-border-subtle",
|
|
64
|
-
"[--xy-controls-box-shadow:none]",
|
|
65
|
-
"[--xy-controls-button-background-color:var(--color-bg-elevated)]",
|
|
66
|
-
"[--xy-controls-button-background-color-hover:var(--color-bg-surface)]",
|
|
67
|
-
"[--xy-controls-button-border-color:var(--color-border-subtle)]",
|
|
68
|
-
"[--xy-controls-button-color:var(--color-text-secondary)]",
|
|
69
|
-
"[--xy-controls-button-color-hover:var(--color-text-primary)]"
|
|
70
|
-
].join(" "), K = {
|
|
62
|
+
}, K = "overflow-hidden rounded-lg border border-border-subtle [--xy-controls-box-shadow:none] [--xy-controls-button-background-color:var(--color-bg-elevated)] [--xy-controls-button-background-color-hover:var(--color-bg-surface)] [--xy-controls-button-border-color:var(--color-border-subtle)] [--xy-controls-button-color:var(--color-text-secondary)] [--xy-controls-button-color-hover:var(--color-text-primary)]", q = {
|
|
71
63
|
background: "var(--color-text-secondary)",
|
|
72
64
|
width: 10,
|
|
73
65
|
height: 10
|
|
74
66
|
};
|
|
75
|
-
function
|
|
76
|
-
let
|
|
77
|
-
return /* @__PURE__ */
|
|
67
|
+
function J({ data: e, selected: t }) {
|
|
68
|
+
let n = l(), r = W[e.kind], i = r.icon;
|
|
69
|
+
return /* @__PURE__ */ I("div", {
|
|
78
70
|
"data-testid": `workflow-node-${e.kind.toLowerCase()}`,
|
|
79
|
-
className: `w-52 overflow-hidden rounded-xl border bg-bg-surface shadow-sm ${
|
|
71
|
+
className: `w-52 overflow-hidden rounded-xl border bg-bg-surface shadow-sm ${t ? "border-[var(--color-focus-ring)] ring-2 ring-[var(--color-focus-ring)]" : e.hasIssue ? "border-status-warning-text" : "border-border-subtle"}`,
|
|
80
72
|
children: [
|
|
81
|
-
e.kind !== "TRIGGER" && /* @__PURE__ */
|
|
73
|
+
e.kind !== "TRIGGER" && /* @__PURE__ */ F(R, {
|
|
82
74
|
type: "target",
|
|
83
75
|
position: z.Left,
|
|
84
|
-
style:
|
|
76
|
+
style: q
|
|
85
77
|
}),
|
|
86
|
-
/* @__PURE__ */
|
|
87
|
-
className: `h-1 w-full ${
|
|
78
|
+
/* @__PURE__ */ F("div", {
|
|
79
|
+
className: `h-1 w-full ${r.bar}`,
|
|
88
80
|
"aria-hidden": !0
|
|
89
81
|
}),
|
|
90
|
-
/* @__PURE__ */
|
|
82
|
+
/* @__PURE__ */ I("div", {
|
|
91
83
|
className: "p-3",
|
|
92
84
|
children: [
|
|
93
|
-
/* @__PURE__ */
|
|
85
|
+
/* @__PURE__ */ I("div", {
|
|
94
86
|
className: "flex items-center gap-2",
|
|
95
87
|
children: [
|
|
96
|
-
/* @__PURE__ */
|
|
88
|
+
/* @__PURE__ */ F("span", {
|
|
97
89
|
className: "flex size-8 shrink-0 items-center justify-center rounded-lg bg-[var(--color-accent-soft)] text-text-primary",
|
|
98
|
-
children: /* @__PURE__ */
|
|
90
|
+
children: /* @__PURE__ */ F(i, { className: "h-4 w-4" })
|
|
99
91
|
}),
|
|
100
|
-
/* @__PURE__ */
|
|
92
|
+
/* @__PURE__ */ F("p", {
|
|
101
93
|
className: "text-[10px] font-medium uppercase tracking-wide text-text-secondary",
|
|
102
|
-
children: r
|
|
94
|
+
children: n(r.labelKey, r.fallback)
|
|
103
95
|
}),
|
|
104
|
-
e.hasIssue && /* @__PURE__ */
|
|
96
|
+
e.hasIssue && /* @__PURE__ */ F(S, {
|
|
105
97
|
className: "ms-auto h-3.5 w-3.5 text-status-warning-text",
|
|
106
|
-
"aria-label":
|
|
98
|
+
"aria-label": n("workflows.builder.nodeHasIssue", "Needs attention")
|
|
107
99
|
})
|
|
108
100
|
]
|
|
109
101
|
}),
|
|
110
|
-
/* @__PURE__ */
|
|
102
|
+
/* @__PURE__ */ F("p", {
|
|
111
103
|
className: "mt-2 truncate text-sm font-semibold text-text-primary",
|
|
112
104
|
title: e.label,
|
|
113
105
|
children: e.label
|
|
114
106
|
}),
|
|
115
|
-
/* @__PURE__ */
|
|
107
|
+
/* @__PURE__ */ F("p", {
|
|
116
108
|
className: "mt-0.5 truncate text-xs text-text-secondary",
|
|
117
109
|
title: e.summary,
|
|
118
110
|
children: e.summary
|
|
119
111
|
})
|
|
120
112
|
]
|
|
121
113
|
}),
|
|
122
|
-
e.kind === "CONDITION" ? /* @__PURE__ */ P
|
|
114
|
+
e.kind === "CONDITION" ? /* @__PURE__ */ I(P, { children: [/* @__PURE__ */ F(R, {
|
|
123
115
|
id: "true",
|
|
124
116
|
type: "source",
|
|
125
117
|
position: z.Right,
|
|
126
118
|
style: {
|
|
127
|
-
...
|
|
119
|
+
...q,
|
|
128
120
|
top: "35%",
|
|
129
121
|
background: "var(--color-status-success-text)"
|
|
130
122
|
}
|
|
131
|
-
}), /* @__PURE__ */
|
|
123
|
+
}), /* @__PURE__ */ F(R, {
|
|
132
124
|
id: "false",
|
|
133
125
|
type: "source",
|
|
134
126
|
position: z.Right,
|
|
135
127
|
style: {
|
|
136
|
-
...
|
|
128
|
+
...q,
|
|
137
129
|
top: "70%",
|
|
138
130
|
background: "var(--color-status-error-text)"
|
|
139
131
|
}
|
|
140
|
-
})] }) : /* @__PURE__ */
|
|
132
|
+
})] }) : /* @__PURE__ */ F(R, {
|
|
141
133
|
type: "source",
|
|
142
134
|
position: z.Right,
|
|
143
|
-
style:
|
|
135
|
+
style: q
|
|
144
136
|
})
|
|
145
137
|
]
|
|
146
138
|
});
|
|
147
139
|
}
|
|
148
|
-
var
|
|
149
|
-
function
|
|
150
|
-
let
|
|
140
|
+
var le = { workflow: J };
|
|
141
|
+
function ue({ node: e, readOnly: t, onChange: n, onDelete: r }) {
|
|
142
|
+
let i = l(), a = W[e.kind], o = (t) => n({ config: {
|
|
151
143
|
...e.config,
|
|
152
144
|
...t
|
|
153
145
|
} });
|
|
154
|
-
return /* @__PURE__ */
|
|
146
|
+
return /* @__PURE__ */ I("div", {
|
|
155
147
|
className: "space-y-4",
|
|
156
148
|
"data-testid": "workflow-node-inspector",
|
|
157
149
|
children: [
|
|
158
|
-
/* @__PURE__ */
|
|
150
|
+
/* @__PURE__ */ F("p", {
|
|
159
151
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
160
|
-
children: a
|
|
152
|
+
children: i(a.labelKey, a.fallback)
|
|
161
153
|
}),
|
|
162
|
-
/* @__PURE__ */
|
|
154
|
+
/* @__PURE__ */ I("div", { children: [/* @__PURE__ */ F("label", {
|
|
163
155
|
htmlFor: "wfb-label",
|
|
164
156
|
className: V,
|
|
165
|
-
children:
|
|
166
|
-
}), /* @__PURE__ */
|
|
157
|
+
children: i("workflows.builder.inspector.label", "Label")
|
|
158
|
+
}), /* @__PURE__ */ F("input", {
|
|
167
159
|
id: "wfb-label",
|
|
168
160
|
className: B,
|
|
169
161
|
value: e.label,
|
|
170
162
|
maxLength: 120,
|
|
171
|
-
disabled:
|
|
172
|
-
onChange: (e) =>
|
|
163
|
+
disabled: t,
|
|
164
|
+
onChange: (e) => n({ label: e.target.value })
|
|
173
165
|
})] }),
|
|
174
|
-
e.kind === "TRIGGER" && /* @__PURE__ */
|
|
166
|
+
e.kind === "TRIGGER" && /* @__PURE__ */ I("div", { children: [/* @__PURE__ */ F("label", {
|
|
175
167
|
htmlFor: "wfb-event",
|
|
176
168
|
className: V,
|
|
177
|
-
children:
|
|
178
|
-
}), /* @__PURE__ */
|
|
169
|
+
children: i("workflows.builder.inspector.event", "Trigger event")
|
|
170
|
+
}), /* @__PURE__ */ F("input", {
|
|
179
171
|
id: "wfb-event",
|
|
180
172
|
className: B,
|
|
181
173
|
value: typeof e.config.event == "string" ? e.config.event : "",
|
|
182
174
|
maxLength: 120,
|
|
183
|
-
placeholder:
|
|
184
|
-
disabled:
|
|
185
|
-
onChange: (e) =>
|
|
175
|
+
placeholder: i("workflows.form.triggerPlaceholder", "e.g. InvoiceReceived, RenewalDetected"),
|
|
176
|
+
disabled: t,
|
|
177
|
+
onChange: (e) => o({ event: e.target.value })
|
|
186
178
|
})] }),
|
|
187
|
-
e.kind === "ACTION" && /* @__PURE__ */ P
|
|
179
|
+
e.kind === "ACTION" && /* @__PURE__ */ I(P, { children: [/* @__PURE__ */ I("div", { children: [/* @__PURE__ */ F("label", {
|
|
188
180
|
htmlFor: "wfb-action",
|
|
189
181
|
className: V,
|
|
190
|
-
children:
|
|
191
|
-
}), /* @__PURE__ */
|
|
182
|
+
children: i("workflows.builder.inspector.action", "Action")
|
|
183
|
+
}), /* @__PURE__ */ I("select", {
|
|
192
184
|
id: "wfb-action",
|
|
193
185
|
className: B,
|
|
194
186
|
value: typeof e.config.action == "string" ? e.config.action : "",
|
|
195
|
-
disabled:
|
|
196
|
-
onChange: (e) =>
|
|
197
|
-
children: [/* @__PURE__ */
|
|
187
|
+
disabled: t,
|
|
188
|
+
onChange: (e) => o({ action: e.target.value || void 0 }),
|
|
189
|
+
children: [/* @__PURE__ */ F("option", {
|
|
198
190
|
value: "",
|
|
199
|
-
children:
|
|
200
|
-
}), d.map((e) => /* @__PURE__ */
|
|
191
|
+
children: i("workflows.builder.inspector.chooseAction", "Choose an action…")
|
|
192
|
+
}), d.map((e) => /* @__PURE__ */ F("option", {
|
|
201
193
|
value: e,
|
|
202
|
-
children:
|
|
194
|
+
children: i(`workflows.builder.action.${e.toLowerCase()}`, G[e])
|
|
203
195
|
}, e))]
|
|
204
|
-
})] }), /* @__PURE__ */
|
|
196
|
+
})] }), /* @__PURE__ */ I("div", { children: [/* @__PURE__ */ F("label", {
|
|
205
197
|
htmlFor: "wfb-message",
|
|
206
198
|
className: V,
|
|
207
|
-
children:
|
|
208
|
-
}), /* @__PURE__ */
|
|
199
|
+
children: i("workflows.builder.inspector.message", "Message (optional)")
|
|
200
|
+
}), /* @__PURE__ */ F("textarea", {
|
|
209
201
|
id: "wfb-message",
|
|
210
202
|
rows: 3,
|
|
211
203
|
className: B,
|
|
212
204
|
maxLength: 1e3,
|
|
213
205
|
value: typeof e.config.message == "string" ? e.config.message : "",
|
|
214
|
-
disabled:
|
|
215
|
-
onChange: (e) =>
|
|
206
|
+
disabled: t,
|
|
207
|
+
onChange: (e) => o({ message: e.target.value })
|
|
216
208
|
})] })] }),
|
|
217
|
-
e.kind === "CONDITION" && /* @__PURE__ */
|
|
218
|
-
/* @__PURE__ */
|
|
209
|
+
e.kind === "CONDITION" && /* @__PURE__ */ I("div", { children: [
|
|
210
|
+
/* @__PURE__ */ F("label", {
|
|
219
211
|
htmlFor: "wfb-expression",
|
|
220
212
|
className: V,
|
|
221
|
-
children:
|
|
213
|
+
children: i("workflows.builder.inspector.expression", "Condition")
|
|
222
214
|
}),
|
|
223
|
-
/* @__PURE__ */
|
|
215
|
+
/* @__PURE__ */ F("input", {
|
|
224
216
|
id: "wfb-expression",
|
|
225
217
|
className: B,
|
|
226
218
|
maxLength: 500,
|
|
227
|
-
placeholder:
|
|
219
|
+
placeholder: i("workflows.builder.inspector.expressionPlaceholder", "e.g. monthlySpend > 100"),
|
|
228
220
|
value: typeof e.config.expression == "string" ? e.config.expression : "",
|
|
229
|
-
disabled:
|
|
230
|
-
onChange: (e) =>
|
|
221
|
+
disabled: t,
|
|
222
|
+
onChange: (e) => o({ expression: e.target.value })
|
|
231
223
|
}),
|
|
232
|
-
/* @__PURE__ */
|
|
224
|
+
/* @__PURE__ */ F("p", {
|
|
233
225
|
className: "mt-1 text-xs text-text-secondary",
|
|
234
|
-
children:
|
|
226
|
+
children: i("workflows.builder.inspector.expressionHint", "Connect the green outlet for when it holds and the red outlet for when it does not.")
|
|
235
227
|
})
|
|
236
228
|
] }),
|
|
237
|
-
e.kind === "DELAY" && /* @__PURE__ */
|
|
229
|
+
e.kind === "DELAY" && /* @__PURE__ */ I("div", { children: [/* @__PURE__ */ F("label", {
|
|
238
230
|
htmlFor: "wfb-delay",
|
|
239
231
|
className: V,
|
|
240
|
-
children:
|
|
241
|
-
}), /* @__PURE__ */
|
|
232
|
+
children: i("workflows.builder.inspector.delay", "Wait (minutes)")
|
|
233
|
+
}), /* @__PURE__ */ F("input", {
|
|
242
234
|
id: "wfb-delay",
|
|
243
235
|
type: "number",
|
|
244
236
|
min: 1,
|
|
@@ -246,59 +238,59 @@ function de({ node: e, readOnly: n, onChange: r, onDelete: i }) {
|
|
|
246
238
|
step: 1,
|
|
247
239
|
className: B,
|
|
248
240
|
value: typeof e.config.durationMinutes == "number" ? e.config.durationMinutes : "",
|
|
249
|
-
disabled:
|
|
241
|
+
disabled: t,
|
|
250
242
|
onChange: (e) => {
|
|
251
243
|
let t = Number.parseInt(e.target.value, 10);
|
|
252
|
-
|
|
244
|
+
o({ durationMinutes: Number.isFinite(t) ? t : void 0 });
|
|
253
245
|
}
|
|
254
246
|
})] }),
|
|
255
|
-
e.kind === "BRANCH" && /* @__PURE__ */
|
|
247
|
+
e.kind === "BRANCH" && /* @__PURE__ */ F("p", {
|
|
256
248
|
className: "text-xs text-text-secondary",
|
|
257
|
-
children:
|
|
249
|
+
children: i("workflows.builder.inspector.branchHint", "Connect two or more steps; they run in parallel.")
|
|
258
250
|
}),
|
|
259
|
-
!
|
|
251
|
+
!t && /* @__PURE__ */ I("button", {
|
|
260
252
|
type: "button",
|
|
261
|
-
onClick:
|
|
253
|
+
onClick: r,
|
|
262
254
|
className: "inline-flex items-center gap-1.5 rounded-lg border border-status-error-text/40 px-3 py-1.5 text-xs font-medium text-status-error-text hover:bg-status-error-bg-subtle",
|
|
263
255
|
children: [
|
|
264
|
-
/* @__PURE__ */
|
|
256
|
+
/* @__PURE__ */ F(j, { className: "h-3.5 w-3.5" }),
|
|
265
257
|
" ",
|
|
266
|
-
|
|
258
|
+
i("workflows.builder.inspector.deleteNode", "Delete node")
|
|
267
259
|
]
|
|
268
260
|
})
|
|
269
261
|
]
|
|
270
262
|
});
|
|
271
263
|
}
|
|
272
|
-
function
|
|
273
|
-
let
|
|
274
|
-
|
|
275
|
-
let
|
|
264
|
+
function Y({ workflow: r }) {
|
|
265
|
+
let i = l(), s = n(), c = e(), u = t(), [d, C] = x(() => h(r.graph)), [T, E] = x(r.graph.issues), [D, A] = x(!1), [N, R] = x(null), [z, B] = x(null), [V, G] = x(null), [q, J] = x(1), Y = r.status === "ACTIVE", X = Y || s.isPending, [de, fe] = x(r.graph);
|
|
266
|
+
de !== r.graph && (fe(r.graph), D || (C(h(r.graph)), E(r.graph.issues)));
|
|
267
|
+
let Z = b(() => new Set(T.map((e) => e.nodeId).filter((e) => !!e)), [T]), pe = b(() => d.nodes.map((e) => ({
|
|
276
268
|
id: e.id,
|
|
277
269
|
type: "workflow",
|
|
278
270
|
position: {
|
|
279
271
|
x: e.x,
|
|
280
272
|
y: e.y
|
|
281
273
|
},
|
|
282
|
-
selected: e.id ===
|
|
274
|
+
selected: e.id === N,
|
|
283
275
|
data: {
|
|
284
276
|
kind: e.kind,
|
|
285
|
-
label: e.label ||
|
|
286
|
-
summary: ee(e,
|
|
287
|
-
hasIssue: !
|
|
277
|
+
label: e.label || i(`workflowBuilder.nodeLabel.${e.kind.toLowerCase()}`, m(e.kind)),
|
|
278
|
+
summary: ee(e, i),
|
|
279
|
+
hasIssue: !D && Z.has(e.id)
|
|
288
280
|
}
|
|
289
281
|
})), [
|
|
290
282
|
d.nodes,
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
]),
|
|
283
|
+
N,
|
|
284
|
+
D,
|
|
285
|
+
Z,
|
|
286
|
+
i
|
|
287
|
+
]), me = b(() => d.edges.map((e) => ({
|
|
296
288
|
id: e.id,
|
|
297
289
|
source: e.source,
|
|
298
290
|
target: e.target,
|
|
299
291
|
sourceHandle: e.handle,
|
|
300
292
|
selected: e.id === z,
|
|
301
|
-
label: e.handle === "true" ?
|
|
293
|
+
label: e.handle === "true" ? i("workflows.builder.yes", "Yes") : e.handle === "false" ? i("workflows.builder.no", "No") : void 0,
|
|
302
294
|
markerEnd: {
|
|
303
295
|
type: oe.ArrowClosed,
|
|
304
296
|
color: "var(--color-text-secondary)"
|
|
@@ -310,12 +302,12 @@ function J({ workflow: e }) {
|
|
|
310
302
|
})), [
|
|
311
303
|
d.edges,
|
|
312
304
|
z,
|
|
313
|
-
|
|
314
|
-
]), Q =
|
|
315
|
-
|
|
316
|
-
}, []), he =
|
|
305
|
+
i
|
|
306
|
+
]), Q = y((e) => {
|
|
307
|
+
C((t) => e(t)), A(!0), G(null);
|
|
308
|
+
}, []), he = y((e) => {
|
|
317
309
|
let t = e.filter((e) => e.type === "position" && e.position), n = e.filter((e) => e.type === "remove");
|
|
318
|
-
|
|
310
|
+
X || t.length === 0 && n.length === 0 || Q((e) => {
|
|
319
311
|
let r = ce(t, e.nodes.map((e) => ({
|
|
320
312
|
id: e.id,
|
|
321
313
|
position: {
|
|
@@ -334,26 +326,22 @@ function J({ workflow: e }) {
|
|
|
334
326
|
}),
|
|
335
327
|
edges: e.edges
|
|
336
328
|
};
|
|
337
|
-
for (let e of n) e.type === "remove" && (i =
|
|
329
|
+
for (let e of n) e.type === "remove" && (i = v(i, e.id));
|
|
338
330
|
return i;
|
|
339
331
|
});
|
|
340
|
-
}, [Q,
|
|
332
|
+
}, [Q, X]), ge = y((e) => {
|
|
341
333
|
let t = new Set(e.filter((e) => e.type === "remove").map((e) => e.id));
|
|
342
|
-
|
|
334
|
+
X || t.size === 0 || Q((e) => ({
|
|
343
335
|
nodes: e.nodes,
|
|
344
336
|
edges: e.edges.filter((e) => !t.has(e.id))
|
|
345
337
|
}));
|
|
346
|
-
}, [Q,
|
|
347
|
-
if (
|
|
348
|
-
let t = e.sourceHandle ?? null,
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
});
|
|
354
|
-
return;
|
|
355
|
-
}
|
|
356
|
-
Q((n) => ({
|
|
338
|
+
}, [Q, X]), _e = y((e) => {
|
|
339
|
+
if (X) return;
|
|
340
|
+
let t = e.sourceHandle ?? null, n = te(d, e.source, e.target, t, i);
|
|
341
|
+
n ? G({
|
|
342
|
+
tone: "error",
|
|
343
|
+
text: n
|
|
344
|
+
}) : Q((n) => ({
|
|
357
345
|
nodes: n.nodes,
|
|
358
346
|
edges: [...n.edges, {
|
|
359
347
|
id: `edge-${e.source}-${t ?? "out"}-${e.target}`,
|
|
@@ -366,166 +354,166 @@ function J({ workflow: e }) {
|
|
|
366
354
|
}, [
|
|
367
355
|
Q,
|
|
368
356
|
d,
|
|
369
|
-
|
|
370
|
-
|
|
357
|
+
X,
|
|
358
|
+
i
|
|
371
359
|
]), ve = (e) => {
|
|
372
|
-
let t = `new-${
|
|
373
|
-
|
|
374
|
-
let
|
|
375
|
-
Q((
|
|
376
|
-
nodes: [...
|
|
360
|
+
let t = `new-${q}`;
|
|
361
|
+
J((e) => e + 1);
|
|
362
|
+
let n = _(d.nodes);
|
|
363
|
+
Q((r) => ({
|
|
364
|
+
nodes: [...r.nodes, {
|
|
377
365
|
id: t,
|
|
378
366
|
kind: e,
|
|
379
|
-
label:
|
|
367
|
+
label: i(`workflowBuilder.nodeLabel.${e.toLowerCase()}`, m(e)),
|
|
380
368
|
config: g(e),
|
|
381
|
-
x:
|
|
382
|
-
y:
|
|
369
|
+
x: n.x,
|
|
370
|
+
y: n.y
|
|
383
371
|
}],
|
|
384
|
-
edges:
|
|
372
|
+
edges: r.edges
|
|
385
373
|
})), R(t), B(null);
|
|
386
|
-
}, $ = d.nodes.find((e) => e.id ===
|
|
387
|
-
|
|
388
|
-
workflowId:
|
|
389
|
-
input:
|
|
374
|
+
}, $ = d.nodes.find((e) => e.id === N) ?? null, ye = () => {
|
|
375
|
+
s.mutate({
|
|
376
|
+
workflowId: r.id,
|
|
377
|
+
input: ne(d)
|
|
390
378
|
}, {
|
|
391
379
|
onSuccess: (e) => {
|
|
392
|
-
|
|
380
|
+
C(h(e)), E(e.issues), A(!1), R(null), B(null), G({
|
|
393
381
|
tone: "success",
|
|
394
|
-
text: e.valid ?
|
|
382
|
+
text: e.valid ? i("workflows.builder.savedValid", "Saved. This workflow is ready to activate.") : i("workflows.builder.savedWithIssues", "Saved as a draft. Fix the issues below before activating.")
|
|
395
383
|
});
|
|
396
384
|
},
|
|
397
385
|
onError: (e) => G({
|
|
398
386
|
tone: "error",
|
|
399
|
-
text: e instanceof Error ? e.message :
|
|
387
|
+
text: e instanceof Error ? e.message : i("common.error", "An error occurred")
|
|
400
388
|
})
|
|
401
389
|
});
|
|
402
|
-
}, be = () =>
|
|
390
|
+
}, be = () => c.mutate(r.id, {
|
|
403
391
|
onSuccess: () => G({
|
|
404
392
|
tone: "success",
|
|
405
|
-
text:
|
|
393
|
+
text: i("workflows.builder.activated", "Workflow activated.")
|
|
406
394
|
}),
|
|
407
395
|
onError: (e) => G({
|
|
408
396
|
tone: "error",
|
|
409
|
-
text: e instanceof Error ? e.message :
|
|
397
|
+
text: e instanceof Error ? e.message : i("common.error", "An error occurred")
|
|
410
398
|
})
|
|
411
|
-
}), xe = () => u.mutate(
|
|
399
|
+
}), xe = () => u.mutate(r.id, {
|
|
412
400
|
onSuccess: () => G({
|
|
413
401
|
tone: "success",
|
|
414
|
-
text:
|
|
402
|
+
text: i("workflows.builder.paused", "Workflow paused. You can edit it now.")
|
|
415
403
|
}),
|
|
416
404
|
onError: (e) => G({
|
|
417
405
|
tone: "error",
|
|
418
|
-
text: e instanceof Error ? e.message :
|
|
406
|
+
text: e instanceof Error ? e.message : i("common.error", "An error occurred")
|
|
419
407
|
})
|
|
420
|
-
}), Se = !
|
|
421
|
-
return /* @__PURE__ */ P
|
|
422
|
-
/* @__PURE__ */
|
|
408
|
+
}), Se = !Y && !D && T.length === 0 && d.nodes.length > 0;
|
|
409
|
+
return /* @__PURE__ */ I(P, { children: [
|
|
410
|
+
/* @__PURE__ */ I("div", {
|
|
423
411
|
className: "flex flex-wrap items-center justify-between gap-3",
|
|
424
|
-
children: [/* @__PURE__ */
|
|
412
|
+
children: [/* @__PURE__ */ I("div", {
|
|
425
413
|
className: "flex flex-wrap items-center gap-2",
|
|
426
414
|
children: [
|
|
427
|
-
/* @__PURE__ */
|
|
428
|
-
|
|
415
|
+
/* @__PURE__ */ F(a, { status: r.status }),
|
|
416
|
+
D && /* @__PURE__ */ F("span", {
|
|
429
417
|
className: "rounded-full bg-status-warning-bg-subtle px-2 py-0.5 text-xs font-medium text-status-warning-text",
|
|
430
|
-
children:
|
|
418
|
+
children: i("workflows.builder.unsaved", "Unsaved changes")
|
|
431
419
|
}),
|
|
432
|
-
!
|
|
420
|
+
!D && T.length === 0 && d.nodes.length > 0 && /* @__PURE__ */ I("span", {
|
|
433
421
|
className: "inline-flex items-center gap-1 text-xs text-status-success-text",
|
|
434
422
|
children: [
|
|
435
|
-
/* @__PURE__ */
|
|
423
|
+
/* @__PURE__ */ F(w, { className: "h-3.5 w-3.5" }),
|
|
436
424
|
" ",
|
|
437
|
-
|
|
425
|
+
i("workflows.builder.valid", "Ready to run")
|
|
438
426
|
]
|
|
439
427
|
})
|
|
440
428
|
]
|
|
441
|
-
}), /* @__PURE__ */
|
|
429
|
+
}), /* @__PURE__ */ F("div", {
|
|
442
430
|
className: "flex flex-wrap items-center gap-2",
|
|
443
|
-
children:
|
|
431
|
+
children: Y ? /* @__PURE__ */ I("button", {
|
|
444
432
|
type: "button",
|
|
445
433
|
className: H,
|
|
446
434
|
onClick: xe,
|
|
447
435
|
disabled: u.isPending,
|
|
448
436
|
children: [
|
|
449
|
-
/* @__PURE__ */
|
|
437
|
+
/* @__PURE__ */ F(O, { className: "h-4 w-4" }),
|
|
450
438
|
" ",
|
|
451
|
-
|
|
439
|
+
i("workflows.builder.pauseToEdit", "Pause to edit")
|
|
452
440
|
]
|
|
453
|
-
}) : /* @__PURE__ */ P
|
|
441
|
+
}) : /* @__PURE__ */ I(P, { children: [/* @__PURE__ */ I("button", {
|
|
454
442
|
type: "button",
|
|
455
443
|
className: H,
|
|
456
444
|
onClick: ye,
|
|
457
|
-
disabled: !
|
|
445
|
+
disabled: !D || s.isPending,
|
|
458
446
|
children: [
|
|
459
|
-
/* @__PURE__ */
|
|
447
|
+
/* @__PURE__ */ F(re, { className: "h-4 w-4" }),
|
|
460
448
|
" ",
|
|
461
|
-
|
|
449
|
+
s.isPending ? i("workflows.builder.saving", "Saving…") : i("workflows.builder.save", "Save")
|
|
462
450
|
]
|
|
463
|
-
}), /* @__PURE__ */
|
|
451
|
+
}), /* @__PURE__ */ I("button", {
|
|
464
452
|
type: "button",
|
|
465
453
|
className: U,
|
|
466
454
|
onClick: be,
|
|
467
|
-
disabled: !Se ||
|
|
468
|
-
title:
|
|
455
|
+
disabled: !Se || c.isPending,
|
|
456
|
+
title: D ? i("workflows.builder.saveFirst", "Save your changes first") : T.length > 0 ? i("workflows.builder.fixIssuesFirst", "Fix the issues first") : void 0,
|
|
469
457
|
children: [
|
|
470
|
-
/* @__PURE__ */
|
|
458
|
+
/* @__PURE__ */ F(k, { className: "h-4 w-4" }),
|
|
471
459
|
" ",
|
|
472
|
-
|
|
460
|
+
c.isPending ? i("common.activating", "Activating…") : i("workflows.flow.activate", "Activate workflow")
|
|
473
461
|
]
|
|
474
462
|
})] })
|
|
475
463
|
})]
|
|
476
464
|
}),
|
|
477
|
-
V && /* @__PURE__ */
|
|
465
|
+
V && /* @__PURE__ */ F("div", {
|
|
478
466
|
role: V.tone === "error" ? "alert" : "status",
|
|
479
467
|
className: `mt-3 rounded-lg border px-4 py-2 text-sm ${V.tone === "error" ? "border-status-error-text/30 bg-status-error-bg-subtle text-status-error-text" : "border-status-success-text/30 bg-status-success-bg-subtle text-status-success-text"}`,
|
|
480
468
|
children: V.text
|
|
481
469
|
}),
|
|
482
|
-
|
|
470
|
+
Y && /* @__PURE__ */ F("p", {
|
|
483
471
|
className: "mt-3 text-sm text-text-secondary",
|
|
484
|
-
children:
|
|
472
|
+
children: i("workflows.builder.readOnlyActive", "This workflow is active, so it is shown read-only. Pause it to change its steps.")
|
|
485
473
|
}),
|
|
486
|
-
/* @__PURE__ */
|
|
474
|
+
/* @__PURE__ */ I("div", {
|
|
487
475
|
className: "mt-4 grid grid-cols-1 gap-4 lg:grid-cols-[13rem_minmax(0,1fr)_18rem]",
|
|
488
476
|
children: [
|
|
489
|
-
/* @__PURE__ */
|
|
477
|
+
/* @__PURE__ */ I(L, {
|
|
490
478
|
treatment: "metric",
|
|
491
479
|
className: "p-3",
|
|
492
|
-
children: [/* @__PURE__ */
|
|
480
|
+
children: [/* @__PURE__ */ F("p", {
|
|
493
481
|
className: "mb-2 text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
494
|
-
children:
|
|
495
|
-
}), /* @__PURE__ */
|
|
482
|
+
children: i("workflows.builder.palette", "Add a step")
|
|
483
|
+
}), /* @__PURE__ */ F("div", {
|
|
496
484
|
className: "grid grid-cols-2 gap-2 lg:grid-cols-1",
|
|
497
485
|
role: "group",
|
|
498
|
-
"aria-label":
|
|
486
|
+
"aria-label": i("workflows.builder.palette", "Add a step"),
|
|
499
487
|
children: f.map((e) => {
|
|
500
|
-
let t = W[e],
|
|
501
|
-
return /* @__PURE__ */
|
|
488
|
+
let t = W[e], n = t.icon, r = X || !p(e, d.nodes);
|
|
489
|
+
return /* @__PURE__ */ I("button", {
|
|
502
490
|
type: "button",
|
|
503
|
-
disabled:
|
|
491
|
+
disabled: r,
|
|
504
492
|
onClick: () => ve(e),
|
|
505
|
-
title:
|
|
493
|
+
title: i(`${t.labelKey}Hint`, t.hint),
|
|
506
494
|
className: "flex items-center gap-2 rounded-lg border border-border-subtle bg-bg-surface px-2.5 py-2 text-start text-sm text-text-primary hover:bg-bg-sunken disabled:cursor-not-allowed disabled:opacity-50",
|
|
507
|
-
children: [/* @__PURE__ */
|
|
495
|
+
children: [/* @__PURE__ */ F(n, { className: "h-4 w-4 shrink-0 text-text-secondary" }), /* @__PURE__ */ F("span", {
|
|
508
496
|
className: "truncate",
|
|
509
|
-
children:
|
|
497
|
+
children: i(t.labelKey, t.fallback)
|
|
510
498
|
})]
|
|
511
499
|
}, e);
|
|
512
500
|
})
|
|
513
501
|
})]
|
|
514
502
|
}),
|
|
515
|
-
/* @__PURE__ */
|
|
503
|
+
/* @__PURE__ */ F("div", {
|
|
516
504
|
className: "h-[60vh] min-h-[420px] overflow-hidden rounded-xl border border-border-subtle bg-bg-sunken",
|
|
517
505
|
"data-testid": "workflow-canvas",
|
|
518
|
-
children: d.nodes.length === 0 ? /* @__PURE__ */
|
|
506
|
+
children: d.nodes.length === 0 ? /* @__PURE__ */ F("div", {
|
|
519
507
|
className: "flex h-full items-center justify-center p-6",
|
|
520
|
-
children: /* @__PURE__ */
|
|
521
|
-
icon: /* @__PURE__ */
|
|
522
|
-
title:
|
|
523
|
-
description:
|
|
508
|
+
children: /* @__PURE__ */ F(o, {
|
|
509
|
+
icon: /* @__PURE__ */ F(M, { className: "h-10 w-10" }),
|
|
510
|
+
title: i("workflows.builder.emptyTitle", "Start with a trigger"),
|
|
511
|
+
description: i("workflows.builder.emptyDescription", "Add a trigger from the palette, then connect the steps that should follow it.")
|
|
524
512
|
})
|
|
525
|
-
}) : /* @__PURE__ */
|
|
526
|
-
nodes:
|
|
527
|
-
edges:
|
|
528
|
-
nodeTypes:
|
|
513
|
+
}) : /* @__PURE__ */ I(se, {
|
|
514
|
+
nodes: pe,
|
|
515
|
+
edges: me,
|
|
516
|
+
nodeTypes: le,
|
|
529
517
|
onNodesChange: he,
|
|
530
518
|
onEdgesChange: ge,
|
|
531
519
|
onConnect: _e,
|
|
@@ -538,32 +526,32 @@ function J({ workflow: e }) {
|
|
|
538
526
|
onPaneClick: () => {
|
|
539
527
|
R(null), B(null);
|
|
540
528
|
},
|
|
541
|
-
nodesDraggable: !
|
|
542
|
-
nodesConnectable: !
|
|
543
|
-
deleteKeyCode:
|
|
529
|
+
nodesDraggable: !X,
|
|
530
|
+
nodesConnectable: !X,
|
|
531
|
+
deleteKeyCode: X ? null : ["Backspace", "Delete"],
|
|
544
532
|
fitView: !0,
|
|
545
533
|
fitViewOptions: {
|
|
546
534
|
padding: .2,
|
|
547
535
|
maxZoom: 1.1
|
|
548
536
|
},
|
|
549
537
|
proOptions: { hideAttribution: !0 },
|
|
550
|
-
children: [/* @__PURE__ */
|
|
538
|
+
children: [/* @__PURE__ */ F(ie, {
|
|
551
539
|
color: "var(--color-border-subtle)",
|
|
552
540
|
gap: 20
|
|
553
|
-
}), /* @__PURE__ */
|
|
541
|
+
}), /* @__PURE__ */ F(ae, {
|
|
554
542
|
showInteractive: !1,
|
|
555
|
-
className:
|
|
543
|
+
className: K
|
|
556
544
|
})]
|
|
557
545
|
})
|
|
558
546
|
}),
|
|
559
|
-
/* @__PURE__ */
|
|
547
|
+
/* @__PURE__ */ I("div", {
|
|
560
548
|
className: "space-y-4",
|
|
561
|
-
children: [/* @__PURE__ */
|
|
549
|
+
children: [/* @__PURE__ */ F(L, {
|
|
562
550
|
treatment: "metric",
|
|
563
551
|
className: "p-4",
|
|
564
|
-
children: $ ? /* @__PURE__ */
|
|
552
|
+
children: $ ? /* @__PURE__ */ F(ue, {
|
|
565
553
|
node: $,
|
|
566
|
-
readOnly:
|
|
554
|
+
readOnly: X,
|
|
567
555
|
onChange: (e) => Q((t) => ({
|
|
568
556
|
nodes: t.nodes.map((t) => t.id === $.id ? {
|
|
569
557
|
...t,
|
|
@@ -572,14 +560,14 @@ function J({ workflow: e }) {
|
|
|
572
560
|
edges: t.edges
|
|
573
561
|
})),
|
|
574
562
|
onDelete: () => {
|
|
575
|
-
Q((e) =>
|
|
563
|
+
Q((e) => v(e, $.id)), R(null);
|
|
576
564
|
}
|
|
577
|
-
}) : z && !
|
|
565
|
+
}) : z && !X ? /* @__PURE__ */ I("div", {
|
|
578
566
|
className: "space-y-3",
|
|
579
|
-
children: [/* @__PURE__ */
|
|
567
|
+
children: [/* @__PURE__ */ F("p", {
|
|
580
568
|
className: "text-sm text-text-primary",
|
|
581
|
-
children:
|
|
582
|
-
}), /* @__PURE__ */
|
|
569
|
+
children: i("workflows.builder.edgeSelected", "Connection selected")
|
|
570
|
+
}), /* @__PURE__ */ I("button", {
|
|
583
571
|
type: "button",
|
|
584
572
|
onClick: () => {
|
|
585
573
|
Q((e) => ({
|
|
@@ -589,40 +577,40 @@ function J({ workflow: e }) {
|
|
|
589
577
|
},
|
|
590
578
|
className: "inline-flex items-center gap-1.5 rounded-lg border border-status-error-text/40 px-3 py-1.5 text-xs font-medium text-status-error-text hover:bg-status-error-bg-subtle",
|
|
591
579
|
children: [
|
|
592
|
-
/* @__PURE__ */
|
|
580
|
+
/* @__PURE__ */ F(j, { className: "h-3.5 w-3.5" }),
|
|
593
581
|
" ",
|
|
594
|
-
|
|
582
|
+
i("workflows.builder.deleteEdge", "Delete connection")
|
|
595
583
|
]
|
|
596
584
|
})]
|
|
597
|
-
}) : /* @__PURE__ */
|
|
585
|
+
}) : /* @__PURE__ */ F("p", {
|
|
598
586
|
className: "text-sm text-text-secondary",
|
|
599
|
-
children:
|
|
587
|
+
children: i("workflows.builder.inspectorEmpty", "Select a node to edit it. Drag from a node’s right edge to another node to connect them.")
|
|
600
588
|
})
|
|
601
|
-
}), /* @__PURE__ */
|
|
589
|
+
}), /* @__PURE__ */ I(L, {
|
|
602
590
|
treatment: "metric",
|
|
603
591
|
className: "p-4",
|
|
604
592
|
"data-testid": "workflow-issues",
|
|
605
|
-
children: [/* @__PURE__ */
|
|
593
|
+
children: [/* @__PURE__ */ F("p", {
|
|
606
594
|
className: "mb-2 text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
607
|
-
children:
|
|
608
|
-
}),
|
|
595
|
+
children: i("workflows.builder.issues", "Validation")
|
|
596
|
+
}), D ? /* @__PURE__ */ F("p", {
|
|
609
597
|
className: "text-sm text-text-secondary",
|
|
610
|
-
children:
|
|
611
|
-
}) :
|
|
598
|
+
children: i("workflows.builder.issuesAfterSave", "Save to check the workflow.")
|
|
599
|
+
}) : T.length === 0 ? /* @__PURE__ */ I("p", {
|
|
612
600
|
className: "inline-flex items-center gap-1.5 text-sm text-status-success-text",
|
|
613
601
|
children: [
|
|
614
|
-
/* @__PURE__ */
|
|
602
|
+
/* @__PURE__ */ F(w, { className: "h-4 w-4" }),
|
|
615
603
|
" ",
|
|
616
|
-
|
|
604
|
+
i("workflows.builder.noIssues", "No issues found")
|
|
617
605
|
]
|
|
618
|
-
}) : /* @__PURE__ */
|
|
606
|
+
}) : /* @__PURE__ */ F("ul", {
|
|
619
607
|
className: "space-y-2",
|
|
620
|
-
children:
|
|
608
|
+
children: T.map((e, t) => /* @__PURE__ */ F("li", { children: /* @__PURE__ */ I("button", {
|
|
621
609
|
type: "button",
|
|
622
610
|
className: "flex w-full items-start gap-2 text-start text-sm text-text-primary hover:underline disabled:no-underline",
|
|
623
611
|
disabled: !e.nodeId,
|
|
624
612
|
onClick: () => e.nodeId && R(e.nodeId),
|
|
625
|
-
children: [/* @__PURE__ */
|
|
613
|
+
children: [/* @__PURE__ */ F(S, { className: "mt-0.5 h-4 w-4 shrink-0 text-status-warning-text" }), /* @__PURE__ */ F("span", { children: e.message })]
|
|
626
614
|
}) }, `${e.code}-${e.nodeId ?? e.edgeId ?? t}`))
|
|
627
615
|
})]
|
|
628
616
|
})]
|
|
@@ -631,31 +619,30 @@ function J({ workflow: e }) {
|
|
|
631
619
|
})
|
|
632
620
|
] });
|
|
633
621
|
}
|
|
634
|
-
function
|
|
635
|
-
let { id:
|
|
636
|
-
return /* @__PURE__ */
|
|
637
|
-
title:
|
|
638
|
-
description:
|
|
639
|
-
actions: /* @__PURE__ */
|
|
622
|
+
function X() {
|
|
623
|
+
let { id: e } = N(), t = l(), { navigateTo: n } = u(), { data: a, isLoading: d, isError: f, refetch: p } = r(e);
|
|
624
|
+
return /* @__PURE__ */ F(i, {
|
|
625
|
+
title: a?.name ?? t("workflows.builder.title", "Workflow builder"),
|
|
626
|
+
description: a ? t("workflows.builder.subtitle", "Visual builder · starts on {{trigger}}", { trigger: a.triggerEvent || "—" }) : void 0,
|
|
627
|
+
actions: /* @__PURE__ */ I("button", {
|
|
640
628
|
type: "button",
|
|
641
629
|
className: H,
|
|
642
|
-
onClick: () =>
|
|
630
|
+
onClick: () => n(e ? `/workflows/${e}` : "/workflows"),
|
|
643
631
|
children: [
|
|
644
|
-
/* @__PURE__ */
|
|
632
|
+
/* @__PURE__ */ F(C, { className: "rtl:rotate-180 h-4 w-4" }),
|
|
645
633
|
" ",
|
|
646
|
-
|
|
634
|
+
t("workflows.builder.back", "Workflows")
|
|
647
635
|
]
|
|
648
636
|
}),
|
|
649
|
-
children: d ? /* @__PURE__ */
|
|
650
|
-
message:
|
|
637
|
+
children: d ? /* @__PURE__ */ F(c, { label: t("workflows.builder.loading", "Loading workflow…") }) : f ? /* @__PURE__ */ F(s, {
|
|
638
|
+
message: t("workflows.builder.error", "Could not load this workflow."),
|
|
651
639
|
onRetry: () => void p()
|
|
652
|
-
}) :
|
|
653
|
-
title:
|
|
654
|
-
description:
|
|
640
|
+
}) : a ? /* @__PURE__ */ F(Y, { workflow: a }, a.id) : /* @__PURE__ */ F(o, {
|
|
641
|
+
title: t("workflows.builder.notFound", "Workflow not found"),
|
|
642
|
+
description: t("workflows.builder.notFoundDescription", "It may have been deleted, or it belongs to another workspace.")
|
|
655
643
|
})
|
|
656
644
|
});
|
|
657
645
|
}
|
|
658
|
-
|
|
659
|
-
export { Y as WorkflowBuilderPage };
|
|
646
|
+
export { X as WorkflowBuilderPage };
|
|
660
647
|
|
|
661
648
|
//# sourceMappingURL=WorkflowBuilderPage.js.map
|