@beehexa/design-rules 2611.5.5 → 2611.8.1

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 (316) hide show
  1. package/README.md +1 -1
  2. package/dist/AGENTS.md +1 -1
  3. package/dist/catalog.json +3053 -777
  4. package/dist/docs/public/_redirects +2 -2
  5. package/dist/docs/public/r/action-bar.json +26 -0
  6. package/dist/docs/public/r/beehexa-theme.json +18 -0
  7. package/dist/docs/public/r/button-group.json +26 -0
  8. package/dist/docs/public/r/button.json +28 -0
  9. package/dist/docs/public/r/copy-button.json +26 -0
  10. package/dist/docs/public/r/dropdown-menu.json +56 -0
  11. package/dist/docs/public/r/index.json +66 -0
  12. package/dist/docs/public/r/segmented-control.json +31 -0
  13. package/dist/docs/public/r/toggle.json +26 -0
  14. package/dist/docs/public/r/toolbar.json +46 -0
  15. package/dist/docs/public/r/tooltip.json +41 -0
  16. package/dist/docs/scripts/color-pairs.mjs +2 -0
  17. package/dist/docs/src/components/ChildPages.astro +8 -1
  18. package/dist/docs/src/components/CodeExample.astro +123 -6
  19. package/dist/docs/src/components/ColorDemo.astro +21 -18
  20. package/dist/docs/src/components/ComponentTabs.astro +1 -1
  21. package/dist/docs/src/components/DocsFooter.astro +1 -1
  22. package/dist/docs/src/components/ElevationDemo.astro +2 -2
  23. package/dist/docs/src/components/HelpOptions.astro +8 -6
  24. package/dist/docs/src/components/IconBrowser.astro +2 -2
  25. package/dist/docs/src/components/LayoutDemo.astro +178 -99
  26. package/dist/docs/src/components/NativeControlsDemo.astro +169 -44
  27. package/dist/docs/src/components/NativeFlowDemo.astro +206 -0
  28. package/dist/docs/src/components/PhaseTable.astro +9 -5
  29. package/dist/docs/src/components/RoleGuides.astro +30 -22
  30. package/dist/docs/src/components/RuleDemo.astro +111 -0
  31. package/dist/docs/src/components/ShapeDemo.astro +25 -37
  32. package/dist/docs/src/components/SiteHeader.astro +1 -1
  33. package/dist/docs/src/components/SpacingDemo.astro +5 -3
  34. package/dist/docs/src/components/SwitchToggle.astro +13 -0
  35. package/dist/docs/src/components/SystemAreas.astro +9 -6
  36. package/dist/docs/src/components/TableOfContents.astro +1 -1
  37. package/dist/docs/src/components/TokenSearch.astro +64 -0
  38. package/dist/docs/src/components/TokenTable.astro +14 -9
  39. package/dist/docs/src/components/TypeDemo.astro +1 -1
  40. package/dist/docs/src/components/logos/LogoClearSpace.astro +1 -1
  41. package/dist/docs/src/content/components/action-bar/accessibility.mdx +32 -0
  42. package/dist/docs/src/content/components/action-bar/changelog.mdx +7 -0
  43. package/dist/docs/src/content/components/action-bar/code.mdx +69 -0
  44. package/dist/docs/src/content/components/action-bar/examples.mdx +16 -0
  45. package/dist/docs/src/content/components/action-bar/meta.json +9 -0
  46. package/dist/docs/src/content/components/action-bar/style.mdx +13 -0
  47. package/dist/docs/src/content/components/action-bar/usage.mdx +35 -0
  48. package/dist/docs/src/content/components/button/accessibility.mdx +10 -5
  49. package/dist/docs/src/content/components/button/changelog.mdx +26 -1
  50. package/dist/docs/src/content/components/button/code.mdx +130 -25
  51. package/dist/docs/src/content/components/button/examples.mdx +109 -23
  52. package/dist/docs/src/content/components/button/meta.json +5 -1
  53. package/dist/docs/src/content/components/button/style.mdx +72 -0
  54. package/dist/docs/src/content/components/button/usage.mdx +118 -29
  55. package/dist/docs/src/content/components/button-group/accessibility.mdx +32 -0
  56. package/dist/docs/src/content/components/button-group/changelog.mdx +7 -0
  57. package/dist/docs/src/content/components/button-group/code.mdx +39 -0
  58. package/dist/docs/src/content/components/button-group/examples.mdx +36 -0
  59. package/dist/docs/src/content/components/button-group/meta.json +9 -0
  60. package/dist/docs/src/content/components/button-group/style.mdx +12 -0
  61. package/dist/docs/src/content/components/button-group/usage.mdx +31 -0
  62. package/dist/docs/src/content/components/icon-button/accessibility.mdx +35 -0
  63. package/dist/docs/src/content/components/icon-button/changelog.mdx +7 -0
  64. package/dist/docs/src/content/components/icon-button/code.mdx +66 -0
  65. package/dist/docs/src/content/components/icon-button/examples.mdx +46 -0
  66. package/dist/docs/src/content/components/icon-button/meta.json +9 -0
  67. package/dist/docs/src/content/components/icon-button/style.mdx +13 -0
  68. package/dist/docs/src/content/components/icon-button/usage.mdx +42 -0
  69. package/dist/docs/src/content/components/menu-button/accessibility.mdx +36 -0
  70. package/dist/docs/src/content/components/menu-button/changelog.mdx +7 -0
  71. package/dist/docs/src/content/components/menu-button/code.mdx +55 -0
  72. package/dist/docs/src/content/components/menu-button/examples.mdx +26 -0
  73. package/dist/docs/src/content/components/menu-button/meta.json +9 -0
  74. package/dist/docs/src/content/components/menu-button/style.mdx +15 -0
  75. package/dist/docs/src/content/components/menu-button/usage.mdx +44 -0
  76. package/dist/docs/src/content/components/resizable-panel/meta.json +5 -1
  77. package/dist/docs/src/content/{foundations/styles/scrollbars.mdx → components/scrollbar/code.mdx} +20 -39
  78. package/dist/docs/src/content/components/scrollbar/meta.json +9 -0
  79. package/dist/docs/src/content/components/scrollbar/usage.mdx +36 -0
  80. package/dist/docs/src/content/components/segmented-control/accessibility.mdx +32 -0
  81. package/dist/docs/src/content/components/segmented-control/changelog.mdx +7 -0
  82. package/dist/docs/src/content/components/segmented-control/code.mdx +46 -0
  83. package/dist/docs/src/content/components/segmented-control/examples.mdx +26 -0
  84. package/dist/docs/src/content/components/segmented-control/meta.json +9 -0
  85. package/dist/docs/src/content/components/segmented-control/style.mdx +13 -0
  86. package/dist/docs/src/content/components/segmented-control/usage.mdx +38 -0
  87. package/dist/docs/src/content/components/split-button/accessibility.mdx +32 -0
  88. package/dist/docs/src/content/components/split-button/changelog.mdx +7 -0
  89. package/dist/docs/src/content/components/split-button/code.mdx +57 -0
  90. package/dist/docs/src/content/components/split-button/examples.mdx +26 -0
  91. package/dist/docs/src/content/components/split-button/meta.json +9 -0
  92. package/dist/docs/src/content/components/split-button/style.mdx +12 -0
  93. package/dist/docs/src/content/components/split-button/usage.mdx +28 -0
  94. package/dist/docs/src/content/components/switch/accessibility.mdx +28 -0
  95. package/dist/docs/src/content/components/switch/examples.mdx +35 -0
  96. package/dist/docs/src/content/components/switch/meta.json +9 -0
  97. package/dist/docs/src/content/components/switch/usage.mdx +44 -0
  98. package/dist/docs/src/content/components/toggle-button/accessibility.mdx +31 -0
  99. package/dist/docs/src/content/components/toggle-button/changelog.mdx +7 -0
  100. package/dist/docs/src/content/components/toggle-button/code.mdx +45 -0
  101. package/dist/docs/src/content/components/toggle-button/examples.mdx +36 -0
  102. package/dist/docs/src/content/components/toggle-button/meta.json +9 -0
  103. package/dist/docs/src/content/components/toggle-button/style.mdx +11 -0
  104. package/dist/docs/src/content/components/toggle-button/usage.mdx +33 -0
  105. package/dist/docs/src/content/components/toolbar/accessibility.mdx +33 -0
  106. package/dist/docs/src/content/components/toolbar/changelog.mdx +7 -0
  107. package/dist/docs/src/content/components/toolbar/code.mdx +81 -0
  108. package/dist/docs/src/content/components/toolbar/examples.mdx +16 -0
  109. package/dist/docs/src/content/components/toolbar/meta.json +9 -0
  110. package/dist/docs/src/content/components/toolbar/style.mdx +12 -0
  111. package/dist/docs/src/content/components/toolbar/usage.mdx +36 -0
  112. package/dist/docs/src/content/foundations/guidelines/accessibility/statement.mdx +4 -2
  113. package/dist/docs/src/content/foundations/guidelines/accessibility/testing.mdx +1 -1
  114. package/dist/docs/src/content/foundations/guidelines/content/messages.mdx +67 -0
  115. package/dist/docs/src/content/foundations/guidelines/content/numbers-dates-and-currency.mdx +72 -0
  116. package/dist/docs/src/content/foundations/guidelines/content/style-and-grammar.mdx +92 -0
  117. package/dist/docs/src/content/foundations/guidelines/content/terms.mdx +57 -0
  118. package/dist/docs/src/content/foundations/guidelines/content/voice-and-tone.mdx +48 -0
  119. package/dist/docs/src/content/foundations/guidelines/content.mdx +22 -17
  120. package/dist/docs/src/content/foundations/styles/border.mdx +1 -6
  121. package/dist/docs/src/content/foundations/styles/color/dark-mode.mdx +66 -6
  122. package/dist/docs/src/content/foundations/styles/color/usage.mdx +5 -5
  123. package/dist/docs/src/content/foundations/styles/data-visualization.mdx +2 -78
  124. package/dist/docs/src/content/foundations/styles/elevation.mdx +2 -2
  125. package/dist/docs/src/content/foundations/styles/icons/accessibility.mdx +1 -1
  126. package/dist/docs/src/content/foundations/styles/icons/code.mdx +1 -1
  127. package/dist/docs/src/content/foundations/styles/icons/library.mdx +2 -2
  128. package/dist/docs/src/content/foundations/styles/icons/usage.mdx +0 -3
  129. package/dist/docs/src/content/foundations/styles/interaction-states.mdx +13 -69
  130. package/dist/docs/src/content/foundations/styles/layout/app-frame.mdx +4 -9
  131. package/dist/docs/src/content/foundations/styles/layout/grid.mdx +1 -1
  132. package/dist/docs/src/content/foundations/styles/layout/overlays.mdx +3 -0
  133. package/dist/docs/src/content/foundations/styles/logos/downloads-and-terms.mdx +3 -3
  134. package/dist/docs/src/content/foundations/styles/logos/using-the-logo.mdx +1 -1
  135. package/dist/docs/src/content/foundations/styles/motion.mdx +3 -1
  136. package/dist/docs/src/content/foundations/styles/radius.mdx +32 -28
  137. package/dist/docs/src/content/foundations/styles/size-and-density.mdx +7 -6
  138. package/dist/docs/src/content/foundations/styles/spacing.mdx +1 -1
  139. package/dist/docs/src/content/foundations/styles/typography/code.mdx +1 -1
  140. package/dist/docs/src/content/foundations/styles/typography/usage.mdx +7 -0
  141. package/dist/docs/src/content/foundations/styles/z-index.mdx +3 -16
  142. package/dist/docs/src/content/foundations/tokens/all-tokens.mdx +51 -2
  143. package/dist/docs/src/content/foundations/tokens/index.mdx +91 -6
  144. package/dist/docs/src/content/get-started/content.mdx +25 -3
  145. package/dist/docs/src/content/get-started/design.mdx +34 -15
  146. package/dist/docs/src/content/get-started/develop.mdx +83 -28
  147. package/dist/docs/src/content/get-started/get-help.mdx +21 -5
  148. package/dist/docs/src/content/get-started/index.mdx +11 -12
  149. package/dist/docs/src/content/tools/ant-design-vue-theme.mdx +176 -48
  150. package/dist/docs/src/content/tools/application-content.mdx +52 -13
  151. package/dist/docs/src/content/tools/editors.mdx +36 -28
  152. package/dist/docs/src/content/tools/mermaid.mdx +42 -9
  153. package/dist/docs/src/content/tools/vueflow.mdx +199 -60
  154. package/dist/docs/src/content-vi/components/action-bar/accessibility.mdx +32 -0
  155. package/dist/docs/src/content-vi/components/action-bar/changelog.mdx +7 -0
  156. package/dist/docs/src/content-vi/components/action-bar/code.mdx +69 -0
  157. package/dist/docs/src/content-vi/components/action-bar/examples.mdx +16 -0
  158. package/dist/docs/src/content-vi/components/action-bar/style.mdx +13 -0
  159. package/dist/docs/src/content-vi/components/action-bar/usage.mdx +35 -0
  160. package/dist/docs/src/content-vi/components/button/accessibility.mdx +56 -0
  161. package/dist/docs/src/content-vi/components/button/changelog.mdx +31 -0
  162. package/dist/docs/src/content-vi/components/button/code.mdx +139 -0
  163. package/dist/docs/src/content-vi/components/button/examples.mdx +126 -0
  164. package/dist/docs/src/content-vi/components/button/style.mdx +72 -0
  165. package/dist/docs/src/content-vi/components/button/usage.mdx +133 -0
  166. package/dist/docs/src/content-vi/components/button-group/accessibility.mdx +32 -0
  167. package/dist/docs/src/content-vi/components/button-group/changelog.mdx +7 -0
  168. package/dist/docs/src/content-vi/components/button-group/code.mdx +39 -0
  169. package/dist/docs/src/content-vi/components/button-group/examples.mdx +36 -0
  170. package/dist/docs/src/content-vi/components/button-group/style.mdx +12 -0
  171. package/dist/docs/src/content-vi/components/button-group/usage.mdx +31 -0
  172. package/dist/docs/src/content-vi/components/icon-button/accessibility.mdx +35 -0
  173. package/dist/docs/src/content-vi/components/icon-button/changelog.mdx +7 -0
  174. package/dist/docs/src/content-vi/components/icon-button/code.mdx +66 -0
  175. package/dist/docs/src/content-vi/components/icon-button/examples.mdx +46 -0
  176. package/dist/docs/src/content-vi/components/icon-button/style.mdx +13 -0
  177. package/dist/docs/src/content-vi/components/icon-button/usage.mdx +42 -0
  178. package/dist/docs/src/content-vi/components/menu-button/accessibility.mdx +36 -0
  179. package/dist/docs/src/content-vi/components/menu-button/changelog.mdx +7 -0
  180. package/dist/docs/src/content-vi/components/menu-button/code.mdx +55 -0
  181. package/dist/docs/src/content-vi/components/menu-button/examples.mdx +26 -0
  182. package/dist/docs/src/content-vi/components/menu-button/style.mdx +15 -0
  183. package/dist/docs/src/content-vi/components/menu-button/usage.mdx +44 -0
  184. package/dist/docs/src/content-vi/components/resizable-panel/accessibility.mdx +58 -0
  185. package/dist/docs/src/content-vi/components/resizable-panel/changelog.mdx +20 -0
  186. package/dist/docs/src/content-vi/components/resizable-panel/code.mdx +78 -0
  187. package/dist/docs/src/content-vi/components/resizable-panel/examples.mdx +83 -0
  188. package/dist/docs/src/content-vi/components/resizable-panel/usage.mdx +97 -0
  189. package/dist/docs/src/content-vi/components/scrollbar/code.mdx +71 -0
  190. package/dist/docs/src/content-vi/components/scrollbar/usage.mdx +36 -0
  191. package/dist/docs/src/content-vi/components/segmented-control/accessibility.mdx +32 -0
  192. package/dist/docs/src/content-vi/components/segmented-control/changelog.mdx +7 -0
  193. package/dist/docs/src/content-vi/components/segmented-control/code.mdx +46 -0
  194. package/dist/docs/src/content-vi/components/segmented-control/examples.mdx +26 -0
  195. package/dist/docs/src/content-vi/components/segmented-control/style.mdx +13 -0
  196. package/dist/docs/src/content-vi/components/segmented-control/usage.mdx +38 -0
  197. package/dist/docs/src/content-vi/components/split-button/accessibility.mdx +32 -0
  198. package/dist/docs/src/content-vi/components/split-button/changelog.mdx +7 -0
  199. package/dist/docs/src/content-vi/components/split-button/code.mdx +57 -0
  200. package/dist/docs/src/content-vi/components/split-button/examples.mdx +26 -0
  201. package/dist/docs/src/content-vi/components/split-button/style.mdx +12 -0
  202. package/dist/docs/src/content-vi/components/split-button/usage.mdx +28 -0
  203. package/dist/docs/src/content-vi/components/switch/accessibility.mdx +28 -0
  204. package/dist/docs/src/content-vi/components/switch/examples.mdx +35 -0
  205. package/dist/docs/src/content-vi/components/switch/usage.mdx +44 -0
  206. package/dist/docs/src/content-vi/components/toggle-button/accessibility.mdx +31 -0
  207. package/dist/docs/src/content-vi/components/toggle-button/changelog.mdx +7 -0
  208. package/dist/docs/src/content-vi/components/toggle-button/code.mdx +45 -0
  209. package/dist/docs/src/content-vi/components/toggle-button/examples.mdx +36 -0
  210. package/dist/docs/src/content-vi/components/toggle-button/style.mdx +11 -0
  211. package/dist/docs/src/content-vi/components/toggle-button/usage.mdx +33 -0
  212. package/dist/docs/src/content-vi/components/toolbar/accessibility.mdx +33 -0
  213. package/dist/docs/src/content-vi/components/toolbar/changelog.mdx +7 -0
  214. package/dist/docs/src/content-vi/components/toolbar/code.mdx +81 -0
  215. package/dist/docs/src/content-vi/components/toolbar/examples.mdx +16 -0
  216. package/dist/docs/src/content-vi/components/toolbar/style.mdx +12 -0
  217. package/dist/docs/src/content-vi/components/toolbar/usage.mdx +36 -0
  218. package/dist/docs/src/content-vi/foundations/guidelines/accessibility/statement.mdx +4 -2
  219. package/dist/docs/src/content-vi/foundations/guidelines/accessibility/testing.mdx +1 -1
  220. package/dist/docs/src/content-vi/foundations/guidelines/content/messages.mdx +67 -0
  221. package/dist/docs/src/content-vi/foundations/guidelines/content/numbers-dates-and-currency.mdx +71 -0
  222. package/dist/docs/src/content-vi/foundations/guidelines/content/style-and-grammar.mdx +91 -0
  223. package/dist/docs/src/content-vi/foundations/guidelines/content/terms.mdx +57 -0
  224. package/dist/docs/src/content-vi/foundations/guidelines/content/voice-and-tone.mdx +48 -0
  225. package/dist/docs/src/content-vi/foundations/guidelines/content.mdx +24 -19
  226. package/dist/docs/src/content-vi/foundations/styles/border.mdx +1 -5
  227. package/dist/docs/src/content-vi/foundations/styles/color/dark-mode.mdx +65 -6
  228. package/dist/docs/src/content-vi/foundations/styles/color/palette.mdx +1 -1
  229. package/dist/docs/src/content-vi/foundations/styles/color/usage.mdx +7 -7
  230. package/dist/docs/src/content-vi/foundations/styles/data-visualization.mdx +1 -1
  231. package/dist/docs/src/content-vi/foundations/styles/elevation.mdx +3 -3
  232. package/dist/docs/src/content-vi/foundations/styles/icons/accessibility.mdx +2 -2
  233. package/dist/docs/src/content-vi/foundations/styles/icons/code.mdx +1 -1
  234. package/dist/docs/src/content-vi/foundations/styles/icons/library.mdx +2 -2
  235. package/dist/docs/src/content-vi/foundations/styles/icons/usage.mdx +1 -4
  236. package/dist/docs/src/content-vi/foundations/styles/illustration.mdx +3 -3
  237. package/dist/docs/src/content-vi/foundations/styles/interaction-states.mdx +13 -10
  238. package/dist/docs/src/content-vi/foundations/styles/layout/app-frame.mdx +4 -9
  239. package/dist/docs/src/content-vi/foundations/styles/layout/grid.mdx +1 -1
  240. package/dist/docs/src/content-vi/foundations/styles/layout/overlays.mdx +3 -0
  241. package/dist/docs/src/content-vi/foundations/styles/logos/downloads-and-terms.mdx +4 -4
  242. package/dist/docs/src/content-vi/foundations/styles/logos/product-logos.mdx +1 -1
  243. package/dist/docs/src/content-vi/foundations/styles/logos/using-the-logo.mdx +1 -1
  244. package/dist/docs/src/content-vi/foundations/styles/motion.mdx +3 -1
  245. package/dist/docs/src/content-vi/foundations/styles/opacity.mdx +2 -2
  246. package/dist/docs/src/content-vi/foundations/styles/radius.mdx +32 -28
  247. package/dist/docs/src/content-vi/foundations/styles/size-and-density.mdx +7 -6
  248. package/dist/docs/src/content-vi/foundations/styles/spacing.mdx +1 -1
  249. package/dist/docs/src/content-vi/foundations/styles/typography/code.mdx +1 -1
  250. package/dist/docs/src/content-vi/foundations/styles/typography/usage.mdx +7 -0
  251. package/dist/docs/src/content-vi/foundations/styles/z-index.mdx +3 -16
  252. package/dist/docs/src/content-vi/foundations/tokens/all-tokens.mdx +51 -2
  253. package/dist/docs/src/content-vi/foundations/tokens/index.mdx +90 -5
  254. package/dist/docs/src/content-vi/get-started/content.mdx +36 -0
  255. package/dist/docs/src/content-vi/get-started/design.mdx +49 -0
  256. package/dist/docs/src/content-vi/get-started/develop.mdx +110 -0
  257. package/dist/docs/src/content-vi/get-started/get-help.mdx +35 -0
  258. package/dist/docs/src/content-vi/get-started/index.mdx +49 -0
  259. package/dist/docs/src/content-vi/release-phases/index.mdx +11 -0
  260. package/dist/docs/src/content-vi/tools/ai-agents.mdx +36 -0
  261. package/dist/docs/src/content-vi/tools/ant-design-vue-theme.mdx +676 -0
  262. package/dist/docs/src/content-vi/tools/application-content.mdx +171 -0
  263. package/dist/docs/src/content-vi/tools/editors.mdx +254 -0
  264. package/dist/docs/src/content-vi/tools/eslint.mdx +15 -0
  265. package/dist/docs/src/content-vi/tools/index.mdx +7 -0
  266. package/dist/docs/src/content-vi/tools/mermaid.mdx +179 -0
  267. package/dist/docs/src/content-vi/tools/stylelint.mdx +18 -0
  268. package/dist/docs/src/content-vi/tools/vueflow.mdx +264 -0
  269. package/dist/docs/src/content.config.ts +13 -2
  270. package/dist/docs/src/lib/dates.ts +8 -0
  271. package/dist/docs/src/lib/i18n.ts +1 -0
  272. package/dist/docs/src/lib/icons.ts +2 -2
  273. package/dist/docs/src/lib/lucide-svg.ts +14 -0
  274. package/dist/docs/src/lib/navigation.ts +7 -4
  275. package/dist/docs/src/lib/token-descriptions-vi.ts +254 -12
  276. package/dist/docs/src/lib/tokens.ts +3 -0
  277. package/dist/docs/src/lib/utils.ts +9 -0
  278. package/dist/docs/src/styles/chrome.css +7 -7
  279. package/dist/docs/src/styles/color.css +31 -31
  280. package/dist/docs/src/styles/docs.css +75 -46
  281. package/dist/docs/src/styles/elevation.css +1 -1
  282. package/dist/docs/src/styles/global.css +28 -11
  283. package/dist/docs/src/styles/icons.css +16 -16
  284. package/dist/docs/src/styles/kit.css +71 -10
  285. package/dist/docs/src/styles/layout.css +16 -11
  286. package/dist/docs/src/styles/logos.css +24 -24
  287. package/dist/docs/src/styles/opacity.css +3 -3
  288. package/dist/docs/src/styles/registry.css +10 -0
  289. package/dist/docs/src/styles/rules.css +24 -0
  290. package/dist/docs/src/styles/shapes.css +2 -2
  291. package/dist/docs/src/styles/tokens.css +213 -120
  292. package/dist/docs/src/styles/tokens.js +69 -32
  293. package/dist/docs/src/styles/typography.css +9 -9
  294. package/dist/docs/src/styles/zindex.css +6 -5
  295. package/dist/docs/tokens/button.json +51 -0
  296. package/dist/docs/tokens/color.json +13 -8
  297. package/dist/docs/tokens/components.json +39 -0
  298. package/dist/docs/tokens/content.json +103 -10
  299. package/dist/docs/tokens/diagram.json +490 -49
  300. package/dist/docs/tokens/editor.json +128 -22
  301. package/dist/docs/tokens/flow.json +412 -80
  302. package/dist/docs/tokens/layout.json +13 -4
  303. package/dist/docs/tokens/motion.json +14 -0
  304. package/dist/docs/tokens/radius.json +9 -9
  305. package/dist/docs/tokens/renderer.json +8 -0
  306. package/dist/docs/tokens/resize.json +84 -15
  307. package/dist/docs/tokens/scrollbar.json +42 -7
  308. package/dist/docs/tokens/size.json +6 -6
  309. package/dist/docs/tokens/spacing.json +1 -1
  310. package/dist/docs/tokens/switch.json +306 -51
  311. package/dist/docs/tokens/typography.json +1 -1
  312. package/dist/docs/tokens/visualization.json +465 -53
  313. package/dist/docs/tokens/z-index.json +0 -10
  314. package/dist/index.js +3053 -777
  315. package/package.json +1 -1
  316. package/dist/docs/src/brand/structure-proposal.md +0 -227
@@ -0,0 +1,67 @@
1
+ ---
2
+ title: Messages
3
+ description: "A good message turns a problem into a next step. How to write errors, warnings, success messages, empty states and confirmations."
4
+ order: 4
5
+ ---
6
+
7
+ It is 7 in the morning and 3 orders from last night did not reach the ERP. The person needs three things from the message: what failed, why, and what to do now. A message that gives all three gets the orders through before the shop opens.
8
+
9
+ **Every error says what happened, why, and how to fix it.**
10
+
11
+ ## Choose the message
12
+
13
+ | Type | Use it when | Write |
14
+ | --- | --- | --- |
15
+ | Error | Something failed and the person has to act | What happened, why, and how to fix it |
16
+ | Warning | Something may go wrong if nothing changes | What may happen, and how to prevent it |
17
+ | Success | An action the person started has finished | What finished, in the past tense |
18
+ | Information | Something useful changed, and nothing needs doing | The fact, in one sentence |
19
+ | Empty state | A list or page has nothing to show yet | What will appear here, and how to add the first item |
20
+ | Confirmation | An action is hard or impossible to undo | The action, what it affects, and that it can't be undone |
21
+
22
+ ## Errors
23
+
24
+ Write the three parts in this order. WCAG asks for the first and the third: say what went wrong in text (3.3.1), and suggest a fix when one is known (3.3.3).
25
+
26
+ 1. **What happened,** with the object and the number: "Couldn't sync 3 orders to the ERP."
27
+ 2. **Why,** in words the person understands: "The ERP rejected them because the customer is missing."
28
+ 3. **How to fix it,** as an action: "Add a default customer in the connector settings, then sync again."
29
+
30
+ Put the action in a button when the product can do it: "Retry", "Reconnect ERP", "Open settings".
31
+
32
+ - **Don't blame the person.** "The file has no Order ID column", not "You uploaded the wrong file".
33
+ - **Don't show only an error code.** If a code helps support, put it last: "Reference: SYNC-4021."
34
+ - **Say what the product kept.** "Your other 21 orders synced." People need to know what is safe.
35
+ - **Show the error next to its cause.** A field error goes under the field. A sync error goes on the sync it belongs to.
36
+
37
+ ## Warnings
38
+
39
+ Say what will happen and when, then how to avoid it: "Access to your online store expires in 3 days. Reconnect the store to keep orders syncing."
40
+
41
+ ## Success
42
+
43
+ Keep it short and in the past tense: "24 orders synced", "Workflow saved". Don't add exclamation marks or words like "successfully": the past tense already says it worked.
44
+
45
+ ## Empty states
46
+
47
+ Tell people what will appear and how to get there. Offer the first action as a button.
48
+
49
+ | Situation | Example |
50
+ | --- | --- |
51
+ | First use | "No workflows yet. Create a workflow to sync orders between your stores." Button: "Create workflow" |
52
+ | No search results | "No orders match INV-2041. Check the number or clear the filters." |
53
+ | Nothing to do | "No failed syncs. Everything is up to date." |
54
+
55
+ ## Confirmations
56
+
57
+ Ask only before actions that are hard to undo, such as deleting or disconnecting. Asking too often teaches people to confirm without reading.
58
+
59
+ - **Title:** a question with the action and the object: "Delete this workflow?"
60
+ - **Body:** what else is affected, and that it can't be undone: "Its schedule and sync history are deleted too. You can't undo this."
61
+ - **Buttons:** repeat the verb, not "OK" or "Yes": "Delete" and "Cancel".
62
+
63
+ ## Related
64
+
65
+ - [Voice and tone](/foundations/guidelines/content/voice-and-tone/): how the tone changes when things go wrong.
66
+ - [Color usage](/foundations/styles/color/usage/): colours for danger, warning, success and information.
67
+ - [Keyboard and focus](/foundations/guidelines/accessibility/keyboard-and-focus/): where focus goes when a message or dialog opens.
@@ -0,0 +1,72 @@
1
+ ---
2
+ title: Numbers, dates and currency
3
+ description: "An amount read wrongly costs real money. Write numbers, dates, times and currency the same way on every screen, in English and Vietnamese."
4
+ order: 3
5
+ ---
6
+
7
+ In English, 1,250.5 is a little over a thousand. To a Vietnamese reader, the same marks can look like a number over a million. When HexaSync moves orders and invoices between systems, people check amounts and dates all day, so every screen has to write them the same way.
8
+
9
+ **Format numbers, dates and money for the language of the page, and never round data that came from another system.**
10
+
11
+ ## Numbers
12
+
13
+ - **Write numbers as numerals,** even below 10: "3 orders failed", "1 store connected".
14
+ - **Separate thousands and decimals by language:**
15
+
16
+ | | English | Vietnamese |
17
+ | --- | --- | --- |
18
+ | Thousands | Comma: 1,250,000 | Full stop: 1.250.000 |
19
+ | Decimals | Point: 1,250.5 | Comma: 1.250,5 |
20
+ | Percent | 25% | 25% |
21
+ | Range | 10 to 20 | 10 đến 20 |
22
+ | Part of a whole | Step 2 of 3 | Bước 2 trên 3 |
23
+
24
+ - **Four-digit numbers get a separator too:** 1,200 and 1.200.
25
+ - **Write ranges with a word, not a dash:** screen readers read a dash aloud as "dash". In a table or another tight space, an en dash is fine: 10–20.
26
+ - **Write "of", not a slash:** "Step 2 of 3", not "Step 2/3".
27
+
28
+ ## Currency
29
+
30
+ The Vietnamese đồng has no minor unit, so amounts in đồng have no decimals by default.
31
+
32
+ | | English | Vietnamese |
33
+ | --- | --- | --- |
34
+ | Đồng | ₫1,250,000 | 1.250.000 ₫ |
35
+ | Đồng with decimals | ₫1,250,000.223 | 1.250.000,223 ₫ |
36
+ | Other currencies | $1,250.50 | 1.250,50 US$ |
37
+
38
+ - **In Vietnamese, the ₫ sign goes after the amount,** with a space before it.
39
+ - **Totals and line amounts are shown to the whole đồng.**
40
+ - **Keep the decimals that came from the source system.** If a unit price or an exchange rate arrives with three decimals, show all three. Don't round data while it moves between systems: the two systems would then disagree.
41
+ - **When one table holds several currencies,** use the currency code instead of the sign: 1.250,50 USD, 1.250.000 VND.
42
+ - **Show cents only when there are some:** $1,250, not $1,250.00.
43
+ - **Don't shorten amounts:** 12,000, not 12k. Write "million" and "billion" in full.
44
+
45
+ These are the formats that browsers and most platforms produce for the `en` and `vi-VN` locales. Never build a number, amount or date string by hand: use the platform's formatting, such as `Intl.NumberFormat` and `Intl.DateTimeFormat` in JavaScript, and tell developers which format a design needs.
46
+
47
+ ## Dates
48
+
49
+ Write the day first, then the month, then a four-digit year. The month is spelled out in English, because 05/11 means 5 November in Vietnam and 11 May in the United States.
50
+
51
+ | | English | Vietnamese |
52
+ | --- | --- | --- |
53
+ | Tables, fields and lists | 5 Nov 2026 | 05/11/2026 |
54
+ | Running text | 5 November 2026 | 5 tháng 11 năm 2026 |
55
+
56
+ - **In Vietnamese, use two digits for the day and month** so dates line up in tables: 05/11/2026, not 5/11/2026.
57
+ - **In English, use the three-letter month** in tight spaces: Jan, Feb, Mar. Don't add a full stop after it.
58
+ - **Write date ranges with "to":** "5 Nov to 12 Nov 2026", "05/11/2026 đến 12/11/2026".
59
+ - **Join a date and a time with "at":** "5 Nov 2026 at 14:30", "14:30 ngày 05/11/2026".
60
+ - **Don't add ordinals:** "5 November", not "5th November".
61
+ - **For recent events, a relative time is easier to read:** "2 minutes ago", "2 phút trước". Show the full date and time on hover or focus, and switch to the full date after 24 hours.
62
+
63
+ ## Times
64
+
65
+ - **Use the 24-hour clock:** 14:30, not 2:30 PM.
66
+ - **Add the time zone when people work across zones,** or when a schedule runs on a server: "Runs daily at 02:00 (GMT+7)".
67
+ - **Write durations in words and numbers:** "3 minutes", "1 hour 20 minutes". In tight spaces, "3 min".
68
+
69
+ ## Related
70
+
71
+ - [Style and grammar](/foundations/guidelines/content/style-and-grammar/): capitals, buttons and punctuation.
72
+ - [Messages](/foundations/guidelines/content/messages/): how to write each kind of message.
@@ -0,0 +1,92 @@
1
+ ---
2
+ title: Style and grammar
3
+ description: "Small rules, applied the same way everywhere, make a product feel finished. Capitals, buttons, labels, punctuation and links."
4
+ order: 2
5
+ ---
6
+
7
+ A screen where one button says "Save Changes" and the next says "Save changes" looks careless, even if nobody can say why. These rules remove those small differences, so people notice the work, not the words.
8
+
9
+ **Write in sentence case, start buttons with a verb, and end only full sentences with a full stop.**
10
+
11
+ ## Capitals
12
+
13
+ Use sentence case everywhere: capitalise only the first word and proper nouns. This applies to buttons, labels, headings, menu items, tabs and page titles, in both languages.
14
+
15
+ | Do | Don't |
16
+ | --- | --- |
17
+ | Save changes | Save Changes |
18
+ | Sync orders to the ERP | Sync Orders To The ERP |
19
+ | Lưu thay đổi | Lưu Thay Đổi |
20
+
21
+ Sentence case is easier to read, works the same way in English and Vietnamese, and is what most large design systems use.
22
+
23
+ - **Proper nouns and abbreviations keep their capitals:** Beehexa, HexaSync, ERP, CRM.
24
+ - **Don't capitalise features or common things:** "workflow", "connector", "dashboard", not "Workflow" in the middle of a sentence.
25
+ - **Don't write in all capitals.** It is slower to read, and in Vietnamese the marks crowd the line above. Abbreviations such as API, CSV and SKU are the exception.
26
+
27
+ ## Buttons and links
28
+
29
+ - **Start with a verb** and say what will happen: "Sync orders", "Connect store", "Download CSV".
30
+ - **Keep it short:** one to three words. In Vietnamese, two to four.
31
+ - **Leave out "a", "an" and "the":** "Create workflow", not "Create a workflow".
32
+ - **Use the same verb from start to finish.** If the button says "Delete workflow", the confirmation button says "Delete", not "OK" or "Yes".
33
+ - **Name the link by where it goes:** "View sync history", not "Click here" or "Learn more" on its own. A link must make sense from its text (WCAG 2.4.4).
34
+ - **Say "select", not "click"**, because people use touch, keyboards and screen readers too.
35
+
36
+ ## Labels and help text
37
+
38
+ - **Labels are nouns,** with no colon at the end: "Store name", "Sync schedule".
39
+ - **Help text under a field is a full sentence** with a full stop: "Orders older than this date are not synced."
40
+ - **Placeholders are not labels.** They disappear when people type. Put anything people need to keep in the label or the help text (WCAG 3.3.2).
41
+ - **Labels and headings say what the field or section is about** (WCAG 2.4.6).
42
+
43
+ ## Punctuation
44
+
45
+ | Mark | Rule |
46
+ | --- | --- |
47
+ | Full stop | End full sentences in messages and help text. Leave it off buttons, labels, headings, menu items and single-sentence tooltips. |
48
+ | Exclamation mark | Don't use it. Calm text is easier to trust. |
49
+ | Question mark | Use it for real questions, such as a confirmation title: "Delete this workflow?" |
50
+ | Colon | Use it before a list or a value in running text. Not at the end of a label. |
51
+ | Quotation marks | Use them to quote the name of something the person typed: Workflow "Daily orders" was saved. |
52
+ | Ampersand (&) | Don't use it in place of "and", unless it is part of a name. |
53
+ | Ellipsis (…) | Use it only to show text has been cut off, or that something is still in progress: "Syncing…" |
54
+ | Slash and > | Don't use them for paths or choices. Write "Go to Settings, then Connectors". Screen readers read > as "greater than". |
55
+ | Abbreviations | Don't write e.g., i.e. or etc. Write "for example" or "such as". |
56
+
57
+ ## Grammar
58
+
59
+ - **Use the active voice:** "The ERP rejected the request", not "The request was rejected".
60
+ - **Use contractions in English,** such as "can't" and "don't". They sound natural and are easier to read.
61
+ - **Keep sentences short:** one idea per sentence, about 20 words at most.
62
+ - **Put the most important words first.** People scan the start of a line.
63
+ - **Keep lists short and parallel:** six items or fewer, each starting the same way. End an item with a full stop only if it is a full sentence.
64
+ - **Don't cut text off.** Shorten it or let it wrap. If it has to be cut, such as a long store name, show the full text in a tooltip.
65
+ - **Vietnamese:** write complete words with all their marks, never unaccented text. Don't mix English and Vietnamese in one sentence; use the word from [Terms](/foundations/guidelines/content/terms/).
66
+
67
+ ## Writing in two languages
68
+
69
+ **Write the Vietnamese text as Vietnamese, not as a word-for-word copy of the English.** Most style mistakes come from translation: from a machine, or from following the English word order.
70
+
71
+ | English | Don't write | Write | Why |
72
+ |---|---|---|---|
73
+ | Orders synced | Các đơn hàng đã được đồng bộ thành công | Đã đồng bộ đơn hàng | Active, past tense, no "thành công" |
74
+ | You don't have access to this store | Quý khách không có quyền truy cập vào cửa hàng này | Bạn chưa có quyền vào cửa hàng này | "Bạn", and the word from [Terms](/foundations/guidelines/content/terms/) |
75
+ | Click Save | Click vào nút Lưu | Chọn Lưu | No "click", no mixed languages |
76
+ | Sync Orders From Store | Đồng Bộ Đơn Hàng Từ Cửa Hàng | Đồng bộ đơn hàng từ cửa hàng | Sentence case in both languages |
77
+
78
+ - **Read the Vietnamese aloud.** If it sounds like a translation, rewrite it.
79
+ - **Leave room.** Vietnamese is often longer than English. Let text wrap instead of shortening it until the meaning goes.
80
+
81
+ ### Strings with values
82
+
83
+ - **Keep a sentence in one string,** with its values inside: `Synced {count} orders from {store}`. Don't join pieces of sentences in code; the word order differs between languages.
84
+ - **Write the plural forms English needs.** Vietnamese has one form for every count: `{count} đơn hàng`. English has two: `1 order`, `2 orders`. Use the plural format of your translation library, such as `{count, plural, one {# order} other {# orders}}`.
85
+ - **Format numbers, dates and money before they go in,** as on [Numbers, dates and currency](/foundations/guidelines/content/numbers-dates-and-currency/).
86
+ - **Don't build a word from parts,** such as an "s" added in code.
87
+
88
+ ## Related
89
+
90
+ - [Voice and tone](/foundations/guidelines/content/voice-and-tone/): how Beehexa sounds.
91
+ - [Numbers, dates and currency](/foundations/guidelines/content/numbers-dates-and-currency/): how to write amounts and dates.
92
+ - [Typography usage](/foundations/styles/typography/usage/): text styles and long text.
@@ -0,0 +1,57 @@
1
+ ---
2
+ title: Terms
3
+ description: "One thing, one name, in both languages. The words Beehexa products use for each thing, in English and Vietnamese."
4
+ order: 5
5
+ ---
6
+
7
+ If one screen says "connector", the next says "integration" and the help page says "app", people wonder whether these are three different things. A shared word list ends that question, and lets the English and Vietnamese products say exactly the same thing.
8
+
9
+ **Use the word in this list. Translate every term into Vietnamese; keep only names of products and companies in English.**
10
+
11
+ ## Product names
12
+
13
+ Product and company names are never translated and keep their own capitals: Beehexa, HexaSync. In examples, name the kind of system instead of a real product: the online store, the ERP, the CRM.
14
+
15
+ ## Word list
16
+
17
+ | English | Vietnamese | Notes |
18
+ | --- | --- | --- |
19
+ | sync | đồng bộ | Verb and noun: "Sync orders", "Đồng bộ đơn hàng" |
20
+ | connector | trình kết nối | The part of HexaSync that talks to one system, such as the ERP connector |
21
+ | integration | tích hợp | Two or more systems working together through HexaSync |
22
+ | workflow | quy trình | A set of steps that runs on a schedule or a trigger |
23
+ | mapping | ánh xạ | How a field in one system matches a field in another |
24
+ | field | trường | |
25
+ | log | nhật ký | |
26
+ | dashboard | bảng điều khiển | |
27
+ | settings | cài đặt | |
28
+ | account | tài khoản | |
29
+ | store | cửa hàng | |
30
+ | order | đơn hàng | |
31
+ | product | sản phẩm | |
32
+ | customer | khách hàng | |
33
+ | inventory | tồn kho | |
34
+ | invoice | hóa đơn | |
35
+ | schedule | lịch chạy | |
36
+ | connect, disconnect | kết nối, ngắt kết nối | |
37
+ | retry | thử lại | |
38
+ | sign in, sign out | đăng nhập, đăng xuất | Not "log in" or "login" |
39
+
40
+ ## Words to avoid
41
+
42
+ | Avoid | Use instead | Why |
43
+ | --- | --- | --- |
44
+ | click, tap | select | People use a mouse, touch, a keyboard or a screen reader |
45
+ | user, người dùng, quý khách | you, bạn | Speak to the person directly |
46
+ | successfully | the past tense: "saved" | The past tense already says it worked |
47
+ | abort, kill, execute | cancel, stop, run | Plain words, without violence |
48
+ | whitelist, blacklist | allowlist, blocklist | Clearer, and doesn't tie colour to good or bad |
49
+
50
+ ## Adding a term
51
+
52
+ When a new feature needs a name, check this list first. If nothing fits, agree the English and Vietnamese words with the design system team before the feature ships, then add them here.
53
+
54
+ ## Related
55
+
56
+ - [Style and grammar](/foundations/guidelines/content/style-and-grammar/): capitals and proper nouns.
57
+ - [Voice and tone](/foundations/guidelines/content/voice-and-tone/): talking to people.
@@ -0,0 +1,48 @@
1
+ ---
2
+ title: Voice and tone
3
+ description: "Beehexa always sounds clear, direct and calm. The tone changes with the moment: brief when things go well, careful when they go wrong."
4
+ order: 1
5
+ ---
6
+
7
+ Think of a colleague who knows the systems well. When the sync works, they don't make a fuss. When it breaks, they tell you exactly what broke and how to fix it, without blame. That colleague is the Beehexa voice.
8
+
9
+ **Our voice stays the same everywhere. Our tone adapts to how the person feels at that moment.**
10
+
11
+ ## Voice
12
+
13
+ | We are | So we | We are not |
14
+ | --- | --- | --- |
15
+ | Clear | Use plain words and one idea per sentence | Vague or full of jargon |
16
+ | Direct | Lead with the outcome and the next step | Wordy or roundabout |
17
+ | Calm | State facts, even in an error | Alarming, cheerful about problems or overly casual |
18
+ | Helpful | Tell people what they can do now | Only describe what the system did |
19
+
20
+ ## Tone by moment
21
+
22
+ | Moment | How people feel | Tone | Example |
23
+ | --- | --- | --- | --- |
24
+ | First use | Curious, unsure | Welcoming and practical | "Connect your first store to start syncing orders." |
25
+ | Success | Satisfied, busy | Brief, in the past tense | "24 orders synced." |
26
+ | Error | Worried, under pressure | Calm, specific, no blame | "Couldn't sync 3 orders. The online store rejected the request because the access has expired. Reconnect the store to try again." |
27
+ | Destructive action | Careful | Serious and precise | "Delete this workflow? Its schedule and history are deleted too. You can't undo this." |
28
+ | Waiting | Impatient | Honest about time | "Syncing 1,200 products. This can take a few minutes." |
29
+
30
+ ## Talking to people
31
+
32
+ - **Call the person "you".** In Vietnamese, use "bạn". Don't write "the user", "người dùng" or "quý khách" in the product.
33
+ - **Use "we" only for Beehexa itself**, such as "We'll email you when the import finishes." Most messages need neither "you" nor "we".
34
+ - **Don't say "please" in every message.** Keep it for when you ask people to do something extra for us, such as waiting.
35
+ - **Don't apologise for every error.** Say sorry only when Beehexa caused the problem and it costs the person time.
36
+
37
+ ## Do and don't
38
+
39
+ | Do | Don't |
40
+ | --- | --- |
41
+ | "Couldn't connect to the ERP. Check your internet connection and try again." | "Oops! Something went wrong 😕" |
42
+ | "Workflow saved." | "Awesome! Your workflow has been saved successfully!" |
43
+ | "You don't have permission to edit this workflow. Ask an admin for access." | "Error 403: Forbidden." |
44
+
45
+ ## Related
46
+
47
+ - [Messages](/foundations/guidelines/content/messages/): how to write each kind of message.
48
+ - [Style and grammar](/foundations/guidelines/content/style-and-grammar/): capitals, buttons and punctuation.
@@ -4,31 +4,36 @@ description: Words are most of the interface. Write product copy that is clear,
4
4
  order: 2
5
5
  ---
6
6
 
7
- People don't read an interface; they scan it for the next thing to do. Every label, message and empty state either helps them do it or slows them down.
7
+ People don't read an interface; they scan it for the next thing to do. Every label, message and empty state either helps them do it or slows them down. A sync that fails at night is fixed faster when the message says which orders failed and what to do next.
8
8
 
9
- ## Voice
9
+ **Write so a busy person can act after one read.**
10
10
 
11
- Clear, direct and helpful. Write for busy people who manage data across many systems: say what happened and what to do next, in as few words as it takes.
11
+ ## Principles
12
12
 
13
- ## Rules
13
+ - **Clear first.** Use everyday words and short sentences. Many people read Beehexa products in their second language.
14
+ - **Say what to do.** Lead with the outcome or the next action, not with how the system works.
15
+ - **Same word, same thing.** Once a thing has a name, use that name everywhere, in both languages. See [Terms](/foundations/guidelines/content/terms/).
16
+ - **Calm and honest.** Say what happened, even when it is our fault. Don't hide a problem behind a cheerful word.
17
+ - **Words carry the meaning.** Colour and icons support the words; they never replace them.
14
18
 
15
- - Use sentence case for labels, headings and buttons.
16
- - Start buttons with a verb: "Save", "Sync orders", "Delete integration".
17
- - Keep one name for one thing across the product.
18
- - Use numerals for numbers: "3 orders failed".
19
- - Avoid jargon unless your readers use it.
20
- - Write plainly: short sentences, everyday words, one idea at a time. Many people read the product in their second language.
21
- - Write every status in words. Colour and icons support the words; they never replace them.
19
+ ## In this section
22
20
 
23
- ## Messages
21
+ - [Voice and tone](/foundations/guidelines/content/voice-and-tone/): how Beehexa sounds, and how the tone changes when things go well or wrong.
22
+ - [Style and grammar](/foundations/guidelines/content/style-and-grammar/): capitals, buttons, labels, punctuation and links.
23
+ - [Numbers, dates and currency](/foundations/guidelines/content/numbers-dates-and-currency/): how to write amounts, dates and times in English and Vietnamese.
24
+ - [Messages](/foundations/guidelines/content/messages/): errors, warnings, success messages, empty states and confirmations.
25
+ - [Terms](/foundations/guidelines/content/terms/): the words we use for each thing, in English and Vietnamese.
24
26
 
25
- | Type | Write |
27
+ ## Standards behind these rules
28
+
29
+ | Standard | What it covers here |
26
30
  | --- | --- |
27
- | Error | What happened, why, and how to fix it. |
28
- | Empty state | What will appear here and how to add the first item. |
29
- | Confirmation | The action and its consequence: "Delete 3 orders? This can't be undone." |
31
+ | [ISO 24495-1:2023](https://www.iso.org/standard/78907.html), plain language | Write so people can find, understand and use what they need |
32
+ | [WCAG 2.2](https://www.w3.org/TR/WCAG22/) | Headings and labels (2.4.6), link text (2.4.4), labels and instructions (3.3.2), error messages (3.3.1, 3.3.3) |
33
+ | Nghị định 123/2020/NĐ-CP | How numbers and amounts in đồng are written on Vietnamese invoices |
34
+ | [ISO 4217](https://www.iso.org/iso-4217-currency-codes.html) | Currency codes such as VND and USD, and the decimals of each currency |
30
35
 
31
36
  ## Related
32
37
 
33
38
  - [Accessibility](/foundations/guidelines/accessibility/): names for controls, alt text and plain language.
34
- - [Typography usage](/foundations/styles/typography/usage/): text styles, sentence case and long text.
39
+ - [Typography usage](/foundations/styles/typography/usage/): text styles and long text.
@@ -12,11 +12,6 @@ Borders draw the edges people rely on: where a field starts, where one card ends
12
12
 
13
13
  Border colours are colour tokens: `color.border` for dividers and cards, `color.border.bold` for the edges of inputs, checkboxes and selects. See [Tokens](/foundations/styles/color/tokens/#borders).
14
14
 
15
- An interactive bordered card keeps its frame on hover: strengthen it to
16
- `color.border.bold` and add `elevation.shadow.raised`, never transparency or a
17
- fading border. Keyboard focus adds the existing focus ring without removing the
18
- frame. Cards and callouts use `radius.100` (8 px).
19
-
20
15
  ## The widths
21
16
 
22
17
  <ShapeDemo kind="border-scale" />
@@ -92,5 +87,5 @@ Don't show a state with colour alone. Selected and focused also change the width
92
87
 
93
88
  ## Related
94
89
 
95
- - [Radius](/foundations/styles/radius/): corner role steps and functional geometry.
90
+ - [Radius](/foundations/styles/radius/): corner radius steps and the nesting rule.
96
91
  - [Interaction states](/foundations/styles/interaction-states/): hover, pressed, selected and disabled.
@@ -13,10 +13,70 @@ Many people switch to dark mode at night, and some prefer it all day. Supporting
13
13
 
14
14
  Every colour token has a light and a dark value under the same name. The theme picks the value; your code and designs name the token once. The dark values of every palette step are on [Palette](/foundations/styles/color/palette/), and every role token's are on [Tokens](/foundations/styles/color/tokens/).
15
15
 
16
- ## Designing for dark
16
+ ## Turn it on in code
17
+
18
+ **Follow the reader's system setting, let them change it, and remember their choice.**
19
+
20
+ The token CSS (`@beehexa/design-tokens/css`) already holds both themes. It picks the dark values in two cases:
21
+
22
+ | Case | What decides the theme |
23
+ |---|---|
24
+ | `data-theme="dark"` on `<html>` | Your product: the reader chose dark |
25
+ | No `data-theme`, and the system is dark | The reader's system setting (`prefers-color-scheme: dark`) |
26
+
27
+ `data-theme="light"` keeps the light values even when the system is dark.
28
+
29
+ Set the theme before the page draws, in a small script in `<head>`, so the page doesn't flash light first:
30
+
31
+ ```html
32
+ <script>
33
+ let theme = localStorage.getItem('bh-theme');
34
+ if (theme !== 'light' && theme !== 'dark') {
35
+ theme = matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';
36
+ }
37
+ document.documentElement.dataset.theme = theme;
38
+ </script>
39
+ ```
40
+
41
+ - Set `color-scheme` to match (`color-scheme: dark` under `[data-theme='dark']`), so scrollbars, form controls and the browser's own UI follow the theme.
42
+ - Put the theme switch in the header. Save the choice only when the reader picks one; until then, follow the system.
43
+ - A part that must keep one theme whatever the page uses, such as a fixed preview, takes the class `bh-scope-light` or `bh-scope-dark`.
44
+ - Charts, code editors and anything else that needs colour values instead of CSS variables must redraw when the theme changes.
45
+
46
+ ## Surfaces and shadows
47
+
48
+ **In light, shadows separate the levels. In dark, the background gets lighter as the surface rises, and the shadow gets stronger.**
49
+
50
+ | Level | Light | Dark |
51
+ |---|---|---|
52
+ | Page (`color.surface.page`) | White | Graphite 1, the darkest |
53
+ | Card (`color.surface`), `elevation.shadow.raised` | White, faint graphite shadow | Graphite 2, black shadow at 40% and 30% |
54
+ | Menu, popover, dialog (`color.surface.overlay`), `elevation.shadow.overlay` and `.modal` | White, graphite shadow at 15% | Graphite 3, black shadow at 50% |
55
+
56
+ Dark mode adds no border to show a level. Rows in menus and popovers use the overlay state colours, such as `color.surface.overlay.hover`. See [Elevation](/foundations/styles/elevation/#dark-mode).
57
+
58
+ ## Colours that change more
59
+
60
+ - The primary button turns light with dark text. That is intended, not a reason to make it blue.
61
+ - Solid status fills get brighter, with dark text on them (`color.text.on-bold`).
62
+ - Hover and pressed fills get lighter instead of darker. The state tokens already do this; see [Interaction states](/foundations/styles/interaction-states/#dark-mode).
63
+
64
+ ## Images and logos
65
+
66
+ - Logos use their dark-background versions: the wordmark turns white, the yellow mark stays. See [Logos](/foundations/styles/logos/).
67
+ - Give screenshots and illustrations a version for each theme. If an image has only a light version, put it on a light frame (`bh-scope-light`) instead of on the dark page.
68
+ - Don't invert images or change them with CSS filters. Colours shift and brand colours break.
69
+ - An image of something turned off fades the same way in both themes (`opacity.disabled`); see [Opacity](/foundations/styles/opacity/).
70
+
71
+ ## Check before release
72
+
73
+ - Every screen in both themes, including empty, loading and error states.
74
+ - No colour written by hand and none picked by theme in code. Every colour is a token.
75
+ - Text, icons and borders pass contrast in both themes. The token pairs are checked already; check anything you place on an image.
76
+ - The focus ring is visible on every surface.
77
+ - Menus, popovers and dialogs stand out from the card under them.
78
+ - Charts read in both themes, and no series disappears into the background.
79
+ - Logos, screenshots and illustrations have their dark versions or sit on a light frame.
80
+ - Scrollbars and form controls follow the theme (`color-scheme`).
81
+ - The theme switch works with the keyboard, and the choice is remembered after reload.
17
82
 
18
- - Never write a dark colour of your own or pick colours by theme in code.
19
- - Surfaces get lighter as they rise: page darkest, cards one step lighter.
20
- - The primary button turns light, and the solid status fills get brighter with dark text on them.
21
- - Check every screen in both themes before release.
22
- - Logos use their dark-background versions (see [Logos](/foundations/styles/logos/)).
@@ -18,7 +18,8 @@ Every colour on a screen answers two questions: what is this, and what does it m
18
18
  | Page background | `surface.page` |
19
19
  | Card, panel | `surface`, edge `border` |
20
20
  | Menu, popover, dialog, drawer | `surface.overlay`; items inside use `surface.overlay.hover`, `.pressed`, `.selected` |
21
- | Global header and sidebar (same shell surface), mobile navigation drawer, table header, quiet area | `surface.subtle` |
21
+ | App header and side navigation | `surface.page`, edge `border` |
22
+ | Table header, quiet area | `surface.subtle` |
22
23
  | Body text, headings, labels | `text` |
23
24
  | Descriptions, secondary table columns, navigation | `text.subtle` |
24
25
  | Metadata, timestamps, helper text, breadcrumbs | `text.subtlest` |
@@ -41,7 +42,7 @@ Every colour on a screen answers two questions: what is this, and what does it m
41
42
  | Chip: a filter or a picked value | `border.bold`, `text` on `surface`, remove icon `icon.subtle`; when on, `background.selected` and `border.selected` |
42
43
  | Tooltip | `surface.inverse`, `text.inverse` |
43
44
  | Toast | `surface.overlay`, `text`, `icon.{role}`, shadow `elevation.shadow.overlay`; no border |
44
- | Switch | Paired `switch.on.{track,thumb,label,border}` / `switch.off.{track,thumb,label,border}`; ON is neutral-bold, OFF has a strong thumb and meaningful edge, not disabled paint. See [interaction states](/foundations/styles/interaction-states/#boolean-switch). |
45
+ | Switch | `switch.on.*`: track `background.neutral.bold`, thumb `icon.inverse`. `switch.off.*`: track `background.neutral`, edge `border.bold`, thumb `icon`. See [Switch](/components/switch/usage/) |
45
46
  | Avatar with initials | `background.neutral`, `text` |
46
47
  | Step number, count | `background.neutral.bold`, `text.inverse` |
47
48
  | Layer behind a dialog or drawer | `surface.scrim` |
@@ -95,7 +96,7 @@ Warning is orange, not yellow: yellow is the brand. There is no sixth level; say
95
96
  | | Label | State label |
96
97
  |---|---|---|
97
98
  | Looks | Outline in the role's `border`, text in its `text` | Fill in the role's `bold`, text and icon in `text.on-bold` |
98
- | Size | 20 px, padding 6 px; large 24 px, 8 px | 32 px, padding 12 px |
99
+ | Size | 20 px, padding 6 px; large 24 px, 8 px (`label.height.*`, `label.padding.*`) | 32 px, padding 12 px (`label.height.state`, `label.padding.state`) |
99
100
  | Use | Many per screen: status in table rows and lists | One per page: the status the page is about |
100
101
 
101
102
  ### Label, tag or chip
@@ -111,8 +112,7 @@ Three small elements that look alike but do different jobs. Choose by what peopl
111
112
  | People can | Only read it | Read it, or click it to filter when it links | Remove it, or turn it on and off |
112
113
  | States | None | Default; hover and focus only when it links | Default, hover, focus, selected, disabled |
113
114
  | Colour | The status role's `border` and `text` | `border` and `text` on `surface` | `border.bold` and `text` on `surface`; when on, `background.selected` and `border.selected` |
114
- | Size | 20 px, or 24 px large (see above) | 24 px, padding 8 px | 24 px in dense toolbars, 32 px elsewhere |
115
- | Radius | `radius.050` (4 px) | `radius.050` (4 px) | `radius.pill` (`radius.full`) |
115
+ | Size | 20 px, or 24 px large (see above) | 24 px, padding 8 px (`tag.height`, `tag.padding`) | 24 px in dense toolbars, 32 px elsewhere (`chip.height.small`, `.default`) |
116
116
 
117
117
  - A label never looks clickable: no hover, no pointer, no remove button.
118
118
  - A tag never has a remove button. Once it does, it is a chip.
@@ -35,8 +35,8 @@ Use `visualization.line-width`, `sparkline-width`, `grid-width`, `point-radius`
35
35
  and `hover-point-radius` for SVG series and markers. Strokes are CSS pixel
36
36
  dimensions; use a measured viewBox or non-scaling strokes to avoid distortion.
37
37
  `timeline-track-height` and `activity-track-height` set compact proportional tracks.
38
- `ring-size` is a CSS dimension; `ring-width` is the Ant Design percent-based stroke
39
- API, and `ring-gap` is degrees. Convert dimensions only at numeric API boundaries.
38
+ `ring-size` is a CSS dimension; `ring-width` is a percentage of the ring size,
39
+ and `ring-gap` is degrees. Convert dimensions only at numeric API boundaries.
40
40
  Data coordinates and measured container sizes remain data, not design tokens.
41
41
 
42
42
  `timeline-node-size` and `timeline-node-inner-size` define the outer categorical and
@@ -77,79 +77,3 @@ dash pattern and explicit labels, not colour alone. Unavailable means no request
77
77
  to assess. Fault means internal/backend request-processing errors, not a ratio band;
78
78
  show a separate fault count, explicit label/icon and cross-hatching. Fetch failures remain errors, not a band. Never turn missing
79
79
  data into zero or a healthy result. Use normal `color.text` for text on subtle fills.
80
-
81
- ## Source-owned presentation boundaries
82
-
83
- Semantic data does not authorize a local CSS recipe. Prefer a source-configured
84
- native chart, Progress, Tag or Timeline API when it can preserve the required
85
- structure, behavior and accessibility. Custom SVG/data DOM uses the companion
86
- `@beehexa/ant-design-vue-tokens/css` source recipes:
87
-
88
- - `bh-data-track` and `bh-data-fill` own proportional track presentation.
89
- Default thickness is `timeline-track-height`; `data-bh-density="activity"` uses
90
- `activity-track-height`. Coordinates, measured widths and percentages remain data.
91
- - `bh-data-band` is a labeled assessment chip; `bh-data-accent` is a leading
92
- semantic edge; `bh-data-mark` applies the source mark foreground.
93
- - `bh-data-line`, `bh-data-point`, `bh-data-grid`, `bh-data-axis`,
94
- `bh-data-outline` and `bh-data-hatch` own SVG paint/stroke roles.
95
- `data-bh-density="sparkline"` selects the compact series/point geometry.
96
- Dash/hatch geometry may encode distinct data classes, never decorative effects.
97
- - `bh-data-tooltip` owns the source paired tooltip canvas and typography;
98
- the host preserves containment, positioning and equivalent numeric content.
99
-
100
- Bind a source semantic discriminator at the relevant host or mark:
101
- `data-bh-band="good|attention|critical"` maps health assessments to
102
- success/warning/danger pairs; `data-bh-status="success|warning|danger|info|neutral|disabled"`
103
- describes an actual operational state. Threshold classification remains domain
104
- logic and must be explicit in labels; these attributes never calculate a score.
105
- `data-bh-traffic` uses the six traffic bands above. `data-bh-metric`,
106
- `data-bh-job-type` and `data-bh-priority` use the exact named source keys.
107
- Private `--bh-data-*` properties belong to these recipes, not consumer aliases.
108
-
109
- Native APIs requiring resolved color values use
110
- `getVisualizationColor(role, { dark })` or
111
- `getStatusColor(tone, 'text' | 'border' | 'background', { dark })` from
112
- `@beehexa/ant-design-vue-tokens/visualization`. Keep the mode reactive.
113
- The caller classifies domain outcomes; source owns the corresponding paint.
114
- Do not recreate a downstream color map, including token-string maps.
115
-
116
- ### Focus, selection and temporal marks
117
-
118
- `bh-data-hit-target` owns the transparent SVG hit area and visible keyboard-focus
119
- stroke; geometry and domain hit interval remain consumer data. A selected region uses
120
- `bh-data-outline` with `data-bh-shape="selection"` for its no-fill selected frame and
121
- `bh-data-point` with the same attribute for a selected marker. Selection is not focus.
122
- `bh-data-grid[data-bh-current="true"]` marks the current time; `bh-data-axis-tick`
123
- owns a gauge tick's paint while the consumer positions it on the scale.
124
-
125
- Timeline marks use `bh-data-mark` with `data-bh-mark="timeline-outer|timeline-inner|cluster"`.
126
- The outer category and inner execution state are independent encodings. Source defaults
127
- are16/8px for the two diameters; coarse-pointer marks use18/10px. A cluster's minimum
128
- diameter is24px. Hit targets remain distinct from these visible marks.
129
- `data-bh-mark="legend|dot"` uses the source8px circular mark; a hidden series label's
130
- `data-bh-hidden="true"` adds a strike cue rather than changing its meaning through
131
- opacity alone. `data-bh-selected="true"` adds a separate selected outline.
132
-
133
- `bh-data-line[data-bh-line="hover"]` owns the hover guide dash pattern; source
134
- `bh-data-grid` owns grid dashes, and `data-bh-curve="step"` owns a stepped line's
135
- join. Use source point roles for sparkline endpoints rather than local radius paint.
136
- `bh-data-connector` describes a relationship between progress items; status is explicit
137
- and `data-bh-skipped="true"` adds a dashed cue. Prefer native Steps/Progress when they
138
- can preserve the actual structure. The connector recipe exists for split-edge layouts
139
- whose paired half-connectors cannot be represented by those native APIs.
140
-
141
-
142
- `bh-data-area` fills an SVG area without adding an outline, including a hatch
143
- pattern canvas. `bh-data-swatch` owns the source12px square legend, frame and
144
- paired fill; source `data-bh-traffic="degraded"` supplies a dashed outline both
145
- for a swatch and for `bh-data-outline` intervals. Fault remains a cross-hatch,
146
- not merely another color. Pattern coordinates and domain intervals remain data.
147
-
148
-
149
- Actual native Progress accepts `semanticProgressProps` from
150
- `@beehexa/ant-design-vue-tokens/visualization`, together with the appropriate
151
- `data-bh-band` or `data-bh-status` discriminator. These are native stroke/trail
152
- props using source CSS variables, reactive across themes without a downstream
153
- color map or a new theme-store dependency. Use native Progress/Steps/Tag/Statistic
154
- instead of recreating their tracks, connectors, pills or figures in HTML.
155
-