@declarion/react 0.32.0 → 0.35.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist-lib/{ActionRunner-CaSrGpBi.js → ActionRunner-Bkkb_YMa.js} +1332 -1310
- package/dist-lib/{DraggableChildrenTable-CAHg7paQ.js → DraggableChildrenTable-TNni9y0Q.js} +55 -55
- package/dist-lib/DynamicIcon-BWO6QtNF.js +261 -0
- package/dist-lib/{Grid-DDbBhqcl.js → Grid-DOtBLx3n.js} +2 -2
- package/dist-lib/{JsonEditor-KelPV-OQ.js → JsonEditor-DoNmyrYd.js} +2 -2
- package/dist-lib/{LayoutRenderer-CelsqsZ6.js → LayoutRenderer-CMuVgKev.js} +748 -746
- package/dist-lib/{MarkdownRenderer-DThy2ixe.js → MarkdownRenderer-DWOlvx8k.js} +1 -1
- package/dist-lib/{MonacoJson-DVjwsaBK.js → MonacoJson-BfpzZ1iT.js} +1 -1
- package/dist-lib/RefreshControl-CgU8mNEp.js +835 -0
- package/dist-lib/SmartDetailPage.impl-Bjl7EFzU.js +1774 -0
- package/dist-lib/{SmartRecordListPage.impl-BKIpTNK7.js → SmartRecordListPage.impl-D2eE-g5J.js} +91 -91
- package/dist-lib/assets/OFL-Inter.txt +93 -0
- package/dist-lib/assets/OFL-JetBrainsMono.txt +93 -0
- package/dist-lib/assets/inter-latin-ext-wght-normal.woff2 +0 -0
- package/dist-lib/assets/inter-latin-wght-normal.woff2 +0 -0
- package/dist-lib/assets/jetbrains-mono-latin-ext-wght-normal.woff2 +0 -0
- package/dist-lib/assets/jetbrains-mono-latin-wght-normal.woff2 +0 -0
- package/dist-lib/components/fields/cells/factories/host-icons.d.ts +9 -1
- package/dist-lib/components/layout/TopBar.d.ts +2 -1
- package/dist-lib/components/pages/DocumentsMenu.d.ts +22 -0
- package/dist-lib/components/pages/RecordDocumentsPanel.d.ts +42 -0
- package/dist-lib/components/pages/list/DataCell.d.ts +1 -2
- package/dist-lib/components/pages/list/ListHeader.d.ts +1 -11
- package/dist-lib/components/primitives/Btn.d.ts +1 -1
- package/dist-lib/components/primitives/Icons.d.ts +1 -0
- package/dist-lib/components/primitives/Tooltip.d.ts +30 -0
- package/dist-lib/components/primitives/index.d.ts +2 -0
- package/dist-lib/components/shared/ActionResultDialog.d.ts +4 -0
- package/dist-lib/components/shared/RecordHeader.d.ts +2 -1
- package/dist-lib/components/shared/ResponsiveActionBar.d.ts +9 -1
- package/dist-lib/declarion-react.css +1 -1
- package/dist-lib/embed/theme.d.ts +8 -8
- package/dist-lib/hooks/useBrandingChrome.d.ts +28 -2
- package/dist-lib/hooks/useResponsiveMode.d.ts +17 -1
- package/dist-lib/icons.js +1 -1
- package/dist-lib/index.js +2430 -2441
- package/dist-lib/lib/brand-tokens.d.ts +43 -0
- package/dist-lib/lib/document-templates.d.ts +12 -0
- package/dist-lib/lib/download.d.ts +20 -0
- package/dist-lib/lib/html-state.d.ts +11 -0
- package/dist-lib/lib/record-documents-key.d.ts +1 -0
- package/dist-lib/lib/versionTracker.d.ts +6 -0
- package/dist-lib/{registry-KQyyL5Gt.js → registry-GTwsJEYp.js} +1469 -1343
- package/dist-lib/stores/page-state.d.ts +1 -1
- package/dist-lib/stores/preferences.d.ts +37 -0
- package/dist-lib/testing.js +5 -5
- package/dist-lib/types/api.d.ts +95 -23
- package/dist-lib/types/schema.d.ts +32 -1
- package/dist-lib/{useProperties-D74hyWIa.js → useProperties-oNGJ7HwM.js} +67 -67
- package/dist-lib/{value-BfXXl5EE.js → value-DNs5L0Ad.js} +82 -82
- package/dist-lib/vite/fingerprint-plugin.d.ts +1 -1
- package/package.json +17 -16
- package/dist-lib/DynamicIcon-DCRdxxZ7.js +0 -260
- package/dist-lib/RefreshControl-CorluL6r.js +0 -582
- package/dist-lib/SmartDetailPage.impl-USIxbl-8.js +0 -1532
- package/dist-lib/stores/appearance.d.ts +0 -37
package/dist-lib/{SmartRecordListPage.impl-BKIpTNK7.js → SmartRecordListPage.impl-D2eE-g5J.js}
RENAMED
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
import { s as e } from "./DynamicIcon-
|
|
2
|
-
import {
|
|
3
|
-
import { $ as v, G as ne, Q as re, X as y, Z as b, _ as ie, a as x, c as S, et as C, nt as w, s as T, w as ae } from "./registry-
|
|
4
|
-
import { b as E, d as D, f as O, g as k, m as oe, n as A, p as se, r as j, s as M } from "./useProperties-
|
|
5
|
-
import { t as N } from "./LayoutRenderer-
|
|
1
|
+
import { s as e } from "./DynamicIcon-BWO6QtNF.js";
|
|
2
|
+
import { A as t, En as n, Ln as r, N as i, Un as a, V as o, Wn as s, _n as c, an as l, cn as u, g as d, jn as f, kn as ee, mt as p, on as m, p as h, rn as g, v as _, vn as te } from "./ActionRunner-Bkkb_YMa.js";
|
|
3
|
+
import { $ as v, G as ne, Q as re, X as y, Z as b, _ as ie, a as x, c as S, et as C, nt as w, s as T, w as ae } from "./registry-GTwsJEYp.js";
|
|
4
|
+
import { b as E, d as D, f as O, g as k, m as oe, n as A, p as se, r as j, s as M } from "./useProperties-oNGJ7HwM.js";
|
|
5
|
+
import { t as N } from "./LayoutRenderer-CMuVgKev.js";
|
|
6
6
|
import { useCallback as P, useEffect as F, useMemo as I, useRef as L, useState as ce } from "react";
|
|
7
7
|
import { useSearchParams as le } from "react-router-dom";
|
|
8
8
|
import { Fragment as R, jsx as z, jsxs as B } from "react/jsx-runtime";
|
|
9
9
|
//#region src/components/pages/SmartRecordListPage.impl.tsx
|
|
10
|
-
function V({ screenCode:
|
|
11
|
-
let [
|
|
12
|
-
oe(
|
|
13
|
-
let _ = ie(), v =
|
|
14
|
-
let e = D(
|
|
10
|
+
function V({ screenCode: o }) {
|
|
11
|
+
let [s, c] = le(), { data: d } = p(), f = r(), m = d?.screens[o], h = m?.entity ? d?.entities[m.entity] : void 0, g = m?.entity;
|
|
12
|
+
oe(m, h, s.toString()), k(m?.route);
|
|
13
|
+
let _ = ie(), v = s.get("selected") ?? null, ne = s.get("search") ?? "", re = t(ne, 300), y = s.get("sort") ?? m?.sort_default ?? "", b = I(() => {
|
|
14
|
+
let e = D(s);
|
|
15
15
|
return e.length > 0 ? e : void 0;
|
|
16
|
-
}, [
|
|
17
|
-
let e =
|
|
18
|
-
return
|
|
19
|
-
}, [
|
|
20
|
-
let e =
|
|
21
|
-
return e?.list?.presentation === "table" || e?.list?.presentation === "cards" ? e.list.presentation : e?.presentation === "table" || e?.presentation === "cards" ? e.presentation :
|
|
22
|
-
}, [
|
|
23
|
-
entity:
|
|
24
|
-
screen:
|
|
25
|
-
}), [
|
|
26
|
-
entity:
|
|
27
|
-
screen:
|
|
16
|
+
}, [s]), x = I(() => m?.columns ?? h?.fields.names().filter((e) => !h.fields.get(e)?.primary && !h.fields.get(e)?.auto && h.fields.get(e)?.display?.is_listable !== !1).slice(0, 4) ?? [], [m?.columns, h]), C = I(() => {
|
|
17
|
+
let e = m?.responsive?.[f.category]?.presentation;
|
|
18
|
+
return f.category === "phone" ? "drilldown" : e === "split" || e === "drilldown" || e === "stacked" ? e : "split";
|
|
19
|
+
}, [m?.responsive, f.category]), w = I(() => {
|
|
20
|
+
let e = m?.responsive?.[f.category];
|
|
21
|
+
return e?.list?.presentation === "table" || e?.list?.presentation === "cards" ? e.list.presentation : e?.presentation === "table" || e?.presentation === "cards" ? e.presentation : f.category === "phone" ? "cards" : "table";
|
|
22
|
+
}, [m?.responsive, f.category]), ae = m?.responsive?.[f.category]?.layout?.related_records, A = I(() => T({
|
|
23
|
+
entity: h,
|
|
24
|
+
screen: m
|
|
25
|
+
}), [h, m]), j = I(() => S({
|
|
26
|
+
entity: h,
|
|
27
|
+
screen: m,
|
|
28
28
|
presentation: w,
|
|
29
29
|
visibleColumns: x,
|
|
30
30
|
card: A,
|
|
31
31
|
sort: y
|
|
32
32
|
}), [
|
|
33
|
+
h,
|
|
33
34
|
m,
|
|
34
|
-
f,
|
|
35
35
|
w,
|
|
36
36
|
x,
|
|
37
37
|
A,
|
|
38
38
|
y
|
|
39
|
-
]), N =
|
|
39
|
+
]), N = h?.list_pagination === "cursor", { data: V, isLoading: H } = i(g, {
|
|
40
40
|
page: 1,
|
|
41
41
|
per_page: 200,
|
|
42
42
|
sort: y || void 0,
|
|
@@ -45,7 +45,7 @@ function V({ screenCode: r }) {
|
|
|
45
45
|
select: j.selectFields,
|
|
46
46
|
expand: j.expandFields,
|
|
47
47
|
preview: !0,
|
|
48
|
-
screen:
|
|
48
|
+
screen: m?.fixed_filters ? o : void 0
|
|
49
49
|
}, !N), U = E(g, {
|
|
50
50
|
sort: y || void 0,
|
|
51
51
|
search: re || void 0,
|
|
@@ -53,31 +53,31 @@ function V({ screenCode: r }) {
|
|
|
53
53
|
select: j.selectFields,
|
|
54
54
|
expand: j.expandFields,
|
|
55
55
|
preview: !0,
|
|
56
|
-
screen:
|
|
56
|
+
screen: m?.fixed_filters ? o : void 0,
|
|
57
57
|
limit: 200
|
|
58
|
-
}, N), W = N ? U.rows : V?.data ?? [], K = N ? U.refs : V?.$refs, q = N ? U.isLoading : H, de = I(() =>
|
|
59
|
-
|
|
58
|
+
}, N), W = N ? U.rows : V?.data ?? [], K = N ? U.refs : V?.$refs, q = N ? U.isLoading : H, de = I(() => h?.fields.names().find((e) => h.fields.get(e)?.primary) ?? "id", [h]), fe = P((e, t) => {
|
|
59
|
+
c((t) => {
|
|
60
60
|
let n = new URLSearchParams(t);
|
|
61
61
|
return e ? n.set("selected", e) : n.delete("selected"), n;
|
|
62
62
|
}, { replace: t?.replace ?? !0 });
|
|
63
|
-
}, [
|
|
64
|
-
|
|
63
|
+
}, [c]), pe = P((e) => {
|
|
64
|
+
c((t) => {
|
|
65
65
|
let n = new URLSearchParams(t);
|
|
66
66
|
return e ? n.set("search", e) : n.delete("search"), n;
|
|
67
67
|
}, { replace: !0 });
|
|
68
|
-
}, [
|
|
69
|
-
|
|
68
|
+
}, [c]), me = P((e, t) => {
|
|
69
|
+
c((n) => {
|
|
70
70
|
let r = new URLSearchParams(n), i = D(n), a;
|
|
71
71
|
return a = t && t !== "__all__" ? [...O(i, e), M(e, t)] : O(i, e), se(a, r), r;
|
|
72
72
|
}, { replace: !0 });
|
|
73
|
-
}, [
|
|
73
|
+
}, [c]), J = (m?.list_resizable ?? !1) && C === "split" && f.category !== "phone" && !f.touch, Y = L(null), [X, Z] = ce(null), Q = L(!1), $ = m?.list_width;
|
|
74
74
|
F(() => {
|
|
75
75
|
!J || !$?.endsWith("%") || Z(null);
|
|
76
76
|
}, [
|
|
77
77
|
J,
|
|
78
78
|
$,
|
|
79
|
-
|
|
80
|
-
|
|
79
|
+
f.width,
|
|
80
|
+
f.height
|
|
81
81
|
]), F(() => {
|
|
82
82
|
if (!J || X !== null) return;
|
|
83
83
|
let e = Y.current;
|
|
@@ -89,7 +89,7 @@ function V({ screenCode: r }) {
|
|
|
89
89
|
J,
|
|
90
90
|
$,
|
|
91
91
|
X,
|
|
92
|
-
|
|
92
|
+
h
|
|
93
93
|
]);
|
|
94
94
|
let he = L(null);
|
|
95
95
|
F(() => () => {
|
|
@@ -99,15 +99,15 @@ function V({ screenCode: r }) {
|
|
|
99
99
|
e.preventDefault(), Q.current = !0;
|
|
100
100
|
let t = e.clientX, n = X ?? 320, r = (e) => {
|
|
101
101
|
if (!Q.current) return;
|
|
102
|
-
let r = (Y.current?.getBoundingClientRect().width ?? window.innerWidth) - 300;
|
|
103
|
-
Z(
|
|
102
|
+
let r = (Y.current?.getBoundingClientRect().width ?? window.innerWidth) - 300, i = Math.max(200, Math.min(r, n + e.clientX - t));
|
|
103
|
+
Z(i);
|
|
104
104
|
}, i = () => {
|
|
105
105
|
Q.current = !1, document.removeEventListener("mousemove", r), document.removeEventListener("mouseup", i), document.body.style.cursor = "", document.body.style.userSelect = "", he.current = null;
|
|
106
106
|
};
|
|
107
107
|
document.body.style.cursor = "col-resize", document.body.style.userSelect = "none", document.addEventListener("mousemove", r), document.addEventListener("mouseup", i), he.current = i;
|
|
108
108
|
}, [X]);
|
|
109
|
-
if (!
|
|
110
|
-
let _e = b?.length ?? 0, ve = C === "split" || C === "stacked" || !v, ye = C === "split" || C === "stacked" || !!v, be = C !== "split" && v ? () => fe(null, { replace: !0 }) : void 0, xe = C === "split" ? J && X !== null ? X :
|
|
109
|
+
if (!d || !m || !h) return null;
|
|
110
|
+
let _e = b?.length ?? 0, ve = C === "split" || C === "stacked" || !v, ye = C === "split" || C === "stacked" || !!v, be = C !== "split" && v ? () => fe(null, { replace: !0 }) : void 0, xe = C === "split" ? J && X !== null ? X : m.list_width ?? "320px" : "100%";
|
|
111
111
|
return /* @__PURE__ */ B("div", {
|
|
112
112
|
ref: Y,
|
|
113
113
|
"data-record-list-presentation": C,
|
|
@@ -147,7 +147,7 @@ function V({ screenCode: r }) {
|
|
|
147
147
|
alignItems: "center",
|
|
148
148
|
gap: 8
|
|
149
149
|
},
|
|
150
|
-
children: [/* @__PURE__ */ z(
|
|
150
|
+
children: [/* @__PURE__ */ z(a, {
|
|
151
151
|
icon: /* @__PURE__ */ z(e.back, { size: 14 }),
|
|
152
152
|
title: "Back",
|
|
153
153
|
onClick: _.goBack
|
|
@@ -157,38 +157,38 @@ function V({ screenCode: r }) {
|
|
|
157
157
|
fontWeight: 600,
|
|
158
158
|
color: "var(--text)"
|
|
159
159
|
},
|
|
160
|
-
children:
|
|
160
|
+
children: u(m.display?.name) || u(h.display.name_plural)
|
|
161
161
|
})]
|
|
162
162
|
}),
|
|
163
|
-
/* @__PURE__ */ z(
|
|
163
|
+
/* @__PURE__ */ z(ee, {
|
|
164
164
|
value: ne,
|
|
165
165
|
onChange: pe,
|
|
166
|
-
placeholder: `Search ${
|
|
166
|
+
placeholder: `Search ${u(h.display.name_plural)}…`,
|
|
167
167
|
prefix: /* @__PURE__ */ z(e.search, { size: 13 })
|
|
168
168
|
}),
|
|
169
|
-
|
|
169
|
+
m.filters && m.filters.length > 0 && /* @__PURE__ */ z("div", {
|
|
170
170
|
style: {
|
|
171
171
|
display: "flex",
|
|
172
172
|
flexWrap: "wrap",
|
|
173
173
|
gap: 6
|
|
174
174
|
},
|
|
175
|
-
children:
|
|
176
|
-
let t =
|
|
175
|
+
children: m.filters.map((e) => {
|
|
176
|
+
let t = h.fields.get(e);
|
|
177
177
|
if (!t?.values) return null;
|
|
178
|
-
let
|
|
178
|
+
let r = b?.find((t) => t.field === e && t.op === "eq")?.value ?? "__all__", i = l(t, e, d.entities);
|
|
179
179
|
return /* @__PURE__ */ z("div", {
|
|
180
180
|
style: { minWidth: 120 },
|
|
181
|
-
children: /* @__PURE__ */ z(
|
|
182
|
-
value:
|
|
181
|
+
children: /* @__PURE__ */ z(n, {
|
|
182
|
+
value: r,
|
|
183
183
|
options: [{
|
|
184
184
|
value: "__all__",
|
|
185
|
-
label: `All ${
|
|
185
|
+
label: `All ${i}`
|
|
186
186
|
}, ...t.values.map((e) => ({
|
|
187
187
|
value: e.code,
|
|
188
|
-
label:
|
|
188
|
+
label: u(e.name) || e.code
|
|
189
189
|
}))],
|
|
190
190
|
onChange: (t) => me(e, t),
|
|
191
|
-
placeholder:
|
|
191
|
+
placeholder: i
|
|
192
192
|
})
|
|
193
193
|
}, e);
|
|
194
194
|
})
|
|
@@ -201,8 +201,8 @@ function V({ screenCode: r }) {
|
|
|
201
201
|
fontSize: 11,
|
|
202
202
|
color: "var(--text-3)"
|
|
203
203
|
},
|
|
204
|
-
children: [/* @__PURE__ */ z("span", { children: q ? "Loading…" : `${W.length} ${
|
|
205
|
-
onClick: () =>
|
|
204
|
+
children: [/* @__PURE__ */ z("span", { children: q ? "Loading…" : `${W.length} ${u(h.display.name_plural)}` }), _e > 0 && /* @__PURE__ */ z("button", {
|
|
205
|
+
onClick: () => c((e) => {
|
|
206
206
|
let t = new URLSearchParams(e);
|
|
207
207
|
return t.delete("filters"), t;
|
|
208
208
|
}, { replace: !0 }),
|
|
@@ -249,10 +249,10 @@ function V({ screenCode: r }) {
|
|
|
249
249
|
},
|
|
250
250
|
children: "No records found"
|
|
251
251
|
}) : /* @__PURE__ */ B(R, { children: [W.map((e) => {
|
|
252
|
-
let t =
|
|
252
|
+
let t = te(e[de]);
|
|
253
253
|
return /* @__PURE__ */ z(ue, {
|
|
254
254
|
record: e,
|
|
255
|
-
entity:
|
|
255
|
+
entity: h,
|
|
256
256
|
columns: x,
|
|
257
257
|
card: A,
|
|
258
258
|
presentation: w,
|
|
@@ -303,9 +303,9 @@ function V({ screenCode: r }) {
|
|
|
303
303
|
children: v ? /* @__PURE__ */ z(G, {
|
|
304
304
|
entityCode: g,
|
|
305
305
|
recordId: v,
|
|
306
|
-
items:
|
|
307
|
-
schema:
|
|
308
|
-
entity:
|
|
306
|
+
items: m.items,
|
|
307
|
+
schema: d,
|
|
308
|
+
entity: h,
|
|
309
309
|
onBackToList: be,
|
|
310
310
|
relatedRecordsPresentation: ae
|
|
311
311
|
}, v) : /* @__PURE__ */ z("div", {
|
|
@@ -320,7 +320,7 @@ function V({ screenCode: r }) {
|
|
|
320
320
|
style: { fontSize: 12.5 },
|
|
321
321
|
children: [
|
|
322
322
|
"Select a ",
|
|
323
|
-
|
|
323
|
+
u(h.display.name),
|
|
324
324
|
" to view details"
|
|
325
325
|
]
|
|
326
326
|
})
|
|
@@ -330,7 +330,7 @@ function V({ screenCode: r }) {
|
|
|
330
330
|
});
|
|
331
331
|
}
|
|
332
332
|
function ue({ record: e, entity: t, columns: n, card: r, presentation: i, refs: a, isSelected: o, onClick: s }) {
|
|
333
|
-
let c =
|
|
333
|
+
let c = h();
|
|
334
334
|
if (i === "cards") {
|
|
335
335
|
let n = r.badgeFields.filter((n) => H(t, e, n)), i = r.bodyFields.filter((n) => H(t, e, n)), l = r.metaFields.filter((n) => H(t, e, n));
|
|
336
336
|
return /* @__PURE__ */ B("button", {
|
|
@@ -532,7 +532,7 @@ function H(e, t, n) {
|
|
|
532
532
|
return !(r == null || r === "" || Array.isArray(r) && r.length === 0);
|
|
533
533
|
}
|
|
534
534
|
function U({ entity: e, record: t, field: n, refs: r }) {
|
|
535
|
-
let i =
|
|
535
|
+
let i = h(), a = m(t, e);
|
|
536
536
|
return /* @__PURE__ */ z("div", {
|
|
537
537
|
style: {
|
|
538
538
|
fontSize: 13.5,
|
|
@@ -547,7 +547,7 @@ function U({ entity: e, record: t, field: n, refs: r }) {
|
|
|
547
547
|
mode: "display",
|
|
548
548
|
refs: r,
|
|
549
549
|
locale: i
|
|
550
|
-
}) : a) ||
|
|
550
|
+
}) : a) || u(e.display.name)
|
|
551
551
|
});
|
|
552
552
|
}
|
|
553
553
|
function W({ entity: e, record: t, fieldName: n, refs: r, locale: i }) {
|
|
@@ -561,7 +561,7 @@ function W({ entity: e, record: t, fieldName: n, refs: r, locale: i }) {
|
|
|
561
561
|
minWidth: 0,
|
|
562
562
|
overflowWrap: "anywhere"
|
|
563
563
|
},
|
|
564
|
-
children:
|
|
564
|
+
children: l(o, n)
|
|
565
565
|
}), /* @__PURE__ */ z("dd", {
|
|
566
566
|
style: {
|
|
567
567
|
margin: 0,
|
|
@@ -581,7 +581,7 @@ function W({ entity: e, record: t, fieldName: n, refs: r, locale: i }) {
|
|
|
581
581
|
})] }) : null;
|
|
582
582
|
}
|
|
583
583
|
function G({ entityCode: e, recordId: t, items: n, schema: r, entity: i, onBackToList: a, relatedRecordsPresentation: o }) {
|
|
584
|
-
return /* @__PURE__ */ z(
|
|
584
|
+
return /* @__PURE__ */ z(d, { children: /* @__PURE__ */ z(K, {
|
|
585
585
|
entityCode: e,
|
|
586
586
|
recordId: t,
|
|
587
587
|
items: n,
|
|
@@ -591,35 +591,35 @@ function G({ entityCode: e, recordId: t, items: n, schema: r, entity: i, onBackT
|
|
|
591
591
|
relatedRecordsPresentation: o
|
|
592
592
|
}) });
|
|
593
593
|
}
|
|
594
|
-
function K({ entityCode: t, recordId: n, items:
|
|
595
|
-
let
|
|
594
|
+
function K({ entityCode: t, recordId: n, items: r, schema: i, entity: l, onBackToList: d, relatedRecordsPresentation: ee }) {
|
|
595
|
+
let p = g(l, "update"), { data: h, isLoading: ie } = x(t, I(() => n ? c(l, n) : void 0, [n, l])), S = ne(t), C = _(), [T, E] = ce(!1), [D, O] = ce({}), k = h?.data, oe = k?.$statuses, se = k?.$properties, M = j(t, n), F = A(t, n), L = I(() => {
|
|
596
596
|
let e = /* @__PURE__ */ new Set();
|
|
597
|
-
for (let [t, n] of
|
|
598
|
-
for (let [t] of
|
|
597
|
+
for (let [t, n] of l.fields) !n.auto && !n.primary && e.add(t);
|
|
598
|
+
for (let [t] of l.files ?? []) e.add(t);
|
|
599
599
|
return e;
|
|
600
|
-
}, [
|
|
600
|
+
}, [l]), le = P(() => {
|
|
601
601
|
if (k) {
|
|
602
602
|
let e = {};
|
|
603
603
|
L.forEach((t) => {
|
|
604
|
-
let n = v(
|
|
605
|
-
e[t] = re(
|
|
604
|
+
let n = v(l, k, t);
|
|
605
|
+
e[t] = re(l, t) ? n ?? null : n ?? "";
|
|
606
606
|
}), O(e);
|
|
607
607
|
}
|
|
608
608
|
E(!0);
|
|
609
609
|
}, [
|
|
610
610
|
k,
|
|
611
611
|
L,
|
|
612
|
-
|
|
612
|
+
l
|
|
613
613
|
]), V = P(async () => {
|
|
614
614
|
await C.flushAllDrafts(), E(!1), O({});
|
|
615
615
|
}, [C]), ue = P(() => {
|
|
616
616
|
let e = {}, t = y({
|
|
617
|
-
entity:
|
|
617
|
+
entity: l,
|
|
618
618
|
formData: D,
|
|
619
619
|
record: k,
|
|
620
620
|
isNew: !1
|
|
621
621
|
}), r = b(t);
|
|
622
|
-
for (let [t, n] of Object.entries(D))
|
|
622
|
+
for (let [t, n] of Object.entries(D)) l.files?.has(t) || (e[t] = w(l, t, n));
|
|
623
623
|
if (Object.keys(t).length > 0 && (e.$files = t), Object.keys(e).length === 0) {
|
|
624
624
|
E(!1), O({});
|
|
625
625
|
return;
|
|
@@ -629,15 +629,15 @@ function K({ entityCode: t, recordId: n, items: i, schema: s, entity: d, onBackT
|
|
|
629
629
|
data: e
|
|
630
630
|
}, {
|
|
631
631
|
onSuccess: () => {
|
|
632
|
-
r.forEach((e) => C.markCommitted(e)), E(!1), O({}),
|
|
632
|
+
r.forEach((e) => C.markCommitted(e)), E(!1), O({}), o.success("Saved");
|
|
633
633
|
},
|
|
634
|
-
onError: () =>
|
|
634
|
+
onError: () => o.error("Failed to save")
|
|
635
635
|
});
|
|
636
636
|
}, [
|
|
637
637
|
C,
|
|
638
638
|
S,
|
|
639
639
|
n,
|
|
640
|
-
|
|
640
|
+
l,
|
|
641
641
|
D,
|
|
642
642
|
k
|
|
643
643
|
]), H = P((e, t) => {
|
|
@@ -648,9 +648,9 @@ function K({ entityCode: t, recordId: n, items: i, schema: s, entity: d, onBackT
|
|
|
648
648
|
}, []);
|
|
649
649
|
if (ie) return /* @__PURE__ */ z(ae, {});
|
|
650
650
|
if (!k) return null;
|
|
651
|
-
let U =
|
|
652
|
-
schema:
|
|
653
|
-
entity:
|
|
651
|
+
let U = m(k, l), W = l.display?.display_field, G = U ? void 0 : W ? k[W] : k[l.fields.names()[0]], K = U || (G != null && typeof G != "object" ? te(G) : u(l.display.name)), q = k?.$refs, de = {
|
|
652
|
+
schema: i,
|
|
653
|
+
entity: l,
|
|
654
654
|
entityCode: t,
|
|
655
655
|
recordId: n,
|
|
656
656
|
record: T ? {
|
|
@@ -662,13 +662,13 @@ function K({ entityCode: t, recordId: n, items: i, schema: s, entity: d, onBackT
|
|
|
662
662
|
onFieldChange: T ? H : void 0,
|
|
663
663
|
refs: q,
|
|
664
664
|
objectProperties: se ?? void 0,
|
|
665
|
-
onSetProperty:
|
|
665
|
+
onSetProperty: p ? (e, t) => F.mutate({
|
|
666
666
|
propertyCode: e,
|
|
667
667
|
value: t
|
|
668
668
|
}) : void 0,
|
|
669
669
|
isPropertyPending: F.isPending,
|
|
670
670
|
objectStatuses: oe ?? void 0,
|
|
671
|
-
onSetStatus:
|
|
671
|
+
onSetStatus: p ? (e, t) => M.mutate({
|
|
672
672
|
groupCode: e,
|
|
673
673
|
statusCode: t
|
|
674
674
|
}) : void 0,
|
|
@@ -710,23 +710,23 @@ function K({ entityCode: t, recordId: n, items: i, schema: s, entity: d, onBackT
|
|
|
710
710
|
alignItems: "center",
|
|
711
711
|
gap: 6
|
|
712
712
|
},
|
|
713
|
-
children: [
|
|
713
|
+
children: [d && /* @__PURE__ */ z(a, {
|
|
714
714
|
icon: /* @__PURE__ */ z(e.back, { size: 14 }),
|
|
715
715
|
title: "Back to list",
|
|
716
|
-
onClick:
|
|
717
|
-
}),
|
|
716
|
+
onClick: d
|
|
717
|
+
}), p && (T ? /* @__PURE__ */ B(R, { children: [/* @__PURE__ */ z(s, {
|
|
718
718
|
size: "xs",
|
|
719
719
|
icon: /* @__PURE__ */ z(e.x, { size: 12 }),
|
|
720
720
|
onClick: V,
|
|
721
721
|
children: "Cancel"
|
|
722
|
-
}), /* @__PURE__ */ z(
|
|
722
|
+
}), /* @__PURE__ */ z(s, {
|
|
723
723
|
kind: "primary",
|
|
724
724
|
size: "xs",
|
|
725
725
|
icon: S.isPending ? /* @__PURE__ */ z(f, { size: 12 }) : /* @__PURE__ */ z(e.save, { size: 12 }),
|
|
726
726
|
onClick: ue,
|
|
727
727
|
disabled: S.isPending,
|
|
728
728
|
children: S.isPending ? "Saving…" : "Save"
|
|
729
|
-
})] }) : /* @__PURE__ */ z(
|
|
729
|
+
})] }) : /* @__PURE__ */ z(s, {
|
|
730
730
|
size: "xs",
|
|
731
731
|
icon: /* @__PURE__ */ z(e.edit, { size: 12 }),
|
|
732
732
|
onClick: le,
|
|
@@ -742,8 +742,8 @@ function K({ entityCode: t, recordId: n, items: i, schema: s, entity: d, onBackT
|
|
|
742
742
|
flexDirection: "column",
|
|
743
743
|
gap: 12
|
|
744
744
|
},
|
|
745
|
-
children:
|
|
746
|
-
nodes:
|
|
745
|
+
children: r && r.length > 0 ? /* @__PURE__ */ z(N, {
|
|
746
|
+
nodes: r,
|
|
747
747
|
ctx: de
|
|
748
748
|
}) : /* @__PURE__ */ B("p", {
|
|
749
749
|
style: {
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
Copyright 2016 The Inter Project Authors (https://github.com/rsms/inter) Inter-Italic[opsz,wght].ttf: Copyright 2016 The Inter Project Authors (https://github.com/rsms/inter)
|
|
2
|
+
|
|
3
|
+
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
|
4
|
+
This license is copied below, and is also available with a FAQ at:
|
|
5
|
+
http://scripts.sil.org/OFL
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
-----------------------------------------------------------
|
|
9
|
+
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
10
|
+
-----------------------------------------------------------
|
|
11
|
+
|
|
12
|
+
PREAMBLE
|
|
13
|
+
The goals of the Open Font License (OFL) are to stimulate worldwide
|
|
14
|
+
development of collaborative font projects, to support the font creation
|
|
15
|
+
efforts of academic and linguistic communities, and to provide a free and
|
|
16
|
+
open framework in which fonts may be shared and improved in partnership
|
|
17
|
+
with others.
|
|
18
|
+
|
|
19
|
+
The OFL allows the licensed fonts to be used, studied, modified and
|
|
20
|
+
redistributed freely as long as they are not sold by themselves. The
|
|
21
|
+
fonts, including any derivative works, can be bundled, embedded,
|
|
22
|
+
redistributed and/or sold with any software provided that any reserved
|
|
23
|
+
names are not used by derivative works. The fonts and derivatives,
|
|
24
|
+
however, cannot be released under any other type of license. The
|
|
25
|
+
requirement for fonts to remain under this license does not apply
|
|
26
|
+
to any document created using the fonts or their derivatives.
|
|
27
|
+
|
|
28
|
+
DEFINITIONS
|
|
29
|
+
"Font Software" refers to the set of files released by the Copyright
|
|
30
|
+
Holder(s) under this license and clearly marked as such. This may
|
|
31
|
+
include source files, build scripts and documentation.
|
|
32
|
+
|
|
33
|
+
"Reserved Font Name" refers to any names specified as such after the
|
|
34
|
+
copyright statement(s).
|
|
35
|
+
|
|
36
|
+
"Original Version" refers to the collection of Font Software components as
|
|
37
|
+
distributed by the Copyright Holder(s).
|
|
38
|
+
|
|
39
|
+
"Modified Version" refers to any derivative made by adding to, deleting,
|
|
40
|
+
or substituting -- in part or in whole -- any of the components of the
|
|
41
|
+
Original Version, by changing formats or by porting the Font Software to a
|
|
42
|
+
new environment.
|
|
43
|
+
|
|
44
|
+
"Author" refers to any designer, engineer, programmer, technical
|
|
45
|
+
writer or other person who contributed to the Font Software.
|
|
46
|
+
|
|
47
|
+
PERMISSION & CONDITIONS
|
|
48
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
49
|
+
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
|
50
|
+
redistribute, and sell modified and unmodified copies of the Font
|
|
51
|
+
Software, subject to the following conditions:
|
|
52
|
+
|
|
53
|
+
1) Neither the Font Software nor any of its individual components,
|
|
54
|
+
in Original or Modified Versions, may be sold by itself.
|
|
55
|
+
|
|
56
|
+
2) Original or Modified Versions of the Font Software may be bundled,
|
|
57
|
+
redistributed and/or sold with any software, provided that each copy
|
|
58
|
+
contains the above copyright notice and this license. These can be
|
|
59
|
+
included either as stand-alone text files, human-readable headers or
|
|
60
|
+
in the appropriate machine-readable metadata fields within text or
|
|
61
|
+
binary files as long as those fields can be easily viewed by the user.
|
|
62
|
+
|
|
63
|
+
3) No Modified Version of the Font Software may use the Reserved Font
|
|
64
|
+
Name(s) unless explicit written permission is granted by the corresponding
|
|
65
|
+
Copyright Holder. This restriction only applies to the primary font name as
|
|
66
|
+
presented to the users.
|
|
67
|
+
|
|
68
|
+
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
|
69
|
+
Software shall not be used to promote, endorse or advertise any
|
|
70
|
+
Modified Version, except to acknowledge the contribution(s) of the
|
|
71
|
+
Copyright Holder(s) and the Author(s) or with their explicit written
|
|
72
|
+
permission.
|
|
73
|
+
|
|
74
|
+
5) The Font Software, modified or unmodified, in part or in whole,
|
|
75
|
+
must be distributed entirely under this license, and must not be
|
|
76
|
+
distributed under any other license. The requirement for fonts to
|
|
77
|
+
remain under this license does not apply to any document created
|
|
78
|
+
using the Font Software.
|
|
79
|
+
|
|
80
|
+
TERMINATION
|
|
81
|
+
This license becomes null and void if any of the above conditions are
|
|
82
|
+
not met.
|
|
83
|
+
|
|
84
|
+
DISCLAIMER
|
|
85
|
+
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
86
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
|
87
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
|
88
|
+
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
|
89
|
+
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
90
|
+
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
|
91
|
+
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
92
|
+
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
|
93
|
+
OTHER DEALINGS IN THE FONT SOFTWARE.
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
Copyright 2020 The JetBrains Mono Project Authors (https://github.com/JetBrains/JetBrainsMono) JetBrainsMono-Italic[wght].ttf: Copyright 2020 The JetBrains Mono Project Authors (https://github.com/JetBrains/JetBrainsMono)
|
|
2
|
+
|
|
3
|
+
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
|
4
|
+
This license is copied below, and is also available with a FAQ at:
|
|
5
|
+
http://scripts.sil.org/OFL
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
-----------------------------------------------------------
|
|
9
|
+
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
10
|
+
-----------------------------------------------------------
|
|
11
|
+
|
|
12
|
+
PREAMBLE
|
|
13
|
+
The goals of the Open Font License (OFL) are to stimulate worldwide
|
|
14
|
+
development of collaborative font projects, to support the font creation
|
|
15
|
+
efforts of academic and linguistic communities, and to provide a free and
|
|
16
|
+
open framework in which fonts may be shared and improved in partnership
|
|
17
|
+
with others.
|
|
18
|
+
|
|
19
|
+
The OFL allows the licensed fonts to be used, studied, modified and
|
|
20
|
+
redistributed freely as long as they are not sold by themselves. The
|
|
21
|
+
fonts, including any derivative works, can be bundled, embedded,
|
|
22
|
+
redistributed and/or sold with any software provided that any reserved
|
|
23
|
+
names are not used by derivative works. The fonts and derivatives,
|
|
24
|
+
however, cannot be released under any other type of license. The
|
|
25
|
+
requirement for fonts to remain under this license does not apply
|
|
26
|
+
to any document created using the fonts or their derivatives.
|
|
27
|
+
|
|
28
|
+
DEFINITIONS
|
|
29
|
+
"Font Software" refers to the set of files released by the Copyright
|
|
30
|
+
Holder(s) under this license and clearly marked as such. This may
|
|
31
|
+
include source files, build scripts and documentation.
|
|
32
|
+
|
|
33
|
+
"Reserved Font Name" refers to any names specified as such after the
|
|
34
|
+
copyright statement(s).
|
|
35
|
+
|
|
36
|
+
"Original Version" refers to the collection of Font Software components as
|
|
37
|
+
distributed by the Copyright Holder(s).
|
|
38
|
+
|
|
39
|
+
"Modified Version" refers to any derivative made by adding to, deleting,
|
|
40
|
+
or substituting -- in part or in whole -- any of the components of the
|
|
41
|
+
Original Version, by changing formats or by porting the Font Software to a
|
|
42
|
+
new environment.
|
|
43
|
+
|
|
44
|
+
"Author" refers to any designer, engineer, programmer, technical
|
|
45
|
+
writer or other person who contributed to the Font Software.
|
|
46
|
+
|
|
47
|
+
PERMISSION & CONDITIONS
|
|
48
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
49
|
+
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
|
50
|
+
redistribute, and sell modified and unmodified copies of the Font
|
|
51
|
+
Software, subject to the following conditions:
|
|
52
|
+
|
|
53
|
+
1) Neither the Font Software nor any of its individual components,
|
|
54
|
+
in Original or Modified Versions, may be sold by itself.
|
|
55
|
+
|
|
56
|
+
2) Original or Modified Versions of the Font Software may be bundled,
|
|
57
|
+
redistributed and/or sold with any software, provided that each copy
|
|
58
|
+
contains the above copyright notice and this license. These can be
|
|
59
|
+
included either as stand-alone text files, human-readable headers or
|
|
60
|
+
in the appropriate machine-readable metadata fields within text or
|
|
61
|
+
binary files as long as those fields can be easily viewed by the user.
|
|
62
|
+
|
|
63
|
+
3) No Modified Version of the Font Software may use the Reserved Font
|
|
64
|
+
Name(s) unless explicit written permission is granted by the corresponding
|
|
65
|
+
Copyright Holder. This restriction only applies to the primary font name as
|
|
66
|
+
presented to the users.
|
|
67
|
+
|
|
68
|
+
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
|
69
|
+
Software shall not be used to promote, endorse or advertise any
|
|
70
|
+
Modified Version, except to acknowledge the contribution(s) of the
|
|
71
|
+
Copyright Holder(s) and the Author(s) or with their explicit written
|
|
72
|
+
permission.
|
|
73
|
+
|
|
74
|
+
5) The Font Software, modified or unmodified, in part or in whole,
|
|
75
|
+
must be distributed entirely under this license, and must not be
|
|
76
|
+
distributed under any other license. The requirement for fonts to
|
|
77
|
+
remain under this license does not apply to any document created
|
|
78
|
+
using the Font Software.
|
|
79
|
+
|
|
80
|
+
TERMINATION
|
|
81
|
+
This license becomes null and void if any of the above conditions are
|
|
82
|
+
not met.
|
|
83
|
+
|
|
84
|
+
DISCLAIMER
|
|
85
|
+
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
86
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
|
87
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
|
88
|
+
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
|
89
|
+
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
90
|
+
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
|
91
|
+
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
92
|
+
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
|
93
|
+
OTHER DEALINGS IN THE FONT SOFTWARE.
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,9 +1,17 @@
|
|
|
1
1
|
import { type FC, type SVGProps } from "react";
|
|
2
|
+
import type { FaviconSource } from "../../../../types/schema";
|
|
2
3
|
type IconFC = FC<SVGProps<SVGSVGElement>>;
|
|
3
4
|
export interface HostIconProps {
|
|
4
5
|
/** Canonical (after-www) hostname; pass null/empty to render the globe. */
|
|
5
6
|
domain: string | null | undefined;
|
|
7
|
+
/**
|
|
8
|
+
* The already-resolved outbound-request policy for this column. Resolved
|
|
9
|
+
* once per column by urlFactory (`field.display.favicon_source`, else the
|
|
10
|
+
* `google` platform default), never per cell: a virtualized list renders
|
|
11
|
+
* this component once per visible row.
|
|
12
|
+
*/
|
|
13
|
+
source: FaviconSource;
|
|
6
14
|
}
|
|
7
|
-
export declare function HostIcon({ domain }: HostIconProps): React.ReactElement;
|
|
15
|
+
export declare function HostIcon({ domain, source }: HostIconProps): React.ReactElement;
|
|
8
16
|
export declare const GENERIC_GLOBE: IconFC;
|
|
9
17
|
export {};
|
|
@@ -17,5 +17,6 @@ export interface TopBarProps {
|
|
|
17
17
|
onOpenPrefs?: () => void;
|
|
18
18
|
showTenantSwitcher?: boolean;
|
|
19
19
|
showBreadcrumbs?: boolean;
|
|
20
|
+
showThemeToggle?: boolean;
|
|
20
21
|
}
|
|
21
|
-
export declare function TopBar({ breadcrumbs, onCrumbClick, onOpenNav, navButtonRef, showNavButton, onOpenTabs, tabsButtonRef, showTabsButton, mobileTabCount, onCmdK, onToggleAI, aiOpen, onOpenProfile, onOpenPrefs, showTenantSwitcher, showBreadcrumbs, }?: TopBarProps): import("react").JSX.Element;
|
|
22
|
+
export declare function TopBar({ breadcrumbs, onCrumbClick, onOpenNav, navButtonRef, showNavButton, onOpenTabs, tabsButtonRef, showTabsButton, mobileTabCount, onCmdK, onToggleAI, aiOpen, onOpenProfile, onOpenPrefs, showTenantSwitcher, showBreadcrumbs, showThemeToggle, }?: TopBarProps): import("react").JSX.Element;
|