Gerald 8 лет назад
Родитель
Сommit
846e06e292
6 измененных файлов с 11 добавлено и 8 удалено
  1. 7 0
      src/common/ui/code.vue
  2. 0 1
      src/common/ui/style/style.css
  3. 1 1
      src/confirm/app.js
  4. 1 1
      src/options/app.js
  5. 1 4
      src/options/views/edit/index.vue
  6. 1 1
      src/popup/app.js

+ 7 - 0
src/common/ui/code.vue

@@ -286,3 +286,10 @@ export default {
   },
   },
 };
 };
 </script>
 </script>
+
+<style>
+/* compatible with old browsers, e.g. Maxthon 4.4 */
+.editor-code.flex-auto {
+  height: 100%;
+}
+</style>

+ 0 - 1
src/common/ui/style/style.css

@@ -163,7 +163,6 @@ button {
   }
   }
 }
 }
 
 
-.editor-code,
 .editor-code .CodeMirror {
 .editor-code .CodeMirror {
   height: 100%;
   height: 100%;
   /* Use `Courier New` to ensure `&nbsp;` has the same width as an original space. */
   /* Use `Courier New` to ensure `&nbsp;` has the same width as an original space. */

+ 1 - 1
src/confirm/app.js

@@ -1,6 +1,6 @@
-import Vue from 'vue';
 import 'src/common/polyfills';
 import 'src/common/polyfills';
 import 'src/common/browser';
 import 'src/common/browser';
+import Vue from 'vue';
 import { i18n } from 'src/common';
 import { i18n } from 'src/common';
 import 'src/common/handlers';
 import 'src/common/handlers';
 import options from 'src/common/options';
 import options from 'src/common/options';

+ 1 - 1
src/options/app.js

@@ -1,7 +1,7 @@
-import Vue from 'vue';
 import 'src/common/polyfills';
 import 'src/common/polyfills';
 import 'src/common/browser';
 import 'src/common/browser';
 import 'src/common/sprite';
 import 'src/common/sprite';
+import Vue from 'vue';
 import { sendMessage, i18n, getLocaleString } from 'src/common';
 import { sendMessage, i18n, getLocaleString } from 'src/common';
 import options from 'src/common/options';
 import options from 'src/common/options';
 import getPathInfo from 'src/common/pathinfo';
 import getPathInfo from 'src/common/pathinfo';

+ 1 - 4
src/options/views/edit/index.vue

@@ -15,7 +15,7 @@
     <div class="frame-block flex-auto pos-rel">
     <div class="frame-block flex-auto pos-rel">
       <vm-code
       <vm-code
         v-show="nav === 'code'" class="abs-full"
         v-show="nav === 'code'" class="abs-full"
-        v-model="code" :commands="commands" @ready="initEditor"
+        v-model="code" :commands="commands"
       />
       />
       <vm-settings
       <vm-settings
         v-show="nav === 'settings'" class="abs-full"
         v-show="nav === 'settings'" class="abs-full"
@@ -192,9 +192,6 @@ export default {
     saveClose() {
     saveClose() {
       this.save().then(this.close);
       this.save().then(this.close);
     },
     },
-    initEditor(cm) {
-      this.cm = cm;
-    },
   },
   },
 };
 };
 </script>
 </script>

+ 1 - 1
src/popup/app.js

@@ -1,7 +1,7 @@
-import Vue from 'vue';
 import 'src/common/polyfills';
 import 'src/common/polyfills';
 import 'src/common/browser';
 import 'src/common/browser';
 import 'src/common/sprite';
 import 'src/common/sprite';
+import Vue from 'vue';
 import { i18n, sendMessage } from 'src/common';
 import { i18n, sendMessage } from 'src/common';
 import handlers from 'src/common/handlers';
 import handlers from 'src/common/handlers';
 import 'src/common/ui/style';
 import 'src/common/ui/style';