aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/collectionSchema/SchemaRowBox.tsx
diff options
context:
space:
mode:
authorNathan-SR <144961007+Nathan-SR@users.noreply.github.com>2024-03-21 00:43:08 -0400
committerNathan-SR <144961007+Nathan-SR@users.noreply.github.com>2024-03-21 00:43:08 -0400
commit9ccbc0a6d6f6fffbc479d37ac2a880eafe85c65d (patch)
tree9eb60db4c05a7a79bf12a4bb31920b15f7689eac /src/client/views/collections/collectionSchema/SchemaRowBox.tsx
parenta598877cc71c1f2a25e8cac4b831ab947a2539e0 (diff)
multiple cell column switching working
Diffstat (limited to 'src/client/views/collections/collectionSchema/SchemaRowBox.tsx')
-rw-r--r--src/client/views/collections/collectionSchema/SchemaRowBox.tsx6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/client/views/collections/collectionSchema/SchemaRowBox.tsx b/src/client/views/collections/collectionSchema/SchemaRowBox.tsx
index af502dd03..e3654facb 100644
--- a/src/client/views/collections/collectionSchema/SchemaRowBox.tsx
+++ b/src/client/views/collections/collectionSchema/SchemaRowBox.tsx
@@ -98,10 +98,11 @@ export class SchemaRowBox extends ViewBoxBaseComponent<SchemaRowBoxProps>() {
document.removeEventListener('pointermove', this.onPointerMove);
};
+ selectedCol = () => this.schemaView._selectedCol;
getFinfo = computedFn((fieldKey: string) => this.schemaView?.fieldInfos.get(fieldKey));
selectCell = (doc: Doc, col: number, shift: boolean) => this.schemaView?.selectCell(doc, col, shift);
deselectCell = () => this.schemaView?.deselectAllCells();
- selectedCell = () => this.schemaView?._selectedCells;
+ selectedCells = () => this.schemaView?._selectedCells;
setColumnValues = (field: any, value: any) => this.schemaView?.setColumnValues(field, value) ?? false;
setSelectedColumnValues = (field: any, value: any) => this.schemaView?.setSelectedColumnValues(field, value) ?? false;
columnWidth = computedFn((index: number) => () => this.schemaView?.displayColumnWidths[index] ?? CollectionSchemaView._minColWidth);
@@ -187,7 +188,8 @@ export class SchemaRowBox extends ViewBoxBaseComponent<SchemaRowBoxProps>() {
getFinfo={this.getFinfo}
selectCell={this.selectCell}
deselectCell={this.deselectCell}
- selectedCells={this.selectedCell}
+ selectedCells={this.selectedCells}
+ selectedCol={this.selectedCol}
setColumnValues={this.setColumnValues}
setSelectedColumnValues={this.setSelectedColumnValues}
oneLine={BoolCast(this.schemaDoc?._singleLine)}