去掉 temporaryStore

This commit is contained in:
fofolee
2022-04-19 21:46:05 +08:00
parent 6cfd054767
commit 015513ec45
4 changed files with 14 additions and 27 deletions

View File

@@ -78,13 +78,16 @@ export default {
};
},
mounted() {
window.temporaryStore.updateSelectList = (opt, id) => {
quickcommand.updateSelectList = (opt, id) => {
if (typeof id === "undefined") this.items.push(opt);
else this.items[id] = opt;
};
this.options.enableSearch && this.setSubInput();
this.setUtoolsHeight(this.itemHeight * this.matchedItemsSize);
},
unmounted() {
this.clear();
},
computed: {
matchedItems() {
let matchedItems = this.searchWords
@@ -188,7 +191,7 @@ export default {
clear() {
utools.removeSubInput();
this.setUtoolsHeight(this.listMaxHeight);
window.temporaryStoreSoldOut();
quickcommand.updateSelectList = () => {};
},
},
};