@ai-matrx/records-ui 0.115.69 → 0.115.70
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 +6 -0
- package/dist/index.cjs +26 -24
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +26 -24
- package/dist/index.js.map +1 -1
- package/dist/pickers.cjs +16 -17
- package/dist/pickers.cjs.map +1 -1
- package/dist/pickers.js +16 -17
- package/dist/pickers.js.map +1 -1
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog — @ai-matrx/records-ui
|
|
2
2
|
|
|
3
|
+
## 0.115.70
|
|
4
|
+
|
|
5
|
+
Automatic changed-only republish (docs/metadata drift since the last tag — see
|
|
6
|
+
`git diff npm/records-ui/v0.115.69..npm/records-ui/v0.115.70 -- apps/shared/records-ui`).
|
|
7
|
+
No source changes intended and no consumer action required.
|
|
8
|
+
|
|
3
9
|
## 0.115.69
|
|
4
10
|
|
|
5
11
|
Automatic changed-only republish (docs/metadata drift since the last tag — see
|
package/dist/index.cjs
CHANGED
|
@@ -5085,6 +5085,7 @@ var import_react26 = require("react");
|
|
|
5085
5085
|
var import_source = require("@ai-matrx/content-ir/source");
|
|
5086
5086
|
var import_records14 = require("@ai-matrx/records");
|
|
5087
5087
|
var import_design_system14 = require("@ai-matrx/design-system");
|
|
5088
|
+
var import_outbound_react = require("@ai-matrx/kit/outbound-react");
|
|
5088
5089
|
var import_jsx_runtime16 = require("react/jsx-runtime");
|
|
5089
5090
|
var own = (event) => event.stopPropagation();
|
|
5090
5091
|
function newerKindValue(field2, value, opts = {}) {
|
|
@@ -5133,11 +5134,9 @@ function AddressLink({ value }) {
|
|
|
5133
5134
|
const href = (0, import_records14.addressMapUrl)(value);
|
|
5134
5135
|
if (!words2 || !href) return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "text-muted-foreground", children: "\u2014" });
|
|
5135
5136
|
return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
|
|
5136
|
-
|
|
5137
|
+
import_outbound_react.OutboundLink,
|
|
5137
5138
|
{
|
|
5138
5139
|
href,
|
|
5139
|
-
target: "_blank",
|
|
5140
|
-
rel: "noopener noreferrer",
|
|
5141
5140
|
className: "inline-flex min-w-0 items-center gap-1 text-primary hover:underline",
|
|
5142
5141
|
title: "Open in maps",
|
|
5143
5142
|
"data-records-address": "",
|
|
@@ -5185,7 +5184,7 @@ function marks(text, key) {
|
|
|
5185
5184
|
const link = /^\[([^\]]+)\]\(([^)\s]+)\)$/.exec(tok);
|
|
5186
5185
|
const href = (0, import_records14.safeLinkHref)(link?.[2] ?? "");
|
|
5187
5186
|
out.push(
|
|
5188
|
-
href ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
|
|
5187
|
+
href ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_outbound_react.OutboundLink, { href, className: "text-primary underline-offset-2 hover:underline", onClick: own, children: link?.[1] }, k) : link?.[1] ?? tok
|
|
5189
5188
|
);
|
|
5190
5189
|
} else out.push(/* @__PURE__ */ (0, import_jsx_runtime16.jsx)("em", { children: tok.slice(1, -1) }, k));
|
|
5191
5190
|
last = at + tok.length;
|
|
@@ -6441,6 +6440,7 @@ var import_core6 = require("@ai-matrx/records/core");
|
|
|
6441
6440
|
var import_react36 = require("react");
|
|
6442
6441
|
var import_core5 = require("@ai-matrx/records/core");
|
|
6443
6442
|
var import_design_system19 = require("@ai-matrx/design-system");
|
|
6443
|
+
var import_outbound_react2 = require("@ai-matrx/kit/outbound-react");
|
|
6444
6444
|
var import_jsx_runtime22 = require("react/jsx-runtime");
|
|
6445
6445
|
var WHOLE_VALUE_UNBOUND = "The whole text is kept as a file, and this screen has no way to open files yet.";
|
|
6446
6446
|
function wholeValueLine(pointer) {
|
|
@@ -6455,7 +6455,7 @@ function WholeValueCell({ words: words2, pointer }) {
|
|
|
6455
6455
|
words2,
|
|
6456
6456
|
"\u2026"
|
|
6457
6457
|
] }),
|
|
6458
|
-
href ? host.Link ? host.Link({ href, children: line, className: "shrink-0 text-xs text-primary underline-offset-2 hover:underline" }) : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
6458
|
+
href ? host.Link ? host.Link({ href, children: line, className: "shrink-0 text-xs text-primary underline-offset-2 hover:underline" }) : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_outbound_react2.OutboundLink, { className: "shrink-0 text-xs text-primary underline-offset-2 hover:underline", href, children: line }) : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: "shrink-0 text-xs italic text-muted-foreground", title: WHOLE_VALUE_UNBOUND, children: `${(0, import_core5.wholeValueSize)(pointer)} in a file` })
|
|
6459
6459
|
] });
|
|
6460
6460
|
}
|
|
6461
6461
|
var WHOLE_VALUE_NOT_EDITABLE_HERE = "The whole text is kept as a file. Open it to read it; this screen cannot load it to edit.";
|
|
@@ -6537,6 +6537,7 @@ var import_react37 = require("react");
|
|
|
6537
6537
|
var import_data_table5 = require("@ai-matrx/design-system/data-table");
|
|
6538
6538
|
var import_field_formats3 = require("@ai-matrx/design-system/field-formats");
|
|
6539
6539
|
var import_design_system20 = require("@ai-matrx/design-system");
|
|
6540
|
+
var import_outbound_react3 = require("@ai-matrx/kit/outbound-react");
|
|
6540
6541
|
var import_jsx_runtime23 = require("react/jsx-runtime");
|
|
6541
6542
|
var LINK = "inline-flex min-w-0 items-center gap-1 text-primary hover:underline";
|
|
6542
6543
|
var own2 = (event) => event.stopPropagation();
|
|
@@ -6607,16 +6608,14 @@ function rich(id, text, raw, format) {
|
|
|
6607
6608
|
case "email":
|
|
6608
6609
|
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("a", { href: `mailto:${text}`, className: LINK, onClick: own2, children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "truncate", children: text }) });
|
|
6609
6610
|
case "url":
|
|
6610
|
-
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
6611
|
+
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_outbound_react3.OutboundLink, { href: text.includes("://") ? text : `https://${text}`, className: LINK, onClick: own2, children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "truncate", children: text }) });
|
|
6611
6612
|
case "phone":
|
|
6612
6613
|
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("a", { href: `tel:${text.replace(/[^\d+]/g, "")}`, className: LINK, onClick: own2, title: text, children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "truncate tabular-nums", children: (0, import_field_formats3.formatPhone)(text) }) });
|
|
6613
6614
|
case "address":
|
|
6614
6615
|
return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
|
|
6615
|
-
|
|
6616
|
+
import_outbound_react3.OutboundLink,
|
|
6616
6617
|
{
|
|
6617
6618
|
href: `https://www.google.com/maps/search/?api=1&query=${encodeURIComponent(text)}`,
|
|
6618
|
-
target: "_blank",
|
|
6619
|
-
rel: "noopener noreferrer",
|
|
6620
6619
|
className: LINK,
|
|
6621
6620
|
title: "Open in maps",
|
|
6622
6621
|
onClick: own2,
|
|
@@ -6786,6 +6785,7 @@ function FilePicker({
|
|
|
6786
6785
|
}
|
|
6787
6786
|
|
|
6788
6787
|
// src/gridAttachments.tsx
|
|
6788
|
+
var import_outbound_react4 = require("@ai-matrx/kit/outbound-react");
|
|
6789
6789
|
var import_jsx_runtime25 = require("react/jsx-runtime");
|
|
6790
6790
|
function attachmentIdsOf(value) {
|
|
6791
6791
|
return idsOf(value);
|
|
@@ -6842,11 +6842,9 @@ function AttachmentChip({ id, onRemove }) {
|
|
|
6842
6842
|
const title = href ? `Open ${words2}` : read?.why ?? FILE_CHIP_NO_PAGE;
|
|
6843
6843
|
return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(import_design_system22.Badge, { variant: "secondary", className: "max-w-[14rem] gap-1 text-[11px]", "data-records-file-chip": id, title, children: [
|
|
6844
6844
|
href ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
6845
|
-
|
|
6845
|
+
import_outbound_react4.OutboundLink,
|
|
6846
6846
|
{
|
|
6847
6847
|
href,
|
|
6848
|
-
target: "_blank",
|
|
6849
|
-
rel: "noreferrer",
|
|
6850
6848
|
className: "truncate underline-offset-2 hover:underline",
|
|
6851
6849
|
"data-records-file-link": read?.fileId ?? "",
|
|
6852
6850
|
onClick: (event) => event.stopPropagation(),
|
|
@@ -7505,6 +7503,7 @@ function WorkedOutError({ field: field2, sentence: sentence2, floated = false })
|
|
|
7505
7503
|
}
|
|
7506
7504
|
|
|
7507
7505
|
// src/values.tsx
|
|
7506
|
+
var import_outbound_react5 = require("@ai-matrx/kit/outbound-react");
|
|
7508
7507
|
var import_jsx_runtime30 = require("react/jsx-runtime");
|
|
7509
7508
|
function statusMark(field2, item, document2) {
|
|
7510
7509
|
const mark = statusMarkOf(field2, item, document2);
|
|
@@ -7629,12 +7628,10 @@ function renderValue(field2, value, document2, labels, stillWaitingFor, look) {
|
|
|
7629
7628
|
if (kind === "url" && typeof value === "string") {
|
|
7630
7629
|
const href = value.includes("://") ? value : `https://${value}`;
|
|
7631
7630
|
return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
|
|
7632
|
-
|
|
7631
|
+
import_outbound_react5.OutboundLink,
|
|
7633
7632
|
{
|
|
7634
7633
|
className: "inline-flex min-w-0 max-w-full items-center gap-1 rounded-md border border-border bg-muted/60 px-1.5 py-0.5 text-[11px] text-foreground hover:bg-accent",
|
|
7635
7634
|
href,
|
|
7636
|
-
target: "_blank",
|
|
7637
|
-
rel: "noreferrer",
|
|
7638
7635
|
title: value,
|
|
7639
7636
|
"data-records-link-chip": "",
|
|
7640
7637
|
onClick: (event) => event.stopPropagation(),
|
|
@@ -10451,6 +10448,8 @@ function NewColumnDefault({
|
|
|
10451
10448
|
}
|
|
10452
10449
|
|
|
10453
10450
|
// src/buttonCell.tsx
|
|
10451
|
+
var import_outbound_react6 = require("@ai-matrx/kit/outbound-react");
|
|
10452
|
+
var import_outbound = require("@ai-matrx/kit/outbound");
|
|
10454
10453
|
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
10455
10454
|
function buttonPressWords(label, pressed) {
|
|
10456
10455
|
if (pressed.do === "open_url") return `${label} opened ${pressed.url}`;
|
|
@@ -10481,7 +10480,7 @@ function ButtonValue({ field: field2, recordId, inCell }) {
|
|
|
10481
10480
|
if (!answered.ok) return setSaid({ kind: "refused", error: answered.error });
|
|
10482
10481
|
const pressed = answered.data;
|
|
10483
10482
|
if (pressed.do === "open_url") {
|
|
10484
|
-
const opened = typeof window !== "undefined" ?
|
|
10483
|
+
const opened = typeof window !== "undefined" ? (0, import_outbound.openOutbound)(pressed.url, "_blank", "noopener") : null;
|
|
10485
10484
|
return setSaid({ kind: "ran", says: opened ? `${b.label} opened.` : `${b.label} is ready:`, link: pressed.url });
|
|
10486
10485
|
}
|
|
10487
10486
|
setSaid({ kind: "ran", says: buttonPressWords(b.label, pressed) });
|
|
@@ -10515,7 +10514,7 @@ function ButtonValue({ field: field2, recordId, inCell }) {
|
|
|
10515
10514
|
said2?.kind === "ran" ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("p", { className: "break-words", children: [
|
|
10516
10515
|
said2.says,
|
|
10517
10516
|
" ",
|
|
10518
|
-
said2.link ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
10517
|
+
said2.link ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_outbound_react6.OutboundLink, { href: said2.link, className: "text-primary underline", children: said2.link }) : null
|
|
10519
10518
|
] }) : null,
|
|
10520
10519
|
said2?.kind === "needs" ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_jsx_runtime39.Fragment, { children: [
|
|
10521
10520
|
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("p", { children: said2.says }),
|
|
@@ -21430,6 +21429,7 @@ function ObjectActionMenuItems({ actions }) {
|
|
|
21430
21429
|
}
|
|
21431
21430
|
|
|
21432
21431
|
// src/RecordActionMenu.tsx
|
|
21432
|
+
var import_outbound2 = require("@ai-matrx/kit/outbound");
|
|
21433
21433
|
var import_jsx_runtime75 = require("react/jsx-runtime");
|
|
21434
21434
|
function duplicateValues(fields, document2) {
|
|
21435
21435
|
const data = {};
|
|
@@ -21462,7 +21462,7 @@ function useRecordActionHost({ tableId, row, onOpenRecord, onChanged, onMerge, o
|
|
|
21462
21462
|
// The record's panel carries its history under it — on its page, or in the table's rail.
|
|
21463
21463
|
...href ? { history: () => window.location.assign(href) } : onOpenRecord ? { history: (r) => onOpenRecord(r.id) } : {},
|
|
21464
21464
|
openInNewTab: (url) => {
|
|
21465
|
-
|
|
21465
|
+
(0, import_outbound2.openOutbound)(url, "_blank", "noopener");
|
|
21466
21466
|
},
|
|
21467
21467
|
copyText: async (url) => {
|
|
21468
21468
|
if (await (0, import_clipboard2.copyText)(url)) {
|
|
@@ -21630,6 +21630,7 @@ function RecordActionMenu({ tableId, row, name, onOpenRecord, onChanged, childre
|
|
|
21630
21630
|
}
|
|
21631
21631
|
|
|
21632
21632
|
// src/gridOpen.tsx
|
|
21633
|
+
var import_outbound3 = require("@ai-matrx/kit/outbound");
|
|
21633
21634
|
var import_jsx_runtime76 = require("react/jsx-runtime");
|
|
21634
21635
|
function openRecordLabel(name) {
|
|
21635
21636
|
return `Open ${name}`;
|
|
@@ -21667,7 +21668,7 @@ function withOpenRecord(columns, onOpen, nameOf2, place = "end", hrefOf) {
|
|
|
21667
21668
|
onOpen(row.id);
|
|
21668
21669
|
return;
|
|
21669
21670
|
}
|
|
21670
|
-
if (event.metaKey || event.ctrlKey)
|
|
21671
|
+
if (event.metaKey || event.ctrlKey) (0, import_outbound3.openOutbound)(href, "_blank", "noopener");
|
|
21671
21672
|
else window.location.assign(href);
|
|
21672
21673
|
},
|
|
21673
21674
|
children: "\u2922"
|
|
@@ -46512,6 +46513,7 @@ function Question({
|
|
|
46512
46513
|
|
|
46513
46514
|
// src/FormBuilder.tsx
|
|
46514
46515
|
var import_forms3 = require("@ai-matrx/records/forms");
|
|
46516
|
+
var import_outbound_react7 = require("@ai-matrx/kit/outbound-react");
|
|
46515
46517
|
var import_jsx_runtime151 = require("react/jsx-runtime");
|
|
46516
46518
|
function freshFormName(base2, taken) {
|
|
46517
46519
|
const names = new Set(taken.map((n) => n.trim().toLowerCase()));
|
|
@@ -47166,11 +47168,9 @@ function PublishRow({
|
|
|
47166
47168
|
) : null,
|
|
47167
47169
|
state !== "draft" ? /* @__PURE__ */ (0, import_jsx_runtime151.jsxs)(import_jsx_runtime151.Fragment, { children: [
|
|
47168
47170
|
/* @__PURE__ */ (0, import_jsx_runtime151.jsx)(
|
|
47169
|
-
|
|
47171
|
+
import_outbound_react7.OutboundLink,
|
|
47170
47172
|
{
|
|
47171
47173
|
href: url,
|
|
47172
|
-
target: "_blank",
|
|
47173
|
-
rel: "noreferrer",
|
|
47174
47174
|
className: "min-w-0 flex-1 truncate text-xs underline underline-offset-2",
|
|
47175
47175
|
children: url
|
|
47176
47176
|
}
|
|
@@ -52156,6 +52156,7 @@ function asRefusal3(e, fallback) {
|
|
|
52156
52156
|
|
|
52157
52157
|
// src/CalendarSubscribe.tsx
|
|
52158
52158
|
var import_design_system150 = require("@ai-matrx/design-system");
|
|
52159
|
+
var import_outbound_react8 = require("@ai-matrx/kit/outbound-react");
|
|
52159
52160
|
var import_jsx_runtime168 = require("react/jsx-runtime");
|
|
52160
52161
|
function CalendarLinkOnce({ url }) {
|
|
52161
52162
|
const notify = useRecordsUi().notify;
|
|
@@ -52183,7 +52184,7 @@ function CalendarLinkOnce({ url }) {
|
|
|
52183
52184
|
] }),
|
|
52184
52185
|
/* @__PURE__ */ (0, import_jsx_runtime168.jsxs)("div", { className: "flex flex-wrap gap-2", children: [
|
|
52185
52186
|
/* @__PURE__ */ (0, import_jsx_runtime168.jsx)(import_design_system150.Button, { asChild: true, size: "sm", variant: "outline", children: /* @__PURE__ */ (0, import_jsx_runtime168.jsx)("a", { href: webcalUrl(url), "data-calendar-apple": "", children: "Open in Apple Calendar" }) }),
|
|
52186
|
-
/* @__PURE__ */ (0, import_jsx_runtime168.jsx)(import_design_system150.Button, { asChild: true, size: "sm", variant: "outline", children: /* @__PURE__ */ (0, import_jsx_runtime168.jsx)(
|
|
52187
|
+
/* @__PURE__ */ (0, import_jsx_runtime168.jsx)(import_design_system150.Button, { asChild: true, size: "sm", variant: "outline", children: /* @__PURE__ */ (0, import_jsx_runtime168.jsx)(import_outbound_react8.OutboundLink, { href: googleCalendarUrl(url), "data-calendar-google": "", children: "Add to Google Calendar" }) })
|
|
52187
52188
|
] }),
|
|
52188
52189
|
/* @__PURE__ */ (0, import_jsx_runtime168.jsx)("p", { className: "text-xs text-muted-foreground", children: "Shown once. Rotate it from Settings if you lose it." })
|
|
52189
52190
|
] });
|
|
@@ -53077,6 +53078,7 @@ function useSlotScroll(slot) {
|
|
|
53077
53078
|
|
|
53078
53079
|
// src/TablePage.tsx
|
|
53079
53080
|
var import_uuid3 = require("@ai-matrx/kit/uuid");
|
|
53081
|
+
var import_outbound4 = require("@ai-matrx/kit/outbound");
|
|
53080
53082
|
var import_jsx_runtime175 = require("react/jsx-runtime");
|
|
53081
53083
|
var RAIL_TITLE = {
|
|
53082
53084
|
settings: "Table settings",
|
|
@@ -53897,7 +53899,7 @@ function TablePage({
|
|
|
53897
53899
|
...actionHost?.extend ? actionHost.extend(subject, mayDo) : []
|
|
53898
53900
|
],
|
|
53899
53901
|
openInNewTab: (url) => {
|
|
53900
|
-
|
|
53902
|
+
(0, import_outbound4.openOutbound)(url, "_blank", "noopener");
|
|
53901
53903
|
},
|
|
53902
53904
|
copyText: async (url) => {
|
|
53903
53905
|
if (await (0, import_clipboard17.copyText)(url)) {
|