📝 update readme

This commit is contained in:
muwoo
2023-10-12 15:43:56 +08:00
parent c5ddeef8bc
commit 96bc02905a
5 changed files with 29 additions and 33 deletions

View File

@@ -102,15 +102,15 @@ const createPluginManager = (): any => {
};
const changePluginHistory = (plugin) => {
if (state.pluginHistory.length >= 8) {
state.pluginHistory.pop();
}
state.pluginHistory.forEach((p, index) => {
if (p.name === plugin.name) {
state.pluginHistory.splice(index, 1);
}
});
state.pluginHistory.unshift(plugin);
if (state.pluginHistory.length > 8) {
state.pluginHistory.pop();
}
};
const { searchValue, onSearch, setSearchValue, placeholder } =