@object-ui/plugin-timeline 17.7.0 → 18.0.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.
package/dist/index.js CHANGED
@@ -2,15 +2,15 @@ import * as e from "react";
2
2
  import { useCallback as t, useEffect as n, useMemo as r, useRef as i, useState as a } from "react";
3
3
  import { NavigationOverlay as o, cn as s, cva as c, renderChildren as l } from "@object-ui/components";
4
4
  import { jsx as u, jsxs as d } from "react/jsx-runtime";
5
- import { ComponentRegistry as f, buildExpandFields as p, convertSortToQueryParams as m, createFieldColorResolver as h, elementDataSourceBlock as g, extractRecords as _, isRealCalendarDate as v, recordDisplayValueAt as ee, toDateInputValue as y, toDisplayDate as b, toDisplayEndDate as te, toDomProps as x } from "@object-ui/core";
6
- import { createSafeTranslation as ne, useDisplayLocale as re } from "@object-ui/i18n";
7
- import { ElementDataSourceGate as ie, useDataInvalidation as ae, useDataScope as oe, useFilterScope as se, useNavigationOverlay as ce, useResolvedFilter as le, useSafeFieldLabel as ue, useSchemaContext as de, useSettledSchema as fe } from "@object-ui/react";
5
+ import { ComponentRegistry as f, buildExpandFields as p, convertSortToQueryParams as m, createFieldColorResolver as h, elementDataSourceBlock as g, extractRecords as _, isRealCalendarDate as v, recordDisplayValueAt as y, toDateInputValue as b, toDisplayDate as x, toDisplayEndDate as ee, toDomProps as S } from "@object-ui/core";
6
+ import { createSafeTranslation as te, firstDayOfWeek as ne, useDisplayLocale as re, useObjectTranslation as ie } from "@object-ui/i18n";
7
+ import { ElementDataSourceGate as C, useDataInvalidation as ae, useDataScope as oe, useFilterScope as se, useNavigationOverlay as ce, useResolvedFilter as le, useSafeFieldLabel as ue, useSchemaContext as de, useSettledSchema as fe } from "@object-ui/react";
8
8
  import { usePermissions as pe } from "@object-ui/permissions";
9
9
  import { usePullToRefresh as me } from "@object-ui/mobile";
10
- import { z as S } from "zod";
10
+ import { z as w } from "zod";
11
11
  //#region src/useTimelineTranslation.ts
12
- var C = {
13
- "timeline.bucket.overdue": "Overdue",
12
+ var T = {
13
+ "timeline.bucket.earlier": "Earlier",
14
14
  "timeline.bucket.today": "Today",
15
15
  "timeline.bucket.tomorrow": "Tomorrow",
16
16
  "timeline.bucket.thisWeek": "This week",
@@ -26,7 +26,7 @@ var C = {
26
26
  "timeline.gantt.unusableRange.malformedRow": "Unusable gantt rows — {{path}} is {{value}}, which is not a row shape. A gantt draws items as a list of rows, every row as an object with a label and its own items, and every row's items as a list of bars; a null, a number, a string or a plain object in any of those places cannot be drawn.",
27
27
  "timeline.unsupported.objectBoundGantt": "Unsupported variant \"gantt\" — an object-bound timeline renders the feed variants ({{variants}}). Gantt needs literal rows, each with its own nested items, so the gantt axis (scale) has no effect here.",
28
28
  "timeline.unconfigured.noDateAxis": "Timeline date axis required — this view declares no date field, and an object-bound timeline will not invent one. Declare one of: {{fields}}. The first is the spec spelling; the rest are legacy aliases."
29
- }, w = "timeline.bucket.today", he = (e, t) => Object.entries(t ?? {}).reduce((e, [t, n]) => e.split(`{{${t}}}`).join(String(n)), C[e] || e), ge = ne(C, w), T = /* @__PURE__ */ new Set([
29
+ }, E = "timeline.bucket.today", he = (e, t) => Object.entries(t ?? {}).reduce((e, [t, n]) => e.split(`{{${t}}}`).join(String(n)), T[e] || e), ge = te(T, E), D = /* @__PURE__ */ new Set([
30
30
  "hour",
31
31
  "day",
32
32
  "week",
@@ -34,14 +34,14 @@ var C = {
34
34
  "quarter",
35
35
  "year"
36
36
  ]);
37
- function E(e) {
37
+ function O(e) {
38
38
  let t = e.scale;
39
- return typeof t == "string" && T.has(t) ? t : "month";
39
+ return typeof t == "string" && D.has(t) ? t : "month";
40
40
  }
41
- function D(e) {
42
- return typeof e == "string" ? b(e) : new Date(e);
41
+ function k(e) {
42
+ return typeof e == "string" ? x(e) : new Date(e);
43
43
  }
44
- function O(e) {
44
+ function A(e) {
45
45
  let t = new Date(e);
46
46
  return t.setHours(0, 0, 0, 0), t;
47
47
  }
@@ -58,8 +58,8 @@ var _e = 36e5, ve = {
58
58
  day: "numeric",
59
59
  hour: "numeric"
60
60
  })
61
- }, k = {
62
- floor: O,
61
+ }, ye = {
62
+ floor: A,
63
63
  step: (e) => {
64
64
  e.setDate(e.getDate() + 1);
65
65
  },
@@ -67,15 +67,15 @@ var _e = 36e5, ve = {
67
67
  month: "short",
68
68
  day: "numeric"
69
69
  })
70
- }, ye = {
71
- floor: O,
70
+ }, be = {
71
+ floor: A,
72
72
  step: (e) => {
73
73
  e.setDate(e.getDate() + 7);
74
74
  },
75
75
  label: (e, t, n, r) => r("timeline.scale.week", { n: t + 1 })
76
- }, A = {
76
+ }, j = {
77
77
  floor: (e) => {
78
- let t = O(e);
78
+ let t = A(e);
79
79
  return t.setDate(1), t;
80
80
  },
81
81
  step: (e) => {
@@ -85,9 +85,9 @@ var _e = 36e5, ve = {
85
85
  month: "short",
86
86
  year: "numeric"
87
87
  })
88
- }, j = {
88
+ }, M = {
89
89
  floor: (e) => {
90
- let t = O(e);
90
+ let t = A(e);
91
91
  return t.setMonth(Math.floor(t.getMonth() / 3) * 3, 1), t;
92
92
  },
93
93
  step: (e) => {
@@ -97,9 +97,9 @@ var _e = 36e5, ve = {
97
97
  quarter: Math.floor(e.getMonth() / 3) + 1,
98
98
  year: e.getFullYear()
99
99
  })
100
- }, be = {
100
+ }, N = {
101
101
  floor: (e) => {
102
- let t = O(e);
102
+ let t = A(e);
103
103
  return t.setMonth(0, 1), t;
104
104
  },
105
105
  step: (e) => {
@@ -110,18 +110,18 @@ var _e = 36e5, ve = {
110
110
  function xe(e) {
111
111
  switch (e) {
112
112
  case "hour": return ve;
113
- case "day": return k;
114
- case "week": return ye;
115
- case "quarter": return j;
116
- case "year": return be;
117
- default: return A;
113
+ case "day": return ye;
114
+ case "week": return be;
115
+ case "quarter": return M;
116
+ case "year": return N;
117
+ default: return j;
118
118
  }
119
119
  }
120
- function M(e) {
121
- return typeof e == "string" ? te(e) : D(e);
120
+ function P(e) {
121
+ return typeof e == "string" ? ee(e) : k(e);
122
122
  }
123
- function N(e, t, n, r, i, a) {
124
- let o = D(t).getTime(), s = D(n).getTime();
123
+ function F(e, t, n, r, i, a) {
124
+ let o = k(t).getTime(), s = k(n).getTime();
125
125
  if (Number.isNaN(o) || Number.isNaN(s) || o > s) return;
126
126
  let c = a === void 0 ? s : Math.max(s, a), l = xe(e), u = [], d = l.floor(new Date(o));
127
127
  for (; d.getTime() <= c;) {
@@ -138,7 +138,7 @@ function N(e, t, n, r, i, a) {
138
138
  units: u
139
139
  };
140
140
  }
141
- function P(e, t, n) {
141
+ function I(e, t, n) {
142
142
  let r = e.end - e.start;
143
143
  return {
144
144
  start: (t - e.start) / r * 100,
@@ -146,17 +146,17 @@ function P(e, t, n) {
146
146
  };
147
147
  }
148
148
  function Se(e, t, n, r = "en", i = he) {
149
- let a = N(e, t, n, r, i);
149
+ let a = F(e, t, n, r, i);
150
150
  return a ? a.units.map((e) => e.label) : [];
151
151
  }
152
- function F() {
153
- let e = y(/* @__PURE__ */ new Date());
152
+ function L() {
153
+ let e = b(/* @__PURE__ */ new Date());
154
154
  return {
155
155
  minDate: e,
156
156
  maxDate: e
157
157
  };
158
158
  }
159
- function I(e) {
159
+ function R(e) {
160
160
  if (!Array.isArray(e)) return {
161
161
  ok: !1,
162
162
  path: "items",
@@ -187,32 +187,32 @@ function I(e) {
187
187
  rows: t
188
188
  };
189
189
  }
190
- function L(e) {
190
+ function z(e) {
191
191
  let t = e.flatMap((e) => e.items.flatMap((e) => [e.startDate, e.endDate]));
192
- if (t.length === 0) return F();
193
- let n = Math.min(...t.map((e) => D(e).getTime())), r = Math.max(...t.map((e) => D(e).getTime())), i = Math.max(...e.flatMap((e) => e.items.map((e) => {
194
- let t = D(e.startDate).getTime(), n = M(e.endDate).getTime();
192
+ if (t.length === 0) return L();
193
+ let n = Math.min(...t.map((e) => k(e).getTime())), r = Math.max(...t.map((e) => k(e).getTime())), i = Math.max(...e.flatMap((e) => e.items.map((e) => {
194
+ let t = k(e.startDate).getTime(), n = P(e.endDate).getTime();
195
195
  return n > t ? n - 1 : t;
196
196
  })));
197
197
  return {
198
- minDate: y(new Date(n)),
199
- maxDate: y(new Date(r)),
198
+ minDate: b(new Date(n)),
199
+ maxDate: b(new Date(r)),
200
200
  through: i
201
201
  };
202
202
  }
203
- var R = (e) => {
203
+ var B = (e) => {
204
204
  try {
205
205
  return Date.prototype.getTime.call(e), !0;
206
206
  } catch {
207
207
  return !1;
208
208
  }
209
209
  };
210
- function z(e) {
211
- return typeof e == "string" ? JSON.stringify(e) : e === void 0 ? "undefined" : e === null ? "null" : typeof e == "symbol" ? e.toString() : typeof e == "bigint" ? `${e}n` : typeof e == "number" || typeof e == "boolean" ? String(e) : R(e) ? Date.prototype.toString.call(e) : Array.isArray(e) ? "an array" : typeof e == "function" ? "a function" : "an object";
210
+ function V(e) {
211
+ return typeof e == "string" ? JSON.stringify(e) : e === void 0 ? "undefined" : e === null ? "null" : typeof e == "symbol" ? e.toString() : typeof e == "bigint" ? `${e}n` : typeof e == "number" || typeof e == "boolean" ? String(e) : B(e) ? Date.prototype.toString.call(e) : Array.isArray(e) ? "an array" : typeof e == "function" ? "a function" : "an object";
212
212
  }
213
- var Ce = (e) => typeof e == "string" || typeof e == "number" && Number.isFinite(e) || R(e);
214
- function B(e, t, n) {
215
- let r = (e) => !Ce(e) || Number.isNaN(D(e).getTime());
213
+ var Ce = (e) => typeof e == "string" || typeof e == "number" && Number.isFinite(e) || B(e);
214
+ function we(e, t, n) {
215
+ let r = (e) => !Ce(e) || Number.isNaN(k(e).getTime());
216
216
  for (let t = 0; t < e.length; t++) {
217
217
  let n = e[t].items;
218
218
  for (let e = 0; e < n.length; e++) for (let i of ["startDate", "endDate"]) {
@@ -228,18 +228,18 @@ function B(e, t, n) {
228
228
  value: i
229
229
  };
230
230
  }
231
- function V(e, t, n) {
232
- return P(n, D(e).getTime(), M(t).getTime());
233
- }
234
231
  function H(e, t, n) {
235
- let r = b(e);
232
+ return I(n, k(e).getTime(), P(t).getTime());
233
+ }
234
+ function U(e, t, n) {
235
+ let r = x(e);
236
236
  return t === "short" ? r.toLocaleDateString(n) : t === "long" ? r.toLocaleDateString(n, {
237
237
  year: "numeric",
238
238
  month: "long",
239
239
  day: "numeric"
240
- }) : Number.isNaN(r.getTime()) ? String(e) : v(e) ? y(r) : r.toISOString().split("T")[0];
240
+ }) : Number.isNaN(r.getTime()) ? String(e) : v(e) ? b(r) : r.toISOString().split("T")[0];
241
241
  }
242
- function U({ label: e, color: t }) {
242
+ function W({ label: e, color: t }) {
243
243
  let n = t ? {
244
244
  backgroundColor: `${t}22`,
245
245
  color: t,
@@ -251,26 +251,30 @@ function U({ label: e, color: t }) {
251
251
  children: e
252
252
  });
253
253
  }
254
- function we(e) {
255
- let t = [];
256
- for (let n of e) {
257
- let e = n.group == null ? "" : String(n.group), r = t[t.length - 1];
258
- r && r.key === e ? r.items.push(n) : t.push({
259
- key: e,
260
- items: [n]
261
- });
254
+ function Te(e) {
255
+ let t = [], n = /* @__PURE__ */ new Map();
256
+ for (let r of e) {
257
+ let e = r.group == null ? "" : String(r.group), i = n.get(e);
258
+ if (i) i.items.push(r);
259
+ else {
260
+ let i = {
261
+ key: e,
262
+ items: [r]
263
+ };
264
+ n.set(e, i), t.push(i);
265
+ }
262
266
  }
263
267
  return t;
264
268
  }
265
- var W = ({ schema: e, className: t, style: n, ...r }) => {
269
+ var Ee = ({ schema: e, className: t, style: n, ...r }) => {
266
270
  let { variant: i = "vertical", items: a = [], dateFormat: o = "short", onItemClick: c } = e, f = re(), { t: p } = ge();
267
271
  if (i === "vertical") {
268
- let e = we(a), i = e.some((e) => e.key !== ""), p = (e, t) => {
272
+ let e = Te(a), i = e.some((e) => e.key !== ""), p = (e, t) => {
269
273
  let n = e.color ? {
270
274
  backgroundColor: `${e.color}33`,
271
275
  borderColor: e.color
272
- } : void 0, r = e.time ? H(e.time, o, f) : e.startDate ? H(e.startDate, o, f) : "", i = e.endDate && e.endDate !== e.startDate ? H(e.endDate, o, f) : "", a = Array.isArray(e.meta) ? e.meta : [];
273
- return /* @__PURE__ */ d(Pe, {
276
+ } : void 0, r = e.time ? U(e.time, o, f) : e.startDate ? U(e.startDate, o, f) : "", i = e.endDate && e.endDate !== e.startDate ? U(e.endDate, o, f) : "", a = Array.isArray(e.meta) ? e.meta : [];
277
+ return /* @__PURE__ */ d(Ie, {
274
278
  density: "compact",
275
279
  className: s(e.className, c && "cursor-pointer"),
276
280
  onClick: () => c?.(e),
@@ -281,7 +285,7 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
281
285
  className: "text-xs",
282
286
  children: e.icon
283
287
  })
284
- }), /* @__PURE__ */ d(Ie, { children: [
288
+ }), /* @__PURE__ */ d(Re, { children: [
285
289
  (r || i) && /* @__PURE__ */ d(J, {
286
290
  dateTime: e.time || e.startDate,
287
291
  className: "!mb-1 text-xs",
@@ -296,7 +300,7 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
296
300
  }),
297
301
  a.length > 0 && /* @__PURE__ */ u("div", {
298
302
  className: "flex flex-wrap gap-1.5 mt-1 mb-1",
299
- children: a.map((e) => /* @__PURE__ */ u(U, {
303
+ children: a.map((e) => /* @__PURE__ */ u(W, {
300
304
  label: e.label,
301
305
  color: e.color
302
306
  }, e.key))
@@ -310,7 +314,7 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
310
314
  }, t);
311
315
  };
312
316
  return i ? /* @__PURE__ */ u("div", {
313
- ...x(r),
317
+ ...S(r),
314
318
  className: s("px-4 sm:px-6 py-2", t),
315
319
  style: n,
316
320
  children: e.map((e, t) => /* @__PURE__ */ d("section", {
@@ -327,17 +331,17 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
327
331
  })]
328
332
  }, `${e.key}-${t}`))
329
333
  }) : /* @__PURE__ */ u(G, {
330
- ...x(r),
334
+ ...S(r),
331
335
  className: t,
332
336
  style: n,
333
337
  children: a.map((e, t) => p(e, t))
334
338
  });
335
339
  }
336
- if (i === "horizontal") return /* @__PURE__ */ u(Le, {
337
- ...x(r),
340
+ if (i === "horizontal") return /* @__PURE__ */ u(ze, {
341
+ ...S(r),
338
342
  className: s("overflow-x-auto [-webkit-overflow-scrolling:touch]", t),
339
343
  style: n,
340
- children: a.map((e, t) => /* @__PURE__ */ d(Re, {
344
+ children: a.map((e, t) => /* @__PURE__ */ d(Be, {
341
345
  className: s(e.className, c && "cursor-pointer"),
342
346
  onClick: () => c?.(e),
343
347
  children: [/* @__PURE__ */ d("div", {
@@ -353,7 +357,7 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
353
357
  children: [
354
358
  e.time && /* @__PURE__ */ u(J, {
355
359
  dateTime: e.time,
356
- children: H(e.time, o, f)
360
+ children: U(e.time, o, f)
357
361
  }),
358
362
  e.title && /* @__PURE__ */ u(q, { children: e.title }),
359
363
  e.description && /* @__PURE__ */ u(Y, {
@@ -367,32 +371,32 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
367
371
  }, t))
368
372
  });
369
373
  if (i === "gantt") {
370
- let i = I(a);
374
+ let i = R(a);
371
375
  if (!i.ok) return /* @__PURE__ */ u("div", {
372
376
  className: "p-4 text-destructive",
373
377
  "data-testid": "timeline-unusable-date-range",
374
378
  role: "alert",
375
379
  children: p("timeline.gantt.unusableRange.malformedRow", {
376
380
  path: i.path,
377
- value: z(i.value)
381
+ value: V(i.value)
378
382
  })
379
383
  });
380
- let l = i.rows, m = B(l, e.minDate, e.maxDate);
384
+ let l = i.rows, m = we(l, e.minDate, e.maxDate);
381
385
  if (m) return /* @__PURE__ */ u("div", {
382
386
  className: "p-4 text-destructive",
383
387
  "data-testid": "timeline-unusable-date-range",
384
388
  role: "alert",
385
389
  children: p("timeline.gantt.unusableRange.malformedDate", {
386
390
  path: m.path,
387
- value: z(m.value)
391
+ value: V(m.value)
388
392
  })
389
393
  });
390
- let h = L(l), g = e.minDate || h.minDate, _ = e.maxDate || h.maxDate, v = N(E(e), g, _, f, p, e.maxDate ? void 0 : h.through);
391
- return v ? /* @__PURE__ */ d(ze, {
392
- ...x(r),
394
+ let h = z(l), g = e.minDate || h.minDate, _ = e.maxDate || h.maxDate, v = F(O(e), g, _, f, p, e.maxDate ? void 0 : h.through);
395
+ return v ? /* @__PURE__ */ d(Ve, {
396
+ ...S(r),
393
397
  className: s("overflow-x-auto [-webkit-overflow-scrolling:touch]", t),
394
398
  style: n,
395
- children: [/* @__PURE__ */ d(Be, { children: [/* @__PURE__ */ u(X, {
399
+ children: [/* @__PURE__ */ d(He, { children: [/* @__PURE__ */ u(X, {
396
400
  className: "flex items-center px-2 sm:px-4 py-2 sm:py-3",
397
401
  children: /* @__PURE__ */ u("span", {
398
402
  className: "font-semibold text-xs sm:text-sm",
@@ -402,12 +406,12 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
402
406
  className: "flex h-full",
403
407
  children: v.units.map((e, t) => /* @__PURE__ */ u("div", {
404
408
  className: "shrink-0 min-w-0 overflow-hidden px-1 sm:px-2 py-2 sm:py-3 border-r text-xs font-medium text-center",
405
- style: { width: `${P(v, e.start, e.end).width}%` },
409
+ style: { width: `${I(v, e.start, e.end).width}%` },
406
410
  children: e.label
407
411
  }, t))
408
412
  }) })] }), /* @__PURE__ */ u("div", { children: /* @__PURE__ */ d("div", {
409
413
  className: "flex",
410
- children: [/* @__PURE__ */ u(X, { children: l.map((e, t) => /* @__PURE__ */ u(Q, { children: /* @__PURE__ */ u(Ve, {
414
+ children: [/* @__PURE__ */ u(X, { children: l.map((e, t) => /* @__PURE__ */ u(Q, { children: /* @__PURE__ */ u(Ue, {
411
415
  title: e.label,
412
416
  className: "truncate",
413
417
  children: e.label
@@ -416,14 +420,14 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
416
420
  children: l.map((e, t) => /* @__PURE__ */ u(Q, {
417
421
  className: "relative",
418
422
  children: e.items.map((n, r) => {
419
- let i = V(n.startDate, n.endDate, v);
420
- return /* @__PURE__ */ u(He, {
423
+ let i = H(n.startDate, n.endDate, v);
424
+ return /* @__PURE__ */ u(We, {
421
425
  start: i.start,
422
426
  width: i.width,
423
427
  variant: n.variant || "default",
424
428
  onClick: () => c?.(n, e.authored, t, r),
425
- title: `${n.title || ""}\n${H(n.startDate, o, f)} - ${H(n.endDate, o, f)}`,
426
- children: /* @__PURE__ */ u(Ue, { children: n.title })
429
+ title: `${n.title || ""}\n${U(n.startDate, o, f)} - ${U(n.endDate, o, f)}`,
430
+ children: /* @__PURE__ */ u(Ge, { children: n.title })
427
431
  }, r);
428
432
  })
429
433
  }, t))
@@ -434,14 +438,14 @@ var W = ({ schema: e, className: t, style: n, ...r }) => {
434
438
  "data-testid": "timeline-unusable-date-range",
435
439
  role: "alert",
436
440
  children: p("timeline.gantt.unusableRange.inverted", {
437
- minDate: z(g),
438
- maxDate: z(_)
441
+ minDate: V(g),
442
+ maxDate: V(_)
439
443
  })
440
444
  });
441
445
  }
442
446
  return null;
443
447
  };
444
- f.register("timeline", W, {
448
+ f.register("timeline", Ee, {
445
449
  namespace: "plugin-timeline",
446
450
  skipFallback: !0,
447
451
  label: "Timeline",
@@ -473,7 +477,7 @@ f.register("timeline", W, {
473
477
  {
474
478
  name: "scale",
475
479
  type: "enum",
476
- enum: [...T]
480
+ enum: [...D]
477
481
  },
478
482
  {
479
483
  name: "rowLabel",
@@ -621,37 +625,36 @@ f.register("timeline", W, {
621
625
  }
622
626
  }
623
627
  });
624
- function Te(e) {
628
+ function De(e) {
625
629
  return typeof e == "number" && Number.isInteger(e) && e > 0;
626
630
  }
627
- function Ee(e, t) {
628
- return Te(e) ? e : t;
631
+ function Oe(e, t) {
632
+ return De(e) ? e : t;
629
633
  }
630
- function De(e, t) {
631
- return e == null || Te(e) ? null : `[ObjectUI] ObjectTimeline row cap: ${typeof t == "string" && t ? `object-timeline on ${t}` : "object-timeline"} declared limit: ${String(e)}, which is not a positive integer. A row cap must be a positive integer (the spec refuses zero and negative values), so it was ignored and this timeline fell back to its default row cap (100).`;
634
+ function ke(e, t) {
635
+ return e == null || De(e) ? null : `[ObjectUI] ObjectTimeline row cap: ${typeof t == "string" && t ? `object-timeline on ${t}` : "object-timeline"} declared limit: ${String(e)}, which is not a positive integer. A row cap must be a positive integer (the spec refuses zero and negative values), so it was ignored and this timeline fell back to its default row cap (100).`;
632
636
  }
633
- var Oe = ["vertical", "horizontal"], ke = [
637
+ var Ae = ["vertical", "horizontal"], je = [
634
638
  "timeline.startDateField",
635
- "timeline.dateField",
636
639
  "mapping.date",
637
640
  "startDateField",
638
641
  "dateField"
639
- ], Ae = S.object({
640
- title: S.string().optional(),
641
- date: S.string().optional(),
642
- description: S.string().optional(),
643
- variant: S.string().optional()
644
- }), je = S.object({
645
- mapping: Ae.optional(),
646
- objectName: S.string().optional(),
647
- titleField: S.string().optional(),
648
- dateField: S.string().optional(),
649
- startDateField: S.string().optional(),
650
- endDateField: S.string().optional(),
651
- descriptionField: S.string().optional(),
652
- groupByField: S.string().optional(),
653
- colorField: S.string().optional(),
654
- scale: S.enum([
642
+ ], Me = w.object({
643
+ title: w.string().optional(),
644
+ date: w.string().optional(),
645
+ description: w.string().optional(),
646
+ variant: w.string().optional()
647
+ }), Ne = w.object({
648
+ mapping: Me.optional(),
649
+ objectName: w.string().optional(),
650
+ titleField: w.string().optional(),
651
+ dateField: w.string().optional(),
652
+ startDateField: w.string().optional(),
653
+ endDateField: w.string().optional(),
654
+ descriptionField: w.string().optional(),
655
+ groupByField: w.string().optional(),
656
+ colorField: w.string().optional(),
657
+ scale: w.enum([
655
658
  "hour",
656
659
  "day",
657
660
  "week",
@@ -659,78 +662,78 @@ var Oe = ["vertical", "horizontal"], ke = [
659
662
  "quarter",
660
663
  "year"
661
664
  ]).optional()
662
- }), Me = ({ schema: e, dataSource: s, className: c, onRowClick: l, onItemClick: f, ...g }) => {
663
- let [v, y] = a([]), [te, x] = a(() => {
665
+ }), Pe = ({ schema: e, dataSource: s, className: c, onRowClick: l, onItemClick: f, ...g }) => {
666
+ let [v, b] = a([]), [ee, S] = a(() => {
664
667
  let t = Array.isArray(e.items) && e.items.length > 0, n = Array.isArray(g.data) && g.data.length > 0;
665
668
  return !t && !n && !!e.objectName;
666
- }), [ne, re] = a(null), ie = i(0), [de, S] = a(0), C = e.timeline;
669
+ }), [te, ie] = a(null), C = i(0), [de, w] = a(0), T = e.timeline;
667
670
  n(() => {
668
- let t = je.safeParse(e);
671
+ let t = Ne.safeParse(e);
669
672
  t.success || console.warn("[ObjectTimeline] Invalid timeline configuration:", t.error.format());
670
673
  }, [e]), n(() => {
671
- let t = De(e.limit, e.objectName);
674
+ let t = ke(e.limit, e.objectName);
672
675
  t && console.warn(t);
673
676
  }, [e.limit, e.objectName]);
674
- let w = oe(e.bind), { ready: he, def: T } = fe(e.objectName ?? "", s), E = pe(), D = se(), O = le(e.filter, D), _e = JSON.stringify(O ?? null), ve = JSON.stringify(e.sort ?? null), k = !!e.objectName && !w && !e.items && !g.data, ye = ae(k ? e.objectName : void 0);
677
+ let E = oe(e.bind), { ready: he, def: D } = fe(e.objectName ?? "", s), O = pe(), k = se(), A = le(e.filter, k), _e = JSON.stringify(A ?? null), ve = JSON.stringify(e.sort ?? null), ye = !!e.objectName && !E && !e.items && !g.data, be = ae(ye ? e.objectName : void 0);
675
678
  n(() => {
676
- let t = ++ie.current, n = () => ie.current === t, r = async () => {
679
+ let t = ++C.current, n = () => C.current === t, r = async () => {
677
680
  if (!s || typeof s.find != "function" || !e.objectName) {
678
- x(!1);
681
+ S(!1);
679
682
  return;
680
683
  }
681
- x(!0);
684
+ S(!0);
682
685
  try {
683
- let t = p(T?.fields), r = E?.isLoaded ? t.filter((t) => E.checkField(e.objectName, t, "read")) : t, i = await s.find(e.objectName, {
684
- $filter: O,
686
+ let t = p(D?.fields), r = O?.isLoaded ? t.filter((t) => O.checkField(e.objectName, t, "read")) : t, i = await s.find(e.objectName, {
687
+ $filter: A,
685
688
  $orderby: m(e.sort),
686
- $top: Ee(e.limit, 100),
689
+ $top: Oe(e.limit, 100),
687
690
  ...r.length > 0 ? { $expand: r } : {}
688
691
  }), a = _(i);
689
- n() && (y(a), re(null));
692
+ n() && (b(a), ie(null));
690
693
  } catch (e) {
691
- console.error(e), n() && re(e);
694
+ console.error(e), n() && ie(e);
692
695
  } finally {
693
- n() && x(!1);
696
+ n() && S(!1);
694
697
  }
695
698
  };
696
- if (k) {
699
+ if (ye) {
697
700
  if (!he) return;
698
701
  r();
699
- } else x(!1);
702
+ } else S(!1);
700
703
  }, [
701
704
  e.objectName,
702
705
  s,
703
- w,
706
+ E,
704
707
  e.items,
705
708
  g.data,
706
709
  de,
707
710
  he,
708
- T,
711
+ D,
709
712
  _e,
710
713
  ve,
711
714
  e.limit,
712
- E,
713
- ye
715
+ O,
716
+ be
714
717
  ]);
715
- let A = g.data || w || v, { t: j } = ge(), { fieldOptionLabel: be } = ue(), xe = C?.titleField ?? e.mapping?.title ?? e.titleField ?? "name", M = C?.startDateField ?? C?.dateField ?? e.mapping?.date ?? e.startDateField ?? e.dateField, N = C?.endDateField ?? e.endDateField ?? M, P = e.mapping?.description ?? e.descriptionField ?? "description", Se = e.mapping?.variant ?? "variant", F = C?.groupByField ?? e.groupByField, I = C?.colorField ?? e.colorField, L = r(() => {
718
+ let j = g.data || E || v, { t: M } = ge(), { fieldOptionLabel: N } = ue(), xe = re(), P = T?.titleField ?? e.mapping?.title ?? e.titleField ?? "name", F = T?.startDateField ?? e.mapping?.date ?? e.startDateField ?? e.dateField, I = T?.endDateField ?? e.endDateField ?? F, Se = e.mapping?.description ?? e.descriptionField ?? "description", L = e.mapping?.variant ?? "variant", R = T?.groupByField ?? e.groupByField, z = T?.colorField ?? e.colorField, B = r(() => {
716
719
  if (e.items) return e.items;
717
- if (!A || !Array.isArray(A) || !M) return [];
718
- let t = M, n = N ?? M, r = T?.fields ?? {}, i = e.objectName || "", a = (e) => {
720
+ if (!j || !Array.isArray(j) || !F) return [];
721
+ let t = F, n = I ?? F, r = D?.fields ?? {}, i = e.objectName || "", a = (e) => {
719
722
  if (!e || !r[e]?.options) return {};
720
723
  let t = {};
721
724
  for (let n of r[e].options) n && n.value != null && (t[String(n.value)] = n);
722
725
  return t;
723
726
  }, o = ["status", "priority"].filter((e) => r[e]), s = {};
724
727
  for (let e of o) s[e] = a(e);
725
- let c = h(r[I ?? ""]), l = (e, t, n) => {
728
+ let c = h(r[z ?? ""]), l = (e, t, n) => {
726
729
  if (t == null || t === "") return null;
727
730
  let r = n[String(t)];
728
731
  return {
729
- label: r?.label ? be(i, e, String(t), r.label) : String(t),
732
+ label: r?.label ? N(i, e, String(t), r.label) : String(t),
730
733
  color: r?.color
731
734
  };
732
- }, u = A.map((e) => {
733
- let r = e[t], a = e[n], u = I ? e[I] : void 0, d = F ? e[F] : void 0, f = [];
735
+ }, u = j.map((e) => {
736
+ let r = e[t], a = e[n], u = z ? e[z] : void 0, d = R ? e[R] : void 0, f = [];
734
737
  if (i) for (let t of o) {
735
738
  let n = l(t, e[t], s[t] || {});
736
739
  n && f.push({
@@ -740,12 +743,12 @@ var Oe = ["vertical", "horizontal"], ke = [
740
743
  });
741
744
  }
742
745
  return {
743
- title: ee(e, xe),
746
+ title: y(e, P),
744
747
  time: r,
745
748
  startDate: r,
746
749
  endDate: a,
747
- description: ee(e, P),
748
- variant: e[Se] || "default",
750
+ description: y(e, Se),
751
+ variant: e[L] || "default",
749
752
  color: c(u),
750
753
  group: d,
751
754
  meta: f,
@@ -753,81 +756,82 @@ var Oe = ["vertical", "horizontal"], ke = [
753
756
  };
754
757
  }), d = (e) => {
755
758
  if (!e) return Infinity;
756
- let t = b(e).getTime();
759
+ let t = x(e).getTime();
757
760
  return Number.isNaN(t) ? Infinity : t;
758
761
  };
759
762
  u.sort((e, t) => d(e.startDate) - d(t.startDate));
760
- let f = /* @__PURE__ */ new Date(), p = (e) => new Date(e.getFullYear(), e.getMonth(), e.getDate()).getTime(), m = p(f), g = 864e5, _ = m - (f.getDay() + 6) % 7 * g + 7 * g, v = _ + 7 * g, y = (e) => {
761
- if (!e) return j("timeline.bucket.noDate");
762
- let t = p(b(e));
763
- return Number.isNaN(t) ? j("timeline.bucket.noDate") : t < m ? j("timeline.bucket.overdue") : t === m ? j("timeline.bucket.today") : t === m + g ? j("timeline.bucket.tomorrow") : j(t < _ ? "timeline.bucket.thisWeek" : t < v ? "timeline.bucket.nextWeek" : "timeline.bucket.later");
763
+ let f = /* @__PURE__ */ new Date(), p = (e) => new Date(e.getFullYear(), e.getMonth(), e.getDate()).getTime(), m = (e) => new Date(f.getFullYear(), f.getMonth(), f.getDate() + e).getTime(), g = m(0), _ = m(1), v = (f.getDay() - ne(xe) + 7) % 7, b = m(7 - v), ee = m(14 - v), S = (e) => {
764
+ if (!e) return M("timeline.bucket.noDate");
765
+ let t = p(x(e));
766
+ return M(Number.isNaN(t) ? "timeline.bucket.noDate" : t < g ? "timeline.bucket.earlier" : t === g ? "timeline.bucket.today" : t === _ ? "timeline.bucket.tomorrow" : t < b ? "timeline.bucket.thisWeek" : t < ee ? "timeline.bucket.nextWeek" : "timeline.bucket.later");
764
767
  };
765
- if (F && !u.every((e) => e.group == null || e.group === "")) {
766
- let e = a(F);
767
- return u.map((t) => {
768
- let n = l(F, t.group, e);
769
- return {
770
- ...t,
771
- group: n ? n.label : t.group != null && t.group !== "" ? String(t.group) : j("timeline.bucket.unassigned")
772
- };
768
+ if (R) {
769
+ let e = a(R), t = u.map((t) => {
770
+ let n = t.group != null && t.group !== "" ? e[String(t.group)] : void 0;
771
+ return n?.label ? N(i, R, String(t.group), n.label) : Array.isArray(t.group) ? String(t.group) : y(t._data, R);
773
772
  });
773
+ if (t.some((e) => e !== void 0)) return u.map((e, n) => ({
774
+ ...e,
775
+ group: t[n] ?? M("timeline.bucket.unassigned")
776
+ }));
774
777
  }
775
778
  return u.map((e) => ({
776
779
  ...e,
777
- group: y(e.startDate)
780
+ group: S(e.startDate)
778
781
  }));
779
782
  }, [
780
783
  e.items,
781
- A,
782
- T,
784
+ j,
785
+ D,
783
786
  e.objectName,
784
- xe,
785
- M,
786
- N,
787
787
  P,
788
- Se,
789
- I,
790
788
  F,
791
- j,
792
- be
793
- ]), R = t(async () => {
794
- S((e) => e + 1);
795
- }, []), { ref: z, isRefreshing: Ce, pullDistance: B } = me({
796
- onRefresh: R,
789
+ I,
790
+ Se,
791
+ L,
792
+ z,
793
+ R,
794
+ M,
795
+ N,
796
+ xe
797
+ ]), V = t(async () => {
798
+ w((e) => e + 1);
799
+ }, []), { ref: Ce, isRefreshing: we, pullDistance: H } = me({
800
+ onRefresh: V,
797
801
  enabled: !!e.objectName && !!s
798
- }), V = ce({
802
+ }), U = ce({
799
803
  navigation: e.navigation,
800
804
  objectName: e.objectName,
801
805
  onRowClick: l ?? f
802
- }), H = C?.scale ?? e.scale, U = !!e.items;
803
- if (!U && e.variant === "gantt") return /* @__PURE__ */ u("div", {
806
+ }), W = T?.scale ?? e.scale, Te = !!e.items;
807
+ if (!Te && e.variant === "gantt") return /* @__PURE__ */ u("div", {
804
808
  className: "p-4 text-destructive",
805
809
  "data-testid": "timeline-unsupported-variant",
806
810
  role: "alert",
807
- children: j("timeline.unsupported.objectBoundGantt", { variants: Oe.join(", ") })
811
+ children: M("timeline.unsupported.objectBoundGantt", { variants: Ae.join(", ") })
808
812
  });
809
- if (!U && !M) return /* @__PURE__ */ u("div", {
813
+ if (!Te && !F) return /* @__PURE__ */ u("div", {
810
814
  className: "p-4 text-destructive",
811
815
  "data-testid": "timeline-missing-date-axis",
812
816
  role: "alert",
813
- children: j("timeline.unconfigured.noDateAxis", { fields: ke.join(", ") })
817
+ children: M("timeline.unconfigured.noDateAxis", { fields: je.join(", ") })
814
818
  });
815
- let we = {
819
+ let De = {
816
820
  ...e,
817
- items: L || [],
821
+ items: B || [],
818
822
  className: c || e.className,
819
- ...H ? { scale: H } : {},
823
+ ...W ? { scale: W } : {},
820
824
  onItemClick: (e) => {
821
825
  let t = e._data || e;
822
- V.handleClick(t), f?.(t);
826
+ U.handleClick(t), f?.(t);
823
827
  }
824
828
  };
825
- return ne ? /* @__PURE__ */ d("div", {
829
+ return te ? /* @__PURE__ */ d("div", {
826
830
  className: "p-4 text-destructive",
827
831
  "data-testid": "timeline-error",
828
832
  role: "alert",
829
- children: ["Error loading timeline: ", ne.message]
830
- }) : te && (!L || L.length === 0) ? /* @__PURE__ */ d("div", {
833
+ children: ["Error loading timeline: ", te.message]
834
+ }) : ee && (!B || B.length === 0) ? /* @__PURE__ */ d("div", {
831
835
  className: "flex flex-col h-full min-h-[200px] p-4 gap-3",
832
836
  "data-testid": "timeline-loading",
833
837
  role: "status",
@@ -850,18 +854,18 @@ var Oe = ["vertical", "horizontal"], ke = [
850
854
  })]
851
855
  }, e))]
852
856
  }) : /* @__PURE__ */ d("div", {
853
- ref: z,
857
+ ref: Ce,
854
858
  className: "relative overflow-auto h-full min-w-0",
855
859
  "data-testid": "timeline-canvas",
856
860
  children: [
857
- B > 0 && /* @__PURE__ */ u("div", {
861
+ H > 0 && /* @__PURE__ */ u("div", {
858
862
  className: "flex items-center justify-center text-xs text-muted-foreground",
859
- style: { height: B },
860
- children: Ce ? "Refreshing…" : "Pull to refresh"
863
+ style: { height: H },
864
+ children: we ? "Refreshing…" : "Pull to refresh"
861
865
  }),
862
- /* @__PURE__ */ u(W, { schema: we }),
863
- V.isOverlay && /* @__PURE__ */ u(o, {
864
- ...V,
866
+ /* @__PURE__ */ u(Ee, { schema: De }),
867
+ U.isOverlay && /* @__PURE__ */ u(o, {
868
+ ...U,
865
869
  title: "Timeline Item",
866
870
  children: (e) => /* @__PURE__ */ u("div", {
867
871
  className: "space-y-3",
@@ -885,20 +889,20 @@ var Oe = ["vertical", "horizontal"], ke = [
885
889
  ...t
886
890
  }));
887
891
  G.displayName = "Timeline";
888
- var Ne = c("ml-6", {
892
+ var Fe = c("ml-6", {
889
893
  variants: { density: {
890
894
  default: "mb-10",
891
895
  compact: "mb-3",
892
896
  comfortable: "mb-6"
893
897
  } },
894
898
  defaultVariants: { density: "default" }
895
- }), Pe = e.forwardRef(({ className: e, density: t, ...n }, r) => /* @__PURE__ */ u("li", {
899
+ }), Ie = e.forwardRef(({ className: e, density: t, ...n }, r) => /* @__PURE__ */ u("li", {
896
900
  ref: r,
897
- className: s(Ne({ density: t }), e),
901
+ className: s(Fe({ density: t }), e),
898
902
  ...n
899
903
  }));
900
- Pe.displayName = "TimelineItem";
901
- var Fe = c("absolute -left-3 w-6 h-6 rounded-full border-2 flex items-center justify-center", {
904
+ Ie.displayName = "TimelineItem";
905
+ var Le = c("absolute -left-3 w-6 h-6 rounded-full border-2 flex items-center justify-center", {
902
906
  variants: { variant: {
903
907
  default: "bg-blue-200 border-blue-400",
904
908
  success: "bg-emerald-200 border-emerald-500",
@@ -912,16 +916,16 @@ var Fe = c("absolute -left-3 w-6 h-6 rounded-full border-2 flex items-center jus
912
916
  defaultVariants: { variant: "default" }
913
917
  }), K = e.forwardRef(({ className: e, variant: t = "default", ...n }, r) => /* @__PURE__ */ u("div", {
914
918
  ref: r,
915
- className: s(Fe({ variant: t }), e),
919
+ className: s(Le({ variant: t }), e),
916
920
  ...n
917
921
  }));
918
922
  K.displayName = "TimelineMarker";
919
- var Ie = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
923
+ var Re = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
920
924
  ref: n,
921
925
  className: e,
922
926
  ...t
923
927
  }));
924
- Ie.displayName = "TimelineContent";
928
+ Re.displayName = "TimelineContent";
925
929
  var q = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("h3", {
926
930
  ref: n,
927
931
  className: s("font-semibold text-lg mb-1", e),
@@ -940,30 +944,30 @@ var Y = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("p", {
940
944
  ...t
941
945
  }));
942
946
  Y.displayName = "TimelineDescription";
943
- var Le = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
947
+ var ze = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
944
948
  ref: n,
945
949
  className: s("relative flex overflow-x-auto py-8", e),
946
950
  ...t
947
951
  }));
948
- Le.displayName = "TimelineHorizontal";
949
- var Re = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
952
+ ze.displayName = "TimelineHorizontal";
953
+ var Be = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
950
954
  ref: n,
951
955
  className: s("shrink-0 w-64 relative", e),
952
956
  ...t
953
957
  }));
954
- Re.displayName = "TimelineHorizontalItem";
955
- var ze = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
958
+ Be.displayName = "TimelineHorizontalItem";
959
+ var Ve = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
956
960
  ref: n,
957
961
  className: s("relative w-full border rounded-lg overflow-hidden", e),
958
962
  ...t
959
963
  }));
960
- ze.displayName = "TimelineGantt";
961
- var Be = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
964
+ Ve.displayName = "TimelineGantt";
965
+ var He = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
962
966
  ref: n,
963
967
  className: s("flex border-b bg-gray-50", e),
964
968
  ...t
965
969
  }));
966
- Be.displayName = "TimelineGanttHeader";
970
+ He.displayName = "TimelineGanttHeader";
967
971
  var X = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
968
972
  ref: n,
969
973
  className: s("w-48 border-r bg-white", e),
@@ -982,13 +986,13 @@ var Q = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
982
986
  ...t
983
987
  }));
984
988
  Q.displayName = "TimelineGanttRow";
985
- var Ve = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
989
+ var Ue = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
986
990
  ref: n,
987
991
  className: s("px-4 py-2 font-medium text-sm truncate", e),
988
992
  ...t
989
993
  }));
990
- Ve.displayName = "TimelineGanttLabel";
991
- var He = e.forwardRef(({ className: e, start: t = 0, width: n = 100, variant: r = "default", ...i }, a) => /* @__PURE__ */ u("div", {
994
+ Ue.displayName = "TimelineGanttLabel";
995
+ var We = e.forwardRef(({ className: e, start: t = 0, width: n = 100, variant: r = "default", ...i }, a) => /* @__PURE__ */ u("div", {
992
996
  ref: a,
993
997
  className: s("absolute h-8 rounded-md transition-colors cursor-pointer", {
994
998
  default: "bg-blue-500 hover:bg-blue-600",
@@ -1003,32 +1007,32 @@ var He = e.forwardRef(({ className: e, start: t = 0, width: n = 100, variant: r
1003
1007
  },
1004
1008
  ...i
1005
1009
  }));
1006
- He.displayName = "TimelineGanttBar";
1007
- var Ue = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
1010
+ We.displayName = "TimelineGanttBar";
1011
+ var Ge = e.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ u("div", {
1008
1012
  ref: n,
1009
1013
  className: s("px-2 py-1 text-white text-xs font-medium truncate", e),
1010
1014
  ...t
1011
1015
  }));
1012
- Ue.displayName = "TimelineGanttBarContent";
1013
- var We = {
1016
+ Ge.displayName = "TimelineGanttBarContent";
1017
+ var Ke = {
1014
1018
  filter: !0,
1015
1019
  sort: !0,
1016
1020
  limit: "limit"
1017
1021
  }, $ = g(({ schema: e, ...t }) => {
1018
- let { dataSource: n } = de() || {};
1019
- return /* @__PURE__ */ u(ie, {
1022
+ let { dataSource: n } = de() || {}, { t: r } = ie();
1023
+ return /* @__PURE__ */ u(C, {
1020
1024
  schema: e,
1021
- mapping: We,
1025
+ mapping: Ke,
1022
1026
  dataSource: n,
1023
1027
  testId: "object-timeline",
1024
- errorTitle: "This timeline’s data source could not be resolved",
1025
- children: (e) => /* @__PURE__ */ u(Me, {
1028
+ errorTitle: r("element.timeline.sourceUnresolved", { defaultValue: "This timeline’s data source could not be resolved" }),
1029
+ children: (e) => /* @__PURE__ */ u(Pe, {
1026
1030
  schema: e,
1027
1031
  dataSource: n,
1028
1032
  ...t
1029
1033
  })
1030
1034
  });
1031
- }), Ge = [
1035
+ }), qe = [
1032
1036
  {
1033
1037
  name: "objectName",
1034
1038
  type: "string",
@@ -1076,7 +1080,7 @@ var We = {
1076
1080
  {
1077
1081
  name: "items",
1078
1082
  type: "array",
1079
- description: "Static inline entries — read ahead of every record source, `data` above included, and bypasses the object query entirely (the renderer becomes a pass-through). Each element is objectui's declared timeline element, `@object-ui/types`'s `TimelineFeedItem` (`variant` absent / `vertical` / `horizontal`) or `TimelineGanttItem` (`variant: 'gantt'`), the arm this node's `variant` selects. They are drawn as written: the `timeline` block’s field bindings, `mapping` and `descriptionField` do not apply to them."
1083
+ description: "Static inline entries — read ahead of every record source, `data` above included, and bypasses the object query entirely (the renderer becomes a pass-through). Each entry is the kind this node's `variant` selects: a feed entry `{ time?, title, description?, variant?, icon?, content?, className? }` (`variant` absent / `vertical` / `horizontal`), or a gantt row `{ label, items? }` (`variant: 'gantt'`) whose bars are `{ title?, startDate?, endDate?, variant? }`, each date a string or epoch milliseconds. These are `@object-ui/types`'s `TimelineFeedItem` and `TimelineGanttItem`. They are drawn as written: the `timeline` block’s field bindings, `mapping` and `descriptionField` do not apply to them."
1080
1084
  },
1081
1085
  {
1082
1086
  name: "dateFormat",
@@ -1111,19 +1115,19 @@ var We = {
1111
1115
  {
1112
1116
  name: "mapping",
1113
1117
  type: "object",
1114
- description: "Record-to-entry field mapping ({ title, date, description, variant }) — the objectui-side binding record read BETWEEN the `timeline` block and the flat fallbacks. Its `variant` member (the field whose value picks each marker colour, renderer default `variant`) is the only spelling that binding has. On the vertical rail a colour that `timeline.colorField` resolves for an entry outranks that marker colour."
1118
+ description: "Record-to-entry field mapping `{ title?, date?, description?, variant? }`, each a field name — the binding record read BETWEEN the `timeline` block and the flat fallbacks. Its `variant` member (the field whose value picks each marker colour, renderer default `variant`) is the only spelling that binding has. On the vertical rail a colour that `timeline.colorField` resolves for an entry outranks that marker colour."
1115
1119
  }
1116
1120
  ];
1117
1121
  f.register("object-timeline", $, {
1118
1122
  namespace: "plugin-timeline",
1119
1123
  label: "Object Timeline",
1120
1124
  category: "view",
1121
- inputs: [...Ge]
1125
+ inputs: [...qe]
1122
1126
  }), f.register("timeline", $, {
1123
1127
  namespace: "view",
1124
1128
  label: "Timeline View",
1125
1129
  category: "view",
1126
- inputs: [...Ge]
1130
+ inputs: [...qe]
1127
1131
  });
1128
1132
  //#endregion
1129
- export { Me as ObjectTimeline, $ as ObjectTimelineRenderer, T as TIMELINE_SCALES, G as Timeline, Ie as TimelineContent, Y as TimelineDescription, ze as TimelineGantt, He as TimelineGanttBar, Ue as TimelineGanttBarContent, Z as TimelineGanttGrid, Be as TimelineGanttHeader, Ve as TimelineGanttLabel, Q as TimelineGanttRow, X as TimelineGanttRowLabels, Le as TimelineHorizontal, Re as TimelineHorizontalItem, Pe as TimelineItem, K as TimelineMarker, W as TimelineRenderer, J as TimelineTime, q as TimelineTitle, Se as generateTimeScaleHeaders, E as resolveTimelineScale, Ne as timelineItemVariants, Fe as timelineMarkerVariants };
1133
+ export { Pe as ObjectTimeline, $ as ObjectTimelineRenderer, D as TIMELINE_SCALES, G as Timeline, Re as TimelineContent, Y as TimelineDescription, Ve as TimelineGantt, We as TimelineGanttBar, Ge as TimelineGanttBarContent, Z as TimelineGanttGrid, He as TimelineGanttHeader, Ue as TimelineGanttLabel, Q as TimelineGanttRow, X as TimelineGanttRowLabels, ze as TimelineHorizontal, Be as TimelineHorizontalItem, Ie as TimelineItem, K as TimelineMarker, Ee as TimelineRenderer, J as TimelineTime, q as TimelineTitle, Se as generateTimeScaleHeaders, O as resolveTimelineScale, Fe as timelineItemVariants, Le as timelineMarkerVariants };