@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
|
@@ -1,65 +1,80 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { CopyCheck as
|
|
3
|
-
import { formatNumber as
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { jsx as o, jsxs as r } from "react/jsx-runtime";
|
|
2
|
+
import { CopyCheck as n } from "lucide-react";
|
|
3
|
+
import { formatNumber as s, cn as m } from "../../lib/utils.js";
|
|
4
|
+
function c({ skipped: e, className: a }) {
|
|
5
|
+
return e != null && e.length ? /* @__PURE__ */ r(
|
|
6
|
+
"p",
|
|
7
|
+
{
|
|
8
|
+
"data-import-duplicates-skipped": !0,
|
|
9
|
+
className: m("text-[11px] text-slate-500 dark:text-muted-foreground", a),
|
|
10
|
+
children: [
|
|
11
|
+
"Not checked for duplicates: ",
|
|
12
|
+
e.join("; "),
|
|
13
|
+
"."
|
|
14
|
+
]
|
|
15
|
+
}
|
|
16
|
+
) : null;
|
|
17
|
+
}
|
|
18
|
+
const i = (e, a, l) => e === 1 ? a : l;
|
|
19
|
+
function p({ dup: e }) {
|
|
6
20
|
const a = e.exact_rows + e.close_rows + e.in_file_rows;
|
|
7
|
-
if (a === 0) return
|
|
8
|
-
const
|
|
9
|
-
e.exact_rows > 0 && `${
|
|
10
|
-
e.close_rows > 0 && `${
|
|
11
|
-
e.in_file_rows > 0 && `${
|
|
21
|
+
if (a === 0) return /* @__PURE__ */ o(c, { skipped: e.skipped });
|
|
22
|
+
const l = [
|
|
23
|
+
e.exact_rows > 0 && `${s(e.exact_rows)} ${i(e.exact_rows, "copies", "copy")} an existing record`,
|
|
24
|
+
e.close_rows > 0 && `${s(e.close_rows)} ${i(e.close_rows, "nearly copies", "nearly copy")} one`,
|
|
25
|
+
e.in_file_rows > 0 && `${s(e.in_file_rows)} ${i(e.in_file_rows, "repeats", "repeat")} an earlier row`
|
|
12
26
|
].filter(Boolean);
|
|
13
|
-
return /* @__PURE__ */
|
|
27
|
+
return /* @__PURE__ */ r(
|
|
14
28
|
"div",
|
|
15
29
|
{
|
|
16
30
|
"data-import-duplicates": !0,
|
|
17
31
|
className: "rounded-md border border-amber-200 bg-amber-50 px-3 py-2 dark:border-amber-500/30 dark:bg-amber-500/10",
|
|
18
32
|
children: [
|
|
19
|
-
/* @__PURE__ */
|
|
20
|
-
/* @__PURE__ */
|
|
21
|
-
/* @__PURE__ */
|
|
22
|
-
|
|
33
|
+
/* @__PURE__ */ r("p", { className: "flex items-start gap-1.5 text-[12px] font-medium text-amber-800 dark:text-amber-300", children: [
|
|
34
|
+
/* @__PURE__ */ o(n, { className: "mt-[2px] h-3.5 w-3.5 shrink-0", "aria-hidden": !0 }),
|
|
35
|
+
/* @__PURE__ */ r("span", { children: [
|
|
36
|
+
s(a),
|
|
23
37
|
" new ",
|
|
24
|
-
|
|
38
|
+
i(a, "row", "rows"),
|
|
25
39
|
" would create a duplicate",
|
|
26
40
|
" — ",
|
|
27
|
-
|
|
41
|
+
l.join(", ")
|
|
28
42
|
] })
|
|
29
43
|
] }),
|
|
30
|
-
/* @__PURE__ */
|
|
44
|
+
/* @__PURE__ */ r("p", { className: "mt-0.5 pl-5 text-[11px] text-amber-700/90 dark:text-amber-300/80", children: [
|
|
31
45
|
"Compared on ",
|
|
32
46
|
e.fields.join(", "),
|
|
33
47
|
". To update the existing records instead, choose a match field; otherwise remove these rows from the file."
|
|
34
48
|
] }),
|
|
35
|
-
/* @__PURE__ */
|
|
36
|
-
/* @__PURE__ */
|
|
49
|
+
/* @__PURE__ */ o("ul", { className: "mt-1 max-h-32 space-y-0.5 overflow-y-auto pl-5 text-[11.5px] text-amber-800 dark:text-amber-200", children: e.rows.map((t) => /* @__PURE__ */ r("li", { "data-import-duplicate-row": t.row, children: [
|
|
50
|
+
/* @__PURE__ */ r("span", { className: "text-amber-600/80 dark:text-amber-400/70", children: [
|
|
37
51
|
"Row ",
|
|
38
|
-
|
|
52
|
+
t.row,
|
|
39
53
|
":"
|
|
40
54
|
] }),
|
|
41
55
|
" ",
|
|
42
|
-
/* @__PURE__ */
|
|
56
|
+
/* @__PURE__ */ o("span", { className: "font-medium", children: t.value }),
|
|
43
57
|
" ",
|
|
44
|
-
/* @__PURE__ */
|
|
58
|
+
/* @__PURE__ */ o(
|
|
45
59
|
"span",
|
|
46
60
|
{
|
|
47
|
-
className:
|
|
48
|
-
|
|
61
|
+
className: m(
|
|
62
|
+
t.match === "exact" ? "text-amber-800 dark:text-amber-200" : "text-amber-700/80 dark:text-amber-300/70"
|
|
49
63
|
),
|
|
50
|
-
children:
|
|
64
|
+
children: t.first_row != null ? `repeats row ${t.first_row}` : t.match === "exact" ? "already exists" : `looks like “${t.existing_value ?? ""}”`
|
|
51
65
|
}
|
|
52
66
|
)
|
|
53
|
-
] }, `${
|
|
54
|
-
e.rows.length < e.exact_rows + e.close_rows + e.in_file_rows && /* @__PURE__ */
|
|
67
|
+
] }, `${t.row}-${t.field}`)) }),
|
|
68
|
+
e.rows.length < e.exact_rows + e.close_rows + e.in_file_rows && /* @__PURE__ */ r("p", { className: "mt-0.5 pl-5 text-[11px] text-amber-700/80 dark:text-amber-300/70", children: [
|
|
55
69
|
"First ",
|
|
56
|
-
|
|
70
|
+
s(e.rows.length),
|
|
57
71
|
" shown."
|
|
58
|
-
] })
|
|
72
|
+
] }),
|
|
73
|
+
/* @__PURE__ */ o(c, { skipped: e.skipped, className: "mt-0.5 pl-5" })
|
|
59
74
|
]
|
|
60
75
|
}
|
|
61
76
|
);
|
|
62
77
|
}
|
|
63
78
|
export {
|
|
64
|
-
|
|
79
|
+
p as ImportDuplicatesNotice
|
|
65
80
|
};
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
import { jsx as d, jsxs as m } from "react/jsx-runtime";
|
|
2
|
+
import { useQuery as _, useQueryClient as q, useMutation as M } from "@tanstack/react-query";
|
|
3
|
+
import { RefreshCw as $, PauseCircle as D, CloudOff as L, XCircle as F, CheckCircle2 as P, Clock as Q, Loader2 as g, Send as j } from "lucide-react";
|
|
4
|
+
import { useState as K, useEffect as W, useMemo as B, useRef as O } from "react";
|
|
5
|
+
import { useNivaroClient as k } from "../../context.js";
|
|
6
|
+
import { get as V, post as X } from "../../lib/commands.js";
|
|
7
|
+
import { toastError as Y } from "../../lib/error-toast.js";
|
|
8
|
+
import { useLiveRecordQueries as z, LIVE_ASPECTS as G } from "../../lib/live.js";
|
|
9
|
+
import { useLiveFade as H } from "../../lib/live-screen.js";
|
|
10
|
+
import { sendStatusWords as w, retryCountdown as S, msUntilNoAnswer as J, msUntilRetryTick as U } from "../../lib/send-status.js";
|
|
11
|
+
import { cn as f } from "../../lib/utils.js";
|
|
12
|
+
const N = "send-status";
|
|
13
|
+
function v(e) {
|
|
14
|
+
const t = "text-sky-600 dark:text-sky-400", n = "text-amber-600 dark:text-amber-400";
|
|
15
|
+
if (e.retry_at) return { Icon: $, cls: t, label: "Retrying" };
|
|
16
|
+
switch (e.state) {
|
|
17
|
+
case "sending":
|
|
18
|
+
return {
|
|
19
|
+
Icon: g,
|
|
20
|
+
cls: `${t} animate-spin motion-reduce:animate-none`,
|
|
21
|
+
label: "Sending"
|
|
22
|
+
};
|
|
23
|
+
case "waiting":
|
|
24
|
+
return { Icon: Q, cls: t, label: "Waiting" };
|
|
25
|
+
case "accepted":
|
|
26
|
+
return {
|
|
27
|
+
Icon: P,
|
|
28
|
+
cls: "text-emerald-600 dark:text-emerald-400",
|
|
29
|
+
label: "Accepted"
|
|
30
|
+
};
|
|
31
|
+
case "refused":
|
|
32
|
+
return { Icon: F, cls: "text-rose-600 dark:text-rose-400", label: "Refused" };
|
|
33
|
+
case "not_taken":
|
|
34
|
+
return { Icon: L, cls: n, label: "Not sent" };
|
|
35
|
+
default:
|
|
36
|
+
return { Icon: D, cls: n, label: "No answer" };
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
function C(e) {
|
|
40
|
+
const [t, n] = K(() => Date.now());
|
|
41
|
+
return W(() => {
|
|
42
|
+
let r = null;
|
|
43
|
+
const s = () => {
|
|
44
|
+
const o = Date.now(), a = (Array.isArray(e) ? e : []).flatMap((l) => [J(l, o), U(l, o)]).filter((l) => l != null);
|
|
45
|
+
a.length !== 0 && (r = setTimeout(
|
|
46
|
+
() => {
|
|
47
|
+
n(Date.now()), s();
|
|
48
|
+
},
|
|
49
|
+
Math.min(...a)
|
|
50
|
+
));
|
|
51
|
+
};
|
|
52
|
+
return s(), () => {
|
|
53
|
+
r && clearTimeout(r);
|
|
54
|
+
};
|
|
55
|
+
}, [e]), t;
|
|
56
|
+
}
|
|
57
|
+
function Z(e, t) {
|
|
58
|
+
const n = S(e.retry_at, t);
|
|
59
|
+
return [e.text + (n ? ` · ${n}` : ""), e.detail].filter(Boolean).join(" · ");
|
|
60
|
+
}
|
|
61
|
+
function ee(e) {
|
|
62
|
+
const t = O(null);
|
|
63
|
+
return t.current == null && e && (t.current = e), e && e !== t.current ? e : 0;
|
|
64
|
+
}
|
|
65
|
+
function te(e, t) {
|
|
66
|
+
const n = k(), r = String(t);
|
|
67
|
+
return _({
|
|
68
|
+
queryKey: [N, e, r],
|
|
69
|
+
queryFn: () => n.request(
|
|
70
|
+
V("/erp-submissions/send-status", { collection: e, ids: r })
|
|
71
|
+
).then((s) => {
|
|
72
|
+
var a;
|
|
73
|
+
const o = (a = s == null ? void 0 : s.data) == null ? void 0 : a[r];
|
|
74
|
+
return Array.isArray(o) ? o : [];
|
|
75
|
+
}),
|
|
76
|
+
enabled: !!e && !!r && r !== "new",
|
|
77
|
+
staleTime: 3e4,
|
|
78
|
+
retry: !1
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
function pe({
|
|
82
|
+
collection: e,
|
|
83
|
+
item: t,
|
|
84
|
+
skipIds: n,
|
|
85
|
+
className: r
|
|
86
|
+
}) {
|
|
87
|
+
const s = k(), o = q(), a = String(t), l = B(() => [N, e, a], [e, a]), { data: u, dataUpdatedAt: A } = te(e, a);
|
|
88
|
+
z(e, a, [l], {
|
|
89
|
+
aspects: [G.integrations],
|
|
90
|
+
client: o,
|
|
91
|
+
debounceMs: 800
|
|
92
|
+
});
|
|
93
|
+
const b = C(u), I = H(ee(A)), p = M({
|
|
94
|
+
mutationFn: (i) => s.request(X(`/erp-submissions/${i}/retry`, {})),
|
|
95
|
+
onSuccess: () => void o.invalidateQueries({ queryKey: l }),
|
|
96
|
+
onError: (i) => Y(i, "Could not send it again")
|
|
97
|
+
}), R = new Set(n ?? []), h = (Array.isArray(u) ? u : []).filter((i) => !R.has(i.id));
|
|
98
|
+
return h.length === 0 ? null : /* @__PURE__ */ d(
|
|
99
|
+
"div",
|
|
100
|
+
{
|
|
101
|
+
ref: I,
|
|
102
|
+
"data-send-status": !0,
|
|
103
|
+
className: f(
|
|
104
|
+
"space-y-1 border-t border-slate-100 px-4 py-2 dark:border-border/60",
|
|
105
|
+
r
|
|
106
|
+
),
|
|
107
|
+
children: h.map((i) => {
|
|
108
|
+
const c = w(i, { now: b }), { Icon: T, cls: E } = v(c), x = S(c.retry_at, b), y = p.isPending && p.variables === i.id;
|
|
109
|
+
return /* @__PURE__ */ m(
|
|
110
|
+
"div",
|
|
111
|
+
{
|
|
112
|
+
"data-send-state": c.state,
|
|
113
|
+
className: "flex items-start gap-2 text-[12px] leading-snug text-slate-700 dark:text-slate-300",
|
|
114
|
+
children: [
|
|
115
|
+
/* @__PURE__ */ d(T, { "aria-hidden": !0, className: f("mt-[2px] h-3.5 w-3.5 shrink-0", E) }),
|
|
116
|
+
/* @__PURE__ */ m("div", { className: "min-w-0 flex-1", children: [
|
|
117
|
+
/* @__PURE__ */ m("p", { className: "break-words", children: [
|
|
118
|
+
c.text,
|
|
119
|
+
x && // rt6 #18 — the countdown to the automatic retry, quiet beside the sentence.
|
|
120
|
+
/* @__PURE__ */ m(
|
|
121
|
+
"span",
|
|
122
|
+
{
|
|
123
|
+
"data-send-retry-countdown": !0,
|
|
124
|
+
className: "ml-1.5 whitespace-nowrap text-[11px] tabular-nums text-slate-500 dark:text-slate-400",
|
|
125
|
+
children: [
|
|
126
|
+
"· ",
|
|
127
|
+
x
|
|
128
|
+
]
|
|
129
|
+
}
|
|
130
|
+
)
|
|
131
|
+
] }),
|
|
132
|
+
c.detail && /* @__PURE__ */ d(
|
|
133
|
+
"p",
|
|
134
|
+
{
|
|
135
|
+
"data-send-no-retry": !0,
|
|
136
|
+
className: "mt-0.5 break-words text-[11px] text-slate-500 dark:text-slate-400",
|
|
137
|
+
children: c.detail
|
|
138
|
+
}
|
|
139
|
+
)
|
|
140
|
+
] }),
|
|
141
|
+
c.resend && /* @__PURE__ */ m(
|
|
142
|
+
"button",
|
|
143
|
+
{
|
|
144
|
+
type: "button",
|
|
145
|
+
"data-send-again": i.id,
|
|
146
|
+
disabled: p.isPending,
|
|
147
|
+
onClick: () => p.mutate(i.id),
|
|
148
|
+
className: "inline-flex shrink-0 items-center gap-1.5 rounded-md border border-slate-200 bg-white px-2 py-1 text-[11.5px] font-medium text-slate-700 transition-colors hover:bg-slate-50 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-nvr-cyan/60 disabled:opacity-60 dark:border-border dark:bg-transparent dark:text-slate-200 dark:hover:bg-white/5",
|
|
149
|
+
children: [
|
|
150
|
+
y ? /* @__PURE__ */ d(
|
|
151
|
+
g,
|
|
152
|
+
{
|
|
153
|
+
"aria-hidden": !0,
|
|
154
|
+
className: "h-3 w-3 animate-spin motion-reduce:animate-none"
|
|
155
|
+
}
|
|
156
|
+
) : /* @__PURE__ */ d(j, { "aria-hidden": !0, className: "h-3 w-3" }),
|
|
157
|
+
y ? "Sending…" : "Send again"
|
|
158
|
+
]
|
|
159
|
+
}
|
|
160
|
+
)
|
|
161
|
+
]
|
|
162
|
+
},
|
|
163
|
+
i.id
|
|
164
|
+
);
|
|
165
|
+
})
|
|
166
|
+
}
|
|
167
|
+
);
|
|
168
|
+
}
|
|
169
|
+
function fe({
|
|
170
|
+
facts: e,
|
|
171
|
+
className: t
|
|
172
|
+
}) {
|
|
173
|
+
const n = C(Array.isArray(e) ? e : void 0);
|
|
174
|
+
return !Array.isArray(e) || e.length === 0 ? null : /* @__PURE__ */ d(
|
|
175
|
+
"span",
|
|
176
|
+
{
|
|
177
|
+
"data-send-status-marks": !0,
|
|
178
|
+
className: f("inline-flex shrink-0 items-center gap-1", t),
|
|
179
|
+
children: e.map((r) => {
|
|
180
|
+
const s = w(r, { now: n }), { Icon: o, cls: a, label: l } = v(s), u = Z(s, n);
|
|
181
|
+
return /* @__PURE__ */ d(
|
|
182
|
+
"span",
|
|
183
|
+
{
|
|
184
|
+
"data-send-state": s.state,
|
|
185
|
+
"data-tip": u,
|
|
186
|
+
"aria-label": `${r.api}: ${l}. ${u}`,
|
|
187
|
+
role: "img",
|
|
188
|
+
className: "inline-flex shrink-0",
|
|
189
|
+
children: /* @__PURE__ */ d(o, { "aria-hidden": !0, className: f("h-3.5 w-3.5", a) })
|
|
190
|
+
},
|
|
191
|
+
r.id
|
|
192
|
+
);
|
|
193
|
+
})
|
|
194
|
+
}
|
|
195
|
+
);
|
|
196
|
+
}
|
|
197
|
+
export {
|
|
198
|
+
N as SEND_STATUS_KEY,
|
|
199
|
+
pe as SendStatusLines,
|
|
200
|
+
fe as SendStatusMarks,
|
|
201
|
+
te as useRecordSendStatus
|
|
202
|
+
};
|
|
@@ -1,37 +1,41 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { useState as
|
|
1
|
+
import { jsx as r, jsxs as u } from "react/jsx-runtime";
|
|
2
|
+
import { useState as b } from "react";
|
|
3
3
|
import { cn as t } from "../../../lib/utils.js";
|
|
4
|
-
import {
|
|
4
|
+
import { LiveCount as L } from "../../LiveCount.js";
|
|
5
|
+
import { TipLayer as S } from "../../TipLayer.js";
|
|
5
6
|
import { AlertsView as j } from "./AlertsView.js";
|
|
6
|
-
import { useSignals as F } from "./api.js";
|
|
7
|
-
import { EventsView as
|
|
8
|
-
import { FirefightView as
|
|
9
|
-
import { InboundView as
|
|
10
|
-
import { PartnersView as
|
|
7
|
+
import { useSignals as F, useLiveIntegrations as O } from "./api.js";
|
|
8
|
+
import { EventsView as P } from "./EventsView.js";
|
|
9
|
+
import { FirefightView as A } from "./FirefightView.js";
|
|
10
|
+
import { InboundView as J } from "./InboundView.js";
|
|
11
|
+
import { PartnersView as _ } from "./PartnersView.js";
|
|
12
|
+
import { ReadyToSendView as C } from "./ReadyToSendView.js";
|
|
11
13
|
import { TONE_SOFT as g, TONE_TEXT as v } from "./tone.js";
|
|
12
|
-
function
|
|
14
|
+
function Y({
|
|
13
15
|
extraTabs: y = [],
|
|
14
|
-
tab:
|
|
16
|
+
tab: s,
|
|
15
17
|
onTabChange: i,
|
|
16
|
-
onOpenRecord:
|
|
18
|
+
onOpenRecord: a,
|
|
17
19
|
focusSignal: k,
|
|
18
|
-
inboundExtra:
|
|
19
|
-
className:
|
|
20
|
+
inboundExtra: w,
|
|
21
|
+
className: h
|
|
20
22
|
}) {
|
|
21
23
|
var p;
|
|
22
|
-
const [x, I] =
|
|
23
|
-
|
|
24
|
-
|
|
24
|
+
const [x, I] = b("firefight"), N = s ?? x, [T, d] = b(null), E = F();
|
|
25
|
+
O();
|
|
26
|
+
const l = (e) => {
|
|
27
|
+
s == null && I(e), i == null || i(e);
|
|
28
|
+
}, m = (((p = E.data) == null ? void 0 : p.signals) ?? []).filter((e) => !e.error), c = m.reduce((e, n) => e + n.count, 0), V = m.some((e) => e.severity === "critical" && e.count > 0), o = [
|
|
25
29
|
{
|
|
26
30
|
key: "firefight",
|
|
27
31
|
label: "Firefight",
|
|
28
|
-
render: () => /* @__PURE__ */
|
|
29
|
-
|
|
32
|
+
render: () => /* @__PURE__ */ r(
|
|
33
|
+
A,
|
|
30
34
|
{
|
|
31
|
-
onOpenRecord:
|
|
35
|
+
onOpenRecord: a,
|
|
32
36
|
focusSignal: k,
|
|
33
|
-
onJumpTab: (e,
|
|
34
|
-
e === "partners" && (
|
|
37
|
+
onJumpTab: (e, n) => {
|
|
38
|
+
e === "partners" && (n == null ? void 0 : n.apiId) != null && d(Number(n.apiId)), l(e);
|
|
35
39
|
}
|
|
36
40
|
}
|
|
37
41
|
)
|
|
@@ -39,23 +43,28 @@ function M({
|
|
|
39
43
|
{
|
|
40
44
|
key: "partners",
|
|
41
45
|
label: "Partners",
|
|
42
|
-
render: () => /* @__PURE__ */
|
|
46
|
+
render: () => /* @__PURE__ */ r(_, { openId: T, onOpenChange: d })
|
|
43
47
|
},
|
|
44
48
|
{
|
|
45
49
|
key: "events",
|
|
46
50
|
label: "Events",
|
|
47
|
-
render: () => /* @__PURE__ */
|
|
51
|
+
render: () => /* @__PURE__ */ r(P, { onOpenRecord: a })
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
key: "ready",
|
|
55
|
+
label: "Ready to send",
|
|
56
|
+
render: () => /* @__PURE__ */ r(C, { onOpenRecord: a })
|
|
48
57
|
},
|
|
49
58
|
...y,
|
|
50
59
|
{
|
|
51
60
|
key: "inbound",
|
|
52
61
|
label: "Inbound",
|
|
53
|
-
render: () => /* @__PURE__ */
|
|
62
|
+
render: () => /* @__PURE__ */ r(J, { extra: w })
|
|
54
63
|
},
|
|
55
64
|
{
|
|
56
65
|
key: "alerts",
|
|
57
66
|
label: "Alerts",
|
|
58
|
-
render: () => /* @__PURE__ */
|
|
67
|
+
render: () => /* @__PURE__ */ r(
|
|
59
68
|
j,
|
|
60
69
|
{
|
|
61
70
|
tabLabels: Object.fromEntries(o.map((e) => [e.key, e.label])),
|
|
@@ -64,38 +73,38 @@ function M({
|
|
|
64
73
|
)
|
|
65
74
|
}
|
|
66
75
|
], f = o.find((e) => e.key === N) ?? o[0];
|
|
67
|
-
return /* @__PURE__ */
|
|
68
|
-
/* @__PURE__ */
|
|
69
|
-
/* @__PURE__ */
|
|
76
|
+
return /* @__PURE__ */ u("div", { className: t("flex flex-col gap-5", h), "data-ic-console": !0, children: [
|
|
77
|
+
/* @__PURE__ */ r(S, {}),
|
|
78
|
+
/* @__PURE__ */ r(
|
|
70
79
|
"div",
|
|
71
80
|
{
|
|
72
81
|
role: "tablist",
|
|
73
82
|
"aria-label": "Integrations",
|
|
74
83
|
className: "flex shrink-0 gap-6 overflow-x-auto overflow-y-hidden border-b border-border [scrollbar-width:none]",
|
|
75
84
|
children: o.map((e) => {
|
|
76
|
-
const
|
|
77
|
-
return /* @__PURE__ */
|
|
85
|
+
const n = e.key === f.key;
|
|
86
|
+
return /* @__PURE__ */ u(
|
|
78
87
|
"button",
|
|
79
88
|
{
|
|
80
89
|
type: "button",
|
|
81
90
|
role: "tab",
|
|
82
|
-
"aria-selected":
|
|
91
|
+
"aria-selected": n,
|
|
83
92
|
"data-ic-tab": e.key,
|
|
84
93
|
onClick: () => l(e.key),
|
|
85
94
|
className: t(
|
|
86
95
|
"inline-flex shrink-0 items-center gap-2 whitespace-nowrap border-b-2 pb-2.5 pt-1 text-[13px] font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring",
|
|
87
|
-
|
|
96
|
+
n ? "border-nvr-cyan text-foreground" : "border-transparent text-muted-foreground hover:text-foreground"
|
|
88
97
|
),
|
|
89
98
|
children: [
|
|
90
99
|
e.label,
|
|
91
|
-
e.key === "firefight" &&
|
|
100
|
+
e.key === "firefight" && c > 0 && /* @__PURE__ */ r(
|
|
92
101
|
"span",
|
|
93
102
|
{
|
|
94
103
|
className: t(
|
|
95
104
|
"rounded-full px-1.5 py-px text-[11px] font-semibold tabular-nums",
|
|
96
105
|
V ? t(g.negative, v.negative) : t(g.warning, v.warning)
|
|
97
106
|
),
|
|
98
|
-
children:
|
|
107
|
+
children: /* @__PURE__ */ r(L, { value: c })
|
|
99
108
|
}
|
|
100
109
|
)
|
|
101
110
|
]
|
|
@@ -105,9 +114,9 @@ function M({
|
|
|
105
114
|
})
|
|
106
115
|
}
|
|
107
116
|
),
|
|
108
|
-
/* @__PURE__ */
|
|
117
|
+
/* @__PURE__ */ r("div", { role: "tabpanel", className: "min-w-0", children: f.render() })
|
|
109
118
|
] });
|
|
110
119
|
}
|
|
111
120
|
export {
|
|
112
|
-
|
|
121
|
+
Y as IntegrationsConsole
|
|
113
122
|
};
|