@@ -173,7 +176,7 @@
-
+
@@ -193,17 +196,23 @@ export default {
},
data() {
return {
- configurationPage: this.$root.$refs.configuration,
setCssVar: setCssVar,
selectFile: ref(null),
showAbout: false,
showPanelConf: false,
- panelConf: {
- name: "",
- description: "",
- },
};
},
+ computed: {
+ configurationPage() {
+ return this.$root.$refs.view;
+ },
+ allQuickCommandsLength() {
+ return Object.keys(this.configurationPage.allQuickCommands).length;
+ },
+ allFeaturesLength() {
+ return this.configurationPage.activatedQuickCommandFeatureCodes.length;
+ },
+ },
mounted() {
window.configurationMenu = this;
},
diff --git a/src/components/PanelSetting.vue b/src/components/PanelSetting.vue
index 737d4f1..374c09b 100644
--- a/src/components/PanelSetting.vue
+++ b/src/components/PanelSetting.vue
@@ -11,3 +11,16 @@
+
+
diff --git a/src/components/UserInfo.vue b/src/components/UserInfo.vue
index 1c8eb0a..b56d5df 100644
--- a/src/components/UserInfo.vue
+++ b/src/components/UserInfo.vue
@@ -20,14 +20,14 @@
{{
- Object.keys(configurationPage.allQuickCommands).length
+ allQuickCommandsLength
}}
Quickcommands
当前拥有的「快捷命令」数
{{
- configurationPage.activatedQuickCommandFeatureCodes.length
+ allFeaturesLength
}}
Features
当前启用的「快捷命令」数
@@ -67,8 +67,11 @@ export default {
number: 1,
process: 0.4,
},
- configurationPage: this.$root.$refs.configuration,
};
},
+ props: {
+ allFeaturesLength: Number,
+ allQuickCommandsLength: Number,
+ },
};
diff --git a/src/pages/ConfigurationPage.vue b/src/pages/ConfigurationPage.vue
index 7dbe47a..9c124e5 100644
--- a/src/pages/ConfigurationPage.vue
+++ b/src/pages/ConfigurationPage.vue
@@ -478,8 +478,8 @@ export default {
});
let stringifyCommands = JSON.stringify(commandsToExport);
if (saveAsFile) {
- window.saveFile(stringifyCommands, options);
- quickcommand.showMessageBox("导出成功!");
+ window.saveFile(stringifyCommands, options) &&
+ quickcommand.showMessageBox("导出成功!");
} else {
utools.copyText(stringifyCommands);
}