stylegallery 0.1.0

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.
Files changed (346) hide show
  1. package/AGENTS.md +156 -0
  2. package/CATALOG.md +69 -0
  3. package/DOMAINS.md +65 -0
  4. package/GOVERNANCE.md +222 -0
  5. package/GUIDE.md +59 -0
  6. package/README.md +313 -0
  7. package/consumer-reference/adapters/style-dictionary.config.mjs +36 -0
  8. package/consumer-reference/agent-native/README.md +157 -0
  9. package/consumer-reference/agent-native/registry.json +640 -0
  10. package/consumer-reference/agent-native/schema/agent-native.schema.json +848 -0
  11. package/consumer-reference/agent-native/schema/epistemic.schema.json +14 -0
  12. package/consumer-reference/agent-native/schema/execution.schema.json +12 -0
  13. package/consumer-reference/agent-native/schema/identity.schema.json +10 -0
  14. package/consumer-reference/agent-native/schema/learning.schema.json +12 -0
  15. package/consumer-reference/agent-native/schema/manifest.schema.json +6 -0
  16. package/consumer-reference/agent-native/schema/operation.schema.json +12 -0
  17. package/consumer-reference/agent-native/schema/protocol-binding.schema.json +9 -0
  18. package/consumer-reference/agent-native/schema/retrieval.schema.json +10 -0
  19. package/consumer-reference/baselines/calibration.json +260 -0
  20. package/consumer-reference/baselines/manifest.json +21 -0
  21. package/consumer-reference/contract.md +83 -0
  22. package/consumer-reference/fixtures/consumer-conformance/e2e-fixture.mjs +282 -0
  23. package/consumer-reference/fixtures/consumer-conformance/manifest.json +102 -0
  24. package/consumer-reference/fixtures/consumer-conformance/runtime-proof.mjs +32 -0
  25. package/consumer-reference/fixtures/consumer-conformance/valid-migration-result.json +18 -0
  26. package/consumer-reference/fixtures/consumer-conformance/valid-migration.json +142 -0
  27. package/consumer-reference/fixtures/invalid-stable-ended-support.json +19 -0
  28. package/consumer-reference/fixtures/promotion/invalid-blocking-evidence.json +26 -0
  29. package/consumer-reference/fixtures/promotion/invalid-count-only.json +29 -0
  30. package/consumer-reference/fixtures/promotion/invalid-missing-owner-migration.json +25 -0
  31. package/consumer-reference/fixtures/promotion/invalid-normative-bypass-no-regression.json +25 -0
  32. package/consumer-reference/fixtures/promotion/invalid-related-counted-independent.json +45 -0
  33. package/consumer-reference/fixtures/promotion/invalid-stable-ended-support.json +26 -0
  34. package/consumer-reference/fixtures/promotion/manifest.json +15 -0
  35. package/consumer-reference/fixtures/promotion/valid-deferred-example.json +67 -0
  36. package/consumer-reference/fixtures/promotion/valid-normative-bypass.json +67 -0
  37. package/consumer-reference/fixtures/token-portability/invalid-cycle.json +7 -0
  38. package/consumer-reference/fixtures/token-portability/invalid-dangling-alias.json +6 -0
  39. package/consumer-reference/fixtures/token-portability/invalid-extends.json +4 -0
  40. package/consumer-reference/fixtures/token-portability/invalid-json-pointer.json +7 -0
  41. package/consumer-reference/fixtures/token-portability/invalid-resolver.json +9 -0
  42. package/consumer-reference/fixtures/token-portability/invalid-type-mismatch.json +10 -0
  43. package/consumer-reference/fixtures/token-portability/invalid-unknown-reserved.json +6 -0
  44. package/consumer-reference/fixtures/token-portability/invalid-untested-type.json +6 -0
  45. package/consumer-reference/fixtures/token-portability/valid-border.json +14 -0
  46. package/consumer-reference/fixtures/token-portability/valid-reference.json +32 -0
  47. package/consumer-reference/fixtures/token-portability/valid-whole-alias.json +7 -0
  48. package/consumer-reference/fixtures/valid-deprecated.json +21 -0
  49. package/consumer-reference/fixtures/valid-experimental.json +19 -0
  50. package/consumer-reference/generated/manifest.json +40 -0
  51. package/consumer-reference/generated/tokens.css +12 -0
  52. package/consumer-reference/index.md +32 -0
  53. package/consumer-reference/policies/shared-experimental.json +37 -0
  54. package/consumer-reference/schema/ax-evidence.schema.json +30 -0
  55. package/consumer-reference/schema/baseline-manifest.schema.json +55 -0
  56. package/consumer-reference/schema/calibration-record.schema.json +190 -0
  57. package/consumer-reference/schema/capture-session.schema.json +161 -0
  58. package/consumer-reference/schema/component-state.schema.json +150 -0
  59. package/consumer-reference/schema/consumer-conformance-record.schema.json +365 -0
  60. package/consumer-reference/schema/dom-evidence.schema.json +38 -0
  61. package/consumer-reference/schema/evidence-record.schema.json +81 -0
  62. package/consumer-reference/schema/fixture-manifest.schema.json +32 -0
  63. package/consumer-reference/schema/item.schema.json +188 -0
  64. package/consumer-reference/schema/page-evidence-manifest.schema.json +216 -0
  65. package/consumer-reference/schema/page-evidence-session.schema.json +119 -0
  66. package/consumer-reference/schema/portable-tokens.schema.json +104 -0
  67. package/consumer-reference/schema/promotion-rfc.schema.json +219 -0
  68. package/consumer-reference/schema/runtime-evidence-manifest.schema.json +33 -0
  69. package/consumer-reference/schema/visual-evidence.schema.json +31 -0
  70. package/design-engineering/consumer-migration-readiness.md +124 -0
  71. package/design-engineering/index.md +28 -0
  72. package/design-engineering/interface-craft.md +107 -0
  73. package/design-engineering/reference-profiles/external-adaptation/index.md +12 -0
  74. package/design-engineering/reference-profiles/governed-local/editorial/components/button.component.json +125 -0
  75. package/design-engineering/reference-profiles/governed-local/editorial/evidence/button.evidence.json +3504 -0
  76. package/design-engineering/reference-profiles/governed-local/editorial/fixtures/button.fixture.json +65 -0
  77. package/design-engineering/reference-profiles/governed-local/editorial/generated/evidence-coverage.md +23 -0
  78. package/design-engineering/reference-profiles/governed-local/editorial/generated/keyboard-matrix.md +19 -0
  79. package/design-engineering/reference-profiles/governed-local/editorial/generated/state-matrix.md +21 -0
  80. package/design-engineering/reference-profiles/governed-local/editorial/local-foundations.json +12 -0
  81. package/design-engineering/reference-profiles/governed-local/editorial/profile.json +43 -0
  82. package/design-engineering/reference-profiles/governed-local/editorial/states/button.states.json +195 -0
  83. package/design-engineering/reference-profiles/governed-local/editorial/tokens.dtcg.json +17 -0
  84. package/design-engineering/reference-profiles/governed-local/index.md +26 -0
  85. package/design-engineering/reference-profiles/governed-local/terminal/components/button.component.json +125 -0
  86. package/design-engineering/reference-profiles/governed-local/terminal/evidence/button.evidence.json +3504 -0
  87. package/design-engineering/reference-profiles/governed-local/terminal/fixtures/button.fixture.json +65 -0
  88. package/design-engineering/reference-profiles/governed-local/terminal/generated/evidence-coverage.md +23 -0
  89. package/design-engineering/reference-profiles/governed-local/terminal/generated/keyboard-matrix.md +19 -0
  90. package/design-engineering/reference-profiles/governed-local/terminal/generated/state-matrix.md +21 -0
  91. package/design-engineering/reference-profiles/governed-local/terminal/local-foundations.json +12 -0
  92. package/design-engineering/reference-profiles/governed-local/terminal/profile.json +43 -0
  93. package/design-engineering/reference-profiles/governed-local/terminal/states/button.states.json +195 -0
  94. package/design-engineering/reference-profiles/governed-local/terminal/tokens.dtcg.json +17 -0
  95. package/design-engineering/reference-profiles/index.md +19 -0
  96. package/game-ui/classification.md +82 -0
  97. package/game-ui/index.md +35 -0
  98. package/game-ui/reference-record.md +62 -0
  99. package/game-ui/screen-hierarchy.md +107 -0
  100. package/game-ui/unity/architecture.md +166 -0
  101. package/game-ui/unity/cli-loop.md +84 -0
  102. package/game-ui/unity/data/unity-technologies-public-repositories.json +26654 -0
  103. package/game-ui/unity/org-wiki.md +146 -0
  104. package/game-ui/unity/repository-map.md +102 -0
  105. package/game-ui/unity/ui-systems.md +85 -0
  106. package/guides/decision-tree.md +149 -0
  107. package/guides/documentation-mode-taxonomy.md +157 -0
  108. package/guides/layout-brief.md +220 -0
  109. package/guides/vocabulary.md +148 -0
  110. package/guides/webpage-generation-workflow.md +185 -0
  111. package/index.md +36 -0
  112. package/layout/index.md +26 -0
  113. package/motion/index.md +24 -0
  114. package/motion/practice-reference.md +145 -0
  115. package/motion/review-workflow.md +86 -0
  116. package/motion/vocabulary.md +82 -0
  117. package/package.json +78 -0
  118. package/patterns/centering/center.md +87 -0
  119. package/patterns/centering/index.md +6 -0
  120. package/patterns/centering/super-center.md +89 -0
  121. package/patterns/containment/box.md +87 -0
  122. package/patterns/containment/clamped-card.md +86 -0
  123. package/patterns/containment/content-limiter.md +87 -0
  124. package/patterns/containment/fluid-styles.md +86 -0
  125. package/patterns/containment/index.md +8 -0
  126. package/patterns/grid-repetition/card-grid.md +88 -0
  127. package/patterns/grid-repetition/columns.md +87 -0
  128. package/patterns/grid-repetition/dense-grid.md +88 -0
  129. package/patterns/grid-repetition/grid-wrapper.md +89 -0
  130. package/patterns/grid-repetition/index.md +12 -0
  131. package/patterns/grid-repetition/masonry-approx.md +87 -0
  132. package/patterns/grid-repetition/page-grid.md +90 -0
  133. package/patterns/grid-repetition/ram-grid.md +88 -0
  134. package/patterns/grid-repetition/twelve-span-grid.md +92 -0
  135. package/patterns/in-line-grouping/badge-list.md +94 -0
  136. package/patterns/in-line-grouping/breadcrumb.md +89 -0
  137. package/patterns/in-line-grouping/cluster.md +89 -0
  138. package/patterns/in-line-grouping/deconstructed-pancake.md +92 -0
  139. package/patterns/in-line-grouping/index.md +13 -0
  140. package/patterns/in-line-grouping/pagination.md +89 -0
  141. package/patterns/in-line-grouping/reel.md +90 -0
  142. package/patterns/in-line-grouping/split-nav.md +97 -0
  143. package/patterns/in-line-grouping/tab-strip.md +88 -0
  144. package/patterns/in-line-grouping/wrap-row.md +89 -0
  145. package/patterns/index.md +13 -0
  146. package/patterns/media-fit/frame.md +95 -0
  147. package/patterns/media-fit/icon-frame.md +87 -0
  148. package/patterns/media-fit/index.md +6 -0
  149. package/patterns/overlay-exception/imposter.md +95 -0
  150. package/patterns/overlay-exception/index.md +6 -0
  151. package/patterns/overlay-exception/overlay-stack.md +89 -0
  152. package/patterns/split-sidebar/index.md +12 -0
  153. package/patterns/split-sidebar/list-detail.md +95 -0
  154. package/patterns/split-sidebar/main-with-rail.md +95 -0
  155. package/patterns/split-sidebar/media-object.md +102 -0
  156. package/patterns/split-sidebar/sidebar.md +101 -0
  157. package/patterns/split-sidebar/split-screen.md +92 -0
  158. package/patterns/split-sidebar/sticky-aside.md +97 -0
  159. package/patterns/split-sidebar/supporting-pane.md +95 -0
  160. package/patterns/split-sidebar/switcher.md +93 -0
  161. package/patterns/stacking/feed.md +88 -0
  162. package/patterns/stacking/index.md +8 -0
  163. package/patterns/stacking/line-up.md +95 -0
  164. package/patterns/stacking/stack.md +87 -0
  165. package/patterns/stacking/step-nav.md +88 -0
  166. package/patterns/viewport-shell/cover.md +90 -0
  167. package/patterns/viewport-shell/fixed-sidenav-shell.md +97 -0
  168. package/patterns/viewport-shell/holy-grail.md +112 -0
  169. package/patterns/viewport-shell/index.md +11 -0
  170. package/patterns/viewport-shell/panel-layout.md +95 -0
  171. package/patterns/viewport-shell/scroll-body-shell.md +93 -0
  172. package/patterns/viewport-shell/sticky-footer.md +92 -0
  173. package/patterns/viewport-shell/sticky-header.md +86 -0
  174. package/platform-guides/apple-interaction.md +89 -0
  175. package/platform-guides/index.md +26 -0
  176. package/quality/claim-records/index.md +3 -0
  177. package/quality/claim-records/samples.md +92 -0
  178. package/quality/claim-records/stylegallery-multidomain-scope.md +42 -0
  179. package/quality/claims.md +77 -0
  180. package/quality/evidence/accessibility.md +58 -0
  181. package/quality/evidence/consumer-migration.md +42 -0
  182. package/quality/evidence/design-rationale.md +34 -0
  183. package/quality/evidence/executable-evidence.md +79 -0
  184. package/quality/evidence/families.md +56 -0
  185. package/quality/evidence/hci-evaluation.md +36 -0
  186. package/quality/evidence/index.md +16 -0
  187. package/quality/evidence/pattern-contract-audit.md +96 -0
  188. package/quality/evidence/search-metadata-polyhierarchy.md +86 -0
  189. package/quality/evidence/sources.md +43 -0
  190. package/quality/evidence/tokens.md +33 -0
  191. package/quality/evidence/visual-qa.md +41 -0
  192. package/quality/gates/accessibility-evidence.md +60 -0
  193. package/quality/gates/consumer-migration-evidence.md +53 -0
  194. package/quality/gates/design-claim.md +56 -0
  195. package/quality/gates/harmony-evaluation.md +78 -0
  196. package/quality/gates/index.md +13 -0
  197. package/quality/gates/layout.md +52 -0
  198. package/quality/gates/rationale.md +53 -0
  199. package/quality/gates/visual-evidence.md +47 -0
  200. package/quality/index.md +55 -0
  201. package/quality/principles.md +58 -0
  202. package/recipes/article-page.md +52 -0
  203. package/recipes/command-surface.md +55 -0
  204. package/recipes/dashboard.md +56 -0
  205. package/recipes/form-flow.md +55 -0
  206. package/recipes/homepage.md +89 -0
  207. package/recipes/index.md +13 -0
  208. package/recipes/list-detail.md +55 -0
  209. package/recipes/primitive-to-recipe-matrix.md +83 -0
  210. package/recipes/saas-settings.md +52 -0
  211. package/scripts/agent-native/a2a-projection.mjs +248 -0
  212. package/scripts/agent-native/agui-projection.mjs +178 -0
  213. package/scripts/agent-native/canonical-json.mjs +109 -0
  214. package/scripts/agent-native/cli-adapter.mjs +68 -0
  215. package/scripts/agent-native/events.mjs +113 -0
  216. package/scripts/agent-native/execution.mjs +227 -0
  217. package/scripts/agent-native/fixture.mjs +159 -0
  218. package/scripts/agent-native/identity.mjs +184 -0
  219. package/scripts/agent-native/immutable-store.mjs +102 -0
  220. package/scripts/agent-native/knowledge.mjs +168 -0
  221. package/scripts/agent-native/learning-records.mjs +244 -0
  222. package/scripts/agent-native/learning.mjs +247 -0
  223. package/scripts/agent-native/mcp-adapter.mjs +173 -0
  224. package/scripts/agent-native/queries.mjs +173 -0
  225. package/scripts/agent-native/registry.mjs +154 -0
  226. package/scripts/agent-native/retrieval.mjs +171 -0
  227. package/scripts/agent-native/self-description.mjs +160 -0
  228. package/scripts/artifact-metadata.mjs +20 -0
  229. package/scripts/audit-evidence-freshness.mjs +308 -0
  230. package/scripts/baseline-contract.mjs +189 -0
  231. package/scripts/baseline-schema-parity.mjs +40 -0
  232. package/scripts/build-reference-artifacts.mjs +127 -0
  233. package/scripts/calibration-raw-contract.mjs +172 -0
  234. package/scripts/capture-session-contract.mjs +187 -0
  235. package/scripts/component-state-artifact-fixture.mjs +44 -0
  236. package/scripts/component-state-contract.mjs +99 -0
  237. package/scripts/component-state-semantics.mjs +128 -0
  238. package/scripts/component-state-workflow-contract.mjs +67 -0
  239. package/scripts/component-state-workflow-negative-cases.mjs +64 -0
  240. package/scripts/consumer-conformance-contract.mjs +198 -0
  241. package/scripts/consumer-evidence-governance-contract.mjs +210 -0
  242. package/scripts/consumer-reference-case-runner.mjs +93 -0
  243. package/scripts/consumer-reference-schema.mjs +155 -0
  244. package/scripts/create-component-state-session.mjs +100 -0
  245. package/scripts/create-page-evidence-session.mjs +139 -0
  246. package/scripts/domain-document-boundaries.mjs +40 -0
  247. package/scripts/domain-validation-checks.mjs +141 -0
  248. package/scripts/evidence-artifact-contract.mjs +191 -0
  249. package/scripts/finalize-component-state-evidence.mjs +165 -0
  250. package/scripts/finalize-page-evidence.mjs +197 -0
  251. package/scripts/generate-consumer-reference-evidence.mjs +154 -0
  252. package/scripts/generate-patterns.mjs +218 -0
  253. package/scripts/governance-matrix-contract.mjs +73 -0
  254. package/scripts/governance-matrix-negative-cases.mjs +114 -0
  255. package/scripts/governance-policy-contract.mjs +49 -0
  256. package/scripts/governance-test-fixture.mjs +321 -0
  257. package/scripts/governance-workflow-negative-cases.mjs +241 -0
  258. package/scripts/governed-profile-registry.mjs +125 -0
  259. package/scripts/json-schema-formats.mjs +31 -0
  260. package/scripts/markdown-structure.mjs +45 -0
  261. package/scripts/page-artifact-metadata.mjs +124 -0
  262. package/scripts/page-evidence-contract.mjs +297 -0
  263. package/scripts/page-evidence-fixture.mjs +271 -0
  264. package/scripts/pattern-data.mjs +325 -0
  265. package/scripts/profile-record-contract.mjs +140 -0
  266. package/scripts/promotion-attestation-contract.mjs +91 -0
  267. package/scripts/promotion-boundary-test-contract.mjs +92 -0
  268. package/scripts/promotion-fixture-inventory.mjs +109 -0
  269. package/scripts/promotion-governance-contract.mjs +28 -0
  270. package/scripts/reference-artifact-path-contract.mjs +28 -0
  271. package/scripts/reference-profile-contract.mjs +114 -0
  272. package/scripts/reference-token-contract.mjs +156 -0
  273. package/scripts/run-consumer-page-evidence-ci.mjs +170 -0
  274. package/scripts/sg-mcp.mjs +16 -0
  275. package/scripts/sg.mjs +27 -0
  276. package/scripts/strict-json.mjs +72 -0
  277. package/scripts/summarize-sentinel-calibration.mjs +98 -0
  278. package/scripts/test-agent-adapter-conformance.mjs +250 -0
  279. package/scripts/test-agent-conformance-receipt.mjs +106 -0
  280. package/scripts/test-agent-events.mjs +81 -0
  281. package/scripts/test-agent-execution-effects.mjs +114 -0
  282. package/scripts/test-agent-execution-fixtures.mjs +140 -0
  283. package/scripts/test-agent-execution-kernel.mjs +39 -0
  284. package/scripts/test-agent-execution-learning.mjs +130 -0
  285. package/scripts/test-agent-execution-lifecycle.mjs +143 -0
  286. package/scripts/test-agent-execution-safety.mjs +158 -0
  287. package/scripts/test-agent-execution-views.mjs +117 -0
  288. package/scripts/test-agent-identity-integrity-cases.mjs +160 -0
  289. package/scripts/test-agent-knowledge-kernel.mjs +183 -0
  290. package/scripts/test-agent-learning.mjs +246 -0
  291. package/scripts/test-agent-mcp.mjs +246 -0
  292. package/scripts/test-agent-native-schemas.mjs +215 -0
  293. package/scripts/test-agent-projections.mjs +249 -0
  294. package/scripts/test-agent-registry-mcp-integrity.mjs +215 -0
  295. package/scripts/test-agent-registry-mutations.mjs +110 -0
  296. package/scripts/test-audit-evidence-freshness.mjs +177 -0
  297. package/scripts/test-component-state-sentinel.mjs +35 -0
  298. package/scripts/test-component-state-source-contract.mjs +83 -0
  299. package/scripts/test-consumer-conformance-sentinel.mjs +165 -0
  300. package/scripts/test-consumer-reference-sentinel.mjs +31 -0
  301. package/scripts/test-generate-consumer-reference-evidence.mjs +124 -0
  302. package/scripts/test-json-cli-output.mjs +151 -0
  303. package/scripts/test-json-schema-formats.mjs +40 -0
  304. package/scripts/test-reference-adapters.mjs +199 -0
  305. package/scripts/test-renderer-purity.mjs +34 -0
  306. package/scripts/test-sg-cli.mjs +129 -0
  307. package/scripts/test-summarize-sentinel-calibration.mjs +226 -0
  308. package/scripts/test-validate-baseline-manifest.mjs +234 -0
  309. package/scripts/test-validate-component-state-artifacts.mjs +243 -0
  310. package/scripts/test-validate-component-state.mjs +106 -0
  311. package/scripts/test-validate-consumer-conformance.mjs +427 -0
  312. package/scripts/test-validate-consumer-reference-cli.mjs +69 -0
  313. package/scripts/test-validate-consumer-reference.mjs +263 -0
  314. package/scripts/test-validate-domains.mjs +357 -0
  315. package/scripts/test-validate-governance.mjs +292 -0
  316. package/scripts/test-validate-ia.mjs +262 -0
  317. package/scripts/test-validate-okf.mjs +73 -0
  318. package/scripts/test-validate-page-evidence.mjs +302 -0
  319. package/scripts/test-validate-patterns.mjs +157 -0
  320. package/scripts/test-validate-promotion-rfc.mjs +250 -0
  321. package/scripts/test-validate-reference-profiles.mjs +170 -0
  322. package/scripts/test-validate-unity-org-wiki.mjs +57 -0
  323. package/scripts/test-validate-unity-source-contracts.mjs +67 -0
  324. package/scripts/test-validate-vocabulary.mjs +174 -0
  325. package/scripts/test-validate-webpage-workflow.mjs +293 -0
  326. package/scripts/validate-baseline-manifest.mjs +44 -0
  327. package/scripts/validate-catalog.mjs +65 -0
  328. package/scripts/validate-component-state.mjs +141 -0
  329. package/scripts/validate-consumer-conformance.mjs +477 -0
  330. package/scripts/validate-consumer-reference.mjs +288 -0
  331. package/scripts/validate-domains.mjs +237 -0
  332. package/scripts/validate-governance.mjs +248 -0
  333. package/scripts/validate-ia.mjs +136 -0
  334. package/scripts/validate-links.mjs +66 -0
  335. package/scripts/validate-okf.mjs +104 -0
  336. package/scripts/validate-page-evidence.mjs +191 -0
  337. package/scripts/validate-patterns.mjs +246 -0
  338. package/scripts/validate-promotion-rfc.mjs +224 -0
  339. package/scripts/validate-reference-artifacts.mjs +125 -0
  340. package/scripts/validate-renderer-purity.mjs +56 -0
  341. package/scripts/validate-unity-org-wiki.mjs +146 -0
  342. package/scripts/validate-unity-source-contracts.mjs +107 -0
  343. package/scripts/validate-vocabulary.mjs +115 -0
  344. package/scripts/validate-webpage-workflow.mjs +254 -0
  345. package/scripts/visual-expectation-contract.mjs +20 -0
  346. package/scripts/workflow-action-contract.mjs +163 -0
@@ -0,0 +1,107 @@
1
+ ---
2
+ type: Domain Guide
3
+ title: Game UI Screen Hierarchy
4
+ description: Engine-neutral ownership model for composing game-interface shells, screens, layers, regions, components, and controls.
5
+ domain: game-ui
6
+ lifecycle: experimental
7
+ ---
8
+
9
+ # Game UI Screen Hierarchy
10
+
11
+ Primary role: engine-neutral hierarchy guide.
12
+
13
+ ## Repository Boundary
14
+
15
+ This hierarchy describes interface responsibility, not a required scene graph or prefab tree. Engines may realize the same roles through scenes, widgets, documents, entities, prefabs, or runtime objects.
16
+
17
+ ## Reusable Method
18
+
19
+ Read a game UI hierarchy from ownership outward:
20
+
21
+ 1. Identify the lifetime owner.
22
+ 2. Identify the active player task.
23
+ 3. Separate persistent, replaceable, modal, transient, and world-linked layers.
24
+ 4. Name screen regions by responsibility.
25
+ 5. Find repeated components and atomic controls.
26
+ 6. Record navigation, input blocking, sorting, focus, and teardown ownership.
27
+
28
+ ## Reference Hierarchy
29
+
30
+ ```text
31
+ Application UI Root
32
+ ├── Persistent Services
33
+ │ ├── Input and Focus Routing
34
+ │ ├── Loading and Blocking
35
+ │ ├── Notifications
36
+ │ └── Accessibility and Localization
37
+ ├── Screen Host
38
+ │ └── Active Screen
39
+ │ ├── Screen Header
40
+ │ ├── Primary Region
41
+ │ ├── Supporting Region
42
+ │ └── Screen Actions
43
+ ├── HUD Layer
44
+ │ ├── Player Status
45
+ │ ├── World Status
46
+ │ ├── Objectives
47
+ │ └── Context Actions
48
+ ├── Modal Layer
49
+ │ ├── Blocker
50
+ │ └── Dialog or Popup Stack
51
+ ├── Transient Layer
52
+ │ ├── Toasts
53
+ │ ├── Tooltips
54
+ │ └── Reward and Feedback Effects
55
+ └── World-Linked UI
56
+ ├── Markers
57
+ ├── Labels
58
+ └── Interaction Prompts
59
+ ```
60
+
61
+ ## Hierarchy Roles
62
+
63
+ | Level | Owns | Must not silently own |
64
+ | --- | --- | --- |
65
+ | Application root | Cross-screen lifetime, global routing, top-level sorting | Screen-specific business state |
66
+ | Layer host | Ordering, visibility policy, input blocking | Individual component presentation |
67
+ | Screen | One primary player task and its navigation boundary | Unrelated global services |
68
+ | Region | A stable information or action responsibility | Whole-screen lifecycle |
69
+ | Component | Reusable stateful presentation unit | Global navigation policy |
70
+ | Control | One direct interaction or value presentation | Hidden cross-screen side effects |
71
+
72
+ ## Composition Rules
73
+
74
+ - Keep persistent services independent from replaceable screen content.
75
+ - Assign explicit ownership for modal blocking and modal content.
76
+ - Separate popup stacks, notifications, tooltips, and reward effects when their lifetime, input, sorting, or interruption responsibilities differ.
77
+ - Distinguish world-linked UI from screen-space HUD by camera, target, and lifetime ownership, not shared visual tokens.
78
+ - Prefer explicit data and state inputs for repeated list cells, slots, tabs, meters, and buttons over implicit global-state access.
79
+ - Preserve logical navigation order when visual sorting or animation changes.
80
+
81
+ ## Opinionated Guidance
82
+
83
+ A shallow tree is not automatically better than a deep tree. Prefer boundaries that make lifetime, input, sorting, and reuse obvious. Undocumented nodes used only to offset animation, scaling, or masking side effects are a fragility signal.
84
+
85
+ ## Platform-Specific Guidance
86
+
87
+ Map these roles to the target engine without copying the hierarchy literally. See [Unity UI Architecture](unity/architecture.md) for Unity Scene, Canvas, prefab, and runtime mapping.
88
+
89
+ ## Unsupported Absolutes
90
+
91
+ - Do not require one root Canvas, widget tree, or scene for every game.
92
+ - Do not equate folder nesting with runtime ownership.
93
+ - Do not assume a prefab, widget, or component boundary is also a navigation boundary.
94
+ - Do not infer input blocking or render order from hierarchy position alone.
95
+
96
+ ## Verification Contract
97
+
98
+ Trace one screen from creation through teardown. Record its creator, sorting layer, input blocker, focus entry and return, what survives screen changes, and modal or transition interruption behavior.
99
+
100
+ ## Source, License, And Attribution
101
+
102
+ This page synthesizes recurring hierarchy responsibilities observed across game UI implementations without reproducing any project-specific object tree.
103
+
104
+ ## IA Navigation
105
+
106
+ Parent: [Game UI](index.md).
107
+ Next: [Game UI Reference Record](reference-record.md).
@@ -0,0 +1,166 @@
1
+ ---
2
+ type: Domain Guide
3
+ title: Unity UI Architecture
4
+ description: Unity-specific mapping from engine-neutral game UI hierarchy to Scenes, Canvas layers, prefabs, runtime instances, and motion ownership.
5
+ domain: game-ui
6
+ lifecycle: experimental
7
+ source_repository: https://github.com/annulusgames/UGUIAnimationSamples
8
+ source_path: README.md
9
+ source_revision: 343c8110e5683be209cc01ccb4cb986175e61643
10
+ platform: Unity uGUI and legacy Unity UI stacks
11
+ platform_version: Unity 2022.3.7f1 sample evidence; Unity 6.3 LTS and uGUI 2.0 guidance
12
+ reviewed_on: 2026-07-14
13
+ ---
14
+
15
+ # Unity UI Architecture
16
+
17
+ Primary role: Unity hierarchy and implementation guide.
18
+
19
+ ## Repository Boundary
20
+
21
+ This page maps the engine-neutral [Game UI Screen Hierarchy](../screen-hierarchy.md) to Unity concepts. It does not define game UI classification, require one universal Scene or Canvas structure, or treat a sample repository as a complete production architecture.
22
+
23
+ ## Version Boundary
24
+
25
+ Two evidence contexts are intentionally separate:
26
+
27
+ - **Pinned sample evidence:** the UGUI Animation Samples revision `343c8110e5683be209cc01ccb4cb986175e61643` records Unity `2022.3.7f1`, uGUI `1.0.0`, and TextMesh Pro `3.0.7`. Claims about its files apply only to that immutable snapshot.
28
+ - **Current implementation guidance:** Unity Manual `6000.3` (Unity 6.3 LTS) and uGUI package `2.0` documentation were reviewed on 2026-07-14. Use those versioned documents for the concepts linked below, then verify the exact Unity and package versions recorded by each gallery entry.
29
+
30
+ The pinned project is evidence about a small animation sample, not proof that its serialized hierarchy, packages, or lifecycle choices are appropriate for production or current Unity versions.
31
+
32
+ ## Reusable Method
33
+
34
+ Inspect a Unity UI reference in this order:
35
+
36
+ 1. Record the Unity editor and UI package versions.
37
+ 2. Identify the Scene or persistent bootstrap object that owns UI lifetime.
38
+ 3. Locate root Canvas, UIDocument, or legacy NGUI panel boundaries.
39
+ 4. Identify screen, HUD, modal, transient, and world-space hosts.
40
+ 5. Trace prefab assets, nested prefabs, variants, scene instances, and runtime-created instances.
41
+ 6. Record sorting, input routing, focus, scaling, animation, and teardown ownership.
42
+ 7. Compare the rendered result with the engine-neutral Game UI record.
43
+
44
+ ## Scene And Runtime Hierarchy
45
+
46
+ Unity's Hierarchy window shows GameObjects in the loaded Scene, including prefab instances. It does not by itself reveal asset ownership, runtime-created objects, persistent objects from another Scene, or the complete navigation policy.
47
+
48
+ ```text
49
+ Bootstrap or Loaded Scene
50
+ ├── Persistent UI Services
51
+ │ ├── EventSystem or Input Router
52
+ │ ├── Loading and Blocking Host
53
+ │ └── Notification Host
54
+ ├── Screen-Space UI Root
55
+ │ ├── Screen Canvas or UIDocument
56
+ │ ├── HUD Canvas
57
+ │ ├── Modal Canvas
58
+ │ └── Transient Effects Canvas
59
+ └── World-Space UI Roots
60
+ ├── Markers
61
+ ├── Labels
62
+ └── Interaction Prompts
63
+ ```
64
+
65
+ Treat this as a responsibility map. A project may combine or split these roots according to rebuild cost, sorting, camera setup, lifetime, input, and team ownership.
66
+
67
+ ## Prefab Hierarchy
68
+
69
+ | Unity concept | What it represents | Review question |
70
+ | --- | --- | --- |
71
+ | Prefab asset | Reusable serialized GameObject hierarchy | What stable responsibility does the asset own? |
72
+ | Prefab instance | Scene or runtime occurrence linked to an asset | Which properties are overrides, and who owns its lifetime? |
73
+ | Nested prefab | Prefab instance preserved inside another prefab | Does nesting express reuse or hide cross-component coupling? |
74
+ | Prefab variant | Asset inheriting from another prefab | Are differences intentional variants or accumulated overrides? |
75
+ | Unpacked object | Hierarchy no longer linked as an instance | Was the loss of inheritance deliberate and recorded? |
76
+ | Runtime instance | Object created during play | Where is it parented, initialized, focused, pooled, and destroyed? |
77
+
78
+ Use prefab boundaries for stable ownership and reuse. Do not create a prefab for every visual node, and do not let a large screen prefab silently own global routing, data services, or unrelated modal layers.
79
+
80
+ ## Canvas And Layer Ownership
81
+
82
+ | Layer responsibility | Typical Unity realization | Evidence to capture |
83
+ | --- | --- | --- |
84
+ | Persistent services | DontDestroyOnLoad root or bootstrap Scene | Creation order, duplicate prevention, teardown policy |
85
+ | Active screen | Screen prefab under a screen host | Navigation boundary, initial focus, close behavior |
86
+ | HUD | Dedicated Canvas or stable subtree | Camera relationship, update ownership, visibility policy |
87
+ | Modal | Sorting layer with blocker and popup stack | Raycast blocking, stacking, cancellation, focus return |
88
+ | Transient feedback | Pooled toast, tooltip, reward, or effect host | Sorting, pooling, interruption, time source |
89
+ | World-linked UI | World Space Canvas or camera-projected element | Target loss, occlusion, distance, camera switching |
90
+
91
+ Canvas boundaries create ownership, sorting, and configuration decisions. Measure batching and rebuild behavior with the actual content and update pattern, and profile representative target-device workloads before attributing a performance benefit to nested Canvases.
92
+
93
+ ## Component Hierarchy
94
+
95
+ A reusable Unity UI component commonly separates these roles:
96
+
97
+ ```text
98
+ Component Prefab Root
99
+ ├── Layout Root
100
+ ├── Visual States
101
+ ├── Content Bindings
102
+ ├── Interaction Target
103
+ ├── Optional Feedback Effects
104
+ └── Component Controller
105
+ ```
106
+
107
+ - `RectTransform` hierarchy expresses layout and parenting, not business ownership by itself.
108
+ - `CanvasGroup` may coordinate visibility, interaction, and raycast blocking; verify all three properties.
109
+ - `Selectable` navigation and EventSystem state require keyboard and gamepad evidence, not only pointer behavior.
110
+ - ScrollRect structures should make viewport, content, scrollbar, cell reuse, and scroll ownership explicit.
111
+ - Text components require localization, fallback, wrapping, material, and dynamic-size evidence.
112
+
113
+ ## Motion Ownership
114
+
115
+ The pinned snapshot contains four serialized Scene YAML files and scripts for hover, button, text, and toggle examples. The scripts use LitMotion; `TextAnimation.cs` and the pinned package files contain text evidence of UniTask use for button-click subscriptions. Text and YAML inspection does not prove compilation, rendering, or runtime behavior, although the YAML records Screen Space Overlay Canvas, Canvas Scaler, and EventSystem components.
116
+
117
+ Use the snapshot only as serialized evidence for component interaction motion. It does not establish a production Scene or prefab architecture, keyboard or gamepad coverage, responsive behavior, multi-Scene lifetime, successful runtime execution, or teardown policy. The inspected hover and button scripts contain `OnDestroy` cancellation paths; the two toggle scripts do not contain `OnDestroy`, but that absence alone is not proof of a leak or other runtime defect.
118
+
119
+ Record whether motion is owned by Animator, a tween library, Timeline, a custom update loop, or a mixed system. For every transition, identify the trigger, animated properties, time source, cancellation behavior, disabled-object behavior, completion callback, and final state. A parent screen transition must not leave child controls focused, interactive, or visually stale.
120
+
121
+ ## Opinionated Guidance
122
+
123
+ - Separate Scene lifetime, layer lifetime, screen lifetime, and component lifetime.
124
+ - Prefer a small number of named layer hosts over ad hoc sorting overrides across unrelated prefabs.
125
+ - Keep screen prefabs focused on one primary player task; route global blockers and notifications through explicit hosts.
126
+ - Use nested prefabs and variants when inheritance is intentional and reviewable, not merely to reduce duplication at any cost.
127
+
128
+ ## Platform-Specific Guidance
129
+
130
+ - Record whether the entry uses uGUI, UI Toolkit, legacy NGUI, or a mixed stack.
131
+ - For uGUI, capture Canvas render mode, Canvas Scaler settings, sorting configuration, Graphic Raycaster, EventSystem, and relevant input module.
132
+ - For UI Toolkit, capture Panel Settings, UIDocument ownership, visual tree source, style-sheet sources, focus behavior, and runtime document lifecycle.
133
+ - For legacy or mixed stacks, name the bridge points, camera and sorting relationships, input ownership, and migration limits.
134
+
135
+ ## Unsupported Absolutes
136
+
137
+ - Do not require one Canvas for an entire application or one Canvas per screen.
138
+ - Do not equate Scene hierarchy order with render order, input priority, or lifetime ownership.
139
+ - Do not assume a prefab instance is unchanged; inspect overrides and variants.
140
+ - Do not call a UI responsive because Canvas Scaler is present.
141
+ - Do not infer runtime behavior from YAML, asset paths, or prefab names alone.
142
+ - Do not claim one animation system is faster or easier to maintain without measurements and project constraints.
143
+
144
+ ## Verification Contract
145
+
146
+ Open the target Scene and Prefab Mode, then enter Play Mode. Capture the loaded Scene hierarchy, persistent objects, root UI hosts, prefab instance links and overrides, Canvas settings, sorting, EventSystem selection, and runtime-created objects. Exercise scene changes, repeated screen open and close, nested modals, focus return, safe areas, long localized text, paused or scaled time, and interrupted transitions.
147
+
148
+ Repository YAML and metadata can establish hierarchy leads, but rendered appearance and runtime ownership remain unverified until Editor and Play Mode evidence is attached.
149
+
150
+ ## Source, License, And Attribution
151
+
152
+ - Public sample snapshot: [annulusgames/UGUIAnimationSamples at `343c8110e5683be209cc01ccb4cb986175e61643`](https://github.com/annulusgames/UGUIAnimationSamples/tree/343c8110e5683be209cc01ccb4cb986175e61643) and its pinned [README.md](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/README.md)
153
+ - Pinned version and dependency evidence: [ProjectVersion.txt](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/ProjectSettings/ProjectVersion.txt), [manifest.json](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Packages/manifest.json), and [packages-lock.json](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Packages/packages-lock.json)
154
+ - Pinned serialized Scene evidence: [1_Hover.unity](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/1_Hover/1_Hover.unity), [2_Button.unity](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/2_Button/2_Button.unity), [3_Text.unity](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/3_Text/3_Text.unity), and [4_Toggle.unity](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/4_Toggle/4_Toggle.unity)
155
+ - Pinned hover script evidence: [Hover1.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/1_Hover/Scripts/Hover1.cs), [Hover2.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/1_Hover/Scripts/Hover2.cs), [Hover3.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/1_Hover/Scripts/Hover3.cs), [Hover4.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/1_Hover/Scripts/Hover4.cs), [Hover5.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/1_Hover/Scripts/Hover5.cs), and [Hover6.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/1_Hover/Scripts/Hover6.cs)
156
+ - Pinned button, text, and toggle script evidence: [Button1.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/2_Button/Scripts/Button1.cs), [Button2.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/2_Button/Scripts/Button2.cs), [TextAnimation.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/3_Text/Scripts/TextAnimation.cs), [Toggle1.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/4_Toggle/Scripts/Toggle1.cs), and [Toggle2.cs](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/Assets/Samples/4_Toggle/Scripts/Toggle2.cs)
157
+ - Snapshot license: [The Unlicense](https://github.com/annulusgames/UGUIAnimationSamples/blob/343c8110e5683be209cc01ccb4cb986175e61643/LICENSE)
158
+ - Unity 6.3 LTS Manual: [UI system comparison](https://docs.unity3d.com/6000.3/Documentation/Manual/UI-system-compare.html), [Hierarchy window](https://docs.unity3d.com/6000.3/Documentation/Manual/Hierarchy.html), [Prefabs](https://docs.unity3d.com/6000.3/Documentation/Manual/Prefabs.html), [creating Prefabs](https://docs.unity3d.com/6000.3/Documentation/Manual/CreatingPrefabs.html), [nested Prefabs](https://docs.unity3d.com/6000.3/Documentation/Manual/NestedPrefabs.html), [Prefab variants](https://docs.unity3d.com/6000.3/Documentation/Manual/PrefabVariants.html), [unpacking Prefab instances](https://docs.unity3d.com/6000.3/Documentation/Manual/UnpackingPrefabInstances.html), [`Object.Instantiate`](https://docs.unity3d.com/6000.3/Documentation/ScriptReference/Object.Instantiate.html), and [`Object.DontDestroyOnLoad`](https://docs.unity3d.com/6000.3/Documentation/ScriptReference/Object.DontDestroyOnLoad.html)
159
+ - uGUI 2.0 Manual: [Canvas](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/UICanvas.html), [Rect Transform](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/class-RectTransform.html), [Canvas Group](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/class-CanvasGroup.html), [Canvas Scaler](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/script-CanvasScaler.html), [navigation options](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/script-SelectableNavigation.html), [Event System](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/EventSystem.html), [Graphic Raycaster](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/script-GraphicRaycaster.html), and [Scroll Rect](https://docs.unity3d.com/Packages/com.unity.ugui@2.0/manual/script-ScrollRect.html)
160
+ - Unity 6.3 LTS UI Toolkit Manual: [create a UI Document component](https://docs.unity3d.com/6000.3/Documentation/Manual/UIE-create-ui-document-component.html) and [focus order](https://docs.unity3d.com/6000.3/Documentation/Manual/UIE-focus-order.html)
161
+ - Reuse form: independent, project-neutral architecture and review method; no game assets or upstream implementation samples are reproduced.
162
+
163
+ ## IA Navigation
164
+
165
+ Parent: [Game UI](../index.md).
166
+ Next: [Unity UI Systems](ui-systems.md).
@@ -0,0 +1,84 @@
1
+ ---
2
+ type: Domain Guide
3
+ title: Unity CLI Loop
4
+ description: Source-pinned workflow for inspecting and exercising Unity Game UI with unity-cli-loop while preserving UI-stack boundaries.
5
+ domain: game-ui
6
+ lifecycle: experimental
7
+ source_repository: https://github.com/hatayama/unity-cli-loop
8
+ source_path: README.md
9
+ source_revision: 61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0
10
+ platform: Unity 2022.3 or later as stated by the pinned source
11
+ platform_version: unity-cli-loop source snapshot 61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0
12
+ reviewed_on: 2026-07-14
13
+ ---
14
+
15
+ # Unity CLI Loop
16
+
17
+ Primary role: Unity command-loop verification guide.
18
+
19
+ ## Repository Boundary
20
+
21
+ This guide adapts the pinned unity-cli-loop command surface into a bounded Game UI inspection workflow. It documents what the audited source exposes for Editor control, hierarchy inspection, screenshots, uGUI interaction, input injection, and dynamic C# execution. No live Unity project was executed during this source review, so project compatibility and observed runtime results must be supplied by the user of the guide.
22
+
23
+ ## Reusable Method
24
+
25
+ Use the loop in this order and preserve the evidence from each stage.
26
+
27
+ 1. **Launch the matching Editor.** Run the launch workflow from the Unity project so its recorded Editor version is selected. The pinned README exposes `uloop launch`, project-path selection, build-target selection, and restart behavior in its [direct CLI section](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/README.md#direct-cli-usage-advanced).
28
+ 2. **Compile from a clean console.** Clear stale console entries when appropriate, run `compile`, wait for domain reload when the task requires it, then collect logs. Do not proceed to UI interaction while compile errors make the runtime state ambiguous.
29
+ 3. **Inspect hierarchy and find objects.** Record the loaded Scene context, then use the hierarchy and GameObject search workflows to locate Transforms, `Canvas`, `EventSystem`, `UIDocument`, `UIRoot`, `UIPanel`, and other serialized components. The hierarchy service traverses GameObjects and Transforms in [`HierarchyService.cs`](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/Packages/src/Editor/Core/CoreTools/HierarchyAnalyzer/HierarchyService.cs#L338-L379). A UI Toolkit VisualElement child is not a Transform child, so finding a `UIDocument` does not enumerate its runtime visual tree.
30
+ 4. **Enter Play Mode when runtime evidence is required.** Use the Play Mode control workflow before Game View rendering capture and annotations, pointer simulation, Input System injection, input recording or replay, and inspection of runtime-created objects. Window screenshots may work outside Play Mode, but `CaptureMode: rendering` requires Play Mode at the pinned revision. Capture logs immediately after state changes.
31
+ 5. **Capture the correct screenshot.** An Editor-window screenshot can show editor chrome outside Play Mode. In Play Mode, use the Game View rendering capture and its annotations when coordinates or runtime UI evidence are needed. Keep the pre-action image.
32
+ 6. **Simulate through the stack-appropriate route.** Use the dedicated uGUI pointer workflow for EventSystem-handled UI. Use Input System mouse or keyboard injection only when the project actually reads that input path. For UI Toolkit or NGUI, combine rendering, component inspection, and narrowly scoped project code while keeping their distinct event routes explicit.
33
+ 7. **Use dynamic code for targeted inspection or mutation.** Query project state, inspect `UIDocument.rootVisualElement`, or make bounded editor changes with `execute-dynamic-code`. Treat the result as evidence of the code that ran, not as proof that a player-input path was exercised.
34
+
35
+ > [!IMPORTANT]
36
+ > **Dynamic-code security boundary:** Use the lowest sufficient security level and keep **Restricted** unless the task specifically requires an operation it blocks. Restricted is defense-in-depth, not a trust boundary or a Unity-only sandbox. At the pinned revision, submitted code can read arbitrary files available to the Editor process, can create files and write through permitted stream APIs, can call Unity APIs and .NET standard libraries, and can invoke user-defined project assemblies; those assemblies may expose additional capabilities. Selected deletion, direct file-writing helpers, network, process, dynamic-loading, thread, and registry operations are blocked, and the compiled assembly is validated before and after load, but these checks do not make untrusted code safe. **Review and trust submitted code in both Restricted and FullAccess modes. FullAccess removes the Restricted-mode checks and should be exceptional.** Run AI-generated or otherwise untrusted dynamic code only inside a disposable, least-privilege VM or container with no host credentials, personal files, production tokens, or writable host mounts. Before either mode, review the submitted code and the target Unity project, including project assemblies it can call. Turn off `execute-dynamic-code` in the tool settings when it is unnecessary. The security level is persisted in `.uloop/settings.permissions.json`; although the upstream README permits optional team sharing, keep permission and related local configuration out of commits or published artifacts when it would reveal the project's security policy. See the pinned [security policy](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/SECURITY.md#security-best-practices-for-users), [README security levels](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/README.md#10-execute-dynamic-code---dynamic-c-code-execution), and [settings file guidance](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/README.md#unity-cli-loop-files).
37
+ 8. **Capture the result and save intentionally.** Collect the post-action screenshot and logs, compare the expected state, and explicitly save Scene or prefab changes when the task changed serialized content.
38
+
39
+ ## Stack-Specific Interaction Boundary
40
+
41
+ | Stack | What the pinned workflow exposes | Required caution |
42
+ | --- | --- | --- |
43
+ | uGUI | Dedicated annotation scans uGUI `Selectable` and EventSystem handler targets. `simulate-mouse-ui` constructs pointer/drag events and requires Play Mode plus an EventSystem; ordinary Canvas interaction also needs the project's raycast path, commonly an active Graphic Raycaster. See [`UIElementAnnotator.cs`](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/Packages/src/Editor/Utils/UIElementAnnotator.cs#L145-L215) and [`SimulateMouseUiTool.cs`](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/Packages/src/Editor/Api/McpTools/SimulateMouseUi/SimulateMouseUiTool.cs#L31-L49). | Confirm the active EventSystem, input module, raycaster, blockers, selected object, and target Scene before interpreting a click or drag. |
44
+ | UI Toolkit | Rendering capture can show the Game View, and generic hierarchy inspection can find a `UIDocument` component. Dynamic C# can query its runtime `rootVisualElement`. | The VisualElement tree is Panel-owned rather than Transform-owned. At the pinned snapshot, the audited dedicated UI annotations and pointer tool are uGUI/EventSystem-oriented, so VisualElement lookup and manipulation remain project-specific work. |
45
+ | NGUI | Rendering capture and generic GameObject/component inspection can locate `UIRoot`, `UIPanel`, widgets, and `UICamera`. Dynamic C# can read or set component state. | NGUI's pinned [`UICamera`](https://github.com/tasharen/ngui/blob/9bbc56f11e0e25b89fd55b9b9bc67ddf1f182fe2/Assets/NGUI/Scripts/UI/UICamera.cs#L13-L43) performs its own raycasts and message dispatch with legacy `UnityEngine.Input` defaults. EventSystem dispatch or New Input System injection does not by itself demonstrate that UICamera processed the same pointer route. |
46
+
47
+ ## Coordinate Contract
48
+
49
+ Use the `SimX` and `SimY` values returned by the rendering annotation directly with the matching simulation call. They are caller-facing Game View input coordinates with a top-left origin. Do not substitute Transform positions, RectTransform positions, or Editor-window pixels, and do not apply an extra Y-axis flip. Keep the screenshot resolution and Game View state with the coordinate evidence.
50
+
51
+ ## Dynamic-Code Proof Boundary
52
+
53
+ The pinned dynamic-code skill describes a generic Editor execution mechanism and compilation/error reporting in [`uloop-execute-dynamic-code/SKILL.md`](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/.agents/skills/uloop-execute-dynamic-code/SKILL.md#L22-L56). A direct property assignment or callback invocation can prove that the submitted code completed and that the inspected state changed. By itself it does not prove raycast blockers, hover and press transitions, drag thresholds, focus movement, cancellation, pointer capture, or the player's real input path.
54
+
55
+ ## Opinionated Guidance
56
+
57
+ - Keep command outputs as separate evidence until the verification contract ties them to one claim.
58
+ - Prefer the stack's input route for behavior verification. Use direct code for inspection or bounded setup, and reinspect after entering Play Mode when runtime-created or persistent objects matter.
59
+
60
+ ## Platform-Specific Guidance
61
+
62
+ - For uGUI, confirm the Canvas, Graphic Raycaster, EventSystem, active input module, handler, and current selection before simulation.
63
+ - For UI Toolkit, record the runtime Panel and focus owner. For NGUI, record its collider or raycast configuration and legacy-input delegates.
64
+ - In mixed projects, label each action with the input and hierarchy system it targets.
65
+
66
+ ## Unsupported Absolutes
67
+
68
+ No single command result proves end-to-end interaction: a screenshot does not prove dispatch; finding a component does not enumerate its non-Transform descendants; direct code does not prove the player's input path or that serialized changes were saved. Tool availability also does not prove that a project's packages and configuration meet its prerequisites.
69
+
70
+ ## Verification Contract
71
+
72
+ For a complete UI loop, retain launch/version evidence, clean compile output, relevant logs, pre-action hierarchy, pre-action rendering screenshot, exact `SimX`/`SimY` or input parameters, the stack-specific input route, post-action screenshot, post-action logs, focus or selected-state evidence, and save confirmation for serialized edits. Repeat the critical interaction after a fresh Play Mode entry when persistence or initialization is part of the claim.
73
+
74
+ ## Source, License, And Attribution
75
+
76
+ - Adapted source: [hatayama/unity-cli-loop README at `61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0`](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/README.md)
77
+ - Source license: [MIT](https://github.com/hatayama/unity-cli-loop/blob/61a0fe6d7da0aa9d0bcbc6d95944dd069c483ff0/LICENSE.md)
78
+ - Reuse form: independently authored Game UI verification workflow based on the pinned command documentation and implementation paths; no upstream command output or project asset is reproduced.
79
+ - Review boundary: source inspection only; no live Unity project was run for this page.
80
+
81
+ ## IA Navigation
82
+
83
+ Parent: [Game UI](../index.md).
84
+ Next: [Unity Repository Map](repository-map.md).