@buaa_smat/hometrans 26.0.5 → 26.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +249 -279
- package/agents/code-reviewer.md +1 -1
- package/dist/cli/editors.json +20 -0
- package/dist/platform/registry.js +1 -0
- package/dist/platform/validate.js +2 -1
- package/i18n/agents/code-reviewer.md +1 -1
- package/i18n/platforms/atomcode/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/platforms/claude-code/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/platforms/codebuddy/skills/a2h-app-migrate/SKILL.unique.md +8 -0
- package/i18n/platforms/codex/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/platforms/cursor/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/platforms/deveco/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/platforms/opencode/skills/a2h-app-migrate/SKILL.unique.md +10 -0
- package/i18n/platforms/qoder/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/platforms/qoder-cn/skills/a2h-app-migrate/SKILL.unique.md +8 -0
- package/i18n/platforms/trae/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/platforms/trae-cn/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/i18n/skills/a2h-app-migrate/SKILL.md +32 -15
- package/i18n/skills/a2h-app-migrate/references/stage-map.md +4 -2
- package/i18n/skills/a2h-app-migrate/references/workflow.yaml +148 -89
- package/i18n/skills/a2h-app-migrate/scripts/env_preflight.mjs +1 -1
- package/i18n/skills/a2h-app-migrate/scripts/validate_workflow.mjs +51 -2
- package/i18n/skills/a2h-app-migrate/test/test_build_fixer_contract.mjs +1 -1
- package/i18n/skills/a2h-app-migrate/test/test_interaction.mjs +0 -2
- package/i18n/skills/a2h-app-migrate/test/test_resume_plan.mjs +1 -1
- package/i18n/skills/a2h-app-migrate/test/test_skill_doc.mjs +1 -1
- package/i18n/skills/a2h-app-migrate/test/test_specs_json_preflight.mjs +1 -1
- package/i18n/skills/a2h-app-migrate/test/test_utg_static_done.mjs +9 -3
- package/i18n/skills/a2h-app-migrate/test/test_validate_workflow_bilingual.mjs +4 -2
- package/i18n/skills/a2h-arkts-logic-coder/SKILL.md +8 -7
- package/i18n/skills/a2h-arkts-logic-coder/references/ISSUES.md +2 -2
- package/i18n/skills/a2h-arkts-logic-coder/references/code-generation.md +33 -12
- package/i18n/skills/a2h-batch-ui-align/SKILL.md +14 -12
- package/i18n/skills/a2h-batch-ui-align/references/cards/alignment.md +1 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/canvas.md +1 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/dynamics.md +32 -1
- package/i18n/skills/a2h-batch-ui-align/references/cards/geometry.md +3 -2
- package/i18n/skills/a2h-batch-ui-align/references/cards/interaction.md +4 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/resources.md +19 -1
- package/i18n/skills/a2h-batch-ui-align/references/cards/widgets.md +13 -1
- package/i18n/skills/a2h-batch-ui-align/references/cards/window.md +2 -2
- package/i18n/skills/a2h-batch-ui-align/references/checker-rules.md +205 -7
- package/i18n/skills/a2h-batch-ui-align/references/conversion-procedure.md +10 -17
- package/i18n/skills/a2h-batch-ui-align/references/incremental-scope.md +3 -4
- package/i18n/skills/a2h-batch-ui-align/references/lottie-integration.md +47 -2
- package/i18n/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-atomic-component-mapping-reference.md +52 -328
- package/i18n/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-interaction-mapping-reference.md +1 -138
- package/i18n/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-layout-mapping-reference.md +2 -11
- package/i18n/skills/a2h-batch-ui-align/references/state-mgmt/_paradigm-selection.md +1 -1
- package/i18n/skills/a2h-batch-ui-align/references/step3-capture.md +8 -23
- package/i18n/skills/a2h-batch-ui-align/references/step4-prepare.md +2 -1
- package/i18n/skills/a2h-batch-ui-align/references/step5-convert.md +17 -9
- package/i18n/skills/a2h-batch-ui-align/scripts/build_conversion_set.mjs +239 -16
- package/i18n/skills/a2h-batch-ui-align/scripts/group_pack.mjs +6 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/icon_coverage.mjs +6 -3
- package/i18n/skills/a2h-batch-ui-align/scripts/measure_pack.ts +170 -10
- package/i18n/skills/a2h-batch-ui-align/scripts/phase5_check.mjs +42 -1
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/main.ts +20 -1
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/attr_chain.ts +81 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/click_handler.ts +140 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/collapsing_toolbar.ts +124 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/compose_semantics.ts +287 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/flowitem_width.ts +78 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/hit_test.ts +194 -8
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/inset_stacked.ts +138 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/int_division.ts +181 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/layout_placement.ts +62 -2
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/lottie_path.ts +77 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/lottie_ready.ts +109 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/media_tint.ts +88 -18
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/relative_container_cycle.ts +140 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/relative_container_height.ts +2 -2
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/see_through_overlay.ts +149 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/sheet_builder.ts +139 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/sheet_show_close.ts +53 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/space_between_optional.ts +115 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/theme_color.ts +7 -1
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/width_fill.ts +160 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_inset_stacked.test.mjs +155 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_layout_placement.test.mjs +60 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set.test.mjs +38 -0
- package/i18n/skills/a2h-module-semantic-docs/SKILL.md +3 -2
- package/i18n/skills/a2h-page-specgen/SKILL.md +36 -5
- package/i18n/skills/a2h-page-specgen/references/behavior-ledger.md +89 -21
- package/i18n/skills/a2h-page-specgen/references/gates.md +33 -7
- package/i18n/skills/a2h-page-specgen/references/scenario-authoring.md +67 -13
- package/i18n/skills/a2h-page-specgen/references/spec-example.md +166 -32
- package/i18n/skills/a2h-page-specgen/references/spec-template.md +8 -5
- package/i18n/skills/a2h-page-specgen/scripts/behavior-audit.mjs +37 -1
- package/i18n/skills/a2h-page-specgen/scripts/behavior-discovery.mjs +241 -22
- package/i18n/skills/a2h-page-specgen/scripts/behavior-model.mjs +29 -2
- package/i18n/skills/a2h-page-specgen/scripts/behavior-reconcile.mjs +32 -0
- package/i18n/skills/a2h-page-specgen/scripts/contract-calls.mjs +715 -0
- package/i18n/skills/a2h-page-specgen/scripts/footprint.mjs +129 -2
- package/i18n/skills/a2h-page-specgen/scripts/gate.mjs +19 -10
- package/i18n/skills/a2h-page-specgen/scripts/lib/contracts.mjs +62 -3
- package/i18n/skills/a2h-page-specgen/scripts/lib/graph-evidence.mjs +27 -0
- package/i18n/skills/a2h-page-specgen/scripts/lib/hg.mjs +116 -6
- package/i18n/skills/a2h-page-specgen/scripts/operation-evidence.mjs +270 -29
- package/i18n/skills/a2h-page-specgen/scripts/prepare.mjs +26 -14
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/PlainDisplayPage.prompt.md +118 -25
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/PlainDisplayPage.worker.md +104 -19
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/SilentFailurePage.prompt.md +118 -25
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/SilentFailurePage.worker.md +104 -19
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.discovery.json +216 -216
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.json +1 -1
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.post-review.json +2 -2
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.prompt.md +118 -25
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.worker.md +100 -15
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/ValidatedSearchPage.prompt.md +118 -25
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/ValidatedSearchPage.worker.md +104 -19
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/authoring/run.mjs +155 -3
- package/i18n/skills/a2h-page-specgen/scripts/test/android-operation-evidence.test.mjs +529 -1
- package/i18n/skills/a2h-page-specgen/scripts/test/behavior-audit-pre.test.mjs +27 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/behavior-discovery.test.mjs +158 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/behavior-fixtures.mjs +11 -13
- package/i18n/skills/a2h-page-specgen/scripts/test/behavior-reconcile.test.mjs +97 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/contract-calls.test.mjs +737 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/contracts.test.mjs +75 -3
- package/i18n/skills/a2h-page-specgen/scripts/test/finalize.test.mjs +24 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/fixtures/hg.mkdb.mjs +124 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/footprint-resolve.test.mjs +6 -2
- package/i18n/skills/a2h-page-specgen/scripts/test/gate.test.mjs +106 -1
- package/i18n/skills/a2h-page-specgen/scripts/test/graph-evidence.test.mjs +32 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/hg.test.mjs +12 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/operation-reviews.test.mjs +6 -1
- package/i18n/skills/a2h-page-specgen/scripts/test/prompt-tpl.test.mjs +11 -3
- package/i18n/skills/a2h-page-specgen/scripts/test/protocol-docs.test.mjs +1 -1
- package/i18n/skills/a2h-page-specgen/scripts/test/recovery-e2e.test.mjs +1 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/submit.test.mjs +159 -27
- package/i18n/skills/a2h-resource-convert/SKILL.md +1 -1
- package/i18n/skills/a2h-resource-convert/references/lottie-conversion-rules.md +2 -2
- package/i18n/skills/a2h-resource-convert/scripts/a2h_resource_convert.ts +124 -8
- package/i18n/skills/a2h-resource-convert/scripts/sync-framework-strings.mjs +147 -0
- package/i18n/skills/a2h-resource-convert/scripts/tests/framework_strings.test.mjs +131 -0
- package/i18n/skills/a2h-spec-design-pipeline/SKILL.md +15 -12
- package/i18n/skills/a2h-spec-design-pipeline/references/coding-loop.md +38 -10
- package/i18n/skills/a2h-spec-design-pipeline/references/initialization.md +2 -2
- package/i18n/skills/a2h-spec-design-pipeline/references/post-loop.md +2 -2
- package/i18n/skills/a2h-spec-design-pipeline/references/reply-recovery.md +172 -0
- package/i18n/skills/a2h-spec-design-pipeline/references/review-loop.md +2 -2
- package/i18n/skills/a2h-spec-design-pipeline/references/scripts.md +5 -3
- package/i18n/skills/a2h-spec-design-pipeline/references/state-and-resume.md +7 -1
- package/i18n/skills/a2h-spec-design-pipeline/scripts/plan_groups.ts +1 -1
- package/i18n/skills/a2h-spec-design-pipeline/scripts/test_plan_groups.ts +2 -0
- package/i18n/skills/a2h-spec-generate/references/input-formats.md +1 -1
- package/i18n/skills/a2h-utg-explorer/SKILL.md +11 -5
- package/i18n/skills/a2h-utg-explorer/references/architecture.md +37 -19
- package/i18n/skills/a2h-utg-explorer/scripts/compile_tasks.mjs +48 -3
- package/i18n/skills/a2h-utg-explorer/scripts/final_utg.mjs +21 -0
- package/i18n/skills/a2h-utg-explorer/scripts/recover_d.mjs +67 -8
- package/i18n/skills/a2h-utg-explorer/scripts/tests/diagnostics.test.mjs +32 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/dialog_own_layout.test.mjs +40 -0
- package/i18n/skills/a2h-utg-explorer/scripts/utg_explorer/semantics.mjs +63 -2
- package/i18n/skills/a2h-utg-explorer/scripts/utg_explorer/task_runner.mjs +143 -14
- package/i18n/skills/a2h-utg-static/SKILL.md +3 -3
- package/i18n/skills/a2h-utg-static/references/ui-elements-static-utg-schema.md +4 -3
- package/i18n/skills/a2h-utg-static/scripts/click_paths.mjs +1 -1
- package/i18n/skills/a2h-utg-static/scripts/tests/test_compose_res_text.mjs +25 -0
- package/i18n/skills/a2h-utg-static/tools/convert_static_utg_to_ui_elements.ts +1 -0
- package/package.json +2 -1
- package/platforms/atomcode/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/platforms/claude-code/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/platforms/codebuddy/agents/build-fixer.frontmatter.md +5 -0
- package/platforms/codebuddy/agents/code-reviewer.frontmatter.md +5 -0
- package/platforms/codebuddy/agents/model-render-worker.frontmatter.md +5 -0
- package/platforms/codebuddy/agents/model-worker.frontmatter.md +5 -0
- package/platforms/codebuddy/agents/specgen-worker.frontmatter.md +5 -0
- package/platforms/codebuddy/skills/a2h-app-migrate/SKILL.unique.md +8 -0
- package/platforms/codex/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/platforms/cursor/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/platforms/deveco/agents/build-fixer.frontmatter.md +2 -0
- package/platforms/deveco/agents/code-reviewer.frontmatter.md +2 -0
- package/platforms/deveco/agents/model-render-worker.frontmatter.md +2 -0
- package/platforms/deveco/agents/model-worker.frontmatter.md +2 -0
- package/platforms/deveco/agents/specgen-worker.frontmatter.md +2 -0
- package/platforms/deveco/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/platforms/opencode/agents/build-fixer.frontmatter.md +2 -0
- package/platforms/opencode/agents/code-reviewer.frontmatter.md +2 -0
- package/platforms/opencode/agents/model-render-worker.frontmatter.md +2 -0
- package/platforms/opencode/agents/model-worker.frontmatter.md +2 -0
- package/platforms/opencode/agents/specgen-worker.frontmatter.md +2 -0
- package/platforms/opencode/skills/a2h-app-migrate/SKILL.unique.md +10 -0
- package/platforms/qoder/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/platforms/qoder-cn/skills/a2h-app-migrate/SKILL.unique.md +8 -0
- package/platforms/trae/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/platforms/trae-cn/skills/a2h-app-migrate/SKILL.unique.md +3 -0
- package/skills/a2h-app-migrate/SKILL.md +31 -14
- package/skills/a2h-app-migrate/references/stage-map.md +4 -2
- package/skills/a2h-app-migrate/references/workflow.yaml +152 -89
- package/skills/a2h-app-migrate/scripts/assert_dag_complete.mjs +1 -1
- package/skills/a2h-app-migrate/scripts/check_ui_batch_done.mjs +28 -11
- package/skills/a2h-app-migrate/scripts/dag_action_catalog.mjs +76 -0
- package/skills/a2h-app-migrate/scripts/dag_production_executor.mjs +60 -5
- package/skills/a2h-app-migrate/scripts/dag_runner.mjs +184 -4
- package/skills/a2h-app-migrate/scripts/env_preflight.mjs +1 -1
- package/skills/a2h-app-migrate/scripts/ledger.mjs +2 -2
- package/skills/a2h-app-migrate/scripts/resume_plan.mjs +3 -3
- package/skills/a2h-app-migrate/scripts/validate_workflow.mjs +51 -2
- package/skills/a2h-app-migrate/test/test_dag_blocked_guard.mjs +291 -0
- package/skills/a2h-app-migrate/test/test_dag_production.mjs +40 -0
- package/skills/a2h-app-migrate/test/test_dag_runner.mjs +4 -3
- package/skills/a2h-app-migrate/test/test_i18n_engine_mirror.mjs +1 -1
- package/skills/a2h-app-migrate/test/test_interaction.mjs +0 -2
- package/skills/a2h-app-migrate/test/test_resume_plan.mjs +1 -1
- package/skills/a2h-app-migrate/test/test_skill_doc.mjs +1 -1
- package/skills/a2h-app-migrate/test/test_spec_engine_contract.mjs +1 -1
- package/skills/a2h-app-migrate/test/test_specs_json_preflight.mjs +1 -1
- package/skills/a2h-app-migrate/test/test_ui_batch_done.mjs +36 -0
- package/skills/a2h-app-migrate/test/test_utg_static_done.mjs +19 -6
- package/skills/a2h-app-migrate/test/test_validate_workflow_bilingual.mjs +4 -2
- package/skills/a2h-arkts-logic-coder/SKILL.md +8 -7
- package/skills/a2h-arkts-logic-coder/references/ISSUES.md +2 -2
- package/skills/a2h-arkts-logic-coder/references/code-generation.md +33 -12
- package/skills/a2h-batch-ui-align/SKILL.md +14 -12
- package/skills/a2h-batch-ui-align/references/cards/alignment.md +1 -0
- package/skills/a2h-batch-ui-align/references/cards/canvas.md +1 -0
- package/skills/a2h-batch-ui-align/references/cards/dynamics.md +32 -1
- package/skills/a2h-batch-ui-align/references/cards/geometry.md +3 -2
- package/skills/a2h-batch-ui-align/references/cards/interaction.md +4 -0
- package/skills/a2h-batch-ui-align/references/cards/resources.md +19 -1
- package/skills/a2h-batch-ui-align/references/cards/widgets.md +13 -1
- package/skills/a2h-batch-ui-align/references/cards/window.md +2 -2
- package/skills/a2h-batch-ui-align/references/checker-rules.md +205 -7
- package/skills/a2h-batch-ui-align/references/conversion-procedure.md +10 -17
- package/skills/a2h-batch-ui-align/references/incremental-scope.md +3 -4
- package/skills/a2h-batch-ui-align/references/lottie-integration.md +47 -2
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-atomic-component-mapping-reference.md +52 -328
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-interaction-mapping-reference.md +1 -138
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-layout-mapping-reference.md +2 -11
- package/skills/a2h-batch-ui-align/references/state-mgmt/_/350/214/203/345/274/217/351/200/211/346/213/251/350/257/264/346/230/216.md +1 -1
- package/skills/a2h-batch-ui-align/references/step3-capture.md +8 -23
- package/skills/a2h-batch-ui-align/references/step4-prepare.md +2 -1
- package/skills/a2h-batch-ui-align/references/step5-convert.md +17 -9
- package/skills/a2h-batch-ui-align/scripts/build_conversion_set.mjs +239 -16
- package/skills/a2h-batch-ui-align/scripts/group_commit.mjs +6 -1
- package/skills/a2h-batch-ui-align/scripts/group_pack.mjs +6 -0
- package/skills/a2h-batch-ui-align/scripts/group_pass.mjs +270 -0
- package/skills/a2h-batch-ui-align/scripts/group_queue.mjs +134 -16
- package/skills/a2h-batch-ui-align/scripts/group_watch.mjs +39 -8
- package/skills/a2h-batch-ui-align/scripts/icon_coverage.mjs +6 -3
- package/skills/a2h-batch-ui-align/scripts/measure_pack.ts +170 -10
- package/skills/a2h-batch-ui-align/scripts/module_placement.mjs +189 -0
- package/skills/a2h-batch-ui-align/scripts/overlay_effects.mjs +205 -0
- package/skills/a2h-batch-ui-align/scripts/phase5_check.mjs +42 -1
- package/skills/a2h-batch-ui-align/scripts/static_check/main.ts +20 -1
- package/skills/a2h-batch-ui-align/scripts/static_check/registry.ts +28 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/attr_chain.ts +81 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/click_handler.ts +140 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/collapsing_toolbar.ts +124 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/compose_semantics.ts +287 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/flowitem_width.ts +78 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/hit_test.ts +194 -8
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/inset_stacked.ts +138 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/int_division.ts +181 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/layout_placement.ts +62 -2
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/lottie_path.ts +77 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/lottie_ready.ts +109 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/media_tint.ts +88 -18
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/relative_container_cycle.ts +140 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/relative_container_height.ts +2 -2
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/see_through_overlay.ts +149 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/sheet_builder.ts +139 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/sheet_show_close.ts +53 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/space_between_optional.ts +115 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/theme_color.ts +7 -1
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/width_fill.ts +160 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/scan_file.ts +28 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_chrome_defaults.test.mjs +328 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_click_handler.test.mjs +127 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_compose_semantics.test.mjs +150 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_hit_test.test.mjs +117 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_inset_stacked.test.mjs +155 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_layout_placement.test.mjs +60 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_rule_smoke.test.mjs +413 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_runtime_api.test.mjs +159 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_sheet_builder.test.mjs +192 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_theme.test.mjs +4 -2
- package/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set.test.mjs +38 -0
- package/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set_compose.test.mjs +106 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_commit.test.mjs +15 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_pass.test.mjs +150 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_queue.test.mjs +125 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_watch.test.mjs +56 -0
- package/skills/a2h-batch-ui-align/scripts/tests/measure_pack_icon_leaf.test.mjs +143 -0
- package/skills/a2h-batch-ui-align/scripts/tests/module_placement.test.mjs +248 -0
- package/skills/a2h-batch-ui-align/scripts/tests/overlay_effects.test.mjs +214 -0
- package/skills/a2h-fix-build-errors/references/known-patterns.md +5 -5
- package/skills/a2h-module-semantic-docs/SKILL.md +3 -2
- package/skills/a2h-module-semantic-docs/scripts/commit_module_state.mjs +10 -0
- package/skills/a2h-module-semantic-docs/scripts/design_baseline.mjs +158 -0
- package/skills/a2h-module-semantic-docs/test/test_design_baseline.mjs +128 -0
- package/skills/a2h-page-specgen/SKILL.md +36 -5
- package/skills/a2h-page-specgen/references/behavior-ledger.md +88 -21
- package/skills/a2h-page-specgen/references/evidence.md +2 -1
- package/skills/a2h-page-specgen/references/execution-model.md +13 -5
- package/skills/a2h-page-specgen/references/gates.md +33 -7
- package/skills/a2h-page-specgen/references/scenario-authoring.md +67 -13
- package/skills/a2h-page-specgen/references/spec-example.md +166 -32
- package/skills/a2h-page-specgen/references/spec-template.md +8 -5
- package/skills/a2h-page-specgen/scripts/behavior-audit.mjs +40 -2
- package/skills/a2h-page-specgen/scripts/behavior-discovery.mjs +241 -22
- package/skills/a2h-page-specgen/scripts/behavior-model.mjs +29 -2
- package/skills/a2h-page-specgen/scripts/behavior-reconcile.mjs +35 -2
- package/skills/a2h-page-specgen/scripts/contract-calls.mjs +715 -0
- package/skills/a2h-page-specgen/scripts/finalize.mjs +55 -2
- package/skills/a2h-page-specgen/scripts/footprint.mjs +129 -2
- package/skills/a2h-page-specgen/scripts/gate.mjs +20 -11
- package/skills/a2h-page-specgen/scripts/lib/contracts.mjs +56 -3
- package/skills/a2h-page-specgen/scripts/lib/graph-evidence.mjs +27 -0
- package/skills/a2h-page-specgen/scripts/lib/hg.mjs +114 -5
- package/skills/a2h-page-specgen/scripts/lib/ledger.mjs +20 -3
- package/skills/a2h-page-specgen/scripts/operation-evidence.mjs +270 -29
- package/skills/a2h-page-specgen/scripts/prepare.mjs +25 -14
- package/skills/a2h-page-specgen/scripts/report.mjs +26 -5
- package/skills/a2h-page-specgen/scripts/submission.mjs +69 -2
- package/skills/a2h-page-specgen/scripts/submit.mjs +105 -4
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/PlainDisplayPage.prompt.md +110 -18
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/PlainDisplayPage.worker.md +97 -12
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/SilentFailurePage.prompt.md +110 -18
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/SilentFailurePage.worker.md +97 -12
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.discovery.json +224 -224
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.json +1 -1
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.post-review.json +2 -2
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.prompt.md +110 -18
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/UniAppSourcePage.worker.md +97 -12
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/ValidatedSearchPage.prompt.md +110 -18
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/ValidatedSearchPage.worker.md +97 -12
- package/skills/a2h-page-specgen/scripts/test/acceptance/authoring/run.mjs +153 -3
- package/skills/a2h-page-specgen/scripts/test/android-operation-evidence.test.mjs +529 -1
- package/skills/a2h-page-specgen/scripts/test/behavior-audit-pre.test.mjs +27 -0
- package/skills/a2h-page-specgen/scripts/test/behavior-discovery.test.mjs +158 -0
- package/skills/a2h-page-specgen/scripts/test/behavior-fixtures.mjs +11 -13
- package/skills/a2h-page-specgen/scripts/test/behavior-reconcile.test.mjs +97 -0
- package/skills/a2h-page-specgen/scripts/test/contract-calls.test.mjs +737 -0
- package/skills/a2h-page-specgen/scripts/test/contracts.test.mjs +82 -3
- package/skills/a2h-page-specgen/scripts/test/finalize.test.mjs +24 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/hg.mkdb.mjs +11 -0
- package/skills/a2h-page-specgen/scripts/test/footprint-resolve.test.mjs +6 -2
- package/skills/a2h-page-specgen/scripts/test/gate.test.mjs +94 -1
- package/skills/a2h-page-specgen/scripts/test/graph-evidence.test.mjs +32 -0
- package/skills/a2h-page-specgen/scripts/test/hg.test.mjs +14 -0
- package/skills/a2h-page-specgen/scripts/test/ledger.test.mjs +49 -1
- package/skills/a2h-page-specgen/scripts/test/operation-reviews.test.mjs +6 -1
- package/skills/a2h-page-specgen/scripts/test/prompt-tpl.test.mjs +12 -4
- package/skills/a2h-page-specgen/scripts/test/protocol-docs.test.mjs +1 -1
- package/skills/a2h-page-specgen/scripts/test/recovery-e2e.test.mjs +1 -0
- package/skills/a2h-page-specgen/scripts/test/report.test.mjs +80 -1
- package/skills/a2h-page-specgen/scripts/test/submit.test.mjs +159 -27
- package/skills/a2h-page-specgen/scripts/test/waker-process.test.mjs +23 -0
- package/skills/a2h-page-specgen/scripts/waker.mjs +8 -1
- package/skills/a2h-resource-convert/SKILL.md +1 -1
- package/skills/a2h-resource-convert/data/framework-strings/NOTICE +10 -0
- package/skills/a2h-resource-convert/data/framework-strings/manifest.json +90 -0
- package/skills/a2h-resource-convert/data/framework-strings/strings.json +382 -0
- package/skills/a2h-resource-convert/references/conversion-rules.md +7 -1
- package/skills/a2h-resource-convert/references/lottie-conversion-rules.md +2 -2
- package/skills/a2h-resource-convert/references/step5-reference-resolution.md +16 -0
- package/skills/a2h-resource-convert/scripts/a2h_resource_convert.ts +124 -8
- package/skills/a2h-resource-convert/scripts/sync-framework-strings.mjs +147 -0
- package/skills/a2h-resource-convert/scripts/tests/framework_strings.test.mjs +131 -0
- package/skills/a2h-spec-design-pipeline/SKILL.md +14 -11
- package/skills/a2h-spec-design-pipeline/references/coding-loop.md +38 -10
- package/skills/a2h-spec-design-pipeline/references/execution-model.md +3 -0
- package/skills/a2h-spec-design-pipeline/references/final-report-template.md +6 -3
- package/skills/a2h-spec-design-pipeline/references/initialization.md +2 -2
- package/skills/a2h-spec-design-pipeline/references/post-loop.md +2 -2
- package/skills/a2h-spec-design-pipeline/references/reply-recovery.md +172 -0
- package/skills/a2h-spec-design-pipeline/references/review-loop.md +2 -2
- package/skills/a2h-spec-design-pipeline/references/scripts.md +4 -3
- package/skills/a2h-spec-design-pipeline/references/shared-layer.md +24 -19
- package/skills/a2h-spec-design-pipeline/references/state-and-resume.md +7 -1
- package/skills/a2h-spec-design-pipeline/references/static-defect-gate.md +12 -5
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/config/ruleMeta.json +5 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/config/ruleSet.json +4 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/data/README.md +27 -3
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/data/api-param-contract.json +46 -1
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/data/api-permission-map.json +2511 -295
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/api-permission-declared-cn.md +27 -72
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/api-permission-declared-en.md +39 -83
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/arkui-runtime-pitfall-cn.md +132 -101
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/arkui-runtime-pitfall-en.md +158 -115
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/platform-api-contract-cn.md +60 -93
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/platform-api-contract-en.md +73 -100
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/route-page-side-effect-import-cn.md +52 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/route-page-side-effect-import-en.md +59 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/checker/ApiPermissionDeclaredCheck.js +57 -8
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/checker/ArkUIRuntimePitfallCheck.js +475 -18
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/checker/PlatformApiContractCheck.js +472 -4
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/checker/RoutePageSideEffectImportCheck.js +570 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/checker/arkui/RouteParamCarrierSubCheck.js +1053 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/checker/sql/SqlIdentifierAnalysis.js +427 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/index.js +7 -1
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/package.json +1 -1
- package/skills/a2h-spec-design-pipeline/scripts/plan_groups.ts +1 -1
- package/skills/a2h-spec-design-pipeline/scripts/settle.ts +785 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_api_permission_declared.ts +286 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_arkui_runtime_pitfall.ts +166 -2
- package/skills/a2h-spec-design-pipeline/scripts/test_docs_refresh_contract.ts +40 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_plan_groups.ts +2 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_platform_api_contract.ts +350 -7
- package/skills/a2h-spec-design-pipeline/scripts/test_route_page_side_effect_import.ts +185 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_route_param_carrier.ts +341 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_settle.ts +593 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_shared_layer_docs.ts +92 -1
- package/skills/a2h-spec-design-pipeline/scripts/test_sql_identifier_analysis.ts +137 -0
- package/skills/a2h-spec-generate/references/input-formats.md +1 -1
- package/skills/a2h-utg-explorer/SKILL.md +11 -5
- package/skills/a2h-utg-explorer/references/architecture.md +37 -19
- package/skills/a2h-utg-explorer/scripts/audit.mjs +6 -2
- package/skills/a2h-utg-explorer/scripts/close_phases.mjs +8 -5
- package/skills/a2h-utg-explorer/scripts/compile_tasks.mjs +95 -19
- package/skills/a2h-utg-explorer/scripts/d_prereqs.mjs +192 -4
- package/skills/a2h-utg-explorer/scripts/final_utg.mjs +21 -0
- package/skills/a2h-utg-explorer/scripts/panel_routes.mjs +1 -1
- package/skills/a2h-utg-explorer/scripts/plan.mjs +16 -1
- package/skills/a2h-utg-explorer/scripts/predicates.mjs +270 -0
- package/skills/a2h-utg-explorer/scripts/promote_dynamic.mjs +2 -0
- package/skills/a2h-utg-explorer/scripts/recover.mjs +4 -3
- package/skills/a2h-utg-explorer/scripts/recover_d.mjs +67 -8
- package/skills/a2h-utg-explorer/scripts/rejudge.mjs +4 -3
- package/skills/a2h-utg-explorer/scripts/report.mjs +32 -2
- package/skills/a2h-utg-explorer/scripts/run_cycle.mjs +103 -36
- package/skills/a2h-utg-explorer/scripts/run_device.mjs +3 -8
- package/skills/a2h-utg-explorer/scripts/schedule_states.mjs +189 -0
- package/skills/a2h-utg-explorer/scripts/tests/calendar_round_fixes.test.mjs +9 -0
- package/skills/a2h-utg-explorer/scripts/tests/coverage_rules.test.mjs +11 -0
- package/skills/a2h-utg-explorer/scripts/tests/d_prereqs.test.mjs +31 -2
- package/skills/a2h-utg-explorer/scripts/tests/device_lock_retry.test.mjs +1 -1
- package/skills/a2h-utg-explorer/scripts/tests/diagnostics.test.mjs +32 -0
- package/skills/a2h-utg-explorer/scripts/tests/dialog_own_layout.test.mjs +40 -0
- package/skills/a2h-utg-explorer/scripts/tests/explorer_review_fixes.test.mjs +4 -1
- package/skills/a2h-utg-explorer/scripts/tests/hybrid_route.test.mjs +6 -28
- package/skills/a2h-utg-explorer/scripts/tests/in_route_surface.test.mjs +125 -0
- package/skills/a2h-utg-explorer/scripts/tests/list_probe_target_wait.test.mjs +86 -0
- package/skills/a2h-utg-explorer/scripts/tests/multi_host.test.mjs +167 -0
- package/skills/a2h-utg-explorer/scripts/tests/nested_list.test.mjs +58 -0
- package/skills/a2h-utg-explorer/scripts/tests/overlay_opener.test.mjs +100 -0
- package/skills/a2h-utg-explorer/scripts/tests/pipeline.test.mjs +8 -1
- package/skills/a2h-utg-explorer/scripts/tests/pr169_review_fixes.test.mjs +1 -0
- package/skills/a2h-utg-explorer/scripts/tests/pr191_review_fixes.test.mjs +2 -31
- package/skills/a2h-utg-explorer/scripts/tests/review_fixes.test.mjs +1 -1
- package/skills/a2h-utg-explorer/scripts/tests/run_cycle.test.mjs +56 -7
- package/skills/a2h-utg-explorer/scripts/tests/snapshot_integrity.test.mjs +117 -6
- package/skills/a2h-utg-explorer/scripts/tests/state_inventory.test.mjs +414 -0
- package/skills/a2h-utg-explorer/scripts/tests/tree_unreliable.test.mjs +197 -0
- package/skills/a2h-utg-explorer/scripts/utg_explorer/adapters.mjs +196 -30
- package/skills/a2h-utg-explorer/scripts/utg_explorer/hosts.mjs +146 -0
- package/skills/a2h-utg-explorer/scripts/utg_explorer/semantics.mjs +63 -2
- package/skills/a2h-utg-explorer/scripts/utg_explorer/states.mjs +286 -0
- package/skills/a2h-utg-explorer/scripts/utg_explorer/task_runner.mjs +197 -19
- package/skills/a2h-utg-static/SKILL.md +3 -3
- package/skills/a2h-utg-static/references/extractors.md +7 -0
- package/skills/a2h-utg-static/references/ui-elements-static-utg-schema.md +4 -3
- package/skills/a2h-utg-static/scripts/click_paths.mjs +1 -1
- package/skills/a2h-utg-static/scripts/compose_overlay.mjs +642 -22
- package/skills/a2h-utg-static/scripts/tests/test_compose_res_text.mjs +25 -0
- package/skills/a2h-utg-static/scripts/tests/test_in_route_surface.mjs +123 -0
- package/skills/a2h-utg-static/scripts/tests/test_overlay_host_effects.mjs +239 -0
- package/skills/a2h-utg-static/scripts/tests/test_shared_host_depths.mjs +48 -0
- package/skills/a2h-utg-static/scripts/utg_html.mjs +2 -0
- package/skills/a2h-utg-static/tools/convert_static_utg_to_ui_elements.ts +1 -0
- package/i18n/skills/a2h-app-migrate/references/specs.example.json +0 -19
- package/i18n/skills/a2h-batch-ui-align/scripts/databinding_analyzer_design.md +0 -79
- package/i18n/skills/a2h-utg-explorer/scripts/utg_explorer/state_phase.mjs +0 -47
- package/resource/convert_pipeline_process.svg +0 -114
- package/resource/project_architecture.svg +0 -120
- package/resource/set_environment.png +0 -0
- package/resource/set_multimodel.png +0 -0
- package/skills/a2h-app-migrate/references/specs.example.json +0 -19
- package/skills/a2h-batch-ui-align/scripts/databinding_analyzer_design.md +0 -79
- package/skills/a2h-utg-explorer/scripts/utg_explorer/state_phase.mjs +0 -47
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
| `requestDisallowInterceptTouchEvent()` | `hitTestBehavior` | Prevent interception (static config) | `Component().hitTestBehavior(HitTestMode.None)` |
|
|
58
58
|
| `onInterceptTouchEvent()` | `onTouchIntercept()` | Event interception (dynamic callback) | `Container().onTouchIntercept((event) => { /* return a HitTestMode */ })` |
|
|
59
59
|
| No direct equivalent | `HitTestMode.Default` | Default: a hit on itself blocks sibling components | API 7+ |
|
|
60
|
-
| No direct equivalent | `HitTestMode.None` | Does not receive events itself, does not block | API 7+ |
|
|
60
|
+
| No direct equivalent | `HitTestMode.None` | Does not receive events itself, does not block; **children still respond** (enum reference: "Self not respond … but children respond"), so it cannot disable a whole subtree. To stop a hidden page or layer from taking taps, follow whether Android still composes it: unmount it with `if` when it does not, or use `BLOCK_DESCENDANTS` when it must stay during a transition (GATE `hidden-layer-children-hit`) | API 7+ |
|
|
61
61
|
| No direct equivalent | `HitTestMode.Block` | Blocks touch testing of children | API 7+ |
|
|
62
62
|
| No direct equivalent | `HitTestMode.Transparent` | Touch-tests itself, does not block | API 7+ |
|
|
63
63
|
| No direct equivalent | `HitTestMode.BLOCK_HIERARCHY` (new in API 20)| Itself and children respond; ancestors are blocked | API 20+ |
|
|
@@ -421,140 +421,3 @@ The following Android UI interaction features have no direct equivalent in Harmo
|
|
|
421
421
|
- Enhanced gesture interception (onGestureRecognizerJudgeBegin)
|
|
422
422
|
- Optimized event response chain
|
|
423
423
|
- responseRegion touch hot-zone support
|
|
424
|
-
|
|
425
|
-
---
|
|
426
|
-
|
|
427
|
-
## 13. Mapping Summary
|
|
428
|
-
|
|
429
|
-
### 13.1 Interactions with Direct Mapping (40+)
|
|
430
|
-
|
|
431
|
-
Interaction features that can be replaced one-to-one:
|
|
432
|
-
- Basic touch events (onTouch)
|
|
433
|
-
- Click events (onClick)
|
|
434
|
-
- Focus events (onFocus/onBlur)
|
|
435
|
-
- Keyboard events (onKeyEvent)
|
|
436
|
-
- Basic gestures (tap, long press)
|
|
437
|
-
- Animation API (animateTo)
|
|
438
|
-
|
|
439
|
-
### 13.2 Interactions Needing Adjustment (30+)
|
|
440
|
-
|
|
441
|
-
Interaction features whose implementation must be adjusted:
|
|
442
|
-
- Gesture recognition (use the gesture system instead of listeners)
|
|
443
|
-
- Animation system (declarative, state-driven animation)
|
|
444
|
-
- Event dispatch (automatic vs. manual dispatch)
|
|
445
|
-
- Lifecycle (split into multiple callbacks)
|
|
446
|
-
|
|
447
|
-
### 13.3 Interactions Needing Custom Implementation (15+)
|
|
448
|
-
|
|
449
|
-
Interaction features that need custom logic or components:
|
|
450
|
-
- System drag-and-drop (custom data transfer)
|
|
451
|
-
- Advanced focus features (handled by the system)
|
|
452
|
-
- Animation pause/resume (needs state management)
|
|
453
|
-
- Multi-window interaction (not supported by the architecture)
|
|
454
|
-
|
|
455
|
-
### 13.4 API 20/21 Improvements
|
|
456
|
-
|
|
457
|
-
API 20/21 brings the following important improvements:
|
|
458
|
-
- **Touch hot-zone support**: the `responseRegion` property extends a component's response area
|
|
459
|
-
- **Enhanced touch-test control**: `HitTestMode.BLOCK_HIERARCHY`, `HitTestMode.BLOCK_DESCENDANTS`
|
|
460
|
-
- **Enhanced gesture interception**: `onGestureRecognizerJudgeBegin()`, `parallelGesture()`
|
|
461
|
-
- **Optimized event response chain**: more efficient event dispatch
|
|
462
|
-
- **stopPropagation()**: more flexible event-bubbling control
|
|
463
|
-
|
|
464
|
-
---
|
|
465
|
-
|
|
466
|
-
## 14. Migration Advice
|
|
467
|
-
|
|
468
|
-
### 14.1 Interaction Migration Priorities
|
|
469
|
-
|
|
470
|
-
1. **High priority** (fully supported):
|
|
471
|
-
- Click events, long-press events
|
|
472
|
-
- Basic gestures (tap, long press, drag)
|
|
473
|
-
- Focus events, keyboard events
|
|
474
|
-
- Basic animation
|
|
475
|
-
|
|
476
|
-
2. **Medium priority** (partially supported):
|
|
477
|
-
- Complex gestures (pinch, rotation)
|
|
478
|
-
- Event dispatch and interception
|
|
479
|
-
- Transition animation
|
|
480
|
-
- Accessibility
|
|
481
|
-
|
|
482
|
-
3. **Low priority** (not yet supported or hard):
|
|
483
|
-
- System drag-and-drop
|
|
484
|
-
- Multi-window interaction
|
|
485
|
-
- Advanced keyboard events
|
|
486
|
-
- Animation pause/resume
|
|
487
|
-
|
|
488
|
-
### 14.2 Interaction Migration Strategy
|
|
489
|
-
|
|
490
|
-
1. **Shift to declarative thinking**:
|
|
491
|
-
- Android: imperative, listeners + callbacks
|
|
492
|
-
- HarmonyOS: declarative, state + bindings
|
|
493
|
-
- Requires a change of programming paradigm
|
|
494
|
-
|
|
495
|
-
2. **Prefer the gesture system**:
|
|
496
|
-
- Prefer HarmonyOS gestures (TapGesture, PanGesture, etc.)
|
|
497
|
-
- Avoid parsing gestures by hand in onTouch
|
|
498
|
-
|
|
499
|
-
3. **State-driven animation**:
|
|
500
|
-
- Animations are triggered by state changes
|
|
501
|
-
- Manage animation state with the @State decorator
|
|
502
|
-
|
|
503
|
-
4. **Event bubbling**:
|
|
504
|
-
- Understand the HarmonyOS event-bubbling mechanism
|
|
505
|
-
- Use stopPropagation() judiciously
|
|
506
|
-
|
|
507
|
-
### 14.3 Notes
|
|
508
|
-
|
|
509
|
-
1. **Event model differences**:
|
|
510
|
-
- Android: complex event dispatch
|
|
511
|
-
- HarmonyOS: simpler gesture system
|
|
512
|
-
|
|
513
|
-
2. **Focus handling**:
|
|
514
|
-
- Android: complex focus search and management
|
|
515
|
-
- HarmonyOS: simplified focusControl API
|
|
516
|
-
|
|
517
|
-
3. **Animation architecture differences**:
|
|
518
|
-
- Android: object-based animation system
|
|
519
|
-
- HarmonyOS: state-based declarative animation
|
|
520
|
-
|
|
521
|
-
4. **Gesture recognition**:
|
|
522
|
-
- Android: GestureDetector + listeners
|
|
523
|
-
- HarmonyOS: gesture decorators + callbacks
|
|
524
|
-
|
|
525
|
-
5. **Testing focus**:
|
|
526
|
-
- Multi-touch scenarios
|
|
527
|
-
- Gesture conflict handling
|
|
528
|
-
- Performance (avoid excessive redraws)
|
|
529
|
-
|
|
530
|
-
---
|
|
531
|
-
|
|
532
|
-
## References
|
|
533
|
-
|
|
534
|
-
### Android Official Docs
|
|
535
|
-
1. **[Handle multi-touch gestures | Android Developers](https://developer.android.com/develop/ui/views/touch-and-input/gestures/multi?hl=zh-cn)**
|
|
536
|
-
2. **[Detect common gestures | Android Developers](https://developer.android.com/develop/ui/views/touch-and-input/gestures/detector?hl=zh-cn)**
|
|
537
|
-
3. **[Understand gestures | Jetpack Compose](https://android-docs.cn/develop/ui/compose/touch-input/pointer-input/understand-gestures)**
|
|
538
|
-
4. **[Manage touch events in a ViewGroup | Android Developers](https://developer.android.com/develop/ui/views/touch-and-input/gestures/viewgroup?hl=zh-cn)**
|
|
539
|
-
5. **[Property animation overview | Android Developers](https://developer.android.com/develop/ui/views/animations/prop-animation?hl=zh-cn)**
|
|
540
|
-
6. **[Overview of the official Android touch-gesture basics docs](https://www.cnblogs.com/mengdd/p/3335508.html)**
|
|
541
|
-
7. **[Introduction to the Android gesture-recognition class GestureDetector](https://developer.aliyun.com/article/569712)**
|
|
542
|
-
|
|
543
|
-
### HarmonyOS Official Docs
|
|
544
|
-
1. **[Multi-level gesture events (official docs)](https://developer.huawei.com/consumer/cn/doc/HarmonyOS-Guides/arkts-gesture-events-multi-level-gesture)**
|
|
545
|
-
2. **[Focus events](https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-universal-focus-event)**
|
|
546
|
-
3. **[Focus handling guide](https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/arkts-common-events-focus-event)**
|
|
547
|
-
4. **[Transition animation](https://developer.huawei.com/consumer/cn/doc/HarmonyOS-Guides/arkts-animation-transition)**
|
|
548
|
-
5. **[Explicit animation (animateTo)](https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-explicit-animation)**
|
|
549
|
-
6. **[onBlur/onFocus focus-event callbacks not firing](https://developer.huawei.com/consumer/cn/doc/harmonyos-faqs/faqs-arkui-165)**
|
|
550
|
-
7. **[onTouch vs. onClick event conflict FAQ](https://developer.huawei.com/consumer/cn/doc/harmonyos-faqs/faqs-arkui-174)**
|
|
551
|
-
|
|
552
|
-
### Technical Blogs and Hands-on Articles
|
|
553
|
-
1. **[A complete guide to ArkUI interaction events and gesture handling](https://blog.csdn.net/2301_79624024/article/details/147620496)** - HarmonyOS gesture handling
|
|
554
|
-
2. **[An in-depth look at the touch event mechanism](https://segmentfault.com/a/1190000047072887)** - Android touch events in detail
|
|
555
|
-
3. **[Android touch event dispatch, gesture recognition and input optimization in practice](https://juejin.cn/post/7611830146089615406)** - Event dispatch mechanism
|
|
556
|
-
4. **[Exploring the Android gesture event mechanism and optimization tips](https://juejin.cn/post/7238869983621611576)** - Gesture event mechanism
|
|
557
|
-
|
|
558
|
-
---
|
|
559
|
-
|
|
560
|
-
*This document is based on Android 14 and HarmonyOS NEXT API 20/21 (6.0.0/6.0.1); the latest official docs are authoritative for specific APIs. Mapping UI interactions involves a substantial programming-paradigm shift and the event response chain introduced in API 20/21; apply it flexibly to the concrete scenario during migration.*
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
|
|
48
48
|
| Android UI | HarmonyOS UI | Notes |
|
|
49
49
|
|-----------|---------------|---------|
|
|
50
|
-
| `layout_weight` (usually with `0dp`) | `.layoutWeight()` / `.flexGrow()` | Weight distribution. **Never translate it to `.width('100%')` / `.height('100%')`**: in ArkUI 100% is relative to the parent and is not shared among siblings, so when several siblings are all 100% the first fills the whole row and the rest are pushed out of view
|
|
50
|
+
| `layout_weight` (usually with `0dp`) | `.layoutWeight()` / `.flexGrow()` | Weight distribution. **Never translate it to `.width('100%')` / `.height('100%')`**: in ArkUI 100% is relative to the parent and is not shared among siblings, so when several siblings are all 100% the first fills the whole row and the rest are pushed out of view. Same for a `@Builder` root node. GATE `main-axis-pct-siblings` |
|
|
51
51
|
| `padding` / `margin` | `.padding()` / `.margin()` | Uniform, or per side as `{ top, right, bottom, left }` |
|
|
52
52
|
| `View.GONE` / `View.INVISIBLE` | `Visibility.None` / `Visibility.Hidden` | `None` = takes no space (GONE); `Hidden` = keeps space, not shown (INVISIBLE) |
|
|
53
53
|
| `android:id` | `.id('xxx')` / component reference variable | Component identifier |
|
|
@@ -150,7 +150,7 @@ Position and motion both differ, so when converting:
|
|
|
150
150
|
1. **Wrap the same scope as Android**: `Refresh` wraps the subtree that `SwipeRefreshLayout` wraps. When `SwipeRefreshLayout` wraps the whole `MotionLayout` (header + content), the HarmonyOS side must not wrap only the inner `Scroll` below the header. Wrapping only the inner part puts the indicator below the header and makes the content slide apart from the header while pulling.
|
|
151
151
|
2. **Gesture conflicts are not a reason to shrink the scope**: when the subtree has a collapsing header or inner scrolling, turn pulling off for those periods with `pullToRefresh(false)` (Android's `setEnabled(false)`) instead of moving `Refresh` further in.
|
|
152
152
|
3. **Indicator look and position follow the reference frames**: compare the spinner captured in screenshots or view trees (Android default: a ~40dp circle at the top center) with the `Refresh` effect. If the default does not match, customize the indicator with `builder` / `refreshingContent`, and tune trigger distance and content follow with `refreshOffset`, `pullDownRatio` (pull-down follow ratio, API 12+) and `maxPullDownDistance` (API 20+). Confirm with an on-device screenshot comparison; do not assume the result from memory.
|
|
153
|
-
4. **API mapping**: `setRefreshing(b)` → `Refresh({ refreshing: $$this.isRefreshing })`; `setOnRefreshListener` → `.onRefreshing()
|
|
153
|
+
4. **API mapping**: `setRefreshing(b)` → `Refresh({ refreshing: $$this.isRefreshing })`; `setOnRefreshListener` → `.onRefreshing()`, but the two are not equivalent: `onRefreshing` fires when the refresh state is entered (refresh.d.ts: "Called when the refresh state is entered"), including when code sets `refreshing` to true (first load, a request after the location resolves); Android `setRefreshing(true)` does not notify the listener. When the callback sends a request, record in `.onStateChange` whether the user is dragging (`RefreshStatus.Drag` / `OverDrag` set it, `Inactive` / `Done` clear it) and forward only a user pull; otherwise a code-driven refresh state sends the request again and re-enters (GATE `refresh-programmatic-reentry`); `setEnabled(b)` → `.pullToRefresh(b)`; `setColorSchemeColors` / `setProgressViewOffset` → custom `builder` + `refreshOffset`.
|
|
154
154
|
5. **Report deviations**: if indicator position or content follow genuinely cannot match, list it as a visual deviation in the report, not only in a code comment.
|
|
155
155
|
|
|
156
156
|
## Settings Page (androidx.preference) Mapping
|
|
@@ -168,12 +168,3 @@ Position and motion both differ, so when converting:
|
|
|
168
168
|
- When converting, check the left inset of category rows and item rows separately. Giving only item rows `padding({ left: 72 })` and forgetting category rows renders the category titles flush to the edge, while on Android they share the item titles' indent.
|
|
169
169
|
- Measured view-tree values win: the "text left edge" column of measure_summary groups texts with the same indent; categories and items should fall in one group. Row heights and spacing change with the theme and library version: re-measure them from each project's view tree, never reuse another project's numbers.
|
|
170
170
|
- Title, summary and category-title colors come from the theme, not the preferences XML; trust measure_summary's text colors.
|
|
171
|
-
|
|
172
|
-
## Migration Notes
|
|
173
|
-
|
|
174
|
-
1. **Paradigm shift**: Android uses imperative UI (XML layouts + Java/Kotlin manipulation); ArkUI uses declarative UI (ArkTS component tree + state-driven rendering)
|
|
175
|
-
2. **No more Adapter pattern**: `RecyclerView.Adapter`, `PagerAdapter`, etc. are replaced by `ForEach`/`LazyForEach` + `IDataSource`
|
|
176
|
-
3. **Fragment → NavDestination**: Fragment's modular-UI role maps to `Navigation` + `NavDestination` routing
|
|
177
|
-
4. **Layout attribute changes**: Android layout attributes must be converted to ArkUI chained-call syntax
|
|
178
|
-
5. **Performance**: use `LazyForEach` for lazy loading instead of rendering large data sets at once
|
|
179
|
-
6. **Responsive layout**: use `Flex` and `Grid` for responsive layouts that adapt to different screen sizes
|
|
@@ -23,6 +23,6 @@ Use the `paradigm` field of the output and pass it on as-is. The script scans `s
|
|
|
23
23
|
|
|
24
24
|
**`@Component` / `@ComponentV2` are not counted** (they are only reported in the `components` field): a stateless display-only component (e.g. `@Component struct Divider2 { build() { Divider() } }`) says nothing about which state management the project uses. If they were counted, a 0→1 project would be judged V1 again as soon as an earlier step generated a single shared display component.
|
|
25
25
|
|
|
26
|
-
**The scaffold template does not take part in the decision**: the `pages/Index.ets` that DevEco generates for a new project (the Hello World page of `struct Index`: `@Entry` + `@Component` + a single `@State message`, or the V2 template's `@ComponentV2` + `@Local message`), and the `components/MainPage.ets` that a2h-arch-generate creates in every HAR module (`struct MainPage`, no `@Entry`, likewise a single `message` state), are not business code and cannot count as evidence of an "existing V1 project". Observed in practice
|
|
26
|
+
**The scaffold template does not take part in the decision**: the `pages/Index.ets` that DevEco generates for a new project (the Hello World page of `struct Index`: `@Entry` + `@Component` + a single `@State message`, or the V2 template's `@ComponentV2` + `@Local message`), and the `components/MainPage.ets` that a2h-arch-generate creates in every HAR module (`struct MainPage`, no `@Entry`, likewise a single `message` state), are not business code and cannot count as evidence of an "existing V1 project". Observed in practice: the empty project just created by the app-migrate preflight contained only this template, was judged V1 because "`@Component` + `@State` appear", and the whole 0→1 migration was written in V1. Once the template page has been modified (extra state or decorators), it is counted as business code.
|
|
27
27
|
|
|
28
28
|
The result only decides which decorator set to use, **not which directory to read**: both branches read `_decorator-quickref.md` in this directory (V1 uses its Section 4 mapping table), and every official full doc is read through `scripts/state_doc.mjs read <key>`. Keys carry the paradigm as a prefix (`v1-*` / `v2-*` / `mix-*`), and the script guarantees that `v1-*` returns only V1 pages and `v2-*` only V2 pages.
|
|
@@ -62,7 +62,7 @@ A refused merge names the stage and missing keys; re-dispatch only those parts.
|
|
|
62
62
|
- an `nl_hints` or `view_interactions` part is done only when, in addition, `node <a2h-utg-explorer skill>/scripts/hint_check.mjs --project <Android source root> <answers path>` exits 0 (`bad=0`). Its reviewer writes every key first and then rewrites hints in place, so `complete` alone means it may still be fixing them. While `bad>0`, keep the part in the `wait` loop; do not merge, apply or stop it. If its agent ends with `bad>0`, resume it in its own session with the lines `hint_check` prints;
|
|
63
63
|
- loop on `node ./scripts/group_queue.mjs wait ${harmony_project_dir}` (plus `--job run_cycle` in Step 3.2 while it runs). It follows every reviewer bound with `review-bind` that is not done or consumed, so no `--answers` is needed for them; pass `--answers <path>` (once per path) only for an answers file you did not bind. A job exit is reported once: a later `wait --job run_cycle` does not return again for the same exit, only after a restart ends. It returns when one becomes complete (`answers_complete`), has been silent for the stall limit (`answers_silent`; counted from the file's last write, or from its bind when it has never been written; `stall_limit_min` in the output, at least 20 min and scaled up with load), or after 9 min. Give the shell call a timeout above that;
|
|
64
64
|
- on each return: a silent part, or one whose agent ended without a complete file, is resumed in its own session with its task id (Step 0.1 item 4), and re-bound at once with the same `review-bind` line, which restarts its silence clock. `answers_silent` means only "no write for the limit"; a reviewer of a few items often writes them all at the end. A resume the host answers with "sent to the running background task" was queued behind a run still in progress: that agent is alive. A resume "also goes silent" only when, after the re-bind, `wait` reports the part silent again or its agent ends without a complete file; only then answer the remaining items `unresolved` yourself. Never answer for a part whose agent is still running: it may still write correct answers after your guesses have been merged;
|
|
65
|
-
- in Step 3.2,
|
|
65
|
+
- in Step 3.2, conversion (item 5) starts only after the cycle prints `finished: true`; nothing converts between `wait` returns.
|
|
66
66
|
|
|
67
67
|
**Gate:** `audit.mjs` (run by the pipeline) prints no `SANITY:` line. The workspace must contain `utg.json`, `click_paths.json`, `ui_elements.json` and `utg.html`. Record the audit summary and `interaction_audit.json`'s unresolved counts (`ownerless` ones are a scan limitation, not a review gap).
|
|
68
68
|
### Step 3.2 — Dynamic Page Capture (full mode: `a2h-utg-explorer`)
|
|
@@ -106,8 +106,7 @@ The parent drives the `a2h-utg-explorer` skill's `run_cycle.mjs`; reviewers are
|
|
|
106
106
|
Device phases run inside the call (30+ min), so it **always** runs in the background (Step 0.1 item 3). Pass `--job run_cycle` to every `group_queue.mjs wait` while it runs; when `wait` reports `job`, read the call's JSON from the end of `.hometrans/jobs/run_cycle.log`. That JSON is written only when the call ends. While it runs, follow `$C/cycle_progress.jsonl` (one line per stage and device phase, with result and error), not process lists or `run_device.log`. Each call advances until the next stage needs answers. It prints JSON with `finished`, `covered`, `skipped`, `failed_phases`, `blocked_on` and `waiting` (per worklist, the `parts` with `worklist` / `answers` paths).
|
|
107
107
|
|
|
108
108
|
Reviews overlap (`--review overlap`, the default). A round's stages (A, B/C, D, direct launch) are extracted up front, and `waiting` lists **every** stage's parts at once. The stages still apply and run on the device in order. While `finished` is false:
|
|
109
|
-
-
|
|
110
|
-
- Dispatch one reviewer per waiting part **not already dispatched** (`reviewers.json` records them; `review-bind` each one as you dispatch it) as a Step 3.1 reviewer wave (background sub-agents). Dispatch at most `--max-agents` (10) reviewers at a time, parts of the `blocked_on` worklists first; the rest go as earlier ones complete. The prompt gives the part path, the absolute answers path and the Step 3.1 parse-check, and points to `references/architecture.md` for the schema. Reviewers rely on component trees, open at most one screenshot per item, and save answers every ~4 items. The answers file is a JSON list or `{"items": [...]}`, one row per item with its `key` copied verbatim; `answers_check.mjs` counts a row without `key` as `keyless`, never complete.
|
|
109
|
+
- Dispatch one reviewer per waiting part **not already dispatched** (`reviewers.json` records them; `review-bind` each one as you dispatch it) as a Step 3.1 reviewer wave (background sub-agents). Dispatch at most `--max-agents` (10) reviewers at a time, parts of the `blocked_on` worklists first; the rest go as earlier ones complete. The prompt gives the part path, the absolute answers path and the Step 3.1 parse-check, and points to `references/architecture.md` for the schema. Reviewers rely on component trees, open at most one screenshot per item, and save answers every ~4 items. Conversion never starves them: while the explorer is unfinished, `Q status` / `group_pass.mjs` list the parts nobody dispatched as `reviews_unbound`, and `freeSlots` holds back up to half of `--max-agents` for them. Dispatch every `reviews_unbound` part first; a capture cycle left waiting on unanswered parts never finishes, and the pages it could still have captured are converted source-only. The answers file is a JSON list or `{"items": [...]}`, one row per item with its `key` copied verbatim; `answers_check.mjs` counts a row without `key` as `keyless`, never complete.
|
|
111
110
|
- When the parts of every `blocked_on` worklist are complete (`answers_check.mjs`), a call started with `--follow-min` continues on its own; only when it has ended (the `job` reason) start `run_cycle.mjs` again the same way, even while other stages' reviewers still run. It merges, applies, runs the device phases and stops at the next stage that waits.
|
|
112
111
|
- A stage extracted early is re-extracted after the earlier stages ran. Answers to items still offered are kept (`<x>_answers.seed.json`), and items covered meanwhile are dropped. Only new items come back in `waiting` as new parts, e.g. D requirements from B/C `unreachable` answers. Dispatch reviewers for those only.
|
|
113
112
|
- A `waiting` entry with `error` names answers that do not merge (missing, duplicate or unknown keys). Find the bad part(s) with `answers_check.mjs` and resume their reviewers. The other stages go on meanwhile.
|
|
@@ -121,9 +120,10 @@ The parent drives the `a2h-utg-explorer` skill's `run_cycle.mjs`; reviewers are
|
|
|
121
120
|
- **D runs by default**, because blocked `content` / `data-state` phases hold most core pages. Its worklist is split into parts like A–C, one item per state (phases sharing the same `requires` form one item); reviewers answer each item by `key` with `verdict: "recipe"` or `"skipped"`, within D's limits (`references/architecture.md` §D): in-app steps only, ASCII text input, white-listed keys, fixture-server files added but never modified (names and recipe ids prefixed with the item key), snapshots only under `snapshot_dir`, and a positive probe before any task.
|
|
122
121
|
- Items needing a real account, an external service, another flavor or the system file picker are answered `skipped` with the reason, and reach Step 7 via `deferred_human.json`.
|
|
123
122
|
- Pass `--skip D` only when the user asked not to change app data.
|
|
124
|
-
- `run_cycle.mjs`
|
|
123
|
+
- Before anything else, `run_cycle.mjs` archives the app data the device was handed over with (`initial`, via `run-as`) and restores it at the end. After the first round it takes the first-launch base (`fresh.tar` via `run-as`). A build without `run-as` keeps the original data live-only: no `pm clear`, no fresh base, and every clear / restore is refused (`config.user_state_protected`), so pages only first-launch data shows stay uncaptured and are reported.
|
|
124
|
+
- **Stage S** (before A) compiles each phase requirement into an on-screen predicate (`predicates_worklist.json`, reviewed by `key` like A–D) and runs every state phase in a known data state its requirements hold in (`schedule_states.mjs`): a device handed over logged in with content runs those phases directly. D only builds the states no known one satisfies.
|
|
125
125
|
- The cycle repeats while a round still adds a covered node, up to `--max-rounds` (2). Round 1 runs A–D and direct launch; later rounds run direct launch only (`--later-rounds direct`, the default): later A–D rounds cost hours for few new captures. Pass `--later-rounds all` to run A–D in every round.
|
|
126
|
-
5. **Export and build the conversion set
|
|
126
|
+
5. **Export and build the conversion set once the cycle prints `finished: true`.**
|
|
127
127
|
```bash
|
|
128
128
|
node <this skill>/scripts/export_ui_info.mjs $C --static-ws $S --out <ui_info_root>
|
|
129
129
|
node <this skill>/scripts/build_conversion_set.mjs $S --ui-info <ui_info_root>
|
|
@@ -134,16 +134,7 @@ The parent drives the `a2h-utg-explorer` skill's `run_cycle.mjs`; reviewers are
|
|
|
134
134
|
- writes one `page_NNNN_<Name>/meta.json` per uncaptured page (`evidence_tier: "source-only"`, empty `screenshots`/`view_xmls`, plus `source_hints` / `attached_nodes` / `reached_from` / `navigates_to` / `template_pages`);
|
|
135
135
|
- writes `pages.json` with captured pages first, then source-only pages in click-path order.
|
|
136
136
|
|
|
137
|
-
**Convert
|
|
138
|
-
- check Step 2: while `.hometrans/work/resources.report.md` does not exist yet, skip the rest of this list and dispatch the reviewers. Never wait on it here;
|
|
139
|
-
- run the two commands above, with `--exploring` on the builder;
|
|
140
|
-
- the first time only: run Step 4.4's `shell_contract.mjs` (it needs `utg.json`, `conversion_set.json`'s plan and Step 2's fonts, which all exist now) and Step 4.3;
|
|
141
|
-
- build Step 4.4's packs and prompts for any new group id;
|
|
142
|
-
- the first time: `group_queue.mjs init` (Step 5.4 item 2). Every time: one pass of the Step 5.4 loop (release, lease and dispatch, verify) before the next reviewer wave.
|
|
143
|
-
|
|
144
|
-
Then dispatch the reviewers. Group sub-agents and reviewers run in the background together, so the groups convert while the reviewers and the next `run_cycle.mjs` run. A single `wait` serves all of them: pass `--job run_cycle`; bound reviewers are followed without `--answers`.
|
|
145
|
-
|
|
146
|
-
When `finished` is true, run both once more **without** `--exploring`. Both scripts are incremental:
|
|
137
|
+
**Convert after the cycle finishes.** Once `run_cycle.mjs` prints `finished: true` and Step 2's report exists: run Step 4.4's `shell_contract.mjs` (it needs `utg.json`, `conversion_set.json`'s plan and Step 2's fonts, which all exist now), Step 4.3, `group_queue.mjs init` (Step 5.4 item 2), then build Step 4.4's packs and prompts for every group and enter the Step 5.4 loop. Both scripts are incremental:
|
|
147
138
|
- a page keeps its directory, and unchanged observations keep their `measure_pack.json`;
|
|
148
139
|
- the manifest's `new` / `changed` lists say which pages need a pack;
|
|
149
140
|
- new pages number after existing ones, and a group keeps its id (by anchor).
|
|
@@ -155,7 +146,7 @@ The parent drives the `a2h-utg-explorer` skill's `run_cycle.mjs`; reviewers are
|
|
|
155
146
|
|
|
156
147
|
The queue re-reads the plan on every call. It re-queues a group converted source-only that has since been captured, including one captured while it was running. While `plan.exploring` is true, it holds a source-only group while one of its nodes is listed in `$C/capture_pending.json`; the queue finds `$C` through `export_manifest.json`'s `campaign`. `run_cycle.mjs` rewrites that file on every pass:
|
|
157
148
|
- before the last round's direct-launch answers are in, it lists every uncovered in-scope node;
|
|
158
|
-
- after them, it lists only the nodes answered `launch`.
|
|
149
|
+
- after them, it lists only the nodes answered `launch`.
|
|
159
150
|
|
|
160
151
|
**Backfill.** A slot that no ready group can use still gets a held source-only group, fewest nodes left to capture first (`dispatch[].backfill: true`). If that group is captured later, it is redone against the capture. Without backfill, held groups can leave every slot idle for a long time. `init --no-backfill` turns this off.
|
|
161
152
|
|
|
@@ -185,7 +176,7 @@ The parent drives the `a2h-utg-explorer` skill's `run_cycle.mjs`; reviewers are
|
|
|
185
176
|
- `conversion_set.json`'s `summary`: captured / source-only / attached / skipped.
|
|
186
177
|
### Step 3.2-F — Fast hybrid capture (`capture_fast.mjs`)
|
|
187
178
|
|
|
188
|
-
Use this when the app is a WebView/uni-app shell and the explorer's task scheduler is too slow or too unstable to finish
|
|
179
|
+
Use this when the app is a WebView/uni-app shell and the explorer's task scheduler is too slow or too unstable to finish. It is a **compliant** replacement, not a shortcut:
|
|
189
180
|
|
|
190
181
|
```bash
|
|
191
182
|
node <this skill>/scripts/capture_fast.mjs <ui_info_root> --source <android_project_dir> \
|
|
@@ -197,12 +188,6 @@ For each page it jumps the route, waits until the accessibility tree is stable,
|
|
|
197
188
|
|
|
198
189
|
`--dry-run` lists the selected pages and whether the source declares a scroll container, without touching the device. `--probe-only` records the probe but leaves an overflow page `not-swept`, so the audit lists it as degraded until frames are captured.
|
|
199
190
|
|
|
200
|
-
### Step 3.2-I — Scoped capture (incremental mode's I5)
|
|
201
|
-
|
|
202
|
-
The Step 3.2 explorer cycle with three deltas, all in `./references/incremental-scope.md` I5: the campaign is planned with `plan.mjs --scope <scope.json>` (tasks, review worklists and `capture_pending.json` then cover only the scope), `run_cycle.mjs` gets `--skip D` unless the user allows app-data changes, and the builder runs with `--scope` / `--existing`. No crawler, no model key.
|
|
203
|
-
|
|
204
|
-
Install the APK first (`adb [-s <ADB_SERIAL>] install -r -t <apk_path>`); the explorer never installs it, and an install failure stops I5. Without a device, or when the user declines capture, skip the cycle and run only `build_conversion_set.mjs`: every member converts source-only.
|
|
205
|
-
|
|
206
191
|
### Step 3.3 — Confirm pages.json and coverage
|
|
207
192
|
|
|
208
193
|
`pages.json` is already written by `export_ui_info.mjs` (full mode) and rewritten by `build_conversion_set.mjs` (both modes; in incremental mode without a device it is the only writer). **Check it exists; do not regenerate it.** Only when it is missing (a pre-existing capture made by another tool, with no `export_manifest.json`), use this skill's fallback:
|
|
@@ -40,7 +40,8 @@ Index pages by Activity name. Each Activity's `BASE_UI_INFO` is its first snapsh
|
|
|
40
40
|
| `legacy_writes` | only on such per-instance groups: each per-instance write → the shared name it had before the split. An incremental run on a project converted before the split edits the existing shared file (both instances, serialised in the `entry` lane) instead of creating a parallel one. That shared file usually came from the old bug (the later instance was `verify_only`, so the file shows only the first instance's content): the group must turn it into **one page that switches by mode / instance** (the Android class's own `modes` parameter) and mount each destination with its own mode — not leave both tabs showing the same content |
|
|
41
41
|
| `supplement` | only in an incremental run whose `scope.json` is v2 with `SUP` (supplement) or `CHG` (changed behavior) work: per page, the feature, the work type and the `page_gap.mjs` missing list (or the change). The page already exists: the group pack's "Supplement only" section lists exactly what to add, and the converter edits the existing file in place — never a whole-page conversion over it, never a backup-and-overwrite |
|
|
42
42
|
| `stage` | 0 = entry group; 1 = groups with any capture; 2 = source-only |
|
|
43
|
-
| `after` | same-stage groups that must finish first (the leader of a shared base class / layout / pref-dialog family builds the shared component) |
|
|
43
|
+
| `after` | same-stage groups that must finish first (the leader of a shared base class / layout / pref-dialog / Compose shared-composable family builds the shared component) |
|
|
44
|
+
| `shared_families` | only on a family leader: the families it leads whose holders sit in more than one module (`{family, modules}`). The leader writes those components into a `common/*` HAR, never into its own feature module (`lease` adds the rule to its launch message) |
|
|
44
45
|
| `reuse_from` | families this group reuses read-only, and from which group |
|
|
45
46
|
| `overlays_owned_elsewhere` | overlays a member opens that another group converts: `{node, group, file}`. The host imports that file and never writes a copy; it waits for that group (`after` in the same stage, `waits_for` when the owner is on a lower stage) |
|
|
46
47
|
| `waits_for` | lower-stage groups this one must wait for although the stage rules would let it start: the entry group when the contract has `theme.runtime_slots`, a lower-stage overlay owner. group_queue.mjs adds them to the group's dependencies |
|
|
@@ -15,19 +15,19 @@ Every prompt instructs the agent to **load and follow `./references/conversion-p
|
|
|
15
15
|
5. `android_project_dir`, `harmony_project_dir`.
|
|
16
16
|
6. The absolute path of the mappings directory, the absolute path of the cheat sheet `references/state-mgmt/_decorator-quickref.md` (as `state_quickref`), and the `state_doc` command with absolute paths: `node <skill>/scripts/state_doc.mjs read <key> --project <harmony_project_dir>`.
|
|
17
17
|
7. **`PARADIGM`**, stated as decided, so the agent skips Phase 2.0 and loads `state_quickref` (the same file for V1 and V2; never compose its path from the paradigm). Official state-management docs are read only through `state_doc`, never from a bundled directory and never by the agent's own `devecocli docs search`. Also state that the doc directories, including the atomic component mapping, are for on-demand lookup per control/attribute, never read end-to-end.
|
|
18
|
-
8. **`ALL_MODULES`.** The agent picks the target module from `ALL_MODULES` by function: a page goes to the feature module whose name matches its function when one exists, shared utilities to a common/shared module, and the entry module (`${ui_module}`) otherwise or when uncertain. Every path the agent reports, `provide`s or the plan predicts is either ETS-relative to `${ui_module}` (`pages/A.ets`) or project-relative with its module (`features/home/src/main/ets/pages/A.ets`); `group_watch`, `group_queue`, `group_commit` and `phase5_check` resolve the second form against the module it names.
|
|
18
|
+
8. **`ALL_MODULES` and `TARGET_MODULE`.** When the group has a `module` in the plan (SKILL.md Step 4.2 module placement), the prompt states it as decided, one line `TARGET_MODULE = <module>`, plus one line `TARGET_MODULE <node> = <module>` per entry of `member_modules`, and never offers the agent a choice ("can go in …", "pick the module by function"): `group_queue` refuses such a prompt (`prompts_invalid`). The agent writes the group's files in that module, resources included. Without a `module`, the agent picks the target module from `ALL_MODULES` by function: a page goes to the feature module whose name matches its function when one exists, shared utilities to a common/shared module, and the entry module (`${ui_module}`) otherwise or when uncertain. Every path the agent reports, `provide`s or the plan predicts is either ETS-relative to `${ui_module}` (`pages/A.ets`) or project-relative with its module (`features/home/src/main/ets/pages/A.ets`); `group_watch`, `group_queue`, `group_commit` and `phase5_check` resolve the second form against the module it names.
|
|
19
19
|
9. Resource mappings: `${harmony_project_dir}/.hometrans/resource_mapping.md`.
|
|
20
20
|
10. The Step 4.4 facts: `Project Fact (...)` headings, the shell contract `.md`, `MEASUREMENT_PACK` + the `--probe` block (captured), and `SOURCE_PACK`.
|
|
21
21
|
11. **`EVIDENCE_TIER` per member**, from `meta.json`; a group can mix tiers.
|
|
22
22
|
- `REUSE_FROM` = the group's `reuse_from`: the files the leader wrote, stated **read-only** (extend by composition, never edit).
|
|
23
|
-
- `OVERLAYS_OWNED_ELSEWHERE` = the group's `overlays_owned_elsewhere`, whenever non-empty: overlays a member opens that another group converts (a shared overlay is a group of its own). The prompt says: import `<file>` from group `<group>` and mount it; never write your own copy under another name; if the file does not exist yet or lacks something this page needs, report it under `shell requests`.
|
|
23
|
+
- `OVERLAYS_OWNED_ELSEWHERE` = the group's `overlays_owned_elsewhere`, whenever non-empty: overlays a member opens that another group converts (a shared overlay is a group of its own). The prompt says: import `<file>` from group `<group>` and mount it; never write your own copy under another name; if the file does not exist yet or lacks something this page needs, report it under `shell requests`.
|
|
24
24
|
- `ATTACHED_NODES`, whenever non-empty (both tiers). Menu → the page's overflow/context menu; ui-state/mode → a state of this page; panel/embedded fragment → a component this page hosts. Mark each one **captured** (it has a `###` state in `REFERENCE_SCREENSHOTS`: convert it against those frames) or **uncaptured** (in `uncaptured[]`: convert it from its source branch per conversion-procedure.md §"source-only tier", which then applies to that node only; "the data layer is not converted yet" is never a reason to degrade it).
|
|
25
25
|
- For `source-only` members also pass `SOURCE_HINTS` (= `meta.json.source_hints`), `REACHED_FROM` / `NAVIGATES_TO`, `TEMPLATE_PAGES` + `TEMPLATE_MEASUREMENTS`, and the host-chain source file list (now the primary evidence, so resolve it before dispatch).
|
|
26
26
|
12. **`LOTTIE_ENTRIES_FOR_THIS_PAGE`**, only when `lottie_by_page[suggested_page_name]` is non-empty: the matching rows verbatim as JSON, used per Phase 4.5. Otherwise omit the block and never mention Lottie.
|
|
27
27
|
13. **`PRESENTATION` / `HOST_ACTIVITY`**, only when the group carries `presentation` in `conversion_set.json` → `plan` (the app has a shell host; otherwise omit both and say nothing about shells). State it as decided, with the host's `Shell hosts` entry from `Project Fact (Shell Contract)`:
|
|
28
28
|
- `shell-content`: the group's pages are content the shell mounts. Prompt rules: no `@Entry`; no chrome of its own (bottom nav, tabs, drawer, persistent player bar); a jump to another fragment of the same host goes through a callback parameter the shell passes in, never `router.pushUrl` and never a `console.info('TODO: navigate')` stub; only a jump to another Activity uses `router.pushUrl`; transitions follow the host's declared `transitions`, and "NOT animated" means no `pageTransition()`. Anything the shell must provide goes under `shell requests`. Phase 4.2's chrome description of the screenshot is evidence about the **shell**, not something to draw again.
|
|
29
29
|
- `shell`: the entry group. It additionally builds the shell (Step 5.5).
|
|
30
|
-
14. **`RUNTIME_THEME`**, only when the contract's `theme.runtime_slots` is non-empty. The entry group (stage 0) creates `theme.state_module` (one observable theme state per PARADIGM, each slot initialised to the Android default colour and cited, exposed through getters); every other group carries the entry group in `waits_for` (build_conversion_set.mjs, from the contract), which group_queue.mjs honours even with `overlap_entry`, so the module exists when they start. Every other group's prompt says: read those slots from that module, never `$r('app.color.<slot>')` (a compile-time resource the user's choice never reaches), and never write a theme store of your own (GATE `theme-runtime-color-static`).
|
|
30
|
+
14. **`RUNTIME_THEME`**, only when the contract's `theme.runtime_slots` is non-empty. The entry group (stage 0) creates `theme.state_module` (one observable theme state per PARADIGM, each slot initialised to the Android default colour and cited, exposed through getters); every other group carries the entry group in `waits_for` (build_conversion_set.mjs, from the contract), which group_queue.mjs honours even with `overlap_entry`, so the module exists when they start. Every other group's prompt says: read those slots from that module, never `$r('app.color.<slot>')` (a compile-time resource the user's choice never reaches), and never write a theme store of your own (GATE `theme-runtime-color-static`).
|
|
31
31
|
|
|
32
32
|
**Tier statement.** For captured pages, the prompt must state that every path in `REFERENCE_SCREENSHOTS` / `REFERENCE_VIEW_TREES` was verified by exact-path reads. It must never claim "there is no screenshot". For a source-only page it states, explicitly: "This is a source-only page: there is no screenshot and no view tree (the capture stage did not reach it; see deferred_human for why). Follow conversion-procedure.md §"Source-only Tier", and do not claim or fabricate any pixel-measured value." The tier always comes from `meta.json`, never from the agent's own Glob.
|
|
33
33
|
|
|
@@ -49,7 +49,9 @@ Every prompt instructs the agent to **load and follow `./references/conversion-p
|
|
|
49
49
|
6. **The report goes to disk; the reply is one line.** Write the group's full report (heading `## REPORT <GID>`, A-tier evidence written out, the sections and nothing more of conversion-procedure.md "Report Structure and Size") to `.hometrans/queue_logs/<GID>.report.md` the moment the group is finished. In a family batch, do this per group, before starting the next one. Then end with exactly `DONE <GID…>`. The parent verifies from the file, and its dependants start as soon as the file exists; a report returned as the reply fills the parent's context and counts as missing. `lease`'s launch message states the exact paths.
|
|
50
50
|
|
|
51
51
|
7. **A family leader builds its shared components first and provides each one.** `lease`'s launch message names the families a group leads, and only a leader's message carries this rule.
|
|
52
|
-
- Write the component (base class, shared row, pref-dialog family) before the group's own pages.
|
|
52
|
+
- Write the component (base class, shared row, pref-dialog family, Compose shared composable such as a `XxxScaffold` several screens wrap) before the group's own pages.
|
|
53
|
+
- A family listed in the leader's `shared_families` spans several feature modules: write it into a `common/*` HAR they can all depend on and export it from that HAR's `Index.ets`. A copy in one feature module forces the other modules to depend on that feature, and a copy per page lets each page translate it differently.
|
|
54
|
+
- A Compose shared composable is translated whole, once: every parameter, default and state it owns (a `ModalBottomSheet`'s `sheetState`, a scaffold's top bar padding), from its own `.kt` file. Pages pass only what the Android call site passes.
|
|
53
55
|
- Once its file path, exported names and parameter / `@Param` / `@Prop` types are final, run `node <this skill>/scripts/group_watch.mjs provide ${harmony_project_dir} --group <GID> --family "<family>" --files <files>` (ETS-relative, or module-prefixed for a feature module, Step 5.1 item 8). Its followers start then.
|
|
54
56
|
- From that point the interface is frozen. Internal fixes are allowed; a changed signature is not. If it must change, say so in the report: `release` reports every provided file changed afterwards as `provided_changed`.
|
|
55
57
|
- **Chrome shared by several `@Entry` pages is provided as a host container, not as a bare bar.** With no `shell_hosts` (each destination its own `@Entry` page), the group that writes the persistent chrome (bottom nav, tab strip, player bar) also provides the scaffold that places it: `XxxScaffold({ currentTab, onNavigate }) { @BuilderParam content }` with the `Stack({ alignContent: … })`, floating margins and `hitTestBehavior` fixed inside. Pages fill the content slot and never re-create the placement. A bar plus a usage comment leaves the placement to every page, and a page that writes `Stack()` + `.align(Alignment.Bottom)` on the bar's wrapper gets its nav floating mid-screen (GATE `stack-child-align-noop` now catches that shape; the scaffold removes it).
|
|
@@ -57,7 +59,7 @@ Every prompt instructs the agent to **load and follow `./references/conversion-p
|
|
|
57
59
|
8. **A component written into a shared module (`common/*`, the design system, `uicomponents`) follows its Android component's signature, parameter by parameter.** Any group can be the first to write one, a leader or not, and every later group reuses it as is. One wrong default here repeats on every page. Before the first page uses it, check these four points against the Android source of the component (its `@Composable fun` / custom View):
|
|
58
60
|
- **Nullable callbacks stay optional.** `onClick: (() -> Unit)? = null` becomes `@Event onClick: (() => void) | undefined = undefined`, and the node joins hit testing only when it is set. Never write an empty-function default bound unconditionally with `.onClick`: the component then takes every tap meant for a clickable parent (GATE `event-default-click-swallows-parent`).
|
|
59
61
|
- **No weight or size the source does not have.** `Modifier.weight` lives at the call site in Compose, so the component root gets no `.layoutWeight()` (GATE `layout-weight-on-shared-component-root`). Likewise no `'100%'` on an axis the source wraps.
|
|
60
|
-
- **Slots are @BuilderParam filled with @Builder content.** Callers pass `() => { this.X() }` and nothing else (GATE `builder-param-arrow-inline-component`).
|
|
62
|
+
- **Slots are @BuilderParam filled with @Builder content.** Callers pass `() => { this.X() }` and nothing else (GATE `builder-param-arrow-inline-component`). This arrow form is for a custom component's @BuilderParam only: built-in attributes (`bindSheet` / `bindContentCover` / `overlay` / `background` / `bindMenu`) take `this.X()` directly (GATE `overlay-builder-arrow-arg`).
|
|
61
63
|
- **Defaults equal the source's defaults** (padding, colors, maxLines, showDivider …), each written with its `file:line`.
|
|
62
64
|
|
|
63
65
|
Write the result in the report as one line per parameter: `<param>: Android <signature> → <ArkTS declaration>`. When the parent verifies the group, it treats a shared-module file without these lines as a missing report section.
|
|
@@ -128,6 +130,7 @@ Only true dependencies make a group wait (`after`, lane, `reuse_from`, `template
|
|
|
128
130
|
- **Queued resumes of a finished group.** Once every group of a unit is settled from its report, `release` overwrites the unit's message file with a stop notice. A resume that was queued behind the run reads it and replies `DONE` at once instead of re-running the task, which would edit the group's files while the parent verifies them. Its completion notice then releases nothing (`action: none`).
|
|
129
131
|
- **Re-running `init`** (a new parent session) keeps returned/verified results and queues groups left `running` to resume their own sessions. It also keeps every other group's session bindings: a `queued` group keeps its pending decision (a resume stays a resume), and a failed group whose session stalled resumes that session, so re-initing to change `--width` never starts a second writer.
|
|
130
132
|
3. **The loop.** One pass per parent turn, in this order, so no slot ever waits on the parent's review:
|
|
133
|
+
**One command per pass.** `node <this skill>/scripts/group_pass.mjs ${harmony_project_dir}` runs 3.1 and 3.3 and the lease half of 3.2: it releases `reported` groups, releases `stalled` units on opencode/DevEco, runs `phase5_check --group` on every `returned` group (blocking 0: `Q verified` + `group_commit.mjs`; otherwise `Q requeue` with the blocking items, `--resume` when files are missing), then `Q lease`. It prints one JSON line: `dispatch` (start each entry, then `bind` it), `stop_first` (Claude Code only: stop that task, then `Q release --unit <unit> --stalled`), `needs_human` (a group the queue cannot move: read its `hint`), and `next`. Do not write your own driver, and never sleep between passes: `Q wait` is the only wait.
|
|
131
134
|
1. **Release.** `Q reap ${harmony_project_dir}` lists `reported` groups (report file written, even mid-batch) and `stalled` units.
|
|
132
135
|
- Each reported group: `Q release ${harmony_project_dir} --unit <GID>`.
|
|
133
136
|
- Each stalled unit: Claude Code stops its task first (TaskStop); opencode/DevEco cannot, so it is not stopped. Then `Q release … --unit <unit> --stalled`.
|
|
@@ -142,6 +145,7 @@ Only true dependencies make a group wait (`after`, lane, `reuse_from`, `template
|
|
|
142
145
|
4. **What `release` decides** (no user involved):
|
|
143
146
|
- a group's written files are its predicted writes plus the `.ets` files its report names. A file named in the report counts even at another path than predicted, and even when it was written before a resume. `written` / `missing` in the row come from this;
|
|
144
147
|
- a network failure or stall resumes the same session, at most 3 attempts. A second stall of the same session fails the group (a fresh dispatch starts the count at 0), and the row carries `needs: 'human'` with a `hint`. Do not requeue it fresh while that session may be alive: resume it (`Q requeue` does so by default) or wait for its completion notice.
|
|
148
|
+
- a report that names only `.ets` files outside the predicted write set is `off-target`, not partial progress: it gets the same one narrowed redispatch, and the message names the files still owed (a resume would repeat the same answer);
|
|
145
149
|
- an empty report gets one fresh, narrowed redispatch;
|
|
146
150
|
- a finished or failed group whose members got captured is re-queued against the capture; if its session had stalled it resumes that session (never a second writer);
|
|
147
151
|
- complete/partial work becomes `returned`;
|
|
@@ -149,7 +153,9 @@ Only true dependencies make a group wait (`after`, lane, `reuse_from`, `template
|
|
|
149
153
|
- `provided_changed` (a leader changed a component after providing it): when the leader is verified, re-run `phase5_check.mjs` over every follower that reuses that family and is already `returned` / `verified`. Requeue each one that no longer matches the component, with the changed file named in `--message`.
|
|
150
154
|
- `stop_first: true` (a stall with no bound task, or `requeue --fresh`, whose `warning` names the session) means the old agent must be stopped before the fresh one is dispatched; on opencode/DevEco, where that is impossible, wait for its notice first.
|
|
151
155
|
- Batch and resumed agents run `group_watch.mjs dispatch … --groups <GID> --resume` when they (re)start a group. A re-run inside the same queue attempt counts as a resume even without the flag, so the write watermark never moves back. Agents never edit files under `.hometrans/` except their report and what the scripts write.
|
|
152
|
-
5. **When `summary.idle` is true**, nothing is `returned_unverified` and `summary.stuck` is empty, go to Step 5.5. A non-empty `stuck` means groups that will never start on their own; each lists why (`no prompt file`, `after G012 is pending`, …). Fix the cause: write the prompt, re-run the builder, or `requeue` a group. Never go on to Step 5.5 with groups left open
|
|
156
|
+
5. **When `summary.idle` is true**, nothing is `returned_unverified` and `summary.stuck` is empty, go to Step 5.5. A non-empty `stuck` means groups that will never start on their own; each lists why (`no prompt file`, `after G012 is pending`, …). Fix the cause: write the prompt, re-run the builder, or `requeue` a group. Never go on to Step 5.5 with groups left open: `Q status --assert-settled` must exit 0 first (it exits 1 and lists `open` while any group is pending, queued, running, blocked or returned). `Q status` shows the summary at any time.
|
|
157
|
+
- **Slow progress is not a reason to stop.** Elapsed time, many passes, intake retries, a long tail of groups or a "time budget" never justify ending Step 5 early, the same as the context budget never does: keep running passes, and `requeue` or fix whatever `stuck` lists. Converting the remaining groups by hand outside the queue is not a way out either. Every group left open is a page the logic stage later writes from scratch, without this skill's rules or the reference frames.
|
|
158
|
+
- **`Q stop --by user|handoff --reason "<why>"`** leases nothing new. Use it only when the user aborts the batch (`user`) or the host session hands off with groups still open (`handoff`); without `--by` / `--reason` it refuses. It records `stop` (who, why, the groups left open) in the state; `status` repeats it. After a stop, skip Steps 5.5 and 6 (their entry gate cannot pass) and go straight to Step 7: list those groups as not converted and return `"ok": false`. A later `init` (the next session, or a rerun of the node) clears the stop, keeps it as `previous_stop`, and leases the open groups again.
|
|
153
159
|
**Verifying a returned group.** Set a page `done` only when **both** of these hold:
|
|
154
160
|
- the Phase 5 evidence is in the location the output contract assigns it;
|
|
155
161
|
- the parent's own mechanical re-verification passes.
|
|
@@ -171,7 +177,7 @@ Parent-side re-verification checks the sub-agent's claims independently of its n
|
|
|
171
177
|
|
|
172
178
|
| Check | How |
|
|
173
179
|
|---|---|
|
|
174
|
-
| Lexical checks, in one call | `node ./scripts/phase5_check.mjs ${harmony_project_dir} --group <GID>` (or `--files` with what the report lists). It covers GATE for the group's files, unresolved `$r`/`$rawfile`, misnamed / missing / over-budget `EVIDENCE()`, forbidden patterns (`.position(`/`.offset(`, `` $r(` ``, V1 decorators in a V2 project) and brace balance. With `--group` it also runs `[text_color]`. That compares each measured text colour in the group's `measure_pack.json` files with the colour the matching `Text`/`Span` actually renders; `text-color-unset` / `-mismatch` block. It also runs `[icons]`: every visible ImageView in `measure_pack.json` `icon_inventory` (sampled at the drift-corrected position) needs a `// ICON: <key>` marker on its Image/SymbolGlyph line; `icon-uncovered` / `icon-omit-refused` / `icon-marker-detached` block, and `[drift]` lines mean the screenshot was captured mid-animation. Exit 1 = blocking finding; a static-checker run with no verdict (non-0/1 exit, no report, 0 files scanned) is `[static] …` and blocks too. `--group` covers the predicted writes plus every `.ets` named in the group's report and in its `provides/` markers, so a leader's shared files need no separate `--files` run |
|
|
180
|
+
| Lexical checks, in one call | `node ./scripts/phase5_check.mjs ${harmony_project_dir} --group <GID>` (or `--files` with what the report lists). It covers GATE for the group's files, unresolved `$r`/`$rawfile`, misnamed / missing / over-budget `EVIDENCE()`, forbidden patterns (`.position(`/`.offset(`, `` $r(` ``, V1 decorators in a V2 project) and brace balance. With `--group` it also runs `[text_color]`. That compares each measured text colour in the group's `measure_pack.json` files with the colour the matching `Text`/`Span` actually renders; `text-color-unset` / `-mismatch` block. It also runs `[icons]`: every visible ImageView in `measure_pack.json` `icon_inventory` (sampled at the drift-corrected position) needs a `// ICON: <key>` marker on its Image/SymbolGlyph line; `icon-uncovered` / `icon-omit-refused` / `icon-marker-detached` block, and `[drift]` lines mean the screenshot was captured mid-animation. With `--group` or `--files` it runs `[effects]` when the UTG carries overlay `host_effects`: every effect of an overlay edge touching the group (with `--files`: any converted page) needs `// EFFECT: <id>` on or up to 3 lines above its implementing statement, or `// EFFECT-OMIT: <id> — <basis>`; `overlay-effect-uncovered` / `effect-marker-detached` block (an edge whose opener is in another group is `[cand]` there). Exit 1 = blocking finding; a static-checker run with no verdict (non-0/1 exit, no report, 0 files scanned) is `[static] …` and blocks too. `--group` covers the predicted writes plus every `.ets` named in the group's report and in its `provides/` markers, so a leader's shared files need no separate `--files` run |
|
|
175
181
|
| No SDK API that does not exist | GATE `sdk-api-nonexistent` (inside the call above) must be 0. These are compile errors the lexical items cannot see.
|
|
176
182
|
| Claimed output files exist and are complete | file exists, non-trivial length, no truncated tail |
|
|
177
183
|
| Cited `file:line` really contains the claimed fact | read that exact line; never accept a citation on faith |
|
|
@@ -214,12 +220,14 @@ Pages in a shell-content group that still declare `@Entry` are fixed here (drop
|
|
|
214
220
|
|
|
215
221
|
Then wire navigation to real pages:
|
|
216
222
|
- walk `conversion_set.json`'s `page` rows and each page's `navigates_to`;
|
|
223
|
+
- an edge with `host_effects` (in `navigates_to` / `reached_from`, a captured page's `overlay_effects`, and `conversion_set.json` `overlay_effects`) also changes the host when the overlay opens or dismisses. When you move an overlay's mounting into its page, or write its trigger / onDismiss here, carry every effect with it: implement it from its `resolved` statements in the code that opens / dismisses the overlay and keep (or add) `// EFFECT: <id>` on or up to 3 lines above the implementing statement, or `// EFFECT-OMIT: <id> — <basis>`. The gate's `phase5_check --files` run checks every converted page's effects (`overlay-effect-uncovered`, `effect-marker-detached`);
|
|
224
|
+
- an `// UNWIRED: <android file:line> — <reason>` handler whose target is now converted gets its real body here, and the marker goes. Every one still left is listed in the report and carried into Step 7's Manual Follow-up TODOs;
|
|
217
225
|
- every edge whose target is a converted page gets a real `router.pushUrl` or component toggle;
|
|
218
226
|
- register each target in `main_pages.json`.
|
|
219
227
|
|
|
220
|
-
A remaining `TODO` route is legitimate only when its target is a `skip` row; cite the reason in the report. Also apply the `shell requests` the groups reported. **They come as a ledger**: the parent runs `node scripts/shell_requests.mjs collect --hp ${harmony_project_dir}` before dispatching this step and pastes its table into the prompt. The report answers every id `<GID>#<n>` on its own row with `applied`, `rejected: <reason>` or `deferred:<stage>: <reason>`. A row answered by a different request ("via unification (below)") is not an answer: say what this request asked and what now does it. `deferred` is for work another stage owns (persistence, a data-layer call); the UI-visible half is still applied here.
|
|
228
|
+
A remaining `TODO` route is legitimate only when its target is a `skip` row; cite the reason in the report. Also apply the `shell requests` the groups reported. **They come as a ledger**: the parent runs `node scripts/shell_requests.mjs collect --hp ${harmony_project_dir}` before dispatching this step and pastes its table into the prompt. The report answers every id `<GID>#<n>` on its own row with `applied`, `rejected: <reason>` or `deferred:<stage>: <reason>`. A row answered by a different request ("via unification (below)") is not an answer: say what this request asked and what now does it. `deferred` is for work another stage owns (persistence, a data-layer call); the UI-visible half is still applied here. A request that sets shell or shared **structure** state (chrome visibility, badge, drawer, selected tab, AppStorage flag) is applied with the **Android source's initial state**, never a group's mock data-state. Example: a player bar that a source-only group mocked as visible, set as the shell default, appears on a captured home page whose reference has none. A request that mocks **content data** on a shared VM/Model (list items, forecast entries) is applied when every captured page that reads the field shows it populated in its reference, and rejected otherwise. "Pages that read the field" come from the Android source: every observer / collector / binding of that field, mapped to its UTG page, not only the pages of the group that asked. Several groups may request the same field; apply it once, in the VM/Model file, with values that reproduce every reader's reference. Either way, check it against every captured host page's reference screenshot first.
|
|
221
229
|
|
|
222
|
-
**Merging duplicate implementations.** When two groups wrote the same component (same Android source, different file names), the kept file is the **union** of both, never one side taken as a whole: list each side's exported members and behaviour branches (decode, loading state, error path, parameters) and keep the working one of each. Deleting the other file needs one report line `deleted <file> → merged into <file>: <what each side had, what was kept>`.
|
|
230
|
+
**Merging duplicate implementations.** When two groups wrote the same component (same Android source, different file names), the kept file is the **union** of both, never one side taken as a whole: list each side's exported members and behaviour branches (decode, loading state, error path, parameters) and keep the working one of each. Deleting the other file needs one report line `deleted <file> → merged into <file>: <what each side had, what was kept>`.
|
|
223
231
|
|
|
224
232
|
**Theme closure.** When the contract's `theme.mode` is not `static`, wiring is where the theme takes effect, so it is done here, not left half-wired. Close each of these and list it in the report's `runtime_risks` table (`item | file:line | done / deferred:<stage>: <reason>`):
|
|
225
233
|
- every write of the theme mode (settings page, startup read) reaches `getApplicationContext().setColorMode(ConfigurationConstant.ColorMode.COLOR_MODE_DARK / _LIGHT / _NOT_SET)`;
|