aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx
diff options
context:
space:
mode:
authorNathan-SR <144961007+Nathan-SR@users.noreply.github.com>2024-06-10 04:01:01 -0400
committerNathan-SR <144961007+Nathan-SR@users.noreply.github.com>2024-06-10 04:01:01 -0400
commit99b0ce24e4d56100746016995c20f9bb9c109072 (patch)
tree733ee6074eb67ebaf4a5a17fed471ec092dfbf40 /src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx
parent97977e7156eb852c20422fa995bbf96529dfb4e5 (diff)
adding/removing children from collection works (probably buggy); backspace delete broken
Diffstat (limited to 'src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx')
-rw-r--r--src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx23
1 files changed, 20 insertions, 3 deletions
diff --git a/src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx b/src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx
index dd4a13776..dbbf76ea7 100644
--- a/src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx
+++ b/src/client/views/collections/collectionSchema/SchemaColumnHeader.tsx
@@ -22,6 +22,7 @@ import { SnappingManager } from '../../../util/SnappingManager';
import { undoable } from '../../../util/UndoManager';
import { FInfo } from '../../../documents/Documents';
import { ColumnType } from '../../../../fields/SchemaHeaderField';
+import { IconButton, Size } from 'browndash-components';
export interface SchemaColumnHeaderProps {
Document: Doc;
@@ -174,10 +175,26 @@ export class SchemaColumnHeader extends ObservableReactComponent<SchemaColumnHea
<div>{this.editableView}</div>
<div className="schema-header-menu">
- <div className="schema-header-button" onPointerDown={e => this._props.openContextMenu(e.clientX, e.clientY, this._props.columnIndex)}>
- <FontAwesomeIcon icon="ellipsis-h" />
+ <div className="schema-header-button">
+ <IconButton
+ icon={ <FontAwesomeIcon icon="caret-down" size='lg'/>}
+ size={Size.XSMALL}
+ color={'black'}
+ onPointerDown={e =>
+ setupMoveUpEvents(
+ this,
+ e,
+ returnFalse,
+ emptyFunction,
+ undoable(clickEv => {
+ clickEv.stopPropagation();
+ this._props.openContextMenu(e.clientX, e.clientY, this._props.columnIndex)
+ }, 'open column menu')
+ )
+ }
+ />
</div>
- </div>
+ </div>
</div>
);
}