@42-central/ui-react 0.17.1 → 0.18.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 (345) hide show
  1. package/biome/no-gray-color.grit +18 -0
  2. package/dist/{chunk-FD6P6PLQ.js → chunk-5JHDSVEZ.js} +3 -3
  3. package/dist/{chunk-FD6P6PLQ.js.map → chunk-5JHDSVEZ.js.map} +1 -1
  4. package/dist/{chunk-QMW7D5GU.js → chunk-5OQLFX47.js} +4 -3
  5. package/dist/chunk-5OQLFX47.js.map +1 -0
  6. package/dist/{chunk-VZ2TPU4B.js → chunk-6GDMSENK.js} +3 -2
  7. package/dist/chunk-6GDMSENK.js.map +1 -0
  8. package/dist/{chunk-TNNH3FVQ.js → chunk-6OLTJYSX.js} +24 -8
  9. package/dist/chunk-6OLTJYSX.js.map +1 -0
  10. package/dist/{chunk-POKDSVQT.js → chunk-AE7QTLJ5.js} +5 -4
  11. package/dist/chunk-AE7QTLJ5.js.map +1 -0
  12. package/dist/{chunk-44OV3PNH.js → chunk-B2YJKRNQ.js} +3 -3
  13. package/dist/{chunk-44OV3PNH.js.map → chunk-B2YJKRNQ.js.map} +1 -1
  14. package/dist/{chunk-YIQI2CF3.js → chunk-CTSO6V72.js} +3 -2
  15. package/dist/chunk-CTSO6V72.js.map +1 -0
  16. package/dist/{chunk-EVVMHTCL.js → chunk-EBREIC3L.js} +4 -3
  17. package/dist/chunk-EBREIC3L.js.map +1 -0
  18. package/dist/{chunk-UNSAA7YG.js → chunk-FHG54IT5.js} +3 -2
  19. package/dist/chunk-FHG54IT5.js.map +1 -0
  20. package/dist/{chunk-3GYOIQW7.js → chunk-FZIHZT5R.js} +5 -5
  21. package/dist/{chunk-3GYOIQW7.js.map → chunk-FZIHZT5R.js.map} +1 -1
  22. package/dist/{chunk-2H46IXW4.js → chunk-HAQJQFE6.js} +28 -8
  23. package/dist/chunk-HAQJQFE6.js.map +1 -0
  24. package/dist/{chunk-IHYFYMHJ.js → chunk-HT5JAHR3.js} +6 -6
  25. package/dist/{chunk-IHYFYMHJ.js.map → chunk-HT5JAHR3.js.map} +1 -1
  26. package/dist/chunk-I4SQQIP5.js +12 -0
  27. package/dist/chunk-I4SQQIP5.js.map +1 -0
  28. package/dist/{chunk-J3PELDH3.js → chunk-JITF6I7N.js} +22 -6
  29. package/dist/chunk-JITF6I7N.js.map +1 -0
  30. package/dist/{chunk-IFWCCAQV.js → chunk-KHMFNH3X.js} +3 -2
  31. package/dist/chunk-KHMFNH3X.js.map +1 -0
  32. package/dist/{chunk-SIG4DMNZ.js → chunk-MI2WZRK3.js} +4 -4
  33. package/dist/{chunk-SIG4DMNZ.js.map → chunk-MI2WZRK3.js.map} +1 -1
  34. package/dist/{chunk-YON5Y336.js → chunk-O23Y5ML4.js} +8 -8
  35. package/dist/{chunk-YON5Y336.js.map → chunk-O23Y5ML4.js.map} +1 -1
  36. package/dist/{chunk-P7A3BCAC.js → chunk-OWG4BCQR.js} +3 -3
  37. package/dist/{chunk-P7A3BCAC.js.map → chunk-OWG4BCQR.js.map} +1 -1
  38. package/dist/{chunk-FUWSTUDM.js → chunk-PH354ECN.js} +4 -4
  39. package/dist/{chunk-FUWSTUDM.js.map → chunk-PH354ECN.js.map} +1 -1
  40. package/dist/{chunk-U5GW5EBR.js → chunk-RAUOFTUH.js} +12 -20
  41. package/dist/chunk-RAUOFTUH.js.map +1 -0
  42. package/dist/{chunk-6I4R3HR6.js → chunk-RQL7FVCS.js} +3 -3
  43. package/dist/{chunk-6I4R3HR6.js.map → chunk-RQL7FVCS.js.map} +1 -1
  44. package/dist/{chunk-2762HZYX.js → chunk-S2HWWR2H.js} +47 -25
  45. package/dist/chunk-S2HWWR2H.js.map +1 -0
  46. package/dist/{chunk-VLUKI3HL.js → chunk-S7N4LGLZ.js} +6 -13
  47. package/dist/chunk-S7N4LGLZ.js.map +1 -0
  48. package/dist/{chunk-NSOA3GMZ.js → chunk-UHNRAI6V.js} +3 -3
  49. package/dist/{chunk-NSOA3GMZ.js.map → chunk-UHNRAI6V.js.map} +1 -1
  50. package/dist/{chunk-JBVFWSRQ.js → chunk-VIYVN4WF.js} +6 -4
  51. package/dist/chunk-VIYVN4WF.js.map +1 -0
  52. package/dist/{chunk-3NZXWCGF.js → chunk-WHKKN3ZK.js} +6 -6
  53. package/dist/{chunk-3NZXWCGF.js.map → chunk-WHKKN3ZK.js.map} +1 -1
  54. package/dist/{chunk-MOI7B3KH.js → chunk-WQN64ZHG.js} +5 -5
  55. package/dist/{chunk-MOI7B3KH.js.map → chunk-WQN64ZHG.js.map} +1 -1
  56. package/dist/chunk-WSIVRDRB.js +34 -0
  57. package/dist/chunk-WSIVRDRB.js.map +1 -0
  58. package/dist/{chunk-S53FHWNG.js → chunk-YWRBG23W.js} +3 -3
  59. package/dist/chunk-YWRBG23W.js.map +1 -0
  60. package/dist/{chunk-6SWK4XG5.js → chunk-YXE4B6X3.js} +2 -2
  61. package/dist/chunk-YXE4B6X3.js.map +1 -0
  62. package/dist/{chunk-NGAQITWP.js → chunk-Z2Z5EXVT.js} +10 -7
  63. package/dist/chunk-Z2Z5EXVT.js.map +1 -0
  64. package/dist/{chunk-IXKELBJA.js → chunk-ZDXQ64A7.js} +63 -44
  65. package/dist/chunk-ZDXQ64A7.js.map +1 -0
  66. package/dist/colors.css +12 -26
  67. package/dist/components/accordion/accordion-data.d.ts +3 -2
  68. package/dist/components/accordion/accordion-data.d.ts.map +1 -1
  69. package/dist/components/accordion/accordion.d.ts +2 -2
  70. package/dist/components/accordion/accordion.d.ts.map +1 -1
  71. package/dist/components/accordion/index.js +20 -8
  72. package/dist/components/accordion/index.js.map +1 -1
  73. package/dist/components/action-icon/action-icon.d.ts +3 -4
  74. package/dist/components/action-icon/action-icon.d.ts.map +1 -1
  75. package/dist/components/action-icon/index.js +2 -1
  76. package/dist/components/alert/alert.d.ts +1 -1
  77. package/dist/components/alert/alert.d.ts.map +1 -1
  78. package/dist/components/alert/index.js +16 -4
  79. package/dist/components/alert/index.js.map +1 -1
  80. package/dist/components/app-shell/app-shell.d.ts +3 -2
  81. package/dist/components/app-shell/app-shell.d.ts.map +1 -1
  82. package/dist/components/app-shell/index.js +4 -2
  83. package/dist/components/app-shell/index.js.map +1 -1
  84. package/dist/components/autocomplete/index.js +5 -4
  85. package/dist/components/autocomplete/index.js.map +1 -1
  86. package/dist/components/avatar/avatar.d.ts +3 -3
  87. package/dist/components/avatar/index.js.map +1 -1
  88. package/dist/components/breadcrumb/breadcrumb.d.ts +3 -2
  89. package/dist/components/breadcrumb/breadcrumb.d.ts.map +1 -1
  90. package/dist/components/breadcrumb/index.js +11 -5
  91. package/dist/components/breadcrumb/index.js.map +1 -1
  92. package/dist/components/button/button.d.ts +4 -4
  93. package/dist/components/button/button.d.ts.map +1 -1
  94. package/dist/components/button/index.js +2 -1
  95. package/dist/components/button-multi-select/index.js +4 -3
  96. package/dist/components/button-multi-select/index.js.map +1 -1
  97. package/dist/components/button-select/index.js +4 -3
  98. package/dist/components/button-select/index.js.map +1 -1
  99. package/dist/components/calendar/index.js +3 -2
  100. package/dist/components/chart/chart.d.ts +1 -1
  101. package/dist/components/chart/index.js +1 -1
  102. package/dist/components/chart/index.js.map +1 -1
  103. package/dist/components/checkbox/index.js +2 -2
  104. package/dist/components/choice-card-group/index.js +1 -1
  105. package/dist/components/circular-progress/circular-progress.d.ts +3 -2
  106. package/dist/components/circular-progress/circular-progress.d.ts.map +1 -1
  107. package/dist/components/circular-progress/index.js +1 -0
  108. package/dist/components/circular-progress/index.js.map +1 -1
  109. package/dist/components/clipboard/clipboard.d.ts +1 -1
  110. package/dist/components/clipboard/clipboard.d.ts.map +1 -1
  111. package/dist/components/clipboard/index.js +9 -5
  112. package/dist/components/clipboard/index.js.map +1 -1
  113. package/dist/components/code/index.js +1 -1
  114. package/dist/components/code-block/chrome.d.ts +4 -1
  115. package/dist/components/code-block/chrome.d.ts.map +1 -1
  116. package/dist/components/code-block/chrome.js +5 -4
  117. package/dist/components/code-block/code-block.d.ts +7 -1
  118. package/dist/components/code-block/code-block.d.ts.map +1 -1
  119. package/dist/components/code-block/index.d.ts +1 -1
  120. package/dist/components/code-block/index.js +12 -10
  121. package/dist/components/code-block/index.js.map +1 -1
  122. package/dist/components/code-block/notation.d.ts +5 -2
  123. package/dist/components/code-block/notation.d.ts.map +1 -1
  124. package/dist/components/code-block/static.d.ts +4 -1
  125. package/dist/components/code-block/static.d.ts.map +1 -1
  126. package/dist/components/code-block/static.js +5 -4
  127. package/dist/components/code-block/static.js.map +1 -1
  128. package/dist/components/collapse/collapse.d.ts +7 -3
  129. package/dist/components/collapse/collapse.d.ts.map +1 -1
  130. package/dist/components/collapse/index.js +2 -1
  131. package/dist/components/combobox/combobox.d.ts +11 -10
  132. package/dist/components/combobox/combobox.d.ts.map +1 -1
  133. package/dist/components/combobox/index.js +5 -4
  134. package/dist/components/combobox-list/index.js +6 -5
  135. package/dist/components/data-table/index.js +21 -20
  136. package/dist/components/data-table/index.js.map +1 -1
  137. package/dist/components/date-picker/index.js +12 -11
  138. package/dist/components/date-picker/index.js.map +1 -1
  139. package/dist/components/divider/divider.d.ts +3 -2
  140. package/dist/components/divider/divider.d.ts.map +1 -1
  141. package/dist/components/divider/index.js +1 -1
  142. package/dist/components/drawer/drawer.d.ts +6 -5
  143. package/dist/components/drawer/drawer.d.ts.map +1 -1
  144. package/dist/components/drawer/index.js +3 -2
  145. package/dist/components/field/field.d.ts +7 -4
  146. package/dist/components/field/field.d.ts.map +1 -1
  147. package/dist/components/field/index.js +1 -1
  148. package/dist/components/file-upload/index.js +3 -2
  149. package/dist/components/file-upload/index.js.map +1 -1
  150. package/dist/components/hover-card/index.js +1 -1
  151. package/dist/components/input/index.js +2 -2
  152. package/dist/components/input/input.d.ts +3 -2
  153. package/dist/components/input/input.d.ts.map +1 -1
  154. package/dist/components/mark/index.js +1 -1
  155. package/dist/components/mark/mark.d.ts +2 -2
  156. package/dist/components/menu/index.js +3 -2
  157. package/dist/components/menu/index.js.map +1 -1
  158. package/dist/components/menu/menu-data.d.ts +6 -1
  159. package/dist/components/menu/menu-data.d.ts.map +1 -1
  160. package/dist/components/menu/menu.d.ts +5 -5
  161. package/dist/components/menu/menu.d.ts.map +1 -1
  162. package/dist/components/modal/index.js +3 -2
  163. package/dist/components/modal/modal.d.ts +4 -3
  164. package/dist/components/modal/modal.d.ts.map +1 -1
  165. package/dist/components/multi-combobox-list/index.js +6 -5
  166. package/dist/components/multi-select/index.js +7 -6
  167. package/dist/components/multi-select/index.js.map +1 -1
  168. package/dist/components/nav-link/index.js +3 -2
  169. package/dist/components/nav-link/tanstack.js +3 -2
  170. package/dist/components/nav-link/tanstack.js.map +1 -1
  171. package/dist/components/notification/index.js +4 -3
  172. package/dist/components/notification/index.js.map +1 -1
  173. package/dist/components/notification/notification.d.ts +3 -2
  174. package/dist/components/notification/notification.d.ts.map +1 -1
  175. package/dist/components/number-input/index.js +4 -4
  176. package/dist/components/overlays/index.js +5 -4
  177. package/dist/components/overlays/index.js.map +1 -1
  178. package/dist/components/password-input/index.js +2 -2
  179. package/dist/components/pill/index.js +2 -1
  180. package/dist/components/pill/pill.d.ts +4 -2
  181. package/dist/components/pill/pill.d.ts.map +1 -1
  182. package/dist/components/pills-input/index.js +5 -4
  183. package/dist/components/pills-input/pills-input.d.ts +3 -2
  184. package/dist/components/pills-input/pills-input.d.ts.map +1 -1
  185. package/dist/components/pin-input/index.js +2 -2
  186. package/dist/components/popover/index.js +1 -1
  187. package/dist/components/popover/popover.d.ts +3 -2
  188. package/dist/components/popover/popover.d.ts.map +1 -1
  189. package/dist/components/progress/index.js +1 -0
  190. package/dist/components/progress/index.js.map +1 -1
  191. package/dist/components/progress/progress.d.ts +3 -2
  192. package/dist/components/progress/progress.d.ts.map +1 -1
  193. package/dist/components/radio-group/index.js +1 -1
  194. package/dist/components/rating/index.js +2 -1
  195. package/dist/components/rating/index.js.map +1 -1
  196. package/dist/components/rating/rating.d.ts +3 -2
  197. package/dist/components/rating/rating.d.ts.map +1 -1
  198. package/dist/components/schedule/index.d.ts +2 -2
  199. package/dist/components/schedule/index.js +50 -23
  200. package/dist/components/schedule/index.js.map +1 -1
  201. package/dist/components/schedule/schedule-agenda-list.d.ts +6 -7
  202. package/dist/components/schedule/schedule-agenda-list.d.ts.map +1 -1
  203. package/dist/components/schedule/schedule-agenda-view.d.ts +19 -16
  204. package/dist/components/schedule/schedule-agenda-view.d.ts.map +1 -1
  205. package/dist/components/schedule/schedule-dates.d.ts.map +1 -1
  206. package/dist/components/schedule/schedule-days-view.d.ts +3 -2
  207. package/dist/components/schedule/schedule-days-view.d.ts.map +1 -1
  208. package/dist/components/schedule/schedule-month-view.d.ts +3 -2
  209. package/dist/components/schedule/schedule-month-view.d.ts.map +1 -1
  210. package/dist/components/schedule/schedule-next-up.d.ts +4 -3
  211. package/dist/components/schedule/schedule-next-up.d.ts.map +1 -1
  212. package/dist/components/schedule/schedule-toolbar.d.ts +1 -1
  213. package/dist/components/schedule/schedule-toolbar.d.ts.map +1 -1
  214. package/dist/components/schedule/schedule-types.d.ts +6 -4
  215. package/dist/components/schedule/schedule-types.d.ts.map +1 -1
  216. package/dist/components/schedule/schedule-views.d.ts +2 -2
  217. package/dist/components/schedule/schedule-views.d.ts.map +1 -1
  218. package/dist/components/schedule/schedule-year-view.d.ts +3 -2
  219. package/dist/components/schedule/schedule-year-view.d.ts.map +1 -1
  220. package/dist/components/schedule/schedule.d.ts +9 -6
  221. package/dist/components/schedule/schedule.d.ts.map +1 -1
  222. package/dist/components/segment-group/index.js +2 -2
  223. package/dist/components/select/index.js +4 -4
  224. package/dist/components/slider/index.js +2 -1
  225. package/dist/components/slider/index.js.map +1 -1
  226. package/dist/components/slider/slider.d.ts +3 -2
  227. package/dist/components/slider/slider.d.ts.map +1 -1
  228. package/dist/components/switch/index.js +1 -1
  229. package/dist/components/tabs/index.js +1 -1
  230. package/dist/components/tabs/tabs-data.d.ts +3 -2
  231. package/dist/components/tabs/tabs-data.d.ts.map +1 -1
  232. package/dist/components/tags-input/index.js +6 -5
  233. package/dist/components/tags-input/index.js.map +1 -1
  234. package/dist/components/text-input/index.js +2 -2
  235. package/dist/components/textarea/index.js +2 -2
  236. package/dist/components/theme-icon/index.js +1 -1
  237. package/dist/components/time-input/index.js +6 -6
  238. package/dist/components/timeline/index.js +8 -5
  239. package/dist/components/timeline/index.js.map +1 -1
  240. package/dist/components/timeline/timeline.d.ts +1 -1
  241. package/dist/components/timeline/timeline.d.ts.map +1 -1
  242. package/dist/components/tooltip/index.js +1 -1
  243. package/dist/components/tooltip/tooltip.d.ts +2 -1
  244. package/dist/components/tooltip/tooltip.d.ts.map +1 -1
  245. package/dist/components/tree-multi-select/index.js +6 -5
  246. package/dist/components/tree-multi-select/index.js.map +1 -1
  247. package/dist/components/tree-select/index.js +3 -3
  248. package/dist/index.js +1 -1
  249. package/dist/lib/as-child.d.ts +104 -0
  250. package/dist/lib/as-child.d.ts.map +1 -0
  251. package/dist/lib/colors.d.ts +1 -1
  252. package/dist/lib/colors.d.ts.map +1 -1
  253. package/dist/theme.css +0 -33
  254. package/package.json +2 -1
  255. package/src/as-child.contract.test.tsx +809 -0
  256. package/src/biome-plugins.test.ts +61 -0
  257. package/src/colors.css +12 -26
  258. package/src/components/accordion/accordion-data.tsx +8 -5
  259. package/src/components/accordion/accordion.test.tsx +40 -0
  260. package/src/components/accordion/accordion.tsx +23 -6
  261. package/src/components/action-icon/action-icon.tsx +9 -24
  262. package/src/components/alert/alert.test.tsx +17 -0
  263. package/src/components/alert/alert.tsx +21 -2
  264. package/src/components/app-shell/app-shell.tsx +3 -1
  265. package/src/components/avatar/avatar.tsx +3 -3
  266. package/src/components/breadcrumb/breadcrumb.test.tsx +30 -0
  267. package/src/components/breadcrumb/breadcrumb.tsx +21 -12
  268. package/src/components/button/button.tsx +21 -50
  269. package/src/components/chart/chart.test.tsx +1 -2
  270. package/src/components/chart/chart.tsx +1 -1
  271. package/src/components/circular-progress/circular-progress.tsx +4 -1
  272. package/src/components/clipboard/clipboard.test.tsx +18 -0
  273. package/src/components/clipboard/clipboard.tsx +8 -2
  274. package/src/components/code-block/chrome.tsx +60 -36
  275. package/src/components/code-block/code-block.test.tsx +27 -0
  276. package/src/components/code-block/code-block.tsx +13 -3
  277. package/src/components/code-block/gutters.test.ts +2 -2
  278. package/src/components/code-block/notation.test.ts +8 -0
  279. package/src/components/code-block/notation.ts +6 -3
  280. package/src/components/code-block/static.tsx +8 -2
  281. package/src/components/collapse/collapse.tsx +33 -15
  282. package/src/components/combobox/combobox.test.tsx +38 -0
  283. package/src/components/combobox/combobox.tsx +24 -10
  284. package/src/components/divider/divider.tsx +3 -1
  285. package/src/components/drawer/drawer.tsx +37 -16
  286. package/src/components/field/field.tsx +7 -3
  287. package/src/components/input/input.tsx +3 -1
  288. package/src/components/mark/mark.test.tsx +4 -4
  289. package/src/components/mark/mark.tsx +3 -3
  290. package/src/components/menu/menu-data.tsx +8 -1
  291. package/src/components/menu/menu.test.tsx +52 -0
  292. package/src/components/menu/menu.tsx +83 -35
  293. package/src/components/modal/close-trigger.test.tsx +38 -0
  294. package/src/components/modal/modal.tsx +29 -13
  295. package/src/components/notification/notification.tsx +4 -1
  296. package/src/components/pill/pill.tsx +29 -20
  297. package/src/components/pills-input/pills-input.tsx +3 -1
  298. package/src/components/popover/popover.tsx +3 -1
  299. package/src/components/progress/progress.tsx +4 -1
  300. package/src/components/rating/rating.tsx +27 -23
  301. package/src/components/schedule/index.ts +1 -1
  302. package/src/components/schedule/schedule-agenda-list.tsx +6 -7
  303. package/src/components/schedule/schedule-agenda-view.test.tsx +105 -28
  304. package/src/components/schedule/schedule-agenda-view.tsx +41 -28
  305. package/src/components/schedule/schedule-dates.test.ts +37 -52
  306. package/src/components/schedule/schedule-dates.ts +22 -25
  307. package/src/components/schedule/schedule-days-view.tsx +3 -1
  308. package/src/components/schedule/schedule-month-view.tsx +3 -1
  309. package/src/components/schedule/schedule-next-up.tsx +6 -2
  310. package/src/components/schedule/schedule-toolbar.test.tsx +26 -0
  311. package/src/components/schedule/schedule-toolbar.tsx +13 -1
  312. package/src/components/schedule/schedule-types.ts +6 -4
  313. package/src/components/schedule/schedule-views.ts +4 -5
  314. package/src/components/schedule/schedule-year-view.tsx +3 -1
  315. package/src/components/schedule/schedule.test.tsx +66 -22
  316. package/src/components/schedule/schedule.tsx +22 -13
  317. package/src/components/slider/slider.tsx +4 -0
  318. package/src/components/tabs/tabs-data.tsx +17 -14
  319. package/src/components/theme-icon/theme-icon.tsx +1 -1
  320. package/src/components/timeline/timeline.tsx +102 -95
  321. package/src/components/tooltip/tooltip.tsx +2 -1
  322. package/src/lib/as-child.test.tsx +70 -0
  323. package/src/lib/as-child.ts +119 -0
  324. package/src/lib/colors.ts +4 -2
  325. package/src/theme.css +0 -33
  326. package/dist/chunk-2762HZYX.js.map +0 -1
  327. package/dist/chunk-2H46IXW4.js.map +0 -1
  328. package/dist/chunk-6SWK4XG5.js.map +0 -1
  329. package/dist/chunk-EVVMHTCL.js.map +0 -1
  330. package/dist/chunk-HWNPXAEN.js +0 -31
  331. package/dist/chunk-HWNPXAEN.js.map +0 -1
  332. package/dist/chunk-IFWCCAQV.js.map +0 -1
  333. package/dist/chunk-IXKELBJA.js.map +0 -1
  334. package/dist/chunk-J3PELDH3.js.map +0 -1
  335. package/dist/chunk-JBVFWSRQ.js.map +0 -1
  336. package/dist/chunk-NGAQITWP.js.map +0 -1
  337. package/dist/chunk-POKDSVQT.js.map +0 -1
  338. package/dist/chunk-QMW7D5GU.js.map +0 -1
  339. package/dist/chunk-S53FHWNG.js.map +0 -1
  340. package/dist/chunk-TNNH3FVQ.js.map +0 -1
  341. package/dist/chunk-U5GW5EBR.js.map +0 -1
  342. package/dist/chunk-UNSAA7YG.js.map +0 -1
  343. package/dist/chunk-VLUKI3HL.js.map +0 -1
  344. package/dist/chunk-VZ2TPU4B.js.map +0 -1
  345. package/dist/chunk-YIQI2CF3.js.map +0 -1
@@ -202,37 +202,31 @@ describe("getVisibleRange", () => {
202
202
  expect(end.toISOString()).toBe(day(2027, 0, 1).toISOString())
203
203
  })
204
204
 
205
- it("agenda view spans the strict calendar month", () => {
206
- const { start, end } = getVisibleRange("agenda", day(2026, 6, 15), opts)
207
- expect(start.toISOString()).toBe(day(2026, 6, 1).toISOString())
208
- expect(end.toISOString()).toBe(day(2026, 7, 1).toISOString())
205
+ it("agenda view starts at the anchor's own day and spans visibleDays", () => {
206
+ const { start, end } = getVisibleRange("agenda", day(2026, 6, 15, 14), opts)
207
+ expect(start.toISOString()).toBe(day(2026, 6, 15).toISOString())
208
+ expect(end.toISOString()).toBe(day(2026, 6, 22).toISOString())
209
209
  })
210
210
 
211
- /** The whole reason agenda can't reuse the month branch: the padded grid
212
- * would make `isEventInVisibleRange` claim an adjacent-month event is on
213
- * screen in a list that never renders one. */
214
- it("agenda view does not pad like the month grid", () => {
215
- const agenda = getVisibleRange("agenda", day(2026, 6, 15), opts)
216
- const month = getVisibleRange("month", day(2026, 6, 15), opts)
217
- expect(agenda.start.toISOString()).not.toBe(month.start.toISOString())
218
- expect(agenda.end.toISOString()).not.toBe(month.end.toISOString())
211
+ it("agenda view takes its span from visibleDays", () => {
212
+ const { start, end } = getVisibleRange("agenda", day(2026, 6, 15), { ...opts, visibleDays: 3 })
213
+ expect(start.toISOString()).toBe(day(2026, 6, 15).toISOString())
214
+ expect(end.toISOString()).toBe(day(2026, 6, 18).toISOString())
219
215
  })
220
216
 
221
- it("agenda view ignores startOfWeek and visibleDays", () => {
217
+ /** A list is read from its top, so the window never snaps back to a week
218
+ * start — whatever `startOfWeek` says, the anchor's day comes first. */
219
+ it("agenda view ignores startOfWeek", () => {
222
220
  const plain = getVisibleRange("agenda", day(2026, 6, 15), opts)
223
- const fiddled = getVisibleRange("agenda", day(2026, 6, 15), {
224
- ...opts,
225
- startOfWeek: "mon",
226
- visibleDays: 3,
227
- })
221
+ const fiddled = getVisibleRange("agenda", day(2026, 6, 15), { ...opts, startOfWeek: "mon" })
228
222
  expect(fiddled.start.toISOString()).toBe(plain.start.toISOString())
229
223
  expect(fiddled.end.toISOString()).toBe(plain.end.toISOString())
230
224
  })
231
225
 
232
- it("agenda view closes February on a leap year", () => {
233
- const { start, end } = getVisibleRange("agenda", day(2028, 1, 10), opts)
234
- expect(start.toISOString()).toBe(day(2028, 1, 1).toISOString())
235
- expect(end.toISOString()).toBe(day(2028, 2, 1).toISOString())
226
+ it("agenda view runs across a month end", () => {
227
+ const { start, end } = getVisibleRange("agenda", day(2028, 1, 27), opts)
228
+ expect(start.toISOString()).toBe(day(2028, 1, 27).toISOString())
229
+ expect(end.toISOString()).toBe(day(2028, 2, 5).toISOString())
236
230
  })
237
231
  })
238
232
 
@@ -251,27 +245,18 @@ describe("paginateDate", () => {
251
245
  expect(paginateDate("year", anchor, 1, { timeZone: TZ }).toISOString()).toBe(
252
246
  day(2027, 6, 15).toISOString(),
253
247
  )
254
- expect(paginateDate("agenda", anchor, 1, { timeZone: TZ }).toISOString()).toBe(
255
- day(2026, 7, 15).toISOString(),
248
+ expect(paginateDate("agenda", anchor, 1, { timeZone: TZ, visibleDays: 7 }).toISOString()).toBe(
249
+ day(2026, 6, 22).toISOString(),
256
250
  )
257
- expect(paginateDate("agenda", anchor, -1, { timeZone: TZ }).toISOString()).toBe(
258
- day(2026, 5, 15).toISOString(),
251
+ expect(paginateDate("agenda", anchor, -1, { timeZone: TZ, visibleDays: 7 }).toISOString()).toBe(
252
+ day(2026, 6, 8).toISOString(),
259
253
  )
260
254
  })
261
255
 
262
- /** Without the clamp a Jan 31 anchor would land on Mar 2/3, i.e. Next would
263
- * skip February entirely. `@internationalized/date` handles it; this pins
264
- * that we rely on it. */
265
- it("clamps an agenda step onto a shorter month", () => {
266
- expect(paginateDate("agenda", day(2026, 0, 31), 1, { timeZone: TZ }).toISOString()).toBe(
267
- day(2026, 1, 28).toISOString(),
268
- )
269
- })
270
-
271
- it("steps the agenda exactly as the month view does", () => {
256
+ it("steps the agenda exactly as the days view does", () => {
272
257
  const anchor = day(2026, 6, 15)
273
- expect(paginateDate("agenda", anchor, 1, { timeZone: TZ }).toISOString()).toBe(
274
- paginateDate("month", anchor, 1, { timeZone: TZ }).toISOString(),
258
+ expect(paginateDate("agenda", anchor, 1, { timeZone: TZ, visibleDays: 5 }).toISOString()).toBe(
259
+ paginateDate("days", anchor, 1, { timeZone: TZ, visibleDays: 5 }).toISOString(),
275
260
  )
276
261
  })
277
262
 
@@ -526,14 +511,14 @@ describe("formatScheduleTitle", () => {
526
511
  expect(formatScheduleTitle("days", anchor, { ...opts, visibleDays: 1 })).toBe("July 15, 2026")
527
512
  expect(formatScheduleTitle("month", anchor, opts)).toBe("July 2026")
528
513
  expect(formatScheduleTitle("year", anchor, opts)).toBe("2026")
529
- expect(formatScheduleTitle("agenda", anchor, opts)).toBe("July 2026")
530
514
  })
531
515
 
532
- it("titles the agenda exactly as the month view", () => {
516
+ /** Days would snap this Wednesday anchor back to Sunday the 12th; the
517
+ * agenda's title names the window it really lists, from the anchor on. */
518
+ it("titles the agenda with its own range, starting at the anchor", () => {
533
519
  const anchor = day(2026, 6, 15)
534
- expect(formatScheduleTitle("agenda", anchor, opts)).toBe(
535
- formatScheduleTitle("month", anchor, opts),
536
- )
520
+ expect(formatScheduleTitle("agenda", anchor, opts)).toBe("Jul 15 – 21, 2026")
521
+ expect(formatScheduleTitle("agenda", anchor, { ...opts, visibleDays: 1 })).toBe("July 15, 2026")
537
522
  })
538
523
 
539
524
  it("condenses a same-month 7-day range (the default visibleDays)", () => {
@@ -750,22 +735,22 @@ describe("isEventInVisibleRange", () => {
750
735
 
751
736
  describe("isEventInVisibleRange — agenda", () => {
752
737
  const opts = { timeZone: "UTC", locale: "en-US" } as const
753
- const anchor = new Date(Date.UTC(2026, 8, 15, 12)) // September 2026
738
+ const anchor = new Date(Date.UTC(2026, 8, 15, 12)) // Tue 15 Sep → window 15–21 Sep
754
739
  const at = (m: number, d: number, h = 0) => new Date(Date.UTC(2026, m, d, h))
755
740
  const inAgenda = (start: Date, end: Date) =>
756
741
  isEventInVisibleRange({ start, end }, "agenda", anchor, opts)
757
742
 
758
- it("sees an event inside the anchored month", () => {
759
- expect(inAgenda(at(8, 2, 9), at(8, 2, 10))).toBe(true)
760
- expect(inAgenda(at(8, 30, 9), at(8, 30, 10))).toBe(true)
743
+ it("sees an event inside the window, including earlier on the anchor's day", () => {
744
+ expect(inAgenda(at(8, 15, 9), at(8, 15, 10))).toBe(true)
745
+ expect(inAgenda(at(8, 21, 22), at(8, 21, 23))).toBe(true)
761
746
  })
762
747
 
763
- it("does not see an event in an adjacent month", () => {
764
- expect(inAgenda(at(7, 31, 9), at(7, 31, 10))).toBe(false)
765
- expect(inAgenda(at(9, 1, 9), at(9, 1, 10))).toBe(false)
748
+ it("does not see an event before the anchor's day or past the window", () => {
749
+ expect(inAgenda(at(8, 14, 9), at(8, 14, 10))).toBe(false)
750
+ expect(inAgenda(at(8, 22, 9), at(8, 22, 10))).toBe(false)
766
751
  })
767
752
 
768
- it("sees a multi-day event that only straddles the month start", () => {
769
- expect(inAgenda(at(7, 28), at(8, 2))).toBe(true)
753
+ it("sees a multi-day event that only straddles the window start", () => {
754
+ expect(inAgenda(at(8, 12), at(8, 16))).toBe(true)
770
755
  })
771
756
  })
@@ -158,23 +158,19 @@ export function getVisibleRange(view: ScheduleView, date: Date, options: RangeOp
158
158
  return { start, end }
159
159
  })
160
160
  .with("agenda", () => {
161
- // The **strict** calendar month, deliberately not `"month"`'s padded
162
- // six-week grid. Month pads because the adjacent-month days are real
163
- // cells on screen whose events have to be queried; the agenda has no
164
- // cells — it lists what the title claims, so padding would open a
165
- // September list with three late-August rows and double-list every
166
- // seam day across two consecutive months.
161
+ // A list window that **starts at the anchor itself** and runs
162
+ // `visibleDays` days — `"relative"` Days, never a calendar snap. A list
163
+ // is read top to bottom, so wherever it starts is what the reader sees
164
+ // first: snapping to the 1st of the month (the old window) buried today
165
+ // halfway down and left the Now button with nothing visible to do.
167
166
  //
168
- // The sharper reason it cannot reuse Month's range: `Root`'s reveal
169
- // asks `isEventInVisibleRange(event, currentView, ...)`, which is a
170
- // composition over this function. Under the padded range that answers
171
- // "yes, already visible" for an August 31st event the agenda does not
172
- // list, so `Root` declines to move the anchor and the selected event is
173
- // nowhere on screen. Strict bounds keep "is it in range" and "is it
174
- // rendered" the same predicate over the same range.
175
- const start = midnightOf(startOfMonth(value))
176
- const end = midnightOf(endOfMonth(value)).add({ days: 1 })
177
- return { start, end }
167
+ // Still unpadded, and still the one range both "is it in range" and "is
168
+ // it rendered" are asked against: `Root`'s reveal asks
169
+ // `isEventInVisibleRange(event, "agenda", ...)`, a composition over this
170
+ // function, and an event outside it moves the anchor onto that event's
171
+ // own day — so the reveal needs no agenda-specific code.
172
+ const start = midnightOf(value)
173
+ return { start, end: start.add({ days: visibleDays }) }
178
174
  })
179
175
  .exhaustive()
180
176
 
@@ -195,12 +191,12 @@ export function paginateDate(
195
191
  ): Date {
196
192
  const value = toZoned(date, options.timeZone)
197
193
  const duration = match(view)
198
- .with("days", () => ({ days: options.visibleDays ?? 7 }))
199
- // One pattern, not two branches: "the agenda is month-windowed" is stated
200
- // once, so the two can never drift into stepping differently.
194
+ // One pattern, not two branches: the agenda's window is a days-window
195
+ // that starts at the anchor, so it steps exactly as Days does.
196
+ .with("days", "agenda", () => ({ days: options.visibleDays ?? 7 }))
201
197
  // `@internationalized/date`'s `add({ months: 1 })` clamps Jan 31 to Feb
202
198
  // 28/29, so Prev/Next never skips a month.
203
- .with("month", "agenda", () => ({ months: 1 }))
199
+ .with("month", () => ({ months: 1 }))
204
200
  .with("year", () => ({ years: 1 }))
205
201
  .exhaustive()
206
202
  const next = direction === 1 ? value.add(duration) : value.subtract(duration)
@@ -605,12 +601,15 @@ export function formatScheduleTitle(
605
601
  const { timeZone, locale = DEFAULT_LOCALE, startOfWeek, visibleDays } = options
606
602
  return (
607
603
  match(view)
608
- .with("days", () => {
604
+ // The agenda's window is a days-window (see `getVisibleRange`), so its
605
+ // title is the same range label — computed from its own range, which
606
+ // never snaps, rather than Days'.
607
+ .with("days", "agenda", (v) => {
609
608
  const days = visibleDays ?? 7
610
609
  if (days === 1) {
611
610
  return new Intl.DateTimeFormat(locale, { dateStyle: "long", timeZone }).format(date)
612
611
  }
613
- const range = getVisibleRange("days", date, {
612
+ const range = getVisibleRange(v, date, {
614
613
  timeZone,
615
614
  locale,
616
615
  startOfWeek,
@@ -621,9 +620,7 @@ export function formatScheduleTitle(
621
620
  .formatRange(range.start, lastDay)
622
621
  .normalize("NFKC")
623
622
  })
624
- // Same merge, same reason, as `paginateDate` above: the agenda's title is
625
- // Month's by construction rather than by a copied format object.
626
- .with("month", "agenda", () =>
623
+ .with("month", () =>
627
624
  new Intl.DateTimeFormat(locale, { month: "long", year: "numeric", timeZone }).format(date),
628
625
  )
629
626
  .with("year", () =>
@@ -3,6 +3,7 @@
3
3
  import { ark, type HTMLArkProps } from "@ark-ui/react"
4
4
  import type { Ref } from "react"
5
5
  import { useRef } from "react"
6
+ import type { NoAsChild } from "../../lib/as-child"
6
7
  import { cn } from "../../lib/cn"
7
8
  import { useLocale, useTimeZone } from "../../lib/intl"
8
9
  import { mergeRefs } from "../../lib/merge-refs"
@@ -57,7 +58,7 @@ export type DaysViewBaseProps<P = unknown> = ScheduleSharedProps<P> &
57
58
  // two intersect into a handler that has to satisfy *both* signatures, so the
58
59
  // declaration compiles and every call site fails. The kit already uses this
59
60
  // treatment for other redefined natives.
60
- Omit<HTMLArkProps<"div">, "onSelect"> &
61
+ NoAsChild<Omit<HTMLArkProps<"div">, "onSelect">> &
61
62
  WithTestId & {
62
63
  /** How many day-columns to show at once. Default `7`. */
63
64
  visibleDays?: number
@@ -145,6 +146,7 @@ export function DaysViewBody<P = unknown>({
145
146
  gridRef,
146
147
  nowRef,
147
148
  testId,
149
+ asChild: _asChild,
148
150
  ...rest
149
151
  }: DaysViewBaseProps<P> & ScheduleSlotValues) {
150
152
  const locale = useLocale(localeProp)
@@ -3,6 +3,7 @@
3
3
  import { ark, type HTMLArkProps } from "@ark-ui/react"
4
4
  import type { ReactNode } from "react"
5
5
  import { useRef } from "react"
6
+ import type { NoAsChild } from "../../lib/as-child"
6
7
  import { cn } from "../../lib/cn"
7
8
  import { focusStyles } from "../../lib/focus-styles"
8
9
  import { useLocale, useTimeZone } from "../../lib/intl"
@@ -89,7 +90,7 @@ export type MonthViewProps<P = unknown> = ScheduleSharedProps<P> &
89
90
  // two intersect into a handler that has to satisfy *both* signatures, so the
90
91
  // declaration compiles and every call site fails. The kit already uses this
91
92
  // treatment for other redefined natives.
92
- Omit<HTMLArkProps<"div">, "onSelect"> &
93
+ NoAsChild<Omit<HTMLArkProps<"div">, "onSelect">> &
93
94
  WithTestId & {
94
95
  /** Locale default when omitted. */
95
96
  startOfWeek?: FirstDayOfWeek
@@ -511,6 +512,7 @@ export function MonthView<P = unknown>({
511
512
  dayDisabled,
512
513
  maxEventsPerDay = 3,
513
514
  testId,
515
+ asChild: _asChild,
514
516
  ...rest
515
517
  }: MonthViewProps<P>) {
516
518
  const locale = useLocale(localeProp)
@@ -2,6 +2,7 @@
2
2
 
3
3
  import { ark, type HTMLArkProps } from "@ark-ui/react"
4
4
  import type { ReactNode } from "react"
5
+ import type { NoAsChild } from "../../lib/as-child"
5
6
  import { cn } from "../../lib/cn"
6
7
  import { useLocale, useTimeZone } from "../../lib/intl"
7
8
  import { props } from "../../lib/props"
@@ -22,7 +23,7 @@ import { resolveScheduleTranslations } from "./schedule-types"
22
23
  * time label).
23
24
  *
24
25
  * It renders the very same list `AgendaView` does (`schedule-agenda-list.tsx`)
25
- * over a different window: `AgendaView` shows one calendar month and is a
26
+ * over a different window: `AgendaView` shows a span of days from its date and is a
26
27
  * toolbar-switchable view; this shows everything from now on, unbounded, and
27
28
  * is not. That makes it the standalone preset — a sidebar/dashboard "what's
28
29
  * next" panel — rather than a fourth grid.
@@ -54,7 +55,9 @@ export type ScheduleNextUpClassNames = ScheduleAgendaListClassNames
54
55
  * `ScheduleNextUpClassNames` above. */
55
56
  export type NextUpEventRenderState = AgendaEventRenderState
56
57
 
57
- export type ScheduleNextUpProps<P = unknown> = Omit<HTMLArkProps<"section">, "children"> &
58
+ export type ScheduleNextUpProps<P = unknown> = NoAsChild<
59
+ Omit<HTMLArkProps<"section">, "children">
60
+ > &
58
61
  WithTestId & {
59
62
  /** Both interactive and read-only events, merged — `NextUp` never
60
63
  * drags, resizes, or removes anything, so there's no reason to force
@@ -105,6 +108,7 @@ export function ScheduleNextUp<P = unknown>({
105
108
  classNames,
106
109
  className,
107
110
  testId,
111
+ asChild: _asChild,
108
112
  ...rest
109
113
  }: ScheduleNextUpProps<P>) {
110
114
  const locale = useLocale(localeProp)
@@ -0,0 +1,26 @@
1
+ import { render, screen } from "@testing-library/react"
2
+ import { describe, expect, it } from "vitest"
3
+ import { ScheduleToolbar } from "./schedule-toolbar"
4
+
5
+ const MARCH = new Date("2026-03-04T10:00:00Z")
6
+
7
+ describe("ScheduleToolbar.Title", () => {
8
+ it("renders the computed title in its own heading", () => {
9
+ render(<ScheduleToolbar.Title view="month" date={MARCH} timeZone="UTC" locale="en-US" />)
10
+ expect(screen.getByRole("heading", { level: 2 }).textContent).toBe("March 2026")
11
+ })
12
+
13
+ // The computed string used to replace the children outright, so under
14
+ // `asChild` Ark got a string instead of an element and rendered nothing.
15
+ it("fills an empty asChild element with the computed title", () => {
16
+ render(
17
+ <ScheduleToolbar.Title asChild view="month" date={MARCH} timeZone="UTC" locale="en-US">
18
+ {/* biome-ignore lint/a11y/useHeadingContent: the computed title is what fills the empty heading */}
19
+ <h1 />
20
+ </ScheduleToolbar.Title>,
21
+ )
22
+ const heading = screen.getByRole("heading", { level: 1 })
23
+ expect(heading.textContent).toBe("March 2026")
24
+ expect(heading.getAttribute("data-schedule-part")).toBe("toolbar-title")
25
+ })
26
+ })
@@ -2,6 +2,7 @@
2
2
 
3
3
  import { ark, type HTMLArkProps } from "@ark-ui/react"
4
4
  import { ChevronLeftIcon, ChevronRightIcon } from "lucide-react"
5
+ import { withAsChildContent } from "../../lib/as-child"
5
6
  import { cn } from "../../lib/cn"
6
7
  import { useLocale, useTimeZone } from "../../lib/intl"
7
8
  import { props } from "../../lib/props"
@@ -177,18 +178,29 @@ const ScheduleToolbarTitle = ({
177
178
  visibleDays,
178
179
  className,
179
180
  testId,
181
+ asChild,
182
+ children,
180
183
  ...rest
181
184
  }: ScheduleToolbarTitleProps) => {
182
185
  const locale = useLocale(localeProp)
183
186
  const timeZone = useTimeZone(timeZoneProp)
187
+ const title = formatScheduleTitle(view, date, {
188
+ timeZone,
189
+ locale,
190
+ startOfWeek: align,
191
+ visibleDays,
192
+ })
184
193
  return (
185
194
  <ark.h2
195
+ asChild={asChild}
186
196
  data-schedule-part="toolbar-title"
187
197
  className={cn("truncate font-semibold text-sm", className)}
188
198
  {...props({ "data-testid": testId })}
189
199
  {...rest}
190
200
  >
191
- {formatScheduleTitle(view, date, { timeZone, locale, startOfWeek: align, visibleDays })}
201
+ {/* Under `asChild` the computed title fills the consumer's element (an
202
+ `<h1>`, say) unless that element brings its own content. */}
203
+ {asChild ? withAsChildContent(children, (own) => own ?? title) : title}
192
204
  </ark.h2>
193
205
  )
194
206
  }
@@ -6,7 +6,7 @@ import type { ScheduleSlotPredicate } from "../../lib/schedule-predicates"
6
6
 
7
7
  /**
8
8
  * A closed subset of the kit's full palette (`lib/colors.ts`), not the
9
- * shared `Color` type: `brand` and `gray` are excluded (reserved for chrome),
9
+ * shared `Color` type: `brand` and `neutral` are excluded (reserved for chrome),
10
10
  * and there's no custom-string escape hatch — every allowed value's
11
11
  * `--c-text`/`--c-soft` pairing has been checked against a white/near-black
12
12
  * grid background, a guarantee an arbitrary custom color couldn't make.
@@ -371,7 +371,7 @@ export type ScheduleTranslations = {
371
371
  days?: string
372
372
  month?: string
373
373
  year?: string
374
- /** The `"agenda"` view-switcher entry — the month-windowed event list. */
374
+ /** The `"agenda"` view-switcher entry — the event list. */
375
375
  agenda?: string
376
376
  empty?: string
377
377
  removeEvent?: string
@@ -623,8 +623,10 @@ export type ScheduleEventProps<P = unknown> = {
623
623
  */
624
624
  withSelection?: boolean
625
625
  /**
626
- * Default `true`. Whether the built-in event-details popover mounts for the
627
- * selected event.
626
+ * Default `true` — except in the agenda, whose rows already print the title,
627
+ * time and description, so it defaults to `false` there unless
628
+ * `renderEventDetails` is passed. Whether the built-in event-details popover
629
+ * mounts for the selected event.
628
630
  *
629
631
  * Set `false` when you are rendering the detail yourself (a side panel, a
630
632
  * drawer) and only want the selection state — the dashboard example does
@@ -38,8 +38,8 @@ export type ScheduleViewOptionObject = {
38
38
  * shorthand, otherwise `"days"`. */
39
39
  view?: ScheduleView
40
40
  /** Overrides `ScheduleProps.visibleDays` while this entry is active.
41
- * Meaningful only for the `"days"` renderer; Month, Year and Agenda take no
42
- * window size. */
41
+ * Meaningful for the `"days"` and `"agenda"` renderers; Month and Year take
42
+ * no window size. */
43
43
  visibleDays?: number
44
44
  /** Overrides the `translations`-derived tab label. `ReactNode`, not `string`,
45
45
  * so a custom entry can carry an icon or a `<Trans>`-style element. */
@@ -200,9 +200,8 @@ const SHORTHANDS: {
200
200
  days: { id: "days", view: "days" },
201
201
  month: { id: "month", view: "month" },
202
202
  year: { id: "year", view: "year" },
203
- // Pins no `visibleDays` for the opposite reason `"days"` doesn't: not
204
- // "inherit the consumer's window" but "there is no day window at all" —
205
- // the agenda is month-scoped, exactly like `month` and `year`.
203
+ // Pins no `visibleDays`, for the same reason `"days"` doesn't: it inherits
204
+ // the consumer's window, so a week-sized Days and the agenda step in sync.
206
205
  agenda: { id: "agenda", view: "agenda" },
207
206
  }
208
207
 
@@ -1,6 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import { ark, type HTMLArkProps } from "@ark-ui/react"
4
+ import type { NoAsChild } from "../../lib/as-child"
4
5
  import { cn } from "../../lib/cn"
5
6
  import { focusStyles } from "../../lib/focus-styles"
6
7
  import { useLocale, useTimeZone } from "../../lib/intl"
@@ -54,7 +55,7 @@ export type YearViewProps<P = unknown> = ScheduleSharedProps<P> &
54
55
  ScheduleDayDisabledProps &
55
56
  AnchorDateProps &
56
57
  PaginationChromeProps &
57
- HTMLArkProps<"div"> &
58
+ NoAsChild<HTMLArkProps<"div">> &
58
59
  WithTestId &
59
60
  ScheduleYearOnlyProps
60
61
 
@@ -94,6 +95,7 @@ export function YearView<P = unknown>({
94
95
  now,
95
96
  dayDisabled,
96
97
  testId,
98
+ asChild: _asChild,
97
99
  ...rest
98
100
  }: YearViewProps<P>) {
99
101
  const locale = useLocale(localeProp)
@@ -3644,6 +3644,7 @@ describe("ScheduleRoot — several selected chips", () => {
3644
3644
  views={["days", "agenda"]}
3645
3645
  view="agenda"
3646
3646
  selected={["offer:before", "offer:after"]}
3647
+ withEventDetails
3647
3648
  />,
3648
3649
  )
3649
3650
  const rows = document.querySelectorAll('[data-schedule-part="agenda-event"][data-selected]')
@@ -3856,20 +3857,30 @@ describe("ScheduleRoot — the agenda view", () => {
3856
3857
  ),
3857
3858
  ).map((el) => el.dataset["eventId"])
3858
3859
 
3860
+ // "Today" is Tue 15 Sep, so the default 7-day window is 15–21 Sep: one
3861
+ // event in it, one the week after, and one earlier in the same month that a
3862
+ // month window would have listed first.
3859
3863
  const SEPT: ScheduleEvent[] = [
3860
3864
  {
3861
3865
  kind: "event",
3862
- id: "sept",
3863
- title: "Sept planning",
3864
- start: day(2026, 8, 10, 9),
3865
- end: day(2026, 8, 10, 10),
3866
+ id: "this-week",
3867
+ title: "Planning",
3868
+ start: day(2026, 8, 16, 9),
3869
+ end: day(2026, 8, 16, 10),
3870
+ },
3871
+ {
3872
+ kind: "event",
3873
+ id: "next-week",
3874
+ title: "Retro",
3875
+ start: day(2026, 8, 23, 9),
3876
+ end: day(2026, 8, 23, 10),
3866
3877
  },
3867
3878
  {
3868
3879
  kind: "event",
3869
- id: "oct",
3870
- title: "Oct retro",
3871
- start: day(2026, 9, 10, 9),
3872
- end: day(2026, 9, 10, 10),
3880
+ id: "last-week",
3881
+ title: "Kickoff",
3882
+ start: day(2026, 8, 10, 9),
3883
+ end: day(2026, 8, 10, 10),
3873
3884
  },
3874
3885
  ]
3875
3886
  const SEPT_NOW = day(2026, 8, 15, 12)
@@ -3880,7 +3891,7 @@ describe("ScheduleRoot — the agenda view", () => {
3880
3891
  expect(tabNames()).toEqual(["Week", "Agenda", "Month"])
3881
3892
  })
3882
3893
 
3883
- it("renders the agenda, titled and windowed by month", () => {
3894
+ it("renders the agenda from today, titled by its range", () => {
3884
3895
  render(
3885
3896
  <ScheduleRoot
3886
3897
  data={SEPT}
@@ -3891,11 +3902,25 @@ describe("ScheduleRoot — the agenda view", () => {
3891
3902
  />,
3892
3903
  )
3893
3904
  expect(agenda()).not.toBeNull()
3894
- expect(title()).toBe("September 2026")
3895
- expect(rowIds()).toEqual(["sept"])
3905
+ expect(title()).toBe("15 – 21 Sept 2026")
3906
+ expect(rowIds()).toEqual(["this-week"])
3907
+ })
3908
+
3909
+ it("takes its span from an entry's own visibleDays", () => {
3910
+ render(
3911
+ <ScheduleRoot
3912
+ data={SEPT}
3913
+ now={SEPT_NOW}
3914
+ timeZone="UTC"
3915
+ locale="en-GB"
3916
+ views={[{ id: "agenda", visibleDays: 14 }]}
3917
+ />,
3918
+ )
3919
+ expect(title()).toBe("15 – 28 Sept 2026")
3920
+ expect(rowIds()).toEqual(["this-week", "next-week"])
3896
3921
  })
3897
3922
 
3898
- it("steps a month per Prev/Next from Root's own toolbar", () => {
3923
+ it("steps by its span per Prev/Next from Root's own toolbar", () => {
3899
3924
  render(
3900
3925
  <ScheduleRoot
3901
3926
  data={SEPT}
@@ -3906,8 +3931,8 @@ describe("ScheduleRoot — the agenda view", () => {
3906
3931
  />,
3907
3932
  )
3908
3933
  fireEvent.click(screen.getByRole("button", { name: "Next" }))
3909
- expect(title()).toBe("October 2026")
3910
- expect(rowIds()).toEqual(["oct"])
3934
+ expect(title()).toBe("22 – 28 Sept 2026")
3935
+ expect(rowIds()).toEqual(["next-week"])
3911
3936
  })
3912
3937
 
3913
3938
  it("suppresses the view's own pagination chrome", () => {
@@ -3933,16 +3958,18 @@ describe("ScheduleRoot — the agenda view", () => {
3933
3958
  '[data-schedule-part="agenda-event-trigger"]',
3934
3959
  )
3935
3960
  if (control) fireEvent.click(control)
3936
- expect(onSelect).toHaveBeenCalledWith(expect.objectContaining({ id: "sept" }))
3961
+ expect(onSelect).toHaveBeenCalledWith(expect.objectContaining({ id: "this-week" }))
3962
+ // Selecting is all a click does here: the row already shows the details.
3963
+ expect(screen.queryByRole("dialog")).toBeNull()
3937
3964
  })
3938
3965
 
3939
3966
  /**
3940
3967
  * The load-bearing integration: `Root`'s reveal effect asks
3941
- * `isEventInVisibleRange`, which resolves the agenda's strict month — so a
3942
- * selection outside the window pages to it with no agenda-specific code in
3943
- * `Root` at all. It is tested precisely *because* nothing implements it.
3968
+ * `isEventInVisibleRange`, which resolves the agenda's own window — so a
3969
+ * selection outside it pages there with no agenda-specific code in `Root`
3970
+ * at all. It is tested precisely *because* nothing implements it.
3944
3971
  */
3945
- it("pages to a selection outside the current month", () => {
3972
+ it("pages to a selection outside the current window", () => {
3946
3973
  const onDateChange = vi.fn()
3947
3974
  render(
3948
3975
  <ScheduleRoot
@@ -3950,14 +3977,31 @@ describe("ScheduleRoot — the agenda view", () => {
3950
3977
  now={SEPT_NOW}
3951
3978
  timeZone="UTC"
3952
3979
  views={["agenda"]}
3953
- selected="oct"
3980
+ selected="next-week"
3954
3981
  onDateChange={onDateChange}
3955
3982
  />,
3956
3983
  )
3957
3984
  expect(onDateChange).toHaveBeenCalledWith(SEPT[1]?.start)
3958
3985
  })
3959
3986
 
3960
- it("leaves the anchor alone for a selection already in the month", () => {
3987
+ /** Earlier in the same month: a month window used to list it, so this is
3988
+ * the case that changed. */
3989
+ it("pages back to a selection before the window", () => {
3990
+ const onDateChange = vi.fn()
3991
+ render(
3992
+ <ScheduleRoot
3993
+ data={SEPT}
3994
+ now={SEPT_NOW}
3995
+ timeZone="UTC"
3996
+ views={["agenda"]}
3997
+ selected="last-week"
3998
+ onDateChange={onDateChange}
3999
+ />,
4000
+ )
4001
+ expect(onDateChange).toHaveBeenCalledWith(SEPT[2]?.start)
4002
+ })
4003
+
4004
+ it("leaves the anchor alone for a selection already in the window", () => {
3961
4005
  const onDateChange = vi.fn()
3962
4006
  render(
3963
4007
  <ScheduleRoot
@@ -3965,7 +4009,7 @@ describe("ScheduleRoot — the agenda view", () => {
3965
4009
  now={SEPT_NOW}
3966
4010
  timeZone="UTC"
3967
4011
  views={["agenda"]}
3968
- selected="sept"
4012
+ selected="this-week"
3969
4013
  onDateChange={onDateChange}
3970
4014
  />,
3971
4015
  )