Files
2026-10-29 16:27:16 +08:00

13 lines
690 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 前端文件组织
- `base.html`:页面基础壳,包含图标、顶栏、底栏、移动端导航和资源入口。
- `views/`:按业务页面拆分的视图片段。
- `components/dialogs/`:按功能拆分的弹窗片段。
- `components/toast.html`:Toast 的独立 DOM 结构。
- `js/toast.js`:Toast 行为及顶层堆叠处理。
- `styles/toast.css`:Toast 专属样式。
`backend/main.py` 中的 `render_frontend_shell()` 会在请求 `/`、`/index.html` 或
`/base.html` 时将这些固定片段组合成一个完整文档。新增视图或弹窗时,将文件加入
对应的 `FRONTEND_*_FILES` 列表即可;不要再把大段页面结构写回 `index.html`。