@ai-matrx/records-ui 0.116.84 → 0.116.86

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/CHANGELOG.md CHANGED
@@ -1,5 +1,24 @@
1
1
  # Changelog — @ai-matrx/records-ui
2
2
 
3
+ <!-- matrx-auto-git-docs-resolution-needed-delete-this-when-resolved — two versions follow: LOCAL first, then GITHUB. (LOCAL latest 2026-10-22 09:12; GITHUB latest 2026-10-22 11:20; LOCAL lacks 2 of GITHUB's 8 new lines; GITHUB lacks 1 of LOCAL's 2 new lines; recover: git show aed77f7b0f:'apps/shared/records-ui/CHANGELOG.md' / 6acfc6b938:'apps/shared/records-ui/CHANGELOG.md') Delete these three marker lines when resolved. -->
4
+
5
+ ## 0.116.86
6
+
7
+ - **A total's filter written by a template reads in words (CD-FORMULA-04, lane CLOSE-FORMULA, 2026-10-22).** Column settings on a roll-up whose `config.filter` is the store's flat map (`{"status": {"not": "Lost"}}`, `{"result": ["Rework", "Fail"]}`, `{"paid": null}`, `{"logged_on": {"relative": "this_month"}}`, the list words) read "Only use records where ." on every one of the 98 filtered roll-ups in the live store; `conditionInWords` now reads that grammar (`flatFilterInWords`, exported) and never returns an empty sentence. Guard: `a-total-filter-from-a-template-reads-in-words.test.tsx` (13 red on 0.116.76, green now). Consumer action: none.
8
+ <!-- matrx-auto-git-docs-resolution-needed-delete-this-when-resolved — GITHUB version below -->
9
+ ## 0.116.85
10
+
11
+ SOURCE CHANGED WITH NO RELEASE NOTE. This release shipped source changes that nobody described in an Unreleased entry,
12
+ so they may include breaking API changes. Consumer action is UNKNOWN: read the diff before upgrading.
13
+ Diff: `git diff 66ed17883d 35a2d04ffa -- apps/shared/records-ui/src`
14
+
15
+ Changed shipped source files (4):
16
+ - `apps/shared/records-ui/src/FieldHistoryPanel.tsx`
17
+ - `apps/shared/records-ui/src/FormulaHistoryList.tsx`
18
+ - `apps/shared/records-ui/src/HistoryPanel.tsx`
19
+ - `apps/shared/records-ui/src/valueSource.ts`
20
+ <!-- matrx-auto-git-docs-resolution-needed-delete-this-when-resolved — end of both versions -->
21
+
3
22
  ## 0.116.84
4
23
 
5
24
  - **A choice column's settings link it to a named pick list (lane L58, defect 91, 2026-10-22).** Column settings of a Choice / Several-choices column carry "Choices come from" (`PickListLink.tsx`): the organization's pick lists, read only when the picker opens, or "This column only". Choosing a list saves the Field's `options_table_id` alone in the one settings call; "This column only" sends the words shown with the column's kind. The cell editor and an agent's pick-list read already follow `options_table_id`. Guard: `a-column-settings-link-a-column-to-a-named-pick-list.test.tsx`. Consumer action: none.
@@ -4,9 +4,9 @@ import {
4
4
  SAVE_TO_TABLE_TYPES,
5
5
  SaveToTable,
6
6
  shapesOfSource
7
- } from "./chunk-OGEB2WDY.js";
7
+ } from "./chunk-7IBO6WSM.js";
8
8
  import "./chunk-ESNTHDQO.js";
9
- import "./chunk-3I6HFES6.js";
9
+ import "./chunk-NSRAGMZ2.js";
10
10
  import "./chunk-6Z537SLG.js";
11
11
  import "./chunk-LBZZDHV6.js";
12
12
  import "./chunk-K7OX6RG6.js";
@@ -17,4 +17,4 @@ export {
17
17
  SaveToTable,
18
18
  shapesOfSource
19
19
  };
20
- //# sourceMappingURL=SaveToTable-IHKEDRQY.js.map
20
+ //# sourceMappingURL=SaveToTable-NJQZTAMX.js.map
@@ -12,6 +12,7 @@ import {
12
12
  declareTable,
13
13
  fieldName,
14
14
  hintForAPerson,
15
+ memberName,
15
16
  realPlural,
16
17
  recordName,
17
18
  recordVersions_exports,
@@ -22,10 +23,11 @@ import {
22
23
  tablePickerEntries,
23
24
  tokenFor,
24
25
  useChoiceNudge,
26
+ useMemberRoster,
25
27
  useRecordsUi,
26
28
  useTableRights,
27
29
  writeOnTheWinningVersion_exports
28
- } from "./chunk-3I6HFES6.js";
30
+ } from "./chunk-NSRAGMZ2.js";
29
31
  import {
30
32
  guessColumn,
31
33
  readTableShapes,
@@ -3044,6 +3046,12 @@ function BookingBuilder({ tableId, bookingId, onSaved, onClose, startNew, classN
3044
3046
  const [days, setDays] = useState3(30);
3045
3047
  const [timezone, setTimezone] = useState3(() => ownTimeZone());
3046
3048
  const [windows, setWindows] = useState3(() => draftWindows(null));
3049
+ const [capacity, setCapacity] = useState3(1);
3050
+ const [video, setVideo] = useState3("none");
3051
+ const [videoUrl, setVideoUrl] = useState3("");
3052
+ const [busyFeed, setBusyFeed] = useState3("");
3053
+ const [hosts, setHosts] = useState3([]);
3054
+ const roster = useMemberRoster();
3047
3055
  const [asked, setAsked] = useState3([]);
3048
3056
  const [confirmation, setConfirmation] = useState3("");
3049
3057
  const [messages, setMessages] = useState3({});
@@ -3118,6 +3126,11 @@ function BookingBuilder({ tableId, bookingId, onSaved, onClose, startNew, classN
3118
3126
  setLead(offer.lead_minutes);
3119
3127
  setPerDay(offer.max_per_day);
3120
3128
  setDays(offer.days);
3129
+ setCapacity(offer.capacity ?? 1);
3130
+ setVideo(offer.video ?? "none");
3131
+ setVideoUrl(offer.video_url ?? "");
3132
+ if (offer.busy_feed !== void 0) setBusyFeed(offer.busy_feed ?? "");
3133
+ setHosts([...new Set(offer.windows.map((w) => w.member_user_id).filter((id) => typeof id === "string" && id !== ""))]);
3121
3134
  if (offer.timezone && offer.timezone !== "UTC") setTimezone(offer.timezone);
3122
3135
  }, [offer]);
3123
3136
  const availability = useCallback3(
@@ -3128,9 +3141,16 @@ function BookingBuilder({ tableId, bookingId, onSaved, onClose, startNew, classN
3128
3141
  lead_minutes: lead,
3129
3142
  max_per_day: perDay,
3130
3143
  days,
3131
- windows: windows.filter((w) => w.on).map((w) => ({ weekday: w.weekday, from: w.from, to: w.to }))
3144
+ // Every host keeps the same hours; with nobody named the bookings are with the organization.
3145
+ windows: windows.filter((w) => w.on).flatMap(
3146
+ (w) => hosts.length === 0 ? [{ weekday: w.weekday, from: w.from, to: w.to }] : hosts.map((member_user_id) => ({ weekday: w.weekday, from: w.from, to: w.to, member_user_id }))
3147
+ ),
3148
+ capacity,
3149
+ video,
3150
+ ...video === "link" ? { video_url: videoUrl.trim() } : {},
3151
+ ...busyFeed.trim() !== "" ? { busy_feed: busyFeed.trim() } : {}
3132
3152
  }),
3133
- [timezone, minutes, buffer, lead, perDay, days, windows]
3153
+ [timezone, minutes, buffer, lead, perDay, days, windows, hosts, capacity, video, videoUrl, busyFeed]
3134
3154
  );
3135
3155
  const startedAsking = useRef2(false);
3136
3156
  useEffect2(() => {
@@ -3348,6 +3368,82 @@ function BookingBuilder({ tableId, bookingId, onSaved, onClose, startNew, classN
3348
3368
  ] }) : /* @__PURE__ */ jsx4("span", { className: "text-xs text-muted-foreground", children: "not taking bookings" })
3349
3369
  ] }, w.weekday))
3350
3370
  ] }),
3371
+ /* @__PURE__ */ jsxs4("div", { className: "grid grid-cols-1 gap-2 @md:grid-cols-2", "data-booking-calendly": "", children: [
3372
+ /* @__PURE__ */ jsxs4("label", { className: "flex flex-col gap-1", children: [
3373
+ /* @__PURE__ */ jsx4(Label3, { className: "text-xs font-medium", children: "People at one time" }),
3374
+ /* @__PURE__ */ jsx4(
3375
+ BasicInput3,
3376
+ {
3377
+ type: "number",
3378
+ min: 1,
3379
+ max: 100,
3380
+ "aria-label": "People at one time",
3381
+ "data-booking-capacity": "",
3382
+ value: capacity,
3383
+ onChange: (e) => setCapacity(Math.min(100, Math.max(1, Number(e.target.value) || 1)))
3384
+ }
3385
+ )
3386
+ ] }),
3387
+ /* @__PURE__ */ jsxs4("label", { className: "flex flex-col gap-1", children: [
3388
+ /* @__PURE__ */ jsx4(Label3, { className: "text-xs font-medium", children: "Video" }),
3389
+ /* @__PURE__ */ jsx4(
3390
+ Select3,
3391
+ {
3392
+ "aria-label": "Video",
3393
+ value: video,
3394
+ onValueChange: (v) => setVideo(v),
3395
+ options: [
3396
+ { value: "none", label: "No video" },
3397
+ { value: "auto", label: "A new video room for each booking" },
3398
+ { value: "link", label: "My own video room" }
3399
+ ]
3400
+ }
3401
+ )
3402
+ ] }),
3403
+ video === "link" ? /* @__PURE__ */ jsxs4("label", { className: "flex flex-col gap-1 @md:col-span-2", children: [
3404
+ /* @__PURE__ */ jsx4(Label3, { className: "text-xs font-medium", children: "Your video room's link" }),
3405
+ /* @__PURE__ */ jsx4(
3406
+ BasicInput3,
3407
+ {
3408
+ "aria-label": "Your video room's link",
3409
+ "data-booking-video-url": "",
3410
+ value: videoUrl,
3411
+ placeholder: "https://meet.google.com/abc-defg-hij",
3412
+ onChange: (e) => setVideoUrl(e.target.value)
3413
+ }
3414
+ )
3415
+ ] }) : null,
3416
+ /* @__PURE__ */ jsxs4("label", { className: "flex flex-col gap-1 @md:col-span-2", children: [
3417
+ /* @__PURE__ */ jsx4(Label3, { className: "text-xs font-medium", children: "Connected calendar (private iCal address)" }),
3418
+ /* @__PURE__ */ jsx4(
3419
+ BasicInput3,
3420
+ {
3421
+ "aria-label": "Connected calendar",
3422
+ "data-booking-busy-feed": "",
3423
+ value: busyFeed,
3424
+ placeholder: "https://calendar.google.com/calendar/ical/\u2026/private-\u2026/basic.ics",
3425
+ onChange: (e) => setBusyFeed(e.target.value)
3426
+ }
3427
+ ),
3428
+ offer?.busy_problem ? /* @__PURE__ */ jsx4("span", { className: "text-xs text-destructive", "data-booking-busy-problem": "", children: offer.busy_problem }) : offer?.busy_feed && offer.busy_read_at ? /* @__PURE__ */ jsxs4("span", { className: "text-xs text-muted-foreground", "data-booking-busy-read": "", children: [
3429
+ "Busy times read ",
3430
+ new Date(offer.busy_read_at).toLocaleString()
3431
+ ] }) : null
3432
+ ] }),
3433
+ roster && roster.size > 1 ? /* @__PURE__ */ jsxs4("div", { className: "flex flex-col gap-1 @md:col-span-2", "data-booking-hosts": "", children: [
3434
+ /* @__PURE__ */ jsx4(Label3, { className: "text-xs font-medium", children: "Who takes bookings (in turn)" }),
3435
+ /* @__PURE__ */ jsx4("div", { className: "flex flex-wrap gap-x-4 gap-y-1.5", children: [...roster.values()].map((m) => /* @__PURE__ */ jsxs4("label", { className: "flex items-center gap-1.5 text-xs", children: [
3436
+ /* @__PURE__ */ jsx4(
3437
+ Checkbox,
3438
+ {
3439
+ checked: hosts.includes(m.userId),
3440
+ onCheckedChange: (on) => setHosts((prev) => on ? [...prev, m.userId] : prev.filter((id) => id !== m.userId))
3441
+ }
3442
+ ),
3443
+ memberName(m)
3444
+ ] }, m.userId)) })
3445
+ ] }) : null
3446
+ ] }),
3351
3447
  /* @__PURE__ */ jsxs4("div", { className: "flex flex-col gap-1.5", children: [
3352
3448
  /* @__PURE__ */ jsx4(Label3, { className: "text-xs font-medium", children: "What to ask the person booking" }),
3353
3449
  askable.length === 0 ? /* @__PURE__ */ jsx4("p", { className: "text-xs text-muted-foreground", children: "This table has no fields yet, so there is nothing a booking page could ask for. Add a field first \u2014 every question is one of this table's own fields." }) : /* @__PURE__ */ jsx4("div", { className: "flex flex-wrap gap-x-4 gap-y-1.5", children: askable.map((f) => /* @__PURE__ */ jsxs4("label", { className: "flex items-center gap-1.5 text-xs", children: [
@@ -5109,4 +5205,4 @@ export {
5109
5205
  shapesOfSource,
5110
5206
  SaveToTable
5111
5207
  };
5112
- //# sourceMappingURL=chunk-OGEB2WDY.js.map
5208
+ //# sourceMappingURL=chunk-7IBO6WSM.js.map