From df7257d1b39f51a7e00a495f0d4a2366f0e21f7d Mon Sep 17 00:00:00 2001
From: bobzel <zzzman@gmail.com>
Date: Sun, 14 May 2023 22:04:36 -0400
Subject: fixed webpage link following by adding a presData for the current URL
 to all embedded docs.  fixed getView() in showDocuments to not get called
 with the proper anchors. changed unrendered MARKERs to CONFIGs. changed
 anchors to Configs or Markers as appropriate.

---
 src/client/views/MainView.tsx | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

(limited to 'src/client/views/MainView.tsx')

diff --git a/src/client/views/MainView.tsx b/src/client/views/MainView.tsx
index ce29b63cd..853f9cace 100644
--- a/src/client/views/MainView.tsx
+++ b/src/client/views/MainView.tsx
@@ -81,7 +81,7 @@ export class MainView extends React.Component {
     @observable private _sidebarContent: any = Doc.MyLeftSidebarPanel;
     @observable private _leftMenuFlyoutWidth: number = 0;
     @computed get _hideUI() {
-        return this.mainDoc && this.mainDoc._viewType !== CollectionViewType.Docking;
+        return this.mainDoc && this.mainDoc._type_collection !== CollectionViewType.Docking;
     }
 
     @computed private get dashboardTabHeight() {
@@ -158,6 +158,7 @@ export class MainView extends React.Component {
                 'viewTransition',
                 'treeViewOpen',
                 'layout_showSidebar',
+                'carousel_index',
                 'itemIndex', // for changing slides in presentations
                 'layout_sidebarWidthPercent',
                 'layout_currentTimecode',
@@ -177,7 +178,7 @@ export class MainView extends React.Component {
                 'layout_scrollTop',
                 'hidden',
                 'layout_curPage',
-                'viewType',
+                'type_collection',
                 'chromeHidden',
                 'currentFrame',
                 'width',
@@ -236,7 +237,7 @@ export class MainView extends React.Component {
             if (pathname.length > 1 && pathname[0] === 'doc') {
                 DocServer.GetRefField(pathname[1]).then(
                     action(field => {
-                        if (field instanceof Doc && field._viewType !== CollectionViewType.Docking) {
+                        if (field instanceof Doc && field._type_collection !== CollectionViewType.Docking) {
                             Doc.GuestTarget = field;
                         }
                     })
@@ -693,7 +694,7 @@ export class MainView extends React.Component {
     sidebarScreenToLocal = () => new Transform(0, -this.topOfSidebarDoc, 1);
     mainContainerXf = () => this.sidebarScreenToLocal().translate(-this.leftScreenOffsetOfMainDocView, 0);
     static addDocTabFunc_impl = (doc: Doc, location: OpenWhere): boolean => {
-        const whereFields = doc._viewType === CollectionViewType.Docking ? [OpenWhere.dashboard] : location.split(':');
+        const whereFields = doc._type_collection === CollectionViewType.Docking ? [OpenWhere.dashboard] : location.split(':');
         const keyValue = whereFields[1]?.includes('KeyValue');
         const whereMods: OpenWhereMod = whereFields.length > 1 ? (whereFields[1].replace('KeyValue', '') as OpenWhereMod) : OpenWhereMod.none;
         if (doc.dockingConfig) return DashboardView.openDashboard(doc);
-- 
cgit v1.2.3-70-g09d2

