zahmis 5 лет назад
Родитель
Сommit
eddf92da17

+ 3 - 1
src/client/js/components/Page/DisplaySwitcher.jsx

@@ -17,12 +17,14 @@ const DisplaySwitcher = (props) => {
   return (
     <>
       {editorMode === 'view' && <Page />}
-      {editorMode === 'edit' && (
+      <div id="edit">
+        {editorMode === 'edit' && (
         <>
           <Editor />
           <EditorNavbarBottom />
         </>
       )}
+      </div>
       {editorMode === 'hackmd' && <PageEditorByHackmd />}
     </>
   );

+ 5 - 0
src/client/js/services/NavigationContainer.js

@@ -35,6 +35,11 @@ export default class NavigationContainer extends Container {
       isPageCreateModalShown: false,
     };
 
+    const editPage = document.querySelector('#edit');
+    if (editPage) {
+      return 'hoge';
+    }
+
     this.openPageCreateModal = this.openPageCreateModal.bind(this);
     this.closePageCreateModal = this.closePageCreateModal.bind(this);
     this.initDeviceSize();