diff options
| author | bobzel <zzzman@gmail.com> | 2019-02-27 00:01:11 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-02-27 00:01:11 -0500 |
| commit | 609dc8f234f6eafdd5c7ed3f7040fff169bf266a (patch) | |
| tree | 133da1d566c0fb37e14c84494aa14edef7ed6bd8 /src/client/views/nodes/DocumentView.tsx | |
| parent | 04ee2ad6e7ca887c3cfc7277c4b382f936c0fa6d (diff) | |
| parent | 14d6495e4d4b9d38a37187a50ebeb84057abbc20 (diff) | |
Merge pull request #7 from browngraphicslab/web_box
Web box
Diffstat (limited to 'src/client/views/nodes/DocumentView.tsx')
| -rw-r--r-- | src/client/views/nodes/DocumentView.tsx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/client/views/nodes/DocumentView.tsx b/src/client/views/nodes/DocumentView.tsx index feecde921..c929f9d54 100644 --- a/src/client/views/nodes/DocumentView.tsx +++ b/src/client/views/nodes/DocumentView.tsx @@ -12,10 +12,10 @@ import { CollectionDockingView } from "../collections/CollectionDockingView"; import { CollectionFreeFormView } from "../collections/CollectionFreeFormView"; import { CollectionSchemaView } from "../collections/CollectionSchemaView"; import { CollectionView, CollectionViewType } from "../collections/CollectionView"; -import { WebView } from "./WebView"; import { ContextMenu } from "../ContextMenu"; import { FormattedTextBox } from "../nodes/FormattedTextBox"; import { ImageBox } from "../nodes/ImageBox"; +import { WebBox } from "../nodes/WebBox"; import "./DocumentView.scss"; import React = require("react"); const JsxParser = require('react-jsx-parser').default;//TODO Why does this need to be imported like this? @@ -119,6 +119,8 @@ export class DocumentView extends React.Component<DocumentViewProps> { return; } if (Math.abs(this._downX - e.clientX) > 3 || Math.abs(this._downY - e.clientY) > 3) { + document.removeEventListener("pointermove", this.onPointerMove) + document.removeEventListener("pointerup", this.onPointerUp) this._contextMenuCanOpen = false; if (this._mainCont.current != null && !this.topMost) { this._contextMenuCanOpen = false; @@ -195,7 +197,7 @@ export class DocumentView extends React.Component<DocumentViewProps> { @computed get mainContent() { var val = this.props.Document.Id; return <JsxParser - components={{ FormattedTextBox, ImageBox, CollectionFreeFormView, CollectionDockingView, CollectionSchemaView, CollectionView, WebView }} + components={{ FormattedTextBox, ImageBox, CollectionFreeFormView, CollectionDockingView, CollectionSchemaView, CollectionView, WebBox }} bindings={this._documentBindings} jsx={this.layout} showWarnings={true} |
