mirror of
https://github.com/agent0ai/agent-zero.git
synced 2026-04-30 12:40:33 +00:00
improve Plugin Hub cards and plugin info
Surface repository metadata for installed custom plugins and add quick actions from the plugin info modal to open plugin files or jump back into the Plugin Hub. Refresh Plugin Hub card/status styling and modal spacing.
This commit is contained in:
parent
a5620506d5
commit
6b8a6d959a
9 changed files with 349 additions and 88 deletions
|
|
@ -3,6 +3,7 @@ import * as api from "/js/api.js";
|
|||
import { store as pluginSettingsStore } from "/components/plugins/plugin-settings-store.js";
|
||||
import { store as pluginToggleStore } from "/components/plugins/toggle/plugin-toggle-store.js";
|
||||
import { store as pluginExecuteStore } from "/components/plugins/list/plugin-execute-store.js";
|
||||
import { store as fileBrowserStore } from "/components/modals/file-browser/file-browser-store.js";
|
||||
import { store as markdownModalStore } from "/components/modals/markdown/markdown-store.js";
|
||||
import { callJsExtensions } from "/js/extensions.js";
|
||||
import {
|
||||
|
|
@ -156,6 +157,20 @@ const model = {
|
|||
window.openModal?.("components/plugins/plugin-info.html");
|
||||
},
|
||||
|
||||
async openPluginFolder(plugin) {
|
||||
if (!plugin?.path) return;
|
||||
await fileBrowserStore.open(plugin.path);
|
||||
},
|
||||
|
||||
async openPluginHub(plugin) {
|
||||
const pluginKey = (plugin?.pluginHub?.key || "").trim();
|
||||
if (!pluginKey) return;
|
||||
const { store: pluginInstallStore } = await import(
|
||||
"/plugins/_plugin_installer/webui/pluginInstallStore.js"
|
||||
);
|
||||
await pluginInstallStore.openPluginHubDetailByKey(pluginKey);
|
||||
},
|
||||
|
||||
async deletePlugin(plugin) {
|
||||
if (!plugin?.name) return;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue