@nivaro/react 0.3.114 → 0.3.116
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/components/ScreenShareHost.js +24 -0
- package/dist/full.css +50 -2
- package/dist/hooks/useSessionRecorder.js +61 -60
- package/dist/index.d.ts +1728 -22
- package/dist/index.js +1091 -950
- package/dist/shared/components/ActivityEntry.js +209 -97
- package/dist/shared/components/AgentPresenceChip.js +51 -0
- package/dist/shared/components/AnnouncementBanner.js +56 -41
- package/dist/shared/components/AutolinkedText.js +98 -85
- package/dist/shared/components/BroadcastView.js +149 -141
- package/dist/shared/components/CacheStamp.js +78 -30
- package/dist/shared/components/CollectionBrowserView.js +4909 -4182
- package/dist/shared/components/ConfigChangeStrip.js +63 -0
- package/dist/shared/components/ConfigReachNote.js +107 -0
- package/dist/shared/components/ConformanceView.js +389 -319
- package/dist/shared/components/DataTable.js +612 -551
- package/dist/shared/components/DelegateCoverLine.js +164 -0
- package/dist/shared/components/EnvironmentNotice.js +56 -65
- package/dist/shared/components/FilePreviewLightbox.js +89 -43
- package/dist/shared/components/FindingFixedMark.js +23 -0
- package/dist/shared/components/GridPresenceLine.js +100 -0
- package/dist/shared/components/IdleReloadWatcher.js +82 -43
- package/dist/shared/components/InStep.js +46 -0
- package/dist/shared/components/ItemEditForm.js +5504 -4889
- package/dist/shared/components/LiveAnnouncer.js +62 -0
- package/dist/shared/components/LiveCount.js +54 -0
- package/dist/shared/components/LiveFigure.js +28 -0
- package/dist/shared/components/LiveListControls.js +114 -0
- package/dist/shared/components/LiveNewMatchesPill.js +25 -0
- package/dist/shared/components/LiveOffNote.js +44 -0
- package/dist/shared/components/LivePreferenceHost.js +42 -0
- package/dist/shared/components/LiveRowMark.js +25 -20
- package/dist/shared/components/LiveTraceView.js +257 -0
- package/dist/shared/components/MapView.js +30 -29
- package/dist/shared/components/MatrixEditor.js +497 -462
- package/dist/shared/components/MyWorkView.js +346 -272
- package/dist/shared/components/NotificationBell.js +215 -201
- package/dist/shared/components/OverflowRail.js +326 -0
- package/dist/shared/components/PageRenderer.js +636 -599
- package/dist/shared/components/PresenceDot.js +21 -0
- package/dist/shared/components/ProfileView.js +656 -536
- package/dist/shared/components/RealtimeStatusBanner.js +25 -25
- package/dist/shared/components/RecentRecordsRail.js +51 -48
- package/dist/shared/components/RecordCompare.js +241 -150
- package/dist/shared/components/RecordDrilldownSheet.js +66 -64
- package/dist/shared/components/RecordGridEditor.js +350 -311
- package/dist/shared/components/RecordHoverCard.js +147 -0
- package/dist/shared/components/RecordPeekHost.js +111 -0
- package/dist/shared/components/RecordReadView.js +414 -412
- package/dist/shared/components/RelativeTime.js +16 -0
- package/dist/shared/components/ReportView.js +1396 -1304
- package/dist/shared/components/ScreenRefreshButton.js +77 -0
- package/dist/shared/components/TabCountHost.js +10 -0
- package/dist/shared/components/TickerNumber.js +19 -18
- package/dist/shared/components/TipLayer.js +70 -58
- package/dist/shared/components/WidgetImageMenu.js +59 -0
- package/dist/shared/components/WidgetSlot.js +571 -524
- package/dist/shared/components/activity/RecordActivityStream.js +317 -0
- package/dist/shared/components/bulk/BulkSelectionNotices.js +220 -0
- package/dist/shared/components/cbv/approval-changed.js +20 -0
- package/dist/shared/components/cbv/changed-by-others.js +251 -0
- package/dist/shared/components/change-proposals/ChangeProposalsPanel.js +320 -0
- package/dist/shared/components/change-proposals/ProposalValue.js +28 -0
- package/dist/shared/components/change-proposals/ProposeChangeButton.js +44 -0
- package/dist/shared/components/change-proposals/ProposeChangeDialog.js +359 -0
- package/dist/shared/components/change-proposals/types.js +4 -0
- package/dist/shared/components/chat/ChatPanel.js +1571 -1528
- package/dist/shared/components/chat/Composer.js +276 -298
- package/dist/shared/components/chat/room-due.js +13 -0
- package/dist/shared/components/collections-directory/CollectionRow.js +76 -75
- package/dist/shared/components/collections-directory/CollectionsDirectory.js +415 -395
- package/dist/shared/components/collections-directory/directory-data.js +75 -63
- package/dist/shared/components/imports/ImportConsole.js +159 -155
- package/dist/shared/components/imports/ImportDuplicatesNotice.js +46 -31
- package/dist/shared/components/integrations/SendStatus.js +202 -0
- package/dist/shared/components/integrations/console/IntegrationsConsole.js +45 -36
- package/dist/shared/components/integrations/console/ReadyToSendView.js +453 -0
- package/dist/shared/components/integrations/console/SignalCard.js +84 -77
- package/dist/shared/components/integrations/console/api.js +161 -117
- package/dist/shared/components/integrations/console/tone.js +15 -12
- package/dist/shared/components/item-edit/CatalogPickerField.js +1353 -1245
- package/dist/shared/components/item-edit/ChangedAfterApprovalBadge.js +162 -0
- package/dist/shared/components/item-edit/CloneDialog.js +208 -206
- package/dist/shared/components/item-edit/DerivedCauseNote.js +57 -0
- package/dist/shared/components/item-edit/DraftRecoveryBanner.js +81 -70
- package/dist/shared/components/item-edit/DuplicateNotice.js +169 -101
- package/dist/shared/components/item-edit/FieldAffordances.js +294 -385
- package/dist/shared/components/item-edit/FieldComments.js +159 -116
- package/dist/shared/components/item-edit/FieldPointer.js +132 -0
- package/dist/shared/components/item-edit/FieldRenderer.js +277 -273
- package/dist/shared/components/item-edit/FieldRow.js +519 -439
- package/dist/shared/components/item-edit/FieldSourceBadge.js +88 -0
- package/dist/shared/components/item-edit/FilePickerField.js +454 -369
- package/dist/shared/components/item-edit/GroupSection.js +618 -567
- package/dist/shared/components/item-edit/HeldEditsChip.js +113 -0
- package/dist/shared/components/item-edit/InlineTableField.js +2891 -2723
- package/dist/shared/components/item-edit/ListNeighborNav.js +79 -0
- package/dist/shared/components/item-edit/LiveTraceSheet.js +26 -0
- package/dist/shared/components/item-edit/M2MCombobox.js +284 -273
- package/dist/shared/components/item-edit/OutboxReviewTray.js +313 -0
- package/dist/shared/components/item-edit/PickerBadges.js +52 -0
- package/dist/shared/components/item-edit/PlanGrid.js +434 -439
- package/dist/shared/components/item-edit/RecalcValue.js +55 -0
- package/dist/shared/components/item-edit/RecordChatActions.js +76 -64
- package/dist/shared/components/item-edit/RecordChatMentionsChip.js +103 -0
- package/dist/shared/components/item-edit/RecordGrantTools.js +87 -86
- package/dist/shared/components/item-edit/RecordHelpChip.js +70 -0
- package/dist/shared/components/item-edit/RecordLiveSync.js +230 -217
- package/dist/shared/components/item-edit/RecordOutbox.js +53 -52
- package/dist/shared/components/item-edit/RecordRecapStrip.js +109 -36
- package/dist/shared/components/item-edit/RelationCombobox.js +229 -217
- package/dist/shared/components/item-edit/RelationGroupedCombobox.js +105 -100
- package/dist/shared/components/item-edit/RemoteChangeUi.js +454 -0
- package/dist/shared/components/item-edit/RemoteUploads.js +55 -0
- package/dist/shared/components/item-edit/RemovedLineNote.js +92 -0
- package/dist/shared/components/item-edit/RichTextEditorImpl.js +298 -223
- package/dist/shared/components/item-edit/ScheduledChangeChip.js +244 -0
- package/dist/shared/components/item-edit/SectionPresence.js +78 -0
- package/dist/shared/components/item-edit/SplitLinesButton.js +166 -0
- package/dist/shared/components/item-edit/catalog-line-watch.js +94 -0
- package/dist/shared/components/item-edit/coedit/collab.js +84 -0
- package/dist/shared/components/item-edit/coedit/context.js +24 -0
- package/dist/shared/components/item-edit/coedit/cursors.js +103 -0
- package/dist/shared/components/item-edit/coedit/safe-link.js +15 -0
- package/dist/shared/components/item-edit/coedit/session.js +382 -0
- package/dist/shared/components/item-edit/coedit/useCoedit.js +49 -0
- package/dist/shared/components/item-edit/file-live.js +77 -0
- package/dist/shared/components/item-edit/file-processing.js +87 -0
- package/dist/shared/components/item-edit/layout-switch.js +148 -0
- package/dist/shared/components/item-edit/live-related.js +23 -0
- package/dist/shared/components/item-edit/live-title.js +66 -0
- package/dist/shared/components/item-edit/partner-needs.js +142 -0
- package/dist/shared/components/item-edit/removed-line.js +58 -0
- package/dist/shared/components/item-edit/render-stability.js +70 -59
- package/dist/shared/components/layout-editor/ChangeNote.js +36 -34
- package/dist/shared/components/layout-editor/CollabParts.js +72 -70
- package/dist/shared/components/layout-editor/LayoutEditor.js +306 -303
- package/dist/shared/components/list/InlineEdit.js +504 -208
- package/dist/shared/components/list/ListViewers.js +81 -0
- package/dist/shared/components/list/PhonePager.js +50 -0
- package/dist/shared/components/merge/MergeRecordsDialog.js +1227 -0
- package/dist/shared/components/merge/MergeWithFlow.js +290 -0
- package/dist/shared/components/merge/merge-values.js +110 -0
- package/dist/shared/components/monitoring/InactiveUserLinksView.js +285 -258
- package/dist/shared/components/notifications/NotificationCenterView.js +389 -323
- package/dist/shared/components/notifications/NotificationDetailBits.js +205 -130
- package/dist/shared/components/notifications/NotificationRulesEditor.js +72 -52
- package/dist/shared/components/notifications/bundles.js +21 -19
- package/dist/shared/components/notifications/resolved-line.js +25 -0
- package/dist/shared/components/ops/OpsTasksView.js +45 -44
- package/dist/shared/components/panels/AccessGrantedNote.js +85 -0
- package/dist/shared/components/panels/AlertBanners.js +132 -0
- package/dist/shared/components/panels/AsyncUserPicker.js +54 -45
- package/dist/shared/components/panels/BranchLanes.js +82 -54
- package/dist/shared/components/panels/CommentAwareness.js +332 -0
- package/dist/shared/components/panels/CommentImages.js +219 -0
- package/dist/shared/components/panels/CommentPanel.js +649 -530
- package/dist/shared/components/panels/ExternalRequestsChip.js +98 -80
- package/dist/shared/components/panels/NewSinceChip.js +16 -0
- package/dist/shared/components/panels/OwnerOpenedLine.js +85 -0
- package/dist/shared/components/panels/PipelinePanel.js +1644 -1494
- package/dist/shared/components/panels/ResubmissionDiff.js +293 -0
- package/dist/shared/components/panels/SlaBreachBanner.js +30 -29
- package/dist/shared/components/panels/SlaClock.js +130 -99
- package/dist/shared/components/panels/TaskPanel.js +308 -287
- package/dist/shared/components/panels/unseen-move-check.js +101 -0
- package/dist/shared/components/pipeline/OwnerMatrix.js +80 -71
- package/dist/shared/components/pipeline/OwnerMatrixSheet.js +495 -0
- package/dist/shared/components/pipeline/PipelineEditorView.js +2050 -1942
- package/dist/shared/components/profile/AgentNameField.js +141 -0
- package/dist/shared/components/profile/AgentsPanel.js +55 -46
- package/dist/shared/components/profile/PersonAccess.js +398 -330
- package/dist/shared/components/profile/PersonAdminTools.js +127 -113
- package/dist/shared/components/profile/PersonProfile.js +81 -73
- package/dist/shared/components/profile/SignInTroubleshooter.js +361 -0
- package/dist/shared/components/queue/OwnerAvatars.js +9 -9
- package/dist/shared/components/queue/QueueBulkBar.js +101 -84
- package/dist/shared/components/queue/QueueItemSheet.js +66 -66
- package/dist/shared/components/queue/QueueTeamStrip.js +279 -0
- package/dist/shared/components/queue/QueueWorklist.js +2407 -1950
- package/dist/shared/components/queue/worklist-helpers.js +10 -6
- package/dist/shared/components/send-view/SendViewButton.js +136 -0
- package/dist/shared/components/send-view/SentViewCards.js +147 -0
- package/dist/shared/components/support/ReportProblem.js +1 -0
- package/dist/shared/components/support/ScreenShare.js +554 -0
- package/dist/shared/components/support/SupportView.js +160 -129
- package/dist/shared/components/support/TicketDetailSheet.js +101 -89
- package/dist/shared/components/ui/popover.js +53 -29
- package/dist/shared/components/watch-list/WatchDock.js +1044 -0
- package/dist/shared/components/watch-list/WatchExtras.js +723 -0
- package/dist/shared/components/watch-list/WatchListButton.js +46 -0
- package/dist/shared/components/watch-list/WatchPinButton.js +67 -0
- package/dist/shared/components/watch-list/WatchRows.js +348 -0
- package/dist/shared/lib/activity-sentence.js +87 -75
- package/dist/shared/lib/agent-presence.js +46 -0
- package/dist/shared/lib/approval-progress.js +49 -0
- package/dist/shared/lib/attention-prefs.js +27 -0
- package/dist/shared/lib/cell-locks.js +56 -0
- package/dist/shared/lib/co-edit.js +166 -0
- package/dist/shared/lib/coedit-registry.js +44 -0
- package/dist/shared/lib/comment-awareness.js +124 -0
- package/dist/shared/lib/comment-images.js +45 -0
- package/dist/shared/lib/config-watch.js +94 -0
- package/dist/shared/lib/copy-rules.js +65 -0
- package/dist/shared/lib/count-step.js +30 -0
- package/dist/shared/lib/deadline-ticker.js +68 -0
- package/dist/shared/lib/derived-causes.js +115 -0
- package/dist/shared/lib/draft-store.js +114 -85
- package/dist/shared/lib/error-hints.js +1 -0
- package/dist/shared/lib/field-merge.js +126 -0
- package/dist/shared/lib/filter-sentence.js +10 -10
- package/dist/shared/lib/focus-mode.js +16 -12
- package/dist/shared/lib/grid-cursors.js +77 -0
- package/dist/shared/lib/grid-presence.js +182 -0
- package/dist/shared/lib/idle-reload.js +100 -73
- package/dist/shared/lib/in-step.js +45 -0
- package/dist/shared/lib/integration-chip.js +19 -18
- package/dist/shared/lib/keep-row-focus.js +43 -0
- package/dist/shared/lib/line-locks.js +141 -0
- package/dist/shared/lib/line-split.js +41 -0
- package/dist/shared/lib/linked-changes.js +150 -0
- package/dist/shared/lib/list-return.js +231 -0
- package/dist/shared/lib/list-viewers.js +52 -0
- package/dist/shared/lib/live-announcer.js +86 -0
- package/dist/shared/lib/live-counts.js +85 -0
- package/dist/shared/lib/live-data-changed.js +108 -0
- package/dist/shared/lib/live-deltas.js +81 -0
- package/dist/shared/lib/live-findings.js +113 -0
- package/dist/shared/lib/live-groups.js +122 -0
- package/dist/shared/lib/live-link-labels.js +162 -0
- package/dist/shared/lib/live-list-flow.js +334 -0
- package/dist/shared/lib/live-list.js +143 -129
- package/dist/shared/lib/live-moves.js +51 -0
- package/dist/shared/lib/live-ops.js +26 -26
- package/dist/shared/lib/live-pickers.js +7 -0
- package/dist/shared/lib/live-preference.js +184 -0
- package/dist/shared/lib/live-queries.js +226 -181
- package/dist/shared/lib/live-screen.js +333 -0
- package/dist/shared/lib/live-search.js +108 -0
- package/dist/shared/lib/live-seen.js +35 -0
- package/dist/shared/lib/live-views.js +100 -0
- package/dist/shared/lib/live.js +159 -133
- package/dist/shared/lib/missed-updates.js +198 -0
- package/dist/shared/lib/newer-file.js +56 -0
- package/dist/shared/lib/notification-sound.js +42 -20
- package/dist/shared/lib/obligation-banner.js +17 -17
- package/dist/shared/lib/own-writes.js +59 -41
- package/dist/shared/lib/picker-badges.js +94 -0
- package/dist/shared/lib/presence-signals.js +131 -84
- package/dist/shared/lib/rail-menu-context.js +9 -0
- package/dist/shared/lib/realtime.js +49 -24
- package/dist/shared/lib/record-gaps.js +85 -0
- package/dist/shared/lib/record-outbox.js +369 -222
- package/dist/shared/lib/record-peek.js +75 -0
- package/dist/shared/lib/record-tabs.js +92 -72
- package/dist/shared/lib/relative-ticker.js +42 -0
- package/dist/shared/lib/request-gate.js +119 -119
- package/dist/shared/lib/rollup-recalc.js +107 -0
- package/dist/shared/lib/room-gaps.js +40 -36
- package/dist/shared/lib/row-surface.js +7 -0
- package/dist/shared/lib/rum.js +137 -87
- package/dist/shared/lib/save-progress.js +20 -0
- package/dist/shared/lib/scheduled-countdown.js +67 -0
- package/dist/shared/lib/screen-refresh.js +160 -0
- package/dist/shared/lib/screen-share.js +234 -0
- package/dist/shared/lib/seen-since.js +74 -0
- package/dist/shared/lib/selection-watch.js +205 -0
- package/dist/shared/lib/send-status.js +132 -0
- package/dist/shared/lib/send-view.js +23 -0
- package/dist/shared/lib/socket-liveness.js +155 -0
- package/dist/shared/lib/socket-realtime.js +168 -140
- package/dist/shared/lib/state-census.js +53 -0
- package/dist/shared/lib/summary-mode.js +61 -39
- package/dist/shared/lib/tab-attention.js +143 -32
- package/dist/shared/lib/table-density.js +64 -0
- package/dist/shared/lib/table-pins.js +20 -18
- package/dist/shared/lib/track-travel.js +40 -0
- package/dist/shared/lib/unseen-changes.js +68 -0
- package/dist/shared/lib/upload-file.js +62 -0
- package/dist/shared/lib/upload-presence.js +127 -0
- package/dist/shared/lib/urgent-chime.js +65 -0
- package/dist/shared/lib/use-below-md.js +29 -0
- package/dist/shared/lib/use-online-users.js +32 -11
- package/dist/shared/lib/user-sync.js +155 -39
- package/dist/shared/lib/waiting-count.js +44 -0
- package/dist/shared/lib/watch-desktop.js +83 -0
- package/dist/shared/lib/watch-list.js +447 -0
- package/dist/shared/lib/widget-image-render.js +64 -0
- package/dist/shared/lib/widget-image.js +111 -0
- package/dist/shared/lib/worker-socket.js +130 -104
- package/dist/shared/lib/write-to-screen.js +133 -0
- package/package.json +1 -1
- package/styles.css +49 -1
package/dist/index.d.ts
CHANGED
|
@@ -124,6 +124,9 @@ declare interface ActiveLayoutData {
|
|
|
124
124
|
/** The `?layout=` this page was opened with names no form the person may
|
|
125
125
|
* open: the answer is the usual form, and the page says so (army11 f3). */
|
|
126
126
|
requested_form_unavailable?: boolean;
|
|
127
|
+
/** Fields any candidate form's record rules read (rt8 #18): a change to one — or a move —
|
|
128
|
+
* re-asks which form applies to the open record. Absent when a form was pinned by name. */
|
|
129
|
+
rule_fields?: string[];
|
|
127
130
|
}
|
|
128
131
|
|
|
129
132
|
/** Who really did it (nivaro_activity.actor, migration 516; derived for older rows). */
|
|
@@ -174,7 +177,7 @@ declare interface ActivityChange {
|
|
|
174
177
|
value?: unknown;
|
|
175
178
|
}
|
|
176
179
|
|
|
177
|
-
export declare function ActivityEntry({ entry, labels, group, onOpen, actions, showTime, className }: ActivityEntryProps): JSX.Element;
|
|
180
|
+
export declare function ActivityEntry({ entry, labels, group, onOpen, actions, showTime, className, omitPhrases, reserveChevron }: ActivityEntryProps): JSX.Element;
|
|
178
181
|
|
|
179
182
|
export declare interface ActivityEntryInput {
|
|
180
183
|
id?: number | string | null;
|
|
@@ -244,10 +247,17 @@ export declare interface ActivityEntryProps {
|
|
|
244
247
|
/** Show the time at the row's end (default true). */
|
|
245
248
|
showTime?: boolean;
|
|
246
249
|
className?: string;
|
|
250
|
+
/**
|
|
251
|
+
* Record phrases the sentence leaves out ("Project 12 – Alpha"): on a record's own stream the
|
|
252
|
+
* subject is the page itself, so "updated Project 12 – Alpha 3 times" reads "updated 3 times".
|
|
253
|
+
*/
|
|
254
|
+
omitPhrases?: string[];
|
|
255
|
+
/** Keep the chevron's room on rows that do not fold, so every sentence starts at one edge. */
|
|
256
|
+
reserveChevron?: boolean;
|
|
247
257
|
}
|
|
248
258
|
|
|
249
259
|
/** A list of entries with bursts folded (groupActivity) — each group one ActivityEntry. */
|
|
250
|
-
export declare function ActivityFeed({ entries, labels, onOpen, actionsFor, empty, className }: {
|
|
260
|
+
export declare function ActivityFeed({ entries, labels, onOpen, actionsFor, empty, className, isFresh }: {
|
|
251
261
|
entries: ActivityEntryInput[];
|
|
252
262
|
labels?: ActivityLabels | null;
|
|
253
263
|
onOpen?: (entry: ActivityEntryInput) => void;
|
|
@@ -255,6 +265,8 @@ export declare function ActivityFeed({ entries, labels, onOpen, actionsFor, empt
|
|
|
255
265
|
actionsFor?: (group: ActivityGroup) => ReactNode;
|
|
256
266
|
empty?: ReactNode;
|
|
257
267
|
className?: string;
|
|
268
|
+
/** A live feed (rt4 #15): entries that just arrived fade in once (no motion when reduced). */
|
|
269
|
+
isFresh?: (entry: ActivityEntryInput) => boolean;
|
|
258
270
|
}): JSX.Element;
|
|
259
271
|
|
|
260
272
|
declare interface ActivityGroup<T extends ActivityEntryInput = ActivityEntryInput> {
|
|
@@ -367,6 +379,36 @@ export declare function AddendumPanel({ collection, item, addendumLayoutId, canC
|
|
|
367
379
|
defaultExpanded?: boolean;
|
|
368
380
|
}): JSX.Element | null;
|
|
369
381
|
|
|
382
|
+
/**
|
|
383
|
+
* Agents working on a record right now (rt8 #21): "Claude (for Rob) is updating this record".
|
|
384
|
+
*
|
|
385
|
+
* The server marks a record whenever an AI agent's tool call (hosted MCP) reads or writes it
|
|
386
|
+
* and tells the record room `record:agents` with the whole current list; a socket that joins the
|
|
387
|
+
* room later is told once on join (api services/agent-presence.ts). The room admits only people
|
|
388
|
+
* who may open the record, so this hook never learns about an agent on a record its viewer
|
|
389
|
+
* cannot see. Names only: the name the agent's connection goes by (its owner or an administrator
|
|
390
|
+
* sets it) and the person it acts for.
|
|
391
|
+
*
|
|
392
|
+
* A presence indicator: quiet in Calm and Off (the live preference seam drops the event, and
|
|
393
|
+
* anything already shown clears).
|
|
394
|
+
*/
|
|
395
|
+
declare type AgentMode = 'reading' | 'updating';
|
|
396
|
+
|
|
397
|
+
/**
|
|
398
|
+
* "Claude (for Rob) is updating this record" — beside a record's viewers while an AI agent
|
|
399
|
+
* reads or writes it (rt8 #21). Quiet text, no motion beyond a soft dot while it writes (none
|
|
400
|
+
* with reduced motion); nothing at all in Calm / Off or when no agent is there. Several agents
|
|
401
|
+
* show the first sentence and "+N", every sentence in the tip.
|
|
402
|
+
*/
|
|
403
|
+
export declare function AgentPresenceChip({ collection, item, className }: {
|
|
404
|
+
collection: string | null | undefined;
|
|
405
|
+
item: string | number | null | undefined;
|
|
406
|
+
className?: string;
|
|
407
|
+
}): JSX.Element | null;
|
|
408
|
+
|
|
409
|
+
/** "Claude (for Rob) is updating this record" (pure). `meId` reads the viewer's own as "you". */
|
|
410
|
+
export declare function agentSentence(a: RecordAgent, meId?: string | null, short?: boolean): string;
|
|
411
|
+
|
|
370
412
|
export declare function agingBucket(hours: number | null): string;
|
|
371
413
|
|
|
372
414
|
export declare function AiAnalyticsView(): JSX.Element;
|
|
@@ -548,6 +590,46 @@ export declare function AiReviewCard({ templateId }: {
|
|
|
548
590
|
*/
|
|
549
591
|
declare type AiStreamSubscribe = (event: 'ai:delta' | 'ai:status' | 'ai:done' | 'ai:error', handler: (payload: Record<string, unknown>) => void) => () => void;
|
|
550
592
|
|
|
593
|
+
/**
|
|
594
|
+
* Threshold banners (realtime round 9, item 20): "Project US201979 just crossed 90%".
|
|
595
|
+
*
|
|
596
|
+
* Shows crossings of the alert definitions an administrator switched to "Show as a banner"
|
|
597
|
+
* (Alerts → definition). Record mode (`itemId`) sits in a record page's banner stack; without
|
|
598
|
+
* `itemId` it lists the collection's newest crossings (a budget console, a project hub). Each
|
|
599
|
+
* banner is dismissed for the viewer alone; a later crossing shows again. Read as the viewer
|
|
600
|
+
* (GET /alerts/banners), live: a new crossing (`$alerts`) or a write to a field a banner
|
|
601
|
+
* watches re-reads it once per burst — no toast, no sound, nothing moves under the pointer.
|
|
602
|
+
* Renders nothing when there is nothing to say.
|
|
603
|
+
*/
|
|
604
|
+
export declare interface AlertBannerData {
|
|
605
|
+
log_id: number;
|
|
606
|
+
definition_id: number;
|
|
607
|
+
name: string;
|
|
608
|
+
collection: string;
|
|
609
|
+
item: string;
|
|
610
|
+
record: string;
|
|
611
|
+
field: string;
|
|
612
|
+
operator: string;
|
|
613
|
+
threshold: number;
|
|
614
|
+
unit: string;
|
|
615
|
+
value: number | null;
|
|
616
|
+
triggered_at: string;
|
|
617
|
+
phrase: string;
|
|
618
|
+
}
|
|
619
|
+
|
|
620
|
+
export declare function AlertBanners({ collection, itemId, max, onOpenRecord, className }: {
|
|
621
|
+
collection: string;
|
|
622
|
+
/** One record's banners; omit for the collection's newest crossings. */
|
|
623
|
+
itemId?: string | null;
|
|
624
|
+
/** Collection mode: how many show before "N more". */
|
|
625
|
+
max?: number;
|
|
626
|
+
/** Collection mode: open the record a banner names. */
|
|
627
|
+
onOpenRecord?: (collection: string, item: string) => void;
|
|
628
|
+
className?: string;
|
|
629
|
+
}): JSX.Element | null;
|
|
630
|
+
|
|
631
|
+
export declare const alertBannersKey: (collection: string, itemId?: string | null) => readonly ["alert-banners", string, string];
|
|
632
|
+
|
|
551
633
|
export declare function AlertManagerView({ defaultTab, hiddenTabs, onOpenReport, className }: AlertManagerViewProps): JSX.Element;
|
|
552
634
|
|
|
553
635
|
export declare interface AlertManagerViewProps {
|
|
@@ -1140,6 +1222,12 @@ declare type BinaryOp = '+' | '-' | '*' | '/' | '==' | '!=' | '<' | '<=' | '>' |
|
|
|
1140
1222
|
*/
|
|
1141
1223
|
export declare function bindClientChaosSocket(socket: ClientChaosSocket | null | undefined): () => void;
|
|
1142
1224
|
|
|
1225
|
+
/**
|
|
1226
|
+
* Wire the host's record-room socket to this module for one record. Returns the cleanup. The
|
|
1227
|
+
* host still joins/leaves the room and paints its own field outlines; this only listens.
|
|
1228
|
+
*/
|
|
1229
|
+
export declare function bindRecordCoEdit(socket: CoEditSocket, collection: string, item: string | number, selfId: string | null | undefined): () => void;
|
|
1230
|
+
|
|
1143
1231
|
declare interface Blur {
|
|
1144
1232
|
id: string;
|
|
1145
1233
|
start_ms: number;
|
|
@@ -1194,6 +1282,9 @@ export declare function buildReportPayload(input: {
|
|
|
1194
1282
|
} | null;
|
|
1195
1283
|
}): ReportProblemPayload;
|
|
1196
1284
|
|
|
1285
|
+
/** Everything that is printed on the picture, in order. */
|
|
1286
|
+
export declare function buildWidgetImageLabel(input: WidgetImageInput): WidgetImageLabel;
|
|
1287
|
+
|
|
1197
1288
|
export declare function BulkActionButtons({ targets, enabledKeys, tone, disabled, onDone }: {
|
|
1198
1289
|
targets: BulkTarget[];
|
|
1199
1290
|
/** Surface allow-list (browser_config.bulk_actions / display_config.bulk_action_keys). */
|
|
@@ -1240,11 +1331,18 @@ declare interface BulkTarget {
|
|
|
1240
1331
|
* a report served from Redis is indistinguishable from one just computed.
|
|
1241
1332
|
* Renders nothing for an uncached query — there is nothing to disclose.
|
|
1242
1333
|
*/
|
|
1243
|
-
export declare function CacheStamp({ envelope, onRefresh, refreshing, className }: {
|
|
1334
|
+
export declare function CacheStamp({ envelope, onRefresh, refreshing, className, changedLive, autoRefresh }: {
|
|
1244
1335
|
envelope: CustomQueryEnvelope | undefined;
|
|
1245
1336
|
onRefresh?: () => void;
|
|
1246
1337
|
refreshing?: boolean;
|
|
1247
1338
|
className?: string;
|
|
1339
|
+
/** A table this figure reads changed since it was computed (see LiveCacheStamp). */
|
|
1340
|
+
changedLive?: boolean;
|
|
1341
|
+
/** The viewer's opt-in to refresh by itself when that happens. */
|
|
1342
|
+
autoRefresh?: {
|
|
1343
|
+
on: boolean;
|
|
1344
|
+
onChange: (on: boolean) => void;
|
|
1345
|
+
} | null;
|
|
1248
1346
|
}): JSX.Element | null;
|
|
1249
1347
|
|
|
1250
1348
|
export declare function CallerChangesSection({ caller, hours }: {
|
|
@@ -1412,8 +1510,19 @@ declare type CascadeSwapConfig = {
|
|
|
1412
1510
|
* record the click came from. Shape is host-interpreted. */
|
|
1413
1511
|
declare type CatalogItemOpener = (id: string, context?: Record<string, unknown>) => void;
|
|
1414
1512
|
|
|
1513
|
+
declare interface CellAnnouncer {
|
|
1514
|
+
/** Focus is in this cell now (null = focus left every cell). */
|
|
1515
|
+
focus: (cell: string | null) => void;
|
|
1516
|
+
/** Focus left the grid. */
|
|
1517
|
+
blur: () => void;
|
|
1518
|
+
/** Send any pending end now (unmount). */
|
|
1519
|
+
flush: () => void;
|
|
1520
|
+
}
|
|
1521
|
+
|
|
1415
1522
|
export declare function CellCopyLayer(): ReactPortal | null;
|
|
1416
1523
|
|
|
1524
|
+
declare type CellEmit = (cell: string, state: 'start' | 'end') => void;
|
|
1525
|
+
|
|
1417
1526
|
declare interface CellFilterLite {
|
|
1418
1527
|
field: string;
|
|
1419
1528
|
value: unknown;
|
|
@@ -1906,6 +2015,13 @@ export declare function clearRecordOutbox(): Promise<void>;
|
|
|
1906
2015
|
|
|
1907
2016
|
export declare function clearSignOutNote(): void;
|
|
1908
2017
|
|
|
2018
|
+
declare interface ClickLike {
|
|
2019
|
+
metaKey?: boolean;
|
|
2020
|
+
ctrlKey?: boolean;
|
|
2021
|
+
shiftKey?: boolean;
|
|
2022
|
+
button?: number;
|
|
2023
|
+
}
|
|
2024
|
+
|
|
1909
2025
|
/**
|
|
1910
2026
|
* Browser chaos mode (#2840) — this tab's own requests fail or slow down for a set time, so a
|
|
1911
2027
|
* tester can watch error boundaries, retry UI, autosave and the offline outbox do their job
|
|
@@ -2084,6 +2200,7 @@ export declare function CloneDialog({ collection, itemId, fields, relations, cur
|
|
|
2084
2200
|
declare interface CloneDialogProps {
|
|
2085
2201
|
collection: string;
|
|
2086
2202
|
itemId: string;
|
|
2203
|
+
/** The record's fields in the order the form shows them. */
|
|
2087
2204
|
fields: CMSField[];
|
|
2088
2205
|
relations: CMSRelation[];
|
|
2089
2206
|
currentValues: Record<string, unknown>;
|
|
@@ -2137,6 +2254,43 @@ declare interface CMSRelation {
|
|
|
2137
2254
|
one_allowed_collections?: string | string[] | null;
|
|
2138
2255
|
}
|
|
2139
2256
|
|
|
2257
|
+
declare interface Coalescer {
|
|
2258
|
+
/** Something moved: schedule (or push back) the call. */
|
|
2259
|
+
poke: () => void;
|
|
2260
|
+
/** The tab came back to the front: make the call now if one is owed. */
|
|
2261
|
+
resume: () => void;
|
|
2262
|
+
/** Drop anything scheduled. */
|
|
2263
|
+
cancel: () => void;
|
|
2264
|
+
/** A call is scheduled or owed (tests). */
|
|
2265
|
+
pending: () => boolean;
|
|
2266
|
+
}
|
|
2267
|
+
|
|
2268
|
+
/**
|
|
2269
|
+
* Counts that follow the data — quietly (realtime program 2026-11-14, ideas 9 + 19).
|
|
2270
|
+
*
|
|
2271
|
+
* A count (a tab total, a view pill, a badge) is a read the viewer's own permissions answer,
|
|
2272
|
+
* so a live event can only ever say "this may have moved"; the number is then re-read through
|
|
2273
|
+
* its normal route. What this file adds is the discipline around that re-read:
|
|
2274
|
+
*
|
|
2275
|
+
* - `createCoalescer` turns any number of pokes into ONE call: it waits until the pokes have
|
|
2276
|
+
* been quiet for `quietMs` (default 2 s), but never later than `maxWaitMs` after the first
|
|
2277
|
+
* poke of a burst, so a steady stream still refreshes. A hidden tab does not call; it owes
|
|
2278
|
+
* one call for when it is shown again.
|
|
2279
|
+
* - `useLiveRefresh` hangs that on an ops topic and/or a list of query keys: one refresh per
|
|
2280
|
+
* quiet window for every count that names the same keys, however many components ask.
|
|
2281
|
+
* - `LiveCount` shows the number and cross-fades when it changes (no bounce, no movement;
|
|
2282
|
+
* reduced motion just swaps).
|
|
2283
|
+
*/
|
|
2284
|
+
declare interface CoalescerOptions {
|
|
2285
|
+
/** Call once pokes have stopped for this long (default 2000). */
|
|
2286
|
+
quietMs?: number;
|
|
2287
|
+
/** …but never later than this after the first poke of a burst (default 15000). */
|
|
2288
|
+
maxWaitMs?: number;
|
|
2289
|
+
/** Whether the tab is on screen (default: `document.visibilityState !== 'hidden'`). */
|
|
2290
|
+
isVisible?: () => boolean;
|
|
2291
|
+
now?: () => number;
|
|
2292
|
+
}
|
|
2293
|
+
|
|
2140
2294
|
declare interface CoalescingOptions {
|
|
2141
2295
|
/**
|
|
2142
2296
|
* #1304: record reads (`GET /items/<c>` and `GET /items/<c>/<id>`) fired in
|
|
@@ -2161,6 +2315,13 @@ declare interface CoalescingOptions {
|
|
|
2161
2315
|
batchCollections?: boolean;
|
|
2162
2316
|
}
|
|
2163
2317
|
|
|
2318
|
+
/** The socket calls this module needs (socket.io's Socket and the worker facade both fit). */
|
|
2319
|
+
export declare interface CoEditSocket {
|
|
2320
|
+
on(event: string, cb: (payload: any) => void): unknown;
|
|
2321
|
+
off(event: string, cb: (payload: any) => void): unknown;
|
|
2322
|
+
emit(event: string, payload: unknown): unknown;
|
|
2323
|
+
}
|
|
2324
|
+
|
|
2164
2325
|
/** @deprecated Column model changed to plain field keys — kept for source
|
|
2165
2326
|
* compatibility with early adopters; maps `path` to a field key. */
|
|
2166
2327
|
export declare interface CollectionBrowserColumn {
|
|
@@ -2170,7 +2331,7 @@ export declare interface CollectionBrowserColumn {
|
|
|
2170
2331
|
filterable?: boolean;
|
|
2171
2332
|
}
|
|
2172
2333
|
|
|
2173
|
-
export declare function CollectionBrowserView({ collection, quickFilters, initialColumns, initialSort, pageSize, initialSearch, initialFilters, initialConditions, onOpenItem, initialAiPrompt, extraViews, showCreate, className }: CollectionBrowserViewProps): React_2.JSX.Element;
|
|
2334
|
+
export declare function CollectionBrowserView({ collection, quickFilters, initialColumns, initialSort, pageSize, initialSearch, initialFilters, initialConditions, onOpenItem, initialAiPrompt, extraViews, showCreate, viewersInHeader, className }: CollectionBrowserViewProps): React_2.JSX.Element;
|
|
2174
2335
|
|
|
2175
2336
|
export declare interface CollectionBrowserViewProps {
|
|
2176
2337
|
collection: string;
|
|
@@ -2210,6 +2371,9 @@ export declare interface CollectionBrowserViewProps {
|
|
|
2210
2371
|
render: () => React_2.ReactNode;
|
|
2211
2372
|
}>;
|
|
2212
2373
|
showCreate?: boolean;
|
|
2374
|
+
/** The host's header row shows who else has this list open (admin list page), so the
|
|
2375
|
+
* toolbar keeps no slot for it. */
|
|
2376
|
+
viewersInHeader?: boolean;
|
|
2213
2377
|
className?: string;
|
|
2214
2378
|
}
|
|
2215
2379
|
|
|
@@ -2484,6 +2648,13 @@ export declare type ComponentOverrides = {
|
|
|
2484
2648
|
* several conditions AND together. */
|
|
2485
2649
|
export declare function conditionsToFilter(conditions: string | undefined): Record<string, unknown> | null;
|
|
2486
2650
|
|
|
2651
|
+
export declare function ConfigReachNote({ collections, className, enabled }: {
|
|
2652
|
+
/** The collections the change applies to (a layout's, a pipeline's bound ones …). */
|
|
2653
|
+
collections: Array<string | null | undefined>;
|
|
2654
|
+
className?: string;
|
|
2655
|
+
enabled?: boolean;
|
|
2656
|
+
}): JSX.Element | null;
|
|
2657
|
+
|
|
2487
2658
|
/**
|
|
2488
2659
|
* Keep sounds apart per sign-in: a "View as" tab is someone else and must not be silenced by
|
|
2489
2660
|
* (or silence) the administrator's own tabs. Call before the first sound; same idea as the
|
|
@@ -2535,6 +2706,26 @@ export declare function copyErrorDetails(input: ErrorDescription | unknown, extr
|
|
|
2535
2706
|
action?: string;
|
|
2536
2707
|
}): Promise<boolean>;
|
|
2537
2708
|
|
|
2709
|
+
/**
|
|
2710
|
+
* "You're covering for Jane Smith today — 4 of Jane's records need you" (rt5 #15).
|
|
2711
|
+
*
|
|
2712
|
+
* GET /api/my-work/covering answers who named this person their delegate and is out right now,
|
|
2713
|
+
* and which of the records waiting on them reach them only through that cover. Live without a
|
|
2714
|
+
* reload: the line re-reads when owners move anywhere (`owners:changed` — delegation and
|
|
2715
|
+
* out-of-office starting or ending ride it), when one of the counted records changes (handled,
|
|
2716
|
+
* moved on), and at the moment the cover runs out. Re-reads are coalesced and kept apart
|
|
2717
|
+
* (the answer resolves owners), and the count rolls rather than jumps. Renders nothing when the
|
|
2718
|
+
* person covers nobody.
|
|
2719
|
+
*/
|
|
2720
|
+
declare interface CoverLine {
|
|
2721
|
+
user_id: string;
|
|
2722
|
+
name: string;
|
|
2723
|
+
first_name: string | null;
|
|
2724
|
+
ends_at: string | null;
|
|
2725
|
+
records: number;
|
|
2726
|
+
keys: string[];
|
|
2727
|
+
}
|
|
2728
|
+
|
|
2538
2729
|
export declare interface CrashBody {
|
|
2539
2730
|
message: string;
|
|
2540
2731
|
name: string;
|
|
@@ -2603,6 +2794,11 @@ export declare interface CrashReporterOptions {
|
|
|
2603
2794
|
now?: () => number;
|
|
2604
2795
|
}
|
|
2605
2796
|
|
|
2797
|
+
/** One announcer per grid. `emit` defaults to the window event the presence hosts relay. */
|
|
2798
|
+
export declare function createCellAnnouncer(emit?: CellEmit): CellAnnouncer;
|
|
2799
|
+
|
|
2800
|
+
export declare function createCoalescer(fn: () => void, opts?: CoalescerOptions): Coalescer;
|
|
2801
|
+
|
|
2606
2802
|
export declare function createCrashReporter(opts: CrashReporterOptions): CrashReporter;
|
|
2607
2803
|
|
|
2608
2804
|
/**
|
|
@@ -2646,6 +2842,9 @@ export declare function CronBuilder({ value, onChange, disabled }: {
|
|
|
2646
2842
|
disabled?: boolean;
|
|
2647
2843
|
}): JSX.Element;
|
|
2648
2844
|
|
|
2845
|
+
/** One colour per person, the same on every screen (a hash of their id). */
|
|
2846
|
+
export declare function cursorColor(personId: string | null | undefined): string;
|
|
2847
|
+
|
|
2649
2848
|
/** The cursor switches (#1517): only `{ show: true }` (plus `shortcuts: true`)
|
|
2650
2849
|
* is ever stored; off = the key is absent. */
|
|
2651
2850
|
declare interface CursorEdits {
|
|
@@ -2724,7 +2923,7 @@ export declare function dashboardPretendDownOptions(widgets: Array<{
|
|
|
2724
2923
|
field?: string | null;
|
|
2725
2924
|
}>, labels?: Record<string, string | null | undefined>): PretendDownOption[];
|
|
2726
2925
|
|
|
2727
|
-
export declare function DataTable<T = Record<string, unknown>>({ columns, rows, rowKey, total, page, limit, isLoading, isError, errorMessage, onRetry, sort, onSortChange, onPageChange, onRowClick, onRowContextMenu, searchValue, onSearchChange, searchPlaceholder, filterDefs, filterValues, onFilterChange, toolbarRight, emptyMessage, minBodyHeight, fillHeight, footer, hideFilterRow, nowrapCells, density, pinFirstColumn, columnPins, onColumnPinChange, columnFilterRow, hScrollProxy, selectedIds, onSelectionChange, rowClassName, rowDragProps, rowTitle, enterKey, rowGroups, collapsedGroups, onToggleGroup, onRowFocus, activeRowKey, rowAriaLabel, totalsRow }: DataTableProps<T>): React_2.JSX.Element;
|
|
2926
|
+
export declare function DataTable<T = Record<string, unknown>>({ columns, rows, rowKey, total, page, limit, isLoading, isError, errorMessage, onRetry, sort, onSortChange, onPageChange, onRowClick, onRowContextMenu, searchValue, onSearchChange, searchPlaceholder, filterDefs, filterValues, onFilterChange, toolbarRight, emptyMessage, minBodyHeight, fillHeight, footer, hideFilterRow, nowrapCells, density, pinFirstColumn, columnPins, onColumnPinChange, pinKeepRank, pinRightShare, columnFilterRow, hScrollProxy, selectedIds, onSelectionChange, rowClassName, rowDragProps, rowTitle, enterKey, rowGroups, collapsedGroups, onToggleGroup, onRowFocus, activeRowKey, rowAriaLabel, totalsRow }: DataTableProps<T>): React_2.JSX.Element;
|
|
2728
2927
|
|
|
2729
2928
|
export declare interface DataTableProps<T = Record<string, unknown>> {
|
|
2730
2929
|
columns: Column<T>[];
|
|
@@ -2770,6 +2969,14 @@ export declare interface DataTableProps<T = Record<string, unknown>> {
|
|
|
2770
2969
|
* hover-revealed pin button cycling none → left → right → none. */
|
|
2771
2970
|
columnPins?: Record<string, 'left' | 'right'>;
|
|
2772
2971
|
onColumnPinChange?: (key: string, pin: 'left' | 'right' | null) => void;
|
|
2972
|
+
/** On a narrow desktop table, which right pins give way first (lib/table-pins.ts
|
|
2973
|
+
* fitPins `rank`): lower ranks are released first. A pinned column whose cells on
|
|
2974
|
+
* this page are all empty ("—", blank, or text marked `data-cell-empty`) is released
|
|
2975
|
+
* before any other. Released columns scroll with the data columns; the view's
|
|
2976
|
+
* pins are untouched. */
|
|
2977
|
+
pinKeepRank?: (key: string) => number;
|
|
2978
|
+
/** Cap on the right pins alone, as a share of the visible width (fitPins `rightShare`). */
|
|
2979
|
+
pinRightShare?: number;
|
|
2773
2980
|
/** Render a compact per-column filter row under the headers — each column
|
|
2774
2981
|
* whose key matches a FilterDef gets that def's control inline (the
|
|
2775
2982
|
* CollectionBrowserView column-filter pattern). Independent of the
|
|
@@ -2862,6 +3069,15 @@ export declare function DefinitionsPanel({ definitions, runCounts, isLoading, in
|
|
|
2862
3069
|
initialKey?: string | null;
|
|
2863
3070
|
}): JSX.Element;
|
|
2864
3071
|
|
|
3072
|
+
export declare function DelegateCoverLine({ onShow, showing, showLabel, className }: {
|
|
3073
|
+
/** "Show them": the host filters its list to these records (My Work), or opens My Work. */
|
|
3074
|
+
onShow?: (line: CoverLine) => void;
|
|
3075
|
+
/** The cover whose records the host is showing now (its button reads "Showing"). */
|
|
3076
|
+
showing?: string | null;
|
|
3077
|
+
showLabel?: string;
|
|
3078
|
+
className?: string;
|
|
3079
|
+
}): JSX.Element | null;
|
|
3080
|
+
|
|
2865
3081
|
export declare function DelegationCard({ user, onSaved, forUser, coversFor }: {
|
|
2866
3082
|
user: ManagedUser & {
|
|
2867
3083
|
ooo_start?: string | null;
|
|
@@ -2902,6 +3118,15 @@ declare interface DeliveryChipsProps {
|
|
|
2902
3118
|
className?: string;
|
|
2903
3119
|
}
|
|
2904
3120
|
|
|
3121
|
+
declare interface DeltaChip {
|
|
3122
|
+
delta: number;
|
|
3123
|
+
/** `+3` / `−2`, with a real minus sign. */
|
|
3124
|
+
sign: string;
|
|
3125
|
+
since: 'this morning' | 'earlier today' | 'yesterday';
|
|
3126
|
+
/** The whole phrase: "+3 since this morning". */
|
|
3127
|
+
text: string;
|
|
3128
|
+
}
|
|
3129
|
+
|
|
2905
3130
|
/** What the author reads as while a clean recording runs. */
|
|
2906
3131
|
export declare const DEMO_USER: {
|
|
2907
3132
|
readonly name: "Demo User";
|
|
@@ -3106,6 +3331,27 @@ export declare function DndMark({ className }: {
|
|
|
3106
3331
|
className?: string;
|
|
3107
3332
|
}): JSX.Element;
|
|
3108
3333
|
|
|
3334
|
+
declare type DockSort = 'mine' | 'changed' | 'due';
|
|
3335
|
+
|
|
3336
|
+
/**
|
|
3337
|
+
* The watch list (rt5 #1 / #2): records a person pinned to follow from every page, in a dock
|
|
3338
|
+
* the app shell mounts once (components/watch-list/WatchDock.tsx). Server: /api/watch-list
|
|
3339
|
+
* (routes/watch-list.ts), stored in the person's own preferences, so it follows them across
|
|
3340
|
+
* tabs and devices.
|
|
3341
|
+
*
|
|
3342
|
+
* Reads:
|
|
3343
|
+
* prefs — pins + dock state, no record reads (every pin button and the header icon)
|
|
3344
|
+
* rows — the pinned records as the viewer reads them (dock open)
|
|
3345
|
+
* summary — only which pins changed since seen (dock minimized / closed: the dot)
|
|
3346
|
+
*
|
|
3347
|
+
* Nothing here polls. The dock follows the pinned records' collections on the shared socket
|
|
3348
|
+
* and refetches in place, coalesced.
|
|
3349
|
+
*/
|
|
3350
|
+
declare type DockState = 'open' | 'minimized' | 'closed';
|
|
3351
|
+
|
|
3352
|
+
/** A shared list's tab is `team:<list id>`. */
|
|
3353
|
+
declare type DockTab = 'watching' | 'waiting' | 'mentions' | `team:${string}`;
|
|
3354
|
+
|
|
3109
3355
|
declare type DocumentApplySelection = {
|
|
3110
3356
|
values: Record<string, unknown>;
|
|
3111
3357
|
lines_by_alias: Record<string, Array<{
|
|
@@ -3742,12 +3988,38 @@ declare interface ExtraSectionSpec {
|
|
|
3742
3988
|
/** Extract the slot key from an assignment field name, or null. */
|
|
3743
3989
|
export declare function extSlotKey(field: string): string | null;
|
|
3744
3990
|
|
|
3991
|
+
/**
|
|
3992
|
+
* The elements a batch of DOM mutations changed, worth fading (pure-ish; exported for tests):
|
|
3993
|
+
* the parent of changed text, or an added element. Never inside an editor or a
|
|
3994
|
+
* `data-live-nofade` area, never the focused element's subtree, never the root itself.
|
|
3995
|
+
*/
|
|
3996
|
+
export declare function fadeTargets(root: Element, records: readonly Pick<MutationRecord, 'type' | 'target' | 'addedNodes'>[], active?: Element | null): Element[];
|
|
3997
|
+
|
|
3745
3998
|
declare interface FallbackSocket extends SocketLike {
|
|
3746
3999
|
once?(event: string, cb: Listener): unknown;
|
|
3747
4000
|
connect?(): unknown;
|
|
3748
4001
|
disconnect?(): unknown;
|
|
3749
4002
|
}
|
|
3750
4003
|
|
|
4004
|
+
/**
|
|
4005
|
+
* One live stream of what changed across a set of related records — a project and its
|
|
4006
|
+
* workflows, requests, invoices and budgets (realtime program 2026-11-14, idea 21).
|
|
4007
|
+
*
|
|
4008
|
+
* `POST /api/activity/feed` resolves the sources AS THE VIEWER, so the stream never names a
|
|
4009
|
+
* record they cannot open. Rows are the shared activity sentences (groupActivity folds a burst or
|
|
4010
|
+
* a link-table write into one line, labels read as the viewer). The type chips filter it.
|
|
4011
|
+
*
|
|
4012
|
+
* Live and quiet: no timer. A live write to one of the records the stream follows (or a new
|
|
4013
|
+
* record of a followed type) refetches the newest page, after a 2 s quiet window and never more
|
|
4014
|
+
* than one read at a time. New rows slide in at the top only while the person is
|
|
4015
|
+
* scrolled to the top; otherwise they wait behind a "3 new" pill and nothing on screen moves.
|
|
4016
|
+
* Older rows load on request and are kept, so the head refreshing never drops what was read.
|
|
4017
|
+
*/
|
|
4018
|
+
export declare interface FeedSourceInput {
|
|
4019
|
+
collection: string;
|
|
4020
|
+
filter?: Record<string, unknown>;
|
|
4021
|
+
}
|
|
4022
|
+
|
|
3751
4023
|
declare type FetchCfg = {
|
|
3752
4024
|
apiBase: string;
|
|
3753
4025
|
authHeaders: Record<string, string>;
|
|
@@ -3927,9 +4199,15 @@ export declare type FieldState = {
|
|
|
3927
4199
|
*/
|
|
3928
4200
|
export declare function FileField({ field, value, onChange, error, disabled, readOnly, inputId, errorId }: FieldComponentProps): JSX.Element;
|
|
3929
4201
|
|
|
3930
|
-
export declare function FilePreviewLightbox({ file, onClose }: {
|
|
4202
|
+
export declare function FilePreviewLightbox({ file: opened, onClose, record: recordProp }: {
|
|
3931
4203
|
file: PreviewFile;
|
|
3932
4204
|
onClose: () => void;
|
|
4205
|
+
/** The record the file was opened from: its `$files` notices say when the file changed
|
|
4206
|
+
* (rt8 #19). Defaults to the record form the preview sits in. */
|
|
4207
|
+
record?: {
|
|
4208
|
+
collection: string;
|
|
4209
|
+
itemId: string | number;
|
|
4210
|
+
} | null;
|
|
3933
4211
|
}): ReactPortal;
|
|
3934
4212
|
|
|
3935
4213
|
export declare function FilterControl({ def, value, onChange, layout }: {
|
|
@@ -3988,6 +4266,47 @@ declare interface FilterOptionSpec {
|
|
|
3988
4266
|
* (ids → names), ≥/≤ for ranges, first two entries + count for multiselects. */
|
|
3989
4267
|
export declare function filterValueDisplay(def: FilterDef, value: string | string[]): string;
|
|
3990
4268
|
|
|
4269
|
+
/**
|
|
4270
|
+
* The calm "Fixed by Beth" state of a finding whose record was just fixed (see
|
|
4271
|
+
* lib/live-findings.ts). Quiet green check + words, no animation; the row around it should be
|
|
4272
|
+
* dimmed by the board (`opacity-60`) and stays until the next refresh.
|
|
4273
|
+
*/
|
|
4274
|
+
export declare function FindingFixedMark({ mark, className }: {
|
|
4275
|
+
mark: ResolvedMark;
|
|
4276
|
+
className?: string;
|
|
4277
|
+
}): JSX.Element;
|
|
4278
|
+
|
|
4279
|
+
/**
|
|
4280
|
+
* "Finding resolved live" (realtime program 2026-11-14, item 15).
|
|
4281
|
+
*
|
|
4282
|
+
* A board of findings (Data Integrity sweeps, orphans, inactive people, a "ready to send"
|
|
4283
|
+
* board…) goes stale the moment someone fixes a record. This hook turns a finding whose record
|
|
4284
|
+
* was just fixed into a calm "Fixed by Beth" state in place — it does not remove the row (the
|
|
4285
|
+
* list would shift under the pointer); the next refresh drops it.
|
|
4286
|
+
*
|
|
4287
|
+
* What it does, per burst of `collection:update` events (default debounce 1 s):
|
|
4288
|
+
* 1. picks the findings whose record the events named (a bulk write that named nobody picks
|
|
4289
|
+
* every finding on the page, capped at `maxPerRun`);
|
|
4290
|
+
* 2. asks the board's own `recheck(refs)` — a read as the VIEWER that returns the keys that
|
|
4291
|
+
* no longer have a finding (the board decides what "fixed" means: a conformance
|
|
4292
|
+
* re-check, an orphan re-test, a re-listing);
|
|
4293
|
+
* 3. marks those keys resolved, with who saved the record last when the viewer may read
|
|
4294
|
+
* `user_updated`.
|
|
4295
|
+
* A record that breaks again (a later recheck says it still has the finding) loses its mark.
|
|
4296
|
+
*
|
|
4297
|
+
* Wiring a board: pass `findings` as `{key, collection, itemId}` (the key is whatever the row
|
|
4298
|
+
* is keyed by), render `resolved.get(key)` as a `<FindingFixedMark>` and dim the row. See
|
|
4299
|
+
* ConformanceView and the orphan finder for the two shapes (one finding per row; one record
|
|
4300
|
+
* with several findings).
|
|
4301
|
+
*/
|
|
4302
|
+
export declare interface FindingRef {
|
|
4303
|
+
/** The row's own key (unique on the board). */
|
|
4304
|
+
key: string;
|
|
4305
|
+
collection: string;
|
|
4306
|
+
/** The record the finding is about. */
|
|
4307
|
+
itemId: string;
|
|
4308
|
+
}
|
|
4309
|
+
|
|
3991
4310
|
export declare function FirefightView({ onOpenRecord, onJumpTab, focusSignal }: FirefightViewProps): JSX.Element;
|
|
3992
4311
|
|
|
3993
4312
|
export declare interface FirefightViewProps {
|
|
@@ -4401,6 +4720,9 @@ export declare function getFiscalStartMonth(): number;
|
|
|
4401
4720
|
|
|
4402
4721
|
export declare function getLayoutSlot(key: string | null | undefined): LayoutSlotPlugin | null;
|
|
4403
4722
|
|
|
4723
|
+
/** The mode this tab runs in now. */
|
|
4724
|
+
export declare function getLiveMode(): LiveMode;
|
|
4725
|
+
|
|
4404
4726
|
/** What createGetBatcher returns: queue one GET for the next batch. */
|
|
4405
4727
|
declare type GetLoader = <T>(path: string, read: BatchedGet<T>) => Promise<T>;
|
|
4406
4728
|
|
|
@@ -4411,6 +4733,16 @@ export declare function getNavTrail(): TrailState;
|
|
|
4411
4733
|
/** A copy of the rings, oldest first. */
|
|
4412
4734
|
export declare function getReplayTail(): ReplayTail;
|
|
4413
4735
|
|
|
4736
|
+
export declare interface GridEditor {
|
|
4737
|
+
userId: string;
|
|
4738
|
+
name: string;
|
|
4739
|
+
item: string;
|
|
4740
|
+
field: string | null;
|
|
4741
|
+
page: string;
|
|
4742
|
+
at: number;
|
|
4743
|
+
color: string;
|
|
4744
|
+
}
|
|
4745
|
+
|
|
4414
4746
|
export declare const GridFlushContext: React_2.Context<GridFlushContextValue | null>;
|
|
4415
4747
|
|
|
4416
4748
|
export declare type GridFlushContextValue = {
|
|
@@ -4418,6 +4750,48 @@ export declare type GridFlushContextValue = {
|
|
|
4418
4750
|
unregister: (key: string) => void;
|
|
4419
4751
|
};
|
|
4420
4752
|
|
|
4753
|
+
/** A page key from parts (`matrix`, a collection, the other scope values): short, stable,
|
|
4754
|
+
* within the server's page-key alphabet. */
|
|
4755
|
+
export declare function gridPageKey(kind: string, ...parts: string[]): string;
|
|
4756
|
+
|
|
4757
|
+
declare interface GridPresence {
|
|
4758
|
+
/** The OTHER people editing on this page now (empty in Calm / Off). */
|
|
4759
|
+
editors: GridEditor[];
|
|
4760
|
+
}
|
|
4761
|
+
|
|
4762
|
+
/** The `data-grid-cell` value of a presence-tracked cell. */
|
|
4763
|
+
export declare function gridPresenceCell(item: string | number, field: string): string;
|
|
4764
|
+
|
|
4765
|
+
/**
|
|
4766
|
+
* The page-level line of a budget / planning grid (realtime round 8, item 22):
|
|
4767
|
+
* "Beth Ray is editing allocations for 4471 · March". One person reads as a sentence; more
|
|
4768
|
+
* become a short list of people, each with the row they are in. Each person keeps the colour
|
|
4769
|
+
* their cell outline uses. Names come from the server (the people already passed the read gate
|
|
4770
|
+
* of the row they are in, as did the viewer); row and cell labels come from the viewer's own
|
|
4771
|
+
* page — a row not on it falls back to its id.
|
|
4772
|
+
*/
|
|
4773
|
+
export declare function GridPresenceLine({ editors, noun, rowLabel, cellLabel, className }: {
|
|
4774
|
+
editors: GridEditor[];
|
|
4775
|
+
/** What the page edits, plural: "forecasts", "allocations". */
|
|
4776
|
+
noun: string;
|
|
4777
|
+
rowLabel: (item: string) => string | null | undefined;
|
|
4778
|
+
cellLabel?: (field: string, item: string) => string | null | undefined;
|
|
4779
|
+
className?: string;
|
|
4780
|
+
}): JSX.Element | null;
|
|
4781
|
+
|
|
4782
|
+
declare interface GridPresenceOptions {
|
|
4783
|
+
/** Which page this is (`forecast-worksheet`, `matrix:allocations`…); only the same page's
|
|
4784
|
+
* marks show. Letters, digits and `_.:-`, up to 64. */
|
|
4785
|
+
page: string;
|
|
4786
|
+
/** The collection of the records each row stands for — the read gate is that record's. */
|
|
4787
|
+
collection: string | null | undefined;
|
|
4788
|
+
/** The records on screen. */
|
|
4789
|
+
items: Array<string | number>;
|
|
4790
|
+
/** The grid: focus inside it is announced and others' cells are outlined inside it. */
|
|
4791
|
+
containerRef?: RefObject<HTMLElement | null>;
|
|
4792
|
+
enabled?: boolean;
|
|
4793
|
+
}
|
|
4794
|
+
|
|
4421
4795
|
/** options.set_all_rows on an O2M grid: one header button per entry that writes ONE value
|
|
4422
4796
|
* into that column on every line (or the ticked lines), or clears it when left blank —
|
|
4423
4797
|
* e.g. "Set REQ ID on all lines" (EFP v2's "apply req id to all lines"). Admin-only unless
|
|
@@ -5096,6 +5470,13 @@ declare interface Hold {
|
|
|
5096
5470
|
/** Queue one toast-worthy thing; returns true when it was held (caller shows nothing). */
|
|
5097
5471
|
export declare function holdNotification(item: Omit<HeldItem, 'at'>): boolean;
|
|
5098
5472
|
|
|
5473
|
+
/**
|
|
5474
|
+
* Pure (exported for tests). `shown`: keys on screen now (null = nothing yet). At the top, the
|
|
5475
|
+
* answer as it is. Scrolled down: rows on screen keep their order (taking new data), rows that
|
|
5476
|
+
* arrived ahead of every shown row are held back and counted, other arrivals go to the end.
|
|
5477
|
+
*/
|
|
5478
|
+
export declare function holdTopInserts<T>(shown: readonly string[] | null, next: readonly T[], keyOf: (row: T) => string, atTop: boolean): TopInsertResult<T>;
|
|
5479
|
+
|
|
5099
5480
|
/** The house style (#1551): defaults every new help video starts from.
|
|
5100
5481
|
* Administrators only. */
|
|
5101
5482
|
export declare function HouseStyleButton(): JSX.Element | null;
|
|
@@ -5125,6 +5506,12 @@ export declare const IDLE_AFTER_MS: number;
|
|
|
5125
5506
|
*
|
|
5126
5507
|
* Asks GET /realtime/build-status through the host's NivaroClient when there is one, else the
|
|
5127
5508
|
* same-origin /api (admin mounts the banner outside its NivaroProvider).
|
|
5509
|
+
*
|
|
5510
|
+
* Two reasons, two remedies (realtime idea 13): only a NEW BUILD reloads the page. Stale DATA —
|
|
5511
|
+
* the tab was hidden or the machine asleep longer than the server can replay live events, the
|
|
5512
|
+
* socket lost events it could not replay while the tab was away, or nobody used it for hours —
|
|
5513
|
+
* refreshes the screen's data in place on return (lib/screen-refresh.ts, the same refresh as
|
|
5514
|
+
* the ↻ button), keeping scroll, open panels and edits. `decideIdleResync` is the pure rule.
|
|
5128
5515
|
*/
|
|
5129
5516
|
export declare function IdleReloadWatcher(): null;
|
|
5130
5517
|
|
|
@@ -6060,6 +6447,9 @@ export declare function isCrashWorthy(err: unknown): err is Error;
|
|
|
6060
6447
|
*/
|
|
6061
6448
|
export declare function isListTimeout(err: unknown): boolean;
|
|
6062
6449
|
|
|
6450
|
+
/** A click that asks for a new tab (Cmd / Ctrl / Shift / middle button). */
|
|
6451
|
+
export declare function isNewTabClick(e?: ClickLike | null): boolean;
|
|
6452
|
+
|
|
6063
6453
|
/**
|
|
6064
6454
|
* Text a person should never see: a bare status line, a JavaScript or driver
|
|
6065
6455
|
* error, a stack, SQL or the database's own names, or an internal id. The
|
|
@@ -6648,6 +7038,29 @@ export declare function LearningPathCard({ className }: {
|
|
|
6648
7038
|
className?: string;
|
|
6649
7039
|
}): JSX.Element;
|
|
6650
7040
|
|
|
7041
|
+
/** Set by the record form: the record's lines lock one at a time (its line grids read it). */
|
|
7042
|
+
export declare const LineLockContext: Context<boolean>;
|
|
7043
|
+
|
|
7044
|
+
declare interface LineLocks {
|
|
7045
|
+
enabled: boolean;
|
|
7046
|
+
view: (rowId: string | null | undefined) => LineLockView;
|
|
7047
|
+
/** Take the lock on a line before editing it. false = someone else holds it. */
|
|
7048
|
+
claim: (rowId: string) => Promise<boolean>;
|
|
7049
|
+
/** Let go of the line this viewer holds (after LINE_LOCK_LEAVE_MS unless `now`). */
|
|
7050
|
+
release: (opts?: {
|
|
7051
|
+
now?: boolean;
|
|
7052
|
+
}) => void;
|
|
7053
|
+
/** The line this viewer holds right now. */
|
|
7054
|
+
held: string | null;
|
|
7055
|
+
}
|
|
7056
|
+
|
|
7057
|
+
declare interface LineLockView {
|
|
7058
|
+
/** Someone else is editing this line: it is read-only here. */
|
|
7059
|
+
readOnly: boolean;
|
|
7060
|
+
/** Their name ("Someone" when the server could not name them). */
|
|
7061
|
+
by: string | null;
|
|
7062
|
+
}
|
|
7063
|
+
|
|
6651
7064
|
/**
|
|
6652
7065
|
* Fired on `window` after a list rewrote its address (replaceListLinkParam), with
|
|
6653
7066
|
* `detail.path` = the new pathname + search + hash. Hosts that remember "where a record was
|
|
@@ -6680,11 +7093,39 @@ export declare function ListLoadError({ error, onRetry, className }: {
|
|
|
6680
7093
|
*/
|
|
6681
7094
|
export declare function listLoadErrorText(err: unknown): string;
|
|
6682
7095
|
|
|
7096
|
+
/**
|
|
7097
|
+
* Realtime #16 — "Previous / Next in list" on a record opened from a list or a worklist.
|
|
7098
|
+
*
|
|
7099
|
+
* The list kept its row order when it opened this record (lib/list-return.ts); this walks it
|
|
7100
|
+
* without going back to the list. A step REPLACES the record's history entry, so the browser's
|
|
7101
|
+
* Back (and the record's back arrow) still lands on the list — which then marks the row the
|
|
7102
|
+
* person ended on. A modified click (Cmd / Ctrl / Shift / middle) opens that record in a new tab.
|
|
7103
|
+
* Renders nothing when the record was not opened from a list in this tab.
|
|
7104
|
+
*/
|
|
7105
|
+
export declare function ListNeighborNav({ collection, itemId, className }: {
|
|
7106
|
+
collection: string;
|
|
7107
|
+
itemId: string | number | null | undefined;
|
|
7108
|
+
className?: string;
|
|
7109
|
+
}): JSX.Element | null;
|
|
7110
|
+
|
|
7111
|
+
/** Where `at` sits in the stashed list: its 1-based position, the total and its neighbours. */
|
|
7112
|
+
export declare function listNeighbors(stash: ListReturnStash | null, at: ListRef): {
|
|
7113
|
+
index: number;
|
|
7114
|
+
total: number;
|
|
7115
|
+
prev: ListRef | null;
|
|
7116
|
+
next: ListRef | null;
|
|
7117
|
+
} | null;
|
|
7118
|
+
|
|
6683
7119
|
/** The query key a collection list (CollectionBrowserView) reads its metadata under. */
|
|
6684
7120
|
export declare function listQueryKeys(collection: string): {
|
|
6685
7121
|
meta: QueryKey;
|
|
6686
7122
|
};
|
|
6687
7123
|
|
|
7124
|
+
declare interface ListRef {
|
|
7125
|
+
collection: string;
|
|
7126
|
+
id: string;
|
|
7127
|
+
}
|
|
7128
|
+
|
|
6688
7129
|
/**
|
|
6689
7130
|
* "Copy as …" (#654): the request a list or record view is making, rendered
|
|
6690
7131
|
* as a curl command, an SDK call and a GraphQL document. Pure — no client,
|
|
@@ -6703,6 +7144,33 @@ declare interface ListRequest {
|
|
|
6703
7144
|
page?: number;
|
|
6704
7145
|
}
|
|
6705
7146
|
|
|
7147
|
+
/**
|
|
7148
|
+
* The stash this record page belongs to, or null: the record must be the one the list opened
|
|
7149
|
+
* (or walked to with Previous / Next), on the history entry it was opened on — the same
|
|
7150
|
+
* record reached later from a search is not "in the list" any more.
|
|
7151
|
+
*/
|
|
7152
|
+
export declare function listReturnFor(at: ListRef, stash?: ListReturnStash | null): ListReturnStash | null;
|
|
7153
|
+
|
|
7154
|
+
declare interface ListReturnStash {
|
|
7155
|
+
/** The list's own key: `cbv:<collection>`, `queue:<id>`. */
|
|
7156
|
+
list: string;
|
|
7157
|
+
/** How the list is named to the person ("Workflows", a queue's name). */
|
|
7158
|
+
label?: string | null;
|
|
7159
|
+
/** The list's address when the record was opened (pathname + search). */
|
|
7160
|
+
path: string;
|
|
7161
|
+
/** The rows the list showed, in order. */
|
|
7162
|
+
rows: ListRef[];
|
|
7163
|
+
/** The record the person is on now (moves with Previous / Next). */
|
|
7164
|
+
current: ListRef;
|
|
7165
|
+
/** The record the list opened (stays put). */
|
|
7166
|
+
opened: ListRef;
|
|
7167
|
+
/** history.state.idx of the record page (null when the host keeps no index). */
|
|
7168
|
+
idx: number | null;
|
|
7169
|
+
/** The list's own history entry key, so Back to that entry knows it is a return. */
|
|
7170
|
+
entry: string | null;
|
|
7171
|
+
at: number;
|
|
7172
|
+
}
|
|
7173
|
+
|
|
6706
7174
|
/**
|
|
6707
7175
|
* A whole list placeholder for surfaces without a real header yet: a header strip (real labels
|
|
6708
7176
|
* when given) and rows at the real row height, one bar per column.
|
|
@@ -6731,6 +7199,43 @@ export declare function listTrailDetail(p: {
|
|
|
6731
7199
|
page?: number;
|
|
6732
7200
|
}): string;
|
|
6733
7201
|
|
|
7202
|
+
/**
|
|
7203
|
+
* "Beth and 2 others are viewing this list" — ADMINISTRATORS ONLY (api
|
|
7204
|
+
* services/list-viewer-topics.ts).
|
|
7205
|
+
*
|
|
7206
|
+
* Every open list / queue worklist joins its viewer topic (`list-view:<collection>`,
|
|
7207
|
+
* `queue-view:<id>`) through the ordinary reference-counted `ops:join`, so the server can
|
|
7208
|
+
* count the person. The names come back as `ops:changed {topic, viewers}` — and the server
|
|
7209
|
+
* only lets administrators into the room that carries them, so for anyone else this hook
|
|
7210
|
+
* simply never hears anything and returns []. Nothing about this is decided in the browser.
|
|
7211
|
+
*/
|
|
7212
|
+
declare interface ListViewer {
|
|
7213
|
+
id: string;
|
|
7214
|
+
name: string;
|
|
7215
|
+
}
|
|
7216
|
+
|
|
7217
|
+
/**
|
|
7218
|
+
* Small avatars of who else has this list / queue open — administrators only (the server
|
|
7219
|
+
* sends the names to administrators and nobody else; for everyone else this renders
|
|
7220
|
+
* nothing). Quiet: no toast, and it never moves anything:
|
|
7221
|
+
*
|
|
7222
|
+
* variant 'header' a page header row (admin list + queue pages): avatars and the sentence.
|
|
7223
|
+
* variant 'inline' inside a wrapping toolbar (hosts without a header row): avatars only,
|
|
7224
|
+
* in a fixed-width slot an administrator's toolbar always reserves, so
|
|
7225
|
+
* names arriving or leaving never push buttons onto another row. The
|
|
7226
|
+
* sentence and the names ride the tooltip.
|
|
7227
|
+
*/
|
|
7228
|
+
export declare function ListViewers({ kind, id, variant, selfId, className }: {
|
|
7229
|
+
kind: 'list' | 'queue';
|
|
7230
|
+
id: string | number | null | undefined;
|
|
7231
|
+
variant?: 'header' | 'inline';
|
|
7232
|
+
/** Who "me" is when the host sits outside an ItemEditAuthContext. */
|
|
7233
|
+
selfId?: string;
|
|
7234
|
+
className?: string;
|
|
7235
|
+
}): JSX.Element | null;
|
|
7236
|
+
|
|
7237
|
+
export declare const LIVE_MODE_LABELS: Record<LiveMode, string>;
|
|
7238
|
+
|
|
6734
7239
|
/**
|
|
6735
7240
|
* Query-key heads of surfaces that keep themselves live with their own socket handlers (record
|
|
6736
7241
|
* pages — RECORD_QUERY_HEADS in item-edit/RecordLiveSync — the collection browser's row reads,
|
|
@@ -6739,12 +7244,73 @@ export declare function listTrailDetail(p: {
|
|
|
6739
7244
|
*/
|
|
6740
7245
|
export declare const LIVE_RECONCILE_HEADS: readonly string[];
|
|
6741
7246
|
|
|
7247
|
+
/**
|
|
7248
|
+
* The one polite live region of an app shell: screen-reader users hear that something on
|
|
7249
|
+
* the page changed ("2 rows updated", "Status changed"), at most once every ~5 seconds, never
|
|
7250
|
+
* for their own writes, never a value (live events carry field NAMES only).
|
|
7251
|
+
*
|
|
7252
|
+
* Mount ONCE, inside the realtime and item-edit-auth providers. Renders nothing visible. The
|
|
7253
|
+
* person's "Live changes" setting (Profile → Display: Full / Brief / Off) is respected, and
|
|
7254
|
+
* `off` stops listening entirely.
|
|
7255
|
+
*/
|
|
7256
|
+
export declare function LiveAnnouncer(): JSX.Element;
|
|
7257
|
+
|
|
7258
|
+
/**
|
|
7259
|
+
* CacheStamp that also watches the tables the figure reads (`freshness_sources`): the first
|
|
7260
|
+
* write after the run raises "Data changed since run", and the viewer may opt in to refreshing
|
|
7261
|
+
* automatically (`scope` keeps that choice, e.g. `widget:7`). Without known tables it is the
|
|
7262
|
+
* plain stamp.
|
|
7263
|
+
*/
|
|
7264
|
+
export declare function LiveCacheStamp({ scope, ...stamp }: Omit<Parameters<typeof CacheStamp>[0], 'changedLive' | 'autoRefresh'> & {
|
|
7265
|
+
scope: string;
|
|
7266
|
+
}): JSX.Element;
|
|
7267
|
+
|
|
7268
|
+
declare interface LiveCalendar<T> {
|
|
7269
|
+
/** Entries to draw; `departed` ones are no longer in the server's answer. */
|
|
7270
|
+
entries: SettledRow<T>[];
|
|
7271
|
+
/** Put on the element that contains the grid (pointer / focus inside it holds the order). */
|
|
7272
|
+
ref: (el: HTMLElement | null) => void;
|
|
7273
|
+
}
|
|
7274
|
+
|
|
7275
|
+
declare interface LiveCalendarOptions<T> {
|
|
7276
|
+
collection: string | null | undefined;
|
|
7277
|
+
/** Query keys (prefixes) re-read when the collection moves. */
|
|
7278
|
+
keys: QueryKey[];
|
|
7279
|
+
/** The rows the query answered (undefined while loading). */
|
|
7280
|
+
items: readonly T[] | undefined;
|
|
7281
|
+
keyOf: (row: T) => string;
|
|
7282
|
+
/** react-query `dataUpdatedAt` of the main query. */
|
|
7283
|
+
updatedAt?: number;
|
|
7284
|
+
/** The person's own view (month, date field, filter): a change shows the new answer as it is. */
|
|
7285
|
+
resetKey: string;
|
|
7286
|
+
/** Only writes naming one of these fields refresh the grid (default: any non-aspect write). */
|
|
7287
|
+
fields?: string[];
|
|
7288
|
+
quietMs?: number;
|
|
7289
|
+
maxWaitMs?: number;
|
|
7290
|
+
enabled?: boolean;
|
|
7291
|
+
}
|
|
7292
|
+
|
|
7293
|
+
export declare function LiveCount({ value, format, className }: LiveCountProps): JSX.Element;
|
|
7294
|
+
|
|
7295
|
+
declare interface LiveCountProps {
|
|
7296
|
+
value: number | string | null | undefined;
|
|
7297
|
+
/** Render the text (e.g. `99+`, a unit); default is the plain number. */
|
|
7298
|
+
format?: (value: number | string) => ReactNode;
|
|
7299
|
+
className?: string;
|
|
7300
|
+
}
|
|
7301
|
+
|
|
6742
7302
|
/** The slice of `document` / `window` the bridge listens on. */
|
|
6743
7303
|
declare interface LiveEventTarget {
|
|
6744
7304
|
addEventListener(type: string, cb: () => void): void;
|
|
6745
7305
|
removeEventListener(type: string, cb: () => void): void;
|
|
6746
7306
|
}
|
|
6747
7307
|
|
|
7308
|
+
declare interface LiveFadeOptions {
|
|
7309
|
+
enabled?: boolean;
|
|
7310
|
+
/** How long after an arm DOM changes count as the live change (default 1.2 s). */
|
|
7311
|
+
windowMs?: number;
|
|
7312
|
+
}
|
|
7313
|
+
|
|
6748
7314
|
/**
|
|
6749
7315
|
* Live data hooks for headless frontends (#1751).
|
|
6750
7316
|
*
|
|
@@ -6774,6 +7340,19 @@ export declare interface LiveHookOptions {
|
|
|
6774
7340
|
includeOwn?: boolean;
|
|
6775
7341
|
}
|
|
6776
7342
|
|
|
7343
|
+
declare interface LiveJobsOptions {
|
|
7344
|
+
/** Query keys (prefixes) re-read when a run starts or finishes. */
|
|
7345
|
+
keys: QueryKey[];
|
|
7346
|
+
/** A progress report (never refetches). */
|
|
7347
|
+
onProgress?: (p: {
|
|
7348
|
+
id?: number;
|
|
7349
|
+
progress: Record<string, unknown>;
|
|
7350
|
+
}) => void;
|
|
7351
|
+
quietMs?: number;
|
|
7352
|
+
maxWaitMs?: number;
|
|
7353
|
+
enabled?: boolean;
|
|
7354
|
+
}
|
|
7355
|
+
|
|
6777
7356
|
export declare function liveListKey(collection: string, query?: Query<any>): QueryKey;
|
|
6778
7357
|
|
|
6779
7358
|
export declare interface LiveListOptions extends LiveHookOptions {
|
|
@@ -6784,6 +7363,75 @@ export declare type LiveListResult<T> = UseQueryResult<ListResponse<T>> & {
|
|
|
6784
7363
|
live: boolean;
|
|
6785
7364
|
};
|
|
6786
7365
|
|
|
7366
|
+
/**
|
|
7367
|
+
* Live updates, the person's own setting (realtime round 3, item 24) — Profile → Display:
|
|
7368
|
+
*
|
|
7369
|
+
* normal what the app always did: changes land in place with a short fade, new rows carry a
|
|
7370
|
+
* dot, co-viewers and "Beth is writing a note" show.
|
|
7371
|
+
* calm the same data, quieter: values change without fades, flashes or marks, a list keeps
|
|
7372
|
+
* its order until the person pauses (no pointer or keys for a few seconds), and no
|
|
7373
|
+
* typing or "who else is here" indicators.
|
|
7374
|
+
* off no live data refresh at all: someone else's change shows after the ↻ refresh-data
|
|
7375
|
+
* button (or the next time the screen loads). New-version reloads, the person's own
|
|
7376
|
+
* writes, notifications, preferences and access changes still arrive.
|
|
7377
|
+
*
|
|
7378
|
+
* Stored as `preferences.live_mode` (PATCH /users/me/preferences; null = the role's default,
|
|
7379
|
+
* GET /api/live-preference/default, else normal). This module is the ONE read: the transport
|
|
7380
|
+
* tap (realtime.ts `withLiveSeenTap`), the live hooks (live.ts), the list/screen helpers and
|
|
7381
|
+
* the CSS (`html[data-live-mode]`) all ask it, so a surface built on them follows the setting
|
|
7382
|
+
* without knowing about it. `LivePreferenceHost` (mounted once per app shell) feeds it from the
|
|
7383
|
+
* profile query; every tab of the browser follows a change at once (localStorage `storage`
|
|
7384
|
+
* event), other devices on the `prefs:changed` notice user-sync already handles.
|
|
7385
|
+
*/
|
|
7386
|
+
declare type LiveMode = 'calm' | 'normal' | 'off';
|
|
7387
|
+
|
|
7388
|
+
declare type LiveModeSource = 'own' | 'role' | 'default';
|
|
7389
|
+
|
|
7390
|
+
/**
|
|
7391
|
+
* "2 new matches · Show" — the quiet pill a live results page raises when records start
|
|
7392
|
+
* matching after the page loaded. It floats over the top of the results (no height of its own),
|
|
7393
|
+
* so nothing the person is reading moves when it appears. Put it first inside the scrolling
|
|
7394
|
+
* results container.
|
|
7395
|
+
*/
|
|
7396
|
+
export declare function LiveNewMatchesPill({ count, onShow, className }: {
|
|
7397
|
+
count: number;
|
|
7398
|
+
onShow: () => void;
|
|
7399
|
+
className?: string;
|
|
7400
|
+
}): JSX.Element;
|
|
7401
|
+
|
|
7402
|
+
/**
|
|
7403
|
+
* The quiet "Live updates off" note (realtime round 3, item 24). Shown only when the person set
|
|
7404
|
+
* Profile → Display → Live updates to Off, so a screen that does not move is never mistaken for
|
|
7405
|
+
* one with nothing new. `ScreenRefreshButton` renders it beside every ↻ (record headers, the
|
|
7406
|
+
* portal bar); a host may also place it itself.
|
|
7407
|
+
*
|
|
7408
|
+
* `variant`: `header` (a small outlined pill on a page header), `bar` (inherits a top bar's text
|
|
7409
|
+
* colour), `dot` (a corner mark for a narrow rail button — the caller positions it).
|
|
7410
|
+
*/
|
|
7411
|
+
export declare function LiveOffNote({ variant, className }: {
|
|
7412
|
+
variant?: 'header' | 'bar' | 'dot';
|
|
7413
|
+
className?: string;
|
|
7414
|
+
}): JSX.Element | null;
|
|
7415
|
+
|
|
7416
|
+
declare interface LivePreference {
|
|
7417
|
+
mode: LiveMode;
|
|
7418
|
+
source: LiveModeSource;
|
|
7419
|
+
normal: boolean;
|
|
7420
|
+
calm: boolean;
|
|
7421
|
+
off: boolean;
|
|
7422
|
+
/** Calm or Off: no fades, flashes, marks or presence indicators. */
|
|
7423
|
+
quiet: boolean;
|
|
7424
|
+
}
|
|
7425
|
+
|
|
7426
|
+
/**
|
|
7427
|
+
* Feeds the person's live-updates setting (lib/live-preference.ts) into this tab. Mount ONCE per
|
|
7428
|
+
* app shell, inside the NivaroProvider and QueryClientProvider. Reads the same profile query the
|
|
7429
|
+
* Display card writes (`nvr-profile-prefs`, refreshed on `prefs:changed` by user-sync), plus the
|
|
7430
|
+
* role's default from GET /live-preference/default. Until both answered, the tab keeps the mode
|
|
7431
|
+
* it last ran in (stored per browser), so an Off tab never flickers live on a page load.
|
|
7432
|
+
*/
|
|
7433
|
+
export declare function LivePreferenceHost(): null;
|
|
7434
|
+
|
|
6787
7435
|
export declare interface LiveQueryBridge {
|
|
6788
7436
|
/** Refetch every tagged query and every active reconcile head once. */
|
|
6789
7437
|
reconcile(reason: string): void;
|
|
@@ -6871,6 +7519,20 @@ export declare interface LiveQueryMeta {
|
|
|
6871
7519
|
minGapMs?: number;
|
|
6872
7520
|
/** Never refreshed by events — only reconciled after a gap (a surface that keeps itself live). */
|
|
6873
7521
|
reconcileOnly?: boolean;
|
|
7522
|
+
/**
|
|
7523
|
+
* Events (and reconciles) only mark it stale — it is never re-read while on screen; it reads
|
|
7524
|
+
* again the next time it is shown or enabled. For a picker's option list: someone else's new
|
|
7525
|
+
* vendor appears the next time the dropdown opens, and an OPEN dropdown never reshuffles under
|
|
7526
|
+
* the pointer. Joins its collection's room only once it holds data (a picker nobody opened
|
|
7527
|
+
* listens to nothing).
|
|
7528
|
+
*/
|
|
7529
|
+
staleOnly?: boolean;
|
|
7530
|
+
/** Wait a random 0..jitterMs before an event refetch, so every open tab does not read in the
|
|
7531
|
+
* same second (a dashboard many people keep open). Default 0. */
|
|
7532
|
+
jitterMs?: number;
|
|
7533
|
+
/** Wait at least this long before an event refetch (a server cache dropped a moment after
|
|
7534
|
+
* the write, e.g. a cached report). Default 0. */
|
|
7535
|
+
delayMs?: number;
|
|
6874
7536
|
}
|
|
6875
7537
|
|
|
6876
7538
|
/** `meta` for a query the bridge keeps current: `useQuery({ …, meta: liveQueryMeta({ reads: ['orders'] }) })`. */
|
|
@@ -6899,6 +7561,83 @@ export declare type LiveRecordResult<T> = UseQueryResult<T | null> & {
|
|
|
6899
7561
|
/** Pure form of `useLiveRefetchInterval` (exported for tests). */
|
|
6900
7562
|
export declare function liveRefetchInterval(live: boolean, base: number | false | undefined, safetyMs?: number): number | false | undefined;
|
|
6901
7563
|
|
|
7564
|
+
declare interface LiveRefreshOptions {
|
|
7565
|
+
/** Ops topic to listen on (`useLiveOps`); the page is only told THAT something moved. */
|
|
7566
|
+
topic?: string | null;
|
|
7567
|
+
/** Query keys (prefixes) to re-read. */
|
|
7568
|
+
keys: ReadonlyArray<QueryKey>;
|
|
7569
|
+
/** Quiet window before the re-read (default 2 s, never lower than 2 s). */
|
|
7570
|
+
quietMs?: number;
|
|
7571
|
+
maxWaitMs?: number;
|
|
7572
|
+
enabled?: boolean;
|
|
7573
|
+
/** Extra poke source: call `poke` from your own live subscription. */
|
|
7574
|
+
onReady?: (poke: () => void) => (() => void) | undefined;
|
|
7575
|
+
}
|
|
7576
|
+
|
|
7577
|
+
export declare interface LiveSearchOptions<T extends SearchRow> {
|
|
7578
|
+
/** The rows exactly as the page's query returned them. */
|
|
7579
|
+
rows: T[];
|
|
7580
|
+
/** Collections whose writes matter (the page's result collections). */
|
|
7581
|
+
collections: string[];
|
|
7582
|
+
/** The page's own search, run again as the viewer, bypassing any short cache. */
|
|
7583
|
+
fetchFresh: () => Promise<T[]>;
|
|
7584
|
+
/** Changes whenever the page's query shows a new answer (query text, tab, page, refetch). */
|
|
7585
|
+
resetKey: string;
|
|
7586
|
+
/** The page's normal refetch — what Show runs. */
|
|
7587
|
+
onShow: () => void;
|
|
7588
|
+
enabled?: boolean;
|
|
7589
|
+
/** Count newly matching records (off past the first page: a later page cannot say). */
|
|
7590
|
+
detectNew?: boolean;
|
|
7591
|
+
/** Put on the element that contains the rows (`data-row-key` = searchRowKey) for the fade. */
|
|
7592
|
+
rootRef?: RefObject<HTMLElement | null>;
|
|
7593
|
+
/** Least time between two re-asks. */
|
|
7594
|
+
minGapMs?: number;
|
|
7595
|
+
/** `fetchFresh` answers only the first N rows (a longer, paged list): later rows are left alone. */
|
|
7596
|
+
windowSize?: number;
|
|
7597
|
+
}
|
|
7598
|
+
|
|
7599
|
+
export declare interface LiveSearchState<T extends SearchRow> {
|
|
7600
|
+
/** `rows` with in-place updates applied (same order, same length). */
|
|
7601
|
+
rows: T[];
|
|
7602
|
+
/** Keys (searchRowKey) of rows that no longer match. */
|
|
7603
|
+
dimmed: ReadonlySet<string>;
|
|
7604
|
+
newCount: number;
|
|
7605
|
+
/** Re-run the page's query (shows the new matches, drops the dimmed rows). */
|
|
7606
|
+
show: () => void;
|
|
7607
|
+
}
|
|
7608
|
+
|
|
7609
|
+
/** The refetch interval to use: the caller's own while not live, a slow safety poll while live. */
|
|
7610
|
+
export declare function liveWidgetInterval(live: boolean, base: number | undefined): number | undefined;
|
|
7611
|
+
|
|
7612
|
+
/**
|
|
7613
|
+
* Pushed dashboard and report widgets (#1675).
|
|
7614
|
+
*
|
|
7615
|
+
* The widget asks the server to watch it (`widgets:watch` over the host's socket). When a write
|
|
7616
|
+
* lands on a collection the widget reads, the server recomputes it AS THIS SIGN-IN — at most
|
|
7617
|
+
* once every 10 seconds per widget — and pushes the new figure to this socket alone
|
|
7618
|
+
* (`widget:data`). `onData` gets it; the caller drops it into its query cache.
|
|
7619
|
+
*
|
|
7620
|
+
* Returns whether the push is on. While it is, the caller slows its poll to a safety net
|
|
7621
|
+
* (`liveWidgetInterval`); when the server refuses the widget (raw-SQL query widgets, AI
|
|
7622
|
+
* insight, calc formulas, a host without realtime) or drops it, the poll carries on as before.
|
|
7623
|
+
* The watch is renewed every minute and after a reconnect (the server lets it lapse after 150
|
|
7624
|
+
* seconds unrenewed), and a reconnect refetches once through `onStale`, since writes made while
|
|
7625
|
+
* disconnected were not pushed.
|
|
7626
|
+
*/
|
|
7627
|
+
declare interface LiveWidgetOptions {
|
|
7628
|
+
kind: 'dashboard' | 'report';
|
|
7629
|
+
widget: string;
|
|
7630
|
+
report?: string | null;
|
|
7631
|
+
/** Dashboard: `{ extra_filters }`; report: `{ date_range, entity_filters }`. */
|
|
7632
|
+
params?: Record<string, unknown> | null;
|
|
7633
|
+
enabled?: boolean;
|
|
7634
|
+
onData: (data: unknown) => void;
|
|
7635
|
+
/** Refetch through the normal route (figure too large to push, or a reconnect). */
|
|
7636
|
+
onStale?: () => void;
|
|
7637
|
+
}
|
|
7638
|
+
|
|
7639
|
+
declare type Loader = () => unknown;
|
|
7640
|
+
|
|
6902
7641
|
/**
|
|
6903
7642
|
* The degraded state for a widget or panel whose data did not load (#2858): what happened in
|
|
6904
7643
|
* plain words and a way to try again, instead of a blank box, "No data" or a raw error string.
|
|
@@ -6952,10 +7691,20 @@ export declare interface M2MStagingCtx {
|
|
|
6952
7691
|
}
|
|
6953
7692
|
|
|
6954
7693
|
/**
|
|
6955
|
-
*
|
|
6956
|
-
*
|
|
6957
|
-
*
|
|
6958
|
-
|
|
7694
|
+
* Mark a grid cell as someone else's cursor: their colour as the outline (`--nvr-cursor`,
|
|
7695
|
+
* the hosts' CSS reads it) and their name as the hover tip. `color` overrides the hashed one
|
|
7696
|
+
* (a screen that assigns colours per person present). Returns the undo.
|
|
7697
|
+
*/
|
|
7698
|
+
export declare function markRemoteCell(el: HTMLElement, person: {
|
|
7699
|
+
id?: string | null;
|
|
7700
|
+
name: string;
|
|
7701
|
+
}, color?: string): () => void;
|
|
7702
|
+
|
|
7703
|
+
/**
|
|
7704
|
+
* A screenshot of the page for Report a problem (#1390), with every typed
|
|
7705
|
+
* value masked first — the same rule session replay applies (all inputs
|
|
7706
|
+
* masked, `.nvr-no-record` blocked). html2canvas renders a CLONE of the
|
|
7707
|
+
* document, and the masking happens on that clone, so the live page is never
|
|
6959
7708
|
* touched.
|
|
6960
7709
|
*
|
|
6961
7710
|
* html2canvas is an optional peer dependency of @nivaro/react (the admin
|
|
@@ -7106,6 +7855,9 @@ declare interface MatrixEditorConfig {
|
|
|
7106
7855
|
group_label?: string;
|
|
7107
7856
|
} | false;
|
|
7108
7857
|
};
|
|
7858
|
+
/** What the matrix edits, plural, for the "who is editing" line ("allocations"). Default:
|
|
7859
|
+
* the target collection's name in words. */
|
|
7860
|
+
presence_noun?: string;
|
|
7109
7861
|
}
|
|
7110
7862
|
|
|
7111
7863
|
/** Prefetch requests one tab runs at once; the rest wait their turn. */
|
|
@@ -7120,6 +7872,37 @@ declare type MaybeIntent = IntentProps | Record<string, never>;
|
|
|
7120
7872
|
*/
|
|
7121
7873
|
export declare function measureClockOffset(samples: ClockSample[]): number | null;
|
|
7122
7874
|
|
|
7875
|
+
export declare interface MergeDoneInfo {
|
|
7876
|
+
survivor: string;
|
|
7877
|
+
merge_id: string | null;
|
|
7878
|
+
discarded: string[];
|
|
7879
|
+
}
|
|
7880
|
+
|
|
7881
|
+
export declare function MergeRecordsDialog({ collection, ids, open, onOpenChange, draft, preferredSurvivor, onMerged, container }: {
|
|
7882
|
+
collection: string;
|
|
7883
|
+
ids: Array<string | number>;
|
|
7884
|
+
open: boolean;
|
|
7885
|
+
onOpenChange: (open: boolean) => void;
|
|
7886
|
+
draft?: {
|
|
7887
|
+
values: Record<string, unknown>;
|
|
7888
|
+
label?: string;
|
|
7889
|
+
} | null;
|
|
7890
|
+
preferredSurvivor?: string | number | null;
|
|
7891
|
+
/** After a merge (or an undo) — refresh lists, leave a create form. */
|
|
7892
|
+
onMerged?: (info: MergeDoneInfo) => void;
|
|
7893
|
+
container?: HTMLElement | null;
|
|
7894
|
+
}): JSX.Element;
|
|
7895
|
+
|
|
7896
|
+
/** The picker, then the merge screen. */
|
|
7897
|
+
export declare function MergeWithFlow({ collection, itemId, itemLabel, open, onOpenChange, onMerged }: {
|
|
7898
|
+
collection: string;
|
|
7899
|
+
itemId: string | number;
|
|
7900
|
+
itemLabel?: string | null;
|
|
7901
|
+
open: boolean;
|
|
7902
|
+
onOpenChange: (open: boolean) => void;
|
|
7903
|
+
onMerged?: (info: MergeDoneInfo) => void;
|
|
7904
|
+
}): JSX.Element;
|
|
7905
|
+
|
|
7123
7906
|
declare interface MessageToken {
|
|
7124
7907
|
text: string;
|
|
7125
7908
|
entity?: string;
|
|
@@ -7266,9 +8049,12 @@ export declare const NavigationContext: React_2.Context<NavigationContextValue>;
|
|
|
7266
8049
|
|
|
7267
8050
|
export declare type NavigationContextValue = {
|
|
7268
8051
|
/** `options.state` rides along for hosts whose router supports it (e.g. react-router's
|
|
7269
|
-
* useNavigate) — hosts that ignore the second argument still navigate correctly.
|
|
8052
|
+
* useNavigate) — hosts that ignore the second argument still navigate correctly.
|
|
8053
|
+
* `options.replace` replaces the current history entry (Previous / Next in list keeps
|
|
8054
|
+
* Back pointing at the list); a host that ignores it pushes, which still works. */
|
|
7270
8055
|
navigate: (path: string, options?: {
|
|
7271
8056
|
state?: unknown;
|
|
8057
|
+
replace?: boolean;
|
|
7272
8058
|
}) => void;
|
|
7273
8059
|
/** Map item links onto the host app's own routes. Components fall back to
|
|
7274
8060
|
* the admin shape (/collections/:collection/:id?layout=…) when absent —
|
|
@@ -7309,6 +8095,9 @@ export declare function NewImportDialog({ open, onOpenChange, definitions, runCo
|
|
|
7309
8095
|
onQueued: (id: number) => void;
|
|
7310
8096
|
}): JSX.Element;
|
|
7311
8097
|
|
|
8098
|
+
/** "1 new match" / "3 new matches". */
|
|
8099
|
+
export declare function newMatchesText(count: number): string;
|
|
8100
|
+
|
|
7312
8101
|
/**
|
|
7313
8102
|
* Selects and renders the correct field component for a single field based on
|
|
7314
8103
|
* its normalized fieldType. Override any type via `components`; falls back to
|
|
@@ -7380,6 +8169,19 @@ export declare function normalizeFieldType(rawType: string, iface: string | null
|
|
|
7380
8169
|
/** The host swapped credentials (a new bearer token): whatever was refused may work now. */
|
|
7381
8170
|
export declare function noteCredentialChanged(): void;
|
|
7382
8171
|
|
|
8172
|
+
/**
|
|
8173
|
+
* A list is opening a record: keep its row order and the opened row. Call it right BEFORE the
|
|
8174
|
+
* navigation (the record page lands one history entry later, which `idx` records).
|
|
8175
|
+
*/
|
|
8176
|
+
export declare function noteListOpen(s: {
|
|
8177
|
+
list: string;
|
|
8178
|
+
label?: string | null;
|
|
8179
|
+
path?: string;
|
|
8180
|
+
rows: ListRef[];
|
|
8181
|
+
opened: ListRef;
|
|
8182
|
+
entry?: string | null;
|
|
8183
|
+
}): void;
|
|
8184
|
+
|
|
7383
8185
|
/**
|
|
7384
8186
|
* An identity call succeeded: this tab is signed in. Other tabs hear it when this tab was
|
|
7385
8187
|
* signed out until now, or the first time this page learns it (a fresh page after sign-in).
|
|
@@ -7452,7 +8254,7 @@ export declare function NotificationAnalyticsView({ className, compactHeader }:
|
|
|
7452
8254
|
* click-through routing via the shared notification-target resolver. Needs
|
|
7453
8255
|
* `<NivaroProvider>`.
|
|
7454
8256
|
*/
|
|
7455
|
-
export declare function NotificationBell({ routes, onNavigate, app, subscribe, buttonClassName, panelClassName, beforeList, extraBadge, mailLogUrl, renderTrigger, allPath, subscriptionsPath, rulesPath, onActionError, panelPlacement
|
|
8257
|
+
export declare function NotificationBell({ routes, onNavigate, app, subscribe, buttonClassName, panelClassName, beforeList, extraBadge, mailLogUrl, renderTrigger, allPath, subscriptionsPath, rulesPath, onActionError, panelPlacement }: NotificationBellProps): JSX.Element;
|
|
7456
8258
|
|
|
7457
8259
|
export declare interface NotificationBellProps {
|
|
7458
8260
|
/** Where each notification kind lands in the host app. */
|
|
@@ -7499,7 +8301,7 @@ export declare interface NotificationBellProps {
|
|
|
7499
8301
|
* positions it beside the trigger — for a sidebar rail whose overflow
|
|
7500
8302
|
* would clip an inline panel. */
|
|
7501
8303
|
panelPlacement?: 'below' | 'right';
|
|
7502
|
-
/**
|
|
8304
|
+
/** @deprecated The tab count moved to `TabCountHost`; this does nothing. */
|
|
7503
8305
|
tabBadge?: boolean;
|
|
7504
8306
|
}
|
|
7505
8307
|
|
|
@@ -7969,7 +8771,7 @@ export declare function pageAtPayload(path: string, app: string): {
|
|
|
7969
8771
|
app: string;
|
|
7970
8772
|
} | null;
|
|
7971
8773
|
|
|
7972
|
-
export declare function PageRenderer({ slug, hideHeader, className }: PageRendererProps): JSX.Element;
|
|
8774
|
+
export declare function PageRenderer({ slug, hideHeader, className, liveReads, liveGapMs }: PageRendererProps): JSX.Element;
|
|
7973
8775
|
|
|
7974
8776
|
export declare interface PageRendererPage {
|
|
7975
8777
|
slug: string;
|
|
@@ -7986,6 +8788,14 @@ export declare interface PageRendererProps {
|
|
|
7986
8788
|
/** Hide the page-name header row (host renders its own chrome). */
|
|
7987
8789
|
hideHeader?: boolean;
|
|
7988
8790
|
className?: string;
|
|
8791
|
+
/**
|
|
8792
|
+
* Collections the page's figures are computed from. Set, the query and widget figures
|
|
8793
|
+
* refresh when one of them changes (coalesced, at most every `liveGapMs`, spread over a few
|
|
8794
|
+
* seconds across viewers) and changed figures fade in. Absent: no live refresh (as before).
|
|
8795
|
+
*/
|
|
8796
|
+
liveReads?: string[];
|
|
8797
|
+
/** Least time between two live refreshes of one figure (default 15 s). */
|
|
8798
|
+
liveGapMs?: number;
|
|
7989
8799
|
}
|
|
7990
8800
|
|
|
7991
8801
|
export declare interface PageRendererWidget {
|
|
@@ -8007,6 +8817,9 @@ declare interface ParseFailure {
|
|
|
8007
8817
|
position: number;
|
|
8008
8818
|
}
|
|
8009
8819
|
|
|
8820
|
+
/** A stored or posted value → a mode, or null when it is none of them. */
|
|
8821
|
+
export declare function parseLiveMode(v: unknown): LiveMode | null;
|
|
8822
|
+
|
|
8010
8823
|
/**
|
|
8011
8824
|
* Text → amount. Empty (or "—" / "-") is 0. Negative amounts come back
|
|
8012
8825
|
* negative; a caller that only takes zero or more refuses them itself.
|
|
@@ -8094,6 +8907,35 @@ export declare interface PartnersViewProps {
|
|
|
8094
8907
|
|
|
8095
8908
|
declare type PathStepKind = 'request' | 'cron' | 'import' | 'feed' | 'write' | 'transition' | 'flow' | 'push' | 'attempt' | 'partner_call' | 'notify' | 'mail' | 'group';
|
|
8096
8909
|
|
|
8910
|
+
/** Collections the sheet can show: business records, not system tables or chat. */
|
|
8911
|
+
export declare function peekable(collection: string | null | undefined): boolean;
|
|
8912
|
+
|
|
8913
|
+
declare type PeekDecision = 'new-tab' | 'peek' | 'navigate';
|
|
8914
|
+
|
|
8915
|
+
/** What a click on a record link does (pure; see the module note). */
|
|
8916
|
+
export declare function peekDecision(e: ClickLike | null | undefined, hasPeek: boolean, collection: string | null | undefined): PeekDecision;
|
|
8917
|
+
|
|
8918
|
+
/**
|
|
8919
|
+
* Realtime #17 — peek at a record from anywhere, without leaving the page.
|
|
8920
|
+
*
|
|
8921
|
+
* Lists and queues already open a record in a side sheet (CollectionBrowserView's Peek,
|
|
8922
|
+
* QueueItemSheet). The app host mounts ONE `RecordPeekHost` (components/RecordPeekHost.tsx)
|
|
8923
|
+
* that renders the same `RecordDrilldownSheet`, and any surface — My Work, home worklists,
|
|
8924
|
+
* notifications, search results, record links in comments — opens a record in it through
|
|
8925
|
+
* `usePeekOrOpen()`:
|
|
8926
|
+
*
|
|
8927
|
+
* - a plain click opens the sheet (live, Esc closes, ↑ / ↓ walk the surface's own list when
|
|
8928
|
+
* it passed one, "Open record" goes to the full page);
|
|
8929
|
+
* - Cmd / Ctrl / Shift / middle click opens the full page in a new tab;
|
|
8930
|
+
* - a host without a peek host keeps today's behaviour: the click navigates.
|
|
8931
|
+
*/
|
|
8932
|
+
export declare interface PeekTarget {
|
|
8933
|
+
collection: string;
|
|
8934
|
+
itemId: string;
|
|
8935
|
+
/** What the sheet calls it until the record loads. */
|
|
8936
|
+
title?: string | null;
|
|
8937
|
+
}
|
|
8938
|
+
|
|
8097
8939
|
declare interface PendingTask {
|
|
8098
8940
|
title: string;
|
|
8099
8941
|
description?: string;
|
|
@@ -8248,6 +9090,9 @@ export declare interface PersonProfileData {
|
|
|
8248
9090
|
end: number;
|
|
8249
9091
|
samples: number;
|
|
8250
9092
|
} | null;
|
|
9093
|
+
/** Idea 32 — the viewer may open the sign-in troubleshooter (admins; support-desk members
|
|
9094
|
+
* without network details). */
|
|
9095
|
+
sign_in_help?: boolean;
|
|
8251
9096
|
admin: {
|
|
8252
9097
|
account_kind: string | null;
|
|
8253
9098
|
city: string | null;
|
|
@@ -9105,8 +9950,14 @@ export declare function QueryWidgetView({ config }: {
|
|
|
9105
9950
|
config: QueryWidgetConfig;
|
|
9106
9951
|
}): JSX.Element;
|
|
9107
9952
|
|
|
9108
|
-
export declare function QueueBulkBar({ count, states, busy, claimsEnabled, showClaim, showRelease, showTransition, onClaim, onRelease, onTransition, onClear, children }: {
|
|
9953
|
+
export declare function QueueBulkBar({ count, states, busy, claimsEnabled, showClaim, showRelease, showTransition, onClaim, onRelease, onTransition, onClear, children, figures, notices, onActionIntent }: {
|
|
9109
9954
|
count: number;
|
|
9955
|
+
/** rt8 — the selection's live count + sums (replaces "N selected"). */
|
|
9956
|
+
figures?: ReactNode;
|
|
9957
|
+
/** rt8 — "open by Beth" / "changed since you picked them", drawn above the bar. */
|
|
9958
|
+
notices?: ReactNode;
|
|
9959
|
+
/** rt8 — the person reached for one of the bar's actions (pointer or keyboard). */
|
|
9960
|
+
onActionIntent?: () => void;
|
|
9110
9961
|
states: Array<{
|
|
9111
9962
|
value: string;
|
|
9112
9963
|
label: string;
|
|
@@ -9225,7 +10076,7 @@ export declare interface QueueRealtimeAdapter {
|
|
|
9225
10076
|
}) => void) => () => void;
|
|
9226
10077
|
}
|
|
9227
10078
|
|
|
9228
|
-
export declare function QueueWorklist({ queueId, realtime, renderError, hideCreateActions, onAsk }: QueueWorklistProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | ReactPortal | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | JSX.Element | null;
|
|
10079
|
+
export declare function QueueWorklist({ queueId, realtime, renderError, hideCreateActions, viewersInHeader, onAsk }: QueueWorklistProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | ReactPortal | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | JSX.Element | null;
|
|
9229
10080
|
|
|
9230
10081
|
export declare interface QueueWorklistProps {
|
|
9231
10082
|
queueId: string;
|
|
@@ -9236,6 +10087,9 @@ export declare interface QueueWorklistProps {
|
|
|
9236
10087
|
* everywhere; a list hides them only when every collection the queue can
|
|
9237
10088
|
* create in is on it (the header covers those, not the rest). */
|
|
9238
10089
|
hideCreateActions?: boolean | string[];
|
|
10090
|
+
/** The host's header row shows who else has this queue open (admin queue page), so the
|
|
10091
|
+
* toolbar keeps no slot for it. */
|
|
10092
|
+
viewersInHeader?: boolean;
|
|
9239
10093
|
/** Hosts with an Ask AI page pass this: the toolbar gains "Ask about this
|
|
9240
10094
|
* queue" (#1276), which hands the queue over so the host can open Ask AI
|
|
9241
10095
|
* with the question seeded. Absent = no button. */
|
|
@@ -9343,6 +10197,8 @@ export declare function rankTeamForFilters(scopes: TeamScopeMap | undefined, fil
|
|
|
9343
10197
|
/** The reaction palette — mirrored server-side; anything else is rejected. */
|
|
9344
10198
|
export declare const REACTION_EMOJI: readonly ["👍", "✅", "👀", "🎉", "❤️", "😂"];
|
|
9345
10199
|
|
|
10200
|
+
export declare function readListReturn(now?: number): ListReturnStash | null;
|
|
10201
|
+
|
|
9346
10202
|
export declare function readSignOutNote(): SignOutNote | null;
|
|
9347
10203
|
|
|
9348
10204
|
export declare interface ReadViewLayout {
|
|
@@ -9404,6 +10260,12 @@ export declare interface RealtimeStatus {
|
|
|
9404
10260
|
* cursor, or no answer in time). Absent = unknown; the live-query bridge reconciles then.
|
|
9405
10261
|
*/
|
|
9406
10262
|
resumed?: 'replayed' | 'reloaded' | 'unverified' | null;
|
|
10263
|
+
/**
|
|
10264
|
+
* Realtime 24 — a dead connection is being repaired quietly (lib/socket-liveness.ts): the
|
|
10265
|
+
* state may read `reconnecting`, but nothing is shown for it (no banner, no stale marks)
|
|
10266
|
+
* unless the repair fails twice, when this clears.
|
|
10267
|
+
*/
|
|
10268
|
+
repair?: 'silent' | null;
|
|
9407
10269
|
}
|
|
9408
10270
|
|
|
9409
10271
|
/**
|
|
@@ -9411,6 +10273,10 @@ export declare interface RealtimeStatus {
|
|
|
9411
10273
|
* updates are paused; after the reconnect and catch-up it says so (and, when catch-up had to
|
|
9412
10274
|
* reload, what was refreshed), then clears itself. Renders nothing for hosts without a
|
|
9413
10275
|
* realtime status, and nothing while the browser is offline (OfflineBanner says that).
|
|
10276
|
+
*
|
|
10277
|
+
* Realtime 24: nothing at all while the connection repairs itself quietly (`status.repair`) —
|
|
10278
|
+
* neither the paused strip nor the "resumed" line; the strip shows only once that repair has
|
|
10279
|
+
* failed twice and the flag clears.
|
|
9414
10280
|
*/
|
|
9415
10281
|
export declare function RealtimeStatusBanner(): JSX.Element | null;
|
|
9416
10282
|
|
|
@@ -9420,6 +10286,37 @@ export declare function RecentRecordsRail({ limit, title, className }: {
|
|
|
9420
10286
|
className?: string;
|
|
9421
10287
|
}): JSX.Element;
|
|
9422
10288
|
|
|
10289
|
+
export declare function RecordActivityStream({ sources, records, typeLabels, live, empty, className, maxHeightClass, onOpenRecord }: {
|
|
10290
|
+
sources: FeedSourceInput[];
|
|
10291
|
+
records?: Array<{
|
|
10292
|
+
collection: string;
|
|
10293
|
+
id: string | number;
|
|
10294
|
+
}>;
|
|
10295
|
+
/** Chip names by collection ("workflows" → "Workflows"). */
|
|
10296
|
+
typeLabels?: Record<string, string>;
|
|
10297
|
+
live?: boolean;
|
|
10298
|
+
empty?: string;
|
|
10299
|
+
className?: string;
|
|
10300
|
+
maxHeightClass?: string;
|
|
10301
|
+
/** Open a row's record (a host's drill-down sheet). Default: the host's record route. */
|
|
10302
|
+
onOpenRecord?: (target: {
|
|
10303
|
+
collection: string;
|
|
10304
|
+
itemId: string;
|
|
10305
|
+
}) => void;
|
|
10306
|
+
}): JSX.Element;
|
|
10307
|
+
|
|
10308
|
+
export declare interface RecordAgent {
|
|
10309
|
+
key: string;
|
|
10310
|
+
name: string;
|
|
10311
|
+
for: {
|
|
10312
|
+
id: string;
|
|
10313
|
+
name: string;
|
|
10314
|
+
};
|
|
10315
|
+
mode: AgentMode;
|
|
10316
|
+
/** Local clock (ms) the mark lapses at. */
|
|
10317
|
+
until: number;
|
|
10318
|
+
}
|
|
10319
|
+
|
|
9423
10320
|
export declare function RecordChatActions({ collection, itemDraft, compact }: {
|
|
9424
10321
|
collection: string;
|
|
9425
10322
|
itemDraft: Record<string, unknown>;
|
|
@@ -9427,7 +10324,7 @@ export declare function RecordChatActions({ collection, itemDraft, compact }: {
|
|
|
9427
10324
|
compact?: boolean;
|
|
9428
10325
|
}): JSX.Element | null;
|
|
9429
10326
|
|
|
9430
|
-
export declare function RecordDrilldownSheet({ collection, itemId, layoutId, rootLayoutSlug, width, title, stack: controlledStack, onPush, onPop, onClose, design, onOpenRecord }: {
|
|
10327
|
+
export declare function RecordDrilldownSheet({ collection, itemId, layoutId, rootLayoutSlug, width, title, stack: controlledStack, onPush, onPop, onClose, design, onOpenRecord, headerExtra }: {
|
|
9431
10328
|
collection: string;
|
|
9432
10329
|
itemId: string;
|
|
9433
10330
|
layoutId?: number | null;
|
|
@@ -9457,6 +10354,8 @@ export declare function RecordDrilldownSheet({ collection, itemId, layoutId, roo
|
|
|
9457
10354
|
collection: string;
|
|
9458
10355
|
itemId: string;
|
|
9459
10356
|
}) => void;
|
|
10357
|
+
/** Shown in the strip before "Open record" (the app record sheet's ↑ / ↓ position). */
|
|
10358
|
+
headerExtra?: ReactNode;
|
|
9460
10359
|
}): JSX.Element;
|
|
9461
10360
|
|
|
9462
10361
|
/**
|
|
@@ -9542,6 +10441,9 @@ export declare function RecordGridEditor({ config }: {
|
|
|
9542
10441
|
declare interface RecordGridEditorConfig {
|
|
9543
10442
|
collection: string;
|
|
9544
10443
|
title?: string;
|
|
10444
|
+
/** What the grid edits, plural, for the "who is editing" line of the browse grid
|
|
10445
|
+
* ("forecasts"). Default: the collection's name in words. */
|
|
10446
|
+
presence_noun?: string;
|
|
9545
10447
|
/**
|
|
9546
10448
|
* BROWSE-THEN-EDIT: the key columns become header pickers. Until every key
|
|
9547
10449
|
* is chosen the grid shows read-only totals rolled up by the unpicked keys
|
|
@@ -9656,7 +10558,33 @@ export declare function recordNavigation(ev: TrailEvent): TrailEntry | undefined
|
|
|
9656
10558
|
export declare function RecordOutboxHost({ userId, onOpenRecord }: {
|
|
9657
10559
|
userId: string | null | undefined;
|
|
9658
10560
|
onOpenRecord?: (collection: string, itemId: string) => void;
|
|
9659
|
-
}):
|
|
10561
|
+
}): JSX.Element;
|
|
10562
|
+
|
|
10563
|
+
export declare interface RecordPeekApi {
|
|
10564
|
+
/** Open `target` in the app's record sheet; `list` (in order) enables ↑ / ↓. */
|
|
10565
|
+
open: (target: PeekTarget, opts?: {
|
|
10566
|
+
list?: PeekTarget[];
|
|
10567
|
+
}) => void;
|
|
10568
|
+
}
|
|
10569
|
+
|
|
10570
|
+
export declare const RecordPeekContext: Context<RecordPeekApi | null>;
|
|
10571
|
+
|
|
10572
|
+
/**
|
|
10573
|
+
* Realtime #17 — the app's one record sheet (see lib/record-peek.ts). Mount it ONCE, around
|
|
10574
|
+
* the app or beside it (it registers itself, so surfaces anywhere find it), inside the host's
|
|
10575
|
+
* QueryClient; `wrapSheet` adds the providers the sheet's form needs (NivaroProvider,
|
|
10576
|
+
* NavigationContext, ItemEditAuthContext) when they are not above it. It reuses `RecordDrilldownSheet`, so the sheet is the same one
|
|
10577
|
+
* lists and queues show: the record's form (live), nested drills, presence, "Open record".
|
|
10578
|
+
*
|
|
10579
|
+
* The open sheet sits in the host's overlay history when it gives one (Back closes it), else
|
|
10580
|
+
* in component state. ↑ / ↓ walk the opening surface's list while focus is not in a field or
|
|
10581
|
+
* menu; Esc closes.
|
|
10582
|
+
*/
|
|
10583
|
+
export declare function RecordPeekHost({ children, width, wrapSheet }: {
|
|
10584
|
+
children?: ReactNode;
|
|
10585
|
+
width?: number | string;
|
|
10586
|
+
wrapSheet?: (sheet: ReactNode) => ReactNode;
|
|
10587
|
+
}): JSX.Element;
|
|
9660
10588
|
|
|
9661
10589
|
/**
|
|
9662
10590
|
* Presence hooks for headless frontends (#2487, #2486), over the host's realtime adapter —
|
|
@@ -9744,6 +10672,12 @@ declare function RecordReadViewBody({ collection, itemId: itemIdProp, layoutData
|
|
|
9744
10672
|
* whatever the touch returned. Dismiss POSTs /dismiss, which collapses the
|
|
9745
10673
|
* server baseline to now — a reload inside the session grace stays quiet, and
|
|
9746
10674
|
* only changes made after the dismissal come back as news.
|
|
10675
|
+
*
|
|
10676
|
+
* Opened from an email (realtime round 3 #2): the link carries the send time
|
|
10677
|
+
* (`?since=`), and the strip instead says quietly what happened since that
|
|
10678
|
+
* email — "Since this email: moved to Approved · 2 fields changed" — judged by
|
|
10679
|
+
* the server as the viewer (only fields they may read). Dismissing it drops
|
|
10680
|
+
* `since` from the address.
|
|
9747
10681
|
*/
|
|
9748
10682
|
export declare function RecordRecapStrip({ collection, itemId }: {
|
|
9749
10683
|
collection: string;
|
|
@@ -9755,7 +10689,7 @@ export declare function RecordRecapStrip({ collection, itemId }: {
|
|
|
9755
10689
|
* never content, sent only to people already admitted to the same room (the record read gate,
|
|
9756
10690
|
* the ticket gate):
|
|
9757
10691
|
*
|
|
9758
|
-
* note "Beth is
|
|
10692
|
+
* note "Beth is replying" (#1721, record rooms; `field` = one field thread)
|
|
9759
10693
|
* transition "Kim is approving" (#1722, record rooms)
|
|
9760
10694
|
* reply "Kim is replying" (#2026, ticket pages)
|
|
9761
10695
|
* viewers "Kim is looking at this" (#1882, ticket and issue pages)
|
|
@@ -9819,6 +10753,17 @@ declare type Rect = {
|
|
|
9819
10753
|
h: number;
|
|
9820
10754
|
};
|
|
9821
10755
|
|
|
10756
|
+
/**
|
|
10757
|
+
* Refetch what this screen shows, in place. `reason` is for diagnostics ('button', 'palette',
|
|
10758
|
+
* 'idle-replay-window'…). Automatic reasons (anything but 'button' / 'palette' / 'shortcut')
|
|
10759
|
+
* inside SCREEN_REFRESH_MIN_GAP_MS of the last refresh are folded into it.
|
|
10760
|
+
*/
|
|
10761
|
+
export declare function refreshScreenData(opts?: {
|
|
10762
|
+
reason?: string;
|
|
10763
|
+
qc?: QueryClient | null;
|
|
10764
|
+
now?: () => number;
|
|
10765
|
+
}): Promise<ScreenRefreshResult>;
|
|
10766
|
+
|
|
9822
10767
|
/** What a refused call tried: `{method, path}` (GraphQL/upload/import name themselves). */
|
|
9823
10768
|
declare type RefusedWrite = {
|
|
9824
10769
|
method: string;
|
|
@@ -9856,6 +10801,12 @@ export declare function registerReplayCapture(fn: Capture, snap?: Snapshot): ()
|
|
|
9856
10801
|
|
|
9857
10802
|
export declare function registerRoomOpener(fn: RoomOpener): () => void;
|
|
9858
10803
|
|
|
10804
|
+
/**
|
|
10805
|
+
* A screen that keeps data outside react-query (its own fetch + useState) registers how to load
|
|
10806
|
+
* it again. Returns the unregister function.
|
|
10807
|
+
*/
|
|
10808
|
+
export declare function registerScreenLoader(run: Loader): () => void;
|
|
10809
|
+
|
|
9859
10810
|
/** Report a source of unsaved work; the returned function removes it. */
|
|
9860
10811
|
export declare function registerUnsavedWork(label: string, dirty: () => boolean, opts?: UnsavedWorkOptions): () => void;
|
|
9861
10812
|
|
|
@@ -10130,6 +11081,26 @@ export declare function RequiredVideosCard({ className }: {
|
|
|
10130
11081
|
|
|
10131
11082
|
export declare function resolveCollectionIcon(iconName: string | null | undefined): React.ElementType | null;
|
|
10132
11083
|
|
|
11084
|
+
declare interface ResolvedFindingsOptions {
|
|
11085
|
+
findings: FindingRef[];
|
|
11086
|
+
/** The board's own re-check, as the viewer: the keys (of `refs`) that no longer have a finding. */
|
|
11087
|
+
recheck: (refs: FindingRef[]) => Promise<string[]>;
|
|
11088
|
+
enabled?: boolean;
|
|
11089
|
+
/** Most findings re-checked in one go. */
|
|
11090
|
+
maxPerRun?: number;
|
|
11091
|
+
/** Who saved the record last; default reads `user_updated` through the viewer's own read. */
|
|
11092
|
+
lookupWriter?: (ref: FindingRef) => Promise<string | null>;
|
|
11093
|
+
}
|
|
11094
|
+
|
|
11095
|
+
/** The calm label: "Fixed by Beth", "Fixed by you", or just "Fixed" when nobody can be named. */
|
|
11096
|
+
export declare function resolvedLabel(mark: ResolvedMark, name: string | null | undefined, selfId?: string | null): string;
|
|
11097
|
+
|
|
11098
|
+
export declare interface ResolvedMark {
|
|
11099
|
+
at: number;
|
|
11100
|
+
/** User id that saved the record last (null: unknown or not readable). */
|
|
11101
|
+
by: string | null;
|
|
11102
|
+
}
|
|
11103
|
+
|
|
10133
11104
|
export declare function resolveNotificationTarget(collection: string | null | undefined, item: string | null | undefined, routes: NotificationRouteMap): NotificationTarget;
|
|
10134
11105
|
|
|
10135
11106
|
/**
|
|
@@ -10369,6 +11340,8 @@ declare interface Row {
|
|
|
10369
11340
|
/** The kind's human label from the registry ("Fusion — transfer order
|
|
10370
11341
|
* submitted"); null when the server no longer knows the kind. */
|
|
10371
11342
|
label?: string | null;
|
|
11343
|
+
/** What the partner is behind on, in the record's words ("Workflow ID HQ26-81459"). */
|
|
11344
|
+
subject?: string | null;
|
|
10372
11345
|
submission_id?: number | null;
|
|
10373
11346
|
transition_id?: string | null;
|
|
10374
11347
|
transition_label?: string | null;
|
|
@@ -10597,6 +11570,78 @@ declare interface ScopeDimensionLite {
|
|
|
10597
11570
|
display_field?: string | null;
|
|
10598
11571
|
}
|
|
10599
11572
|
|
|
11573
|
+
/**
|
|
11574
|
+
* The small ↻ that refreshes this screen's data in place (realtime idea 12) — never the page.
|
|
11575
|
+
* Spins while the reads run, then shows a quiet ✓ for a moment. No toast: a read that failed
|
|
11576
|
+
* shows its own error where it renders, and the button keeps a small amber dot with a tip.
|
|
11577
|
+
*
|
|
11578
|
+
* `variant`:
|
|
11579
|
+
* - `header` (default): beside a page or record header's actions, a 32 px ghost button.
|
|
11580
|
+
* - `rail`: the admin sidebar's always-dark footer strip.
|
|
11581
|
+
* - `bar`: a portal top bar (inherits the bar's text colour).
|
|
11582
|
+
*
|
|
11583
|
+
* One ↻ per screen: a `header` button (a page's own) registers while mounted, and the app-wide
|
|
11584
|
+
* `rail` / `bar` button renders nothing meanwhile.
|
|
11585
|
+
*/
|
|
11586
|
+
export declare function ScreenRefreshButton({ variant, className }: {
|
|
11587
|
+
variant?: 'header' | 'rail' | 'bar';
|
|
11588
|
+
className?: string;
|
|
11589
|
+
}): JSX.Element | null;
|
|
11590
|
+
|
|
11591
|
+
/** Pure: does a command-palette query ask for "Refresh this page's data"? (both apps' palettes) */
|
|
11592
|
+
export declare function screenRefreshMatches(query: string): boolean;
|
|
11593
|
+
|
|
11594
|
+
/**
|
|
11595
|
+
* Refresh the data on this screen, never the page (realtime idea 12).
|
|
11596
|
+
*
|
|
11597
|
+
* People reloaded a page to be sure what they saw was current (prod, a week to 2026-11-14:
|
|
11598
|
+
* ~1,050 same-page reloads). A reload costs them their scroll, open panels, selection and any
|
|
11599
|
+
* half-typed edit. This refetches what the screen shows, in place:
|
|
11600
|
+
*
|
|
11601
|
+
* - every ACTIVE react-query read (`refetchQueries({type: 'active'})`, reads already in flight are
|
|
11602
|
+
* kept, not restarted), while inactive cached reads are only marked stale so the next screen
|
|
11603
|
+
* that mounts them asks again;
|
|
11604
|
+
* - every loader a screen registered for data it keeps outside react-query
|
|
11605
|
+
* (`useScreenLoader(fn)` / `registerScreenLoader(fn)`);
|
|
11606
|
+
* - the `nvr:screen-refresh` window event, for anything else that wants to listen.
|
|
11607
|
+
*
|
|
11608
|
+
* What stays: unsaved edits (the record form merges a refetch into its draft field by field —
|
|
11609
|
+
* the same path a live write by someone else takes, so a touched field keeps the person's value),
|
|
11610
|
+
* scroll position, open sheets and popovers, selection. Nothing remounts.
|
|
11611
|
+
*
|
|
11612
|
+
* A query opts out with `meta: { screenRefresh: false }` (a read that must not repeat — a one-off
|
|
11613
|
+
* export, a run that costs money).
|
|
11614
|
+
*
|
|
11615
|
+
* One refresh at a time: a second call while one runs gets the same promise. Automatic callers
|
|
11616
|
+
* (the idle resync, idea 13) are coalesced to one per second.
|
|
11617
|
+
*/
|
|
11618
|
+
declare type ScreenRefreshPhase = 'idle' | 'running' | 'done' | 'partial';
|
|
11619
|
+
|
|
11620
|
+
declare interface ScreenRefreshResult {
|
|
11621
|
+
/** Active reads refetched. */
|
|
11622
|
+
queries: number;
|
|
11623
|
+
/** Registered loaders run. */
|
|
11624
|
+
loaders: number;
|
|
11625
|
+
/** Reads or loaders that answered with an error. */
|
|
11626
|
+
failed: number;
|
|
11627
|
+
ms: number;
|
|
11628
|
+
/** True when this call was folded into one already running or just finished. */
|
|
11629
|
+
coalesced?: boolean;
|
|
11630
|
+
}
|
|
11631
|
+
|
|
11632
|
+
declare interface ScreenRefreshState {
|
|
11633
|
+
phase: ScreenRefreshPhase;
|
|
11634
|
+
/** When the phase last changed (ms). */
|
|
11635
|
+
at: number;
|
|
11636
|
+
/** What asked for the last refresh ('button', 'palette', 'idle-…'). */
|
|
11637
|
+
reason: string | null;
|
|
11638
|
+
}
|
|
11639
|
+
|
|
11640
|
+
export declare function ScreenShareHost(): JSX.Element;
|
|
11641
|
+
|
|
11642
|
+
/** Nearest ancestor that scrolls vertically (the document's scroller as a last resort). */
|
|
11643
|
+
export declare function scrollParentOf(el: Element | null): HTMLElement | null;
|
|
11644
|
+
|
|
10600
11645
|
/** A child's position under `root` as child indexes ('0.2.1'); '' = root itself. */
|
|
10601
11646
|
export declare function scrollPathOf(root: Element, el: Element): string | null;
|
|
10602
11647
|
|
|
@@ -10644,6 +11689,30 @@ export declare function SearchHighlight({ text, query, synonyms, className, mark
|
|
|
10644
11689
|
*/
|
|
10645
11690
|
export declare function searchRankTier(values: ReadonlyArray<unknown>, q: string | null | undefined): number;
|
|
10646
11691
|
|
|
11692
|
+
/**
|
|
11693
|
+
* Live search results (realtime program 2026-11-14, item 14).
|
|
11694
|
+
*
|
|
11695
|
+
* The open results page follows other people's writes without anyone pressing reload:
|
|
11696
|
+
*
|
|
11697
|
+
* - a result whose record changed updates in place (same position, a short fade);
|
|
11698
|
+
* - a result that STOPS matching dims and stays where it is (nothing leaves under the
|
|
11699
|
+
* pointer) — it is gone on the next refresh;
|
|
11700
|
+
* - a record that newly matches is only COUNTED ("2 new matches · Show"); Show re-runs the
|
|
11701
|
+
* page's own query as the viewer. The client never works out matching itself.
|
|
11702
|
+
*
|
|
11703
|
+
* How it learns what changed: a `collection:update` for a collection on the page schedules ONE
|
|
11704
|
+
* re-ask (`fetchFresh`, the page's own permission-checked search, run as the viewer) — at most
|
|
11705
|
+
* one per `minGapMs`, none while the tab is hidden. Only records the events NAMED can dim or
|
|
11706
|
+
* count as new, so a result that merely moves down the ranking is neither.
|
|
11707
|
+
*/
|
|
11708
|
+
export declare interface SearchRow {
|
|
11709
|
+
collection: string;
|
|
11710
|
+
id: string | number;
|
|
11711
|
+
}
|
|
11712
|
+
|
|
11713
|
+
/** The one key a result row and an event agree on: `collection:ID` (ids compare upper-case). */
|
|
11714
|
+
export declare function searchRowKey(r: SearchRow): string;
|
|
11715
|
+
|
|
10647
11716
|
export declare interface SearchTextOptions {
|
|
10648
11717
|
/** Groups of interchangeable words/phrases; a token in a group also matches the rest. */
|
|
10649
11718
|
synonyms?: SynonymGroups;
|
|
@@ -10694,6 +11763,87 @@ declare interface SendInput {
|
|
|
10694
11763
|
urgent?: boolean;
|
|
10695
11764
|
}
|
|
10696
11765
|
|
|
11766
|
+
/**
|
|
11767
|
+
* "Send my view" — hand a colleague the screen you are on (this record, or this list / queue
|
|
11768
|
+
* with its filters, sort and columns). They open it as themselves: what they may read decides
|
|
11769
|
+
* what they see. Nothing of the records travels, only where to go and how the view is set up.
|
|
11770
|
+
*/
|
|
11771
|
+
export declare function SendViewButton({ getView, describe, compact, className }: {
|
|
11772
|
+
/** Read at send time, so the latest filters go. */
|
|
11773
|
+
getView: () => SendViewInput;
|
|
11774
|
+
/** What the person is about to send, in words ("Workflows — 2 filters"). */
|
|
11775
|
+
describe?: () => string;
|
|
11776
|
+
/** Icon-only, borderless — the record header's tool group. */
|
|
11777
|
+
compact?: boolean;
|
|
11778
|
+
className?: string;
|
|
11779
|
+
}): JSX.Element;
|
|
11780
|
+
|
|
11781
|
+
/**
|
|
11782
|
+
* "Send my view to Beth" (api routes/send-view.ts). What a screen hands over: which record,
|
|
11783
|
+
* list or queue, and the list's VIEW SETTINGS (the same `lv` envelope "Copy link" uses —
|
|
11784
|
+
* filters, sort, columns, page size). Never rows, never a record's values. The recipient
|
|
11785
|
+
* opens it as themselves.
|
|
11786
|
+
*/
|
|
11787
|
+
declare interface SendViewInput {
|
|
11788
|
+
kind: 'record' | 'list' | 'queue';
|
|
11789
|
+
collection?: string | null;
|
|
11790
|
+
item?: string | number | null;
|
|
11791
|
+
queue?: string | number | null;
|
|
11792
|
+
/** base64url `lv` envelope (lists and queues). */
|
|
11793
|
+
lv?: string | null;
|
|
11794
|
+
/** A record tab to land on. */
|
|
11795
|
+
tab?: string | null;
|
|
11796
|
+
/** The sender's own words for the filters, e.g. "Region NER, PUB'd". */
|
|
11797
|
+
summary?: string | null;
|
|
11798
|
+
}
|
|
11799
|
+
|
|
11800
|
+
/**
|
|
11801
|
+
* Configuration read back in plain English (#11, #10, #13).
|
|
11802
|
+
*
|
|
11803
|
+
* One pure module: every builder (field rules, cascade filters, alerts, flows,
|
|
11804
|
+
* owner groups, transitions, validation rules, show/lock conditions) and the
|
|
11805
|
+
* record form's "where does this come from?" turn their stored JSON into
|
|
11806
|
+
* sentences here, so a rule reads the same wherever it is shown.
|
|
11807
|
+
*
|
|
11808
|
+
* Rules:
|
|
11809
|
+
* - Nothing is fetched. Field labels, choice labels, record labels, role
|
|
11810
|
+
* names and collection names come in through `SentenceLabels`; a missing
|
|
11811
|
+
* label falls back to the key in title case.
|
|
11812
|
+
* - Sentences follow how the engines judge a rule: a "not" condition also
|
|
11813
|
+
* matches empty values in every evaluator here, so it says "(or is empty)".
|
|
11814
|
+
* - An unknown shape (an op, a type or a key this module does not know)
|
|
11815
|
+
* gives NO sentence — null — never a guess.
|
|
11816
|
+
*/
|
|
11817
|
+
declare interface SentenceLabels {
|
|
11818
|
+
/** field → label, for the collection the config belongs to. */
|
|
11819
|
+
fields?: Record<string, string>;
|
|
11820
|
+
/** field → type ('integer', 'decimal', 'date', 'boolean', …). */
|
|
11821
|
+
types?: Record<string, string>;
|
|
11822
|
+
/** field → stored value → choice label. */
|
|
11823
|
+
choices?: Record<string, Record<string, string>>;
|
|
11824
|
+
/** field → record id → that record's label (relation values). */
|
|
11825
|
+
records?: Record<string, Record<string, string>>;
|
|
11826
|
+
/** collection → label. */
|
|
11827
|
+
collections?: Record<string, string>;
|
|
11828
|
+
/** collection → field → label, for fields of OTHER collections. */
|
|
11829
|
+
relatedFields?: Record<string, Record<string, string>>;
|
|
11830
|
+
/** collection → field → value → choice label, for OTHER collections' fields. */
|
|
11831
|
+
relatedChoices?: Record<string, Record<string, Record<string, string>>>;
|
|
11832
|
+
/** link field → the collection it points at (M2O / lookup sources). */
|
|
11833
|
+
links?: Record<string, string>;
|
|
11834
|
+
/** role id → role name. */
|
|
11835
|
+
roles?: Record<string, string>;
|
|
11836
|
+
/** state id or key → state label. */
|
|
11837
|
+
states?: Record<string, string>;
|
|
11838
|
+
/** field → how numbers read. */
|
|
11839
|
+
formats?: Record<string, 'money' | 'percent' | 'number'>;
|
|
11840
|
+
}
|
|
11841
|
+
|
|
11842
|
+
export declare function SentViewCards({ routes, onNavigate }: {
|
|
11843
|
+
routes: NotificationRouteMap;
|
|
11844
|
+
onNavigate: (path: string) => void;
|
|
11845
|
+
}): JSX.Element | null;
|
|
11846
|
+
|
|
10697
11847
|
/**
|
|
10698
11848
|
* Server time (#2132). A machine whose clock drifts shows "2 minutes ago" for something that
|
|
10699
11849
|
* just happened and runs countdowns early or late. The host measures the offset between this
|
|
@@ -10762,6 +11912,9 @@ export declare function setFiscalStartMonth(m: number | null | undefined): void;
|
|
|
10762
11912
|
|
|
10763
11913
|
export declare function setFormulaConstants(map: Record<string, number> | null | undefined): void;
|
|
10764
11914
|
|
|
11915
|
+
/** Set the mode (the host does this from the profile; tests and tools may too). */
|
|
11916
|
+
export declare function setLiveMode(mode: LiveMode, source?: LiveModeSource): void;
|
|
11917
|
+
|
|
10765
11918
|
export declare function setNumberFormat(opts: {
|
|
10766
11919
|
locale?: string;
|
|
10767
11920
|
compact?: boolean;
|
|
@@ -10775,6 +11928,76 @@ export declare function setServerClockOffset(ms: number): void;
|
|
|
10775
11928
|
|
|
10776
11929
|
export declare function setTimeDisplay(mode: string | null | undefined): void;
|
|
10777
11930
|
|
|
11931
|
+
/**
|
|
11932
|
+
* Screens that update live without moving under the person (realtime program 2026-11-14).
|
|
11933
|
+
*
|
|
11934
|
+
* The live-query bridge (live-queries.ts) decides WHEN a screen's reads refetch. This file is
|
|
11935
|
+
* what a screen does with the fresh answer so the change lands quietly:
|
|
11936
|
+
*
|
|
11937
|
+
* - `useSettledRows` — a list whose rows may leave or arrive while someone works in it. Rows
|
|
11938
|
+
* never reorder under the pointer or keyboard focus, a row that left stays where it was in a
|
|
11939
|
+
* calm "departed" state until the person's next interaction away from it (never while the
|
|
11940
|
+
* pointer is on it or something holds it, like an open confirm), and rows that arrive while
|
|
11941
|
+
* the list is held are added at the end.
|
|
11942
|
+
* - `holdTopInserts` / `useTopInserts` — a newest-first feed (notifications): new rows slide in
|
|
11943
|
+
* at the top only while the person is scrolled at the top; otherwise they wait behind a quiet
|
|
11944
|
+
* "3 new" pill and the rows on screen keep their order.
|
|
11945
|
+
* - `useLiveFade` — the changed figure fades in (Web Animations; reduced motion: none). Only
|
|
11946
|
+
* text that changed while the screen was armed by a background refresh fades; first loads,
|
|
11947
|
+
* typing and the person's own clicks do not.
|
|
11948
|
+
* - `updatedAgoLabel` — "Updated 10 s ago" for a hover/focus-only footer.
|
|
11949
|
+
*
|
|
11950
|
+
* Nothing here reads data or talks to the server.
|
|
11951
|
+
*/
|
|
11952
|
+
export declare interface SettledRow<T> {
|
|
11953
|
+
key: string;
|
|
11954
|
+
row: T;
|
|
11955
|
+
/** `departed`: no longer in the server's answer, still shown (calmly) where it was. */
|
|
11956
|
+
state: 'live' | 'departed';
|
|
11957
|
+
}
|
|
11958
|
+
|
|
11959
|
+
export declare interface SettledRows<T> {
|
|
11960
|
+
rows: SettledRow<T>[];
|
|
11961
|
+
/** Put on the element that contains the rows (pointer / focus inside it holds the order). */
|
|
11962
|
+
containerRef: (el: HTMLElement | null) => void;
|
|
11963
|
+
/** The person's own action removed these: let them go at once (no departed state). */
|
|
11964
|
+
release: (keys: Iterable<string>) => void;
|
|
11965
|
+
/** Whether the list is holding its order right now (pointer or focus inside). */
|
|
11966
|
+
frozen: boolean;
|
|
11967
|
+
}
|
|
11968
|
+
|
|
11969
|
+
declare interface SettledRowsOptions {
|
|
11970
|
+
/** Off: the server's rows as they are (no holding, nothing departs). */
|
|
11971
|
+
enabled?: boolean;
|
|
11972
|
+
/** Keys that must not leave right now (an open confirm, a drawer on that row). */
|
|
11973
|
+
held?: Iterable<string>;
|
|
11974
|
+
/**
|
|
11975
|
+
* The person's own view (search, sort, filter, tab): when it changes, the new answer shows
|
|
11976
|
+
* as it is — rows their filter dropped are not "departed", a sort they asked for applies.
|
|
11977
|
+
*/
|
|
11978
|
+
resetKey?: string;
|
|
11979
|
+
}
|
|
11980
|
+
|
|
11981
|
+
declare interface SettleOptions {
|
|
11982
|
+
/** The pointer or keyboard focus is in the list: keep the order, append arrivals at the end. */
|
|
11983
|
+
frozen: boolean;
|
|
11984
|
+
/** Keys of departed rows that may now leave (an interaction happened since they left). */
|
|
11985
|
+
mayLeave?: ReadonlySet<string> | ((key: string) => boolean);
|
|
11986
|
+
/** Keys that never leave, whatever happened (pointer on it, its confirm is open). */
|
|
11987
|
+
held?: ReadonlySet<string>;
|
|
11988
|
+
/** Keys whose departure is expected (the person's own decision): they leave at once. */
|
|
11989
|
+
released?: ReadonlySet<string>;
|
|
11990
|
+
}
|
|
11991
|
+
|
|
11992
|
+
/**
|
|
11993
|
+
* Fold a fresh server answer into what is on screen (pure; exported for tests).
|
|
11994
|
+
*
|
|
11995
|
+
* Frozen: the shown order stays; rows still present take their new data in place, rows gone
|
|
11996
|
+
* from the answer stay as `departed`, new rows go to the end. Not frozen: the server's order,
|
|
11997
|
+
* with departed rows kept next to the row they followed until they may leave.
|
|
11998
|
+
*/
|
|
11999
|
+
export declare function settleRows<T>(prev: readonly SettledRow<T>[], next: readonly T[], keyOf: (row: T) => string, opts: SettleOptions): SettledRow<T>[];
|
|
12000
|
+
|
|
10778
12001
|
/**
|
|
10779
12002
|
* What a list shows right now, for the crumb / back link that returns to it ("My open ·
|
|
10780
12003
|
* page 3" → "Back to Workflows · My open · page 3"). The list component calls it on every
|
|
@@ -10838,6 +12061,39 @@ declare interface SheetItem {
|
|
|
10838
12061
|
*/
|
|
10839
12062
|
export declare function shouldUseWorkerSocket(url: string): boolean;
|
|
10840
12063
|
|
|
12064
|
+
/**
|
|
12065
|
+
* Missed-update detector (realtime idea 14).
|
|
12066
|
+
*
|
|
12067
|
+
* A reload is a person saying "I don't trust what this page shows". This finds out whether they
|
|
12068
|
+
* were right, without ever sending a value anywhere:
|
|
12069
|
+
*
|
|
12070
|
+
* 1. Before the page goes (pagehide) each live screen's shown records are stored in
|
|
12071
|
+
* sessionStorage as a small snapshot: per record (cap 200) its collection, id, when the screen
|
|
12072
|
+
* loaded it, when this tab last heard a live event naming it, and ONE HASH PER FIELD (cap 40
|
|
12073
|
+
* fields) — hashes only, never values.
|
|
12074
|
+
* 2. After a reload (PerformanceNavigationTiming type `reload`, same path, snapshot under two
|
|
12075
|
+
* minutes old) the same screens register their fresh data; each field's new hash is compared.
|
|
12076
|
+
* 3. A field whose hash changed counts as a MISSED UPDATE only when this tab heard no live event
|
|
12077
|
+
* for the record after it loaded it (an event it heard but did not show is a screen problem,
|
|
12078
|
+
* not a delivery one), and the record was loaded more than ~5 s before the reload (a change
|
|
12079
|
+
* that may still have been on its way is ignored).
|
|
12080
|
+
* 4. One beacon per reload: collection, record id, field NAMES, the page route and how long the
|
|
12081
|
+
* old value sat on screen (`gap_s`). Reloads that compared records and found nothing different
|
|
12082
|
+
* are counted too ("trust reloads"). The server classifies each miss (routes/realtime-trust).
|
|
12083
|
+
*
|
|
12084
|
+
* Screens take part with `useShownRecords(records)`; the detector starts with `startRum`.
|
|
12085
|
+
*/
|
|
12086
|
+
declare interface ShownRecord {
|
|
12087
|
+
collection: string;
|
|
12088
|
+
id: string | number;
|
|
12089
|
+
/** The values as shown (only hashed, on this device). */
|
|
12090
|
+
values: Record<string, unknown>;
|
|
12091
|
+
/** When the screen's data for this record arrived (react-query `dataUpdatedAt`). */
|
|
12092
|
+
loadedAt: number;
|
|
12093
|
+
/** Limit the hashed fields to these (default: every key but `id`). */
|
|
12094
|
+
fields?: string[];
|
|
12095
|
+
}
|
|
12096
|
+
|
|
10841
12097
|
/**
|
|
10842
12098
|
* Sign-out note (2026-11-10, Rob): the message an administrator left when
|
|
10843
12099
|
* signing a person out (api services/sign-out-note.ts). The person's open tabs
|
|
@@ -11018,6 +12274,15 @@ export declare interface SlaRule {
|
|
|
11018
12274
|
|
|
11019
12275
|
export declare function SlaRulesView(): JSX.Element;
|
|
11020
12276
|
|
|
12277
|
+
/**
|
|
12278
|
+
* Mark rows `keys` (matched by `data-live-key`) under `root` as just arrived. Text is never faded.
|
|
12279
|
+
* The row slides in 6 px (and is already readable); it carries an accent background that holds
|
|
12280
|
+
* ~2 s and then fades over ~1.5 s. The highlight and the dot carry state, so they show even with
|
|
12281
|
+
* reduced motion or Calm updates — only the slide is skipped there. A row that arrived while
|
|
12282
|
+
* nobody was looking gets a small dot in its gutter instead, cleared the first time it is in view.
|
|
12283
|
+
*/
|
|
12284
|
+
export declare function slideIn(root: ParentNode | null | undefined, keys: Iterable<string>): void;
|
|
12285
|
+
|
|
11021
12286
|
declare interface SlotAssignment {
|
|
11022
12287
|
field: string;
|
|
11023
12288
|
sort: number;
|
|
@@ -11183,6 +12448,11 @@ export declare function SnoozeMenu({ signal, signalLabel, rowKey, group, default
|
|
|
11183
12448
|
* - Missed events while connected (#2462): a room whose own counter (`_rseq`) skips is caught up
|
|
11184
12449
|
* alone (`catchup:room`); `realtime:stale` (#2460 — the server held this socket's broadcasts
|
|
11185
12450
|
* while it was too far behind) refetches the rooms it names and raises `nvr:realtime-stale`.
|
|
12451
|
+
* - Missed changes per record (realtime 23): a record whose own counter (`_iseq`) skips is
|
|
12452
|
+
* re-read alone (record-gaps.ts) — also after a reconnect whose catch-up went unanswered.
|
|
12453
|
+
* - Silent self-repair (realtime 24): a connection that says it is up but is dead is reopened
|
|
12454
|
+
* quietly (socket-liveness.ts; the shared worker runs its own); `status().repair` is
|
|
12455
|
+
* `'silent'` meanwhile, so the banner stays away unless the repair fails twice.
|
|
11186
12456
|
*
|
|
11187
12457
|
* The socket is duck-typed (socket.io-client's `Socket` fits), so this package takes no
|
|
11188
12458
|
* dependency on socket.io-client. It never decides what a viewer may see: every room is gated by
|
|
@@ -11589,6 +12859,8 @@ export declare interface SupportTicketDetail extends SupportTicket {
|
|
|
11589
12859
|
}>;
|
|
11590
12860
|
history: Array<{
|
|
11591
12861
|
id: number;
|
|
12862
|
+
/** The activity action (screen-share-start / -watch / -stop fold into one line). */
|
|
12863
|
+
action?: string | null;
|
|
11592
12864
|
text: string;
|
|
11593
12865
|
user: string | null;
|
|
11594
12866
|
user_name: string | null;
|
|
@@ -11639,6 +12911,19 @@ export declare function SupportView({ initialTicketId, onTicketChange, className
|
|
|
11639
12911
|
*/
|
|
11640
12912
|
export declare type SynonymGroups = ReadonlyArray<ReadonlyArray<string>>;
|
|
11641
12913
|
|
|
12914
|
+
/**
|
|
12915
|
+
* Puts what is waiting on the signed-in person in the browser tab: "(3) My Work · App" in
|
|
12916
|
+
* the title and a small numbered dot on the tab icon (the host's own icon, white-label
|
|
12917
|
+
* included). The number is the My Work figure — records you own, approvals and
|
|
12918
|
+
* questions — and follows it live. Profile → Display → "Count in the tab" turns it off.
|
|
12919
|
+
*
|
|
12920
|
+
* Mount ONCE per app shell (inside the query, Nivaro and realtime providers); renders nothing.
|
|
12921
|
+
* `extra` adds host-side items the My Work figure does not hold.
|
|
12922
|
+
*/
|
|
12923
|
+
export declare function TabCountHost({ extra }: {
|
|
12924
|
+
extra?: number;
|
|
12925
|
+
}): null;
|
|
12926
|
+
|
|
11642
12927
|
declare type TabKey = 'catalog' | 'rules' | 'subscriptions' | 'history' | 'widget_alerts' | 'widget_alert_history' | 'anomaly_rules' | 'anomaly_history';
|
|
11643
12928
|
|
|
11644
12929
|
/**
|
|
@@ -11847,6 +13132,23 @@ declare interface TopicPresence {
|
|
|
11847
13132
|
signalReplying: (active: boolean) => void;
|
|
11848
13133
|
}
|
|
11849
13134
|
|
|
13135
|
+
declare interface TopInsertResult<T> {
|
|
13136
|
+
rows: T[];
|
|
13137
|
+
/** New rows waiting above (shown once the person is at the top or presses the pill). */
|
|
13138
|
+
held: number;
|
|
13139
|
+
}
|
|
13140
|
+
|
|
13141
|
+
export declare interface TopInserts<T> {
|
|
13142
|
+
rows: T[];
|
|
13143
|
+
held: number;
|
|
13144
|
+
/** Show the held rows (scrolls the feed to the top). */
|
|
13145
|
+
reveal: () => void;
|
|
13146
|
+
/** Put on the feed's root element (its nearest scrolling ancestor is watched). */
|
|
13147
|
+
rootRef: (el: HTMLElement | null) => void;
|
|
13148
|
+
/** Keys that slid in with the last reveal (for the entrance animation). */
|
|
13149
|
+
arrived: ReadonlySet<string>;
|
|
13150
|
+
}
|
|
13151
|
+
|
|
11850
13152
|
/** Install the listeners. Safe to call more than once. */
|
|
11851
13153
|
export declare function trackActivity(): void;
|
|
11852
13154
|
|
|
@@ -12041,6 +13343,22 @@ export declare interface Typing {
|
|
|
12041
13343
|
setTyping: (active: boolean) => void;
|
|
12042
13344
|
}
|
|
12043
13345
|
|
|
13346
|
+
declare interface UiState {
|
|
13347
|
+
/** The narrow-screen sheet is open. */
|
|
13348
|
+
sheet: boolean;
|
|
13349
|
+
/** Pins someone else changed while the rows were not on screen (live, no read). */
|
|
13350
|
+
localChanged: ReadonlySet<string>;
|
|
13351
|
+
/** The viewport is wide enough to dock. */
|
|
13352
|
+
wide: boolean;
|
|
13353
|
+
/** What the dock knows, for the header icon: changed pins + unread mentions. */
|
|
13354
|
+
changed: number;
|
|
13355
|
+
unreadMentions: number;
|
|
13356
|
+
/** A dock is mounted in this app (the header icon renders nothing without one). */
|
|
13357
|
+
mounted: boolean;
|
|
13358
|
+
/** Pins this tab marked seen, and when (an answer read before the mark landed stays quiet). */
|
|
13359
|
+
seenLocal: ReadonlyMap<string, number>;
|
|
13360
|
+
}
|
|
13361
|
+
|
|
12044
13362
|
/** What is unsaved right now — the leave-page prompt, the changes tray and
|
|
12045
13363
|
* the host's own dirty indicator all read this one breakdown. */
|
|
12046
13364
|
declare interface UnsavedSummary {
|
|
@@ -12062,6 +13380,9 @@ declare interface UnsavedWorkOptions {
|
|
|
12062
13380
|
saveForReload?: () => boolean | Promise<boolean>;
|
|
12063
13381
|
}
|
|
12064
13382
|
|
|
13383
|
+
/** Footer text for a live figure's freshness; null before the first answer. */
|
|
13384
|
+
export declare function updatedAgoLabel(at: number | null | undefined, now?: number): string | null;
|
|
13385
|
+
|
|
12065
13386
|
/** The ids an update covers: one, a coalesced list, or null = "too many — refresh it all". */
|
|
12066
13387
|
export declare function updateItemIds(ev: CollectionUpdateEvent): Array<string | number> | null;
|
|
12067
13388
|
|
|
@@ -12171,9 +13492,13 @@ export declare function useAutoRecord(opts?: {
|
|
|
12171
13492
|
disabled?: boolean;
|
|
12172
13493
|
}): void;
|
|
12173
13494
|
|
|
13495
|
+
export declare function useAutoRefreshPref(scope: string): [boolean, (on: boolean) => void];
|
|
13496
|
+
|
|
12174
13497
|
/** Available actions per collection, for the viewer. */
|
|
12175
13498
|
export declare function useAvailableBulkActions(collections: string[]): UseQueryResult<NoInfer<Record<string, AvailableBulkAction[]>>, Error>;
|
|
12176
13499
|
|
|
13500
|
+
export declare function useBackgroundArm(updatedAt: number | undefined, resetKey?: string): number;
|
|
13501
|
+
|
|
12177
13502
|
declare interface UseBackgroundRun {
|
|
12178
13503
|
phase: BackgroundPhase;
|
|
12179
13504
|
/** The usual duration the server knows, ms. */
|
|
@@ -12202,6 +13527,14 @@ declare interface UseBackgroundRunOptions {
|
|
|
12202
13527
|
onGone?: () => void;
|
|
12203
13528
|
}
|
|
12204
13529
|
|
|
13530
|
+
/**
|
|
13531
|
+
* The change chip for one figure. `storeKey` names the person and the figure
|
|
13532
|
+
* (`<user id>:<figure key>`); `value` is what the figure shows now — pass null while it is
|
|
13533
|
+
* loading or failed (a placeholder is never a baseline). Returns null for non-count values and
|
|
13534
|
+
* while nothing has moved.
|
|
13535
|
+
*/
|
|
13536
|
+
export declare function useChangeChip(storeKey: string, value: string | null | undefined, enabled?: boolean): DeltaChip | null;
|
|
13537
|
+
|
|
12205
13538
|
export declare function useChannelAdmin(channelId: number | null): {
|
|
12206
13539
|
update: UseMutationResult<unknown, Error, {
|
|
12207
13540
|
name?: string;
|
|
@@ -12276,7 +13609,7 @@ export declare function useChatRooms(): {
|
|
|
12276
13609
|
|
|
12277
13610
|
export declare function useChatSearch(q: string, filters?: ChatSearchFilters): {
|
|
12278
13611
|
hits: ChatSearchHit[];
|
|
12279
|
-
meaning: "
|
|
13612
|
+
meaning: "words" | "model" | null;
|
|
12280
13613
|
loading: boolean;
|
|
12281
13614
|
};
|
|
12282
13615
|
|
|
@@ -12424,6 +13757,8 @@ export declare function useFormStatus(form: UseNivaroFormReturn): FormStatus;
|
|
|
12424
13757
|
|
|
12425
13758
|
export declare function useGridFlush(): GridFlushContextValue | null;
|
|
12426
13759
|
|
|
13760
|
+
export declare function useGridPresence(opts: GridPresenceOptions): GridPresence;
|
|
13761
|
+
|
|
12427
13762
|
export declare function useHelpVideo(id: string | null): UseQueryResult<NoInfer<HelpVideoDto>, Error>;
|
|
12428
13763
|
|
|
12429
13764
|
/**
|
|
@@ -12547,6 +13882,37 @@ export declare function useLayoutEditingQuiet(editing: boolean): {
|
|
|
12547
13882
|
settle: (saved: Promise<unknown>) => void;
|
|
12548
13883
|
};
|
|
12549
13884
|
|
|
13885
|
+
export declare function useLineLocks(opts: {
|
|
13886
|
+
/** The line collection (the inline grid's related collection). */
|
|
13887
|
+
collection: string | null | undefined;
|
|
13888
|
+
/** The saved lines on screen. */
|
|
13889
|
+
rowIds: string[];
|
|
13890
|
+
/** The parent collection has line locks on, and this grid is editable. */
|
|
13891
|
+
enabled: boolean;
|
|
13892
|
+
}): LineLocks;
|
|
13893
|
+
|
|
13894
|
+
/** Who else has this list open (empty for non-administrators — the server sends them nothing). */
|
|
13895
|
+
export declare function useListViewers(kind: 'list' | 'queue', id: string | number | null | undefined, enabled?: boolean,
|
|
13896
|
+
/** Who "me" is, for hosts outside an ItemEditAuthContext (a page header). */
|
|
13897
|
+
selfId?: string): ListViewer[];
|
|
13898
|
+
|
|
13899
|
+
export declare function useLiveCalendar<T>(opts: LiveCalendarOptions<T>): LiveCalendar<T>;
|
|
13900
|
+
|
|
13901
|
+
/**
|
|
13902
|
+
* Fade in what changed under the element when `armKey` changes (pass the time the screen's data
|
|
13903
|
+
* was refreshed in the background — not on first load). Returns a callback ref for the element.
|
|
13904
|
+
* Changes seen up to 0.6 s before the arm and for `windowMs` after it fade; anything else (the
|
|
13905
|
+
* first render, typing, opening a menu) does not. Order does not matter: an arm set in an
|
|
13906
|
+
* effect after the refreshed rows were drawn still fades them.
|
|
13907
|
+
*/
|
|
13908
|
+
export declare function useLiveFade(armKey: unknown, opts?: LiveFadeOptions): (el: HTMLElement | null) => void;
|
|
13909
|
+
|
|
13910
|
+
/**
|
|
13911
|
+
* Join the admin `jobs` watch room and re-read `keys` once per quiet window after a run
|
|
13912
|
+
* starts or finishes. Returns whether events can arrive (hosts keep a slow poll as the net).
|
|
13913
|
+
*/
|
|
13914
|
+
export declare function useLiveJobs(opts: LiveJobsOptions): boolean;
|
|
13915
|
+
|
|
12550
13916
|
/**
|
|
12551
13917
|
* A list read (`readItems` query), kept current: rows others change are re-read as the viewer
|
|
12552
13918
|
* and patched in place, rows that stop matching leave, deletes drop out, and anything whose
|
|
@@ -12555,6 +13921,9 @@ export declare function useLayoutEditingQuiet(editing: boolean): {
|
|
|
12555
13921
|
*/
|
|
12556
13922
|
export declare function useLiveList<T extends Record<string, unknown> = Record<string, unknown>>(collection: string | null | undefined, query?: Query<T>, opts?: LiveListOptions): LiveListResult<T>;
|
|
12557
13923
|
|
|
13924
|
+
/** The person's live-updates setting; re-renders when it changes (any tab). */
|
|
13925
|
+
export declare function useLivePreference(): LivePreference;
|
|
13926
|
+
|
|
12558
13927
|
/** Whether a bridge is mounted for this QueryClient (tagged queries refresh on events). */
|
|
12559
13928
|
export declare function useLiveQueriesOn(): boolean;
|
|
12560
13929
|
|
|
@@ -12582,6 +13951,17 @@ export declare function useLiveRefetchInterval(base: number | false | undefined,
|
|
|
12582
13951
|
enabled?: boolean;
|
|
12583
13952
|
}): number | false | undefined;
|
|
12584
13953
|
|
|
13954
|
+
/**
|
|
13955
|
+
* Re-read `keys` through their normal routes when `topic` pokes (or `onReady`'s source does),
|
|
13956
|
+
* at most once per quiet window per tab. Only mounted (active) queries refetch; the rest are
|
|
13957
|
+
* marked stale. Without a realtime adapter nothing is poked and the queries keep their own poll.
|
|
13958
|
+
*/
|
|
13959
|
+
export declare function useLiveRefresh(opts: LiveRefreshOptions): void;
|
|
13960
|
+
|
|
13961
|
+
export declare function useLiveSearchResults<T extends SearchRow>(opts: LiveSearchOptions<T>): LiveSearchState<T>;
|
|
13962
|
+
|
|
13963
|
+
export declare function useLiveWidget(opts: LiveWidgetOptions): boolean;
|
|
13964
|
+
|
|
12585
13965
|
/**
|
|
12586
13966
|
* Mark read. The server upserts against UNIQUE(user, room), so the old
|
|
12587
13967
|
* select-then-insert dance (and the per-room promise chain that stopped it
|
|
@@ -12684,6 +14064,9 @@ export declare type UseNivaroFormReturn = {
|
|
|
12684
14064
|
*/
|
|
12685
14065
|
export declare function useNotificationSoundPreference(): string;
|
|
12686
14066
|
|
|
14067
|
+
/** A "now" that ticks (countdowns and "ago" labels move without a refetch). */
|
|
14068
|
+
export declare function useNowTick(everyMs?: number, enabled?: boolean): number;
|
|
14069
|
+
|
|
12687
14070
|
/**
|
|
12688
14071
|
* Online-user set for presence dots in user pickers (#284); consumers get a
|
|
12689
14072
|
* Set of upper-cased user ids. Shares the chat's ['presence-online'] entry —
|
|
@@ -12733,6 +14116,16 @@ summary: IntegrationPartnersSummary;
|
|
|
12733
14116
|
partners: IntegrationPartnerCard[];
|
|
12734
14117
|
}>, Error>;
|
|
12735
14118
|
|
|
14119
|
+
/**
|
|
14120
|
+
* The record-link click handler every surface uses. Pass the click (for the new-tab rule)
|
|
14121
|
+
* and, from a list, the list's records in order (for ↑ / ↓ in the sheet). Returns what it did.
|
|
14122
|
+
*/
|
|
14123
|
+
export declare function usePeekOrOpen(): (target: PeekTarget, e?: (ClickLike & {
|
|
14124
|
+
preventDefault?: () => void;
|
|
14125
|
+
}) | null, opts?: {
|
|
14126
|
+
list?: PeekTarget[];
|
|
14127
|
+
}) => PeekDecision;
|
|
14128
|
+
|
|
12736
14129
|
export declare function usePeerReadAt(room: string | null): string | null;
|
|
12737
14130
|
|
|
12738
14131
|
export declare function usePersonProfile(userId: string | null | undefined): UseQueryResult<NoInfer<PersonProfileData | null>, Error>;
|
|
@@ -12809,6 +14202,9 @@ export declare function UserChip({ userId, size, children }: {
|
|
|
12809
14202
|
/** The host's connection state, or null when the host gives none (no realtime, or no status). */
|
|
12810
14203
|
export declare function useRealtimeStatus(): RealtimeStatus | null;
|
|
12811
14204
|
|
|
14205
|
+
/** The agents on one record right now; [] when there are none or live presence is quiet. */
|
|
14206
|
+
export declare function useRecordAgents(collection: string | null | undefined, item: string | number | null | undefined): RecordAgent[];
|
|
14207
|
+
|
|
12812
14208
|
/** Integration events about one record, newest first, one page at a time. */
|
|
12813
14209
|
export declare function useRecordIntegrationActivity(collection: string, item: string, page: number): UseQueryResult<NoInfer<{
|
|
12814
14210
|
entries: IntegrationEvent[];
|
|
@@ -12816,8 +14212,15 @@ page: number;
|
|
|
12816
14212
|
has_more: boolean;
|
|
12817
14213
|
}>, Error>;
|
|
12818
14214
|
|
|
12819
|
-
/**
|
|
12820
|
-
export declare function
|
|
14215
|
+
/** The app's record sheet, or null when the host mounted none. */
|
|
14216
|
+
export declare function useRecordPeek(): RecordPeekApi | null;
|
|
14217
|
+
|
|
14218
|
+
/** Names of the OTHER people currently signalling `kind` on this record. `field`: only the
|
|
14219
|
+
* signals about that field's comment thread (null = only the record's own thread); omitted =
|
|
14220
|
+
* every signal of the kind this viewer receives. */
|
|
14221
|
+
export declare function useRecordSignalPeers(collection: string | null | undefined, item: string | number | null | undefined, kind: RecordSignalKind, opts?: {
|
|
14222
|
+
field?: string | null;
|
|
14223
|
+
}): string[];
|
|
12821
14224
|
|
|
12822
14225
|
/**
|
|
12823
14226
|
* While `active`, tell the record's other viewers (start now, then every SIGNAL_BEAT_MS);
|
|
@@ -12858,6 +14261,10 @@ export declare function useRequiredVideos(): UseQueryResult<NoInfer<HelpVideoDto
|
|
|
12858
14261
|
*/
|
|
12859
14262
|
export declare function userErrorMessage(err: unknown, fallback?: string): string;
|
|
12860
14263
|
|
|
14264
|
+
export declare function useResolvedFindings(opts: ResolvedFindingsOptions): {
|
|
14265
|
+
resolved: ReadonlyMap<string, ResolvedMark>;
|
|
14266
|
+
};
|
|
14267
|
+
|
|
12861
14268
|
export declare function useRoomMembership(): {
|
|
12862
14269
|
join: UseMutationResult<unknown, Error, string, unknown>;
|
|
12863
14270
|
leave: UseMutationResult<unknown, Error, string, unknown>;
|
|
@@ -12933,10 +14340,19 @@ export declare function UserRosterCluster({ users, showSingleName, nameLabel, st
|
|
|
12933
14340
|
declare interface UserSyncOptions {
|
|
12934
14341
|
/** The host refetches whatever it keeps preferences in (the admin's auth user). */
|
|
12935
14342
|
onPrefsChanged?: () => void;
|
|
14343
|
+
/** The host refetches its signed-in user (permissions, menus). Default: onPrefsChanged,
|
|
14344
|
+
* which every host already points at its auth user. */
|
|
14345
|
+
onAccessChanged?: () => void;
|
|
12936
14346
|
}
|
|
12937
14347
|
|
|
12938
14348
|
export declare function useScopeDimensions(): ScopeDimensionLite[];
|
|
12939
14349
|
|
|
14350
|
+
/** Hook form: the latest `run` is called on every screen refresh while mounted. */
|
|
14351
|
+
export declare function useScreenLoader(run: Loader, enabled?: boolean): void;
|
|
14352
|
+
|
|
14353
|
+
/** The refresh state for a button or a status line. */
|
|
14354
|
+
export declare function useScreenRefreshState(): ScreenRefreshState;
|
|
14355
|
+
|
|
12940
14356
|
export declare function useSectionState(form: UseNivaroFormReturn, defaultCollapsed?: string[]): SectionState;
|
|
12941
14357
|
|
|
12942
14358
|
/**
|
|
@@ -12955,6 +14371,19 @@ export declare function useSessionRecorder(options?: SessionRecorderOptions): vo
|
|
|
12955
14371
|
/** Write one staleness setting: a number of hours, 0 (not monitored) or null (back to default). */
|
|
12956
14372
|
export declare function useSetImportCadence(): UseMutationResult<unknown, Error, Record<string, number | null>, unknown>;
|
|
12957
14373
|
|
|
14374
|
+
/**
|
|
14375
|
+
* `settleRows` with the person's pointer, focus and interactions wired in. A departed row
|
|
14376
|
+
* leaves at the first moment when the person has interacted (pointer down or a key) since it
|
|
14377
|
+
* left, the list is not held (pointer and focus outside it), and nothing holds the row.
|
|
14378
|
+
*/
|
|
14379
|
+
export declare function useSettledRows<T>(rows: readonly T[] | undefined, keyOf: (row: T) => string, opts?: SettledRowsOptions): SettledRows<T>;
|
|
14380
|
+
|
|
14381
|
+
/**
|
|
14382
|
+
* A live screen says what it shows (the latest list is read only when the page goes and right
|
|
14383
|
+
* after a reload, so this costs nothing per render beyond a ref write).
|
|
14384
|
+
*/
|
|
14385
|
+
export declare function useShownRecords(records: ShownRecord[] | null | undefined | (() => ShownRecord[] | null | undefined)): void;
|
|
14386
|
+
|
|
12958
14387
|
export declare function useSignalAction(): UseMutationResult<IntegrationActionResult[], Error, {
|
|
12959
14388
|
signal: string;
|
|
12960
14389
|
row_keys: string[];
|
|
@@ -13016,6 +14445,15 @@ emoji: string;
|
|
|
13016
14445
|
*/
|
|
13017
14446
|
export declare function useTopicPresence(topic: string | null | undefined, selfId?: string | null): TopicPresence;
|
|
13018
14447
|
|
|
14448
|
+
/**
|
|
14449
|
+
* `holdTopInserts` wired to the feed's scroller. `resetKey` (a filter, a page) starts over:
|
|
14450
|
+
* whatever the new view's first answer is shows as it is.
|
|
14451
|
+
*/
|
|
14452
|
+
export declare function useTopInserts<T>(rows: readonly T[] | undefined, keyOf: (row: T) => string, opts?: {
|
|
14453
|
+
enabled?: boolean;
|
|
14454
|
+
resetKey?: string;
|
|
14455
|
+
}): TopInserts<T>;
|
|
14456
|
+
|
|
13019
14457
|
/** "Beth is writing a note" on a record's comment thread, both directions. */
|
|
13020
14458
|
export declare function useTyping(collection: string | null | undefined, item: string | number | null | undefined): Typing;
|
|
13021
14459
|
|
|
@@ -13031,6 +14469,9 @@ export declare function useUnreadChirp(totalUnread: number, rooms?: RoomInfo[]):
|
|
|
13031
14469
|
* pushed reload — the latest function is always the one called). */
|
|
13032
14470
|
export declare function useUnsavedWork(dirty: boolean, label?: string, saveForReload?: () => boolean | Promise<boolean>): void;
|
|
13033
14471
|
|
|
14472
|
+
/** `updatedAgoLabel` that re-reads the clock every 5 s while `active` (hovered / focused). */
|
|
14473
|
+
export declare function useUpdatedAgo(at: number | null | undefined, active: boolean): string | null;
|
|
14474
|
+
|
|
13034
14475
|
/** Directory of users to add to a private channel. */
|
|
13035
14476
|
export declare function useUserSearch(search: string, enabled: boolean): {
|
|
13036
14477
|
users: NoInfer<{
|
|
@@ -13044,8 +14485,20 @@ export declare function useUserSearch(search: string, enabled: boolean): {
|
|
|
13044
14485
|
|
|
13045
14486
|
export declare function useUserSync(opts?: UserSyncOptions): void;
|
|
13046
14487
|
|
|
14488
|
+
export declare function useWatchActions(): WatchActions & {
|
|
14489
|
+
prefs: WatchPrefs;
|
|
14490
|
+
};
|
|
14491
|
+
|
|
13047
14492
|
export declare function useWatchFields(form: UseNivaroFormReturn, fields: string[]): Record<string, unknown>;
|
|
13048
14493
|
|
|
14494
|
+
/** The stored list (pins + dock). Null client (no provider) = an empty, inert list. */
|
|
14495
|
+
export declare function useWatchPrefs(): {
|
|
14496
|
+
prefs: WatchPrefs;
|
|
14497
|
+
ready: boolean;
|
|
14498
|
+
};
|
|
14499
|
+
|
|
14500
|
+
export declare function useWatchUi(): UiState;
|
|
14501
|
+
|
|
13049
14502
|
/**
|
|
13050
14503
|
* Authoring-time check. The point of separating this from evaluation is that
|
|
13051
14504
|
* a formula can be told it is wrong while it is being written, instead of
|
|
@@ -13217,6 +14670,259 @@ export declare interface WalkStep {
|
|
|
13217
14670
|
text: string | null;
|
|
13218
14671
|
}
|
|
13219
14672
|
|
|
14673
|
+
declare interface WatchActions {
|
|
14674
|
+
isPinned: (collection: string, id: string | number) => boolean;
|
|
14675
|
+
pin: (collection: string, id: string | number) => Promise<void>;
|
|
14676
|
+
unpin: (collection: string, id: string | number) => Promise<void>;
|
|
14677
|
+
toggle: (collection: string, id: string | number) => Promise<boolean>;
|
|
14678
|
+
setDock: (patchDock: Partial<WatchDockPrefs>) => void;
|
|
14679
|
+
reorder: (keys: string[]) => void;
|
|
14680
|
+
markSeen: (keys?: string[]) => void;
|
|
14681
|
+
full: boolean;
|
|
14682
|
+
setSettings: (patch: Partial<WatchSettings>) => Promise<void>;
|
|
14683
|
+
addAlert: (input: {
|
|
14684
|
+
collection: string;
|
|
14685
|
+
id: string;
|
|
14686
|
+
kind: WatchAlertKind;
|
|
14687
|
+
step?: string;
|
|
14688
|
+
field?: string;
|
|
14689
|
+
label?: string;
|
|
14690
|
+
repeat: boolean;
|
|
14691
|
+
}) => Promise<void>;
|
|
14692
|
+
removeAlert: (alertId: string) => Promise<void>;
|
|
14693
|
+
createTeam: (input: {
|
|
14694
|
+
name: string;
|
|
14695
|
+
members: string[];
|
|
14696
|
+
reports?: boolean;
|
|
14697
|
+
remove_completed?: boolean;
|
|
14698
|
+
}) => Promise<string | null>;
|
|
14699
|
+
editTeam: (id: string, patch: {
|
|
14700
|
+
name?: string;
|
|
14701
|
+
members?: string[];
|
|
14702
|
+
remove_completed?: boolean;
|
|
14703
|
+
}) => Promise<void>;
|
|
14704
|
+
/** Undo a removal: the record goes back on the list (and stays). */
|
|
14705
|
+
restoreRemoved: (collection: string, id: string, teamId?: string) => Promise<void>;
|
|
14706
|
+
deleteTeam: (id: string) => Promise<void>;
|
|
14707
|
+
leaveTeam: (id: string) => Promise<void>;
|
|
14708
|
+
/** An administrator takes over a list whose maker is gone; answers the list's new id. */
|
|
14709
|
+
takeOverTeam: (id: string) => Promise<string | null>;
|
|
14710
|
+
teamPin: (teamId: string, collection: string, id: string) => Promise<void>;
|
|
14711
|
+
teamUnpin: (teamId: string, collection: string, id: string) => Promise<void>;
|
|
14712
|
+
teamSeen: (teamId: string, keys?: string[]) => void;
|
|
14713
|
+
}
|
|
14714
|
+
|
|
14715
|
+
declare type WatchAlertKind = 'step' | 'field' | 'overdue';
|
|
14716
|
+
|
|
14717
|
+
declare interface WatchAlertRef {
|
|
14718
|
+
id: string;
|
|
14719
|
+
/** "collection:id" of the record. */
|
|
14720
|
+
key: string;
|
|
14721
|
+
kind: WatchAlertKind;
|
|
14722
|
+
step: string | null;
|
|
14723
|
+
field: string | null;
|
|
14724
|
+
label: string | null;
|
|
14725
|
+
repeat: boolean;
|
|
14726
|
+
fired_at: string | null;
|
|
14727
|
+
}
|
|
14728
|
+
|
|
14729
|
+
export declare function WatchDock(): JSX.Element | null;
|
|
14730
|
+
|
|
14731
|
+
declare interface WatchDockPrefs {
|
|
14732
|
+
state: DockState;
|
|
14733
|
+
width: number;
|
|
14734
|
+
tab: DockTab;
|
|
14735
|
+
sort: DockSort;
|
|
14736
|
+
}
|
|
14737
|
+
|
|
14738
|
+
export declare const watchKeys: {
|
|
14739
|
+
all: readonly ["watch-list"];
|
|
14740
|
+
prefs: readonly ["watch-list", "prefs"];
|
|
14741
|
+
rows: (sig: string) => readonly ["watch-list", "rows", string];
|
|
14742
|
+
summary: (sig: string) => readonly ["watch-list", "summary", string];
|
|
14743
|
+
waiting: readonly ["watch-list", "waiting"];
|
|
14744
|
+
mentions: readonly ["watch-list", "mentions"];
|
|
14745
|
+
team: (id: string, sig: string) => readonly ["watch-list", "team", string, string];
|
|
14746
|
+
alertOptions: (collection: string, id: string) => readonly ["watch-list", "alert-options", string, string];
|
|
14747
|
+
};
|
|
14748
|
+
|
|
14749
|
+
/**
|
|
14750
|
+
* The app-header icon for the watch list (rt5 #1). Wide screens: it opens a closed or
|
|
14751
|
+
* minimized dock and closes an open one. Narrow screens (and phones): it opens the dock as a
|
|
14752
|
+
* sheet. A small dot says a pinned record changed, or a mention waits, while the list was
|
|
14753
|
+
* out of sight. Renders nothing in an app without a dock.
|
|
14754
|
+
*
|
|
14755
|
+
* `variant`: 'rail' = the admin's dark icon rail; 'bar' = a light/dark top bar.
|
|
14756
|
+
*/
|
|
14757
|
+
export declare function WatchListButton({ variant, className, ringClass }: {
|
|
14758
|
+
variant?: 'rail' | 'bar';
|
|
14759
|
+
className?: string;
|
|
14760
|
+
/** The dot's ring = the bar's own background, so the dot reads as cut out of it. */
|
|
14761
|
+
ringClass?: string;
|
|
14762
|
+
}): JSX.Element | null;
|
|
14763
|
+
|
|
14764
|
+
export declare function WatchPinButton({ collection, itemId, shortcut, size, className }: {
|
|
14765
|
+
collection: string;
|
|
14766
|
+
itemId: string | number | null | undefined;
|
|
14767
|
+
shortcut?: boolean;
|
|
14768
|
+
size?: 'sm' | 'md';
|
|
14769
|
+
className?: string;
|
|
14770
|
+
}): JSX.Element | null;
|
|
14771
|
+
|
|
14772
|
+
declare interface WatchPinRef {
|
|
14773
|
+
key: string;
|
|
14774
|
+
collection: string;
|
|
14775
|
+
id: string;
|
|
14776
|
+
pinned_at: string;
|
|
14777
|
+
/** Added automatically (the record landed on the person's step). */
|
|
14778
|
+
auto?: boolean;
|
|
14779
|
+
/** When the record was completed (the list removes completed records). */
|
|
14780
|
+
done_at?: string | null;
|
|
14781
|
+
}
|
|
14782
|
+
|
|
14783
|
+
declare interface WatchPrefs {
|
|
14784
|
+
pins: WatchPinRef[];
|
|
14785
|
+
dock: WatchDockPrefs;
|
|
14786
|
+
replies_seen_at: string | null;
|
|
14787
|
+
max: number;
|
|
14788
|
+
settings: WatchSettings;
|
|
14789
|
+
alerts: WatchAlertRef[];
|
|
14790
|
+
teams: WatchTeam[];
|
|
14791
|
+
/** Taken off because they were completed (7 days, Undo puts one back). */
|
|
14792
|
+
removed: WatchRemovedRef[];
|
|
14793
|
+
/** How many direct reports the person has (a manager may add their team in one go). */
|
|
14794
|
+
direct_reports?: number;
|
|
14795
|
+
/** The signed-in person (only on the prefs read). */
|
|
14796
|
+
me?: {
|
|
14797
|
+
id: string;
|
|
14798
|
+
name: string;
|
|
14799
|
+
};
|
|
14800
|
+
}
|
|
14801
|
+
|
|
14802
|
+
/** A record taken off because it was completed ("Recently removed", 7 days). */
|
|
14803
|
+
declare interface WatchRemovedRef {
|
|
14804
|
+
key: string;
|
|
14805
|
+
collection: string;
|
|
14806
|
+
id: string;
|
|
14807
|
+
title: string | null;
|
|
14808
|
+
done_at: string;
|
|
14809
|
+
removed_at: string;
|
|
14810
|
+
}
|
|
14811
|
+
|
|
14812
|
+
declare interface WatchSettings {
|
|
14813
|
+
desktop: boolean;
|
|
14814
|
+
auto_add: boolean;
|
|
14815
|
+
auto_remove: boolean;
|
|
14816
|
+
digest: boolean;
|
|
14817
|
+
/** Completed records leave the list (24 h after, or once seen); 7 days to undo. */
|
|
14818
|
+
remove_completed: boolean;
|
|
14819
|
+
}
|
|
14820
|
+
|
|
14821
|
+
declare interface WatchTeam {
|
|
14822
|
+
id: string;
|
|
14823
|
+
name: string;
|
|
14824
|
+
owner: {
|
|
14825
|
+
id: string;
|
|
14826
|
+
name: string;
|
|
14827
|
+
};
|
|
14828
|
+
members: Array<{
|
|
14829
|
+
id: string;
|
|
14830
|
+
name: string;
|
|
14831
|
+
}>;
|
|
14832
|
+
pins: Array<{
|
|
14833
|
+
key: string;
|
|
14834
|
+
collection: string;
|
|
14835
|
+
id: string;
|
|
14836
|
+
pinned_at: string;
|
|
14837
|
+
by: string;
|
|
14838
|
+
done_at?: string | null;
|
|
14839
|
+
}>;
|
|
14840
|
+
/** The owner's switch: completed records leave this list. */
|
|
14841
|
+
remove_completed?: boolean;
|
|
14842
|
+
removed?: WatchRemovedRef[];
|
|
14843
|
+
can_manage: boolean;
|
|
14844
|
+
is_member: boolean;
|
|
14845
|
+
/** Its maker can no longer sign in: read-only until an administrator takes it over. */
|
|
14846
|
+
owner_gone?: boolean;
|
|
14847
|
+
can_take_over?: boolean;
|
|
14848
|
+
}
|
|
14849
|
+
|
|
14850
|
+
export declare const watchUi: {
|
|
14851
|
+
publish(counts: {
|
|
14852
|
+
changed: number;
|
|
14853
|
+
unreadMentions: number;
|
|
14854
|
+
}): void;
|
|
14855
|
+
setMounted(mounted: boolean): void;
|
|
14856
|
+
openSheet: () => void;
|
|
14857
|
+
closeSheet: () => void;
|
|
14858
|
+
markLocal(keys: string[]): void;
|
|
14859
|
+
noteSeen(keys: string[] | null, pins: string[]): void;
|
|
14860
|
+
clearLocal(keys?: string[]): void;
|
|
14861
|
+
};
|
|
14862
|
+
|
|
14863
|
+
/** Hosts mark their own chrome (menu button, title row, toolbars) with this. */
|
|
14864
|
+
export declare const WIDGET_IMAGE_IGNORE_ATTR = "data-widget-image-ignore";
|
|
14865
|
+
|
|
14866
|
+
export declare interface WidgetImageInput {
|
|
14867
|
+
title: string;
|
|
14868
|
+
/** When the figures were read; defaults to now. */
|
|
14869
|
+
asOf?: Date | number | string;
|
|
14870
|
+
/** Dashboard-level filters (field/op/value). */
|
|
14871
|
+
dashboardFilters?: Array<{
|
|
14872
|
+
field: string;
|
|
14873
|
+
op?: string;
|
|
14874
|
+
value: unknown;
|
|
14875
|
+
}> | null;
|
|
14876
|
+
/** Report date range. */
|
|
14877
|
+
dateRange?: {
|
|
14878
|
+
preset?: string;
|
|
14879
|
+
start?: string;
|
|
14880
|
+
end?: string;
|
|
14881
|
+
} | null;
|
|
14882
|
+
/** Report entity filters. */
|
|
14883
|
+
entityFilters?: Array<{
|
|
14884
|
+
field: string;
|
|
14885
|
+
values: Array<string | number>;
|
|
14886
|
+
labels?: string[];
|
|
14887
|
+
}> | null;
|
|
14888
|
+
/** The widget's own filter (object or JSON text). */
|
|
14889
|
+
widgetFilter?: unknown;
|
|
14890
|
+
/** The widget's own `{field, op, value}` rules (report widgets). */
|
|
14891
|
+
widgetRules?: Array<{
|
|
14892
|
+
field?: string;
|
|
14893
|
+
op?: string;
|
|
14894
|
+
value?: unknown;
|
|
14895
|
+
}> | null;
|
|
14896
|
+
/** Extra plain-word lines a host wants on the picture. */
|
|
14897
|
+
extra?: string[];
|
|
14898
|
+
labels?: SentenceLabels;
|
|
14899
|
+
}
|
|
14900
|
+
|
|
14901
|
+
export declare interface WidgetImageLabel {
|
|
14902
|
+
title: string;
|
|
14903
|
+
asOf: string;
|
|
14904
|
+
/** Every filter in effect, one plain sentence each; empty = none. */
|
|
14905
|
+
filters: string[];
|
|
14906
|
+
}
|
|
14907
|
+
|
|
14908
|
+
/**
|
|
14909
|
+
* The ⋯ menu on a dashboard / report widget: "Copy as image" and "Download
|
|
14910
|
+
* PNG". The picture is the widget as it is on screen, in the light theme on
|
|
14911
|
+
* white, with the title, "As of <time>" and the filters in effect printed on
|
|
14912
|
+
* top — ready for an email or Teams message.
|
|
14913
|
+
*
|
|
14914
|
+
* `getTarget` returns the widget card element; the host marks its own chrome
|
|
14915
|
+
* (title row, buttons) with `data-widget-image-ignore` so it is left out.
|
|
14916
|
+
* `label` is read when the item is chosen, so it always carries the filters
|
|
14917
|
+
* in effect right then.
|
|
14918
|
+
*/
|
|
14919
|
+
export declare function WidgetImageMenu({ getTarget, label, className, align }: {
|
|
14920
|
+
getTarget: () => HTMLElement | null;
|
|
14921
|
+
label: WidgetImageInput | (() => WidgetImageInput);
|
|
14922
|
+
className?: string;
|
|
14923
|
+
align?: 'start' | 'center' | 'end';
|
|
14924
|
+
}): JSX.Element;
|
|
14925
|
+
|
|
13220
14926
|
export declare function WidgetSlot({ widgetId, inputBindings, itemDraft, itemCollection, ready, label, defaultExpanded, frameless, apiBase: apiBaseProp, compact, strip, onClientAction, onWidgetType, onContentChange }: WidgetSlotProps): JSX.Element | null;
|
|
13221
14927
|
|
|
13222
14928
|
declare interface WidgetSlotProps {
|