@wazir-dev/cli 1.0.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 (629) hide show
  1. package/AGENTS.md +111 -0
  2. package/CHANGELOG.md +14 -0
  3. package/CONTRIBUTING.md +101 -0
  4. package/LICENSE +21 -0
  5. package/README.md +314 -0
  6. package/assets/composition-engine.mmd +34 -0
  7. package/assets/demo-script.sh +17 -0
  8. package/assets/logo-dark.svg +14 -0
  9. package/assets/logo.svg +14 -0
  10. package/assets/pipeline.mmd +39 -0
  11. package/assets/record-demo.sh +51 -0
  12. package/docs/README.md +51 -0
  13. package/docs/adapters/context-mode.md +60 -0
  14. package/docs/concepts/architecture.md +87 -0
  15. package/docs/concepts/artifact-model.md +60 -0
  16. package/docs/concepts/composition-engine.md +36 -0
  17. package/docs/concepts/indexing-and-recall.md +160 -0
  18. package/docs/concepts/observability.md +41 -0
  19. package/docs/concepts/roles-and-workflows.md +59 -0
  20. package/docs/concepts/terminology-policy.md +27 -0
  21. package/docs/getting-started/01-installation.md +78 -0
  22. package/docs/getting-started/02-first-run.md +102 -0
  23. package/docs/getting-started/03-adding-to-project.md +15 -0
  24. package/docs/getting-started/04-host-setup.md +15 -0
  25. package/docs/guides/ci-integration.md +15 -0
  26. package/docs/guides/creating-skills.md +15 -0
  27. package/docs/guides/expertise-module-authoring.md +15 -0
  28. package/docs/guides/hook-development.md +15 -0
  29. package/docs/guides/memory-and-learnings.md +34 -0
  30. package/docs/guides/multi-host-export.md +15 -0
  31. package/docs/guides/troubleshooting.md +101 -0
  32. package/docs/guides/writing-custom-roles.md +15 -0
  33. package/docs/plans/2026-03-15-cli-pipeline-integration-design.md +592 -0
  34. package/docs/plans/2026-03-15-cli-pipeline-integration-plan.md +598 -0
  35. package/docs/plans/2026-03-15-docs-enforcement-plan.md +238 -0
  36. package/docs/readmes/INDEX.md +99 -0
  37. package/docs/readmes/features/expertise/README.md +171 -0
  38. package/docs/readmes/features/exports/README.md +222 -0
  39. package/docs/readmes/features/hooks/README.md +103 -0
  40. package/docs/readmes/features/hooks/loop-cap-guard.md +133 -0
  41. package/docs/readmes/features/hooks/post-tool-capture.md +121 -0
  42. package/docs/readmes/features/hooks/post-tool-lint.md +130 -0
  43. package/docs/readmes/features/hooks/pre-compact-summary.md +122 -0
  44. package/docs/readmes/features/hooks/pre-tool-capture-route.md +100 -0
  45. package/docs/readmes/features/hooks/protected-path-write-guard.md +128 -0
  46. package/docs/readmes/features/hooks/session-start.md +119 -0
  47. package/docs/readmes/features/hooks/stop-handoff-harvest.md +125 -0
  48. package/docs/readmes/features/roles/README.md +157 -0
  49. package/docs/readmes/features/roles/clarifier.md +152 -0
  50. package/docs/readmes/features/roles/content-author.md +190 -0
  51. package/docs/readmes/features/roles/designer.md +193 -0
  52. package/docs/readmes/features/roles/executor.md +184 -0
  53. package/docs/readmes/features/roles/learner.md +210 -0
  54. package/docs/readmes/features/roles/planner.md +182 -0
  55. package/docs/readmes/features/roles/researcher.md +164 -0
  56. package/docs/readmes/features/roles/reviewer.md +184 -0
  57. package/docs/readmes/features/roles/specifier.md +162 -0
  58. package/docs/readmes/features/roles/verifier.md +215 -0
  59. package/docs/readmes/features/schemas/README.md +178 -0
  60. package/docs/readmes/features/skills/README.md +63 -0
  61. package/docs/readmes/features/skills/brainstorming.md +96 -0
  62. package/docs/readmes/features/skills/debugging.md +148 -0
  63. package/docs/readmes/features/skills/design.md +120 -0
  64. package/docs/readmes/features/skills/prepare-next.md +109 -0
  65. package/docs/readmes/features/skills/run-audit.md +159 -0
  66. package/docs/readmes/features/skills/scan-project.md +109 -0
  67. package/docs/readmes/features/skills/self-audit.md +176 -0
  68. package/docs/readmes/features/skills/tdd.md +137 -0
  69. package/docs/readmes/features/skills/using-skills.md +92 -0
  70. package/docs/readmes/features/skills/verification.md +120 -0
  71. package/docs/readmes/features/skills/writing-plans.md +104 -0
  72. package/docs/readmes/features/tooling/README.md +320 -0
  73. package/docs/readmes/features/workflows/README.md +186 -0
  74. package/docs/readmes/features/workflows/author.md +181 -0
  75. package/docs/readmes/features/workflows/clarify.md +154 -0
  76. package/docs/readmes/features/workflows/design-review.md +171 -0
  77. package/docs/readmes/features/workflows/design.md +169 -0
  78. package/docs/readmes/features/workflows/discover.md +162 -0
  79. package/docs/readmes/features/workflows/execute.md +173 -0
  80. package/docs/readmes/features/workflows/learn.md +167 -0
  81. package/docs/readmes/features/workflows/plan-review.md +165 -0
  82. package/docs/readmes/features/workflows/plan.md +170 -0
  83. package/docs/readmes/features/workflows/prepare-next.md +167 -0
  84. package/docs/readmes/features/workflows/review.md +169 -0
  85. package/docs/readmes/features/workflows/run-audit.md +191 -0
  86. package/docs/readmes/features/workflows/spec-challenge.md +159 -0
  87. package/docs/readmes/features/workflows/specify.md +160 -0
  88. package/docs/readmes/features/workflows/verify.md +177 -0
  89. package/docs/readmes/packages/README.md +50 -0
  90. package/docs/readmes/packages/ajv.md +117 -0
  91. package/docs/readmes/packages/context-mode.md +118 -0
  92. package/docs/readmes/packages/gray-matter.md +116 -0
  93. package/docs/readmes/packages/node-test.md +137 -0
  94. package/docs/readmes/packages/yaml.md +112 -0
  95. package/docs/reference/configuration-reference.md +159 -0
  96. package/docs/reference/expertise-index.md +52 -0
  97. package/docs/reference/git-flow.md +43 -0
  98. package/docs/reference/hooks.md +87 -0
  99. package/docs/reference/host-exports.md +50 -0
  100. package/docs/reference/launch-checklist.md +172 -0
  101. package/docs/reference/marketplace-listings.md +76 -0
  102. package/docs/reference/release-process.md +34 -0
  103. package/docs/reference/roles-reference.md +77 -0
  104. package/docs/reference/skills.md +33 -0
  105. package/docs/reference/templates.md +29 -0
  106. package/docs/reference/tooling-cli.md +94 -0
  107. package/docs/truth-claims.yaml +222 -0
  108. package/expertise/PROGRESS.md +63 -0
  109. package/expertise/README.md +18 -0
  110. package/expertise/antipatterns/PROGRESS.md +56 -0
  111. package/expertise/antipatterns/backend/api-design-antipatterns.md +1271 -0
  112. package/expertise/antipatterns/backend/auth-antipatterns.md +1195 -0
  113. package/expertise/antipatterns/backend/caching-antipatterns.md +622 -0
  114. package/expertise/antipatterns/backend/database-antipatterns.md +1038 -0
  115. package/expertise/antipatterns/backend/index.md +24 -0
  116. package/expertise/antipatterns/backend/microservices-antipatterns.md +850 -0
  117. package/expertise/antipatterns/code/architecture-antipatterns.md +919 -0
  118. package/expertise/antipatterns/code/async-antipatterns.md +622 -0
  119. package/expertise/antipatterns/code/code-smells.md +1186 -0
  120. package/expertise/antipatterns/code/dependency-antipatterns.md +1209 -0
  121. package/expertise/antipatterns/code/error-handling-antipatterns.md +1360 -0
  122. package/expertise/antipatterns/code/index.md +27 -0
  123. package/expertise/antipatterns/code/naming-and-abstraction.md +1118 -0
  124. package/expertise/antipatterns/code/state-management-antipatterns.md +1076 -0
  125. package/expertise/antipatterns/code/testing-antipatterns.md +1053 -0
  126. package/expertise/antipatterns/design/accessibility-antipatterns.md +1136 -0
  127. package/expertise/antipatterns/design/dark-patterns.md +1121 -0
  128. package/expertise/antipatterns/design/index.md +22 -0
  129. package/expertise/antipatterns/design/ui-antipatterns.md +1202 -0
  130. package/expertise/antipatterns/design/ux-antipatterns.md +680 -0
  131. package/expertise/antipatterns/frontend/css-layout-antipatterns.md +691 -0
  132. package/expertise/antipatterns/frontend/flutter-antipatterns.md +1827 -0
  133. package/expertise/antipatterns/frontend/index.md +23 -0
  134. package/expertise/antipatterns/frontend/mobile-antipatterns.md +573 -0
  135. package/expertise/antipatterns/frontend/react-antipatterns.md +1128 -0
  136. package/expertise/antipatterns/frontend/spa-antipatterns.md +1235 -0
  137. package/expertise/antipatterns/index.md +31 -0
  138. package/expertise/antipatterns/performance/index.md +20 -0
  139. package/expertise/antipatterns/performance/performance-antipatterns.md +1013 -0
  140. package/expertise/antipatterns/performance/premature-optimization.md +623 -0
  141. package/expertise/antipatterns/performance/scaling-antipatterns.md +785 -0
  142. package/expertise/antipatterns/process/ai-coding-antipatterns.md +853 -0
  143. package/expertise/antipatterns/process/code-review-antipatterns.md +656 -0
  144. package/expertise/antipatterns/process/deployment-antipatterns.md +920 -0
  145. package/expertise/antipatterns/process/index.md +23 -0
  146. package/expertise/antipatterns/process/technical-debt-antipatterns.md +647 -0
  147. package/expertise/antipatterns/security/index.md +20 -0
  148. package/expertise/antipatterns/security/secrets-antipatterns.md +849 -0
  149. package/expertise/antipatterns/security/security-theater.md +843 -0
  150. package/expertise/antipatterns/security/vulnerability-patterns.md +801 -0
  151. package/expertise/architecture/PROGRESS.md +70 -0
  152. package/expertise/architecture/data/caching-architecture.md +671 -0
  153. package/expertise/architecture/data/data-consistency.md +574 -0
  154. package/expertise/architecture/data/data-modeling.md +536 -0
  155. package/expertise/architecture/data/event-streams-and-queues.md +634 -0
  156. package/expertise/architecture/data/index.md +25 -0
  157. package/expertise/architecture/data/search-architecture.md +663 -0
  158. package/expertise/architecture/data/sql-vs-nosql.md +708 -0
  159. package/expertise/architecture/decisions/architecture-decision-records.md +640 -0
  160. package/expertise/architecture/decisions/build-vs-buy.md +616 -0
  161. package/expertise/architecture/decisions/index.md +23 -0
  162. package/expertise/architecture/decisions/monolith-to-microservices.md +790 -0
  163. package/expertise/architecture/decisions/technology-selection.md +616 -0
  164. package/expertise/architecture/distributed/cap-theorem-and-tradeoffs.md +800 -0
  165. package/expertise/architecture/distributed/circuit-breaker-bulkhead.md +741 -0
  166. package/expertise/architecture/distributed/consensus-and-coordination.md +796 -0
  167. package/expertise/architecture/distributed/distributed-systems-fundamentals.md +564 -0
  168. package/expertise/architecture/distributed/idempotency-and-retry.md +796 -0
  169. package/expertise/architecture/distributed/index.md +25 -0
  170. package/expertise/architecture/distributed/saga-pattern.md +797 -0
  171. package/expertise/architecture/foundations/architectural-thinking.md +460 -0
  172. package/expertise/architecture/foundations/coupling-and-cohesion.md +770 -0
  173. package/expertise/architecture/foundations/design-principles-solid.md +649 -0
  174. package/expertise/architecture/foundations/domain-driven-design.md +719 -0
  175. package/expertise/architecture/foundations/index.md +25 -0
  176. package/expertise/architecture/foundations/separation-of-concerns.md +472 -0
  177. package/expertise/architecture/foundations/twelve-factor-app.md +797 -0
  178. package/expertise/architecture/index.md +34 -0
  179. package/expertise/architecture/integration/api-design-graphql.md +638 -0
  180. package/expertise/architecture/integration/api-design-grpc.md +804 -0
  181. package/expertise/architecture/integration/api-design-rest.md +892 -0
  182. package/expertise/architecture/integration/index.md +25 -0
  183. package/expertise/architecture/integration/third-party-integration.md +795 -0
  184. package/expertise/architecture/integration/webhooks-and-callbacks.md +1152 -0
  185. package/expertise/architecture/integration/websockets-realtime.md +791 -0
  186. package/expertise/architecture/mobile-architecture/index.md +22 -0
  187. package/expertise/architecture/mobile-architecture/mobile-app-architecture.md +780 -0
  188. package/expertise/architecture/mobile-architecture/mobile-backend-for-frontend.md +670 -0
  189. package/expertise/architecture/mobile-architecture/offline-first.md +719 -0
  190. package/expertise/architecture/mobile-architecture/push-and-sync.md +782 -0
  191. package/expertise/architecture/patterns/cqrs-event-sourcing.md +717 -0
  192. package/expertise/architecture/patterns/event-driven.md +797 -0
  193. package/expertise/architecture/patterns/hexagonal-clean-architecture.md +870 -0
  194. package/expertise/architecture/patterns/index.md +27 -0
  195. package/expertise/architecture/patterns/layered-architecture.md +736 -0
  196. package/expertise/architecture/patterns/microservices.md +753 -0
  197. package/expertise/architecture/patterns/modular-monolith.md +692 -0
  198. package/expertise/architecture/patterns/monolith.md +626 -0
  199. package/expertise/architecture/patterns/plugin-architecture.md +735 -0
  200. package/expertise/architecture/patterns/serverless.md +780 -0
  201. package/expertise/architecture/scaling/database-scaling.md +615 -0
  202. package/expertise/architecture/scaling/feature-flags-and-rollouts.md +757 -0
  203. package/expertise/architecture/scaling/horizontal-vs-vertical.md +606 -0
  204. package/expertise/architecture/scaling/index.md +24 -0
  205. package/expertise/architecture/scaling/multi-tenancy.md +800 -0
  206. package/expertise/architecture/scaling/stateless-design.md +787 -0
  207. package/expertise/backend/embedded-firmware.md +625 -0
  208. package/expertise/backend/go.md +853 -0
  209. package/expertise/backend/index.md +24 -0
  210. package/expertise/backend/java-spring.md +448 -0
  211. package/expertise/backend/node-typescript.md +625 -0
  212. package/expertise/backend/python-fastapi.md +724 -0
  213. package/expertise/backend/rust.md +458 -0
  214. package/expertise/backend/solidity.md +711 -0
  215. package/expertise/composition-map.yaml +443 -0
  216. package/expertise/content/foundations/content-modeling.md +395 -0
  217. package/expertise/content/foundations/editorial-standards.md +449 -0
  218. package/expertise/content/foundations/index.md +24 -0
  219. package/expertise/content/foundations/microcopy.md +455 -0
  220. package/expertise/content/foundations/terminology-governance.md +509 -0
  221. package/expertise/content/index.md +34 -0
  222. package/expertise/content/patterns/accessibility-copy.md +518 -0
  223. package/expertise/content/patterns/index.md +24 -0
  224. package/expertise/content/patterns/notification-content.md +433 -0
  225. package/expertise/content/patterns/sample-content.md +486 -0
  226. package/expertise/content/patterns/state-copy.md +439 -0
  227. package/expertise/design/PROGRESS.md +58 -0
  228. package/expertise/design/disciplines/dark-mode-theming.md +577 -0
  229. package/expertise/design/disciplines/design-systems.md +595 -0
  230. package/expertise/design/disciplines/index.md +25 -0
  231. package/expertise/design/disciplines/information-architecture.md +800 -0
  232. package/expertise/design/disciplines/interaction-design.md +788 -0
  233. package/expertise/design/disciplines/responsive-design.md +552 -0
  234. package/expertise/design/disciplines/usability-testing.md +516 -0
  235. package/expertise/design/disciplines/user-research.md +792 -0
  236. package/expertise/design/foundations/accessibility-design.md +796 -0
  237. package/expertise/design/foundations/color-theory.md +797 -0
  238. package/expertise/design/foundations/iconography.md +795 -0
  239. package/expertise/design/foundations/index.md +26 -0
  240. package/expertise/design/foundations/motion-and-animation.md +653 -0
  241. package/expertise/design/foundations/rtl-design.md +585 -0
  242. package/expertise/design/foundations/spacing-and-layout.md +607 -0
  243. package/expertise/design/foundations/typography.md +800 -0
  244. package/expertise/design/foundations/visual-hierarchy.md +761 -0
  245. package/expertise/design/index.md +32 -0
  246. package/expertise/design/patterns/authentication-flows.md +474 -0
  247. package/expertise/design/patterns/content-consumption.md +789 -0
  248. package/expertise/design/patterns/data-display.md +618 -0
  249. package/expertise/design/patterns/e-commerce.md +1494 -0
  250. package/expertise/design/patterns/feedback-and-states.md +642 -0
  251. package/expertise/design/patterns/forms-and-input.md +819 -0
  252. package/expertise/design/patterns/gamification.md +801 -0
  253. package/expertise/design/patterns/index.md +31 -0
  254. package/expertise/design/patterns/microinteractions.md +449 -0
  255. package/expertise/design/patterns/navigation.md +800 -0
  256. package/expertise/design/patterns/notifications.md +705 -0
  257. package/expertise/design/patterns/onboarding.md +700 -0
  258. package/expertise/design/patterns/search-and-filter.md +601 -0
  259. package/expertise/design/patterns/settings-and-preferences.md +768 -0
  260. package/expertise/design/patterns/social-and-community.md +748 -0
  261. package/expertise/design/platforms/desktop-native.md +612 -0
  262. package/expertise/design/platforms/index.md +25 -0
  263. package/expertise/design/platforms/mobile-android.md +825 -0
  264. package/expertise/design/platforms/mobile-cross-platform.md +983 -0
  265. package/expertise/design/platforms/mobile-ios.md +699 -0
  266. package/expertise/design/platforms/tablet.md +794 -0
  267. package/expertise/design/platforms/web-dashboard.md +790 -0
  268. package/expertise/design/platforms/web-responsive.md +550 -0
  269. package/expertise/design/psychology/behavioral-nudges.md +449 -0
  270. package/expertise/design/psychology/cognitive-load.md +1191 -0
  271. package/expertise/design/psychology/error-psychology.md +778 -0
  272. package/expertise/design/psychology/index.md +22 -0
  273. package/expertise/design/psychology/persuasive-design.md +736 -0
  274. package/expertise/design/psychology/user-mental-models.md +623 -0
  275. package/expertise/design/tooling/open-pencil.md +266 -0
  276. package/expertise/frontend/angular.md +1073 -0
  277. package/expertise/frontend/desktop-electron.md +546 -0
  278. package/expertise/frontend/flutter.md +782 -0
  279. package/expertise/frontend/index.md +27 -0
  280. package/expertise/frontend/native-android.md +409 -0
  281. package/expertise/frontend/native-ios.md +490 -0
  282. package/expertise/frontend/react-native.md +1160 -0
  283. package/expertise/frontend/react.md +808 -0
  284. package/expertise/frontend/vue.md +1089 -0
  285. package/expertise/humanize/domain-rules-code.md +79 -0
  286. package/expertise/humanize/domain-rules-content.md +67 -0
  287. package/expertise/humanize/domain-rules-technical-docs.md +56 -0
  288. package/expertise/humanize/index.md +35 -0
  289. package/expertise/humanize/self-audit-checklist.md +87 -0
  290. package/expertise/humanize/sentence-patterns.md +218 -0
  291. package/expertise/humanize/vocabulary-blacklist.md +105 -0
  292. package/expertise/i18n/PROGRESS.md +65 -0
  293. package/expertise/i18n/advanced/accessibility-and-i18n.md +28 -0
  294. package/expertise/i18n/advanced/bidirectional-text-algorithm.md +38 -0
  295. package/expertise/i18n/advanced/complex-scripts.md +30 -0
  296. package/expertise/i18n/advanced/performance-and-i18n.md +27 -0
  297. package/expertise/i18n/advanced/testing-i18n.md +28 -0
  298. package/expertise/i18n/content/content-adaptation.md +23 -0
  299. package/expertise/i18n/content/locale-specific-formatting.md +23 -0
  300. package/expertise/i18n/content/machine-translation-integration.md +28 -0
  301. package/expertise/i18n/content/translation-management.md +29 -0
  302. package/expertise/i18n/foundations/date-time-calendars.md +67 -0
  303. package/expertise/i18n/foundations/i18n-architecture.md +272 -0
  304. package/expertise/i18n/foundations/locale-and-language-tags.md +79 -0
  305. package/expertise/i18n/foundations/numbers-currency-units.md +61 -0
  306. package/expertise/i18n/foundations/pluralization-and-gender.md +109 -0
  307. package/expertise/i18n/foundations/string-externalization.md +236 -0
  308. package/expertise/i18n/foundations/text-direction-bidi.md +241 -0
  309. package/expertise/i18n/foundations/unicode-and-encoding.md +86 -0
  310. package/expertise/i18n/index.md +38 -0
  311. package/expertise/i18n/platform/backend-i18n.md +31 -0
  312. package/expertise/i18n/platform/flutter-i18n.md +148 -0
  313. package/expertise/i18n/platform/native-android-i18n.md +36 -0
  314. package/expertise/i18n/platform/native-ios-i18n.md +36 -0
  315. package/expertise/i18n/platform/react-i18n.md +103 -0
  316. package/expertise/i18n/platform/web-css-i18n.md +81 -0
  317. package/expertise/i18n/rtl/arabic-specific.md +175 -0
  318. package/expertise/i18n/rtl/hebrew-specific.md +149 -0
  319. package/expertise/i18n/rtl/rtl-animations-and-transitions.md +111 -0
  320. package/expertise/i18n/rtl/rtl-forms-and-input.md +161 -0
  321. package/expertise/i18n/rtl/rtl-fundamentals.md +211 -0
  322. package/expertise/i18n/rtl/rtl-icons-and-images.md +181 -0
  323. package/expertise/i18n/rtl/rtl-layout-mirroring.md +252 -0
  324. package/expertise/i18n/rtl/rtl-navigation-and-gestures.md +107 -0
  325. package/expertise/i18n/rtl/rtl-testing-and-qa.md +147 -0
  326. package/expertise/i18n/rtl/rtl-typography.md +160 -0
  327. package/expertise/index.md +113 -0
  328. package/expertise/index.yaml +216 -0
  329. package/expertise/infrastructure/cloud-aws.md +597 -0
  330. package/expertise/infrastructure/cloud-gcp.md +599 -0
  331. package/expertise/infrastructure/cybersecurity.md +816 -0
  332. package/expertise/infrastructure/database-mongodb.md +447 -0
  333. package/expertise/infrastructure/database-postgres.md +400 -0
  334. package/expertise/infrastructure/devops-cicd.md +787 -0
  335. package/expertise/infrastructure/index.md +27 -0
  336. package/expertise/performance/PROGRESS.md +50 -0
  337. package/expertise/performance/backend/api-latency.md +1204 -0
  338. package/expertise/performance/backend/background-jobs.md +506 -0
  339. package/expertise/performance/backend/connection-pooling.md +1209 -0
  340. package/expertise/performance/backend/database-query-optimization.md +515 -0
  341. package/expertise/performance/backend/index.md +23 -0
  342. package/expertise/performance/backend/rate-limiting-and-throttling.md +971 -0
  343. package/expertise/performance/foundations/algorithmic-complexity.md +954 -0
  344. package/expertise/performance/foundations/caching-strategies.md +489 -0
  345. package/expertise/performance/foundations/concurrency-and-parallelism.md +847 -0
  346. package/expertise/performance/foundations/index.md +24 -0
  347. package/expertise/performance/foundations/measuring-and-profiling.md +440 -0
  348. package/expertise/performance/foundations/memory-management.md +964 -0
  349. package/expertise/performance/foundations/performance-budgets.md +1314 -0
  350. package/expertise/performance/index.md +31 -0
  351. package/expertise/performance/infrastructure/auto-scaling.md +1059 -0
  352. package/expertise/performance/infrastructure/cdn-and-edge.md +1081 -0
  353. package/expertise/performance/infrastructure/index.md +22 -0
  354. package/expertise/performance/infrastructure/load-balancing.md +1081 -0
  355. package/expertise/performance/infrastructure/observability.md +1079 -0
  356. package/expertise/performance/mobile/index.md +23 -0
  357. package/expertise/performance/mobile/mobile-animations.md +544 -0
  358. package/expertise/performance/mobile/mobile-memory-battery.md +416 -0
  359. package/expertise/performance/mobile/mobile-network.md +452 -0
  360. package/expertise/performance/mobile/mobile-rendering.md +599 -0
  361. package/expertise/performance/mobile/mobile-startup-time.md +505 -0
  362. package/expertise/performance/platform-specific/flutter-performance.md +647 -0
  363. package/expertise/performance/platform-specific/index.md +22 -0
  364. package/expertise/performance/platform-specific/node-performance.md +1307 -0
  365. package/expertise/performance/platform-specific/postgres-performance.md +1366 -0
  366. package/expertise/performance/platform-specific/react-performance.md +1403 -0
  367. package/expertise/performance/web/bundle-optimization.md +1239 -0
  368. package/expertise/performance/web/image-and-media.md +636 -0
  369. package/expertise/performance/web/index.md +24 -0
  370. package/expertise/performance/web/network-optimization.md +1133 -0
  371. package/expertise/performance/web/rendering-performance.md +1098 -0
  372. package/expertise/performance/web/ssr-and-hydration.md +918 -0
  373. package/expertise/performance/web/web-vitals.md +1374 -0
  374. package/expertise/quality/accessibility.md +985 -0
  375. package/expertise/quality/evidence-based-verification.md +499 -0
  376. package/expertise/quality/index.md +24 -0
  377. package/expertise/quality/ml-model-audit.md +614 -0
  378. package/expertise/quality/performance.md +600 -0
  379. package/expertise/quality/testing-api.md +891 -0
  380. package/expertise/quality/testing-mobile.md +496 -0
  381. package/expertise/quality/testing-web.md +849 -0
  382. package/expertise/security/PROGRESS.md +54 -0
  383. package/expertise/security/agentic-identity.md +540 -0
  384. package/expertise/security/compliance-frameworks.md +601 -0
  385. package/expertise/security/data/data-encryption.md +364 -0
  386. package/expertise/security/data/data-privacy-gdpr.md +692 -0
  387. package/expertise/security/data/database-security.md +1171 -0
  388. package/expertise/security/data/index.md +22 -0
  389. package/expertise/security/data/pii-handling.md +531 -0
  390. package/expertise/security/foundations/authentication.md +1041 -0
  391. package/expertise/security/foundations/authorization.md +603 -0
  392. package/expertise/security/foundations/cryptography.md +1001 -0
  393. package/expertise/security/foundations/index.md +25 -0
  394. package/expertise/security/foundations/owasp-top-10.md +1354 -0
  395. package/expertise/security/foundations/secrets-management.md +1217 -0
  396. package/expertise/security/foundations/secure-sdlc.md +700 -0
  397. package/expertise/security/foundations/supply-chain-security.md +698 -0
  398. package/expertise/security/index.md +31 -0
  399. package/expertise/security/infrastructure/cloud-security-aws.md +1296 -0
  400. package/expertise/security/infrastructure/cloud-security-gcp.md +1376 -0
  401. package/expertise/security/infrastructure/container-security.md +721 -0
  402. package/expertise/security/infrastructure/incident-response.md +1295 -0
  403. package/expertise/security/infrastructure/index.md +24 -0
  404. package/expertise/security/infrastructure/logging-and-monitoring.md +1618 -0
  405. package/expertise/security/infrastructure/network-security.md +1337 -0
  406. package/expertise/security/mobile/index.md +23 -0
  407. package/expertise/security/mobile/mobile-android-security.md +1218 -0
  408. package/expertise/security/mobile/mobile-binary-protection.md +1229 -0
  409. package/expertise/security/mobile/mobile-data-storage.md +1265 -0
  410. package/expertise/security/mobile/mobile-ios-security.md +1401 -0
  411. package/expertise/security/mobile/mobile-network-security.md +1520 -0
  412. package/expertise/security/smart-contract-security.md +594 -0
  413. package/expertise/security/testing/index.md +22 -0
  414. package/expertise/security/testing/penetration-testing.md +1258 -0
  415. package/expertise/security/testing/security-code-review.md +1765 -0
  416. package/expertise/security/testing/threat-modeling.md +1074 -0
  417. package/expertise/security/testing/vulnerability-scanning.md +1062 -0
  418. package/expertise/security/web/api-security.md +586 -0
  419. package/expertise/security/web/cors-and-headers.md +433 -0
  420. package/expertise/security/web/csrf.md +562 -0
  421. package/expertise/security/web/file-upload.md +1477 -0
  422. package/expertise/security/web/index.md +25 -0
  423. package/expertise/security/web/injection.md +1375 -0
  424. package/expertise/security/web/session-management.md +1101 -0
  425. package/expertise/security/web/xss.md +1158 -0
  426. package/exports/README.md +17 -0
  427. package/exports/hosts/claude/.claude/agents/clarifier.md +42 -0
  428. package/exports/hosts/claude/.claude/agents/content-author.md +63 -0
  429. package/exports/hosts/claude/.claude/agents/designer.md +55 -0
  430. package/exports/hosts/claude/.claude/agents/executor.md +55 -0
  431. package/exports/hosts/claude/.claude/agents/learner.md +51 -0
  432. package/exports/hosts/claude/.claude/agents/planner.md +53 -0
  433. package/exports/hosts/claude/.claude/agents/researcher.md +43 -0
  434. package/exports/hosts/claude/.claude/agents/reviewer.md +54 -0
  435. package/exports/hosts/claude/.claude/agents/specifier.md +47 -0
  436. package/exports/hosts/claude/.claude/agents/verifier.md +71 -0
  437. package/exports/hosts/claude/.claude/commands/author.md +42 -0
  438. package/exports/hosts/claude/.claude/commands/clarify.md +38 -0
  439. package/exports/hosts/claude/.claude/commands/design-review.md +46 -0
  440. package/exports/hosts/claude/.claude/commands/design.md +44 -0
  441. package/exports/hosts/claude/.claude/commands/discover.md +37 -0
  442. package/exports/hosts/claude/.claude/commands/execute.md +48 -0
  443. package/exports/hosts/claude/.claude/commands/learn.md +38 -0
  444. package/exports/hosts/claude/.claude/commands/plan-review.md +42 -0
  445. package/exports/hosts/claude/.claude/commands/plan.md +39 -0
  446. package/exports/hosts/claude/.claude/commands/prepare-next.md +37 -0
  447. package/exports/hosts/claude/.claude/commands/review.md +40 -0
  448. package/exports/hosts/claude/.claude/commands/run-audit.md +41 -0
  449. package/exports/hosts/claude/.claude/commands/spec-challenge.md +41 -0
  450. package/exports/hosts/claude/.claude/commands/specify.md +38 -0
  451. package/exports/hosts/claude/.claude/commands/verify.md +37 -0
  452. package/exports/hosts/claude/.claude/settings.json +34 -0
  453. package/exports/hosts/claude/CLAUDE.md +19 -0
  454. package/exports/hosts/claude/export.manifest.json +38 -0
  455. package/exports/hosts/claude/host-package.json +67 -0
  456. package/exports/hosts/codex/AGENTS.md +19 -0
  457. package/exports/hosts/codex/export.manifest.json +38 -0
  458. package/exports/hosts/codex/host-package.json +41 -0
  459. package/exports/hosts/cursor/.cursor/hooks.json +16 -0
  460. package/exports/hosts/cursor/.cursor/rules/wazir-core.mdc +19 -0
  461. package/exports/hosts/cursor/export.manifest.json +38 -0
  462. package/exports/hosts/cursor/host-package.json +42 -0
  463. package/exports/hosts/gemini/GEMINI.md +19 -0
  464. package/exports/hosts/gemini/export.manifest.json +38 -0
  465. package/exports/hosts/gemini/host-package.json +41 -0
  466. package/hooks/README.md +18 -0
  467. package/hooks/definitions/loop_cap_guard.yaml +21 -0
  468. package/hooks/definitions/post_tool_capture.yaml +24 -0
  469. package/hooks/definitions/pre_compact_summary.yaml +19 -0
  470. package/hooks/definitions/pre_tool_capture_route.yaml +19 -0
  471. package/hooks/definitions/protected_path_write_guard.yaml +19 -0
  472. package/hooks/definitions/session_start.yaml +19 -0
  473. package/hooks/definitions/stop_handoff_harvest.yaml +20 -0
  474. package/hooks/loop-cap-guard +17 -0
  475. package/hooks/post-tool-lint +36 -0
  476. package/hooks/protected-path-write-guard +17 -0
  477. package/hooks/session-start +41 -0
  478. package/llms-full.txt +2355 -0
  479. package/llms.txt +43 -0
  480. package/package.json +79 -0
  481. package/roles/README.md +20 -0
  482. package/roles/clarifier.md +42 -0
  483. package/roles/content-author.md +63 -0
  484. package/roles/designer.md +55 -0
  485. package/roles/executor.md +55 -0
  486. package/roles/learner.md +51 -0
  487. package/roles/planner.md +53 -0
  488. package/roles/researcher.md +43 -0
  489. package/roles/reviewer.md +54 -0
  490. package/roles/specifier.md +47 -0
  491. package/roles/verifier.md +71 -0
  492. package/schemas/README.md +24 -0
  493. package/schemas/accepted-learning.schema.json +20 -0
  494. package/schemas/author-artifact.schema.json +156 -0
  495. package/schemas/clarification.schema.json +19 -0
  496. package/schemas/design-artifact.schema.json +80 -0
  497. package/schemas/docs-claim.schema.json +18 -0
  498. package/schemas/export-manifest.schema.json +20 -0
  499. package/schemas/hook.schema.json +67 -0
  500. package/schemas/host-export-package.schema.json +18 -0
  501. package/schemas/implementation-plan.schema.json +19 -0
  502. package/schemas/proposed-learning.schema.json +19 -0
  503. package/schemas/research.schema.json +18 -0
  504. package/schemas/review.schema.json +29 -0
  505. package/schemas/run-manifest.schema.json +18 -0
  506. package/schemas/spec-challenge.schema.json +18 -0
  507. package/schemas/spec.schema.json +20 -0
  508. package/schemas/usage.schema.json +102 -0
  509. package/schemas/verification-proof.schema.json +29 -0
  510. package/schemas/wazir-manifest.schema.json +173 -0
  511. package/skills/README.md +40 -0
  512. package/skills/brainstorming/SKILL.md +77 -0
  513. package/skills/debugging/SKILL.md +50 -0
  514. package/skills/design/SKILL.md +61 -0
  515. package/skills/dispatching-parallel-agents/SKILL.md +128 -0
  516. package/skills/executing-plans/SKILL.md +70 -0
  517. package/skills/finishing-a-development-branch/SKILL.md +169 -0
  518. package/skills/humanize/SKILL.md +123 -0
  519. package/skills/init-pipeline/SKILL.md +124 -0
  520. package/skills/prepare-next/SKILL.md +20 -0
  521. package/skills/receiving-code-review/SKILL.md +123 -0
  522. package/skills/requesting-code-review/SKILL.md +105 -0
  523. package/skills/requesting-code-review/code-reviewer.md +108 -0
  524. package/skills/run-audit/SKILL.md +197 -0
  525. package/skills/scan-project/SKILL.md +41 -0
  526. package/skills/self-audit/SKILL.md +153 -0
  527. package/skills/subagent-driven-development/SKILL.md +154 -0
  528. package/skills/subagent-driven-development/code-quality-reviewer-prompt.md +26 -0
  529. package/skills/subagent-driven-development/implementer-prompt.md +102 -0
  530. package/skills/subagent-driven-development/spec-reviewer-prompt.md +61 -0
  531. package/skills/tdd/SKILL.md +23 -0
  532. package/skills/using-git-worktrees/SKILL.md +163 -0
  533. package/skills/using-skills/SKILL.md +95 -0
  534. package/skills/verification/SKILL.md +22 -0
  535. package/skills/wazir/SKILL.md +463 -0
  536. package/skills/writing-plans/SKILL.md +30 -0
  537. package/skills/writing-skills/SKILL.md +157 -0
  538. package/skills/writing-skills/anthropic-best-practices.md +122 -0
  539. package/skills/writing-skills/persuasion-principles.md +50 -0
  540. package/templates/README.md +20 -0
  541. package/templates/artifacts/README.md +10 -0
  542. package/templates/artifacts/accepted-learning.md +19 -0
  543. package/templates/artifacts/accepted-learning.template.json +12 -0
  544. package/templates/artifacts/author.md +74 -0
  545. package/templates/artifacts/author.template.json +19 -0
  546. package/templates/artifacts/clarification.md +21 -0
  547. package/templates/artifacts/clarification.template.json +12 -0
  548. package/templates/artifacts/execute-notes.md +19 -0
  549. package/templates/artifacts/implementation-plan.md +21 -0
  550. package/templates/artifacts/implementation-plan.template.json +11 -0
  551. package/templates/artifacts/learning-proposal.md +19 -0
  552. package/templates/artifacts/next-run-handoff.md +21 -0
  553. package/templates/artifacts/plan-review.md +19 -0
  554. package/templates/artifacts/proposed-learning.template.json +12 -0
  555. package/templates/artifacts/research.md +21 -0
  556. package/templates/artifacts/research.template.json +12 -0
  557. package/templates/artifacts/review-findings.md +19 -0
  558. package/templates/artifacts/review.template.json +11 -0
  559. package/templates/artifacts/run-manifest.template.json +8 -0
  560. package/templates/artifacts/spec-challenge.md +19 -0
  561. package/templates/artifacts/spec-challenge.template.json +11 -0
  562. package/templates/artifacts/spec.md +21 -0
  563. package/templates/artifacts/spec.template.json +12 -0
  564. package/templates/artifacts/verification-proof.md +19 -0
  565. package/templates/artifacts/verification-proof.template.json +11 -0
  566. package/templates/examples/accepted-learning.example.json +14 -0
  567. package/templates/examples/author.example.json +152 -0
  568. package/templates/examples/clarification.example.json +15 -0
  569. package/templates/examples/docs-claim.example.json +8 -0
  570. package/templates/examples/export-manifest.example.json +7 -0
  571. package/templates/examples/host-export-package.example.json +11 -0
  572. package/templates/examples/implementation-plan.example.json +17 -0
  573. package/templates/examples/proposed-learning.example.json +13 -0
  574. package/templates/examples/research.example.json +15 -0
  575. package/templates/examples/research.example.md +6 -0
  576. package/templates/examples/review.example.json +17 -0
  577. package/templates/examples/run-manifest.example.json +9 -0
  578. package/templates/examples/spec-challenge.example.json +14 -0
  579. package/templates/examples/spec.example.json +21 -0
  580. package/templates/examples/verification-proof.example.json +21 -0
  581. package/templates/examples/wazir-manifest.example.yaml +65 -0
  582. package/templates/task-definition-schema.md +99 -0
  583. package/tooling/README.md +20 -0
  584. package/tooling/src/adapters/context-mode.js +50 -0
  585. package/tooling/src/capture/command.js +376 -0
  586. package/tooling/src/capture/store.js +99 -0
  587. package/tooling/src/capture/usage.js +270 -0
  588. package/tooling/src/checks/branches.js +50 -0
  589. package/tooling/src/checks/brand-truth.js +110 -0
  590. package/tooling/src/checks/changelog.js +231 -0
  591. package/tooling/src/checks/command-registry.js +36 -0
  592. package/tooling/src/checks/commits.js +102 -0
  593. package/tooling/src/checks/docs-drift.js +103 -0
  594. package/tooling/src/checks/docs-truth.js +201 -0
  595. package/tooling/src/checks/runtime-surface.js +156 -0
  596. package/tooling/src/cli.js +116 -0
  597. package/tooling/src/command-options.js +56 -0
  598. package/tooling/src/commands/validate.js +320 -0
  599. package/tooling/src/doctor/command.js +91 -0
  600. package/tooling/src/export/command.js +77 -0
  601. package/tooling/src/export/compiler.js +498 -0
  602. package/tooling/src/guards/loop-cap-guard.js +52 -0
  603. package/tooling/src/guards/protected-path-write-guard.js +67 -0
  604. package/tooling/src/index/command.js +152 -0
  605. package/tooling/src/index/storage.js +1061 -0
  606. package/tooling/src/index/summarizers.js +261 -0
  607. package/tooling/src/loaders.js +18 -0
  608. package/tooling/src/project-root.js +22 -0
  609. package/tooling/src/recall/command.js +225 -0
  610. package/tooling/src/schema-validator.js +30 -0
  611. package/tooling/src/state-root.js +40 -0
  612. package/tooling/src/status/command.js +71 -0
  613. package/wazir.manifest.yaml +135 -0
  614. package/workflows/README.md +19 -0
  615. package/workflows/author.md +42 -0
  616. package/workflows/clarify.md +38 -0
  617. package/workflows/design-review.md +46 -0
  618. package/workflows/design.md +44 -0
  619. package/workflows/discover.md +37 -0
  620. package/workflows/execute.md +48 -0
  621. package/workflows/learn.md +38 -0
  622. package/workflows/plan-review.md +42 -0
  623. package/workflows/plan.md +39 -0
  624. package/workflows/prepare-next.md +37 -0
  625. package/workflows/review.md +40 -0
  626. package/workflows/run-audit.md +41 -0
  627. package/workflows/spec-challenge.md +41 -0
  628. package/workflows/specify.md +38 -0
  629. package/workflows/verify.md +37 -0
@@ -0,0 +1,796 @@
1
+ # Accessibility in UI/UX Design -- Foundation Module
2
+
3
+ > Accessibility is a foundational design discipline that ensures digital products are perceivable,
4
+ > operable, understandable, and robust for all users -- including those with permanent, temporary,
5
+ > and situational disabilities. The scope spans visual design, interaction design, content strategy,
6
+ > and cross-platform implementation across web (WCAG 2.2), iOS (Apple HIG), and Android (Material
7
+ > Design 3). Accessibility is not a feature to retrofit; it is a quality that must be designed in
8
+ > from the first wireframe.
9
+
10
+ ---
11
+
12
+ ## 1. Core Principles
13
+
14
+ ### 1.1 WCAG 2.2 POUR Principles
15
+
16
+ WCAG 2.2 (W3C Recommendation, October 2023) organizes all success criteria under four principles.
17
+ Every design decision must satisfy all four.
18
+
19
+ **Perceivable -- Users must be able to perceive the information presented.**
20
+ - All non-text content has text alternatives (SC 1.1.1).
21
+ - Content is adaptable to different presentations without losing meaning (SC 1.3.1-1.3.6).
22
+ - Content is distinguishable -- sufficient contrast, resizable text, no information conveyed by
23
+ color alone (SC 1.4.1-1.4.13).
24
+
25
+ **Operable -- Users must be able to operate the interface.**
26
+ - All functionality is available from a keyboard (SC 2.1.1).
27
+ - Users have enough time to read and use content (SC 2.2.1-2.2.6).
28
+ - Content does not cause seizures or physical reactions (SC 2.3.1-2.3.3).
29
+ - Users can navigate, find content, and determine where they are (SC 2.4.1-2.4.13).
30
+ - Users can operate through input modalities beyond keyboard (SC 2.5.1-2.5.8).
31
+
32
+ **Understandable -- Users must be able to understand the information and UI operation.**
33
+ - Text content is readable and understandable (SC 3.1.1-3.1.6).
34
+ - Pages appear and operate in predictable ways (SC 3.2.1-3.2.6).
35
+ - Users are helped to avoid and correct mistakes (SC 3.3.1-3.3.9).
36
+
37
+ **Robust -- Content must be robust enough for reliable interpretation by assistive technologies.**
38
+ - Content is compatible with current and future user agents, including assistive technologies
39
+ (SC 4.1.2-4.1.3). Note: SC 4.1.1 Parsing was removed in WCAG 2.2 as obsolete.
40
+
41
+ ### 1.2 WCAG 2.2 New Success Criteria
42
+
43
+ WCAG 2.2 added nine new success criteria that directly affect design decisions:
44
+
45
+ | SC Number | Name | Level | Design Impact |
46
+ |-----------|------|-------|---------------|
47
+ | 2.4.11 | Focus Not Obscured (Minimum) | AA | Focused element must not be fully hidden by sticky headers, modals, or overlays |
48
+ | 2.4.12 | Focus Not Obscured (Enhanced) | AAA | Focused element must be fully visible, not partially covered |
49
+ | 2.4.13 | Focus Appearance | AAA | Focus indicator must have minimum 2px solid outline with 3:1 contrast between focused and unfocused states |
50
+ | 2.5.7 | Dragging Movements | AA | Every drag operation must have a single-pointer alternative (tap, click) |
51
+ | 2.5.8 | Target Size (Minimum) | AA | Interactive targets at least 24x24 CSS pixels (with spacing exceptions) |
52
+ | 3.2.6 | Consistent Help | A | Help mechanisms (chat, phone, FAQ) appear in same relative position across pages |
53
+ | 3.3.7 | Redundant Entry | A | Previously entered data auto-populated or selectable in multi-step flows |
54
+ | 3.3.8 | Accessible Authentication (Minimum) | AA | No cognitive function test required for login (memory, transcription, calculation) |
55
+ | 3.3.9 | Accessible Authentication (Enhanced) | AAA | No object recognition or personal content identification for login |
56
+
57
+ ### 1.3 Designing for Screen Readers from the Start
58
+
59
+ Screen reader users navigate interfaces through an auditory document model. Design decisions made
60
+ in wireframes directly determine screen reader experience.
61
+
62
+ **Design-time screen reader considerations:**
63
+ - Define heading hierarchy (h1-h6) in wireframes, not just visual size. 67.5% of screen reader
64
+ users navigate by headings as their primary strategy (WebAIM Survey #10, 2024).
65
+ - Specify landmark regions in wireframes: header/banner, nav, main, complementary, contentinfo.
66
+ - Write alt text intent in design specs -- describe purpose, not appearance. A search icon button
67
+ should read "Search" not "magnifying glass icon."
68
+ - Annotate reading order explicitly when visual layout differs from DOM order (e.g., cards with
69
+ prices visually above titles but logically after them).
70
+ - Design for announcement patterns: specify what screen readers should say on state changes
71
+ (loading, error, success).
72
+ - Label every form field in the design -- floating labels alone are insufficient if they disappear
73
+ on focus.
74
+
75
+ **Screen reader market share (WebAIM Survey #10, 2024, n=1539):**
76
+ - JAWS: 41% primary usage (dominant in North America at 55.5%)
77
+ - NVDA: 38% primary usage (dominant in Europe, Asia, Africa)
78
+ - VoiceOver (iOS): used by 72.4% of mobile respondents
79
+ - TalkBack (Android): used by 27% of mobile respondents
80
+ - 72% of respondents use more than one screen reader
81
+
82
+ ### 1.4 Touch Target Sizes
83
+
84
+ Minimum touch/click target sizes differ by platform but share the principle: large enough to tap
85
+ without error, with sufficient spacing to prevent accidental activation.
86
+
87
+ | Platform | Minimum Size | Recommended Size | Spacing | Source |
88
+ |----------|-------------|-----------------|---------|--------|
89
+ | iOS | 44x44 pt | 44x44 pt | 8pt between targets | Apple HIG |
90
+ | Android | 48x48 dp | 48x48 dp | 8dp between targets | Material Design 3 |
91
+ | Web (WCAG AA) | 24x24 CSS px | 44x44 CSS px | Inline targets exempt if text-spaced | WCAG 2.2 SC 2.5.8 |
92
+ | Web (WCAG AAA) | 44x44 CSS px | 44x44 CSS px | No spacing exceptions | WCAG 2.2 SC 2.5.5 |
93
+
94
+ **Design rules:**
95
+ - Visual size can be smaller than touch target -- a 24x24dp icon can have 48x48dp tap area via
96
+ padding. Design the tap area, not just the visible element.
97
+ - Inline text links are exempt from minimum size requirements under SC 2.5.8 (24x24) as long as
98
+ they are within a sentence or paragraph.
99
+ - Close buttons, dismiss icons, and action buttons on notifications must meet minimum target size --
100
+ these are frequently too small in practice.
101
+ - Navigation items in bottom tab bars must meet platform minimums without exception.
102
+
103
+ ### 1.5 Color Contrast Ratios
104
+
105
+ Color contrast is measured as a luminance ratio between foreground and background colors.
106
+
107
+ | Content Type | Level AA Ratio | Level AAA Ratio | WCAG SC |
108
+ |-------------|---------------|----------------|---------|
109
+ | Normal text (<18pt / <14pt bold) | 4.5:1 | 7:1 | 1.4.3 / 1.4.6 |
110
+ | Large text (>=18pt / >=14pt bold) | 3:1 | 4.5:1 | 1.4.3 / 1.4.6 |
111
+ | UI components & graphical objects | 3:1 | N/A | 1.4.11 |
112
+ | Focus indicators | 3:1 against adjacent colors | N/A | 2.4.13 |
113
+ | Inactive components | Exempt | Exempt | 1.4.3 Note |
114
+ | Logos and decorative text | Exempt | Exempt | 1.4.3 Note |
115
+
116
+ **Design implications:**
117
+ - A 4.499:1 ratio does NOT meet the 4.5:1 threshold -- ratios must not be rounded.
118
+ - Light gray placeholder text (#999 on #FFF = 2.85:1) fails AA. Use #767676 minimum for white
119
+ backgrounds (4.54:1).
120
+ - Brand colors often fail contrast requirements. Establish accessible brand palettes early --
121
+ adjust tints/shades rather than abandoning brand identity.
122
+ - Dark mode requires separate contrast verification. White text on dark gray is not automatically
123
+ sufficient.
124
+ - Charts, graphs, and data visualizations must meet 3:1 non-text contrast (SC 1.4.11) for
125
+ meaningful graphical objects.
126
+
127
+ ### 1.6 Never Rely on Color Alone
128
+
129
+ Color must never be the sole means of conveying information, indicating an action, prompting a
130
+ response, or distinguishing a visual element (SC 1.4.1).
131
+
132
+ **Redundant coding strategies:**
133
+ - Form errors: red color + error icon + descriptive text ("Password must be at least 8 characters")
134
+ - Required fields: red asterisk + "(required)" label text
135
+ - Status indicators: colored dot + text label ("Active", "Paused", "Error")
136
+ - Charts/graphs: color + pattern fills (hatching, dots, stripes) + direct labels
137
+ - Links in text: color + underline (or other non-color distinction like font weight)
138
+ - Success/failure states: color + icon (checkmark/X) + text message
139
+ - Toggle states: color + position + label ("On"/"Off")
140
+
141
+ **Who is affected when color is the sole indicator:**
142
+ - 8% of males and 0.5% of females have color vision deficiency (approximately 300 million people
143
+ worldwide).
144
+ - Monochromacy (total color blindness) affects 1 in 33,000 people.
145
+ - Situational: screen glare, night mode, low-brightness settings, printed in grayscale.
146
+
147
+ ### 1.7 Focus Management and Keyboard Navigation
148
+
149
+ All interactive elements must be reachable and operable with a keyboard alone (SC 2.1.1). Focus
150
+ must be visible and logically ordered.
151
+
152
+ **Design requirements for focus states:**
153
+ - Focus indicators must be visible (SC 2.4.7, Level AA).
154
+ - Focus indicators should have a minimum 2px solid outline with 3:1 contrast ratio between
155
+ focused and unfocused states (SC 2.4.13, Level AAA -- recommended for all projects).
156
+ - Focus order must match visual reading order: left-to-right, top-to-bottom for LTR layouts
157
+ (SC 2.4.3).
158
+ - Focused elements must not be fully obscured by sticky headers, cookie banners, or floating
159
+ action buttons (SC 2.4.11, Level AA).
160
+
161
+ **Design patterns for focus management:**
162
+
163
+ | Pattern | Focus Behavior | Keyboard Interaction |
164
+ |---------|---------------|---------------------|
165
+ | Skip link | First focusable element on page; visually hidden until focused | Enter activates, jumps to main content |
166
+ | Modal dialog | Focus trapped inside modal; Tab/Shift+Tab cycles through focusable elements | Esc closes modal; focus returns to trigger element |
167
+ | Dropdown menu | Focus moves into menu on open; arrow keys navigate items | Esc closes menu; focus returns to trigger |
168
+ | Tab panel | One tab in tab order; arrow keys switch between tabs | Tab moves to panel content; arrow keys switch tabs |
169
+ | Accordion | Each header is focusable; Enter/Space toggles panel | Focus remains on header after toggle |
170
+ | Toast/notification | Not auto-focused (disruptive); announced via aria-live | Dismissible via keyboard if persistent |
171
+ | Autocomplete | Input retains focus; arrow keys navigate suggestions | Enter selects; Esc closes list |
172
+
173
+ **Roving tabindex pattern:**
174
+ For composite widgets (tab bars, toolbars, radio groups), only one child element is in the tab
175
+ order at a time. Arrow keys move focus between children. This prevents tab-key bloat when a
176
+ toolbar has 20 items.
177
+
178
+ ### 1.8 Motion Sensitivity
179
+
180
+ Animations and motion can cause vestibular disorders, motion sickness, nausea, and seizures.
181
+
182
+ **WCAG requirements:**
183
+ - SC 2.3.1 (Level A): No content flashes more than 3 times per second.
184
+ - SC 2.3.3 (Level AAA): Motion animation triggered by interaction can be disabled.
185
+ - SC 2.2.2 (Level A): Moving, blinking, or scrolling content that starts automatically and lasts
186
+ more than 5 seconds must have a pause, stop, or hide mechanism.
187
+
188
+ **Design with prefers-reduced-motion:**
189
+ - Default: design with full animations.
190
+ - Reduced motion: replace movement-based animations (slide, scale, rotate, parallax) with
191
+ non-movement alternatives (opacity fade, crossfade, color transition).
192
+ - Never simply remove all animation when reduced motion is preferred -- transitions that aid
193
+ comprehension (opacity changes, subtle fades) should remain.
194
+ - Auto-playing carousels, parallax scrolling, and background video must respect this preference.
195
+ - Provide an on-page animation toggle control as a fallback for users who have not set OS-level
196
+ motion preferences.
197
+
198
+ **Motion alternatives:**
199
+
200
+ | Full Motion | Reduced Motion Alternative |
201
+ |------------|--------------------------|
202
+ | Slide-in panel | Opacity fade-in |
203
+ | Parallax scrolling | Static background |
204
+ | Scale/zoom transition | Crossfade |
205
+ | Spinning loader | Pulsing opacity or static progress bar |
206
+ | Page transition slide | Instant cut or opacity crossfade |
207
+ | Bouncing attention animation | Subtle color highlight |
208
+
209
+ ### 1.9 Cognitive Accessibility
210
+
211
+ Cognitive accessibility ensures that people with learning disabilities, attention disorders,
212
+ memory impairments, and neurodivergent conditions can understand and operate interfaces.
213
+
214
+ **Plain language principles (W3C Cognitive Accessibility Design Patterns):**
215
+ - Use the most common 1500 words of the language where possible.
216
+ - Write at a reading level appropriate to the audience (aim for grade 7-8 / age 12-14 for
217
+ general consumer products).
218
+ - Use short sentences (15-20 words maximum) and short paragraphs (3-4 sentences).
219
+ - Active voice over passive voice: "Enter your email" not "Your email should be entered."
220
+ - Literal language over figurative: "Save your work" not "Don't let your progress slip away."
221
+
222
+ **Consistent patterns:**
223
+ - Navigation, help, and search must appear in the same location on every page (SC 3.2.3, 3.2.4,
224
+ 3.2.6).
225
+ - Interactive elements that look the same must behave the same throughout the product.
226
+ - Do not change context on focus or on input without warning (SC 3.2.1, 3.2.2).
227
+
228
+ **Error prevention and recovery:**
229
+ - Identify errors clearly with specific, actionable messages: "Email must include @ symbol" not
230
+ "Invalid input" (SC 3.3.1, 3.3.3).
231
+ - Provide error suggestions that tell users how to fix the problem (SC 3.3.3).
232
+ - For legal, financial, or data-submission actions: provide confirmation, review, or undo
233
+ capability (SC 3.3.4, 3.3.6).
234
+ - Do not require users to re-enter information they already provided in the same process
235
+ (SC 3.3.7, new in WCAG 2.2).
236
+
237
+ **Memory and attention support:**
238
+ - Display password requirements before the input field, not only after an error.
239
+ - Show progress indicators in multi-step processes.
240
+ - Allow users to save progress and return later.
241
+ - Avoid time limits; when unavoidable, provide at least 20 seconds warning and a way to extend
242
+ (SC 2.2.1).
243
+
244
+ ### 1.10 Inclusive Design vs Accessibility
245
+
246
+ Inclusive design and accessibility are related but distinct concepts.
247
+
248
+ **Accessibility** focuses on conformance to standards (WCAG, platform guidelines) and ensuring
249
+ people with disabilities can use a product. It often addresses specific technical requirements.
250
+
251
+ **Inclusive design** is a broader methodology that considers the full range of human diversity from
252
+ the start of the design process. Microsoft's Inclusive Design Toolkit defines the Persona Spectrum:
253
+
254
+ | Disability Type | Permanent | Temporary | Situational |
255
+ |----------------|-----------|-----------|-------------|
256
+ | Visual | Blind, low vision | Eye infection, dilated pupils | Bright sunlight glare |
257
+ | Motor | Limb difference, paralysis | Broken arm, RSI | Holding a baby, carrying bags |
258
+ | Auditory | Deaf, hard of hearing | Ear infection | Loud environment (concert, factory) |
259
+ | Cognitive | Learning disability, autism | Concussion, medication side effects | Sleep deprivation, stress, distraction |
260
+ | Speech | Nonverbal | Laryngitis | Heavy accent in foreign context |
261
+
262
+ **Design implications of the Persona Spectrum:**
263
+ - A solution designed for someone with one arm (permanent) also helps someone holding a child
264
+ (situational) -- both benefit from one-handed operation.
265
+ - Captions designed for deaf users help someone in a noisy airport (situational).
266
+ - High contrast designed for low vision helps someone using a phone in bright sunlight.
267
+ - When you design for the extremes of human ability, you create solutions that work better for
268
+ everyone in the middle.
269
+
270
+ **Important caveat:** Temporary and situational limitations create empathy bridges for understanding
271
+ permanent disability, but they do not fully represent the lived experience. Always involve people
272
+ with disabilities in design research and testing.
273
+
274
+ ---
275
+
276
+ ## 2. Do's and Don'ts
277
+
278
+ ### 2.1 Do's (Measurable Criteria)
279
+
280
+ 1. **Do meet 4.5:1 contrast ratio for all body text** (SC 1.4.3). Verify with tools such as
281
+ Stark, WebAIM Contrast Checker, or built-in Figma/Sketch plugins against both light and dark
282
+ mode palettes.
283
+
284
+ 2. **Do design focus indicators with minimum 2px solid outline and 3:1 contrast** (SC 2.4.7,
285
+ 2.4.13). Specify focus styles explicitly in design system tokens -- never rely on browser
286
+ defaults, which vary across browsers and are often invisible on dark backgrounds.
287
+
288
+ 3. **Do size all interactive targets at minimum 44x44pt (iOS) / 48x48dp (Android) / 24x24px web
289
+ AA / 44x44px web AAA** (SC 2.5.5, 2.5.8). Measure from the tappable/clickable area, not the
290
+ visible icon or text bounds.
291
+
292
+ 4. **Do write alt text for every meaningful image in design specs** (SC 1.1.1). Describe the
293
+ purpose, not the appearance. Mark decorative images explicitly as decorative (alt="").
294
+
295
+ 5. **Do annotate heading levels (h1-h6) in every wireframe and mockup** (SC 1.3.1). Ensure one
296
+ h1 per page, no skipped levels, and heading text that describes the section content.
297
+
298
+ 6. **Do provide text labels alongside icons for primary actions** (SC 1.3.3, 1.4.1). Icons alone
299
+ are ambiguous -- a hamburger menu icon means nothing to someone who has never seen one. At
300
+ minimum, provide a tooltip and an aria-label.
301
+
302
+ 7. **Do design error states with color + icon + descriptive text** (SC 1.4.1, 3.3.1, 3.3.3).
303
+ Error messages must identify the field, explain the error, and suggest a fix: "Email address:
304
+ must include @ and a domain (e.g., name@example.com)."
305
+
306
+ 8. **Do define a logical tab order in prototypes** (SC 2.4.3). Tab order must match visual reading
307
+ order. Document the intended focus sequence for all interactive components.
308
+
309
+ 9. **Do support text resizing up to 200% without content loss or horizontal scrolling** (SC 1.4.4).
310
+ Use relative units (rem, em) in design tokens. Test designs at 200% zoom.
311
+
312
+ 10. **Do design for single-pointer alternatives to all drag interactions** (SC 2.5.7). A sortable
313
+ list must have up/down buttons or a reorder menu as an alternative to drag-and-drop.
314
+
315
+ 11. **Do provide visible labels for all form inputs** (SC 1.3.1, 3.3.2). Placeholder text is NOT
316
+ a label -- it disappears on input and fails contrast requirements in most implementations.
317
+
318
+ 12. **Do specify aria-live regions for dynamic content updates** (loading states, notifications,
319
+ real-time data). Design specs should note "announce to screen readers: 'Results loaded, 24
320
+ items found.'"
321
+
322
+ 13. **Do design skip links as the first focusable element on every page** (SC 2.4.1). Visually
323
+ hidden until focused, then visible. "Skip to main content" is the standard text.
324
+
325
+ 14. **Do support both prefers-reduced-motion and an on-page animation toggle** (SC 2.3.3). Document
326
+ reduced-motion alternatives for every animation in the design system.
327
+
328
+ 15. **Do place help mechanisms (chat, phone, FAQ link) in the same relative position on every
329
+ page** (SC 3.2.6). Design the help component as a global layout element, not a per-page
330
+ placement decision.
331
+
332
+ ### 2.2 Don'ts (With Impact)
333
+
334
+ 1. **Don't use color as the sole means of conveying information** (SC 1.4.1). Impacts: 300 million
335
+ people with color vision deficiency, plus anyone viewing in bright sunlight or grayscale mode.
336
+
337
+ 2. **Don't remove or hide focus indicators** -- never apply `outline: none` without a visible
338
+ replacement (SC 2.4.7). Impacts: all keyboard users, power users who tab through forms, users
339
+ with motor disabilities who rely on switch access.
340
+
341
+ 3. **Don't use placeholder text as the only label for form fields** (SC 1.3.1, 3.3.2). Impacts:
342
+ users with cognitive disabilities (placeholder disappears on input), screen reader users
343
+ (placeholder is not reliably announced as a label), users with low vision (placeholder text
344
+ typically has insufficient contrast).
345
+
346
+ 4. **Don't create keyboard traps** -- ensure users can Tab into and out of every component
347
+ (SC 2.1.2). Exception: modal dialogs intentionally trap focus but must provide Esc to exit.
348
+ Impacts: all keyboard-only users, switch access users, screen reader users.
349
+
350
+ 5. **Don't auto-play audio or video with sound** (SC 1.4.2). Impacts: screen reader users (audio
351
+ overlaps with screen reader speech), users in quiet environments, users with auditory
352
+ processing disorders.
353
+
354
+ 6. **Don't use fixed font sizes (px) for text in web designs** (SC 1.4.4). Impacts: users with
355
+ low vision who need to resize text, users of browser zoom, users with dyslexia who prefer
356
+ larger text.
357
+
358
+ 7. **Don't convey information only through spatial position** ("click the button on the right")
359
+ or sensory characteristics ("the red warning") (SC 1.3.3). Impacts: screen reader users who
360
+ have no spatial context, users with color vision deficiency.
361
+
362
+ 8. **Don't use CAPTCHA as the sole authentication method** (SC 3.3.8). Impacts: users with visual
363
+ disabilities (image CAPTCHA), users with cognitive disabilities (puzzle CAPTCHA), users with
364
+ motor disabilities (drag-and-drop CAPTCHA). Provide alternatives: email/SMS codes, passkeys,
365
+ biometrics.
366
+
367
+ 9. **Don't design interactions that require precise pointer gestures (dragging, multi-point
368
+ touch) without alternatives** (SC 2.5.1, 2.5.7). Impacts: users with motor disabilities,
369
+ users with tremors, users using mouth sticks or head pointers.
370
+
371
+ 10. **Don't use flashing or strobing content exceeding 3 flashes per second** (SC 2.3.1). Impacts:
372
+ users with photosensitive epilepsy (can trigger seizures -- this is a safety issue, not just
373
+ a usability concern).
374
+
375
+ 11. **Don't change context automatically on focus or on input** without prior warning (SC 3.2.1,
376
+ 3.2.2). Impacts: screen reader users (unexpected navigation is disorienting), users with
377
+ cognitive disabilities (unexpected changes cause confusion), keyboard users (unintentional
378
+ form submissions).
379
+
380
+ 12. **Don't use vague link text like "click here" or "read more"** (SC 2.4.4). Impacts: screen
381
+ reader users who navigate by links hear a list of "click here, click here, click here."
382
+ Write descriptive link text: "Read the accessibility audit report."
383
+
384
+ 13. **Don't layer content over focused elements** -- sticky headers, cookie banners, and floating
385
+ buttons must not obscure the focused element (SC 2.4.11). Impacts: keyboard users who cannot
386
+ see where their focus is, leading to disorientation and errors.
387
+
388
+ 14. **Don't require users to re-enter information already provided in the same session** (SC 3.3.7).
389
+ Impacts: users with cognitive disabilities (memory burden), users with motor disabilities
390
+ (repeated typing is physically taxing), all users (frustrating UX).
391
+
392
+ 15. **Don't rely solely on hover states to reveal critical information or actions** (SC 1.4.13).
393
+ Impacts: touch screen users (no hover on mobile), keyboard users (hover is mouse-only),
394
+ screen magnification users (hover content may appear outside magnified viewport).
395
+
396
+ ---
397
+
398
+ ## 3. Platform Variations
399
+
400
+ ### 3.1 iOS (Apple Human Interface Guidelines)
401
+
402
+ **VoiceOver:**
403
+ - VoiceOver is the built-in screen reader on all Apple devices. It reads accessibility labels,
404
+ traits, hints, and values.
405
+ - Every interactive element must have an `accessibilityLabel` (what it is), appropriate
406
+ `accessibilityTraits` (button, link, header, image), and optionally an `accessibilityHint`
407
+ (what will happen).
408
+ - VoiceOver navigation gestures: swipe right/left to move between elements, double-tap to
409
+ activate, two-finger swipe up to read all from top.
410
+ - Group related elements using `shouldGroupAccessibilityChildren` to prevent VoiceOver from
411
+ reading each element individually when they form a logical unit (e.g., a card with title,
412
+ subtitle, and action).
413
+
414
+ **Dynamic Type:**
415
+ - iOS Dynamic Type allows users to set preferred text size across all apps. Sizes range from
416
+ xSmall to AX5 (accessibility extra-extra-extra-extra-extra large).
417
+ - Design with `UIFont.preferredFont(forTextStyle:)` text styles, not fixed point sizes.
418
+ - Set `adjustsFontForContentSizeCategory = true` on all text elements.
419
+ - Test designs at the largest Dynamic Type sizes -- layouts must reflow (stacking horizontal
420
+ elements vertically) rather than truncating or overlapping.
421
+ - Critical text must never be clipped. Use scrollable containers if necessary at large sizes.
422
+
423
+ **Reduce Motion:**
424
+ - iOS provides a system-wide "Reduce Motion" toggle in Settings > Accessibility > Motion.
425
+ - When enabled, apps should replace slide transitions with crossfades, disable parallax effects,
426
+ and stop auto-playing animations.
427
+ - Check `UIAccessibility.isReduceMotionEnabled` and observe
428
+ `UIAccessibility.reduceMotionStatusDidChangeNotification`.
429
+
430
+ **Bold Text:**
431
+ - iOS "Bold Text" setting increases font weight system-wide.
432
+ - Use system fonts or fonts that include bold weights to automatically respect this preference.
433
+
434
+ **Design specs for iOS accessibility:**
435
+ - Minimum touch target: 44x44 pt (Apple's explicit requirement).
436
+ - Contrast: follow WCAG 4.5:1 for normal text, 3:1 for large text.
437
+ - Color: never rely on color alone; Apple specifically calls out using shape, text, and position
438
+ alongside color.
439
+ - Haptics: provide haptic feedback for confirmations and errors as a non-visual cue.
440
+
441
+ ### 3.2 Android (Material Design 3)
442
+
443
+ **TalkBack:**
444
+ - TalkBack is the primary screen reader on Android. It reads `contentDescription`, role
445
+ descriptions, and state descriptions.
446
+ - Every informational icon and interactive element needs a `contentDescription`.
447
+ - Decorative images should set `importantForAccessibility="no"`.
448
+ - TalkBack navigation: swipe right/left to move between elements, double-tap to activate,
449
+ swipe up then right for local context menu.
450
+ - Use `android:accessibilityLiveRegion` for dynamic content updates (equivalent to aria-live).
451
+
452
+ **Font Scaling:**
453
+ - Android allows users to scale fonts from the system settings. Text sizes should use `sp`
454
+ (scale-independent pixels), not `dp`, to respect user preference.
455
+ - Test at maximum font scale (typically 200%).
456
+ - Layouts should accommodate larger text without truncation or overlap.
457
+
458
+ **Touch Exploration:**
459
+ - TalkBack's touch exploration mode allows users to drag a finger across the screen to hear
460
+ element descriptions. Elements must have clear boundaries and labels.
461
+ - Touch target minimum: 48x48 dp with 8dp spacing between targets.
462
+ - Visual icon can be smaller (e.g., 24x24dp) as long as the tappable area extends to 48x48dp
463
+ through padding.
464
+
465
+ **Material Design 3 accessibility specifics:**
466
+ - Use Material's built-in accessibility support: M3 components have correct semantics, roles,
467
+ and keyboard support out of the box.
468
+ - Color system: M3 dynamic color must still meet contrast ratios when custom theme colors are
469
+ applied. Test all tonal palette combinations.
470
+ - Elevation and shadows: do not rely solely on shadow/elevation to distinguish layers -- ensure
471
+ border or color contrast between overlapping surfaces.
472
+
473
+ ### 3.3 Web
474
+
475
+ **Screen Reader Modes:**
476
+ - Screen readers operate in different modes on the web. JAWS and NVDA have "Browse mode"
477
+ (virtual cursor, reads the page) and "Focus/Forms mode" (direct keyboard interaction with
478
+ form controls).
479
+ - Mode switching is automatic when focus enters a form field or ARIA widget. Designers must
480
+ ensure that instructions and labels are perceivable in both modes.
481
+ - Custom widgets with `role="application"` override browse mode entirely -- use this role only
482
+ when absolutely necessary, as it removes screen reader navigation shortcuts.
483
+
484
+ **Keyboard Navigation:**
485
+ - Tab key moves between focusable elements (links, buttons, inputs, elements with tabindex="0").
486
+ - Arrow keys navigate within composite widgets (tabs, menus, radio groups, tree views).
487
+ - Enter/Space activate buttons and links. Space scrolls in browse mode -- this causes issues
488
+ when developers use Space as the only activation key for custom buttons.
489
+ - Escape closes modals, dropdowns, and tooltips, returning focus to the trigger element.
490
+ - Skip links must be the first focusable element, visible on focus.
491
+
492
+ **:focus-visible:**
493
+ - The CSS `:focus-visible` pseudo-class shows focus indicators for keyboard navigation but hides
494
+ them for mouse clicks, solving the aesthetic objection to focus rings.
495
+ - Design two focus states: one for `:focus-visible` (keyboard users see it) and one for
496
+ `:focus:not(:focus-visible)` (mouse users do not).
497
+ - Minimum recommendation: 2px solid outline with offset, using a color that provides 3:1
498
+ contrast against the adjacent background.
499
+
500
+ **Semantic HTML priority:**
501
+ - Use native HTML elements before ARIA. A `<button>` has built-in keyboard support, role, and
502
+ click handling. A `<div role="button">` requires manual keyboard event handling, tabindex, and
503
+ ARIA states.
504
+ - Landmark elements (`<header>`, `<nav>`, `<main>`, `<aside>`, `<footer>`) create the page
505
+ outline screen readers use for navigation.
506
+ - Form controls (`<input>`, `<select>`, `<textarea>`) with associated `<label>` elements provide
507
+ accessible names automatically.
508
+
509
+ ### 3.4 Cross-Platform Requirements (Must Be the Same Everywhere)
510
+
511
+ Regardless of platform, these accessibility behaviors must be consistent:
512
+
513
+ - **Contrast ratios**: 4.5:1 for normal text, 3:1 for large text and UI components.
514
+ - **Text alternatives**: every meaningful image has alt text; every icon button has a label.
515
+ - **Keyboard/switch operability**: all functionality reachable without a pointer device.
516
+ - **Focus management**: logical focus order, visible focus indicators, no focus traps.
517
+ - **Error handling**: specific, actionable error messages with suggestions.
518
+ - **Motion respect**: honor OS-level reduced motion preferences.
519
+ - **Text scaling**: support at least 200% text enlargement without content loss.
520
+ - **Color independence**: never convey information through color alone.
521
+ - **Reading order**: programmatic reading order matches logical content order.
522
+ - **Consistent navigation**: same navigation structure across the entire product.
523
+
524
+ ---
525
+
526
+ ## 4. Common Mistakes in AI-Generated Designs
527
+
528
+ AI design tools (Figma AI, Galileo AI, Uizard, v0, and LLM-generated code) consistently produce
529
+ interfaces with accessibility deficiencies. Automated testing catches only about 30% of
530
+ accessibility issues (Deque research). The remaining 70% require design-level and manual review.
531
+
532
+ ### 4.1 Missing or Inadequate Alt Text
533
+
534
+ **The problem:** AI either omits alt text entirely, generates purely visual descriptions ("a blue
535
+ rectangle with rounded corners"), or produces contextually inaccurate descriptions that confuse
536
+ rather than inform.
537
+
538
+ **How to detect:**
539
+ - Automated: axe-core, WAVE, or Lighthouse flag missing alt attributes.
540
+ - Manual: review every image in the design spec. Ask "If I could not see this image, what would
541
+ I need to know?" If the answer is "nothing" -- mark as decorative. If the answer describes a
542
+ purpose -- write that purpose as the alt text.
543
+
544
+ **How to fix:**
545
+ - Write alt text that describes purpose, not appearance: "Sales dashboard showing Q3 revenue
546
+ up 12%" not "bar chart with blue and green bars."
547
+ - Mark decorative images explicitly (alt="" in HTML, isAccessibilityElement = false on iOS).
548
+ - Complex images (charts, diagrams) need both short alt text and a longer text description or
549
+ data table alternative.
550
+
551
+ ### 4.2 Insufficient Color Contrast
552
+
553
+ **The problem:** AI tools frequently generate aesthetically pleasing but low-contrast color
554
+ combinations -- especially light gray text on white backgrounds, pastel palettes, and thin-weight
555
+ fonts on colored backgrounds.
556
+
557
+ **How to detect:**
558
+ - Plugin: Stark (Figma/Sketch) scans entire frames for contrast violations.
559
+ - Automated: Lighthouse, axe-core, WAVE flag contrast failures against WCAG thresholds.
560
+ - Manual: check every text/background combination, including hover states, disabled states,
561
+ error states, and dark mode variants.
562
+
563
+ **How to fix:**
564
+ - Adjust text color to meet 4.5:1 (or 7:1 for AAA).
565
+ - Increase font weight -- a heavier weight at the same color can pass where a lighter weight
566
+ fails (large text threshold: 14pt bold / 18pt regular).
567
+ - Adjust background color rather than text color to preserve brand palette.
568
+ - Verify contrast in all states: default, hover, focus, active, disabled, error, dark mode.
569
+
570
+ ### 4.3 No Keyboard Navigation Support
571
+
572
+ **The problem:** AI-generated interfaces use `<div>` and `<span>` for interactive elements, omit
573
+ tabindex, and provide no keyboard event handlers. Custom components lack focus management.
574
+
575
+ **How to detect:**
576
+ - Manual: unplug your mouse and Tab through the entire interface. Every interactive element must
577
+ be reachable, visually indicated when focused, and activatable with Enter or Space.
578
+ - Automated: axe-core detects some issues (missing roles, missing tabindex) but cannot verify
579
+ keyboard operability of custom widgets.
580
+
581
+ **How to fix:**
582
+ - Replace `<div onclick>` with `<button>` or `<a href>` elements.
583
+ - Add tabindex="0" to custom interactive elements that must be focusable.
584
+ - Implement keyboard event handlers: Enter and Space for activation, Arrow keys for navigation
585
+ within composite widgets, Esc to dismiss.
586
+ - Define visible focus styles for every interactive component.
587
+
588
+ ### 4.4 Focus Traps and Missing Focus Management
589
+
590
+ **The problem:** AI-generated modals, drawers, and popovers do not trap focus (allowing Tab to
591
+ reach background content), do not return focus to the trigger element on close, and do not
592
+ support Esc to dismiss.
593
+
594
+ **How to detect:**
595
+ - Manual: open the modal, Tab through all elements. Focus should cycle within the modal. Press
596
+ Esc -- the modal should close and focus should return to the button that opened it.
597
+ - Check that background content has `inert` attribute or `aria-hidden="true"` when modal is open.
598
+
599
+ **How to fix:**
600
+ - Implement focus trapping: on modal open, move focus to the first focusable element inside the
601
+ modal. On Tab past the last element, cycle to the first. On Shift+Tab past the first, cycle
602
+ to the last.
603
+ - On modal close, restore focus to the trigger element.
604
+ - Apply `inert` attribute to all background content when modal is open (modern browsers support
605
+ this natively).
606
+ - Add Esc key handler to close the modal.
607
+
608
+ ### 4.5 Missing Semantic Structure
609
+
610
+ **The problem:** AI-generated HTML uses `<div>` soup -- no landmarks, no heading hierarchy, no
611
+ list semantics, no form labels. This renders the page meaningless to screen readers.
612
+
613
+ **How to detect:**
614
+ - Browser extension: HeadingsMap shows heading hierarchy. Gaps or wrong levels are immediately
615
+ visible.
616
+ - Screen reader: navigate by landmarks (JAWS: semicolon key; NVDA: D key). If no landmarks
617
+ exist, the page has no structure.
618
+ - Automated: axe-core flags missing landmarks, skipped heading levels, and unlabeled form
619
+ controls.
620
+
621
+ **How to fix:**
622
+ - Add landmark elements: `<header>`, `<nav>`, `<main>`, `<aside>`, `<footer>`.
623
+ - Establish heading hierarchy: one `<h1>` per page, no skipped levels.
624
+ - Use `<ul>`/`<ol>` for lists, `<table>` for tabular data, `<form>` with `<label>` for inputs.
625
+ - Label landmarks when there are multiples of the same type: `<nav aria-label="Primary">` and
626
+ `<nav aria-label="Footer">`.
627
+
628
+ ### 4.6 Missing ARIA States and Properties
629
+
630
+ **The problem:** AI-generated custom widgets (accordions, tabs, menus) lack ARIA roles, states,
631
+ and properties. An accordion built from `<div>` elements without `role="button"`,
632
+ `aria-expanded`, and `aria-controls` is unusable for screen reader users.
633
+
634
+ **How to detect:**
635
+ - Manual: use a screen reader to interact with every custom widget. If the screen reader does
636
+ not announce the widget type (tab, menu, accordion) and its state (expanded, selected,
637
+ checked), ARIA is missing.
638
+ - Automated: axe-core detects missing ARIA roles and properties on some widget patterns.
639
+
640
+ **How to fix:**
641
+ - Follow WAI-ARIA Authoring Practices Guide (APG) patterns for every custom widget.
642
+ - Add required roles: `role="tablist"`, `role="tab"`, `role="tabpanel"` for tabs.
643
+ - Add required states: `aria-expanded="true|false"` for accordions, `aria-selected="true|false"`
644
+ for tabs, `aria-checked="true|false"` for custom checkboxes.
645
+ - Add required properties: `aria-controls`, `aria-labelledby`, `aria-describedby` as needed.
646
+
647
+ ---
648
+
649
+ ## 5. Decision Framework
650
+
651
+ ### 5.1 When AA vs AAA Compliance
652
+
653
+ | Factor | Target AA | Target AAA |
654
+ |--------|----------|-----------|
655
+ | Legal requirement | AA is the legal standard (ADA, EAA, Section 508, EN 301 549) | AAA is not legally required but may be contractually required |
656
+ | User base | General consumer products | Government services, healthcare, education, accessibility-focused products |
657
+ | Budget/timeline | AA is achievable within standard development cycles | AAA adds 15-25% additional design and development effort |
658
+ | Contrast | 4.5:1 normal text, 3:1 large text is achievable with most brand palettes | 7:1 normal text may require brand palette adjustments |
659
+ | Target size | 24x24px is achievable for most designs | 44x44px may require layout changes for dense UIs |
660
+ | Recommended approach | **Always meet AA as a minimum baseline** | Apply AAA selectively: enhanced contrast for body text, enhanced target size for primary actions, focus appearance for all components |
661
+
662
+ **Practical recommendation:** Design to AA as the non-negotiable baseline. Apply AAA criteria
663
+ where the cost is low and the benefit is high -- enhanced contrast (SC 1.4.6), focus appearance
664
+ (SC 2.4.13), and enhanced target size (SC 2.5.5) are the highest-value AAA criteria.
665
+
666
+ ### 5.2 When to Add ARIA vs Rely on Semantic HTML
667
+
668
+ **The first rule of ARIA: if you can use a native HTML element with the semantics and behavior
669
+ you need, do so. No ARIA is better than bad ARIA.**
670
+
671
+ WebAIM's analysis of one million home pages found that pages with ARIA present averaged 41% more
672
+ detected accessibility errors than those without ARIA. This is not because ARIA is bad -- it is
673
+ because ARIA is frequently misused.
674
+
675
+ | Scenario | Use Semantic HTML | Use ARIA |
676
+ |----------|------------------|---------|
677
+ | Button | `<button>` | Only if you cannot use `<button>` (extremely rare) |
678
+ | Link | `<a href="...">` | Only for SPA router links that use `<button>` for navigation |
679
+ | Navigation | `<nav>` | `<div role="navigation">` only if `<nav>` is not available (never on modern web) |
680
+ | Form label | `<label for="id">` | `aria-label` or `aria-labelledby` only when visible label is not possible |
681
+ | Dynamic updates | Not applicable | `aria-live="polite"` or `aria-live="assertive"` for content that changes without user action |
682
+ | Tab interface | No native element | `role="tablist"`, `role="tab"`, `role="tabpanel"` -- ARIA is required |
683
+ | Tree view | No native element | `role="tree"`, `role="treeitem"` -- ARIA is required |
684
+ | Combobox/autocomplete | `<input>` + `<datalist>` for simple cases | `role="combobox"` for complex cases with custom dropdowns |
685
+ | Modal dialog | `<dialog>` (modern) | `role="dialog"` + `aria-modal="true"` if `<dialog>` cannot be used |
686
+ | Expanded/collapsed state | No native attribute | `aria-expanded="true|false"` -- ARIA is required for state |
687
+ | Current page in nav | No native attribute | `aria-current="page"` -- ARIA is required |
688
+
689
+ **Decision heuristic:**
690
+ 1. Can a native HTML element do this? Use it.
691
+ 2. Does the native element need additional state information? Add ARIA state attributes.
692
+ 3. Is there no native element for this pattern? Build a custom widget following WAI-ARIA APG
693
+ patterns with full ARIA roles, states, properties, and keyboard support.
694
+ 4. Are you adding `role` to override a native element's semantics? Stop -- you are probably
695
+ doing it wrong.
696
+
697
+ ### 5.3 Trade-offs: Visual Aesthetics vs Accessibility
698
+
699
+ Accessibility and aesthetics are not inherently in conflict. The perception of conflict typically
700
+ arises from three sources:
701
+
702
+ **1. Focus indicators "look ugly"**
703
+ - Solution: design custom focus indicators that are both visible (2px, 3:1 contrast) and
704
+ aesthetically integrated. Use `:focus-visible` to show focus rings only for keyboard users.
705
+ - Use branded focus colors, offset outlines, or combined outline+box-shadow treatments.
706
+ - This is a solved problem -- Stripe, Linear, Vercel, and other design-forward products have
707
+ accessible, attractive focus indicators.
708
+
709
+ **2. High contrast "limits my palette"**
710
+ - Solution: adjust tints and shades, not hues. Most brand colors can achieve 4.5:1 on white
711
+ with a 10-20% darkness adjustment.
712
+ - Dark mode often makes high contrast easier, not harder -- light text on dark backgrounds
713
+ naturally provides high ratios.
714
+ - Tools: Stark Auto-Contrast, Leonardo (Adobe), Reasonable Colors all generate accessible
715
+ palettes from brand colors.
716
+
717
+ **3. Larger touch targets "waste space"**
718
+ - Solution: touch target size is independent of visual size. An icon can be 24px visually with
719
+ 48px of tappable padding. The spacing also improves visual clarity and reduces cognitive load.
720
+ - Dense data tables can use 24px (AA minimum) for inline controls while keeping primary actions
721
+ at 44px.
722
+
723
+ **The business case for accessibility:**
724
+ - 1.3 billion people (16% of world population) experience significant disability (WHO, 2023).
725
+ - ADA digital accessibility lawsuits increased 37% in 2025.
726
+ - The European Accessibility Act (EAA) came into force June 28, 2025, applying to all digital
727
+ products and services sold in the EU.
728
+ - Accessible design correlates with improved SEO, better mobile usability, and reduced
729
+ development rework.
730
+
731
+ ---
732
+
733
+ ## Quick Reference Checklist
734
+
735
+ Use this checklist during design review. Each item references the relevant WCAG 2.2 success
736
+ criterion.
737
+
738
+ ### Perceivable
739
+
740
+ - [ ] All meaningful images have descriptive alt text (SC 1.1.1)
741
+ - [ ] Heading hierarchy is defined (h1-h6) with no skipped levels (SC 1.3.1)
742
+ - [ ] Information is not conveyed by color alone -- redundant coding used (SC 1.4.1)
743
+ - [ ] Text contrast meets 4.5:1 for normal text, 3:1 for large text (SC 1.4.3)
744
+ - [ ] UI component and graphical object contrast meets 3:1 (SC 1.4.11)
745
+ - [ ] Text is resizable to 200% without loss of content or functionality (SC 1.4.4)
746
+ - [ ] Content reflows at 320px viewport width without horizontal scrolling (SC 1.4.10)
747
+ - [ ] Hover/focus-triggered content is dismissible, hoverable, and persistent (SC 1.4.13)
748
+
749
+ ### Operable
750
+
751
+ - [ ] All functionality is operable with keyboard alone (SC 2.1.1)
752
+ - [ ] No keyboard traps -- users can navigate away from all components (SC 2.1.2)
753
+ - [ ] Skip link is provided as first focusable element (SC 2.4.1)
754
+ - [ ] Focus order matches visual layout order (SC 2.4.3)
755
+ - [ ] Focus indicator is visible on all interactive elements (SC 2.4.7)
756
+ - [ ] Focused elements are not obscured by overlays or sticky elements (SC 2.4.11)
757
+ - [ ] Touch targets are at least 24x24 CSS px on web / 44x44pt iOS / 48x48dp Android (SC 2.5.8)
758
+ - [ ] Drag operations have single-pointer alternatives (SC 2.5.7)
759
+ - [ ] No content flashes more than 3 times per second (SC 2.3.1)
760
+ - [ ] Reduced motion preference is honored (SC 2.3.3)
761
+
762
+ ### Understandable
763
+
764
+ - [ ] Page language is declared (SC 3.1.1)
765
+ - [ ] Navigation is consistent across pages (SC 3.2.3)
766
+ - [ ] Help mechanisms appear in consistent positions (SC 3.2.6)
767
+ - [ ] Error messages identify the field, explain the error, and suggest a fix (SC 3.3.1, 3.3.3)
768
+ - [ ] Previously entered data is auto-populated in multi-step flows (SC 3.3.7)
769
+ - [ ] Authentication does not require cognitive function tests (SC 3.3.8)
770
+
771
+ ### Robust
772
+
773
+ - [ ] Custom widgets use appropriate ARIA roles, states, and properties (SC 4.1.2)
774
+ - [ ] Dynamic content updates use aria-live regions (SC 4.1.3)
775
+
776
+ ---
777
+
778
+ ## Sources and References
779
+
780
+ - [WCAG 2.2 W3C Recommendation](https://www.w3.org/TR/WCAG22/)
781
+ - [What's New in WCAG 2.2 (W3C WAI)](https://www.w3.org/WAI/standards-guidelines/wcag/new-in-22/)
782
+ - [Apple Human Interface Guidelines: Accessibility](https://developer.apple.com/design/human-interface-guidelines/accessibility)
783
+ - [Material Design 3: Accessible Design](https://m3.material.io/foundations/accessible-design/overview)
784
+ - [WAI-ARIA Authoring Practices Guide (APG)](https://www.w3.org/WAI/ARIA/apg/)
785
+ - [WAI-ARIA 1.2 Specification](https://www.w3.org/TR/wai-aria-1.2/)
786
+ - [Using ARIA (W3C)](https://www.w3.org/TR/using-aria/)
787
+ - [WebAIM Screen Reader User Survey #10 (2024)](https://webaim.org/projects/screenreadersurvey10/)
788
+ - [WebAIM Contrast and Color Accessibility](https://webaim.org/articles/contrast/)
789
+ - [W3C Cognitive Accessibility Design Patterns](https://www.w3.org/WAI/WCAG2/supplemental/patterns/o3p01-clear-words/)
790
+ - [Microsoft Inclusive Design Toolkit](https://inclusive.microsoft.design/)
791
+ - [Understanding SC 1.4.3 Contrast Minimum (W3C)](https://www.w3.org/WAI/WCAG22/Understanding/contrast-minimum.html)
792
+ - [CSS prefers-reduced-motion (MDN)](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@media/prefers-reduced-motion)
793
+ - [Principles of Inclusive App Design (WWDC 2025)](https://developer.apple.com/videos/play/wwdc2025/316/)
794
+ - [WCAG 2.2 Compliance Checklist (Level Access)](https://www.levelaccess.com/blog/wcag-2-2-aa-summary-and-checklist-for-website-owners/)
795
+ - [AI-Generated UX and Accessibility Debt](https://medium.com/design-bootcamp/ai-generated-ux-and-the-growing-accessibility-debt-how-to-fix-it-8109fda7d9d5)
796
+ - [Deque University WCAG 2.2 Updates](https://dequeuniversity.com/resources/wcag-2.2/)