@declarion/react 0.65.1 → 0.66.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/dist-lib/api/access-expiry.js +32 -0
- package/dist-lib/api/agents.js +105 -0
- package/dist-lib/api/auth-redirect.js +30 -0
- package/dist-lib/api/auth.js +67 -0
- package/dist-lib/api/batch.js +34 -0
- package/dist-lib/api/client.js +241 -0
- package/dist-lib/api/data.js +122 -0
- package/dist-lib/api/entities.js +160 -0
- package/dist-lib/api/events.js +120 -0
- package/dist-lib/api/fileReferences.js +8 -0
- package/dist-lib/api/params.js +20 -0
- package/dist-lib/api/properties.js +25 -0
- package/dist-lib/api/request-bounds.js +28 -0
- package/dist-lib/api/schema.js +71 -0
- package/dist-lib/api/session-renewal.js +36 -0
- package/dist-lib/api/status.js +17 -0
- package/dist-lib/app.js +262 -0
- package/dist-lib/components/actions/ActionButton.js +116 -0
- package/dist-lib/{ActionDialog-C6EG-AmC.js → components/actions/ActionDialog.js} +63 -53
- package/dist-lib/{ActionResultDialog.impl-BATutW8J.js → components/actions/ActionResultDialog.impl.js} +53 -48
- package/dist-lib/components/actions/ActionResultDialog.js +12 -0
- package/dist-lib/components/actions/ActionRunner.js +274 -0
- package/dist-lib/components/actions/ObjectActionBar.js +127 -0
- package/dist-lib/components/actions/PropertyGridEditor.js +202 -0
- package/dist-lib/components/actions/ResponsiveActionBar.js +773 -0
- package/dist-lib/components/actions/RowActionsKebab.js +90 -0
- package/dist-lib/{AgentChatPanel.impl-D5y_qEex.js → components/agents/AgentChatPanel.impl.js} +314 -362
- package/dist-lib/components/agents/AgentChatPanel.js +12 -0
- package/dist-lib/components/agents/AgentConversationDrawer.js +59 -0
- package/dist-lib/components/agents/AgentElicitForm.js +152 -0
- package/dist-lib/components/agents/AgentOpenFollower.impl.js +7 -0
- package/dist-lib/components/agents/AgentOpenFollower.js +12 -0
- package/dist-lib/components/agents/AgentPicker.js +58 -0
- package/dist-lib/components/agents/transcript-runs.js +52 -0
- package/dist-lib/components/chrome/AssociationTabs.js +176 -0
- package/dist-lib/components/chrome/AuditMetaStrip.js +64 -0
- package/dist-lib/components/chrome/Breadcrumbs.js +67 -0
- package/dist-lib/components/chrome/HighlightsStrip.js +39 -0
- package/dist-lib/{PageHeader-DiwLe7CO.js → components/chrome/PageHeader.js} +19 -15
- package/dist-lib/{PageShell-BJz1MiTH.js → components/chrome/PageShell.js} +3 -3
- package/dist-lib/components/chrome/RecordHeader.js +119 -0
- package/dist-lib/{headerActionZone-bef-tZZ7.js → components/chrome/headerActionZone.js} +1 -1
- package/dist-lib/components/detail-layout/AssociatedBlock.js +1244 -0
- package/dist-lib/components/detail-layout/AssociatedToolbar.js +87 -0
- package/dist-lib/components/detail-layout/ChildrenBlock.js +80 -0
- package/dist-lib/components/detail-layout/ChildrenCards.js +156 -0
- package/dist-lib/components/detail-layout/ChildrenList.js +135 -0
- package/dist-lib/components/detail-layout/ChildrenTable.js +189 -0
- package/dist-lib/components/detail-layout/ChildrenTimeline.js +609 -0
- package/dist-lib/components/detail-layout/DetailAuditStrip.js +40 -0
- package/dist-lib/components/detail-layout/DetailHighlights.js +54 -0
- package/dist-lib/{DraggableChildrenTable-Dd5SeuF6.js → components/detail-layout/DraggableChildrenTable.js} +56 -53
- package/dist-lib/components/detail-layout/EditableChildrenTable.js +341 -0
- package/dist-lib/components/detail-layout/ErrorSummary.js +89 -0
- package/dist-lib/components/detail-layout/EvidenceBlock.js +66 -0
- package/dist-lib/{FieldRow-DedGIY9R.js → components/detail-layout/FieldRow.js} +8 -7
- package/dist-lib/components/detail-layout/FieldsBlock.js +74 -0
- package/dist-lib/components/detail-layout/LayoutColumn.js +16 -0
- package/dist-lib/components/detail-layout/LayoutRenderer.js +54 -0
- package/dist-lib/components/detail-layout/LayoutRow.js +83 -0
- package/dist-lib/components/detail-layout/LayoutTabs.js +195 -0
- package/dist-lib/components/detail-layout/PropertiesBlock.js +74 -0
- package/dist-lib/components/detail-layout/QuickAddForm.js +81 -0
- package/dist-lib/components/detail-layout/SectionBlock.js +48 -0
- package/dist-lib/components/detail-layout/StatusesBlock.js +18 -0
- package/dist-lib/components/detail-layout/TimelineComposer.js +205 -0
- package/dist-lib/components/detail-layout/blockMeta.js +27 -0
- package/dist-lib/components/detail-layout/useManualColumnResize.js +94 -0
- package/dist-lib/components/detail-layout/useQuickAdd.js +85 -0
- package/dist-lib/components/detail-layout/widgets/EntityScorecardWidget.js +295 -0
- package/dist-lib/components/detail-layout/widgets/JsonDiffWidget.js +107 -0
- package/dist-lib/components/detail-layout/widgets/MonacoJson.js +47 -0
- package/dist-lib/components/detail-layout/widgets/WidgetHost.js +36 -0
- package/dist-lib/components/detail-layout/widgets/builtins.js +10 -0
- package/dist-lib/components/detail-layout/widgets/canonicalizeJson.js +32 -0
- package/dist-lib/components/detail-layout/widgets/monacoBootstrap.js +16 -0
- package/dist-lib/components/detail-layout/widgets/registry.js +13 -0
- package/dist-lib/components/fields/BoolField.js +13 -0
- package/dist-lib/components/fields/EmailField.js +16 -0
- package/dist-lib/components/fields/EnumField.js +38 -0
- package/dist-lib/components/fields/FileReferenceField.js +60 -0
- package/dist-lib/components/fields/IntArrayField.js +83 -0
- package/dist-lib/components/fields/JsonField.js +51 -0
- package/dist-lib/components/fields/MultilangArrayField.js +56 -0
- package/dist-lib/components/fields/MultilangField.js +65 -0
- package/dist-lib/components/fields/MultilangTextField.js +65 -0
- package/dist-lib/components/fields/NumberField.js +64 -0
- package/dist-lib/components/fields/PasswordField.js +34 -0
- package/dist-lib/components/fields/PhoneField.js +84 -0
- package/dist-lib/components/fields/RefCombobox.js +112 -0
- package/dist-lib/components/fields/RefField.js +45 -0
- package/dist-lib/components/fields/RichTextField.js +225 -0
- package/dist-lib/components/fields/SecretField.js +34 -0
- package/dist-lib/components/fields/StringArrayField.js +165 -0
- package/dist-lib/components/fields/StringField.js +39 -0
- package/dist-lib/components/fields/StructureField.js +221 -0
- package/dist-lib/components/fields/TextField.js +76 -0
- package/dist-lib/components/fields/TimestampField.js +110 -0
- package/dist-lib/components/fields/UrlField.js +18 -0
- package/dist-lib/components/fields/cells/factories/badge.js +42 -0
- package/dist-lib/components/fields/cells/factories/boolPill.js +17 -0
- package/dist-lib/components/fields/cells/factories/code.js +11 -0
- package/dist-lib/components/fields/cells/factories/date.js +30 -0
- package/dist-lib/components/fields/cells/factories/email.js +26 -0
- package/dist-lib/components/fields/cells/factories/emptyCell.js +10 -0
- package/dist-lib/components/fields/cells/factories/fileReference.js +17 -0
- package/dist-lib/components/fields/cells/factories/host-icons.js +146 -0
- package/dist-lib/components/fields/cells/factories/json.js +61 -0
- package/dist-lib/components/fields/cells/factories/link.js +32 -0
- package/dist-lib/components/fields/cells/factories/markdown.js +31 -0
- package/dist-lib/components/fields/cells/factories/markdownPreview.js +81 -0
- package/dist-lib/components/fields/cells/factories/money.js +37 -0
- package/dist-lib/components/fields/cells/factories/multilangInline.js +35 -0
- package/dist-lib/components/fields/cells/factories/nextRun.js +46 -0
- package/dist-lib/components/fields/cells/factories/number.js +42 -0
- package/dist-lib/components/fields/cells/factories/passwordMask.js +23 -0
- package/dist-lib/components/fields/cells/factories/phone.js +35 -0
- package/dist-lib/components/fields/cells/factories/refLink.js +57 -0
- package/dist-lib/components/fields/cells/factories/richTextPreview.js +34 -0
- package/dist-lib/components/fields/cells/factories/statusPill.js +35 -0
- package/dist-lib/components/fields/cells/factories/tagList.js +44 -0
- package/dist-lib/components/fields/cells/factories/text.js +5 -0
- package/dist-lib/components/fields/cells/factories/timestamp.js +18 -0
- package/dist-lib/components/fields/cells/factories/url-helpers.js +49 -0
- package/dist-lib/components/fields/cells/factories/url.js +45 -0
- package/dist-lib/components/fields/cells/registry.js +58 -0
- package/dist-lib/components/fields/index.js +80 -0
- package/dist-lib/components/fields/langMap.js +6 -0
- package/dist-lib/components/fields/secretValue.js +7 -0
- package/dist-lib/components/file-widgets/CircleImage.js +11 -0
- package/dist-lib/components/file-widgets/DocumentCard.js +277 -0
- package/dist-lib/components/file-widgets/FileList.js +213 -0
- package/dist-lib/{Grid-XUHm5SDe.js → components/file-widgets/Grid.js} +45 -40
- package/dist-lib/components/file-widgets/GridLazy.js +15 -0
- package/dist-lib/components/file-widgets/ImageWidget.js +354 -0
- package/dist-lib/components/file-widgets/LabeledSlots.js +69 -0
- package/dist-lib/components/file-widgets/SquareImage.js +11 -0
- package/dist-lib/components/file-widgets/UnknownFileWidget.js +22 -0
- package/dist-lib/components/file-widgets/UploadFailureText.js +10 -0
- package/dist-lib/components/file-widgets/WideBanner.js +11 -0
- package/dist-lib/components/file-widgets/builtins.js +15 -0
- package/dist-lib/components/file-widgets/cropper.js +13 -0
- package/dist-lib/components/file-widgets/draft-scope.js +59 -0
- package/dist-lib/components/file-widgets/helpers.js +75 -0
- package/dist-lib/components/file-widgets/host.js +75 -0
- package/dist-lib/{payload-DioMoxMX.js → components/file-widgets/payload.js} +14 -14
- package/dist-lib/components/file-widgets/registry.js +13 -0
- package/dist-lib/components/file-widgets/upload.js +180 -0
- package/dist-lib/components/file-widgets/useEmbedFileSrc.js +45 -0
- package/dist-lib/components/file-widgets/value.js +12 -0
- package/dist-lib/components/filters/FilterChips.js +123 -0
- package/dist-lib/components/filters/FilterConditionValue.js +40 -0
- package/dist-lib/components/filters/FilterDrawer.js +670 -0
- package/dist-lib/components/filters/FilterOmittedNotice.js +14 -0
- package/dist-lib/components/filters/filter-op-label.js +8 -0
- package/dist-lib/{CommandPalette.impl-DRI5kxVY.js → components/layout/CommandPalette.impl.js} +62 -61
- package/dist-lib/components/layout/CommandPalette.js +12 -0
- package/dist-lib/{DirtyTabsCloseDialog.impl-FhAiOmEb.js → components/layout/DirtyTabsCloseDialog.impl.js} +16 -14
- package/dist-lib/components/layout/DirtyTabsCloseDialog.js +12 -0
- package/dist-lib/{ImpersonationBanner.impl--g0iYwcV.js → components/layout/ImpersonationBanner.impl.js} +4 -3
- package/dist-lib/components/layout/ImpersonationBanner.js +12 -0
- package/dist-lib/components/layout/ImpersonationFrame.js +29 -0
- package/dist-lib/{ImpersonationStartModal.impl-BFBN0YJe.js → components/layout/ImpersonationStartModal.impl.js} +9 -9
- package/dist-lib/components/layout/ImpersonationStartModal.js +12 -0
- package/dist-lib/components/layout/Layout.js +755 -0
- package/dist-lib/components/layout/Rail.js +149 -0
- package/dist-lib/components/layout/Sidebar.js +362 -0
- package/dist-lib/components/layout/TabStrip.js +321 -0
- package/dist-lib/components/layout/TenantChip.js +355 -0
- package/dist-lib/components/layout/TopBar.js +305 -0
- package/dist-lib/components/layout/tab-close.js +24 -0
- package/dist-lib/components/list/ColumnPicker.js +112 -0
- package/dist-lib/components/list/InlineEditCell.js +107 -0
- package/dist-lib/components/list/PeekFieldCell.js +143 -0
- package/dist-lib/components/list/QuickPeek.js +263 -0
- package/dist-lib/components/list/ViewSwitcher.js +156 -0
- package/dist-lib/components/list/peekDraftStore.js +14 -0
- package/dist-lib/{AdminCatalogPage.impl-B-7MLqa1.js → components/pages/AdminCatalogPage.impl.js} +53 -49
- package/dist-lib/components/pages/AdminCatalogPage.js +12 -0
- package/dist-lib/components/pages/DocumentsMenu.js +150 -0
- package/dist-lib/components/pages/ExportMenu.js +123 -0
- package/dist-lib/{NotFoundPage.impl-BoX11u-P.js → components/pages/NotFoundPage.impl.js} +6 -4
- package/dist-lib/components/pages/NotFoundPage.js +12 -0
- package/dist-lib/components/pages/RecordDocumentsPanel.js +230 -0
- package/dist-lib/components/pages/RecordNotesPanel.js +200 -0
- package/dist-lib/components/pages/RecordPanels.js +18 -0
- package/dist-lib/components/pages/SSOCallbackPage.impl.js +28 -0
- package/dist-lib/components/pages/SSOCallbackPage.js +12 -0
- package/dist-lib/components/pages/SmartDetailPage.impl.js +986 -0
- package/dist-lib/components/pages/SmartDetailPage.js +12 -0
- package/dist-lib/components/pages/SmartListPage.impl.js +708 -0
- package/dist-lib/components/pages/SmartListPage.js +12 -0
- package/dist-lib/components/pages/SmartRecordListPage.impl.js +818 -0
- package/dist-lib/components/pages/SmartRecordListPage.js +12 -0
- package/dist-lib/components/pages/auth/AuthShell.js +350 -0
- package/dist-lib/{Forgot.impl-6tL6SBlS.js → components/pages/auth/Forgot.impl.js} +13 -12
- package/dist-lib/components/pages/auth/Forgot.js +12 -0
- package/dist-lib/{Reset.impl-D0pjhS6d.js → components/pages/auth/Reset.impl.js} +17 -15
- package/dist-lib/components/pages/auth/Reset.js +12 -0
- package/dist-lib/components/pages/auth/SignIn.js +252 -0
- package/dist-lib/{SignUp.impl-CfEXrUeg.js → components/pages/auth/SignUp.impl.js} +31 -27
- package/dist-lib/components/pages/auth/SignUp.js +12 -0
- package/dist-lib/{TwoFA.impl-B2HtPduH.js → components/pages/auth/TwoFA.impl.js} +9 -8
- package/dist-lib/components/pages/auth/TwoFA.js +12 -0
- package/dist-lib/components/pages/auth/icons.js +56 -0
- package/dist-lib/components/pages/exportRequest.js +17 -0
- package/dist-lib/components/pages/list/DataCell.js +27 -0
- package/dist-lib/components/pages/list/DeleteViewDialog.js +22 -0
- package/dist-lib/{ListCardsBody-BEoYjSZ2.js → components/pages/list/ListCardRow.js} +47 -72
- package/dist-lib/components/pages/list/ListCardsBody.js +31 -0
- package/dist-lib/components/pages/list/ListFloatbar.js +130 -0
- package/dist-lib/components/pages/list/ListFooter.js +138 -0
- package/dist-lib/components/pages/list/ListHeader.js +120 -0
- package/dist-lib/components/pages/list/ListNoRows.js +72 -0
- package/dist-lib/components/pages/list/ListTable.js +191 -0
- package/dist-lib/components/pages/list/ListTableRow.js +37 -0
- package/dist-lib/components/pages/list/ListToolbar.js +261 -0
- package/dist-lib/components/pages/list/ListUrlBanner.js +45 -0
- package/dist-lib/components/pages/list/RowActionsCell.js +49 -0
- package/dist-lib/components/pages/list/RowContextMenu.js +55 -0
- package/dist-lib/components/pages/list/SaveViewDialog.js +111 -0
- package/dist-lib/{SortHeaderMenu-Co5PvhTA.js → components/pages/list/SortHeaderMenu.js} +18 -17
- package/dist-lib/{cardProjection-Cxlogzh8.js → components/pages/list/cardProjection.js} +3 -3
- package/dist-lib/components/pages/list/column-sizing.js +17 -0
- package/dist-lib/components/pages/list/columns.js +168 -0
- package/dist-lib/components/pages/list/filter-meta.js +84 -0
- package/dist-lib/components/pages/list/page-size.js +11 -0
- package/dist-lib/components/pages/list/sortable-header.js +18 -0
- package/dist-lib/components/pages/list/table-features.js +11 -0
- package/dist-lib/components/pages/list/use-filter-value-labels.js +115 -0
- package/dist-lib/components/pages/list/useActiveView.js +98 -0
- package/dist-lib/components/pages/list/useHeaderReorder.js +93 -0
- package/dist-lib/components/pages/list/useListColumnLayout.js +56 -0
- package/dist-lib/components/pages/list/useListFilterPresentation.js +34 -0
- package/dist-lib/components/pages/list/useListQuery.js +101 -0
- package/dist-lib/components/pages/list/useListRowInteraction.js +120 -0
- package/dist-lib/components/pages/list/useListSelection.js +53 -0
- package/dist-lib/components/pages/list/useListSort.js +44 -0
- package/dist-lib/components/pages/list/useListViews.js +148 -0
- package/dist-lib/components/pages/list/useRowMenu.js +106 -0
- package/dist-lib/components/pages/list/visible-filters.js +19 -0
- package/dist-lib/{Preferences.impl-Ct5xwZtT.js → components/pages/profile/Preferences.impl.js} +34 -31
- package/dist-lib/components/pages/profile/Preferences.js +12 -0
- package/dist-lib/components/pages/profile/Profile.impl.js +437 -0
- package/dist-lib/components/pages/profile/Profile.js +12 -0
- package/dist-lib/{TenantParamsPage.impl-BGpdmEZg.js → components/pages/tenant-params/TenantParamsPage.impl.js} +45 -40
- package/dist-lib/components/pages/tenant-params/TenantParamsPage.js +12 -0
- package/dist-lib/components/params/ParamsBlock.js +119 -0
- package/dist-lib/{param-editors-TYYU7HKK.js → components/params/param-editors.js} +32 -28
- package/dist-lib/components/primitives/Avatar.js +33 -0
- package/dist-lib/components/primitives/BoolToggle.js +35 -0
- package/dist-lib/components/primitives/BrandGlyph.js +38 -0
- package/dist-lib/components/primitives/BrandLogo.js +20 -0
- package/dist-lib/components/primitives/Btn.js +67 -0
- package/dist-lib/{Check-DAfMbQIw.js → components/primitives/Check.js} +2 -2
- package/dist-lib/components/primitives/Chip.js +44 -0
- package/dist-lib/components/primitives/ClassifiedFieldLocked.js +15 -0
- package/dist-lib/components/primitives/Dropdown.js +85 -0
- package/dist-lib/components/primitives/Fields.js +751 -0
- package/dist-lib/components/primitives/HoverCard.js +115 -0
- package/dist-lib/components/primitives/IconBtn.js +37 -0
- package/dist-lib/{Icons-lt-7lhYR.js → components/primitives/Icons.js} +1 -1
- package/dist-lib/{Kbd-CNttVu0z.js → components/primitives/Kbd.js} +2 -2
- package/dist-lib/components/primitives/MenuItem.js +57 -0
- package/dist-lib/{Pill-D-wsfRhx.js → components/primitives/Pill.js} +1 -1
- package/dist-lib/{RecordIdBadge-wbigZaFc.js → components/primitives/RecordIdBadge.js} +5 -5
- package/dist-lib/components/primitives/RowField.js +47 -0
- package/dist-lib/{SectionCard-BYHoHWJc.js → components/primitives/SectionCard.js} +10 -10
- package/dist-lib/components/primitives/Spinner.js +31 -0
- package/dist-lib/components/primitives/StatTile.js +108 -0
- package/dist-lib/components/primitives/Tooltip.js +115 -0
- package/dist-lib/{dataTableStyles-vwD1mVOP.js → components/primitives/dataTableStyles.js} +1 -1
- package/dist-lib/components/shared/BlankScreen.js +13 -0
- package/dist-lib/{ChangePasswordDialog.impl-5hDc0wpE.js → components/shared/ChangePasswordDialog.impl.js} +27 -22
- package/dist-lib/{ChangePasswordDialog-C_T_3pjl.js → components/shared/ChangePasswordDialog.js} +2 -2
- package/dist-lib/components/shared/ConfirmDialog.js +129 -0
- package/dist-lib/components/shared/ConnectionNotice.js +12 -0
- package/dist-lib/components/shared/CopyButton.js +25 -0
- package/dist-lib/components/shared/DynamicIcon.js +73 -0
- package/dist-lib/components/shared/EmptyState.js +56 -0
- package/dist-lib/components/shared/ErrorBoundary.js +96 -0
- package/dist-lib/components/shared/LoadingSkeleton.js +117 -0
- package/dist-lib/components/shared/LucideIcon.js +43 -0
- package/dist-lib/components/shared/Markdown.js +15 -0
- package/dist-lib/{MarkdownRenderer-sK2TRZS-.js → components/shared/MarkdownRenderer.js} +10 -9
- package/dist-lib/components/shared/RefreshControl.js +42 -0
- package/dist-lib/components/shared/StatusGroupsDisplay.js +123 -0
- package/dist-lib/components/shared/StatusStepper.js +70 -0
- package/dist-lib/components/shared/toast/DeclarionToast.js +308 -0
- package/dist-lib/components/shared/useOwnRefresh.js +19 -0
- package/dist-lib/declarion-react.css +1 -1
- package/dist-lib/embed/EmbedAuthBootstrap.js +71 -0
- package/dist-lib/embed/EmbedContext.js +38 -0
- package/dist-lib/embed/EmbedDirtyReporter.js +17 -0
- package/dist-lib/embed/EmbedHistoryTracker.js +17 -0
- package/dist-lib/embed/EmbedLocationReporter.js +26 -0
- package/dist-lib/embed/EmbedResizeReporter.js +25 -0
- package/dist-lib/embed/EmbedUnsavedGuard.js +23 -0
- package/dist-lib/embed/embed-dirty.js +21 -0
- package/dist-lib/embed/embed-history.js +17 -0
- package/dist-lib/embed/embed-nav-guard.js +13 -0
- package/dist-lib/embed/file-src.js +60 -0
- package/dist-lib/embed/handshake.js +37 -0
- package/dist-lib/embed/params.js +45 -0
- package/dist-lib/embed/protocol.js +26 -0
- package/dist-lib/embed/screen-location.js +44 -0
- package/dist-lib/embed/theme.js +11 -0
- package/dist-lib/embed/token.js +54 -0
- package/dist-lib/embed/useEmbedNavigate.js +65 -0
- package/dist-lib/embed/useGlobalLinkInterceptor.js +63 -0
- package/dist-lib/hooks/useActionData.js +58 -0
- package/dist-lib/hooks/useAgentConversation.js +311 -0
- package/dist-lib/hooks/useAggregate.js +18 -0
- package/dist-lib/hooks/useAllEntityData.js +53 -0
- package/dist-lib/hooks/useAssociatedData.js +37 -0
- package/dist-lib/hooks/useAuth.js +56 -0
- package/dist-lib/hooks/useBranding.js +18 -0
- package/dist-lib/hooks/useBrandingChrome.js +58 -0
- package/dist-lib/hooks/useChildrenData.js +33 -0
- package/dist-lib/hooks/useColumns.js +44 -0
- package/dist-lib/hooks/useConnectionNotice.js +35 -0
- package/dist-lib/{useCurrentLocation-Bq1T72AW.js → hooks/useCurrentLocation.js} +2 -2
- package/dist-lib/hooks/useCurrentScreen.js +20 -0
- package/dist-lib/hooks/useCursorEntityData.js +77 -0
- package/dist-lib/hooks/useDebounce.js +11 -0
- package/dist-lib/hooks/useEntity.js +8 -0
- package/dist-lib/hooks/useEntityData.js +64 -0
- package/dist-lib/hooks/useFileReferenceJSON.js +29 -0
- package/dist-lib/hooks/useFilters.js +28 -0
- package/dist-lib/hooks/useFollowAgentOpen.js +84 -0
- package/dist-lib/hooks/useImpersonation.js +40 -0
- package/dist-lib/hooks/useIntentPrefetch.js +43 -0
- package/dist-lib/hooks/useJsonSnapshot.js +8 -0
- package/dist-lib/hooks/useLanguage.js +21 -0
- package/dist-lib/hooks/useLiveObject.js +17 -0
- package/dist-lib/hooks/useLongPress.js +49 -0
- package/dist-lib/hooks/useMutations.js +70 -0
- package/dist-lib/{useObject-B45F96rC.js → hooks/useObject.js} +2 -2
- package/dist-lib/hooks/useObjectStatus.js +20 -0
- package/dist-lib/hooks/usePageState.js +18 -0
- package/dist-lib/hooks/usePageStateRuntime.js +46 -0
- package/dist-lib/hooks/usePageStateTtl.js +10 -0
- package/dist-lib/hooks/useParams.js +123 -0
- package/dist-lib/hooks/useProperties.js +32 -0
- package/dist-lib/hooks/useRealtimeThresholds.js +31 -0
- package/dist-lib/hooks/useRegisterScreenTab.js +28 -0
- package/dist-lib/hooks/useResponsiveMode.js +84 -0
- package/dist-lib/hooks/useSSE.js +307 -0
- package/dist-lib/hooks/useSchema.js +73 -0
- package/dist-lib/hooks/useScreen.js +8 -0
- package/dist-lib/hooks/useScreenBack.js +60 -0
- package/dist-lib/hooks/useScreenTab.js +11 -0
- package/dist-lib/hooks/useTabNavigate.js +82 -0
- package/dist-lib/hooks/useTabSearchMirror.js +19 -0
- package/dist-lib/{useTabTitle-KrzEo118.js → hooks/useTabTitle.js} +9 -7
- package/dist-lib/hooks/useText.js +15 -0
- package/dist-lib/hooks/useTimelineData.js +44 -0
- package/dist-lib/hooks/useUnsavedInput.js +18 -0
- package/dist-lib/hooks/useVersionWatcher.js +62 -0
- package/dist-lib/hooks/useViews.js +88 -0
- package/dist-lib/hooks/useWindowConversation.js +11 -0
- package/dist-lib/icons.js +5 -3
- package/dist-lib/index.d.ts +42 -20
- package/dist-lib/index.js +131 -3926
- package/dist-lib/lib/action-dispatch.js +7 -0
- package/dist-lib/lib/actions.js +279 -0
- package/dist-lib/lib/anchor.js +41 -0
- package/dist-lib/lib/brand-tokens.js +95 -0
- package/dist-lib/lib/branding.js +25 -0
- package/dist-lib/lib/canonical-url.js +17 -0
- package/dist-lib/lib/capabilityPrefetch.js +57 -0
- package/dist-lib/lib/child-config.js +111 -0
- package/dist-lib/lib/children-validation.js +52 -0
- package/dist-lib/lib/decimal-text.js +15 -0
- package/dist-lib/lib/display-value.js +19 -0
- package/dist-lib/lib/document-templates.js +6 -0
- package/dist-lib/lib/download.js +41 -0
- package/dist-lib/lib/evidence-verdict.js +23 -0
- package/dist-lib/lib/failure.js +9 -0
- package/dist-lib/lib/field-classification.js +58 -0
- package/dist-lib/lib/field-regions.js +13 -0
- package/dist-lib/lib/filter-evaluator.js +98 -0
- package/dist-lib/lib/filters.js +118 -0
- package/dist-lib/lib/format-count.js +24 -0
- package/dist-lib/lib/html-state.js +9 -0
- package/dist-lib/lib/language.js +52 -0
- package/dist-lib/lib/longPressGesture.js +34 -0
- package/dist-lib/lib/mass-edit.js +65 -0
- package/dist-lib/{page-inset-D_kkVwwN.js → lib/page-inset.js} +1 -1
- package/dist-lib/lib/phone.js +28 -0
- package/dist-lib/lib/query-retry.js +7 -0
- package/dist-lib/lib/quick-add.js +23 -0
- package/dist-lib/lib/realtime-query-keys.js +23 -0
- package/dist-lib/lib/realtime-reconcile.js +148 -0
- package/dist-lib/lib/realtime-resync.js +192 -0
- package/dist-lib/lib/record-documents-key.js +4 -0
- package/dist-lib/lib/ref-choices.js +6 -0
- package/dist-lib/lib/refetch-when-idle.js +25 -0
- package/dist-lib/lib/rich-text.js +46 -0
- package/dist-lib/lib/rowClickGesture.js +10 -0
- package/dist-lib/lib/safe-url.js +34 -0
- package/dist-lib/lib/schema-routing.js +51 -0
- package/dist-lib/{screen-back-BtbEp5sO.js → lib/screen-back.js} +2 -2
- package/dist-lib/lib/scroll-restoration.js +156 -0
- package/dist-lib/lib/size-value.js +22 -0
- package/dist-lib/lib/sort.js +59 -0
- package/dist-lib/lib/timestamp.js +97 -0
- package/dist-lib/lib/toast.js +78 -0
- package/dist-lib/lib/ui-actions.js +81 -0
- package/dist-lib/{utils-D_QDpB8_.js → lib/utils.js} +1 -1
- package/dist-lib/lib/variants.js +63 -0
- package/dist-lib/lib/versionTracker.js +102 -0
- package/dist-lib/lib/viewport-category.js +12 -0
- package/dist-lib/{window-election-CHIvIZwx.js → lib/window-election.js} +1 -1
- package/dist-lib/stores/auth.js +84 -0
- package/dist-lib/stores/icon-registry.js +24 -0
- package/dist-lib/stores/list-layout.js +178 -0
- package/dist-lib/{page-state-eA6J_KIR.js → stores/page-state.js} +1 -1
- package/dist-lib/stores/preferences.js +126 -0
- package/dist-lib/stores/realtime.js +115 -0
- package/dist-lib/stores/screen-registry.js +10 -0
- package/dist-lib/stores/tabs.js +220 -0
- package/dist-lib/test/seed-schema.js +8 -0
- package/dist-lib/testing.d.ts +1 -1
- package/dist-lib/testing.js +80 -76
- package/dist-lib/types/api.js +48 -0
- package/dist-lib/types/fieldType.js +4 -0
- package/dist-lib/types/ordmap.js +50 -0
- package/dist-lib/types/schema.js +173 -0
- package/dist-lib/{useResponsiveMode-DIR1bZfo.d.ts → useResponsiveMode-DmrpMbZX.d.ts} +44 -16
- package/package.json +13 -12
- package/dist-lib/ActionRunner-DdBFhqGe.js +0 -1440
- package/dist-lib/AgentOpenFollower.impl-BAs_wGEZ.js +0 -81
- package/dist-lib/AssociatedBlock-BOoPLOjw.js +0 -1515
- package/dist-lib/AuthShell-C8aVwHS7.js +0 -361
- package/dist-lib/BlankScreen-DVc7fh8C.js +0 -61
- package/dist-lib/CopyButton-DRIT_f0k.js +0 -119
- package/dist-lib/DynamicIcon-DuBSz6TZ.js +0 -133
- package/dist-lib/FilterChips-Cv1tlXyo.js +0 -1031
- package/dist-lib/LayoutRenderer-d-tXYPze.js +0 -3239
- package/dist-lib/MenuItem-CfkVXPvC.js +0 -140
- package/dist-lib/MonacoJson-BG3S3GHX.js +0 -60
- package/dist-lib/Profile.impl-Cypk27ah.js +0 -527
- package/dist-lib/PropertyGridEditor-XrP6TZ5s.js +0 -4378
- package/dist-lib/RecordHeader-BfQ0_4wq.js +0 -217
- package/dist-lib/RefreshControl-CRdWPoF5.js +0 -195
- package/dist-lib/SSOCallbackPage.impl-Cfi2pQ59.js +0 -31
- package/dist-lib/SmartDetailPage.impl-BiIX0n7K.js +0 -1609
- package/dist-lib/SmartListPage.impl-Cu83Gv_G.js +0 -2818
- package/dist-lib/SmartRecordListPage.impl-DR6lq7HA.js +0 -795
- package/dist-lib/format-count-lyB4CPen.js +0 -943
- package/dist-lib/peekDraftStore-CaimrOhW.js +0 -200
- package/dist-lib/registry-CGe5kCXN.js +0 -119
- package/dist-lib/use-filter-value-labels-D3YDgUzg.js +0 -413
- package/dist-lib/useAgentConversation-rru-7hnF.js +0 -612
- package/dist-lib/useBranding-zcxEic2k.js +0 -41
- package/dist-lib/useBrandingChrome-bxaR3G1R.js +0 -170
- package/dist-lib/useCurrentScreen-BZOHBGQZ.js +0 -2522
- package/dist-lib/useImpersonation-DBIRRR70.js +0 -35
- package/dist-lib/useOwnRefresh-DJjaje52.js +0 -435
- package/dist-lib/useParams-BFLJi4n3.js +0 -133
- package/dist-lib/useProperties-B7opZ-iy.js +0 -81
- package/dist-lib/useScreenBack-DENlz844.js +0 -71
- package/dist-lib/useTabNavigate-CUqOmcMj.js +0 -78
- package/dist-lib/value-BuQVYx52.js +0 -194
- package/dist-lib/variants-vUtfBbE6.js +0 -1961
- /package/dist-lib/{JsonEditor-Dz1PQHC8.js → components/fields/JsonEditor.js} +0 -0
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
import { Icon as e } from "../primitives/Icons.js";
|
|
2
|
+
import { useAnchoredTooltip as t } from "../primitives/Tooltip.js";
|
|
3
|
+
import { useText as n } from "../../hooks/useText.js";
|
|
4
|
+
import { DynamicIcon as r } from "../shared/DynamicIcon.js";
|
|
5
|
+
import { isValidLogoUrl as i } from "../../lib/branding.js";
|
|
6
|
+
import { useRef as a, useState as o } from "react";
|
|
7
|
+
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
8
|
+
//#region src/components/layout/Rail.tsx
|
|
9
|
+
var l = 32;
|
|
10
|
+
function u(e, t) {
|
|
11
|
+
return !t || t.length === 0 ? [] : t.map((t) => ({
|
|
12
|
+
id: t.code,
|
|
13
|
+
icon: t.icon || void 0,
|
|
14
|
+
label: e(t.name) || t.code
|
|
15
|
+
}));
|
|
16
|
+
}
|
|
17
|
+
function d({ activeArea: t, onPick: r, onToggleAI: a, aiOpen: o, onCmdK: d, areas: m, branding: h }) {
|
|
18
|
+
let g = n(), _ = u(g, m), v = h?.app_name ?? "", y = i(h?.app_logo) ? h?.app_logo : void 0;
|
|
19
|
+
return /* @__PURE__ */ c("div", {
|
|
20
|
+
style: {
|
|
21
|
+
gridArea: "rail",
|
|
22
|
+
background: "var(--rail)",
|
|
23
|
+
color: "var(--rail-fg)",
|
|
24
|
+
display: "flex",
|
|
25
|
+
flexDirection: "column",
|
|
26
|
+
alignItems: "center",
|
|
27
|
+
padding: "8px 0",
|
|
28
|
+
gap: 2
|
|
29
|
+
},
|
|
30
|
+
children: [
|
|
31
|
+
/* @__PURE__ */ s("div", {
|
|
32
|
+
style: {
|
|
33
|
+
width: l,
|
|
34
|
+
height: l,
|
|
35
|
+
borderRadius: "var(--radius-md)",
|
|
36
|
+
background: y ? "transparent" : "linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%)",
|
|
37
|
+
display: "flex",
|
|
38
|
+
alignItems: "center",
|
|
39
|
+
justifyContent: "center",
|
|
40
|
+
marginBottom: 8,
|
|
41
|
+
boxShadow: y ? "none" : "var(--shadow-sm)",
|
|
42
|
+
overflow: "hidden"
|
|
43
|
+
},
|
|
44
|
+
title: v ? g("shell.rail.home_named", "{brand} — home", { brand: v }) : g("shell.rail.home", "home"),
|
|
45
|
+
children: y ? /* @__PURE__ */ s("img", {
|
|
46
|
+
src: y,
|
|
47
|
+
alt: v,
|
|
48
|
+
width: l,
|
|
49
|
+
height: l,
|
|
50
|
+
style: {
|
|
51
|
+
display: "block",
|
|
52
|
+
objectFit: "contain"
|
|
53
|
+
}
|
|
54
|
+
}) : v ? /* @__PURE__ */ s("span", {
|
|
55
|
+
style: {
|
|
56
|
+
fontSize: 11,
|
|
57
|
+
fontWeight: 700,
|
|
58
|
+
letterSpacing: "0.04em"
|
|
59
|
+
},
|
|
60
|
+
children: v.charAt(0).toUpperCase()
|
|
61
|
+
}) : null
|
|
62
|
+
}),
|
|
63
|
+
_.map((e) => /* @__PURE__ */ s(f, {
|
|
64
|
+
item: e,
|
|
65
|
+
active: t === e.id,
|
|
66
|
+
onPick: r
|
|
67
|
+
}, e.id)),
|
|
68
|
+
/* @__PURE__ */ s("div", { style: { flex: 1 } }),
|
|
69
|
+
/* @__PURE__ */ s("button", {
|
|
70
|
+
onClick: d,
|
|
71
|
+
title: g("shell.palette.open", "Command Palette (⌘K)"),
|
|
72
|
+
style: p(!1),
|
|
73
|
+
children: e.command && /* @__PURE__ */ s(e.command, { size: 16 })
|
|
74
|
+
}),
|
|
75
|
+
/* @__PURE__ */ s("button", {
|
|
76
|
+
onClick: a,
|
|
77
|
+
title: g("shell.ai_assistant", "AI Assistant"),
|
|
78
|
+
style: {
|
|
79
|
+
...p(!1),
|
|
80
|
+
background: o ? "var(--accent)" : "transparent",
|
|
81
|
+
color: o ? "var(--rail-fg)" : "var(--rail-muted)"
|
|
82
|
+
},
|
|
83
|
+
children: e.sparkle && /* @__PURE__ */ s(e.sparkle, { size: 16 })
|
|
84
|
+
})
|
|
85
|
+
]
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
function f({ item: e, active: n, onPick: i }) {
|
|
89
|
+
let [l, u] = o(!1), d = a(null), f = t(d, e.label), p = n ? "var(--rail-active)" : l ? "var(--rail-hover)" : "transparent", m = n || l ? "var(--rail-fg)" : "var(--rail-muted)";
|
|
90
|
+
return /* @__PURE__ */ c("button", {
|
|
91
|
+
ref: d,
|
|
92
|
+
onClick: () => i(e.id),
|
|
93
|
+
"aria-label": e.label,
|
|
94
|
+
"aria-describedby": f.describedBy,
|
|
95
|
+
onMouseEnter: () => {
|
|
96
|
+
u(!0), f.triggerHandlers.onMouseEnter();
|
|
97
|
+
},
|
|
98
|
+
onMouseLeave: () => {
|
|
99
|
+
u(!1), f.triggerHandlers.onMouseLeave();
|
|
100
|
+
},
|
|
101
|
+
onFocus: f.triggerHandlers.onFocus,
|
|
102
|
+
onBlur: f.triggerHandlers.onBlur,
|
|
103
|
+
style: {
|
|
104
|
+
width: 36,
|
|
105
|
+
height: 36,
|
|
106
|
+
borderRadius: "var(--radius-md)",
|
|
107
|
+
display: "flex",
|
|
108
|
+
alignItems: "center",
|
|
109
|
+
justifyContent: "center",
|
|
110
|
+
background: p,
|
|
111
|
+
color: m,
|
|
112
|
+
border: "none",
|
|
113
|
+
cursor: "pointer",
|
|
114
|
+
position: "relative"
|
|
115
|
+
},
|
|
116
|
+
children: [
|
|
117
|
+
e.icon ? /* @__PURE__ */ s(r, {
|
|
118
|
+
name: e.icon,
|
|
119
|
+
size: 16
|
|
120
|
+
}) : null,
|
|
121
|
+
n && /* @__PURE__ */ s("span", { style: {
|
|
122
|
+
position: "absolute",
|
|
123
|
+
left: -1,
|
|
124
|
+
top: 8,
|
|
125
|
+
bottom: 8,
|
|
126
|
+
width: 2,
|
|
127
|
+
background: "var(--accent)",
|
|
128
|
+
borderRadius: "var(--radius-xs)"
|
|
129
|
+
} }),
|
|
130
|
+
f.portal
|
|
131
|
+
]
|
|
132
|
+
});
|
|
133
|
+
}
|
|
134
|
+
function p(e) {
|
|
135
|
+
return {
|
|
136
|
+
width: 36,
|
|
137
|
+
height: 36,
|
|
138
|
+
borderRadius: "var(--radius-md)",
|
|
139
|
+
display: "flex",
|
|
140
|
+
alignItems: "center",
|
|
141
|
+
justifyContent: "center",
|
|
142
|
+
background: "transparent",
|
|
143
|
+
color: "var(--rail-muted)",
|
|
144
|
+
border: 0,
|
|
145
|
+
cursor: "pointer"
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
//#endregion
|
|
149
|
+
export { d as Rail };
|
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
import { useSchema as e } from "../../hooks/useSchema.js";
|
|
2
|
+
import { Icon as t } from "../primitives/Icons.js";
|
|
3
|
+
import { Kbd as n } from "../primitives/Kbd.js";
|
|
4
|
+
import { useText as r } from "../../hooks/useText.js";
|
|
5
|
+
import { DynamicIcon as i } from "../shared/DynamicIcon.js";
|
|
6
|
+
import { BrandLogo as a } from "../primitives/BrandLogo.js";
|
|
7
|
+
import { useBrandingIdentity as o } from "../../hooks/useBranding.js";
|
|
8
|
+
import { usePreferencesStore as s } from "../../stores/preferences.js";
|
|
9
|
+
import { isModifiedClick as c } from "../../lib/utils.js";
|
|
10
|
+
import { useTabNavigate as l } from "../../hooks/useTabNavigate.js";
|
|
11
|
+
import { useIntentPrefetch as u } from "../../hooks/useIntentPrefetch.js";
|
|
12
|
+
import { useMemo as d, useState as f } from "react";
|
|
13
|
+
import { Fragment as p, jsx as m, jsxs as h } from "react/jsx-runtime";
|
|
14
|
+
import { useLocation as g } from "react-router";
|
|
15
|
+
//#region src/components/layout/Sidebar.tsx
|
|
16
|
+
function _({ activeArea: i }) {
|
|
17
|
+
let c = r(), { data: u } = e(), _ = g(), y = l(), x = s((e) => e.sidebar), S = s((e) => e.set), C = x === "collapsed", [w, T] = f({}), E = o(), D = E?.app_name ?? "", O = E?.app_logo, k = E?.version_label ?? "", A = d(() => v(c, u?.navigation ?? [], i), [
|
|
18
|
+
c,
|
|
19
|
+
u?.navigation,
|
|
20
|
+
i
|
|
21
|
+
]), j = (e) => e ? _.pathname === e || _.pathname.startsWith(e + "/") : !1, M = (e, t) => {
|
|
22
|
+
if (!e.screen) return;
|
|
23
|
+
let n = u?.screens[e.screen];
|
|
24
|
+
n && y(n.route, {
|
|
25
|
+
title: c(e.name),
|
|
26
|
+
icon: e.icon,
|
|
27
|
+
topLevel: !0
|
|
28
|
+
});
|
|
29
|
+
};
|
|
30
|
+
return /* @__PURE__ */ h("aside", {
|
|
31
|
+
style: {
|
|
32
|
+
gridArea: "sidebar",
|
|
33
|
+
background: "var(--sidebar)",
|
|
34
|
+
borderRight: "1px solid var(--border)",
|
|
35
|
+
display: "flex",
|
|
36
|
+
flexDirection: "column",
|
|
37
|
+
overflow: "hidden"
|
|
38
|
+
},
|
|
39
|
+
children: [
|
|
40
|
+
/* @__PURE__ */ m("div", {
|
|
41
|
+
style: {
|
|
42
|
+
height: 44,
|
|
43
|
+
display: "flex",
|
|
44
|
+
alignItems: "center",
|
|
45
|
+
padding: C ? 0 : "0 12px",
|
|
46
|
+
justifyContent: C ? "center" : "flex-start",
|
|
47
|
+
borderBottom: "1px solid var(--divider)",
|
|
48
|
+
gap: 8
|
|
49
|
+
},
|
|
50
|
+
children: C ? O ? /* @__PURE__ */ m(a, {
|
|
51
|
+
appLogo: O,
|
|
52
|
+
size: 18
|
|
53
|
+
}) : D ? /* @__PURE__ */ m("span", {
|
|
54
|
+
style: {
|
|
55
|
+
fontSize: 11,
|
|
56
|
+
fontWeight: 700,
|
|
57
|
+
color: "var(--accent-text)"
|
|
58
|
+
},
|
|
59
|
+
children: D.charAt(0)
|
|
60
|
+
}) : null : /* @__PURE__ */ h(p, { children: [
|
|
61
|
+
/* @__PURE__ */ m(a, {
|
|
62
|
+
appLogo: O,
|
|
63
|
+
size: 20
|
|
64
|
+
}),
|
|
65
|
+
/* @__PURE__ */ m("div", {
|
|
66
|
+
style: {
|
|
67
|
+
fontSize: 13,
|
|
68
|
+
fontWeight: 600,
|
|
69
|
+
letterSpacing: "-0.01em",
|
|
70
|
+
color: "var(--text)"
|
|
71
|
+
},
|
|
72
|
+
children: D
|
|
73
|
+
}),
|
|
74
|
+
k && /* @__PURE__ */ m("span", {
|
|
75
|
+
style: {
|
|
76
|
+
padding: "1px 6px",
|
|
77
|
+
background: "var(--accent-soft)",
|
|
78
|
+
color: "var(--accent-text)",
|
|
79
|
+
fontSize: 9.5,
|
|
80
|
+
fontWeight: 600,
|
|
81
|
+
borderRadius: "var(--radius-xs)",
|
|
82
|
+
letterSpacing: "0.04em",
|
|
83
|
+
textTransform: "uppercase"
|
|
84
|
+
},
|
|
85
|
+
children: k
|
|
86
|
+
})
|
|
87
|
+
] })
|
|
88
|
+
}),
|
|
89
|
+
/* @__PURE__ */ m("nav", {
|
|
90
|
+
style: {
|
|
91
|
+
flex: 1,
|
|
92
|
+
overflowY: "auto",
|
|
93
|
+
padding: C ? "8px 4px" : "8px 6px"
|
|
94
|
+
},
|
|
95
|
+
children: A.map((e, t) => /* @__PURE__ */ h("div", {
|
|
96
|
+
style: { marginBottom: 12 },
|
|
97
|
+
children: [!C && e.title && /* @__PURE__ */ m("div", {
|
|
98
|
+
style: {
|
|
99
|
+
fontSize: 9.5,
|
|
100
|
+
fontWeight: 700,
|
|
101
|
+
color: "var(--text-3)",
|
|
102
|
+
letterSpacing: "0.08em",
|
|
103
|
+
padding: "4px 10px 4px",
|
|
104
|
+
textTransform: "uppercase"
|
|
105
|
+
},
|
|
106
|
+
children: e.title
|
|
107
|
+
}), e.items.map((e, n) => {
|
|
108
|
+
let r = `${t}-${n}-${e.screen || c(e.name)}`, i = e.screen ? u?.screens[e.screen] : void 0, a = j(i?.route), o = !!(e.children && e.children.length > 0), s = !!w[r];
|
|
109
|
+
return /* @__PURE__ */ m(b, {
|
|
110
|
+
item: e,
|
|
111
|
+
href: i?.route,
|
|
112
|
+
collapsed: C,
|
|
113
|
+
active: a,
|
|
114
|
+
hasKids: o,
|
|
115
|
+
expanded: s,
|
|
116
|
+
onToggleExpand: () => T((e) => ({
|
|
117
|
+
...e,
|
|
118
|
+
[r]: !e[r]
|
|
119
|
+
})),
|
|
120
|
+
onPick: (t) => M(e, t),
|
|
121
|
+
resolveChild: (e) => e.screen ? u?.screens[e.screen] : void 0,
|
|
122
|
+
onPickChild: (e) => {
|
|
123
|
+
let t = e.screen ? u?.screens[e.screen] : void 0;
|
|
124
|
+
t && y(t.route, {
|
|
125
|
+
title: c(e.name),
|
|
126
|
+
icon: e.icon,
|
|
127
|
+
topLevel: !0
|
|
128
|
+
});
|
|
129
|
+
}
|
|
130
|
+
}, r);
|
|
131
|
+
})]
|
|
132
|
+
}, t))
|
|
133
|
+
}),
|
|
134
|
+
/* @__PURE__ */ h("div", {
|
|
135
|
+
style: {
|
|
136
|
+
padding: "6px 8px",
|
|
137
|
+
borderTop: "1px solid var(--divider)",
|
|
138
|
+
display: "flex",
|
|
139
|
+
alignItems: "center",
|
|
140
|
+
gap: 6,
|
|
141
|
+
justifyContent: C ? "center" : "space-between"
|
|
142
|
+
},
|
|
143
|
+
children: [/* @__PURE__ */ m("button", {
|
|
144
|
+
onClick: () => S("sidebar", C ? "wide" : "collapsed"),
|
|
145
|
+
title: C ? c("shell.sidebar.expand", "Expand sidebar (⌘B)") : c("shell.sidebar.collapse", "Collapse sidebar (⌘B)"),
|
|
146
|
+
style: {
|
|
147
|
+
display: "flex",
|
|
148
|
+
alignItems: "center",
|
|
149
|
+
justifyContent: "center",
|
|
150
|
+
width: 26,
|
|
151
|
+
height: 26,
|
|
152
|
+
borderRadius: "var(--radius-sm)",
|
|
153
|
+
background: "transparent",
|
|
154
|
+
border: 0,
|
|
155
|
+
color: "var(--text-3)",
|
|
156
|
+
cursor: "pointer"
|
|
157
|
+
},
|
|
158
|
+
children: m(C ? t.right : t.left, { size: 14 })
|
|
159
|
+
}), !C && /* @__PURE__ */ h(p, { children: [/* @__PURE__ */ m("span", {
|
|
160
|
+
style: {
|
|
161
|
+
flex: 1,
|
|
162
|
+
fontSize: 11,
|
|
163
|
+
color: "var(--text-3)"
|
|
164
|
+
},
|
|
165
|
+
children: c("shell.sidebar.footer", "Docs · API · Help")
|
|
166
|
+
}), /* @__PURE__ */ m(n, { children: "?" })] })]
|
|
167
|
+
})
|
|
168
|
+
]
|
|
169
|
+
});
|
|
170
|
+
}
|
|
171
|
+
function v(e, t, n) {
|
|
172
|
+
let r = [];
|
|
173
|
+
for (let i of t) if (y(i, n)) {
|
|
174
|
+
if (i.items && i.items.length > 0) r.push({
|
|
175
|
+
title: e(i.name) || "",
|
|
176
|
+
items: i.items
|
|
177
|
+
});
|
|
178
|
+
else if (i.screen) {
|
|
179
|
+
let e = r.find((e) => e.title === "");
|
|
180
|
+
e || (e = {
|
|
181
|
+
title: "",
|
|
182
|
+
items: []
|
|
183
|
+
}, r.push(e)), e.items.push(i);
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
return r;
|
|
187
|
+
}
|
|
188
|
+
function y(e, t) {
|
|
189
|
+
return (e.area || "default") === t;
|
|
190
|
+
}
|
|
191
|
+
function b({ item: e, href: n, collapsed: a, active: o, hasKids: s, expanded: l, onToggleExpand: d, onPick: g, onPickChild: _, resolveChild: v }) {
|
|
192
|
+
let y = r(), [b, S] = f(!1), C = u(n), w = !!e.icon, T = y(e.name) || e.screen || "";
|
|
193
|
+
if (a) {
|
|
194
|
+
let t = {
|
|
195
|
+
width: 40,
|
|
196
|
+
height: 32,
|
|
197
|
+
margin: "2px auto",
|
|
198
|
+
borderRadius: "var(--radius-md)",
|
|
199
|
+
border: 0,
|
|
200
|
+
cursor: "pointer",
|
|
201
|
+
display: "flex",
|
|
202
|
+
alignItems: "center",
|
|
203
|
+
justifyContent: "center",
|
|
204
|
+
background: o ? "var(--sidebar-active)" : b ? "var(--sidebar-hover)" : "transparent",
|
|
205
|
+
color: o ? "var(--accent)" : "var(--text-3)",
|
|
206
|
+
textDecoration: "none"
|
|
207
|
+
};
|
|
208
|
+
return n ? /* @__PURE__ */ m("a", {
|
|
209
|
+
href: n,
|
|
210
|
+
"data-declarion-native-link": "",
|
|
211
|
+
...C,
|
|
212
|
+
onClick: (e) => {
|
|
213
|
+
c(e) || (e.preventDefault(), g());
|
|
214
|
+
},
|
|
215
|
+
title: T,
|
|
216
|
+
onMouseEnter: () => S(!0),
|
|
217
|
+
onMouseLeave: () => S(!1),
|
|
218
|
+
style: t,
|
|
219
|
+
children: w && /* @__PURE__ */ m(i, {
|
|
220
|
+
name: e.icon,
|
|
221
|
+
size: 14
|
|
222
|
+
})
|
|
223
|
+
}) : /* @__PURE__ */ m("button", {
|
|
224
|
+
onClick: () => g(),
|
|
225
|
+
title: T,
|
|
226
|
+
onMouseEnter: () => S(!0),
|
|
227
|
+
onMouseLeave: () => S(!1),
|
|
228
|
+
style: t,
|
|
229
|
+
children: w && /* @__PURE__ */ m(i, {
|
|
230
|
+
name: e.icon,
|
|
231
|
+
size: 14
|
|
232
|
+
})
|
|
233
|
+
});
|
|
234
|
+
}
|
|
235
|
+
let E = {
|
|
236
|
+
width: "calc(100% - 4px)",
|
|
237
|
+
margin: "0 2px",
|
|
238
|
+
display: "flex",
|
|
239
|
+
alignItems: "center",
|
|
240
|
+
gap: 8,
|
|
241
|
+
padding: "5px 8px",
|
|
242
|
+
borderRadius: "var(--radius-sm)",
|
|
243
|
+
border: 0,
|
|
244
|
+
cursor: "pointer",
|
|
245
|
+
textAlign: "left",
|
|
246
|
+
background: o ? "var(--sidebar-active)" : b ? "var(--sidebar-hover)" : "transparent",
|
|
247
|
+
color: o ? "var(--accent)" : "var(--text-2)",
|
|
248
|
+
fontSize: 12.5,
|
|
249
|
+
fontWeight: o ? 600 : 500,
|
|
250
|
+
textDecoration: "none"
|
|
251
|
+
}, D = /* @__PURE__ */ h(p, { children: [
|
|
252
|
+
w && /* @__PURE__ */ m(i, {
|
|
253
|
+
name: e.icon,
|
|
254
|
+
size: 14
|
|
255
|
+
}),
|
|
256
|
+
/* @__PURE__ */ m("span", {
|
|
257
|
+
style: { flex: 1 },
|
|
258
|
+
children: T
|
|
259
|
+
}),
|
|
260
|
+
e.badge && /* @__PURE__ */ m("span", {
|
|
261
|
+
style: {
|
|
262
|
+
padding: "1px 5px",
|
|
263
|
+
background: "var(--surface-3)",
|
|
264
|
+
color: "var(--text-2)",
|
|
265
|
+
borderRadius: "var(--radius-xs)",
|
|
266
|
+
fontSize: 10,
|
|
267
|
+
fontWeight: 600
|
|
268
|
+
},
|
|
269
|
+
children: e.badge
|
|
270
|
+
}),
|
|
271
|
+
s && /* @__PURE__ */ m("span", {
|
|
272
|
+
role: "button",
|
|
273
|
+
"aria-label": l ? y("shell.sidebar.collapse_item", "Collapse") : y("shell.sidebar.expand_item", "Expand"),
|
|
274
|
+
onClick: (e) => {
|
|
275
|
+
e.stopPropagation(), e.preventDefault(), d();
|
|
276
|
+
},
|
|
277
|
+
style: {
|
|
278
|
+
display: "inline-flex",
|
|
279
|
+
padding: 2,
|
|
280
|
+
cursor: "pointer"
|
|
281
|
+
},
|
|
282
|
+
children: /* @__PURE__ */ m(t.down, {
|
|
283
|
+
size: 11,
|
|
284
|
+
style: {
|
|
285
|
+
transform: l ? "rotate(0)" : "rotate(-90deg)",
|
|
286
|
+
transition: "transform .15s",
|
|
287
|
+
color: "var(--text-3)"
|
|
288
|
+
}
|
|
289
|
+
})
|
|
290
|
+
})
|
|
291
|
+
] });
|
|
292
|
+
return /* @__PURE__ */ h("div", { children: [n ? /* @__PURE__ */ m("a", {
|
|
293
|
+
href: n,
|
|
294
|
+
"data-declarion-native-link": "",
|
|
295
|
+
...C,
|
|
296
|
+
onClick: (e) => {
|
|
297
|
+
c(e) || (e.preventDefault(), g());
|
|
298
|
+
},
|
|
299
|
+
onMouseEnter: () => S(!0),
|
|
300
|
+
onMouseLeave: () => S(!1),
|
|
301
|
+
style: E,
|
|
302
|
+
children: D
|
|
303
|
+
}) : /* @__PURE__ */ m("button", {
|
|
304
|
+
onClick: () => {
|
|
305
|
+
s && d();
|
|
306
|
+
},
|
|
307
|
+
onMouseEnter: () => S(!0),
|
|
308
|
+
onMouseLeave: () => S(!1),
|
|
309
|
+
style: E,
|
|
310
|
+
children: D
|
|
311
|
+
}), s && l && /* @__PURE__ */ m("div", {
|
|
312
|
+
style: {
|
|
313
|
+
marginLeft: 22,
|
|
314
|
+
borderLeft: "1px solid var(--divider)",
|
|
315
|
+
paddingLeft: 6
|
|
316
|
+
},
|
|
317
|
+
children: (e.children || []).map((e, t) => {
|
|
318
|
+
let n = v(e), r = e.screen || `${t}`;
|
|
319
|
+
return /* @__PURE__ */ m(x, {
|
|
320
|
+
label: y(e.name) || e.screen || "",
|
|
321
|
+
href: n?.route,
|
|
322
|
+
enabled: !!n,
|
|
323
|
+
onPick: () => _(e)
|
|
324
|
+
}, r);
|
|
325
|
+
})
|
|
326
|
+
})] });
|
|
327
|
+
}
|
|
328
|
+
function x({ label: e, href: t, enabled: n, onPick: r }) {
|
|
329
|
+
let [i, a] = f(!1), o = u(n ? t : void 0), s = {
|
|
330
|
+
width: "100%",
|
|
331
|
+
display: "block",
|
|
332
|
+
padding: "4px 8px",
|
|
333
|
+
borderRadius: "var(--radius-sm)",
|
|
334
|
+
background: i ? "var(--sidebar-hover)" : "transparent",
|
|
335
|
+
border: 0,
|
|
336
|
+
textAlign: "left",
|
|
337
|
+
cursor: n ? "pointer" : "default",
|
|
338
|
+
fontSize: 12,
|
|
339
|
+
color: "var(--text-3)",
|
|
340
|
+
textDecoration: "none"
|
|
341
|
+
};
|
|
342
|
+
return n && t ? /* @__PURE__ */ m("a", {
|
|
343
|
+
href: t,
|
|
344
|
+
"data-declarion-native-link": "",
|
|
345
|
+
...o,
|
|
346
|
+
onClick: (e) => {
|
|
347
|
+
c(e) || (e.preventDefault(), r());
|
|
348
|
+
},
|
|
349
|
+
onMouseEnter: () => a(!0),
|
|
350
|
+
onMouseLeave: () => a(!1),
|
|
351
|
+
style: s,
|
|
352
|
+
children: e
|
|
353
|
+
}) : /* @__PURE__ */ m("button", {
|
|
354
|
+
onClick: () => n && r(),
|
|
355
|
+
onMouseEnter: () => a(!0),
|
|
356
|
+
onMouseLeave: () => a(!1),
|
|
357
|
+
style: s,
|
|
358
|
+
children: e
|
|
359
|
+
});
|
|
360
|
+
}
|
|
361
|
+
//#endregion
|
|
362
|
+
export { _ as Sidebar, v as buildSections };
|