@declarion/react 0.65.0 → 0.66.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-lib/api/access-expiry.js +32 -0
- package/dist-lib/api/agents.js +105 -0
- package/dist-lib/api/auth-redirect.js +30 -0
- package/dist-lib/api/auth.js +67 -0
- package/dist-lib/api/batch.js +34 -0
- package/dist-lib/api/client.js +241 -0
- package/dist-lib/api/data.js +122 -0
- package/dist-lib/api/entities.js +160 -0
- package/dist-lib/api/events.js +120 -0
- package/dist-lib/api/fileReferences.js +8 -0
- package/dist-lib/api/params.js +20 -0
- package/dist-lib/api/properties.js +25 -0
- package/dist-lib/api/request-bounds.js +28 -0
- package/dist-lib/api/schema.js +71 -0
- package/dist-lib/api/session-renewal.js +36 -0
- package/dist-lib/api/status.js +17 -0
- package/dist-lib/app.js +262 -0
- package/dist-lib/components/actions/ActionButton.js +116 -0
- package/dist-lib/{ActionDialog-C6EG-AmC.js → components/actions/ActionDialog.js} +63 -53
- package/dist-lib/{ActionResultDialog.impl-BATutW8J.js → components/actions/ActionResultDialog.impl.js} +53 -48
- package/dist-lib/components/actions/ActionResultDialog.js +12 -0
- package/dist-lib/components/actions/ActionRunner.js +274 -0
- package/dist-lib/components/actions/ObjectActionBar.js +127 -0
- package/dist-lib/components/actions/PropertyGridEditor.js +202 -0
- package/dist-lib/components/actions/ResponsiveActionBar.js +773 -0
- package/dist-lib/components/actions/RowActionsKebab.js +90 -0
- package/dist-lib/{AgentChatPanel.impl-D5y_qEex.js → components/agents/AgentChatPanel.impl.js} +314 -362
- package/dist-lib/components/agents/AgentChatPanel.js +12 -0
- package/dist-lib/components/agents/AgentConversationDrawer.js +59 -0
- package/dist-lib/components/agents/AgentElicitForm.js +152 -0
- package/dist-lib/components/agents/AgentOpenFollower.impl.js +7 -0
- package/dist-lib/components/agents/AgentOpenFollower.js +12 -0
- package/dist-lib/components/agents/AgentPicker.js +58 -0
- package/dist-lib/components/agents/transcript-runs.js +52 -0
- package/dist-lib/components/chrome/AssociationTabs.js +176 -0
- package/dist-lib/components/chrome/AuditMetaStrip.js +64 -0
- package/dist-lib/components/chrome/Breadcrumbs.js +67 -0
- package/dist-lib/components/chrome/HighlightsStrip.js +39 -0
- package/dist-lib/{PageHeader-DiwLe7CO.js → components/chrome/PageHeader.js} +19 -15
- package/dist-lib/{PageShell-BJz1MiTH.js → components/chrome/PageShell.js} +3 -3
- package/dist-lib/components/chrome/RecordHeader.js +119 -0
- package/dist-lib/{headerActionZone-bef-tZZ7.js → components/chrome/headerActionZone.js} +1 -1
- package/dist-lib/components/detail-layout/AssociatedBlock.js +1244 -0
- package/dist-lib/components/detail-layout/AssociatedToolbar.js +87 -0
- package/dist-lib/components/detail-layout/ChildrenBlock.js +80 -0
- package/dist-lib/components/detail-layout/ChildrenCards.js +156 -0
- package/dist-lib/components/detail-layout/ChildrenList.js +135 -0
- package/dist-lib/components/detail-layout/ChildrenTable.js +189 -0
- package/dist-lib/components/detail-layout/ChildrenTimeline.js +609 -0
- package/dist-lib/components/detail-layout/DetailAuditStrip.js +40 -0
- package/dist-lib/components/detail-layout/DetailHighlights.js +54 -0
- package/dist-lib/{DraggableChildrenTable-Dd5SeuF6.js → components/detail-layout/DraggableChildrenTable.js} +56 -53
- package/dist-lib/components/detail-layout/EditableChildrenTable.js +341 -0
- package/dist-lib/components/detail-layout/ErrorSummary.js +89 -0
- package/dist-lib/components/detail-layout/EvidenceBlock.js +66 -0
- package/dist-lib/{FieldRow-DedGIY9R.js → components/detail-layout/FieldRow.js} +8 -7
- package/dist-lib/components/detail-layout/FieldsBlock.js +74 -0
- package/dist-lib/components/detail-layout/LayoutColumn.js +16 -0
- package/dist-lib/components/detail-layout/LayoutRenderer.js +54 -0
- package/dist-lib/components/detail-layout/LayoutRow.js +83 -0
- package/dist-lib/components/detail-layout/LayoutTabs.js +195 -0
- package/dist-lib/components/detail-layout/PropertiesBlock.js +74 -0
- package/dist-lib/components/detail-layout/QuickAddForm.js +81 -0
- package/dist-lib/components/detail-layout/SectionBlock.js +48 -0
- package/dist-lib/components/detail-layout/StatusesBlock.js +18 -0
- package/dist-lib/components/detail-layout/TimelineComposer.js +205 -0
- package/dist-lib/components/detail-layout/blockMeta.js +27 -0
- package/dist-lib/components/detail-layout/useManualColumnResize.js +94 -0
- package/dist-lib/components/detail-layout/useQuickAdd.js +85 -0
- package/dist-lib/components/detail-layout/widgets/EntityScorecardWidget.js +295 -0
- package/dist-lib/components/detail-layout/widgets/JsonDiffWidget.js +107 -0
- package/dist-lib/components/detail-layout/widgets/MonacoJson.js +47 -0
- package/dist-lib/components/detail-layout/widgets/WidgetHost.js +36 -0
- package/dist-lib/components/detail-layout/widgets/builtins.js +10 -0
- package/dist-lib/components/detail-layout/widgets/canonicalizeJson.js +32 -0
- package/dist-lib/components/detail-layout/widgets/monacoBootstrap.js +16 -0
- package/dist-lib/components/detail-layout/widgets/registry.js +13 -0
- package/dist-lib/components/fields/BoolField.js +13 -0
- package/dist-lib/components/fields/EmailField.js +16 -0
- package/dist-lib/components/fields/EnumField.js +38 -0
- package/dist-lib/components/fields/FileReferenceField.js +60 -0
- package/dist-lib/components/fields/IntArrayField.js +83 -0
- package/dist-lib/components/fields/JsonField.js +51 -0
- package/dist-lib/components/fields/MultilangArrayField.js +56 -0
- package/dist-lib/components/fields/MultilangField.js +65 -0
- package/dist-lib/components/fields/MultilangTextField.js +65 -0
- package/dist-lib/components/fields/NumberField.js +64 -0
- package/dist-lib/components/fields/PasswordField.js +34 -0
- package/dist-lib/components/fields/PhoneField.js +84 -0
- package/dist-lib/components/fields/RefCombobox.js +112 -0
- package/dist-lib/components/fields/RefField.js +45 -0
- package/dist-lib/components/fields/RichTextField.js +225 -0
- package/dist-lib/components/fields/SecretField.js +34 -0
- package/dist-lib/components/fields/StringArrayField.js +165 -0
- package/dist-lib/components/fields/StringField.js +39 -0
- package/dist-lib/components/fields/StructureField.js +221 -0
- package/dist-lib/components/fields/TextField.js +76 -0
- package/dist-lib/components/fields/TimestampField.js +110 -0
- package/dist-lib/components/fields/UrlField.js +18 -0
- package/dist-lib/components/fields/cells/factories/badge.js +42 -0
- package/dist-lib/components/fields/cells/factories/boolPill.js +17 -0
- package/dist-lib/components/fields/cells/factories/code.js +11 -0
- package/dist-lib/components/fields/cells/factories/date.js +30 -0
- package/dist-lib/components/fields/cells/factories/email.js +26 -0
- package/dist-lib/components/fields/cells/factories/emptyCell.js +10 -0
- package/dist-lib/components/fields/cells/factories/fileReference.js +17 -0
- package/dist-lib/components/fields/cells/factories/host-icons.js +146 -0
- package/dist-lib/components/fields/cells/factories/json.js +61 -0
- package/dist-lib/components/fields/cells/factories/link.js +32 -0
- package/dist-lib/components/fields/cells/factories/markdown.js +31 -0
- package/dist-lib/components/fields/cells/factories/markdownPreview.js +81 -0
- package/dist-lib/components/fields/cells/factories/money.js +37 -0
- package/dist-lib/components/fields/cells/factories/multilangInline.js +35 -0
- package/dist-lib/components/fields/cells/factories/nextRun.js +46 -0
- package/dist-lib/components/fields/cells/factories/number.js +42 -0
- package/dist-lib/components/fields/cells/factories/passwordMask.js +23 -0
- package/dist-lib/components/fields/cells/factories/phone.js +35 -0
- package/dist-lib/components/fields/cells/factories/refLink.js +57 -0
- package/dist-lib/components/fields/cells/factories/richTextPreview.js +34 -0
- package/dist-lib/components/fields/cells/factories/statusPill.js +35 -0
- package/dist-lib/components/fields/cells/factories/tagList.js +44 -0
- package/dist-lib/components/fields/cells/factories/text.js +5 -0
- package/dist-lib/components/fields/cells/factories/timestamp.js +18 -0
- package/dist-lib/components/fields/cells/factories/url-helpers.js +49 -0
- package/dist-lib/components/fields/cells/factories/url.js +45 -0
- package/dist-lib/components/fields/cells/registry.js +58 -0
- package/dist-lib/components/fields/index.js +80 -0
- package/dist-lib/components/fields/langMap.js +6 -0
- package/dist-lib/components/fields/secretValue.js +7 -0
- package/dist-lib/components/file-widgets/CircleImage.js +11 -0
- package/dist-lib/components/file-widgets/DocumentCard.js +277 -0
- package/dist-lib/components/file-widgets/FileList.js +213 -0
- package/dist-lib/{Grid-XUHm5SDe.js → components/file-widgets/Grid.js} +45 -40
- package/dist-lib/components/file-widgets/GridLazy.js +15 -0
- package/dist-lib/components/file-widgets/ImageWidget.js +354 -0
- package/dist-lib/components/file-widgets/LabeledSlots.js +69 -0
- package/dist-lib/components/file-widgets/SquareImage.js +11 -0
- package/dist-lib/components/file-widgets/UnknownFileWidget.js +22 -0
- package/dist-lib/components/file-widgets/UploadFailureText.js +10 -0
- package/dist-lib/components/file-widgets/WideBanner.js +11 -0
- package/dist-lib/components/file-widgets/builtins.js +15 -0
- package/dist-lib/components/file-widgets/cropper.js +13 -0
- package/dist-lib/components/file-widgets/draft-scope.js +59 -0
- package/dist-lib/components/file-widgets/helpers.js +75 -0
- package/dist-lib/components/file-widgets/host.js +75 -0
- package/dist-lib/{payload-DioMoxMX.js → components/file-widgets/payload.js} +14 -14
- package/dist-lib/components/file-widgets/registry.js +13 -0
- package/dist-lib/components/file-widgets/upload.js +180 -0
- package/dist-lib/components/file-widgets/useEmbedFileSrc.js +45 -0
- package/dist-lib/components/file-widgets/value.js +12 -0
- package/dist-lib/components/filters/FilterChips.js +123 -0
- package/dist-lib/components/filters/FilterConditionValue.js +40 -0
- package/dist-lib/components/filters/FilterDrawer.js +670 -0
- package/dist-lib/components/filters/FilterOmittedNotice.js +14 -0
- package/dist-lib/components/filters/filter-op-label.js +8 -0
- package/dist-lib/{CommandPalette.impl-DRI5kxVY.js → components/layout/CommandPalette.impl.js} +62 -61
- package/dist-lib/components/layout/CommandPalette.js +12 -0
- package/dist-lib/{DirtyTabsCloseDialog.impl-FhAiOmEb.js → components/layout/DirtyTabsCloseDialog.impl.js} +16 -14
- package/dist-lib/components/layout/DirtyTabsCloseDialog.js +12 -0
- package/dist-lib/{ImpersonationBanner.impl--g0iYwcV.js → components/layout/ImpersonationBanner.impl.js} +4 -3
- package/dist-lib/components/layout/ImpersonationBanner.js +12 -0
- package/dist-lib/components/layout/ImpersonationFrame.js +29 -0
- package/dist-lib/{ImpersonationStartModal.impl-BFBN0YJe.js → components/layout/ImpersonationStartModal.impl.js} +9 -9
- package/dist-lib/components/layout/ImpersonationStartModal.js +12 -0
- package/dist-lib/components/layout/Layout.js +755 -0
- package/dist-lib/components/layout/Rail.js +149 -0
- package/dist-lib/components/layout/Sidebar.js +362 -0
- package/dist-lib/components/layout/TabStrip.js +321 -0
- package/dist-lib/components/layout/TenantChip.js +355 -0
- package/dist-lib/components/layout/TopBar.js +305 -0
- package/dist-lib/components/layout/tab-close.js +24 -0
- package/dist-lib/components/list/ColumnPicker.js +112 -0
- package/dist-lib/components/list/InlineEditCell.js +107 -0
- package/dist-lib/components/list/PeekFieldCell.js +143 -0
- package/dist-lib/components/list/QuickPeek.js +263 -0
- package/dist-lib/components/list/ViewSwitcher.js +156 -0
- package/dist-lib/components/list/peekDraftStore.js +14 -0
- package/dist-lib/{AdminCatalogPage.impl-B-7MLqa1.js → components/pages/AdminCatalogPage.impl.js} +53 -49
- package/dist-lib/components/pages/AdminCatalogPage.js +12 -0
- package/dist-lib/components/pages/DocumentsMenu.js +150 -0
- package/dist-lib/components/pages/ExportMenu.js +123 -0
- package/dist-lib/{NotFoundPage.impl-BoX11u-P.js → components/pages/NotFoundPage.impl.js} +6 -4
- package/dist-lib/components/pages/NotFoundPage.js +12 -0
- package/dist-lib/components/pages/RecordDocumentsPanel.js +230 -0
- package/dist-lib/components/pages/RecordNotesPanel.js +200 -0
- package/dist-lib/components/pages/RecordPanels.js +18 -0
- package/dist-lib/components/pages/SSOCallbackPage.impl.js +28 -0
- package/dist-lib/components/pages/SSOCallbackPage.js +12 -0
- package/dist-lib/components/pages/SmartDetailPage.impl.js +986 -0
- package/dist-lib/components/pages/SmartDetailPage.js +12 -0
- package/dist-lib/components/pages/SmartListPage.impl.js +708 -0
- package/dist-lib/components/pages/SmartListPage.js +12 -0
- package/dist-lib/components/pages/SmartRecordListPage.impl.js +818 -0
- package/dist-lib/components/pages/SmartRecordListPage.js +12 -0
- package/dist-lib/components/pages/auth/AuthShell.js +350 -0
- package/dist-lib/{Forgot.impl-6tL6SBlS.js → components/pages/auth/Forgot.impl.js} +13 -12
- package/dist-lib/components/pages/auth/Forgot.js +12 -0
- package/dist-lib/{Reset.impl-D0pjhS6d.js → components/pages/auth/Reset.impl.js} +17 -15
- package/dist-lib/components/pages/auth/Reset.js +12 -0
- package/dist-lib/components/pages/auth/SignIn.js +252 -0
- package/dist-lib/{SignUp.impl-CfEXrUeg.js → components/pages/auth/SignUp.impl.js} +31 -27
- package/dist-lib/components/pages/auth/SignUp.js +12 -0
- package/dist-lib/{TwoFA.impl-B2HtPduH.js → components/pages/auth/TwoFA.impl.js} +9 -8
- package/dist-lib/components/pages/auth/TwoFA.js +12 -0
- package/dist-lib/components/pages/auth/icons.js +56 -0
- package/dist-lib/components/pages/exportRequest.js +17 -0
- package/dist-lib/components/pages/list/DataCell.js +27 -0
- package/dist-lib/components/pages/list/DeleteViewDialog.js +22 -0
- package/dist-lib/{ListCardsBody-BEoYjSZ2.js → components/pages/list/ListCardRow.js} +47 -72
- package/dist-lib/components/pages/list/ListCardsBody.js +31 -0
- package/dist-lib/components/pages/list/ListFloatbar.js +130 -0
- package/dist-lib/components/pages/list/ListFooter.js +138 -0
- package/dist-lib/components/pages/list/ListHeader.js +120 -0
- package/dist-lib/components/pages/list/ListNoRows.js +72 -0
- package/dist-lib/components/pages/list/ListTable.js +191 -0
- package/dist-lib/components/pages/list/ListTableRow.js +37 -0
- package/dist-lib/components/pages/list/ListToolbar.js +261 -0
- package/dist-lib/components/pages/list/ListUrlBanner.js +45 -0
- package/dist-lib/components/pages/list/RowActionsCell.js +49 -0
- package/dist-lib/components/pages/list/RowContextMenu.js +55 -0
- package/dist-lib/components/pages/list/SaveViewDialog.js +111 -0
- package/dist-lib/{SortHeaderMenu-Co5PvhTA.js → components/pages/list/SortHeaderMenu.js} +18 -17
- package/dist-lib/{cardProjection-Cxlogzh8.js → components/pages/list/cardProjection.js} +3 -3
- package/dist-lib/components/pages/list/column-sizing.js +17 -0
- package/dist-lib/components/pages/list/columns.js +168 -0
- package/dist-lib/components/pages/list/filter-meta.js +84 -0
- package/dist-lib/components/pages/list/page-size.js +11 -0
- package/dist-lib/components/pages/list/sortable-header.js +18 -0
- package/dist-lib/components/pages/list/table-features.js +11 -0
- package/dist-lib/components/pages/list/use-filter-value-labels.js +115 -0
- package/dist-lib/components/pages/list/useActiveView.js +98 -0
- package/dist-lib/components/pages/list/useHeaderReorder.js +93 -0
- package/dist-lib/components/pages/list/useListColumnLayout.js +56 -0
- package/dist-lib/components/pages/list/useListFilterPresentation.js +34 -0
- package/dist-lib/components/pages/list/useListQuery.js +101 -0
- package/dist-lib/components/pages/list/useListRowInteraction.js +120 -0
- package/dist-lib/components/pages/list/useListSelection.js +53 -0
- package/dist-lib/components/pages/list/useListSort.js +44 -0
- package/dist-lib/components/pages/list/useListViews.js +148 -0
- package/dist-lib/components/pages/list/useRowMenu.js +106 -0
- package/dist-lib/components/pages/list/visible-filters.js +19 -0
- package/dist-lib/{Preferences.impl-Ct5xwZtT.js → components/pages/profile/Preferences.impl.js} +34 -31
- package/dist-lib/components/pages/profile/Preferences.js +12 -0
- package/dist-lib/components/pages/profile/Profile.impl.js +437 -0
- package/dist-lib/components/pages/profile/Profile.js +12 -0
- package/dist-lib/{TenantParamsPage.impl-BGpdmEZg.js → components/pages/tenant-params/TenantParamsPage.impl.js} +45 -40
- package/dist-lib/components/pages/tenant-params/TenantParamsPage.js +12 -0
- package/dist-lib/components/params/ParamsBlock.js +119 -0
- package/dist-lib/{param-editors-TYYU7HKK.js → components/params/param-editors.js} +32 -28
- package/dist-lib/components/primitives/Avatar.js +33 -0
- package/dist-lib/components/primitives/BoolToggle.js +35 -0
- package/dist-lib/components/primitives/BrandGlyph.js +38 -0
- package/dist-lib/components/primitives/BrandLogo.js +20 -0
- package/dist-lib/components/primitives/Btn.js +67 -0
- package/dist-lib/{Check-DAfMbQIw.js → components/primitives/Check.js} +2 -2
- package/dist-lib/components/primitives/Chip.js +44 -0
- package/dist-lib/components/primitives/ClassifiedFieldLocked.js +15 -0
- package/dist-lib/components/primitives/Dropdown.js +85 -0
- package/dist-lib/components/primitives/Fields.js +751 -0
- package/dist-lib/components/primitives/HoverCard.js +115 -0
- package/dist-lib/components/primitives/IconBtn.js +37 -0
- package/dist-lib/{Icons-lt-7lhYR.js → components/primitives/Icons.js} +1 -1
- package/dist-lib/{Kbd-CNttVu0z.js → components/primitives/Kbd.js} +2 -2
- package/dist-lib/components/primitives/MenuItem.js +57 -0
- package/dist-lib/{Pill-D-wsfRhx.js → components/primitives/Pill.js} +1 -1
- package/dist-lib/{RecordIdBadge-wbigZaFc.js → components/primitives/RecordIdBadge.js} +5 -5
- package/dist-lib/components/primitives/RowField.js +47 -0
- package/dist-lib/{SectionCard-BYHoHWJc.js → components/primitives/SectionCard.js} +10 -10
- package/dist-lib/components/primitives/Spinner.js +31 -0
- package/dist-lib/components/primitives/StatTile.js +108 -0
- package/dist-lib/components/primitives/Tooltip.js +115 -0
- package/dist-lib/{dataTableStyles-vwD1mVOP.js → components/primitives/dataTableStyles.js} +1 -1
- package/dist-lib/components/shared/BlankScreen.js +13 -0
- package/dist-lib/{ChangePasswordDialog.impl-5hDc0wpE.js → components/shared/ChangePasswordDialog.impl.js} +27 -22
- package/dist-lib/{ChangePasswordDialog-C_T_3pjl.js → components/shared/ChangePasswordDialog.js} +2 -2
- package/dist-lib/components/shared/ConfirmDialog.js +129 -0
- package/dist-lib/components/shared/ConnectionNotice.js +12 -0
- package/dist-lib/components/shared/CopyButton.js +25 -0
- package/dist-lib/components/shared/DynamicIcon.js +73 -0
- package/dist-lib/components/shared/EmptyState.js +56 -0
- package/dist-lib/components/shared/ErrorBoundary.js +96 -0
- package/dist-lib/components/shared/LoadingSkeleton.js +117 -0
- package/dist-lib/components/shared/LucideIcon.js +43 -0
- package/dist-lib/components/shared/Markdown.js +15 -0
- package/dist-lib/{MarkdownRenderer-sK2TRZS-.js → components/shared/MarkdownRenderer.js} +10 -9
- package/dist-lib/components/shared/RefreshControl.js +42 -0
- package/dist-lib/components/shared/StatusGroupsDisplay.js +123 -0
- package/dist-lib/components/shared/StatusStepper.js +70 -0
- package/dist-lib/components/shared/toast/DeclarionToast.js +308 -0
- package/dist-lib/components/shared/useOwnRefresh.js +19 -0
- package/dist-lib/declarion-react.css +1 -1
- package/dist-lib/embed/EmbedAuthBootstrap.js +71 -0
- package/dist-lib/embed/EmbedContext.js +38 -0
- package/dist-lib/embed/EmbedDirtyReporter.js +17 -0
- package/dist-lib/embed/EmbedHistoryTracker.js +17 -0
- package/dist-lib/embed/EmbedLocationReporter.js +26 -0
- package/dist-lib/embed/EmbedResizeReporter.js +25 -0
- package/dist-lib/embed/EmbedUnsavedGuard.js +23 -0
- package/dist-lib/embed/embed-dirty.js +21 -0
- package/dist-lib/embed/embed-history.js +17 -0
- package/dist-lib/embed/embed-nav-guard.js +13 -0
- package/dist-lib/embed/file-src.js +60 -0
- package/dist-lib/embed/handshake.js +37 -0
- package/dist-lib/embed/params.js +45 -0
- package/dist-lib/embed/protocol.js +26 -0
- package/dist-lib/embed/screen-location.js +44 -0
- package/dist-lib/embed/theme.js +11 -0
- package/dist-lib/embed/token.js +54 -0
- package/dist-lib/embed/useEmbedNavigate.js +65 -0
- package/dist-lib/embed/useGlobalLinkInterceptor.js +63 -0
- package/dist-lib/hooks/useActionData.js +58 -0
- package/dist-lib/hooks/useAgentConversation.js +311 -0
- package/dist-lib/hooks/useAggregate.js +18 -0
- package/dist-lib/hooks/useAllEntityData.js +53 -0
- package/dist-lib/hooks/useAssociatedData.js +37 -0
- package/dist-lib/hooks/useAuth.js +56 -0
- package/dist-lib/hooks/useBranding.js +18 -0
- package/dist-lib/hooks/useBrandingChrome.js +58 -0
- package/dist-lib/hooks/useChildrenData.js +33 -0
- package/dist-lib/hooks/useColumns.js +44 -0
- package/dist-lib/hooks/useConnectionNotice.js +35 -0
- package/dist-lib/{useCurrentLocation-Bq1T72AW.js → hooks/useCurrentLocation.js} +2 -2
- package/dist-lib/hooks/useCurrentScreen.js +20 -0
- package/dist-lib/hooks/useCursorEntityData.js +77 -0
- package/dist-lib/hooks/useDebounce.js +11 -0
- package/dist-lib/hooks/useEntity.js +8 -0
- package/dist-lib/hooks/useEntityData.js +64 -0
- package/dist-lib/hooks/useFileReferenceJSON.js +29 -0
- package/dist-lib/hooks/useFilters.js +28 -0
- package/dist-lib/hooks/useFollowAgentOpen.js +84 -0
- package/dist-lib/hooks/useImpersonation.js +40 -0
- package/dist-lib/hooks/useIntentPrefetch.js +43 -0
- package/dist-lib/hooks/useJsonSnapshot.js +8 -0
- package/dist-lib/hooks/useLanguage.js +21 -0
- package/dist-lib/hooks/useLiveObject.js +17 -0
- package/dist-lib/hooks/useLongPress.js +49 -0
- package/dist-lib/hooks/useMutations.js +70 -0
- package/dist-lib/{useObject-B45F96rC.js → hooks/useObject.js} +2 -2
- package/dist-lib/hooks/useObjectStatus.js +20 -0
- package/dist-lib/hooks/usePageState.js +18 -0
- package/dist-lib/hooks/usePageStateRuntime.js +46 -0
- package/dist-lib/hooks/usePageStateTtl.js +10 -0
- package/dist-lib/hooks/useParams.js +123 -0
- package/dist-lib/hooks/useProperties.js +32 -0
- package/dist-lib/hooks/useRealtimeThresholds.js +31 -0
- package/dist-lib/hooks/useRegisterScreenTab.js +28 -0
- package/dist-lib/hooks/useResponsiveMode.js +84 -0
- package/dist-lib/hooks/useSSE.js +307 -0
- package/dist-lib/hooks/useSchema.js +73 -0
- package/dist-lib/hooks/useScreen.js +8 -0
- package/dist-lib/hooks/useScreenBack.js +60 -0
- package/dist-lib/hooks/useScreenTab.js +11 -0
- package/dist-lib/hooks/useTabNavigate.js +82 -0
- package/dist-lib/hooks/useTabSearchMirror.js +19 -0
- package/dist-lib/{useTabTitle-KrzEo118.js → hooks/useTabTitle.js} +9 -7
- package/dist-lib/hooks/useText.js +15 -0
- package/dist-lib/hooks/useTimelineData.js +44 -0
- package/dist-lib/hooks/useUnsavedInput.js +18 -0
- package/dist-lib/hooks/useVersionWatcher.js +62 -0
- package/dist-lib/hooks/useViews.js +88 -0
- package/dist-lib/hooks/useWindowConversation.js +11 -0
- package/dist-lib/icons.js +5 -3
- package/dist-lib/index.d.ts +42 -20
- package/dist-lib/index.js +131 -3926
- package/dist-lib/lib/action-dispatch.js +7 -0
- package/dist-lib/lib/actions.js +279 -0
- package/dist-lib/lib/anchor.js +41 -0
- package/dist-lib/lib/brand-tokens.js +95 -0
- package/dist-lib/lib/branding.js +25 -0
- package/dist-lib/lib/canonical-url.js +17 -0
- package/dist-lib/lib/capabilityPrefetch.js +57 -0
- package/dist-lib/lib/child-config.js +111 -0
- package/dist-lib/lib/children-validation.js +52 -0
- package/dist-lib/lib/decimal-text.js +15 -0
- package/dist-lib/lib/display-value.js +19 -0
- package/dist-lib/lib/document-templates.js +6 -0
- package/dist-lib/lib/download.js +41 -0
- package/dist-lib/lib/evidence-verdict.js +23 -0
- package/dist-lib/lib/failure.js +9 -0
- package/dist-lib/lib/field-classification.js +58 -0
- package/dist-lib/lib/field-regions.js +13 -0
- package/dist-lib/lib/filter-evaluator.js +98 -0
- package/dist-lib/lib/filters.js +118 -0
- package/dist-lib/lib/format-count.js +24 -0
- package/dist-lib/lib/html-state.js +9 -0
- package/dist-lib/lib/language.js +52 -0
- package/dist-lib/lib/longPressGesture.js +34 -0
- package/dist-lib/lib/mass-edit.js +65 -0
- package/dist-lib/{page-inset-D_kkVwwN.js → lib/page-inset.js} +1 -1
- package/dist-lib/lib/phone.js +28 -0
- package/dist-lib/lib/query-retry.js +7 -0
- package/dist-lib/lib/quick-add.js +23 -0
- package/dist-lib/lib/realtime-query-keys.js +23 -0
- package/dist-lib/lib/realtime-reconcile.js +148 -0
- package/dist-lib/lib/realtime-resync.js +192 -0
- package/dist-lib/lib/record-documents-key.js +4 -0
- package/dist-lib/lib/ref-choices.js +6 -0
- package/dist-lib/lib/refetch-when-idle.js +25 -0
- package/dist-lib/lib/rich-text.js +46 -0
- package/dist-lib/lib/rowClickGesture.js +10 -0
- package/dist-lib/lib/safe-url.js +34 -0
- package/dist-lib/lib/schema-routing.js +51 -0
- package/dist-lib/{screen-back-BtbEp5sO.js → lib/screen-back.js} +2 -2
- package/dist-lib/lib/scroll-restoration.js +156 -0
- package/dist-lib/lib/size-value.js +22 -0
- package/dist-lib/lib/sort.js +59 -0
- package/dist-lib/lib/timestamp.js +97 -0
- package/dist-lib/lib/toast.js +78 -0
- package/dist-lib/lib/ui-actions.js +81 -0
- package/dist-lib/{utils-D_QDpB8_.js → lib/utils.js} +1 -1
- package/dist-lib/lib/variants.js +63 -0
- package/dist-lib/lib/versionTracker.js +102 -0
- package/dist-lib/lib/viewport-category.js +12 -0
- package/dist-lib/{window-election-CHIvIZwx.js → lib/window-election.js} +1 -1
- package/dist-lib/stores/auth.js +84 -0
- package/dist-lib/stores/icon-registry.js +24 -0
- package/dist-lib/stores/list-layout.js +178 -0
- package/dist-lib/{page-state-eA6J_KIR.js → stores/page-state.js} +1 -1
- package/dist-lib/stores/preferences.js +126 -0
- package/dist-lib/stores/realtime.js +115 -0
- package/dist-lib/stores/screen-registry.js +10 -0
- package/dist-lib/stores/tabs.js +220 -0
- package/dist-lib/test/seed-schema.js +8 -0
- package/dist-lib/testing.d.ts +1 -1
- package/dist-lib/testing.js +80 -76
- package/dist-lib/types/api.js +48 -0
- package/dist-lib/types/fieldType.js +4 -0
- package/dist-lib/types/ordmap.js +50 -0
- package/dist-lib/types/schema.js +173 -0
- package/dist-lib/{useResponsiveMode-DIR1bZfo.d.ts → useResponsiveMode-DmrpMbZX.d.ts} +44 -16
- package/package.json +13 -12
- package/dist-lib/ActionRunner-DdBFhqGe.js +0 -1440
- package/dist-lib/AgentOpenFollower.impl-BAs_wGEZ.js +0 -81
- package/dist-lib/AssociatedBlock-BOoPLOjw.js +0 -1515
- package/dist-lib/AuthShell-C8aVwHS7.js +0 -361
- package/dist-lib/BlankScreen-DVc7fh8C.js +0 -61
- package/dist-lib/CopyButton-DRIT_f0k.js +0 -119
- package/dist-lib/DynamicIcon-DuBSz6TZ.js +0 -133
- package/dist-lib/FilterChips-Cv1tlXyo.js +0 -1031
- package/dist-lib/LayoutRenderer-d-tXYPze.js +0 -3239
- package/dist-lib/MenuItem-CfkVXPvC.js +0 -140
- package/dist-lib/MonacoJson-BG3S3GHX.js +0 -60
- package/dist-lib/Profile.impl-Cypk27ah.js +0 -527
- package/dist-lib/PropertyGridEditor-XrP6TZ5s.js +0 -4378
- package/dist-lib/RecordHeader-BfQ0_4wq.js +0 -217
- package/dist-lib/RefreshControl-CRdWPoF5.js +0 -195
- package/dist-lib/SSOCallbackPage.impl-Cfi2pQ59.js +0 -31
- package/dist-lib/SmartDetailPage.impl-BiIX0n7K.js +0 -1609
- package/dist-lib/SmartListPage.impl-Cu83Gv_G.js +0 -2818
- package/dist-lib/SmartRecordListPage.impl-DR6lq7HA.js +0 -795
- package/dist-lib/format-count-lyB4CPen.js +0 -943
- package/dist-lib/peekDraftStore-CaimrOhW.js +0 -200
- package/dist-lib/registry-CGe5kCXN.js +0 -119
- package/dist-lib/use-filter-value-labels-D3YDgUzg.js +0 -413
- package/dist-lib/useAgentConversation-rru-7hnF.js +0 -612
- package/dist-lib/useBranding-zcxEic2k.js +0 -41
- package/dist-lib/useBrandingChrome-bxaR3G1R.js +0 -170
- package/dist-lib/useCurrentScreen-BZOHBGQZ.js +0 -2522
- package/dist-lib/useImpersonation-DBIRRR70.js +0 -35
- package/dist-lib/useOwnRefresh-DJjaje52.js +0 -435
- package/dist-lib/useParams-BFLJi4n3.js +0 -133
- package/dist-lib/useProperties-B7opZ-iy.js +0 -81
- package/dist-lib/useScreenBack-DENlz844.js +0 -71
- package/dist-lib/useTabNavigate-CUqOmcMj.js +0 -78
- package/dist-lib/value-BuQVYx52.js +0 -194
- package/dist-lib/variants-vUtfBbE6.js +0 -1961
- /package/dist-lib/{JsonEditor-Dz1PQHC8.js → components/fields/JsonEditor.js} +0 -0
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { errorCodeOf as e, isCursorStaleError as t } from "../types/api.js";
|
|
2
|
+
import { apiFetch as n, callHandler as r } from "./client.js";
|
|
3
|
+
import { executeAction as i } from "./data.js";
|
|
4
|
+
//#region src/api/entities.ts
|
|
5
|
+
function a(e, t) {
|
|
6
|
+
return e.$statuses?.find((e) => e.group_code === t);
|
|
7
|
+
}
|
|
8
|
+
function o(e, t) {
|
|
9
|
+
return e.$properties?.find((e) => e.property_code === t);
|
|
10
|
+
}
|
|
11
|
+
function s(e) {
|
|
12
|
+
let t = { ...e };
|
|
13
|
+
return t.$status = (e) => a(t, e), t.$property = (e) => o(t, e), t;
|
|
14
|
+
}
|
|
15
|
+
var c = class {
|
|
16
|
+
cache = {};
|
|
17
|
+
merge(e) {
|
|
18
|
+
if (e) for (let t of Object.keys(e)) {
|
|
19
|
+
this.cache[t] || (this.cache[t] = {});
|
|
20
|
+
let n = e[t];
|
|
21
|
+
for (let e of Object.keys(n)) this.cache[t][e] = {
|
|
22
|
+
...this.cache[t][e],
|
|
23
|
+
...n[e]
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
all() {
|
|
28
|
+
return this.cache;
|
|
29
|
+
}
|
|
30
|
+
get(e, t) {
|
|
31
|
+
return this.cache[e]?.[t];
|
|
32
|
+
}
|
|
33
|
+
clear() {
|
|
34
|
+
this.cache = {};
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
function l(e, t) {
|
|
38
|
+
let n = new URL(`/api/data/${e}`, window.location.origin);
|
|
39
|
+
return t.select && t.select.length > 0 && n.searchParams.set("select", t.select.join(",")), t.expand && t.expand.length > 0 && n.searchParams.set("expand", t.expand.join(",")), t.sort && n.searchParams.set("sort", t.sort), t.search && n.searchParams.set("search", t.search), t.limit && n.searchParams.set("limit", String(t.limit)), t.after && n.searchParams.set("after", t.after), t.count && n.searchParams.set("count", "with"), t.screen && n.searchParams.set("screen", t.screen), t.preview && n.searchParams.set("preview", "true"), t.include_deleted && n.searchParams.set("include_deleted", "true"), t.filters && t.filters.length > 0 && n.searchParams.set("filters", JSON.stringify(t.filters)), n.pathname + n.search;
|
|
40
|
+
}
|
|
41
|
+
var u = class {
|
|
42
|
+
entity;
|
|
43
|
+
refs;
|
|
44
|
+
constructor(e, t) {
|
|
45
|
+
this.entity = e, this.refs = t ?? new c();
|
|
46
|
+
}
|
|
47
|
+
async get(e) {
|
|
48
|
+
let t = new URLSearchParams(typeof e == "string" ? { id: e } : e);
|
|
49
|
+
return s((await n(`/api/data/${this.entity}?${t.toString()}`)).data);
|
|
50
|
+
}
|
|
51
|
+
async list(e = {}) {
|
|
52
|
+
let r, i = !1;
|
|
53
|
+
try {
|
|
54
|
+
r = await n(l(this.entity, e));
|
|
55
|
+
} catch (a) {
|
|
56
|
+
if (e.after && t(a)) {
|
|
57
|
+
let { after: t, ...a } = e;
|
|
58
|
+
r = await n(l(this.entity, a)), i = !0;
|
|
59
|
+
} else throw a;
|
|
60
|
+
}
|
|
61
|
+
return this.refs.merge(r.$refs), {
|
|
62
|
+
data: r.data.map((e) => s(e)),
|
|
63
|
+
meta: r.meta,
|
|
64
|
+
$refs: this.refs.all(),
|
|
65
|
+
reset: i
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
async create(e) {
|
|
69
|
+
return (await this.createMany([e]))[0];
|
|
70
|
+
}
|
|
71
|
+
async createMany(e) {
|
|
72
|
+
if (e.length === 0) return [];
|
|
73
|
+
let t = e.map((e) => ({
|
|
74
|
+
action: `${this.entity}.__create`,
|
|
75
|
+
params: {
|
|
76
|
+
entity: this.entity,
|
|
77
|
+
fields: e
|
|
78
|
+
}
|
|
79
|
+
})), n = await r("system.batch", {
|
|
80
|
+
actions: t,
|
|
81
|
+
atomic: !0
|
|
82
|
+
});
|
|
83
|
+
return d(n, `${this.entity}.__create`), n.results.map((e) => s(f(e)));
|
|
84
|
+
}
|
|
85
|
+
async update(e, t) {
|
|
86
|
+
return (await this.updateMany([{
|
|
87
|
+
id: e,
|
|
88
|
+
...t
|
|
89
|
+
}]))[0];
|
|
90
|
+
}
|
|
91
|
+
async updateMany(e) {
|
|
92
|
+
if (e.length === 0) return [];
|
|
93
|
+
let t = e.map(({ id: e, ...t }) => ({
|
|
94
|
+
action: `${this.entity}.__update`,
|
|
95
|
+
params: {
|
|
96
|
+
object_ids: [e],
|
|
97
|
+
entity: this.entity,
|
|
98
|
+
fields: t
|
|
99
|
+
}
|
|
100
|
+
})), n = await r("system.batch", {
|
|
101
|
+
actions: t,
|
|
102
|
+
atomic: !0
|
|
103
|
+
});
|
|
104
|
+
return d(n, `${this.entity}.__update`), n.results.map((e) => s(f(e)));
|
|
105
|
+
}
|
|
106
|
+
async delete(e) {
|
|
107
|
+
await this.deleteMany([e]);
|
|
108
|
+
}
|
|
109
|
+
async deleteMany(e) {
|
|
110
|
+
return e.length === 0 ? { count: 0 } : { count: (await i(`${this.entity}.__delete`, {
|
|
111
|
+
object_ids: e,
|
|
112
|
+
entity: this.entity
|
|
113
|
+
})).object_count ?? e.length };
|
|
114
|
+
}
|
|
115
|
+
async restore(e) {
|
|
116
|
+
await this.restoreMany([e]);
|
|
117
|
+
}
|
|
118
|
+
async restoreMany(e) {
|
|
119
|
+
return e.length === 0 ? { count: 0 } : { count: (await i(`${this.entity}.__restore`, {
|
|
120
|
+
object_ids: e,
|
|
121
|
+
entity: this.entity
|
|
122
|
+
})).object_count ?? e.length };
|
|
123
|
+
}
|
|
124
|
+
async upsert(e, t) {
|
|
125
|
+
return (await this.upsertMany([e], t))[0];
|
|
126
|
+
}
|
|
127
|
+
async upsertMany(e, t) {
|
|
128
|
+
if (e.length === 0) return [];
|
|
129
|
+
let n = e.map((e) => ({
|
|
130
|
+
action: `${this.entity}.__upsert`,
|
|
131
|
+
params: {
|
|
132
|
+
entity: this.entity,
|
|
133
|
+
fields: e,
|
|
134
|
+
unique_by: t
|
|
135
|
+
}
|
|
136
|
+
})), i = await r("system.batch", {
|
|
137
|
+
actions: n,
|
|
138
|
+
atomic: !0
|
|
139
|
+
});
|
|
140
|
+
return d(i, `${this.entity}.__upsert`), i.results.map((e) => s(p(e)));
|
|
141
|
+
}
|
|
142
|
+
};
|
|
143
|
+
function d(t, n) {
|
|
144
|
+
if (t.committed) return;
|
|
145
|
+
let r = t.results.find((e) => !e.ok), i = r?.error ? `${e(r.error.type)}: ${r.error.title}` : "batch did not commit";
|
|
146
|
+
throw Error(`${n} batch failed: ${i}`);
|
|
147
|
+
}
|
|
148
|
+
function f(e) {
|
|
149
|
+
let t = e.result ?? {};
|
|
150
|
+
return (Array.isArray(t.rows) ? t.rows[0] : void 0) ?? {};
|
|
151
|
+
}
|
|
152
|
+
function p(e) {
|
|
153
|
+
let t = e.result ?? {};
|
|
154
|
+
return (Array.isArray(t.rows) ? t.rows[0] : void 0)?.row ?? {};
|
|
155
|
+
}
|
|
156
|
+
function m(e, t) {
|
|
157
|
+
return new u(e, t);
|
|
158
|
+
}
|
|
159
|
+
//#endregion
|
|
160
|
+
export { u as EntityClient, c as RefCache, m as entityClient };
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { ApiError as e, readProblem as t } from "../types/api.js";
|
|
2
|
+
import { withPublishedLanguage as n } from "./client.js";
|
|
3
|
+
//#region src/api/events.ts
|
|
4
|
+
var r = new EventTarget(), i = "agent-frame", a = "agent-message-changed";
|
|
5
|
+
function o(e) {
|
|
6
|
+
r.dispatchEvent(new CustomEvent(i, { detail: e }));
|
|
7
|
+
}
|
|
8
|
+
var s = class extends Error {
|
|
9
|
+
constructor() {
|
|
10
|
+
super("SSE auth expired"), this.name = "SSEAuthError";
|
|
11
|
+
}
|
|
12
|
+
}, c;
|
|
13
|
+
function l() {
|
|
14
|
+
return c;
|
|
15
|
+
}
|
|
16
|
+
async function* u(i = {}) {
|
|
17
|
+
let l = new Headers();
|
|
18
|
+
i.lastEventID && l.set("Last-Event-ID", i.lastEventID), i.bearerToken && l.set("Authorization", `Bearer ${i.bearerToken}`);
|
|
19
|
+
let u = await fetch(n("/api/events"), {
|
|
20
|
+
credentials: i.credentials ?? "include",
|
|
21
|
+
signal: i.signal,
|
|
22
|
+
headers: l
|
|
23
|
+
});
|
|
24
|
+
if (!u.ok || !u.body) {
|
|
25
|
+
let { raw: n, body: r } = await t(u);
|
|
26
|
+
throw u.status === 401 ? new s() : new e(u.status, r, n);
|
|
27
|
+
}
|
|
28
|
+
if (c === void 0) {
|
|
29
|
+
let e = Date.parse(u.headers.get("Date") ?? "");
|
|
30
|
+
Number.isNaN(e) || (c = e);
|
|
31
|
+
}
|
|
32
|
+
let d = u.body.getReader(), f = new TextDecoder(), p = "", m = "", h = "", g = "";
|
|
33
|
+
try {
|
|
34
|
+
for (;;) {
|
|
35
|
+
let { done: e, value: t } = await d.read();
|
|
36
|
+
if (e) break;
|
|
37
|
+
i.onActivity?.(), p += f.decode(t, { stream: !0 });
|
|
38
|
+
let n = p.split("\n");
|
|
39
|
+
p = n.pop() ?? "";
|
|
40
|
+
for (let e of n) if (e.startsWith("event: ")) m = e.slice(7);
|
|
41
|
+
else if (e.startsWith("id: ")) g = e.slice(4);
|
|
42
|
+
else if (e === "id:") g = "";
|
|
43
|
+
else if (e.startsWith("data: ")) h = e.slice(6);
|
|
44
|
+
else if (e === "" && m) {
|
|
45
|
+
try {
|
|
46
|
+
if (m === "session_refresh") yield { type: "session_refresh" };
|
|
47
|
+
else if (m === "checkpoint" && g) yield {
|
|
48
|
+
type: "checkpoint",
|
|
49
|
+
eventID: g
|
|
50
|
+
};
|
|
51
|
+
else if (m === "replay_complete") yield {
|
|
52
|
+
type: "replay_complete",
|
|
53
|
+
seq: (h ? JSON.parse(h) : {}).seq
|
|
54
|
+
};
|
|
55
|
+
else if (m === "snapshot_complete") {
|
|
56
|
+
let e = h ? JSON.parse(h) : {};
|
|
57
|
+
yield {
|
|
58
|
+
type: "snapshot_complete",
|
|
59
|
+
known: e.known === !0,
|
|
60
|
+
asOf: typeof e.as_of == "number" ? e.as_of : void 0
|
|
61
|
+
};
|
|
62
|
+
} else if (m === "realtime_streaming" && h) {
|
|
63
|
+
let e = JSON.parse(h);
|
|
64
|
+
Array.isArray(e.degraded) && e.degraded.every((e) => typeof e == "string") && (yield {
|
|
65
|
+
type: "realtime_streaming",
|
|
66
|
+
eventID: g || void 0,
|
|
67
|
+
degraded: e.degraded
|
|
68
|
+
});
|
|
69
|
+
} else if (m === "realtime_degraded" && h) {
|
|
70
|
+
let e = JSON.parse(h);
|
|
71
|
+
e.entity && (yield {
|
|
72
|
+
type: "realtime_degraded",
|
|
73
|
+
eventID: g || void 0,
|
|
74
|
+
entity: e.entity,
|
|
75
|
+
degradedSeq: e.degraded_seq
|
|
76
|
+
});
|
|
77
|
+
} else if (m === "cache_reset" && h) {
|
|
78
|
+
let e = JSON.parse(h);
|
|
79
|
+
yield {
|
|
80
|
+
type: "cache_reset",
|
|
81
|
+
eventID: g || void 0,
|
|
82
|
+
reason: e.reason || "replay_gap",
|
|
83
|
+
requestedSeq: e.requested_seq,
|
|
84
|
+
oldestSeq: e.oldest_seq,
|
|
85
|
+
resetSeq: e.reset_seq
|
|
86
|
+
};
|
|
87
|
+
} else if (m === "agent_stream" && h) {
|
|
88
|
+
let e = JSON.parse(h);
|
|
89
|
+
o({
|
|
90
|
+
convId: e.conversation_id,
|
|
91
|
+
kind: e.kind,
|
|
92
|
+
turnId: e.turn_id,
|
|
93
|
+
payload: e.payload
|
|
94
|
+
});
|
|
95
|
+
} else if (m === "entity_changed" && h) {
|
|
96
|
+
let e = JSON.parse(h);
|
|
97
|
+
(e.entity === "agent_message" || e.entity === "agent_turn" || e.entity === "agent_tool_invocation") && r.dispatchEvent(new CustomEvent(a, { detail: {
|
|
98
|
+
entity: e.entity,
|
|
99
|
+
rowId: e.ids[0],
|
|
100
|
+
action: e.action
|
|
101
|
+
} })), yield {
|
|
102
|
+
type: "entity_changed",
|
|
103
|
+
eventID: g || void 0,
|
|
104
|
+
entity: e.entity,
|
|
105
|
+
ids: e.ids,
|
|
106
|
+
objects: e.objects,
|
|
107
|
+
action: e.action,
|
|
108
|
+
reason: e.reason
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
} catch {}
|
|
112
|
+
m = "", h = "", g = "";
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
} finally {
|
|
116
|
+
d.releaseLock();
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
//#endregion
|
|
120
|
+
export { i as AGENT_FRAME_EVENT, a as AGENT_MESSAGE_CHANGED_EVENT, s as SSEAuthError, r as agentBus, o as emitAgentFrame, l as eventStreamFirstOpenedAt, u as streamEvents };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { apiFetchBlob as e } from "./client.js";
|
|
2
|
+
//#region src/api/fileReferences.ts
|
|
3
|
+
function t(t, n, r, i = {}) {
|
|
4
|
+
let a = new URLSearchParams(typeof n == "string" ? { id: n } : n);
|
|
5
|
+
return e(`/api/files/references/${encodeURIComponent(t)}/${encodeURIComponent(r)}?${a.toString()}`, { signal: i.signal });
|
|
6
|
+
}
|
|
7
|
+
//#endregion
|
|
8
|
+
export { t as readFileReference };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { apiFetch as e } from "./client.js";
|
|
2
|
+
//#region src/api/params.ts
|
|
3
|
+
async function t() {
|
|
4
|
+
let t = (await e("/api/params/public")).data;
|
|
5
|
+
if (Array.isArray(t)) return { parameters: t };
|
|
6
|
+
let n = t ?? {};
|
|
7
|
+
return {
|
|
8
|
+
parameters: n.parameters ?? [],
|
|
9
|
+
accents: n.accents,
|
|
10
|
+
meta: n.meta
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
async function n(t, n = {}) {
|
|
14
|
+
return (await e(`/api/params/${encodeURIComponent(t)}`, {}, n)).data;
|
|
15
|
+
}
|
|
16
|
+
async function r(t) {
|
|
17
|
+
return (await e(`/api/params${t === "tenant" ? "?resolution=tenant" : ""}`)).data ?? [];
|
|
18
|
+
}
|
|
19
|
+
//#endregion
|
|
20
|
+
export { r as fetchAllParams, n as fetchParam, t as fetchPublicParams };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { executeAction as e } from "./data.js";
|
|
2
|
+
//#region src/api/properties.ts
|
|
3
|
+
async function t(t, n, r, i) {
|
|
4
|
+
let a = (await e(`${t}.__update`, {
|
|
5
|
+
object_ids: [n],
|
|
6
|
+
entity: t,
|
|
7
|
+
fields: { $properties: [{
|
|
8
|
+
property_code: r,
|
|
9
|
+
value: i
|
|
10
|
+
}] }
|
|
11
|
+
})).result?.rows?.[0]?.$properties ?? [];
|
|
12
|
+
return a.find((e) => e.property_code === r) ?? a[0];
|
|
13
|
+
}
|
|
14
|
+
async function n(t, n, r) {
|
|
15
|
+
await e(`${t}.__update`, {
|
|
16
|
+
object_ids: [n],
|
|
17
|
+
entity: t,
|
|
18
|
+
fields: { $properties: [{
|
|
19
|
+
property_code: r,
|
|
20
|
+
value: null
|
|
21
|
+
}] }
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
//#endregion
|
|
25
|
+
export { n as deleteObjectProperty, t as setObjectProperty };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
//#region src/api/request-bounds.ts
|
|
2
|
+
var e = 1e4, t = 3e4, n = 15e3, r = 75e3;
|
|
3
|
+
function i(e) {
|
|
4
|
+
return Math.floor(Math.random() * Math.min(3e4, 1e3 * 2 ** e));
|
|
5
|
+
}
|
|
6
|
+
var a = /* @__PURE__ */ new Map();
|
|
7
|
+
function o(e) {
|
|
8
|
+
a = new Map(Object.entries(e.actions ?? {}));
|
|
9
|
+
for (let [t, n] of Object.entries(e.entities ?? {})) for (let [e, r] of Object.entries(n.actions ?? {})) a.set(`${t}.${e}`, r);
|
|
10
|
+
}
|
|
11
|
+
function s(e) {
|
|
12
|
+
try {
|
|
13
|
+
return JSON.parse(e).object_ids?.length || 1;
|
|
14
|
+
} catch {
|
|
15
|
+
return 1;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
var c = "/api/actions/";
|
|
19
|
+
function l(e, i) {
|
|
20
|
+
if (!i.method || i.method === "GET") return t;
|
|
21
|
+
if (e.startsWith(c)) {
|
|
22
|
+
let t = a.get(e.slice(13).split("?", 1)[0]);
|
|
23
|
+
if (t?.timeout_ms) return t.timeout_ms * (t.invoke === "each" ? s(i.body) : 1) + n;
|
|
24
|
+
}
|
|
25
|
+
return r;
|
|
26
|
+
}
|
|
27
|
+
//#endregion
|
|
28
|
+
export { n as ACTION_NETWORK_MARGIN_MS, t as READ_TIMEOUT_MS, e as REFRESH_TIMEOUT_MS, r as UNKNOWN_ACTION_TIMEOUT_MS, i as backoffDelayMs, o as recordActionTimeouts, l as requestTimeoutMs };
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { recordActionTimeouts as e } from "./request-bounds.js";
|
|
2
|
+
import { apiFetch as t, currentReader as n, publishLanguageFor as r } from "./client.js";
|
|
3
|
+
import { OrderedMap as i } from "../types/ordmap.js";
|
|
4
|
+
//#region src/api/schema.ts
|
|
5
|
+
function a(e) {
|
|
6
|
+
return {
|
|
7
|
+
...e,
|
|
8
|
+
params: e.params ? i.fromWire(e.params) : void 0
|
|
9
|
+
};
|
|
10
|
+
}
|
|
11
|
+
function o(e) {
|
|
12
|
+
return {
|
|
13
|
+
...e,
|
|
14
|
+
resolved_params: e.resolved_params ? i.fromWire(e.resolved_params) : void 0
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
function s(e) {
|
|
18
|
+
let t = {};
|
|
19
|
+
if (e.handlers) for (let [n, r] of Object.entries(e.handlers)) t[n] = a(r);
|
|
20
|
+
let n = {};
|
|
21
|
+
if (e.actions) for (let [t, r] of Object.entries(e.actions)) n[t] = o(r);
|
|
22
|
+
return {
|
|
23
|
+
...e,
|
|
24
|
+
fields: i.fromWire(e.fields),
|
|
25
|
+
files: e.files ? i.fromWire(e.files) : void 0,
|
|
26
|
+
variants: e.variants ? i.fromWire(e.variants) : void 0,
|
|
27
|
+
handlers: e.handlers ? t : void 0,
|
|
28
|
+
actions: e.actions ? n : void 0
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
function c(e) {
|
|
32
|
+
let t = {};
|
|
33
|
+
if (e.entities) for (let [n, r] of Object.entries(e.entities)) t[n] = s(r);
|
|
34
|
+
let n = {};
|
|
35
|
+
if (e.structures) for (let [t, r] of Object.entries(e.structures)) n[t] = {
|
|
36
|
+
...r,
|
|
37
|
+
fields: i.fromWire(r.fields)
|
|
38
|
+
};
|
|
39
|
+
let r = {};
|
|
40
|
+
if (e.handlers) for (let [t, n] of Object.entries(e.handlers)) r[t] = a(n);
|
|
41
|
+
let c = {};
|
|
42
|
+
if (e.actions) for (let [t, n] of Object.entries(e.actions)) c[t] = o(n);
|
|
43
|
+
let l = { ...e.screens };
|
|
44
|
+
for (let [e, t] of Object.entries(l)) {
|
|
45
|
+
let n = t;
|
|
46
|
+
l[e] = {
|
|
47
|
+
...t,
|
|
48
|
+
variants: n.variants ? i.fromWire(n.variants) : void 0
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
...e,
|
|
53
|
+
entities: t,
|
|
54
|
+
structures: n,
|
|
55
|
+
handlers: r,
|
|
56
|
+
actions: c,
|
|
57
|
+
screens: l
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
async function l() {
|
|
61
|
+
let i = performance.now(), a = n(), { audience: o, ...s } = await t("/api/schema", { cache: "no-cache" });
|
|
62
|
+
if (o === void 0) throw Error("/api/schema answered without its audience");
|
|
63
|
+
let l = c(s);
|
|
64
|
+
return r(a, l.language), e(l), {
|
|
65
|
+
schema: l,
|
|
66
|
+
audience: o,
|
|
67
|
+
requestedAt: i
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
//#endregion
|
|
71
|
+
export { l as fetchSchema };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { isEmbedTokenMode as e } from "../embed/token.js";
|
|
2
|
+
import { backoffDelayMs as t } from "./request-bounds.js";
|
|
3
|
+
import { RefreshDeadError as n, ensureRefresh as r, getPersistentAuthFailureHandler as i } from "./client.js";
|
|
4
|
+
//#region src/api/session-renewal.ts
|
|
5
|
+
var a = 6e4, o = 5e3, s = null, c = null, l = 0, u = !1;
|
|
6
|
+
function d() {
|
|
7
|
+
s && clearTimeout(s), s = null;
|
|
8
|
+
}
|
|
9
|
+
function f(e) {
|
|
10
|
+
d(), s = setTimeout(() => {
|
|
11
|
+
s = null, p();
|
|
12
|
+
}, e);
|
|
13
|
+
}
|
|
14
|
+
function p() {
|
|
15
|
+
u || e() || (d(), u = !0, r().catch((e) => {
|
|
16
|
+
e instanceof n ? i()() : c !== null && f(t(l++));
|
|
17
|
+
}).finally(() => {
|
|
18
|
+
u = !1;
|
|
19
|
+
}));
|
|
20
|
+
}
|
|
21
|
+
function m(e) {
|
|
22
|
+
h();
|
|
23
|
+
let t = e ? Date.parse(e) : NaN;
|
|
24
|
+
Number.isNaN(t) || (c = t, f(Math.max(t - Date.now() - a, o)));
|
|
25
|
+
}
|
|
26
|
+
function h() {
|
|
27
|
+
d(), c = null, l = 0;
|
|
28
|
+
}
|
|
29
|
+
function g() {
|
|
30
|
+
c !== null && Date.now() >= c - 6e4 && p();
|
|
31
|
+
}
|
|
32
|
+
document.addEventListener("visibilitychange", () => {
|
|
33
|
+
document.visibilityState === "visible" && g();
|
|
34
|
+
}), document.addEventListener("resume", g), window.addEventListener("pageshow", g), window.addEventListener("online", g);
|
|
35
|
+
//#endregion
|
|
36
|
+
export { a as PROACTIVE_REFRESH_MARGIN_MS, h as cancelRenewal, m as scheduleRenewal };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { executeAction as e } from "./data.js";
|
|
2
|
+
//#region src/api/status.ts
|
|
3
|
+
async function t(t, n, r, i, a) {
|
|
4
|
+
let o = {
|
|
5
|
+
status_group_code: r,
|
|
6
|
+
status_code: i
|
|
7
|
+
};
|
|
8
|
+
a != null && (o.note = a);
|
|
9
|
+
let s = (await e(`${t}.__update`, {
|
|
10
|
+
object_ids: [n],
|
|
11
|
+
entity: t,
|
|
12
|
+
fields: { $statuses: [o] }
|
|
13
|
+
})).result?.rows?.[0]?.$statuses ?? [];
|
|
14
|
+
return s.find((e) => e.group_code === r) ?? s[0];
|
|
15
|
+
}
|
|
16
|
+
//#endregion
|
|
17
|
+
export { t as setObjectStatus };
|