@declarion/react 0.141.0 → 0.146.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/{Icons-Dzl-AkD_.d.ts → Icons-BdXCxyw3.d.ts} +0 -4
- package/dist-lib/api/access-expiry.js +1 -2
- package/dist-lib/api/agents.js +1 -2
- package/dist-lib/api/audience.js +1 -2
- package/dist-lib/api/auth-redirect.js +1 -2
- package/dist-lib/api/auth.js +1 -2
- package/dist-lib/api/batch.js +1 -2
- package/dist-lib/api/client.js +27 -28
- package/dist-lib/api/data.js +23 -24
- package/dist-lib/api/entities.js +36 -37
- package/dist-lib/api/events.js +6 -7
- package/dist-lib/api/fileReferences.js +1 -2
- package/dist-lib/api/params.js +1 -2
- package/dist-lib/api/properties.js +1 -2
- package/dist-lib/api/request-bounds.js +1 -2
- package/dist-lib/api/schema.js +5 -6
- package/dist-lib/api/session-renewal.js +6 -7
- package/dist-lib/api/status.js +1 -2
- package/dist-lib/app.js +154 -155
- package/dist-lib/components/actions/ActionButton.js +32 -33
- package/dist-lib/components/actions/ActionDialog.js +85 -86
- package/dist-lib/components/actions/ActionResultDialog.impl.js +48 -49
- package/dist-lib/components/actions/ActionResultDialog.js +1 -2
- package/dist-lib/components/actions/ActionRunner.js +96 -97
- package/dist-lib/components/actions/ObjectActionBar.js +49 -50
- package/dist-lib/components/actions/PropertyGridEditor.js +50 -51
- package/dist-lib/components/actions/ResponsiveActionBar.js +127 -128
- package/dist-lib/components/actions/RowActionsKebab.js +27 -28
- package/dist-lib/components/agents/AgentChatPanel.impl.js +317 -318
- package/dist-lib/components/agents/AgentChatPanel.js +1 -2
- package/dist-lib/components/agents/AgentConversationDrawer.js +6 -7
- package/dist-lib/components/agents/AgentElicitForm.js +13 -14
- package/dist-lib/components/agents/AgentOpenFollower.impl.js +1 -2
- package/dist-lib/components/agents/AgentOpenFollower.js +1 -2
- package/dist-lib/components/agents/AgentPicker.js +1 -2
- package/dist-lib/components/agents/ChatAttachments.js +22 -23
- package/dist-lib/components/agents/transcript-runs.js +1 -2
- package/dist-lib/components/chrome/AssociationTabs.js +44 -45
- package/dist-lib/components/chrome/AuditMetaStrip.js +1 -2
- package/dist-lib/components/chrome/Breadcrumbs.js +1 -2
- package/dist-lib/components/chrome/HighlightsStrip.js +1 -2
- package/dist-lib/components/chrome/PageHeader.js +12 -13
- package/dist-lib/components/chrome/PageShell.js +1 -2
- package/dist-lib/components/chrome/RecordHeader.js +1 -2
- package/dist-lib/components/chrome/headerActionZone.js +0 -1
- package/dist-lib/components/detail-layout/AssociatedBlock.js +463 -464
- package/dist-lib/components/detail-layout/AssociatedToolbar.js +43 -44
- package/dist-lib/components/detail-layout/ChildrenBlock.js +24 -25
- package/dist-lib/components/detail-layout/ChildrenCards.js +29 -30
- package/dist-lib/components/detail-layout/ChildrenList.js +23 -24
- package/dist-lib/components/detail-layout/ChildrenTable.js +50 -51
- package/dist-lib/components/detail-layout/ChildrenTimeline.js +164 -165
- package/dist-lib/components/detail-layout/DetailAuditStrip.js +14 -15
- package/dist-lib/components/detail-layout/DetailHighlights.js +23 -24
- package/dist-lib/components/detail-layout/DraggableChildrenTable.js +76 -77
- package/dist-lib/components/detail-layout/EditableChildrenTable.js +90 -91
- package/dist-lib/components/detail-layout/ErrorSummary.js +7 -8
- package/dist-lib/components/detail-layout/EvidenceBlock.js +15 -16
- package/dist-lib/components/detail-layout/FieldRow.js +11 -12
- package/dist-lib/components/detail-layout/FieldsBlock.js +31 -32
- package/dist-lib/components/detail-layout/LayoutColumn.js +1 -2
- package/dist-lib/components/detail-layout/LayoutRenderer.js +11 -12
- package/dist-lib/components/detail-layout/LayoutRow.js +1 -2
- package/dist-lib/components/detail-layout/LayoutTabs.js +23 -24
- package/dist-lib/components/detail-layout/PropertiesBlock.js +38 -39
- package/dist-lib/components/detail-layout/QuickAddForm.js +28 -29
- package/dist-lib/components/detail-layout/SectionBlock.js +9 -10
- package/dist-lib/components/detail-layout/StatusesBlock.js +1 -2
- package/dist-lib/components/detail-layout/TimelineComposer.js +19 -20
- package/dist-lib/components/detail-layout/blockMeta.js +1 -2
- package/dist-lib/components/detail-layout/useManualColumnResize.js +1 -2
- package/dist-lib/components/detail-layout/useQuickAdd.js +21 -22
- package/dist-lib/components/detail-layout/visibility.js +1 -2
- package/dist-lib/components/detail-layout/widgets/EntityScorecardWidget.js +25 -26
- package/dist-lib/components/detail-layout/widgets/JsonDiffWidget.js +18 -19
- package/dist-lib/components/detail-layout/widgets/MonacoJson.js +1 -2
- package/dist-lib/components/detail-layout/widgets/WidgetHost.js +10 -11
- package/dist-lib/components/detail-layout/widgets/builtins.js +1 -2
- package/dist-lib/components/detail-layout/widgets/canonicalizeJson.js +1 -2
- package/dist-lib/components/detail-layout/widgets/monacoBootstrap.js +1 -2
- package/dist-lib/components/detail-layout/widgets/registry.js +1 -2
- package/dist-lib/components/fields/BoolField.js +1 -2
- package/dist-lib/components/fields/EmailField.js +5 -6
- package/dist-lib/components/fields/EnumField.js +7 -8
- package/dist-lib/components/fields/FileReferenceField.js +18 -19
- package/dist-lib/components/fields/IntArrayField.js +11 -12
- package/dist-lib/components/fields/JsonEditor.js +1 -2
- package/dist-lib/components/fields/JsonField.js +1 -2
- package/dist-lib/components/fields/MultilangArrayField.js +22 -23
- package/dist-lib/components/fields/MultilangField.js +13 -14
- package/dist-lib/components/fields/MultilangTextField.js +13 -14
- package/dist-lib/components/fields/NumberField.js +5 -6
- package/dist-lib/components/fields/PasswordField.js +1 -2
- package/dist-lib/components/fields/PhoneField.js +24 -25
- package/dist-lib/components/fields/RefCombobox.js +42 -43
- package/dist-lib/components/fields/RefField.js +14 -15
- package/dist-lib/components/fields/RichTextField.js +29 -30
- package/dist-lib/components/fields/SecretField.js +1 -2
- package/dist-lib/components/fields/StringArrayField.js +29 -30
- package/dist-lib/components/fields/StringField.js +12 -13
- package/dist-lib/components/fields/StructureField.js +60 -61
- package/dist-lib/components/fields/TextField.js +18 -19
- package/dist-lib/components/fields/TimestampField.js +17 -18
- package/dist-lib/components/fields/UrlField.js +5 -6
- package/dist-lib/components/fields/cells/factories/badge.js +5 -6
- package/dist-lib/components/fields/cells/factories/boolPill.js +1 -2
- package/dist-lib/components/fields/cells/factories/code.js +1 -2
- package/dist-lib/components/fields/cells/factories/date.js +1 -2
- package/dist-lib/components/fields/cells/factories/email.js +1 -2
- package/dist-lib/components/fields/cells/factories/emptyCell.js +0 -1
- package/dist-lib/components/fields/cells/factories/fileReference.js +1 -2
- package/dist-lib/components/fields/cells/factories/host-icons.js +1 -2
- package/dist-lib/components/fields/cells/factories/json.js +1 -2
- package/dist-lib/components/fields/cells/factories/link.js +10 -11
- package/dist-lib/components/fields/cells/factories/markdown.js +14 -15
- package/dist-lib/components/fields/cells/factories/markdownPreview.js +1 -2
- package/dist-lib/components/fields/cells/factories/money.js +1 -2
- package/dist-lib/components/fields/cells/factories/multilangInline.js +1 -2
- package/dist-lib/components/fields/cells/factories/nextRun.js +8 -9
- package/dist-lib/components/fields/cells/factories/number.js +1 -2
- package/dist-lib/components/fields/cells/factories/passwordMask.js +1 -2
- package/dist-lib/components/fields/cells/factories/phone.js +1 -2
- package/dist-lib/components/fields/cells/factories/refLink.js +13 -14
- package/dist-lib/components/fields/cells/factories/richTextPreview.js +16 -17
- package/dist-lib/components/fields/cells/factories/statusPill.js +5 -6
- package/dist-lib/components/fields/cells/factories/tagList.js +6 -7
- package/dist-lib/components/fields/cells/factories/text.js +1 -2
- package/dist-lib/components/fields/cells/factories/timestamp.js +1 -2
- package/dist-lib/components/fields/cells/factories/url-helpers.js +1 -2
- package/dist-lib/components/fields/cells/factories/url.js +13 -14
- package/dist-lib/components/fields/cells/registry.js +1 -2
- package/dist-lib/components/fields/index.js +19 -20
- package/dist-lib/components/fields/langMap.js +1 -2
- package/dist-lib/components/fields/secretValue.js +1 -2
- package/dist-lib/components/file-widgets/CircleImage.js +1 -2
- package/dist-lib/components/file-widgets/DocumentCard.js +101 -102
- package/dist-lib/components/file-widgets/FileList.js +35 -36
- package/dist-lib/components/file-widgets/Grid.js +119 -120
- package/dist-lib/components/file-widgets/GridLazy.js +1 -2
- package/dist-lib/components/file-widgets/ImageWidget.js +189 -190
- package/dist-lib/components/file-widgets/LabeledSlots.js +14 -15
- package/dist-lib/components/file-widgets/SquareImage.js +1 -2
- package/dist-lib/components/file-widgets/UnknownFileWidget.js +1 -2
- package/dist-lib/components/file-widgets/UploadFailureText.js +1 -2
- package/dist-lib/components/file-widgets/WideBanner.js +1 -2
- package/dist-lib/components/file-widgets/builtins.js +1 -2
- package/dist-lib/components/file-widgets/cropper.js +1 -2
- package/dist-lib/components/file-widgets/draft-scope.js +1 -2
- package/dist-lib/components/file-widgets/helpers.js +1 -2
- package/dist-lib/components/file-widgets/host.js +33 -34
- package/dist-lib/components/file-widgets/payload.js +1 -2
- package/dist-lib/components/file-widgets/registry.js +1 -2
- package/dist-lib/components/file-widgets/upload.js +41 -42
- package/dist-lib/components/file-widgets/useEmbedFileSrc.js +12 -13
- package/dist-lib/components/file-widgets/useFileSelection.js +1 -2
- package/dist-lib/components/file-widgets/value.js +1 -2
- package/dist-lib/components/filters/FilterChips.js +15 -16
- package/dist-lib/components/filters/FilterConditionValue.js +15 -16
- package/dist-lib/components/filters/FilterDrawer.js +141 -142
- package/dist-lib/components/filters/FilterOmittedNotice.js +1 -2
- package/dist-lib/components/filters/filter-op-label.js +1 -2
- package/dist-lib/components/layout/CommandPalette.impl.js +24 -25
- package/dist-lib/components/layout/CommandPalette.js +1 -2
- package/dist-lib/components/layout/DirtyTabsCloseDialog.impl.js +15 -16
- package/dist-lib/components/layout/DirtyTabsCloseDialog.js +1 -2
- package/dist-lib/components/layout/ImpersonationBanner.impl.js +6 -7
- package/dist-lib/components/layout/ImpersonationBanner.js +1 -2
- package/dist-lib/components/layout/ImpersonationFrame.js +4 -5
- package/dist-lib/components/layout/ImpersonationStartModal.impl.js +4 -5
- package/dist-lib/components/layout/ImpersonationStartModal.js +1 -2
- package/dist-lib/components/layout/Layout.js +132 -140
- package/dist-lib/components/layout/Rail.js +11 -12
- package/dist-lib/components/layout/Sidebar.js +60 -61
- package/dist-lib/components/layout/TabStrip.js +66 -67
- package/dist-lib/components/layout/TenantChip.js +21 -22
- package/dist-lib/components/layout/TopBar.js +89 -90
- package/dist-lib/components/layout/tab-close.js +1 -2
- package/dist-lib/components/list/ColumnPicker.js +35 -36
- package/dist-lib/components/list/InlineEditCell.js +22 -23
- package/dist-lib/components/list/PeekFieldCell.js +7 -8
- package/dist-lib/components/list/QuickPeek.js +29 -30
- package/dist-lib/components/list/ViewSwitcher.js +44 -45
- package/dist-lib/components/list/peekDraftStore.js +1 -2
- package/dist-lib/components/pages/AdminCatalogPage.impl.js +59 -60
- package/dist-lib/components/pages/AdminCatalogPage.js +1 -2
- package/dist-lib/components/pages/DocumentsMenu.js +53 -54
- package/dist-lib/components/pages/ExportMenu.js +37 -38
- package/dist-lib/components/pages/NoScreensPage.impl.js +5 -6
- package/dist-lib/components/pages/NoScreensPage.js +1 -2
- package/dist-lib/components/pages/NotFoundPage.impl.js +7 -8
- package/dist-lib/components/pages/NotFoundPage.js +1 -2
- package/dist-lib/components/pages/RecordDocumentsPanel.js +40 -41
- package/dist-lib/components/pages/RecordNotesPanel.js +43 -44
- package/dist-lib/components/pages/RecordPanels.js +1 -2
- package/dist-lib/components/pages/SSOCallbackPage.impl.js +6 -7
- package/dist-lib/components/pages/SSOCallbackPage.js +1 -2
- package/dist-lib/components/pages/SmartDetailPage.impl.js +501 -502
- package/dist-lib/components/pages/SmartDetailPage.js +1 -2
- package/dist-lib/components/pages/SmartListPage.impl.js +316 -317
- package/dist-lib/components/pages/SmartListPage.js +1 -2
- package/dist-lib/components/pages/SmartRecordListPage.impl.js +316 -317
- package/dist-lib/components/pages/SmartRecordListPage.js +1 -2
- package/dist-lib/components/pages/auth/AuthShell.js +14 -15
- package/dist-lib/components/pages/auth/CodeInput.js +0 -1
- package/dist-lib/components/pages/auth/Forgot.impl.js +12 -13
- package/dist-lib/components/pages/auth/Forgot.js +1 -2
- package/dist-lib/components/pages/auth/Reset.impl.js +20 -21
- package/dist-lib/components/pages/auth/Reset.js +1 -2
- package/dist-lib/components/pages/auth/SignIn.js +44 -45
- package/dist-lib/components/pages/auth/SignUp.impl.js +35 -36
- package/dist-lib/components/pages/auth/SignUp.js +1 -2
- package/dist-lib/components/pages/auth/SignUpCode.js +17 -18
- package/dist-lib/components/pages/auth/TwoFA.impl.js +9 -10
- package/dist-lib/components/pages/auth/TwoFA.js +1 -2
- package/dist-lib/components/pages/auth/icons.js +1 -2
- package/dist-lib/components/pages/exportRequest.js +1 -2
- package/dist-lib/components/pages/list/DataCell.js +1 -2
- package/dist-lib/components/pages/list/DeleteViewDialog.js +5 -6
- package/dist-lib/components/pages/list/ListCardRow.js +53 -54
- package/dist-lib/components/pages/list/ListCardsBody.js +1 -2
- package/dist-lib/components/pages/list/ListFloatbar.js +25 -26
- package/dist-lib/components/pages/list/ListFooter.js +17 -18
- package/dist-lib/components/pages/list/ListHeader.js +31 -32
- package/dist-lib/components/pages/list/ListNoRows.js +32 -33
- package/dist-lib/components/pages/list/ListTable.js +29 -30
- package/dist-lib/components/pages/list/ListTableRow.js +1 -2
- package/dist-lib/components/pages/list/ListToolbar.js +58 -59
- package/dist-lib/components/pages/list/ListUrlBanner.js +1 -2
- package/dist-lib/components/pages/list/RowActionsCell.js +6 -7
- package/dist-lib/components/pages/list/RowContextMenu.js +1 -2
- package/dist-lib/components/pages/list/SaveViewDialog.js +5 -6
- package/dist-lib/components/pages/list/SortHeaderMenu.js +25 -26
- package/dist-lib/components/pages/list/cardProjection.js +16 -17
- package/dist-lib/components/pages/list/column-sizing.js +1 -2
- package/dist-lib/components/pages/list/columns.js +74 -75
- package/dist-lib/components/pages/list/filter-meta.js +1 -2
- package/dist-lib/components/pages/list/page-size.js +1 -2
- package/dist-lib/components/pages/list/sortable-header.js +1 -2
- package/dist-lib/components/pages/list/table-features.js +1 -2
- package/dist-lib/components/pages/list/use-filter-value-labels.js +15 -16
- package/dist-lib/components/pages/list/useActiveView.js +1 -2
- package/dist-lib/components/pages/list/useHeaderReorder.js +1 -2
- package/dist-lib/components/pages/list/useListColumnLayout.js +6 -7
- package/dist-lib/components/pages/list/useListFilterPresentation.js +1 -2
- package/dist-lib/components/pages/list/useListQuery.js +1 -2
- package/dist-lib/components/pages/list/useListRowInteraction.js +37 -38
- package/dist-lib/components/pages/list/useListSelection.js +16 -17
- package/dist-lib/components/pages/list/useListSort.js +1 -2
- package/dist-lib/components/pages/list/useListViews.js +31 -32
- package/dist-lib/components/pages/list/useRowMenu.js +20 -21
- package/dist-lib/components/pages/list/visible-filters.js +1 -2
- package/dist-lib/components/pages/profile/Preferences.impl.js +44 -45
- package/dist-lib/components/pages/profile/Preferences.js +1 -2
- package/dist-lib/components/pages/profile/Profile.impl.js +223 -224
- package/dist-lib/components/pages/profile/Profile.js +1 -2
- package/dist-lib/components/pages/tenant-params/TenantParamsPage.impl.js +133 -134
- package/dist-lib/components/pages/tenant-params/TenantParamsPage.js +1 -2
- package/dist-lib/components/params/ParamsBlock.js +30 -31
- package/dist-lib/components/params/param-editors.js +58 -59
- package/dist-lib/components/primitives/Avatar.js +1 -2
- package/dist-lib/components/primitives/BoolToggle.js +1 -2
- package/dist-lib/components/primitives/BrandGlyph.js +1 -2
- package/dist-lib/components/primitives/BrandLogo.js +1 -2
- package/dist-lib/components/primitives/Btn.js +1 -2
- package/dist-lib/components/primitives/Check.js +1 -2
- package/dist-lib/components/primitives/Chip.js +1 -2
- package/dist-lib/components/primitives/ClassifiedFieldLocked.js +1 -2
- package/dist-lib/components/primitives/Dropdown.js +2 -3
- package/dist-lib/components/primitives/Fields.js +128 -129
- package/dist-lib/components/primitives/HoverCard.js +2 -3
- package/dist-lib/components/primitives/IconBtn.js +1 -2
- package/dist-lib/components/primitives/Icons.js +1 -2
- package/dist-lib/components/primitives/Kbd.js +1 -2
- package/dist-lib/components/primitives/MenuItem.js +1 -2
- package/dist-lib/components/primitives/Pill.js +1 -2
- package/dist-lib/components/primitives/RecordIdBadge.js +1 -2
- package/dist-lib/components/primitives/RetryButton.js +5 -6
- package/dist-lib/components/primitives/RowField.js +1 -2
- package/dist-lib/components/primitives/SectionCard.js +1 -2
- package/dist-lib/components/primitives/Spinner.js +1 -2
- package/dist-lib/components/primitives/StatTile.js +1 -2
- package/dist-lib/components/primitives/Tooltip.js +1 -2
- package/dist-lib/components/primitives/dataTableStyles.js +1 -2
- package/dist-lib/components/shared/BlankScreen.js +1 -2
- package/dist-lib/components/shared/ChangePasswordDialog.impl.js +20 -21
- package/dist-lib/components/shared/ChangePasswordDialog.js +1 -2
- package/dist-lib/components/shared/ConfirmDialog.js +7 -8
- package/dist-lib/components/shared/ConnectionNotice.js +1 -2
- package/dist-lib/components/shared/CopyButton.js +1 -2
- package/dist-lib/components/shared/DynamicIcon.js +1 -2
- package/dist-lib/components/shared/EmptyState.js +1 -2
- package/dist-lib/components/shared/ErrorBoundary.js +10 -11
- package/dist-lib/components/shared/LoadingSkeleton.js +1 -2
- package/dist-lib/components/shared/LucideIcon.js +1 -2
- package/dist-lib/components/shared/Markdown.js +1 -2
- package/dist-lib/components/shared/MarkdownRenderer.js +22 -23
- package/dist-lib/components/shared/ModalFrame.js +1 -2
- package/dist-lib/components/shared/RefreshControl.js +6 -7
- package/dist-lib/components/shared/StatusGroupsDisplay.js +16 -17
- package/dist-lib/components/shared/StatusStepper.js +1 -2
- package/dist-lib/components/shared/toast/DeclarionToast.js +1 -2
- package/dist-lib/components/shared/useOwnRefresh.js +1 -2
- package/dist-lib/embed/EmbedAuthBootstrap.js +30 -31
- package/dist-lib/embed/EmbedContext.js +1 -2
- package/dist-lib/embed/EmbedDirtyReporter.js +6 -7
- package/dist-lib/embed/EmbedHistoryTracker.js +1 -2
- package/dist-lib/embed/EmbedLocationReporter.js +11 -12
- package/dist-lib/embed/EmbedResizeReporter.js +9 -10
- package/dist-lib/embed/EmbedUnsavedGuard.js +5 -6
- package/dist-lib/embed/embed-dirty.js +1 -2
- package/dist-lib/embed/embed-history.js +1 -2
- package/dist-lib/embed/embed-nav-guard.js +1 -2
- package/dist-lib/embed/file-src.js +12 -13
- package/dist-lib/embed/handshake.js +1 -2
- package/dist-lib/embed/params.js +1 -2
- package/dist-lib/embed/protocol.js +1 -2
- package/dist-lib/embed/screen-location.js +1 -2
- package/dist-lib/embed/theme.js +1 -2
- package/dist-lib/embed/token.js +1 -2
- package/dist-lib/embed/useEmbedNavigate.js +25 -26
- package/dist-lib/embed/useGlobalLinkInterceptor.js +9 -10
- package/dist-lib/hooks/useActionData.js +1 -2
- package/dist-lib/hooks/useActiveTabFollowsRoute.js +7 -8
- package/dist-lib/hooks/useAgentConversation.js +122 -123
- package/dist-lib/hooks/useAggregate.js +1 -2
- package/dist-lib/hooks/useAllEntityData.js +9 -10
- package/dist-lib/hooks/useAssociatedData.js +1 -2
- package/dist-lib/hooks/useAuth.js +26 -27
- package/dist-lib/hooks/useBranding.js +1 -2
- package/dist-lib/hooks/useBrandingChrome.js +16 -17
- package/dist-lib/hooks/useChildrenData.js +4 -5
- package/dist-lib/hooks/useColumns.js +1 -2
- package/dist-lib/hooks/useConnectionNotice.js +16 -17
- package/dist-lib/hooks/useCurrentLocation.js +1 -2
- package/dist-lib/hooks/useCurrentScreen.js +1 -2
- package/dist-lib/hooks/useCursorEntityData.js +1 -2
- package/dist-lib/hooks/useDebounce.js +1 -2
- package/dist-lib/hooks/useDisplayTimeZone.js +4 -5
- package/dist-lib/hooks/useDocumentTitle.js +5 -6
- package/dist-lib/hooks/useEntity.js +1 -2
- package/dist-lib/hooks/useEntityData.js +1 -2
- package/dist-lib/hooks/useFileReferenceJSON.js +9 -10
- package/dist-lib/hooks/useFilters.js +5 -6
- package/dist-lib/hooks/useFollowAgentOpen.js +40 -41
- package/dist-lib/hooks/useImpersonation.js +15 -16
- package/dist-lib/hooks/useIntentPrefetch.js +6 -7
- package/dist-lib/hooks/useJsonSnapshot.js +1 -2
- package/dist-lib/hooks/useLanguage.js +11 -12
- package/dist-lib/hooks/useLiveObject.js +6 -7
- package/dist-lib/hooks/useLongPress.js +1 -2
- package/dist-lib/hooks/useMutations.js +31 -32
- package/dist-lib/hooks/useObject.js +1 -2
- package/dist-lib/hooks/useObjectStatus.js +4 -5
- package/dist-lib/hooks/usePageState.js +9 -10
- package/dist-lib/hooks/usePageStateRuntime.js +16 -17
- package/dist-lib/hooks/usePageStateTtl.js +1 -2
- package/dist-lib/hooks/useParams.js +58 -59
- package/dist-lib/hooks/useProperties.js +5 -6
- package/dist-lib/hooks/useRealtimeThresholds.js +4 -5
- package/dist-lib/hooks/useRefRecords.js +31 -32
- package/dist-lib/hooks/useRegisterScreenTab.js +12 -13
- package/dist-lib/hooks/useResponsiveMode.js +1 -2
- package/dist-lib/hooks/useRowTenant.js +1 -2
- package/dist-lib/hooks/useSSE.js +100 -101
- package/dist-lib/hooks/useSchema.js +16 -17
- package/dist-lib/hooks/useScreen.js +1 -2
- package/dist-lib/hooks/useScreenBack.js +17 -18
- package/dist-lib/hooks/useScreenTab.js +1 -2
- package/dist-lib/hooks/useTabNavigate.js +25 -26
- package/dist-lib/hooks/useTabSearchMirror.js +6 -7
- package/dist-lib/hooks/useTabTitle.js +10 -11
- package/dist-lib/hooks/useText.js +6 -7
- package/dist-lib/hooks/useTimelineData.js +5 -6
- package/dist-lib/hooks/useUiPreferences.js +31 -32
- package/dist-lib/hooks/useUnsavedInput.js +1 -2
- package/dist-lib/hooks/useVersionWatcher.js +16 -17
- package/dist-lib/hooks/useViews.js +16 -17
- package/dist-lib/hooks/useWindowConversation.js +1 -2
- package/dist-lib/{icon-registry-CUT4eF63.d.ts → icon-registry-BY2tt-GF.d.ts} +0 -2
- package/dist-lib/icons.d.ts +2 -4
- package/dist-lib/icons.js +5 -5
- package/dist-lib/index.d.ts +4 -272
- package/dist-lib/index.js +129 -129
- package/dist-lib/lib/action-dispatch.js +1 -2
- package/dist-lib/lib/actions.js +26 -27
- package/dist-lib/lib/anchor.js +1 -2
- package/dist-lib/lib/brand-tokens.js +1 -2
- package/dist-lib/lib/branding.js +1 -2
- package/dist-lib/lib/canonical-url.js +1 -2
- package/dist-lib/lib/capabilityPrefetch.js +1 -2
- package/dist-lib/lib/child-config.js +1 -2
- package/dist-lib/lib/children-validation.js +2 -3
- package/dist-lib/lib/date-text.js +1 -2
- package/dist-lib/lib/decimal-text.js +1 -2
- package/dist-lib/lib/display-value.js +1 -2
- package/dist-lib/lib/document-templates.js +1 -2
- package/dist-lib/lib/download.js +13 -14
- package/dist-lib/lib/evidence-verdict.js +1 -2
- package/dist-lib/lib/failure.js +4 -5
- package/dist-lib/lib/field-classification.js +1 -2
- package/dist-lib/lib/field-regions.js +1 -2
- package/dist-lib/lib/filter-evaluator.js +1 -2
- package/dist-lib/lib/filters.js +1 -2
- package/dist-lib/lib/format-count.js +1 -2
- package/dist-lib/lib/html-state.js +1 -2
- package/dist-lib/lib/language.js +1 -2
- package/dist-lib/lib/longPressGesture.js +0 -1
- package/dist-lib/lib/mass-edit.js +1 -2
- package/dist-lib/lib/money-text.js +1 -2
- package/dist-lib/lib/number-text.js +1 -2
- package/dist-lib/lib/page-inset.js +1 -2
- package/dist-lib/lib/phone.js +1 -2
- package/dist-lib/lib/profile.js +1 -2
- package/dist-lib/lib/query-retry.js +1 -2
- package/dist-lib/lib/quick-add.js +1 -2
- package/dist-lib/lib/read-display-state.js +1 -2
- package/dist-lib/lib/realtime-query-keys.js +2 -3
- package/dist-lib/lib/realtime-reconcile.js +32 -33
- package/dist-lib/lib/realtime-resync.js +40 -41
- package/dist-lib/lib/record-documents-key.js +1 -2
- package/dist-lib/lib/ref-choices.js +1 -2
- package/dist-lib/lib/refetch-when-idle.js +1 -2
- package/dist-lib/lib/rich-text.js +1 -2
- package/dist-lib/lib/role-label.js +1 -2
- package/dist-lib/lib/rowClickGesture.js +1 -2
- package/dist-lib/lib/safe-url.js +1 -2
- package/dist-lib/lib/schema-routing.js +1 -2
- package/dist-lib/lib/screen-back.js +1 -2
- package/dist-lib/lib/scroll-restoration.js +21 -22
- package/dist-lib/lib/shortcut.js +1 -2
- package/dist-lib/lib/size-value.js +1 -2
- package/dist-lib/lib/sort.js +1 -2
- package/dist-lib/lib/timestamp.js +1 -2
- package/dist-lib/lib/toast.js +1 -2
- package/dist-lib/lib/ui-actions.js +43 -44
- package/dist-lib/lib/utils.js +1 -2
- package/dist-lib/lib/variants.js +1 -2
- package/dist-lib/lib/versionTracker.js +26 -27
- package/dist-lib/lib/viewport-category.js +1 -2
- package/dist-lib/lib/window-election.js +1 -2
- package/dist-lib/stores/auth.js +32 -33
- package/dist-lib/stores/icon-registry.js +1 -2
- package/dist-lib/stores/list-layout.js +0 -1
- package/dist-lib/stores/page-state.js +1 -2
- package/dist-lib/stores/preferences.js +1 -2
- package/dist-lib/stores/realtime.js +1 -2
- package/dist-lib/stores/screen-registry.js +1 -2
- package/dist-lib/stores/tabs.js +1 -2
- package/dist-lib/test/seed-schema.js +4 -5
- package/dist-lib/testing.d.ts +2 -4
- package/dist-lib/testing.js +49 -50
- package/dist-lib/types/api.js +1 -2
- package/dist-lib/types/fieldType.js +1 -2
- package/dist-lib/types/ordmap.js +1 -2
- package/dist-lib/types/schema.js +1 -2
- package/dist-lib/{useResponsiveMode-C4MeAgoS.d.ts → useResponsiveMode-BElw02Gh.d.ts} +1 -19
- package/dist-lib/vite/index.d.ts +0 -2
- package/dist-lib/vite/index.js +1 -2
- package/package.json +11 -11
package/dist-lib/app.js
CHANGED
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
38
|
-
import {
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
import { CONSUMER_BRAND_CSS_ID as
|
|
42
|
-
import { useEffect as
|
|
43
|
-
import { QueryClient as
|
|
44
|
-
import { Fragment as
|
|
45
|
-
import { BrowserRouter as
|
|
46
|
-
import { Toaster as
|
|
47
|
-
|
|
48
|
-
var
|
|
1
|
+
import { useLanguage as e } from "./hooks/useLanguage.js";
|
|
2
|
+
import { Layout as t } from "./components/layout/Layout.js";
|
|
3
|
+
import { SignIn as n } from "./components/pages/auth/SignIn.js";
|
|
4
|
+
import { SignUp as r } from "./components/pages/auth/SignUp.js";
|
|
5
|
+
import { Forgot as i } from "./components/pages/auth/Forgot.js";
|
|
6
|
+
import { Reset as ee } from "./components/pages/auth/Reset.js";
|
|
7
|
+
import { TwoFA as a } from "./components/pages/auth/TwoFA.js";
|
|
8
|
+
import { SSOCallbackPage as te } from "./components/pages/SSOCallbackPage.js";
|
|
9
|
+
import { NotFoundPage as ne } from "./components/pages/NotFoundPage.js";
|
|
10
|
+
import { NoScreensPage as re } from "./components/pages/NoScreensPage.js";
|
|
11
|
+
import { Profile as o } from "./components/pages/profile/Profile.js";
|
|
12
|
+
import { TenantParamsPage as s } from "./components/pages/tenant-params/TenantParamsPage.js";
|
|
13
|
+
import { Preferences as c } from "./components/pages/profile/Preferences.js";
|
|
14
|
+
import { AdminCatalogPage as l } from "./components/pages/AdminCatalogPage.js";
|
|
15
|
+
import { SmartListPage as u } from "./components/pages/SmartListPage.js";
|
|
16
|
+
import { SmartDetailPage as d } from "./components/pages/SmartDetailPage.js";
|
|
17
|
+
import { SmartRecordListPage as f } from "./components/pages/SmartRecordListPage.js";
|
|
18
|
+
import { ErrorBoundary as p } from "./components/shared/ErrorBoundary.js";
|
|
19
|
+
import { useAuthStore as m } from "./stores/auth.js";
|
|
20
|
+
import { usePreferencesStore as h } from "./stores/preferences.js";
|
|
21
|
+
import { useSchema as g } from "./hooks/useSchema.js";
|
|
22
|
+
import { usePublicParams as _ } from "./hooks/useParams.js";
|
|
23
|
+
import { useBranding as ie } from "./hooks/useBranding.js";
|
|
24
|
+
import { useBrandingBreakpoints as v, useBrandingViewport as y } from "./hooks/useBrandingChrome.js";
|
|
25
|
+
import { useVersionWatcher as b } from "./hooks/useVersionWatcher.js";
|
|
26
|
+
import { ConnectionNotice as x } from "./components/shared/ConnectionNotice.js";
|
|
27
|
+
import { shouldRetryQuery as S } from "./lib/query-retry.js";
|
|
28
|
+
import { backoffDelayMs as C } from "./api/request-bounds.js";
|
|
29
|
+
import { ResponsiveModeProvider as w } from "./hooks/useResponsiveMode.js";
|
|
30
|
+
import { isValidLogoUrl as T } from "./lib/branding.js";
|
|
31
|
+
import { useFirstScreenSettledOnInput as E } from "./lib/capabilityPrefetch.js";
|
|
32
|
+
import { schemaDefaultRoute as D } from "./lib/schema-routing.js";
|
|
33
|
+
import { getRegisteredScreen as O, registerScreen as k } from "./stores/screen-registry.js";
|
|
34
|
+
import { CurrentScreenProvider as A } from "./hooks/useCurrentScreen.js";
|
|
35
|
+
import { setIconRegistry as ae } from "./stores/icon-registry.js";
|
|
36
|
+
import { applyRetainedReadGcTime as j } from "./hooks/usePageStateRuntime.js";
|
|
37
|
+
import { DEFAULT_PAGE_STATE_TTL_MS as M } from "./stores/page-state.js";
|
|
38
|
+
import { EmbedProvider as N, useEmbed as P } from "./embed/EmbedContext.js";
|
|
39
|
+
import { EmbedAuthBootstrap as F } from "./embed/EmbedAuthBootstrap.js";
|
|
40
|
+
import { BlankScreen as I } from "./components/shared/BlankScreen.js";
|
|
41
|
+
import { CONSUMER_BRAND_CSS_ID as L, applyBrandTokens as R, brandTokenCss as z } from "./lib/brand-tokens.js";
|
|
42
|
+
import { useEffect as B, useMemo as V } from "react";
|
|
43
|
+
import { QueryClient as H, QueryClientProvider as U } from "@tanstack/react-query";
|
|
44
|
+
import { Fragment as W, jsx as G, jsxs as K } from "react/jsx-runtime";
|
|
45
|
+
import { BrowserRouter as q, Navigate as J, Route as Y, Routes as oe } from "react-router";
|
|
46
|
+
import { Toaster as se } from "sonner";
|
|
47
|
+
k("Profile", o), k("TenantParameters", s);
|
|
48
|
+
var X = "declarion-managed-favicon", Z = new H({ defaultOptions: { queries: {
|
|
49
49
|
staleTime: 3e5,
|
|
50
|
-
retry:
|
|
51
|
-
retryDelay:
|
|
50
|
+
retry: S,
|
|
51
|
+
retryDelay: C
|
|
52
52
|
} } });
|
|
53
|
-
|
|
54
|
-
function
|
|
53
|
+
j(Z, M);
|
|
54
|
+
function Q(e) {
|
|
55
55
|
if (typeof window > "u") return null;
|
|
56
56
|
try {
|
|
57
57
|
let t = new URL(e, window.location.origin);
|
|
@@ -60,46 +60,46 @@ function $(e) {
|
|
|
60
60
|
return null;
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
|
-
function
|
|
64
|
-
return
|
|
63
|
+
function ce({ component: e, screenCode: t }) {
|
|
64
|
+
return E(), /* @__PURE__ */ G(e, { screenCode: t });
|
|
65
65
|
}
|
|
66
|
-
function
|
|
67
|
-
let { data: e } =
|
|
66
|
+
function le() {
|
|
67
|
+
let { data: e } = g();
|
|
68
68
|
return {
|
|
69
|
-
routes:
|
|
69
|
+
routes: V(() => {
|
|
70
70
|
if (!e) return [];
|
|
71
71
|
let t = [];
|
|
72
|
-
for (let [n,
|
|
73
|
-
let
|
|
74
|
-
if ((
|
|
75
|
-
t.push(/* @__PURE__ */
|
|
76
|
-
path:
|
|
77
|
-
element: /* @__PURE__ */
|
|
72
|
+
for (let [n, r] of Object.entries(e.screens ?? {})) if (r.type === "list") {
|
|
73
|
+
let i = r.entity;
|
|
74
|
+
if ((i ? e.entities?.[i] : void 0)?.singleton) continue;
|
|
75
|
+
t.push(/* @__PURE__ */ G(Y, {
|
|
76
|
+
path: r.route,
|
|
77
|
+
element: /* @__PURE__ */ G(p, { children: /* @__PURE__ */ G(A, {
|
|
78
78
|
code: n,
|
|
79
|
-
children: /* @__PURE__ */
|
|
79
|
+
children: /* @__PURE__ */ G(u, { screenCode: n })
|
|
80
80
|
}) })
|
|
81
81
|
}, n));
|
|
82
|
-
} else if (
|
|
83
|
-
path:
|
|
84
|
-
element: /* @__PURE__ */
|
|
82
|
+
} else if (r.type === "detail") t.push(/* @__PURE__ */ G(Y, {
|
|
83
|
+
path: r.route,
|
|
84
|
+
element: /* @__PURE__ */ G(p, { children: /* @__PURE__ */ G(A, {
|
|
85
85
|
code: n,
|
|
86
|
-
children: /* @__PURE__ */
|
|
86
|
+
children: /* @__PURE__ */ G(d, { screenCode: n })
|
|
87
87
|
}) })
|
|
88
88
|
}, n));
|
|
89
|
-
else if (
|
|
90
|
-
path:
|
|
91
|
-
element: /* @__PURE__ */
|
|
89
|
+
else if (r.type === "record_list") t.push(/* @__PURE__ */ G(Y, {
|
|
90
|
+
path: r.route,
|
|
91
|
+
element: /* @__PURE__ */ G(p, { children: /* @__PURE__ */ G(A, {
|
|
92
92
|
code: n,
|
|
93
|
-
children: /* @__PURE__ */
|
|
93
|
+
children: /* @__PURE__ */ G(f, { screenCode: n })
|
|
94
94
|
}) })
|
|
95
95
|
}, n));
|
|
96
|
-
else if (
|
|
97
|
-
let e =
|
|
98
|
-
e && t.push(/* @__PURE__ */
|
|
99
|
-
path:
|
|
100
|
-
element: /* @__PURE__ */
|
|
96
|
+
else if (r.type === "custom") {
|
|
97
|
+
let e = r.component ? O(r.component) : void 0;
|
|
98
|
+
e && t.push(/* @__PURE__ */ G(Y, {
|
|
99
|
+
path: r.route,
|
|
100
|
+
element: /* @__PURE__ */ G(p, { children: /* @__PURE__ */ G(A, {
|
|
101
101
|
code: n,
|
|
102
|
-
children: /* @__PURE__ */
|
|
102
|
+
children: /* @__PURE__ */ G(ce, {
|
|
103
103
|
component: e,
|
|
104
104
|
screenCode: n
|
|
105
105
|
})
|
|
@@ -108,133 +108,133 @@ function ce() {
|
|
|
108
108
|
}
|
|
109
109
|
return t;
|
|
110
110
|
}, [e]),
|
|
111
|
-
defaultRoute:
|
|
111
|
+
defaultRoute: V(() => D(e), [e])
|
|
112
112
|
};
|
|
113
113
|
}
|
|
114
|
-
function
|
|
115
|
-
let
|
|
116
|
-
|
|
117
|
-
document.documentElement.lang =
|
|
118
|
-
}, [
|
|
119
|
-
let
|
|
120
|
-
|
|
121
|
-
|
|
114
|
+
function $() {
|
|
115
|
+
let o = m((e) => e.initialize), s = m((e) => e.isLoading), u = m((e) => e.isAuthenticated), { data: d, isError: f } = g(), p = e(), { data: h, isLoading: v } = _(), { branding: y, isLoading: b } = ie(), { routes: x, defaultRoute: S } = le(), C = P();
|
|
116
|
+
B(() => {
|
|
117
|
+
document.documentElement.lang = p;
|
|
118
|
+
}, [p]);
|
|
119
|
+
let w = typeof window < "u" && window.self !== window.top && !C.enabled;
|
|
120
|
+
B(() => {
|
|
121
|
+
C.enabled || w || o();
|
|
122
122
|
}, [
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
123
|
+
C.enabled,
|
|
124
|
+
w,
|
|
125
|
+
o
|
|
126
126
|
]);
|
|
127
|
-
let
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
}, [
|
|
131
|
-
let
|
|
132
|
-
|
|
127
|
+
let E = d?.icons;
|
|
128
|
+
B(() => {
|
|
129
|
+
ae(E ?? {});
|
|
130
|
+
}, [E]);
|
|
131
|
+
let D = y?.identity, O = y?.theme;
|
|
132
|
+
B(() => {
|
|
133
133
|
if (typeof document > "u") return;
|
|
134
|
-
let e =
|
|
134
|
+
let e = D?.app_name?.trim();
|
|
135
135
|
e && (document.title = e);
|
|
136
|
-
}, [
|
|
136
|
+
}, [D?.app_name]), B(() => {
|
|
137
137
|
if (typeof document > "u") return;
|
|
138
|
-
let e =
|
|
138
|
+
let e = D?.app_logo, t = T(e) ? Q(e.trim()) : null, n = document.getElementById(X);
|
|
139
139
|
if (!t) n && n.remove();
|
|
140
140
|
else if (n) n.href !== t && (n.href = t);
|
|
141
141
|
else {
|
|
142
142
|
document.querySelectorAll("link[rel=\"icon\"], link[rel=\"shortcut icon\"]").forEach((e) => e.remove());
|
|
143
143
|
let e = document.createElement("link");
|
|
144
|
-
e.id =
|
|
144
|
+
e.id = X, e.rel = "icon", e.href = t, document.head.appendChild(e);
|
|
145
145
|
}
|
|
146
|
-
}, [
|
|
147
|
-
let
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
}, [
|
|
146
|
+
}, [D?.app_logo]);
|
|
147
|
+
let k = O?.css_url ?? null, A = V(() => z(O), [O]);
|
|
148
|
+
B(() => {
|
|
149
|
+
R(A);
|
|
150
|
+
}, [A]), B(() => {
|
|
151
151
|
if (typeof document > "u") return;
|
|
152
|
-
let e = document.getElementById(
|
|
153
|
-
if (!
|
|
152
|
+
let e = document.getElementById(L);
|
|
153
|
+
if (!k) {
|
|
154
154
|
e && e.remove();
|
|
155
155
|
return;
|
|
156
156
|
}
|
|
157
|
-
let t =
|
|
157
|
+
let t = Q(k);
|
|
158
158
|
if (!t) {
|
|
159
|
-
e && e.remove(), console.error(`[declarion] branding.theme.css_url rejected: ${
|
|
159
|
+
e && e.remove(), console.error(`[declarion] branding.theme.css_url rejected: ${k}. Only same-origin, relative URLs are allowed (e.g. /modules/crm/public/brand.css).`);
|
|
160
160
|
return;
|
|
161
161
|
}
|
|
162
162
|
if (e && e.href === t) return;
|
|
163
163
|
e && e.remove();
|
|
164
164
|
let n = document.createElement("link");
|
|
165
|
-
n.id =
|
|
166
|
-
}, [
|
|
167
|
-
let
|
|
168
|
-
return
|
|
169
|
-
/* @__PURE__ */
|
|
165
|
+
n.id = L, n.rel = "stylesheet", n.href = t, document.head.appendChild(n);
|
|
166
|
+
}, [k]);
|
|
167
|
+
let j = C.enabled && !u;
|
|
168
|
+
return w || j || s || v && !h || b || !d && (u || !f) ? /* @__PURE__ */ G(I, {}) : /* @__PURE__ */ K(oe, { children: [
|
|
169
|
+
/* @__PURE__ */ G(Y, {
|
|
170
170
|
path: "/login",
|
|
171
|
-
element: /* @__PURE__ */
|
|
171
|
+
element: /* @__PURE__ */ G(n, {})
|
|
172
172
|
}),
|
|
173
|
-
/* @__PURE__ */
|
|
173
|
+
/* @__PURE__ */ G(Y, {
|
|
174
174
|
path: "/login/sso-callback",
|
|
175
|
-
element: /* @__PURE__ */
|
|
175
|
+
element: /* @__PURE__ */ G(te, {})
|
|
176
176
|
}),
|
|
177
|
-
/* @__PURE__ */
|
|
177
|
+
/* @__PURE__ */ G(Y, {
|
|
178
178
|
path: "/signup",
|
|
179
|
-
element: /* @__PURE__ */
|
|
179
|
+
element: /* @__PURE__ */ G(r, {})
|
|
180
180
|
}),
|
|
181
|
-
/* @__PURE__ */
|
|
181
|
+
/* @__PURE__ */ G(Y, {
|
|
182
182
|
path: "/forgot",
|
|
183
|
-
element: /* @__PURE__ */
|
|
183
|
+
element: /* @__PURE__ */ G(i, {})
|
|
184
184
|
}),
|
|
185
|
-
/* @__PURE__ */
|
|
185
|
+
/* @__PURE__ */ G(Y, {
|
|
186
186
|
path: "/reset",
|
|
187
|
-
element: /* @__PURE__ */
|
|
187
|
+
element: /* @__PURE__ */ G(ee, {})
|
|
188
188
|
}),
|
|
189
|
-
/* @__PURE__ */
|
|
189
|
+
/* @__PURE__ */ G(Y, {
|
|
190
190
|
path: "/2fa",
|
|
191
|
-
element: /* @__PURE__ */
|
|
191
|
+
element: /* @__PURE__ */ G(a, {})
|
|
192
192
|
}),
|
|
193
|
-
/* @__PURE__ */
|
|
194
|
-
element: /* @__PURE__ */
|
|
193
|
+
/* @__PURE__ */ K(Y, {
|
|
194
|
+
element: /* @__PURE__ */ G(t, {}),
|
|
195
195
|
children: [
|
|
196
|
-
|
|
196
|
+
d && !S && /* @__PURE__ */ G(Y, {
|
|
197
197
|
index: !0,
|
|
198
|
-
element: /* @__PURE__ */
|
|
198
|
+
element: /* @__PURE__ */ G(re, {})
|
|
199
199
|
}),
|
|
200
|
-
|
|
200
|
+
S && /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G(Y, {
|
|
201
201
|
index: !0,
|
|
202
|
-
element: /* @__PURE__ */
|
|
203
|
-
to:
|
|
202
|
+
element: /* @__PURE__ */ G(J, {
|
|
203
|
+
to: S,
|
|
204
204
|
replace: !0
|
|
205
205
|
})
|
|
206
|
-
}), /* @__PURE__ */
|
|
206
|
+
}), /* @__PURE__ */ G(Y, {
|
|
207
207
|
path: "/admin",
|
|
208
|
-
element: /* @__PURE__ */
|
|
209
|
-
to:
|
|
208
|
+
element: /* @__PURE__ */ G(J, {
|
|
209
|
+
to: S,
|
|
210
210
|
replace: !0
|
|
211
211
|
})
|
|
212
212
|
})] }),
|
|
213
|
-
|
|
214
|
-
/* @__PURE__ */
|
|
213
|
+
x,
|
|
214
|
+
/* @__PURE__ */ G(Y, {
|
|
215
215
|
path: "/preferences",
|
|
216
|
-
element: /* @__PURE__ */
|
|
216
|
+
element: /* @__PURE__ */ G(c, {})
|
|
217
217
|
}),
|
|
218
|
-
/* @__PURE__ */
|
|
218
|
+
/* @__PURE__ */ G(Y, {
|
|
219
219
|
path: "/admin/catalog",
|
|
220
|
-
element: /* @__PURE__ */
|
|
220
|
+
element: /* @__PURE__ */ G(l, {})
|
|
221
221
|
}),
|
|
222
|
-
/* @__PURE__ */
|
|
222
|
+
/* @__PURE__ */ G(Y, {
|
|
223
223
|
path: "*",
|
|
224
|
-
element: /* @__PURE__ */
|
|
224
|
+
element: /* @__PURE__ */ G(ne, {})
|
|
225
225
|
})
|
|
226
226
|
]
|
|
227
227
|
})
|
|
228
228
|
] });
|
|
229
229
|
}
|
|
230
230
|
function ue() {
|
|
231
|
-
|
|
232
|
-
let e =
|
|
233
|
-
return /* @__PURE__ */ q
|
|
234
|
-
/* @__PURE__ */
|
|
235
|
-
/* @__PURE__ */
|
|
236
|
-
/* @__PURE__ */
|
|
237
|
-
/* @__PURE__ */
|
|
231
|
+
b();
|
|
232
|
+
let e = h((e) => e.toastPosition);
|
|
233
|
+
return /* @__PURE__ */ K(q, { children: [
|
|
234
|
+
/* @__PURE__ */ G(F, {}),
|
|
235
|
+
/* @__PURE__ */ G(x, {}),
|
|
236
|
+
/* @__PURE__ */ G($, {}),
|
|
237
|
+
/* @__PURE__ */ G(se, {
|
|
238
238
|
position: e,
|
|
239
239
|
toastOptions: { unstyled: !0 },
|
|
240
240
|
expand: !0,
|
|
@@ -250,18 +250,17 @@ function ue() {
|
|
|
250
250
|
] });
|
|
251
251
|
}
|
|
252
252
|
function de({ children: e }) {
|
|
253
|
-
let t =
|
|
254
|
-
return /* @__PURE__ */
|
|
253
|
+
let t = y(), n = v();
|
|
254
|
+
return /* @__PURE__ */ G(w, {
|
|
255
255
|
viewport: t,
|
|
256
256
|
breakpoints: n,
|
|
257
257
|
children: e
|
|
258
258
|
});
|
|
259
259
|
}
|
|
260
260
|
function fe() {
|
|
261
|
-
return /* @__PURE__ */
|
|
262
|
-
client:
|
|
263
|
-
children: /* @__PURE__ */
|
|
261
|
+
return /* @__PURE__ */ G(p, { children: /* @__PURE__ */ G(U, {
|
|
262
|
+
client: Z,
|
|
263
|
+
children: /* @__PURE__ */ G(N, { children: /* @__PURE__ */ G(de, { children: /* @__PURE__ */ G(ue, {}) }) })
|
|
264
264
|
}) });
|
|
265
265
|
}
|
|
266
|
-
//#endregion
|
|
267
266
|
export { fe as App };
|
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import { useTabNavigate as
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
1
|
+
import { useConditionCaller as e } from "../../hooks/useRowTenant.js";
|
|
2
|
+
import { Btn as t } from "../primitives/Btn.js";
|
|
3
|
+
import { Icon as n } from "../primitives/Icons.js";
|
|
4
|
+
import { IconBtn as r } from "../primitives/IconBtn.js";
|
|
5
|
+
import { DynamicIcon as i } from "../shared/DynamicIcon.js";
|
|
6
|
+
import { useActionRunner as a } from "./ActionRunner.js";
|
|
7
|
+
import { buildActionBody as o, executeAction as s, resolveAssociation as c } from "../../api/data.js";
|
|
8
|
+
import { evaluateConditions as l, findListScreenForEntity as u, isAssociationAction as d, rowDetailId as f } from "../../lib/actions.js";
|
|
9
|
+
import { useSchema as p } from "../../hooks/useSchema.js";
|
|
10
|
+
import { useTabNavigate as m } from "../../hooks/useTabNavigate.js";
|
|
11
|
+
import { toast as h } from "../../lib/toast.js";
|
|
12
|
+
import { executeUISteps as g, isUIAction as _ } from "../../lib/ui-actions.js";
|
|
13
|
+
import { useText as v } from "../../hooks/useText.js";
|
|
14
|
+
import { failureTitle as y } from "../../lib/failure.js";
|
|
15
15
|
import { useCallback as b, useState as x } from "react";
|
|
16
16
|
import { jsx as S } from "react/jsx-runtime";
|
|
17
|
-
|
|
17
|
+
// src/components/actions/ActionButton.tsx
|
|
18
18
|
function C({ actionCode: C, action: w, entityCode: T, objectIds: E = [], row: D, variant: O = "outline", size: k = "default", onSuccess: A }) {
|
|
19
|
-
let j =
|
|
19
|
+
let j = v(), M = v("errors"), [N, P] = x(!1), [F, I] = x(!1), { data: L } = p(), R = m(), { run: z } = a(), B = d(w), V = e(), H = !D || l(w.conditions, D, V), U = b(async () => {
|
|
20
20
|
if (w.association && E.length !== 0) {
|
|
21
21
|
P(!0);
|
|
22
22
|
try {
|
|
23
|
-
let e = T ? `${T}.${w.association}` : w.association, t = await
|
|
23
|
+
let e = T ? `${T}.${w.association}` : w.association, t = await c(e, E), n = u(L, t.target_entity);
|
|
24
24
|
if (!n) {
|
|
25
|
-
|
|
25
|
+
h.error(M("action.list_screen_missing", "No list screen is declared for this entity."), t.target_entity);
|
|
26
26
|
return;
|
|
27
27
|
}
|
|
28
|
-
let
|
|
28
|
+
let r = L?.entities[t.target_entity], i = j(w.display?.name) || t.target_entity;
|
|
29
29
|
if (t.ids.length === 0) {
|
|
30
|
-
|
|
30
|
+
h.info(j("action.association.none_related", "No related {name} found", { name: i }));
|
|
31
31
|
return;
|
|
32
32
|
}
|
|
33
|
-
let
|
|
34
|
-
|
|
35
|
-
title:
|
|
33
|
+
let a = r?.fields.names().find((e) => r.fields.get(e)?.primary) ?? "id", o = new URLSearchParams();
|
|
34
|
+
o.set(`filter_${a}`, t.ids.join(",")), R(n.route, {
|
|
35
|
+
title: i,
|
|
36
36
|
icon: w.display?.icon || n.icon,
|
|
37
|
-
search:
|
|
37
|
+
search: o.toString()
|
|
38
38
|
}), A?.();
|
|
39
39
|
} catch (e) {
|
|
40
|
-
|
|
40
|
+
h.error(y(M, e));
|
|
41
41
|
} finally {
|
|
42
42
|
P(!1);
|
|
43
43
|
}
|
|
@@ -57,7 +57,7 @@ function C({ actionCode: C, action: w, entityCode: T, objectIds: E = [], row: D,
|
|
|
57
57
|
title: j(w.display?.name) || C,
|
|
58
58
|
row: D,
|
|
59
59
|
entity: T,
|
|
60
|
-
execute: (e) =>
|
|
60
|
+
execute: (e) => s(W, o(e, G)),
|
|
61
61
|
onSuccess: () => A?.()
|
|
62
62
|
}).finally(() => I(!1));
|
|
63
63
|
}, [
|
|
@@ -71,10 +71,10 @@ function C({ actionCode: C, action: w, entityCode: T, objectIds: E = [], row: D,
|
|
|
71
71
|
G,
|
|
72
72
|
A
|
|
73
73
|
]), q = b(() => {
|
|
74
|
-
if (
|
|
74
|
+
if (_(w)) g(M, w.ui_steps, { row: D }).then(() => A?.());
|
|
75
75
|
else if (B) U();
|
|
76
76
|
else if (w.href && !w.handler && !w.association) {
|
|
77
|
-
let e = T ? L?.entities[T] : void 0, t =
|
|
77
|
+
let e = T ? L?.entities[T] : void 0, t = f(D, e), n = w.href;
|
|
78
78
|
T && (n = n.replaceAll("${entity}", T)), t && (n = n.replaceAll("${id}", encodeURIComponent(t))), R(n, {
|
|
79
79
|
title: j(w.display?.name) || C,
|
|
80
80
|
icon: w.display?.icon
|
|
@@ -93,15 +93,15 @@ function C({ actionCode: C, action: w, entityCode: T, objectIds: E = [], row: D,
|
|
|
93
93
|
U,
|
|
94
94
|
K,
|
|
95
95
|
A
|
|
96
|
-
]), J = j(w.display?.name), Y = w.display?.icon, X = Y &&
|
|
96
|
+
]), J = j(w.display?.name), Y = w.display?.icon, X = Y && n[Y], Z = X ? /* @__PURE__ */ S(X, { size: 13 }) : Y ? /* @__PURE__ */ S(i, {
|
|
97
97
|
name: Y,
|
|
98
98
|
size: 13
|
|
99
99
|
}) : null, Q = !H || F || N;
|
|
100
|
-
return k === "icon" ? /* @__PURE__ */ S(
|
|
101
|
-
icon: Z ?? /* @__PURE__ */ S(
|
|
100
|
+
return k === "icon" ? /* @__PURE__ */ S(r, {
|
|
101
|
+
icon: Z ?? /* @__PURE__ */ S(n.bolt, { size: 13 }),
|
|
102
102
|
onClick: q,
|
|
103
103
|
title: J
|
|
104
|
-
}) : /* @__PURE__ */ S(
|
|
104
|
+
}) : /* @__PURE__ */ S(t, {
|
|
105
105
|
kind: O === "default" ? "primary" : O === "ghost" ? "ghost" : "default",
|
|
106
106
|
size: "sm",
|
|
107
107
|
icon: Z,
|
|
@@ -113,5 +113,4 @@ function C({ actionCode: C, action: w, entityCode: T, objectIds: E = [], row: D,
|
|
|
113
113
|
children: J
|
|
114
114
|
});
|
|
115
115
|
}
|
|
116
|
-
//#endregion
|
|
117
116
|
export { C as ActionButton };
|