@lincyaw/aegis-ui 0.5.0 → 0.7.0
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 +3 -2
- package/dist/agent/ask/AskOverlay.cjs +2 -0
- package/dist/agent/ask/AskOverlay.cjs.map +1 -0
- package/dist/agent/ask/AskOverlay.js +83 -0
- package/dist/agent/ask/AskOverlay.js.map +1 -0
- package/dist/agent/ask/AskPanel.cjs +2 -0
- package/dist/agent/ask/AskPanel.cjs.map +1 -0
- package/dist/agent/{AskPanel.d.ts → ask/AskPanel.d.ts} +1 -1
- package/dist/agent/ask/AskPanel.js +174 -0
- package/dist/agent/ask/AskPanel.js.map +1 -0
- package/dist/agent/ask/buildAskContext.cjs +2 -0
- package/dist/agent/ask/buildAskContext.cjs.map +1 -0
- package/dist/agent/{buildAskContext.d.ts → ask/buildAskContext.d.ts} +2 -2
- package/dist/agent/ask/buildAskContext.js +22 -0
- package/dist/agent/ask/buildAskContext.js.map +1 -0
- package/dist/agent/chat/AgentChatProvider.cjs +2 -0
- package/dist/agent/chat/AgentChatProvider.cjs.map +1 -0
- package/dist/agent/{AgentProvider.d.ts → chat/AgentChatProvider.d.ts} +4 -4
- package/dist/agent/chat/AgentChatProvider.js +26 -0
- package/dist/agent/chat/AgentChatProvider.js.map +1 -0
- package/dist/agent/chat/chat.cjs +2 -0
- package/dist/agent/chat/chat.cjs.map +1 -0
- package/dist/agent/{agentContext.d.ts → chat/chat.d.ts} +5 -6
- package/dist/agent/chat/chat.js +14 -0
- package/dist/agent/chat/chat.js.map +1 -0
- package/dist/agent/chat/useAgentChat.cjs +2 -0
- package/dist/agent/chat/useAgentChat.cjs.map +1 -0
- package/dist/agent/chat/useAgentChat.d.ts +7 -0
- package/dist/agent/chat/useAgentChat.js +9 -0
- package/dist/agent/chat/useAgentChat.js.map +1 -0
- package/dist/agent/core/AegisRuntimeProvider.cjs +2 -0
- package/dist/agent/core/AegisRuntimeProvider.cjs.map +1 -0
- package/dist/agent/core/AegisRuntimeProvider.d.ts +32 -0
- package/dist/agent/core/AegisRuntimeProvider.js +35 -0
- package/dist/agent/core/AegisRuntimeProvider.js.map +1 -0
- package/dist/agent/core/aegisRuntimeContext.cjs +2 -0
- package/dist/agent/core/aegisRuntimeContext.cjs.map +1 -0
- package/dist/agent/core/aegisRuntimeContext.d.ts +6 -0
- package/dist/agent/core/aegisRuntimeContext.js +6 -0
- package/dist/agent/core/aegisRuntimeContext.js.map +1 -0
- package/dist/agent/core/hooks.cjs +2 -0
- package/dist/agent/core/hooks.cjs.map +1 -0
- package/dist/agent/core/hooks.js +83 -0
- package/dist/agent/core/hooks.js.map +1 -0
- package/dist/agent/core/mcpToolCatalogue.cjs +2 -0
- package/dist/agent/core/mcpToolCatalogue.cjs.map +1 -0
- package/dist/agent/core/mcpToolCatalogue.js +101 -0
- package/dist/agent/core/mcpToolCatalogue.js.map +1 -0
- package/dist/agent/core/runtime.cjs +2 -0
- package/dist/agent/core/runtime.cjs.map +1 -0
- package/dist/agent/{runtime.d.ts → core/runtime.d.ts} +3 -7
- package/dist/agent/core/runtime.js +391 -0
- package/dist/agent/core/runtime.js.map +1 -0
- package/dist/agent/core/usePrimitiveSurface.cjs +2 -0
- package/dist/agent/core/usePrimitiveSurface.cjs.map +1 -0
- package/dist/agent/core/usePrimitiveSurface.js +21 -0
- package/dist/agent/core/usePrimitiveSurface.js.map +1 -0
- package/dist/agent/index.d.ts +14 -17
- package/dist/auth/AuthProvider.cjs +2 -0
- package/dist/auth/AuthProvider.cjs.map +1 -0
- package/dist/auth/AuthProvider.js +12 -0
- package/dist/auth/AuthProvider.js.map +1 -0
- package/dist/auth/RequireAuth.cjs +2 -0
- package/dist/auth/RequireAuth.cjs.map +1 -0
- package/dist/auth/RequireAuth.js +15 -0
- package/dist/auth/RequireAuth.js.map +1 -0
- package/dist/auth/authContext.cjs +2 -0
- package/dist/auth/authContext.cjs.map +1 -0
- package/dist/auth/authContext.js +12 -0
- package/dist/auth/authContext.js.map +1 -0
- package/dist/auth/useAuth.cjs +2 -0
- package/dist/auth/useAuth.cjs.map +1 -0
- package/dist/auth/useAuth.js +9 -0
- package/dist/auth/useAuth.js.map +1 -0
- package/dist/commands/CommandProvider.cjs +2 -0
- package/dist/commands/CommandProvider.cjs.map +1 -0
- package/dist/commands/CommandProvider.js +76 -0
- package/dist/commands/CommandProvider.js.map +1 -0
- package/dist/commands/commandContext.cjs +2 -0
- package/dist/commands/commandContext.cjs.map +1 -0
- package/dist/commands/commandContext.d.ts +1 -1
- package/dist/commands/commandContext.js +20 -0
- package/dist/commands/commandContext.js.map +1 -0
- package/dist/commands/shortcut.cjs +2 -0
- package/dist/commands/shortcut.cjs.map +1 -0
- package/dist/commands/shortcut.js +62 -0
- package/dist/commands/shortcut.js.map +1 -0
- package/dist/commands/useCommands.cjs +2 -0
- package/dist/commands/useCommands.cjs.map +1 -0
- package/dist/commands/useCommands.js +9 -0
- package/dist/commands/useCommands.js.map +1 -0
- package/dist/commands/useRegisterCommands.cjs +2 -0
- package/dist/commands/useRegisterCommands.cjs.map +1 -0
- package/dist/commands/useRegisterCommands.js +12 -0
- package/dist/commands/useRegisterCommands.js.map +1 -0
- package/dist/components/ui/AgentPanel.cjs +2 -0
- package/dist/components/ui/AgentPanel.cjs.map +1 -0
- package/dist/components/ui/AgentPanel.d.ts +1 -1
- package/dist/components/ui/AgentPanel.js +35 -0
- package/dist/components/ui/AgentPanel.js.map +1 -0
- package/dist/components/ui/Alert.cjs +2 -0
- package/dist/components/ui/Alert.cjs.map +1 -0
- package/dist/components/ui/Alert.d.ts +14 -0
- package/dist/components/ui/Alert.js +29 -0
- package/dist/components/ui/Alert.js.map +1 -0
- package/dist/components/ui/AmbientBackground.cjs +2 -0
- package/dist/components/ui/AmbientBackground.cjs.map +1 -0
- package/dist/components/ui/AmbientBackground.d.ts +23 -0
- package/dist/components/ui/AmbientBackground.js +24 -0
- package/dist/components/ui/AmbientBackground.js.map +1 -0
- package/dist/components/ui/AuthLayout.cjs +2 -0
- package/dist/components/ui/AuthLayout.cjs.map +1 -0
- package/dist/components/ui/AuthLayout.js +27 -0
- package/dist/components/ui/AuthLayout.js.map +1 -0
- package/dist/components/ui/Avatar.cjs +2 -0
- package/dist/components/ui/Avatar.cjs.map +1 -0
- package/dist/components/ui/Avatar.d.ts +9 -2
- package/dist/components/ui/Avatar.js +55 -0
- package/dist/components/ui/Avatar.js.map +1 -0
- package/dist/components/ui/BlastRadiusBar.cjs +2 -0
- package/dist/components/ui/BlastRadiusBar.cjs.map +1 -0
- package/dist/components/ui/BlastRadiusBar.d.ts +1 -1
- package/dist/components/ui/BlastRadiusBar.js +46 -0
- package/dist/components/ui/BlastRadiusBar.js.map +1 -0
- package/dist/components/ui/Breadcrumb.cjs +2 -0
- package/dist/components/ui/Breadcrumb.cjs.map +1 -0
- package/dist/components/ui/Breadcrumb.d.ts +3 -13
- package/dist/components/ui/Breadcrumb.js +29 -0
- package/dist/components/ui/Breadcrumb.js.map +1 -0
- package/dist/components/ui/BucketCard.cjs +2 -0
- package/dist/components/ui/BucketCard.cjs.map +1 -0
- package/dist/components/ui/BucketCard.js +73 -0
- package/dist/components/ui/BucketCard.js.map +1 -0
- package/dist/components/ui/Button.cjs +2 -0
- package/dist/components/ui/Button.cjs.map +1 -0
- package/dist/components/ui/Button.d.ts +27 -5
- package/dist/components/ui/Button.js +73 -0
- package/dist/components/ui/Button.js.map +1 -0
- package/dist/components/ui/Carousel.cjs +2 -0
- package/dist/components/ui/Carousel.cjs.map +1 -0
- package/dist/components/ui/Carousel.d.ts +28 -0
- package/dist/components/ui/Carousel.js +112 -0
- package/dist/components/ui/Carousel.js.map +1 -0
- package/dist/components/ui/ChatComposer.cjs +2 -0
- package/dist/components/ui/ChatComposer.cjs.map +1 -0
- package/dist/components/ui/ChatComposer.js +63 -0
- package/dist/components/ui/ChatComposer.js.map +1 -0
- package/dist/components/ui/ChatMessage.cjs +2 -0
- package/dist/components/ui/ChatMessage.cjs.map +1 -0
- package/dist/components/ui/ChatMessage.d.ts +2 -2
- package/dist/components/ui/ChatMessage.js +36 -0
- package/dist/components/ui/ChatMessage.js.map +1 -0
- package/dist/components/ui/ChatMessageList.cjs +2 -0
- package/dist/components/ui/ChatMessageList.cjs.map +1 -0
- package/dist/components/ui/ChatMessageList.d.ts +1 -1
- package/dist/components/ui/ChatMessageList.js +35 -0
- package/dist/components/ui/ChatMessageList.js.map +1 -0
- package/dist/components/ui/ChatSessionList.cjs +2 -0
- package/dist/components/ui/ChatSessionList.cjs.map +1 -0
- package/dist/components/ui/ChatSessionList.js +232 -0
- package/dist/components/ui/ChatSessionList.js.map +1 -0
- package/dist/components/ui/CheckGrid.cjs +2 -0
- package/dist/components/ui/CheckGrid.cjs.map +1 -0
- package/dist/components/ui/CheckGrid.d.ts +47 -0
- package/dist/components/ui/CheckGrid.js +69 -0
- package/dist/components/ui/CheckGrid.js.map +1 -0
- package/dist/components/ui/Checkbox.cjs +2 -0
- package/dist/components/ui/Checkbox.cjs.map +1 -0
- package/dist/components/ui/Checkbox.d.ts +14 -0
- package/dist/components/ui/Checkbox.js +41 -0
- package/dist/components/ui/Checkbox.js.map +1 -0
- package/dist/components/ui/Chip.cjs +2 -0
- package/dist/components/ui/Chip.cjs.map +1 -0
- package/dist/components/ui/Chip.d.ts +15 -5
- package/dist/components/ui/Chip.js +55 -0
- package/dist/components/ui/Chip.js.map +1 -0
- package/dist/components/ui/CodeBlock.cjs +3 -0
- package/dist/components/ui/CodeBlock.cjs.map +1 -0
- package/dist/components/ui/CodeBlock.d.ts +4 -2
- package/dist/components/ui/CodeBlock.js +54 -0
- package/dist/components/ui/CodeBlock.js.map +1 -0
- package/dist/components/ui/CodeEditor.cjs +2 -0
- package/dist/components/ui/CodeEditor.cjs.map +1 -0
- package/dist/components/ui/CodeEditor.d.ts +1 -1
- package/dist/components/ui/CodeEditor.js +119 -0
- package/dist/components/ui/CodeEditor.js.map +1 -0
- package/dist/components/ui/Collapse.cjs +2 -0
- package/dist/components/ui/Collapse.cjs.map +1 -0
- package/dist/components/ui/Collapse.d.ts +16 -0
- package/dist/components/ui/Collapse.js +52 -0
- package/dist/components/ui/Collapse.js.map +1 -0
- package/dist/components/ui/ColumnLayout.cjs +2 -0
- package/dist/components/ui/ColumnLayout.cjs.map +1 -0
- package/dist/components/ui/ColumnLayout.d.ts +16 -0
- package/dist/components/ui/ColumnLayout.js +26 -0
- package/dist/components/ui/ColumnLayout.js.map +1 -0
- package/dist/components/ui/CommandInvocationCard.cjs +2 -0
- package/dist/components/ui/CommandInvocationCard.cjs.map +1 -0
- package/dist/components/ui/CommandInvocationCard.d.ts +1 -1
- package/dist/components/ui/CommandInvocationCard.js +65 -0
- package/dist/components/ui/CommandInvocationCard.js.map +1 -0
- package/dist/components/ui/CommandPalette.cjs +2 -0
- package/dist/components/ui/CommandPalette.cjs.map +1 -0
- package/dist/components/ui/CommandPalette.js +147 -0
- package/dist/components/ui/CommandPalette.js.map +1 -0
- package/dist/components/ui/ContentInspectorContent.cjs +5 -0
- package/dist/components/ui/ContentInspectorContent.cjs.map +1 -0
- package/dist/components/ui/ContentInspectorContent.js +101 -0
- package/dist/components/ui/ContentInspectorContent.js.map +1 -0
- package/dist/components/ui/ContentInspectorDialog.cjs +4 -0
- package/dist/components/ui/ContentInspectorDialog.cjs.map +1 -0
- package/dist/components/ui/ContentInspectorDialog.js +211 -0
- package/dist/components/ui/ContentInspectorDialog.js.map +1 -0
- package/dist/components/ui/ControlListItem.cjs +2 -0
- package/dist/components/ui/ControlListItem.cjs.map +1 -0
- package/dist/components/ui/ControlListItem.d.ts +4 -2
- package/dist/components/ui/ControlListItem.js +48 -0
- package/dist/components/ui/ControlListItem.js.map +1 -0
- package/dist/components/ui/DangerZone.cjs +2 -0
- package/dist/components/ui/DangerZone.cjs.map +1 -0
- package/dist/components/ui/DangerZone.js +23 -0
- package/dist/components/ui/DangerZone.js.map +1 -0
- package/dist/components/ui/DataList.cjs +2 -0
- package/dist/components/ui/DataList.cjs.map +1 -0
- package/dist/components/ui/DataList.d.ts +1 -1
- package/dist/components/ui/DataList.js +41 -0
- package/dist/components/ui/DataList.js.map +1 -0
- package/dist/components/ui/DataTable.cjs +2 -0
- package/dist/components/ui/DataTable.cjs.map +1 -0
- package/dist/components/ui/DataTable.d.ts +62 -2
- package/dist/components/ui/DataTable.js +419 -0
- package/dist/components/ui/DataTable.js.map +1 -0
- package/dist/components/ui/Dialog.cjs +2 -0
- package/dist/components/ui/Dialog.cjs.map +1 -0
- package/dist/components/ui/Dialog.d.ts +21 -0
- package/dist/components/ui/Dialog.js +110 -0
- package/dist/components/ui/Dialog.js.map +1 -0
- package/dist/components/ui/DiffViewer.cjs +2 -0
- package/dist/components/ui/DiffViewer.cjs.map +1 -0
- package/dist/components/ui/DiffViewer.d.ts +1 -1
- package/dist/components/ui/DiffViewer.js +83 -0
- package/dist/components/ui/DiffViewer.js.map +1 -0
- package/dist/components/ui/DropdownMenu.cjs +2 -0
- package/dist/components/ui/DropdownMenu.cjs.map +1 -0
- package/dist/components/ui/DropdownMenu.d.ts +1 -1
- package/dist/components/ui/DropdownMenu.js +104 -0
- package/dist/components/ui/DropdownMenu.js.map +1 -0
- package/dist/components/ui/EmptyState.cjs +2 -0
- package/dist/components/ui/EmptyState.cjs.map +1 -0
- package/dist/components/ui/EmptyState.js +21 -0
- package/dist/components/ui/EmptyState.js.map +1 -0
- package/dist/components/ui/EnvironmentSwitcher.cjs +2 -0
- package/dist/components/ui/EnvironmentSwitcher.cjs.map +1 -0
- package/dist/components/ui/EnvironmentSwitcher.d.ts +1 -1
- package/dist/components/ui/EnvironmentSwitcher.js +115 -0
- package/dist/components/ui/EnvironmentSwitcher.js.map +1 -0
- package/dist/components/ui/ErrorState.cjs +2 -0
- package/dist/components/ui/ErrorState.cjs.map +1 -0
- package/dist/components/ui/ErrorState.js +28 -0
- package/dist/components/ui/ErrorState.js.map +1 -0
- package/dist/components/ui/EventTable.cjs +2 -0
- package/dist/components/ui/EventTable.cjs.map +1 -0
- package/dist/components/ui/EventTable.js +184 -0
- package/dist/components/ui/EventTable.js.map +1 -0
- package/dist/components/ui/FileDropzone.cjs +2 -0
- package/dist/components/ui/FileDropzone.cjs.map +1 -0
- package/dist/components/ui/FileDropzone.js +84 -0
- package/dist/components/ui/FileDropzone.js.map +1 -0
- package/dist/components/ui/FilePreview.cjs +2 -0
- package/dist/components/ui/FilePreview.cjs.map +1 -0
- package/dist/components/ui/FilePreview.d.ts +2 -2
- package/dist/components/ui/FilePreview.js +102 -0
- package/dist/components/ui/FilePreview.js.map +1 -0
- package/dist/components/ui/FileTree.cjs +2 -0
- package/dist/components/ui/FileTree.cjs.map +1 -0
- package/dist/components/ui/FileTree.d.ts +27 -0
- package/dist/components/ui/FileTree.js +159 -0
- package/dist/components/ui/FileTree.js.map +1 -0
- package/dist/components/ui/FolderDropzone.cjs +2 -0
- package/dist/components/ui/FolderDropzone.cjs.map +1 -0
- package/dist/components/ui/FolderDropzone.js +158 -0
- package/dist/components/ui/FolderDropzone.js.map +1 -0
- package/dist/components/ui/ForgotPasswordForm.cjs +2 -0
- package/dist/components/ui/ForgotPasswordForm.cjs.map +1 -0
- package/dist/components/ui/ForgotPasswordForm.js +47 -0
- package/dist/components/ui/ForgotPasswordForm.js.map +1 -0
- package/dist/components/ui/FormRow.cjs +2 -0
- package/dist/components/ui/FormRow.cjs.map +1 -0
- package/dist/components/ui/FormRow.js +21 -0
- package/dist/components/ui/FormRow.js.map +1 -0
- package/dist/components/ui/IdentityCell.cjs +2 -0
- package/dist/components/ui/IdentityCell.cjs.map +1 -0
- package/dist/components/ui/IdentityCell.d.ts +25 -0
- package/dist/components/ui/IdentityCell.js +47 -0
- package/dist/components/ui/IdentityCell.js.map +1 -0
- package/dist/components/ui/InboxPage.cjs +2 -0
- package/dist/components/ui/InboxPage.cjs.map +1 -0
- package/dist/components/ui/InboxPage.d.ts +1 -1
- package/dist/components/ui/InboxPage.js +102 -0
- package/dist/components/ui/InboxPage.js.map +1 -0
- package/dist/components/ui/KeyValueList.cjs +2 -0
- package/dist/components/ui/KeyValueList.cjs.map +1 -0
- package/dist/components/ui/KeyValueList.d.ts +1 -1
- package/dist/components/ui/KeyValueList.js +23 -0
- package/dist/components/ui/KeyValueList.js.map +1 -0
- package/dist/components/ui/LoginForm.cjs +2 -0
- package/dist/components/ui/LoginForm.cjs.map +1 -0
- package/dist/components/ui/LoginForm.js +100 -0
- package/dist/components/ui/LoginForm.js.map +1 -0
- package/dist/components/ui/Markdown.cjs +2 -0
- package/dist/components/ui/Markdown.cjs.map +1 -0
- package/dist/components/ui/Markdown.js +82 -0
- package/dist/components/ui/Markdown.js.map +1 -0
- package/dist/components/ui/MdxDocument.cjs +2 -0
- package/dist/components/ui/MdxDocument.cjs.map +1 -0
- package/dist/components/ui/MdxDocument.d.ts +17 -0
- package/dist/components/ui/MdxDocument.js +66 -0
- package/dist/components/ui/MdxDocument.js.map +1 -0
- package/dist/components/ui/MetadataList.cjs +2 -0
- package/dist/components/ui/MetadataList.cjs.map +1 -0
- package/dist/components/ui/MetadataList.js +36 -0
- package/dist/components/ui/MetadataList.js.map +1 -0
- package/dist/components/ui/MetricCard.cjs +2 -0
- package/dist/components/ui/MetricCard.cjs.map +1 -0
- package/dist/components/ui/MetricCard.d.ts +1 -1
- package/dist/components/ui/MetricCard.js +63 -0
- package/dist/components/ui/MetricCard.js.map +1 -0
- package/dist/components/ui/MetricLabel.cjs +2 -0
- package/dist/components/ui/MetricLabel.cjs.map +1 -0
- package/dist/components/ui/MetricLabel.d.ts +1 -0
- package/dist/components/ui/MetricLabel.js +22 -0
- package/dist/components/ui/MetricLabel.js.map +1 -0
- package/dist/components/ui/MonoValue.cjs +2 -0
- package/dist/components/ui/MonoValue.cjs.map +1 -0
- package/dist/components/ui/MonoValue.d.ts +4 -2
- package/dist/components/ui/MonoValue.js +29 -0
- package/dist/components/ui/MonoValue.js.map +1 -0
- package/dist/components/ui/NotificationBell.cjs +2 -0
- package/dist/components/ui/NotificationBell.cjs.map +1 -0
- package/dist/components/ui/NotificationBell.d.ts +1 -1
- package/dist/components/ui/NotificationBell.js +98 -0
- package/dist/components/ui/NotificationBell.js.map +1 -0
- package/dist/components/ui/ObjectBrowser.cjs +2 -0
- package/dist/components/ui/ObjectBrowser.cjs.map +1 -0
- package/dist/components/ui/ObjectBrowser.js +116 -0
- package/dist/components/ui/ObjectBrowser.js.map +1 -0
- package/dist/components/ui/ObjectInspector.cjs +2 -0
- package/dist/components/ui/ObjectInspector.cjs.map +1 -0
- package/dist/components/ui/ObjectInspector.js +117 -0
- package/dist/components/ui/ObjectInspector.js.map +1 -0
- package/dist/components/ui/PageHeader.cjs +2 -0
- package/dist/components/ui/PageHeader.cjs.map +1 -0
- package/dist/components/ui/PageHeader.d.ts +7 -2
- package/dist/components/ui/PageHeader.js +29 -0
- package/dist/components/ui/PageHeader.js.map +1 -0
- package/dist/components/ui/PageSizeSelect.cjs +2 -0
- package/dist/components/ui/PageSizeSelect.cjs.map +1 -0
- package/dist/components/ui/PageSizeSelect.d.ts +2 -1
- package/dist/components/ui/PageSizeSelect.js +88 -0
- package/dist/components/ui/PageSizeSelect.js.map +1 -0
- package/dist/components/ui/Pagination.cjs +2 -0
- package/dist/components/ui/Pagination.cjs.map +1 -0
- package/dist/components/ui/Pagination.d.ts +13 -0
- package/dist/components/ui/Pagination.js +56 -0
- package/dist/components/ui/Pagination.js.map +1 -0
- package/dist/components/ui/Panel.cjs +2 -0
- package/dist/components/ui/Panel.cjs.map +1 -0
- package/dist/components/ui/Panel.d.ts +33 -5
- package/dist/components/ui/Panel.js +47 -0
- package/dist/components/ui/Panel.js.map +1 -0
- package/dist/components/ui/PanelTitle.cjs +2 -0
- package/dist/components/ui/PanelTitle.cjs.map +1 -0
- package/dist/components/ui/PanelTitle.d.ts +2 -2
- package/dist/components/ui/PanelTitle.js +21 -0
- package/dist/components/ui/PanelTitle.js.map +1 -0
- package/dist/components/ui/ParetoChart.cjs +2 -0
- package/dist/components/ui/ParetoChart.cjs.map +1 -0
- package/dist/components/ui/ParetoChart.d.ts +41 -0
- package/dist/components/ui/ParetoChart.js +278 -0
- package/dist/components/ui/ParetoChart.js.map +1 -0
- package/dist/components/ui/ParquetViewer.cjs +2 -0
- package/dist/components/ui/ParquetViewer.cjs.map +1 -0
- package/dist/components/ui/ParquetViewer.d.ts +1 -1
- package/dist/components/ui/ParquetViewer.js +210 -0
- package/dist/components/ui/ParquetViewer.js.map +1 -0
- package/dist/components/ui/PasswordField.cjs +2 -0
- package/dist/components/ui/PasswordField.cjs.map +1 -0
- package/dist/components/ui/PasswordField.js +37 -0
- package/dist/components/ui/PasswordField.js.map +1 -0
- package/dist/components/ui/PickerField.cjs +2 -0
- package/dist/components/ui/PickerField.cjs.map +1 -0
- package/dist/components/ui/PickerField.d.ts +17 -0
- package/dist/components/ui/PickerField.js +45 -0
- package/dist/components/ui/PickerField.js.map +1 -0
- package/dist/components/ui/ProjectSelector.cjs +2 -0
- package/dist/components/ui/ProjectSelector.cjs.map +1 -0
- package/dist/components/ui/ProjectSelector.d.ts +1 -1
- package/dist/components/ui/ProjectSelector.js +74 -0
- package/dist/components/ui/ProjectSelector.js.map +1 -0
- package/dist/components/ui/QueryAutocomplete.cjs +2 -0
- package/dist/components/ui/QueryAutocomplete.cjs.map +1 -0
- package/dist/components/ui/QueryAutocomplete.js +235 -0
- package/dist/components/ui/QueryAutocomplete.js.map +1 -0
- package/dist/components/ui/RankBar.cjs +2 -0
- package/dist/components/ui/RankBar.cjs.map +1 -0
- package/dist/components/ui/RankBar.d.ts +25 -0
- package/dist/components/ui/RankBar.js +90 -0
- package/dist/components/ui/RankBar.js.map +1 -0
- package/dist/components/ui/RegisterForm.cjs +2 -0
- package/dist/components/ui/RegisterForm.cjs.map +1 -0
- package/dist/components/ui/RegisterForm.js +72 -0
- package/dist/components/ui/RegisterForm.js.map +1 -0
- package/dist/components/ui/ResizableSidePanel.cjs +2 -0
- package/dist/components/ui/ResizableSidePanel.cjs.map +1 -0
- package/dist/components/ui/ResizableSidePanel.js +79 -0
- package/dist/components/ui/ResizableSidePanel.js.map +1 -0
- package/dist/components/ui/Reveal.cjs +2 -0
- package/dist/components/ui/Reveal.cjs.map +1 -0
- package/dist/components/ui/Reveal.d.ts +17 -0
- package/dist/components/ui/Reveal.js +37 -0
- package/dist/components/ui/Reveal.js.map +1 -0
- package/dist/components/ui/RunPips.cjs +2 -0
- package/dist/components/ui/RunPips.cjs.map +1 -0
- package/dist/components/ui/RunPips.d.ts +25 -0
- package/dist/components/ui/RunPips.js +53 -0
- package/dist/components/ui/RunPips.js.map +1 -0
- package/dist/components/ui/SavedQueryBar.cjs +2 -0
- package/dist/components/ui/SavedQueryBar.cjs.map +1 -0
- package/dist/components/ui/SavedQueryBar.js +390 -0
- package/dist/components/ui/SavedQueryBar.js.map +1 -0
- package/dist/components/ui/ScoreBar.cjs +2 -0
- package/dist/components/ui/ScoreBar.cjs.map +1 -0
- package/dist/components/ui/ScoreBar.d.ts +21 -0
- package/dist/components/ui/ScoreBar.js +44 -0
- package/dist/components/ui/ScoreBar.js.map +1 -0
- package/dist/components/ui/ScrollStory.cjs +3 -0
- package/dist/components/ui/ScrollStory.cjs.map +1 -0
- package/dist/components/ui/ScrollStory.d.ts +33 -0
- package/dist/components/ui/ScrollStory.js +116 -0
- package/dist/components/ui/ScrollStory.js.map +1 -0
- package/dist/components/ui/SearchInput.cjs +2 -0
- package/dist/components/ui/SearchInput.cjs.map +1 -0
- package/dist/components/ui/SearchInput.d.ts +6 -1
- package/dist/components/ui/SearchInput.js +48 -0
- package/dist/components/ui/SearchInput.js.map +1 -0
- package/dist/components/ui/SectionDivider.cjs +2 -0
- package/dist/components/ui/SectionDivider.cjs.map +1 -0
- package/dist/components/ui/SectionDivider.js +22 -0
- package/dist/components/ui/SectionDivider.js.map +1 -0
- package/dist/components/ui/Select.cjs +2 -0
- package/dist/components/ui/Select.cjs.map +1 -0
- package/dist/components/ui/Select.d.ts +25 -0
- package/dist/components/ui/Select.js +70 -0
- package/dist/components/ui/Select.js.map +1 -0
- package/dist/components/ui/ServiceMap.cjs +2 -0
- package/dist/components/ui/ServiceMap.cjs.map +1 -0
- package/dist/components/ui/ServiceMap.js +187 -0
- package/dist/components/ui/ServiceMap.js.map +1 -0
- package/dist/components/ui/SessionRunView.cjs +4 -0
- package/dist/components/ui/SessionRunView.cjs.map +1 -0
- package/dist/components/ui/SessionRunView.js +379 -0
- package/dist/components/ui/SessionRunView.js.map +1 -0
- package/dist/components/ui/SettingsSection.cjs +2 -0
- package/dist/components/ui/SettingsSection.cjs.map +1 -0
- package/dist/components/ui/SettingsSection.js +23 -0
- package/dist/components/ui/SettingsSection.js.map +1 -0
- package/dist/components/ui/ShareLinkDialog.cjs +2 -0
- package/dist/components/ui/ShareLinkDialog.cjs.map +1 -0
- package/dist/components/ui/ShareLinkDialog.d.ts +21 -5
- package/dist/components/ui/ShareLinkDialog.js +133 -0
- package/dist/components/ui/ShareLinkDialog.js.map +1 -0
- package/dist/components/ui/Skeleton.cjs +2 -0
- package/dist/components/ui/Skeleton.cjs.map +1 -0
- package/dist/components/ui/Skeleton.js +42 -0
- package/dist/components/ui/Skeleton.js.map +1 -0
- package/dist/components/ui/SparkLine.cjs +2 -0
- package/dist/components/ui/SparkLine.cjs.map +1 -0
- package/dist/components/ui/SparkLine.d.ts +1 -1
- package/dist/components/ui/SparkLine.js +61 -0
- package/dist/components/ui/SparkLine.js.map +1 -0
- package/dist/components/ui/StackedBar.cjs +2 -0
- package/dist/components/ui/StackedBar.cjs.map +1 -0
- package/dist/components/ui/StackedBar.d.ts +47 -0
- package/dist/components/ui/StackedBar.js +110 -0
- package/dist/components/ui/StackedBar.js.map +1 -0
- package/dist/components/ui/StatBlock.cjs +2 -0
- package/dist/components/ui/StatBlock.cjs.map +1 -0
- package/dist/components/ui/StatBlock.d.ts +9 -3
- package/dist/components/ui/StatBlock.js +67 -0
- package/dist/components/ui/StatBlock.js.map +1 -0
- package/dist/components/ui/StatusDot.cjs +2 -0
- package/dist/components/ui/StatusDot.cjs.map +1 -0
- package/dist/components/ui/StatusDot.d.ts +1 -1
- package/dist/components/ui/StatusDot.js +27 -0
- package/dist/components/ui/StatusDot.js.map +1 -0
- package/dist/components/ui/TableOfContents.cjs +2 -0
- package/dist/components/ui/TableOfContents.cjs.map +1 -0
- package/dist/components/ui/TableOfContents.d.ts +20 -0
- package/dist/components/ui/TableOfContents.js +104 -0
- package/dist/components/ui/TableOfContents.js.map +1 -0
- package/dist/components/ui/Tabs.cjs +3 -0
- package/dist/components/ui/Tabs.cjs.map +1 -0
- package/dist/components/ui/Tabs.d.ts +12 -2
- package/dist/components/ui/Tabs.js +144 -0
- package/dist/components/ui/Tabs.js.map +1 -0
- package/dist/components/ui/Terminal.cjs +2 -0
- package/dist/components/ui/Terminal.cjs.map +1 -0
- package/dist/components/ui/Terminal.d.ts +1 -1
- package/dist/components/ui/Terminal.js +42 -0
- package/dist/components/ui/Terminal.js.map +1 -0
- package/dist/components/ui/TextField.cjs +2 -0
- package/dist/components/ui/TextField.cjs.map +1 -0
- package/dist/components/ui/TextField.js +56 -0
- package/dist/components/ui/TextField.js.map +1 -0
- package/dist/components/ui/ThemeToggle.cjs +2 -0
- package/dist/components/ui/ThemeToggle.cjs.map +1 -0
- package/dist/components/ui/ThemeToggle.d.ts +1 -1
- package/dist/components/ui/ThemeToggle.js +37 -0
- package/dist/components/ui/ThemeToggle.js.map +1 -0
- package/dist/components/ui/TimeDisplay.cjs +2 -0
- package/dist/components/ui/TimeDisplay.cjs.map +1 -0
- package/dist/components/ui/TimeDisplay.js +56 -0
- package/dist/components/ui/TimeDisplay.js.map +1 -0
- package/dist/components/ui/TimeRangePicker.cjs +2 -0
- package/dist/components/ui/TimeRangePicker.cjs.map +1 -0
- package/dist/components/ui/TimeRangePicker.js +152 -0
- package/dist/components/ui/TimeRangePicker.js.map +1 -0
- package/dist/components/ui/Timeline.cjs +2 -0
- package/dist/components/ui/Timeline.cjs.map +1 -0
- package/dist/components/ui/Timeline.d.ts +21 -6
- package/dist/components/ui/Timeline.js +54 -0
- package/dist/components/ui/Timeline.js.map +1 -0
- package/dist/components/ui/TimelineChart.cjs +2 -0
- package/dist/components/ui/TimelineChart.cjs.map +1 -0
- package/dist/components/ui/TimelineChart.js +281 -0
- package/dist/components/ui/TimelineChart.js.map +1 -0
- package/dist/components/ui/ToolCallCard.cjs +4 -0
- package/dist/components/ui/ToolCallCard.cjs.map +1 -0
- package/dist/components/ui/ToolCallCard.d.ts +1 -2
- package/dist/components/ui/ToolCallCard.js +56 -0
- package/dist/components/ui/ToolCallCard.js.map +1 -0
- package/dist/components/ui/Toolbar.cjs +2 -0
- package/dist/components/ui/Toolbar.cjs.map +1 -0
- package/dist/components/ui/Toolbar.js +68 -0
- package/dist/components/ui/Toolbar.js.map +1 -0
- package/dist/components/ui/TraceSpanInspector.cjs +2 -0
- package/dist/components/ui/TraceSpanInspector.cjs.map +1 -0
- package/dist/components/ui/TraceSpanInspector.d.ts +4 -1
- package/dist/components/ui/TraceSpanInspector.js +148 -0
- package/dist/components/ui/TraceSpanInspector.js.map +1 -0
- package/dist/components/ui/TraceTree.cjs +2 -0
- package/dist/components/ui/TraceTree.cjs.map +1 -0
- package/dist/components/ui/TraceTree.d.ts +8 -4
- package/dist/components/ui/TraceTree.js +195 -0
- package/dist/components/ui/TraceTree.js.map +1 -0
- package/dist/components/ui/TrajectoryStep.cjs +2 -0
- package/dist/components/ui/TrajectoryStep.cjs.map +1 -0
- package/dist/components/ui/TrajectoryStep.d.ts +14 -1
- package/dist/components/ui/TrajectoryStep.js +74 -0
- package/dist/components/ui/TrajectoryStep.js.map +1 -0
- package/dist/components/ui/TrajectoryTimeline.cjs +2 -0
- package/dist/components/ui/TrajectoryTimeline.cjs.map +1 -0
- package/dist/components/ui/TrajectoryTimeline.d.ts +4 -2
- package/dist/components/ui/TrajectoryTimeline.js +51 -0
- package/dist/components/ui/TrajectoryTimeline.js.map +1 -0
- package/dist/components/ui/UploadQueue.cjs +2 -0
- package/dist/components/ui/UploadQueue.cjs.map +1 -0
- package/dist/components/ui/UploadQueue.js +146 -0
- package/dist/components/ui/UploadQueue.js.map +1 -0
- package/dist/components/ui/codeFence.cjs +2 -0
- package/dist/components/ui/codeFence.cjs.map +1 -0
- package/dist/components/ui/codeFence.d.ts +5 -0
- package/dist/components/ui/codeFence.js +16 -0
- package/dist/components/ui/codeFence.js.map +1 -0
- package/dist/components/ui/index.d.ts +44 -5
- package/dist/components/ui/linkComponent.cjs +2 -0
- package/dist/components/ui/linkComponent.cjs.map +1 -0
- package/dist/components/ui/linkComponent.d.ts +15 -0
- package/dist/components/ui/linkComponent.js +11 -0
- package/dist/components/ui/linkComponent.js.map +1 -0
- package/dist/components/ui/mdxTableOfContents.cjs +2 -0
- package/dist/components/ui/mdxTableOfContents.cjs.map +1 -0
- package/dist/components/ui/mdxTableOfContents.d.ts +13 -0
- package/dist/components/ui/mdxTableOfContents.js +13 -0
- package/dist/components/ui/mdxTableOfContents.js.map +1 -0
- package/dist/components/ui/relativeTime.cjs +2 -0
- package/dist/components/ui/relativeTime.cjs.map +1 -0
- package/dist/components/ui/relativeTime.js +11 -0
- package/dist/components/ui/relativeTime.js.map +1 -0
- package/dist/components/ui/tablistKeyboard.cjs +2 -0
- package/dist/components/ui/tablistKeyboard.cjs.map +1 -0
- package/dist/components/ui/tablistKeyboard.d.ts +6 -0
- package/dist/components/ui/tablistKeyboard.js +18 -0
- package/dist/components/ui/tablistKeyboard.js.map +1 -0
- package/dist/components/ui/traceFormat.cjs +2 -0
- package/dist/components/ui/traceFormat.cjs.map +1 -0
- package/dist/components/ui/traceFormat.js +15 -0
- package/dist/components/ui/traceFormat.js.map +1 -0
- package/dist/hooks/index.d.ts +4 -0
- package/dist/hooks/useCopyToClipboard.cjs +2 -0
- package/dist/hooks/useCopyToClipboard.cjs.map +1 -0
- package/dist/hooks/useCopyToClipboard.d.ts +1 -1
- package/dist/hooks/useCopyToClipboard.js +24 -0
- package/dist/hooks/useCopyToClipboard.js.map +1 -0
- package/dist/hooks/useElementWidth.cjs +2 -0
- package/dist/hooks/useElementWidth.cjs.map +1 -0
- package/dist/hooks/useElementWidth.d.ts +3 -0
- package/dist/hooks/useElementWidth.js +22 -0
- package/dist/hooks/useElementWidth.js.map +1 -0
- package/dist/hooks/useIsomorphicLayoutEffect.cjs +2 -0
- package/dist/hooks/useIsomorphicLayoutEffect.cjs.map +1 -0
- package/dist/hooks/useIsomorphicLayoutEffect.d.ts +7 -0
- package/dist/hooks/useIsomorphicLayoutEffect.js +6 -0
- package/dist/hooks/useIsomorphicLayoutEffect.js.map +1 -0
- package/dist/hooks/useMediaQuery.cjs +2 -0
- package/dist/hooks/useMediaQuery.cjs.map +1 -0
- package/dist/hooks/useMediaQuery.d.ts +5 -0
- package/dist/hooks/useMediaQuery.js +23 -0
- package/dist/hooks/useMediaQuery.js.map +1 -0
- package/dist/hooks/useMenuPopover.cjs +2 -0
- package/dist/hooks/useMenuPopover.cjs.map +1 -0
- package/dist/hooks/useMenuPopover.js +64 -0
- package/dist/hooks/useMenuPopover.js.map +1 -0
- package/dist/hooks/usePageHidden.cjs +2 -0
- package/dist/hooks/usePageHidden.cjs.map +1 -0
- package/dist/hooks/usePageHidden.d.ts +2 -0
- package/dist/hooks/usePageHidden.js +23 -0
- package/dist/hooks/usePageHidden.js.map +1 -0
- package/dist/hooks/useResizable.cjs +2 -0
- package/dist/hooks/useResizable.cjs.map +1 -0
- package/dist/hooks/useResizable.js +99 -0
- package/dist/hooks/useResizable.js.map +1 -0
- package/dist/hooks/useSavedQueries.cjs +2 -0
- package/dist/hooks/useSavedQueries.cjs.map +1 -0
- package/dist/hooks/useSavedQueries.js +93 -0
- package/dist/hooks/useSavedQueries.js.map +1 -0
- package/dist/hooks/useScrollProgress.cjs +2 -0
- package/dist/hooks/useScrollProgress.cjs.map +1 -0
- package/dist/hooks/useScrollProgress.d.ts +36 -0
- package/dist/hooks/useScrollProgress.js +64 -0
- package/dist/hooks/useScrollProgress.js.map +1 -0
- package/dist/hooks/useWindowScrolled.cjs +2 -0
- package/dist/hooks/useWindowScrolled.cjs.map +1 -0
- package/dist/hooks/useWindowScrolled.d.ts +2 -0
- package/dist/hooks/useWindowScrolled.js +19 -0
- package/dist/hooks/useWindowScrolled.js.map +1 -0
- package/dist/index.cjs +1 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +13 -8
- package/dist/index.js +307 -9848
- package/dist/index.js.map +1 -1
- package/dist/layouts/PageWrapper.cjs +2 -0
- package/dist/layouts/PageWrapper.cjs.map +1 -0
- package/dist/layouts/PageWrapper.js +14 -0
- package/dist/layouts/PageWrapper.js.map +1 -0
- package/dist/layouts/shell/AegisShell.cjs +2 -0
- package/dist/layouts/shell/AegisShell.cjs.map +1 -0
- package/dist/layouts/shell/AegisShell.d.ts +1 -1
- package/dist/layouts/shell/AegisShell.js +311 -0
- package/dist/layouts/shell/AegisShell.js.map +1 -0
- package/dist/layouts/shell/AppSwitcher.cjs +2 -0
- package/dist/layouts/shell/AppSwitcher.cjs.map +1 -0
- package/dist/layouts/shell/AppSwitcher.js +81 -0
- package/dist/layouts/shell/AppSwitcher.js.map +1 -0
- package/dist/layouts/shell/AuthRequiredCard.cjs +2 -0
- package/dist/layouts/shell/AuthRequiredCard.cjs.map +1 -0
- package/dist/layouts/shell/AuthRequiredCard.js +33 -0
- package/dist/layouts/shell/AuthRequiredCard.js.map +1 -0
- package/dist/layouts/shell/BreadcrumbBar.cjs +2 -0
- package/dist/layouts/shell/BreadcrumbBar.cjs.map +1 -0
- package/dist/layouts/shell/BreadcrumbBar.js +38 -0
- package/dist/layouts/shell/BreadcrumbBar.js.map +1 -0
- package/dist/layouts/shell/Sidebar.cjs +2 -0
- package/dist/layouts/shell/Sidebar.cjs.map +1 -0
- package/dist/layouts/shell/Sidebar.js +34 -0
- package/dist/layouts/shell/Sidebar.js.map +1 -0
- package/dist/layouts/shell/TopHeader.cjs +2 -0
- package/dist/layouts/shell/TopHeader.cjs.map +1 -0
- package/dist/layouts/shell/TopHeader.d.ts +5 -1
- package/dist/layouts/shell/TopHeader.js +201 -0
- package/dist/layouts/shell/TopHeader.js.map +1 -0
- package/dist/layouts/shell/activeAppContext.cjs +2 -0
- package/dist/layouts/shell/activeAppContext.cjs.map +1 -0
- package/dist/layouts/shell/activeAppContext.js +17 -0
- package/dist/layouts/shell/activeAppContext.js.map +1 -0
- package/dist/layouts/shell/environments/EnvironmentContext.cjs +2 -0
- package/dist/layouts/shell/environments/EnvironmentContext.cjs.map +1 -0
- package/dist/layouts/shell/environments/EnvironmentContext.js +94 -0
- package/dist/layouts/shell/environments/EnvironmentContext.js.map +1 -0
- package/dist/layouts/shell/environments/context.cjs +2 -0
- package/dist/layouts/shell/environments/context.cjs.map +1 -0
- package/dist/layouts/shell/environments/context.js +6 -0
- package/dist/layouts/shell/environments/context.js.map +1 -0
- package/dist/layouts/shell/environments/hooks.cjs +2 -0
- package/dist/layouts/shell/environments/hooks.cjs.map +1 -0
- package/dist/layouts/shell/environments/hooks.js +24 -0
- package/dist/layouts/shell/environments/hooks.js.map +1 -0
- package/dist/layouts/shell/environments/manifest.cjs +2 -0
- package/dist/layouts/shell/environments/manifest.cjs.map +1 -0
- package/dist/layouts/shell/environments/manifest.js +82 -0
- package/dist/layouts/shell/environments/manifest.js.map +1 -0
- package/dist/layouts/shell/environments/types.cjs +2 -0
- package/dist/layouts/shell/environments/types.cjs.map +1 -0
- package/dist/layouts/shell/environments/types.js +5 -0
- package/dist/layouts/shell/environments/types.js.map +1 -0
- package/dist/layouts/shell/paths.cjs +2 -0
- package/dist/layouts/shell/paths.cjs.map +1 -0
- package/dist/layouts/shell/paths.d.ts +4 -1
- package/dist/layouts/shell/paths.js +17 -0
- package/dist/layouts/shell/paths.js.map +1 -0
- package/dist/layouts/shell/types.d.ts +29 -2
- package/dist/layouts/shell/useAppNavigate.cjs +2 -0
- package/dist/layouts/shell/useAppNavigate.cjs.map +1 -0
- package/dist/layouts/shell/useAppNavigate.js +25 -0
- package/dist/layouts/shell/useAppNavigate.js.map +1 -0
- package/dist/layouts/site/SiteFooter.cjs +2 -0
- package/dist/layouts/site/SiteFooter.cjs.map +1 -0
- package/dist/layouts/site/SiteFooter.d.ts +27 -0
- package/dist/layouts/site/SiteFooter.js +58 -0
- package/dist/layouts/site/SiteFooter.js.map +1 -0
- package/dist/layouts/site/SiteLayout.cjs +2 -0
- package/dist/layouts/site/SiteLayout.cjs.map +1 -0
- package/dist/layouts/site/SiteLayout.d.ts +18 -0
- package/dist/layouts/site/SiteLayout.js +44 -0
- package/dist/layouts/site/SiteLayout.js.map +1 -0
- package/dist/layouts/site/SiteNav.cjs +2 -0
- package/dist/layouts/site/SiteNav.cjs.map +1 -0
- package/dist/layouts/site/SiteNav.d.ts +31 -0
- package/dist/layouts/site/SiteNav.js +113 -0
- package/dist/layouts/site/SiteNav.js.map +1 -0
- package/dist/layouts/site/SiteSection.cjs +2 -0
- package/dist/layouts/site/SiteSection.cjs.map +1 -0
- package/dist/layouts/site/SiteSection.d.ts +20 -0
- package/dist/layouts/site/SiteSection.js +27 -0
- package/dist/layouts/site/SiteSection.js.map +1 -0
- package/dist/layouts/site/index.d.ts +8 -0
- package/dist/lib/format.cjs +2 -0
- package/dist/lib/format.cjs.map +1 -0
- package/dist/lib/format.js +13 -0
- package/dist/lib/format.js.map +1 -0
- package/dist/lib/id.cjs +2 -0
- package/dist/lib/id.cjs.map +1 -0
- package/dist/lib/id.js +7 -0
- package/dist/lib/id.js.map +1 -0
- package/dist/lib/luceneQuery/index.d.ts +0 -2
- package/dist/lib/luceneQuery/tokenizeAtCursor.cjs +3 -0
- package/dist/lib/luceneQuery/tokenizeAtCursor.cjs.map +1 -0
- package/dist/lib/luceneQuery/tokenizeAtCursor.js +58 -0
- package/dist/lib/luceneQuery/tokenizeAtCursor.js.map +1 -0
- package/dist/lib/scrollView.cjs +2 -0
- package/dist/lib/scrollView.cjs.map +1 -0
- package/dist/lib/scrollView.d.ts +16 -0
- package/dist/lib/scrollView.js +27 -0
- package/dist/lib/scrollView.js.map +1 -0
- package/dist/lib/storage.cjs +2 -0
- package/dist/lib/storage.cjs.map +1 -0
- package/dist/lib/storage.js +35 -0
- package/dist/lib/storage.js.map +1 -0
- package/dist/lib/timeRange.cjs +2 -0
- package/dist/lib/timeRange.cjs.map +1 -0
- package/dist/lib/timeRange.js +70 -0
- package/dist/lib/timeRange.js.map +1 -0
- package/dist/locale/LocaleProvider.cjs +2 -0
- package/dist/locale/LocaleProvider.cjs.map +1 -0
- package/dist/locale/LocaleProvider.d.ts +9 -0
- package/dist/locale/LocaleProvider.js +9 -0
- package/dist/locale/LocaleProvider.js.map +1 -0
- package/dist/locale/index.d.ts +4 -0
- package/dist/locale/localeContext.cjs +2 -0
- package/dist/locale/localeContext.cjs.map +1 -0
- package/dist/locale/localeContext.d.ts +2 -0
- package/dist/locale/localeContext.js +7 -0
- package/dist/locale/localeContext.js.map +1 -0
- package/dist/locale/strings.cjs +2 -0
- package/dist/locale/strings.cjs.map +1 -0
- package/dist/locale/strings.d.ts +114 -0
- package/dist/locale/strings.js +202 -0
- package/dist/locale/strings.js.map +1 -0
- package/dist/locale/useStrings.cjs +2 -0
- package/dist/locale/useStrings.cjs.map +1 -0
- package/dist/locale/useStrings.d.ts +2 -0
- package/dist/locale/useStrings.js +9 -0
- package/dist/locale/useStrings.js.map +1 -0
- package/dist/mdx-modules.d.ts +22 -0
- package/dist/notifications/NotificationProvider.cjs +2 -0
- package/dist/notifications/NotificationProvider.cjs.map +1 -0
- package/dist/notifications/NotificationProvider.js +18 -0
- package/dist/notifications/NotificationProvider.js.map +1 -0
- package/dist/notifications/notificationContext.cjs +2 -0
- package/dist/notifications/notificationContext.cjs.map +1 -0
- package/dist/notifications/notificationContext.js +11 -0
- package/dist/notifications/notificationContext.js.map +1 -0
- package/dist/notifications/useNotifications.cjs +2 -0
- package/dist/notifications/useNotifications.cjs.map +1 -0
- package/dist/notifications/useNotifications.js +9 -0
- package/dist/notifications/useNotifications.js.map +1 -0
- package/dist/style.css +1 -1
- package/dist/theme/ThemeProvider.cjs +2 -0
- package/dist/theme/ThemeProvider.cjs.map +1 -0
- package/dist/theme/ThemeProvider.d.ts +3 -1
- package/dist/theme/ThemeProvider.js +62 -0
- package/dist/theme/ThemeProvider.js.map +1 -0
- package/dist/theme/antdTheme.cjs +2 -0
- package/dist/theme/antdTheme.cjs.map +1 -0
- package/dist/theme/antdTheme.js +230 -0
- package/dist/theme/antdTheme.js.map +1 -0
- package/dist/theme/themeContext.cjs +2 -0
- package/dist/theme/themeContext.cjs.map +1 -0
- package/dist/theme/themeContext.js +6 -0
- package/dist/theme/themeContext.js.map +1 -0
- package/dist/theme/themeInitScript.cjs +2 -0
- package/dist/theme/themeInitScript.cjs.map +1 -0
- package/dist/theme/themeInitScript.d.ts +10 -0
- package/dist/theme/themeInitScript.js +16 -0
- package/dist/theme/themeInitScript.js.map +1 -0
- package/dist/theme/useTheme.cjs +2 -0
- package/dist/theme/useTheme.cjs.map +1 -0
- package/dist/theme/useTheme.js +12 -0
- package/dist/theme/useTheme.js.map +1 -0
- package/dist/transports/agentm/AgentmChannelProvider.cjs +2 -0
- package/dist/transports/agentm/AgentmChannelProvider.cjs.map +1 -0
- package/dist/{agent → transports/agentm}/AgentmChannelProvider.d.ts +2 -2
- package/dist/transports/agentm/AgentmChannelProvider.js +193 -0
- package/dist/transports/agentm/AgentmChannelProvider.js.map +1 -0
- package/dist/transports/agentm/agentmChannelClient.cjs +2 -0
- package/dist/transports/agentm/agentmChannelClient.cjs.map +1 -0
- package/dist/transports/agentm/agentmChannelClient.js +279 -0
- package/dist/transports/agentm/agentmChannelClient.js.map +1 -0
- package/dist/transports/bridge.cjs +2 -0
- package/dist/transports/bridge.cjs.map +1 -0
- package/dist/transports/bridge.d.ts +17 -0
- package/dist/transports/bridge.js +143 -0
- package/dist/transports/bridge.js.map +1 -0
- package/dist/transports/index.d.ts +5 -0
- package/dist/transports.cjs +2 -0
- package/dist/transports.cjs.map +1 -0
- package/dist/transports.js +10 -0
- package/dist/transports.js.map +1 -0
- package/dist/vite.cjs +2 -0
- package/dist/vite.cjs.map +1 -0
- package/dist/vite.d.ts +7 -0
- package/dist/vite.js +18 -0
- package/dist/vite.js.map +1 -0
- package/package.json +25 -3
- package/dist/agent/AegisAgentProvider.d.ts +0 -35
- package/dist/agent/aegisAgentContext.d.ts +0 -6
- package/dist/agent/useAgent.d.ts +0 -7
- package/dist/lib/luceneQuery/compile.d.ts +0 -29
- /package/dist/agent/{AskOverlay.d.ts → ask/AskOverlay.d.ts} +0 -0
- /package/dist/agent/{hooks.d.ts → core/hooks.d.ts} +0 -0
- /package/dist/agent/{mcpToolCatalogue.d.ts → core/mcpToolCatalogue.d.ts} +0 -0
- /package/dist/agent/{types.d.ts → core/types.d.ts} +0 -0
- /package/dist/agent/{usePrimitiveSurface.d.ts → core/usePrimitiveSurface.d.ts} +0 -0
- /package/dist/{agent → transports/agentm}/agentmChannelClient.d.ts +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EnvironmentContext.js","sources":["../../../../src/layouts/shell/environments/EnvironmentContext.tsx"],"sourcesContent":["import {\n type ReactElement,\n type ReactNode,\n useEffect,\n useMemo,\n useRef,\n useState,\n} from 'react';\n\nimport { readStorage, writeStorage } from '../../../lib/storage';\nimport type { AegisApp } from '../types';\nimport {\n AppEnvironmentContext,\n type AppEnvironmentContextValue,\n} from './context';\nimport { fetchManifest } from './manifest';\nimport {\n ENVIRONMENT_CHANGED_EVENT,\n type EnvironmentChangedEventDetail,\n type EnvironmentDescriptor,\n type EnvironmentManifest,\n type EnvironmentManifestStatus,\n} from './types';\n\nconst DEFAULT_DISCOVERY_PATH = '/.well-known/aegis-environments.json';\n\nfunction storageKeyFor(app: AegisApp): string {\n return app.environments?.storageKey ?? `aegis.env.${app.id}`;\n}\n\nfunction syntheticProd(app: AegisApp): EnvironmentDescriptor {\n return {\n id: 'prod',\n label: 'Production',\n baseUrl: app.apiBaseUrl ?? '',\n badge: 'default',\n };\n}\n\ninterface ProviderProps {\n app: AegisApp | undefined;\n children: ReactNode;\n}\n\n/**\n * Mounts environment-discovery state for the active app. Internal — the\n * shell wires it; consumers read state via `useCurrentEnvironment()`.\n */\nexport function ActiveAppEnvironmentProvider({\n app,\n children,\n}: ProviderProps): ReactElement {\n const [manifest, setManifest] = useState<EnvironmentManifest | null>(null);\n const [loading, setLoading] = useState(false);\n const [supported, setSupported] = useState(true);\n const [currentEnvId, setCurrentEnvIdState] = useState<string | null>(null);\n const previousIdRef = useRef<string | null>(null);\n\n const apiBaseUrl = app?.apiBaseUrl;\n const discoveryPath =\n app?.environments?.discoveryPath ?? DEFAULT_DISCOVERY_PATH;\n const storageKey = app ? storageKeyFor(app) : null;\n const fallbackMode = app?.environments?.fallback ?? 'production';\n\n useEffect(() => {\n if (!app || !apiBaseUrl) {\n setManifest(null);\n setSupported(true);\n setCurrentEnvIdState(null);\n previousIdRef.current = null;\n return;\n }\n\n let cancelled = false;\n setLoading(true);\n setSupported(true);\n\n void fetchManifest({\n apiBaseUrl,\n discoveryPath,\n }).then((result) => {\n if (cancelled) {\n return;\n }\n setLoading(false);\n if (!result) {\n setManifest(null);\n setSupported(false);\n setCurrentEnvIdState(null);\n previousIdRef.current = null;\n return;\n }\n setManifest(result);\n setSupported(true);\n const stored = storageKey ? readStorage(storageKey) : null;\n const initial =\n stored && result.environments.some((e) => e.id === stored)\n ? stored\n : result.default;\n setCurrentEnvIdState(initial);\n previousIdRef.current = initial;\n });\n\n return () => {\n cancelled = true;\n };\n }, [app, apiBaseUrl, discoveryPath, storageKey]);\n\n const setCurrentEnv = useMemo(() => {\n return (id: string): void => {\n if (!manifest || !app) {\n return;\n }\n const next = manifest.environments.find((e) => e.id === id);\n if (!next) {\n return;\n }\n const from = previousIdRef.current;\n if (from === id) {\n return;\n }\n previousIdRef.current = id;\n setCurrentEnvIdState(id);\n if (storageKey) {\n writeStorage(storageKey, id);\n }\n if (typeof window !== 'undefined') {\n const detail: EnvironmentChangedEventDetail = {\n appId: app.id,\n fromEnvId: from,\n toEnvId: id,\n env: next,\n };\n window.dispatchEvent(\n new CustomEvent(ENVIRONMENT_CHANGED_EVENT, { detail }),\n );\n }\n };\n }, [manifest, app, storageKey]);\n\n const state = useMemo<EnvironmentManifestStatus>(() => {\n if (!app) {\n return { status: 'idle' };\n }\n if (loading) {\n return { status: 'loading' };\n }\n if (!supported || !manifest || !currentEnvId) {\n if (fallbackMode === 'hidden') {\n return { status: 'idle' };\n }\n return { status: 'unsupported', currentEnv: syntheticProd(app) };\n }\n const currentEnv =\n manifest.environments.find((e) => e.id === currentEnvId) ??\n manifest.environments[0];\n return {\n status: 'ready',\n manifest,\n currentEnvId,\n currentEnv,\n setCurrentEnv,\n };\n }, [\n app,\n loading,\n supported,\n manifest,\n currentEnvId,\n setCurrentEnv,\n fallbackMode,\n ]);\n\n const value = useMemo<AppEnvironmentContextValue | null>(() => {\n if (!app) {\n return null;\n }\n return { appId: app.id, state };\n }, [app, state]);\n\n return (\n <AppEnvironmentContext.Provider value={value}>\n {children}\n </AppEnvironmentContext.Provider>\n );\n}\n"],"names":["DEFAULT_DISCOVERY_PATH","storageKeyFor","app","syntheticProd","ActiveAppEnvironmentProvider","children","manifest","setManifest","useState","loading","setLoading","supported","setSupported","currentEnvId","setCurrentEnvIdState","previousIdRef","useRef","apiBaseUrl","discoveryPath","storageKey","fallbackMode","useEffect","cancelled","fetchManifest","result","stored","readStorage","initial","e","setCurrentEnv","useMemo","id","next","from","writeStorage","detail","ENVIRONMENT_CHANGED_EVENT","state","currentEnv","value","jsx","AppEnvironmentContext"],"mappings":";;;;;;AAwBA,MAAMA,IAAyB;AAE/B,SAASC,EAAcC,GAAuB;AAC5C,SAAOA,EAAI,cAAc,cAAc,aAAaA,EAAI,EAAE;AAC5D;AAEA,SAASC,EAAcD,GAAsC;AAC3D,SAAO;AAAA,IACL,IAAI;AAAA,IACJ,OAAO;AAAA,IACP,SAASA,EAAI,cAAc;AAAA,IAC3B,OAAO;AAAA,EAAA;AAEX;AAWO,SAASE,EAA6B;AAAA,EAC3C,KAAAF;AAAA,EACA,UAAAG;AACF,GAAgC;AAC9B,QAAM,CAACC,GAAUC,CAAW,IAAIC,EAAqC,IAAI,GACnE,CAACC,GAASC,CAAU,IAAIF,EAAS,EAAK,GACtC,CAACG,GAAWC,CAAY,IAAIJ,EAAS,EAAI,GACzC,CAACK,GAAcC,CAAoB,IAAIN,EAAwB,IAAI,GACnEO,IAAgBC,EAAsB,IAAI,GAE1CC,IAAaf,GAAK,YAClBgB,IACJhB,GAAK,cAAc,iBAAiBF,GAChCmB,IAAajB,IAAMD,EAAcC,CAAG,IAAI,MACxCkB,IAAelB,GAAK,cAAc,YAAY;AAEpD,EAAAmB,EAAU,MAAM;AACd,QAAI,CAACnB,KAAO,CAACe,GAAY;AACvB,MAAAV,EAAY,IAAI,GAChBK,EAAa,EAAI,GACjBE,EAAqB,IAAI,GACzBC,EAAc,UAAU;AACxB;AAAA,IACF;AAEA,QAAIO,IAAY;AAChB,WAAAZ,EAAW,EAAI,GACfE,EAAa,EAAI,GAEZW,EAAc;AAAA,MACjB,YAAAN;AAAA,MACA,eAAAC;AAAA,IAAA,CACD,EAAE,KAAK,CAACM,MAAW;AAClB,UAAIF;AACF;AAGF,UADAZ,EAAW,EAAK,GACZ,CAACc,GAAQ;AACX,QAAAjB,EAAY,IAAI,GAChBK,EAAa,EAAK,GAClBE,EAAqB,IAAI,GACzBC,EAAc,UAAU;AACxB;AAAA,MACF;AACA,MAAAR,EAAYiB,CAAM,GAClBZ,EAAa,EAAI;AACjB,YAAMa,IAASN,IAAaO,EAAYP,CAAU,IAAI,MAChDQ,IACJF,KAAUD,EAAO,aAAa,KAAK,CAACI,MAAMA,EAAE,OAAOH,CAAM,IACrDA,IACAD,EAAO;AACb,MAAAV,EAAqBa,CAAO,GAC5BZ,EAAc,UAAUY;AAAA,IAC1B,CAAC,GAEM,MAAM;AACX,MAAAL,IAAY;AAAA,IACd;AAAA,EACF,GAAG,CAACpB,GAAKe,GAAYC,GAAeC,CAAU,CAAC;AAE/C,QAAMU,IAAgBC,EAAQ,MACrB,CAACC,MAAqB;AAC3B,QAAI,CAACzB,KAAY,CAACJ;AAChB;AAEF,UAAM8B,IAAO1B,EAAS,aAAa,KAAK,CAACsB,MAAMA,EAAE,OAAOG,CAAE;AAC1D,QAAI,CAACC;AACH;AAEF,UAAMC,IAAOlB,EAAc;AAC3B,QAAIkB,MAASF,MAGbhB,EAAc,UAAUgB,GACxBjB,EAAqBiB,CAAE,GACnBZ,KACFe,EAAaf,GAAYY,CAAE,GAEzB,OAAO,SAAW,MAAa;AACjC,YAAMI,IAAwC;AAAA,QAC5C,OAAOjC,EAAI;AAAA,QACX,WAAW+B;AAAA,QACX,SAASF;AAAA,QACT,KAAKC;AAAA,MAAA;AAEP,aAAO;AAAA,QACL,IAAI,YAAYI,GAA2B,EAAE,QAAAD,GAAQ;AAAA,MAAA;AAAA,IAEzD;AAAA,EACF,GACC,CAAC7B,GAAUJ,GAAKiB,CAAU,CAAC,GAExBkB,IAAQP,EAAmC,MAAM;AACrD,QAAI,CAAC5B;AACH,aAAO,EAAE,QAAQ,OAAA;AAEnB,QAAIO;AACF,aAAO,EAAE,QAAQ,UAAA;AAEnB,QAAI,CAACE,KAAa,CAACL,KAAY,CAACO;AAC9B,aAAIO,MAAiB,WACZ,EAAE,QAAQ,OAAA,IAEZ,EAAE,QAAQ,eAAe,YAAYjB,EAAcD,CAAG,EAAA;AAE/D,UAAMoC,IACJhC,EAAS,aAAa,KAAK,CAACsB,MAAMA,EAAE,OAAOf,CAAY,KACvDP,EAAS,aAAa,CAAC;AACzB,WAAO;AAAA,MACL,QAAQ;AAAA,MACR,UAAAA;AAAA,MACA,cAAAO;AAAA,MACA,YAAAyB;AAAA,MACA,eAAAT;AAAA,IAAA;AAAA,EAEJ,GAAG;AAAA,IACD3B;AAAA,IACAO;AAAA,IACAE;AAAA,IACAL;AAAA,IACAO;AAAA,IACAgB;AAAA,IACAT;AAAA,EAAA,CACD,GAEKmB,IAAQT,EAA2C,MAClD5B,IAGE,EAAE,OAAOA,EAAI,IAAI,OAAAmC,EAAA,IAFf,MAGR,CAACnC,GAAKmC,CAAK,CAAC;AAEf,SACE,gBAAAG,EAACC,EAAsB,UAAtB,EAA+B,OAAAF,GAC7B,UAAAlC,EAAA,CACH;AAEJ;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"context.cjs","sources":["../../../../src/layouts/shell/environments/context.ts"],"sourcesContent":["import { createContext } from 'react';\n\nimport type { EnvironmentManifestStatus } from './types';\n\nexport interface AppEnvironmentContextValue {\n appId: string;\n state: EnvironmentManifestStatus;\n}\n\nexport const AppEnvironmentContext =\n createContext<AppEnvironmentContextValue | null>(null);\n"],"names":["AppEnvironmentContext","createContext"],"mappings":"yGASaA,EACXC,EAAAA,cAAiD,IAAI"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"context.js","sources":["../../../../src/layouts/shell/environments/context.ts"],"sourcesContent":["import { createContext } from 'react';\n\nimport type { EnvironmentManifestStatus } from './types';\n\nexport interface AppEnvironmentContextValue {\n appId: string;\n state: EnvironmentManifestStatus;\n}\n\nexport const AppEnvironmentContext =\n createContext<AppEnvironmentContextValue | null>(null);\n"],"names":["AppEnvironmentContext","createContext"],"mappings":";AASO,MAAMA,IACXC,EAAiD,IAAI;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react"),n=require("./context.cjs");function r(){const t=e.useContext(n.AppEnvironmentContext);if(!t)return null;switch(t.state.status){case"ready":return t.state.currentEnv;case"unsupported":return t.state.currentEnv;default:return null}}function u(){const t=e.useContext(n.AppEnvironmentContext);return t?t.state:{status:"idle"}}exports.useCurrentEnvironment=r;exports.useEnvironmentManifest=u;
|
|
2
|
+
//# sourceMappingURL=hooks.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hooks.cjs","sources":["../../../../src/layouts/shell/environments/hooks.ts"],"sourcesContent":["import { useContext } from 'react';\n\nimport { AppEnvironmentContext } from './context';\nimport type { EnvironmentDescriptor, EnvironmentManifestStatus } from './types';\n\n/**\n * Read the active app's current environment selection. Returns `null` when\n * no app is active or the manifest is still loading without a fallback.\n */\nexport function useCurrentEnvironment(): EnvironmentDescriptor | null {\n const ctx = useContext(AppEnvironmentContext);\n if (!ctx) {\n return null;\n }\n switch (ctx.state.status) {\n case 'ready':\n return ctx.state.currentEnv;\n case 'unsupported':\n return ctx.state.currentEnv;\n default:\n return null;\n }\n}\n\n/** Read the full status object — useful for the switcher itself. */\nexport function useEnvironmentManifest(): EnvironmentManifestStatus {\n const ctx = useContext(AppEnvironmentContext);\n if (!ctx) {\n return { status: 'idle' };\n }\n return ctx.state;\n}\n"],"names":["useCurrentEnvironment","ctx","useContext","AppEnvironmentContext","useEnvironmentManifest"],"mappings":"oIASO,SAASA,GAAsD,CACpE,MAAMC,EAAMC,EAAAA,WAAWC,uBAAqB,EAC5C,GAAI,CAACF,EACH,OAAO,KAET,OAAQA,EAAI,MAAM,OAAA,CAChB,IAAK,QACH,OAAOA,EAAI,MAAM,WACnB,IAAK,cACH,OAAOA,EAAI,MAAM,WACnB,QACE,OAAO,IAAA,CAEb,CAGO,SAASG,GAAoD,CAClE,MAAMH,EAAMC,EAAAA,WAAWC,uBAAqB,EAC5C,OAAKF,EAGEA,EAAI,MAFF,CAAE,OAAQ,MAAA,CAGrB"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { useContext as n } from "react";
|
|
2
|
+
import { AppEnvironmentContext as e } from "./context.js";
|
|
3
|
+
function s() {
|
|
4
|
+
const t = n(e);
|
|
5
|
+
if (!t)
|
|
6
|
+
return null;
|
|
7
|
+
switch (t.state.status) {
|
|
8
|
+
case "ready":
|
|
9
|
+
return t.state.currentEnv;
|
|
10
|
+
case "unsupported":
|
|
11
|
+
return t.state.currentEnv;
|
|
12
|
+
default:
|
|
13
|
+
return null;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
function o() {
|
|
17
|
+
const t = n(e);
|
|
18
|
+
return t ? t.state : { status: "idle" };
|
|
19
|
+
}
|
|
20
|
+
export {
|
|
21
|
+
s as useCurrentEnvironment,
|
|
22
|
+
o as useEnvironmentManifest
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=hooks.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hooks.js","sources":["../../../../src/layouts/shell/environments/hooks.ts"],"sourcesContent":["import { useContext } from 'react';\n\nimport { AppEnvironmentContext } from './context';\nimport type { EnvironmentDescriptor, EnvironmentManifestStatus } from './types';\n\n/**\n * Read the active app's current environment selection. Returns `null` when\n * no app is active or the manifest is still loading without a fallback.\n */\nexport function useCurrentEnvironment(): EnvironmentDescriptor | null {\n const ctx = useContext(AppEnvironmentContext);\n if (!ctx) {\n return null;\n }\n switch (ctx.state.status) {\n case 'ready':\n return ctx.state.currentEnv;\n case 'unsupported':\n return ctx.state.currentEnv;\n default:\n return null;\n }\n}\n\n/** Read the full status object — useful for the switcher itself. */\nexport function useEnvironmentManifest(): EnvironmentManifestStatus {\n const ctx = useContext(AppEnvironmentContext);\n if (!ctx) {\n return { status: 'idle' };\n }\n return ctx.state;\n}\n"],"names":["useCurrentEnvironment","ctx","useContext","AppEnvironmentContext","useEnvironmentManifest"],"mappings":";;AASO,SAASA,IAAsD;AACpE,QAAMC,IAAMC,EAAWC,CAAqB;AAC5C,MAAI,CAACF;AACH,WAAO;AAET,UAAQA,EAAI,MAAM,QAAA;AAAA,IAChB,KAAK;AACH,aAAOA,EAAI,MAAM;AAAA,IACnB,KAAK;AACH,aAAOA,EAAI,MAAM;AAAA,IACnB;AACE,aAAO;AAAA,EAAA;AAEb;AAGO,SAASG,IAAoD;AAClE,QAAMH,IAAMC,EAAWC,CAAqB;AAC5C,SAAKF,IAGEA,EAAI,QAFF,EAAE,QAAQ,OAAA;AAGrB;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=new Set(["default","info","warning","danger"]),b=5*60*1e3,s=new Map,f=new Map;function u(a,e){const r=a.replace(/\/+$/,""),t=e.startsWith("/")?e:`/${e}`;return`${r}${t}`}function g(a){if(!a||typeof a!="object")return null;const e=a;if(typeof e.default!="string"||e.default.length===0||!Array.isArray(e.environments)||e.environments.length===0)return null;const r=[];for(const t of e.environments){if(!t||typeof t!="object")return null;const n=t;if(typeof n.id!="string"||n.id.length===0||typeof n.label!="string"||n.label.length===0||typeof n.baseUrl!="string"||n.baseUrl.length===0)return null;let l;if(n.badge!==void 0){if(typeof n.badge!="string"||!h.has(n.badge))return null;l=n.badge}r.push({id:n.id,label:n.label,baseUrl:n.baseUrl,badge:l})}return r.some(t=>t.id===e.default)?{default:e.default,environments:r}:null}async function m(a){const e=u(a.apiBaseUrl,a.discoveryPath),r=Date.now(),t=s.get(e);if(!a.force&&t&&r-t.fetchedAt<b)return t.manifest;const n=f.get(e);if(n)return n;const l={Accept:"application/json"};t?.etag&&(l["If-None-Match"]=t.etag);const o=(async()=>{try{const i=await fetch(e,{headers:l,signal:a.signal,credentials:"omit"});if(i.status===304&&t)return s.set(e,{...t,fetchedAt:r}),t.manifest;if(!i.ok)return null;const d=await i.json(),c=g(d);return c?(s.set(e,{fetchedAt:r,manifest:c,etag:i.headers.get("ETag")}),c):null}catch{return null}finally{f.delete(e)}})();return f.set(e,o),o}function y(){s.clear(),f.clear()}exports.clearManifestCache=y;exports.fetchManifest=m;exports.manifestUrl=u;exports.validateManifest=g;
|
|
2
|
+
//# sourceMappingURL=manifest.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manifest.cjs","sources":["../../../../src/layouts/shell/environments/manifest.ts"],"sourcesContent":["import type {\n EnvironmentBadge,\n EnvironmentDescriptor,\n EnvironmentManifest,\n} from './types';\n\nconst VALID_BADGES: ReadonlySet<EnvironmentBadge> = new Set([\n 'default',\n 'info',\n 'warning',\n 'danger',\n]);\n\ninterface CacheEntry {\n fetchedAt: number;\n manifest: EnvironmentManifest;\n etag: string | null;\n}\n\nconst TTL_MS = 5 * 60 * 1000;\nconst cache = new Map<string, CacheEntry>();\nconst inflight = new Map<string, Promise<EnvironmentManifest | null>>();\n\nexport interface ManifestFetchOptions {\n apiBaseUrl: string;\n discoveryPath: string;\n signal?: AbortSignal;\n /** Skip cache + force a network round-trip (revalidates with ETag if known). */\n force?: boolean;\n}\n\n/** Compose the URL the way the spec describes. Tolerates trailing slashes. */\nexport function manifestUrl(apiBaseUrl: string, discoveryPath: string): string {\n const base = apiBaseUrl.replace(/\\/+$/, '');\n const path = discoveryPath.startsWith('/')\n ? discoveryPath\n : `/${discoveryPath}`;\n return `${base}${path}`;\n}\n\n/**\n * Validate manifest shape. Returns the parsed manifest on success, `null`\n * when the payload is malformed. Does not throw — schema mismatch is a\n * silent unsupported state per the design.\n */\nexport function validateManifest(input: unknown): EnvironmentManifest | null {\n if (!input || typeof input !== 'object') {\n return null;\n }\n const raw = input as Record<string, unknown>;\n if (typeof raw.default !== 'string' || raw.default.length === 0) {\n return null;\n }\n if (!Array.isArray(raw.environments) || raw.environments.length === 0) {\n return null;\n }\n const environments: EnvironmentDescriptor[] = [];\n for (const item of raw.environments) {\n if (!item || typeof item !== 'object') {\n return null;\n }\n const env = item as Record<string, unknown>;\n if (typeof env.id !== 'string' || env.id.length === 0) {\n return null;\n }\n if (typeof env.label !== 'string' || env.label.length === 0) {\n return null;\n }\n if (typeof env.baseUrl !== 'string' || env.baseUrl.length === 0) {\n return null;\n }\n let badge: EnvironmentBadge | undefined;\n if (env.badge !== undefined) {\n if (\n typeof env.badge !== 'string' ||\n !VALID_BADGES.has(env.badge as EnvironmentBadge)\n ) {\n return null;\n }\n badge = env.badge as EnvironmentBadge;\n }\n environments.push({\n id: env.id,\n label: env.label,\n baseUrl: env.baseUrl,\n badge,\n });\n }\n if (!environments.some((e) => e.id === raw.default)) {\n return null;\n }\n return { default: raw.default, environments };\n}\n\n/**\n * Fetch + cache a manifest. Resolves to the manifest on 2xx with a valid\n * payload, `null` on 404 / network error / schema mismatch.\n *\n * Errors are intentionally swallowed — the design makes manifest absence\n * a normal mode, not a failure.\n */\nexport async function fetchManifest(\n opts: ManifestFetchOptions,\n): Promise<EnvironmentManifest | null> {\n const url = manifestUrl(opts.apiBaseUrl, opts.discoveryPath);\n const now = Date.now();\n const cached = cache.get(url);\n if (!opts.force && cached && now - cached.fetchedAt < TTL_MS) {\n return cached.manifest;\n }\n\n const existing = inflight.get(url);\n if (existing) {\n return existing;\n }\n\n const headers: Record<string, string> = { Accept: 'application/json' };\n if (cached?.etag) {\n headers['If-None-Match'] = cached.etag;\n }\n\n const promise = (async (): Promise<EnvironmentManifest | null> => {\n try {\n const res = await fetch(url, {\n headers,\n signal: opts.signal,\n credentials: 'omit',\n });\n if (res.status === 304 && cached) {\n cache.set(url, { ...cached, fetchedAt: now });\n return cached.manifest;\n }\n if (!res.ok) {\n return null;\n }\n const json: unknown = await res.json();\n const manifest = validateManifest(json);\n if (!manifest) {\n return null;\n }\n cache.set(url, {\n fetchedAt: now,\n manifest,\n etag: res.headers.get('ETag'),\n });\n return manifest;\n } catch {\n return null;\n } finally {\n inflight.delete(url);\n }\n })();\n\n inflight.set(url, promise);\n return promise;\n}\n\n/** Test helper — exported so unit tests / specimens can reset state. */\nexport function clearManifestCache(): void {\n cache.clear();\n inflight.clear();\n}\n"],"names":["VALID_BADGES","TTL_MS","cache","inflight","manifestUrl","apiBaseUrl","discoveryPath","base","path","validateManifest","input","raw","environments","item","env","badge","e","fetchManifest","opts","url","now","cached","existing","headers","promise","res","json","manifest","clearManifestCache"],"mappings":"gFAMA,MAAMA,MAAkD,IAAI,CAC1D,UACA,OACA,UACA,QACF,CAAC,EAQKC,EAAS,EAAI,GAAK,IAClBC,MAAY,IACZC,MAAe,IAWd,SAASC,EAAYC,EAAoBC,EAA+B,CAC7E,MAAMC,EAAOF,EAAW,QAAQ,OAAQ,EAAE,EACpCG,EAAOF,EAAc,WAAW,GAAG,EACrCA,EACA,IAAIA,CAAa,GACrB,MAAO,GAAGC,CAAI,GAAGC,CAAI,EACvB,CAOO,SAASC,EAAiBC,EAA4C,CAC3E,GAAI,CAACA,GAAS,OAAOA,GAAU,SAC7B,OAAO,KAET,MAAMC,EAAMD,EAIZ,GAHI,OAAOC,EAAI,SAAY,UAAYA,EAAI,QAAQ,SAAW,GAG1D,CAAC,MAAM,QAAQA,EAAI,YAAY,GAAKA,EAAI,aAAa,SAAW,EAClE,OAAO,KAET,MAAMC,EAAwC,CAAA,EAC9C,UAAWC,KAAQF,EAAI,aAAc,CACnC,GAAI,CAACE,GAAQ,OAAOA,GAAS,SAC3B,OAAO,KAET,MAAMC,EAAMD,EAOZ,GANI,OAAOC,EAAI,IAAO,UAAYA,EAAI,GAAG,SAAW,GAGhD,OAAOA,EAAI,OAAU,UAAYA,EAAI,MAAM,SAAW,GAGtD,OAAOA,EAAI,SAAY,UAAYA,EAAI,QAAQ,SAAW,EAC5D,OAAO,KAET,IAAIC,EACJ,GAAID,EAAI,QAAU,OAAW,CAC3B,GACE,OAAOA,EAAI,OAAU,UACrB,CAACd,EAAa,IAAIc,EAAI,KAAyB,EAE/C,OAAO,KAETC,EAAQD,EAAI,KACd,CACAF,EAAa,KAAK,CAChB,GAAIE,EAAI,GACR,MAAOA,EAAI,MACX,QAASA,EAAI,QACb,MAAAC,CAAA,CACD,CACH,CACA,OAAKH,EAAa,KAAMI,GAAMA,EAAE,KAAOL,EAAI,OAAO,EAG3C,CAAE,QAASA,EAAI,QAAS,aAAAC,CAAA,EAFtB,IAGX,CASA,eAAsBK,EACpBC,EACqC,CACrC,MAAMC,EAAMf,EAAYc,EAAK,WAAYA,EAAK,aAAa,EACrDE,EAAM,KAAK,IAAA,EACXC,EAASnB,EAAM,IAAIiB,CAAG,EAC5B,GAAI,CAACD,EAAK,OAASG,GAAUD,EAAMC,EAAO,UAAYpB,EACpD,OAAOoB,EAAO,SAGhB,MAAMC,EAAWnB,EAAS,IAAIgB,CAAG,EACjC,GAAIG,EACF,OAAOA,EAGT,MAAMC,EAAkC,CAAE,OAAQ,kBAAA,EAC9CF,GAAQ,OACVE,EAAQ,eAAe,EAAIF,EAAO,MAGpC,MAAMG,GAAW,SAAiD,CAChE,GAAI,CACF,MAAMC,EAAM,MAAM,MAAMN,EAAK,CAC3B,QAAAI,EACA,OAAQL,EAAK,OACb,YAAa,MAAA,CACd,EACD,GAAIO,EAAI,SAAW,KAAOJ,EACxB,OAAAnB,EAAM,IAAIiB,EAAK,CAAE,GAAGE,EAAQ,UAAWD,EAAK,EACrCC,EAAO,SAEhB,GAAI,CAACI,EAAI,GACP,OAAO,KAET,MAAMC,EAAgB,MAAMD,EAAI,KAAA,EAC1BE,EAAWlB,EAAiBiB,CAAI,EACtC,OAAKC,GAGLzB,EAAM,IAAIiB,EAAK,CACb,UAAWC,EACX,SAAAO,EACA,KAAMF,EAAI,QAAQ,IAAI,MAAM,CAAA,CAC7B,EACME,GAPE,IAQX,MAAQ,CACN,OAAO,IACT,QAAA,CACExB,EAAS,OAAOgB,CAAG,CACrB,CACF,GAAA,EAEA,OAAAhB,EAAS,IAAIgB,EAAKK,CAAO,EAClBA,CACT,CAGO,SAASI,GAA2B,CACzC1B,EAAM,MAAA,EACNC,EAAS,MAAA,CACX"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
const g = /* @__PURE__ */ new Set([
|
|
2
|
+
"default",
|
|
3
|
+
"info",
|
|
4
|
+
"warning",
|
|
5
|
+
"danger"
|
|
6
|
+
]), d = 5 * 60 * 1e3, i = /* @__PURE__ */ new Map(), f = /* @__PURE__ */ new Map();
|
|
7
|
+
function h(r, e) {
|
|
8
|
+
const a = r.replace(/\/+$/, ""), t = e.startsWith("/") ? e : `/${e}`;
|
|
9
|
+
return `${a}${t}`;
|
|
10
|
+
}
|
|
11
|
+
function b(r) {
|
|
12
|
+
if (!r || typeof r != "object")
|
|
13
|
+
return null;
|
|
14
|
+
const e = r;
|
|
15
|
+
if (typeof e.default != "string" || e.default.length === 0 || !Array.isArray(e.environments) || e.environments.length === 0)
|
|
16
|
+
return null;
|
|
17
|
+
const a = [];
|
|
18
|
+
for (const t of e.environments) {
|
|
19
|
+
if (!t || typeof t != "object")
|
|
20
|
+
return null;
|
|
21
|
+
const n = t;
|
|
22
|
+
if (typeof n.id != "string" || n.id.length === 0 || typeof n.label != "string" || n.label.length === 0 || typeof n.baseUrl != "string" || n.baseUrl.length === 0)
|
|
23
|
+
return null;
|
|
24
|
+
let l;
|
|
25
|
+
if (n.badge !== void 0) {
|
|
26
|
+
if (typeof n.badge != "string" || !g.has(n.badge))
|
|
27
|
+
return null;
|
|
28
|
+
l = n.badge;
|
|
29
|
+
}
|
|
30
|
+
a.push({
|
|
31
|
+
id: n.id,
|
|
32
|
+
label: n.label,
|
|
33
|
+
baseUrl: n.baseUrl,
|
|
34
|
+
badge: l
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
return a.some((t) => t.id === e.default) ? { default: e.default, environments: a } : null;
|
|
38
|
+
}
|
|
39
|
+
async function p(r) {
|
|
40
|
+
const e = h(r.apiBaseUrl, r.discoveryPath), a = Date.now(), t = i.get(e);
|
|
41
|
+
if (!r.force && t && a - t.fetchedAt < d)
|
|
42
|
+
return t.manifest;
|
|
43
|
+
const n = f.get(e);
|
|
44
|
+
if (n)
|
|
45
|
+
return n;
|
|
46
|
+
const l = { Accept: "application/json" };
|
|
47
|
+
t?.etag && (l["If-None-Match"] = t.etag);
|
|
48
|
+
const c = (async () => {
|
|
49
|
+
try {
|
|
50
|
+
const s = await fetch(e, {
|
|
51
|
+
headers: l,
|
|
52
|
+
signal: r.signal,
|
|
53
|
+
credentials: "omit"
|
|
54
|
+
});
|
|
55
|
+
if (s.status === 304 && t)
|
|
56
|
+
return i.set(e, { ...t, fetchedAt: a }), t.manifest;
|
|
57
|
+
if (!s.ok)
|
|
58
|
+
return null;
|
|
59
|
+
const u = await s.json(), o = b(u);
|
|
60
|
+
return o ? (i.set(e, {
|
|
61
|
+
fetchedAt: a,
|
|
62
|
+
manifest: o,
|
|
63
|
+
etag: s.headers.get("ETag")
|
|
64
|
+
}), o) : null;
|
|
65
|
+
} catch {
|
|
66
|
+
return null;
|
|
67
|
+
} finally {
|
|
68
|
+
f.delete(e);
|
|
69
|
+
}
|
|
70
|
+
})();
|
|
71
|
+
return f.set(e, c), c;
|
|
72
|
+
}
|
|
73
|
+
function m() {
|
|
74
|
+
i.clear(), f.clear();
|
|
75
|
+
}
|
|
76
|
+
export {
|
|
77
|
+
m as clearManifestCache,
|
|
78
|
+
p as fetchManifest,
|
|
79
|
+
h as manifestUrl,
|
|
80
|
+
b as validateManifest
|
|
81
|
+
};
|
|
82
|
+
//# sourceMappingURL=manifest.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manifest.js","sources":["../../../../src/layouts/shell/environments/manifest.ts"],"sourcesContent":["import type {\n EnvironmentBadge,\n EnvironmentDescriptor,\n EnvironmentManifest,\n} from './types';\n\nconst VALID_BADGES: ReadonlySet<EnvironmentBadge> = new Set([\n 'default',\n 'info',\n 'warning',\n 'danger',\n]);\n\ninterface CacheEntry {\n fetchedAt: number;\n manifest: EnvironmentManifest;\n etag: string | null;\n}\n\nconst TTL_MS = 5 * 60 * 1000;\nconst cache = new Map<string, CacheEntry>();\nconst inflight = new Map<string, Promise<EnvironmentManifest | null>>();\n\nexport interface ManifestFetchOptions {\n apiBaseUrl: string;\n discoveryPath: string;\n signal?: AbortSignal;\n /** Skip cache + force a network round-trip (revalidates with ETag if known). */\n force?: boolean;\n}\n\n/** Compose the URL the way the spec describes. Tolerates trailing slashes. */\nexport function manifestUrl(apiBaseUrl: string, discoveryPath: string): string {\n const base = apiBaseUrl.replace(/\\/+$/, '');\n const path = discoveryPath.startsWith('/')\n ? discoveryPath\n : `/${discoveryPath}`;\n return `${base}${path}`;\n}\n\n/**\n * Validate manifest shape. Returns the parsed manifest on success, `null`\n * when the payload is malformed. Does not throw — schema mismatch is a\n * silent unsupported state per the design.\n */\nexport function validateManifest(input: unknown): EnvironmentManifest | null {\n if (!input || typeof input !== 'object') {\n return null;\n }\n const raw = input as Record<string, unknown>;\n if (typeof raw.default !== 'string' || raw.default.length === 0) {\n return null;\n }\n if (!Array.isArray(raw.environments) || raw.environments.length === 0) {\n return null;\n }\n const environments: EnvironmentDescriptor[] = [];\n for (const item of raw.environments) {\n if (!item || typeof item !== 'object') {\n return null;\n }\n const env = item as Record<string, unknown>;\n if (typeof env.id !== 'string' || env.id.length === 0) {\n return null;\n }\n if (typeof env.label !== 'string' || env.label.length === 0) {\n return null;\n }\n if (typeof env.baseUrl !== 'string' || env.baseUrl.length === 0) {\n return null;\n }\n let badge: EnvironmentBadge | undefined;\n if (env.badge !== undefined) {\n if (\n typeof env.badge !== 'string' ||\n !VALID_BADGES.has(env.badge as EnvironmentBadge)\n ) {\n return null;\n }\n badge = env.badge as EnvironmentBadge;\n }\n environments.push({\n id: env.id,\n label: env.label,\n baseUrl: env.baseUrl,\n badge,\n });\n }\n if (!environments.some((e) => e.id === raw.default)) {\n return null;\n }\n return { default: raw.default, environments };\n}\n\n/**\n * Fetch + cache a manifest. Resolves to the manifest on 2xx with a valid\n * payload, `null` on 404 / network error / schema mismatch.\n *\n * Errors are intentionally swallowed — the design makes manifest absence\n * a normal mode, not a failure.\n */\nexport async function fetchManifest(\n opts: ManifestFetchOptions,\n): Promise<EnvironmentManifest | null> {\n const url = manifestUrl(opts.apiBaseUrl, opts.discoveryPath);\n const now = Date.now();\n const cached = cache.get(url);\n if (!opts.force && cached && now - cached.fetchedAt < TTL_MS) {\n return cached.manifest;\n }\n\n const existing = inflight.get(url);\n if (existing) {\n return existing;\n }\n\n const headers: Record<string, string> = { Accept: 'application/json' };\n if (cached?.etag) {\n headers['If-None-Match'] = cached.etag;\n }\n\n const promise = (async (): Promise<EnvironmentManifest | null> => {\n try {\n const res = await fetch(url, {\n headers,\n signal: opts.signal,\n credentials: 'omit',\n });\n if (res.status === 304 && cached) {\n cache.set(url, { ...cached, fetchedAt: now });\n return cached.manifest;\n }\n if (!res.ok) {\n return null;\n }\n const json: unknown = await res.json();\n const manifest = validateManifest(json);\n if (!manifest) {\n return null;\n }\n cache.set(url, {\n fetchedAt: now,\n manifest,\n etag: res.headers.get('ETag'),\n });\n return manifest;\n } catch {\n return null;\n } finally {\n inflight.delete(url);\n }\n })();\n\n inflight.set(url, promise);\n return promise;\n}\n\n/** Test helper — exported so unit tests / specimens can reset state. */\nexport function clearManifestCache(): void {\n cache.clear();\n inflight.clear();\n}\n"],"names":["VALID_BADGES","TTL_MS","cache","inflight","manifestUrl","apiBaseUrl","discoveryPath","base","path","validateManifest","input","raw","environments","item","env","badge","e","fetchManifest","opts","url","now","cached","existing","headers","promise","res","json","manifest","clearManifestCache"],"mappings":"AAMA,MAAMA,wBAAkD,IAAI;AAAA,EAC1D;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC,GAQKC,IAAS,IAAI,KAAK,KAClBC,wBAAY,IAAA,GACZC,wBAAe,IAAA;AAWd,SAASC,EAAYC,GAAoBC,GAA+B;AAC7E,QAAMC,IAAOF,EAAW,QAAQ,QAAQ,EAAE,GACpCG,IAAOF,EAAc,WAAW,GAAG,IACrCA,IACA,IAAIA,CAAa;AACrB,SAAO,GAAGC,CAAI,GAAGC,CAAI;AACvB;AAOO,SAASC,EAAiBC,GAA4C;AAC3E,MAAI,CAACA,KAAS,OAAOA,KAAU;AAC7B,WAAO;AAET,QAAMC,IAAMD;AAIZ,MAHI,OAAOC,EAAI,WAAY,YAAYA,EAAI,QAAQ,WAAW,KAG1D,CAAC,MAAM,QAAQA,EAAI,YAAY,KAAKA,EAAI,aAAa,WAAW;AAClE,WAAO;AAET,QAAMC,IAAwC,CAAA;AAC9C,aAAWC,KAAQF,EAAI,cAAc;AACnC,QAAI,CAACE,KAAQ,OAAOA,KAAS;AAC3B,aAAO;AAET,UAAMC,IAAMD;AAOZ,QANI,OAAOC,EAAI,MAAO,YAAYA,EAAI,GAAG,WAAW,KAGhD,OAAOA,EAAI,SAAU,YAAYA,EAAI,MAAM,WAAW,KAGtD,OAAOA,EAAI,WAAY,YAAYA,EAAI,QAAQ,WAAW;AAC5D,aAAO;AAET,QAAIC;AACJ,QAAID,EAAI,UAAU,QAAW;AAC3B,UACE,OAAOA,EAAI,SAAU,YACrB,CAACd,EAAa,IAAIc,EAAI,KAAyB;AAE/C,eAAO;AAET,MAAAC,IAAQD,EAAI;AAAA,IACd;AACA,IAAAF,EAAa,KAAK;AAAA,MAChB,IAAIE,EAAI;AAAA,MACR,OAAOA,EAAI;AAAA,MACX,SAASA,EAAI;AAAA,MACb,OAAAC;AAAA,IAAA,CACD;AAAA,EACH;AACA,SAAKH,EAAa,KAAK,CAACI,MAAMA,EAAE,OAAOL,EAAI,OAAO,IAG3C,EAAE,SAASA,EAAI,SAAS,cAAAC,EAAA,IAFtB;AAGX;AASA,eAAsBK,EACpBC,GACqC;AACrC,QAAMC,IAAMf,EAAYc,EAAK,YAAYA,EAAK,aAAa,GACrDE,IAAM,KAAK,IAAA,GACXC,IAASnB,EAAM,IAAIiB,CAAG;AAC5B,MAAI,CAACD,EAAK,SAASG,KAAUD,IAAMC,EAAO,YAAYpB;AACpD,WAAOoB,EAAO;AAGhB,QAAMC,IAAWnB,EAAS,IAAIgB,CAAG;AACjC,MAAIG;AACF,WAAOA;AAGT,QAAMC,IAAkC,EAAE,QAAQ,mBAAA;AAClD,EAAIF,GAAQ,SACVE,EAAQ,eAAe,IAAIF,EAAO;AAGpC,QAAMG,KAAW,YAAiD;AAChE,QAAI;AACF,YAAMC,IAAM,MAAM,MAAMN,GAAK;AAAA,QAC3B,SAAAI;AAAA,QACA,QAAQL,EAAK;AAAA,QACb,aAAa;AAAA,MAAA,CACd;AACD,UAAIO,EAAI,WAAW,OAAOJ;AACxB,eAAAnB,EAAM,IAAIiB,GAAK,EAAE,GAAGE,GAAQ,WAAWD,GAAK,GACrCC,EAAO;AAEhB,UAAI,CAACI,EAAI;AACP,eAAO;AAET,YAAMC,IAAgB,MAAMD,EAAI,KAAA,GAC1BE,IAAWlB,EAAiBiB,CAAI;AACtC,aAAKC,KAGLzB,EAAM,IAAIiB,GAAK;AAAA,QACb,WAAWC;AAAA,QACX,UAAAO;AAAA,QACA,MAAMF,EAAI,QAAQ,IAAI,MAAM;AAAA,MAAA,CAC7B,GACME,KAPE;AAAA,IAQX,QAAQ;AACN,aAAO;AAAA,IACT,UAAA;AACE,MAAAxB,EAAS,OAAOgB,CAAG;AAAA,IACrB;AAAA,EACF,GAAA;AAEA,SAAAhB,EAAS,IAAIgB,GAAKK,CAAO,GAClBA;AACT;AAGO,SAASI,IAA2B;AACzC,EAAA1B,EAAM,MAAA,GACNC,EAAS,MAAA;AACX;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.cjs","sources":["../../../../src/layouts/shell/environments/types.ts"],"sourcesContent":["/**\n * Backend-declared environment discovery — public types.\n *\n * Each AegisApp may opt-in to environment discovery by setting `apiBaseUrl`\n * + (optionally) `environments`. The shell fetches a manifest from\n * `<apiBaseUrl><discoveryPath>` (default `/.well-known/aegis-environments.json`)\n * and surfaces the env list through the `<EnvironmentSwitcher>` mounted in\n * the top header. Apps subscribe to the `app.environmentChanged` runtime\n * event (or read `useCurrentEnvironment()`) to react to switches.\n */\n\nexport type EnvironmentBadge = 'default' | 'info' | 'warning' | 'danger';\n\nexport interface EnvironmentDescriptor {\n id: string;\n label: string;\n baseUrl: string;\n badge?: EnvironmentBadge;\n}\n\nexport interface EnvironmentManifest {\n default: string;\n environments: EnvironmentDescriptor[];\n}\n\nexport interface AegisAppEnvironmentsConfig {\n /** Path appended to `apiBaseUrl`. Default `/.well-known/aegis-environments.json`. */\n discoveryPath?: string;\n /**\n * What to do when the manifest is missing / 404 / schema invalid.\n * - `production` (default) — show a single synthetic prod env, hide the switcher.\n * - `hidden` — render nothing.\n */\n fallback?: 'production' | 'hidden';\n /** localStorage key. Default `aegis.env.${app.id}`. */\n storageKey?: string;\n}\n\nexport type EnvironmentManifestStatus =\n | { status: 'idle' }\n | { status: 'loading' }\n | {\n status: 'ready';\n manifest: EnvironmentManifest;\n currentEnvId: string;\n currentEnv: EnvironmentDescriptor;\n setCurrentEnv: (id: string) => void;\n }\n | {\n status: 'unsupported';\n currentEnv: EnvironmentDescriptor;\n };\n\nexport interface EnvironmentChangedEventDetail {\n appId: string;\n fromEnvId: string | null;\n toEnvId: string;\n env: EnvironmentDescriptor;\n}\n\n/** Window-level event name for env switch broadcasts. */\nexport const ENVIRONMENT_CHANGED_EVENT = 'app.environmentChanged';\n"],"names":["ENVIRONMENT_CHANGED_EVENT"],"mappings":"gFA6DO,MAAMA,EAA4B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sources":["../../../../src/layouts/shell/environments/types.ts"],"sourcesContent":["/**\n * Backend-declared environment discovery — public types.\n *\n * Each AegisApp may opt-in to environment discovery by setting `apiBaseUrl`\n * + (optionally) `environments`. The shell fetches a manifest from\n * `<apiBaseUrl><discoveryPath>` (default `/.well-known/aegis-environments.json`)\n * and surfaces the env list through the `<EnvironmentSwitcher>` mounted in\n * the top header. Apps subscribe to the `app.environmentChanged` runtime\n * event (or read `useCurrentEnvironment()`) to react to switches.\n */\n\nexport type EnvironmentBadge = 'default' | 'info' | 'warning' | 'danger';\n\nexport interface EnvironmentDescriptor {\n id: string;\n label: string;\n baseUrl: string;\n badge?: EnvironmentBadge;\n}\n\nexport interface EnvironmentManifest {\n default: string;\n environments: EnvironmentDescriptor[];\n}\n\nexport interface AegisAppEnvironmentsConfig {\n /** Path appended to `apiBaseUrl`. Default `/.well-known/aegis-environments.json`. */\n discoveryPath?: string;\n /**\n * What to do when the manifest is missing / 404 / schema invalid.\n * - `production` (default) — show a single synthetic prod env, hide the switcher.\n * - `hidden` — render nothing.\n */\n fallback?: 'production' | 'hidden';\n /** localStorage key. Default `aegis.env.${app.id}`. */\n storageKey?: string;\n}\n\nexport type EnvironmentManifestStatus =\n | { status: 'idle' }\n | { status: 'loading' }\n | {\n status: 'ready';\n manifest: EnvironmentManifest;\n currentEnvId: string;\n currentEnv: EnvironmentDescriptor;\n setCurrentEnv: (id: string) => void;\n }\n | {\n status: 'unsupported';\n currentEnv: EnvironmentDescriptor;\n };\n\nexport interface EnvironmentChangedEventDetail {\n appId: string;\n fromEnvId: string | null;\n toEnvId: string;\n env: EnvironmentDescriptor;\n}\n\n/** Window-level event name for env switch broadcasts. */\nexport const ENVIRONMENT_CHANGED_EVENT = 'app.environmentChanged';\n"],"names":["ENVIRONMENT_CHANGED_EVENT"],"mappings":"AA6DO,MAAMA,IAA4B;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function c(t){return t.replace(/\/+$/,"")}function r(t,e){const a=c(t),o=n(e).replace(/^\/+/,""),i=e.slice(n(e).length);return`${o?`${a}/${o}`:a||"/"}${i}`}function n(t){const e=t.indexOf("?");return e===-1?t:t.slice(0,e)}exports.joinPath=r;exports.normalizeBasePath=c;exports.pathOf=n;
|
|
2
|
+
//# sourceMappingURL=paths.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"paths.cjs","sources":["../../../src/layouts/shell/paths.ts"],"sourcesContent":["/** Strips trailing slashes, so an app mounted at `/` has the basePath `''`. */\nexport function normalizeBasePath(basePath: string): string {\n return basePath.replace(/\\/+$/, '');\n}\n\n/**\n * Resolves an app-relative path against a basePath. Leading slashes on\n * `rel` are app-root-relative, and an empty `rel` is the app root (`/` for\n * an app mounted at the root). A query string on `rel` is kept and appended\n * after the joined path, so `?x=1` resolves to the app root with that query.\n */\nexport function joinPath(basePath: string, rel: string): string {\n const base = normalizeBasePath(basePath);\n const path = pathOf(rel).replace(/^\\/+/, '');\n const query = rel.slice(pathOf(rel).length);\n return `${path ? `${base}/${path}` : base || '/'}${query}`;\n}\n\n/** The path part of an app-relative link, without its query string. */\nexport function pathOf(rel: string): string {\n const queryStart = rel.indexOf('?');\n return queryStart === -1 ? rel : rel.slice(0, queryStart);\n}\n"],"names":["normalizeBasePath","basePath","joinPath","rel","base","path","pathOf","query","queryStart"],"mappings":"gFACO,SAASA,EAAkBC,EAA0B,CAC1D,OAAOA,EAAS,QAAQ,OAAQ,EAAE,CACpC,CAQO,SAASC,EAASD,EAAkBE,EAAqB,CAC9D,MAAMC,EAAOJ,EAAkBC,CAAQ,EACjCI,EAAOC,EAAOH,CAAG,EAAE,QAAQ,OAAQ,EAAE,EACrCI,EAAQJ,EAAI,MAAMG,EAAOH,CAAG,EAAE,MAAM,EAC1C,MAAO,GAAGE,EAAO,GAAGD,CAAI,IAAIC,CAAI,GAAKD,GAAQ,GAAG,GAAGG,CAAK,EAC1D,CAGO,SAASD,EAAOH,EAAqB,CAC1C,MAAMK,EAAaL,EAAI,QAAQ,GAAG,EAClC,OAAOK,IAAe,GAAKL,EAAMA,EAAI,MAAM,EAAGK,CAAU,CAC1D"}
|
|
@@ -3,6 +3,9 @@ export declare function normalizeBasePath(basePath: string): string;
|
|
|
3
3
|
/**
|
|
4
4
|
* Resolves an app-relative path against a basePath. Leading slashes on
|
|
5
5
|
* `rel` are app-root-relative, and an empty `rel` is the app root (`/` for
|
|
6
|
-
* an app mounted at the root).
|
|
6
|
+
* an app mounted at the root). A query string on `rel` is kept and appended
|
|
7
|
+
* after the joined path, so `?x=1` resolves to the app root with that query.
|
|
7
8
|
*/
|
|
8
9
|
export declare function joinPath(basePath: string, rel: string): string;
|
|
10
|
+
/** The path part of an app-relative link, without its query string. */
|
|
11
|
+
export declare function pathOf(rel: string): string;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
function r(t) {
|
|
2
|
+
return t.replace(/\/+$/, "");
|
|
3
|
+
}
|
|
4
|
+
function i(t, n) {
|
|
5
|
+
const e = r(t), c = a(n).replace(/^\/+/, ""), o = n.slice(a(n).length);
|
|
6
|
+
return `${c ? `${e}/${c}` : e || "/"}${o}`;
|
|
7
|
+
}
|
|
8
|
+
function a(t) {
|
|
9
|
+
const n = t.indexOf("?");
|
|
10
|
+
return n === -1 ? t : t.slice(0, n);
|
|
11
|
+
}
|
|
12
|
+
export {
|
|
13
|
+
i as joinPath,
|
|
14
|
+
r as normalizeBasePath,
|
|
15
|
+
a as pathOf
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=paths.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"paths.js","sources":["../../../src/layouts/shell/paths.ts"],"sourcesContent":["/** Strips trailing slashes, so an app mounted at `/` has the basePath `''`. */\nexport function normalizeBasePath(basePath: string): string {\n return basePath.replace(/\\/+$/, '');\n}\n\n/**\n * Resolves an app-relative path against a basePath. Leading slashes on\n * `rel` are app-root-relative, and an empty `rel` is the app root (`/` for\n * an app mounted at the root). A query string on `rel` is kept and appended\n * after the joined path, so `?x=1` resolves to the app root with that query.\n */\nexport function joinPath(basePath: string, rel: string): string {\n const base = normalizeBasePath(basePath);\n const path = pathOf(rel).replace(/^\\/+/, '');\n const query = rel.slice(pathOf(rel).length);\n return `${path ? `${base}/${path}` : base || '/'}${query}`;\n}\n\n/** The path part of an app-relative link, without its query string. */\nexport function pathOf(rel: string): string {\n const queryStart = rel.indexOf('?');\n return queryStart === -1 ? rel : rel.slice(0, queryStart);\n}\n"],"names":["normalizeBasePath","basePath","joinPath","rel","base","path","pathOf","query","queryStart"],"mappings":"AACO,SAASA,EAAkBC,GAA0B;AAC1D,SAAOA,EAAS,QAAQ,QAAQ,EAAE;AACpC;AAQO,SAASC,EAASD,GAAkBE,GAAqB;AAC9D,QAAMC,IAAOJ,EAAkBC,CAAQ,GACjCI,IAAOC,EAAOH,CAAG,EAAE,QAAQ,QAAQ,EAAE,GACrCI,IAAQJ,EAAI,MAAMG,EAAOH,CAAG,EAAE,MAAM;AAC1C,SAAO,GAAGE,IAAO,GAAGD,CAAI,IAAIC,CAAI,KAAKD,KAAQ,GAAG,GAAGG,CAAK;AAC1D;AAGO,SAASD,EAAOH,GAAqB;AAC1C,QAAMK,IAAaL,EAAI,QAAQ,GAAG;AAClC,SAAOK,MAAe,KAAKL,IAAMA,EAAI,MAAM,GAAGK,CAAU;AAC1D;"}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { RouteObject } from 'react-router-dom';
|
|
3
|
+
import { AegisRuntime } from '../../agent/core/runtime';
|
|
3
4
|
import { Command } from '../../commands';
|
|
5
|
+
import { AmbientBackgroundVariant } from '../../components/ui/AmbientBackground';
|
|
4
6
|
import { AegisAppEnvironmentsConfig } from './environments/types';
|
|
5
7
|
/**
|
|
6
8
|
* One entry in an app's internal left-nav. Sub-app authors only have to
|
|
@@ -58,6 +60,11 @@ export interface AegisApp {
|
|
|
58
60
|
* shell render, blowing away its state.
|
|
59
61
|
*/
|
|
60
62
|
wrap?: (children: ReactNode) => ReactNode;
|
|
63
|
+
/**
|
|
64
|
+
* Set false to drop the shell's breadcrumb bar while this app is active,
|
|
65
|
+
* for apps whose pages render their own `<Breadcrumb>`. Default true.
|
|
66
|
+
*/
|
|
67
|
+
breadcrumbBar?: boolean;
|
|
61
68
|
/** Optional one-line description shown in app pickers. */
|
|
62
69
|
description?: string;
|
|
63
70
|
/**
|
|
@@ -152,6 +159,19 @@ export interface AegisShellProps {
|
|
|
152
159
|
headerCenter?: ReactNode;
|
|
153
160
|
/** Slot rendered in the top header right side, before the user menu. */
|
|
154
161
|
headerActions?: ReactNode;
|
|
162
|
+
/**
|
|
163
|
+
* Renders the app launcher in the top header. Default true; a single-app
|
|
164
|
+
* site sets false, since the launcher would only list that app.
|
|
165
|
+
*/
|
|
166
|
+
appSwitcher?: boolean;
|
|
167
|
+
/** Gives the sticky top header a shadow once the page scrolls. */
|
|
168
|
+
elevateHeaderOnScroll?: boolean;
|
|
169
|
+
/**
|
|
170
|
+
* Draws an `AmbientBackground` of this variant across the top of the
|
|
171
|
+
* shell, beneath the glass header and the page content. Omit it for a
|
|
172
|
+
* plain page background.
|
|
173
|
+
*/
|
|
174
|
+
ambient?: AmbientBackgroundVariant;
|
|
155
175
|
/**
|
|
156
176
|
* When set, a notification bell is rendered in the top header (between
|
|
157
177
|
* `headerActions` and the user menu) and clicking "View all" routes to
|
|
@@ -171,11 +191,18 @@ export interface AegisShellProps {
|
|
|
171
191
|
enableCommandPalette?: boolean;
|
|
172
192
|
/**
|
|
173
193
|
* When provided, AegisShell renders the node (typically <AgentPanel/>
|
|
174
|
-
* filled from
|
|
194
|
+
* filled from useAgentChat()) as a right-side column while the agent
|
|
175
195
|
* context's `panelOpen` is true — at ≤768 px as an overlay below the
|
|
176
196
|
* header. A header toggle flips it through `setPanelOpen`. Requires
|
|
177
|
-
* <
|
|
197
|
+
* <AgentChatProvider/> above the shell; without one nothing renders and a
|
|
178
198
|
* warning is logged.
|
|
179
199
|
*/
|
|
180
200
|
agentPanel?: ReactNode;
|
|
201
|
+
/**
|
|
202
|
+
* The agent runtime the shell's primitives register with. Pass one you
|
|
203
|
+
* created with `createAegisRuntime()` to connect it to a transport such
|
|
204
|
+
* as `connectAegisBridge` from `@lincyaw/aegis-ui/transports`; omitted,
|
|
205
|
+
* the shell creates its own. Read once when the shell mounts.
|
|
206
|
+
*/
|
|
207
|
+
agentRuntime?: AegisRuntime;
|
|
181
208
|
}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react"),u=require("react-router-dom"),n=require("./activeAppContext.cjs"),c=require("./paths.cjs");function a(){const{basePath:e}=n.useActiveApp();return s.useCallback(t=>t.startsWith("http://")||t.startsWith("https://")||t.startsWith("mailto:")||t.startsWith("#")?t:c.joinPath(e,t),[e])}function p(){const e=u.useNavigate(),t=a();return s.useCallback((r,i)=>{e(t(r),i)},[e,t])}exports.useAppHref=a;exports.useAppNavigate=p;
|
|
2
|
+
//# sourceMappingURL=useAppNavigate.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useAppNavigate.cjs","sources":["../../../src/layouts/shell/useAppNavigate.ts"],"sourcesContent":["import { useCallback } from 'react';\n\nimport { type NavigateOptions, useNavigate } from 'react-router-dom';\n\nimport { useActiveApp } from './activeAppContext';\nimport { joinPath } from './paths';\n\n/**\n * Resolves an app-relative path against the active app's `basePath`.\n *\n * - A leading `/` is treated as app-root-relative: `link('/projects')` and\n * `link('projects')` both produce `${basePath}/projects`.\n * - An empty string resolves to the app root.\n * - Fully qualified URLs (http://, mailto:) and hash-only links pass\n * through untouched.\n *\n * Use this inside an AegisShell-mounted app instead of hardcoding the\n * basePath, so the app stays portable if it gets re-mounted elsewhere.\n */\nexport function useAppHref(): (to: string) => string {\n const { basePath } = useActiveApp();\n return useCallback(\n (to: string) =>\n to.startsWith('http://') ||\n to.startsWith('https://') ||\n to.startsWith('mailto:') ||\n to.startsWith('#')\n ? to\n : joinPath(basePath, to),\n [basePath],\n );\n}\n\n/**\n * Drop-in replacement for `useNavigate` that resolves paths against the\n * active app's `basePath`. App code should never write absolute portal\n * paths like `navigate('/projects')` — the shell decides where each app\n * is mounted.\n */\nexport function useAppNavigate(): (\n to: string,\n options?: NavigateOptions,\n) => void {\n const navigate = useNavigate();\n const href = useAppHref();\n return useCallback(\n (to: string, options?: NavigateOptions) => {\n navigate(href(to), options);\n },\n [navigate, href],\n );\n}\n"],"names":["useAppHref","basePath","useActiveApp","useCallback","to","joinPath","useAppNavigate","navigate","useNavigate","href","options"],"mappings":"oMAmBO,SAASA,GAAqC,CACnD,KAAM,CAAE,SAAAC,CAAA,EAAaC,eAAA,EACrB,OAAOC,EAAAA,YACJC,GACCA,EAAG,WAAW,SAAS,GACvBA,EAAG,WAAW,UAAU,GACxBA,EAAG,WAAW,SAAS,GACvBA,EAAG,WAAW,GAAG,EACbA,EACAC,EAAAA,SAASJ,EAAUG,CAAE,EAC3B,CAACH,CAAQ,CAAA,CAEb,CAQO,SAASK,GAGN,CACR,MAAMC,EAAWC,EAAAA,YAAA,EACXC,EAAOT,EAAA,EACb,OAAOG,EAAAA,YACL,CAACC,EAAYM,IAA8B,CACzCH,EAASE,EAAKL,CAAE,EAAGM,CAAO,CAC5B,EACA,CAACH,EAAUE,CAAI,CAAA,CAEnB"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { useCallback as s } from "react";
|
|
2
|
+
import { useNavigate as e } from "react-router-dom";
|
|
3
|
+
import { useActiveApp as p } from "./activeAppContext.js";
|
|
4
|
+
import { joinPath as n } from "./paths.js";
|
|
5
|
+
function o() {
|
|
6
|
+
const { basePath: r } = p();
|
|
7
|
+
return s(
|
|
8
|
+
(t) => t.startsWith("http://") || t.startsWith("https://") || t.startsWith("mailto:") || t.startsWith("#") ? t : n(r, t),
|
|
9
|
+
[r]
|
|
10
|
+
);
|
|
11
|
+
}
|
|
12
|
+
function c() {
|
|
13
|
+
const r = e(), t = o();
|
|
14
|
+
return s(
|
|
15
|
+
(a, i) => {
|
|
16
|
+
r(t(a), i);
|
|
17
|
+
},
|
|
18
|
+
[r, t]
|
|
19
|
+
);
|
|
20
|
+
}
|
|
21
|
+
export {
|
|
22
|
+
o as useAppHref,
|
|
23
|
+
c as useAppNavigate
|
|
24
|
+
};
|
|
25
|
+
//# sourceMappingURL=useAppNavigate.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useAppNavigate.js","sources":["../../../src/layouts/shell/useAppNavigate.ts"],"sourcesContent":["import { useCallback } from 'react';\n\nimport { type NavigateOptions, useNavigate } from 'react-router-dom';\n\nimport { useActiveApp } from './activeAppContext';\nimport { joinPath } from './paths';\n\n/**\n * Resolves an app-relative path against the active app's `basePath`.\n *\n * - A leading `/` is treated as app-root-relative: `link('/projects')` and\n * `link('projects')` both produce `${basePath}/projects`.\n * - An empty string resolves to the app root.\n * - Fully qualified URLs (http://, mailto:) and hash-only links pass\n * through untouched.\n *\n * Use this inside an AegisShell-mounted app instead of hardcoding the\n * basePath, so the app stays portable if it gets re-mounted elsewhere.\n */\nexport function useAppHref(): (to: string) => string {\n const { basePath } = useActiveApp();\n return useCallback(\n (to: string) =>\n to.startsWith('http://') ||\n to.startsWith('https://') ||\n to.startsWith('mailto:') ||\n to.startsWith('#')\n ? to\n : joinPath(basePath, to),\n [basePath],\n );\n}\n\n/**\n * Drop-in replacement for `useNavigate` that resolves paths against the\n * active app's `basePath`. App code should never write absolute portal\n * paths like `navigate('/projects')` — the shell decides where each app\n * is mounted.\n */\nexport function useAppNavigate(): (\n to: string,\n options?: NavigateOptions,\n) => void {\n const navigate = useNavigate();\n const href = useAppHref();\n return useCallback(\n (to: string, options?: NavigateOptions) => {\n navigate(href(to), options);\n },\n [navigate, href],\n );\n}\n"],"names":["useAppHref","basePath","useActiveApp","useCallback","to","joinPath","useAppNavigate","navigate","useNavigate","href","options"],"mappings":";;;;AAmBO,SAASA,IAAqC;AACnD,QAAM,EAAE,UAAAC,EAAA,IAAaC,EAAA;AACrB,SAAOC;AAAA,IACL,CAACC,MACCA,EAAG,WAAW,SAAS,KACvBA,EAAG,WAAW,UAAU,KACxBA,EAAG,WAAW,SAAS,KACvBA,EAAG,WAAW,GAAG,IACbA,IACAC,EAASJ,GAAUG,CAAE;AAAA,IAC3B,CAACH,CAAQ;AAAA,EAAA;AAEb;AAQO,SAASK,IAGN;AACR,QAAMC,IAAWC,EAAA,GACXC,IAAOT,EAAA;AACb,SAAOG;AAAA,IACL,CAACC,GAAYM,MAA8B;AACzC,MAAAH,EAASE,EAAKL,CAAE,GAAGM,CAAO;AAAA,IAC5B;AAAA,IACA,CAACH,GAAUE,CAAI;AAAA,EAAA;AAEnB;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),f=require("react"),m=require("../../components/ui/linkComponent.cjs");;/* empty css */const j=require("../../locale/useStrings.cjs");function u({brand:l,tagline:t,columns:r=[],note:a,wordmark:o,linkComponent:c=m.DefaultLink,className:d}){const _=j.useStrings(),g=f.useId();return e.jsx("footer",{className:["aegis-site-footer",d??""].join(" ").trim(),children:e.jsxs("div",{className:"aegis-site-footer__inner",children:[e.jsxs("div",{className:"aegis-site-footer__top",children:[e.jsxs("div",{className:"aegis-site-footer__brand",children:[l,t!==void 0&&e.jsx("p",{className:"aegis-site-footer__tagline",children:t})]}),r.length>0&&e.jsx("nav",{className:"aegis-site-footer__columns","aria-label":_.siteFooterNavigation,children:r.map(s=>{const n=`${g}-${s.key}`;return e.jsxs("div",{className:"aegis-site-footer__column",children:[e.jsx("p",{id:n,className:"aegis-site-footer__title",children:s.title}),e.jsx("ul",{className:"aegis-site-footer__links","aria-labelledby":n,children:s.links.map(i=>e.jsx("li",{children:e.jsx(c,{to:i.to,className:"aegis-site-footer__link",children:i.label})},i.key))})]},s.key)})})]}),a!==void 0&&e.jsx("p",{className:"aegis-site-footer__note",children:a}),o!==void 0&&e.jsx("p",{className:"aegis-site-footer__wordmark","aria-hidden":"true",children:o})]})})}exports.SiteFooter=u;
|
|
2
|
+
//# sourceMappingURL=SiteFooter.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SiteFooter.cjs","sources":["../../../src/layouts/site/SiteFooter.tsx"],"sourcesContent":["import { type ReactElement, type ReactNode, useId } from 'react';\n\nimport {\n DefaultLink,\n type LinkComponent,\n} from '../../components/ui/linkComponent';\nimport { useStrings } from '../../locale';\nimport './SiteFooter.css';\n\nexport interface SiteFooterLink {\n key: string;\n label: ReactNode;\n to: string;\n}\n\nexport interface SiteFooterColumn {\n key: string;\n title: ReactNode;\n links: SiteFooterLink[];\n}\n\nexport interface SiteFooterProps {\n /** The brand lockup; the host supplies its own mark and wordmark. */\n brand: ReactNode;\n /** One line under the brand. */\n tagline?: ReactNode;\n columns?: SiteFooterColumn[];\n /** A closing line, such as when the data was last updated. */\n note?: ReactNode;\n /** Drawn as large outlined letters across the bottom; decorative. */\n wordmark?: string;\n linkComponent?: LinkComponent;\n className?: string;\n}\n\n/** The public site's footer: brand, link columns and an outlined wordmark. */\nexport function SiteFooter({\n brand,\n tagline,\n columns = [],\n note,\n wordmark,\n linkComponent: Link = DefaultLink,\n className,\n}: SiteFooterProps): ReactElement {\n const strings = useStrings();\n const idPrefix = useId();\n return (\n <footer className={['aegis-site-footer', className ?? ''].join(' ').trim()}>\n <div className=\"aegis-site-footer__inner\">\n <div className=\"aegis-site-footer__top\">\n <div className=\"aegis-site-footer__brand\">\n {brand}\n {tagline !== undefined && (\n <p className=\"aegis-site-footer__tagline\">{tagline}</p>\n )}\n </div>\n {columns.length > 0 && (\n <nav\n className=\"aegis-site-footer__columns\"\n aria-label={strings.siteFooterNavigation}\n >\n {columns.map((column) => {\n const titleId = `${idPrefix}-${column.key}`;\n return (\n <div key={column.key} className=\"aegis-site-footer__column\">\n <p id={titleId} className=\"aegis-site-footer__title\">\n {column.title}\n </p>\n <ul\n className=\"aegis-site-footer__links\"\n aria-labelledby={titleId}\n >\n {column.links.map((link) => (\n <li key={link.key}>\n <Link\n to={link.to}\n className=\"aegis-site-footer__link\"\n >\n {link.label}\n </Link>\n </li>\n ))}\n </ul>\n </div>\n );\n })}\n </nav>\n )}\n </div>\n {note !== undefined && (\n <p className=\"aegis-site-footer__note\">{note}</p>\n )}\n {wordmark !== undefined && (\n <p className=\"aegis-site-footer__wordmark\" aria-hidden=\"true\">\n {wordmark}\n </p>\n )}\n </div>\n </footer>\n );\n}\n"],"names":["SiteFooter","brand","tagline","columns","note","wordmark","Link","DefaultLink","className","strings","useStrings","idPrefix","useId","jsxs","jsx","column","titleId","link"],"mappings":"0QAoCO,SAASA,EAAW,CACzB,MAAAC,EACA,QAAAC,EACA,QAAAC,EAAU,CAAA,EACV,KAAAC,EACA,SAAAC,EACA,cAAeC,EAAOC,EAAAA,YACtB,UAAAC,CACF,EAAkC,CAChC,MAAMC,EAAUC,EAAAA,WAAA,EACVC,EAAWC,EAAAA,MAAA,EACjB,aACG,SAAA,CAAO,UAAW,CAAC,oBAAqBJ,GAAa,EAAE,EAAE,KAAK,GAAG,EAAE,KAAA,EAClE,SAAAK,EAAAA,KAAC,MAAA,CAAI,UAAU,2BACb,SAAA,CAAAA,EAAAA,KAAC,MAAA,CAAI,UAAU,yBACb,SAAA,CAAAA,EAAAA,KAAC,MAAA,CAAI,UAAU,2BACZ,SAAA,CAAAZ,EACAC,IAAY,QACXY,EAAAA,IAAC,IAAA,CAAE,UAAU,6BAA8B,SAAAZ,CAAA,CAAQ,CAAA,EAEvD,EACCC,EAAQ,OAAS,GAChBW,EAAAA,IAAC,MAAA,CACC,UAAU,6BACV,aAAYL,EAAQ,qBAEnB,SAAAN,EAAQ,IAAKY,GAAW,CACvB,MAAMC,EAAU,GAAGL,CAAQ,IAAII,EAAO,GAAG,GACzC,OACEF,EAAAA,KAAC,MAAA,CAAqB,UAAU,4BAC9B,SAAA,CAAAC,MAAC,KAAE,GAAIE,EAAS,UAAU,2BACvB,WAAO,MACV,EACAF,EAAAA,IAAC,KAAA,CACC,UAAU,2BACV,kBAAiBE,EAEhB,WAAO,MAAM,IAAKC,SAChB,KAAA,CACC,SAAAH,EAAAA,IAACR,EAAA,CACC,GAAIW,EAAK,GACT,UAAU,0BAET,SAAAA,EAAK,KAAA,CAAA,CACR,EANOA,EAAK,GAOd,CACD,CAAA,CAAA,CACH,CAAA,EAlBQF,EAAO,GAmBjB,CAEJ,CAAC,CAAA,CAAA,CACH,EAEJ,EACCX,IAAS,QACRU,EAAAA,IAAC,IAAA,CAAE,UAAU,0BAA2B,SAAAV,EAAK,EAE9CC,IAAa,QACZS,MAAC,IAAA,CAAE,UAAU,8BAA8B,cAAY,OACpD,SAAAT,CAAA,CACH,CAAA,CAAA,CAEJ,CAAA,CACF,CAEJ"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { ReactElement, ReactNode } from 'react';
|
|
2
|
+
import { LinkComponent } from '../../components/ui/linkComponent';
|
|
3
|
+
export interface SiteFooterLink {
|
|
4
|
+
key: string;
|
|
5
|
+
label: ReactNode;
|
|
6
|
+
to: string;
|
|
7
|
+
}
|
|
8
|
+
export interface SiteFooterColumn {
|
|
9
|
+
key: string;
|
|
10
|
+
title: ReactNode;
|
|
11
|
+
links: SiteFooterLink[];
|
|
12
|
+
}
|
|
13
|
+
export interface SiteFooterProps {
|
|
14
|
+
/** The brand lockup; the host supplies its own mark and wordmark. */
|
|
15
|
+
brand: ReactNode;
|
|
16
|
+
/** One line under the brand. */
|
|
17
|
+
tagline?: ReactNode;
|
|
18
|
+
columns?: SiteFooterColumn[];
|
|
19
|
+
/** A closing line, such as when the data was last updated. */
|
|
20
|
+
note?: ReactNode;
|
|
21
|
+
/** Drawn as large outlined letters across the bottom; decorative. */
|
|
22
|
+
wordmark?: string;
|
|
23
|
+
linkComponent?: LinkComponent;
|
|
24
|
+
className?: string;
|
|
25
|
+
}
|
|
26
|
+
/** The public site's footer: brand, link columns and an outlined wordmark. */
|
|
27
|
+
export declare function SiteFooter({ brand, tagline, columns, note, wordmark, linkComponent: Link, className, }: SiteFooterProps): ReactElement;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { jsx as e, jsxs as s } from "react/jsx-runtime";
|
|
2
|
+
import { useId as g } from "react";
|
|
3
|
+
import { DefaultLink as h } from "../../components/ui/linkComponent.js";
|
|
4
|
+
/* empty css */
|
|
5
|
+
import { useStrings as p } from "../../locale/useStrings.js";
|
|
6
|
+
function x({
|
|
7
|
+
brand: d,
|
|
8
|
+
tagline: a,
|
|
9
|
+
columns: o = [],
|
|
10
|
+
note: r,
|
|
11
|
+
wordmark: l,
|
|
12
|
+
linkComponent: c = h,
|
|
13
|
+
className: m
|
|
14
|
+
}) {
|
|
15
|
+
const _ = p(), f = g();
|
|
16
|
+
return /* @__PURE__ */ e("footer", { className: ["aegis-site-footer", m ?? ""].join(" ").trim(), children: /* @__PURE__ */ s("div", { className: "aegis-site-footer__inner", children: [
|
|
17
|
+
/* @__PURE__ */ s("div", { className: "aegis-site-footer__top", children: [
|
|
18
|
+
/* @__PURE__ */ s("div", { className: "aegis-site-footer__brand", children: [
|
|
19
|
+
d,
|
|
20
|
+
a !== void 0 && /* @__PURE__ */ e("p", { className: "aegis-site-footer__tagline", children: a })
|
|
21
|
+
] }),
|
|
22
|
+
o.length > 0 && /* @__PURE__ */ e(
|
|
23
|
+
"nav",
|
|
24
|
+
{
|
|
25
|
+
className: "aegis-site-footer__columns",
|
|
26
|
+
"aria-label": _.siteFooterNavigation,
|
|
27
|
+
children: o.map((i) => {
|
|
28
|
+
const n = `${f}-${i.key}`;
|
|
29
|
+
return /* @__PURE__ */ s("div", { className: "aegis-site-footer__column", children: [
|
|
30
|
+
/* @__PURE__ */ e("p", { id: n, className: "aegis-site-footer__title", children: i.title }),
|
|
31
|
+
/* @__PURE__ */ e(
|
|
32
|
+
"ul",
|
|
33
|
+
{
|
|
34
|
+
className: "aegis-site-footer__links",
|
|
35
|
+
"aria-labelledby": n,
|
|
36
|
+
children: i.links.map((t) => /* @__PURE__ */ e("li", { children: /* @__PURE__ */ e(
|
|
37
|
+
c,
|
|
38
|
+
{
|
|
39
|
+
to: t.to,
|
|
40
|
+
className: "aegis-site-footer__link",
|
|
41
|
+
children: t.label
|
|
42
|
+
}
|
|
43
|
+
) }, t.key))
|
|
44
|
+
}
|
|
45
|
+
)
|
|
46
|
+
] }, i.key);
|
|
47
|
+
})
|
|
48
|
+
}
|
|
49
|
+
)
|
|
50
|
+
] }),
|
|
51
|
+
r !== void 0 && /* @__PURE__ */ e("p", { className: "aegis-site-footer__note", children: r }),
|
|
52
|
+
l !== void 0 && /* @__PURE__ */ e("p", { className: "aegis-site-footer__wordmark", "aria-hidden": "true", children: l })
|
|
53
|
+
] }) });
|
|
54
|
+
}
|
|
55
|
+
export {
|
|
56
|
+
x as SiteFooter
|
|
57
|
+
};
|
|
58
|
+
//# sourceMappingURL=SiteFooter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SiteFooter.js","sources":["../../../src/layouts/site/SiteFooter.tsx"],"sourcesContent":["import { type ReactElement, type ReactNode, useId } from 'react';\n\nimport {\n DefaultLink,\n type LinkComponent,\n} from '../../components/ui/linkComponent';\nimport { useStrings } from '../../locale';\nimport './SiteFooter.css';\n\nexport interface SiteFooterLink {\n key: string;\n label: ReactNode;\n to: string;\n}\n\nexport interface SiteFooterColumn {\n key: string;\n title: ReactNode;\n links: SiteFooterLink[];\n}\n\nexport interface SiteFooterProps {\n /** The brand lockup; the host supplies its own mark and wordmark. */\n brand: ReactNode;\n /** One line under the brand. */\n tagline?: ReactNode;\n columns?: SiteFooterColumn[];\n /** A closing line, such as when the data was last updated. */\n note?: ReactNode;\n /** Drawn as large outlined letters across the bottom; decorative. */\n wordmark?: string;\n linkComponent?: LinkComponent;\n className?: string;\n}\n\n/** The public site's footer: brand, link columns and an outlined wordmark. */\nexport function SiteFooter({\n brand,\n tagline,\n columns = [],\n note,\n wordmark,\n linkComponent: Link = DefaultLink,\n className,\n}: SiteFooterProps): ReactElement {\n const strings = useStrings();\n const idPrefix = useId();\n return (\n <footer className={['aegis-site-footer', className ?? ''].join(' ').trim()}>\n <div className=\"aegis-site-footer__inner\">\n <div className=\"aegis-site-footer__top\">\n <div className=\"aegis-site-footer__brand\">\n {brand}\n {tagline !== undefined && (\n <p className=\"aegis-site-footer__tagline\">{tagline}</p>\n )}\n </div>\n {columns.length > 0 && (\n <nav\n className=\"aegis-site-footer__columns\"\n aria-label={strings.siteFooterNavigation}\n >\n {columns.map((column) => {\n const titleId = `${idPrefix}-${column.key}`;\n return (\n <div key={column.key} className=\"aegis-site-footer__column\">\n <p id={titleId} className=\"aegis-site-footer__title\">\n {column.title}\n </p>\n <ul\n className=\"aegis-site-footer__links\"\n aria-labelledby={titleId}\n >\n {column.links.map((link) => (\n <li key={link.key}>\n <Link\n to={link.to}\n className=\"aegis-site-footer__link\"\n >\n {link.label}\n </Link>\n </li>\n ))}\n </ul>\n </div>\n );\n })}\n </nav>\n )}\n </div>\n {note !== undefined && (\n <p className=\"aegis-site-footer__note\">{note}</p>\n )}\n {wordmark !== undefined && (\n <p className=\"aegis-site-footer__wordmark\" aria-hidden=\"true\">\n {wordmark}\n </p>\n )}\n </div>\n </footer>\n );\n}\n"],"names":["SiteFooter","brand","tagline","columns","note","wordmark","Link","DefaultLink","className","strings","useStrings","idPrefix","useId","jsxs","jsx","column","titleId","link"],"mappings":";;;;;AAoCO,SAASA,EAAW;AAAA,EACzB,OAAAC;AAAA,EACA,SAAAC;AAAA,EACA,SAAAC,IAAU,CAAA;AAAA,EACV,MAAAC;AAAA,EACA,UAAAC;AAAA,EACA,eAAeC,IAAOC;AAAA,EACtB,WAAAC;AACF,GAAkC;AAChC,QAAMC,IAAUC,EAAA,GACVC,IAAWC,EAAA;AACjB,2BACG,UAAA,EAAO,WAAW,CAAC,qBAAqBJ,KAAa,EAAE,EAAE,KAAK,GAAG,EAAE,KAAA,GAClE,UAAA,gBAAAK,EAAC,OAAA,EAAI,WAAU,4BACb,UAAA;AAAA,IAAA,gBAAAA,EAAC,OAAA,EAAI,WAAU,0BACb,UAAA;AAAA,MAAA,gBAAAA,EAAC,OAAA,EAAI,WAAU,4BACZ,UAAA;AAAA,QAAAZ;AAAA,QACAC,MAAY,UACX,gBAAAY,EAAC,KAAA,EAAE,WAAU,8BAA8B,UAAAZ,EAAA,CAAQ;AAAA,MAAA,GAEvD;AAAA,MACCC,EAAQ,SAAS,KAChB,gBAAAW;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,WAAU;AAAA,UACV,cAAYL,EAAQ;AAAA,UAEnB,UAAAN,EAAQ,IAAI,CAACY,MAAW;AACvB,kBAAMC,IAAU,GAAGL,CAAQ,IAAII,EAAO,GAAG;AACzC,mBACE,gBAAAF,EAAC,OAAA,EAAqB,WAAU,6BAC9B,UAAA;AAAA,cAAA,gBAAAC,EAAC,OAAE,IAAIE,GAAS,WAAU,4BACvB,YAAO,OACV;AAAA,cACA,gBAAAF;AAAA,gBAAC;AAAA,gBAAA;AAAA,kBACC,WAAU;AAAA,kBACV,mBAAiBE;AAAA,kBAEhB,YAAO,MAAM,IAAI,CAACC,wBAChB,MAAA,EACC,UAAA,gBAAAH;AAAA,oBAACR;AAAA,oBAAA;AAAA,sBACC,IAAIW,EAAK;AAAA,sBACT,WAAU;AAAA,sBAET,UAAAA,EAAK;AAAA,oBAAA;AAAA,kBAAA,EACR,GANOA,EAAK,GAOd,CACD;AAAA,gBAAA;AAAA,cAAA;AAAA,YACH,EAAA,GAlBQF,EAAO,GAmBjB;AAAA,UAEJ,CAAC;AAAA,QAAA;AAAA,MAAA;AAAA,IACH,GAEJ;AAAA,IACCX,MAAS,UACR,gBAAAU,EAAC,KAAA,EAAE,WAAU,2BAA2B,UAAAV,GAAK;AAAA,IAE9CC,MAAa,UACZ,gBAAAS,EAAC,KAAA,EAAE,WAAU,+BAA8B,eAAY,QACpD,UAAAT,EAAA,CACH;AAAA,EAAA,EAAA,CAEJ,EAAA,CACF;AAEJ;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),n=require("react"),d=require("../../components/ui/AmbientBackground.cjs");;/* empty css */const m=require("../../locale/useStrings.cjs");function g({nav:r,footer:a,ambient:s,className:u,children:c}){const o=m.useStrings(),i=n.useId(),t=n.useRef(null);return e.jsxs("div",{className:["aegis-site",u??""].join(" ").trim(),children:[e.jsx("a",{className:"aegis-site__skip",href:`#${i}`,onClick:l=>{l.preventDefault(),t.current?.focus()},children:o.skipToContent}),s&&e.jsx(d.AmbientBackground,{variant:s}),r,e.jsx("main",{ref:t,id:i,tabIndex:-1,className:"aegis-site__main",children:c}),a]})}exports.SiteLayout=g;
|
|
2
|
+
//# sourceMappingURL=SiteLayout.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SiteLayout.cjs","sources":["../../../src/layouts/site/SiteLayout.tsx"],"sourcesContent":["import { type ReactElement, type ReactNode, useId, useRef } from 'react';\n\nimport {\n AmbientBackground,\n type AmbientBackgroundVariant,\n} from '../../components/ui/AmbientBackground';\nimport { useStrings } from '../../locale';\nimport './SiteLayout.css';\n\nexport interface SiteLayoutProps {\n /** The top bar, usually a `SiteNav`. */\n nav: ReactNode;\n footer?: ReactNode;\n /** Draws the ambient glows behind the page; `hero` for an overview page. */\n ambient?: AmbientBackgroundVariant;\n className?: string;\n /** The page: `SiteSection` bands, each holding its own content column. */\n children: ReactNode;\n}\n\n/**\n * The frame of the public site: a skip link, the nav, the page and the\n * footer. Unlike `AegisShell` it adds no sidebar and no padding, so a page\n * can run its bands edge to edge.\n */\nexport function SiteLayout({\n nav,\n footer,\n ambient,\n className,\n children,\n}: SiteLayoutProps): ReactElement {\n const strings = useStrings();\n const mainId = useId();\n const mainRef = useRef<HTMLElement>(null);\n return (\n <div className={['aegis-site', className ?? ''].join(' ').trim()}>\n {/* Moves focus without a URL fragment, so a shared page link stays as it was. */}\n <a\n className=\"aegis-site__skip\"\n href={`#${mainId}`}\n onClick={(event) => {\n event.preventDefault();\n mainRef.current?.focus();\n }}\n >\n {strings.skipToContent}\n </a>\n {ambient && <AmbientBackground variant={ambient} />}\n {nav}\n <main\n ref={mainRef}\n id={mainId}\n tabIndex={-1}\n className=\"aegis-site__main\"\n >\n {children}\n </main>\n {footer}\n </div>\n );\n}\n"],"names":["SiteLayout","nav","footer","ambient","className","children","strings","useStrings","mainId","useId","mainRef","useRef","jsxs","jsx","event","AmbientBackground"],"mappings":"8QAyBO,SAASA,EAAW,CACzB,IAAAC,EACA,OAAAC,EACA,QAAAC,EACA,UAAAC,EACA,SAAAC,CACF,EAAkC,CAChC,MAAMC,EAAUC,EAAAA,WAAA,EACVC,EAASC,EAAAA,MAAA,EACTC,EAAUC,EAAAA,OAAoB,IAAI,EACxC,OACEC,EAAAA,KAAC,MAAA,CAAI,UAAW,CAAC,aAAcR,GAAa,EAAE,EAAE,KAAK,GAAG,EAAE,KAAA,EAExD,SAAA,CAAAS,EAAAA,IAAC,IAAA,CACC,UAAU,mBACV,KAAM,IAAIL,CAAM,GAChB,QAAUM,GAAU,CAClBA,EAAM,eAAA,EACNJ,EAAQ,SAAS,MAAA,CACnB,EAEC,SAAAJ,EAAQ,aAAA,CAAA,EAEVH,GAAWU,EAAAA,IAACE,EAAAA,kBAAA,CAAkB,QAASZ,CAAA,CAAS,EAChDF,EACDY,EAAAA,IAAC,OAAA,CACC,IAAKH,EACL,GAAIF,EACJ,SAAU,GACV,UAAU,mBAET,SAAAH,CAAA,CAAA,EAEFH,CAAA,EACH,CAEJ"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ReactElement, ReactNode } from 'react';
|
|
2
|
+
import { AmbientBackgroundVariant } from '../../components/ui/AmbientBackground';
|
|
3
|
+
export interface SiteLayoutProps {
|
|
4
|
+
/** The top bar, usually a `SiteNav`. */
|
|
5
|
+
nav: ReactNode;
|
|
6
|
+
footer?: ReactNode;
|
|
7
|
+
/** Draws the ambient glows behind the page; `hero` for an overview page. */
|
|
8
|
+
ambient?: AmbientBackgroundVariant;
|
|
9
|
+
className?: string;
|
|
10
|
+
/** The page: `SiteSection` bands, each holding its own content column. */
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* The frame of the public site: a skip link, the nav, the page and the
|
|
15
|
+
* footer. Unlike `AegisShell` it adds no sidebar and no padding, so a page
|
|
16
|
+
* can run its bands edge to edge.
|
|
17
|
+
*/
|
|
18
|
+
export declare function SiteLayout({ nav, footer, ambient, className, children, }: SiteLayoutProps): ReactElement;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { jsxs as f, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { useId as u, useRef as l } from "react";
|
|
3
|
+
import { AmbientBackground as p } from "../../components/ui/AmbientBackground.js";
|
|
4
|
+
/* empty css */
|
|
5
|
+
import { useStrings as d } from "../../locale/useStrings.js";
|
|
6
|
+
function j({
|
|
7
|
+
nav: n,
|
|
8
|
+
footer: r,
|
|
9
|
+
ambient: e,
|
|
10
|
+
className: o,
|
|
11
|
+
children: a
|
|
12
|
+
}) {
|
|
13
|
+
const m = d(), s = u(), t = l(null);
|
|
14
|
+
return /* @__PURE__ */ f("div", { className: ["aegis-site", o ?? ""].join(" ").trim(), children: [
|
|
15
|
+
/* @__PURE__ */ i(
|
|
16
|
+
"a",
|
|
17
|
+
{
|
|
18
|
+
className: "aegis-site__skip",
|
|
19
|
+
href: `#${s}`,
|
|
20
|
+
onClick: (c) => {
|
|
21
|
+
c.preventDefault(), t.current?.focus();
|
|
22
|
+
},
|
|
23
|
+
children: m.skipToContent
|
|
24
|
+
}
|
|
25
|
+
),
|
|
26
|
+
e && /* @__PURE__ */ i(p, { variant: e }),
|
|
27
|
+
n,
|
|
28
|
+
/* @__PURE__ */ i(
|
|
29
|
+
"main",
|
|
30
|
+
{
|
|
31
|
+
ref: t,
|
|
32
|
+
id: s,
|
|
33
|
+
tabIndex: -1,
|
|
34
|
+
className: "aegis-site__main",
|
|
35
|
+
children: a
|
|
36
|
+
}
|
|
37
|
+
),
|
|
38
|
+
r
|
|
39
|
+
] });
|
|
40
|
+
}
|
|
41
|
+
export {
|
|
42
|
+
j as SiteLayout
|
|
43
|
+
};
|
|
44
|
+
//# sourceMappingURL=SiteLayout.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SiteLayout.js","sources":["../../../src/layouts/site/SiteLayout.tsx"],"sourcesContent":["import { type ReactElement, type ReactNode, useId, useRef } from 'react';\n\nimport {\n AmbientBackground,\n type AmbientBackgroundVariant,\n} from '../../components/ui/AmbientBackground';\nimport { useStrings } from '../../locale';\nimport './SiteLayout.css';\n\nexport interface SiteLayoutProps {\n /** The top bar, usually a `SiteNav`. */\n nav: ReactNode;\n footer?: ReactNode;\n /** Draws the ambient glows behind the page; `hero` for an overview page. */\n ambient?: AmbientBackgroundVariant;\n className?: string;\n /** The page: `SiteSection` bands, each holding its own content column. */\n children: ReactNode;\n}\n\n/**\n * The frame of the public site: a skip link, the nav, the page and the\n * footer. Unlike `AegisShell` it adds no sidebar and no padding, so a page\n * can run its bands edge to edge.\n */\nexport function SiteLayout({\n nav,\n footer,\n ambient,\n className,\n children,\n}: SiteLayoutProps): ReactElement {\n const strings = useStrings();\n const mainId = useId();\n const mainRef = useRef<HTMLElement>(null);\n return (\n <div className={['aegis-site', className ?? ''].join(' ').trim()}>\n {/* Moves focus without a URL fragment, so a shared page link stays as it was. */}\n <a\n className=\"aegis-site__skip\"\n href={`#${mainId}`}\n onClick={(event) => {\n event.preventDefault();\n mainRef.current?.focus();\n }}\n >\n {strings.skipToContent}\n </a>\n {ambient && <AmbientBackground variant={ambient} />}\n {nav}\n <main\n ref={mainRef}\n id={mainId}\n tabIndex={-1}\n className=\"aegis-site__main\"\n >\n {children}\n </main>\n {footer}\n </div>\n );\n}\n"],"names":["SiteLayout","nav","footer","ambient","className","children","strings","useStrings","mainId","useId","mainRef","useRef","jsxs","jsx","event","AmbientBackground"],"mappings":";;;;;AAyBO,SAASA,EAAW;AAAA,EACzB,KAAAC;AAAA,EACA,QAAAC;AAAA,EACA,SAAAC;AAAA,EACA,WAAAC;AAAA,EACA,UAAAC;AACF,GAAkC;AAChC,QAAMC,IAAUC,EAAA,GACVC,IAASC,EAAA,GACTC,IAAUC,EAAoB,IAAI;AACxC,SACE,gBAAAC,EAAC,OAAA,EAAI,WAAW,CAAC,cAAcR,KAAa,EAAE,EAAE,KAAK,GAAG,EAAE,KAAA,GAExD,UAAA;AAAA,IAAA,gBAAAS;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAU;AAAA,QACV,MAAM,IAAIL,CAAM;AAAA,QAChB,SAAS,CAACM,MAAU;AAClB,UAAAA,EAAM,eAAA,GACNJ,EAAQ,SAAS,MAAA;AAAA,QACnB;AAAA,QAEC,UAAAJ,EAAQ;AAAA,MAAA;AAAA,IAAA;AAAA,IAEVH,KAAW,gBAAAU,EAACE,GAAA,EAAkB,SAASZ,EAAA,CAAS;AAAA,IAChDF;AAAA,IACD,gBAAAY;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,KAAKH;AAAA,QACL,IAAIF;AAAA,QACJ,UAAU;AAAA,QACV,WAAU;AAAA,QAET,UAAAH;AAAA,MAAA;AAAA,IAAA;AAAA,IAEFH;AAAA,EAAA,GACH;AAEJ;"}
|