@columnus/shared 0.1.49 → 0.1.51
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/clipboardTransfer.js.map +1 -1
- package/dist/csv.js +26 -1
- package/dist/csv.js.map +1 -1
- package/dist/dateValues.d.ts +3 -0
- package/dist/dateValues.js +23 -1
- package/dist/dateValues.js.map +1 -1
- package/dist/displayLabel.js +26 -1
- package/dist/displayLabel.js.map +1 -1
- package/dist/importMatch.js +26 -1
- package/dist/importMatch.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +221 -43
- package/dist/index.js.map +1 -1
- package/dist/recordTableColumns.d.ts +3 -1
- package/dist/recordTableColumns.js +202 -2
- package/dist/recordTableColumns.js.map +1 -1
- package/dist/recordTablePreload.d.ts +19 -0
- package/dist/recordTablePreload.js +4330 -0
- package/dist/recordTablePreload.js.map +1 -0
- package/dist/refDisplayRequests.js.map +1 -1
- package/dist/richDoc.d.ts +10 -0
- package/dist/richDoc.js +65 -2
- package/dist/richDoc.js.map +1 -1
- package/dist/schemaTypes.js.map +1 -1
- package/dist/shareProposal.js.map +1 -1
- package/dist/spaceBundle.js.map +1 -1
- package/dist/storageFieldValues.js.map +1 -1
- package/package.json +1 -1
package/dist/importMatch.js
CHANGED
|
@@ -4761,10 +4761,33 @@ function visitInlineContent(content, visit) {
|
|
|
4761
4761
|
function walkInlineContent(content, parts) {
|
|
4762
4762
|
visitInlineContent(content, {
|
|
4763
4763
|
text: (t) => parts.push(t),
|
|
4764
|
-
recordLink: (props) => parts.push(props.table ? `[${props.table}]` : "[
|
|
4764
|
+
recordLink: (props) => parts.push(props.table ? `[${props.table}]` : "[Record]"),
|
|
4765
4765
|
link: (nested) => walkInlineContent(nested, parts)
|
|
4766
4766
|
});
|
|
4767
4767
|
}
|
|
4768
|
+
function walkTableCell(cell, parts) {
|
|
4769
|
+
if (Array.isArray(cell)) {
|
|
4770
|
+
walkInlineContent(cell, parts);
|
|
4771
|
+
return;
|
|
4772
|
+
}
|
|
4773
|
+
if (cell && typeof cell === "object") {
|
|
4774
|
+
const node = cell;
|
|
4775
|
+
if (node.type === "tableCell" && Array.isArray(node.content)) {
|
|
4776
|
+
walkInlineContent(node.content, parts);
|
|
4777
|
+
}
|
|
4778
|
+
}
|
|
4779
|
+
}
|
|
4780
|
+
function walkTableContent(content, parts) {
|
|
4781
|
+
if (!content || typeof content !== "object" || Array.isArray(content)) return;
|
|
4782
|
+
const rows = content.rows ?? [];
|
|
4783
|
+
for (const row of rows) {
|
|
4784
|
+
for (const cell of row.cells ?? []) {
|
|
4785
|
+
const before = parts.length;
|
|
4786
|
+
walkTableCell(cell, parts);
|
|
4787
|
+
if (parts.length > before) parts.push(" ");
|
|
4788
|
+
}
|
|
4789
|
+
}
|
|
4790
|
+
}
|
|
4768
4791
|
function walkBlocks(blocks, parts) {
|
|
4769
4792
|
for (const block of blocks) {
|
|
4770
4793
|
if (block.type === "recordTable") {
|
|
@@ -4778,6 +4801,8 @@ function walkBlocks(blocks, parts) {
|
|
|
4778
4801
|
parts.push("[data table]");
|
|
4779
4802
|
}
|
|
4780
4803
|
parts.push(" ");
|
|
4804
|
+
} else if (block.type === "table") {
|
|
4805
|
+
walkTableContent(block.content, parts);
|
|
4781
4806
|
} else if (Array.isArray(block.content)) {
|
|
4782
4807
|
walkInlineContent(block.content, parts);
|
|
4783
4808
|
parts.push(" ");
|