@ai-matrx/records-ui 0.116.46 → 0.116.47
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 +15 -1
- package/dist/{SaveToTable-SWB2ZN5X.js → SaveToTable-HG3HQMAQ.js} +5 -5
- package/dist/{chunk-KQR2RA4V.js → chunk-ABIUJCNS.js} +3 -3
- package/dist/chunk-ABIUJCNS.js.map +1 -0
- package/dist/{chunk-Y5QOV3XA.js → chunk-K3B5IRXY.js} +3 -3
- package/dist/{chunk-OV6QBL5R.js → chunk-LBZZDHV6.js} +8 -8
- package/dist/chunk-LBZZDHV6.js.map +1 -0
- package/dist/{chunk-ZUQUZOL5.js → chunk-MDXDJVDB.js} +3 -3
- package/dist/chunk-MDXDJVDB.js.map +1 -0
- package/dist/{chunk-UTMV5ES2.js → chunk-VJDJQDDI.js} +7 -7
- package/dist/{chunk-UTMV5ES2.js.map → chunk-VJDJQDDI.js.map} +1 -1
- package/dist/helpers.cjs +9 -9
- package/dist/helpers.cjs.map +1 -1
- package/dist/helpers.js +9 -9
- package/dist/helpers.js.map +1 -1
- package/dist/index.cjs +30 -30
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +22 -22
- package/dist/index.js.map +1 -1
- package/dist/object-actions.cjs +8 -8
- package/dist/object-actions.cjs.map +1 -1
- package/dist/object-actions.d.cts +1 -1
- package/dist/object-actions.d.ts +1 -1
- package/dist/object-actions.js +2 -2
- package/dist/{objectActions-Be9sBGvW.d.cts → objectActions-DK-qa5zC.d.cts} +1 -1
- package/dist/{objectActions-Be9sBGvW.d.ts → objectActions-DK-qa5zC.d.ts} +1 -1
- package/dist/pickers.cjs +8 -8
- package/dist/pickers.cjs.map +1 -1
- package/dist/pickers.js +3 -3
- package/package.json +2 -2
- package/dist/chunk-KQR2RA4V.js.map +0 -1
- package/dist/chunk-OV6QBL5R.js.map +0 -1
- package/dist/chunk-ZUQUZOL5.js.map +0 -1
- /package/dist/{SaveToTable-SWB2ZN5X.js.map → SaveToTable-HG3HQMAQ.js.map} +0 -0
- /package/dist/{chunk-Y5QOV3XA.js.map → chunk-K3B5IRXY.js.map} +0 -0
package/dist/index.cjs
CHANGED
|
@@ -54,7 +54,7 @@ function sentenceFor(what, level) {
|
|
|
54
54
|
share: "pass this on to somebody else",
|
|
55
55
|
structure: "change the columns of this table"
|
|
56
56
|
};
|
|
57
|
-
return `You
|
|
57
|
+
return `You have ${have} here, and it takes ${need} to ${doing[what]}. Ask somebody with Full access on it to move you up.`;
|
|
58
58
|
}
|
|
59
59
|
function whatYouMayDo(level, known = true) {
|
|
60
60
|
const may = (what) => known && (0, import_field_kinds.atLeast)(level, NEEDS[what]);
|
|
@@ -92,11 +92,11 @@ var init_rights = __esm({
|
|
|
92
92
|
"use strict";
|
|
93
93
|
import_field_kinds = require("@ai-matrx/records/field-kinds");
|
|
94
94
|
LEVEL_WORD = {
|
|
95
|
-
viewer: "
|
|
96
|
-
commenter: "
|
|
97
|
-
edit_content: "
|
|
98
|
-
editor: "
|
|
99
|
-
admin: "
|
|
95
|
+
viewer: "View access",
|
|
96
|
+
commenter: "Comment access",
|
|
97
|
+
edit_content: "Edit access",
|
|
98
|
+
editor: "Edit access",
|
|
99
|
+
admin: "Full access"
|
|
100
100
|
};
|
|
101
101
|
NEEDS = {
|
|
102
102
|
read: "viewer",
|
|
@@ -118,7 +118,7 @@ var init_rights = __esm({
|
|
|
118
118
|
structure: "admin"
|
|
119
119
|
};
|
|
120
120
|
NOT_YET = "Checking what you may do here. Nothing is offered until then.";
|
|
121
|
-
NOTHING_AT_ALL = "You have not been given this. Ask somebody
|
|
121
|
+
NOTHING_AT_ALL = "You have not been given this. Ask somebody with Full access on it to share it with you.";
|
|
122
122
|
NOT_ANSWERED_YET = whatYouMayDo(null, false);
|
|
123
123
|
KERNEL_REASON = "This is one of the tables the platform ships, so its columns are not changed from a screen. Make your own table to change columns.";
|
|
124
124
|
DATABASE_LOCKED_REASON = "This database is locked, so its columns and settings are read-only. Unlock it to change them.";
|
|
@@ -516,7 +516,7 @@ var init_plainWords = __esm({
|
|
|
516
516
|
// the app, arriving on the screen of somebody who cannot act on it.
|
|
517
517
|
/\bbind\s+[`'"A-Za-z]/i
|
|
518
518
|
];
|
|
519
|
-
TIMED_OUT_SAID = "
|
|
519
|
+
TIMED_OUT_SAID = "That took too long. Nothing was lost; try again.";
|
|
520
520
|
}
|
|
521
521
|
});
|
|
522
522
|
|
|
@@ -5742,7 +5742,7 @@ function BookingBuilder({ tableId, bookingId, onSaved, onClose, startNew, classN
|
|
|
5742
5742
|
}
|
|
5743
5743
|
if (!loaded || fields.loading && !fields.data) return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_design_system36.Skeleton, { className: (0, import_design_system36.cn)("h-64 w-full", className) });
|
|
5744
5744
|
if (!rights.structure) {
|
|
5745
|
-
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("p", { className: (0, import_design_system36.cn)("text-xs text-muted-foreground", className), children: rights.why("structure") ?? "Making a booking page needs
|
|
5745
|
+
return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("p", { className: (0, import_design_system36.cn)("text-xs text-muted-foreground", className), children: rights.why("structure") ?? "Making a booking page needs Full access on this table, because it lets people with no account take time in your calendar." });
|
|
5746
5746
|
}
|
|
5747
5747
|
const url = formId ? `${publicOrigin}${(0, import_records21.bookingPath)(formId)}` : null;
|
|
5748
5748
|
const shown5 = offer ?? null;
|
|
@@ -6156,7 +6156,7 @@ function rightsReason(rights, what, table) {
|
|
|
6156
6156
|
if (what === "structure" && table?.is_kernel) return ACTION_PLATFORM_TABLE_REASON;
|
|
6157
6157
|
if (rights[what]) return null;
|
|
6158
6158
|
if (rights.level === null) return ACTION_NO_ACCESS_REASON;
|
|
6159
|
-
return `Needs ${LEVEL_WORD[levelNeededFor(what)]}
|
|
6159
|
+
return `Needs ${LEVEL_WORD[levelNeededFor(what)]}`;
|
|
6160
6160
|
}
|
|
6161
6161
|
function typingIn(target) {
|
|
6162
6162
|
const el = target;
|
|
@@ -6540,7 +6540,7 @@ function archivedThings(forms, checklists) {
|
|
|
6540
6540
|
id: f.form_id,
|
|
6541
6541
|
title: f.title?.trim() || f.slug,
|
|
6542
6542
|
archivedAt: f.archived_at,
|
|
6543
|
-
whyNot: f.can_restore ? null : f.table_archived ? "Its table is archived" : "Needs
|
|
6543
|
+
whyNot: f.can_restore ? null : f.table_archived ? "Its table is archived" : "Needs Full access on this table"
|
|
6544
6544
|
}));
|
|
6545
6545
|
const fromChecklists = checklists.map((c) => ({
|
|
6546
6546
|
kind: "checklist",
|
|
@@ -6640,7 +6640,7 @@ var init_BuiltOnArchive = __esm({
|
|
|
6640
6640
|
init_ObjectActionMenuItems();
|
|
6641
6641
|
init_Refusal();
|
|
6642
6642
|
import_jsx_runtime46 = require("react/jsx-runtime");
|
|
6643
|
-
ARCHIVE_NEEDS_ADMIN = "Needs
|
|
6643
|
+
ARCHIVE_NEEDS_ADMIN = "Needs Full access on this table";
|
|
6644
6644
|
}
|
|
6645
6645
|
});
|
|
6646
6646
|
|
|
@@ -6904,7 +6904,7 @@ var init_BookingSlots = __esm({
|
|
|
6904
6904
|
import_jsx_runtime47 = require("react/jsx-runtime");
|
|
6905
6905
|
BOOKING_NOT_HERE_LINE = "The link named a booking page this table does not have \u2014 it may have been closed for good, or it writes into another table. The booking pages this table does have are listed here.";
|
|
6906
6906
|
WHAT_A_BOOKING_PAGE_IS = "A booking page offers times you are free and writes each appointment into this table as an ordinary record.";
|
|
6907
|
-
NO_ADMIN = "Opening a booking page lets people with no account take time in your calendar, so it needs
|
|
6907
|
+
NO_ADMIN = "Opening a booking page lets people with no account take time in your calendar, so it needs Full access on the table the appointments land in.";
|
|
6908
6908
|
STATE_WORDS = BOOKING_PAGE_STATE_LABEL;
|
|
6909
6909
|
}
|
|
6910
6910
|
});
|
|
@@ -29546,7 +29546,7 @@ function EnrichPanel({ tableId, fieldId, className }) {
|
|
|
29546
29546
|
target?.name ?? "this column",
|
|
29547
29547
|
" in automatically."
|
|
29548
29548
|
] }),
|
|
29549
|
-
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)("p", { className: "text-muted-foreground", children: "
|
|
29549
|
+
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)("p", { className: "text-muted-foreground", children: "Someone with Full access on this table sets that up." })
|
|
29550
29550
|
] });
|
|
29551
29551
|
}
|
|
29552
29552
|
return /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)("div", { className: (0, import_design_system81.cn)("space-y-3 p-4 text-sm", className), children: [
|
|
@@ -29627,7 +29627,7 @@ function EnrichPanel({ tableId, fieldId, className }) {
|
|
|
29627
29627
|
if (shown5.length === 0) {
|
|
29628
29628
|
return /* @__PURE__ */ (0, import_jsx_runtime93.jsxs)("div", { className: (0, import_design_system81.cn)("space-y-2 p-4 text-sm", className), children: [
|
|
29629
29629
|
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)("p", { className: "font-medium", children: "No column here is filled in by a model." }),
|
|
29630
|
-
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)("p", { className: "text-muted-foreground", children: rights.admin ? "Open a column's menu and choose \u201CLet AI fill\u201D to set one up \u2014 or just ask for it in plain words and the agent will." : "
|
|
29630
|
+
/* @__PURE__ */ (0, import_jsx_runtime93.jsx)("p", { className: "text-muted-foreground", children: rights.admin ? "Open a column's menu and choose \u201CLet AI fill\u201D to set one up \u2014 or just ask for it in plain words and the agent will." : "Someone with Full access on this table sets that up." })
|
|
29631
29631
|
] });
|
|
29632
29632
|
}
|
|
29633
29633
|
return /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("div", { className: (0, import_design_system81.cn)("space-y-6 p-4", className), children: shown5.map((row) => {
|
|
@@ -38270,7 +38270,7 @@ function CommentThread({ tableId, recordId, fieldKey, className }) {
|
|
|
38270
38270
|
}
|
|
38271
38271
|
) : (
|
|
38272
38272
|
// No dead composer. The store's own rung, in a person's words.
|
|
38273
|
-
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)("p", { className: "text-xs text-muted-foreground", children: "You can read this conversation and not join it. Commenting needs
|
|
38273
|
+
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)("p", { className: "text-xs text-muted-foreground", children: "You can read this conversation and not join it. Commenting needs Comment access on this record \u2014 ask whoever shared it with you to raise it." })
|
|
38274
38274
|
)
|
|
38275
38275
|
] });
|
|
38276
38276
|
}
|
|
@@ -58593,7 +58593,7 @@ init_host();
|
|
|
58593
58593
|
var import_jsx_runtime184 = require("react/jsx-runtime");
|
|
58594
58594
|
var FORM_NOT_HERE_LINE = "The link named a form this table does not have \u2014 it may have been removed, or it belongs to another table. The forms this table does have are listed here.";
|
|
58595
58595
|
var WHAT_A_FORM_IS = "A form uses this table's own fields, and its answers land here as ordinary records stamped with the form they came through.";
|
|
58596
|
-
var NO_ADMIN2 = "This table has no forms. Making one needs
|
|
58596
|
+
var NO_ADMIN2 = "This table has no forms. Making one needs Full access on it, because a form decides what people with no account may add here.";
|
|
58597
58597
|
function formSuggestion(tableName2) {
|
|
58598
58598
|
const subject = tableName2?.trim() ? tableName2.trim() : "this table";
|
|
58599
58599
|
return `Make me a form that collects new ${subject} entries and tells me when somebody answers.`;
|
|
@@ -59686,7 +59686,7 @@ function EmbedFrame({
|
|
|
59686
59686
|
if (!rights.admin) {
|
|
59687
59687
|
return /* @__PURE__ */ (0, import_jsx_runtime189.jsxs)("p", { className: (0, import_design_system167.cn)("rounded border border-dashed px-2 py-1 text-xs text-muted-foreground", className), children: [
|
|
59688
59688
|
rights.why("structure"),
|
|
59689
|
-
" Issuing an embed opens a way in from somebody else's website, so it needs
|
|
59689
|
+
" Issuing an embed opens a way in from somebody else's website, so it needs Full access on this table."
|
|
59690
59690
|
] });
|
|
59691
59691
|
}
|
|
59692
59692
|
const snippet = secret ? `<iframe src="${embedUrl}#t=${secret}" style="width:100%;height:640px;border:0" loading="lazy"></iframe>` : null;
|
|
@@ -61105,7 +61105,7 @@ function railFromParam(raw) {
|
|
|
61105
61105
|
function unknownRailLine(raw) {
|
|
61106
61106
|
return `The link asked to open \u201C${raw}\u201D on this table, which is not something a table has, so you are looking at its records. A table opens Forms, Bookings, Checklists, Notifications, Portals, Settings, Import, Inbox and Share \u2014 each is in the table's menu.`;
|
|
61107
61107
|
}
|
|
61108
|
-
var SHARE_NOT_YOURS_LINE = "The link asked to open this table's sharing, and only someone with
|
|
61108
|
+
var SHARE_NOT_YOURS_LINE = "The link asked to open this table's sharing, and only someone with Full access on this table can share it, so it did not open. Ask someone with Full access on this table to share it or to give you Full access.";
|
|
61109
61109
|
function openingView(activeView, activeDashboardId) {
|
|
61110
61110
|
const named = (0, import_views2.pageViewFromParam)(activeView);
|
|
61111
61111
|
if (named === null) {
|
|
@@ -61670,7 +61670,7 @@ function TablePage({
|
|
|
61670
61670
|
label: "Questions",
|
|
61671
61671
|
icon: "layout-dashboard",
|
|
61672
61672
|
group: "built-on",
|
|
61673
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61673
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : {},
|
|
61674
61674
|
run: () => go({ main: "questions" })
|
|
61675
61675
|
},
|
|
61676
61676
|
...canGetReference ? [
|
|
@@ -61679,7 +61679,7 @@ function TablePage({
|
|
|
61679
61679
|
label: "Get reference\u2026",
|
|
61680
61680
|
icon: "link-2",
|
|
61681
61681
|
group: "share",
|
|
61682
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61682
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : {},
|
|
61683
61683
|
run: () => void window.setTimeout(() => setReferenceOpen(true), 0)
|
|
61684
61684
|
}
|
|
61685
61685
|
] : [],
|
|
@@ -61690,7 +61690,7 @@ function TablePage({
|
|
|
61690
61690
|
label: subItemsOn ? "Turn off sub-items" : "Turn on sub-items",
|
|
61691
61691
|
icon: "list-checks",
|
|
61692
61692
|
group: "manage",
|
|
61693
|
-
...mayDo.known && !mayDo.structure ? { disabledReason: "Needs
|
|
61693
|
+
...mayDo.known && !mayDo.structure ? { disabledReason: "Needs Full access" } : {},
|
|
61694
61694
|
run: () => void toggleSubItems()
|
|
61695
61695
|
},
|
|
61696
61696
|
// CLEAN THE WHOLE TABLE (the Sheet's toolbar cleanup): the grid's one review, from the ⋯ too.
|
|
@@ -61700,13 +61700,13 @@ function TablePage({
|
|
|
61700
61700
|
label: CLEAN_TABLE_LABEL,
|
|
61701
61701
|
icon: "eraser",
|
|
61702
61702
|
group: "manage",
|
|
61703
|
-
...mayDo.known && !mayDo.write ? { disabledReason: "Needs
|
|
61703
|
+
...mayDo.known && !mayDo.write ? { disabledReason: "Needs Edit access" } : {},
|
|
61704
61704
|
run: () => void window.setTimeout(() => askToCleanTable(tableId), 0)
|
|
61705
61705
|
}
|
|
61706
61706
|
] : [],
|
|
61707
61707
|
// BREAK DOWN: the grid grouped by one column, through the drill's own question.
|
|
61708
61708
|
breakDownAction({
|
|
61709
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61709
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : !view ? { disabledReason: NO_VIEW_REASON } : allFields.data && allFields.data.length === 0 ? { disabledReason: NO_DIMENSION_REASON } : {},
|
|
61710
61710
|
run: () => void window.setTimeout(() => setBreakDownOpen(true), 0)
|
|
61711
61711
|
}),
|
|
61712
61712
|
// THE VIEW'S TWO ONE-PRESS WAYS OUT (TABLE-EXPERIENCE item 4).
|
|
@@ -61721,10 +61721,10 @@ function TablePage({
|
|
|
61721
61721
|
recordsUi.notify?.error("Couldn\u2019t copy the link");
|
|
61722
61722
|
}
|
|
61723
61723
|
},
|
|
61724
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61724
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : {}
|
|
61725
61725
|
}),
|
|
61726
61726
|
downloadCsvAction({
|
|
61727
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61727
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : !allFields.data ? { disabledReason: "Reading this table\u2026" } : {},
|
|
61728
61728
|
run: () => downloadViewCsv({
|
|
61729
61729
|
client,
|
|
61730
61730
|
host: recordsUi,
|
|
@@ -61736,7 +61736,7 @@ function TablePage({
|
|
|
61736
61736
|
})
|
|
61737
61737
|
}),
|
|
61738
61738
|
downloadMarkdownAction({
|
|
61739
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61739
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : !allFields.data ? { disabledReason: "Reading this table\u2026" } : {},
|
|
61740
61740
|
run: () => downloadViewMarkdown({
|
|
61741
61741
|
client,
|
|
61742
61742
|
host: recordsUi,
|
|
@@ -61748,7 +61748,7 @@ function TablePage({
|
|
|
61748
61748
|
})
|
|
61749
61749
|
}),
|
|
61750
61750
|
copyMarkdownAction({
|
|
61751
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61751
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : !allFields.data ? { disabledReason: "Reading this table\u2026" } : {},
|
|
61752
61752
|
run: () => copyViewMarkdown({
|
|
61753
61753
|
client,
|
|
61754
61754
|
host: recordsUi,
|
|
@@ -61762,7 +61762,7 @@ function TablePage({
|
|
|
61762
61762
|
// PRINT, FULL PRINT, HTML PREVIEW, COPY THE HTML PAGE, SAVE AS FILE (TABLE-PARITY item 3): the platform print system's.
|
|
61763
61763
|
...["print", "full-print", "html-preview", "copy-html-page", "save-as-file"].map(
|
|
61764
61764
|
(kind2) => tablePageAction(kind2, {
|
|
61765
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61765
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : !allFields.data ? { disabledReason: "Reading this table\u2026" } : {},
|
|
61766
61766
|
run: () => runTablePageAction(kind2, {
|
|
61767
61767
|
client,
|
|
61768
61768
|
host: recordsUi,
|
|
@@ -61777,7 +61777,7 @@ function TablePage({
|
|
|
61777
61777
|
// THE PRIVATE CALENDAR LINK (CAL-FEED-UI): only where the host bound the doors.
|
|
61778
61778
|
...recordsUi.calendarFeed && organizationId ? [
|
|
61779
61779
|
subscribeCalendarAction({
|
|
61780
|
-
...mayDo.known && !mayDo.read ? { disabledReason: "Needs
|
|
61780
|
+
...mayDo.known && !mayDo.read ? { disabledReason: "Needs View access" } : !view ? { disabledReason: NO_VIEW_REASON } : !subscribeDateKey ? { disabledReason: shown5?.layout === "calendar" ? "This table has no date column" : "Switch this view to Calendar to subscribe" } : {},
|
|
61781
61781
|
run: () => void window.setTimeout(() => void subscribeInCalendar(), 0)
|
|
61782
61782
|
})
|
|
61783
61783
|
] : [],
|