@declarion/react 0.65.1 → 0.66.1
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,48 @@
|
|
|
1
|
+
import { useText as e } from "../../hooks/useText.js";
|
|
2
|
+
import { SectionCard as t } from "../primitives/SectionCard.js";
|
|
3
|
+
import { DynamicIcon as n } from "../shared/DynamicIcon.js";
|
|
4
|
+
import { schemaFieldHasValue as r } from "../file-widgets/host.js";
|
|
5
|
+
import { LayoutRenderer as i } from "./LayoutRenderer.js";
|
|
6
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
7
|
+
//#region src/components/detail-layout/SectionBlock.tsx
|
|
8
|
+
function o({ config: r, ctx: o }) {
|
|
9
|
+
let c = e(), { name: l, items: u, collapsed: d = !1, columns: f, icon: p, badge: m, emphasis: h } = r, g = r.hide_empty_fields === !0 && o.mode === "display";
|
|
10
|
+
if (g && !s(u, o)) return null;
|
|
11
|
+
let _ = {
|
|
12
|
+
...o,
|
|
13
|
+
withinCard: !0,
|
|
14
|
+
...f ? { columns: f } : null,
|
|
15
|
+
...g ? { hideEmptyFields: g } : null
|
|
16
|
+
}, v = p ? /* @__PURE__ */ a(n, {
|
|
17
|
+
name: p,
|
|
18
|
+
size: 14
|
|
19
|
+
}) : void 0, y = m ? {
|
|
20
|
+
text: c(m.text),
|
|
21
|
+
tone: m.tone,
|
|
22
|
+
dot: m.dot
|
|
23
|
+
} : void 0;
|
|
24
|
+
return /* @__PURE__ */ a(t, {
|
|
25
|
+
title: c(l),
|
|
26
|
+
defaultOpen: !d,
|
|
27
|
+
icon: v,
|
|
28
|
+
badge: y,
|
|
29
|
+
emphasis: h,
|
|
30
|
+
headingLevel: o.withinCard ? 3 : 2,
|
|
31
|
+
children: /* @__PURE__ */ a("div", {
|
|
32
|
+
style: {
|
|
33
|
+
display: "flex",
|
|
34
|
+
flexDirection: "column",
|
|
35
|
+
gap: 12
|
|
36
|
+
},
|
|
37
|
+
children: /* @__PURE__ */ a(i, {
|
|
38
|
+
nodes: u,
|
|
39
|
+
ctx: _
|
|
40
|
+
})
|
|
41
|
+
})
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
function s(e, t) {
|
|
45
|
+
return e.some((e) => !e.fields || e.fields.some((e) => r(t.entity, t.record, e.code)));
|
|
46
|
+
}
|
|
47
|
+
//#endregion
|
|
48
|
+
export { o as SectionBlock };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { StatusGroupsDisplay as e } from "../shared/StatusGroupsDisplay.js";
|
|
2
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
3
|
+
//#region src/components/detail-layout/StatusesBlock.tsx
|
|
4
|
+
var n = () => {};
|
|
5
|
+
function r({ node: r, ctx: i }) {
|
|
6
|
+
let { entity: a, objectStatuses: o, onSetStatus: s, isStatusPending: c, isNew: l } = i, u = a.status_groups ?? {};
|
|
7
|
+
if (l) return null;
|
|
8
|
+
let d = r.statuses === !0 || r.statuses, f = Object.fromEntries(Object.entries(u).filter(([e]) => d === !0 || d.includes(e)));
|
|
9
|
+
return Object.keys(f).length === 0 ? null : /* @__PURE__ */ t(e, {
|
|
10
|
+
statusGroups: f,
|
|
11
|
+
objectStatuses: o,
|
|
12
|
+
onSetStatus: s ?? n,
|
|
13
|
+
isPending: c ?? !1,
|
|
14
|
+
mode: i.mode
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
//#endregion
|
|
18
|
+
export { r as StatusesBlock };
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
import { textWithNodes as e } from "../../lib/language.js";
|
|
2
|
+
import { Icon as t } from "../primitives/Icons.js";
|
|
3
|
+
import { Btn as n } from "../primitives/Btn.js";
|
|
4
|
+
import { useText as r } from "../../hooks/useText.js";
|
|
5
|
+
import { failureTitle as i } from "../../lib/failure.js";
|
|
6
|
+
import { renderField as a } from "../fields/index.js";
|
|
7
|
+
import { registerFieldRegion as o } from "../../lib/field-regions.js";
|
|
8
|
+
import { useQuickAdd as s } from "./useQuickAdd.js";
|
|
9
|
+
import { useCallback as c, useEffect as l, useMemo as u, useRef as d, useState as f } from "react";
|
|
10
|
+
import { Fragment as p, jsx as m, jsxs as h } from "react/jsx-runtime";
|
|
11
|
+
//#region src/components/detail-layout/TimelineComposer.tsx
|
|
12
|
+
var g = "quick_entry", _ = 100, v = 240, y = 800, b = 80;
|
|
13
|
+
function x({ config: x, parentEntity: S, parentId: C, schema: w }) {
|
|
14
|
+
let { values: T, quickAdd: E, childEntity: D, isPending: O, error: k, isReady: A, handleSubmit: j, handleFieldChange: M } = s(x, S, C, w), N = r(), P = r("errors"), [F, I] = f(v), L = d(null), R = d(null), [z, B] = f(y);
|
|
15
|
+
l(() => {
|
|
16
|
+
let e = R.current?.parentElement;
|
|
17
|
+
if (!e) return;
|
|
18
|
+
let t = () => {
|
|
19
|
+
let t = Math.max(_, e.clientHeight - b);
|
|
20
|
+
B(Math.min(y, t));
|
|
21
|
+
};
|
|
22
|
+
t();
|
|
23
|
+
let n = new ResizeObserver(t);
|
|
24
|
+
return n.observe(e), () => n.disconnect();
|
|
25
|
+
}, []), l(() => {
|
|
26
|
+
I((e) => Math.min(e, z));
|
|
27
|
+
}, [z]);
|
|
28
|
+
let V = d(T);
|
|
29
|
+
V.current = T;
|
|
30
|
+
let H = d(M);
|
|
31
|
+
H.current = M;
|
|
32
|
+
let U = d({}), W = u(() => ({
|
|
33
|
+
getField: (e) => V.current[e],
|
|
34
|
+
setField: (e, t) => {
|
|
35
|
+
H.current(e, t);
|
|
36
|
+
},
|
|
37
|
+
focusField: (e) => {
|
|
38
|
+
let t = U.current[e];
|
|
39
|
+
t && (t.querySelector("textarea, input, select, [contenteditable]") ?? t).focus();
|
|
40
|
+
}
|
|
41
|
+
}), []);
|
|
42
|
+
l(() => o(g, W), [W]);
|
|
43
|
+
let G = c((e) => {
|
|
44
|
+
e.preventDefault(), L.current = {
|
|
45
|
+
startY: e.clientY,
|
|
46
|
+
startHeight: F
|
|
47
|
+
};
|
|
48
|
+
let t = (e) => {
|
|
49
|
+
if (!L.current) return;
|
|
50
|
+
let t = L.current.startY - e.clientY, n = Math.min(z, Math.max(_, L.current.startHeight + t));
|
|
51
|
+
I(n);
|
|
52
|
+
}, n = () => {
|
|
53
|
+
L.current = null, document.removeEventListener("mousemove", t), document.removeEventListener("mouseup", n);
|
|
54
|
+
};
|
|
55
|
+
document.addEventListener("mousemove", t), document.addEventListener("mouseup", n);
|
|
56
|
+
}, [F, z]);
|
|
57
|
+
if (!E || E.fields.length === 0 || !D) return null;
|
|
58
|
+
let K = E.fields.find((e) => {
|
|
59
|
+
let t = D.fields.get(e);
|
|
60
|
+
return t && (t.type === "text" || t.type === "string");
|
|
61
|
+
}), q = [], J = [];
|
|
62
|
+
for (let e of E.fields) {
|
|
63
|
+
if (e === K) continue;
|
|
64
|
+
let t = D.fields.get(e);
|
|
65
|
+
t && (t.type === "enum" ? q.push(e) : J.push(e));
|
|
66
|
+
}
|
|
67
|
+
let Y = (e) => {
|
|
68
|
+
let t = D.fields.get(e);
|
|
69
|
+
return t ? /* @__PURE__ */ m("div", {
|
|
70
|
+
ref: (t) => {
|
|
71
|
+
U.current[e] = t;
|
|
72
|
+
},
|
|
73
|
+
children: a({
|
|
74
|
+
field: t,
|
|
75
|
+
fieldName: e,
|
|
76
|
+
value: T[e] ?? "",
|
|
77
|
+
mode: "edit",
|
|
78
|
+
onChange: (t) => M(e, t),
|
|
79
|
+
record: T,
|
|
80
|
+
t: N
|
|
81
|
+
})
|
|
82
|
+
}, e) : null;
|
|
83
|
+
};
|
|
84
|
+
return /* @__PURE__ */ h("div", {
|
|
85
|
+
ref: R,
|
|
86
|
+
style: {
|
|
87
|
+
flexShrink: 0,
|
|
88
|
+
borderTop: "1px solid var(--divider)",
|
|
89
|
+
background: "var(--surface)",
|
|
90
|
+
display: "flex",
|
|
91
|
+
flexDirection: "column",
|
|
92
|
+
height: `${F}px`
|
|
93
|
+
},
|
|
94
|
+
children: [/* @__PURE__ */ m("div", {
|
|
95
|
+
onMouseDown: G,
|
|
96
|
+
title: N("record.layout.drag_to_resize", "Drag to resize"),
|
|
97
|
+
style: {
|
|
98
|
+
height: 12,
|
|
99
|
+
cursor: "row-resize",
|
|
100
|
+
display: "flex",
|
|
101
|
+
alignItems: "center",
|
|
102
|
+
justifyContent: "center",
|
|
103
|
+
flexShrink: 0
|
|
104
|
+
},
|
|
105
|
+
children: /* @__PURE__ */ m("div", { style: {
|
|
106
|
+
width: 56,
|
|
107
|
+
height: 3,
|
|
108
|
+
borderRadius: 999,
|
|
109
|
+
background: "var(--border)"
|
|
110
|
+
} })
|
|
111
|
+
}), /* @__PURE__ */ h("form", {
|
|
112
|
+
onSubmit: j,
|
|
113
|
+
onKeyDown: (e) => {
|
|
114
|
+
(e.metaKey || e.ctrlKey) && e.key === "Enter" && (e.preventDefault(), e.currentTarget.requestSubmit());
|
|
115
|
+
},
|
|
116
|
+
style: {
|
|
117
|
+
flex: 1,
|
|
118
|
+
minHeight: 0,
|
|
119
|
+
display: "flex",
|
|
120
|
+
flexDirection: "column",
|
|
121
|
+
gap: 6,
|
|
122
|
+
padding: "0 12px 8px"
|
|
123
|
+
},
|
|
124
|
+
children: [
|
|
125
|
+
q.length > 0 && /* @__PURE__ */ m("div", {
|
|
126
|
+
style: {
|
|
127
|
+
display: "flex",
|
|
128
|
+
flexWrap: "wrap",
|
|
129
|
+
alignItems: "center",
|
|
130
|
+
gap: 6,
|
|
131
|
+
flexShrink: 0
|
|
132
|
+
},
|
|
133
|
+
children: q.map(Y)
|
|
134
|
+
}),
|
|
135
|
+
K && D.fields.get(K) && /* @__PURE__ */ m("div", {
|
|
136
|
+
style: {
|
|
137
|
+
flex: 1,
|
|
138
|
+
minHeight: 0,
|
|
139
|
+
display: "flex"
|
|
140
|
+
},
|
|
141
|
+
ref: (e) => {
|
|
142
|
+
U.current[K] = e;
|
|
143
|
+
},
|
|
144
|
+
children: a({
|
|
145
|
+
field: D.fields.get(K),
|
|
146
|
+
fieldName: K,
|
|
147
|
+
value: T[K] ?? "",
|
|
148
|
+
mode: "edit",
|
|
149
|
+
onChange: (e) => M(K, e),
|
|
150
|
+
record: T,
|
|
151
|
+
fill: !0,
|
|
152
|
+
t: N
|
|
153
|
+
})
|
|
154
|
+
}),
|
|
155
|
+
/* @__PURE__ */ h("div", {
|
|
156
|
+
style: {
|
|
157
|
+
display: "flex",
|
|
158
|
+
flexWrap: "wrap",
|
|
159
|
+
alignItems: "center",
|
|
160
|
+
gap: 6,
|
|
161
|
+
flexShrink: 0
|
|
162
|
+
},
|
|
163
|
+
children: [J.map(Y), /* @__PURE__ */ h("div", {
|
|
164
|
+
style: {
|
|
165
|
+
marginLeft: "auto",
|
|
166
|
+
display: "flex",
|
|
167
|
+
alignItems: "center",
|
|
168
|
+
gap: 8
|
|
169
|
+
},
|
|
170
|
+
children: [/* @__PURE__ */ m("span", {
|
|
171
|
+
style: {
|
|
172
|
+
fontSize: 10.5,
|
|
173
|
+
color: "var(--text-4)"
|
|
174
|
+
},
|
|
175
|
+
children: e(N("record.related.shortcut_to_add", "{keys} to add"), { keys: /* @__PURE__ */ h(p, { children: [/* @__PURE__ */ m("span", {
|
|
176
|
+
className: "mono",
|
|
177
|
+
children: "⌘"
|
|
178
|
+
}), /* @__PURE__ */ m("span", {
|
|
179
|
+
className: "mono",
|
|
180
|
+
children: "↵"
|
|
181
|
+
})] }) })
|
|
182
|
+
}), /* @__PURE__ */ m(n, {
|
|
183
|
+
type: "submit",
|
|
184
|
+
kind: "primary",
|
|
185
|
+
icon: /* @__PURE__ */ m(t.plus, { size: 13 }),
|
|
186
|
+
disabled: O || !A,
|
|
187
|
+
children: N("record.related.add", "Add")
|
|
188
|
+
})]
|
|
189
|
+
})]
|
|
190
|
+
}),
|
|
191
|
+
k != null && /* @__PURE__ */ m("p", {
|
|
192
|
+
style: {
|
|
193
|
+
fontSize: 11,
|
|
194
|
+
color: "var(--danger)",
|
|
195
|
+
margin: 0,
|
|
196
|
+
flexShrink: 0
|
|
197
|
+
},
|
|
198
|
+
children: i(P, k)
|
|
199
|
+
})
|
|
200
|
+
]
|
|
201
|
+
})]
|
|
202
|
+
});
|
|
203
|
+
}
|
|
204
|
+
//#endregion
|
|
205
|
+
export { x as TimelineComposer };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
//#region src/components/detail-layout/blockMeta.ts
|
|
2
|
+
function e(e) {
|
|
3
|
+
return e.children ?? e.associated;
|
|
4
|
+
}
|
|
5
|
+
function t(t, n, r) {
|
|
6
|
+
let i = e(t);
|
|
7
|
+
if (i) {
|
|
8
|
+
if (t.label) return r(t.label);
|
|
9
|
+
let e = n.entity.children?.find((e) => e.entity === i);
|
|
10
|
+
if (e?.display?.name) return r(e.display.name);
|
|
11
|
+
let a = n.schema.entities[i];
|
|
12
|
+
return a && (r(a.display.name_plural) || r(a.display.name)) || i;
|
|
13
|
+
}
|
|
14
|
+
return t.section ? r(t.section.name) : r("record.tabs.fallback", "Tab");
|
|
15
|
+
}
|
|
16
|
+
function n(t, n) {
|
|
17
|
+
if (t.icon) return t.icon;
|
|
18
|
+
let r = e(t);
|
|
19
|
+
if (r) {
|
|
20
|
+
let e = n.entity.children?.find((e) => e.entity === r);
|
|
21
|
+
if (e?.display?.icon) return e.display.icon;
|
|
22
|
+
let t = n.schema.entities[r];
|
|
23
|
+
if (t) return t.display.icon;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
//#endregion
|
|
27
|
+
export { n as resolveBlockIcon, t as resolveBlockLabel };
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { MAX_COL_WIDTH as e, useListLayout as t } from "../../stores/list-layout.js";
|
|
2
|
+
import { useCallback as n, useEffect as r, useRef as i, useState as a } from "react";
|
|
3
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
4
|
+
//#region src/components/detail-layout/useManualColumnResize.tsx
|
|
5
|
+
function s(e, t, n) {
|
|
6
|
+
return `${e}::child::${t}.${n}`;
|
|
7
|
+
}
|
|
8
|
+
function c(t) {
|
|
9
|
+
return Math.min(e, Math.max(60, Math.round(t)));
|
|
10
|
+
}
|
|
11
|
+
function l(e) {
|
|
12
|
+
let { widths: o, setWidths: s, resetWidths: l } = t(e), [u, d] = a({}), f = i(null);
|
|
13
|
+
r(() => {
|
|
14
|
+
let e = (e) => {
|
|
15
|
+
let t = f.current;
|
|
16
|
+
if (!t) return;
|
|
17
|
+
let n = c(t.startWidth + (e.clientX - t.startX));
|
|
18
|
+
t.current = n, d({ [t.colId]: n });
|
|
19
|
+
}, t = () => {
|
|
20
|
+
let e = f.current;
|
|
21
|
+
e && (f.current = null, s({ [e.colId]: e.current }), d({}));
|
|
22
|
+
};
|
|
23
|
+
return window.addEventListener("mousemove", e), window.addEventListener("mouseup", t), () => {
|
|
24
|
+
window.removeEventListener("mousemove", e), window.removeEventListener("mouseup", t);
|
|
25
|
+
};
|
|
26
|
+
}, [s]);
|
|
27
|
+
let p = n((e, t) => {
|
|
28
|
+
t.preventDefault(), t.stopPropagation();
|
|
29
|
+
let n = t.currentTarget.closest("th")?.getBoundingClientRect().width, r = o[e] ?? (n && n > 0 ? n : 150);
|
|
30
|
+
f.current = {
|
|
31
|
+
colId: e,
|
|
32
|
+
startX: t.clientX,
|
|
33
|
+
startWidth: Math.round(r),
|
|
34
|
+
current: Math.round(r)
|
|
35
|
+
};
|
|
36
|
+
}, [o]);
|
|
37
|
+
return {
|
|
38
|
+
headerStyle: n((e, t) => {
|
|
39
|
+
let n = u[e] ?? o[e];
|
|
40
|
+
return n == null ? {
|
|
41
|
+
...t,
|
|
42
|
+
position: "relative"
|
|
43
|
+
} : {
|
|
44
|
+
...t,
|
|
45
|
+
position: "relative",
|
|
46
|
+
width: n,
|
|
47
|
+
minWidth: n,
|
|
48
|
+
maxWidth: n
|
|
49
|
+
};
|
|
50
|
+
}, [u, o]),
|
|
51
|
+
cellStyle: n((e, t) => {
|
|
52
|
+
let n = u[e] ?? o[e];
|
|
53
|
+
return n == null ? t : {
|
|
54
|
+
...t,
|
|
55
|
+
width: n,
|
|
56
|
+
maxWidth: n,
|
|
57
|
+
overflow: "hidden",
|
|
58
|
+
textOverflow: "ellipsis",
|
|
59
|
+
whiteSpace: "nowrap"
|
|
60
|
+
};
|
|
61
|
+
}, [u, o]),
|
|
62
|
+
onHandleMouseDown: p,
|
|
63
|
+
hasWidths: Object.keys(o).length > 0,
|
|
64
|
+
resetWidths: l
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
function u({ colId: e, onMouseDown: t }) {
|
|
68
|
+
return /* @__PURE__ */ o("span", {
|
|
69
|
+
"data-testid": "col-resize-handle",
|
|
70
|
+
"aria-hidden": "true",
|
|
71
|
+
onMouseDown: (n) => t(e, n),
|
|
72
|
+
onClick: (e) => e.stopPropagation(),
|
|
73
|
+
style: {
|
|
74
|
+
position: "absolute",
|
|
75
|
+
top: 0,
|
|
76
|
+
right: 0,
|
|
77
|
+
height: "100%",
|
|
78
|
+
width: 9,
|
|
79
|
+
display: "flex",
|
|
80
|
+
justifyContent: "center",
|
|
81
|
+
cursor: "col-resize",
|
|
82
|
+
userSelect: "none"
|
|
83
|
+
},
|
|
84
|
+
children: /* @__PURE__ */ o("span", { style: {
|
|
85
|
+
width: 2,
|
|
86
|
+
height: "55%",
|
|
87
|
+
alignSelf: "center",
|
|
88
|
+
background: "var(--border)",
|
|
89
|
+
borderRadius: "var(--radius-xs)"
|
|
90
|
+
} })
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
//#endregion
|
|
94
|
+
export { u as ManualResizeHandle, s as childLayoutKey, l as useManualColumnResize };
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { formatWireDateTime as e } from "../../lib/timestamp.js";
|
|
2
|
+
import { pkValuePartsToId as t } from "../../types/schema.js";
|
|
3
|
+
import { createEntity as n } from "../../api/data.js";
|
|
4
|
+
import { ENTITY_CHILDREN_KEY as r } from "../../hooks/useChildrenData.js";
|
|
5
|
+
import { buildQuickAddPayload as i, isQuickAddReady as a } from "../../lib/quick-add.js";
|
|
6
|
+
import { useState as o } from "react";
|
|
7
|
+
import { useMutation as s, useQueryClient as c } from "@tanstack/react-query";
|
|
8
|
+
//#region src/components/detail-layout/useQuickAdd.ts
|
|
9
|
+
function l(l, u, d, f) {
|
|
10
|
+
let [p, m] = o(() => {
|
|
11
|
+
let t = l.quick_add, n = f.entities[l.entity], r = {};
|
|
12
|
+
if (t?.fields) for (let i of t.fields) t.defaults?.[i] == null ? n?.fields.get(i)?.type === "timestamp" && (r[i] = e()) : r[i] = t.defaults[i];
|
|
13
|
+
return r;
|
|
14
|
+
}), h = c(), { mutate: g, isPending: _, error: v, reset: y } = s({
|
|
15
|
+
mutationFn: (e) => n(l.entity, e),
|
|
16
|
+
onMutate: async (e) => {
|
|
17
|
+
let n = Array.isArray(d) ? t(d.map(String)) : d, i = [
|
|
18
|
+
r,
|
|
19
|
+
u,
|
|
20
|
+
n,
|
|
21
|
+
l.entity
|
|
22
|
+
];
|
|
23
|
+
await h.cancelQueries({ queryKey: i });
|
|
24
|
+
let a = h.getQueriesData({ queryKey: i }), o = {
|
|
25
|
+
...e,
|
|
26
|
+
id: `__optimistic_${crypto.randomUUID()}`,
|
|
27
|
+
__optimistic: !0
|
|
28
|
+
};
|
|
29
|
+
return h.setQueriesData({ queryKey: i }, (e) => {
|
|
30
|
+
if (!e || typeof e != "object") return e;
|
|
31
|
+
if ("pages" in e && Array.isArray(e.pages) && e.pages.length > 0) {
|
|
32
|
+
let t = e, [n, ...r] = t.pages;
|
|
33
|
+
return {
|
|
34
|
+
...t,
|
|
35
|
+
pages: [{
|
|
36
|
+
...n,
|
|
37
|
+
data: [o, ...n.data]
|
|
38
|
+
}, ...r]
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
return e;
|
|
42
|
+
}), { snapshots: a };
|
|
43
|
+
},
|
|
44
|
+
onError: (e, t, n) => {
|
|
45
|
+
if (n?.snapshots) for (let [e, t] of n.snapshots) h.setQueryData(e, t);
|
|
46
|
+
},
|
|
47
|
+
onSuccess: () => {
|
|
48
|
+
let t = l.quick_add, n = f.entities[l.entity], r = {};
|
|
49
|
+
if (t?.fields) for (let i of t.fields) r[i] = t?.defaults?.[i] == null ? n?.fields.get(i)?.type === "timestamp" ? e() : "" : t.defaults[i];
|
|
50
|
+
m(r);
|
|
51
|
+
},
|
|
52
|
+
onSettled: () => {
|
|
53
|
+
let e = Array.isArray(d) ? t(d.map(String)) : d;
|
|
54
|
+
h.invalidateQueries({ queryKey: [
|
|
55
|
+
r,
|
|
56
|
+
u,
|
|
57
|
+
e,
|
|
58
|
+
l.entity
|
|
59
|
+
] });
|
|
60
|
+
}
|
|
61
|
+
}), b = l.quick_add, x = f.entities[l.entity], S = b?.fields.filter((e) => x?.fields.get(e)?.required && !x?.fields.get(e)?.generate) ?? [], C = a(p, S);
|
|
62
|
+
function w(e) {
|
|
63
|
+
if (e.preventDefault(), !b) return;
|
|
64
|
+
let t = i(p, b.defaults, l.foreign_key, d);
|
|
65
|
+
g(t);
|
|
66
|
+
}
|
|
67
|
+
function T(e, t) {
|
|
68
|
+
v && y(), m((n) => ({
|
|
69
|
+
...n,
|
|
70
|
+
[e]: t
|
|
71
|
+
}));
|
|
72
|
+
}
|
|
73
|
+
return {
|
|
74
|
+
values: p,
|
|
75
|
+
quickAdd: b,
|
|
76
|
+
childEntity: x,
|
|
77
|
+
isPending: _,
|
|
78
|
+
error: v,
|
|
79
|
+
isReady: C,
|
|
80
|
+
handleSubmit: w,
|
|
81
|
+
handleFieldChange: T
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
//#endregion
|
|
85
|
+
export { l as useQuickAdd };
|