mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-09 23:36:02 +00:00
feat: 插件删除功能
This commit is contained in:
@@ -59,7 +59,7 @@ const props = defineProps({
|
||||
},
|
||||
});
|
||||
|
||||
const emit = defineEmits(['toggle', 'update', 'uninstall']);
|
||||
const emit = defineEmits(['toggle', 'update', 'remove']);
|
||||
|
||||
const openGithubSource = () => {
|
||||
window.open(props.plugin.source, '_blank');
|
||||
@@ -73,8 +73,8 @@ const updatePlugin = () => {
|
||||
emit('update', props.plugin);
|
||||
}
|
||||
|
||||
const uninstallPlugin = () => {
|
||||
emit('uninstall', props.plugin);
|
||||
const removePlugin = () => {
|
||||
emit('remove', props.plugin);
|
||||
}
|
||||
|
||||
const menuItems = [
|
||||
@@ -96,7 +96,7 @@ const menuItems = [
|
||||
{
|
||||
title: '删除',
|
||||
condition: (plugin) => true,
|
||||
action: uninstallPlugin
|
||||
action: removePlugin
|
||||
}
|
||||
]
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user