@@ -159,8 +181,8 @@ export default {
data() {
return {
programLanguages: Object.keys(this.$programmings),
- sideBarWidth: "290px",
- languageBarHeight: "40px",
+ sideBarWidth: 250,
+ languageBarHeight: 40,
canCommandSave: this.action.type === "code" ? false : true,
quickcommandInfo: {
features: {
@@ -202,8 +224,11 @@ export default {
},
computed: {
allQuickCommandTags() {
- return this.parent.allQuickCommandTags.filter(
- (x) => x !== "默认" && x !== "未分类" && x !== "搜索结果"
+ return _.without(
+ this.parent.allQuickCommandTags,
+ "默认",
+ "未分类",
+ "搜索结果"
);
},
},
@@ -293,6 +318,16 @@ export default {
] = res;
});
},
+ // 展开收起侧栏
+ toggleSideBarWidth() {
+ if (this.sideBarWidth) {
+ this.lastSideBarWidth = this.sideBarWidth;
+ this.sideBarWidth = 0;
+ } else {
+ this.sideBarWidth = this.lastSideBarWidth;
+ this.lastSideBarWidth = 0;
+ }
+ },
// 自定义解释器路径界面
showCustomOptions() {
quickcommand
diff --git a/src/components/CommandMenu.vue b/src/components/CommandMenu.vue
index 83473cb..5ad936a 100644
--- a/src/components/CommandMenu.vue
+++ b/src/components/CommandMenu.vue
@@ -256,12 +256,7 @@ export default {
outputTypes: outputTypes,
outputTypesOptions: Object.keys(outputTypes),
specialVar: "{{}}",
- allQuickCommandTags: _.without(
- this.$parent.parent.allQuickCommandTags,
- "默认",
- "未分类",
- "搜索结果"
- ),
+ allQuickCommandTags: this.$parent.allQuickCommandTags,
};
},
props: {