@noego/wood 0.4.9 → 0.5.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 (493) hide show
  1. package/README.md +118 -42
  2. package/bin/axe.js +313 -98
  3. package/dist/{loader/__fixtures__/layouts/app.load.cjs → automation/actions.cjs} +3 -13
  4. package/dist/automation/actions.cjs.map +1 -0
  5. package/dist/automation/actions.d.cts +57 -0
  6. package/dist/automation/actions.d.ts +57 -0
  7. package/dist/automation/actions.js +1 -0
  8. package/dist/automation/actions.js.map +1 -0
  9. package/dist/automation/actions_executor.cjs +101 -0
  10. package/dist/automation/actions_executor.cjs.map +1 -0
  11. package/dist/automation/actions_executor.d.cts +16 -0
  12. package/dist/automation/actions_executor.d.ts +16 -0
  13. package/dist/automation/actions_executor.js +76 -0
  14. package/dist/automation/actions_executor.js.map +1 -0
  15. package/dist/automation/connection.cjs +86 -0
  16. package/dist/automation/connection.cjs.map +1 -0
  17. package/dist/automation/connection.d.cts +18 -0
  18. package/dist/automation/connection.d.ts +18 -0
  19. package/dist/automation/connection.js +51 -0
  20. package/dist/automation/connection.js.map +1 -0
  21. package/dist/{middleware/__fixtures__/middleware/sequence.cjs → automation/errors.cjs} +25 -22
  22. package/dist/automation/errors.cjs.map +1 -0
  23. package/dist/automation/errors.d.cts +31 -0
  24. package/dist/automation/errors.d.ts +31 -0
  25. package/dist/automation/errors.js +24 -0
  26. package/dist/automation/errors.js.map +1 -0
  27. package/dist/automation/index.cjs +49 -0
  28. package/dist/automation/index.cjs.map +1 -0
  29. package/dist/automation/index.d.cts +16 -0
  30. package/dist/automation/index.d.ts +16 -0
  31. package/dist/automation/index.js +15 -0
  32. package/dist/automation/index.js.map +1 -0
  33. package/dist/automation/introspection_reader.cjs +75 -0
  34. package/dist/automation/introspection_reader.cjs.map +1 -0
  35. package/dist/automation/introspection_reader.d.cts +20 -0
  36. package/dist/automation/introspection_reader.d.ts +20 -0
  37. package/dist/automation/introspection_reader.js +48 -0
  38. package/dist/automation/introspection_reader.js.map +1 -0
  39. package/dist/automation/locator.cjs +102 -0
  40. package/dist/automation/locator.cjs.map +1 -0
  41. package/dist/automation/locator.d.cts +51 -0
  42. package/dist/automation/locator.d.ts +51 -0
  43. package/dist/automation/locator.js +75 -0
  44. package/dist/automation/locator.js.map +1 -0
  45. package/dist/{loader/__fixtures__/views/test/page.load.cjs → automation/observation.cjs} +3 -13
  46. package/dist/automation/observation.cjs.map +1 -0
  47. package/dist/automation/observation.d.cts +44 -0
  48. package/dist/automation/observation.d.ts +44 -0
  49. package/dist/automation/observation.js +1 -0
  50. package/dist/automation/observation.js.map +1 -0
  51. package/dist/{controller/__fixtures__/controllers/test.cjs → automation/receipts.cjs} +3 -15
  52. package/dist/automation/receipts.cjs.map +1 -0
  53. package/dist/automation/receipts.d.cts +27 -0
  54. package/dist/automation/receipts.d.ts +27 -0
  55. package/dist/automation/receipts.js +1 -0
  56. package/dist/automation/receipts.js.map +1 -0
  57. package/dist/automation/scenario.cjs +696 -0
  58. package/dist/automation/scenario.cjs.map +1 -0
  59. package/dist/automation/scenario.d.cts +89 -0
  60. package/dist/automation/scenario.d.ts +89 -0
  61. package/dist/automation/scenario.js +660 -0
  62. package/dist/automation/scenario.js.map +1 -0
  63. package/dist/automation/scrolling.cjs +17 -0
  64. package/dist/automation/scrolling.cjs.map +1 -0
  65. package/dist/automation/scrolling.d.cts +51 -0
  66. package/dist/automation/scrolling.d.ts +51 -0
  67. package/dist/automation/scrolling.js +1 -0
  68. package/dist/automation/scrolling.js.map +1 -0
  69. package/dist/automation/scrolling_executor.cjs +109 -0
  70. package/dist/automation/scrolling_executor.cjs.map +1 -0
  71. package/dist/automation/scrolling_executor.d.cts +13 -0
  72. package/dist/automation/scrolling_executor.d.ts +13 -0
  73. package/dist/automation/scrolling_executor.js +84 -0
  74. package/dist/automation/scrolling_executor.js.map +1 -0
  75. package/dist/automation/target_identity.cjs +17 -0
  76. package/dist/automation/target_identity.cjs.map +1 -0
  77. package/dist/automation/target_identity.d.cts +28 -0
  78. package/dist/automation/target_identity.d.ts +28 -0
  79. package/dist/automation/target_identity.js +1 -0
  80. package/dist/automation/target_identity.js.map +1 -0
  81. package/dist/automation/target_registry.cjs +148 -0
  82. package/dist/automation/target_registry.cjs.map +1 -0
  83. package/dist/automation/target_registry.d.cts +32 -0
  84. package/dist/automation/target_registry.d.ts +32 -0
  85. package/dist/automation/target_registry.js +122 -0
  86. package/dist/automation/target_registry.js.map +1 -0
  87. package/dist/automation/waits.cjs +17 -0
  88. package/dist/automation/waits.cjs.map +1 -0
  89. package/dist/automation/waits.d.cts +44 -0
  90. package/dist/automation/waits.d.ts +44 -0
  91. package/dist/automation/waits.js +1 -0
  92. package/dist/automation/waits.js.map +1 -0
  93. package/dist/automation/waits_executor.cjs +104 -0
  94. package/dist/automation/waits_executor.cjs.map +1 -0
  95. package/dist/automation/waits_executor.d.cts +14 -0
  96. package/dist/automation/waits_executor.d.ts +14 -0
  97. package/dist/automation/waits_executor.js +79 -0
  98. package/dist/automation/waits_executor.js.map +1 -0
  99. package/dist/bridge/backend_bridge.cjs.map +1 -1
  100. package/dist/bridge/backend_bridge.js.map +1 -1
  101. package/dist/client/index.cjs +78 -21
  102. package/dist/client/index.cjs.map +1 -1
  103. package/dist/client/index.d.cts +19 -3
  104. package/dist/client/index.d.ts +19 -3
  105. package/dist/client/index.js +80 -22
  106. package/dist/client/index.js.map +1 -1
  107. package/dist/client/renderer_log_transport.cjs +151 -0
  108. package/dist/client/renderer_log_transport.cjs.map +1 -0
  109. package/dist/client/renderer_log_transport.d.cts +54 -0
  110. package/dist/client/renderer_log_transport.d.ts +54 -0
  111. package/dist/client/renderer_log_transport.js +123 -0
  112. package/dist/client/renderer_log_transport.js.map +1 -0
  113. package/dist/codegen/controller_registration_generator.cjs +13 -2
  114. package/dist/codegen/controller_registration_generator.cjs.map +1 -1
  115. package/dist/codegen/controller_registration_generator.d.cts +12 -1
  116. package/dist/codegen/controller_registration_generator.d.ts +12 -1
  117. package/dist/codegen/controller_registration_generator.js +10 -1
  118. package/dist/codegen/controller_registration_generator.js.map +1 -1
  119. package/dist/codegen/index.d.cts +1 -0
  120. package/dist/codegen/index.d.ts +1 -0
  121. package/dist/codegen/preload_generator.cjs +13 -6
  122. package/dist/codegen/preload_generator.cjs.map +1 -1
  123. package/dist/codegen/preload_generator.d.cts +11 -2
  124. package/dist/codegen/preload_generator.d.ts +11 -2
  125. package/dist/codegen/preload_generator.js +13 -6
  126. package/dist/codegen/preload_generator.js.map +1 -1
  127. package/dist/codegen/renderer_app_generator.cjs +95 -44
  128. package/dist/codegen/renderer_app_generator.cjs.map +1 -1
  129. package/dist/codegen/renderer_app_generator.js +95 -44
  130. package/dist/codegen/renderer_app_generator.js.map +1 -1
  131. package/dist/codegen/type_generator.cjs +1 -0
  132. package/dist/codegen/type_generator.cjs.map +1 -1
  133. package/dist/codegen/type_generator.js +1 -0
  134. package/dist/codegen/type_generator.js.map +1 -1
  135. package/dist/config/config_parser.cjs +95 -4
  136. package/dist/config/config_parser.cjs.map +1 -1
  137. package/dist/config/config_parser.d.cts +10 -2
  138. package/dist/config/config_parser.d.ts +10 -2
  139. package/dist/config/config_parser.js +92 -3
  140. package/dist/config/config_parser.js.map +1 -1
  141. package/dist/config/index.cjs +6 -2
  142. package/dist/config/index.cjs.map +1 -1
  143. package/dist/config/index.d.cts +2 -2
  144. package/dist/config/index.d.ts +2 -2
  145. package/dist/config/index.js +8 -2
  146. package/dist/config/index.js.map +1 -1
  147. package/dist/controller/controller_resolver.cjs +51 -3
  148. package/dist/controller/controller_resolver.cjs.map +1 -1
  149. package/dist/controller/controller_resolver.d.cts +27 -4
  150. package/dist/controller/controller_resolver.d.ts +27 -4
  151. package/dist/controller/controller_resolver.js +48 -2
  152. package/dist/controller/controller_resolver.js.map +1 -1
  153. package/dist/controller/index.cjs +6 -2
  154. package/dist/controller/index.cjs.map +1 -1
  155. package/dist/controller/index.d.cts +1 -1
  156. package/dist/controller/index.d.ts +1 -1
  157. package/dist/controller/index.js +4 -2
  158. package/dist/controller/index.js.map +1 -1
  159. package/dist/dev/wood_dev_server.cjs +4 -1
  160. package/dist/dev/wood_dev_server.cjs.map +1 -1
  161. package/dist/dev/wood_dev_server.js +5 -2
  162. package/dist/dev/wood_dev_server.js.map +1 -1
  163. package/dist/dev/yaml_watcher.cjs +1 -1
  164. package/dist/dev/yaml_watcher.cjs.map +1 -1
  165. package/dist/dev/yaml_watcher.d.cts +4 -0
  166. package/dist/dev/yaml_watcher.d.ts +4 -0
  167. package/dist/dev/yaml_watcher.js +1 -1
  168. package/dist/dev/yaml_watcher.js.map +1 -1
  169. package/dist/frontend/frontend_lifecycle.cjs +74 -0
  170. package/dist/frontend/frontend_lifecycle.cjs.map +1 -0
  171. package/dist/frontend/frontend_lifecycle.d.cts +50 -0
  172. package/dist/frontend/frontend_lifecycle.d.ts +50 -0
  173. package/dist/frontend/frontend_lifecycle.js +50 -0
  174. package/dist/frontend/frontend_lifecycle.js.map +1 -0
  175. package/dist/frontend/frontend_page.cjs +122 -0
  176. package/dist/frontend/frontend_page.cjs.map +1 -0
  177. package/dist/frontend/frontend_page.d.cts +62 -0
  178. package/dist/frontend/frontend_page.d.ts +62 -0
  179. package/dist/frontend/frontend_page.js +98 -0
  180. package/dist/frontend/frontend_page.js.map +1 -0
  181. package/dist/frontend/frontend_surface.cjs +249 -0
  182. package/dist/frontend/frontend_surface.cjs.map +1 -0
  183. package/dist/frontend/frontend_surface.d.cts +64 -0
  184. package/dist/frontend/frontend_surface.d.ts +64 -0
  185. package/dist/frontend/frontend_surface.js +224 -0
  186. package/dist/frontend/frontend_surface.js.map +1 -0
  187. package/dist/frontend/index.cjs +52 -0
  188. package/dist/frontend/index.cjs.map +1 -0
  189. package/dist/frontend/index.d.cts +10 -0
  190. package/dist/frontend/index.d.ts +10 -0
  191. package/dist/frontend/index.js +19 -0
  192. package/dist/frontend/index.js.map +1 -0
  193. package/dist/frontend/page_catalog.cjs +135 -0
  194. package/dist/frontend/page_catalog.cjs.map +1 -0
  195. package/dist/frontend/page_catalog.d.cts +56 -0
  196. package/dist/frontend/page_catalog.d.ts +56 -0
  197. package/dist/frontend/page_catalog.js +108 -0
  198. package/dist/frontend/page_catalog.js.map +1 -0
  199. package/dist/frontend/tracked_transport.cjs +55 -0
  200. package/dist/frontend/tracked_transport.cjs.map +1 -0
  201. package/dist/frontend/tracked_transport.d.cts +36 -0
  202. package/dist/frontend/tracked_transport.d.ts +36 -0
  203. package/dist/frontend/tracked_transport.js +31 -0
  204. package/dist/frontend/tracked_transport.js.map +1 -0
  205. package/dist/frontend/work_registry.cjs +153 -0
  206. package/dist/frontend/work_registry.cjs.map +1 -0
  207. package/dist/frontend/work_registry.d.cts +70 -0
  208. package/dist/frontend/work_registry.d.ts +70 -0
  209. package/dist/frontend/work_registry.js +128 -0
  210. package/dist/frontend/work_registry.js.map +1 -0
  211. package/dist/index.cjs +24 -0
  212. package/dist/index.cjs.map +1 -1
  213. package/dist/index.d.cts +11 -7
  214. package/dist/index.d.ts +11 -7
  215. package/dist/index.js +27 -4
  216. package/dist/index.js.map +1 -1
  217. package/dist/main/index.cjs +10 -0
  218. package/dist/main/index.cjs.map +1 -1
  219. package/dist/main/index.d.cts +14 -2
  220. package/dist/main/index.d.ts +14 -2
  221. package/dist/main/index.js +16 -0
  222. package/dist/main/index.js.map +1 -1
  223. package/dist/middleware/middleware_resolver.cjs +22 -1
  224. package/dist/middleware/middleware_resolver.cjs.map +1 -1
  225. package/dist/middleware/middleware_resolver.d.cts +13 -1
  226. package/dist/middleware/middleware_resolver.d.ts +13 -1
  227. package/dist/middleware/middleware_resolver.js +22 -1
  228. package/dist/middleware/middleware_resolver.js.map +1 -1
  229. package/dist/navigation/automation_introspection.cjs +110 -0
  230. package/dist/navigation/automation_introspection.cjs.map +1 -0
  231. package/dist/navigation/automation_introspection.d.cts +60 -0
  232. package/dist/navigation/automation_introspection.d.ts +60 -0
  233. package/dist/navigation/automation_introspection.js +85 -0
  234. package/dist/navigation/automation_introspection.js.map +1 -0
  235. package/dist/navigation/index.cjs +10 -2
  236. package/dist/navigation/index.cjs.map +1 -1
  237. package/dist/navigation/index.d.cts +27 -1
  238. package/dist/navigation/index.d.ts +27 -1
  239. package/dist/navigation/index.js +6 -1
  240. package/dist/navigation/index.js.map +1 -1
  241. package/dist/{middleware/__fixtures__/middleware/auth.cjs → navigation/layout_preservation.cjs} +18 -20
  242. package/dist/navigation/layout_preservation.cjs.map +1 -0
  243. package/dist/navigation/layout_preservation.d.cts +2 -0
  244. package/dist/navigation/layout_preservation.d.ts +2 -0
  245. package/dist/navigation/layout_preservation.js +18 -0
  246. package/dist/navigation/layout_preservation.js.map +1 -0
  247. package/dist/parser/index.cjs +2 -0
  248. package/dist/parser/index.cjs.map +1 -1
  249. package/dist/parser/index.d.cts +1 -1
  250. package/dist/parser/index.d.ts +1 -1
  251. package/dist/parser/index.js +2 -1
  252. package/dist/parser/index.js.map +1 -1
  253. package/dist/parser/operations_parser.cjs +6 -0
  254. package/dist/parser/operations_parser.cjs.map +1 -1
  255. package/dist/parser/operations_parser.d.cts +9 -2
  256. package/dist/parser/operations_parser.d.ts +9 -2
  257. package/dist/parser/operations_parser.js +5 -0
  258. package/dist/parser/operations_parser.js.map +1 -1
  259. package/dist/parser/views_parser.cjs.map +1 -1
  260. package/dist/parser/views_parser.js.map +1 -1
  261. package/dist/router/index.d.cts +1 -0
  262. package/dist/router/index.d.ts +1 -0
  263. package/dist/router/wood_router.cjs +35 -3
  264. package/dist/router/wood_router.cjs.map +1 -1
  265. package/dist/router/wood_router.d.cts +15 -0
  266. package/dist/router/wood_router.d.ts +15 -0
  267. package/dist/router/wood_router.js +36 -4
  268. package/dist/router/wood_router.js.map +1 -1
  269. package/dist/runtime/get_container.cjs +9 -34
  270. package/dist/runtime/get_container.cjs.map +1 -1
  271. package/dist/runtime/get_container.d.cts +24 -4
  272. package/dist/runtime/get_container.d.ts +24 -4
  273. package/dist/runtime/get_container.js +8 -23
  274. package/dist/runtime/get_container.js.map +1 -1
  275. package/dist/runtime/index.cjs +9 -0
  276. package/dist/runtime/index.cjs.map +1 -1
  277. package/dist/runtime/index.d.cts +5 -2
  278. package/dist/runtime/index.d.ts +5 -2
  279. package/dist/runtime/index.js +10 -1
  280. package/dist/runtime/index.js.map +1 -1
  281. package/dist/runtime/renderer_config_extension.cjs +50 -0
  282. package/dist/runtime/renderer_config_extension.cjs.map +1 -0
  283. package/dist/runtime/renderer_config_extension.d.cts +19 -0
  284. package/dist/runtime/renderer_config_extension.d.ts +19 -0
  285. package/dist/runtime/renderer_config_extension.js +24 -0
  286. package/dist/runtime/renderer_config_extension.js.map +1 -0
  287. package/dist/runtime/renderer_log_batch_receiver.cjs +73 -0
  288. package/dist/runtime/renderer_log_batch_receiver.cjs.map +1 -0
  289. package/dist/runtime/renderer_log_batch_receiver.d.cts +29 -0
  290. package/dist/runtime/renderer_log_batch_receiver.d.ts +29 -0
  291. package/dist/runtime/renderer_log_batch_receiver.js +48 -0
  292. package/dist/runtime/renderer_log_batch_receiver.js.map +1 -0
  293. package/dist/runtime/renderer_trace_batch_receiver_registry.d.cts +1 -1
  294. package/dist/runtime/renderer_trace_batch_receiver_registry.d.ts +1 -1
  295. package/dist/runtime/runtime.cjs +14 -0
  296. package/dist/runtime/runtime.cjs.map +1 -1
  297. package/dist/runtime/runtime.d.cts +2 -1
  298. package/dist/runtime/runtime.d.ts +2 -1
  299. package/dist/runtime/runtime.js +14 -0
  300. package/dist/runtime/runtime.js.map +1 -1
  301. package/dist/stick/index.cjs.map +1 -1
  302. package/dist/stick/index.js.map +1 -1
  303. package/dist/testing/automation_assertions.cjs +417 -0
  304. package/dist/testing/automation_assertions.cjs.map +1 -0
  305. package/dist/testing/automation_assertions.d.cts +44 -0
  306. package/dist/testing/automation_assertions.d.ts +44 -0
  307. package/dist/testing/automation_assertions.js +385 -0
  308. package/dist/testing/automation_assertions.js.map +1 -0
  309. package/dist/testing/browser.cjs +130 -57
  310. package/dist/testing/browser.cjs.map +1 -1
  311. package/dist/testing/browser.d.cts +10 -4
  312. package/dist/testing/browser.d.ts +10 -4
  313. package/dist/testing/browser.js +132 -53
  314. package/dist/testing/browser.js.map +1 -1
  315. package/dist/testing/create_controller_harness.cjs +28 -8
  316. package/dist/testing/create_controller_harness.cjs.map +1 -1
  317. package/dist/testing/create_controller_harness.d.cts +18 -2
  318. package/dist/testing/create_controller_harness.d.ts +18 -2
  319. package/dist/testing/create_controller_harness.js +28 -8
  320. package/dist/testing/create_controller_harness.js.map +1 -1
  321. package/dist/testing/create_router_bridge.d.cts +1 -0
  322. package/dist/testing/create_router_bridge.d.ts +1 -0
  323. package/dist/testing/create_test_router.d.cts +1 -0
  324. package/dist/testing/create_test_router.d.ts +1 -0
  325. package/dist/testing/geometry.cjs +109 -0
  326. package/dist/testing/geometry.cjs.map +1 -0
  327. package/dist/testing/geometry.d.cts +45 -0
  328. package/dist/testing/geometry.d.ts +45 -0
  329. package/dist/testing/geometry.js +79 -0
  330. package/dist/testing/geometry.js.map +1 -0
  331. package/dist/testing/index.cjs +62 -2
  332. package/dist/testing/index.cjs.map +1 -1
  333. package/dist/testing/index.d.cts +23 -4
  334. package/dist/testing/index.d.ts +23 -4
  335. package/dist/testing/index.js +50 -2
  336. package/dist/testing/index.js.map +1 -1
  337. package/dist/{controller/__fixtures__/controllers/not_a_class.cjs → testing/test_wood.cjs} +15 -7
  338. package/dist/testing/test_wood.cjs.map +1 -0
  339. package/dist/testing/test_wood.d.cts +16 -0
  340. package/dist/testing/test_wood.d.ts +16 -0
  341. package/dist/testing/test_wood.js +12 -0
  342. package/dist/testing/test_wood.js.map +1 -0
  343. package/dist/testing/test_wood_config.cjs +272 -0
  344. package/dist/testing/test_wood_config.cjs.map +1 -0
  345. package/dist/testing/test_wood_config.d.cts +111 -0
  346. package/dist/testing/test_wood_config.d.ts +111 -0
  347. package/dist/testing/test_wood_config.js +247 -0
  348. package/dist/testing/test_wood_config.js.map +1 -0
  349. package/dist/testing/wood_config_source.cjs +146 -0
  350. package/dist/testing/wood_config_source.cjs.map +1 -0
  351. package/dist/testing/wood_config_source.d.cts +36 -0
  352. package/dist/testing/wood_config_source.d.ts +36 -0
  353. package/dist/testing/wood_config_source.js +112 -0
  354. package/dist/testing/wood_config_source.js.map +1 -0
  355. package/dist/testing/wood_env_renderer.cjs +210 -0
  356. package/dist/testing/wood_env_renderer.cjs.map +1 -0
  357. package/dist/testing/wood_env_renderer.d.cts +74 -0
  358. package/dist/testing/wood_env_renderer.d.ts +74 -0
  359. package/dist/testing/wood_env_renderer.js +188 -0
  360. package/dist/testing/wood_env_renderer.js.map +1 -0
  361. package/dist/testing/wood_test_selection.cjs +94 -0
  362. package/dist/testing/wood_test_selection.cjs.map +1 -0
  363. package/dist/testing/wood_test_selection.d.cts +39 -0
  364. package/dist/testing/wood_test_selection.d.ts +39 -0
  365. package/dist/testing/wood_test_selection.js +68 -0
  366. package/dist/testing/wood_test_selection.js.map +1 -0
  367. package/dist/trace-testing/index.d.cts +1 -2
  368. package/dist/trace-testing/index.d.ts +1 -2
  369. package/dist/trace-testing/trace_recorder.cjs +1 -1
  370. package/dist/trace-testing/trace_recorder.cjs.map +1 -1
  371. package/dist/trace-testing/trace_recorder.d.cts +1 -2
  372. package/dist/trace-testing/trace_recorder.d.ts +1 -2
  373. package/dist/trace-testing/trace_recorder.js +1 -1
  374. package/dist/trace-testing/trace_recorder.js.map +1 -1
  375. package/dist/trace-transport/index.d.cts +1 -1
  376. package/dist/trace-transport/index.d.ts +1 -1
  377. package/dist/{trace_hub-Cob54qRx.d.cts → trace_hub-Cpo_nVze.d.cts} +21 -1
  378. package/dist/{trace_hub-Cob54qRx.d.ts → trace_hub-Cpo_nVze.d.ts} +21 -1
  379. package/dist/tracing/index.cjs +9 -2
  380. package/dist/tracing/index.cjs.map +1 -1
  381. package/dist/tracing/index.d.cts +3 -2
  382. package/dist/tracing/index.d.ts +3 -2
  383. package/dist/tracing/index.js +7 -1
  384. package/dist/tracing/index.js.map +1 -1
  385. package/dist/tracing/renderer_trace_batch_host.d.cts +1 -1
  386. package/dist/tracing/renderer_trace_batch_host.d.ts +1 -1
  387. package/dist/tracing/renderer_trace_batch_transport.cjs +48 -6
  388. package/dist/tracing/renderer_trace_batch_transport.cjs.map +1 -1
  389. package/dist/tracing/renderer_trace_batch_transport.d.cts +17 -1
  390. package/dist/tracing/renderer_trace_batch_transport.d.ts +17 -1
  391. package/dist/tracing/renderer_trace_batch_transport.js +48 -6
  392. package/dist/tracing/renderer_trace_batch_transport.js.map +1 -1
  393. package/dist/tracing/trace_batch_adapter.cjs +110 -0
  394. package/dist/tracing/trace_batch_adapter.cjs.map +1 -0
  395. package/dist/tracing/trace_batch_adapter.d.cts +36 -0
  396. package/dist/tracing/trace_batch_adapter.d.ts +36 -0
  397. package/dist/tracing/trace_batch_adapter.js +86 -0
  398. package/dist/tracing/trace_batch_adapter.js.map +1 -0
  399. package/dist/tracing/trace_commit_writer.d.cts +1 -1
  400. package/dist/tracing/trace_commit_writer.d.ts +1 -1
  401. package/dist/tracing/trace_hub.cjs +87 -20
  402. package/dist/tracing/trace_hub.cjs.map +1 -1
  403. package/dist/tracing/trace_hub.d.cts +1 -1
  404. package/dist/tracing/trace_hub.d.ts +1 -1
  405. package/dist/tracing/trace_hub.js +85 -20
  406. package/dist/tracing/trace_hub.js.map +1 -1
  407. package/dist/tracing/trace_provider.cjs +21 -6
  408. package/dist/tracing/trace_provider.cjs.map +1 -1
  409. package/dist/tracing/trace_provider.d.cts +13 -4
  410. package/dist/tracing/trace_provider.d.ts +13 -4
  411. package/dist/tracing/trace_provider.js +22 -7
  412. package/dist/tracing/trace_provider.js.map +1 -1
  413. package/dist/tracing/types/wood_trace_batch.types.cjs.map +1 -1
  414. package/dist/tracing/types/wood_trace_batch.types.d.cts +15 -1
  415. package/dist/tracing/types/wood_trace_batch.types.d.ts +15 -1
  416. package/dist/tracing/types/wood_trace_sink.types.d.cts +1 -1
  417. package/dist/tracing/types/wood_trace_sink.types.d.ts +1 -1
  418. package/dist/tracing/wood_trace_batch_contract.cjs +2 -0
  419. package/dist/tracing/wood_trace_batch_contract.cjs.map +1 -1
  420. package/dist/tracing/wood_trace_batch_contract.d.cts +1 -1
  421. package/dist/tracing/wood_trace_batch_contract.d.ts +1 -1
  422. package/dist/tracing/wood_trace_batch_contract.js +2 -0
  423. package/dist/tracing/wood_trace_batch_contract.js.map +1 -1
  424. package/dist/transport/build_transport_bridge.cjs +4 -2
  425. package/dist/transport/build_transport_bridge.cjs.map +1 -1
  426. package/dist/transport/build_transport_bridge.d.cts +7 -1
  427. package/dist/transport/build_transport_bridge.d.ts +7 -1
  428. package/dist/transport/build_transport_bridge.js +2 -1
  429. package/dist/transport/build_transport_bridge.js.map +1 -1
  430. package/dist/transport/in_process_router_transport.d.cts +1 -0
  431. package/dist/transport/in_process_router_transport.d.ts +1 -0
  432. package/dist/transport/index.d.cts +1 -0
  433. package/dist/transport/index.d.ts +1 -0
  434. package/dist/types/config.cjs.map +1 -1
  435. package/dist/types/config.d.cts +47 -1
  436. package/dist/types/config.d.ts +47 -1
  437. package/dist/types/context.cjs +12 -0
  438. package/dist/types/context.cjs.map +1 -1
  439. package/dist/types/context.d.cts +27 -1
  440. package/dist/types/context.d.ts +27 -1
  441. package/dist/types/context.js +4 -0
  442. package/dist/types/context.js.map +1 -1
  443. package/dist/types/index.d.cts +2 -2
  444. package/dist/types/index.d.ts +2 -2
  445. package/dist/types/operations.cjs.map +1 -1
  446. package/dist/types/operations.d.cts +2 -0
  447. package/dist/types/operations.d.ts +2 -0
  448. package/docs/axe.md +706 -0
  449. package/package.json +19 -5
  450. package/src/components/NavigationShell.scopes.browser.test.ts +363 -0
  451. package/src/components/NavigationShell.svelte +126 -49
  452. package/dist/controller/__fixtures__/controllers/chat.cjs +0 -32
  453. package/dist/controller/__fixtures__/controllers/chat.cjs.map +0 -1
  454. package/dist/controller/__fixtures__/controllers/chat.d.cts +0 -11
  455. package/dist/controller/__fixtures__/controllers/chat.d.ts +0 -11
  456. package/dist/controller/__fixtures__/controllers/chat.js +0 -12
  457. package/dist/controller/__fixtures__/controllers/chat.js.map +0 -1
  458. package/dist/controller/__fixtures__/controllers/not_a_class.cjs.map +0 -1
  459. package/dist/controller/__fixtures__/controllers/not_a_class.d.cts +0 -3
  460. package/dist/controller/__fixtures__/controllers/not_a_class.d.ts +0 -3
  461. package/dist/controller/__fixtures__/controllers/not_a_class.js +0 -5
  462. package/dist/controller/__fixtures__/controllers/not_a_class.js.map +0 -1
  463. package/dist/controller/__fixtures__/controllers/settings.controller.cjs +0 -32
  464. package/dist/controller/__fixtures__/controllers/settings.controller.cjs.map +0 -1
  465. package/dist/controller/__fixtures__/controllers/settings.controller.d.cts +0 -12
  466. package/dist/controller/__fixtures__/controllers/settings.controller.d.ts +0 -12
  467. package/dist/controller/__fixtures__/controllers/settings.controller.js +0 -12
  468. package/dist/controller/__fixtures__/controllers/settings.controller.js.map +0 -1
  469. package/dist/controller/__fixtures__/controllers/test.cjs.map +0 -1
  470. package/dist/controller/__fixtures__/controllers/test.d.cts +0 -7
  471. package/dist/controller/__fixtures__/controllers/test.d.ts +0 -7
  472. package/dist/controller/__fixtures__/controllers/test.js +0 -9
  473. package/dist/controller/__fixtures__/controllers/test.js.map +0 -1
  474. package/dist/loader/__fixtures__/layouts/app.load.cjs.map +0 -1
  475. package/dist/loader/__fixtures__/layouts/app.load.d.cts +0 -5
  476. package/dist/loader/__fixtures__/layouts/app.load.d.ts +0 -5
  477. package/dist/loader/__fixtures__/layouts/app.load.js +0 -7
  478. package/dist/loader/__fixtures__/layouts/app.load.js.map +0 -1
  479. package/dist/loader/__fixtures__/views/test/page.load.cjs.map +0 -1
  480. package/dist/loader/__fixtures__/views/test/page.load.d.cts +0 -6
  481. package/dist/loader/__fixtures__/views/test/page.load.d.ts +0 -6
  482. package/dist/loader/__fixtures__/views/test/page.load.js +0 -7
  483. package/dist/loader/__fixtures__/views/test/page.load.js.map +0 -1
  484. package/dist/middleware/__fixtures__/middleware/auth.cjs.map +0 -1
  485. package/dist/middleware/__fixtures__/middleware/auth.d.cts +0 -6
  486. package/dist/middleware/__fixtures__/middleware/auth.d.ts +0 -6
  487. package/dist/middleware/__fixtures__/middleware/auth.js +0 -19
  488. package/dist/middleware/__fixtures__/middleware/auth.js.map +0 -1
  489. package/dist/middleware/__fixtures__/middleware/sequence.cjs.map +0 -1
  490. package/dist/middleware/__fixtures__/middleware/sequence.d.cts +0 -7
  491. package/dist/middleware/__fixtures__/middleware/sequence.d.ts +0 -7
  492. package/dist/middleware/__fixtures__/middleware/sequence.js +0 -21
  493. package/dist/middleware/__fixtures__/middleware/sequence.js.map +0 -1
package/docs/axe.md ADDED
@@ -0,0 +1,706 @@
1
+ # Axe — Live Wood App Driver
2
+
3
+ `axe` is the live-application driver shipped with `@noego/wood`. It connects to
4
+ an already-running Wood Electron app over Playwright/CDP and lets a developer
5
+ inspect or operate the real renderer.
6
+
7
+ It is not the `axe-core` accessibility scanner.
8
+
9
+ This document has two explicit parts:
10
+
11
+ - **Current CLI** — behavior that exists today.
12
+ - **Target driver platform** — the proposed direction for making Axe useful for
13
+ deterministic full-app testing, including route transitions, window changes,
14
+ nested scrolling, virtualized content, waits, and failure evidence.
15
+
16
+ Do not use a proposed command in automation until it has been implemented and
17
+ appears in the current CLI reference.
18
+
19
+ ## Why Axe exists
20
+
21
+ Wood has several complementary test surfaces:
22
+
23
+ | Surface | Best use |
24
+ | --- | --- |
25
+ | Node/controller tests | Pure state, service, routing, policy, and producer behavior |
26
+ | `@noego/wood/testing` browser harness | Real Svelte, CSS, browser APIs, routes, layouts, geometry, animation, and controlled bridge fixtures without Electron |
27
+ | `@noego/wood/trace-testing` | Ordered runtime-flow assertions across renderer, main, and test processes |
28
+ | `stick` | Rendering a known component/state boundary |
29
+ | `axe` | Inspecting and driving the actual running Electron application |
30
+
31
+ Axe is the authoritative surface when the behavior depends on the live app:
32
+ window ownership, actual preload wiring, current HMR state, real IPC, open
33
+ menus, transcript state, or another condition that cannot be recreated honestly
34
+ in an isolated mount.
35
+
36
+ Axe does not replace the lower test tiers. A live click proving that a screen
37
+ works does not replace producer, controller, or state-machine tests for the
38
+ logic that built the screen.
39
+
40
+ # Current CLI
41
+
42
+ ## Prerequisites
43
+
44
+ Start the app with `wood dev` from the project root:
45
+
46
+ ```bash
47
+ npx wood dev
48
+ ```
49
+
50
+ `wood dev` enables a loopback Electron debugging endpoint and writes connection
51
+ metadata to:
52
+
53
+ ```text
54
+ .wood/dev.json
55
+ ```
56
+
57
+ The metadata includes the project, process ID, debug port, and browser URL.
58
+ Axe reads this file from the current working directory, so run Axe from the same
59
+ project root.
60
+
61
+ Playwright is an optional peer dependency. Install it in the app project before
62
+ using Axe:
63
+
64
+ ```bash
65
+ npm install --save-dev playwright
66
+ ```
67
+
68
+ ## Commands available today
69
+
70
+ ```text
71
+ axe targets [--window <windowId>]
72
+ axe js [--window <windowId>]
73
+ axe click <selector> [--window <windowId>]
74
+ axe type <selector> <text> [--window <windowId>]
75
+ axe screenshot [path] [--window <windowId>]
76
+ ```
77
+
78
+ Every command is currently **one-shot**:
79
+
80
+ 1. read `.wood/dev.json`;
81
+ 2. connect with `chromium.connectOverCDP(...)`;
82
+ 3. discover pages;
83
+ 4. perform one operation;
84
+ 5. close the Playwright browser connection.
85
+
86
+ No target generation, route state, trace cursor, or observation is retained
87
+ between commands.
88
+
89
+ ## `axe targets`
90
+
91
+ Lists pages discovered in every connected browser context:
92
+
93
+ ```bash
94
+ npx axe targets
95
+ ```
96
+
97
+ Output is JSON Lines:
98
+
99
+ ```json
100
+ {"index":0,"windowId":"main","defaultRoute":"chat","title":"Kazibee","url":"http://localhost:5173/"}
101
+ ```
102
+
103
+ Fields:
104
+
105
+ - `index` is the current enumeration index. It is diagnostic, not durable
106
+ identity.
107
+ - `windowId` comes from
108
+ `globalThis.__NOEGO_WOOD_BRIDGE__.__window.current()` when the page has a Wood
109
+ bridge.
110
+ - `defaultRoute` is the **configured default route for the window**. It is not
111
+ the route currently displayed after Wood in-app navigation.
112
+ - `title` and `url` come from the current Playwright page.
113
+
114
+ Pages without a Wood bridge may still appear with `windowId: null`.
115
+
116
+ When an app has more than one window, always pass `--window`. Without it, the
117
+ current implementation chooses the first discovered page, whose ordering is not
118
+ a stable test contract.
119
+
120
+ ## `axe click`
121
+
122
+ Uses a Playwright CSS locator and performs a real actionability-checked click:
123
+
124
+ ```bash
125
+ npx axe click '[data-testid="settings-nav"]' --window main
126
+ ```
127
+
128
+ Playwright waits for the target to become actionable and scrolls it into view
129
+ when necessary. The command does not wait for an app route, document, popup, or
130
+ render-settle postcondition after the click.
131
+
132
+ ## `axe type`
133
+
134
+ Despite the command name, the current implementation calls Playwright
135
+ `locator.fill(...)`:
136
+
137
+ ```bash
138
+ npx axe type '[data-testid="composer-input"]' "hello" --window main
139
+ ```
140
+
141
+ This clears and fills a supported form control. It does **not** emit one keyboard
142
+ character at a time. A future driver must expose `fill` and true keyboard
143
+ `type` as separate actions.
144
+
145
+ ## `axe screenshot`
146
+
147
+ Captures the selected Playwright page:
148
+
149
+ ```bash
150
+ npx axe screenshot artifacts/current.png --window main
151
+ ```
152
+
153
+ When no path is supplied, Axe writes an `axe-screenshot-<timestamp>.png` file in
154
+ the current directory.
155
+
156
+ ## `axe js`
157
+
158
+ Reads a JavaScript function body from stdin and evaluates it as an async
159
+ function in the selected renderer:
160
+
161
+ ```bash
162
+ echo 'return document.title' | npx axe js --window main
163
+ ```
164
+
165
+ Use `return` to emit a JSON result.
166
+
167
+ This is a powerful developer escape hatch. It can inspect or mutate DOM state,
168
+ call bridge operations directly, or bypass the real UI. Therefore:
169
+
170
+ - use it for diagnosis, not release qualification;
171
+ - do not treat `element.click()` as proof that a user click is reachable;
172
+ - do not call backend bridge operations directly when testing a UI workflow;
173
+ - do not expose this surface as product authority;
174
+ - avoid printing secrets or user content into terminal history and logs.
175
+
176
+ ### Window identity is not current route state
177
+
178
+ This returns window identity and configured default route:
179
+
180
+ ```bash
181
+ echo '
182
+ const bridge = globalThis.__NOEGO_WOOD_BRIDGE__;
183
+ return await bridge.__window.current();
184
+ ' | npx axe js --window main
185
+ ```
186
+
187
+ It does not return Wood's active navigation entry.
188
+
189
+ For temporary diagnosis only, current Wood navigation is stored on a global
190
+ symbol by the renderer navigation runtime:
191
+
192
+ ```bash
193
+ echo '
194
+ const navigation = globalThis[Symbol.for("@noego/wood.navigation")];
195
+ return navigation?.getCurrent?.() ?? null;
196
+ ' | npx axe js --window main
197
+ ```
198
+
199
+ This is an internal debug technique, not a stable Axe API. The target platform
200
+ below adds an explicit versioned route-introspection contract.
201
+
202
+ ### Temporary scrolling diagnosis
203
+
204
+ Axe has no typed scroll command today. JavaScript can inspect or set a scroll
205
+ container for diagnosis:
206
+
207
+ ```bash
208
+ echo '
209
+ const element = document.querySelector("[data-testid=transcript-scroll-root]");
210
+ if (!(element instanceof HTMLElement)) throw new Error("scroll root missing");
211
+ const before = {
212
+ top: element.scrollTop,
213
+ height: element.clientHeight,
214
+ scrollHeight: element.scrollHeight
215
+ };
216
+ element.scrollBy({ top: 600, behavior: "instant" });
217
+ await new Promise(resolve => requestAnimationFrame(() => resolve()));
218
+ return {
219
+ before,
220
+ after: {
221
+ top: element.scrollTop,
222
+ height: element.clientHeight,
223
+ scrollHeight: element.scrollHeight
224
+ }
225
+ };
226
+ ' | npx axe js --window main
227
+ ```
228
+
229
+ This directly mutates page state and bypasses real wheel routing. It is useful
230
+ for inspection, not a substitute for a qualified user-like scroll action.
231
+
232
+ ## Current limitations
233
+
234
+ The shipped CLI does not yet provide:
235
+
236
+ - a persistent multi-step connection;
237
+ - deterministic target generations or page-replacement tracking;
238
+ - the actual current Wood route;
239
+ - route, URL, popup, target, trace, or element postcondition waits;
240
+ - semantic locators such as role/name, label, placeholder, or test ID;
241
+ - viewport or named-container scrolling;
242
+ - bounded virtual-list traversal;
243
+ - before/after observations and action receipts;
244
+ - console, page-error, failed-request, and trace evidence;
245
+ - automatic screenshots and diagnostics on failure;
246
+ - a generic multi-window Electron fixture that qualifies Axe itself.
247
+
248
+ These gaps matter because separate commands cannot reliably prove:
249
+
250
+ ```text
251
+ click → route/window transition → rendering settles → expected UI appears
252
+ ```
253
+
254
+ The second command reconnects from scratch and may select a different page,
255
+ miss a fast transition, observe an intermediate render, or lose the failure
256
+ context from the first command.
257
+
258
+ # Target driver platform
259
+
260
+ ## Design decision
261
+
262
+ Move connection, target discovery, actions, waits, scrolling, observations,
263
+ receipts, and evidence out of `bin/axe.js` into typed source. Keep the CLI as a
264
+ thin adapter.
265
+
266
+ Recommended package shape:
267
+
268
+ ```text
269
+ src/automation/
270
+ connection.ts
271
+ target_registry.ts
272
+ target_identity.ts
273
+ locator.ts
274
+ observation.ts
275
+ actions.ts
276
+ waits.ts
277
+ stability.ts
278
+ scrolling.ts
279
+ diagnostics.ts
280
+ evidence.ts
281
+ scenario.ts
282
+ receipts.ts
283
+ errors.ts
284
+ bin/
285
+ axe.js
286
+ ```
287
+
288
+ Proposed public entry point:
289
+
290
+ ```ts
291
+ import { automation } from '@noego/wood/automation';
292
+ ```
293
+
294
+ The same neutral contracts should be usable by:
295
+
296
+ - the Axe CLI;
297
+ - Wood's isolated browser harness;
298
+ - app-specific full-Electron tests;
299
+ - deterministic computer-use adapter conformance tests.
300
+
301
+ Sharing contracts does not share product authority. See
302
+ [Computer Use boundary](#computer-use-boundary).
303
+
304
+ ## Dev/test introspection contract
305
+
306
+ Add a development/test-only, versioned renderer surface for facts Axe cannot
307
+ infer reliably from a page URL:
308
+
309
+ ```ts
310
+ type WoodAutomationSnapshot = {
311
+ version: 1;
312
+ windowId: string;
313
+ currentRoute: {
314
+ page: string;
315
+ params: Record<string, string>;
316
+ query: Record<string, string>;
317
+ } | null;
318
+ rendererReady: boolean;
319
+ pendingWork: {
320
+ bridgeCalls: number;
321
+ renders: number;
322
+ animations: number;
323
+ };
324
+ traceCursor?: string;
325
+ };
326
+ ```
327
+
328
+ Suggested bridge:
329
+
330
+ ```ts
331
+ bridge.__automation.snapshot()
332
+ bridge.__automation.waitForIdle({ timeoutMs })
333
+ bridge.__automation.subscribe(event => ...)
334
+ ```
335
+
336
+ Requirements:
337
+
338
+ - absent from normal production builds;
339
+ - inspection and synchronization only;
340
+ - versioned schemas;
341
+ - no arbitrary privileged operation dispatch;
342
+ - route, render, target, and stability changes traced through Wood where
343
+ possible.
344
+
345
+ ## Deterministic target identity
346
+
347
+ A target needs more than an array index:
348
+
349
+ ```ts
350
+ type WoodLiveTarget = {
351
+ targetId: string;
352
+ windowId: string | null;
353
+ webContentsId?: number;
354
+ pageGeneration: number;
355
+ url: string;
356
+ title: string;
357
+ currentRoute?: string;
358
+ configuredDefaultRoute?: string;
359
+ woodBridgePresent: boolean;
360
+ eligible: boolean;
361
+ };
362
+ ```
363
+
364
+ Rules:
365
+
366
+ - reject non-Wood pages by default;
367
+ - require `windowId` when several eligible targets exist;
368
+ - use CDP target identity plus Wood window identity;
369
+ - replace or increment `pageGeneration` after reload or target replacement;
370
+ - fail when the target changes unexpectedly;
371
+ - adopt a popup or replacement only when the scenario declares that
372
+ transition.
373
+
374
+ ## Semantic locator model
375
+
376
+ ```ts
377
+ type WoodLocator =
378
+ | { kind: 'test_id'; value: string }
379
+ | { kind: 'role'; role: string; name?: string; exact?: boolean }
380
+ | { kind: 'label'; value: string; exact?: boolean }
381
+ | { kind: 'placeholder'; value: string; exact?: boolean }
382
+ | { kind: 'text'; value: string; exact?: boolean }
383
+ | { kind: 'css'; value: string };
384
+ ```
385
+
386
+ Semantic locators should be preferred. CSS remains an escape hatch and should
387
+ be marked as lower stability in receipts.
388
+
389
+ A locator resolves to exactly one actionable target unless the scenario
390
+ explicitly chooses `first`, `last`, or an index. Failure output should include:
391
+
392
+ - number of matches;
393
+ - visibility and enabled state;
394
+ - element bounds;
395
+ - actionability failure;
396
+ - center-point hit-test result;
397
+ - likely covering element where available.
398
+
399
+ ## Canonical actions
400
+
401
+ ```ts
402
+ type WoodAutomationAction =
403
+ | { kind: 'click'; target: WoodLocator }
404
+ | { kind: 'double_click'; target: WoodLocator }
405
+ | { kind: 'fill'; target: WoodLocator; value: string }
406
+ | { kind: 'type'; target: WoodLocator; value: string; delayMs?: number }
407
+ | { kind: 'press'; target?: WoodLocator; keys: string[] }
408
+ | { kind: 'select'; target: WoodLocator; option: string }
409
+ | { kind: 'toggle'; target: WoodLocator; checked: boolean }
410
+ | { kind: 'scroll'; command: WoodScrollCommand }
411
+ | { kind: 'back' }
412
+ | { kind: 'forward' }
413
+ | { kind: 'reload' }
414
+ | { kind: 'wait'; condition: WoodWaitCondition };
415
+ ```
416
+
417
+ Every action returns a structured receipt with target and route before/after,
418
+ duration, actionability, document/target/route changes, diagnostics, and evidence
419
+ references.
420
+
421
+ ## Click-through transition contract
422
+
423
+ A click expected to move the app declares its postcondition. Supported
424
+ transitions should include:
425
+
426
+ - exact Wood route and route values;
427
+ - URL or origin;
428
+ - document generation;
429
+ - window or popup appeared;
430
+ - current window closed;
431
+ - element visible, hidden, attached, or detached;
432
+ - trace event occurred;
433
+ - explicitly no route/target transition.
434
+
435
+ Execution order:
436
+
437
+ 1. capture target, route, document, viewport, and trace cursor;
438
+ 2. resolve one actionable target;
439
+ 3. arm route, target, popup, document, and trace listeners;
440
+ 4. perform the Playwright action;
441
+ 5. reconcile window and page identity;
442
+ 6. wait for the declared postcondition;
443
+ 7. wait for bounded app or visual stability where requested;
444
+ 8. capture after-state and evidence;
445
+ 9. emit one receipt.
446
+
447
+ Listeners must be armed before the action so an immediate route or popup event
448
+ cannot be missed.
449
+
450
+ ## Scrolling model
451
+
452
+ ```ts
453
+ type WoodScrollContainer =
454
+ | { kind: 'viewport' }
455
+ | { kind: 'locator'; target: WoodLocator };
456
+
457
+ type WoodScrollCommand =
458
+ | {
459
+ mode: 'wheel';
460
+ container: WoodScrollContainer;
461
+ deltaX?: number;
462
+ deltaY?: number;
463
+ }
464
+ | {
465
+ mode: 'position';
466
+ container: WoodScrollContainer;
467
+ x?: number;
468
+ y?: number;
469
+ edge?: 'top' | 'bottom' | 'left' | 'right';
470
+ }
471
+ | {
472
+ mode: 'into_view';
473
+ target: WoodLocator;
474
+ block?: 'start' | 'center' | 'end' | 'nearest';
475
+ }
476
+ | {
477
+ mode: 'until';
478
+ container: WoodScrollContainer;
479
+ target: WoodLocator;
480
+ direction: 'up' | 'down' | 'left' | 'right';
481
+ stepPx: number;
482
+ maxSteps: number;
483
+ };
484
+ ```
485
+
486
+ Rules:
487
+
488
+ - `wheel` proves user-like wheel routing;
489
+ - `position` is deterministic direct state setting and is labelled as such;
490
+ - nested containers are explicit unless there is exactly one provable scroll
491
+ owner;
492
+ - every step reports `scrollTop`, `scrollLeft`, client size, scroll size, edge
493
+ state, and whether movement occurred;
494
+ - `until` has a hard step bound and exits on no progress;
495
+ - virtualized scenarios assert both scroll movement and newly materialized item
496
+ identity;
497
+ - smooth scrolling is opt-in and requires a stability barrier;
498
+ - test helpers may iterate, but each underlying action remains observable.
499
+
500
+ ## Waits and stability
501
+
502
+ ```ts
503
+ type WoodWaitCondition =
504
+ | { kind: 'route'; page: string; params?: Record<string, string>; query?: Record<string, string> }
505
+ | { kind: 'url'; value: string; match?: 'exact' | 'glob' | 'regex' }
506
+ | { kind: 'target'; windowId: string; state: 'present' | 'active' | 'closed' }
507
+ | { kind: 'visible' | 'hidden' | 'attached' | 'detached' | 'enabled'; target: WoodLocator }
508
+ | { kind: 'trace'; type: string; source?: string; count?: number }
509
+ | { kind: 'scroll_edge'; container: WoodScrollContainer; edge: 'top' | 'bottom' | 'left' | 'right' }
510
+ | { kind: 'visual_stable'; target?: WoodLocator; frames?: number }
511
+ | { kind: 'app_idle' };
512
+ ```
513
+
514
+ Every wait is bounded and reports its final observed state. Fixed sleeps may be
515
+ an explicit diagnostic operation, but normal scenarios should synchronize on a
516
+ real condition. `networkidle` is not a universal app-idle signal for streaming
517
+ or long-lived connections.
518
+
519
+ ## Persistent scenario mode
520
+
521
+ Proposed CLI:
522
+
523
+ ```bash
524
+ axe run scenario.json
525
+ axe run --stdin
526
+ ```
527
+
528
+ One scenario keeps one CDP connection, target registry, trace cursor, and
529
+ evidence directory.
530
+
531
+ Example:
532
+
533
+ ```json
534
+ {
535
+ "version": 1,
536
+ "target": { "windowId": "main" },
537
+ "evidence": {
538
+ "screenshot": "on-failure",
539
+ "console": true,
540
+ "trace": true
541
+ },
542
+ "steps": [
543
+ {
544
+ "name": "open settings",
545
+ "action": {
546
+ "kind": "click",
547
+ "target": { "kind": "test_id", "value": "settings-nav" }
548
+ },
549
+ "wait": {
550
+ "kind": "route",
551
+ "page": "settings.general"
552
+ }
553
+ },
554
+ {
555
+ "name": "reach integrations",
556
+ "action": {
557
+ "kind": "scroll",
558
+ "command": {
559
+ "mode": "until",
560
+ "container": {
561
+ "kind": "locator",
562
+ "target": { "kind": "test_id", "value": "settings-scroll-root" }
563
+ },
564
+ "target": {
565
+ "kind": "test_id",
566
+ "value": "integrations-section"
567
+ },
568
+ "direction": "down",
569
+ "stepPx": 500,
570
+ "maxSteps": 12
571
+ }
572
+ }
573
+ }
574
+ ]
575
+ }
576
+ ```
577
+
578
+ Scenario output should be JSON Lines, with human-readable rendering built from
579
+ the same receipts.
580
+
581
+ Defaults:
582
+
583
+ - fail fast;
584
+ - explicit target when multiple windows exist;
585
+ - no raw JavaScript;
586
+ - no fixed sleeps;
587
+ - bounded observation waits;
588
+ - never retry an action implicitly;
589
+ - redact typed values;
590
+ - capture screenshot and diagnostics on failure.
591
+
592
+ ## Evidence and diagnostics
593
+
594
+ A failed step should be able to include:
595
+
596
+ - stable target identity and page generation;
597
+ - current route, route parameters, and route query;
598
+ - title and URL;
599
+ - viewport, scale, focus, and document generation;
600
+ - selected scroll-root metrics;
601
+ - locator match/actionability details;
602
+ - recent console errors;
603
+ - page errors and failed requests;
604
+ - trace events since the step cursor;
605
+ - before and after screenshots;
606
+ - elapsed action and wait timing.
607
+
608
+ Evidence paths should be returned as artifacts/receipts rather than mixed into
609
+ unstructured command prose.
610
+
611
+ ## Shared assertion kit
612
+
613
+ The strong assertions currently implemented inside `src/testing/browser.ts`
614
+ should be extracted so mounted browser surfaces and live Axe targets can share
615
+ them where the runtime supports the required capability:
616
+
617
+ - visible and hidden;
618
+ - inside viewport;
619
+ - not clipped;
620
+ - not overlapping;
621
+ - hit testing and `unoccluded`;
622
+ - CDP paint-order `inFrontOf`;
623
+ - CDP painted-coverage `notCovered`;
624
+ - rects, shared edges, shared axes, gaps, and even spacing;
625
+ - animation/geometry stability;
626
+ - screenshot evidence;
627
+ - route, target, scroll, trace, console, and page-error assertions.
628
+
629
+ Chromium/CDP-only assertions must report an unsupported-capability error on
630
+ other engines instead of silently substituting a weaker test.
631
+
632
+ ## Required fixture app
633
+
634
+ Wood should own a small Electron fixture dedicated to the live driver. It must
635
+ include:
636
+
637
+ - at least two Wood windows;
638
+ - internal Wood routes whose URL does not change;
639
+ - full document navigation and reload;
640
+ - immediate and delayed transitions;
641
+ - popup/new-window behavior;
642
+ - viewport scrolling;
643
+ - a named nested scroll container;
644
+ - virtualized content;
645
+ - top, bottom, and no-progress scroll states;
646
+ - semantic and intentionally ambiguous controls;
647
+ - disabled, covered, clipped, and offscreen controls;
648
+ - modal, popover, and stacking-context cases;
649
+ - console error, page error, failed request, and trace cases;
650
+ - target replacement;
651
+ - deterministic screenshot content.
652
+
653
+ ## Qualification tiers
654
+
655
+ 1. **Automation-core unit tests** — schemas, target reconciliation, scroll
656
+ calculations, deadlines, redaction, receipts, and error classes.
657
+ 2. **Wood browser-harness tests** — shared actions, waits, assertions, scrolling,
658
+ traces, and evidence in the fastest real-browser tier.
659
+ 3. **Axe Electron-fixture tests** — CDP attachment, multi-window identity,
660
+ internal/full navigation, popup handling, nested/virtual scrolling,
661
+ diagnostics, and cleanup.
662
+ 4. **App full-Electron scenarios** — a deliberately small set of critical live
663
+ workflows.
664
+ 5. **Computer-use adapter conformance** — shared schemas and deterministic
665
+ fixtures against the dedicated product backend, not the Axe dev session.
666
+
667
+ ## Proposed implementation order
668
+
669
+ 1. Extract the current connection and target code into typed source.
670
+ 2. Make multiple-window selection deterministic.
671
+ 3. Add versioned current-route and renderer-readiness introspection.
672
+ 4. Add persistent `axe run` with click plus explicit route/element waits.
673
+ 5. Add viewport, nested-container, edge, into-view, and bounded virtual
674
+ scrolling.
675
+ 6. Add console, page-error, failed-request, trace, and screenshot evidence.
676
+ 7. Extract shared browser assertions.
677
+ 8. Qualify the generic fixture, then a small set of real app workflows.
678
+
679
+ # Computer Use boundary
680
+
681
+ Axe can provide substantial implementation and testing leverage for a managed
682
+ browser Computer Use backend, but it is not the backend itself.
683
+
684
+ Safe to share:
685
+
686
+ - action, locator, wait, scroll, observation, receipt, and error schemas;
687
+ - Playwright actionability and scrolling implementations;
688
+ - deterministic fixture controls;
689
+ - screenshot, trace, and diagnostic evidence formats;
690
+ - adapter conformance scenarios;
691
+ - bounded CDP implementation knowledge.
692
+
693
+ Must remain separate:
694
+
695
+ | Axe | Product Computer Use |
696
+ | --- | --- |
697
+ | Attaches to a running Wood development app | Launches and owns a dedicated verified browser |
698
+ | Reads `.wood/dev.json` | Receives an authenticated session capability |
699
+ | Developer-local authority | Explicit user-authorized product authority |
700
+ | May retain an explicit debug-JavaScript escape hatch | Never exposes arbitrary JavaScript or raw CDP |
701
+ | May inspect the app's own renderer | Must not target trusted controller/approval surfaces |
702
+ | Produces test evidence | Owns policy, approval, durable ledger, data egress, retention, and independent Stop |
703
+
704
+ Computer Use should import qualified neutral contracts and primitives. It must
705
+ never inherit Axe's development endpoint, raw evaluation surface, target
706
+ selection policy, or security assumptions.