Add plugin WebUI extension page and API routing support

Introduces a plugin router registry for registering plugin-specific API routes, static resources, and extension pages. Updates the plugin manager and context to expose the router, and implements backend and frontend support for serving and displaying plugin extension pages in the WebUI. Also adds a demo extension page and static resource to the builtin plugin.
This commit is contained in:
手瓜一十雪
2026-01-30 12:48:24 +08:00
parent bb69ae6c62
commit 012c283dee
18 changed files with 1245 additions and 23 deletions

View File

@@ -20,12 +20,31 @@ export interface PluginItem {
status: PluginStatus;
/** 是否有配置项 */
hasConfig?: boolean;
/** 是否有扩展页面 */
hasPages?: boolean;
}
/** 扩展页面信息 */
export interface ExtensionPageItem {
/** 插件 ID */
pluginId: string;
/** 插件名称 */
pluginName: string;
/** 页面路径 */
path: string;
/** 页面标题 */
title: string;
/** 页面图标 */
icon?: string;
/** 页面描述 */
description?: string;
}
/** 插件列表响应 */
export interface PluginListResponse {
plugins: PluginItem[];
pluginManagerNotFound: boolean;
extensionPages: ExtensionPageItem[];
}
/** 插件配置项定义 */