@buaa_smat/hometrans 26.0.0-devecocli.2 → 26.0.0-devecocli.4
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/LICENSE +21 -21
- package/package.json +1 -1
- package/plugin.jsonc +1 -1
- package/skills/a2h-app-migrate/references/specs.example.json +19 -19
- package/skills/a2h-app-migrate/scripts/env_preflight.mjs +38 -14
- package/skills/a2h-app-migrate/scripts/infer_android_root.mjs +3 -3
- package/skills/a2h-app-migrate/scripts/json_io.mjs +35 -35
- package/skills/a2h-app-migrate/scripts/lib-yaml-lite.mjs +288 -288
- package/skills/a2h-app-migrate/scripts/paths_preflight.mjs +183 -15
- package/skills/a2h-app-migrate/test/test_arch_done.mjs +54 -54
- package/skills/a2h-app-migrate/test/test_env_requirements.mjs +40 -1
- package/skills/a2h-app-migrate/test/test_gate_checkpoint.mjs +146 -146
- package/skills/a2h-app-migrate/test/test_hmos_fingerprint.mjs +68 -68
- package/skills/a2h-app-migrate/test/test_json_io.mjs +32 -32
- package/skills/a2h-app-migrate/test/test_module_docs_done.mjs +53 -53
- package/skills/a2h-app-migrate/test/test_parse_args.mjs +69 -69
- package/skills/a2h-app-migrate/test/test_preflight_report.mjs +11 -1
- package/skills/a2h-app-migrate/test/test_spec_pipeline_done.mjs +181 -181
- package/skills/a2h-app-migrate/test/test_ui_batch_done.mjs +53 -53
- package/skills/a2h-app-migrate/test/test_ui_batch_gate.mjs +226 -226
- package/skills/a2h-app-migrate/test/test_uniapp_preflight.mjs +83 -0
- package/skills/a2h-app-migrate/test/test_utg_dirs.mjs +39 -39
- package/skills/a2h-arch-generate/examples/reconcile-existing-project.md +107 -107
- package/skills/a2h-arch-generate/examples/simple-conversion-android.md +103 -103
- package/skills/a2h-arch-generate/examples/simple-conversion-backend.md +70 -70
- package/skills/a2h-arch-generate/examples/simple-conversion-uniapp.md +106 -106
- package/skills/a2h-arch-generate/references/arkts-mvvm-v2.md +1407 -1407
- package/skills/a2h-arch-generate/references/artifact-contracts.generate.md +120 -120
- package/skills/a2h-arch-generate/references/artifact-contracts.reconcile.md +123 -123
- package/skills/a2h-arch-generate/references/bpta-layered-architecture-design.md +87 -87
- package/skills/a2h-arch-generate/references/database-schema-recovery.md +107 -107
- package/skills/a2h-arch-generate/references/existing-target-annotation.md +68 -68
- package/skills/a2h-arch-generate/references/harmony-project-inspection.md +150 -150
- package/skills/a2h-arch-generate/references/harmony-target-architecture.md +94 -94
- package/skills/a2h-arch-generate/references/reconciliation-model.md +204 -204
- package/skills/a2h-arch-generate/references/scope-policy.md +28 -28
- package/skills/a2h-arch-generate/references/semantic-review.md +65 -65
- package/skills/a2h-arch-generate/references/source-ecosystems.md +54 -54
- package/skills/a2h-arch-generate/references/transformation-model.md +78 -78
- package/skills/a2h-arch-generate/scripts/create_project.mjs +149 -149
- package/skills/a2h-arch-generate/scripts/generate_state.mjs +60 -60
- package/skills/a2h-arch-generate/scripts/inspect_and_route.mjs +326 -326
- package/skills/a2h-arch-generate/scripts/inspect_uniapp_project.mjs +809 -809
- package/skills/a2h-arch-generate/scripts/lib/py_compat.mjs +1454 -1454
- package/skills/a2h-arch-generate/scripts/module_create/create.mjs +136 -136
- package/skills/a2h-arch-generate/scripts/module_create/generate.mjs +636 -636
- package/skills/a2h-arch-generate/scripts/module_create/hap/build-profile.json5 +32 -32
- package/skills/a2h-arch-generate/scripts/module_create/hap/hvigorfile.ts +5 -5
- package/skills/a2h-arch-generate/scripts/module_create/hap/obfuscation-rules.txt +22 -22
- package/skills/a2h-arch-generate/scripts/module_create/hap/oh-package.json5 +10 -10
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/ets/applicationability/ApplicationAbility.ets +43 -43
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/ets/pages/Index.ets +22 -22
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/module.json5 +25 -25
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/resources/base/element/color.json +7 -7
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/resources/base/element/float.json +8 -8
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/resources/base/element/string.json +15 -15
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/resources/base/media/layered_image.json +6 -6
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/main/resources/base/profile/main_pages.json +5 -5
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/mock/mock-config.json5 +1 -1
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/ohosTest/ets/test/Ability.test.ets +34 -34
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/ohosTest/ets/test/List.test.ets +4 -4
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/ohosTest/module.json5 +11 -11
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/test/List.test.ets +4 -4
- package/skills/a2h-arch-generate/scripts/module_create/hap/src/test/LocalUnit.test.ets +32 -32
- package/skills/a2h-arch-generate/scripts/module_create/har/Index.ets +1 -1
- package/skills/a2h-arch-generate/scripts/module_create/har/build-profile.json5 +36 -36
- package/skills/a2h-arch-generate/scripts/module_create/har/hvigorfile.ts +5 -5
- package/skills/a2h-arch-generate/scripts/module_create/har/obfuscation-rules.txt +22 -22
- package/skills/a2h-arch-generate/scripts/module_create/har/oh-package.json5 +9 -9
- package/skills/a2h-arch-generate/scripts/module_create/har/src/main/ets/components/MainPage.ets +19 -19
- package/skills/a2h-arch-generate/scripts/module_create/har/src/main/module.json5 +9 -9
- package/skills/a2h-arch-generate/scripts/module_create/har/src/main/resources/base/element/float.json +8 -8
- package/skills/a2h-arch-generate/scripts/module_create/har/src/main/resources/base/element/string.json +8 -8
- package/skills/a2h-arch-generate/scripts/module_create/har/src/ohosTest/ets/test/Ability.test.ets +34 -34
- package/skills/a2h-arch-generate/scripts/module_create/har/src/ohosTest/ets/test/List.test.ets +4 -4
- package/skills/a2h-arch-generate/scripts/module_create/har/src/ohosTest/module.json5 +11 -11
- package/skills/a2h-arch-generate/scripts/module_create/har/src/test/List.test.ets +4 -4
- package/skills/a2h-arch-generate/scripts/module_create/har/src/test/LocalUnit.test.ets +32 -32
- package/skills/a2h-arch-generate/scripts/module_create/hsp/build-profile.json5 +35 -35
- package/skills/a2h-arch-generate/scripts/module_create/hsp/hvigorfile.ts +5 -5
- package/skills/a2h-arch-generate/scripts/module_create/hsp/obfuscation-rules.txt +22 -22
- package/skills/a2h-arch-generate/scripts/module_create/hsp/oh-package.json5 +9 -9
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/main/ets/pages/Index.ets +19 -19
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/main/ets/utils/Calc.ets +2 -2
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/main/module.json5 +11 -11
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/main/resources/base/element/float.json +8 -8
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/main/resources/base/element/string.json +7 -7
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/main/resources/base/profile/main_pages.json +5 -5
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/ohosTest/ets/test/Ability.test.ets +34 -34
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/ohosTest/ets/test/List.test.ets +4 -4
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/ohosTest/module.json5 +10 -10
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/test/List.test.ets +4 -4
- package/skills/a2h-arch-generate/scripts/module_create/hsp/src/test/LocalUnit.test.ets +32 -32
- package/skills/a2h-arch-generate/scripts/module_create/testdata/reconcile-layer-PROJECT_DESIGN.md +47 -47
- package/skills/a2h-arch-generate/scripts/module_create/testdata/single-entry-PROJECT_DESIGN.md +15 -15
- package/skills/a2h-arch-generate/scripts/module_create/testdata/three-layer-PROJECT_DESIGN.md +36 -36
- package/skills/a2h-arch-generate/scripts/resolve_android_stores.mjs +529 -529
- package/skills/a2h-arch-generate/scripts/scaffold_project.mjs +230 -230
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/build.gradle +11 -11
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/src/main/AndroidManifest.xml +12 -12
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/src/main/java/com/example/notes/MainActivity.kt +8 -8
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/app/src/main/java/com/example/notes/NotesStore.kt +17 -17
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/build.gradle +3 -3
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/android_source/settings.gradle +1 -1
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/AppScope/app.json5 +8 -8
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/build-profile.json5 +14 -14
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/common/utils/build-profile.json5 +7 -7
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/common/utils/oh-package.json5 +1 -1
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/common/utils/src/main/ets/utils/Format.ets +3 -3
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/home/build-profile.json5 +7 -7
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/home/oh-package.json5 +1 -1
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/home/src/main/ets/pages/Home.ets +3 -3
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/sync/build-profile.json5 +7 -7
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/sync/oh-package.json5 +1 -1
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/features/sync/src/main/ets/engine/SyncEngine.ets +3 -3
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/hvigorfile.ts +1 -1
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/oh-package.json5 +1 -1
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/products/app/build-profile.json5 +7 -7
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/products/app/oh-package.json5 +9 -9
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/harmony_target/products/app/src/main/ets/pages/Index.ets +7 -7
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/App.vue +10 -10
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/manifest.json +6 -6
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/pages/index/index.vue +16 -16
- package/skills/a2h-arch-generate/scripts/tests/e2e/fixtures/uniapp_source/pages.json +5 -5
- package/skills/a2h-arch-generate/scripts/tests/test_console_encoding.mjs +52 -52
- package/skills/a2h-arch-generate/scripts/tests/test_git_root.mjs +34 -34
- package/skills/a2h-arch-generate/scripts/tests/test_router.mjs +138 -138
- package/skills/a2h-arch-generate/scripts/validate_data_docs.mjs +937 -937
- package/skills/a2h-arch-generate/scripts/validate_homegraph_artifacts.mjs +542 -542
- package/skills/a2h-arch-generate/scripts/validate_incremental_docs.mjs +415 -415
- package/skills/a2h-arkts-logic-coder/references/ISSUES.md +6 -6
- package/skills/a2h-arkts-logic-coder/scripts/check_module_scope.ts +224 -224
- package/skills/a2h-arkts-logic-coder/scripts/check_mvvm.ts +377 -377
- package/skills/a2h-arkts-logic-coder/scripts/stop_check_hook.ts +443 -443
- package/skills/a2h-arkts-logic-coder/scripts/test_check_scripts.ts +211 -211
- package/skills/a2h-arkts-logic-coder/scripts/test_worktree_compat.ts +81 -81
- package/skills/a2h-batch-ui-align/SKILL.md +19 -7
- package/skills/a2h-batch-ui-align/flowchart.html +271 -271
- package/skills/a2h-batch-ui-align/references/conversion-procedure.md +57 -8
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-atomic-component-mapping-reference.md +2535 -2533
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-interaction-mapping-reference.md +558 -558
- package/skills/a2h-batch-ui-align/references/mappings/android-to-harmonyOS-ui-layout-mapping-reference.md +117 -117
- package/skills/a2h-batch-ui-align/references/mvvm/@Link/350/243/205/351/245/260/345/231/250/357/274/232/347/210/266/345/255/220/345/217/214/345/220/221/345/220/214/346/255/245.md +648 -648
- package/skills/a2h-batch-ui-align/references/mvvm/@Observed/350/243/205/351/245/260/345/231/250/345/222/214@ObjectLink/350/243/205/351/245/260/345/231/250/357/274/232/345/265/214/345/245/227/347/261/273/345/257/271/350/261/241/345/261/236/346/200/247/345/217/230/345/214/226.md +2088 -2088
- package/skills/a2h-batch-ui-align/references/mvvm/@Prop/350/243/205/351/245/260/345/231/250/357/274/232/347/210/266/345/255/220/345/215/225/345/220/221/345/220/214/346/255/245.md +1033 -1033
- package/skills/a2h-batch-ui-align/references/mvvm/@Provide/350/243/205/351/245/260/345/231/250/345/222/214@Consume/350/243/205/351/245/260/345/231/250/357/274/232/344/270/216/345/220/216/344/273/243/347/273/204/344/273/266/345/217/214/345/220/221/345/220/214/346/255/245.md +1183 -1183
- package/skills/a2h-batch-ui-align/references/mvvm/@State/350/243/205/351/245/260/345/231/250/357/274/232/347/273/204/344/273/266/345/206/205/347/212/266/346/200/201.md +576 -576
- package/skills/a2h-batch-ui-align/references/mvvm/@Track/350/243/205/351/245/260/345/231/250/357/274/232class/345/257/271/350/261/241/345/261/236/346/200/247/347/272/247/346/233/264/346/226/260.md +297 -297
- package/skills/a2h-batch-ui-align/references/mvvm/@Watch/350/243/205/351/245/260/345/231/250/357/274/232/347/212/266/346/200/201/345/217/230/351/207/217/346/233/264/346/224/271/351/200/232/347/237/245.md +395 -395
- package/skills/a2h-batch-ui-align/references/mvvm/AppStorage/357/274/232/345/272/224/347/224/250/345/205/250/345/261/200/347/232/204UI/347/212/266/346/200/201/345/255/230/345/202/250.md +902 -902
- package/skills/a2h-batch-ui-align/references/mvvm/Environment/357/274/232/350/256/276/345/244/207/347/216/257/345/242/203/346/237/245/350/257/242.md +106 -106
- package/skills/a2h-batch-ui-align/references/mvvm/LocalStorage/357/274/232/351/241/265/351/235/242/347/272/247UI/347/212/266/346/200/201/345/255/230/345/202/250.md +1178 -1178
- package/skills/a2h-batch-ui-align/references/mvvm/MVVM/346/250/241/345/274/217/357/274/210V1/357/274/211.md +911 -911
- package/skills/a2h-batch-ui-align/references/mvvm/PersistentStorage/357/274/232/346/214/201/344/271/205/345/214/226/345/255/230/345/202/250UI/347/212/266/346/200/201.md +354 -354
- package/skills/a2h-batch-ui-align/references/mvvm//347/256/241/347/220/206/345/272/224/347/224/250/346/213/245/346/234/211/347/232/204/347/212/266/346/200/201/346/246/202/350/277/260.md +11 -11
- package/skills/a2h-batch-ui-align/references/mvvm-v2/!!/350/257/255/346/263/225/357/274/232/345/217/214/345/220/221/347/273/221/345/256/232.md +206 -206
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Computed/350/243/205/351/245/260/345/231/250/357/274/232/350/256/241/347/256/227/345/261/236/346/200/247.md +373 -373
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Event/350/243/205/351/245/260/345/231/250/357/274/232/350/247/204/350/214/203/347/273/204/344/273/266/350/276/223/345/207/272.md +158 -158
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Local/350/243/205/351/245/260/345/231/250/357/274/232/347/273/204/344/273/266/345/206/205/351/203/250/347/212/266/346/200/201.md +750 -750
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Monitor/350/243/205/351/245/260/345/231/250/357/274/232/347/212/266/346/200/201/345/217/230/351/207/217/344/277/256/346/224/271/345/274/202/346/255/245/347/233/221/345/220/254.md +1704 -1704
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@ObservedV2/350/243/205/351/245/260/345/231/250/345/222/214@Trace/350/243/205/351/245/260/345/231/250/357/274/232/347/261/273/345/261/236/346/200/247/345/217/230/345/214/226/350/247/202/346/265/213.md +1012 -1012
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Once/350/243/205/351/245/260/345/231/250/357/274/232/345/210/235/345/247/213/345/214/226/345/220/214/346/255/245/344/270/200/346/254/241.md +164 -164
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Param/350/243/205/351/245/260/345/231/250/357/274/232/347/273/204/344/273/266/345/244/226/351/203/250/350/276/223/345/205/245.md +840 -840
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Provider/350/243/205/351/245/260/345/231/250/345/222/214@Consumer/350/243/205/351/245/260/345/231/250/357/274/232/350/267/250/347/273/204/344/273/266/345/261/202/347/272/247/345/217/214/345/220/221/345/220/214/346/255/245.md +856 -856
- package/skills/a2h-batch-ui-align/references/mvvm-v2/@Type/350/243/205/351/245/260/345/231/250/357/274/232/346/240/207/350/256/260/347/261/273/345/261/236/346/200/247/347/232/204/347/261/273/345/236/213.md +83 -83
- package/skills/a2h-batch-ui-align/references/mvvm-v2/AppStorageV2/357/274/232/345/272/224/347/224/250/345/205/250/345/261/200UI/347/212/266/346/200/201/345/255/230/345/202/250.md +294 -294
- package/skills/a2h-batch-ui-align/references/mvvm-v2/MVVM/346/250/241/345/274/217/357/274/210V2/357/274/211.md +1407 -1407
- package/skills/a2h-batch-ui-align/references/mvvm-v2/PersistenceV2/357/274/232/346/214/201/344/271/205/345/214/226/345/255/230/345/202/250UI/347/212/266/346/200/201.md +1220 -1220
- package/skills/a2h-batch-ui-align/references/mvvm-v2/_/350/214/203/345/274/217/351/200/211/346/213/251/350/257/264/346/230/216.md +47 -47
- package/skills/a2h-batch-ui-align/references/mvvm-v2/_/350/243/205/351/245/260/345/231/250/351/200/237/346/237/245.md +133 -133
- package/skills/a2h-batch-ui-align/references/mvvm-v2//347/212/266/346/200/201/347/256/241/347/220/206V1/345/220/221V2/350/277/201/347/247/273/344/270/216/346/267/267/347/224/250/346/214/207/345/257/274.md +840 -840
- package/skills/a2h-batch-ui-align/references/step3-capture.md +4 -1
- package/skills/a2h-batch-ui-align/references/step4-prepare.md +7 -3
- package/skills/a2h-batch-ui-align/references/step5-convert.md +8 -5
- package/skills/a2h-batch-ui-align/scripts/answers_check.mjs +86 -86
- package/skills/a2h-batch-ui-align/scripts/arkts_static_check.ts +1191 -2
- package/skills/a2h-batch-ui-align/scripts/build_conversion_set.mjs +1675 -1656
- package/skills/a2h-batch-ui-align/scripts/databinding_analyzer_design.md +79 -79
- package/skills/a2h-batch-ui-align/scripts/detach.mjs +258 -258
- package/skills/a2h-batch-ui-align/scripts/export_ui_info.mjs +130 -10
- package/skills/a2h-batch-ui-align/scripts/generate_pages_json.mjs +612 -612
- package/skills/a2h-batch-ui-align/scripts/group_commit.mjs +166 -166
- package/skills/a2h-batch-ui-align/scripts/group_pack.mjs +1627 -1437
- package/skills/a2h-batch-ui-align/scripts/group_queue.mjs +1869 -1869
- package/skills/a2h-batch-ui-align/scripts/harmony_index.mjs +218 -218
- package/skills/a2h-batch-ui-align/scripts/host_env.mjs +208 -208
- package/skills/a2h-batch-ui-align/scripts/phase5_check.mjs +1179 -1124
- package/skills/a2h-batch-ui-align/scripts/shell_contract.mjs +1036 -996
- package/skills/a2h-batch-ui-align/scripts/tests/agent_cli.test.mjs +217 -217
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_align_tint.test.mjs +253 -253
- 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 +241 -0
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_layout_placement.test.mjs +365 -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_rules.test.mjs +365 -365
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_shell.test.mjs +91 -72
- package/skills/a2h-batch-ui-align/scripts/tests/arkts_static_check_weight_color.test.mjs +120 -0
- package/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set.test.mjs +356 -345
- package/skills/a2h-batch-ui-align/scripts/tests/build_conversion_set_scope.test.mjs +290 -290
- 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 +57 -0
- package/skills/a2h-batch-ui-align/scripts/tests/generate_pages_json.test.mjs +123 -123
- package/skills/a2h-batch-ui-align/scripts/tests/group_commit.test.mjs +126 -126
- package/skills/a2h-batch-ui-align/scripts/tests/group_pack.test.mjs +241 -189
- package/skills/a2h-batch-ui-align/scripts/tests/group_queue.test.mjs +1451 -1451
- package/skills/a2h-batch-ui-align/scripts/tests/group_watch.test.mjs +215 -215
- package/skills/a2h-batch-ui-align/scripts/tests/harmony_index.test.mjs +95 -95
- package/skills/a2h-batch-ui-align/scripts/tests/host_env.test.mjs +115 -115
- package/skills/a2h-batch-ui-align/scripts/tests/phase5_check.test.mjs +244 -244
- package/skills/a2h-batch-ui-align/scripts/tests/shell_contract.test.mjs +166 -130
- package/skills/a2h-batch-ui-align/scripts/tests/test_bfs_exit.ts +49 -49
- package/skills/a2h-batch-ui-align/scripts/tests/text_color_diff.test.mjs +219 -0
- package/skills/a2h-batch-ui-align/scripts/text_color_diff.mjs +470 -0
- package/skills/a2h-dashboard-render/references/artifact-registry-spec.md +67 -67
- package/skills/a2h-dashboard-render/references/dashboard.config.example.json +19 -19
- package/skills/a2h-dashboard-render/scripts/artifact_contract.mjs +138 -138
- package/skills/a2h-dashboard-render/scripts/check-registry.mjs +87 -87
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/expected.json +155 -155
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/hmos.json +1 -1
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/list.xml +1 -1
- package/skills/a2h-dashboard-render/test/fixtures/page_capture/nested_scroll.xml +1 -1
- package/skills/a2h-dashboard-render/test/test_cli_check_registry.mjs +99 -99
- package/skills/a2h-dashboard-render/test/test_dashboard_build.mjs +64 -64
- package/skills/a2h-dashboard-render/test/test_page_capture.mjs +147 -147
- package/skills/a2h-fix-build-errors/references/arkts-strict-patterns.md +219 -219
- package/skills/a2h-fix-build-errors/references/known-patterns.md +157 -157
- package/skills/a2h-fix-build-errors/references/rdb-entity-pattern.md +131 -131
- package/skills/a2h-module-semantic-docs/scripts/commit_module_state.mjs +168 -168
- package/skills/a2h-module-semantic-docs/scripts/lib/py_compat.mjs +688 -688
- package/skills/a2h-module-semantic-docs/scripts/scan_modules.mjs +1021 -1021
- package/skills/a2h-module-semantic-docs/test/golden/module_structure.json +187 -187
- package/skills/a2h-module-semantic-docs/test/golden/module_understanding.json +351 -351
- package/skills/a2h-module-semantic-docs/test/golden/module_update_plan.json +495 -495
- package/skills/a2h-module-semantic-docs/test/golden/project_directory_structure.json +157 -157
- package/skills/a2h-module-semantic-docs/test/test_scan_and_commit.mjs +388 -388
- package/skills/a2h-resource-convert/references/code-vector-icon-rules.md +335 -335
- package/skills/a2h-resource-convert/references/conversion-rules.md +687 -687
- package/skills/a2h-resource-convert/references/dependency-analysis-rules.md +410 -410
- package/skills/a2h-resource-convert/references/incremental-page-migration.md +250 -250
- package/skills/a2h-resource-convert/references/lottie-conversion-rules.md +219 -219
- package/skills/a2h-resource-convert/references/resource-mapping-rules.md +493 -493
- package/skills/a2h-resource-convert/references/step3_5-dependency-filter.md +54 -54
- package/skills/a2h-resource-convert/references/step4-qualifiers-and-values.md +142 -142
- package/skills/a2h-resource-convert/references/step4-resource-types.md +249 -249
- package/skills/a2h-resource-convert/references/step5-reference-resolution.md +154 -154
- package/skills/a2h-resource-convert/references/step7-report-template.md +217 -217
- package/skills/a2h-resource-convert/references/xml-drawable-to-svg-rules.md +630 -630
- package/skills/a2h-resource-convert/scripts/a2h_resource_convert.ts +2529 -2529
- package/skills/a2h-resource-convert/scripts/a2h_resource_incremental.ts +1072 -1072
- package/skills/a2h-resource-convert/scripts/code_vector_icons.ts +607 -607
- package/skills/a2h-resource-convert/scripts/extract_page_resources.ts +989 -989
- package/skills/a2h-resource-convert/scripts/extract_project_resources.ts +1464 -1464
- package/skills/a2h-resource-convert/scripts/svg_fidelity_check.ts +632 -632
- package/skills/a2h-resource-convert/scripts/tests/adaptive_icon.test.mjs +182 -182
- package/skills/a2h-spec-design/scripts/inspect_spec_design_inputs.mjs +146 -146
- package/skills/a2h-spec-design/scripts/lib/py_compat.mjs +481 -481
- package/skills/a2h-spec-design/scripts/move_spec_technical_reference.mjs +159 -159
- package/skills/a2h-spec-design/scripts/resolve_module_design.mjs +102 -102
- package/skills/a2h-spec-design/scripts/validate_spec_design_output.mjs +285 -285
- package/skills/a2h-spec-design/test/golden/inspect_happy.json +20 -20
- package/skills/a2h-spec-design/test/golden/move_design.md +18 -18
- package/skills/a2h-spec-design/test/golden/move_spec.md +7 -7
- package/skills/a2h-spec-design/test/golden/resolve_cases.json +36 -36
- package/skills/a2h-spec-design/test/golden/validate_issue_file.md +12 -12
- package/skills/a2h-spec-design/test/golden/validate_issues.json +57 -57
- package/skills/a2h-spec-design/test/test_spec_design_scripts.mjs +381 -381
- package/skills/a2h-spec-design-pipeline/package.json +4 -4
- package/skills/a2h-spec-design-pipeline/references/execution-model.md +69 -69
- package/skills/a2h-spec-design-pipeline/references/final-report-template.md +24 -24
- package/skills/a2h-spec-design-pipeline/references/specs.example.json +19 -19
- package/skills/a2h-spec-design-pipeline/scripts/atomic_write.ts +42 -42
- package/skills/a2h-spec-design-pipeline/scripts/audit_claims.ts +252 -252
- package/skills/a2h-spec-design-pipeline/scripts/branch_landed.ts +77 -77
- package/skills/a2h-spec-design-pipeline/scripts/deps_ready.ts +195 -195
- package/skills/a2h-spec-design-pipeline/scripts/git_baseline.ts +124 -124
- package/skills/a2h-spec-design-pipeline/scripts/lib/bgcli.mjs +95 -95
- package/skills/a2h-spec-design-pipeline/scripts/plan_waves.ts +475 -475
- package/skills/a2h-spec-design-pipeline/scripts/resolve_wiring.ts +164 -164
- package/skills/a2h-spec-design-pipeline/scripts/test_atomic_write.ts +44 -44
- package/skills/a2h-spec-design-pipeline/scripts/test_audit_claims.ts +301 -301
- package/skills/a2h-spec-design-pipeline/scripts/test_bgcli.mjs +64 -64
- package/skills/a2h-spec-design-pipeline/scripts/test_branch_landed.ts +87 -87
- package/skills/a2h-spec-design-pipeline/scripts/test_deps_ready.ts +265 -265
- package/skills/a2h-spec-design-pipeline/scripts/test_git_baseline.ts +105 -105
- package/skills/a2h-spec-design-pipeline/scripts/test_plan_waves.ts +561 -561
- package/skills/a2h-spec-design-pipeline/scripts/test_resolve_wiring.ts +138 -138
- package/skills/a2h-spec-design-pipeline/scripts/test_watchdog.mjs +289 -289
- package/skills/a2h-spec-design-pipeline/scripts/watchdog.mjs +441 -441
- package/skills/a2h-spec-generate/scripts/parse_requirements.ts +515 -515
- package/skills/a2h-spec-generate/template/REQ.txt +22 -22
- package/skills/a2h-spec-generate/test/detect-project.test.mjs +37 -37
- package/skills/a2h-spec-generate/test/fixtures/android/app/src/main/AndroidManifest.xml +3 -3
- package/skills/a2h-spec-generate/test/fixtures/android/build.gradle +3 -3
- package/skills/a2h-spec-generate/test/fixtures/android/settings.gradle +3 -3
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/package.json +9 -9
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/App.vue +8 -8
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/components/MyCard.vue +9 -9
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/feature/editor/index.vue +1 -1
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/main.ts +6 -6
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/manifest.json +4 -4
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/detail/index.vue +1 -1
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/home/index.vue +33 -33
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages/settings/index.vue +1 -1
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/pages.json +23 -23
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/src/services/items.ts +3 -3
- package/skills/a2h-spec-generate/test/fixtures/uniapp-src/tsconfig.json +8 -8
- package/skills/a2h-spec-generate/test/fixtures/unknown/README.txt +1 -1
- package/skills/a2h-spec-generate/test/inspect-uniapp.test.mjs +54 -54
- package/skills/a2h-utg-explorer/SKILL.md +1 -1
- package/skills/a2h-utg-explorer/assets/final_viewer.html +64 -64
- package/skills/a2h-utg-explorer/assets/u2.LICENSE +21 -21
- package/skills/a2h-utg-explorer/assets/u2.NOTICE +25 -25
- package/skills/a2h-utg-explorer/references/protocol.md +9 -9
- package/skills/a2h-utg-explorer/scripts/app_settings.mjs +143 -143
- package/skills/a2h-utg-explorer/scripts/close_phases.mjs +66 -66
- package/skills/a2h-utg-explorer/scripts/d_prereqs.mjs +597 -597
- package/skills/a2h-utg-explorer/scripts/device_health.mjs +227 -227
- package/skills/a2h-utg-explorer/scripts/evidence.mjs +108 -108
- package/skills/a2h-utg-explorer/scripts/final_utg.mjs +61 -9
- package/skills/a2h-utg-explorer/scripts/hint_check.mjs +89 -89
- package/skills/a2h-utg-explorer/scripts/plan.mjs +258 -258
- package/skills/a2h-utg-explorer/scripts/promote_dynamic.mjs +170 -170
- package/skills/a2h-utg-explorer/scripts/recover_d.mjs +380 -302
- package/skills/a2h-utg-explorer/scripts/report.mjs +143 -143
- package/skills/a2h-utg-explorer/scripts/run_cycle.mjs +18 -2
- package/skills/a2h-utg-explorer/scripts/run_device.mjs +137 -137
- package/skills/a2h-utg-explorer/scripts/tests/attest.test.mjs +66 -66
- package/skills/a2h-utg-explorer/scripts/tests/chain.test.mjs +45 -45
- package/skills/a2h-utg-explorer/scripts/tests/compose_identity.test.mjs +37 -1
- package/skills/a2h-utg-explorer/scripts/tests/coverage_rules.test.mjs +104 -104
- package/skills/a2h-utg-explorer/scripts/tests/d_prereqs.test.mjs +223 -223
- package/skills/a2h-utg-explorer/scripts/tests/device_health.test.mjs +88 -88
- package/skills/a2h-utg-explorer/scripts/tests/device_lock_retry.test.mjs +187 -187
- package/skills/a2h-utg-explorer/scripts/tests/direct_launch.test.mjs +130 -130
- package/skills/a2h-utg-explorer/scripts/tests/explorer_review_fixes.test.mjs +136 -136
- package/skills/a2h-utg-explorer/scripts/tests/final_utg.test.mjs +135 -135
- package/skills/a2h-utg-explorer/scripts/tests/generalization_fixes.test.mjs +251 -251
- package/skills/a2h-utg-explorer/scripts/tests/hint_check.test.mjs +42 -42
- package/skills/a2h-utg-explorer/scripts/tests/interruptions.test.mjs +162 -162
- package/skills/a2h-utg-explorer/scripts/tests/node_coverage.test.mjs +193 -193
- package/skills/a2h-utg-explorer/scripts/tests/overflow_prefix.test.mjs +204 -204
- package/skills/a2h-utg-explorer/scripts/tests/page_identity_tiers.test.mjs +355 -355
- package/skills/a2h-utg-explorer/scripts/tests/pipeline.test.mjs +240 -240
- package/skills/a2h-utg-explorer/scripts/tests/recover_b.test.mjs +173 -173
- package/skills/a2h-utg-explorer/scripts/tests/recover_d.test.mjs +280 -207
- package/skills/a2h-utg-explorer/scripts/tests/review_fixes.test.mjs +213 -213
- package/skills/a2h-utg-explorer/scripts/tests/robustness_fixes.test.mjs +345 -345
- package/skills/a2h-utg-explorer/scripts/tests/runner_capabilities.test.mjs +131 -131
- package/skills/a2h-utg-explorer/scripts/tests/scope.test.mjs +229 -229
- package/skills/a2h-utg-explorer/scripts/tests/scroll_sweep.test.mjs +336 -321
- package/skills/a2h-utg-explorer/scripts/tests/semantics.test.mjs +102 -102
- package/skills/a2h-utg-explorer/scripts/tests/state_ambiguity.test.mjs +92 -0
- package/skills/a2h-utg-explorer/scripts/tests/u2_backend.test.mjs +346 -346
- package/skills/a2h-utg-explorer/scripts/tests/worklist_parts.test.mjs +24 -24
- package/skills/a2h-utg-explorer/scripts/utg_explorer/_device_io.mjs +244 -244
- package/skills/a2h-utg-explorer/scripts/utg_explorer/_py.mjs +2097 -2097
- package/skills/a2h-utg-explorer/scripts/utg_explorer/adapters.mjs +18 -0
- package/skills/a2h-utg-explorer/scripts/utg_explorer/attest.mjs +63 -63
- package/skills/a2h-utg-explorer/scripts/utg_explorer/chain.mjs +63 -63
- package/skills/a2h-utg-explorer/scripts/utg_explorer/coverage.mjs +89 -89
- package/skills/a2h-utg-explorer/scripts/utg_explorer/device_lock.mjs +46 -46
- package/skills/a2h-utg-explorer/scripts/utg_explorer/semantics.mjs +66 -2
- package/skills/a2h-utg-explorer/scripts/utg_explorer/task_runner.mjs +53 -4
- package/skills/a2h-utg-explorer/scripts/variant.mjs +75 -75
- package/skills/a2h-utg-explorer/scripts/worklist_parts.mjs +122 -122
- package/skills/a2h-utg-static/config.json +19 -19
- package/skills/a2h-utg-static/references/ui-elements-static-utg-schema.md +248 -248
- package/skills/a2h-utg-static/references/view-interactions.md +215 -215
- package/skills/a2h-utg-static/scripts/_graph.mjs +361 -361
- package/skills/a2h-utg-static/scripts/_py.mjs +2177 -2177
- package/skills/a2h-utg-static/scripts/_spawn.mjs +45 -45
- package/skills/a2h-utg-static/scripts/activity_widgets.mjs +254 -254
- package/skills/a2h-utg-static/scripts/adapter_nav.mjs +229 -229
- package/skills/a2h-utg-static/scripts/androidfragment_nav.mjs +208 -208
- package/skills/a2h-utg-static/scripts/audit.mjs +268 -268
- package/skills/a2h-utg-static/scripts/carry_answers.mjs +201 -201
- package/skills/a2h-utg-static/scripts/compose_body_text.mjs +60 -0
- package/skills/a2h-utg-static/scripts/dialog_listener_nav.mjs +237 -237
- package/skills/a2h-utg-static/scripts/guard_subjects.mjs +162 -162
- package/skills/a2h-utg-static/scripts/hg_query.mjs +137 -137
- package/skills/a2h-utg-static/scripts/hybrid_bundle.mjs +165 -165
- package/skills/a2h-utg-static/scripts/hybrid_pages.mjs +713 -713
- package/skills/a2h-utg-static/scripts/hybrid_scope.mjs +660 -660
- package/skills/a2h-utg-static/scripts/interaction_sites.mjs +267 -267
- package/skills/a2h-utg-static/scripts/io_utils.mjs +59 -59
- package/skills/a2h-utg-static/scripts/measure/measure_corpus.mjs +297 -297
- package/skills/a2h-utg-static/scripts/measure/measure_guards.mjs +98 -98
- package/skills/a2h-utg-static/scripts/media_browse_nav.mjs +356 -356
- package/skills/a2h-utg-static/scripts/orphan_overlay_nav.mjs +89 -89
- package/skills/a2h-utg-static/scripts/phase_plan.mjs +108 -108
- package/skills/a2h-utg-static/scripts/phase_planner.mjs +119 -119
- package/skills/a2h-utg-static/scripts/plaindialog_nav.mjs +411 -411
- package/skills/a2h-utg-static/scripts/preference_widgets.mjs +142 -142
- package/skills/a2h-utg-static/scripts/presenter_nav.mjs +490 -490
- package/skills/a2h-utg-static/scripts/registry_nav.mjs +288 -288
- package/skills/a2h-utg-static/scripts/run_pipeline.mjs +870 -870
- package/skills/a2h-utg-static/scripts/screen_merge.mjs +287 -287
- package/skills/a2h-utg-static/scripts/screen_nav.mjs +279 -279
- package/skills/a2h-utg-static/scripts/starter_nav.mjs +198 -198
- package/skills/a2h-utg-static/scripts/static_prior.mjs +904 -904
- package/skills/a2h-utg-static/scripts/tests/_zipw.mjs +28 -28
- package/skills/a2h-utg-static/scripts/tests/probe_autoload.mjs +108 -108
- package/skills/a2h-utg-static/scripts/tests/probe_layout_fragments.mjs +90 -90
- package/skills/a2h-utg-static/scripts/tests/probe_unknown_scope.mjs +61 -61
- package/skills/a2h-utg-static/scripts/tests/regression_matrix.mjs +1261 -1261
- package/skills/a2h-utg-static/scripts/tests/test_activity_alias_launcher.mjs +90 -90
- package/skills/a2h-utg-static/scripts/tests/test_bottom_sheet_container.mjs +58 -58
- package/skills/a2h-utg-static/scripts/tests/test_branch_guard.mjs +19 -19
- package/skills/a2h-utg-static/scripts/tests/test_carry_answers.mjs +103 -103
- package/skills/a2h-utg-static/scripts/tests/test_chrome_tokens.mjs +60 -60
- package/skills/a2h-utg-static/scripts/tests/test_commented_out_trigger.mjs +111 -111
- package/skills/a2h-utg-static/scripts/tests/test_commit_scope.mjs +113 -113
- package/skills/a2h-utg-static/scripts/tests/test_compose_vm_nav.mjs +23 -1
- package/skills/a2h-utg-static/scripts/tests/test_defensive_null_guard.mjs +77 -77
- package/skills/a2h-utg-static/scripts/tests/test_dialog_orphan_entries.mjs +99 -99
- package/skills/a2h-utg-static/scripts/tests/test_dialog_page_owner.mjs +69 -69
- package/skills/a2h-utg-static/scripts/tests/test_dialogshow_java_factory.mjs +37 -37
- package/skills/a2h-utg-static/scripts/tests/test_disabled_guard.mjs +42 -42
- package/skills/a2h-utg-static/scripts/tests/test_drawer_panel_gesture.mjs +140 -140
- package/skills/a2h-utg-static/scripts/tests/test_edge_dedupe_by_gesture.mjs +111 -111
- package/skills/a2h-utg-static/scripts/tests/test_edge_provenance_lint.mjs +70 -70
- package/skills/a2h-utg-static/scripts/tests/test_enclosing_gesture.mjs +69 -69
- package/skills/a2h-utg-static/scripts/tests/test_external_surface_roots.mjs +43 -43
- package/skills/a2h-utg-static/scripts/tests/test_find_package_indirect.mjs +67 -67
- package/skills/a2h-utg-static/scripts/tests/test_forwarding_wrapper.mjs +38 -38
- package/skills/a2h-utg-static/scripts/tests/test_fragment_containment.mjs +85 -85
- package/skills/a2h-utg-static/scripts/tests/test_fragment_helper_trigger.mjs +92 -92
- package/skills/a2h-utg-static/scripts/tests/test_graph.mjs +55 -55
- package/skills/a2h-utg-static/scripts/tests/test_guard_clause.mjs +86 -86
- package/skills/a2h-utg-static/scripts/tests/test_hybrid_bundle_attribution.mjs +74 -74
- package/skills/a2h-utg-static/scripts/tests/test_hybrid_bundled_pages.mjs +181 -181
- package/skills/a2h-utg-static/scripts/tests/test_hybrid_scope.mjs +293 -293
- package/skills/a2h-utg-static/scripts/tests/test_hybrid_title_renders.mjs +118 -118
- package/skills/a2h-utg-static/scripts/tests/test_interaction_sites.mjs +272 -272
- package/skills/a2h-utg-static/scripts/tests/test_item_data_instance.mjs +51 -51
- package/skills/a2h-utg-static/scripts/tests/test_kotlin_fn_spans.mjs +69 -69
- package/skills/a2h-utg-static/scripts/tests/test_label_accessor_forms.mjs +187 -187
- package/skills/a2h-utg-static/scripts/tests/test_label_source.mjs +70 -70
- package/skills/a2h-utg-static/scripts/tests/test_launch_intent_guard.mjs +67 -67
- package/skills/a2h-utg-static/scripts/tests/test_layout_declared_fragment.mjs +103 -103
- package/skills/a2h-utg-static/scripts/tests/test_listener_call_forms.mjs +79 -79
- package/skills/a2h-utg-static/scripts/tests/test_listener_receiver_binding.mjs +47 -47
- package/skills/a2h-utg-static/scripts/tests/test_manifest_exported_default.mjs +40 -40
- package/skills/a2h-utg-static/scripts/tests/test_manifest_filters_modules.mjs +84 -84
- package/skills/a2h-utg-static/scripts/tests/test_mode_and_cb_param.mjs +172 -172
- package/skills/a2h-utg-static/scripts/tests/test_module_namespace.mjs +33 -33
- package/skills/a2h-utg-static/scripts/tests/test_multiple_entry_contracts.mjs +80 -80
- package/skills/a2h-utg-static/scripts/tests/test_nav_graph_xml.mjs +35 -35
- package/skills/a2h-utg-static/scripts/tests/test_nl_hints_gate.mjs +85 -85
- package/skills/a2h-utg-static/scripts/tests/test_node_id_collision.mjs +57 -57
- package/skills/a2h-utg-static/scripts/tests/test_non_gesture_step_flag.mjs +62 -62
- package/skills/a2h-utg-static/scripts/tests/test_out_of_scope_and_settings.mjs +72 -72
- package/skills/a2h-utg-static/scripts/tests/test_overload_and_climb.mjs +86 -86
- package/skills/a2h-utg-static/scripts/tests/test_pager_page_source.mjs +78 -78
- package/skills/a2h-utg-static/scripts/tests/test_pager_position_zero.mjs +65 -65
- package/skills/a2h-utg-static/scripts/tests/test_pager_variant_guard.mjs +172 -172
- package/skills/a2h-utg-static/scripts/tests/test_pipeline_llm_phases.mjs +107 -107
- package/skills/a2h-utg-static/scripts/tests/test_plain_dialog_nodes.mjs +167 -167
- package/skills/a2h-utg-static/scripts/tests/test_plaindialog_shared_anchor.mjs +117 -117
- package/skills/a2h-utg-static/scripts/tests/test_preference_click_nav.mjs +98 -98
- package/skills/a2h-utg-static/scripts/tests/test_preference_nesting.mjs +183 -183
- package/skills/a2h-utg-static/scripts/tests/test_preference_widgets.mjs +48 -48
- package/skills/a2h-utg-static/scripts/tests/test_read_text_crlf.mjs +41 -41
- package/skills/a2h-utg-static/scripts/tests/test_resolver_tier_parity.mjs +126 -126
- package/skills/a2h-utg-static/scripts/tests/test_review_fixes.mjs +135 -135
- package/skills/a2h-utg-static/scripts/tests/test_scope_utils.mjs +85 -85
- package/skills/a2h-utg-static/scripts/tests/test_sealed_dialog_state.mjs +148 -148
- package/skills/a2h-utg-static/scripts/tests/test_shared_overlay_split.mjs +63 -63
- package/skills/a2h-utg-static/scripts/tests/test_slug_parity.mjs +58 -58
- package/skills/a2h-utg-static/scripts/tests/test_starter_node_id.mjs +41 -41
- package/skills/a2h-utg-static/scripts/tests/test_state_guard_arity.mjs +109 -109
- package/skills/a2h-utg-static/scripts/tests/test_state_guard_commented_candidates.mjs +68 -68
- package/skills/a2h-utg-static/scripts/tests/test_state_guard_model_gates.mjs +127 -127
- package/skills/a2h-utg-static/scripts/tests/test_state_specific_hop.mjs +130 -130
- package/skills/a2h-utg-static/scripts/tests/test_synthetic_label_identity.mjs +51 -51
- package/skills/a2h-utg-static/scripts/tests/test_template_method_layout.mjs +81 -81
- package/skills/a2h-utg-static/scripts/tests/test_trigger_id_spelling.mjs +68 -68
- package/skills/a2h-utg-static/scripts/tests/test_ui_elements_action_override.mjs +91 -91
- package/skills/a2h-utg-static/scripts/tests/test_ui_elements_flow_filter.mjs +110 -110
- package/skills/a2h-utg-static/scripts/tests/test_ui_elements_nl_hint_key.mjs +89 -89
- package/skills/a2h-utg-static/scripts/tests/test_uiless_host_fold.mjs +98 -98
- package/skills/a2h-utg-static/scripts/tests/test_uniapp_source.mjs +231 -231
- package/skills/a2h-utg-static/scripts/tests/test_view_click_refs.mjs +104 -104
- package/skills/a2h-utg-static/scripts/tests/test_view_id_label.mjs +69 -69
- package/skills/a2h-utg-static/scripts/tests/test_view_interactions.mjs +346 -346
- package/skills/a2h-utg-static/scripts/tests/test_viewpage_nav.mjs +340 -273
- package/skills/a2h-utg-static/scripts/tests/test_widget_class_scope.mjs +92 -92
- package/skills/a2h-utg-static/scripts/tests/test_window_nav_kotlin.mjs +158 -158
- package/skills/a2h-utg-static/scripts/tests/test_worklist_parts.mjs +65 -65
- package/skills/a2h-utg-static/scripts/uniapp_nav.mjs +1119 -1119
- package/skills/a2h-utg-static/scripts/uniapp_widgets.mjs +244 -244
- package/skills/a2h-utg-static/scripts/utg_html.mjs +721 -721
- package/skills/a2h-utg-static/scripts/viewpage_nav.mjs +589 -485
- package/skills/a2h-utg-static/scripts/window_nav.mjs +240 -240
- package/skills/a2h-utg-static/scripts/worklist_parts.mjs +154 -154
- package/skills/a2h-utg-static/tools/convert_static_utg_to_ui_elements.ts +769 -769
- package/skills/a2h-utg-static/tools/package.json +3 -3
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
import assert from "node:assert/strict";
|
|
2
|
-
import fs from "node:fs";
|
|
3
|
-
import path from "node:path";
|
|
4
|
-
import test from "node:test";
|
|
5
|
-
import { fileURLToPath } from "node:url";
|
|
6
|
-
|
|
7
|
-
import yaml from "../scripts/lib-yaml-lite.mjs";
|
|
8
|
-
|
|
9
|
-
const WORKFLOW = path.join(path.dirname(fileURLToPath(import.meta.url)), "..", "references", "workflow.yaml");
|
|
10
|
-
const doc = yaml.load(fs.readFileSync(WORKFLOW, "utf8"));
|
|
11
|
-
const byId = Object.fromEntries(doc.nodes.map((n) => [n.id, n]));
|
|
12
|
-
|
|
13
|
-
function expand(value) {
|
|
14
|
-
const env = { HMOS: "/H", ANDROID: "/A" };
|
|
15
|
-
for (const [k, v] of Object.entries(doc.vars)) {
|
|
16
|
-
const d = v && typeof v === "object" ? v.default : v;
|
|
17
|
-
if (d !== undefined && d !== null) env[k] = String(d);
|
|
18
|
-
}
|
|
19
|
-
let out = String(value);
|
|
20
|
-
for (let i = 0; i < 10; i++) out = out.replace(/\$\{(\w+)\}/g, (m, n) => (n in env ? env[n] : m));
|
|
21
|
-
return out.replace(/\/+$/, "");
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
const overlaps = (a, b) => a === b || a.startsWith(b + "/") || b.startsWith(a + "/");
|
|
25
|
-
|
|
26
|
-
test("discover.utg_static and ui.batch Step 3.1 never share a UTG directory", () => {
|
|
27
|
-
const utgDir = expand("${UTG_DIR}");
|
|
28
|
-
const uiUtgDir = expand("${UI_UTG_DIR}");
|
|
29
|
-
assert.equal(uiUtgDir, "/H/.hometrans/utg_static", "a2h-batch-ui-align's fixed path");
|
|
30
|
-
assert.ok(!overlaps(utgDir, uiUtgDir), `${utgDir} vs ${uiUtgDir}`);
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
test("spec lane reads only the snapshot taken from discover.utg_static's own dir", () => {
|
|
34
|
-
const copy = byId["discover.utg_snapshot"].actions.map((a) => a.copy_tree).find(Boolean);
|
|
35
|
-
assert.equal(copy.from, "${UTG_DIR}");
|
|
36
|
-
assert.equal(byId["enrich.spec_gen"].reads.utg_workspace, "${UTG_SNAPSHOT}");
|
|
37
|
-
assert.equal(byId["ui.batch"].writes.utg, "${UI_UTG_DIR}/");
|
|
38
|
-
assert.match(byId["discover.utg_static"].writes.workspace, /^\$\{UTG_DIR\}/);
|
|
39
|
-
});
|
|
1
|
+
import assert from "node:assert/strict";
|
|
2
|
+
import fs from "node:fs";
|
|
3
|
+
import path from "node:path";
|
|
4
|
+
import test from "node:test";
|
|
5
|
+
import { fileURLToPath } from "node:url";
|
|
6
|
+
|
|
7
|
+
import yaml from "../scripts/lib-yaml-lite.mjs";
|
|
8
|
+
|
|
9
|
+
const WORKFLOW = path.join(path.dirname(fileURLToPath(import.meta.url)), "..", "references", "workflow.yaml");
|
|
10
|
+
const doc = yaml.load(fs.readFileSync(WORKFLOW, "utf8"));
|
|
11
|
+
const byId = Object.fromEntries(doc.nodes.map((n) => [n.id, n]));
|
|
12
|
+
|
|
13
|
+
function expand(value) {
|
|
14
|
+
const env = { HMOS: "/H", ANDROID: "/A" };
|
|
15
|
+
for (const [k, v] of Object.entries(doc.vars)) {
|
|
16
|
+
const d = v && typeof v === "object" ? v.default : v;
|
|
17
|
+
if (d !== undefined && d !== null) env[k] = String(d);
|
|
18
|
+
}
|
|
19
|
+
let out = String(value);
|
|
20
|
+
for (let i = 0; i < 10; i++) out = out.replace(/\$\{(\w+)\}/g, (m, n) => (n in env ? env[n] : m));
|
|
21
|
+
return out.replace(/\/+$/, "");
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
const overlaps = (a, b) => a === b || a.startsWith(b + "/") || b.startsWith(a + "/");
|
|
25
|
+
|
|
26
|
+
test("discover.utg_static and ui.batch Step 3.1 never share a UTG directory", () => {
|
|
27
|
+
const utgDir = expand("${UTG_DIR}");
|
|
28
|
+
const uiUtgDir = expand("${UI_UTG_DIR}");
|
|
29
|
+
assert.equal(uiUtgDir, "/H/.hometrans/utg_static", "a2h-batch-ui-align's fixed path");
|
|
30
|
+
assert.ok(!overlaps(utgDir, uiUtgDir), `${utgDir} vs ${uiUtgDir}`);
|
|
31
|
+
});
|
|
32
|
+
|
|
33
|
+
test("spec lane reads only the snapshot taken from discover.utg_static's own dir", () => {
|
|
34
|
+
const copy = byId["discover.utg_snapshot"].actions.map((a) => a.copy_tree).find(Boolean);
|
|
35
|
+
assert.equal(copy.from, "${UTG_DIR}");
|
|
36
|
+
assert.equal(byId["enrich.spec_gen"].reads.utg_workspace, "${UTG_SNAPSHOT}");
|
|
37
|
+
assert.equal(byId["ui.batch"].writes.utg, "${UI_UTG_DIR}/");
|
|
38
|
+
assert.match(byId["discover.utg_static"].writes.workspace, /^\$\{UTG_DIR\}/);
|
|
39
|
+
});
|
|
@@ -1,107 +1,107 @@
|
|
|
1
|
-
# Example: Reconcile an Existing HarmonyOS Project
|
|
2
|
-
|
|
3
|
-
This example illustrates the reconcile mode: an Android notes app is being migrated, and a HarmonyOS project already exists with partial progress. It is not a directory-translation template.
|
|
4
|
-
|
|
5
|
-
## Scenario and routing
|
|
6
|
-
|
|
7
|
-
```text
|
|
8
|
-
source_repo = ~/work/android-notes (Android, Gradle, single :app module)
|
|
9
|
-
target_project_dir = ~/work/notes-harmony (valid DevEco project: entry HAR/HSP modules, no .hometrans documents)
|
|
10
|
-
```
|
|
11
|
-
|
|
12
|
-
`inspect_and_route.mjs` decides from the target state alone:
|
|
13
|
-
|
|
14
|
-
```json
|
|
15
|
-
{"status": "routed", "mode": "reconcile",
|
|
16
|
-
"reason": "target project state: valid_project",
|
|
17
|
-
"next_step": "Step 2: run scripts/inspect_project.mjs ..."}
|
|
18
|
-
```
|
|
19
|
-
|
|
20
|
-
## Deterministic facts (scripts, not model judgment)
|
|
21
|
-
|
|
22
|
-
`inspect_project.mjs` recovers the source facts; `resolve_android_stores.mjs` resolves the runtime-computed store name; `generate_source_baseline.mjs` renders:
|
|
23
|
-
|
|
24
|
-
```text
|
|
25
|
-
source_baseline/database_design.md notes 表:id(PK)/title/created_at,约束由 DDL 恢复
|
|
26
|
-
source_baseline/preferences_design.md notes_prefs:seen_onboarding(Boolean)、theme_mode(String, "light")
|
|
27
|
-
source_baseline/source_semantics.md 骨架:入口 MainActivity、后台无、集成 1 项 + 待补充的语义小节
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
`inspect_harmony_target.mjs` recovers the current state and freezes it:
|
|
31
|
-
|
|
32
|
-
```text
|
|
33
|
-
target_inspection.json modules: products/app(entry), features/home(har), features/sync(hsp), common/utils(har)
|
|
34
|
-
storage: app_settings(theme, launch_count)
|
|
35
|
-
current/ 三份现状文档(模块清单、目录树、存储现状、结构性提示)由脚本生成
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
## Reconciliation (the semantic step)
|
|
39
|
-
|
|
40
|
-
The table below is a human-readable rendering of `architecture_reconciliation.json` under `arch_generate/reconcile/`. It is an **analysis artifact** and never appears in the formal documents. The `Disposition` column carries the disposition vocabulary (`reuse-existing` / `adapt-existing` / `introduce-planned` / `exclude-with-reason`), and every source responsibility receives exactly one.
|
|
41
|
-
|
|
42
|
-
| Source responsibility | Disposition | Target | Reason |
|
|
43
|
-
|---|---|---|---|
|
|
44
|
-
| MainActivity 首页展示 | `reuse-existing` | `products/app/src/main/ets/pages` | 现有页面已承载该职责 |
|
|
45
|
-
| NotesStore.theme 主题偏好 | `adapt-existing` | `products/app/src/main/ets/pages` | 现有 app_settings 存储需扩展主题键 |
|
|
46
|
-
| NotesStore.DDL 本地笔记持久化 | `introduce-planned` | `features/payment…` 之外的规划模块 | 现工程无关系型存储承载 |
|
|
47
|
-
| SessionSyncWorker 后台同步 | `reuse-existing` | `features/sync/src/main/ets/engine` | 现有同步引擎已承载 |
|
|
48
|
-
|
|
49
|
-
Every affected existing module receives a fate (`retained` unless reshaped); every review-required item is listed in the run summary.
|
|
50
|
-
|
|
51
|
-
## The formal project_design.md
|
|
52
|
-
|
|
53
|
-
The formal document contains exactly two sections. The 项目结构 section holds the planned tree with unified markers, and the 模块语义 section holds the only Markdown table in the document.
|
|
54
|
-
|
|
55
|
-
### 项目结构(节选)
|
|
56
|
-
|
|
57
|
-
```text
|
|
58
|
-
products/
|
|
59
|
-
└── app/ # EXISTING HAP
|
|
60
|
-
└── src/
|
|
61
|
-
└── main/
|
|
62
|
-
├── ets/
|
|
63
|
-
│ └── pages/ # EXISTING
|
|
64
|
-
└── resources/
|
|
65
|
-
features/
|
|
66
|
-
├── notes/ # HAR
|
|
67
|
-
│ └── src/
|
|
68
|
-
│ └── main/
|
|
69
|
-
│ ├── ets/
|
|
70
|
-
│ │ └── data/
|
|
71
|
-
│ └── resources/
|
|
72
|
-
├── home/ # EXISTING HAR
|
|
73
|
-
│ └── src/
|
|
74
|
-
│ └── main/
|
|
75
|
-
│ ├── ets/
|
|
76
|
-
│ │ └── pages/ # EXISTING
|
|
77
|
-
│ └── resources/
|
|
78
|
-
└── sync/ # EXISTING HSP
|
|
79
|
-
└── src/
|
|
80
|
-
└── main/
|
|
81
|
-
├── ets/
|
|
82
|
-
│ └── engine/
|
|
83
|
-
└── resources/
|
|
84
|
-
common/
|
|
85
|
-
└── utils/ # EXISTING HAR
|
|
86
|
-
└── src/
|
|
87
|
-
└── main/
|
|
88
|
-
├── ets/
|
|
89
|
-
│ └── utils/ # EXISTING
|
|
90
|
-
└── resources/
|
|
91
|
-
```
|
|
92
|
-
|
|
93
|
-
Read: the annotated paths exist today; `features/notes` is planned only and carries no `EXISTING` token. The skill creates nothing. The planned-only module is realized by later development steps.
|
|
94
|
-
|
|
95
|
-
### 模块语义
|
|
96
|
-
|
|
97
|
-
| 模块路径 | 模块功能 |
|
|
98
|
-
|---|---|
|
|
99
|
-
| products/app/src/main/ets/pages | 应用入口页面装配,承载启动流程与首页展示。 |
|
|
100
|
-
| features/notes/src/main/ets/data | 本地笔记数据层,承载笔记表结构与偏好读写。 |
|
|
101
|
-
| features/home/src/main/ets/pages | 首页信息流页面,提供展示与刷新能力。 |
|
|
102
|
-
| features/sync/src/main/ets/engine | 同步引擎,负责后台数据同步的调度与执行。 |
|
|
103
|
-
| common/utils/src/main/ets/utils | 公共工具库,提供跨模块基础能力。 |
|
|
104
|
-
|
|
105
|
-
## Validation
|
|
106
|
-
|
|
107
|
-
`validate_architecture_docs.mjs --allow-existing` enforces the unified marker grammar and the deep-tree contract on the annotated document; `validate_incremental_docs.mjs` checks that every `# EXISTING` path exists on disk, appears in the frozen `target_inspection.json`, and matches `architecture_reconciliation.json`'s `existing_targets` exactly. It also checks that no `planned_only` path is annotated.
|
|
1
|
+
# Example: Reconcile an Existing HarmonyOS Project
|
|
2
|
+
|
|
3
|
+
This example illustrates the reconcile mode: an Android notes app is being migrated, and a HarmonyOS project already exists with partial progress. It is not a directory-translation template.
|
|
4
|
+
|
|
5
|
+
## Scenario and routing
|
|
6
|
+
|
|
7
|
+
```text
|
|
8
|
+
source_repo = ~/work/android-notes (Android, Gradle, single :app module)
|
|
9
|
+
target_project_dir = ~/work/notes-harmony (valid DevEco project: entry HAR/HSP modules, no .hometrans documents)
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
`inspect_and_route.mjs` decides from the target state alone:
|
|
13
|
+
|
|
14
|
+
```json
|
|
15
|
+
{"status": "routed", "mode": "reconcile",
|
|
16
|
+
"reason": "target project state: valid_project",
|
|
17
|
+
"next_step": "Step 2: run scripts/inspect_project.mjs ..."}
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Deterministic facts (scripts, not model judgment)
|
|
21
|
+
|
|
22
|
+
`inspect_project.mjs` recovers the source facts; `resolve_android_stores.mjs` resolves the runtime-computed store name; `generate_source_baseline.mjs` renders:
|
|
23
|
+
|
|
24
|
+
```text
|
|
25
|
+
source_baseline/database_design.md notes 表:id(PK)/title/created_at,约束由 DDL 恢复
|
|
26
|
+
source_baseline/preferences_design.md notes_prefs:seen_onboarding(Boolean)、theme_mode(String, "light")
|
|
27
|
+
source_baseline/source_semantics.md 骨架:入口 MainActivity、后台无、集成 1 项 + 待补充的语义小节
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
`inspect_harmony_target.mjs` recovers the current state and freezes it:
|
|
31
|
+
|
|
32
|
+
```text
|
|
33
|
+
target_inspection.json modules: products/app(entry), features/home(har), features/sync(hsp), common/utils(har)
|
|
34
|
+
storage: app_settings(theme, launch_count)
|
|
35
|
+
current/ 三份现状文档(模块清单、目录树、存储现状、结构性提示)由脚本生成
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## Reconciliation (the semantic step)
|
|
39
|
+
|
|
40
|
+
The table below is a human-readable rendering of `architecture_reconciliation.json` under `arch_generate/reconcile/`. It is an **analysis artifact** and never appears in the formal documents. The `Disposition` column carries the disposition vocabulary (`reuse-existing` / `adapt-existing` / `introduce-planned` / `exclude-with-reason`), and every source responsibility receives exactly one.
|
|
41
|
+
|
|
42
|
+
| Source responsibility | Disposition | Target | Reason |
|
|
43
|
+
|---|---|---|---|
|
|
44
|
+
| MainActivity 首页展示 | `reuse-existing` | `products/app/src/main/ets/pages` | 现有页面已承载该职责 |
|
|
45
|
+
| NotesStore.theme 主题偏好 | `adapt-existing` | `products/app/src/main/ets/pages` | 现有 app_settings 存储需扩展主题键 |
|
|
46
|
+
| NotesStore.DDL 本地笔记持久化 | `introduce-planned` | `features/payment…` 之外的规划模块 | 现工程无关系型存储承载 |
|
|
47
|
+
| SessionSyncWorker 后台同步 | `reuse-existing` | `features/sync/src/main/ets/engine` | 现有同步引擎已承载 |
|
|
48
|
+
|
|
49
|
+
Every affected existing module receives a fate (`retained` unless reshaped); every review-required item is listed in the run summary.
|
|
50
|
+
|
|
51
|
+
## The formal project_design.md
|
|
52
|
+
|
|
53
|
+
The formal document contains exactly two sections. The 项目结构 section holds the planned tree with unified markers, and the 模块语义 section holds the only Markdown table in the document.
|
|
54
|
+
|
|
55
|
+
### 项目结构(节选)
|
|
56
|
+
|
|
57
|
+
```text
|
|
58
|
+
products/
|
|
59
|
+
└── app/ # EXISTING HAP
|
|
60
|
+
└── src/
|
|
61
|
+
└── main/
|
|
62
|
+
├── ets/
|
|
63
|
+
│ └── pages/ # EXISTING
|
|
64
|
+
└── resources/
|
|
65
|
+
features/
|
|
66
|
+
├── notes/ # HAR
|
|
67
|
+
│ └── src/
|
|
68
|
+
│ └── main/
|
|
69
|
+
│ ├── ets/
|
|
70
|
+
│ │ └── data/
|
|
71
|
+
│ └── resources/
|
|
72
|
+
├── home/ # EXISTING HAR
|
|
73
|
+
│ └── src/
|
|
74
|
+
│ └── main/
|
|
75
|
+
│ ├── ets/
|
|
76
|
+
│ │ └── pages/ # EXISTING
|
|
77
|
+
│ └── resources/
|
|
78
|
+
└── sync/ # EXISTING HSP
|
|
79
|
+
└── src/
|
|
80
|
+
└── main/
|
|
81
|
+
├── ets/
|
|
82
|
+
│ └── engine/
|
|
83
|
+
└── resources/
|
|
84
|
+
common/
|
|
85
|
+
└── utils/ # EXISTING HAR
|
|
86
|
+
└── src/
|
|
87
|
+
└── main/
|
|
88
|
+
├── ets/
|
|
89
|
+
│ └── utils/ # EXISTING
|
|
90
|
+
└── resources/
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
Read: the annotated paths exist today; `features/notes` is planned only and carries no `EXISTING` token. The skill creates nothing. The planned-only module is realized by later development steps.
|
|
94
|
+
|
|
95
|
+
### 模块语义
|
|
96
|
+
|
|
97
|
+
| 模块路径 | 模块功能 |
|
|
98
|
+
|---|---|
|
|
99
|
+
| products/app/src/main/ets/pages | 应用入口页面装配,承载启动流程与首页展示。 |
|
|
100
|
+
| features/notes/src/main/ets/data | 本地笔记数据层,承载笔记表结构与偏好读写。 |
|
|
101
|
+
| features/home/src/main/ets/pages | 首页信息流页面,提供展示与刷新能力。 |
|
|
102
|
+
| features/sync/src/main/ets/engine | 同步引擎,负责后台数据同步的调度与执行。 |
|
|
103
|
+
| common/utils/src/main/ets/utils | 公共工具库,提供跨模块基础能力。 |
|
|
104
|
+
|
|
105
|
+
## Validation
|
|
106
|
+
|
|
107
|
+
`validate_architecture_docs.mjs --allow-existing` enforces the unified marker grammar and the deep-tree contract on the annotated document; `validate_incremental_docs.mjs` checks that every `# EXISTING` path exists on disk, appears in the frozen `target_inspection.json`, and matches `architecture_reconciliation.json`'s `existing_targets` exactly. It also checks that no `planned_only` path is annotated.
|
|
@@ -1,103 +1,103 @@
|
|
|
1
|
-
# Example: Account and Session Continuity
|
|
2
|
-
|
|
3
|
-
This example illustrates capability reconstruction. It is not a directory-translation template.
|
|
4
|
-
|
|
5
|
-
## Android Source Shape
|
|
6
|
-
|
|
7
|
-
```text
|
|
8
|
-
app/src/main/
|
|
9
|
-
├── AndroidManifest.xml
|
|
10
|
-
└── java/com/example/
|
|
11
|
-
├── account/
|
|
12
|
-
│ ├── AccountHostActivity.kt
|
|
13
|
-
│ ├── LoginFragment.kt
|
|
14
|
-
│ ├── AccountSettingsFragment.kt
|
|
15
|
-
│ └── AccountRepository.kt
|
|
16
|
-
└── session/
|
|
17
|
-
├── SessionSyncWorker.kt
|
|
18
|
-
├── SessionRepository.kt
|
|
19
|
-
└── SessionDao.kt
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
The two Android directories are evidence locations, not authoritative module boundaries. The HarmonyOS modules below are justified by reconstructed product responsibilities rather than package-name correspondence.
|
|
23
|
-
|
|
24
|
-
## Evidence Interpretation
|
|
25
|
-
|
|
26
|
-
| Android evidence | Interpretation |
|
|
27
|
-
|---|---|
|
|
28
|
-
| `LoginFragment` and its navigation destination | Independent authentication interface. |
|
|
29
|
-
| `AccountSettingsFragment` and persisted settings | Independent account-preference interface. |
|
|
30
|
-
| `SessionSyncWorker` and its schedule | Independently triggered session-synchronization capability. |
|
|
31
|
-
| `AccountRepository` | Supporting evidence for account-facing features. |
|
|
32
|
-
| `SessionRepository` | Data coordination supporting session continuity. |
|
|
33
|
-
| `SessionDao` | Persistence implementation evidence. Not an automatic target leaf. |
|
|
34
|
-
| `AccountHostActivity` | UI host and application-composition evidence. Not necessarily an independent capability. |
|
|
35
|
-
|
|
36
|
-
Normalized capabilities:
|
|
37
|
-
|
|
38
|
-
```text
|
|
39
|
-
Login
|
|
40
|
-
AccountSettings
|
|
41
|
-
SessionSynchronization
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
## Logical Capability Tree
|
|
45
|
-
|
|
46
|
-
```text
|
|
47
|
-
Account
|
|
48
|
-
├── Authentication
|
|
49
|
-
│ └── Login
|
|
50
|
-
└── Settings
|
|
51
|
-
└── AccountSettings
|
|
52
|
-
|
|
53
|
-
SessionContinuity
|
|
54
|
-
└── SessionSynchronization
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
`Account` is a `BusinessDomain`. `SessionContinuity` is a `CrossCuttingDomain` because session continuity supports several user-facing domains.
|
|
58
|
-
|
|
59
|
-
## Single-Entry Projection
|
|
60
|
-
|
|
61
|
-
```text
|
|
62
|
-
entry/ # HAP
|
|
63
|
-
└── src/
|
|
64
|
-
└── main/
|
|
65
|
-
└── ets/
|
|
66
|
-
├── Account/
|
|
67
|
-
│ ├── Authentication/
|
|
68
|
-
│ │ └── Login/
|
|
69
|
-
│ └── Settings/
|
|
70
|
-
│ └── AccountSettings/
|
|
71
|
-
└── SessionContinuity/
|
|
72
|
-
└── SessionSynchronization/
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
## Layered Projection
|
|
76
|
-
|
|
77
|
-
```text
|
|
78
|
-
products/
|
|
79
|
-
└── DefaultProduct/ # HAP
|
|
80
|
-
└── src/
|
|
81
|
-
└── main/
|
|
82
|
-
└── ets/
|
|
83
|
-
└── AppShell/
|
|
84
|
-
|
|
85
|
-
features/
|
|
86
|
-
└── Account/ # HAR
|
|
87
|
-
└── src/
|
|
88
|
-
└── main/
|
|
89
|
-
└── ets/
|
|
90
|
-
├── Authentication/
|
|
91
|
-
│ └── Login/
|
|
92
|
-
└── Settings/
|
|
93
|
-
└── AccountSettings/
|
|
94
|
-
|
|
95
|
-
common/
|
|
96
|
-
└── SessionContinuity/ # HAR
|
|
97
|
-
└── src/
|
|
98
|
-
└── main/
|
|
99
|
-
└── ets/
|
|
100
|
-
└── SessionSynchronization/
|
|
101
|
-
```
|
|
102
|
-
|
|
103
|
-
Both projections preserve the same logical capabilities. Repositories and DAOs remain internal implementation evidence and do not become target directories.
|
|
1
|
+
# Example: Account and Session Continuity
|
|
2
|
+
|
|
3
|
+
This example illustrates capability reconstruction. It is not a directory-translation template.
|
|
4
|
+
|
|
5
|
+
## Android Source Shape
|
|
6
|
+
|
|
7
|
+
```text
|
|
8
|
+
app/src/main/
|
|
9
|
+
├── AndroidManifest.xml
|
|
10
|
+
└── java/com/example/
|
|
11
|
+
├── account/
|
|
12
|
+
│ ├── AccountHostActivity.kt
|
|
13
|
+
│ ├── LoginFragment.kt
|
|
14
|
+
│ ├── AccountSettingsFragment.kt
|
|
15
|
+
│ └── AccountRepository.kt
|
|
16
|
+
└── session/
|
|
17
|
+
├── SessionSyncWorker.kt
|
|
18
|
+
├── SessionRepository.kt
|
|
19
|
+
└── SessionDao.kt
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
The two Android directories are evidence locations, not authoritative module boundaries. The HarmonyOS modules below are justified by reconstructed product responsibilities rather than package-name correspondence.
|
|
23
|
+
|
|
24
|
+
## Evidence Interpretation
|
|
25
|
+
|
|
26
|
+
| Android evidence | Interpretation |
|
|
27
|
+
|---|---|
|
|
28
|
+
| `LoginFragment` and its navigation destination | Independent authentication interface. |
|
|
29
|
+
| `AccountSettingsFragment` and persisted settings | Independent account-preference interface. |
|
|
30
|
+
| `SessionSyncWorker` and its schedule | Independently triggered session-synchronization capability. |
|
|
31
|
+
| `AccountRepository` | Supporting evidence for account-facing features. |
|
|
32
|
+
| `SessionRepository` | Data coordination supporting session continuity. |
|
|
33
|
+
| `SessionDao` | Persistence implementation evidence. Not an automatic target leaf. |
|
|
34
|
+
| `AccountHostActivity` | UI host and application-composition evidence. Not necessarily an independent capability. |
|
|
35
|
+
|
|
36
|
+
Normalized capabilities:
|
|
37
|
+
|
|
38
|
+
```text
|
|
39
|
+
Login
|
|
40
|
+
AccountSettings
|
|
41
|
+
SessionSynchronization
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## Logical Capability Tree
|
|
45
|
+
|
|
46
|
+
```text
|
|
47
|
+
Account
|
|
48
|
+
├── Authentication
|
|
49
|
+
│ └── Login
|
|
50
|
+
└── Settings
|
|
51
|
+
└── AccountSettings
|
|
52
|
+
|
|
53
|
+
SessionContinuity
|
|
54
|
+
└── SessionSynchronization
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
`Account` is a `BusinessDomain`. `SessionContinuity` is a `CrossCuttingDomain` because session continuity supports several user-facing domains.
|
|
58
|
+
|
|
59
|
+
## Single-Entry Projection
|
|
60
|
+
|
|
61
|
+
```text
|
|
62
|
+
entry/ # HAP
|
|
63
|
+
└── src/
|
|
64
|
+
└── main/
|
|
65
|
+
└── ets/
|
|
66
|
+
├── Account/
|
|
67
|
+
│ ├── Authentication/
|
|
68
|
+
│ │ └── Login/
|
|
69
|
+
│ └── Settings/
|
|
70
|
+
│ └── AccountSettings/
|
|
71
|
+
└── SessionContinuity/
|
|
72
|
+
└── SessionSynchronization/
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
## Layered Projection
|
|
76
|
+
|
|
77
|
+
```text
|
|
78
|
+
products/
|
|
79
|
+
└── DefaultProduct/ # HAP
|
|
80
|
+
└── src/
|
|
81
|
+
└── main/
|
|
82
|
+
└── ets/
|
|
83
|
+
└── AppShell/
|
|
84
|
+
|
|
85
|
+
features/
|
|
86
|
+
└── Account/ # HAR
|
|
87
|
+
└── src/
|
|
88
|
+
└── main/
|
|
89
|
+
└── ets/
|
|
90
|
+
├── Authentication/
|
|
91
|
+
│ └── Login/
|
|
92
|
+
└── Settings/
|
|
93
|
+
└── AccountSettings/
|
|
94
|
+
|
|
95
|
+
common/
|
|
96
|
+
└── SessionContinuity/ # HAR
|
|
97
|
+
└── src/
|
|
98
|
+
└── main/
|
|
99
|
+
└── ets/
|
|
100
|
+
└── SessionSynchronization/
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
Both projections preserve the same logical capabilities. Repositories and DAOs remain internal implementation evidence and do not become target directories.
|
|
@@ -1,70 +1,70 @@
|
|
|
1
|
-
# Example: Backend Scope (Logic-Only Architecture)
|
|
2
|
-
|
|
3
|
-
This example illustrates `--scope backend`. It reconstructs only business/logic/service/data responsibility. It never represents UI, pages, views, or view components, regardless of `source_kind`. It is not a directory-translation template.
|
|
4
|
-
|
|
5
|
-
## The rule in one sentence
|
|
6
|
-
|
|
7
|
-
Under `scope=backend`, an entry point (an Activity, a page, a bundled SDK login screen) remains valid **trigger evidence**. It is proof that a capability exists and where it starts. Its own UI content is never represented as a target module. Only the logic responsibility it triggers is reconstructed.
|
|
8
|
-
|
|
9
|
-
## `source_kind=android`: file-level exclusion
|
|
10
|
-
|
|
11
|
-
```text
|
|
12
|
-
app/src/main/java/com/example/account/
|
|
13
|
-
├── LoginActivity.kt # UI (evidence only, never a target module)
|
|
14
|
-
├── LoginViewModel.kt # UI-adjacent state holder (evidence only)
|
|
15
|
-
├── AuthRepository.kt # logic (reconstructed)
|
|
16
|
-
└── AuthApiClient.kt # logic (reconstructed)
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
`LoginActivity` is the trigger evidence for an `Authentication` capability. Its layout, navigation, and `LoginViewModel`'s UI-state fields are excluded entirely. `AuthRepository` and `AuthApiClient` carry the credential-validation and token-issuance responsibility that `LoginActivity` invokes. They are reconstructed as the `Authentication` capability's actual content.
|
|
20
|
-
|
|
21
|
-
Android files are single-role by convention, so this exclusion is file-level. An Activity/Fragment/View/ViewModel file is evidence-only. A Repository/Service/DAO/domain file is reconstructed content.
|
|
22
|
-
|
|
23
|
-
## `source_kind=uniapp`: section-level exclusion
|
|
24
|
-
|
|
25
|
-
```vue
|
|
26
|
-
<!-- pages/login/login.vue -->
|
|
27
|
-
<template>
|
|
28
|
-
<view><input v-model="account" /><button @click="submit">登录</button></view>
|
|
29
|
-
</template>
|
|
30
|
-
<script>
|
|
31
|
-
export default {
|
|
32
|
-
data() { return { account: '' }; },
|
|
33
|
-
methods: {
|
|
34
|
-
async submit() {
|
|
35
|
-
const result = await AuthService.login(this.account); // logic (reconstructed)
|
|
36
|
-
uni.setStorageSync('token', result.token); // logic (reconstructed)
|
|
37
|
-
uni.navigateTo({ url: '/pages/index/index' }); // UI navigation (evidence only)
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
};
|
|
41
|
-
</script>
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
A uniapp single-file component colocates UI and logic in one file, so the exclusion cannot be file-level the way it is for Android. `<template>` and any presentational state (`account`, `v-model` bindings) are UI, so they are evidence only. Inside `<script>`, the `AuthService.login` call and the `uni.setStorageSync` persistence are logic. They are reconstructed as the `Authentication` capability's content. The `uni.navigateTo` call is UI navigation. It is excluded like the rest of `<template>`, even though it appears in the same `<script>` block as reconstructed logic.
|
|
45
|
-
|
|
46
|
-
## Logical Capability Tree (either source_kind)
|
|
47
|
-
|
|
48
|
-
```text
|
|
49
|
-
Account
|
|
50
|
-
└── Authentication
|
|
51
|
-
```
|
|
52
|
-
|
|
53
|
-
`Authentication`'s module semantics describe credential validation and token issuance. They never describe login-screen layout, input fields, or navigation targets.
|
|
54
|
-
|
|
55
|
-
## Layered Projection
|
|
56
|
-
|
|
57
|
-
```text
|
|
58
|
-
common/
|
|
59
|
-
└── AuthService/ # HAR
|
|
60
|
-
└── src/
|
|
61
|
-
└── main/
|
|
62
|
-
└── ets/
|
|
63
|
-
└── Authentication/
|
|
64
|
-
```
|
|
65
|
-
|
|
66
|
-
No `products/` layer and no page/view-named directory appears. Under `scope=full`, the same evidence would additionally justify a `features/Account/Login` UI module. Under `scope=backend`, that UI module is never generated. `Login`, `pages`, `views`, `components`, and `widgets` are prohibited as directory names anywhere in the target tree.
|
|
67
|
-
|
|
68
|
-
## `project_kind=library` interaction
|
|
69
|
-
|
|
70
|
-
When the source is a library/SDK that bundles an independently launchable UI screen (for example, a login flow shipped inside an AAR or a `uni_modules` plugin), that screen remains valid trigger evidence for a capability under `scope=backend`, the same as any other entry point. It still never becomes a target UI module. Only the logic responsibility the bundled screen triggers is reconstructed, exactly as in the `LoginActivity`/`login.vue` examples above.
|
|
1
|
+
# Example: Backend Scope (Logic-Only Architecture)
|
|
2
|
+
|
|
3
|
+
This example illustrates `--scope backend`. It reconstructs only business/logic/service/data responsibility. It never represents UI, pages, views, or view components, regardless of `source_kind`. It is not a directory-translation template.
|
|
4
|
+
|
|
5
|
+
## The rule in one sentence
|
|
6
|
+
|
|
7
|
+
Under `scope=backend`, an entry point (an Activity, a page, a bundled SDK login screen) remains valid **trigger evidence**. It is proof that a capability exists and where it starts. Its own UI content is never represented as a target module. Only the logic responsibility it triggers is reconstructed.
|
|
8
|
+
|
|
9
|
+
## `source_kind=android`: file-level exclusion
|
|
10
|
+
|
|
11
|
+
```text
|
|
12
|
+
app/src/main/java/com/example/account/
|
|
13
|
+
├── LoginActivity.kt # UI (evidence only, never a target module)
|
|
14
|
+
├── LoginViewModel.kt # UI-adjacent state holder (evidence only)
|
|
15
|
+
├── AuthRepository.kt # logic (reconstructed)
|
|
16
|
+
└── AuthApiClient.kt # logic (reconstructed)
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
`LoginActivity` is the trigger evidence for an `Authentication` capability. Its layout, navigation, and `LoginViewModel`'s UI-state fields are excluded entirely. `AuthRepository` and `AuthApiClient` carry the credential-validation and token-issuance responsibility that `LoginActivity` invokes. They are reconstructed as the `Authentication` capability's actual content.
|
|
20
|
+
|
|
21
|
+
Android files are single-role by convention, so this exclusion is file-level. An Activity/Fragment/View/ViewModel file is evidence-only. A Repository/Service/DAO/domain file is reconstructed content.
|
|
22
|
+
|
|
23
|
+
## `source_kind=uniapp`: section-level exclusion
|
|
24
|
+
|
|
25
|
+
```vue
|
|
26
|
+
<!-- pages/login/login.vue -->
|
|
27
|
+
<template>
|
|
28
|
+
<view><input v-model="account" /><button @click="submit">登录</button></view>
|
|
29
|
+
</template>
|
|
30
|
+
<script>
|
|
31
|
+
export default {
|
|
32
|
+
data() { return { account: '' }; },
|
|
33
|
+
methods: {
|
|
34
|
+
async submit() {
|
|
35
|
+
const result = await AuthService.login(this.account); // logic (reconstructed)
|
|
36
|
+
uni.setStorageSync('token', result.token); // logic (reconstructed)
|
|
37
|
+
uni.navigateTo({ url: '/pages/index/index' }); // UI navigation (evidence only)
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
</script>
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
A uniapp single-file component colocates UI and logic in one file, so the exclusion cannot be file-level the way it is for Android. `<template>` and any presentational state (`account`, `v-model` bindings) are UI, so they are evidence only. Inside `<script>`, the `AuthService.login` call and the `uni.setStorageSync` persistence are logic. They are reconstructed as the `Authentication` capability's content. The `uni.navigateTo` call is UI navigation. It is excluded like the rest of `<template>`, even though it appears in the same `<script>` block as reconstructed logic.
|
|
45
|
+
|
|
46
|
+
## Logical Capability Tree (either source_kind)
|
|
47
|
+
|
|
48
|
+
```text
|
|
49
|
+
Account
|
|
50
|
+
└── Authentication
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
`Authentication`'s module semantics describe credential validation and token issuance. They never describe login-screen layout, input fields, or navigation targets.
|
|
54
|
+
|
|
55
|
+
## Layered Projection
|
|
56
|
+
|
|
57
|
+
```text
|
|
58
|
+
common/
|
|
59
|
+
└── AuthService/ # HAR
|
|
60
|
+
└── src/
|
|
61
|
+
└── main/
|
|
62
|
+
└── ets/
|
|
63
|
+
└── Authentication/
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
No `products/` layer and no page/view-named directory appears. Under `scope=full`, the same evidence would additionally justify a `features/Account/Login` UI module. Under `scope=backend`, that UI module is never generated. `Login`, `pages`, `views`, `components`, and `widgets` are prohibited as directory names anywhere in the target tree.
|
|
67
|
+
|
|
68
|
+
## `project_kind=library` interaction
|
|
69
|
+
|
|
70
|
+
When the source is a library/SDK that bundles an independently launchable UI screen (for example, a login flow shipped inside an AAR or a `uni_modules` plugin), that screen remains valid trigger evidence for a capability under `scope=backend`, the same as any other entry point. It still never becomes a target UI module. Only the logic responsibility the bundled screen triggers is reconstructed, exactly as in the `LoginActivity`/`login.vue` examples above.
|