@nivaro/react 0.3.138 → 0.3.140
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/InlineGridField.js +95 -92
- package/dist/full.css +1 -1
- package/dist/hooks/useSessionRecorder.js +1 -1
- package/dist/index.d.ts +36 -2
- package/dist/shared/components/AudienceConfirmPanel.js +19 -19
- package/dist/shared/components/BroadcastView.js +213 -211
- package/dist/shared/components/CollectionBrowserView.js +2677 -2658
- package/dist/shared/components/ConfigHistory.js +45 -45
- package/dist/shared/components/ConformanceView.js +110 -110
- package/dist/shared/components/DataTable.js +51 -51
- package/dist/shared/components/FilePreviewLightbox.js +26 -25
- package/dist/shared/components/ItemEditForm.js +3038 -3027
- package/dist/shared/components/LiveCount.js +27 -23
- package/dist/shared/components/LiveTraceView.js +62 -61
- package/dist/shared/components/PageRenderer.js +422 -410
- package/dist/shared/components/ProfileView.js +199 -199
- package/dist/shared/components/QualityRulesView.js +70 -70
- package/dist/shared/components/QueryTable.js +131 -130
- package/dist/shared/components/RecordGraph.js +98 -98
- package/dist/shared/components/RecordReadView.js +287 -288
- package/dist/shared/components/ReportView.js +1279 -1259
- package/dist/shared/components/SlaRulesView.js +73 -74
- package/dist/shared/components/WidgetSlot.js +73 -73
- package/dist/shared/components/ai/AiChart.js +36 -32
- package/dist/shared/components/ai/AiMarkdown.js +136 -129
- package/dist/shared/components/ai/TaskDo.js +87 -87
- package/dist/shared/components/ai/answer-formats.js +37 -30
- package/dist/shared/components/ai/call-log/format.js +17 -16
- package/dist/shared/components/bulk/BulkActionButtons.js +66 -66
- package/dist/shared/components/bulk/BulkFieldUpdate.js +59 -59
- package/dist/shared/components/bulk/BulkSelectionNotices.js +34 -34
- package/dist/shared/components/bulk/MessageStakeholders.js +31 -29
- package/dist/shared/components/bulk/PushBulkButtons.js +83 -82
- package/dist/shared/components/bulk/bulk-field-options.js +10 -10
- package/dist/shared/components/cbv/column-totals.js +53 -51
- package/dist/shared/components/chat/ChatAnalyticsView.js +87 -87
- package/dist/shared/components/collections-directory/CollectionsToolbar.js +18 -18
- package/dist/shared/components/command-center/announce.js +7 -6
- package/dist/shared/components/command-center/panels/AttentionPanel.js +32 -31
- package/dist/shared/components/command-center/panels/FlowPanel.js +29 -28
- package/dist/shared/components/command-center/panels/PeoplePanel.js +39 -39
- package/dist/shared/components/delegation/DelegationConsoleView.js +27 -27
- package/dist/shared/components/imports/RunDetailSheet.js +1 -1
- package/dist/shared/components/integrations/IntegrationObligationsView.js +119 -119
- package/dist/shared/components/integrations/console/EventsView.js +35 -35
- package/dist/shared/components/integrations/console/FirefightView.js +15 -14
- package/dist/shared/components/integrations/console/PartnerDetail.js +78 -78
- package/dist/shared/components/integrations/console/ReadyToSendView.js +103 -103
- package/dist/shared/components/integrations/console/SignalCard.js +67 -67
- package/dist/shared/components/item-edit/CatalogPickerField.js +536 -527
- package/dist/shared/components/item-edit/ChangesTray.js +88 -74
- package/dist/shared/components/item-edit/FilePickerField.js +123 -123
- package/dist/shared/components/item-edit/GroupSection.js +301 -292
- package/dist/shared/components/item-edit/HeaderSummaryChip.js +54 -54
- package/dist/shared/components/item-edit/InlineGridField.js +45 -36
- package/dist/shared/components/item-edit/InlineTableField.js +1167 -1153
- package/dist/shared/components/item-edit/NestedRelationEditor.js +106 -99
- package/dist/shared/components/item-edit/RecordChatMentionsChip.js +11 -11
- package/dist/shared/components/layout-editor/ai-forms/SlimPanel.js +43 -44
- package/dist/shared/components/monitoring/ApiRequestLog.js +35 -35
- package/dist/shared/components/notifications/NotificationCenterView.js +268 -268
- package/dist/shared/components/ops-report/format.js +37 -36
- package/dist/shared/components/panels/ReferencedByPanel.js +21 -20
- package/dist/shared/components/panels/RevisionsPanel.js +306 -305
- package/dist/shared/components/pipeline/OwnerMatrixVersionsCard.js +12 -12
- package/dist/shared/components/pipeline/PipelineEditorView.js +483 -482
- package/dist/shared/components/pipeline/PipelineHealthCards.js +33 -32
- package/dist/shared/components/pipeline/TeamsView.js +189 -130
- package/dist/shared/components/profile/AgentsPanel.js +6 -6
- package/dist/shared/components/profile/DelegationCard.js +13 -12
- package/dist/shared/components/profile/PersonActivity.js +48 -48
- package/dist/shared/components/profile/PersonExtras.js +107 -107
- package/dist/shared/components/profile/PersonWeek.js +9 -9
- package/dist/shared/components/queue/QueueBulkBar.js +19 -18
- package/dist/shared/components/queue/QueueBulkMove.js +21 -20
- package/dist/shared/components/queue/QueueItemSheet.js +136 -131
- package/dist/shared/components/queue/QueueWorklist.js +671 -670
- package/dist/shared/components/queue/worklist-helpers.js +36 -21
- package/dist/shared/components/support/RequestList.js +121 -121
- package/dist/shared/components/support/SupportAnalytics.js +29 -29
- package/dist/shared/lib/activity-sentence.js +316 -278
- package/dist/shared/lib/format-value.js +5 -4
- package/dist/shared/lib/number-format.js +87 -0
- package/dist/shared/lib/number-kind.js +133 -0
- package/dist/shared/lib/utils.js +24 -20
- package/dist/shared/lib/watch-list.js +1 -1
- package/dist/shared/lib/widget-value-format.js +26 -12
- package/package.json +1 -1
|
@@ -1,20 +1,21 @@
|
|
|
1
|
+
import { formatCurrency as u } from "../../lib/number-format.js";
|
|
1
2
|
import { OPS_KPI_META as i } from "../../lib/ops-report-types.js";
|
|
2
|
-
const
|
|
3
|
+
const m = [
|
|
3
4
|
{ key: "report", label: "Report" },
|
|
4
5
|
{ key: "trends", label: "Trends" },
|
|
5
6
|
{ key: "compare", label: "Compare" }
|
|
6
7
|
];
|
|
7
|
-
function
|
|
8
|
+
function f(e) {
|
|
8
9
|
return Array.isArray(e) ? e : [];
|
|
9
10
|
}
|
|
10
11
|
function o(e, r = 0) {
|
|
11
12
|
return e == null || Number.isNaN(e) ? "–" : e.toLocaleString("en-US", { maximumFractionDigits: r });
|
|
12
13
|
}
|
|
13
|
-
function
|
|
14
|
+
function d(e) {
|
|
14
15
|
return e == null || Number.isNaN(e) ? "–" : e >= 1e4 ? `${(e / 1e3).toFixed(0)} s` : e >= 1e3 ? `${(e / 1e3).toFixed(1)} s` : `${Math.round(e)} ms`;
|
|
15
16
|
}
|
|
16
17
|
function g(e, r) {
|
|
17
|
-
return e == null || Number.isNaN(e) ? "–" : r === "ms" ?
|
|
18
|
+
return e == null || Number.isNaN(e) ? "–" : r === "ms" ? d(e) : r === "usd" ? `$${Math.round(e).toLocaleString("en-US")}` : r === "pct" ? `${o(e, 1)}%` : o(e, Number.isInteger(e) ? 0 : 1);
|
|
18
19
|
}
|
|
19
20
|
function n(e, r) {
|
|
20
21
|
const t = (r == null ? void 0 : r.find((a) => a.key === e)) ?? i.find((a) => a.key === e);
|
|
@@ -22,7 +23,7 @@ function n(e, r) {
|
|
|
22
23
|
const s = (e.split(".").pop() ?? e).replace(/_/g, " ");
|
|
23
24
|
return s[0].toUpperCase() + s.slice(1);
|
|
24
25
|
}
|
|
25
|
-
function
|
|
26
|
+
function h(e, r) {
|
|
26
27
|
return (r == null ? void 0 : r.find((t) => t.key === e)) ?? i.find((t) => t.key === e) ?? {
|
|
27
28
|
key: e,
|
|
28
29
|
label: n(e),
|
|
@@ -31,17 +32,17 @@ function m(e, r) {
|
|
|
31
32
|
group: "business"
|
|
32
33
|
};
|
|
33
34
|
}
|
|
34
|
-
function
|
|
35
|
+
function k(e) {
|
|
35
36
|
return e === !0 ? "text-emerald-700 dark:text-emerald-400" : e === !1 ? "text-red-600 dark:text-red-400" : "text-slate-500 dark:text-muted-foreground";
|
|
36
37
|
}
|
|
37
|
-
function
|
|
38
|
+
function y(e) {
|
|
38
39
|
if (e.prev == null) return "no earlier day";
|
|
39
40
|
if (e.today === e.prev) return "no change";
|
|
40
41
|
if (e.change_pct == null) return e.today > e.prev ? "up from 0" : "down";
|
|
41
42
|
const r = e.change_pct, t = Math.abs(r) >= 10 ? Math.round(Math.abs(r)) : Math.abs(r).toFixed(1);
|
|
42
43
|
return `${r > 0 ? "+" : "−"}${t}%`;
|
|
43
44
|
}
|
|
44
|
-
const
|
|
45
|
+
const w = {
|
|
45
46
|
healthy: {
|
|
46
47
|
label: "Healthy",
|
|
47
48
|
dot: "bg-emerald-500",
|
|
@@ -57,29 +58,29 @@ const k = {
|
|
|
57
58
|
dot: "bg-red-500",
|
|
58
59
|
badge: "border-red-200 bg-red-50 text-red-800 dark:border-red-500/30 dark:bg-red-500/10 dark:text-red-300"
|
|
59
60
|
}
|
|
60
|
-
},
|
|
61
|
-
function
|
|
61
|
+
}, x = "bg-slate-300 dark:bg-slate-600";
|
|
62
|
+
function N(e) {
|
|
62
63
|
return e === "running" ? "Building" : e === "failed" ? "Failed" : e === "digest_only" ? "Numbers only" : "Ready";
|
|
63
64
|
}
|
|
64
65
|
function l(e) {
|
|
65
66
|
const r = e.match(/^(\d{4})-(\d{2})-(\d{2})/);
|
|
66
67
|
return r ? new Date(Number(r[1]), Number(r[2]) - 1, Number(r[3])) : null;
|
|
67
68
|
}
|
|
68
|
-
function
|
|
69
|
+
function S(e) {
|
|
69
70
|
const r = l(e);
|
|
70
71
|
return r ? r.toLocaleDateString("en-US", { month: "short", day: "numeric" }) : e;
|
|
71
72
|
}
|
|
72
|
-
function
|
|
73
|
+
function D(e) {
|
|
73
74
|
const r = l(e);
|
|
74
75
|
return r ? r.toLocaleDateString("en-US", { weekday: "short" }) : "";
|
|
75
76
|
}
|
|
76
|
-
function
|
|
77
|
-
return e == null ? "–" :
|
|
77
|
+
function M(e) {
|
|
78
|
+
return e == null ? "–" : u(e, { decimals: Math.abs(e) < 1 ? 3 : 2 });
|
|
78
79
|
}
|
|
79
|
-
function
|
|
80
|
+
function T(e) {
|
|
80
81
|
return e.tokens_in == null && e.tokens_out == null ? null : (e.tokens_in ?? 0) + (e.tokens_out ?? 0);
|
|
81
82
|
}
|
|
82
|
-
const
|
|
83
|
+
const L = [
|
|
83
84
|
"requests",
|
|
84
85
|
"p95_ms",
|
|
85
86
|
"server_errors",
|
|
@@ -89,7 +90,7 @@ const D = [
|
|
|
89
90
|
"job_failures",
|
|
90
91
|
"backlog_waiting",
|
|
91
92
|
"open_bugs"
|
|
92
|
-
],
|
|
93
|
+
], c = {
|
|
93
94
|
active_people: "active_people",
|
|
94
95
|
signed_in_today: "signed_in_today",
|
|
95
96
|
sign_ins: "signed_in_today",
|
|
@@ -131,33 +132,33 @@ const D = [
|
|
|
131
132
|
data_violations: "data_quality",
|
|
132
133
|
health_score: "score"
|
|
133
134
|
};
|
|
134
|
-
function
|
|
135
|
-
const r =
|
|
135
|
+
function $(e) {
|
|
136
|
+
const r = c[e];
|
|
136
137
|
return Array.isArray(r) ? { metric: r[0], key: r[1], label: n(e) } : r ? { metric: r, label: n(e) } : e.includes(".") ? { metric: "section", key: e, label: n(e) } : null;
|
|
137
138
|
}
|
|
138
|
-
const
|
|
139
|
+
const I = (e, r, t) => ({
|
|
139
140
|
metric: e,
|
|
140
141
|
key: r == null ? null : String(r),
|
|
141
142
|
label: t
|
|
142
143
|
});
|
|
143
144
|
export {
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
145
|
+
x as NO_VERDICT_DOT,
|
|
146
|
+
m as OPS_TABS,
|
|
147
|
+
L as STRIP_KEYS,
|
|
148
|
+
w as VERDICT,
|
|
149
|
+
f as arr,
|
|
150
|
+
y as changeText,
|
|
151
|
+
M as cost,
|
|
152
|
+
I as dr,
|
|
153
|
+
$ as drillForKpi,
|
|
153
154
|
g as formatKpi,
|
|
154
|
-
|
|
155
|
+
k as goodClass,
|
|
155
156
|
n as kpiLabel,
|
|
156
|
-
|
|
157
|
-
|
|
157
|
+
h as kpiMeta,
|
|
158
|
+
d as ms,
|
|
158
159
|
o as num,
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
160
|
+
T as reportTokens,
|
|
161
|
+
S as shortDay,
|
|
162
|
+
N as statusLabel,
|
|
163
|
+
D as weekday
|
|
163
164
|
};
|
|
@@ -1,25 +1,26 @@
|
|
|
1
1
|
import { jsxs as a, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { useQuery as
|
|
3
|
-
import { Network as
|
|
4
|
-
import { useNivaroClient as
|
|
5
|
-
import { get as
|
|
6
|
-
import { useStartsOpen as
|
|
7
|
-
|
|
2
|
+
import { useQuery as f } from "@tanstack/react-query";
|
|
3
|
+
import { Network as h, ChevronDown as y } from "lucide-react";
|
|
4
|
+
import { useNivaroClient as N, useItemNavigation as v, useDrilldown as g } from "../../context.js";
|
|
5
|
+
import { get as k } from "../../lib/commands.js";
|
|
6
|
+
import { useStartsOpen as w } from "../../lib/use-starts-open.js";
|
|
7
|
+
import { formatNumber as c } from "../../lib/utils.js";
|
|
8
|
+
function B({
|
|
8
9
|
collection: o,
|
|
9
10
|
itemId: n,
|
|
10
|
-
title:
|
|
11
|
-
defaultExpanded:
|
|
11
|
+
title: i,
|
|
12
|
+
defaultExpanded: m = !0
|
|
12
13
|
}) {
|
|
13
|
-
const
|
|
14
|
+
const p = N(), { open: u } = v(), s = g(), [d, x] = w(m, !0), { data: l = [] } = f({
|
|
14
15
|
queryKey: ["referenced-by", o, n],
|
|
15
|
-
queryFn: () =>
|
|
16
|
-
|
|
16
|
+
queryFn: () => p.request(
|
|
17
|
+
k(`/referenced-by/${o}/${encodeURIComponent(n)}`)
|
|
17
18
|
).then((e) => e.data ?? []).catch(() => []),
|
|
18
19
|
enabled: !!n,
|
|
19
20
|
staleTime: 6e4
|
|
20
21
|
});
|
|
21
22
|
if (l.length === 0) return null;
|
|
22
|
-
const
|
|
23
|
+
const b = l.reduce((e, t) => e + t.count, 0);
|
|
23
24
|
return /* @__PURE__ */ a(
|
|
24
25
|
"div",
|
|
25
26
|
{
|
|
@@ -30,14 +31,14 @@ function j({
|
|
|
30
31
|
"button",
|
|
31
32
|
{
|
|
32
33
|
type: "button",
|
|
33
|
-
onClick: () =>
|
|
34
|
+
onClick: () => x((e) => !e),
|
|
34
35
|
className: "flex w-full items-center gap-2.5 px-5 py-3.5 text-left transition-colors hover:bg-slate-50/50 dark:hover:bg-white/[0.02]",
|
|
35
36
|
children: [
|
|
36
|
-
/* @__PURE__ */ r(
|
|
37
|
-
/* @__PURE__ */ r("span", { className: "text-[13px] font-medium text-slate-800 dark:text-slate-200", children:
|
|
38
|
-
/* @__PURE__ */ r("span", { className: "rounded-full bg-slate-100 px-1.5 py-px text-[10.5px] font-semibold tabular-nums text-slate-500 dark:bg-muted dark:text-slate-400", children:
|
|
37
|
+
/* @__PURE__ */ r(h, { className: "h-3.5 w-3.5 shrink-0 text-slate-400" }),
|
|
38
|
+
/* @__PURE__ */ r("span", { className: "text-[13px] font-medium text-slate-800 dark:text-slate-200", children: i ?? "Referenced by" }),
|
|
39
|
+
/* @__PURE__ */ r("span", { className: "rounded-full bg-slate-100 px-1.5 py-px text-[10.5px] font-semibold tabular-nums text-slate-500 dark:bg-muted dark:text-slate-400", children: c(b) }),
|
|
39
40
|
/* @__PURE__ */ r(
|
|
40
|
-
|
|
41
|
+
y,
|
|
41
42
|
{
|
|
42
43
|
className: `ml-auto h-3.5 w-3.5 shrink-0 text-slate-400 transition-transform duration-150${d ? " rotate-180" : ""}`
|
|
43
44
|
}
|
|
@@ -51,7 +52,7 @@ function j({
|
|
|
51
52
|
className: "border-b border-slate-100 py-1.5 last:border-0 dark:border-border/60",
|
|
52
53
|
children: [
|
|
53
54
|
/* @__PURE__ */ a("p", { className: "text-[12px] text-slate-700 dark:text-slate-300", children: [
|
|
54
|
-
/* @__PURE__ */ r("span", { className: "font-semibold tabular-nums", children: e.count }),
|
|
55
|
+
/* @__PURE__ */ r("span", { className: "font-semibold tabular-nums", children: c(e.count) }),
|
|
55
56
|
" ",
|
|
56
57
|
e.display_name ?? e.collection,
|
|
57
58
|
/* @__PURE__ */ a("span", { className: "text-slate-400", children: [
|
|
@@ -64,7 +65,7 @@ function j({
|
|
|
64
65
|
"button",
|
|
65
66
|
{
|
|
66
67
|
type: "button",
|
|
67
|
-
onClick: () => s ? s.open({ collection: e.collection, itemId: t.id }) :
|
|
68
|
+
onClick: () => s ? s.open({ collection: e.collection, itemId: t.id }) : u({ collection: e.collection, itemId: t.id }),
|
|
68
69
|
className: "max-w-[220px] truncate text-[11.5px] text-nvr-navy underline decoration-nvr-cyan/50 underline-offset-2 hover:decoration-nvr-cyan dark:text-nvr-cyan",
|
|
69
70
|
title: t.label,
|
|
70
71
|
children: t.label.trim() || `#${t.id}`
|
|
@@ -86,5 +87,5 @@ function j({
|
|
|
86
87
|
);
|
|
87
88
|
}
|
|
88
89
|
export {
|
|
89
|
-
|
|
90
|
+
B as ReferencedByPanel
|
|
90
91
|
};
|