aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/MapBox/MapBox.tsx
diff options
context:
space:
mode:
authorEric <ericmabr@gmail.com>2023-03-15 17:29:33 -0400
committerEric <ericmabr@gmail.com>2023-03-15 17:29:33 -0400
commit06980bb5fa9f72ad20896be132bcc29e9ae4617e (patch)
treee98357191b26b14bd17b3f8d4656b6789022e1cd /src/client/views/nodes/MapBox/MapBox.tsx
parentc50fc16a161379b20eed04794d1433499b1483c7 (diff)
parent20c0190e820f2bd343693368b7ef55a91f19c880 (diff)
Merge branch 'master' into UI_Update_Eric_Ma
Diffstat (limited to 'src/client/views/nodes/MapBox/MapBox.tsx')
-rw-r--r--src/client/views/nodes/MapBox/MapBox.tsx8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/client/views/nodes/MapBox/MapBox.tsx b/src/client/views/nodes/MapBox/MapBox.tsx
index f4f9e949f..d35a5ef2e 100644
--- a/src/client/views/nodes/MapBox/MapBox.tsx
+++ b/src/client/views/nodes/MapBox/MapBox.tsx
@@ -22,7 +22,7 @@ import { AnchorMenu } from '../../pdf/AnchorMenu';
import { Annotation } from '../../pdf/Annotation';
import { SidebarAnnos } from '../../SidebarAnnos';
import { FieldView, FieldViewProps } from '../FieldView';
-import { PinProps } from '../trails/PresBox';
+import { PinProps } from '../trails';
import './MapBox.scss';
import { MapBoxInfoWindow } from './MapBoxInfoWindow';
@@ -135,8 +135,8 @@ export class MapBox extends ViewBoxAnnotatableComponent<ViewBoxAnnotatableProps
private _sidebarRef = React.createRef<SidebarAnnos>();
private _ref: React.RefObject<HTMLDivElement> = React.createRef();
- constructor(props: any) {
- super(props);
+ componentDidMount() {
+ this.props.setContentView?.(this);
}
@action
@@ -333,7 +333,6 @@ export class MapBox extends ViewBoxAnnotatableComponent<ViewBoxAnnotatableProps
docs.forEach(doc => {
if (doc.lat !== undefined && doc.lng !== undefined) {
const existingMarker = this.allMapMarkers.find(marker => marker.lat === doc.lat && marker.lng === doc.lng);
- doc.onClickBehavior = 'enterPortal';
if (existingMarker) {
Doc.AddDocToList(existingMarker, 'data', doc);
} else {
@@ -529,6 +528,7 @@ export class MapBox extends ViewBoxAnnotatableComponent<ViewBoxAnnotatableProps
}
getAnchor = (addAsAnnotation: boolean, pinProps?: PinProps) => AnchorMenu.Instance?.GetAnchor(this._savedAnnotations, addAsAnnotation) ?? this.rootDoc;
+
/**
* render contents in allMapMarkers (e.g. images with exifData) into google maps as map marker
* @returns