@buaa_smat/hometrans 26.0.1 → 26.0.3
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 +14 -7
- package/agents/code-reviewer.md +25 -138
- package/dist/cli/index.js +4 -1
- package/dist/cli/init.js +131 -26
- package/dist/cli/uninstall.js +5 -5
- package/dist/platform/language.js +77 -0
- package/env-requirements.json +30 -5
- package/i18n/FILE-NAMES.md +9 -0
- package/i18n/agents/code-reviewer.md +364 -0
- package/i18n/agents/model-render-worker.md +38 -0
- package/i18n/agents/specgen-worker.md +18 -0
- package/i18n/commands/hometrans.md +17 -0
- package/i18n/skills/a2h-app-migrate/SKILL.md +198 -0
- package/i18n/skills/a2h-app-migrate/references/config.example.json +28 -0
- package/i18n/skills/a2h-app-migrate/references/specs.example.json +19 -0
- package/i18n/skills/a2h-app-migrate/references/stage-map.md +50 -0
- package/i18n/skills/a2h-app-migrate/references/workflow.yaml +1760 -0
- package/i18n/skills/a2h-app-migrate/scripts/check_spec_gen_done.mjs +114 -0
- package/i18n/skills/a2h-app-migrate/scripts/env_preflight.mjs +1588 -0
- package/i18n/skills/a2h-app-migrate/scripts/human_review_gate.mjs +657 -0
- package/i18n/skills/a2h-app-migrate/scripts/validate_workflow.mjs +541 -0
- package/i18n/skills/a2h-app-migrate/test/test_android_index.mjs +131 -0
- package/i18n/skills/a2h-app-migrate/test/test_arch_done.mjs +54 -0
- package/i18n/skills/a2h-app-migrate/test/test_build_fixer_contract.mjs +98 -0
- package/i18n/skills/a2h-app-migrate/test/test_config_example.mjs +42 -0
- package/i18n/skills/a2h-app-migrate/test/test_ensure_utg_snapshot.mjs +147 -0
- package/i18n/skills/a2h-app-migrate/test/test_env_requirements.mjs +698 -0
- package/i18n/skills/a2h-app-migrate/test/test_finalize.mjs +89 -0
- package/i18n/skills/a2h-app-migrate/test/test_image_probe.mjs +120 -0
- package/i18n/skills/a2h-app-migrate/test/test_interaction.mjs +122 -0
- package/i18n/skills/a2h-app-migrate/test/test_preflight_report.mjs +93 -0
- package/i18n/skills/a2h-app-migrate/test/test_resume_plan.mjs +219 -0
- package/i18n/skills/a2h-app-migrate/test/test_resume_summary.mjs +196 -0
- package/i18n/skills/a2h-app-migrate/test/test_reuse_static_utg.mjs +100 -0
- package/i18n/skills/a2h-app-migrate/test/test_run_dir.mjs +488 -0
- package/i18n/skills/a2h-app-migrate/test/test_skill_doc.mjs +144 -0
- package/i18n/skills/a2h-app-migrate/test/test_spec_gen_done.mjs +146 -0
- package/i18n/skills/a2h-app-migrate/test/test_spec_gen_gate.mjs +161 -0
- package/i18n/skills/a2h-app-migrate/test/test_specs_json_preflight.mjs +76 -0
- package/i18n/skills/a2h-app-migrate/test/test_ui_batch_gate.mjs +226 -0
- package/i18n/skills/a2h-app-migrate/test/test_user_facing_progress.mjs +43 -0
- package/i18n/skills/a2h-app-migrate/test/test_utg_static_done.mjs +171 -0
- package/i18n/skills/a2h-app-migrate/test/test_validate_workflow_bilingual.mjs +87 -0
- package/i18n/skills/a2h-arch-generate/SKILL.md +375 -0
- package/i18n/skills/a2h-arch-generate/examples/reconcile-existing-project.md +107 -0
- package/i18n/skills/a2h-arch-generate/examples/simple-conversion-backend.md +70 -0
- package/i18n/skills/a2h-arch-generate/references/arkts-mvvm-v2.md +1407 -0
- package/i18n/skills/a2h-arch-generate/references/artifact-contracts.generate.md +120 -0
- package/i18n/skills/a2h-arch-generate/references/artifact-contracts.reconcile.md +123 -0
- package/i18n/skills/a2h-arch-generate/references/bpta-layered-architecture-design.md +88 -0
- package/i18n/skills/a2h-arch-generate/references/database-schema-recovery.md +107 -0
- package/i18n/skills/a2h-arch-generate/references/existing-target-annotation.md +68 -0
- package/i18n/skills/a2h-arch-generate/references/harmony-project-inspection.md +150 -0
- package/i18n/skills/a2h-arch-generate/references/harmony-target-architecture.md +94 -0
- package/i18n/skills/a2h-arch-generate/references/homegraph-workflow.md +120 -0
- package/i18n/skills/a2h-arch-generate/references/source-baseline.md +93 -0
- package/i18n/skills/a2h-arch-generate/scripts/generate_source_baseline.mjs +360 -0
- package/i18n/skills/a2h-arch-generate/scripts/inspect_harmony_target.mjs +798 -0
- package/i18n/skills/a2h-arch-generate/scripts/lib/contract_terms.mjs +40 -0
- package/i18n/skills/a2h-arch-generate/scripts/module_create/generate.mjs +639 -0
- package/i18n/skills/a2h-arch-generate/scripts/module_create/testdata/reconcile-layer-PROJECT_DESIGN.md +47 -0
- package/i18n/skills/a2h-arch-generate/scripts/module_create/testdata/single-entry-PROJECT_DESIGN.md +15 -0
- package/i18n/skills/a2h-arch-generate/scripts/module_create/testdata/three-layer-PROJECT_DESIGN.md +36 -0
- package/i18n/skills/a2h-arch-generate/scripts/module_create/testdata/verification-report.md +150 -0
- package/i18n/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/pages.json +5 -0
- package/i18n/skills/a2h-arch-generate/scripts/tests/e2e/run_e2e.mjs +548 -0
- package/i18n/skills/a2h-arch-generate/scripts/tests/run_tests.mjs +1261 -0
- package/i18n/skills/a2h-arch-generate/scripts/tests/test_module_templates.mjs +70 -0
- package/i18n/skills/a2h-arch-generate/scripts/validate_architecture_docs.mjs +851 -0
- package/i18n/skills/a2h-arch-generate/scripts/validate_data_docs.mjs +982 -0
- package/i18n/skills/a2h-arkts-logic-coder/references/ISSUES.md +9 -0
- package/i18n/skills/a2h-arkts-logic-coder/references/code-generation.md +192 -0
- package/i18n/skills/a2h-arkts-logic-coder/references/spec-design.md +303 -0
- package/i18n/skills/a2h-arkts-logic-coder/scripts/design/move_spec_technical_reference.mjs +162 -0
- package/i18n/skills/a2h-arkts-logic-coder/scripts/design/validate_spec_design_output.mjs +298 -0
- package/i18n/skills/a2h-arkts-logic-coder/scripts/state_doc.mjs +587 -0
- package/i18n/skills/a2h-arkts-logic-coder/scripts/test_check_units.ts +149 -0
- package/i18n/skills/a2h-arkts-logic-coder/test/golden/move_design.md +18 -0
- package/i18n/skills/a2h-arkts-logic-coder/test/golden/move_design_crlf.md +18 -0
- package/i18n/skills/a2h-arkts-logic-coder/test/golden/move_spec.md +7 -0
- package/i18n/skills/a2h-arkts-logic-coder/test/golden/validate_issue_file.md +12 -0
- package/i18n/skills/a2h-arkts-logic-coder/test/golden/validate_issues.json +57 -0
- package/i18n/skills/a2h-arkts-logic-coder/test/test_spec_design_scripts.mjs +547 -0
- package/i18n/skills/a2h-arkts-logic-coder/test/test_state_doc.mjs +352 -0
- package/i18n/skills/a2h-batch-ui-align/SKILL.md +323 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/alignment.md +31 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/build.md +13 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/canvas.md +17 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/dynamics.md +27 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/geometry.md +80 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/interaction.md +22 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/resources.md +87 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/state-v1.md +29 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/state.md +14 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/widgets.md +57 -0
- package/i18n/skills/a2h-batch-ui-align/references/cards/window.md +29 -0
- package/i18n/skills/a2h-batch-ui-align/references/checker-rules.md +705 -0
- package/i18n/skills/a2h-batch-ui-align/references/conversion-procedure.md +417 -0
- package/i18n/skills/a2h-batch-ui-align/references/incremental-scope.md +139 -0
- package/i18n/skills/a2h-batch-ui-align/references/lottie-integration.md +43 -0
- package/i18n/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-atomic-component-mapping-reference.md +2549 -0
- package/i18n/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-interaction-mapping-reference.md +560 -0
- package/i18n/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-layout-mapping-reference.md +148 -0
- package/i18n/skills/a2h-batch-ui-align/references/state-mgmt/_decorator-quickref.md +220 -0
- package/i18n/skills/a2h-batch-ui-align/references/state-mgmt/_paradigm-selection.md +28 -0
- package/i18n/skills/a2h-batch-ui-align/references/step3-capture.md +216 -0
- package/i18n/skills/a2h-batch-ui-align/references/step4-prepare.md +203 -0
- package/i18n/skills/a2h-batch-ui-align/references/step5-convert.md +210 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/android_parse_fast.ts +2005 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/build_conversion_set.mjs +1748 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/databinding_analyzer_design.md +79 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/detect_paradigm.mjs +245 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/draw_coverage.mjs +264 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/export_ui_info.mjs +1787 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/gen_rule_docs.mjs +100 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/generate_pages_json.mjs +612 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/group_pack.mjs +1836 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/image_probe.mjs +405 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/measure_pack.ts +1406 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/phase5_check.mjs +1226 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/shell_contract.mjs +1220 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/state_doc.mjs +412 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/core/cli.ts +134 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/core/i18n.ts +18 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/main.ts +173 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/a11y.ts +629 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/android_immersive.ts +125 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/attr_chain.ts +67 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/block_comment_break.ts +64 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/blur_mirrored.ts +134 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/builder_call_sites.ts +242 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/builder_invokes_callback.ts +136 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/canvas.ts +255 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/color_string.ts +109 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/column_shrink.ts +154 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/constant_coordinate.ts +39 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/container_align.ts +140 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/entry_root_builtin.ts +69 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/entry_route.ts +114 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/fixed_size_safe_area.ts +103 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/format_string.ts +157 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/framework_dialog.ts +110 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/framework_picker.ts +115 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/layout_placement.ts +551 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/media_content.ts +138 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/media_tint.ts +374 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/offset_in_scroll.ts +163 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/orphan_component.ts +119 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/padding_in_size.ts +119 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/page_reachability.ts +94 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/path_commands_vp.ts +50 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/percent_height_in_scroll.ts +80 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/popup_menu.ts +137 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/r_template_string.ts +37 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/request_permission.ts +98 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/resource_as_string.ts +68 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/root_weight.ts +97 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/safe_area_clipping.ts +168 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/scroll_align.ts +75 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/scroll_delta.ts +178 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/sdk_api.ts +195 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/shared_chrome.ts +73 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/sheet_blur.ts +95 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/shell_content.ts +198 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/stack_occluding.ts +118 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/state_decorators.ts +73 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/state_name_shadows.ts +93 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/string_quote_leak.ts +73 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/surface_stroke.ts +50 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/theme_color.ts +123 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/track_getter.ts +132 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/wide_constant_width.ts +53 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/static_check/rules/window_mode.ts +67 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_a11y.test.mjs +598 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_blur.test.mjs +217 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_builder_calls.test.mjs +323 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_fidelity.test.mjs +507 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_layout_placement.test.mjs +427 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_occlusion_offset_format.test.mjs +372 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_review_fixes.test.mjs +298 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_rules.test.mjs +365 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_scroll_padding_raster.test.mjs +262 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_weight_color.test.mjs +473 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set.test.mjs +560 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/draw_coverage.test.mjs +245 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/export_ui_info.test.mjs +742 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/generate_pages_json.test.mjs +123 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/group_pack.test.mjs +363 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/image_probe.test.mjs +243 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/measure_pack.test.mjs +324 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/occlusion.test.mjs +102 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/phase5_check.test.mjs +325 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/skill_doc_contract.test.mjs +48 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/state_doc.test.mjs +387 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/static_check_registry.test.mjs +122 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/tests/text_color_diff.test.mjs +250 -0
- package/i18n/skills/a2h-batch-ui-align/scripts/text_color_diff.mjs +470 -0
- package/i18n/skills/a2h-coldstart-smoke-gate/SKILL.md +59 -0
- package/i18n/skills/a2h-dashboard-render/SKILL.md +73 -0
- package/i18n/skills/a2h-dashboard-render/references/artifact-contract.jsonc +117 -0
- package/i18n/skills/a2h-dashboard-render/references/artifact-registry-spec.md +67 -0
- package/i18n/skills/a2h-dashboard-render/references/dashboard-guide.md +91 -0
- package/i18n/skills/a2h-dashboard-render/references/dashboard.config.example.json +19 -0
- package/i18n/skills/a2h-dashboard-render/scripts/dashboard.mjs +3245 -0
- package/i18n/skills/a2h-dashboard-render/scripts/device_capture.mjs +2048 -0
- package/i18n/skills/a2h-dashboard-render/test/fixtures/page_capture/expected.json +156 -0
- package/i18n/skills/a2h-dashboard-render/test/fixtures/page_capture/hmos.json +1 -0
- package/i18n/skills/a2h-dashboard-render/test/fixtures/page_capture/list.xml +1 -0
- package/i18n/skills/a2h-dashboard-render/test/test_artifact_contract.mjs +168 -0
- package/i18n/skills/a2h-dashboard-render/test/test_dashboard_architecture.mjs +118 -0
- package/i18n/skills/a2h-dashboard-render/test/test_dashboard_build.mjs +93 -0
- package/i18n/skills/a2h-dashboard-render/test/test_dashboard_i18n.mjs +154 -0
- package/i18n/skills/a2h-dashboard-render/test/test_dashboard_node.mjs +1369 -0
- package/i18n/skills/a2h-dashboard-render/test/test_dashboard_spec_pipeline.mjs +318 -0
- package/i18n/skills/a2h-dashboard-render/test/test_dashboard_ui_pipeline.mjs +81 -0
- package/i18n/skills/a2h-dashboard-render/test/test_device_capture_env.mjs +115 -0
- package/i18n/skills/a2h-dashboard-render/test/test_device_capture_policy.mjs +411 -0
- package/i18n/skills/a2h-dashboard-render/test/test_page_capture.mjs +147 -0
- package/i18n/skills/a2h-dashboard-render/test/test_usage_readers.mjs +512 -0
- package/i18n/skills/a2h-fix-build-errors/SKILL.md +304 -0
- package/i18n/skills/a2h-fix-build-errors/references/arkts-strict-patterns.md +219 -0
- package/i18n/skills/a2h-fix-build-errors/references/rdb-entity-pattern.md +131 -0
- package/i18n/skills/a2h-module-semantic-docs/SKILL.md +227 -0
- package/i18n/skills/a2h-module-semantic-docs/test/golden/module_structure.json +187 -0
- package/i18n/skills/a2h-module-semantic-docs/test/golden/module_understanding.json +351 -0
- package/i18n/skills/a2h-module-semantic-docs/test/golden/module_update_plan.json +495 -0
- package/i18n/skills/a2h-module-semantic-docs/test/golden/project_directory_structure.json +157 -0
- package/i18n/skills/a2h-module-semantic-docs/test/test_scan_and_commit.mjs +388 -0
- package/i18n/skills/a2h-page-specgen/SKILL.md +136 -0
- package/i18n/skills/a2h-page-specgen/references/body-language.md +177 -0
- package/i18n/skills/a2h-page-specgen/references/gates.md +262 -0
- package/i18n/skills/a2h-page-specgen/references/page-inventory.md +173 -0
- package/i18n/skills/a2h-page-specgen/references/spec-template.md +207 -0
- package/i18n/skills/a2h-page-specgen/scripts/facts-build.mjs +1504 -0
- package/i18n/skills/a2h-page-specgen/scripts/footprint.mjs +1528 -0
- package/i18n/skills/a2h-page-specgen/scripts/gate.mjs +576 -0
- package/i18n/skills/a2h-page-specgen/scripts/interactions.mjs +138 -0
- package/i18n/skills/a2h-page-specgen/scripts/lib/contracts.mjs +262 -0
- package/i18n/skills/a2h-page-specgen/scripts/lib/hg.mjs +176 -0
- package/i18n/skills/a2h-page-specgen/scripts/lib/prose.mjs +248 -0
- package/i18n/skills/a2h-page-specgen/scripts/lib/reach.mjs +53 -0
- package/i18n/skills/a2h-page-specgen/scripts/prepare.mjs +506 -0
- package/i18n/skills/a2h-page-specgen/scripts/render.mjs +299 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/acceptance/acceptance.mjs +616 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/contracts.test.mjs +234 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/facts.test.mjs +1166 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/finalize.test.mjs +74 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/fixtures/facts/i18n/zh.js.txt +8 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values-b+zh+Hans/strings.xml +7 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values-zh/strings.xml +8 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/fixtures/utg/click_paths.json +28 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/footprint-resolve.test.mjs +758 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/fsx.test.mjs +32 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/gate-partial.test.mjs +54 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/gate.test.mjs +271 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/helpers.mjs +54 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/hg.test.mjs +171 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/integration.test.mjs +301 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/interactions.test.mjs +83 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/inventory.test.mjs +139 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/keys.test.mjs +774 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/plan-build.test.mjs +1011 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/prompt-tpl.test.mjs +77 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/prose.test.mjs +419 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/reach.test.mjs +93 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/recovery-e2e.test.mjs +323 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/recovery.test.mjs +546 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/render.test.mjs +511 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/submit.test.mjs +701 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/utg-io.test.mjs +90 -0
- package/i18n/skills/a2h-page-specgen/scripts/test/waker-process.test.mjs +1765 -0
- package/i18n/skills/a2h-resource-convert/SKILL.md +367 -0
- package/i18n/skills/a2h-resource-convert/references/code-vector-icon-rules.md +335 -0
- package/i18n/skills/a2h-resource-convert/references/incremental-page-migration.md +251 -0
- package/i18n/skills/a2h-resource-convert/references/lottie-conversion-rules.md +219 -0
- package/i18n/skills/a2h-resource-convert/references/resource-mapping-rules.md +493 -0
- package/i18n/skills/a2h-resource-convert/references/step4-resource-types.md +249 -0
- package/i18n/skills/a2h-resource-convert/references/step7-report-template.md +217 -0
- package/i18n/skills/a2h-resource-convert/scripts/a2h_resource_convert.ts +2532 -0
- package/i18n/skills/a2h-resource-convert/scripts/tests/docs_only_i18n.test.mjs +44 -0
- package/i18n/skills/a2h-spec-design-pipeline/SKILL.md +278 -0
- package/i18n/skills/a2h-spec-design-pipeline/references/coding-loop.md +260 -0
- package/i18n/skills/a2h-spec-design-pipeline/references/merge-queue.md +163 -0
- package/i18n/skills/a2h-spec-design-pipeline/references/scripts.md +44 -0
- package/i18n/skills/a2h-spec-design-pipeline/references/specs.example.json +19 -0
- package/i18n/skills/a2h-spec-design-pipeline/scripts/plan_groups.ts +589 -0
- package/i18n/skills/a2h-spec-design-pipeline/scripts/test_plan_groups.ts +506 -0
- package/i18n/skills/a2h-spec-generate/SKILL.md +375 -0
- package/i18n/skills/a2h-spec-generate/references/batch-mode.md +215 -0
- package/i18n/skills/a2h-spec-generate/references/delete-blast-radius.md +3 -0
- package/i18n/skills/a2h-spec-generate/references/dispatch-watchdog.md +150 -0
- package/i18n/skills/a2h-spec-generate/references/fusion-task-contract.md +184 -0
- package/i18n/skills/a2h-spec-generate/references/input-formats.md +27 -0
- package/i18n/skills/a2h-spec-generate/references/library-evidence.md +3 -0
- package/i18n/skills/a2h-spec-generate/references/method-discipline.md +64 -0
- package/i18n/skills/a2h-spec-generate/references/optional-gates.json +45 -0
- package/i18n/skills/a2h-spec-generate/references/recall-guide.md +84 -0
- package/i18n/skills/a2h-spec-generate/references/recall-terse.md +3 -0
- package/i18n/skills/a2h-spec-generate/references/recall-uniapp.md +10 -0
- package/i18n/skills/a2h-spec-generate/references/requirement-scope.md +122 -0
- package/i18n/skills/a2h-spec-generate/references/review-checklist.md +22 -0
- package/i18n/skills/a2h-spec-generate/references/spec-sample-complex.md +80 -0
- package/i18n/skills/a2h-spec-generate/references/spec-sample-transfer.md +43 -0
- package/i18n/skills/a2h-spec-generate/references/spec-samples.md +65 -0
- package/i18n/skills/a2h-spec-generate/references/specs.schema.json +85 -0
- package/i18n/skills/a2h-spec-generate/references/synthesis-rules.md +145 -0
- package/i18n/skills/a2h-spec-generate/references/transfer-file.md +5 -0
- package/i18n/skills/a2h-spec-generate/references/transfer-socket.md +5 -0
- package/i18n/skills/a2h-spec-generate/references/worker-rules.md +129 -0
- package/i18n/skills/a2h-spec-generate/scripts/check-fused-spec.mjs +702 -0
- package/i18n/skills/a2h-spec-generate/scripts/check_spec.ts +515 -0
- package/i18n/skills/a2h-spec-generate/scripts/collect-specs.mjs +727 -0
- package/i18n/skills/a2h-spec-generate/scripts/feature-stem.mjs +151 -0
- package/i18n/skills/a2h-spec-generate/scripts/parse_requirements.ts +515 -0
- package/i18n/skills/a2h-spec-generate/scripts/prepare-facts.mjs +313 -0
- package/i18n/skills/a2h-spec-generate/scripts/publish-specs.mjs +354 -0
- package/i18n/skills/a2h-spec-generate/scripts/regroup-by-page.mjs +669 -0
- package/i18n/skills/a2h-spec-generate/scripts/render-tasks.mjs +385 -0
- package/i18n/skills/a2h-spec-generate/scripts/report.mjs +136 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/analysis/graph/build.ts +2217 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/analysis/graph/component-variants.ts +845 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/analysis/names/policy.ts +572 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/analysis/names/traceability.ts +580 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/analysis/req-model/build.ts +1265 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/area-facts.ts +1057 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/behavior-seed.ts +565 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/library-evidence.ts +544 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/navigation-guard.ts +363 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/schema.ts +317 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/selfcheck.ts +707 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/spec-bindings.ts +436 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/fusion/task-contract.ts +608 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/interaction-analysis/contracts.ts +650 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/interaction-analysis/task-contract.ts +178 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/interaction-analysis/tree-sitter-adapter.ts +923 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/model/finalize.ts +912 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/model/task.ts +279 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/requirement-scope.ts +163 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/source-index/homegraph.ts +1039 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/src/validation/req-text.ts +256 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fixtures/fusion-run.ts +243 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-area-facts.test.ts +576 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-detectors.test.ts +176 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-e2e.test.ts +103 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-schema.test.ts +111 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-selfcheck.test.ts +307 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-contract.test.ts +340 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-finalize.test.ts +1857 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-navigation-guard.test.ts +262 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-prepare.test.ts +722 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-scope.test.ts +339 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-selfcheck.test.ts +1253 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/fusion-spec.test.ts +608 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/model-scope.test.ts +411 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/model-task-contract.test.ts +300 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/model-v4.test.ts +1061 -0
- package/i18n/skills/a2h-spec-generate/scripts/reqgen/test/uniapp-scanner.test.ts +159 -0
- package/i18n/skills/a2h-spec-generate/template/REQ.txt +22 -0
- package/i18n/skills/a2h-spec-generate/template/REQ.xlsx +0 -0
- package/i18n/skills/a2h-spec-generate/test/check-fused-spec.test.mjs +847 -0
- package/i18n/skills/a2h-spec-generate/test/check-spec.test.ts +415 -0
- package/i18n/skills/a2h-spec-generate/test/collect-specs.test.mjs +808 -0
- package/i18n/skills/a2h-spec-generate/test/feature-stem.test.mjs +157 -0
- package/i18n/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/components/MyCard.vue +9 -0
- package/i18n/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/feature/editor/index.vue +1 -0
- package/i18n/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/detail/index.vue +1 -0
- package/i18n/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/home/index.vue +33 -0
- package/i18n/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/settings/index.vue +1 -0
- package/i18n/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages.json +23 -0
- package/i18n/skills/a2h-spec-generate/test/inspect-uniapp.test.mjs +54 -0
- package/i18n/skills/a2h-spec-generate/test/prepare-facts.test.mjs +41 -0
- package/i18n/skills/a2h-spec-generate/test/publish-specs.test.mjs +295 -0
- package/i18n/skills/a2h-spec-generate/test/regroup-by-page.test.mjs +354 -0
- package/i18n/skills/a2h-spec-generate/test/render-tasks.test.mjs +596 -0
- package/i18n/skills/a2h-spec-generate/test/report.test.mjs +47 -0
- package/i18n/skills/a2h-utg-explorer/SKILL.md +120 -0
- package/i18n/skills/a2h-utg-explorer/references/architecture.md +279 -0
- package/i18n/skills/a2h-utg-explorer/scripts/compile_tasks.mjs +918 -0
- package/i18n/skills/a2h-utg-explorer/scripts/final_utg.mjs +446 -0
- package/i18n/skills/a2h-utg-explorer/scripts/hint_check.mjs +147 -0
- package/i18n/skills/a2h-utg-explorer/scripts/hint_source.mjs +119 -0
- package/i18n/skills/a2h-utg-explorer/scripts/recover_b.mjs +550 -0
- package/i18n/skills/a2h-utg-explorer/scripts/recover_d.mjs +380 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/attest.test.mjs +66 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/compose_identity.test.mjs +302 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/content_wait.test.mjs +207 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/direct_launch.test.mjs +130 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/final_utg.test.mjs +135 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/generalization_fixes.test.mjs +252 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/hint_check.test.mjs +129 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/interruptions.test.mjs +492 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/launch_bridge.test.mjs +199 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/overflow_prefix.test.mjs +327 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/overlay_identity.test.mjs +204 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/page_identity_tiers.test.mjs +393 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/pager_navigation.test.mjs +119 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/panel_routes.test.mjs +208 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/pipeline.test.mjs +240 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/recover_b.test.mjs +173 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/recover_d.test.mjs +280 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/robustness_fixes.test.mjs +345 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/runner_capabilities.test.mjs +194 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/semantics.test.mjs +102 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/state_ambiguity.test.mjs +92 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/twin_opener.test.mjs +119 -0
- package/i18n/skills/a2h-utg-explorer/scripts/tests/variant_strings.test.mjs +63 -0
- package/i18n/skills/a2h-utg-explorer/scripts/utg_explorer/semantics.mjs +1412 -0
- package/i18n/skills/a2h-utg-explorer/scripts/utg_explorer/task_runner.mjs +2037 -0
- package/i18n/skills/a2h-utg-static/SKILL.md +368 -0
- package/i18n/skills/a2h-utg-static/references/ui-elements-static-utg-schema.md +248 -0
- package/i18n/skills/a2h-utg-static/references/view-interactions.md +215 -0
- package/i18n/skills/a2h-utg-static/scripts/assemble.mjs +2120 -0
- package/i18n/skills/a2h-utg-static/scripts/audit.mjs +268 -0
- package/i18n/skills/a2h-utg-static/scripts/click_paths.mjs +609 -0
- package/i18n/skills/a2h-utg-static/scripts/compose_body_text.mjs +250 -0
- package/i18n/skills/a2h-utg-static/scripts/compose_titles.mjs +374 -0
- package/i18n/skills/a2h-utg-static/scripts/compose_widgets.mjs +498 -0
- package/i18n/skills/a2h-utg-static/scripts/fragment_nav.mjs +1137 -0
- package/i18n/skills/a2h-utg-static/scripts/hybrid_scope.mjs +660 -0
- package/i18n/skills/a2h-utg-static/scripts/interaction_sites.mjs +267 -0
- package/i18n/skills/a2h-utg-static/scripts/label_resolve.mjs +913 -0
- package/i18n/skills/a2h-utg-static/scripts/nl_hints.mjs +517 -0
- package/i18n/skills/a2h-utg-static/scripts/presenter_nav.mjs +490 -0
- package/i18n/skills/a2h-utg-static/scripts/static_prior.mjs +956 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/regression_matrix.mjs +1261 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_callee_string_default.mjs +30 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_chrome_tokens.mjs +60 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_commented_out_trigger.mjs +111 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_compose_res_text.mjs +108 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_compose_vm_nav.mjs +289 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_disabled_guard.mjs +42 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_drawer_panel_gesture.mjs +140 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_fresh_branch_guard.mjs +49 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_hint_language.mjs +136 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_hybrid_bundle_attribution.mjs +74 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_hybrid_bundled_pages.mjs +181 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_hybrid_scope.mjs +293 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_hybrid_title_renders.mjs +118 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_label_accessor_forms.mjs +187 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_label_source.mjs +70 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_launch_intent_guard.mjs +67 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_login_interceptor.mjs +368 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_mode_and_cb_param.mjs +172 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_module_strings.mjs +44 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_nl_hint_grammar.mjs +42 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_nl_hints_gate.mjs +85 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_nl_hints_off_path.mjs +67 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_non_gesture_step_flag.mjs +62 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_preference_widgets.mjs +48 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_read_text_crlf.mjs +41 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_sealed_dialog_state.mjs +148 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_state_specific_hop.mjs +130 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_synthetic_label_identity.mjs +51 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_template_title.mjs +61 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_ui_elements_flow_filter.mjs +110 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_uniapp_data_table.mjs +340 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_uniapp_relative_url.mjs +125 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_uniapp_source.mjs +231 -0
- package/i18n/skills/a2h-utg-static/scripts/tests/test_viewpage_nav.mjs +340 -0
- package/i18n/skills/a2h-utg-static/scripts/uniapp_nav.mjs +1351 -0
- package/i18n/skills/a2h-utg-static/scripts/uniapp_widgets.mjs +244 -0
- package/i18n/skills/a2h-utg-static/tools/convert_static_utg_to_ui_elements.ts +769 -0
- package/package.json +13 -160
- package/platforms/deveco/agents/code-reviewer.frontmatter.md +1 -1
- package/platforms/opencode/agents/code-reviewer.frontmatter.md +1 -1
- package/skills/a2h-app-migrate/SKILL.md +17 -6
- package/skills/a2h-app-migrate/references/config.example.json +1 -0
- package/skills/a2h-app-migrate/references/stage-map.md +3 -1
- package/skills/a2h-app-migrate/references/workflow.yaml +138 -47
- package/skills/a2h-app-migrate/scripts/check_spec_gen_done.mjs +1 -2
- package/skills/a2h-app-migrate/scripts/env_preflight.mjs +105 -39
- package/skills/a2h-app-migrate/scripts/human_review_gate.mjs +7 -8
- package/skills/a2h-app-migrate/scripts/ledger.mjs +17 -5
- package/skills/a2h-app-migrate/scripts/resume_plan.mjs +43 -7
- package/skills/a2h-app-migrate/scripts/run_dir.mjs +127 -41
- package/skills/a2h-app-migrate/scripts/spec_layout.mjs +2 -0
- package/skills/a2h-app-migrate/scripts/validate_workflow.mjs +38 -0
- package/skills/a2h-app-migrate/test/test_android_index.mjs +131 -0
- package/skills/a2h-app-migrate/test/test_apk_preflight.mjs +63 -0
- package/skills/a2h-app-migrate/test/test_arch_done.mjs +54 -0
- package/skills/a2h-app-migrate/test/test_build_fixer_contract.mjs +98 -0
- package/skills/a2h-app-migrate/test/test_config_example.mjs +42 -0
- package/skills/a2h-app-migrate/test/test_devecocli_docs_preflight.mjs +32 -0
- package/skills/a2h-app-migrate/test/test_ensure_utg_snapshot.mjs +147 -0
- package/skills/a2h-app-migrate/test/test_entry_guards.mjs +102 -0
- package/skills/a2h-app-migrate/test/test_env_requirements.mjs +698 -0
- package/skills/a2h-app-migrate/test/test_finalize.mjs +89 -0
- package/skills/a2h-app-migrate/test/test_gate_checkpoint.mjs +146 -0
- package/skills/a2h-app-migrate/test/test_hmos_fingerprint.mjs +68 -0
- package/skills/a2h-app-migrate/test/test_i18n_engine_mirror.mjs +51 -0
- package/skills/a2h-app-migrate/test/test_image_probe.mjs +120 -0
- package/skills/a2h-app-migrate/test/test_infer_android_root.mjs +91 -0
- package/skills/a2h-app-migrate/test/test_interaction.mjs +122 -0
- package/skills/a2h-app-migrate/test/test_json_io.mjs +32 -0
- package/skills/a2h-app-migrate/test/test_leaf_questions.mjs +111 -0
- package/skills/a2h-app-migrate/test/test_module_docs_done.mjs +53 -0
- package/skills/a2h-app-migrate/test/test_parse_args.mjs +69 -0
- package/skills/a2h-app-migrate/test/test_preflight_report.mjs +93 -0
- package/skills/a2h-app-migrate/test/test_resume_plan.mjs +219 -0
- package/skills/a2h-app-migrate/test/test_resume_summary.mjs +196 -0
- package/skills/a2h-app-migrate/test/test_reuse_static_utg.mjs +100 -0
- package/skills/a2h-app-migrate/test/test_run_dir.mjs +488 -0
- package/skills/a2h-app-migrate/test/test_skill_doc.mjs +144 -0
- package/skills/a2h-app-migrate/test/test_spec_engine_acceptance.mjs +94 -0
- package/skills/a2h-app-migrate/test/test_spec_engine_contract.mjs +147 -0
- package/skills/a2h-app-migrate/test/test_spec_gen_done.mjs +146 -0
- package/skills/a2h-app-migrate/test/test_spec_gen_gate.mjs +161 -0
- package/skills/a2h-app-migrate/test/test_spec_pipeline_done.mjs +344 -0
- package/skills/a2h-app-migrate/test/test_specs_json_preflight.mjs +76 -0
- package/skills/a2h-app-migrate/test/test_ui_batch_done.mjs +53 -0
- package/skills/a2h-app-migrate/test/test_ui_batch_gate.mjs +226 -0
- package/skills/a2h-app-migrate/test/test_uniapp_preflight.mjs +83 -0
- package/skills/a2h-app-migrate/test/test_user_facing_progress.mjs +43 -0
- package/skills/a2h-app-migrate/test/test_utg_dirs.mjs +41 -0
- package/skills/a2h-app-migrate/test/test_utg_static_done.mjs +178 -0
- package/skills/a2h-app-migrate/test/test_validate_races.mjs +50 -0
- package/skills/a2h-app-migrate/test/test_validate_workflow_bilingual.mjs +87 -0
- package/skills/a2h-arch-generate/SKILL.md +1 -1
- package/skills/a2h-arch-generate/references/database-schema-recovery.md +2 -2
- package/skills/a2h-arch-generate/references/harmony-project-inspection.md +8 -8
- package/skills/a2h-arch-generate/references/homegraph-workflow.md +15 -6
- package/skills/a2h-arch-generate/references/module-evidence-subagent.md +2 -2
- package/skills/a2h-arch-generate/references/source-baseline.md +2 -2
- package/skills/a2h-arch-generate/scripts/generate_source_baseline.mjs +35 -46
- package/skills/a2h-arch-generate/scripts/inspect_harmony_target.mjs +33 -40
- package/skills/a2h-arch-generate/scripts/module_create/generate.mjs +2 -3
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/build.gradle +11 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/src/main/AndroidManifest.xml +12 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/src/main/java/com/example/notes/MainActivity.kt +8 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/src/main/java/com/example/notes/NotesStore.kt +17 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/build.gradle +3 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/settings.gradle +1 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/AppScope/app.json5 +8 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/build-profile.json5 +14 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/common/utils/build-profile.json5 +7 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/common/utils/oh-package.json5 +1 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/common/utils/src/main/ets/utils/Format.ets +3 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/home/build-profile.json5 +7 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/home/oh-package.json5 +1 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/home/src/main/ets/pages/Home.ets +3 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/sync/build-profile.json5 +7 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/sync/oh-package.json5 +1 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/sync/src/main/ets/engine/SyncEngine.ets +3 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/hvigorfile.ts +1 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/oh-package.json5 +1 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/products/app/build-profile.json5 +7 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/products/app/oh-package.json5 +9 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/products/app/src/main/ets/pages/Index.ets +7 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/App.vue +10 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/manifest.json +6 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/pages/index/index.vue +16 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/pages.json +5 -0
- package/skills/a2h-arch-generate/scripts/tests/e2e/run_e2e.mjs +548 -0
- package/skills/a2h-arch-generate/scripts/tests/run_tests.mjs +1260 -0
- package/skills/a2h-arch-generate/scripts/tests/test_cleanup.mjs +191 -0
- package/skills/a2h-arch-generate/scripts/tests/test_console_encoding.mjs +52 -0
- package/skills/a2h-arch-generate/scripts/tests/test_git_root.mjs +34 -0
- package/skills/a2h-arch-generate/scripts/tests/test_module_templates.mjs +70 -0
- package/skills/a2h-arch-generate/scripts/tests/test_router.mjs +138 -0
- package/skills/a2h-arch-generate/scripts/validate_architecture_docs.mjs +2 -5
- package/skills/a2h-arkts-logic-coder/SKILL.md +21 -2
- package/skills/a2h-arkts-logic-coder/references/ISSUES.md +1 -0
- package/skills/a2h-arkts-logic-coder/references/code-generation.md +62 -0
- package/skills/a2h-arkts-logic-coder/references/spec-design.md +4 -0
- package/skills/a2h-arkts-logic-coder/scripts/design/validate_spec_design_output.mjs +22 -25
- package/skills/a2h-arkts-logic-coder/scripts/state_doc.mjs +583 -0
- package/skills/a2h-arkts-logic-coder/test/golden/inspect_happy.json +20 -0
- package/skills/a2h-arkts-logic-coder/test/golden/move_design.md +18 -0
- package/skills/a2h-arkts-logic-coder/test/golden/move_design_crlf.md +18 -0
- package/skills/a2h-arkts-logic-coder/test/golden/move_spec.md +7 -0
- package/skills/a2h-arkts-logic-coder/test/golden/resolve_cases.json +36 -0
- package/skills/a2h-arkts-logic-coder/test/golden/validate_issue_file.md +12 -0
- package/skills/a2h-arkts-logic-coder/test/golden/validate_issues.json +57 -0
- package/skills/a2h-arkts-logic-coder/test/test_spec_design_scripts.mjs +547 -0
- package/skills/a2h-arkts-logic-coder/test/test_state_doc.mjs +352 -0
- package/skills/a2h-batch-ui-align/SKILL.md +6 -4
- package/skills/a2h-batch-ui-align/references/cards/geometry.md +1 -1
- package/skills/a2h-batch-ui-align/references/cards/resources.md +4 -0
- package/skills/a2h-batch-ui-align/references/cards/widgets.md +22 -3
- package/skills/a2h-batch-ui-align/references/checker-rules.md +66 -3
- package/skills/a2h-batch-ui-align/references/conversion-procedure.md +45 -8
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-atomic-component-mapping-reference.md +7 -5
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-interaction-mapping-reference.md +2 -2
- package/skills/a2h-batch-ui-align/references/step4-prepare.md +4 -2
- package/skills/a2h-batch-ui-align/references/step5-convert.md +7 -5
- package/skills/a2h-batch-ui-align/scripts/android_parse_fast.ts +6 -7
- package/skills/a2h-batch-ui-align/scripts/build_conversion_set.mjs +84 -7
- package/skills/a2h-batch-ui-align/scripts/draw_coverage.mjs +264 -0
- package/skills/a2h-batch-ui-align/scripts/evidence_gate.mjs +229 -0
- package/skills/a2h-batch-ui-align/scripts/export_ui_info.mjs +1 -2
- package/skills/a2h-batch-ui-align/scripts/generate_pages_json.mjs +4 -5
- package/skills/a2h-batch-ui-align/scripts/group_pack.mjs +88 -26
- package/skills/a2h-batch-ui-align/scripts/group_queue.mjs +305 -12
- package/skills/a2h-batch-ui-align/scripts/image_probe.mjs +231 -54
- package/skills/a2h-batch-ui-align/scripts/measure_pack.ts +8 -9
- package/skills/a2h-batch-ui-align/scripts/phase5_check.mjs +18 -5
- package/skills/a2h-batch-ui-align/scripts/shell_contract.mjs +103 -3
- package/skills/a2h-batch-ui-align/scripts/static_check/core/android.ts +231 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/core/i18n.ts +1 -5
- package/skills/a2h-batch-ui-align/scripts/static_check/main.ts +14 -8
- package/skills/a2h-batch-ui-align/scripts/static_check/registry.ts +8 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/android_immersive.ts +3 -3
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/blur_mirrored.ts +2 -2
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/builder_invokes_callback.ts +84 -19
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/color_string.ts +11 -4
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/constant_coordinate.ts +2 -2
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/framework_dialog.ts +110 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/framework_picker.ts +5 -5
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/media_content.ts +2 -2
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/media_tint.ts +66 -2
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/padding_in_size.ts +119 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/popup_menu.ts +81 -8
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/scroll_delta.ts +178 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/theme_color.ts +123 -0
- package/skills/a2h-batch-ui-align/scripts/static_check/rules/window_mode.ts +2 -3
- package/skills/a2h-batch-ui-align/scripts/static_check/scan_file.ts +6 -0
- package/skills/a2h-batch-ui-align/scripts/tests/agent_cli.test.mjs +217 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_a11y.test.mjs +598 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_align_tint.test.mjs +312 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_blur.test.mjs +217 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_builder_calls.test.mjs +323 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_canvas_pct.test.mjs +312 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_fidelity.test.mjs +507 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_layout_placement.test.mjs +427 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_occlusion_offset_format.test.mjs +372 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_review_fixes.test.mjs +298 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_rule_smoke.test.mjs +235 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_rules.test.mjs +365 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_scroll_padding_raster.test.mjs +262 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_scroll_safearea.test.mjs +742 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_shell.test.mjs +91 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_theme.test.mjs +86 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_weight_color.test.mjs +473 -0
- package/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set.test.mjs +567 -0
- package/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set_scope.test.mjs +290 -0
- package/skills/a2h-batch-ui-align/scripts/tests/color_utils_asset.test.mjs +74 -0
- package/skills/a2h-batch-ui-align/scripts/tests/detect_paradigm.test.mjs +260 -0
- package/skills/a2h-batch-ui-align/scripts/tests/draw_coverage.test.mjs +244 -0
- package/skills/a2h-batch-ui-align/scripts/tests/evidence_gate.test.mjs +420 -0
- package/skills/a2h-batch-ui-align/scripts/tests/export_scroll_states.test.mjs +31 -0
- package/skills/a2h-batch-ui-align/scripts/tests/export_ui_info.test.mjs +742 -0
- package/skills/a2h-batch-ui-align/scripts/tests/generate_pages_json.test.mjs +123 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_commit.test.mjs +126 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_pack.test.mjs +363 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_queue.test.mjs +1628 -0
- package/skills/a2h-batch-ui-align/scripts/tests/group_watch.test.mjs +215 -0
- package/skills/a2h-batch-ui-align/scripts/tests/harmony_index.test.mjs +95 -0
- package/skills/a2h-batch-ui-align/scripts/tests/host_env.test.mjs +115 -0
- package/skills/a2h-batch-ui-align/scripts/tests/image_probe.test.mjs +243 -0
- package/skills/a2h-batch-ui-align/scripts/tests/measure_pack.test.mjs +324 -0
- package/skills/a2h-batch-ui-align/scripts/tests/occlusion.test.mjs +102 -0
- package/skills/a2h-batch-ui-align/scripts/tests/phase5_check.test.mjs +325 -0
- package/skills/a2h-batch-ui-align/scripts/tests/shell_contract.test.mjs +297 -0
- package/skills/a2h-batch-ui-align/scripts/tests/skill_doc_contract.test.mjs +48 -0
- package/skills/a2h-batch-ui-align/scripts/tests/state_doc.test.mjs +387 -0
- package/skills/a2h-batch-ui-align/scripts/tests/static_check_registry.test.mjs +122 -0
- package/skills/a2h-batch-ui-align/scripts/tests/test_bfs_exit.ts +49 -0
- package/skills/a2h-batch-ui-align/scripts/tests/text_color_diff.test.mjs +250 -0
- package/skills/a2h-dashboard-render/scripts/dashboard.mjs +12 -14
- package/skills/a2h-dashboard-render/scripts/device_capture.mjs +29 -30
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/broken.xml +1 -0
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/expected.json +156 -0
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/hmos.json +1 -0
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/list.xml +1 -0
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/nested_scroll.xml +1 -0
- package/skills/a2h-dashboard-render/test/test_artifact_contract.mjs +168 -0
- package/skills/a2h-dashboard-render/test/test_cli_check_registry.mjs +99 -0
- package/skills/a2h-dashboard-render/test/test_dashboard_architecture.mjs +118 -0
- package/skills/a2h-dashboard-render/test/test_dashboard_build.mjs +93 -0
- package/skills/a2h-dashboard-render/test/test_dashboard_i18n.mjs +203 -0
- package/skills/a2h-dashboard-render/test/test_dashboard_node.mjs +1369 -0
- package/skills/a2h-dashboard-render/test/test_dashboard_spec_pipeline.mjs +318 -0
- package/skills/a2h-dashboard-render/test/test_dashboard_ui_pipeline.mjs +81 -0
- package/skills/a2h-dashboard-render/test/test_device_capture_env.mjs +115 -0
- package/skills/a2h-dashboard-render/test/test_device_capture_policy.mjs +411 -0
- package/skills/a2h-dashboard-render/test/test_page_capture.mjs +147 -0
- package/skills/a2h-dashboard-render/test/test_usage_readers.mjs +512 -0
- package/skills/a2h-module-semantic-docs/test/golden/module_structure.json +187 -0
- package/skills/a2h-module-semantic-docs/test/golden/module_understanding.json +351 -0
- package/skills/a2h-module-semantic-docs/test/golden/module_update_plan.json +495 -0
- package/skills/a2h-module-semantic-docs/test/golden/project_directory_structure.json +157 -0
- package/skills/a2h-module-semantic-docs/test/test_scan_and_commit.mjs +388 -0
- package/skills/a2h-page-specgen/SKILL.md +136 -0
- package/skills/a2h-page-specgen/references/body-language.md +177 -0
- package/skills/a2h-page-specgen/references/evidence.md +70 -0
- package/skills/a2h-page-specgen/references/execution-model.md +255 -0
- package/skills/a2h-page-specgen/references/footprint-and-grouping.md +250 -0
- package/skills/a2h-page-specgen/references/gates.md +255 -0
- package/skills/a2h-page-specgen/references/page-inventory.md +173 -0
- package/skills/a2h-page-specgen/references/spec-template.md +207 -0
- package/skills/a2h-page-specgen/scripts/dispatch.mjs +209 -0
- package/skills/a2h-page-specgen/scripts/facts-build.mjs +1504 -0
- package/skills/a2h-page-specgen/scripts/finalize.mjs +422 -0
- package/skills/a2h-page-specgen/scripts/footprint.mjs +1528 -0
- package/skills/a2h-page-specgen/scripts/gate.mjs +558 -0
- package/skills/a2h-page-specgen/scripts/interactions.mjs +137 -0
- package/skills/a2h-page-specgen/scripts/inventory.mjs +269 -0
- package/skills/a2h-page-specgen/scripts/lib/contracts.mjs +255 -0
- package/skills/a2h-page-specgen/scripts/lib/deps-source.mjs +399 -0
- package/skills/a2h-page-specgen/scripts/lib/draft-store.mjs +137 -0
- package/skills/a2h-page-specgen/scripts/lib/footprint-roles.mjs +278 -0
- package/skills/a2h-page-specgen/scripts/lib/fsx.mjs +79 -0
- package/skills/a2h-page-specgen/scripts/lib/hg.mjs +175 -0
- package/skills/a2h-page-specgen/scripts/lib/ledger.mjs +355 -0
- package/skills/a2h-page-specgen/scripts/lib/prose.mjs +234 -0
- package/skills/a2h-page-specgen/scripts/lib/reach.mjs +53 -0
- package/skills/a2h-page-specgen/scripts/lib/source-text.mjs +391 -0
- package/skills/a2h-page-specgen/scripts/lib/symbols.mjs +125 -0
- package/skills/a2h-page-specgen/scripts/lib/utg-io.mjs +110 -0
- package/skills/a2h-page-specgen/scripts/lib/waker-event-store.mjs +658 -0
- package/skills/a2h-page-specgen/scripts/prepare.mjs +492 -0
- package/skills/a2h-page-specgen/scripts/render.mjs +317 -0
- package/skills/a2h-page-specgen/scripts/report.mjs +7 -0
- package/skills/a2h-page-specgen/scripts/submission.mjs +532 -0
- package/skills/a2h-page-specgen/scripts/submit.mjs +79 -0
- package/skills/a2h-page-specgen/scripts/test/acceptance/README.md +77 -0
- package/skills/a2h-page-specgen/scripts/test/acceptance/acceptance.mjs +590 -0
- package/skills/a2h-page-specgen/scripts/test/acceptance/cases.example.json +57 -0
- package/skills/a2h-page-specgen/scripts/test/contracts.test.mjs +207 -0
- package/skills/a2h-page-specgen/scripts/test/dispatch.test.mjs +258 -0
- package/skills/a2h-page-specgen/scripts/test/facts.test.mjs +1164 -0
- package/skills/a2h-page-specgen/scripts/test/finalize.test.mjs +74 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Api.kt +20 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/BothAnnotations.kt +28 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Cache.kt +7 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Comments.kt +26 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Mmkv.kt +7 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Models.kt +19 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Pair.kt +7 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Prefs.kt +9 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Room.kt +11 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Sample.kt +43 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Templates.kt +34 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/Timeouts.kt +8 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/androidTest/Helper.kt +5 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/build.gradle.kts +16 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/i18n/en.js.txt +5 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/i18n/zh.js.txt +4 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/libs.versions.toml +14 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/package.json +10 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values/strings.xml +10 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values-b+zh+Hans/strings.xml +4 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values-land/strings.xml +5 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values-night/strings.xml +5 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values-v21/strings.xml +4 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/res/values-zh/strings.xml +4 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/test/Legacy.kt +4 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts/weather.proto +11 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-container/src/AppPreferences.kt +13 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-container/src/SettingsViewModel.kt +16 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-dao/src/UserDao.kt +28 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-moko/i18n/src/commonMain/moko-resources/base/strings.xml +6 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-moko/i18n/src/commonMain/moko-resources/fil/strings.xml +6 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/res/values/arrays.xml +25 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/res/values/strings.xml +10 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/res/xml/prefs.xml +27 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/src/Api.java +19 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/src/Datastore.kt +12 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/src/Settings.java +13 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/src/forecast.js +14 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-pref/src/store.js +14 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-receiver/src/BasePreferences.kt +13 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-receiver/src/Screen.kt +14 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-receiver/src/UiPreferences.kt +8 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/facts-retrofit/src/AuthAPI.kt +26 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/AndroidManifest.xml +20 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/feature/auth/navigation/ScreenRoute.kt +8 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/pages.json +19 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/src/components/Widget.vue +11 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/src/pages/detail/detail.vue +14 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/src/pages/index/index.vue +24 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/src/store/userStore.js +11 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp/src/uni_modules/uview-ui/components/u-thing.js +5 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/fp.mkdb.mjs +144 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/hg.mkdb.mjs +94 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/src/MainFragment.java +6 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/src/ManyListeners.java +12 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/src/PlainActivity.java +3 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/utg/click_paths.json +28 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/utg/fold-chain/utg.json +12 -0
- package/skills/a2h-page-specgen/scripts/test/fixtures/utg/utg.json +34 -0
- package/skills/a2h-page-specgen/scripts/test/footprint-resolve.test.mjs +758 -0
- package/skills/a2h-page-specgen/scripts/test/footprint-roles.test.mjs +172 -0
- package/skills/a2h-page-specgen/scripts/test/fsx.test.mjs +32 -0
- package/skills/a2h-page-specgen/scripts/test/gate-partial.test.mjs +54 -0
- package/skills/a2h-page-specgen/scripts/test/gate.test.mjs +222 -0
- package/skills/a2h-page-specgen/scripts/test/helpers.mjs +54 -0
- package/skills/a2h-page-specgen/scripts/test/hg.test.mjs +171 -0
- package/skills/a2h-page-specgen/scripts/test/integration.test.mjs +301 -0
- package/skills/a2h-page-specgen/scripts/test/interactions.test.mjs +45 -0
- package/skills/a2h-page-specgen/scripts/test/inventory.test.mjs +139 -0
- package/skills/a2h-page-specgen/scripts/test/keys.test.mjs +774 -0
- package/skills/a2h-page-specgen/scripts/test/ledger.test.mjs +464 -0
- package/skills/a2h-page-specgen/scripts/test/plan-build.test.mjs +1011 -0
- package/skills/a2h-page-specgen/scripts/test/prepare-index.test.mjs +120 -0
- package/skills/a2h-page-specgen/scripts/test/prompt-tpl.test.mjs +68 -0
- package/skills/a2h-page-specgen/scripts/test/prose.test.mjs +390 -0
- package/skills/a2h-page-specgen/scripts/test/protocol-docs.test.mjs +167 -0
- package/skills/a2h-page-specgen/scripts/test/reach.test.mjs +93 -0
- package/skills/a2h-page-specgen/scripts/test/recovery-e2e.test.mjs +323 -0
- package/skills/a2h-page-specgen/scripts/test/recovery.test.mjs +546 -0
- package/skills/a2h-page-specgen/scripts/test/render.test.mjs +503 -0
- package/skills/a2h-page-specgen/scripts/test/source-text.test.mjs +181 -0
- package/skills/a2h-page-specgen/scripts/test/submit.test.mjs +701 -0
- package/skills/a2h-page-specgen/scripts/test/utg-io.test.mjs +90 -0
- package/skills/a2h-page-specgen/scripts/test/waker-event-store.test.mjs +1365 -0
- package/skills/a2h-page-specgen/scripts/test/waker-process.test.mjs +1765 -0
- package/skills/a2h-page-specgen/scripts/test/waker.test.mjs +1979 -0
- package/skills/a2h-page-specgen/scripts/test/watchdog.test.mjs +313 -0
- package/skills/a2h-page-specgen/scripts/waker.mjs +1234 -0
- package/skills/a2h-page-specgen/scripts/watchdog.mjs +298 -0
- package/skills/a2h-resource-convert/scripts/a2h_resource_convert.ts +49 -51
- package/skills/a2h-resource-convert/scripts/tests/adaptive_icon.test.mjs +182 -0
- package/skills/a2h-resource-convert/scripts/tests/app_identity.test.mjs +206 -0
- package/skills/a2h-resource-convert/scripts/tests/docs_only_i18n.test.mjs +44 -0
- package/skills/a2h-spec-design-pipeline/SKILL.md +79 -78
- package/skills/a2h-spec-design-pipeline/references/coding-loop.md +51 -12
- package/skills/a2h-spec-design-pipeline/references/execution-model.md +24 -6
- package/skills/a2h-spec-design-pipeline/references/final-report-template.md +3 -2
- package/skills/a2h-spec-design-pipeline/references/initialization.md +15 -4
- package/skills/a2h-spec-design-pipeline/references/merge-queue.md +82 -41
- package/skills/a2h-spec-design-pipeline/references/resolver-prompt.md +61 -0
- package/skills/a2h-spec-design-pipeline/references/scripts.md +19 -10
- package/skills/a2h-spec-design-pipeline/references/shared-layer.md +267 -0
- package/skills/a2h-spec-design-pipeline/references/state-and-resume.md +61 -8
- package/skills/a2h-spec-design-pipeline/references/static-defect-gate.md +62 -13
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/config/ruleMeta.json +8 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/config/ruleSet.json +8 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/http-extra-data-empty-string-cn.md +55 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/document/checker/hometrans/http-extra-data-empty-string-en.md +60 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/checker/HttpExtraDataEmptyStringCheck.js +488 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/lib/index.js +11 -0
- package/skills/a2h-spec-design-pipeline/rules/migration-rules/package.json +17 -0
- package/skills/a2h-spec-design-pipeline/scripts/branch_landed.ts +12 -38
- package/skills/a2h-spec-design-pipeline/scripts/dispatch/evidence.mjs +40 -5
- package/skills/a2h-spec-design-pipeline/scripts/dispatch/fold.mjs +18 -0
- package/skills/a2h-spec-design-pipeline/scripts/dispatch/landing.mjs +74 -0
- package/skills/a2h-spec-design-pipeline/scripts/dispatch/progress.mjs +1 -1
- package/skills/a2h-spec-design-pipeline/scripts/dispatch/wait.mjs +1 -1
- package/skills/a2h-spec-design-pipeline/scripts/dispatch/worktree.mjs +2 -2
- package/skills/a2h-spec-design-pipeline/scripts/dispatch.mjs +128 -5
- package/skills/a2h-spec-design-pipeline/scripts/ensure_wt_index.ts +98 -35
- package/skills/a2h-spec-design-pipeline/scripts/homecheck_scan.ts +218 -37
- package/skills/a2h-spec-design-pipeline/scripts/lib/shared_classes.ts +113 -0
- package/skills/a2h-spec-design-pipeline/scripts/lib/shared_docs.ts +202 -0
- package/skills/a2h-spec-design-pipeline/scripts/lib/wiring.ts +58 -0
- package/skills/a2h-spec-design-pipeline/scripts/plan_groups.ts +6 -7
- package/skills/a2h-spec-design-pipeline/scripts/resolve_wiring.ts +3 -0
- package/skills/a2h-spec-design-pipeline/scripts/resolver_prompt.ts +348 -0
- package/skills/a2h-spec-design-pipeline/scripts/scan_shared.ts +642 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_dispatch_commands.mjs +15 -5
- package/skills/a2h-spec-design-pipeline/scripts/test_dispatch_e2e.mjs +7 -2
- package/skills/a2h-spec-design-pipeline/scripts/test_dispatch_evidence.mjs +104 -1
- package/skills/a2h-spec-design-pipeline/scripts/test_dispatch_fold.mjs +24 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_dispatch_landing.mjs +394 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_dispatch_progress.mjs +24 -1
- package/skills/a2h-spec-design-pipeline/scripts/test_dispatch_wait.mjs +14 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_ensure_wt_index.ts +163 -5
- package/skills/a2h-spec-design-pipeline/scripts/test_homecheck_scan.ts +15 -7
- package/skills/a2h-spec-design-pipeline/scripts/test_resolve_wiring.ts +14 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_resolver_prompt.ts +350 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_scan_shared.ts +996 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_shared_classes.ts +80 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_shared_docs.ts +205 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_shared_layer_docs.ts +121 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_shared_layer_e2e.ts +85 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_validate_shared_manifest.ts +720 -0
- package/skills/a2h-spec-design-pipeline/scripts/test_wiring.ts +40 -0
- package/skills/a2h-spec-design-pipeline/scripts/validate_shared_manifest.ts +566 -0
- package/skills/a2h-spec-generate/SKILL.md +87 -21
- package/skills/a2h-spec-generate/references/batch-mode.md +78 -17
- package/skills/a2h-spec-generate/references/dispatch-watchdog.md +150 -0
- package/skills/a2h-spec-generate/references/fusion-task-contract.md +7 -0
- package/skills/a2h-spec-generate/references/review-checklist.md +1 -0
- package/skills/a2h-spec-generate/references/synthesis-rules.md +4 -2
- package/skills/a2h-spec-generate/references/worker-rules.md +6 -3
- package/skills/a2h-spec-generate/scripts/check-fused-spec.mjs +4 -5
- package/skills/a2h-spec-generate/scripts/check_spec.ts +145 -14
- package/skills/a2h-spec-generate/scripts/collect-specs.mjs +261 -19
- package/skills/a2h-spec-generate/scripts/dispatch-watch.mjs +1168 -0
- package/skills/a2h-spec-generate/scripts/feature-stem.mjs +1 -2
- package/skills/a2h-spec-generate/scripts/publish-specs.mjs +1 -2
- package/skills/a2h-spec-generate/scripts/regroup-by-page.mjs +1 -2
- package/skills/a2h-spec-generate/scripts/render-tasks.mjs +25 -46
- package/skills/a2h-spec-generate/scripts/reqgen/src/analysis/graph/build.ts +26 -27
- package/skills/a2h-spec-generate/scripts/reqgen/src/analysis/graph/component-variants.ts +3 -6
- package/skills/a2h-spec-generate/scripts/reqgen/src/analysis/names/policy.ts +31 -32
- package/skills/a2h-spec-generate/scripts/reqgen/src/analysis/names/traceability.ts +2 -3
- package/skills/a2h-spec-generate/scripts/reqgen/src/analysis/req-model/build.ts +15 -26
- package/skills/a2h-spec-generate/scripts/reqgen/src/fusion/area-facts.ts +102 -81
- package/skills/a2h-spec-generate/scripts/reqgen/src/fusion/behavior-seed.ts +39 -19
- package/skills/a2h-spec-generate/scripts/reqgen/src/fusion/library-evidence.ts +12 -13
- package/skills/a2h-spec-generate/scripts/reqgen/src/fusion/navigation-guard.ts +363 -0
- package/skills/a2h-spec-generate/scripts/reqgen/src/fusion/task-contract.ts +35 -196
- package/skills/a2h-spec-generate/scripts/reqgen/src/interaction-analysis/contracts.ts +3 -1
- package/skills/a2h-spec-generate/scripts/reqgen/src/interaction-analysis/task-contract.ts +22 -96
- package/skills/a2h-spec-generate/scripts/reqgen/src/interaction-analysis/tree-sitter-adapter.ts +3 -4
- package/skills/a2h-spec-generate/scripts/reqgen/src/model/contracts.ts +1 -1
- package/skills/a2h-spec-generate/scripts/reqgen/src/model/finalize.ts +74 -7
- package/skills/a2h-spec-generate/scripts/reqgen/src/model/prepare.ts +51 -7
- package/skills/a2h-spec-generate/scripts/reqgen/src/model/task.ts +42 -111
- package/skills/a2h-spec-generate/scripts/reqgen/src/requirement-scope.ts +1 -20
- package/skills/a2h-spec-generate/scripts/reqgen/src/source-index/homegraph.ts +1 -2
- package/skills/a2h-spec-generate/scripts/reqgen/src/validation/req-text.ts +3 -4
- package/skills/a2h-spec-generate/scripts/reqgen/test/control-fact-join.test.ts +50 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/control-name-uniapp.test.ts +75 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/cross-area-anchor.test.ts +256 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fixtures/fusion-run.ts +243 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fixtures/zip.ts +63 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-area-facts.test.ts +650 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-detectors.test.ts +176 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-e2e.test.ts +103 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-schema.test.ts +111 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-seed.test.ts +195 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-behavior-selfcheck.test.ts +307 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-contract.test.ts +347 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-finalize.test.ts +1948 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-library-evidence.test.ts +239 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-navigation-guard.test.ts +277 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-prepare.test.ts +844 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-scope.test.ts +339 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-selfcheck.test.ts +1253 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/fusion-spec.test.ts +608 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/model-cli-blockers.test.ts +117 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/model-scope.test.ts +411 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/model-seeds.test.ts +175 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/model-task-contract.test.ts +300 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/model-v4.test.ts +1061 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/specgen-completeness.test.ts +286 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/stagem-stored-path.test.ts +25 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/uniapp-scanner.test.ts +159 -0
- package/skills/a2h-spec-generate/scripts/reqgen/test/zip.test.ts +61 -0
- package/skills/a2h-spec-generate/test/check-fused-spec.test.mjs +879 -0
- package/skills/a2h-spec-generate/test/check-spec.test.ts +430 -0
- package/skills/a2h-spec-generate/test/collect-specs.test.mjs +811 -0
- package/skills/a2h-spec-generate/test/detect-project.test.mjs +37 -0
- package/skills/a2h-spec-generate/test/dispatch-watch.test.mjs +606 -0
- package/skills/a2h-spec-generate/test/ensure-index.test.mjs +230 -0
- package/skills/a2h-spec-generate/test/feature-stem.test.mjs +157 -0
- package/skills/a2h-spec-generate/test/fixtures/android/app/src/main/AndroidManifest.xml +3 -0
- package/skills/a2h-spec-generate/test/fixtures/android/build.gradle +3 -0
- package/skills/a2h-spec-generate/test/fixtures/android/settings.gradle +3 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/package.json +9 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/App.vue +8 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/components/MyCard.vue +9 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/feature/editor/index.vue +1 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/main.ts +6 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/manifest.json +4 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/detail/index.vue +1 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/home/index.vue +33 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/settings/index.vue +1 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages.json +23 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/services/items.ts +3 -0
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/tsconfig.json +8 -0
- package/skills/a2h-spec-generate/test/fixtures/unknown/README.txt +1 -0
- package/skills/a2h-spec-generate/test/inspect-uniapp.test.mjs +54 -0
- package/skills/a2h-spec-generate/test/prepare-facts.test.mjs +41 -0
- package/skills/a2h-spec-generate/test/publication-verdict.test.mjs +182 -0
- package/skills/a2h-spec-generate/test/publish-specs.test.mjs +295 -0
- package/skills/a2h-spec-generate/test/regroup-by-page.test.mjs +354 -0
- package/skills/a2h-spec-generate/test/render-tasks.test.mjs +596 -0
- package/skills/a2h-spec-generate/test/report.test.mjs +47 -0
- package/skills/a2h-utg-explorer/references/architecture.md +4 -0
- package/skills/a2h-utg-explorer/scripts/compile_tasks.mjs +64 -80
- package/skills/a2h-utg-explorer/scripts/hint_check.mjs +1 -2
- package/skills/a2h-utg-explorer/scripts/recover.mjs +1 -1
- package/skills/a2h-utg-explorer/scripts/rejudge.mjs +5 -3
- package/skills/a2h-utg-explorer/scripts/tests/attest.test.mjs +66 -0
- package/skills/a2h-utg-explorer/scripts/tests/calendar_round_fixes.test.mjs +244 -0
- package/skills/a2h-utg-explorer/scripts/tests/chain.test.mjs +45 -0
- package/skills/a2h-utg-explorer/scripts/tests/compose_identity.test.mjs +302 -0
- package/skills/a2h-utg-explorer/scripts/tests/content_wait.test.mjs +207 -0
- package/skills/a2h-utg-explorer/scripts/tests/coverage_rules.test.mjs +104 -0
- package/skills/a2h-utg-explorer/scripts/tests/d_prereqs.test.mjs +231 -0
- package/skills/a2h-utg-explorer/scripts/tests/device_health.test.mjs +160 -0
- package/skills/a2h-utg-explorer/scripts/tests/device_locale_identity.test.mjs +77 -0
- package/skills/a2h-utg-explorer/scripts/tests/device_lock_retry.test.mjs +187 -0
- package/skills/a2h-utg-explorer/scripts/tests/direct_launch.test.mjs +130 -0
- package/skills/a2h-utg-explorer/scripts/tests/explorer_review_fixes.test.mjs +137 -0
- package/skills/a2h-utg-explorer/scripts/tests/final_utg.test.mjs +135 -0
- package/skills/a2h-utg-explorer/scripts/tests/first_round_phases.test.mjs +16 -0
- package/skills/a2h-utg-explorer/scripts/tests/fresh_state_plan.test.mjs +78 -0
- package/skills/a2h-utg-explorer/scripts/tests/generalization_fixes.test.mjs +252 -0
- package/skills/a2h-utg-explorer/scripts/tests/hint_check.test.mjs +129 -0
- package/skills/a2h-utg-explorer/scripts/tests/holds_without_data_parity.test.mjs +26 -0
- package/skills/a2h-utg-explorer/scripts/tests/interruptions.test.mjs +492 -0
- package/skills/a2h-utg-explorer/scripts/tests/launch_bridge.test.mjs +199 -0
- package/skills/a2h-utg-explorer/scripts/tests/launch_failure.test.mjs +40 -0
- package/skills/a2h-utg-explorer/scripts/tests/node_coverage.test.mjs +193 -0
- package/skills/a2h-utg-explorer/scripts/tests/overflow_prefix.test.mjs +327 -0
- package/skills/a2h-utg-explorer/scripts/tests/overlay_identity.test.mjs +204 -0
- package/skills/a2h-utg-explorer/scripts/tests/page_identity_tiers.test.mjs +393 -0
- package/skills/a2h-utg-explorer/scripts/tests/pager_navigation.test.mjs +119 -0
- package/skills/a2h-utg-explorer/scripts/tests/panel_routes.test.mjs +208 -0
- package/skills/a2h-utg-explorer/scripts/tests/pipeline.test.mjs +240 -0
- package/skills/a2h-utg-explorer/scripts/tests/recover.test.mjs +212 -0
- package/skills/a2h-utg-explorer/scripts/tests/recover_b.test.mjs +173 -0
- package/skills/a2h-utg-explorer/scripts/tests/recover_d.test.mjs +280 -0
- package/skills/a2h-utg-explorer/scripts/tests/review_fixes.test.mjs +213 -0
- package/skills/a2h-utg-explorer/scripts/tests/robustness_fixes.test.mjs +345 -0
- package/skills/a2h-utg-explorer/scripts/tests/run_cycle.test.mjs +454 -0
- package/skills/a2h-utg-explorer/scripts/tests/runner_capabilities.test.mjs +194 -0
- package/skills/a2h-utg-explorer/scripts/tests/scope.test.mjs +229 -0
- package/skills/a2h-utg-explorer/scripts/tests/scroll_sweep.test.mjs +336 -0
- package/skills/a2h-utg-explorer/scripts/tests/semantics.test.mjs +102 -0
- package/skills/a2h-utg-explorer/scripts/tests/snapshot_integrity.test.mjs +142 -0
- package/skills/a2h-utg-explorer/scripts/tests/state_ambiguity.test.mjs +92 -0
- package/skills/a2h-utg-explorer/scripts/tests/string_tables_twin_ties.test.mjs +83 -0
- package/skills/a2h-utg-explorer/scripts/tests/tar_fixture.mjs +12 -0
- package/skills/a2h-utg-explorer/scripts/tests/twin_opener.test.mjs +119 -0
- package/skills/a2h-utg-explorer/scripts/tests/u2_backend.test.mjs +346 -0
- package/skills/a2h-utg-explorer/scripts/tests/ui_state_anchors.test.mjs +112 -0
- package/skills/a2h-utg-explorer/scripts/tests/variant_strings.test.mjs +63 -0
- package/skills/a2h-utg-explorer/scripts/tests/worklist_parts.test.mjs +24 -0
- package/skills/a2h-utg-explorer/scripts/utg_explorer/adapters.mjs +13 -3
- package/skills/a2h-utg-explorer/scripts/utg_explorer/semantics.mjs +107 -65
- package/skills/a2h-utg-explorer/scripts/utg_explorer/strings.mjs +155 -0
- package/skills/a2h-utg-static/scripts/assemble.mjs +28 -3
- package/skills/a2h-utg-static/scripts/click_paths.mjs +19 -20
- package/skills/a2h-utg-static/scripts/compose_overlay.mjs +102 -2
- package/skills/a2h-utg-static/scripts/fragment_nav.mjs +2 -3
- package/skills/a2h-utg-static/scripts/nl_hints.mjs +2 -3
- package/skills/a2h-utg-static/scripts/presenter_nav.mjs +1 -2
- package/skills/a2h-utg-static/scripts/route_interceptor.mjs +21 -7
- package/skills/a2h-utg-static/scripts/static_prior.mjs +26 -29
- package/skills/a2h-utg-static/scripts/tests/test_activity_gates.mjs +84 -0
- package/skills/a2h-utg-static/scripts/tests/test_login_interceptor.mjs +38 -0
- package/skills/a2h-utg-static/scripts/tests/test_route_token_words.mjs +29 -1
- package/skills/a2h-app-migrate/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-app-migrate/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-arch-generate/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-arch-generate/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-arkts-logic-coder/scripts/design/i18n-term.d.mts +0 -5
- package/skills/a2h-arkts-logic-coder/scripts/design/i18n-term.mjs +0 -54
- package/skills/a2h-batch-ui-align/references/source-only-tier.md +0 -38
- package/skills/a2h-batch-ui-align/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-batch-ui-align/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-dashboard-render/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-dashboard-render/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-resource-convert/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-resource-convert/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-spec-design-pipeline/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-spec-design-pipeline/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-spec-design-pipeline/scripts/test_i18n_term.ts +0 -70
- package/skills/a2h-spec-generate/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-spec-generate/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-spec-generate/scripts/reqgen/src/i18n-term.d.mts +0 -5
- package/skills/a2h-spec-generate/scripts/reqgen/src/i18n-term.mjs +0 -54
- package/skills/a2h-utg-explorer/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-utg-explorer/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-utg-static/scripts/i18n-term.d.mts +0 -5
- package/skills/a2h-utg-static/scripts/i18n-term.mjs +0 -54
- package/skills/a2h-utg-static/scripts/tests/test_i18n_term.mjs +0 -155
|
@@ -0,0 +1,417 @@
|
|
|
1
|
+
# Single-Page Android → HarmonyOS UI Conversion Procedure
|
|
2
|
+
|
|
3
|
+
> This is the single-page conversion procedure that the `a2h-batch-ui-align` skill runs inside each sub-agent. It is adapted from the `a2h-ui-conversion-new` agent, minus Phase 6 build fixing (the parent skill does that once, centrally, at the end).
|
|
4
|
+
|
|
5
|
+
You are a **UI page converter** that migrates the UI of an Android app to HarmonyOS ArkUI (ArkTS).
|
|
6
|
+
|
|
7
|
+
## Inputs (passed in the prompt by the parent skill)
|
|
8
|
+
|
|
9
|
+
1. `activity_name` — Android Activity class name
|
|
10
|
+
2. `android_project_dir` — root of the Android source project
|
|
11
|
+
3. `ui_info` / `CURRENT_UI_INFO` — absolute path of the **current single** page directory
|
|
12
|
+
4. `BASE_UI_INFO` — base-state directory with the smallest numeric index for the same Activity; may equal the current state
|
|
13
|
+
5. `REFERENCE_SCREENSHOTS` — absolute screenshot paths that the parent skill has already read and verified via the exact paths in `meta.json`, **grouped by state** (`### <node> — <label>`): every viewport / scroll frame of this page, plus all frames of every captured attached state (mode tabs, dialogs, panels); `blocked` frames have only a view tree
|
|
14
|
+
6. `REFERENCE_VIEW_TREES` — view tree absolute paths matching the previous item frame by frame (grouped by state the same way)
|
|
15
|
+
7. `harmony_project_dir` — HarmonyOS project root
|
|
16
|
+
8. `mappings_dir` — directory holding the three mapping tables (bundled with the skill)
|
|
17
|
+
9. `state_quickref` — absolute path of the state-management cheat sheet (bundled `references/state-mgmt/_decorator-quickref.md`, shared by V1 and V2, **mandatory**)
|
|
18
|
+
10. `state_doc` — the command that reads an official state-management doc, `node <skill>/scripts/state_doc.mjs read <key> --project <harmony_project_dir>` (read live through `devecocli docs`, **deep-read on demand**; the skill no longer bundles copies of the official docs)
|
|
19
|
+
11. **[UTG]** `EVIDENCE_TIER` — `captured` | `source-only`. When it is `source-only`, items 5/6 are empty and you additionally get `SOURCE_HINTS`, `REACHED_FROM` / `NAVIGATES_TO`, `TEMPLATE_PAGES` + `TEMPLATE_MEASUREMENTS`, and the list of host-chain source files; **first read §"source-only tier" at the end of this file** — it overrides every step below that presupposes screenshots / view trees
|
|
20
|
+
12. **[UTG]** `ATTACHED_NODES` — possible in both tiers: menus / ui-states / multi-select modes / panels / embedded fragments attached to this page; **implement them inside this unit**, not as separate pages. Uncaptured ones (`uncaptured`: no `###` state of theirs in `REFERENCE_SCREENSHOTS`) are implemented per §"source-only tier" at the end of this file
|
|
21
|
+
13. `SOURCE_PACK` — this group's reading list generated by the parent skill with `group_pack.mjs` (`.hometrans/work/group_packs/<GID>.md`): absolute paths of the member / base / host / custom-view / related source files, `file:line` of style and array definitions, and every resource referenced by this group's source → its `$r('app.…')` reference + whether it already exists in the HarmonyOS project + its base/zh_CN/dark values. **Read it first, then read all member + base files not marked `**inlined**` in a single batched turn**; source files / mapping sections / style definitions marked `**inlined**` are already attached with line numbers at the end of the pack — cite their `file:line` directly and **do not read them again**. Check its resource table first for whether a resource exists and what its value is; grep only for what the table lacks. It is only a list, not a conclusion: follow the code to files outside the list as usual, and when the source you read conflicts with the list, the source wins
|
|
22
|
+
14. "Code you build on" in the launch message — export names, component parameters, public members and line numbers of the already-written HarmonyOS code this group depends on (files written and provided by `after` / `reuse_from` groups, `common/`); the equivalent index for the remaining already-written `.ets` files is in `.hometrans/work/harmony_index.md` (paged `.2.md`…). **When calling or composing existing components, treat it as authoritative; do not open component files just to see their parameters**; open them only when you need to read a function body
|
|
23
|
+
|
|
24
|
+
## Outputs
|
|
25
|
+
|
|
26
|
+
- ArkTS `.ets` pages go to `{harmony_project_dir}/entry/src/main/ets/pages/`
|
|
27
|
+
- dialog/fragment/adapter and similar components go to `.../ets/components/`
|
|
28
|
+
- ViewModels go to `.../ets/viewmodel/`, Models to `.../ets/model/`
|
|
29
|
+
- A plain-text conversion report titled `## REPORT <GID>`, **written** to `{harmony_project_dir}/.hometrans/queue_logs/<GID>.report.md` as soon as the group is finished (the exact path is in the launch message). The final reply is a single line `DONE <GID…>`; do not send the report itself as the reply. The parent skill reviews from that file; groups that depend on this one start as soon as the file appears.
|
|
30
|
+
|
|
31
|
+
## Phase 1 — Locate the page
|
|
32
|
+
|
|
33
|
+
`CURRENT_UI_INFO` is the UI page you are converting.
|
|
34
|
+
|
|
35
|
+
**[UTG]** Check `EVIDENCE_TIER` first. With `source-only` this page has no screenshots/view trees at all; that is because the capture phase never reached the page, not a read failure — do not Glob for screenshots and do not report "missing reference". Follow §"source-only tier" at the end of this file.
|
|
36
|
+
|
|
37
|
+
## Phase 2 — Detect the project paradigm + load the MVVM references
|
|
38
|
+
|
|
39
|
+
### 2.0 Detect whether the target project uses V1 or V2 (do this first; it decides which docs to read)
|
|
40
|
+
|
|
41
|
+
> **If the prompt already provides `PARADIGM = V1|V2` (decided by the parent flow), skip this whole section** and go straight to 2.1 with that conclusion.
|
|
42
|
+
> The decision is **project-wide**: pages in the same project cannot reach different conclusions, so re-detecting is pure redundancy.
|
|
43
|
+
|
|
44
|
+
Only when the prompt does not provide `PARADIGM`, run `node <skill>/scripts/detect_paradigm.mjs <harmony_project_dir>` (`<skill>` = this skill's root, i.e. the `a2h-batch-ui-align/` directory containing `SKILL.md`; rules in `<skill>/references/state-mgmt/_paradigm-selection.md`) once against `{harmony_project_dir}` (empty project / 0→1 defaults to V2; the DevEco scaffold Hello World page does not count as existing V1 code). It outputs `paradigm = V1 | V2`, and Phase 4 chooses decorators from it throughout. V1 and V2 are **never mixed in the same project**.
|
|
45
|
+
|
|
46
|
+
### 2.1 Load the MVVM docs for that paradigm (**cheat sheet first, full docs deep-read on demand**)
|
|
47
|
+
|
|
48
|
+
> **Loading strategy (mandatory; it directly determines run time)**: the official state-management docs total about 20,000 lines of the **official API manual**
|
|
49
|
+
> (including tutorials and edge cases), whereas this Phase really only needs "which decorator for which scenario + minimal syntax".
|
|
50
|
+
> So: **read only the cheat sheet first**, and read **that one doc** with `{state_doc}` only when the cheat sheet explicitly points to a deep read, or when you hit an edge case
|
|
51
|
+
> the cheat sheet does not cover. The cheat sheet's "Deep read" columns give keys (e.g. `v2-monitor`, `v1-track`),
|
|
52
|
+
> not file names; `state_doc.mjs list` prints every key.
|
|
53
|
+
>
|
|
54
|
+
> **Read only through `{state_doc}`; never run `devecocli docs search` / `docs read` yourself**: search results mix in FAQs, error-code pages
|
|
55
|
+
> and the same-named page of the other paradigm (the top 10 results for "Track decorator" include a V2 `@ObservedV2` FAQ), and picking freely is exactly how V1/V2 docs get mixed;
|
|
56
|
+
> the script resolves by slug + paradigm path, so `v1-*` returns only V1 pages and `v2-*` only V2 pages. When the script reports `unresolved` /
|
|
57
|
+
> `unparseable` / `devecocli not found`, or the prompt states `STATE_DOCS=unavailable`, copy the message into the report's "Open issues" and carry on from the cheat sheet;
|
|
58
|
+
> do **not** fall back to APIs from memory. Docs marked "mandatory" below are then replaced by the matching cheat-sheet sections (`v1-track` → the last two rows of Section 3 + Section 4's V1 minimal syntax), and the report says so.
|
|
59
|
+
|
|
60
|
+
**If the result is V2** (the default branch):
|
|
61
|
+
1. Read `{state_quickref}` — the **only mandatory read**. It covers the selection criteria for every V2 decorator,
|
|
62
|
+
minimal syntax and a list of frequent mistakes; for a normal page conversion you can proceed to Phase 3 after it.
|
|
63
|
+
2. Only in the following cases, read **the one matching doc** with `{state_doc}` (the "Deep read" column of each cheat-sheet row gives the key; read only `v2-*`):
|
|
64
|
+
- the cheat sheet's selection table / mistake table does not cover your scenario;
|
|
65
|
+
- you need the decorator's full constraints (e.g. the multi-path/deep-path semantics of `@Monitor`, `PersistenceV2`'s
|
|
66
|
+
serialization limits and capacity constraints, the same-name shadowing and lookup rules of `@Provider`/`@Consumer`);
|
|
67
|
+
- a compile/render error related to state management appears and you need to verify API details.
|
|
68
|
+
|
|
69
|
+
**If the result is V1** (an existing V1 project), follow the same "deep-read on demand" rule: read `{state_quickref}`'s **Section 1, the selection table** +
|
|
70
|
+
**Section 4, the V1↔V2 mapping** (to turn the choice into a V1 decorator) + **the last two rows of Section 3, the frequent-mistake table
|
|
71
|
+
(V1-specific pitfalls)**, then read the `v1-*` keys from Section 4's "V1 deep read" column with `{state_doc}` on demand. **If this run adds new code to an existing V1 project**, you must read
|
|
72
|
+
`{state_doc} mix-usage` (`mix-usage-pre19` when the project targets API below 19) to confirm you do not trigger mixing.
|
|
73
|
+
|
|
74
|
+
> **Mandatory-read exception on the V1 branch**: if this run **writes or modifies any `@Observed` class** (VM / Model),
|
|
75
|
+
> then `{state_doc} v1-track` **is mandatory, no longer on demand**.
|
|
76
|
+
> Reasons (all-or-nothing semantics, V1 has no `@Computed`, a bare `get x()` crashes on the first frame) are in the V1 part of Phase 5 "Missing Observation Decorators".
|
|
77
|
+
> Why this exception exists: lazy loading saves **repeated** reading; it must not skip the **only** document that records a hard constraint.
|
|
78
|
+
|
|
79
|
+
A key's prefix is its paradigm: the V2 branch reads only `v2-*`, the V1 branch only `v1-*`; `mix-*` is read **only** when locally extending a V1 project, and the V2 branch does not read it. In the report's "Reference input evidence", list the keys actually read, not file paths.
|
|
80
|
+
|
|
81
|
+
## Phase 3 — Load the mapping references
|
|
82
|
+
|
|
83
|
+
The three files under `{mappings_dir}/` are **loaded differently**:
|
|
84
|
+
|
|
85
|
+
1. `android-to-harmonyOS-ui-layout-mapping-reference.md` — **read in full** (it is small). Layout containers and layout attribute mappings (LinearLayout→Column/Row, FrameLayout→Stack, RecyclerView→List, RelativeLayout/ConstraintLayout→RelativeContainer `.alignRules()`, layout_weight→.layoutWeight(), padding→.padding(), etc.)
|
|
86
|
+
2. `android-to-harmonyOS-ui-atomic-component-mapping-reference.md` — **look up on demand; do not read in full**. It is a **lookup-style** table of well over a thousand lines (including attribute-level mappings: text/style/alignment/ellipsis, etc.). Approach: first list the widgets and attributes that **actually appear** on this page from the Phase 4.1 view tree / layout XML, then **search** (grep by widget name/attribute name) to locate the matching entries in this file and read those sections. A page usually has only a dozen or so widget kinds; search hits are enough, there is no need to load the whole table.
|
|
87
|
+
3. `android-to-harmonyOS-ui-interaction-mapping-reference.md` — **look up on demand; do not read in full** (556 lines, 43% table rows, 65 subsections; like the atomic table it is **lookup-style**). Same approach as item 2: first list the interaction kinds this page **actually uses** from `clickable_elements` in `meta.json` and the listeners in the source, then search by keyword to locate the section.
|
|
88
|
+
A typical page uses only two or three of the sections "basic click", "long press", "swipe/pull-to-refresh"; the full table also covers keyboard events, focus traversal, rotate/pinch gestures, drag-to-delete, the event dispatch chain and other sections this page most likely does not touch — reading them will not make this page more correct.
|
|
89
|
+
**Entry sections you must check** (pick per the page's actual needs): `## 2. Click Event Mapping` (onClick), `## 3. Gesture Recognition Mapping` (long press/drag/pinch), `## 4. Swipe and Drag Mapping` (swipe, pull-to-refresh, swipe-to-delete), `## 6. Keyboard Event Mapping` (input method and IME behavior), `## 7. Event Dispatch and Interception Mapping` (hit testing and bubbling, together with Phase 5's Interaction Reachability Evidence).
|
|
90
|
+
|
|
91
|
+
> These three mappings are the **primary source**, ahead of built-in knowledge. "Look up on demand" changes only how they are loaded; it **does not lower how much you depend on them**:
|
|
92
|
+
> every widget/attribute/interaction used on this page must be verified in the tables; only when it cannot be found may you fall back to built-in knowledge, and you must say so in the report.
|
|
93
|
+
> For every widget and interaction in the report you must be able to point to the entry you looked up; if you cannot, you did not look it up.
|
|
94
|
+
>
|
|
95
|
+
> **Issue the searches as one batch in a single turn.** First list this page's widgets/attributes/interactions completely, then send
|
|
96
|
+
> all searches against the three mapping tables **in the same turn** — the three tables are independent, and searching one by one only multiplies each lookup by a turn of latency.
|
|
97
|
+
> Tool execution is a tiny part of the time per page; the bulk is the "think + generate after receiving results" of each turn,
|
|
98
|
+
> so whether you can merge turns is almost exactly what decides fast versus slow. The same applies to batch-reading Android source and drawable XML.
|
|
99
|
+
|
|
100
|
+
### 3.1 Load the knowledge cards (`<skill>/references/cards/`)
|
|
101
|
+
|
|
102
|
+
Conversion knowledge is organized by topic into knowledge cards, each with a "Common Mistranslations" table for its topic. Read all the **required cards** before you start writing code (in one batched read):
|
|
103
|
+
`geometry.md` (size/position/coordinate system, ConstraintLayout, hit testing of fill containers), `alignment.md` (alignment and horizontal inset),
|
|
104
|
+
`window.md` (immersion and safe area), `widgets.md` (framework composite widgets, appearance substitution, system dialogs and menus), `resources.md` (strings/colors/icons/SVG/shapes),
|
|
105
|
+
`dynamics.md` (data-driven variants, state transitions, state branches), `state.md` (observation decorators), `build.md` (SDK and defaults).
|
|
106
|
+
**Conditional cards**: `state-v1.md` (required when `PARADIGM = V1`), `canvas.md` (required when this group has custom-drawn Views: `onDraw` / `Canvas` / `Path` / Compose `drawBehind`,
|
|
107
|
+
or when `SOURCE_PACK` has a "Canvas-drawn text" section). The "Knowledge cards" section of `SOURCE_PACK` lists the cards to read based on this group's signals; when in doubt, read them.
|
|
108
|
+
|
|
109
|
+
## Phase 4 — Single-page conversion (for `CURRENT_UI_INFO`)
|
|
110
|
+
|
|
111
|
+
### 4.1 Parse meta.json
|
|
112
|
+
|
|
113
|
+
Extract: `page_id`, `label`, `clickable_elements` (with class/resource-id/text/content-desc/bounds), `click_path`, `came_from`/`trigger_element`, `screenshot` / `screenshots`, `view_xml` / `view_xmls`.
|
|
114
|
+
|
|
115
|
+
The parent skill has already read and verified `REFERENCE_SCREENSHOTS` and `REFERENCE_VIEW_TREES` via their exact paths. You must read them again via the paths passed in, **every frame of every state**, not just the first image; you must not overturn the parent skill's verification with an empty Glob result of your own, nor claim that a screenshot verified to exist does not exist.
|
|
116
|
+
|
|
117
|
+
Keep one in-memory `LAYOUT_EVIDENCE` **per state** (one per `###` state; multiple viewport / scroll frames of the same state are merged into one, noting the regions that newly appear in each frame):
|
|
118
|
+
|
|
119
|
+
- The absolute paths of the screenshots and view trees actually read
|
|
120
|
+
- Screenshot width and height
|
|
121
|
+
- View tree root bounds, app content bounds
|
|
122
|
+
- Top/bottom system bars or immersive areas (when measure_summary has a "nav bar" row, that strip is the system navigation bar, already subtracted from the app bounds and not part of this page; `edge_colors.bottom` is sampled inside its upper edge, and `nav_bar` is the color of the navigation bar itself — do not treat it as the page background or a dialog scrim)
|
|
123
|
+
- Left/right text-edge groups (measure_summary columns "text left edge" and "text right edge"): same group = same indent, compared group by group in Phase 5 "Horizontal Inset Evidence"
|
|
124
|
+
- Bounds of the main regions such as toolbar, main content, list/card area, bottom area
|
|
125
|
+
- Regions added, hidden, moved or scrolled in the current state relative to the base state
|
|
126
|
+
- `blocked` frames (the app forbids screenshots): record only the view tree bounds; take colors from source / theme and say so; do not sample colors from the black image
|
|
127
|
+
- `MEASUREMENT_PACK` is given per state and measures only that state's main frame; ask about pixel questions on other frames with `--probe`
|
|
128
|
+
|
|
129
|
+
**Before citing vp values from `measure_pack.json`, check `density.confident`.** Every vp in that file is computed as `px / density`; get the density wrong once and the whole page's sizes are systematically off by 2–3×, while compilation, reference checks and cross-page consistency all pass (every page is wrong the same way — one of the hardest defects to attribute):
|
|
130
|
+
- `density.source == "device"` (the true value recorded with `wm density` at capture time: `page_capture.mjs` (a2h-dashboard-render) / `android_parse_fast.ts`, or in full mode read per session by `android-utg-explorer` and written by `export_ui_info.mjs`) or `"cli"` (given explicitly by the parent flow with `--density`) → vp may be cited directly as measured evidence; note the source in the evidence.
|
|
131
|
+
- `density.source == "inferred"` and `confident: true` → may be cited, but the evidence must also give the matching line from `evidence` (which node, how many px, how many dp it corresponds to).
|
|
132
|
+
- `confident: false` → **treat every `wVp`/`hVp` on this page as unusable** and cite `wPx`/`hPx` or relative ratios such as `xRatio`/`wRatio` instead; `density.reason` explains why it is uncertain (usually two candidate densities are neck and neck), and `density.rival` gives the runner-up. Do not pick one of the candidates yourself as the conclusion — the right move is for the parent flow to verify with `adb shell wm density` and rerun with `--density`, or to express things in px/ratios.
|
|
133
|
+
|
|
134
|
+
### 4.2 Parse the view tree
|
|
135
|
+
|
|
136
|
+
Read `REFERENCE_VIEW_TREES` and build a structured understanding: root layout, toolbar, content, bottom nav, each widget's class/resource-id/text/content-desc/bounds/clickable/scrollable/checkable/checked/enabled, parent-child + sibling relations inferred from bounds, and reusable patterns (list item / card).
|
|
137
|
+
|
|
138
|
+
If `view_scroll_n.xml` (n=1,2,...) exists: the Android UI was too long and was captured by scrolling; read them in order 1→n and merge all `view_scroll_n.xml` **with `view.xml` as the root** into a merged structure. In full mode these frames come from the explorer's whole-page scroll capture, and `meta.json.scroll_completeness` states how far the evidence covers: `complete` means it was proven to reach the bottom; any other value (`truncated`/`aborted`/`no-container`/`not-swept`, etc.) means there is uncaptured content after the last frame, which must be completed from the static layout and noted in the report. `view_loaded.xml` (present only when `view.xml` is a scroll origin captured before the data arrived or under FLAG_SECURE) is a capture of the same state with the data loaded; it is not part of the scroll sequence and must not be merged as scrolling. Take the page data from it.
|
|
139
|
+
|
|
140
|
+
**Frames captured before loading do not represent the page's appearance**: when `meta.json.content_loading` is present, the views listed in `views[]` were captured before the data came back; their text is the default value of the layout's `android:text` (e.g. `Feels like %1$s`, `%1$d km/h`, a placeholder city name), not what the page actually displays. `texts` gives the unformatted placeholders detected. The page's appearance (text, values, icons, number of list rows) follows the frames in `loaded_views[]`; `primary: true` means `view.xml` / `screenshot.png` itself is a pre-load frame. When `loaded_views` is empty, derive the data state from the source's binding code (`setText(getString(id, args))`, adapter) and note "capture has only pre-load frames" in the report. These placeholder strings **must not** be written into ArkTS display text or default values, and the ViewModel **must not** skip data binding on the grounds that "the screenshot shows the default value". Layout geometry is unaffected; the bounds of pre-load frames can be used as usual.
|
|
141
|
+
|
|
142
|
+
**Nodes covered by an upper layer do not belong to this page**: in single-Activity apps a new Fragment is often stacked on top of an old one, and the old Fragment's nodes remain in the view tree with `visible-to-user="true"`. Regions in `measure_pack.json` carrying `occludedBy` are exactly such nodes (the "occluded" line in the summary names the upper node covering them): they are invisible in the screenshot, must not be converted as this page's structure, and their sizes or colors must not be cited; this page's structure is the subtree of the upper node `occludedBy` points to. `clickable_elements` in `meta.json` marks such widgets `occluded: true` by the same criterion (the count is in `clickable_occluded`), and they likewise do not belong to this page. The criterion does not know whether the upper layer is transparent, so it only marks, never deletes: if it contradicts the screenshot (the element is clearly visible), the screenshot wins.
|
|
143
|
+
|
|
144
|
+
The merged structure may still be incomplete (some components appear in no snapshot). You **must** find and read, in `android_project_dir`, the static XML layout files + Kotlin/Java code most relevant to `meta.json` and the merged structure (start from the member / base lists in `SOURCE_PACK`, read them in one batched turn; search for what the list does not cover), take the static source as the primary structure and the merged structure as dynamic supplementary information, and expand user-defined/third-party components into atomic Android layouts/widgets to get the **final structural understanding**. Output that understanding.
|
|
145
|
+
|
|
146
|
+
**Data-driven visible variants, declared state transitions, state-branch list** → `cards/dynamics.md`. Font-size, coordinate and `Path` units of custom-drawn Views → `cards/canvas.md`.
|
|
147
|
+
|
|
148
|
+
**Coordinate and window-mode rules, ConstraintLayout rewrite, the three hard requirements for size / position / coordinate system** → `cards/geometry.md`.
|
|
149
|
+
|
|
150
|
+
### 4.3 Generate the ArkUI code
|
|
151
|
+
|
|
152
|
+
**Handling conflicts with existing Harmony files**: if the target .ets already exists before conversion, there are three cases —
|
|
153
|
+
1. A dynamically refreshed component (the toolbar shows different icons in different states)
|
|
154
|
+
2. An incremental implementation
|
|
155
|
+
3. The existing code or the final structural understanding is wrong
|
|
156
|
+
|
|
157
|
+
In every case you must verify against the static XML/Kotlin/Java + view.xml + view_scroll_n.xml. **Do not delete existing Harmony code**.
|
|
158
|
+
|
|
159
|
+
dialog/fragment/adapter and similar must be split out of the main page into `{harmony_project_dir}/entry/src/main/ets/components/`.
|
|
160
|
+
|
|
161
|
+
**Part ownership of framework composite widgets (the (a)/(b1)/(b2) ownership table), Appearance Substitution, system dialogs and menus** → `cards/widgets.md`.
|
|
162
|
+
|
|
163
|
+
**General rule — "taken over by the platform" does not end the check (applies to every check item in this procedure)**:
|
|
164
|
+
|
|
165
|
+
Whenever a rule's conclusion reads like "taken over by the platform/atomic component/framework", "built into the component", "the default behavior is fine", or "no need to set", that conclusion **is not a pass**. You must also answer: **is the result it produces after taking over equivalent to the reference, and on what evidence?**
|
|
166
|
+
|
|
167
|
+
Criterion (mechanical): when the conclusion text contains words like "built in / default / taken over / no need to set / absorbed", it must be immediately followed by an equivalence statement with evidence (an `@default` value from the SDK `.d.ts`, or a screenshot/view tree measurement); otherwise the item fails.
|
|
168
|
+
|
|
169
|
+
> This procedure has registered several instances of "two individually correct rules combining into an error" (`fill="none"` and `.fillColor()` being duals, view-tree parts versus the atomic component's built-in decorations, platform default differences, opposite container alignment defaults, inverted `padding` semantics…). **Such a list can never be complete** — every new atomic component or new default value adds another unregistered instance. So do not rely on "checking the list"; instead, every time you reach a "the platform takes over" conclusion, mechanically ask the question above. The list is examples; the general rule is the line of defense.
|
|
170
|
+
|
|
171
|
+
**Architecture**:
|
|
172
|
+
- MVVM: page/component uses the viewmodel, the viewmodel uses the model
|
|
173
|
+
- Before converting, scan `{harmony_project_dir}` for reusable components/VMs/Models; extract shared components such as the toolbar into components for reuse; merge and reuse related models/viewmodels instead of creating a new one per page
|
|
174
|
+
- **Choose decorators by the paradigm decided in Phase 2.0 and keep to the same set throughout; never mix**:
|
|
175
|
+
- **V1**: `@Component` components; component state `@State`, parent-child `@Prop` (one-way) / `@Link` (two-way), cross-level `@Provide`/`@Consume`; ViewModel/Model classes use `@Observed` + `@Track` on properties; side-effect watching `@Watch`
|
|
176
|
+
- **V2**: `@ComponentV2` components; component state `@Local`, parent-to-child input `@Param` (+ optional `@Once`), child-to-parent `@Event` (with `!!` two-way binding), cross-level `@Provider`/`@Consumer`; ViewModel/Model classes use `@ObservedV2` + `@Trace` on properties; watching `@Monitor`, computed properties `@Computed`
|
|
177
|
+
|
|
178
|
+
**Resources**: every resource referenced by the HarmonyOS UI (images/strings/colors/dimensions, etc.) must be explored and used by semantic match against the resources already converted in the HarmonyOS project.
|
|
179
|
+
|
|
180
|
+
**String resource values, color arithmetic, icon source tiers L1–L3, ShapeDrawable, Visible Resource Closure** → `cards/resources.md`.
|
|
181
|
+
|
|
182
|
+
**Layout**: look up the layout mapping ref.
|
|
183
|
+
|
|
184
|
+
**Components**: look up the atomic component mapping ref.
|
|
185
|
+
|
|
186
|
+
**Interaction**: look up the interaction mapping ref.
|
|
187
|
+
|
|
188
|
+
**Always check the mapping files first** (project-specific, broader coverage); they override built-in knowledge.
|
|
189
|
+
|
|
190
|
+
**Units and styles**:
|
|
191
|
+
- `dp` → `vp`, `sp` → `fp`
|
|
192
|
+
- `bounds` differences are only for computing region ratios and verifying relative layout, never used directly as vp; intrinsic dp/sp sizes follow Android XML/dimens
|
|
193
|
+
- Resources use `$r('app.color.xxx')` / `$r('app.string.xxx')` / `$r('app.media.xxx')`
|
|
194
|
+
|
|
195
|
+
**Routing**: implement the routing relations between the UI and components.
|
|
196
|
+
|
|
197
|
+
**Interactive elements**:
|
|
198
|
+
- Attach `.onClick()` to every `clickable_element`
|
|
199
|
+
- `click_path` shows a jump to another Activity → `router.pushUrl()`
|
|
200
|
+
- **Exception: navigation inside a shell is not `router.pushUrl`.** For pages with `presentation: shell-content` in the prompt, and for the host Activities listed in the `Shell hosts` section of `Project Fact (Shell Contract)`, their Fragments are content units mounted by the shell. In that case:
|
|
201
|
+
- Do not write `@Entry` and do not draw chrome yourself (bottom navigation/Tab/Drawer/persistent player bar all belong to the shell; a builder of that kind inside the page is a GATE);
|
|
202
|
+
- Navigation to another Fragment of the same host calls the callback the shell passes in as a parameter (e.g. `onNavigate`), not `router.pushUrl`; when the shell does not yet provide it, write it as an optional callback parameter and register it under `shell requests` in the report — do not fake an implementation with `console.info('TODO: navigate')`;
|
|
203
|
+
- Use `router.pushUrl` only for navigation to **another Activity** (UTG edge mechanism `startActivity-*`);
|
|
204
|
+
- Transitions follow the `transitions` of `Shell hosts`: implement what is declared; for `NOT animated` write no `pageTransition()`/`transition()` at all and mark `n/a (no source declaration)` in "Transition Implementation Evidence".
|
|
205
|
+
Projects without a `Shell hosts` section are not subject to this exception; follow the rules above.
|
|
206
|
+
- State switches (dialog/menu/toggle) → managed with `@State`
|
|
207
|
+
- **Prefer the real implementation**: before mocking, search `{harmony_project_dir}` for whether the target page/component .ets exists; if it does, wire the real `router.pushUrl()`; **only when the target is not yet implemented** mock it + `console.info('TODO: ...')`
|
|
208
|
+
- **Mocks must not reference unreachable addresses**: images/icons in mocks must not use made-up URLs (e.g. `https://mock.weather.icon/…`, `example.com`); they are bound to fail to load and render as blank cells, unlike the reference. Use a semantically equivalent resource already converted in the project (`$r('app.media.…')`); if there is none, register `degraded` and leave an empty placeholder; list remote icons delivered by operations in the report as "takes effect once the data layer is wired up".
|
|
209
|
+
- **Mock data must reproduce the visible state of the reference screenshot**: mock/placeholder data is not a free value. The **values, count, start/end and order** of every visible item in the reference screenshot must be faithfully reproduced by the mock (while the real data layer is not converted, the mock should be **reverse-engineered** from the reference screenshot). If the visible state the implementation produces differs from the reference, you **must not** pass it on the grounds that "this is mock data and it will heal itself once real data is wired up" — first prove the rule layer is correct, then discuss the data source. A rule-layer error (selection rule, sequence start, item count) is just as wrong with real data.
|
|
210
|
+
|
|
211
|
+
### 4.5 Lottie animation integration (only when the parent skill injected `LOTTIE_ENTRIES_FOR_THIS_PAGE`)
|
|
212
|
+
|
|
213
|
+
**No such block in the prompt → skip this section**: do not go reading `resource_mapping.md` on your own, and do not mention Lottie additionally in the generated .ets. With the block → **first read `lottie-integration.md` in the same directory in full** (locating the host logic, `@ohos/lottie` usage, per-scenario adaptations, integration into the page and verification), then generate the code.
|
|
214
|
+
|
|
215
|
+
## Phase 5 — Consistency verification (critical: 2 mandatory rounds + a conditional 3rd)
|
|
216
|
+
|
|
217
|
+
**Round rules**: rounds 1 and 2 are **mandatory** and both must go through every check item below. Round 3 is **as needed**:
|
|
218
|
+
- If round 2 made **any change** (to .ets, resources or routing) → round 3 is **mandatory**, and it re-checks only the items affected by round 2's changes,
|
|
219
|
+
repeating until some round makes **zero changes**;
|
|
220
|
+
- If round 2 made **zero changes** (pure confirmation) → **skip** round 3, go straight to the report, and record in the report "round 2 made zero changes;
|
|
221
|
+
round 3 skipped per the rules".
|
|
222
|
+
|
|
223
|
+
**The mechanical part of each round is one command** (run it once at the start of each round; do not grep item by item / run the static checker separately any more):
|
|
224
|
+
|
|
225
|
+
```
|
|
226
|
+
node <skill>/scripts/phase5_check.mjs <harmony_project_dir> --files <.ets files this group wrote, relative to the ets root, comma-separated> --round <N> --report <harmony_project_dir>/.hometrans/queue_logs/<GID>.report.md [--android <android_project_dir>]
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
(`--android` may be omitted: the script takes the Android project directory from `batch_progress.json` → `work/resource_deps.json` → `work/icons.json`, in that order, for source-side rules such as `framework-picker-appearance`.)
|
|
230
|
+
|
|
231
|
+
A single output gives: static GATE / CANDIDATES for this group's files (batch-level orphan / unreachable belong to the parent flow's Step 5.5), unresolvable `$r` / `$rawfile`,
|
|
232
|
+
`EVIDENCE()` whose names do not match the headings below verbatim, Tier B items this group has not covered, over-budget EVIDENCE blocks, forbidden patterns and `.position/.offset` positions awaiting evidence, brace balance, **Android custom drawing in this group's reach (`drawPath`/`drawCircle`/`drawText`… inside `Canvas` / `onDraw`) with no Harmony file that draws it** (`drawing_uncovered`: a `.kt` cited by this group's `.ets`, or a drawing composable those call one level down, needs a file that cites it and contains `Canvas`/`Path`/`Shape` drawing; when it truly does not apply, write one report line "<name> n/a: <reason>"), **`degraded`/`simplified to` lines whose only reason is "uncaptured / not collected / no snapshot / data layer not wired / unreachable"** (`degrade_reason_ruled_out`; both read the group report given by `--report`, else the `--group` one, else none — so pass `--report` every round, even while the report is unfinished; transitions/gestures and lines naming a platform gap are exempt) — both blocking,
|
|
233
|
+
and **which files changed relative to the previous round's snapshot** — the output at the start of round 3 directly says "round 2 made zero changes" or gives the change list, which is the criterion for the round rules.
|
|
234
|
+
It only makes lexical judgments: uncovered items may genuinely be not applicable (just state N/A in the report), and CANDIDATES still need their source annotated one by one as described below.
|
|
235
|
+
**Every semantic check item below is still walked through by hand, none skipped** — what the script saves is the turn spent "going to look", not the "judging".
|
|
236
|
+
|
|
237
|
+
### Phase 5 output contract — write each fact only once
|
|
238
|
+
|
|
239
|
+
**The number of check items, the two-mandatory-rounds rule, and the conclusion each item must reach are all unchanged. Only "where it is written, and how many times" changes.**
|
|
240
|
+
|
|
241
|
+
Two tiers:
|
|
242
|
+
|
|
243
|
+
**Tier A — the report must spell out the full derivation** (5 items):
|
|
244
|
+
`Window Mode Evidence`, `Transition Implementation Evidence`, `Duplicate Decoration Check`, `Visible Resource Closure`, `Position Anchor Evidence`.
|
|
245
|
+
|
|
246
|
+
The miss pattern of these 5 items is always "two individually correct rules combining into an error" (`fill="none"` and `.fillColor()` being duals,
|
|
247
|
+
view-tree parts versus the atomic component's built-in decorations, ① misjudged from a screenshot + ④ confirmed by "consistent with the baseline"…).
|
|
248
|
+
Such errors **can only be self-detected by laying the reasoning chain out in writing**; compressing it into a one-sentence conclusion is bound to let them through.
|
|
249
|
+
|
|
250
|
+
**Tier B — the report gives only "conclusion + `file:line` pointer"** (all other items):
|
|
251
|
+
the derivation is left as a structured comment in the corresponding `.ets`, in a fixed format:
|
|
252
|
+
|
|
253
|
+
```
|
|
254
|
+
// EVIDENCE(<check item name>): <conclusion> —— basis: <source>
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
- The name in parentheses must match the check item heading below **verbatim** (e.g. `EVIDENCE(Text Alignment Evidence)`); otherwise the parent side cannot locate it mechanically.
|
|
258
|
+
- `<source>` must still be one of the four classic kinds: `constraint-solved` / `xml-explicit-dp` / Android source `file:line` / `pixel-measured`.
|
|
259
|
+
- The report **no longer lists the Tier B items one by one**: the `EVIDENCE()` tag itself is the index, and the parent side locates them mechanically with `phase5_check.mjs --group` (`evidence_uncovered_B`) and grep. The report lists only the Tier B items that are **genuinely not applicable**, one line each: `<check item name>: N/A —— <reason>`.
|
|
260
|
+
|
|
261
|
+
**Never write the same fact twice, once in a comment and once in the report.** The comment is the only carrier; the report does not repeat it.
|
|
262
|
+
|
|
263
|
+
**Size of an EVIDENCE block: conclusion + derivation + source, no narration.** Each Tier B block ≤ 400 characters (about two comment lines); `phase5_check.mjs` names offenders.
|
|
264
|
+
What gets compressed is repetition and narration, **not evidence** — every needed derivation (formula, constraint-solved value, `file:line`) stays:
|
|
265
|
+
- Write derivations as formulas, not sentences: `141px/2.625=53.71vp = padding 16×2 + line-height 21.71` rather than a paragraph of explanation.
|
|
266
|
+
- **Project-level facts are cited, not restated**: immersive conclusion, density, content bounds, theme colors and other facts the parent flow has already fixed in the brief are written as `basis: Project Fact (<name>)`; do not recopy the theme chain and `styles.xml` line numbers on every page (otherwise the same immersive theme chain gets rewritten in every page's `.ets`).
|
|
267
|
+
- **Evidence for a shared component is written once in the component file**; pages only write `see components/X.ets:<line>`.
|
|
268
|
+
- `Reference Input Evidence` needs just one line listing paths; the other items do not restate which files were read.
|
|
269
|
+
- **The full derivation of Tier A items is written only in the report**; if an anchor is wanted in the `.ets`, leave just one line ≤ 200 characters: `EVIDENCE(<name>): <conclusion> —— derivation in report`. Writing the full derivation in both places violates the previous rule.
|
|
270
|
+
|
|
271
|
+
Without constraints, EVIDENCE comments take up a considerable share of the characters in the generated `.ets`, and every character is generated token by token.
|
|
272
|
+
|
|
273
|
+
The by-product is worth more than the time saved: a uniform marker turns the parent's review from "reading prose" into "running grep" —
|
|
274
|
+
`grep -rn "EVIDENCE(" <ets dir>` lists every evidence location for item-by-item comparison.
|
|
275
|
+
|
|
276
|
+
**Report Structure and Size.** The report is also generated token by token, and its size is mostly spent on the Tier B item-by-item index, round logs and narration. The report contains only the following sections, in this order, and the heading `## REPORT <GID>` appears only once:
|
|
277
|
+
|
|
278
|
+
| Section | Write | Do not write |
|
|
279
|
+
|---|---|---|
|
|
280
|
+
| Files | One line per `.ets` this group wrote/changed (the parent's `--group` uses it to determine the scan surface) | A narrative of what each file does |
|
|
281
|
+
| Reference Input Evidence | One line per frame path (the only Tier B item fully listed in the report) | The list of source files read |
|
|
282
|
+
| Tier A, 5 items | The full derivation chain, written with tables and formulas; project facts as `Project Fact (<name>)`; the same fact in another Tier A item as `see Tier A #<N>` | Narrative sentences, restating files read, anything duplicating the `.ets` comments |
|
|
283
|
+
| Fact conflicts | Every place that overturns a parent-flow fact: the fact, evidence `file:line`, disposition | Omit the whole section when there is no conflict |
|
|
284
|
+
| Tier B N/A | Only the genuinely not-applicable items, one line of reason each | The other Tier B items (see above) |
|
|
285
|
+
| CANDIDATES | One line per item: source and conclusion | Restating the phase5_check output |
|
|
286
|
+
| Uncalibrated Items / degraded | Residuals of source-only and transitional states, one line each | |
|
|
287
|
+
| registry_requests / shell requests | The JSON structure from Step 5.3 rule 7 | |
|
|
288
|
+
| Rounds | One line per round: `Round N: blocking <n>, changed <files or 0>` | A running log of findings and changes per round |
|
|
289
|
+
|
|
290
|
+
The Tier A derivation chain skips no step: what is compressed is the form of expression and repetition, not the reasoning.
|
|
291
|
+
|
|
292
|
+
List every layout/component/resource reference in the converted HarmonyOS UI and, for each one, go through every check below **item by item** (none may be skipped):
|
|
293
|
+
|
|
294
|
+
- **Reference Input Evidence**: in the report, list by state the `REFERENCE_SCREENSHOTS` and `REFERENCE_VIEW_TREES` this page actually read, **every frame**; if any frame was not read or is missing, the page does not pass. **[UTG]** For `source-only` pages, list instead the layout XML, host class and its base classes actually read, and the `file:line` of `TEMPLATE_PAGES`; if any of `SOURCE_HINTS.layout_files` was not read, the page does not pass.
|
|
295
|
+
- **Main Region Evidence**: list the Android bounds of the main regions, their normalized ratios relative to the content area, and the corresponding ArkUI containers; check that top-level regions have no large sourceless `.position()`/fixed heights. **Also** label, region by region, the **source** of every width/height value: `constraint-solved` (from the reference view tree) or `xml-explicit-dp`. Failing to label a source is a failure; using `'100%'`/`.height('100%')` for a region whose measured size differs from its parent is likewise a failure (see the ConstraintLayout translation table in Phase 4.2).
|
|
296
|
+
- **Position Anchor Evidence**: besides widths/heights, **list every coordinate of every `.position()` / `.offset()`**, labeling it as `fixed-offset` (on Android it is itself fixed relative to the parent's start edge) or `parent-derived` (on Android it is right/bottom/center anchored). **A `parent-derived` coordinate written as a constant is a failure** — it must be restored to an alignment relation (`RelativeContainer` + `.alignRules()`, `Stack` + `Alignment`, parent `padding`) or a live parent-size expression. Self-check per coordinate: "if the screen width shrinks by 10%, is this value still right?". The typical sign of missing this is an element that moves out of the visible area and gets clipped on narrower screens while being perfectly normal at the reference resolution (see **Hard requirement (position)** in Phase 4.2).
|
|
297
|
+
- **Window Mode Evidence**: immersion always goes through **component-level background immersion** (shell contract `system_bars`; HarmonyOS best practice "window immersion", option 1), and you must **list per page** and check four points:
|
|
298
|
+
The criteria for ①–④, the component-layer form, the "Key point" paragraph and the cross-page consistency rules → `cards/window.md`.
|
|
299
|
+
- **Visible Resource Closure**: list the Android source, Harmony resource and code reference of each visible Image/Video/Text; a key media item missing any link does not pass. **Also**, for every visible element whose variant is selected by a runtime value, list the comparison "state shown in the reference screenshot → variant your rule actually selects in that state"; merely listing a complete mapping table is not enough to pass. If this page uses mock/placeholder data, list item by item the comparison between the reference screenshot's visible state and the state the implementation produces; any mismatch is a failure (per the mock rules in Phase 4.3). **Whenever you cite the reference screenshot/view tree as the basis for a rule, substitute back and verify that the rule really yields the cited state** — if the argument and the conclusion are mutually exclusive (e.g. claiming "this rule reproduces the reference" when it cannot yield what the reference shows), it fails.
|
|
300
|
+
- **Shape Background Evidence**: list the mapping from Android ShapeDrawables to ArkUI styles; a stretchable shape without `<size>` used via an ordinary Image + `ImageFit.Fill` is a failure.
|
|
301
|
+
- **Static Clipping Check**: using the main-region ratios of the reference screenshot/view tree, check that the toolbar, content area, cards and bottom area do not cover each other or exceed the expected content area. **Also**:
|
|
302
|
+
- For sibling text/icon rows inside a `Stack`, write out each one's vertical interval `[top, top+height]` and its origin (criterion: the origin paragraph of "Hard requirement (coordinate system)" in `cards/geometry.md`); for state-driven offsets/sizes, compute the start and end values once each and compare them with the corresponding snapshot bounds — if the snapshot shows no overlap but the computation does, it fails.
|
|
303
|
+
- For text that is **single-line** `wrap_content` in the reference view tree (height ≈ one line of text), find its available width on the HarmonyOS side (parent width − width taken by same-row siblings − padding) and estimate from the font size that the text fits; if it does not fit while it fits on Android, the structure has spread siblings into the same row (the "two-dimensional constraints" row of the ConstraintLayout rewrite table in `cards/geometry.md`) — change the structure; do not mask it by shrinking the font or truncating with `maxLines(1)`.
|
|
304
|
+
- **Interaction Reachability Evidence**: for each clickable element, list its **z-order** in the parent `Stack`/layered structure and confirm that **no** sibling after it covers its visible rectangle. **Also** list every container on this page with `width('100%')` and `height('100%')` (or equivalent fill) and label each as interactive or as having declared `hitTestBehavior(HitTestMode.None)`. "No visual overlap" and "hits not blocked" are two different things: a transparent or bottom-pinned container does not count as covering in a visual check, yet it can swallow every click beneath it. The typical sign of missing this item is an element that looks normal but does nothing at all when tapped (not even console output), because the event is consumed by an upper node that has no `onClick` of its own.
|
|
305
|
+
|
|
306
|
+
- **Missing Observation Decorators** (per the paradigm branch decided in Phase 2.0):
|
|
307
|
+
List the read surface of build() item by item; criteria in `cards/state.md`, and additionally `cards/state-v1.md` for V1 projects.
|
|
308
|
+
- **Color Conflict**: do fill/background/foreground colors conflict and make something invisible (white image on white)? Fix it if so
|
|
309
|
+
- **Color Settings**: do the background/fill/foreground colors match the Android UI (missing, wrong)? Fix them if not. **For a background that switches by state, the text color must be written with the same condition**: Android's selected/occupied branches usually call both `setBackground` and `setTextColor`; translate only the background and the text color stays at the default dark color. A `Span`'s color inherits from the enclosing `Text`; if neither sets it, it is the default color. This item **cannot rely on self-reporting alone**: the `[text_color]` section of `phase5_check --group` compares, segment by segment, the text foreground color measured by measure_pack with the effective text color of `Text`/`Span` in the code; `text-color-unset` / `text-color-mismatch` are blocking. Mechanical backstop: GATE `text-on-stateful-bg-no-color` (a lexical check, also effective on source-only pages)
|
|
310
|
+
- **Text Alignment Evidence**: list every `Column`/`Row` that directly contains `Text` (or a `@Builder` call that renders `Text`), labeling whether it explicitly declares **the axis that determines horizontal position**, and the Android basis for that value.
|
|
311
|
+
Criteria (the horizontal axis of the two containers, looking at the parent container, `Scroll.align`, Compose `Box` child alignment) → `cards/alignment.md`.
|
|
312
|
+
- **Horizontal Inset Evidence**: "Text Alignment Evidence" only governs alignment direction (Start/Center/End), not **how much it is indented** — left-aligned but 72vp off on the left margin still passes. This item checks the left margin of every visible `Text`, one by one:
|
|
313
|
+
Criteria (matches the measurement, same group same indent, right edge likewise) → `cards/alignment.md`.
|
|
314
|
+
- **Icon Source Tier Evidence**: for every visible icon, label which tier of Phase 4.3 it belongs to — L1 / L2 / L2.5 / L3; L2 must give the library and symbol name, L2.5 the original web path and (for Remote) the absolute URL, L3 the downgrade explanation. **An unregistered L3 is a failure; deciding L3 without first checking the two Hybrid-Shell sections is likewise a failure**. Also confirm one by one that none of the three forbidden downgrades was used (emoji/text glyphs, substituting a semantically mismatched drawable, hand-writing SVG from memory).
|
|
315
|
+
- **Misused Resource References**: do the resource references match the Android UI; nonexistent resources must be looked up again for the right name; "no emoji or hard-coded icons of any kind are allowed".
|
|
316
|
+
SVG content sub-checks (clip-path, fill/stroke, viewBox, tint channel, bounding-box path, `?attr`, placeholder SVG, duplicate attributes) → `cards/resources.md`.
|
|
317
|
+
- **Transition Implementation Evidence**: list every entry of the Phase 4.2 "declared state transitions" list, labeling it `implemented` / `degraded` (with the reason and the actual behavior after downgrading) / `escalate` / `n/a` (with the reason). **A missing list entry, or any entry left unlabeled, is a failure.**
|
|
318
|
+
**List the Phase 4.2 "state-branch list" in the same section**: each row "state → source-side condition `file:line` → build/draw calls in the branch → captured by a snapshot or not → HarmonyOS-side `file:line`". Each `drawXxx` of a custom-drawn View gets its own row. A branch call of an uncaptured state with no matching line on the HarmonyOS side and not labeled `n/a` is a failure — this is the only acceptance basis for uncaptured states.
|
|
319
|
+
|
|
320
|
+
**`degraded` is not a universal exit you may adopt on your own.** When the **end state of a transition has been captured by any reference snapshot**, this page **must not** label it `degraded` on its own — only `implemented`, or `escalate` (with a description of the gap), and the parent flow decides whether to accept or send it back. Reason: `degraded` and `implemented` stand side by side as zero-cost legal end states, while the state captured by a reference snapshot **is itself the acceptance target**, not an optional behavioral detail; allowing self-downgrading means allowing the page to shrink its own acceptance scope.
|
|
321
|
+
Criterion (mechanical, the same as the cross-check in Phase 4.2): when the bounds or size of the same `resource-id` change across snapshots in a way **that scroll displacement cannot explain** (the whole block gets shorter rather than moving up as a whole), that end state counts as "captured".
|
|
322
|
+
Transitions not captured by any snapshot (pure interaction states, no matching snapshot) may still be self-labeled `degraded`. When implementing only the base state and skipping the transition entirely, you **must** explicitly write it as `degraded` in the report and say what is missing — do not skip registering it because "transitions are behavior, not layout": if a reference snapshot has captured the post-transition state (e.g. `screenshot_scroll_n` captured the collapsed header), that state is part of this page's acceptance scope. The typical sign of missing this item is a perfect static first screen that diverges from the source app as soon as you interact.
|
|
323
|
+
- **Duplicate Decoration Check**: against the "part ownership table of framework composite widgets" in Phase 4.3, confirm one by one that the decorations built into the target atomic component (input underline, cursor, icon slot, selection mark, etc.) are **not** drawn again by hand-written sibling nodes. Criterion: the same visual element should have only one drawing source in the final tree. The typical sign of missing this item is an extra line/box in the UI, often positioned **outside** the component (the hand-written node's box does not coincide with the atomic component's rounded box).
|
|
324
|
+
**Also** state "reference appearance → target component appearance" for each framework widget (e.g. "clock face → wheel"). If the two have different graphic structures and the conclusion is `degraded`, it fails (Phase 4.3 "Appearance Substitution"): it can only be (b2)/(a) or `escalate`.
|
|
325
|
+
- **Misused Shapes**: do shapes such as rounded/square corners match the Android UI; does a ShapeDrawable keep its fixed dp corner radius instead of being stretched non-uniformly
|
|
326
|
+
- **Size Issues**: do icon/component sizes match
|
|
327
|
+
- **Position Issues**: is the toolbar at the top, are icons positioned too far left/right, etc.
|
|
328
|
+
- **Routing Relations**: is routing between the UI and components implemented correctly
|
|
329
|
+
- **Lottie Integration** (checked only when Lottie entries were injected for this page):
|
|
330
|
+
- Does the `path` of `lottie.loadAnimation` exactly match the entry's `load_path`
|
|
331
|
+
- Do `loop` / `autoplay` / `contentMode` faithfully map Android `lottie_loop` / `lottie_autoPlay` / `lottie_scaleType`
|
|
332
|
+
- Is `lottie.destroy(name)` called in both `aboutToDisappear` and `Canvas.onDisAppear`
|
|
333
|
+
- Is the `animateName` unique across multiple animations on the same page
|
|
334
|
+
- If Android uses a pull-to-refresh animation, are all 4 state branches of `onStateChange` present
|
|
335
|
+
|
|
336
|
+
**Run the verification iterations per the round rules at the start of this Phase (2 mandatory rounds; if round 2 changes anything, keep going until zero changes) and output the verification report**.
|
|
337
|
+
|
|
338
|
+
### Static checker (`phase5_check.mjs` already runs it and lists only this group's files; the parent flow's Step 6.1 runs it once over the whole project)
|
|
339
|
+
|
|
340
|
+
Several of the **purely lexical** items above are implemented as a script. `phase5_check.mjs` calls it automatically every round and filters this group's files; run it separately only when you need a whole-project view (static, no device or SDK needed, takes seconds):
|
|
341
|
+
|
|
342
|
+
```
|
|
343
|
+
node <skill>/scripts/arkts_static_check.ts --ets <harmony_project_dir>/entry/src/main/ets \
|
|
344
|
+
--resources <harmony_project_dir>/entry/src/main/resources \
|
|
345
|
+
--android <android_project_dir>
|
|
346
|
+
```
|
|
347
|
+
|
|
348
|
+
- The `[GATE]` section holds zero-ambiguity defects and **must be cleared**. Among them, "block comment closed early by `*/`" is especially worth running early: writing an evidence path containing a wildcard (like `foo_*/view.xml`) into JSDoc makes the compiler report **hundreds** of bogus errors whose coordinates point into the comment body, which is extremely time-consuming to trace back from the build output, while the script names it directly.
|
|
349
|
+
- The `[CANDIDATES]` section is **not defects**, just a narrowing of the manual review scope. Whether the fill containers and constant coordinates it lists are correct depends on the anchoring direction and stacking order on the Android source side — lexical analysis cannot decide that. Treat it as the to-review list for the three items "Position Anchor Evidence", "Interaction Reachability Evidence" and "Window Mode Evidence", and annotate the source of each entry; **do not change code just because something is listed** — most fill containers are legitimate.
|
|
350
|
+
- The meaning, fix and downgrade marker of each rule: look up `<skill>/references/checker-rules.md` by rule id (`grep -n "### <id>"`, read only the matching section, do not read it through).
|
|
351
|
+
- Items the script cannot cover (scope of value-selection rules, whether the mock reproduces the reference, whether self-evidence is self-consistent) must still be walked through by hand, item by item. **A cleared `[GATE]` is not grounds for passing this page.**
|
|
352
|
+
|
|
353
|
+
### Common Mistranslations Cheat Sheet (undetectable at compile time; self-check each one)
|
|
354
|
+
|
|
355
|
+
The common trait of the defects below: **syntactically valid, compiles, zero warnings**, and the static reference checks all pass too —
|
|
356
|
+
they only surface when reading the code's semantics or running on a real device. Avoid them while generating code rather than patching afterwards.
|
|
357
|
+
|
|
358
|
+
Rows whose full derivation is written elsewhere keep just one sentence, pointing to the detailed location (after "→") and the mechanical backstop rule; when self-checking, go through the referenced check item.
|
|
359
|
+
|
|
360
|
+
Each entry has been merged by topic into the "Common Mistranslations" table at the end of the corresponding knowledge card (geometry, alignment, window, widgets, resources, Canvas, state, SDK). Compare card by card before generating code, and self-check card by card again before Phase 5 ends.
|
|
361
|
+
|
|
362
|
+
> The bold rows differ fundamentally from the others: **the defect stems from the two platforms defining the same concept differently, or from two individually correct rules combining into an error**, not from the translator writing a wrong value.
|
|
363
|
+
> Reviewing either side alone finds nothing, and an attribute-by-attribute check actually confirms it as "correctly translated" —
|
|
364
|
+
> it can only be ruled out item by item with the **targeted checks** given above (fold padding into the declared size, check `.d.ts` defaults).
|
|
365
|
+
|
|
366
|
+
## Source-only Tier [UTG]
|
|
367
|
+
|
|
368
|
+
Applies to: (1) pages with `EVIDENCE_TIER == source-only`; (2) uncaptured (`uncaptured`) attached nodes in `ATTACHED_NODES` of either tier (dialogs, menus, panels, mode states) — for these the rules cover only that node's own source branch, and the captured parts of the host page still follow the screenshot / view tree evidence. Below, "this page" means that node for case (2). **The procedure, the check items, the two-round mandatory rules and the Tier A/B output contract are all unchanged**; the only thing that changes is "where the evidence comes from". The principle in one sentence: **whatever a screenshot would have given you is either derived from source, borrowed from a template page that shares the same source, or honestly labelled as framework default / uncalibrated — never fabricate a measured value.**
|
|
369
|
+
|
|
370
|
+
**"The data layer is not converted yet" is not a reason to degrade.** UI conversion runs before logic conversion, so Repository / network / database are usually not wired in yet; that is the normal state, not a defect. A dialog, panel, menu or mode state must still be fully implemented even when it is unreachable in the current project because "there is no data, so its entry never opens": rebuild its structure from its source branch (layout / dialog class / adapter / item layout), render the with-data state with mock data (fields taken from the item layout and the Model class, marked `// TODO(data-layer)`), and wire its entry the way the source triggers it. Labelling it `degraded` only because it is "uncaptured", "the data layer is not converted" or "currently unreachable" fails; a genuine downgrade needs another reason (a missing platform capability, etc.) and goes into `Uncalibrated Items`. The rule below that mocking the with-data state must not change structural state still applies.
|
|
371
|
+
|
|
372
|
+
**Evidence sources (replacing the "original four kinds" of Phase 5)**:
|
|
373
|
+
- Allowed: `xml-explicit-dp` / Android source `file:line` (including the style/theme resolution chain) / `template-measured(<page_id>)` / `framework-default(<basis>)`
|
|
374
|
+
- **Forbidden**: `constraint-solved`, `pixel-measured` — this page has nothing to measure. Any occurrence is judged fabricated
|
|
375
|
+
- `template-measured` may be used **only** for parts **shared** with the template page: the same layout file, structure rendered by the same base class, the same framework widget (Toolbar, PreferenceScreen row, AlertDialog skeleton). Regions unique to this page must not borrow from it
|
|
376
|
+
- Every `EVIDENCE(...)` comment puts `[source-only]` before its conclusion, e.g. `// EVIDENCE(Text Alignment Evidence): [source-only] left-aligned —— basis: <x>_fragment.xml:<line> gravity unset, LinearLayout defaults to start`
|
|
377
|
+
|
|
378
|
+
**Phase 4.1 → build `LAYOUT_EVIDENCE` from source**: read `SOURCE_HINTS.layout_files` and the classes `declared_at` points to (plus the `onCreateView` / `setContentView` / `addPreferencesFromResource` of the `extends_base` base class). Where there is no layout file (built in code, Preference XML, base-class layout), follow the call chain to the real layout source. Record: the major regions and how each region declares its size (explicit dp / `wrap_content` / `match_parent` / `0dp`+constraints / weight). Density and app content bounds come from the project token table supplied by the parent flow; do not assume them yourself.
|
|
379
|
+
|
|
380
|
+
**Phase 4.2 → structure**: this was already driven mainly by static source, so run it as usual; there is no merged view tree to fill in gaps, so **the dynamic parts must be traced in source**:
|
|
381
|
+
- **Visibility**: decide the initial state of each `layout_hidden_ids` entry and each `setVisibility` / `isVisible` branch in code, one by one.
|
|
382
|
+
- **Which initial state to render**: for pages whose `SOURCE_HINTS.required_state` is `content` / a data state (list pages, detail pages), render the **with-data state** as the primary state using mock data (3–5 items, fields taken from the item layout and the Model class), and implement the empty state (the empty-state handler class that `content_state_evidence` points to, etc.) alongside it as a switchable secondary state. State the choice and its basis in the report.
|
|
383
|
+
- **Login-gated pages**: when `SOURCE_HINTS.login_interceptor` is present, the Android navigation layer intercepts this page centrally (`at` is the protected list, `gate` the interception check) and redirects a logged-out user to `redirect_when_unmet`. Render the **logged-in state** and do not add a login check inside the page; list the page and its `redirect_when_unmet` in the report so the navigation-layer logic conversion implements the interception.
|
|
384
|
+
- **Mocking the with-data state must not change "structural" state.** Any state that lives in the shell or is shared across pages and decides **what other host pages look like** — visibility of shell chrome (player panel, badge, drawer), the selected tab, AppStorage flags — must have an initial value **equal to the Android source's initial state** (e.g. `setPlayerVisible(false)` / XML initial `gone`); do not switch it to a with-data state just so that this component "has data to show". This group does not write such values; report them as `shell requests` (shell contract rules). Reason: a shell-state default applies to **every host page**, including captured pages that have screenshots: a with-data value makes chrome that their reference screenshots do not have appear on those pages.
|
|
385
|
+
**Content data on a shared VM / Model is not covered by this** (list items, forecast data, displayed values): as long as every captured page that reads the field shows a with-data state in its reference, reverse-engineer the mock from the reference screenshots per the mock rules in Phase 4.3 of this document and mark it `// TODO(data-layer)`; if any captured page's reference shows the empty state, keep the source's initial state. Three boundaries:
|
|
386
|
+
- **Structure vs content**: the test is "would this value change pages that **do not render this field**". A page that reads the field switching from its empty-state placeholder to a list (the empty view disappears) is content, decided by the "every captured page that reads it has data" rule above; only values that change another page's chrome / layout are structure.
|
|
387
|
+
- **Which pages read it**: go by the **Android source** — find every reader of the field (LiveData / StateFlow / getter) in source (observe / collect / binding expressions) and map each reader's Activity / Fragment to a UTG page; do not look only at this group's own pages. When this group cannot see the reference of one of those captured pages, do not mock; report it as a `shell requests` entry (state the field, the reader pages and the suggested mock value), and the parent task decides in Step 5.5 against all references.
|
|
388
|
+
- **Who writes it**: only the group whose write set contains that shared VM / Model file (the host-chain group, see step5-convert.md) writes the mock, and only once; other groups that render the same field do not, and report it as `shell requests` if they find it still empty.
|
|
389
|
+
Counter-example: when content data hangs off a cross-page shared VM, never mocking "shared VM fields" leaves the page's lists empty while every captured reference has data.
|
|
390
|
+
- **How the hard size requirement is relaxed**: with no constraint-solver result from a reference view tree, the only legitimate source for width/height is `xml-explicit-dp`; `wrap_content` → set no size (let the content decide); `match_parent` → `'100%'`; `0dp`+constraints / `layout_weight` → `.layoutWeight()` or alignment relations. Substituting an estimated constant for a constraint-solver result is **still forbidden**. The position-anchor rules are completely unchanged (they only ever looked at the Android-side intent).
|
|
391
|
+
|
|
392
|
+
**Phase 4.3 → generation**:
|
|
393
|
+
- **Colours**: resolve the `?attr/` → theme → style chain down to a concrete resource; when it resolves to a Material dynamic colour or a framework colour (a fallback replacement entry in resource_mapping), prefer the same-role value already adopted from measurement on a captured page in the project token table, labelled `template-measured`; otherwise use the mapping's fallback value labelled `framework-default(uncalibrated)`.
|
|
394
|
+
- **Framework widget appearance** (Toolbar, FAB, BottomSheet, AlertDialog, Chip, Preference row): prefer reusing the same kind of component a captured page has already produced over deriving it again.
|
|
395
|
+
- **Font size / line height**: resolve from `textAppearance` / style; when it cannot be resolved, use `framework-default` and list it in the report.
|
|
396
|
+
|
|
397
|
+
**Adjusted criteria for the Phase 5 items in this tier** (items not listed are completely unchanged):
|
|
398
|
+
- **Main Region Evidence**: label the source of every width/height as `xml-explicit-dp` / `wrap_content` / `constraint→layoutWeight` / `template-measured`; normalized ratios are not required (there is no reference to compute them from).
|
|
399
|
+
- **Visible Resource Closure**: "state shown in the reference screenshot → variant" becomes "**source initial state (and the chosen mock state) → the variant your rule selects**"; still do the back-substitution check.
|
|
400
|
+
- **Static Clipping Check**: check against the layout hierarchy and size declarations, not screenshot proportions.
|
|
401
|
+
- **Window Mode Evidence**: screenshots were never allowed for this decision; unchanged.
|
|
402
|
+
- **Transition Implementation Evidence**: unchanged (it was always recorded from source); skip the "cross-check against snapshots" step and note "source-only, no snapshot".
|
|
403
|
+
|
|
404
|
+
**An extra report section `Uncalibrated Items`**: list every value labelled `framework-default(uncalibrated)`, every visible state decided by mock data, and every visual judgment that could not be confirmed for lack of a screenshot. Entries for uncaptured attached nodes start with `<host page> / <node id>`. This section feeds the parent flow's Step 7 "Source-only pages awaiting visual calibration" and is the work list for calibration once screenshots are available.
|
|
405
|
+
|
|
406
|
+
## Global guidelines
|
|
407
|
+
|
|
408
|
+
- **Strict fidelity**: layout structure, component hierarchy and resource references must correspond one-to-one with the Android source; do not add/remove/reorder UI elements
|
|
409
|
+
- **Exact resource matching**: every color/string/dimension/image must have a corresponding HarmonyOS resource; do not hard-code
|
|
410
|
+
- **Compilability is mandatory**: wire real events where the target is implemented; mock only where it is not
|
|
411
|
+
- Declarative ArkUI only; never write imperative DOM manipulation
|
|
412
|
+
- Resources are always `$r('app.type.name')`
|
|
413
|
+
- Leave `// TODO:` comments for: business logic, ViewModel data binding, unconverted target Activities, mock data
|
|
414
|
+
- Responsive layout: prefer percentage widths + Flex; use fixed sizes sparingly
|
|
415
|
+
- Accessibility: `content-desc` → `.accessibilityText()` **+** `.accessibilityDescription()` (same value; `uitest` only exports the latter's `description` field, so an icon-only control that writes only the former has no readable label at runtime); meaningful `text` → the correct label; the selected state of segmented controls/tabs/chips → `.accessibilitySelected(<the same state that drives the visual selection>)`. An Image's `contentDescription` is **not** `.alt()` (that is a placeholder image). Check each GATE `a11y-content-desc-unobservable` against the Android view tree
|
|
416
|
+
- When nesting exceeds 5 levels, split the related UI into `@Component` subcomponents
|
|
417
|
+
- If any mapping file is missing/empty: continue with built-in knowledge and note it in the report
|