{ "schema": "freecad-web-manual/scenario/v1", "chapter": "ch07", "workflow": "import-export-panels", "title": "导入导出面板:Files 工具、OPFS 浏览器与 Import 命令坞", "actions": [ { "type": "goto", "url": "/project.html" }, { "type": "waitFor", "selector": "select[aria-label=\"Workbench\"]" }, { "type": "wait", "ms": 1200 }, { "type": "click", "selector": "nav[aria-label=\"Application menus\"] details", "hasText": "File", "target": ":scope > summary" }, { "type": "click", "role": "button", "name": "新建 Document", "exact": true }, { "type": "wait", "ms": 2200 }, { "type": "eval", "script": "for (const d of document.querySelectorAll('nav[aria-label=\"Application menus\"] details[open]')) d.open = false" }, { "type": "click", "selector": "nav[aria-label=\"Application menus\"] details", "hasText": "File", "target": ":scope > summary" }, { "type": "click", "role": "button", "name": "Open / import / export", "exact": true }, { "type": "waitFor", "selector": "details.file-tools" }, { "type": "wait", "ms": 1000 }, { "type": "assertAnyText", "selector": "details.file-tools", "contains": "导出格式" }, { "type": "shot", "name": "01-file-tools", "selector": "details.file-tools" }, { "type": "save" }, { "type": "eval", "script": "const lab=[...document.querySelectorAll('details.file-tools label')].find(l=>(l.textContent||'').includes('OPFS 导出件')); if(lab) lab.scrollIntoView({block:'center'});" }, { "type": "wait", "ms": 500 }, { "type": "shot", "name": "02-opfs-browser" }, { "type": "goto", "url": "/project.html" }, { "type": "waitFor", "selector": "select[aria-label=\"Workbench\"]" }, { "type": "wait", "ms": 1200 }, { "type": "select", "selector": "select[aria-label=\"Workbench\"]", "label": "Import" }, { "type": "wait", "ms": 1800 }, { "type": "waitFor", "selector": "aside:has-text(\"Import commands\")" }, { "type": "assertAnyText", "selector": "aside:has-text(\"Import commands\")", "contains": "GUI / Web matrix" }, { "type": "shot", "name": "03-import-commands", "selector": "aside:has-text(\"Import commands\")" }, { "type": "click", "selector": "button[data-command=\"import.pythonApi\"]" }, { "type": "wait", "ms": 400 }, { "type": "click", "role": "button", "name": "执行选中命令", "exact": true }, { "type": "wait", "ms": 3000 }, { "type": "assertAnyText", "selector": "section:has-text(\"统一命令结果\")", "contains": "native command complete" }, { "type": "shot", "name": "04-import-result", "selector": "section:has-text(\"统一命令结果\")" } ] }