@stigmer/react 3.40.1 → 3.41.1-dev.20261003094357.g39d6aa748646
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/access/ManageAccessButton.d.ts +1 -1
- package/access/ManageAccessButton.js +1 -1
- package/access/ManageAccessDialog.d.ts +1 -1
- package/access/ManageAccessDialog.js +2 -2
- package/access/ManageAccessDialog.js.map +1 -1
- package/access/types.d.ts +1 -1
- package/agent/AgentDetailView.d.ts.map +1 -1
- package/agent/AgentDetailView.js +2 -1
- package/agent/AgentDetailView.js.map +1 -1
- package/api-key/ApiKeyListPanel.d.ts.map +1 -1
- package/api-key/ApiKeyListPanel.js +2 -1
- package/api-key/ApiKeyListPanel.js.map +1 -1
- package/attachment/AttachmentImageLightbox.d.ts.map +1 -1
- package/attachment/AttachmentImageLightbox.js.map +1 -1
- package/billing/AutoRechargeCard.d.ts +3 -3
- package/billing/AutoRechargeCard.d.ts.map +1 -1
- package/billing/AutoRechargeCard.js +4 -4
- package/billing/AutoRechargeCard.js.map +1 -1
- package/billing/BillingSection.d.ts.map +1 -1
- package/billing/BillingSection.js +7 -6
- package/billing/BillingSection.js.map +1 -1
- package/billing/ChangePlanDialog.d.ts.map +1 -1
- package/billing/ChangePlanDialog.js +13 -1
- package/billing/ChangePlanDialog.js.map +1 -1
- package/billing/CreditLedgerTable.d.ts +3 -3
- package/billing/CreditLedgerTable.d.ts.map +1 -1
- package/billing/CreditLedgerTable.js +3 -3
- package/billing/CreditLedgerTable.js.map +1 -1
- package/billing/CreditPackGrid.d.ts +1 -1
- package/billing/CreditPackGrid.js +1 -1
- package/billing/PaymentMethodCard.d.ts +1 -1
- package/billing/PaymentMethodCard.js +1 -1
- package/billing/PlanSection.d.ts +3 -3
- package/billing/PlanSection.d.ts.map +1 -1
- package/billing/PlanSection.js +4 -3
- package/billing/PlanSection.js.map +1 -1
- package/billing/ProviderKeysSection.d.ts +33 -0
- package/billing/ProviderKeysSection.d.ts.map +1 -0
- package/billing/ProviderKeysSection.js +143 -0
- package/billing/ProviderKeysSection.js.map +1 -0
- package/billing/UpgradeNotice.d.ts.map +1 -1
- package/billing/UpgradeNotice.js +1 -0
- package/billing/UpgradeNotice.js.map +1 -1
- package/billing/index.d.ts +4 -0
- package/billing/index.d.ts.map +1 -1
- package/billing/index.js +2 -0
- package/billing/index.js.map +1 -1
- package/billing/plan-features.d.ts +3 -2
- package/billing/plan-features.d.ts.map +1 -1
- package/billing/plan-features.js +5 -4
- package/billing/plan-features.js.map +1 -1
- package/billing/useBillingAccount.d.ts +4 -4
- package/billing/useBillingAccount.d.ts.map +1 -1
- package/billing/useBillingAccount.js +7 -7
- package/billing/useBillingAccount.js.map +1 -1
- package/billing/useBillingUsageReport.d.ts +4 -4
- package/billing/useBillingUsageReport.d.ts.map +1 -1
- package/billing/useBillingUsageReport.js +7 -7
- package/billing/useBillingUsageReport.js.map +1 -1
- package/billing/useChangePlan.d.ts +2 -2
- package/billing/useChangePlan.d.ts.map +1 -1
- package/billing/useChangePlan.js +4 -4
- package/billing/useChangePlan.js.map +1 -1
- package/billing/useCreateBillingPortalSession.d.ts +2 -2
- package/billing/useCreateBillingPortalSession.d.ts.map +1 -1
- package/billing/useCreateBillingPortalSession.js +3 -3
- package/billing/useCreateBillingPortalSession.js.map +1 -1
- package/billing/useCreateCheckoutSession.d.ts +2 -2
- package/billing/useCreateCheckoutSession.d.ts.map +1 -1
- package/billing/useCreateCheckoutSession.js +2 -2
- package/billing/useCreateCheckoutSession.js.map +1 -1
- package/billing/useCreatePaymentMethodSetupSession.d.ts +1 -1
- package/billing/useCreatePaymentMethodSetupSession.d.ts.map +1 -1
- package/billing/useCreatePaymentMethodSetupSession.js +2 -2
- package/billing/useCreatePaymentMethodSetupSession.js.map +1 -1
- package/billing/useCreditLedger.d.ts +4 -4
- package/billing/useCreditLedger.d.ts.map +1 -1
- package/billing/useCreditLedger.js +7 -7
- package/billing/useCreditLedger.js.map +1 -1
- package/billing/useCustomerModelPricing.d.ts +4 -4
- package/billing/useCustomerModelPricing.d.ts.map +1 -1
- package/billing/useCustomerModelPricing.js +6 -6
- package/billing/useCustomerModelPricing.js.map +1 -1
- package/billing/useEntitlements.d.ts +2 -2
- package/billing/useEntitlements.d.ts.map +1 -1
- package/billing/useEntitlements.js +4 -4
- package/billing/useEntitlements.js.map +1 -1
- package/billing/usePeriodEstimate.d.ts +1 -1
- package/billing/usePeriodEstimate.d.ts.map +1 -1
- package/billing/usePeriodEstimate.js +3 -3
- package/billing/usePeriodEstimate.js.map +1 -1
- package/billing/useProviderKeys.d.ts +67 -0
- package/billing/useProviderKeys.d.ts.map +1 -0
- package/billing/useProviderKeys.js +61 -0
- package/billing/useProviderKeys.js.map +1 -0
- package/billing/useSetAutoRechargeConfig.d.ts +2 -2
- package/billing/useSetAutoRechargeConfig.d.ts.map +1 -1
- package/billing/useSetAutoRechargeConfig.js +2 -2
- package/billing/useSetAutoRechargeConfig.js.map +1 -1
- package/billing/useSubscription.d.ts +3 -3
- package/billing/useSubscription.d.ts.map +1 -1
- package/billing/useSubscription.js +7 -7
- package/billing/useSubscription.js.map +1 -1
- package/channel/AgentChannelsPanel.d.ts.map +1 -1
- package/channel/AgentChannelsPanel.js +11 -9
- package/channel/AgentChannelsPanel.js.map +1 -1
- package/channel/connect/ServingAppSection.js +1 -1
- package/channel/connect/ServingAppSection.js.map +1 -1
- package/channel-app/ChannelAppDetailPanel.d.ts +2 -2
- package/channel-app/ChannelAppDetailPanel.js +17 -10
- package/channel-app/ChannelAppDetailPanel.js.map +1 -1
- package/channel-app/ChannelAppListPanel.d.ts +2 -2
- package/channel-app/ChannelAppListPanel.d.ts.map +1 -1
- package/channel-app/ChannelAppListPanel.js +2 -1
- package/channel-app/ChannelAppListPanel.js.map +1 -1
- package/channel-app/CreateChannelAppForm.js +1 -1
- package/channel-app/CreateChannelAppForm.js.map +1 -1
- package/channel-app/copy.d.ts +3 -3
- package/channel-app/copy.js +3 -3
- package/channel-app/internal.d.ts +9 -0
- package/channel-app/internal.d.ts.map +1 -1
- package/channel-app/internal.js +9 -0
- package/channel-app/internal.js.map +1 -1
- package/channel-app/slackAppSetup.d.ts +3 -24
- package/channel-app/slackAppSetup.d.ts.map +1 -1
- package/channel-app/slackAppSetup.js +6 -3
- package/channel-app/slackAppSetup.js.map +1 -1
- package/channel-app/whatsappAppSetup.d.ts +3 -27
- package/channel-app/whatsappAppSetup.d.ts.map +1 -1
- package/channel-app/whatsappAppSetup.js +5 -2
- package/channel-app/whatsappAppSetup.js.map +1 -1
- package/composer/SessionComposer.d.ts.map +1 -1
- package/composer/SessionComposer.js +5 -9
- package/composer/SessionComposer.js.map +1 -1
- package/cursor-accounts/CursorAccountEditor.js +3 -3
- package/cursor-accounts/CursorAccountEditor.js.map +1 -1
- package/cursor-accounts/CursorAccountsConsole.js +3 -3
- package/cursor-accounts/CursorAccountsConsole.js.map +1 -1
- package/dashboard/OperationalDashboard.d.ts +1 -4
- package/dashboard/OperationalDashboard.d.ts.map +1 -1
- package/dashboard/OperationalDashboard.js +1 -3
- package/dashboard/OperationalDashboard.js.map +1 -1
- package/dashboard/useDashboardSummary.d.ts +1 -3
- package/dashboard/useDashboardSummary.d.ts.map +1 -1
- package/dashboard/useDashboardSummary.js +1 -1
- package/dashboard/useDashboardSummary.js.map +1 -1
- package/environment/EnvironmentListPanel.d.ts.map +1 -1
- package/environment/EnvironmentListPanel.js +2 -1
- package/environment/EnvironmentListPanel.js.map +1 -1
- package/environment/EnvironmentVariableEditor.d.ts.map +1 -1
- package/environment/EnvironmentVariableEditor.js +3 -2
- package/environment/EnvironmentVariableEditor.js.map +1 -1
- package/environment/index.d.ts +1 -1
- package/environment/index.d.ts.map +1 -1
- package/environment/index.js +1 -1
- package/environment/index.js.map +1 -1
- package/environment/systemEnvVars.d.ts +4 -63
- package/environment/systemEnvVars.d.ts.map +1 -1
- package/environment/systemEnvVars.js +21 -113
- package/environment/systemEnvVars.js.map +1 -1
- package/execution/ArtifactFileContent.d.ts.map +1 -1
- package/execution/ArtifactFileContent.js +2 -1
- package/execution/ArtifactFileContent.js.map +1 -1
- package/execution/McpToolDetail.d.ts.map +1 -1
- package/execution/McpToolDetail.js +2 -1
- package/execution/McpToolDetail.js.map +1 -1
- package/execution/RecalledMemoriesCard.js +1 -1
- package/execution/ResultView.d.ts.map +1 -1
- package/execution/ResultView.js +2 -1
- package/execution/ResultView.js.map +1 -1
- package/execution/TerminalSession.js +1 -1
- package/execution/TerminalSession.js.map +1 -1
- package/execution/ThreadSkeleton.d.ts.map +1 -1
- package/execution/ThreadSkeleton.js +2 -1
- package/execution/ThreadSkeleton.js.map +1 -1
- package/execution/file-path-resolver.d.ts.map +1 -1
- package/execution/file-path-resolver.js +3 -2
- package/execution/file-path-resolver.js.map +1 -1
- package/execution/sandbox-path-normalizer.d.ts +0 -11
- package/execution/sandbox-path-normalizer.d.ts.map +1 -1
- package/execution/sandbox-path-normalizer.js +2 -1
- package/execution/sandbox-path-normalizer.js.map +1 -1
- package/github/parseGitUrl.d.ts.map +1 -1
- package/github/parseGitUrl.js +16 -4
- package/github/parseGitUrl.js.map +1 -1
- package/iam-policy/GrantAccessForm.d.ts +3 -3
- package/iam-policy/GrantAccessForm.d.ts.map +1 -1
- package/iam-policy/GrantAccessForm.js +3 -3
- package/iam-policy/GrantAccessForm.js.map +1 -1
- package/iam-policy/OrgMembersPanel.d.ts +3 -3
- package/iam-policy/OrgMembersPanel.d.ts.map +1 -1
- package/iam-policy/OrgMembersPanel.js +5 -4
- package/iam-policy/OrgMembersPanel.js.map +1 -1
- package/iam-policy/PeopleWithAccess.d.ts +2 -2
- package/iam-policy/PeopleWithAccess.d.ts.map +1 -1
- package/iam-policy/PeopleWithAccess.js +2 -2
- package/iam-policy/PeopleWithAccess.js.map +1 -1
- package/iam-policy/PrincipalPicker.d.ts +2 -2
- package/iam-policy/PrincipalPicker.d.ts.map +1 -1
- package/iam-policy/PrincipalPicker.js +2 -2
- package/iam-policy/PrincipalPicker.js.map +1 -1
- package/iam-policy/SharePanel.d.ts +3 -3
- package/iam-policy/SharePanel.d.ts.map +1 -1
- package/iam-policy/SharePanel.js +3 -3
- package/iam-policy/SharePanel.js.map +1 -1
- package/iam-policy/useCheckPermission.d.ts +4 -1
- package/iam-policy/useCheckPermission.d.ts.map +1 -1
- package/iam-policy/useCheckPermission.js +4 -1
- package/iam-policy/useCheckPermission.js.map +1 -1
- package/iam-policy/useCreateIamPolicy.d.ts +1 -1
- package/iam-policy/useCreateIamPolicy.js +1 -1
- package/iam-policy/useDeleteIamPolicy.d.ts +1 -1
- package/iam-policy/useDeleteIamPolicy.js +1 -1
- package/iam-policy/useGrantableRoles.d.ts +1 -1
- package/iam-policy/useGrantableRoles.js +1 -1
- package/iam-policy/useGranteeCandidates.d.ts +3 -3
- package/iam-policy/useGranteeCandidates.d.ts.map +1 -1
- package/iam-policy/useGranteeCandidates.js +2 -2
- package/iam-policy/useGranteeCandidates.js.map +1 -1
- package/iam-policy/useOwnerAssignment.d.ts +2 -2
- package/iam-policy/useOwnerAssignment.d.ts.map +1 -1
- package/iam-policy/useOwnerAssignment.js +3 -3
- package/iam-policy/useOwnerAssignment.js.map +1 -1
- package/iam-policy/usePrincipalsCount.d.ts +4 -4
- package/iam-policy/usePrincipalsCount.d.ts.map +1 -1
- package/iam-policy/usePrincipalsCount.js +7 -7
- package/iam-policy/usePrincipalsCount.js.map +1 -1
- package/iam-policy/useResourceAccess.d.ts +1 -1
- package/iam-policy/useResourceAccess.js +1 -1
- package/iam-policy/useRevokeOrgAccess.d.ts +11 -9
- package/iam-policy/useRevokeOrgAccess.d.ts.map +1 -1
- package/iam-policy/useRevokeOrgAccess.js +6 -6
- package/iam-policy/useRevokeOrgAccess.js.map +1 -1
- package/identity-account/AccountPreferencesPanel.d.ts +6 -0
- package/identity-account/AccountPreferencesPanel.d.ts.map +1 -1
- package/identity-account/AccountPreferencesPanel.js +35 -3
- package/identity-account/AccountPreferencesPanel.js.map +1 -1
- package/identity-account/useAccountExecutionDefaults.d.ts +1 -1
- package/identity-account/useAccountExecutionDefaults.d.ts.map +1 -1
- package/identity-account/useAccountExecutionDefaults.js +2 -3
- package/identity-account/useAccountExecutionDefaults.js.map +1 -1
- package/identity-provider/IdentityProviderDetailPanel.js +4 -4
- package/identity-provider/IdentityProviderDetailPanel.js.map +1 -1
- package/identity-provider/IdentityProviderListPanel.d.ts.map +1 -1
- package/identity-provider/IdentityProviderListPanel.js +2 -1
- package/identity-provider/IdentityProviderListPanel.js.map +1 -1
- package/identity-provider/IdentityProviderWizard.js +1 -1
- package/identity-provider/IdentityProviderWizard.js.map +1 -1
- package/identity-provider/SsoLoginPrompt.js +2 -1
- package/identity-provider/SsoLoginPrompt.js.map +1 -1
- package/identity-provider/useIdentityProviderList.d.ts +2 -2
- package/identity-provider/useIdentityProviderList.js +2 -2
- package/index.d.ts +4 -4
- package/index.d.ts.map +1 -1
- package/index.js +4 -4
- package/index.js.map +1 -1
- package/inline-edit/InlineEditImage.d.ts +4 -0
- package/inline-edit/InlineEditImage.d.ts.map +1 -1
- package/inline-edit/InlineEditImage.js +12 -11
- package/inline-edit/InlineEditImage.js.map +1 -1
- package/inline-edit/InlineEditText.d.ts +4 -0
- package/inline-edit/InlineEditText.d.ts.map +1 -1
- package/inline-edit/InlineEditText.js +12 -11
- package/inline-edit/InlineEditText.js.map +1 -1
- package/inline-edit/InlineEditTextarea.d.ts +4 -0
- package/inline-edit/InlineEditTextarea.d.ts.map +1 -1
- package/inline-edit/InlineEditTextarea.js +11 -16
- package/inline-edit/InlineEditTextarea.js.map +1 -1
- package/inline-edit/useInlineDraft.d.ts +26 -0
- package/inline-edit/useInlineDraft.d.ts.map +1 -0
- package/inline-edit/useInlineDraft.js +61 -0
- package/inline-edit/useInlineDraft.js.map +1 -0
- package/internal/DialogShell.d.ts +21 -0
- package/internal/DialogShell.d.ts.map +1 -1
- package/internal/DialogShell.js +51 -4
- package/internal/DialogShell.js.map +1 -1
- package/internal/LoadingRegion.d.ts +35 -0
- package/internal/LoadingRegion.d.ts.map +1 -0
- package/internal/LoadingRegion.js +33 -0
- package/internal/LoadingRegion.js.map +1 -0
- package/internal/UnknownPublicAddressNotice.d.ts +20 -0
- package/internal/UnknownPublicAddressNotice.d.ts.map +1 -0
- package/internal/UnknownPublicAddressNotice.js +19 -0
- package/internal/UnknownPublicAddressNotice.js.map +1 -0
- package/internal/features.js +2 -2
- package/internal/features.js.map +1 -1
- package/internal/markdown-components.d.ts.map +1 -1
- package/internal/markdown-components.js +18 -4
- package/internal/markdown-components.js.map +1 -1
- package/internal/trim.d.ts +7 -0
- package/internal/trim.d.ts.map +1 -0
- package/internal/trim.js +12 -0
- package/internal/trim.js.map +1 -0
- package/invitation/InvitationManager.d.ts.map +1 -1
- package/invitation/InvitationManager.js +2 -1
- package/invitation/InvitationManager.js.map +1 -1
- package/invitation/InvitationRedemption.d.ts.map +1 -1
- package/invitation/InvitationRedemption.js +5 -4
- package/invitation/InvitationRedemption.js.map +1 -1
- package/invitation/useInvitationPreview.d.ts +1 -1
- package/invitation/useInvitationPreview.js +1 -1
- package/library/InstanceVisibilitySelector.d.ts +1 -1
- package/library/InstanceVisibilitySelector.d.ts.map +1 -1
- package/library/ResourceVisibilityControl.d.ts +6 -3
- package/library/ResourceVisibilityControl.d.ts.map +1 -1
- package/library/ResourceVisibilityControl.js +7 -4
- package/library/ResourceVisibilityControl.js.map +1 -1
- package/library/VisibilitySelector.d.ts +2 -2
- package/library/VisibilitySelector.d.ts.map +1 -1
- package/library/VisibilitySelector.js +1 -1
- package/licenses/LicenseDetail.d.ts.map +1 -1
- package/licenses/LicenseDetail.js +3 -3
- package/licenses/LicenseDetail.js.map +1 -1
- package/licenses/LicenseIssueForm.js +7 -7
- package/licenses/LicenseIssueForm.js.map +1 -1
- package/licenses/license-draft.d.ts +1 -1
- package/licenses/license-draft.d.ts.map +1 -1
- package/licenses/license-draft.js +3 -3
- package/licenses/license-draft.js.map +1 -1
- package/licenses/license-format.d.ts +7 -5
- package/licenses/license-format.d.ts.map +1 -1
- package/licenses/license-format.js +2 -4
- package/licenses/license-format.js.map +1 -1
- package/mcp-server/McpServerConnectDialog.js +4 -5
- package/mcp-server/McpServerConnectDialog.js.map +1 -1
- package/mcp-server/McpServerDetailView.d.ts.map +1 -1
- package/mcp-server/McpServerDetailView.js +5 -7
- package/mcp-server/McpServerDetailView.js.map +1 -1
- package/mcp-server/McpServerPicker.d.ts.map +1 -1
- package/mcp-server/McpServerPicker.js +2 -6
- package/mcp-server/McpServerPicker.js.map +1 -1
- package/mcp-server/McpToolSelector.js +1 -1
- package/mcp-server/McpToolSelector.js.map +1 -1
- package/mcp-server/useMcpServerConnect.d.ts +14 -25
- package/mcp-server/useMcpServerConnect.d.ts.map +1 -1
- package/mcp-server/useMcpServerConnect.js +7 -19
- package/mcp-server/useMcpServerConnect.js.map +1 -1
- package/mcp-server/useMcpServerOAuthConnect.d.ts +1 -3
- package/mcp-server/useMcpServerOAuthConnect.d.ts.map +1 -1
- package/mcp-server/useMcpServerOAuthConnect.js +6 -19
- package/mcp-server/useMcpServerOAuthConnect.js.map +1 -1
- package/memory/MemoryListPanel.d.ts.map +1 -1
- package/memory/MemoryListPanel.js +2 -1
- package/memory/MemoryListPanel.js.map +1 -1
- package/models/HarnessSelector.d.ts.map +1 -1
- package/models/HarnessSelector.js +1 -2
- package/models/HarnessSelector.js.map +1 -1
- package/models/ModelSelector.d.ts +1 -1
- package/models/ModelSelector.d.ts.map +1 -1
- package/models/ModelSelector.js +1 -7
- package/models/ModelSelector.js.map +1 -1
- package/models/harness.d.ts +10 -6
- package/models/harness.d.ts.map +1 -1
- package/models/harness.js +35 -28
- package/models/harness.js.map +1 -1
- package/models/index.d.ts +1 -1
- package/models/index.d.ts.map +1 -1
- package/models/index.js +1 -1
- package/models/index.js.map +1 -1
- package/oauth-app/OAuthAppListPanel.d.ts.map +1 -1
- package/oauth-app/OAuthAppListPanel.js +2 -1
- package/oauth-app/OAuthAppListPanel.js.map +1 -1
- package/organization/OrgPreferencesPanel.d.ts +3 -3
- package/organization/OrgPreferencesPanel.d.ts.map +1 -1
- package/organization/OrgPreferencesPanel.js +19 -6
- package/organization/OrgPreferencesPanel.js.map +1 -1
- package/organization/OrgProfilePanel.d.ts +3 -3
- package/organization/OrgProfilePanel.d.ts.map +1 -1
- package/organization/OrgProfilePanel.js +8 -7
- package/organization/OrgProfilePanel.js.map +1 -1
- package/organization/index.d.ts +1 -0
- package/organization/index.d.ts.map +1 -1
- package/organization/index.js +1 -0
- package/organization/index.js.map +1 -1
- package/organization/useFollowSessionOrganization.d.ts +9 -0
- package/organization/useFollowSessionOrganization.d.ts.map +1 -0
- package/organization/useFollowSessionOrganization.js +52 -0
- package/organization/useFollowSessionOrganization.js.map +1 -0
- package/package.json +5 -5
- package/plan-catalog/plan-draft.js +3 -3
- package/plan-catalog/plan-draft.js.map +1 -1
- package/platform-client/PlatformClientListPanel.d.ts.map +1 -1
- package/platform-client/PlatformClientListPanel.js +2 -1
- package/platform-client/PlatformClientListPanel.js.map +1 -1
- package/plugin/PluginDetailView.d.ts.map +1 -1
- package/plugin/PluginDetailView.js +2 -1
- package/plugin/PluginDetailView.js.map +1 -1
- package/plugin/useMcpServerReadiness.js +2 -2
- package/plugin/useMcpServerReadiness.js.map +1 -1
- package/portal-container.d.ts +8 -0
- package/portal-container.d.ts.map +1 -1
- package/portal-container.js +8 -0
- package/portal-container.js.map +1 -1
- package/provider-standing/ProviderStandingConsole.js +1 -1
- package/provider.d.ts +31 -2
- package/provider.d.ts.map +1 -1
- package/provider.js +7 -3
- package/provider.js.map +1 -1
- package/public-base-url-context.d.ts +35 -0
- package/public-base-url-context.d.ts.map +1 -0
- package/public-base-url-context.js +63 -0
- package/public-base-url-context.js.map +1 -0
- package/resource-workbench/components/SelectionCheckbox.js +1 -1
- package/resource-workbench/components/SelectionCheckbox.js.map +1 -1
- package/schedule/ScheduleDetailView.d.ts.map +1 -1
- package/schedule/ScheduleDetailView.js +2 -1
- package/schedule/ScheduleDetailView.js.map +1 -1
- package/session/SessionViewer.d.ts +7 -2
- package/session/SessionViewer.d.ts.map +1 -1
- package/session/SessionViewer.js +7 -2
- package/session/SessionViewer.js.map +1 -1
- package/session/useLocalSessionWorker.d.ts +19 -3
- package/session/useLocalSessionWorker.d.ts.map +1 -1
- package/session/useLocalSessionWorker.js +37 -4
- package/session/useLocalSessionWorker.js.map +1 -1
- package/session/useSessionConversation.d.ts +10 -1
- package/session/useSessionConversation.d.ts.map +1 -1
- package/session/useSessionConversation.js +5 -3
- package/session/useSessionConversation.js.map +1 -1
- package/settings/ChannelAppsSection.d.ts +4 -4
- package/settings/ChannelAppsSection.js +4 -4
- package/settings/EnvironmentsSection.d.ts.map +1 -1
- package/settings/EnvironmentsSection.js +2 -1
- package/settings/EnvironmentsSection.js.map +1 -1
- package/settings/MembersSection.js +2 -2
- package/settings/MembersSection.js.map +1 -1
- package/settings/OrgPreferencesSection.js +1 -1
- package/settings/OrgPreferencesSection.js.map +1 -1
- package/settings/OrgProfileSection.js +1 -1
- package/settings/OrgProfileSection.js.map +1 -1
- package/settings/ProviderKeysSection.d.ts +3 -0
- package/settings/ProviderKeysSection.d.ts.map +1 -0
- package/settings/ProviderKeysSection.js +3 -0
- package/settings/ProviderKeysSection.js.map +1 -0
- package/settings/TeamsSection.js +1 -1
- package/settings/TeamsSection.js.map +1 -1
- package/settings/UsageSection.js +1 -1
- package/settings/UsageSection.js.map +1 -1
- package/settings/index.d.ts +2 -0
- package/settings/index.d.ts.map +1 -1
- package/settings/index.js +1 -0
- package/settings/index.js.map +1 -1
- package/settings/settings-nav.d.ts.map +1 -1
- package/settings/settings-nav.js +2 -1
- package/settings/settings-nav.js.map +1 -1
- package/sharing/ShareAgentDialog.d.ts.map +1 -1
- package/sharing/ShareAgentDialog.js +14 -9
- package/sharing/ShareAgentDialog.js.map +1 -1
- package/sharing/SharedAgentChat.d.ts.map +1 -1
- package/sharing/SharedAgentChat.js +2 -1
- package/sharing/SharedAgentChat.js.map +1 -1
- package/sharing/useCanCreateAgentShare.d.ts +3 -1
- package/sharing/useCanCreateAgentShare.d.ts.map +1 -1
- package/sharing/useCanCreateAgentShare.js +5 -3
- package/sharing/useCanCreateAgentShare.js.map +1 -1
- package/sharing/useSaveAgentShare.d.ts +1 -1
- package/sharing/useSaveAgentShare.js +1 -1
- package/sidebar/WorkspaceSidebar.d.ts.map +1 -1
- package/sidebar/WorkspaceSidebar.js +2 -1
- package/sidebar/WorkspaceSidebar.js.map +1 -1
- package/skill/SkillDetailView.d.ts.map +1 -1
- package/skill/SkillDetailView.js +2 -1
- package/skill/SkillDetailView.js.map +1 -1
- package/skill/SkillDiffDialog.d.ts.map +1 -1
- package/skill/SkillDiffDialog.js +2 -1
- package/skill/SkillDiffDialog.js.map +1 -1
- package/skill/SkillFileBrowser.d.ts.map +1 -1
- package/skill/SkillFileBrowser.js +2 -1
- package/skill/SkillFileBrowser.js.map +1 -1
- package/src/access/ManageAccessButton.tsx +1 -1
- package/src/access/ManageAccessDialog.tsx +2 -2
- package/src/access/types.ts +1 -1
- package/src/agent/AgentDetailView.tsx +4 -4
- package/src/api-key/ApiKeyListPanel.tsx +4 -4
- package/src/attachment/AttachmentImageLightbox.tsx +3 -4
- package/src/billing/AutoRechargeCard.tsx +5 -5
- package/src/billing/BillingSection.tsx +10 -9
- package/src/billing/ChangePlanDialog.tsx +14 -2
- package/src/billing/CreditLedgerTable.tsx +4 -4
- package/src/billing/CreditPackGrid.tsx +1 -1
- package/src/billing/PaymentMethodCard.tsx +1 -1
- package/src/billing/PlanSection.tsx +6 -5
- package/src/billing/ProviderKeysSection.tsx +324 -0
- package/src/billing/UpgradeNotice.tsx +1 -0
- package/src/billing/index.ts +9 -0
- package/src/billing/plan-features.ts +5 -4
- package/src/billing/useBillingAccount.ts +7 -7
- package/src/billing/useBillingUsageReport.ts +7 -7
- package/src/billing/useChangePlan.ts +6 -6
- package/src/billing/useCreateBillingPortalSession.ts +4 -4
- package/src/billing/useCreateCheckoutSession.ts +3 -3
- package/src/billing/useCreatePaymentMethodSetupSession.ts +3 -3
- package/src/billing/useCreditLedger.ts +7 -7
- package/src/billing/useCustomerModelPricing.ts +7 -7
- package/src/billing/useEntitlements.ts +5 -5
- package/src/billing/usePeriodEstimate.ts +4 -4
- package/src/billing/useProviderKeys.ts +129 -0
- package/src/billing/useSetAutoRechargeConfig.ts +3 -3
- package/src/billing/useSubscription.ts +7 -7
- package/src/channel/AgentChannelsPanel.tsx +11 -9
- package/src/channel/connect/ServingAppSection.tsx +1 -1
- package/src/channel-app/ChannelAppDetailPanel.tsx +37 -20
- package/src/channel-app/ChannelAppListPanel.tsx +6 -6
- package/src/channel-app/CreateChannelAppForm.tsx +0 -1
- package/src/channel-app/copy.ts +3 -3
- package/src/channel-app/internal.tsx +21 -0
- package/src/channel-app/slackAppSetup.ts +6 -3
- package/src/channel-app/whatsappAppSetup.ts +5 -2
- package/src/composer/SessionComposer.tsx +5 -14
- package/src/cursor-accounts/CursorAccountEditor.tsx +3 -3
- package/src/cursor-accounts/CursorAccountsConsole.tsx +5 -5
- package/src/dashboard/OperationalDashboard.tsx +1 -6
- package/src/dashboard/useDashboardSummary.ts +2 -4
- package/src/environment/EnvironmentListPanel.tsx +4 -4
- package/src/environment/EnvironmentVariableEditor.tsx +5 -5
- package/src/environment/index.ts +1 -7
- package/src/environment/systemEnvVars.ts +21 -133
- package/src/execution/ArtifactFileContent.tsx +3 -2
- package/src/execution/McpToolDetail.tsx +3 -3
- package/src/execution/RecalledMemoriesCard.tsx +1 -1
- package/src/execution/ResultView.tsx +3 -3
- package/src/execution/TerminalSession.tsx +1 -1
- package/src/execution/ThreadSkeleton.tsx +4 -4
- package/src/execution/file-path-resolver.ts +3 -2
- package/src/execution/sandbox-path-normalizer.ts +2 -1
- package/src/github/parseGitUrl.ts +13 -4
- package/src/iam-policy/GrantAccessForm.tsx +4 -4
- package/src/iam-policy/OrgMembersPanel.tsx +10 -8
- package/src/iam-policy/PeopleWithAccess.tsx +3 -3
- package/src/iam-policy/PrincipalPicker.tsx +3 -3
- package/src/iam-policy/SharePanel.tsx +4 -4
- package/src/iam-policy/useCheckPermission.ts +4 -1
- package/src/iam-policy/useCreateIamPolicy.ts +1 -1
- package/src/iam-policy/useDeleteIamPolicy.ts +1 -1
- package/src/iam-policy/useGrantableRoles.ts +1 -1
- package/src/iam-policy/useGranteeCandidates.ts +3 -3
- package/src/iam-policy/useOwnerAssignment.ts +3 -3
- package/src/iam-policy/usePrincipalsCount.ts +7 -7
- package/src/iam-policy/useResourceAccess.ts +1 -1
- package/src/iam-policy/useRevokeOrgAccess.ts +13 -11
- package/src/identity-account/AccountPreferencesPanel.tsx +60 -13
- package/src/identity-account/useAccountExecutionDefaults.ts +2 -5
- package/src/identity-provider/IdentityProviderDetailPanel.tsx +3 -9
- package/src/identity-provider/IdentityProviderListPanel.tsx +4 -4
- package/src/identity-provider/IdentityProviderWizard.tsx +1 -1
- package/src/identity-provider/SsoLoginPrompt.tsx +6 -5
- package/src/identity-provider/useIdentityProviderList.ts +2 -2
- package/src/index.ts +10 -5
- package/src/inline-edit/InlineEditImage.tsx +13 -11
- package/src/inline-edit/InlineEditText.tsx +13 -11
- package/src/inline-edit/InlineEditTextarea.tsx +12 -16
- package/src/inline-edit/useInlineDraft.ts +85 -0
- package/src/internal/DialogShell.tsx +80 -3
- package/src/internal/LoadingRegion.tsx +46 -0
- package/src/internal/UnknownPublicAddressNotice.tsx +31 -0
- package/src/internal/features.ts +2 -2
- package/src/internal/loading-region-markup.json +71 -0
- package/src/internal/markdown-components.tsx +15 -4
- package/src/internal/trim.ts +10 -0
- package/src/invitation/InvitationManager.tsx +4 -4
- package/src/invitation/InvitationRedemption.tsx +7 -7
- package/src/invitation/useInvitationPreview.ts +1 -1
- package/src/library/InstanceVisibilitySelector.tsx +1 -1
- package/src/library/ResourceVisibilityControl.tsx +7 -4
- package/src/library/VisibilitySelector.tsx +2 -2
- package/src/licenses/LicenseDetail.tsx +8 -6
- package/src/licenses/LicenseIssueForm.tsx +7 -7
- package/src/licenses/license-draft.ts +4 -4
- package/src/licenses/license-format.ts +12 -8
- package/src/mcp-server/McpServerConnectDialog.tsx +4 -6
- package/src/mcp-server/McpServerDetailView.tsx +7 -10
- package/src/mcp-server/McpServerPicker.tsx +2 -12
- package/src/mcp-server/McpToolSelector.tsx +1 -1
- package/src/mcp-server/useMcpServerConnect.ts +14 -33
- package/src/mcp-server/useMcpServerOAuthConnect.ts +7 -23
- package/src/memory/MemoryListPanel.tsx +4 -4
- package/src/models/HarnessSelector.tsx +1 -3
- package/src/models/ModelSelector.tsx +2 -7
- package/src/models/harness.ts +41 -39
- package/src/models/index.ts +1 -1
- package/src/oauth-app/OAuthAppListPanel.tsx +4 -4
- package/src/organization/OrgPreferencesPanel.tsx +28 -10
- package/src/organization/OrgProfilePanel.tsx +12 -12
- package/src/organization/index.ts +1 -0
- package/src/organization/useFollowSessionOrganization.ts +54 -0
- package/src/plan-catalog/plan-draft.ts +3 -3
- package/src/platform-client/PlatformClientListPanel.tsx +4 -4
- package/src/plugin/PluginDetailView.tsx +3 -2
- package/src/plugin/useMcpServerReadiness.ts +2 -2
- package/src/portal-container.ts +8 -0
- package/src/provider-standing/ProviderStandingConsole.tsx +1 -1
- package/src/provider.tsx +60 -27
- package/src/public-base-url-context.ts +71 -0
- package/src/resource-workbench/components/SelectionCheckbox.tsx +1 -1
- package/src/schedule/ScheduleDetailView.tsx +4 -4
- package/src/session/SessionViewer.tsx +13 -3
- package/src/session/useLocalSessionWorker.ts +35 -4
- package/src/session/useSessionConversation.ts +14 -3
- package/src/settings/ChannelAppsSection.tsx +4 -4
- package/src/settings/EnvironmentsSection.tsx +3 -2
- package/src/settings/MembersSection.tsx +3 -3
- package/src/settings/OrgPreferencesSection.tsx +1 -1
- package/src/settings/OrgProfileSection.tsx +1 -1
- package/src/settings/ProviderKeysSection.tsx +4 -0
- package/src/settings/TeamsSection.tsx +1 -1
- package/src/settings/UsageSection.tsx +1 -1
- package/src/settings/index.ts +2 -0
- package/src/settings/settings-nav.ts +2 -0
- package/src/sharing/ShareAgentDialog.tsx +32 -15
- package/src/sharing/SharedAgentChat.tsx +4 -4
- package/src/sharing/useCanCreateAgentShare.ts +6 -4
- package/src/sharing/useSaveAgentShare.ts +1 -1
- package/src/sidebar/WorkspaceSidebar.tsx +3 -2
- package/src/skill/SkillDetailView.tsx +4 -4
- package/src/skill/SkillDiffDialog.tsx +4 -4
- package/src/skill/SkillFileBrowser.tsx +4 -4
- package/src/styles.css +14 -4
- package/src/team/TeamDetailPanel.tsx +3 -3
- package/src/team/TeamListPanel.tsx +3 -2
- package/src/team/TeamMembersPanel.tsx +3 -3
- package/src/usage/OrgUsagePanel.tsx +9 -9
- package/src/usage/useExportCSV.ts +9 -9
- package/src/usage/useOrgUsageReport.ts +7 -7
- package/src/version-history/VersionTimeline.tsx +4 -4
- package/src/workflow/WorkflowTaskApprovalSummary.tsx +14 -7
- package/src/workflow/WorkflowVersionDiffViewer.tsx +4 -4
- package/src/workflow/WorkflowVersionTimeline.tsx +4 -4
- package/src/workflow/inspector/tabs/BranchesTab.tsx +2 -2
- package/src/workflow/inspector/tabs/CatchTab.tsx +1 -1
- package/src/workflow/inspector/tabs/IterationTab.tsx +1 -1
- package/src/workflow/instance/WorkflowInstanceDetailPanel.tsx +7 -6
- package/src/workflow/task-detail/task-approval.ts +20 -13
- package/src/workflow/useDiagnoseExecutionFlow.ts +23 -18
- package/src/workflow/useExplainWorkflowFlow.ts +7 -3
- package/src/workflow/useRefineWorkflowFlow.ts +17 -10
- package/src/workflow/useWorkflowArchitectFlow.ts +7 -3
- package/src/workspace/ExplorerTree.tsx +4 -8
- package/src/workspace/FileViewer.tsx +4 -5
- package/styles.css +1 -1
- package/team/TeamDetailPanel.d.ts +2 -2
- package/team/TeamDetailPanel.d.ts.map +1 -1
- package/team/TeamDetailPanel.js +2 -2
- package/team/TeamDetailPanel.js.map +1 -1
- package/team/TeamListPanel.d.ts.map +1 -1
- package/team/TeamListPanel.js +2 -1
- package/team/TeamListPanel.js.map +1 -1
- package/team/TeamMembersPanel.d.ts +2 -2
- package/team/TeamMembersPanel.d.ts.map +1 -1
- package/team/TeamMembersPanel.js +2 -2
- package/team/TeamMembersPanel.js.map +1 -1
- package/usage/OrgUsagePanel.d.ts +3 -3
- package/usage/OrgUsagePanel.d.ts.map +1 -1
- package/usage/OrgUsagePanel.js +6 -5
- package/usage/OrgUsagePanel.js.map +1 -1
- package/usage/useExportCSV.d.ts +2 -2
- package/usage/useExportCSV.d.ts.map +1 -1
- package/usage/useExportCSV.js +9 -9
- package/usage/useExportCSV.js.map +1 -1
- package/usage/useOrgUsageReport.d.ts +4 -4
- package/usage/useOrgUsageReport.d.ts.map +1 -1
- package/usage/useOrgUsageReport.js +7 -7
- package/usage/useOrgUsageReport.js.map +1 -1
- package/version-history/VersionTimeline.d.ts.map +1 -1
- package/version-history/VersionTimeline.js +2 -1
- package/version-history/VersionTimeline.js.map +1 -1
- package/workflow/WorkflowTaskApprovalSummary.d.ts +7 -4
- package/workflow/WorkflowTaskApprovalSummary.d.ts.map +1 -1
- package/workflow/WorkflowTaskApprovalSummary.js +8 -3
- package/workflow/WorkflowTaskApprovalSummary.js.map +1 -1
- package/workflow/WorkflowVersionDiffViewer.d.ts.map +1 -1
- package/workflow/WorkflowVersionDiffViewer.js +2 -1
- package/workflow/WorkflowVersionDiffViewer.js.map +1 -1
- package/workflow/WorkflowVersionTimeline.d.ts.map +1 -1
- package/workflow/WorkflowVersionTimeline.js +2 -1
- package/workflow/WorkflowVersionTimeline.js.map +1 -1
- package/workflow/inspector/tabs/BranchesTab.js +1 -1
- package/workflow/inspector/tabs/BranchesTab.js.map +1 -1
- package/workflow/inspector/tabs/CatchTab.js +1 -1
- package/workflow/inspector/tabs/CatchTab.js.map +1 -1
- package/workflow/inspector/tabs/IterationTab.js +1 -1
- package/workflow/inspector/tabs/IterationTab.js.map +1 -1
- package/workflow/instance/WorkflowInstanceDetailPanel.d.ts.map +1 -1
- package/workflow/instance/WorkflowInstanceDetailPanel.js +6 -5
- package/workflow/instance/WorkflowInstanceDetailPanel.js.map +1 -1
- package/workflow/task-detail/task-approval.d.ts +13 -11
- package/workflow/task-detail/task-approval.d.ts.map +1 -1
- package/workflow/task-detail/task-approval.js +8 -4
- package/workflow/task-detail/task-approval.js.map +1 -1
- package/workflow/useDiagnoseExecutionFlow.d.ts.map +1 -1
- package/workflow/useDiagnoseExecutionFlow.js +23 -18
- package/workflow/useDiagnoseExecutionFlow.js.map +1 -1
- package/workflow/useExplainWorkflowFlow.d.ts.map +1 -1
- package/workflow/useExplainWorkflowFlow.js +7 -3
- package/workflow/useExplainWorkflowFlow.js.map +1 -1
- package/workflow/useRefineWorkflowFlow.d.ts.map +1 -1
- package/workflow/useRefineWorkflowFlow.js +14 -10
- package/workflow/useRefineWorkflowFlow.js.map +1 -1
- package/workflow/useWorkflowArchitectFlow.d.ts.map +1 -1
- package/workflow/useWorkflowArchitectFlow.js +7 -3
- package/workflow/useWorkflowArchitectFlow.js.map +1 -1
- package/workspace/ExplorerTree.d.ts.map +1 -1
- package/workspace/ExplorerTree.js +2 -5
- package/workspace/ExplorerTree.js.map +1 -1
- package/workspace/FileViewer.d.ts.map +1 -1
- package/workspace/FileViewer.js +2 -1
- package/workspace/FileViewer.js.map +1 -1
package/src/provider.tsx
CHANGED
|
@@ -15,6 +15,7 @@ import { StigmerContext } from "./context.js";
|
|
|
15
15
|
import { DeploymentModeContext } from "./deployment-mode.js";
|
|
16
16
|
import { ExecutionTargetContext } from "./execution-target-context.js";
|
|
17
17
|
import { ApprovalDefaultsContext } from "./approval-defaults-context.js";
|
|
18
|
+
import { PublicBaseUrlContext } from "./public-base-url-context.js";
|
|
18
19
|
import type { ApprovalDefaults } from "./approval-defaults-context.js";
|
|
19
20
|
import type { ExecutionTargetOption } from "./session/execution-target.js";
|
|
20
21
|
import type { RunnerAdapter } from "./runner-adapter.js";
|
|
@@ -121,6 +122,32 @@ export interface StigmerProviderProps {
|
|
|
121
122
|
* ```
|
|
122
123
|
*/
|
|
123
124
|
readonly approvalDefaults?: ApprovalDefaults;
|
|
125
|
+
/**
|
|
126
|
+
* The address the Stigmer API is reached at from outside this page, for
|
|
127
|
+
* the URLs the SDK shows a user to copy (the Slack and WhatsApp webhook
|
|
128
|
+
* URLs a channel app registers, and the platform client snippet in the
|
|
129
|
+
* Share dialog). A session's MCP servers get their
|
|
130
|
+
* `STIGMER_SERVER_ADDRESS` from the platform, never from this value.
|
|
131
|
+
*
|
|
132
|
+
* Omit it when the client's `baseUrl` is absolute: that address is used,
|
|
133
|
+
* exactly as before. Pass it when the client talks to the server through
|
|
134
|
+
* a relative `baseUrl` (a same-origin proxy), because the page's own
|
|
135
|
+
* origin need not be where Slack, Meta, a backend or a remote MCP server
|
|
136
|
+
* can reach the API. Without it, the copy surfaces say they do not know
|
|
137
|
+
* the server's public address and offer nothing to copy. Only an
|
|
138
|
+
* absolute `http(s)` URL is used.
|
|
139
|
+
*
|
|
140
|
+
* @example
|
|
141
|
+
* ```tsx
|
|
142
|
+
* // The browser reaches the API through the page's own origin
|
|
143
|
+
* const client = new Stigmer({ baseUrl: "/", getAccessToken });
|
|
144
|
+
*
|
|
145
|
+
* <StigmerProvider client={client} publicBaseUrl="https://api.example.com">
|
|
146
|
+
* <App />
|
|
147
|
+
* </StigmerProvider>
|
|
148
|
+
* ```
|
|
149
|
+
*/
|
|
150
|
+
readonly publicBaseUrl?: string;
|
|
124
151
|
/**
|
|
125
152
|
* Built-in theme preset to apply.
|
|
126
153
|
*
|
|
@@ -258,7 +285,10 @@ const EMPTY_REVIEW_RENDERERS: ReviewRenderers = {};
|
|
|
258
285
|
* Two stable selector hooks are part of the public contract:
|
|
259
286
|
* `data-stgm-root` marks the in-tree container (and only it);
|
|
260
287
|
* `data-stgm-portal` marks the portal container appended to
|
|
261
|
-
* `document.body` for portaled surfaces.
|
|
288
|
+
* `document.body` for portaled surfaces. A popup opened inside an SDK
|
|
289
|
+
* modal dialog renders inside that dialog instead (the browser's top
|
|
290
|
+
* layer would otherwise cover it), so it is not under
|
|
291
|
+
* `[data-stgm-portal]`.
|
|
262
292
|
*
|
|
263
293
|
* The `colorMode` prop controls dark/light appearance via a
|
|
264
294
|
* `data-stgm-color-mode` attribute on the scoping container.
|
|
@@ -288,6 +318,7 @@ export function StigmerProvider({
|
|
|
288
318
|
executionTarget,
|
|
289
319
|
runnerAdapter,
|
|
290
320
|
approvalDefaults,
|
|
321
|
+
publicBaseUrl,
|
|
291
322
|
preset,
|
|
292
323
|
className,
|
|
293
324
|
colorMode = "light",
|
|
@@ -310,32 +341,34 @@ export function StigmerProvider({
|
|
|
310
341
|
<ExecutionTargetContext.Provider value={executionTarget}>
|
|
311
342
|
<ApprovalDefaultsContext.Provider value={approvalDefaults}>
|
|
312
343
|
<RunnerAdapterContext.Provider value={runnerAdapter ?? null}>
|
|
313
|
-
<
|
|
314
|
-
<
|
|
315
|
-
<
|
|
316
|
-
<
|
|
317
|
-
<
|
|
318
|
-
{
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
344
|
+
<PublicBaseUrlContext.Provider value={publicBaseUrl}>
|
|
345
|
+
<ColorModeContext.Provider value={resolvedMode}>
|
|
346
|
+
<ModelRegistryContext.Provider value={registryState}>
|
|
347
|
+
<TaskKindRegistryContext.Provider value={taskKindRegistryState}>
|
|
348
|
+
<ReviewRendererContext.Provider value={reviewRenderers ?? EMPTY_REVIEW_RENDERERS}>
|
|
349
|
+
<PortalContainerContext.Provider value={portalContainer}>
|
|
350
|
+
{/*
|
|
351
|
+
The in-tree scoping container. `data-stgm-root` is a
|
|
352
|
+
stable public selector — the documented seam for hosts
|
|
353
|
+
to style THIS element only (e.g. the fixed-height
|
|
354
|
+
embedding recipe, #260). It must never be mirrored
|
|
355
|
+
onto the portal container, whose own `data-stgm-portal`
|
|
356
|
+
marker keeps host in-tree-only CSS away from the
|
|
357
|
+
off-tree element.
|
|
358
|
+
*/}
|
|
359
|
+
<div
|
|
360
|
+
className={scope.className}
|
|
361
|
+
data-stgm-root=""
|
|
362
|
+
data-stgm-color-mode={scope.colorMode}
|
|
363
|
+
>
|
|
364
|
+
{children}
|
|
365
|
+
</div>
|
|
366
|
+
</PortalContainerContext.Provider>
|
|
367
|
+
</ReviewRendererContext.Provider>
|
|
368
|
+
</TaskKindRegistryContext.Provider>
|
|
369
|
+
</ModelRegistryContext.Provider>
|
|
370
|
+
</ColorModeContext.Provider>
|
|
371
|
+
</PublicBaseUrlContext.Provider>
|
|
339
372
|
</RunnerAdapterContext.Provider>
|
|
340
373
|
</ApprovalDefaultsContext.Provider>
|
|
341
374
|
</ExecutionTargetContext.Provider>
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { createContext, useContext } from "react";
|
|
4
|
+
import { useStigmer } from "./hooks.js";
|
|
5
|
+
import { trimTrailing } from "./internal/trim.js";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* React context for the server's public base URL: the address the Stigmer
|
|
9
|
+
* API is reached at from outside the page, supplied by the host through
|
|
10
|
+
* `StigmerProvider`'s `publicBaseUrl`.
|
|
11
|
+
*
|
|
12
|
+
* Separated from the provider to mirror the `ExecutionTargetContext`
|
|
13
|
+
* pattern and avoid circular imports.
|
|
14
|
+
*
|
|
15
|
+
* `undefined` means the host named no public address; the client's own
|
|
16
|
+
* `baseUrl` then stands in when it is absolute.
|
|
17
|
+
*/
|
|
18
|
+
export const PublicBaseUrlContext = createContext<string | undefined>(
|
|
19
|
+
undefined,
|
|
20
|
+
);
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* The server's public base URL for URLs the SDK shows a user to copy (a
|
|
24
|
+
* webhook URL pasted into Slack or Meta, a platform client snippet run by
|
|
25
|
+
* a backend), or `null` when it cannot be known.
|
|
26
|
+
*
|
|
27
|
+
* The host owns public addresses, and the SDK never guesses one (the
|
|
28
|
+
* `buildShareUrl` precedent in `ShareAgentDialog`): the provider's
|
|
29
|
+
* `publicBaseUrl` wins, the client's `baseUrl` stands in for it, and only
|
|
30
|
+
* an absolute `http(s)` URL counts. A relative `baseUrl` (a same-origin
|
|
31
|
+
* proxy, the documentation tours) with no `publicBaseUrl` answers `null`,
|
|
32
|
+
* because the page's own origin need not be where the API is reached from
|
|
33
|
+
* outside; the surface then says the address is unknown instead of offering
|
|
34
|
+
* one nobody can call. A `publicBaseUrl` that is not absolute is a host
|
|
35
|
+
* mistake and counts for nothing. Trailing slashes are trimmed.
|
|
36
|
+
*/
|
|
37
|
+
export function usePublicBaseUrl(): string | null {
|
|
38
|
+
const hostPublicBaseUrl = useContext(PublicBaseUrlContext);
|
|
39
|
+
const { baseUrl } = useStigmer();
|
|
40
|
+
return resolvePublicBaseUrl(hostPublicBaseUrl, baseUrl);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* The pure rule behind {@link usePublicBaseUrl}: the first of the host's
|
|
45
|
+
* public base URL and the client's base URL that is an absolute `http(s)` URL,
|
|
46
|
+
* trailing slashes trimmed, or `null` when neither is.
|
|
47
|
+
*/
|
|
48
|
+
export function resolvePublicBaseUrl(
|
|
49
|
+
hostPublicBaseUrl: string | undefined,
|
|
50
|
+
clientBaseUrl: string,
|
|
51
|
+
): string | null {
|
|
52
|
+
for (const candidate of [hostPublicBaseUrl, clientBaseUrl]) {
|
|
53
|
+
if (candidate !== undefined && isAbsoluteUrl(candidate)) {
|
|
54
|
+
return trimTrailing(candidate, "/");
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
return null;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* Whether `value` is an absolute `http(s)` URL. The protocol check matters:
|
|
62
|
+
* `new URL("localhost:7234")` parses, with `localhost:` as its scheme.
|
|
63
|
+
*/
|
|
64
|
+
function isAbsoluteUrl(value: string): boolean {
|
|
65
|
+
try {
|
|
66
|
+
const { protocol } = new URL(value);
|
|
67
|
+
return protocol === "http:" || protocol === "https:";
|
|
68
|
+
} catch {
|
|
69
|
+
return false;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
@@ -43,7 +43,7 @@ export function SelectionCheckbox({
|
|
|
43
43
|
onChange={(e) => onChange(e.target.checked)}
|
|
44
44
|
aria-label={ariaLabel}
|
|
45
45
|
className={cn(
|
|
46
|
-
"stg:size-3.5 stg:shrink-0 stg:cursor-pointer stg:rounded stg:border stg:border-input
|
|
46
|
+
"stg:size-3.5 stg:shrink-0 stg:cursor-pointer stg:rounded stg:border stg:border-input",
|
|
47
47
|
"stg:focus-visible:outline-none stg:focus-visible:ring-2 stg:focus-visible:ring-ring stg:focus-visible:ring-offset-1",
|
|
48
48
|
className,
|
|
49
49
|
)}
|
|
@@ -78,6 +78,7 @@ import { useSetScheduleEnabled } from "./useSetScheduleEnabled.js";
|
|
|
78
78
|
import { useTriggerSchedule } from "./useTriggerSchedule.js";
|
|
79
79
|
import { useUpdateScheduleSpec } from "./useUpdateScheduleSpec.js";
|
|
80
80
|
import { SpinnerIcon } from "../internal/SpinnerIcon.js";
|
|
81
|
+
import { LoadingRegion } from "../internal/LoadingRegion.js";
|
|
81
82
|
|
|
82
83
|
/** Props for {@link ScheduleDetailView}. */
|
|
83
84
|
export interface ScheduleDetailViewProps {
|
|
@@ -1552,10 +1553,9 @@ function ReferenceLink({
|
|
|
1552
1553
|
|
|
1553
1554
|
function LoadingSkeleton({ className }: { readonly className?: string }) {
|
|
1554
1555
|
return (
|
|
1555
|
-
<
|
|
1556
|
+
<LoadingRegion
|
|
1556
1557
|
className={cn("stg:flex stg:flex-col stg:gap-6", className)}
|
|
1557
|
-
|
|
1558
|
-
aria-label="Loading schedule details"
|
|
1558
|
+
label="Loading schedule details"
|
|
1559
1559
|
>
|
|
1560
1560
|
<div className="stg:flex stg:items-start stg:gap-3">
|
|
1561
1561
|
<div className="stg:mt-1 stg:size-6 stg:shrink-0 stg:animate-pulse stg:rounded stg:bg-muted" />
|
|
@@ -1578,7 +1578,7 @@ function LoadingSkeleton({ className }: { readonly className?: string }) {
|
|
|
1578
1578
|
style={{ height: "160px" }}
|
|
1579
1579
|
/>
|
|
1580
1580
|
</div>
|
|
1581
|
-
</
|
|
1581
|
+
</LoadingRegion>
|
|
1582
1582
|
);
|
|
1583
1583
|
}
|
|
1584
1584
|
|
|
@@ -144,7 +144,12 @@ const CONVERSATION_COLUMN_CLASS = "stg:mx-auto stg:w-full stg:max-w-3xl";
|
|
|
144
144
|
export interface SessionViewerProps {
|
|
145
145
|
/** Session ID to load and display. */
|
|
146
146
|
readonly sessionId: string;
|
|
147
|
-
/**
|
|
147
|
+
/**
|
|
148
|
+
* Organization slug to act in until the session has loaded. After that
|
|
149
|
+
* the viewer acts in the session's own organization (`session.metadata.org`),
|
|
150
|
+
* whatever this prop says: a turn in a session belongs to that session's
|
|
151
|
+
* organization.
|
|
152
|
+
*/
|
|
148
153
|
readonly org: string;
|
|
149
154
|
/**
|
|
150
155
|
* GitHub connection state. Platform-specific — web passes
|
|
@@ -384,7 +389,7 @@ export interface SessionViewerProps {
|
|
|
384
389
|
*/
|
|
385
390
|
export function SessionViewer({
|
|
386
391
|
sessionId,
|
|
387
|
-
org,
|
|
392
|
+
org: orgProp,
|
|
388
393
|
gitHubConnection,
|
|
389
394
|
enableGitHub = true,
|
|
390
395
|
enableLocal = false,
|
|
@@ -410,13 +415,18 @@ export function SessionViewer({
|
|
|
410
415
|
}: SessionViewerProps) {
|
|
411
416
|
const flow = useSessionPageFlow({
|
|
412
417
|
sessionId,
|
|
413
|
-
org,
|
|
418
|
+
org: orgProp,
|
|
414
419
|
getRuntimeEnv,
|
|
415
420
|
audience,
|
|
416
421
|
runConfig,
|
|
417
422
|
accountDefaults,
|
|
418
423
|
});
|
|
419
424
|
const { conv } = flow;
|
|
425
|
+
// Everything org-scoped below acts in the session's own organization once
|
|
426
|
+
// it has loaded (the pickers, artifacts, plan actions and the reply), so a
|
|
427
|
+
// session opened while another organization is active never files its
|
|
428
|
+
// turns there (stigmer/stigmer#1580).
|
|
429
|
+
const org = conv.org;
|
|
420
430
|
const isGuest = audience === "guest";
|
|
421
431
|
// A pinned model makes the picker a dead control (the pin wins over any
|
|
422
432
|
// choice it could offer), so the pin forces it hidden; the guest strip
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
import { useEffect, useMemo } from "react";
|
|
4
4
|
import type { Session } from "@stigmer/protos/ai/stigmer/agentic/session/v1/api_pb";
|
|
5
5
|
import { ExecutionTarget } from "@stigmer/protos/ai/stigmer/agentic/session/v1/enum_pb";
|
|
6
|
+
import { useWhoAmI } from "../iam-policy/useWhoAmI.js";
|
|
6
7
|
import { useRunnerAdapter } from "../runner-adapter.js";
|
|
7
8
|
import { useExecutionTarget } from "../execution-target-context.js";
|
|
8
9
|
import { fromProtoExecutionTarget } from "./execution-target.js";
|
|
@@ -25,12 +26,28 @@ import { fromProtoExecutionTarget } from "./execution-target.js";
|
|
|
25
26
|
* free. It is a no-op unless a `runnerAdapter` is configured **and** the
|
|
26
27
|
* session resolves to local execution (cloud sessions are server-provisioned).
|
|
27
28
|
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
29
|
+
* **Only the session's own person serves it.** Anyone a session is shared
|
|
30
|
+
* with can open it, and every desktop that attached would poll the same
|
|
31
|
+
* queue, each turn going to whichever worker asks first. A server with
|
|
32
|
+
* sign-in credentials a local session's runner for the person who created
|
|
33
|
+
* the session, so another viewer's desktop would take turns it cannot run
|
|
34
|
+
* (or, where it could, run someone else's turn on its own machine). The
|
|
35
|
+
* worker is therefore kept off exactly when the signed-in account is known
|
|
36
|
+
* and is not the session's creator — the creator stamp read the two ways
|
|
37
|
+
* the server reads it, as the account id and as the account's identity
|
|
38
|
+
* provider subject. Every other case attaches as before: while the account
|
|
39
|
+
* is loading the attach waits (as it waits for the session), and when there
|
|
40
|
+
* is no account (a single-user server answers `whoAmI` NOT_FOUND, and every
|
|
41
|
+
* session there is its operator's) the desktop serves the session.
|
|
42
|
+
*
|
|
43
|
+
* The effect depends only on stable primitives (`adapter`, `sessionId`, the
|
|
44
|
+
* derived `effectiveTarget` string and the derived `servesHere` flag) and
|
|
45
|
+
* **never on the `session` object**.
|
|
30
46
|
* `useSessionConversation` refetches the session frequently; keying the effect
|
|
31
47
|
* on the object would tear down and restart the worker on every refetch
|
|
32
48
|
* (DD-010 / reference-stability). `executionTarget` is immutable after the
|
|
33
|
-
* first execution,
|
|
49
|
+
* first execution, and a session's creator never changes, so both derived
|
|
50
|
+
* values stay stable across refetches.
|
|
34
51
|
*
|
|
35
52
|
* @param sessionId - The session being viewed, or `null` to skip.
|
|
36
53
|
* @param session - The loaded session, or `null` while loading. The worker is
|
|
@@ -43,6 +60,7 @@ export function useLocalSessionWorker(
|
|
|
43
60
|
): void {
|
|
44
61
|
const adapter = useRunnerAdapter();
|
|
45
62
|
const contextTarget = useExecutionTarget();
|
|
63
|
+
const { account, isLoading: accountLoading } = useWhoAmI();
|
|
46
64
|
|
|
47
65
|
// Resolve the session's effective execution target as a stable primitive.
|
|
48
66
|
// `undefined` until the session loads — so we never attach a local worker
|
|
@@ -59,8 +77,21 @@ export function useLocalSessionWorker(
|
|
|
59
77
|
);
|
|
60
78
|
}, [isLoaded, specTarget, contextTarget]);
|
|
61
79
|
|
|
80
|
+
// Whether this viewer's desktop may serve the session, as a stable
|
|
81
|
+
// primitive: `undefined` while the account is loading, `true` when there
|
|
82
|
+
// is no account to compare or the account is the session's creator.
|
|
83
|
+
const creatorStamp = session?.status?.audit?.specAudit?.createdBy?.id ?? "";
|
|
84
|
+
const accountId = account?.metadata?.id ?? "";
|
|
85
|
+
const accountSubject = account?.spec?.idpId ?? "";
|
|
86
|
+
const servesHere = useMemo(() => {
|
|
87
|
+
if (accountLoading) return undefined;
|
|
88
|
+
if (accountId === "" || creatorStamp === "") return true;
|
|
89
|
+
return creatorStamp === accountId || creatorStamp === accountSubject;
|
|
90
|
+
}, [accountLoading, accountId, accountSubject, creatorStamp]);
|
|
91
|
+
|
|
62
92
|
useEffect(() => {
|
|
63
93
|
if (!adapter || !sessionId || effectiveTarget !== "local") return;
|
|
94
|
+
if (servesHere !== true) return;
|
|
64
95
|
|
|
65
96
|
// Fire-and-forget: a runner-start failure must not crash the session view.
|
|
66
97
|
// The host adapter's add/remove are idempotent, so React's cleanup-driven
|
|
@@ -69,5 +100,5 @@ export function useLocalSessionWorker(
|
|
|
69
100
|
return () => {
|
|
70
101
|
adapter.onSessionClosed(sessionId).catch(() => {});
|
|
71
102
|
};
|
|
72
|
-
}, [adapter, sessionId, effectiveTarget]);
|
|
103
|
+
}, [adapter, sessionId, effectiveTarget, servesHere]);
|
|
73
104
|
}
|
|
@@ -161,6 +161,15 @@ export interface SendFollowUpOptions {
|
|
|
161
161
|
export interface UseSessionConversationReturn {
|
|
162
162
|
/** The session object, or null while loading. */
|
|
163
163
|
readonly session: Session | null;
|
|
164
|
+
/**
|
|
165
|
+
* The organization this conversation's turns are filed under: the
|
|
166
|
+
* session's own (`session.metadata.org`) once it has loaded, the `org`
|
|
167
|
+
* argument until then. A turn in a session belongs to that session's
|
|
168
|
+
* organization, and the server refuses any other (stigmer/stigmer#1580),
|
|
169
|
+
* so every org-scoped control of a session surface reads this value
|
|
170
|
+
* rather than the caller's active organization.
|
|
171
|
+
*/
|
|
172
|
+
readonly org: string;
|
|
164
173
|
/**
|
|
165
174
|
* Executions in terminal phases, in chronological order.
|
|
166
175
|
*
|
|
@@ -373,7 +382,7 @@ export interface UseSessionConversationReturn {
|
|
|
373
382
|
* locally, so it is safe in every environment.
|
|
374
383
|
*
|
|
375
384
|
* @param sessionId - Session to display and converse in. Pass `null` to skip.
|
|
376
|
-
* @param org - Organization slug
|
|
385
|
+
* @param org - Organization slug to act in until the session has loaded; after that the session's own organization is used (the returned `org`).
|
|
377
386
|
*
|
|
378
387
|
* @example
|
|
379
388
|
* ```tsx
|
|
@@ -433,6 +442,7 @@ export function useSessionConversation(
|
|
|
433
442
|
clearError: clearCreateError,
|
|
434
443
|
} = useCreateAgentExecution();
|
|
435
444
|
const { update: updateSession } = useUpdateSession();
|
|
445
|
+
const turnOrg = session?.metadata?.org || org;
|
|
436
446
|
const {
|
|
437
447
|
submitApproval: rawSubmitApproval,
|
|
438
448
|
submittingToolCallIds,
|
|
@@ -667,7 +677,7 @@ export function useSessionConversation(
|
|
|
667
677
|
}
|
|
668
678
|
|
|
669
679
|
const result = await create({
|
|
670
|
-
org,
|
|
680
|
+
org: turnOrg,
|
|
671
681
|
sessionId,
|
|
672
682
|
message,
|
|
673
683
|
modelName: options?.modelName,
|
|
@@ -698,7 +708,7 @@ export function useSessionConversation(
|
|
|
698
708
|
}
|
|
699
709
|
}
|
|
700
710
|
},
|
|
701
|
-
[sessionId, session,
|
|
711
|
+
[sessionId, session, turnOrg, stigmer, create, updateSession, refetch, refetchSession],
|
|
702
712
|
);
|
|
703
713
|
|
|
704
714
|
const retryLastSend = useCallback(() => {
|
|
@@ -763,6 +773,7 @@ export function useSessionConversation(
|
|
|
763
773
|
|
|
764
774
|
return {
|
|
765
775
|
session,
|
|
776
|
+
org: turnOrg,
|
|
766
777
|
completedExecutions,
|
|
767
778
|
activeStreamExecution,
|
|
768
779
|
activePhase,
|
|
@@ -41,10 +41,10 @@ type FlowState =
|
|
|
41
41
|
*
|
|
42
42
|
* "New channel app" is offered once the server confirms the caller holds
|
|
43
43
|
* `can_create_channel_app` on the organization. The list shows only the
|
|
44
|
-
* apps the caller may view (
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
44
|
+
* apps the caller may view (the organization's admins, and anyone granted
|
|
45
|
+
* viewer on an app), so a caller who may not create channel apps is told
|
|
46
|
+
* that the organization's admins manage them rather than that none is
|
|
47
|
+
* registered.
|
|
48
48
|
*/
|
|
49
49
|
export function ChannelAppsSection() {
|
|
50
50
|
const headingId = useId();
|
|
@@ -7,6 +7,7 @@ import { EnvironmentVariableEditor } from "../environment/EnvironmentVariableEdi
|
|
|
7
7
|
import { EnvironmentListPanel } from "../environment/EnvironmentListPanel.js";
|
|
8
8
|
import { CreateEnvironmentForm } from "../environment/CreateEnvironmentForm.js";
|
|
9
9
|
import { useActiveOrgSlug } from "../organization/OrgProvider.js";
|
|
10
|
+
import { LoadingRegion } from "../internal/LoadingRegion.js";
|
|
10
11
|
|
|
11
12
|
const ENV_EXCLUDE_LABELS: Record<string, string>[] = [
|
|
12
13
|
{ "stigmer.ai/personal": "true" },
|
|
@@ -152,7 +153,7 @@ function EnvironmentsCard({ org }: { org: string }) {
|
|
|
152
153
|
|
|
153
154
|
function SkeletonRows({ count }: { count: number }) {
|
|
154
155
|
return (
|
|
155
|
-
<
|
|
156
|
+
<LoadingRegion className="stg:space-y-2" label="Loading">
|
|
156
157
|
{Array.from({ length: count }, (_, i) => (
|
|
157
158
|
<div
|
|
158
159
|
key={i}
|
|
@@ -160,6 +161,6 @@ function SkeletonRows({ count }: { count: number }) {
|
|
|
160
161
|
style={{ width: `${85 - i * 10}%` }}
|
|
161
162
|
/>
|
|
162
163
|
))}
|
|
163
|
-
</
|
|
164
|
+
</LoadingRegion>
|
|
164
165
|
);
|
|
165
166
|
}
|
|
@@ -24,7 +24,7 @@ export function MembersSection() {
|
|
|
24
24
|
ApiResourceKind.invitation,
|
|
25
25
|
);
|
|
26
26
|
const idpAvailable = useResourceAvailable(ApiResourceKind.identity_provider);
|
|
27
|
-
const
|
|
27
|
+
const org = activeOrg?.metadata?.id ?? "";
|
|
28
28
|
const orgSlug = activeOrg?.metadata?.slug ?? "";
|
|
29
29
|
|
|
30
30
|
const { identityProviders } = useIdentityProviderList(
|
|
@@ -57,7 +57,7 @@ export function MembersSection() {
|
|
|
57
57
|
)}
|
|
58
58
|
</p>
|
|
59
59
|
|
|
60
|
-
{!
|
|
60
|
+
{!org ? (
|
|
61
61
|
<p className="stg:text-muted-foreground stg:py-4 stg:text-center stg:text-xs">
|
|
62
62
|
Select an organization to manage members.
|
|
63
63
|
</p>
|
|
@@ -72,7 +72,7 @@ export function MembersSection() {
|
|
|
72
72
|
</p>
|
|
73
73
|
</div>
|
|
74
74
|
)}
|
|
75
|
-
<OrgMembersPanel
|
|
75
|
+
<OrgMembersPanel org={org} />
|
|
76
76
|
</>
|
|
77
77
|
)}
|
|
78
78
|
</section>
|
package/src/settings/index.ts
CHANGED
|
@@ -22,3 +22,5 @@ export { TeamsSection } from "./TeamsSection.js";
|
|
|
22
22
|
export { OAuthAppsSection } from "./OAuthAppsSection.js";
|
|
23
23
|
export { ChannelAppsSection } from "./ChannelAppsSection.js";
|
|
24
24
|
export { UsageSection } from "./UsageSection.js";
|
|
25
|
+
export { ProviderKeysSection } from "./ProviderKeysSection.js";
|
|
26
|
+
export type { ProviderKeysSectionProps } from "./ProviderKeysSection.js";
|
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
FileBadge,
|
|
11
11
|
Layers,
|
|
12
12
|
KeyRound,
|
|
13
|
+
KeySquare,
|
|
13
14
|
Link,
|
|
14
15
|
MessageSquare,
|
|
15
16
|
MousePointerClick,
|
|
@@ -102,6 +103,7 @@ export const SETTINGS_NAV_GROUPS: readonly SettingsNavGroup[] = [
|
|
|
102
103
|
items: [
|
|
103
104
|
{ href: "/settings/billing", label: "Billing", icon: CreditCard },
|
|
104
105
|
{ href: "/settings/usage", label: "Usage", icon: BarChart3 },
|
|
106
|
+
{ href: "/settings/provider-keys", label: "Provider keys", icon: KeySquare },
|
|
105
107
|
],
|
|
106
108
|
},
|
|
107
109
|
{
|
|
@@ -23,7 +23,8 @@ import { ApiResourceMetadataSchema } from "@stigmer/protos/ai/stigmer/commons/ap
|
|
|
23
23
|
import { Switch } from "../switch/Switch.js";
|
|
24
24
|
import { Tabs, type TabItem } from "../tabs/Tabs.js";
|
|
25
25
|
import { toast } from "../feedback/toast.js";
|
|
26
|
-
import {
|
|
26
|
+
import { usePublicBaseUrl } from "../public-base-url-context.js";
|
|
27
|
+
import { UnknownPublicAddressNotice } from "../internal/UnknownPublicAddressNotice.js";
|
|
27
28
|
import { useCopyResource } from "../resource-detail/useCopyResource.js";
|
|
28
29
|
import { useDeploymentMode } from "../deployment-mode.js";
|
|
29
30
|
import { useBillingAccount } from "../billing/useBillingAccount.js";
|
|
@@ -40,6 +41,7 @@ import {
|
|
|
40
41
|
} from "./useSaveAgentShare.js";
|
|
41
42
|
import { useRotateShareLink } from "./useRotateShareLink.js";
|
|
42
43
|
import { useShareToolReadiness } from "./useShareToolReadiness.js";
|
|
44
|
+
import { trimTrailing } from "../internal/trim.js";
|
|
43
45
|
|
|
44
46
|
/** Maximum length of each visitor message (proto: `string.max_len = 300`). */
|
|
45
47
|
const MAX_MESSAGE_LENGTH = 300;
|
|
@@ -1510,17 +1512,17 @@ function MessageField({
|
|
|
1510
1512
|
|
|
1511
1513
|
/**
|
|
1512
1514
|
* The platform client snippet, aimed at the server the console is connected
|
|
1513
|
-
* to
|
|
1514
|
-
*
|
|
1515
|
-
*
|
|
1516
|
-
* string literal.
|
|
1515
|
+
* to — a self-hosted admin copies code for their own server, not Stigmer
|
|
1516
|
+
* Cloud. `apiBaseUrl` is the server's public base URL (`usePublicBaseUrl`),
|
|
1517
|
+
* the address the channel-app webhook URLs are built from too, JSON-quoted
|
|
1518
|
+
* so the line is always a valid string literal.
|
|
1517
1519
|
*/
|
|
1518
1520
|
function buildDeveloperSnippet(
|
|
1519
1521
|
apiBaseUrl: string,
|
|
1520
1522
|
org: string,
|
|
1521
1523
|
slug: string,
|
|
1522
1524
|
): string {
|
|
1523
|
-
const baseUrl = JSON.stringify(apiBaseUrl
|
|
1525
|
+
const baseUrl = JSON.stringify(trimTrailing(apiBaseUrl, "/"));
|
|
1524
1526
|
return [
|
|
1525
1527
|
`import { createPlatformClientAuth } from "@stigmer/sdk/node";`,
|
|
1526
1528
|
``,
|
|
@@ -1544,10 +1546,14 @@ function DeveloperTab({
|
|
|
1544
1546
|
readonly org: string;
|
|
1545
1547
|
readonly slug: string;
|
|
1546
1548
|
}) {
|
|
1547
|
-
const
|
|
1549
|
+
const publicBaseUrl = usePublicBaseUrl();
|
|
1550
|
+
// `null` while the server's public address is unknown: the field says so.
|
|
1548
1551
|
const snippet = useMemo(
|
|
1549
|
-
() =>
|
|
1550
|
-
|
|
1552
|
+
() =>
|
|
1553
|
+
publicBaseUrl === null
|
|
1554
|
+
? null
|
|
1555
|
+
: buildDeveloperSnippet(publicBaseUrl, org, slug),
|
|
1556
|
+
[publicBaseUrl, org, slug],
|
|
1551
1557
|
);
|
|
1552
1558
|
|
|
1553
1559
|
return (
|
|
@@ -1557,12 +1563,23 @@ function DeveloperTab({
|
|
|
1557
1563
|
integrate this agent with the Stigmer SDK — the same runtime, full
|
|
1558
1564
|
control.
|
|
1559
1565
|
</p>
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
+
{snippet !== null ? (
|
|
1567
|
+
<CopyField
|
|
1568
|
+
label="Platform client integration"
|
|
1569
|
+
value={snippet}
|
|
1570
|
+
copyLabel="Code"
|
|
1571
|
+
multiline
|
|
1572
|
+
/>
|
|
1573
|
+
) : (
|
|
1574
|
+
<section>
|
|
1575
|
+
<h3 className="stg:text-xs stg:font-medium stg:text-muted-foreground">
|
|
1576
|
+
Platform client integration
|
|
1577
|
+
</h3>
|
|
1578
|
+
<div className="stg:mt-1.5">
|
|
1579
|
+
<UnknownPublicAddressNotice subject="the integration code" />
|
|
1580
|
+
</div>
|
|
1581
|
+
</section>
|
|
1582
|
+
)}
|
|
1566
1583
|
<a
|
|
1567
1584
|
href={PLATFORM_CLIENT_DOCS_URL}
|
|
1568
1585
|
target="_blank"
|