diff options
author | bob <bcz@cs.brown.edu> | 2019-03-18 12:57:36 -0400 |
---|---|---|
committer | bob <bcz@cs.brown.edu> | 2019-03-18 12:57:36 -0400 |
commit | be117e38a63a558684baa69f719787f11dfc3be3 (patch) | |
tree | 8275d70be6aa728de3fea9af76b9422464143227 /src/client/views/collections/CollectionSchemaView.tsx | |
parent | 8acbb6e31d913982e06b8498078b90bf99c18600 (diff) | |
parent | 861614569c2d72e0ee9a6a698f3978f609a3b2bc (diff) |
Merge branch 'master' into authentication
Diffstat (limited to 'src/client/views/collections/CollectionSchemaView.tsx')
-rw-r--r-- | src/client/views/collections/CollectionSchemaView.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/collections/CollectionSchemaView.tsx b/src/client/views/collections/CollectionSchemaView.tsx index 0e8ad44c9..02e840b39 100644 --- a/src/client/views/collections/CollectionSchemaView.tsx +++ b/src/client/views/collections/CollectionSchemaView.tsx @@ -14,7 +14,7 @@ import { EditableView } from "../EditableView"; import { DocumentView } from "../nodes/DocumentView"; import { FieldView, FieldViewProps } from "../nodes/FieldView"; import "./CollectionSchemaView.scss"; -import { COLLECTION_BORDER_WIDTH } from "./CollectionView"; +import { COLLECTION_BORDER_WIDTH, CollectionView } from "./CollectionView"; import { CollectionViewBase } from "./CollectionViewBase"; import { setupDrag } from "../../util/DragManager"; @@ -47,7 +47,7 @@ export class CollectionSchemaView extends CollectionViewBase { <FieldView {...props} /> ) let reference = React.createRef<HTMLDivElement>(); - let onItemDown = setupDrag(reference, () => props.doc); + let onItemDown = setupDrag(reference, () => props.doc, (containingCollection: CollectionView) => this.props.removeDocument(props.doc)); return ( <div className="collectionSchemaView-cellContents" onPointerDown={onItemDown} style={{ height: "36px" }} key={props.doc.Id} ref={reference}> <EditableView |