From 1a3aa8a4e79deb501fce0c89ace8ea960003d8cd Mon Sep 17 00:00:00 2001 From: bobzel Date: Fri, 29 Dec 2023 10:50:42 -0500 Subject: fixed sidebar button highoighting. fixed explore mode. --- src/client/views/nodes/DocumentView.tsx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/client/views/nodes') diff --git a/src/client/views/nodes/DocumentView.tsx b/src/client/views/nodes/DocumentView.tsx index 336f65b85..cc7fca8d2 100644 --- a/src/client/views/nodes/DocumentView.tsx +++ b/src/client/views/nodes/DocumentView.tsx @@ -712,7 +712,7 @@ export class DocumentViewInternal extends DocComponent { @@ -1337,10 +1337,8 @@ export class DocumentView extends ObservableReactComponent { runInAction(() => (this._selected = val)); } @observable public static LongPress = false; - @observable public static ExploreMode = false; - @observable public static LastPressedSidebarBtn: Opt = undefined; // bcz: this is a hack to handle highlighting buttons in the leftpanel menu .. need to find a cleaner approach @computed public static get exploreMode() { - return () => (DocumentView.ExploreMode ? ScriptField.MakeScript('CollectionBrowseClick(documentView, clientX, clientY)', { documentView: 'any', clientX: 'number', clientY: 'number' })! : undefined); + return () => (SnappingManager.ExploreMode ? ScriptField.MakeScript('CollectionBrowseClick(documentView, clientX, clientY)', { documentView: 'any', clientX: 'number', clientY: 'number' })! : undefined); } @observable public docView: DocumentViewInternal | undefined | null = undefined; @observable public textHtmlOverlay: Opt = undefined; -- cgit v1.2.3-70-g09d2