@ensi-platform/admin-ui 0.13.2 → 0.14.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 (221) hide show
  1. package/dist/Component--pn4mDeS.js +870 -0
  2. package/dist/Component--pn4mDeS.js.map +1 -0
  3. package/dist/{Component-BhZC1r4b.js → Component-BJz78zCJ.js} +2 -2
  4. package/dist/{Component-BhZC1r4b.js.map → Component-BJz78zCJ.js.map} +1 -1
  5. package/dist/{Component-DV6H96-0.js → Component-BbslNbTq.js} +2 -2
  6. package/dist/{Component-DV6H96-0.js.map → Component-BbslNbTq.js.map} +1 -1
  7. package/dist/{Component-B6OSgrmp.js → Component-COgt_U9z.js} +3 -3
  8. package/dist/{Component-B6OSgrmp.js.map → Component-COgt_U9z.js.map} +1 -1
  9. package/dist/{Component-kqMyROjC.js → Component-DHBQ3LMI.js} +2 -2
  10. package/dist/{Component-kqMyROjC.js.map → Component-DHBQ3LMI.js.map} +1 -1
  11. package/dist/{Component-BoAQ166N.js → Component-DrdEP1wD.js} +3 -3
  12. package/dist/{Component-BoAQ166N.js.map → Component-DrdEP1wD.js.map} +1 -1
  13. package/dist/{Component-CMdJyqc-.js → Component-Qhj0uSjq.js} +2 -2
  14. package/dist/{Component-CMdJyqc-.js.map → Component-Qhj0uSjq.js.map} +1 -1
  15. package/dist/{Component-CiwX3wP8.js → Component-Zja2mwzK.js} +2 -2
  16. package/dist/{Component-CiwX3wP8.js.map → Component-Zja2mwzK.js.map} +1 -1
  17. package/dist/{Component-CS-9-L8S.js → Component-_PP1i9V1.js} +3 -3
  18. package/dist/{Component-CS-9-L8S.js.map → Component-_PP1i9V1.js.map} +1 -1
  19. package/dist/{Component-BBzbDcdq.js → Component-yeVZUFid.js} +2 -2
  20. package/dist/{Component-BBzbDcdq.js.map → Component-yeVZUFid.js.map} +1 -1
  21. package/dist/{Search-CS1rsu-f.js → Search-dQa9wT3n.js} +3 -3
  22. package/dist/{Search-CS1rsu-f.js.map → Search-dQa9wT3n.js.map} +1 -1
  23. package/dist/Star-JBCU7DBD.js +28 -0
  24. package/dist/Star-JBCU7DBD.js.map +1 -0
  25. package/dist/action-popup/index.js +2 -2
  26. package/dist/active-filters/index.js +1 -1
  27. package/dist/arrangement-settings/index.js +2 -2
  28. package/dist/assets/Component16.css +1 -1
  29. package/dist/assets/index.css +1 -1
  30. package/dist/assets/index27.css +1 -1
  31. package/dist/assets/index28.css +1 -1
  32. package/dist/assets/index29.css +1 -1
  33. package/dist/assets/index30.css +1 -1
  34. package/dist/assets/index31.css +1 -1
  35. package/dist/assets/index32.css +1 -1
  36. package/dist/assets/index33.css +1 -1
  37. package/dist/assets/index34.css +1 -1
  38. package/dist/assets/index35.css +1 -0
  39. package/dist/autocomplete/index.js +1 -1
  40. package/dist/autocomplete-async/Component.d.ts.map +1 -1
  41. package/dist/autocomplete-async/index.js +98 -92
  42. package/dist/autocomplete-async/index.js.map +1 -1
  43. package/dist/bottom-sheet/index.js +2 -2
  44. package/dist/cascade-menu/index.js +4 -4
  45. package/dist/color-field/index.js +2 -2
  46. package/dist/color-picker/index.js +1 -1
  47. package/dist/combobox/components/Trigger/index.d.ts +1 -0
  48. package/dist/combobox/components/Trigger/index.d.ts.map +1 -1
  49. package/dist/combobox/index.d.ts +1 -1
  50. package/dist/combobox/index.d.ts.map +1 -1
  51. package/dist/combobox/index.js +15 -14
  52. package/dist/copy-button/index.js +1 -1
  53. package/dist/data-table/Component.d.ts +1 -1
  54. package/dist/data-table/index.js +2 -2
  55. package/dist/date-picker/index.js +2 -2
  56. package/dist/date-range-picker/index.js +2 -2
  57. package/dist/drawer/index.js +1 -1
  58. package/dist/dropzone/index.js +2 -2
  59. package/dist/{hooks-Di5rgHTG.js → hooks-BSSTu-2y.js} +3 -2
  60. package/dist/{hooks-Di5rgHTG.js.map → hooks-BSSTu-2y.js.map} +1 -1
  61. package/dist/icons/AlignCenter.d.ts +7 -0
  62. package/dist/icons/AlignCenter.d.ts.map +1 -0
  63. package/dist/icons/AlignJustify.d.ts +7 -0
  64. package/dist/icons/AlignJustify.d.ts.map +1 -0
  65. package/dist/icons/AlignLeft.d.ts +7 -0
  66. package/dist/icons/AlignLeft.d.ts.map +1 -0
  67. package/dist/icons/AlignRight.d.ts +7 -0
  68. package/dist/icons/AlignRight.d.ts.map +1 -0
  69. package/dist/icons/Anchor.d.ts +7 -0
  70. package/dist/icons/Anchor.d.ts.map +1 -0
  71. package/dist/icons/Bold.d.ts +7 -0
  72. package/dist/icons/Bold.d.ts.map +1 -0
  73. package/dist/icons/Code.d.ts +7 -0
  74. package/dist/icons/Code.d.ts.map +1 -0
  75. package/dist/icons/HorizontalRule.d.ts +7 -0
  76. package/dist/icons/HorizontalRule.d.ts.map +1 -0
  77. package/dist/icons/Indent.d.ts +7 -0
  78. package/dist/icons/Indent.d.ts.map +1 -0
  79. package/dist/icons/Italic.d.ts +7 -0
  80. package/dist/icons/Italic.d.ts.map +1 -0
  81. package/dist/icons/Link.d.ts +7 -0
  82. package/dist/icons/Link.d.ts.map +1 -0
  83. package/dist/icons/List.d.ts +7 -0
  84. package/dist/icons/List.d.ts.map +1 -0
  85. package/dist/icons/ListOrdered.d.ts +7 -0
  86. package/dist/icons/ListOrdered.d.ts.map +1 -0
  87. package/dist/icons/Maximize.d.ts +7 -0
  88. package/dist/icons/Maximize.d.ts.map +1 -0
  89. package/dist/icons/Outdent.d.ts +7 -0
  90. package/dist/icons/Outdent.d.ts.map +1 -0
  91. package/dist/icons/Palette.d.ts +7 -0
  92. package/dist/icons/Palette.d.ts.map +1 -0
  93. package/dist/icons/Quote.d.ts +7 -0
  94. package/dist/icons/Quote.d.ts.map +1 -0
  95. package/dist/icons/Redo.d.ts +7 -0
  96. package/dist/icons/Redo.d.ts.map +1 -0
  97. package/dist/icons/Smile.d.ts +7 -0
  98. package/dist/icons/Smile.d.ts.map +1 -0
  99. package/dist/icons/Star.d.ts +7 -0
  100. package/dist/icons/Star.d.ts.map +1 -0
  101. package/dist/icons/Strike.d.ts +7 -0
  102. package/dist/icons/Strike.d.ts.map +1 -0
  103. package/dist/icons/Subscript.d.ts +7 -0
  104. package/dist/icons/Subscript.d.ts.map +1 -0
  105. package/dist/icons/Superscript.d.ts +7 -0
  106. package/dist/icons/Superscript.d.ts.map +1 -0
  107. package/dist/icons/Table.d.ts +7 -0
  108. package/dist/icons/Table.d.ts.map +1 -0
  109. package/dist/icons/Underline.d.ts +7 -0
  110. package/dist/icons/Underline.d.ts.map +1 -0
  111. package/dist/icons/Undo.d.ts +7 -0
  112. package/dist/icons/Undo.d.ts.map +1 -0
  113. package/dist/icons/Video.d.ts +7 -0
  114. package/dist/icons/Video.d.ts.map +1 -0
  115. package/dist/icons/index.d.ts +27 -0
  116. package/dist/icons/index.d.ts.map +1 -1
  117. package/dist/icons/index.js +709 -177
  118. package/dist/icons/index.js.map +1 -1
  119. package/dist/{index-Co6mzXrw.js → index-CYUeRS10.js} +3 -3
  120. package/dist/{index-Co6mzXrw.js.map → index-CYUeRS10.js.map} +1 -1
  121. package/dist/index-Rx06m88a.js +101 -0
  122. package/dist/index-Rx06m88a.js.map +1 -0
  123. package/dist/{index-BAFoUNz-.js → index-o14ps46j.js} +2 -2
  124. package/dist/{index-BAFoUNz-.js.map → index-o14ps46j.js.map} +1 -1
  125. package/dist/input/index.js +1 -1
  126. package/dist/loader/index.js +1 -1
  127. package/dist/mask/index.js +1 -1
  128. package/dist/menu-list/index.js +1 -1
  129. package/dist/{metrics-CaN_sENu.js → metrics-D4vChkd-.js} +2 -2
  130. package/dist/{metrics-CaN_sENu.js.map → metrics-D4vChkd-.js.map} +1 -1
  131. package/dist/modal/index.js +1 -1
  132. package/dist/multi-autocomplete/index.js +1 -1
  133. package/dist/multi-autocomplete-async/index.js +1 -1
  134. package/dist/multi-select/index.js +2 -2
  135. package/dist/number-input/index.js +1 -1
  136. package/dist/number-range/index.js +1 -1
  137. package/dist/password/index.js +2 -2
  138. package/dist/provider/context.d.ts.map +1 -1
  139. package/dist/provider/index.js +2 -2
  140. package/dist/provider/types.d.ts +2 -0
  141. package/dist/provider/types.d.ts.map +1 -1
  142. package/dist/rating/Component.d.ts +5 -0
  143. package/dist/rating/Component.d.ts.map +1 -0
  144. package/dist/rating/FormRating.d.ts +6 -0
  145. package/dist/rating/FormRating.d.ts.map +1 -0
  146. package/dist/rating/components/Star/index.d.ts +14 -0
  147. package/dist/rating/components/Star/index.d.ts.map +1 -0
  148. package/dist/rating/components/Star/theme.d.ts +5 -0
  149. package/dist/rating/components/Star/theme.d.ts.map +1 -0
  150. package/dist/rating/components/Track/index.d.ts +41 -0
  151. package/dist/rating/components/Track/index.d.ts.map +1 -0
  152. package/dist/rating/index.d.ts +4 -0
  153. package/dist/rating/index.d.ts.map +1 -0
  154. package/dist/rating/index.js +361 -0
  155. package/dist/rating/index.js.map +1 -0
  156. package/dist/rating/theme.d.ts +5 -0
  157. package/dist/rating/theme.d.ts.map +1 -0
  158. package/dist/rating/types.d.ts +56 -0
  159. package/dist/rating/types.d.ts.map +1 -0
  160. package/dist/rating/utils.d.ts +11 -0
  161. package/dist/rating/utils.d.ts.map +1 -0
  162. package/dist/select/index.js +1 -1
  163. package/dist/suggest-checklist/index.js +3 -3
  164. package/dist/table/Component.d.ts +3 -3
  165. package/dist/table/components/Cell/index.d.ts +1 -1
  166. package/dist/table/components/Cell/index.d.ts.map +1 -1
  167. package/dist/table/components/Cell/theme.d.ts +1 -0
  168. package/dist/table/components/Cell/theme.d.ts.map +1 -1
  169. package/dist/table/components/CheckboxCell/index.d.ts.map +1 -1
  170. package/dist/table/components/HeaderCell/index.d.ts +1 -1
  171. package/dist/table/components/HeaderCell/index.d.ts.map +1 -1
  172. package/dist/table/components/HeaderCell/theme.d.ts +1 -0
  173. package/dist/table/components/HeaderCell/theme.d.ts.map +1 -1
  174. package/dist/table/components/HeaderCheckboxCell/index.d.ts.map +1 -1
  175. package/dist/table/components/Row/index.d.ts +1 -1
  176. package/dist/table/components/Row/index.d.ts.map +1 -1
  177. package/dist/table/components/Row/types.d.ts +6 -0
  178. package/dist/table/components/Row/types.d.ts.map +1 -1
  179. package/dist/table/components/TableElement/index.d.ts.map +1 -1
  180. package/dist/table/hooks/useTablePin.d.ts +6 -0
  181. package/dist/table/hooks/useTablePin.d.ts.map +1 -0
  182. package/dist/table/index.js +1 -1
  183. package/dist/table/types.d.ts +5 -1
  184. package/dist/table/types.d.ts.map +1 -1
  185. package/dist/table/utils.d.ts +45 -1
  186. package/dist/table/utils.d.ts.map +1 -1
  187. package/dist/tabs/index.js +1 -1
  188. package/dist/tag/index.js +1 -1
  189. package/dist/textarea/index.js +1 -1
  190. package/dist/time-field/index.js +1 -1
  191. package/dist/toast/index.js +2 -2
  192. package/dist/typography/index.js +1 -1
  193. package/dist/{utils-qHAuIhao.js → utils-Dfp1NDWx.js} +3 -3
  194. package/dist/{utils-qHAuIhao.js.map → utils-Dfp1NDWx.js.map} +1 -1
  195. package/dist/vertical-tabs/index.js +1 -1
  196. package/docs/design-language.md +14 -13
  197. package/package.json +5 -1
  198. package/src/autocomplete/docs/Description.md +2 -0
  199. package/src/autocomplete-async/docs/Description.md +1 -1
  200. package/src/badge/docs/cssVariables.ts +3 -3
  201. package/src/bottom-sheet/docs/cssVariables.ts +1 -1
  202. package/src/cascade-menu/docs/cssVariables.ts +7 -7
  203. package/src/data-table/docs/Description.md +2 -1
  204. package/src/ds/tokens/docs/Description.md +2 -1
  205. package/src/link/docs/cssVariables.ts +1 -1
  206. package/src/provider/docs/cssVariables.ts +1 -1
  207. package/src/provider/types.ts +2 -0
  208. package/src/rating/docs/Description.md +47 -0
  209. package/src/rating/docs/Example.md +9 -0
  210. package/src/rating/docs/cssVariables.ts +14 -0
  211. package/src/rating/types.ts +69 -0
  212. package/src/table/docs/Description.md +10 -8
  213. package/src/table/docs/Example.md +22 -5
  214. package/src/table/docs/cssVariables.ts +8 -3
  215. package/src/table/types.ts +6 -1
  216. package/src/toast/docs/cssVariables.ts +4 -4
  217. package/src/tooltip/docs/cssVariables.ts +2 -2
  218. package/dist/Component-DmKmX7so.js +0 -712
  219. package/dist/Component-DmKmX7so.js.map +0 -1
  220. package/dist/index-BHUJOcwj.js +0 -85
  221. package/dist/index-BHUJOcwj.js.map +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ensi-platform/admin-ui",
3
- "version": "0.13.2",
3
+ "version": "0.14.0",
4
4
  "description": "Admin UI for Ensi admin panel",
5
5
  "type": "module",
6
6
  "sideEffects": [
@@ -237,6 +237,10 @@
237
237
  "types": "./dist/provider/index.d.ts",
238
238
  "import": "./dist/provider/index.js"
239
239
  },
240
+ "./rating": {
241
+ "types": "./dist/rating/index.d.ts",
242
+ "import": "./dist/rating/index.js"
243
+ },
240
244
  "./select": {
241
245
  "types": "./dist/select/index.d.ts",
242
246
  "import": "./dist/select/index.js"
@@ -34,6 +34,8 @@ import { Autocomplete, FormAutocomplete } from '@ensi-platform/admin-ui/autocomp
34
34
  | `block` | `boolean` | — | full width |
35
35
  | `dataTestId` | `string` | — | `data-test-id` for tests |
36
36
 
37
+ A click on the field opens the list. A second click leaves it open.
38
+
37
39
  ### FormAutocomplete
38
40
 
39
41
  | Prop | Values | Default | Description |
@@ -50,7 +50,7 @@ Pass a stable module hook reference (not inline or conditional).
50
50
  | `block` | `boolean` | — | full width |
51
51
  | `dataTestId` | `string` | — | `data-test-id` for tests |
52
52
 
53
- Editing the text does not clear `value`. Blur restores the selected label.
53
+ Backspace keeps the typed remainder and does not change `value`. Tab and one Escape restore the selected label without `onChange`. A click on another option changes `value`. A click on the field opens the list.
54
54
 
55
55
  No external `options` / `isLoading`.
56
56
 
@@ -2,11 +2,11 @@
2
2
  export const docsCssVariables = `/* CSS variables — Badge (--aui-badge-*) */
3
3
  --aui-badge-bg-neutral: var(--aui-surface-bg-muted); /* neutral fill */
4
4
  --aui-badge-fg-neutral: var(--aui-page-fg-primary); /* neutral foreground */
5
- --aui-badge-bg-success: var(--aui-green-50); /* success fill */
5
+ --aui-badge-bg-success: color-mix(in srgb, var(--aui-green-700) 22%, var(--aui-surface-bg-primary)); /* success fill */
6
6
  --aui-badge-fg-success: var(--aui-green-700); /* success foreground */
7
- --aui-badge-bg-warning: var(--aui-yellow-50); /* warning fill */
7
+ --aui-badge-bg-warning: color-mix(in srgb, var(--aui-yellow-700) 22%, var(--aui-surface-bg-primary)); /* warning fill */
8
8
  --aui-badge-fg-warning: var(--aui-yellow-700); /* warning foreground */
9
- --aui-badge-bg-danger: var(--aui-red-50); /* danger fill */
9
+ --aui-badge-bg-danger: color-mix(in srgb, var(--aui-red-700) 22%, var(--aui-surface-bg-primary)); /* danger fill */
10
10
  --aui-badge-fg-danger: var(--aui-red-700); /* danger foreground */
11
11
  --aui-badge-bg-info: var(--aui-badge-bg-neutral); /* info fill = neutral */
12
12
  --aui-badge-fg-info: var(--aui-badge-fg-neutral); /* info foreground = neutral */
@@ -24,7 +24,7 @@ export const docsCssVariables = `/* CSS variables — BottomSheet (--aui-bottom-
24
24
  --aui-bottom-sheet-handle-w-md: var(--aui-spacing-48); /* drag handle w md */
25
25
  --aui-bottom-sheet-handle-h-md: var(--aui-spacing-4); /* drag handle h md */
26
26
  --aui-bottom-sheet-handle-radius-md: var(--aui-radius-4); /* drag handle radius md */
27
- --aui-bottom-sheet-handle-bg-primary: var(--aui-grey-300); /* drag handle bg primary */
27
+ --aui-bottom-sheet-handle-bg-primary: var(--aui-surface-bg-muted-active); /* drag handle bg primary */
28
28
 
29
29
  --aui-bottom-sheet-close-size-sm: var(--aui-spacing-16); /* close button size sm */
30
30
  --aui-bottom-sheet-close-hit-sm: var(--aui-spacing-32); /* close button hit sm */
@@ -1,10 +1,10 @@
1
1
  export const docsCssVariables = `/* CSS variables — CascadeMenu (--aui-cascade-menu-*)
2
- * Light/default values below (semantic.css). Dark remap: black-900 / grey-700 in semantic.dark.css.
2
+ * Light/default values below (semantic.css). Dark remaps page, surface, and control only.
3
3
  */
4
- --aui-cascade-menu-bg-primary: var(--aui-neutral-50); /* L0 — off-white in light, page black in dark */
4
+ --aui-cascade-menu-bg-primary: var(--aui-page-bg-subtle); /* L0 — matches the page; the divider is the edge */
5
5
  --aui-cascade-menu-fg-primary: var(--aui-page-fg-primary); /* primary text / logo currentColor */
6
6
  --aui-cascade-menu-fg-muted: var(--aui-page-fg-muted); /* secondary text on L0 */
7
- --aui-cascade-menu-border-divider: var(--aui-surface-border-primary); /* footer / edges / L0+flyout border-right; dark = white 12% */
7
+ --aui-cascade-menu-border-divider: var(--aui-surface-border-primary); /* footer / edges / L0+flyout border-right */
8
8
  --aui-cascade-menu-border-focus: var(--aui-control-border-focus); /* focus / resize hover */
9
9
  --aui-cascade-menu-w-md: 280px; /* default L0 width token (resize 200–400) */
10
10
  --aui-cascade-menu-w-collapsed: 64px; /* collapsed rail width */
@@ -21,11 +21,11 @@ export const docsCssVariables = `/* CSS variables — CascadeMenu (--aui-cascade
21
21
  --aui-cascade-menu-user-pad-y-md: var(--aui-spacing-12); /* footer top pad */
22
22
  --aui-cascade-menu-handle-w: 4px; /* resize line width */
23
23
  --aui-cascade-menu-handle-delay: 400ms; /* hover dwell before the resize line thickens; drag skips it */
24
- --aui-cascade-menu-item-bg-hover: var(--aui-surface-bg-muted); /* L0 item / user / collapse hover; dark = grey-700 */
24
+ --aui-cascade-menu-item-bg-hover: var(--aui-surface-bg-muted); /* L0 item / user / collapse hover */
25
25
  --aui-cascade-menu-item-bg-active: transparent; /* current leaf — no fill (breadcrumbs own “where am I”) */
26
- --aui-cascade-menu-item-bg-active-hover: var(--aui-surface-bg-muted); /* current leaf hover = same as hover; dark = grey-700 */
27
- --aui-cascade-menu-item-bg-open: var(--aui-surface-bg-muted); /* open folder / path fill; dark = grey-700 */
28
- --aui-cascade-menu-item-bg-open-hover: var(--aui-surface-bg-muted-hover); /* open folder hover; dark = white 8% on grey-700 */
26
+ --aui-cascade-menu-item-bg-active-hover: var(--aui-surface-bg-muted); /* current leaf hover = same as hover */
27
+ --aui-cascade-menu-item-bg-open: var(--aui-surface-bg-muted); /* open folder / path fill */
28
+ --aui-cascade-menu-item-bg-open-hover: var(--aui-surface-bg-muted-hover); /* open folder hover */
29
29
  --aui-cascade-menu-nested-bg: var(--aui-cascade-menu-bg-primary); /* flyout fill = L0 chrome */
30
30
  --aui-cascade-menu-nested-shadow: none; /* full-height panel flush to L0 — no elevation */
31
31
  --aui-cascade-menu-z: var(--aui-z-chrome); /* L0 stacking context — above sticky table, below dropdown */
@@ -28,6 +28,7 @@ Slots: `Header` / `Body` / `Footer` / `Row` / `Cell` / `HeaderCell` / `CheckboxC
28
28
  - The root renders the scroll area and `<table>`. `Header` and `Body` sit inside the table, `Footer` sits outside
29
29
  - `HeaderCell`: `column` and `sortable`. Without `Filter`, sorting is a header click (`none` → `asc` → `desc` → `none`). Switching column clears the previous one
30
30
  - `Filter` is the drop body inside `HeaderCell`. `active` colors the icon. No slot — no drop. When the column is `sortable`, sort actions sit under the filter
31
- - `Row` `onContextMenu` is the right click, the same prop as on a `Table` row. The row does not open a menu
31
+ - `Cell` / `HeaderCell` `pin` and `Row` `pin` match `Table`. Checkbox cells stay pinned to the start
32
+ - `Row` `onContextMenu` is the right click, the same prop as on a `Table` row. The row does not open a menu. `active` keeps `--aui-table-bg-hover`, including on a checked row, while the screen keeps the menu open
32
33
  - `Actions` is a quiet “⋯” button with `onClick`. It stays visible, with no fill. The row assembly decides what the click opens
33
34
  - `Pagination` and `PageSize` match `Table` and usually live in `Footer`
@@ -19,6 +19,7 @@ An app layout may use only these:
19
19
  | Token | Role |
20
20
  | --- | --- |
21
21
  | `--aui-page-bg-primary` | page fill |
22
+ | `--aui-page-bg-subtle` | sidebar, matches the page; the divider is the edge |
22
23
  | `--aui-page-fg-primary` | page text |
23
24
  | `--aui-page-fg-muted` | secondary text |
24
25
  | `--aui-page-fg-link` | link text (underline; same as page text) |
@@ -27,4 +28,4 @@ An app layout may use only these:
27
28
  | `--aui-surface-bg-elevated` | raised surface |
28
29
  | `--aui-surface-border-primary` | zone stroke, when the zone has no fill |
29
30
 
30
- Primitive scales (`--aui-neutral-*`, `--aui-grey-*`, `--aui-red-*`, radius, spacing) are not for app CSS. Screen layers and hex roles — `docs/design-language.md`.
31
+ Primitive scales (`--aui-neutral-*`, `--aui-red-*`, radius, spacing) are not for app CSS. Screen layers and hex roles — `docs/design-language.md`.
@@ -3,7 +3,7 @@ export const docsCssVariables = `/* CSS variables — Link (--aui-link-*)
3
3
  * Light/default below (semantic.css). Dark: hover white in semantic.dark.css.
4
4
  */
5
5
  --aui-link-fg: var(--aui-page-fg-link); /* link text = page fg */
6
- --aui-link-fg-hover: var(--aui-neutral-800); /* link hover (light near-black; dark = white) */
6
+ --aui-link-fg-hover: var(--aui-control-bg-brand); /* link hover; dark mirrors brand */
7
7
  --aui-link-border-focus: var(--aui-control-border-focus); /* focus ring */
8
8
  --aui-link-duration-fast: var(--aui-control-duration-fast); /* transition duration */
9
9
  --aui-link-ease-out: var(--aui-control-ease-out); /* transition easing */`;
@@ -1,5 +1,5 @@
1
1
  /** Page substrate CSS variables used by AdminUiProvider root (--aui-page-*). */
2
2
  export const docsCssVariables = `/* CSS variables — AdminUiProvider page substrate (--aui-page-*) */
3
3
  --aui-page-bg-primary: var(--aui-white); /* page canvas background */
4
- --aui-page-fg-primary: var(--aui-black-900); /* page default foreground */
4
+ --aui-page-fg-primary: var(--aui-neutral-900); /* page default foreground */
5
5
  `;
@@ -152,6 +152,8 @@ export interface IAuiLabels {
152
152
  dropzoneLimitReached: string;
153
153
  /** Dropzone: form message while a file is still uploading. */
154
154
  dropzoneUploading: string;
155
+ /** Rating value text (`{value}`, `{max}`). */
156
+ ratingValue: string;
155
157
  }
156
158
 
157
159
  export type TAuiLabels = IAuiLabels;
@@ -0,0 +1,47 @@
1
+ Star rating in whole and half steps.
2
+
3
+ ```tsx
4
+ import { Rating, FormRating } from '@ensi-platform/admin-ui/rating';
5
+ ```
6
+
7
+ ## When to use
8
+
9
+ - a product, review, or quality score
10
+ - a track without stars — see `Slider`
11
+ - a status with no number — see `Badge`
12
+
13
+ ## API (short)
14
+
15
+ ### Rating
16
+
17
+ | Prop | Values | Default | Description |
18
+ | -------------- | ------------------------- | --------- | -------------------------------------------------------- |
19
+ | `size` | `sm` \| `md` \| `lg` | `md` | star size |
20
+ | `variant` | `primary` | `primary` | palette |
21
+ | `value` | `number` | — | controlled value |
22
+ | `defaultValue` | `number` | — | initial value |
23
+ | `onChange` | `(value: number) => void` | — | value change |
24
+ | `minValue` | `number` | `0` | minimum; a second press on the current half returns here |
25
+ | `maxValue` | `number` | `5` | maximum; one star per unit above `minValue` |
26
+ | `step` | `number` | `0.5` | step |
27
+ | `readOnly` | `boolean` | `false` | display without a slider: `role="img"` |
28
+ | `invalid` | `boolean` | `false` | error |
29
+ | `disabled` | `boolean` | `false` | unavailable; with `readOnly` it stays a slider |
30
+ | `dataTestId` | `string` | — | `data-test-id` for tests |
31
+
32
+ Label it with `Field` or `aria-label`. The number is not shown. On the slider it is `aria-valuetext` from the `ratingValue` template (`{value}` of `{max}`). On `readOnly` the same string is the image name. No `as`.
33
+
34
+ ### FormRating
35
+
36
+ | Prop | Values | Default | Description |
37
+ | ------------ | -------------------- | ------- | ---------------------------- |
38
+ | `name` | `string` | — | `Form` field name (`number`) |
39
+ | `label` | `ReactNode` | — | label |
40
+ | `hint` | `ReactNode` | — | hint under the stars |
41
+ | `size` | `sm` \| `md` \| `lg` | `md` | size |
42
+ | `readOnly` | `boolean` | — | display only |
43
+ | `disabled` | `boolean` | — | unavailable |
44
+ | `block` | `boolean` | `true` | `Field` column width |
45
+ | `dataTestId` | `string` | — | `data-test-id` for tests |
46
+
47
+ A missing field value becomes `minValue` (`0`).
@@ -0,0 +1,9 @@
1
+ ## Example
2
+
3
+ ```tsx
4
+ <Rating aria-label="Score" value={value} onChange={setValue} />
5
+
6
+ <Form initialValues={{ score: 4 }} onSubmit={save}>
7
+ <FormRating name="score" label="Score" hint="From 0 to 5" />
8
+ </Form>
9
+ ```
@@ -0,0 +1,14 @@
1
+ /** Rating CSS variables from semantic tokens (--aui-rating-*). */
2
+ export const docsCssVariables = `/* CSS variables — Rating (--aui-rating-*) */
3
+ --aui-rating-fg-primary: var(--aui-yellow-500); /* filled star */
4
+ --aui-rating-fg-primary-hover: color-mix(in srgb, var(--aui-yellow-500) 65%, transparent); /* preview fill */
5
+ --aui-rating-fg-muted: var(--aui-page-fg-muted); /* empty star */
6
+ --aui-rating-border-focus: var(--aui-control-border-focus); /* focus outline */
7
+ --aui-rating-border-danger: var(--aui-control-border-danger); /* invalid outline */
8
+ --aui-rating-icon-sm: var(--aui-spacing-16); /* star sm */
9
+ --aui-rating-icon-md: var(--aui-spacing-20); /* star md */
10
+ --aui-rating-icon-lg: var(--aui-spacing-24); /* star lg */
11
+ --aui-rating-gap: var(--aui-spacing-4); /* gap between stars */
12
+ --aui-rating-duration-fast: var(--aui-control-duration-fast); /* fill transition */
13
+ --aui-rating-ease-out: var(--aui-control-ease-out); /* fill easing */
14
+ `;
@@ -0,0 +1,69 @@
1
+ import { type FocusEventHandler, type Ref } from 'react';
2
+
3
+ import { type SliderProps as RacSliderProps } from 'react-aria-components';
4
+
5
+ import { type IDataTestIdProps } from '@ds/common';
6
+
7
+ import { type IFieldStateProps } from '@/field/types';
8
+ import { type IFormFieldLayoutProps } from '@/form/types';
9
+
10
+ export type TRatingSize = 'sm' | 'md' | 'lg';
11
+
12
+ export type TRatingVariant = 'primary';
13
+
14
+ /** Theme inputs. */
15
+ export interface IRatingThemeProps {
16
+ /** Rating size. */
17
+ size?: TRatingSize;
18
+ /** Visual variant. */
19
+ variant?: TRatingVariant;
20
+ }
21
+
22
+ /** Control state (our names, not RAC). */
23
+ export interface IRatingControlProps {
24
+ /** Controlled value. */
25
+ value?: number;
26
+ /** Uncontrolled initial value. */
27
+ defaultValue?: number;
28
+ /** Value change handler. */
29
+ onChange?: (value: number) => void;
30
+ /** Blur handler for the range input. */
31
+ onBlur?: FocusEventHandler<HTMLInputElement>;
32
+ /** Minimum value. A click on the current half returns here. */
33
+ minValue?: number;
34
+ /** Maximum value. One star per unit above `minValue`. */
35
+ maxValue?: number;
36
+ /** Step between values. */
37
+ step?: number;
38
+ /** Show the value without a slider. */
39
+ readOnly?: boolean;
40
+ }
41
+
42
+ /** Own / chrome props (not from RAC). */
43
+ export interface IRatingOwnProps extends IDataTestIdProps {
44
+ /** Ref to the range input (React 19 prop). */
45
+ ref?: Ref<HTMLInputElement>;
46
+ }
47
+
48
+ /** Content slice for FormRating. */
49
+ export interface IRatingContentProps {
50
+ minValue?: number;
51
+ maxValue?: number;
52
+ step?: number;
53
+ readOnly?: boolean;
54
+ /** Accessible name when there is no visible `label`. */
55
+ 'aria-label'?: string;
56
+ }
57
+
58
+ export interface IRatingBaseProps
59
+ extends IRatingThemeProps, Pick<IFieldStateProps, 'invalid' | 'disabled'>, IRatingControlProps, IRatingOwnProps {}
60
+
61
+ /** RAC keys omitted because names differ from ours. */
62
+ export type TRatingRacOmit =
63
+ 'isDisabled' | 'value' | 'defaultValue' | 'onChange' | 'onBlur' | 'minValue' | 'maxValue' | 'step';
64
+
65
+ export interface IRatingProps
66
+ extends IRatingBaseProps, Omit<RacSliderProps<number>, keyof IRatingBaseProps | TRatingRacOmit> {}
67
+
68
+ export interface IFormRatingProps
69
+ extends IFormFieldLayoutProps, Pick<IRatingThemeProps, 'variant'>, IRatingContentProps {}
@@ -10,20 +10,22 @@ import { Table, useTableRowSelection } from '@ensi-platform/admin-ui/table';
10
10
 
11
11
  ## API (short)
12
12
 
13
- | Prop | Values | Default | Description |
14
- | ------------ | -------------------- | ------- | ---------------------------------------------------------- |
15
- | `size` | `sm` \| `md` \| `lg` | `md` | row density |
16
- | `block` | `boolean` | `true` | stretch to 100% of parent width |
17
- | `hasChecked` | `boolean` | `false` | reserve layout for a leading checkbox column |
18
- | `zebra` | `boolean` | `false` | subtle even-row background (overridden by checked / hover) |
19
- | `dataTestId` | `string` | — | `data-test-id` for tests |
13
+ | Prop | Values | Default | Description |
14
+ | ------------ | -------------------- | ------- | -------------------------------------------------------------------------------------------------- |
15
+ | `size` | `sm` \| `md` \| `lg` | `md` | row density |
16
+ | `block` | `boolean` | `true` | stretch to 100% of parent width |
17
+ | `hasChecked` | `boolean` | `false` | reserve layout for a leading checkbox column |
18
+ | `zebra` | `boolean` | `false` | subtle even-row background (checked / hover win; a checked row hovers with `--aui-table-bg-hover`) |
19
+ | `dataTestId` | `string` | — | `data-test-id` for tests |
20
20
 
21
21
  Slots: `Scroll` / `Table` / `Header` / `Body` / `Footer` / `Row` / `Cell` / `HeaderCell` / `CheckboxCell` / `HeaderCheckboxCell` / `ActionBar` / `SortIndicator` / `Pagination` / `PageSize`.
22
22
 
23
23
  - `Scroll` — scroll area; `Footer` is a sibling (not inside `Table.Table` / `<table>`)
24
24
  - `Table` — native `<table>`: only `Header` / `Body` / `Row` / cells
25
25
  - `Header`: `sticky?`; `Footer`: `sticky?` (default `true`); left `PageSize`, right `Pagination`
26
- - `Cell` / `HeaderCell`: `numeric?`, `align?`, `utility?`, `noWrap?`, `width?`; `HeaderCell` also has `sortable?`, `sortDirection?`, `onSort?`, `filter?`, `filterActive?`
26
+ - `Cell` / `HeaderCell`: `numeric?`, `align?`, `utility?`, `noWrap?`, `width?`, `pin?` (`start` | `end`); `HeaderCell` also has `sortable?`, `sortDirection?`, `onSort?`, `filter?`, `filterActive?`
27
+ - the same `pin` goes on every cell of that column, including the header. Several columns on one edge stack their offsets. Checkbox cells are always `start`. The edge seam shows only while that edge is stuck to the scroll area
28
+ - `Row`: `pin?` (`top` | `bottom`) for body rows. Several rows on one edge stack under the sticky header or up from the bottom of the scroll area. `active` keeps `--aui-table-bg-hover`, including on a checked row; the row does not open a menu
27
29
  - `filter` is the drop body in the column header. The trigger is a floating pill. When the column is `sortable`, sort actions sit under the filter. Without `filter`, sorting stays a click on the header. `filterActive` colors the filter icon
28
30
  - `Pagination`: controlled `page` + `pageCount` + `onPageChange` + `from` + `to` + `total`; numbered pages (window, first and last always present); optional `rangeLabel?`, `prevLabel?` / `nextLabel?`, `disabled?`
29
31
  - `PageSize`: controlled `value` + `onChange`; `options?` (default `[5, 10, 25, 50, 100]`); `label?`; `disabled?`
@@ -27,10 +27,18 @@ const onPageSizeChange = (size: number) => {
27
27
  onChange={setAllOnPage}
28
28
  aria-label="Select all"
29
29
  />
30
- <Table.HeaderCell sortable sortDirection={sort} onSort={setSort}>
30
+ <Table.HeaderCell pin="start" width={180} sortable sortDirection={sort} onSort={setSort}>
31
31
  Name
32
32
  </Table.HeaderCell>
33
- <Table.HeaderCell numeric>Amount</Table.HeaderCell>
33
+ <Table.HeaderCell width={160}>City</Table.HeaderCell>
34
+ <Table.HeaderCell width={140}>Status</Table.HeaderCell>
35
+ <Table.HeaderCell width={180}>Manager</Table.HeaderCell>
36
+ <Table.HeaderCell width={160}>Warehouse</Table.HeaderCell>
37
+ <Table.HeaderCell width={180}>Channel</Table.HeaderCell>
38
+ <Table.HeaderCell numeric width={120}>
39
+ Amount
40
+ </Table.HeaderCell>
41
+ <Table.HeaderCell pin="end" utility />
34
42
  </Table.Row>
35
43
  </Table.Header>
36
44
  <Table.Body>
@@ -41,9 +49,18 @@ const onPageSizeChange = (size: number) => {
41
49
  onChange={() => toggle(row.id)}
42
50
  aria-label={`Select ${row.name}`}
43
51
  />
44
- <Table.Cell>{row.name}</Table.Cell>
45
- <Table.Cell numeric>{row.amount}</Table.Cell>
46
- <Table.Cell utility>
52
+ <Table.Cell pin="start" width={180}>
53
+ {row.name}
54
+ </Table.Cell>
55
+ <Table.Cell width={160}>{row.city}</Table.Cell>
56
+ <Table.Cell width={140}>{row.status}</Table.Cell>
57
+ <Table.Cell width={180}>{row.manager}</Table.Cell>
58
+ <Table.Cell width={160}>{row.warehouse}</Table.Cell>
59
+ <Table.Cell width={180}>{row.channel}</Table.Cell>
60
+ <Table.Cell numeric width={120}>
61
+ {row.amount}
62
+ </Table.Cell>
63
+ <Table.Cell pin="end" utility>
47
64
  <Table.ActionBar visibleCount={0} items={[{ text: 'Edit', onClick: () => {} }]} />
48
65
  </Table.Cell>
49
66
  </Table.Row>
@@ -1,9 +1,9 @@
1
1
  /** Table CSS variables from semantic tokens (--aui-table-*). */
2
2
  export const docsCssVariables = `/* CSS variables — Table (--aui-table-*) */
3
3
  --aui-table-bg-primary: var(--aui-surface-bg-primary); /* primary fill */
4
- --aui-table-bg-hover: var(--aui-neutral-300); /* hover fill; dark: grey-500 */
5
- --aui-table-bg-selected: var(--aui-neutral-100); /* selected fill; dark: muted (grey-600) */
6
- --aui-table-bg-zebra: var(--aui-neutral-50); /* zebra fill; dark: muted 18% on page */
4
+ --aui-table-bg-hover: var(--aui-surface-bg-muted-active); /* hover fill */
5
+ --aui-table-bg-selected: var(--aui-surface-bg-muted); /* selected fill */
6
+ --aui-table-bg-zebra: var(--aui-neutral-50); /* zebra fill; dark is a quiet white mix */
7
7
  --aui-table-bg-header: var(--aui-surface-bg-primary); /* header fill */
8
8
  --aui-table-bg-footer: var(--aui-surface-bg-primary); /* footer fill */
9
9
 
@@ -56,8 +56,13 @@ export const docsCssVariables = `/* CSS variables — Table (--aui-table-*) */
56
56
  --aui-table-page-size-min: var(--aui-spacing-64); /* page-size select min width */
57
57
 
58
58
  --aui-table-z-sticky: 2; /* z-index */
59
+ --aui-table-z-pin: 1; /* pinned cell z-index */
60
+ --aui-table-z-pin-cross: 2; /* pinned row and column intersection z-index */
59
61
 
60
62
  --aui-table-shadow-sticky: 0 1px 0 var(--aui-table-border-primary); /* sticky shadow */
63
+ --aui-table-shadow-pin-start: 1px 0 0 var(--aui-table-border-primary); /* pin seam at the inline start */
64
+ --aui-table-shadow-pin-end: -1px 0 0 var(--aui-table-border-primary); /* pin seam at the inline end */
65
+ --aui-table-shadow-pin-bottom: 0 -1px 0 var(--aui-table-border-primary); /* pin seam above a bottom row */
61
66
 
62
67
  --aui-table-duration-fast: var(--aui-control-duration-fast); /* transition duration (fast) */
63
68
  --aui-table-ease-out: var(--aui-control-ease-out); /* transition easing */`;
@@ -11,6 +11,9 @@ export type TTableSortDirection = 'asc' | 'desc';
11
11
  /** Cell horizontal alignment. */
12
12
  export type TTableAlign = 'start' | 'end' | 'center';
13
13
 
14
+ /** Column pin edge. */
15
+ export type TTablePin = 'start' | 'end';
16
+
14
17
  /** Theme inputs. */
15
18
  export interface ITableThemeProps {
16
19
  /** Row density. */
@@ -54,6 +57,8 @@ export interface ITableCellChromeProps {
54
57
  width?: CSSProperties['width'];
55
58
  /** Utility column (checkbox / actions / settings). */
56
59
  utility?: boolean;
60
+ /** Stick to the inline start or end while the shell scrolls. */
61
+ pin?: TTablePin;
57
62
  }
58
63
 
59
64
  export type { ITableHeaderProps } from './components/Header/types';
@@ -61,7 +66,7 @@ export type { ITableBodyProps } from './components/Body/types';
61
66
  export type { ITableFooterProps } from './components/Footer/types';
62
67
  export type { ITableScrollProps } from './components/Scroll/types';
63
68
  export type { ITableElementProps } from './components/TableElement/types';
64
- export type { ITableRowProps } from './components/Row/types';
69
+ export type { ITableRowProps, TTableRowPin } from './components/Row/types';
65
70
  export type { ITableCellProps } from './components/Cell/types';
66
71
  export type { ITableHeaderCellProps } from './components/HeaderCell/types';
67
72
  export type { ITableCheckboxCellProps } from './components/CheckboxCell/types';
@@ -1,12 +1,12 @@
1
1
  /** Toast CSS variables from semantic tokens (--aui-toast-*). */
2
2
  export const docsCssVariables = `/* CSS variables — Toast (--aui-toast-*) */
3
3
  --aui-toast-bg-neutral: var(--aui-surface-bg-muted); /* neutral fill */
4
- --aui-toast-accent-neutral: var(--aui-neutral-500); /* neutral accent */
5
- --aui-toast-bg-success: var(--aui-green-50); /* success fill */
4
+ --aui-toast-accent-neutral: var(--aui-page-fg-muted); /* neutral accent */
5
+ --aui-toast-bg-success: color-mix(in srgb, var(--aui-green-700) 22%, var(--aui-surface-bg-primary)); /* success fill */
6
6
  --aui-toast-accent-success: var(--aui-green-700); /* success accent */
7
- --aui-toast-bg-warning: var(--aui-yellow-50); /* warning fill */
7
+ --aui-toast-bg-warning: color-mix(in srgb, var(--aui-yellow-700) 22%, var(--aui-surface-bg-primary)); /* warning fill */
8
8
  --aui-toast-accent-warning: var(--aui-yellow-700); /* warning accent */
9
- --aui-toast-bg-danger: var(--aui-red-50); /* danger fill */
9
+ --aui-toast-bg-danger: color-mix(in srgb, var(--aui-red-700) 22%, var(--aui-surface-bg-primary)); /* danger fill */
10
10
  --aui-toast-accent-danger: var(--aui-red-700); /* danger accent */
11
11
  --aui-toast-bg-info: var(--aui-surface-bg-muted); /* info fill = muted */
12
12
  --aui-toast-accent-info: var(--aui-page-fg-muted); /* info accent = muted fg */
@@ -1,7 +1,7 @@
1
1
  /** Tooltip CSS variables from semantic tokens (--aui-tooltip-*). */
2
2
  export const docsCssVariables = `/* CSS variables — Tooltip (--aui-tooltip-*) */
3
- --aui-tooltip-bg-primary: var(--aui-neutral-800); /* primary fill */
4
- --aui-tooltip-fg-primary: var(--aui-neutral-50); /* primary foreground */
3
+ --aui-tooltip-bg-primary: var(--aui-control-bg-brand); /* primary fill */
4
+ --aui-tooltip-fg-primary: var(--aui-control-fg-brand); /* primary foreground */
5
5
 
6
6
  --aui-tooltip-radius-md: var(--aui-control-radius-sm); /* md radius */
7
7
  --aui-tooltip-pad-y-sm: var(--aui-spacing-4); /* padding-y sm */