qinglong and Claude
dcef1173f2
feat(v0.2.2): 调试服务器自启动 — InitService.start_auto_scripts()
...
通用自动启动脚本机制:
- base_config.yaml 新增 auto_start_scripts 配置段
- InitService 在日志服务就绪后扫描并拉起配置的脚本
- 脚本不存在时优雅跳过,不影响框架启动
- 每个脚本独立子进程 + 独立进程组 (os.setsid)
- 框架 shutdown 时自动终止 (SIGTERM → killpg)
- 模块级单例跟踪所有进程,避免重复启动
Co-Authored-By: Claude <noreply@anthropic.com >
2026-06-13 10:58:01 +08:00
qinglong and Claude Opus 4.8
9de094ea54
fix: 移除遗留fmfuncs目录创建 + 清理init_service无用导入 + 文件管理器SVG图标 + 示例插件MD3改造
...
- init_service: 删除_load_fmfuncs方法和fmfuncs目录创建(已迁移到sdk/)
- init_service: 清理未使用的importlib.util和sys导入
- 文件管理器: 全部emoji替换为MD3 SVG矢量图标(文件夹/文件类型/右键菜单)
- 示例插件: dashboard.html改为MD3风格 CSS变量自动适配日夜主题
- 面包屑: 加底色+模糊+左右外边距
- CSS: .btn::after加pointer-events:none
- 插件开发指南: 更新2.6节MD3主题同步和完善的CSS变量/组件类参考表
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-12 19:00:19 +08:00
qinglong and Claude Opus 4.8
9b997d8bda
fix: 文件选择器改为页内iframe弹窗 + 乱码编码修复 + API路径修复
...
- pickPath()从window.open改为页内iframe模态弹窗(遮罩+关闭按钮)
- files.html添加meta charset+CSS link,独立模式自动加载files.js
- API路径统一通过_apiUrl()构建,适配主面板和iframe两种上下文
- 独立iframe模式注入body/container覆写样式(无topbar)
- 选择模式栏移至底部margin-top:auto紧凑排列
- MD3风格toggle开关(显示隐藏复选框)
- CSS版本号缓存破坏
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-11 21:51:42 +08:00
qinglong and Claude Opus 4.8
d275c78aed
docs: 插件开发指南新增 pickPath() 便捷调用说明
...
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-11 21:13:25 +08:00
qinglong and Claude Opus 4.8
dc0bb79a7e
feat: 全局文件选择器 + 项目管理路径选择按钮
...
- app.js新增window.pickPath(mode,callback)全局复用
- 项目管理「工作目录」+Git部署「目标目录」添加📁 选择按钮
- Git部署不再硬编码data/projects,改用用户选择的目标目录
- files.js picker模式读取URL cb参数实现callback_id回传
- app.js版本号更新至v=0701
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-11 21:11:50 +08:00
qinglong and Claude Opus 4.8
99c3e3e853
feat: hash路由 + 插件页面内联加载 + 侧边栏插件面板展开项
...
- Hash路由: #/dashboard #/files #/plugins/xxx 支持刷新保持/前进后退
- 登录过期保留hash,登录后自动跳回原页面
- 插件WebUI页面内联加载到page-container(不再弹新窗)
- 插件页面HTML自动处理: style提取/body剥离/script执行/padding归零
- 侧边栏新增「插件面板」可折叠项,展开列出所有已注册插件页面
- 内存卡片显示 已用/总容量(百分比右侧)
- 插件开发指南新增 2.6 WebUI页面开发章节
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-11 20:56:39 +08:00
qinglong and Claude Opus 4.8
eeca8e37e1
docs: 更新README+架构文档 反映v0.6.0文件管理器/WS推送/WebUI重构
...
- README: 新增文件管理器特性/Web面板路由/架构更新
- 框架架构文档: 新增第十章 v0.6.0 WebUI重构+文件管理器+WS推送+MD3主题
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-11 18:28:50 +08:00
qinglong and Claude Opus 4.8
fd715eac2b
feat: 文件管理器 + Windows兼容 + SVG主题适配 (v0.6.0)
...
新增:
- services/web_panel/routes/files.py — 全功能文件管理后端API (11个端点)
- pages/files.html + files.js — 文件管理前端 (浏览/编辑/上传/删除/右键菜单)
- 插件Picker API: window.open+postMessage唤出文件选择器
- 符号链接目录双层面包屑 (逻辑路径+物理路径)
- 文件系统全访问+跨平台 (Linux/Windows/macOS)
- permission_rules.yaml新增4个filemanager.*权限
修复:
- SVG fill=currentColor 日夜模式自适应
- 特殊目录容错 (/dev/fd损坏符号链接/proc)
- 面包屑每层级独立可点击+可编辑路径跳转
- ..行返回上级+data-is-dir补全
- rmlint→lstat回退 损坏符号链接不炸页面
文档:
- 插件开发指南新增第八章(文件管理器集成)
- 开发踩坑记录新增4条(特殊目录/双面包屑/SVG颜色/Windows)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-11 18:23:32 +08:00
qinglong and Claude Opus 4.8
4a989bf50f
feat: WS实时推送、网速双线图、按钮MD3修复、页面加载器修复 (v0.6.0)
...
后端:
- 新增 /api/system/ws WebSocket端点 替代HTTP轮询 (每2s推送系统+框架数据)
- 修复 uptime始终为0 (sm.start_time时间戳)
- 网络采集新增TX上行+实时网速(delta法)
- 进程内存采集 (/proc/self/status VmRSS)
- 抑制aiohttp内部WS帧日志防刷爆日志文件
前端:
- 仪表盘: HTTP轮询→WS连接+指数退避自动重连
- 实时日志: 修复onclose重连bug+批量渲染30fps+500行上限防卡死
- 网速卡片: DualLineChart双线图(下行实线/上行虚线)
- Y轴零点偏移-5% 防止零网速贴底
- 所有按钮修复MD3组合类(btn+btn-tonal+btn-sm)
- 页面加载器: 改动态script元素执行 修复onclick全局作用域问题
- emoji图标→Material Design SVG图标
- CSS去残留</style>+新增.nav-item svg约束
- 登录页输入框+标签左对齐+按钮MD3样式
- 多个版本号显示修复(去双重v前缀)
- chart.js/app.js/HTML页面统一加版本号防浏览器缓存
- .gitignore新增docs/目录
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com >
2026-06-11 16:23:31 +08:00
qinglong
fd0a97fec5
Fix login redirect: add /SenSu/index.html route, restart picks up new app.js
...
- /SenSu/index.html now serves login page (was 404 after cookie expiry)
- Fresh restart with latest page loader + inline script execution
- All routes verified: 200 OK
2026-06-11 14:47:37 +08:00
qinglong
c07cea4ff7
Fix page loader: execute inline scripts, JS module loading optional
...
- innerHTML strips script tags, now extract and eval them
- External .js module: 404 = skip gracefully (no error)
- Progress bar: completes regardless of JS module
- Proxy/projects pages now render with CSS + inline JS executes
2026-06-11 14:43:24 +08:00
qinglong
dd8a31e29a
Fix: proxy API prefix, version from config, remove auth from framework/system endpoints
...
- Proxy routes now use /SenSu/api/proxy (was missing prefix)
- Projects routes use dynamic prefix
- Version reads from config/framework/base_config.yaml
- Framework/System APIs no longer require auth (public info)
- Proxy init separated from route setup (avoids frozen router error)
- Version updated to v0.6.0
2026-06-11 14:37:28 +08:00
qinglong
6918ee6514
Fix headless mode: use sleep loop instead of CLI mode (prevent EOF exit)
...
- Headless now keeps server alive with asyncio.sleep(1) loop
- CLI mode only for non-headless fallback
- Enables running SenSu as daemon/service
2026-06-11 13:02:56 +08:00
qinglong
885929f3ff
Fix proxy/projects pages: error handling when API unavailable
...
- proxy: .catch() shows 'service not ready' instead of stuck loading
- projects: shows 'engine not ready' on API error
- Both: show 'no items' placeholder instead of blank
2026-06-11 12:47:39 +08:00
qinglong
a1dd401efc
Fix theme toggle: move init to app.js, remove duplicate script
...
- Theme initialized BEFORE page render (no flash)
- toggleTheme() now in app.js global scope
- Proxy page rewritten with btn-filled MD3 class
2026-06-11 12:46:33 +08:00
qinglong
c4e2783120
WebUI: MD3 projects/proxy pages, sidebar links, CSS animations
...
- Add projects + proxy nav items to sidebar
- Rewrite projects.html with MD3 cards + tabs + mgmt-cards
- Rewrite proxy.html with MD3 form + mgmt-cards
- CSS: button ripple, card elevation, page fade, tab slide, input glow, nav dot, status pulse, log entry fade, shimmer, scrollbar, badge bounce, card hover mouse-glow (428 lines)
2026-06-11 12:12:03 +08:00