@declarion/react 0.87.0 → 0.89.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/dist-lib/app.js +28 -28
  2. package/dist-lib/components/actions/ActionButton.js +86 -85
  3. package/dist-lib/components/actions/ActionResultDialog.impl.js +47 -47
  4. package/dist-lib/components/actions/ActionRunner.js +47 -47
  5. package/dist-lib/components/actions/ObjectActionBar.js +9 -9
  6. package/dist-lib/components/actions/RowActionsKebab.js +19 -19
  7. package/dist-lib/components/agents/AgentChatPanel.impl.js +53 -53
  8. package/dist-lib/components/chrome/AssociationTabs.js +21 -21
  9. package/dist-lib/components/chrome/RecordHeader.js +33 -40
  10. package/dist-lib/components/detail-layout/AssociatedBlock.js +387 -381
  11. package/dist-lib/components/detail-layout/ChildrenBlock.js +12 -13
  12. package/dist-lib/components/detail-layout/ChildrenTimeline.js +198 -198
  13. package/dist-lib/components/detail-layout/DraggableChildrenTable.js +114 -114
  14. package/dist-lib/components/detail-layout/EditableChildrenTable.js +160 -160
  15. package/dist-lib/components/detail-layout/EvidenceBlock.js +20 -21
  16. package/dist-lib/components/detail-layout/PropertiesBlock.js +45 -39
  17. package/dist-lib/components/detail-layout/QuickAddForm.js +9 -9
  18. package/dist-lib/components/detail-layout/TimelineComposer.js +87 -89
  19. package/dist-lib/components/detail-layout/widgets/EntityScorecardWidget.js +100 -99
  20. package/dist-lib/components/fields/FileReferenceField.js +9 -9
  21. package/dist-lib/components/fields/StructureField.js +57 -47
  22. package/dist-lib/components/fields/TimestampField.js +59 -54
  23. package/dist-lib/components/fields/cells/factories/money.js +14 -23
  24. package/dist-lib/components/fields/cells/factories/nextRun.js +1 -1
  25. package/dist-lib/components/fields/cells/factories/text.js +18 -3
  26. package/dist-lib/components/fields/cells/factories/timestamp.js +24 -12
  27. package/dist-lib/components/file-widgets/DocumentCard.js +108 -106
  28. package/dist-lib/components/layout/Layout.js +306 -361
  29. package/dist-lib/components/layout/Rail.js +42 -41
  30. package/dist-lib/components/layout/Sidebar.js +132 -117
  31. package/dist-lib/components/layout/TabStrip.js +116 -115
  32. package/dist-lib/components/layout/TenantChip.js +47 -54
  33. package/dist-lib/components/layout/TopBar.js +108 -105
  34. package/dist-lib/components/list/InlineEditCell.js +23 -23
  35. package/dist-lib/components/list/QuickPeek.js +65 -66
  36. package/dist-lib/components/pages/DocumentsMenu.js +42 -42
  37. package/dist-lib/components/pages/ExportMenu.js +25 -25
  38. package/dist-lib/components/pages/RecordDocumentsPanel.js +35 -35
  39. package/dist-lib/components/pages/RecordNotesPanel.js +94 -93
  40. package/dist-lib/components/pages/SmartDetailPage.impl.js +421 -417
  41. package/dist-lib/components/pages/SmartListPage.impl.js +293 -295
  42. package/dist-lib/components/pages/SmartRecordListPage.impl.js +310 -310
  43. package/dist-lib/components/pages/auth/AuthShell.js +73 -73
  44. package/dist-lib/components/pages/auth/SignIn.js +32 -32
  45. package/dist-lib/components/pages/auth/SignUp.impl.js +3 -3
  46. package/dist-lib/components/pages/auth/SignUpCode.js +9 -9
  47. package/dist-lib/components/pages/list/ListFloatbar.js +12 -12
  48. package/dist-lib/components/pages/list/ListHeader.js +19 -19
  49. package/dist-lib/components/pages/list/ListNoRows.js +15 -15
  50. package/dist-lib/components/pages/list/ListToolbar.js +145 -145
  51. package/dist-lib/components/pages/list/useActiveView.js +14 -5
  52. package/dist-lib/components/pages/list/useListQuery.js +121 -81
  53. package/dist-lib/components/pages/list/useListRowInteraction.js +70 -70
  54. package/dist-lib/components/pages/list/useRowMenu.js +7 -7
  55. package/dist-lib/components/pages/profile/Preferences.impl.js +81 -78
  56. package/dist-lib/components/pages/profile/Profile.impl.js +191 -189
  57. package/dist-lib/components/pages/tenant-params/TenantParamsPage.impl.js +166 -158
  58. package/dist-lib/components/shared/ChangePasswordDialog.impl.js +23 -23
  59. package/dist-lib/components/shared/MarkdownRenderer.js +9 -9
  60. package/dist-lib/hooks/useAuth.js +11 -11
  61. package/dist-lib/hooks/useBranding.js +4 -4
  62. package/dist-lib/hooks/useDisplayTimeZone.js +8 -0
  63. package/dist-lib/hooks/useFollowAgentOpen.js +24 -24
  64. package/dist-lib/hooks/useImpersonation.js +6 -6
  65. package/dist-lib/hooks/useMutations.js +23 -23
  66. package/dist-lib/hooks/useObjectStatus.js +5 -5
  67. package/dist-lib/hooks/useParams.js +59 -51
  68. package/dist-lib/hooks/useProperties.js +8 -8
  69. package/dist-lib/hooks/useRowTenant.js +18 -6
  70. package/dist-lib/hooks/useText.js +9 -7
  71. package/dist-lib/hooks/useUiPreferences.js +71 -0
  72. package/dist-lib/index.d.ts +22 -6
  73. package/dist-lib/index.js +127 -126
  74. package/dist-lib/lib/actions.js +116 -84
  75. package/dist-lib/lib/child-config.js +10 -1
  76. package/dist-lib/lib/format-count.js +16 -1
  77. package/dist-lib/lib/language.js +23 -21
  78. package/dist-lib/lib/money-text.js +29 -0
  79. package/dist-lib/lib/profile.js +4 -0
  80. package/dist-lib/lib/role-label.js +8 -0
  81. package/dist-lib/lib/schema-routing.js +34 -14
  82. package/dist-lib/lib/shortcut.js +10 -0
  83. package/dist-lib/lib/timestamp.js +93 -31
  84. package/dist-lib/stores/auth.js +9 -8
  85. package/dist-lib/stores/preferences.js +56 -17
  86. package/dist-lib/testing.d.ts +1 -1
  87. package/dist-lib/testing.js +25 -28
  88. package/dist-lib/types/schema.js +33 -27
  89. package/dist-lib/{useResponsiveMode-D3SKz5z4.d.ts → useResponsiveMode-9_eJT18k.d.ts} +5 -5
  90. package/package.json +1 -1
@@ -1,13 +1,14 @@
1
1
  import { propertyToField as e } from "../../types/schema.js";
2
2
  import { useText as t } from "../../hooks/useText.js";
3
- import { ClassifiedFieldLocked as n } from "../primitives/ClassifiedFieldLocked.js";
4
- import { classificationTier as r, fieldAccessInfo as i } from "../../lib/field-classification.js";
5
- import { renderField as a } from "../fields/index.js";
6
- import { FieldRow as o, FieldsGrid as s, SPAN_FIELD_TYPES as c } from "./FieldRow.js";
7
- import { useCallback as l, useEffect as u, useRef as d } from "react";
8
- import { jsx as f } from "react/jsx-runtime";
3
+ import { SectionCard as n } from "../primitives/SectionCard.js";
4
+ import { ClassifiedFieldLocked as r } from "../primitives/ClassifiedFieldLocked.js";
5
+ import { classificationTier as i, fieldAccessInfo as a } from "../../lib/field-classification.js";
6
+ import { renderField as o } from "../fields/index.js";
7
+ import { FieldRow as s, FieldsGrid as c, SPAN_FIELD_TYPES as l } from "./FieldRow.js";
8
+ import { useCallback as u, useEffect as d, useRef as f } from "react";
9
+ import { jsx as p } from "react/jsx-runtime";
9
10
  //#region src/components/detail-layout/PropertiesBlock.tsx
10
- var p = /* @__PURE__ */ new Set([
11
+ var m = /* @__PURE__ */ new Set([
11
12
  "string",
12
13
  "text",
13
14
  "int",
@@ -15,52 +16,57 @@ var p = /* @__PURE__ */ new Set([
15
16
  "decimal",
16
17
  "email",
17
18
  "url"
18
- ]), m = 500;
19
- function h({ node: t, ctx: n }) {
20
- let { entity: r, objectProperties: i, onSetProperty: a, isNew: o, mode: c, refs: l } = n, u = r.properties ?? {};
21
- if (o) return null;
22
- let d = t.properties === !0 || t.properties, p = d === !0 ? Object.entries(u).sort(([e], [t]) => e.localeCompare(t)) : d.filter((e) => u[e] != null).map((e) => [e, u[e]]);
23
- return p.length === 0 ? null : /* @__PURE__ */ f(s, {
19
+ ]), h = 500;
20
+ function g({ node: r, ctx: i }) {
21
+ let { entity: a, objectProperties: o, onSetProperty: s, isNew: l, mode: u, refs: d } = i, f = t(), m = a.properties ?? {};
22
+ if (l) return null;
23
+ let h = r.properties === !0 || r.properties, g = h === !0 ? Object.entries(m).sort(([e], [t]) => e.localeCompare(t)) : h.filter((e) => m[e] != null).map((e) => [e, m[e]]);
24
+ if (g.length === 0) return null;
25
+ let v = /* @__PURE__ */ p(c, {
24
26
  columns: 2,
25
- children: p.map(([t, o]) => {
26
- let s = i?.find((e) => e.property_code === t), u = e(o), d = o.readonly || !a ? "display" : c;
27
- return /* @__PURE__ */ f(g, {
27
+ children: g.map(([t, n]) => {
28
+ let r = o?.find((e) => e.property_code === t), c = e(n), l = n.readonly || !s ? "display" : u;
29
+ return /* @__PURE__ */ p(_, {
28
30
  propCode: t,
29
- prop: o,
30
- field: u,
31
- value: s?.value,
32
- mode: d,
33
- onSetProperty: a,
34
- refs: l,
35
- entity: r,
36
- schema: n.schema
31
+ prop: n,
32
+ field: c,
33
+ value: r?.value,
34
+ mode: l,
35
+ onSetProperty: s,
36
+ refs: d,
37
+ entity: a,
38
+ schema: i.schema
37
39
  }, t);
38
40
  })
39
41
  });
42
+ return i.withinCard ? v : /* @__PURE__ */ p(n, {
43
+ title: f("record.properties", "Properties"),
44
+ children: v
45
+ });
40
46
  }
41
- function g({ propCode: e, prop: s, field: h, value: g, mode: _, onSetProperty: v, refs: y, entity: b, schema: x }) {
42
- let S = t(), C = d(null);
43
- u(() => () => {
47
+ function _({ propCode: e, prop: n, field: c, value: g, mode: _, onSetProperty: v, refs: y, entity: b, schema: x }) {
48
+ let S = t(), C = f(null);
49
+ d(() => () => {
44
50
  C.current && clearTimeout(C.current);
45
51
  }, []);
46
- let w = l((t) => {
47
- v && (p.has(s.type) ? (C.current && clearTimeout(C.current), C.current = setTimeout(() => v(e, t), m)) : v(e, t));
52
+ let w = u((t) => {
53
+ v && (m.has(n.type) ? (C.current && clearTimeout(C.current), C.current = setTimeout(() => v(e, t), h)) : v(e, t));
48
54
  }, [
49
55
  e,
50
- s.type,
56
+ n.type,
51
57
  v
52
- ]), T = i(b, e), E = T?.read === "denied", D = T?.write === "denied", O = _ === "display" ? E : D || E, k = _ === "edit" && D ? "display" : _;
53
- return /* @__PURE__ */ f(o, {
54
- label: S(s.display?.name ?? s.name),
58
+ ]), T = a(b, e), E = T?.read === "denied", D = T?.write === "denied", O = _ === "display" ? E : D || E, k = _ === "edit" && D ? "display" : _;
59
+ return /* @__PURE__ */ p(s, {
60
+ label: S(n.display?.name ?? n.name),
55
61
  mode: k,
56
- span: c.has(s.type),
57
- children: O ? /* @__PURE__ */ f(n, {
62
+ span: l.has(n.type),
63
+ children: O ? /* @__PURE__ */ p(r, {
58
64
  tier: T.classification,
59
- tierDef: r(x, b, e),
65
+ tierDef: i(x, b, e),
60
66
  requiredPermission: T?.required_permission,
61
67
  variant: k === "edit" ? "input" : "value"
62
- }) : a({
63
- field: h,
68
+ }) : o({
69
+ field: c,
64
70
  fieldName: e,
65
71
  value: g,
66
72
  mode: k,
@@ -71,4 +77,4 @@ function g({ propCode: e, prop: s, field: h, value: g, mode: _, onSetProperty: v
71
77
  });
72
78
  }
73
79
  //#endregion
74
- export { h as PropertiesBlock };
80
+ export { g as PropertiesBlock };
@@ -1,16 +1,16 @@
1
1
  import { fieldDisplayName as e } from "../../types/schema.js";
2
- import { Icon as t } from "../primitives/Icons.js";
3
- import { Btn as n } from "../primitives/Btn.js";
4
- import { useText as r } from "../../hooks/useText.js";
5
- import { useResponsiveMode as i } from "../../hooks/useResponsiveMode.js";
6
- import { failureTitle as a } from "../../lib/failure.js";
2
+ import { failureTitle as t } from "../../lib/failure.js";
3
+ import { Icon as n } from "../primitives/Icons.js";
4
+ import { Btn as r } from "../primitives/Btn.js";
5
+ import { useText as i } from "../../hooks/useText.js";
6
+ import { useResponsiveMode as a } from "../../hooks/useResponsiveMode.js";
7
7
  import { renderField as o } from "../fields/index.js";
8
8
  import { useQuickAdd as s } from "./useQuickAdd.js";
9
9
  import { useId as c } from "react";
10
10
  import { jsx as l, jsxs as u } from "react/jsx-runtime";
11
11
  //#region src/components/detail-layout/QuickAddForm.tsx
12
12
  function d({ config: d, parentEntity: f, parentId: p, schema: m }) {
13
- let h = r(), g = r("errors"), { values: _, quickAdd: v, childEntity: y, isPending: b, error: x, isReady: S, handleSubmit: C, handleFieldChange: w } = s(d, f, p, m), T = i(), E = c();
13
+ let h = i(), g = i("errors"), { values: _, quickAdd: v, childEntity: y, isPending: b, error: x, isReady: S, handleSubmit: C, handleFieldChange: w } = s(d, f, p, m), T = a(), E = c();
14
14
  return !v || v.fields.length === 0 || !y ? null : /* @__PURE__ */ u("form", {
15
15
  onSubmit: C,
16
16
  style: {
@@ -56,11 +56,11 @@ function d({ config: d, parentEntity: f, parentId: p, schema: m }) {
56
56
  })]
57
57
  }, t);
58
58
  }),
59
- /* @__PURE__ */ l(n, {
59
+ /* @__PURE__ */ l(r, {
60
60
  type: "submit",
61
61
  kind: "primary",
62
62
  size: T.isPhone ? "md" : "sm",
63
- icon: /* @__PURE__ */ l(t.plus, { size: 12 }),
63
+ icon: /* @__PURE__ */ l(n.plus, { size: 12 }),
64
64
  disabled: b || !S,
65
65
  style: T.isPhone ? { alignSelf: "flex-end" } : void 0,
66
66
  children: h("record.related.add", "Add")
@@ -72,7 +72,7 @@ function d({ config: d, parentEntity: f, parentId: p, schema: m }) {
72
72
  alignSelf: "flex-end",
73
73
  marginBottom: 4
74
74
  },
75
- children: a(g, x)
75
+ children: t(g, x)
76
76
  })
77
77
  ]
78
78
  });
@@ -1,99 +1,100 @@
1
1
  import { textWithNodes as e } from "../../lib/language.js";
2
- import { Icon as t } from "../primitives/Icons.js";
3
- import { Btn as n } from "../primitives/Btn.js";
4
- import { useText as r } from "../../hooks/useText.js";
5
- import { failureTitle as i } from "../../lib/failure.js";
6
- import { renderField as a } from "../fields/index.js";
7
- import { registerFieldRegion as o } from "../../lib/field-regions.js";
8
- import { useQuickAdd as s } from "./useQuickAdd.js";
9
- import { useCallback as c, useEffect as l, useMemo as u, useRef as d, useState as f } from "react";
10
- import { Fragment as p, jsx as m, jsxs as h } from "react/jsx-runtime";
2
+ import { failureTitle as t } from "../../lib/failure.js";
3
+ import { Icon as n } from "../primitives/Icons.js";
4
+ import { Btn as r } from "../primitives/Btn.js";
5
+ import { useText as i } from "../../hooks/useText.js";
6
+ import { shortcutLabel as a } from "../../lib/shortcut.js";
7
+ import { renderField as o } from "../fields/index.js";
8
+ import { registerFieldRegion as s } from "../../lib/field-regions.js";
9
+ import { useQuickAdd as c } from "./useQuickAdd.js";
10
+ import { useCallback as l, useEffect as u, useMemo as d, useRef as f, useState as p } from "react";
11
+ import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
11
12
  //#region src/components/detail-layout/TimelineComposer.tsx
12
- var g = "quick_entry", _ = 100, v = 240, y = 800, b = 80;
13
- function x({ config: x, parentEntity: S, parentId: C, schema: w }) {
14
- let { values: T, quickAdd: E, childEntity: D, isPending: O, error: k, isReady: A, handleSubmit: j, handleFieldChange: M } = s(x, S, C, w), N = r(), P = r("errors"), [F, I] = f(v), L = d(null), R = d(null), [z, B] = f(y);
15
- l(() => {
16
- let e = R.current?.parentElement;
13
+ var _ = "quick_entry", v = 100, y = 240, b = 800, x = 80;
14
+ function S({ config: S, parentEntity: C, parentId: w, schema: T }) {
15
+ let { values: E, quickAdd: D, childEntity: O, isPending: k, error: A, isReady: j, handleSubmit: M, handleFieldChange: N } = c(S, C, w, T), P = i(), F = i("errors"), [I, L] = p(y), R = f(null), z = f(null), [B, V] = p(b);
16
+ u(() => {
17
+ let e = z.current?.parentElement;
17
18
  if (!e) return;
18
19
  let t = () => {
19
- let t = Math.max(_, e.clientHeight - b);
20
- B(Math.min(y, t));
20
+ let t = Math.max(v, e.clientHeight - x);
21
+ V(Math.min(b, t));
21
22
  };
22
23
  t();
23
24
  let n = new ResizeObserver(t);
24
25
  return n.observe(e), () => n.disconnect();
25
- }, []), l(() => {
26
- I((e) => Math.min(e, z));
27
- }, [z]);
28
- let V = d(T);
29
- V.current = T;
30
- let H = d(M);
31
- H.current = M;
32
- let U = d({}), W = u(() => ({
33
- getField: (e) => V.current[e],
26
+ }, []), u(() => {
27
+ L((e) => Math.min(e, B));
28
+ }, [B]);
29
+ let H = f(E);
30
+ H.current = E;
31
+ let U = f(N);
32
+ U.current = N;
33
+ let W = f({}), G = d(() => ({
34
+ getField: (e) => H.current[e],
34
35
  setField: (e, t) => {
35
- H.current(e, t);
36
+ U.current(e, t);
36
37
  },
37
38
  focusField: (e) => {
38
- let t = U.current[e];
39
+ let t = W.current[e];
39
40
  t && (t.querySelector("textarea, input, select, [contenteditable]") ?? t).focus();
40
41
  }
41
42
  }), []);
42
- l(() => o(g, W), [W]);
43
- let G = c((e) => {
44
- e.preventDefault(), L.current = {
43
+ u(() => s(_, G), [G]);
44
+ let K = l((e) => {
45
+ e.preventDefault(), R.current = {
45
46
  startY: e.clientY,
46
- startHeight: F
47
+ startHeight: I
47
48
  };
48
49
  let t = (e) => {
49
- if (!L.current) return;
50
- let t = L.current.startY - e.clientY, n = Math.min(z, Math.max(_, L.current.startHeight + t));
51
- I(n);
50
+ if (!R.current) return;
51
+ let t = R.current.startY - e.clientY, n = Math.min(B, Math.max(v, R.current.startHeight + t));
52
+ L(n);
52
53
  }, n = () => {
53
- L.current = null, document.removeEventListener("mousemove", t), document.removeEventListener("mouseup", n);
54
+ R.current = null, document.removeEventListener("mousemove", t), document.removeEventListener("mouseup", n);
54
55
  };
55
56
  document.addEventListener("mousemove", t), document.addEventListener("mouseup", n);
56
- }, [F, z]);
57
- if (!E || E.fields.length === 0 || !D) return null;
58
- let K = E.fields.find((e) => {
59
- let t = D.fields.get(e);
57
+ }, [I, B]);
58
+ if (!D || D.fields.length === 0 || !O) return null;
59
+ let q = D.fields.find((e) => {
60
+ let t = O.fields.get(e);
60
61
  return t && (t.type === "text" || t.type === "string");
61
- }), q = [], J = [];
62
- for (let e of E.fields) {
63
- if (e === K) continue;
64
- let t = D.fields.get(e);
65
- t && (t.type === "enum" ? q.push(e) : J.push(e));
62
+ }), J = [], Y = [];
63
+ for (let e of D.fields) {
64
+ if (e === q) continue;
65
+ let t = O.fields.get(e);
66
+ t && (t.type === "enum" ? J.push(e) : Y.push(e));
66
67
  }
67
- let Y = (e) => {
68
- let t = D.fields.get(e);
69
- return t ? /* @__PURE__ */ m("div", {
68
+ let X = (e) => {
69
+ let t = O.fields.get(e);
70
+ return t ? /* @__PURE__ */ h("div", {
70
71
  ref: (t) => {
71
- U.current[e] = t;
72
+ W.current[e] = t;
72
73
  },
73
- children: a({
74
+ children: o({
74
75
  field: t,
75
76
  fieldName: e,
76
- value: T[e] ?? "",
77
+ value: E[e] ?? "",
77
78
  mode: "edit",
78
- onChange: (t) => M(e, t),
79
- record: T,
80
- t: N
79
+ onChange: (t) => N(e, t),
80
+ record: E,
81
+ t: P
81
82
  })
82
83
  }, e) : null;
83
84
  };
84
- return /* @__PURE__ */ h("div", {
85
- ref: R,
85
+ return /* @__PURE__ */ g("div", {
86
+ ref: z,
86
87
  style: {
87
88
  flexShrink: 0,
88
89
  borderTop: "1px solid var(--divider)",
89
90
  background: "var(--surface)",
90
91
  display: "flex",
91
92
  flexDirection: "column",
92
- height: `${F}px`
93
+ height: `${I}px`
93
94
  },
94
- children: [/* @__PURE__ */ m("div", {
95
- onMouseDown: G,
96
- title: N("record.layout.drag_to_resize", "Drag to resize"),
95
+ children: [/* @__PURE__ */ h("div", {
96
+ onMouseDown: K,
97
+ title: P("record.layout.drag_to_resize", "Drag to resize"),
97
98
  style: {
98
99
  height: 12,
99
100
  cursor: "row-resize",
@@ -102,14 +103,14 @@ function x({ config: x, parentEntity: S, parentId: C, schema: w }) {
102
103
  justifyContent: "center",
103
104
  flexShrink: 0
104
105
  },
105
- children: /* @__PURE__ */ m("div", { style: {
106
+ children: /* @__PURE__ */ h("div", { style: {
106
107
  width: 56,
107
108
  height: 3,
108
109
  borderRadius: 999,
109
110
  background: "var(--border)"
110
111
  } })
111
- }), /* @__PURE__ */ h("form", {
112
- onSubmit: j,
112
+ }), /* @__PURE__ */ g("form", {
113
+ onSubmit: M,
113
114
  onKeyDown: (e) => {
114
115
  (e.metaKey || e.ctrlKey) && e.key === "Enter" && (e.preventDefault(), e.currentTarget.requestSubmit());
115
116
  },
@@ -122,7 +123,7 @@ function x({ config: x, parentEntity: S, parentId: C, schema: w }) {
122
123
  padding: "0 12px 8px"
123
124
  },
124
125
  children: [
125
- q.length > 0 && /* @__PURE__ */ m("div", {
126
+ J.length > 0 && /* @__PURE__ */ h("div", {
126
127
  style: {
127
128
  display: "flex",
128
129
  flexWrap: "wrap",
@@ -130,29 +131,29 @@ function x({ config: x, parentEntity: S, parentId: C, schema: w }) {
130
131
  gap: 6,
131
132
  flexShrink: 0
132
133
  },
133
- children: q.map(Y)
134
+ children: J.map(X)
134
135
  }),
135
- K && D.fields.get(K) && /* @__PURE__ */ m("div", {
136
+ q && O.fields.get(q) && /* @__PURE__ */ h("div", {
136
137
  style: {
137
138
  flex: 1,
138
139
  minHeight: 0,
139
140
  display: "flex"
140
141
  },
141
142
  ref: (e) => {
142
- U.current[K] = e;
143
+ W.current[q] = e;
143
144
  },
144
- children: a({
145
- field: D.fields.get(K),
146
- fieldName: K,
147
- value: T[K] ?? "",
145
+ children: o({
146
+ field: O.fields.get(q),
147
+ fieldName: q,
148
+ value: E[q] ?? "",
148
149
  mode: "edit",
149
- onChange: (e) => M(K, e),
150
- record: T,
150
+ onChange: (e) => N(q, e),
151
+ record: E,
151
152
  fill: !0,
152
- t: N
153
+ t: P
153
154
  })
154
155
  }),
155
- /* @__PURE__ */ h("div", {
156
+ /* @__PURE__ */ g("div", {
156
157
  style: {
157
158
  display: "flex",
158
159
  flexWrap: "wrap",
@@ -160,46 +161,43 @@ function x({ config: x, parentEntity: S, parentId: C, schema: w }) {
160
161
  gap: 6,
161
162
  flexShrink: 0
162
163
  },
163
- children: [J.map(Y), /* @__PURE__ */ h("div", {
164
+ children: [Y.map(X), /* @__PURE__ */ g("div", {
164
165
  style: {
165
166
  marginLeft: "auto",
166
167
  display: "flex",
167
168
  alignItems: "center",
168
169
  gap: 8
169
170
  },
170
- children: [/* @__PURE__ */ m("span", {
171
+ children: [/* @__PURE__ */ h("span", {
171
172
  style: {
172
173
  fontSize: 10.5,
173
174
  color: "var(--text-4)"
174
175
  },
175
- children: e(N("record.related.shortcut_to_add", "{keys} to add"), { keys: /* @__PURE__ */ h(p, { children: [/* @__PURE__ */ m("span", {
176
+ children: e(P("record.related.shortcut_to_add", "{keys} to add"), { keys: /* @__PURE__ */ h(m, { children: /* @__PURE__ */ h("span", {
176
177
  className: "mono",
177
- children: "⌘"
178
- }), /* @__PURE__ */ m("span", {
179
- className: "mono",
180
- children: "↵"
181
- })] }) })
182
- }), /* @__PURE__ */ m(n, {
178
+ children: a("↵")
179
+ }) }) })
180
+ }), /* @__PURE__ */ h(r, {
183
181
  type: "submit",
184
182
  kind: "primary",
185
- icon: /* @__PURE__ */ m(t.plus, { size: 13 }),
186
- disabled: O || !A,
187
- children: N("record.related.add", "Add")
183
+ icon: /* @__PURE__ */ h(n.plus, { size: 13 }),
184
+ disabled: k || !j,
185
+ children: P("record.related.add", "Add")
188
186
  })]
189
187
  })]
190
188
  }),
191
- k != null && /* @__PURE__ */ m("p", {
189
+ A != null && /* @__PURE__ */ h("p", {
192
190
  style: {
193
191
  fontSize: 11,
194
192
  color: "var(--danger)",
195
193
  margin: 0,
196
194
  flexShrink: 0
197
195
  },
198
- children: i(P, k)
196
+ children: t(F, A)
199
197
  })
200
198
  ]
201
199
  })]
202
200
  });
203
201
  }
204
202
  //#endregion
205
- export { x as TimelineComposer };
203
+ export { S as TimelineComposer };