diff options
author | bobzel <zzzman@gmail.com> | 2023-08-21 12:40:39 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2023-08-21 12:40:39 -0400 |
commit | 565d4c98628f547ba27e2d9c74138602c8cbd7a5 (patch) | |
tree | 77cdb2e427b98a5e909f830cb759092a23599a30 /src/client/views/nodes/MapBox/MapPushpinBox.tsx | |
parent | c2d4aafbe58d5b3ae091c4ce3be379b693e04075 (diff) |
fixed calling setComponentView for maps
Diffstat (limited to 'src/client/views/nodes/MapBox/MapPushpinBox.tsx')
-rw-r--r-- | src/client/views/nodes/MapBox/MapPushpinBox.tsx | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/client/views/nodes/MapBox/MapPushpinBox.tsx b/src/client/views/nodes/MapBox/MapPushpinBox.tsx index 6369f9e04..d28209ea1 100644 --- a/src/client/views/nodes/MapBox/MapPushpinBox.tsx +++ b/src/client/views/nodes/MapBox/MapPushpinBox.tsx @@ -5,28 +5,23 @@ import { FieldView, FieldViewProps } from '../FieldView'; import React = require('react'); import { computed } from 'mobx'; import { MapBox } from './MapBox'; -import { undoable } from '../../../util/UndoManager'; - /** * Map Pushpin doc class */ @observer export class MapPushpinBox extends ViewBoxBaseComponent<FieldViewProps>() { - - public static LayoutString(fieldKey: string) { return FieldView.LayoutString(MapPushpinBox, fieldKey); } componentDidMount() { // if (this.mapBoxView) - this.mapBoxView.addPushpin(this.rootDoc); + this.mapBoxView.addPushpin(this.rootDoc); } componentWillUnmount() { // this.mapBoxView.removePushpin(this.rootDoc); } - @computed get mapBoxView() { return this.props.DocumentView?.()?.props.docViewPath().lastElement()?.ComponentView as MapBox; } @@ -35,6 +30,6 @@ export class MapPushpinBox extends ViewBoxBaseComponent<FieldViewProps>() { } render() { - return (<div></div>); + return <div></div>; } } |