推进 INI 面板 control page controller helper
This commit is contained in:
65
text11.txt
65
text11.txt
@@ -1203,3 +1203,68 @@ host_wasm_opfs_browser_smokes=ok
|
||||
`control-page.html/js` 的页面消费逻辑抽成更小的页面 controller helper,或者直接加一个
|
||||
只读导航入口页,把 `index.html` 与 `control-page.html` 作为并列入口统一暴露;仍保持
|
||||
只读,不新增控制按钮,不解析 G-code。
|
||||
|
||||
十四、2026-06-14 继续执行记录:INI panel control page controller helper
|
||||
|
||||
本轮按“加快实质性推进”把 control page 的页面消费逻辑抽成可复用 controller helper,
|
||||
让只读控制页入口不再把 iframe/API 轮询和渲染逻辑内联在页面脚本里。
|
||||
|
||||
完成内容:
|
||||
|
||||
- 新增 `wasm-port/runtime/ui/ini-panel/control-page-controller.js`;
|
||||
- 导出 `createMachineSessionControlPageController(input)`;
|
||||
- controller 负责:
|
||||
- 读取隐藏 iframe 的 `linuxCncIniPanelApi`;
|
||||
- 调用 `getMachineSessionControlView()`;
|
||||
- 渲染 waiting/status;
|
||||
- 用注入的 renderer 渲染 control view;
|
||||
- 启动轮询;
|
||||
- 挂载 panel iframe;
|
||||
- `wasm-port/runtime/ui/ini-panel/control-page.js` 收敛为 DOM 绑定层;
|
||||
- 新增 `wasm-port/tests/ui/node/verify_ini_panel_control_page_controller.mjs`;
|
||||
- 新增 `wasm-port/tests/ui/node/verify_ini_panel_control_page_controller.sh`;
|
||||
- `wasm-port/tests/ui/node/verify_ui_node_smokes.sh` 纳入 controller node smoke;
|
||||
- `wasm-port/docs/ui-panel-state-summary.md` 补充 controller helper 说明;
|
||||
- 未新增控制按钮;
|
||||
- 未解析 G-code;
|
||||
- 未解释 canonical events;
|
||||
- 未改变 OPFS/session persistence、LinuxCNC interpreter、tool、parameter、planner 或
|
||||
LinuxCNC-owned runtime semantics。
|
||||
|
||||
验证已通过:
|
||||
|
||||
```bash
|
||||
git diff --check
|
||||
wasm-port/tests/ui/node/verify_ini_panel_control_page_controller.sh
|
||||
wasm-port/tests/ui/node/verify_ui_node_smokes.sh
|
||||
wasm-port/tests/browser/verify_ini_panel_browser.sh
|
||||
wasm-port/tools/verify_vendor_sync.sh
|
||||
wasm-port/tools/verify_no_standalone_cnc_semantics.sh
|
||||
SKIP_INTERP_BUILD=1 wasm-port/tests/wasm/node/verify_interp_wasm.sh
|
||||
SKIP_INTERP_BUILD=1 wasm-port/tests/wasm/node/verify_sim_configs_inventory_wasm.sh
|
||||
wasm-port/tests/host/verify_host_smokes.sh
|
||||
```
|
||||
|
||||
关键输出:
|
||||
|
||||
```text
|
||||
ini_panel_control_page_controller_node_smoke=ok
|
||||
ui_node_smokes=ok
|
||||
browser_ini_opfs_smoke=ok
|
||||
browser_ini_control_page_smoke=ok
|
||||
vendor sync up to date
|
||||
standalone CNC semantics guard complete
|
||||
interp_wasm_node_smoke=ok
|
||||
sim_configs_wasm_node_inventory_executed=28
|
||||
sim_configs_wasm_node_inventory_passed=28
|
||||
sim_configs_wasm_node_inventory_skipped=131
|
||||
sim_configs_wasm_node_inventory_unexpected_fail=0
|
||||
host_wasm_opfs_browser_smokes=ok
|
||||
```
|
||||
|
||||
下一步建议:
|
||||
|
||||
继续保持只读边界,下一批建议新增一个极薄的 UI entry index,例如
|
||||
`runtime/ui/ini-panel/launch.html`,把编辑/运行面板 `index.html` 与只读控制页
|
||||
`control-page.html` 作为并列入口暴露,并用 browser smoke 验证两个入口链接可达;仍不新增
|
||||
控制按钮,不解析 G-code。
|
||||
|
||||
Reference in New Issue
Block a user