@weasel-js/ui 1.5.2 → 1.6.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 (565) hide show
  1. package/dist/chunks/ActionBar-DCq16yFA.js +57 -0
  2. package/dist/chunks/ActionBar-DCq16yFA.js.map +1 -0
  3. package/dist/chunks/{Badge-CW9pBPFl.js → Badge-CyAIZSDo.js} +758 -741
  4. package/dist/chunks/Badge-CyAIZSDo.js.map +1 -0
  5. package/dist/chunks/{BandEditor-jY-PFKY6.js → BandEditor-Dhm_Xrlr.js} +37 -36
  6. package/dist/chunks/BandEditor-Dhm_Xrlr.js.map +1 -0
  7. package/dist/chunks/Button-BIdXHQOx.js +111 -0
  8. package/dist/chunks/Button-BIdXHQOx.js.map +1 -0
  9. package/dist/chunks/ButtonBar-D5Vi0aj_.js +46 -0
  10. package/dist/chunks/ButtonBar-D5Vi0aj_.js.map +1 -0
  11. package/dist/chunks/Callout-yEn9iPlh.js +119 -0
  12. package/dist/chunks/Callout-yEn9iPlh.js.map +1 -0
  13. package/dist/chunks/{Checkbox-BOsDAY2F.js → Checkbox-DHXTUHO9.js} +1 -1
  14. package/dist/chunks/Checkbox-DHXTUHO9.js.map +1 -0
  15. package/dist/chunks/Code-AsKpgnv6.js +24 -0
  16. package/dist/chunks/Code-AsKpgnv6.js.map +1 -0
  17. package/dist/chunks/{ColorField-BYzgZM9o.js → ColorField-BcMcW8Sa.js} +16 -16
  18. package/dist/chunks/ColorField-BcMcW8Sa.js.map +1 -0
  19. package/dist/chunks/ColorModeControl-ke5PXbBa.js +47 -0
  20. package/dist/chunks/ColorModeControl-ke5PXbBa.js.map +1 -0
  21. package/dist/chunks/{ComboBox-Cz3f0Y_8.js → ComboBox-DpT8lc3p.js} +3 -3
  22. package/dist/chunks/ComboBox-DpT8lc3p.js.map +1 -0
  23. package/dist/chunks/{CurveEditor-DXwSP-iA.js → CurveEditor-BDJXjEvK.js} +35 -35
  24. package/dist/chunks/CurveEditor-BDJXjEvK.js.map +1 -0
  25. package/dist/chunks/DataGrid-D-dZj1BD.js +152 -0
  26. package/dist/chunks/DataGrid-D-dZj1BD.js.map +1 -0
  27. package/dist/chunks/DetailList-BMER1LUZ.js +43 -0
  28. package/dist/chunks/DetailList-BMER1LUZ.js.map +1 -0
  29. package/dist/chunks/{DetentSlider-CAubVX0J.js → DetentSlider-CL8TlX3S.js} +2 -2
  30. package/dist/chunks/DetentSlider-CL8TlX3S.js.map +1 -0
  31. package/dist/chunks/Dialog-BWyNMgpf.js +66 -0
  32. package/dist/chunks/Dialog-BWyNMgpf.js.map +1 -0
  33. package/dist/chunks/Disclosure-0G0uh2fa.js +58 -0
  34. package/dist/chunks/Disclosure-0G0uh2fa.js.map +1 -0
  35. package/dist/chunks/DragGhost-B5_hb9W9.js +30 -0
  36. package/dist/chunks/DragGhost-B5_hb9W9.js.map +1 -0
  37. package/dist/chunks/{DragHandleGlyph-CppAz4_8.js → DragHandleGlyph-Dr7Fgo0I.js} +1 -1
  38. package/dist/chunks/DragHandleGlyph-Dr7Fgo0I.js.map +1 -0
  39. package/dist/chunks/{Field-DWnV8WZY.js → Field--onYxXTF.js} +7 -6
  40. package/dist/chunks/Field--onYxXTF.js.map +1 -0
  41. package/dist/chunks/FillStrokeSwatch-DNb0KXPk.js +111 -0
  42. package/dist/chunks/FillStrokeSwatch-DNb0KXPk.js.map +1 -0
  43. package/dist/chunks/{FontFamilySelect-DxfgTC3G.js → FontFamilySelect-DXlMKWfK.js} +2 -2
  44. package/dist/chunks/FontFamilySelect-DXlMKWfK.js.map +1 -0
  45. package/dist/chunks/GradientEditor-B3a-MsVJ.js +335 -0
  46. package/dist/chunks/GradientEditor-B3a-MsVJ.js.map +1 -0
  47. package/dist/chunks/{Icon-DT0x6HaQ.js → Icon-Cgzy8VgC.js} +28 -20
  48. package/dist/chunks/Icon-Cgzy8VgC.js.map +1 -0
  49. package/dist/chunks/InlineRange-eOj6JpJl.js +29 -0
  50. package/dist/chunks/InlineRange-eOj6JpJl.js.map +1 -0
  51. package/dist/chunks/{Input-DbMKpkXy.js → Input-CHmkfYaD.js} +24 -19
  52. package/dist/chunks/Input-CHmkfYaD.js.map +1 -0
  53. package/dist/chunks/ItemList-Cm-HUWCi.js +174 -0
  54. package/dist/chunks/ItemList-Cm-HUWCi.js.map +1 -0
  55. package/dist/chunks/ItemList.module-BSpCSxan.js +14 -0
  56. package/dist/chunks/ItemList.module-BSpCSxan.js.map +1 -0
  57. package/dist/chunks/{Jog-DkkTlL3_.js → Jog-DESxZ44P.js} +6 -6
  58. package/dist/chunks/Jog-DESxZ44P.js.map +1 -0
  59. package/dist/chunks/{Keycaps-DunVpejA.js → Keycaps-C0H_v2gO.js} +71 -65
  60. package/dist/chunks/Keycaps-C0H_v2gO.js.map +1 -0
  61. package/dist/chunks/LayerList-nz-QYvTF.js +427 -0
  62. package/dist/chunks/LayerList-nz-QYvTF.js.map +1 -0
  63. package/dist/chunks/ListEditor-BQ6AV3Ac.js +74 -0
  64. package/dist/chunks/ListEditor-BQ6AV3Ac.js.map +1 -0
  65. package/dist/chunks/MenuButton-DtaGenKf.js +70 -0
  66. package/dist/chunks/MenuButton-DtaGenKf.js.map +1 -0
  67. package/dist/chunks/MeshEditor-qqGc6hlD.js +87 -0
  68. package/dist/chunks/MeshEditor-qqGc6hlD.js.map +1 -0
  69. package/dist/chunks/{NumberField-CCjEDZCg.js → NumberField-CwJOMmQR.js} +27 -22
  70. package/dist/chunks/NumberField-CwJOMmQR.js.map +1 -0
  71. package/dist/chunks/{OptionsBar-DeQ-vUeZ.js → OptionsBar-DbzAgIln.js} +3 -3
  72. package/dist/chunks/OptionsBar-DbzAgIln.js.map +1 -0
  73. package/dist/chunks/{PaintField-jBOJ32rL.js → PaintField-DaJukRc6.js} +21 -21
  74. package/dist/chunks/PaintField-DaJukRc6.js.map +1 -0
  75. package/dist/chunks/{PaintInput-Qs7Rul5R.js → PaintInput-Byhna3H-.js} +24 -24
  76. package/dist/chunks/PaintInput-Byhna3H-.js.map +1 -0
  77. package/dist/chunks/{PatternPicker-BMpXWboq.js → PatternPicker-B-cUt-JT.js} +2 -2
  78. package/dist/chunks/PatternPicker-B-cUt-JT.js.map +1 -0
  79. package/dist/chunks/{Plot2D-CXf_f7QD.js → Plot2D-CTXHkL5p.js} +13 -13
  80. package/dist/chunks/Plot2D-CTXHkL5p.js.map +1 -0
  81. package/dist/chunks/{PointPlotter-S_gz7VYt.js → PointPlotter-Bxo6haKe.js} +5 -4
  82. package/dist/chunks/PointPlotter-Bxo6haKe.js.map +1 -0
  83. package/dist/chunks/Powerline-ExO5GwEr.js +42 -0
  84. package/dist/chunks/Powerline-ExO5GwEr.js.map +1 -0
  85. package/dist/chunks/Prefs-DpqFKiwY.js +476 -0
  86. package/dist/chunks/Prefs-DpqFKiwY.js.map +1 -0
  87. package/dist/chunks/Properties-D_KzDN9K.js +282 -0
  88. package/dist/chunks/Properties-D_KzDN9K.js.map +1 -0
  89. package/dist/chunks/PropertyField-DGCecAnV.js +758 -0
  90. package/dist/chunks/PropertyField-DGCecAnV.js.map +1 -0
  91. package/dist/chunks/{RadioGroup-CsVp3SEu.js → RadioGroup-Bh4-12e-.js} +2 -2
  92. package/dist/chunks/RadioGroup-Bh4-12e-.js.map +1 -0
  93. package/dist/chunks/{RangeSlider-DNr-pJpZ.js → RangeSlider-BKRRTPTZ.js} +1 -1
  94. package/dist/chunks/RangeSlider-BKRRTPTZ.js.map +1 -0
  95. package/dist/chunks/{ResizeHandle-RXFf5fXr.js → ResizeHandle-BKT0XYpx.js} +15 -15
  96. package/dist/chunks/ResizeHandle-BKT0XYpx.js.map +1 -0
  97. package/dist/chunks/Select-CzyfaXzp.js +225 -0
  98. package/dist/chunks/Select-CzyfaXzp.js.map +1 -0
  99. package/dist/chunks/{SelectionPanel-CEbLS-0D.js → SelectionPanel-BgUM1h03.js} +21 -20
  100. package/dist/chunks/SelectionPanel-BgUM1h03.js.map +1 -0
  101. package/dist/chunks/{Sidebar-qn_oSCNX.js → Sidebar-BZ0m4afn.js} +8 -8
  102. package/dist/chunks/Sidebar-BZ0m4afn.js.map +1 -0
  103. package/dist/chunks/{SidebarPanel-Bs6V21hg.js → SidebarPanel-aoIqxbtq.js} +15 -19
  104. package/dist/chunks/SidebarPanel-aoIqxbtq.js.map +1 -0
  105. package/dist/chunks/{Slider-CIIrqiFS.js → Slider-CFwQYQ10.js} +94 -92
  106. package/dist/chunks/Slider-CFwQYQ10.js.map +1 -0
  107. package/dist/chunks/{StatusBar-B4L15DSm.js → StatusBar-DzoPDY4k.js} +8 -8
  108. package/dist/chunks/StatusBar-DzoPDY4k.js.map +1 -0
  109. package/dist/chunks/SwatchGrid-BARC3rnF.js +73 -0
  110. package/dist/chunks/SwatchGrid-BARC3rnF.js.map +1 -0
  111. package/dist/chunks/{Switch-DH5POG0T.js → Switch-CSYmcM8y.js} +1 -1
  112. package/dist/chunks/Switch-CSYmcM8y.js.map +1 -0
  113. package/dist/chunks/{Tabs-BFHikpml.js → Tabs-BbpzLLdY.js} +1 -1
  114. package/dist/chunks/Tabs-BbpzLLdY.js.map +1 -0
  115. package/dist/chunks/{Timeline-DNKY_yiK.js → Timeline--58F7MED.js} +141 -145
  116. package/dist/chunks/Timeline--58F7MED.js.map +1 -0
  117. package/dist/chunks/{Toast-CI1UDuK6.js → Toast-DNBb-24H.js} +1 -1
  118. package/dist/chunks/Toast-DNBb-24H.js.map +1 -0
  119. package/dist/chunks/ToggleBar-DTjGeS0Q.js +82 -0
  120. package/dist/chunks/ToggleBar-DTjGeS0Q.js.map +1 -0
  121. package/dist/chunks/{TokenPanel-BPHq24dc.js → TokenPanel-CMq7uydV.js} +50 -47
  122. package/dist/chunks/TokenPanel-CMq7uydV.js.map +1 -0
  123. package/dist/chunks/{ToolButton-9QzJCmuM.js → ToolButton-CR4sQlxF.js} +4 -4
  124. package/dist/chunks/ToolButton-CR4sQlxF.js.map +1 -0
  125. package/dist/chunks/{ToolGroup-BJiDrH_i.js → ToolGroup-Dpg1LN0l.js} +7 -7
  126. package/dist/chunks/ToolGroup-Dpg1LN0l.js.map +1 -0
  127. package/dist/chunks/{ToolOptionsBar-CAM6RcUH.js → ToolOptionsBar-CtzTlaN2.js} +6 -5
  128. package/dist/chunks/ToolOptionsBar-CtzTlaN2.js.map +1 -0
  129. package/dist/chunks/ToolPalette-CKG9qY6P.js +83 -0
  130. package/dist/chunks/ToolPalette-CKG9qY6P.js.map +1 -0
  131. package/dist/chunks/Tooltip-Clg2mhSt.js +42 -0
  132. package/dist/chunks/Tooltip-Clg2mhSt.js.map +1 -0
  133. package/dist/chunks/Tree-DVOtc9R5.js +203 -0
  134. package/dist/chunks/Tree-DVOtc9R5.js.map +1 -0
  135. package/dist/chunks/{createKeyframeLayer-DKtO0Sw_.js → createKeyframeLayer-Czj6Y235.js} +86 -86
  136. package/dist/chunks/createKeyframeLayer-Czj6Y235.js.map +1 -0
  137. package/dist/chunks/{dlog-CMYiRF3Q.js → dlog-F0I8KsIW.js} +2 -2
  138. package/dist/chunks/dlog-F0I8KsIW.js.map +1 -0
  139. package/dist/chunks/formatShortcut-DRQrVThu.js +15 -0
  140. package/dist/chunks/formatShortcut-DRQrVThu.js.map +1 -0
  141. package/dist/chunks/icons-Dk8SRS8g.js +162 -0
  142. package/dist/chunks/icons-Dk8SRS8g.js.map +1 -0
  143. package/dist/chunks/interactiveTarget-BNZmTow2.js +24 -0
  144. package/dist/chunks/interactiveTarget-BNZmTow2.js.map +1 -0
  145. package/dist/chunks/{keyGlyph-Bp0wnLHn.js → keyGlyph-C0qTakG-.js} +1 -1
  146. package/dist/chunks/keyGlyph-C0qTakG-.js.map +1 -0
  147. package/dist/chunks/model-Du7Lta4C.js +360 -0
  148. package/dist/chunks/model-Du7Lta4C.js.map +1 -0
  149. package/dist/chunks/{number-BHz66zQO.js → number-D3NEx_8r.js} +3 -3
  150. package/dist/chunks/number-D3NEx_8r.js.map +1 -0
  151. package/dist/chunks/paintPreview-CuSZiHpR.js +42 -0
  152. package/dist/chunks/paintPreview-CuSZiHpR.js.map +1 -0
  153. package/dist/chunks/paintValue-BpaGPjV3.js +18 -0
  154. package/dist/chunks/paintValue-BpaGPjV3.js.map +1 -0
  155. package/dist/chunks/{portalHost-CjpCnuGU.js → portalHost-yTOVuCej.js} +1 -1
  156. package/dist/chunks/portalHost-yTOVuCej.js.map +1 -0
  157. package/dist/chunks/prefField-Dnl7nmjQ.js +197 -0
  158. package/dist/chunks/prefField-Dnl7nmjQ.js.map +1 -0
  159. package/dist/chunks/segmentTooltip-CStYHKzd.js +29 -0
  160. package/dist/chunks/segmentTooltip-CStYHKzd.js.map +1 -0
  161. package/dist/chunks/segmentedControl.module-Bv7DEg8f.js +11 -0
  162. package/dist/chunks/segmentedControl.module-Bv7DEg8f.js.map +1 -0
  163. package/dist/chunks/{snap-CEjuWOhN.js → snap-DRjbOiG9.js} +1 -1
  164. package/dist/chunks/snap-DRjbOiG9.js.map +1 -0
  165. package/dist/chunks/stance-BFQpS_fL.js +17 -0
  166. package/dist/chunks/stance-BFQpS_fL.js.map +1 -0
  167. package/dist/chunks/useReorderDragList-B_-5L5Gu.js +131 -0
  168. package/dist/chunks/useReorderDragList-B_-5L5Gu.js.map +1 -0
  169. package/dist/chunks/{useRovingTabIndex-Dkpf_KhN.js → useRovingTabIndex-Bp_hYm_h.js} +1 -1
  170. package/dist/chunks/useRovingTabIndex-Bp_hYm_h.js.map +1 -0
  171. package/dist/color/ramp.d.ts +38 -0
  172. package/dist/color/ramp.d.ts.map +1 -0
  173. package/dist/components/ActionBar/ActionBar.d.ts +7 -5
  174. package/dist/components/ActionBar/ActionBar.d.ts.map +1 -1
  175. package/dist/components/ActionBar/index.js +1 -1
  176. package/dist/components/Badge/Badge.d.ts +21 -7
  177. package/dist/components/Badge/Badge.d.ts.map +1 -1
  178. package/dist/components/Badge/effects/Aqua.d.ts +1 -1
  179. package/dist/components/Badge/effects/Aqua.d.ts.map +1 -1
  180. package/dist/components/Badge/index.d.ts +1 -1
  181. package/dist/components/Badge/index.d.ts.map +1 -1
  182. package/dist/components/Badge/index.js +1 -1
  183. package/dist/components/Badge/types.d.ts +6 -5
  184. package/dist/components/Badge/types.d.ts.map +1 -1
  185. package/dist/components/BandEditor/index.js +1 -1
  186. package/dist/components/Button/Button.d.ts +17 -3
  187. package/dist/components/Button/Button.d.ts.map +1 -1
  188. package/dist/components/Button/index.d.ts +1 -1
  189. package/dist/components/Button/index.d.ts.map +1 -1
  190. package/dist/components/Button/index.js +1 -1
  191. package/dist/components/ButtonBar/ButtonBar.d.ts +36 -0
  192. package/dist/components/ButtonBar/ButtonBar.d.ts.map +1 -0
  193. package/dist/components/ButtonBar/index.d.ts +3 -0
  194. package/dist/components/ButtonBar/index.d.ts.map +1 -0
  195. package/dist/components/ButtonBar/index.js +2 -0
  196. package/dist/components/Callout/Callout.d.ts +3 -6
  197. package/dist/components/Callout/Callout.d.ts.map +1 -1
  198. package/dist/components/Callout/index.d.ts +1 -1
  199. package/dist/components/Callout/index.d.ts.map +1 -1
  200. package/dist/components/Callout/index.js +1 -1
  201. package/dist/components/Checkbox/index.js +1 -1
  202. package/dist/components/Code/Code.d.ts +28 -0
  203. package/dist/components/Code/Code.d.ts.map +1 -0
  204. package/dist/components/Code/index.d.ts +3 -0
  205. package/dist/components/Code/index.d.ts.map +1 -0
  206. package/dist/components/Code/index.js +2 -0
  207. package/dist/components/ColorField/ColorField.d.ts +1 -1
  208. package/dist/components/ColorField/ColorField.d.ts.map +1 -1
  209. package/dist/components/ColorField/index.js +1 -1
  210. package/dist/components/ColorModeControl/ColorModeControl.d.ts +21 -0
  211. package/dist/components/ColorModeControl/ColorModeControl.d.ts.map +1 -0
  212. package/dist/components/ColorModeControl/index.d.ts +3 -0
  213. package/dist/components/ColorModeControl/index.d.ts.map +1 -0
  214. package/dist/components/ColorModeControl/index.js +2 -0
  215. package/dist/components/ComboBox/ComboBox.d.ts +2 -2
  216. package/dist/components/ComboBox/ComboBox.d.ts.map +1 -1
  217. package/dist/components/ComboBox/index.js +1 -1
  218. package/dist/components/CurveEditor/CurveEditor.d.ts +1 -1
  219. package/dist/components/CurveEditor/CurveEditor.d.ts.map +1 -1
  220. package/dist/components/CurveEditor/LayeredCurveEditor.d.ts +1 -1
  221. package/dist/components/CurveEditor/LayeredCurveEditor.d.ts.map +1 -1
  222. package/dist/components/CurveEditor/index.js +3 -3
  223. package/dist/components/DataGrid/DataGrid.d.ts +23 -1
  224. package/dist/components/DataGrid/DataGrid.d.ts.map +1 -1
  225. package/dist/components/DataGrid/index.js +1 -1
  226. package/dist/components/DetailList/DetailList.d.ts +36 -0
  227. package/dist/components/DetailList/DetailList.d.ts.map +1 -0
  228. package/dist/components/DetailList/index.d.ts +3 -0
  229. package/dist/components/DetailList/index.d.ts.map +1 -0
  230. package/dist/components/DetailList/index.js +2 -0
  231. package/dist/components/DetentSlider/index.js +1 -1
  232. package/dist/components/Dialog/Dialog.d.ts +9 -3
  233. package/dist/components/Dialog/Dialog.d.ts.map +1 -1
  234. package/dist/components/Dialog/index.js +1 -1
  235. package/dist/components/Disclosure/Disclosure.d.ts +26 -18
  236. package/dist/components/Disclosure/Disclosure.d.ts.map +1 -1
  237. package/dist/components/Disclosure/index.d.ts +2 -2
  238. package/dist/components/Disclosure/index.d.ts.map +1 -1
  239. package/dist/components/Disclosure/index.js +2 -2
  240. package/dist/components/DragGhost/DragGhost.d.ts +21 -0
  241. package/dist/components/DragGhost/DragGhost.d.ts.map +1 -0
  242. package/dist/components/DragGhost/index.d.ts +3 -0
  243. package/dist/components/DragGhost/index.d.ts.map +1 -0
  244. package/dist/components/DragGhost/index.js +2 -0
  245. package/dist/components/DragHandleGlyph/DragHandleGlyph.d.ts +1 -1
  246. package/dist/components/DragHandleGlyph/DragHandleGlyph.d.ts.map +1 -1
  247. package/dist/components/DragHandleGlyph/index.js +1 -1
  248. package/dist/components/Field/Field.d.ts +1 -1
  249. package/dist/components/Field/Field.d.ts.map +1 -1
  250. package/dist/components/Field/index.js +1 -1
  251. package/dist/components/FillStrokeSwatch/FillStrokeSwatch.d.ts +45 -0
  252. package/dist/components/FillStrokeSwatch/FillStrokeSwatch.d.ts.map +1 -0
  253. package/dist/components/FillStrokeSwatch/index.d.ts +3 -0
  254. package/dist/components/FillStrokeSwatch/index.d.ts.map +1 -0
  255. package/dist/components/FillStrokeSwatch/index.js +2 -0
  256. package/dist/components/FontFamilySelect/FontFamilySelect.d.ts +1 -1
  257. package/dist/components/FontFamilySelect/FontFamilySelect.d.ts.map +1 -1
  258. package/dist/components/FontFamilySelect/index.js +1 -1
  259. package/dist/components/GradientEditor/SceneGradientHandles.d.ts.map +1 -1
  260. package/dist/components/GradientEditor/index.js +1 -1
  261. package/dist/components/InlineRange/InlineRange.d.ts +6 -2
  262. package/dist/components/InlineRange/InlineRange.d.ts.map +1 -1
  263. package/dist/components/InlineRange/index.js +1 -1
  264. package/dist/components/Input/Input.d.ts +13 -0
  265. package/dist/components/Input/Input.d.ts.map +1 -1
  266. package/dist/components/Input/index.js +1 -1
  267. package/dist/components/ItemList/ItemList.d.ts +70 -10
  268. package/dist/components/ItemList/ItemList.d.ts.map +1 -1
  269. package/dist/components/ItemList/index.js +1 -1
  270. package/dist/components/Jog/Jog.d.ts +1 -1
  271. package/dist/components/Jog/Jog.d.ts.map +1 -1
  272. package/dist/components/Jog/index.js +1 -1
  273. package/dist/components/Keycaps/Keycap.d.ts +1 -1
  274. package/dist/components/Keycaps/Keycap.d.ts.map +1 -1
  275. package/dist/components/Keycaps/Keycaps.d.ts +1 -1
  276. package/dist/components/Keycaps/Keycaps.d.ts.map +1 -1
  277. package/dist/components/Keycaps/index.d.ts +1 -0
  278. package/dist/components/Keycaps/index.d.ts.map +1 -1
  279. package/dist/components/Keycaps/index.js +3 -3
  280. package/dist/components/Keycaps/keySpecsFromMods.d.ts +2 -0
  281. package/dist/components/Keycaps/keySpecsFromMods.d.ts.map +1 -1
  282. package/dist/components/Keycaps/keySpecsFromShortcut.d.ts +16 -0
  283. package/dist/components/Keycaps/keySpecsFromShortcut.d.ts.map +1 -0
  284. package/dist/components/LayerList/LayerList.d.ts +79 -0
  285. package/dist/components/LayerList/LayerList.d.ts.map +1 -0
  286. package/dist/components/LayerList/index.d.ts +3 -0
  287. package/dist/components/LayerList/index.d.ts.map +1 -0
  288. package/dist/components/LayerList/index.js +2 -0
  289. package/dist/components/LayerList/useSceneLayerList.d.ts +20 -0
  290. package/dist/components/LayerList/useSceneLayerList.d.ts.map +1 -0
  291. package/dist/components/ListEditor/ListEditor.d.ts +23 -0
  292. package/dist/components/ListEditor/ListEditor.d.ts.map +1 -0
  293. package/dist/components/ListEditor/index.d.ts +3 -0
  294. package/dist/components/ListEditor/index.d.ts.map +1 -0
  295. package/dist/components/ListEditor/index.js +2 -0
  296. package/dist/components/MenuButton/MenuButton.d.ts +6 -2
  297. package/dist/components/MenuButton/MenuButton.d.ts.map +1 -1
  298. package/dist/components/MenuButton/index.js +1 -1
  299. package/dist/components/MeshEditor/index.js +1 -1
  300. package/dist/components/NumberField/NumberField.d.ts +13 -0
  301. package/dist/components/NumberField/NumberField.d.ts.map +1 -1
  302. package/dist/components/NumberField/UnitField.d.ts +1 -1
  303. package/dist/components/NumberField/UnitField.d.ts.map +1 -1
  304. package/dist/components/NumberField/index.js +1 -1
  305. package/dist/components/OptionsBar/index.js +1 -1
  306. package/dist/components/PaintField/index.js +1 -1
  307. package/dist/components/PaintInput/index.js +1 -1
  308. package/dist/components/PatternPicker/index.js +1 -1
  309. package/dist/components/Plot2D/index.js +1 -1
  310. package/dist/components/PointPlotter/PointPlotter.d.ts +1 -1
  311. package/dist/components/PointPlotter/PointPlotter.d.ts.map +1 -1
  312. package/dist/components/PointPlotter/index.js +1 -1
  313. package/dist/components/Powerline/Powerline.d.ts +5 -4
  314. package/dist/components/Powerline/Powerline.d.ts.map +1 -1
  315. package/dist/components/Powerline/index.js +2 -2
  316. package/dist/components/Prefs/PrefsDialog.d.ts +11 -3
  317. package/dist/components/Prefs/PrefsDialog.d.ts.map +1 -1
  318. package/dist/components/Prefs/PrefsForm.d.ts +27 -26
  319. package/dist/components/Prefs/PrefsForm.d.ts.map +1 -1
  320. package/dist/components/Prefs/PrefsPane.d.ts +24 -0
  321. package/dist/components/Prefs/PrefsPane.d.ts.map +1 -0
  322. package/dist/components/Prefs/PrefsRail.d.ts +32 -0
  323. package/dist/components/Prefs/PrefsRail.d.ts.map +1 -0
  324. package/dist/components/Prefs/PrefsRow.d.ts +32 -0
  325. package/dist/components/Prefs/PrefsRow.d.ts.map +1 -0
  326. package/dist/components/Prefs/index.d.ts +5 -2
  327. package/dist/components/Prefs/index.d.ts.map +1 -1
  328. package/dist/components/Prefs/index.js +3 -3
  329. package/dist/components/Prefs/prefField.d.ts +36 -0
  330. package/dist/components/Prefs/prefField.d.ts.map +1 -0
  331. package/dist/components/Prefs/schema.d.ts +30 -0
  332. package/dist/components/Prefs/schema.d.ts.map +1 -1
  333. package/dist/components/Properties/CurveField.d.ts +1 -1
  334. package/dist/components/Properties/CurveField.d.ts.map +1 -1
  335. package/dist/components/Properties/DialogRow.d.ts +33 -0
  336. package/dist/components/Properties/DialogRow.d.ts.map +1 -0
  337. package/dist/components/Properties/PropertyField.d.ts +238 -0
  338. package/dist/components/Properties/PropertyField.d.ts.map +1 -0
  339. package/dist/components/Properties/PropertyGroup.d.ts +12 -3
  340. package/dist/components/Properties/PropertyGroup.d.ts.map +1 -1
  341. package/dist/components/Properties/PropertyPanel.d.ts +34 -238
  342. package/dist/components/Properties/PropertyPanel.d.ts.map +1 -1
  343. package/dist/components/Properties/Subpanel.d.ts +14 -0
  344. package/dist/components/Properties/Subpanel.d.ts.map +1 -0
  345. package/dist/components/Properties/index.d.ts +8 -4
  346. package/dist/components/Properties/index.d.ts.map +1 -1
  347. package/dist/components/Properties/index.js +3 -2
  348. package/dist/components/Properties/storyLayouts.d.ts +1 -1
  349. package/dist/components/Properties/storyLayouts.d.ts.map +1 -1
  350. package/dist/components/RadioGroup/RadioGroup.d.ts +2 -2
  351. package/dist/components/RadioGroup/RadioGroup.d.ts.map +1 -1
  352. package/dist/components/RadioGroup/index.js +1 -1
  353. package/dist/components/RangeSlider/RangeSlider.d.ts +1 -1
  354. package/dist/components/RangeSlider/RangeSlider.d.ts.map +1 -1
  355. package/dist/components/RangeSlider/index.js +1 -1
  356. package/dist/components/ResizeHandle/ResizeHandle.d.ts +1 -1
  357. package/dist/components/ResizeHandle/ResizeHandle.d.ts.map +1 -1
  358. package/dist/components/ResizeHandle/index.js +1 -1
  359. package/dist/components/Select/Select.d.ts +40 -7
  360. package/dist/components/Select/Select.d.ts.map +1 -1
  361. package/dist/components/Select/index.d.ts +2 -2
  362. package/dist/components/Select/index.d.ts.map +1 -1
  363. package/dist/components/Select/index.js +2 -2
  364. package/dist/components/SelectionPanel/SelectionPanel.d.ts +1 -1
  365. package/dist/components/SelectionPanel/SelectionPanel.d.ts.map +1 -1
  366. package/dist/components/SelectionPanel/index.js +2 -2
  367. package/dist/components/SelectionPanel/renderLeaf.d.ts +14 -8
  368. package/dist/components/SelectionPanel/renderLeaf.d.ts.map +1 -1
  369. package/dist/components/Sidebar/Sidebar.d.ts +1 -1
  370. package/dist/components/Sidebar/Sidebar.d.ts.map +1 -1
  371. package/dist/components/Sidebar/index.js +1 -1
  372. package/dist/components/SidebarPanel/SidebarPanel.d.ts +3 -3
  373. package/dist/components/SidebarPanel/SidebarPanel.d.ts.map +1 -1
  374. package/dist/components/SidebarPanel/index.js +1 -1
  375. package/dist/components/Slider/Slider.d.ts +2 -1
  376. package/dist/components/Slider/Slider.d.ts.map +1 -1
  377. package/dist/components/Slider/index.js +1 -1
  378. package/dist/components/StatusBar/StatusBar.d.ts +3 -3
  379. package/dist/components/StatusBar/StatusBar.d.ts.map +1 -1
  380. package/dist/components/StatusBar/index.js +1 -1
  381. package/dist/components/SwatchGrid/SwatchGrid.d.ts +34 -0
  382. package/dist/components/SwatchGrid/SwatchGrid.d.ts.map +1 -0
  383. package/dist/components/SwatchGrid/index.d.ts +3 -0
  384. package/dist/components/SwatchGrid/index.d.ts.map +1 -0
  385. package/dist/components/SwatchGrid/index.js +2 -0
  386. package/dist/components/Switch/index.js +1 -1
  387. package/dist/components/Tabs/Tabs.d.ts +4 -4
  388. package/dist/components/Tabs/Tabs.d.ts.map +1 -1
  389. package/dist/components/Tabs/index.js +1 -1
  390. package/dist/components/Timeline/Lane.d.ts.map +1 -1
  391. package/dist/components/Timeline/index.js +1 -1
  392. package/dist/components/Toast/Toast.d.ts +1 -1
  393. package/dist/components/Toast/Toast.d.ts.map +1 -1
  394. package/dist/components/Toast/index.js +1 -1
  395. package/dist/components/ToggleBar/ToggleBar.d.ts +2 -1
  396. package/dist/components/ToggleBar/ToggleBar.d.ts.map +1 -1
  397. package/dist/components/ToggleBar/index.js +1 -1
  398. package/dist/components/TokenPanel/TokenPanel.d.ts +1 -1
  399. package/dist/components/TokenPanel/TokenPanel.d.ts.map +1 -1
  400. package/dist/components/TokenPanel/index.js +1 -1
  401. package/dist/components/ToolButton/ToolButton.d.ts +1 -1
  402. package/dist/components/ToolButton/ToolButton.d.ts.map +1 -1
  403. package/dist/components/ToolButton/index.js +1 -1
  404. package/dist/components/ToolGroup/ToolGroup.d.ts +1 -1
  405. package/dist/components/ToolGroup/ToolGroup.d.ts.map +1 -1
  406. package/dist/components/ToolGroup/index.js +1 -1
  407. package/dist/components/ToolOptionsBar/ToolOptionsBar.d.ts +1 -1
  408. package/dist/components/ToolOptionsBar/ToolOptionsBar.d.ts.map +1 -1
  409. package/dist/components/ToolOptionsBar/index.js +1 -1
  410. package/dist/components/ToolPalette/ToolPalette.d.ts +1 -1
  411. package/dist/components/ToolPalette/ToolPalette.d.ts.map +1 -1
  412. package/dist/components/ToolPalette/index.d.ts +1 -0
  413. package/dist/components/ToolPalette/index.d.ts.map +1 -1
  414. package/dist/components/ToolPalette/index.js +3 -2
  415. package/dist/components/Tooltip/Tooltip.d.ts +8 -4
  416. package/dist/components/Tooltip/Tooltip.d.ts.map +1 -1
  417. package/dist/components/Tooltip/index.d.ts +1 -1
  418. package/dist/components/Tooltip/index.d.ts.map +1 -1
  419. package/dist/components/Tooltip/index.js +2 -2
  420. package/dist/components/Tree/Tree.d.ts +84 -0
  421. package/dist/components/Tree/Tree.d.ts.map +1 -0
  422. package/dist/components/Tree/index.d.ts +3 -0
  423. package/dist/components/Tree/index.d.ts.map +1 -0
  424. package/dist/components/Tree/index.js +2 -0
  425. package/dist/components/segmentTooltip.d.ts +30 -0
  426. package/dist/components/segmentTooltip.d.ts.map +1 -0
  427. package/dist/components/stance.d.ts +30 -0
  428. package/dist/components/stance.d.ts.map +1 -0
  429. package/dist/components/stanceCss.d.ts +31 -0
  430. package/dist/components/stanceCss.d.ts.map +1 -0
  431. package/dist/components/stanceSurfaces.d.ts +4 -0
  432. package/dist/components/stanceSurfaces.d.ts.map +1 -0
  433. package/dist/format/number.d.ts +3 -2
  434. package/dist/format/number.d.ts.map +1 -1
  435. package/dist/icons/Icon.d.ts +1 -1
  436. package/dist/icons/Icon.d.ts.map +1 -1
  437. package/dist/icons/ShapeKindIcon.d.ts +10 -0
  438. package/dist/icons/ShapeKindIcon.d.ts.map +1 -0
  439. package/dist/icons/index.d.ts +55 -53
  440. package/dist/icons/index.d.ts.map +1 -1
  441. package/dist/icons/paths.d.ts +2 -0
  442. package/dist/icons/paths.d.ts.map +1 -1
  443. package/dist/index.d.ts +17 -3
  444. package/dist/index.d.ts.map +1 -1
  445. package/dist/index.js +130 -79
  446. package/dist/index.js.map +1 -1
  447. package/dist/interactiveTarget.d.ts +9 -0
  448. package/dist/interactiveTarget.d.ts.map +1 -0
  449. package/dist/overlays/portalHost.d.ts +1 -1
  450. package/dist/overlays/portalHost.d.ts.map +1 -1
  451. package/dist/style.css +1 -1
  452. package/dist/useReorderDragList.d.ts +36 -7
  453. package/dist/useReorderDragList.d.ts.map +1 -1
  454. package/dist/useRovingTabIndex.d.ts +1 -1
  455. package/dist/useScrollSpy.d.ts +48 -0
  456. package/dist/useScrollSpy.d.ts.map +1 -0
  457. package/package.json +8 -8
  458. package/dist/chunks/ActionBar-CLwiY3Jg.js +0 -62
  459. package/dist/chunks/ActionBar-CLwiY3Jg.js.map +0 -1
  460. package/dist/chunks/ActionsBar-D84a4eGy.js +0 -41
  461. package/dist/chunks/ActionsBar-D84a4eGy.js.map +0 -1
  462. package/dist/chunks/Badge-CW9pBPFl.js.map +0 -1
  463. package/dist/chunks/BandEditor-jY-PFKY6.js.map +0 -1
  464. package/dist/chunks/Button-DRSApvnK.js +0 -90
  465. package/dist/chunks/Button-DRSApvnK.js.map +0 -1
  466. package/dist/chunks/Callout-DrNu-9Qr.js +0 -122
  467. package/dist/chunks/Callout-DrNu-9Qr.js.map +0 -1
  468. package/dist/chunks/Checkbox-BOsDAY2F.js.map +0 -1
  469. package/dist/chunks/ColorField-BYzgZM9o.js.map +0 -1
  470. package/dist/chunks/ComboBox-Cz3f0Y_8.js.map +0 -1
  471. package/dist/chunks/CurveEditor-DXwSP-iA.js.map +0 -1
  472. package/dist/chunks/DataGrid-C8KrYtw7.js +0 -104
  473. package/dist/chunks/DataGrid-C8KrYtw7.js.map +0 -1
  474. package/dist/chunks/DetentSlider-CAubVX0J.js.map +0 -1
  475. package/dist/chunks/Dialog-fGqqQ6o_.js +0 -61
  476. package/dist/chunks/Dialog-fGqqQ6o_.js.map +0 -1
  477. package/dist/chunks/Disclosure-CILDfWsU.js +0 -47
  478. package/dist/chunks/Disclosure-CILDfWsU.js.map +0 -1
  479. package/dist/chunks/DragHandleGlyph-CppAz4_8.js.map +0 -1
  480. package/dist/chunks/Field-DWnV8WZY.js.map +0 -1
  481. package/dist/chunks/FontFamilySelect-DxfgTC3G.js.map +0 -1
  482. package/dist/chunks/GradientEditor-rRBmf3G0.js +0 -333
  483. package/dist/chunks/GradientEditor-rRBmf3G0.js.map +0 -1
  484. package/dist/chunks/Icon-DT0x6HaQ.js.map +0 -1
  485. package/dist/chunks/InlineRange-DdIlfGqG.js +0 -29
  486. package/dist/chunks/InlineRange-DdIlfGqG.js.map +0 -1
  487. package/dist/chunks/Input-DbMKpkXy.js.map +0 -1
  488. package/dist/chunks/ItemList-B9zYb0GE.js +0 -42
  489. package/dist/chunks/ItemList-B9zYb0GE.js.map +0 -1
  490. package/dist/chunks/Jog-DkkTlL3_.js.map +0 -1
  491. package/dist/chunks/Keycaps-DunVpejA.js.map +0 -1
  492. package/dist/chunks/LayerStack-CfQ6GsRz.js +0 -142
  493. package/dist/chunks/LayerStack-CfQ6GsRz.js.map +0 -1
  494. package/dist/chunks/MenuButton-C_4nox39.js +0 -60
  495. package/dist/chunks/MenuButton-C_4nox39.js.map +0 -1
  496. package/dist/chunks/MeshEditor-Bipz-Ocl.js +0 -123
  497. package/dist/chunks/MeshEditor-Bipz-Ocl.js.map +0 -1
  498. package/dist/chunks/NumberField-CCjEDZCg.js.map +0 -1
  499. package/dist/chunks/OptionsBar-DeQ-vUeZ.js.map +0 -1
  500. package/dist/chunks/PaintField-jBOJ32rL.js.map +0 -1
  501. package/dist/chunks/PaintInput-Qs7Rul5R.js.map +0 -1
  502. package/dist/chunks/PatternPicker-BMpXWboq.js.map +0 -1
  503. package/dist/chunks/Plot2D-CXf_f7QD.js.map +0 -1
  504. package/dist/chunks/PointPlotter-S_gz7VYt.js.map +0 -1
  505. package/dist/chunks/Powerline-Ak5AWUlK.js +0 -36
  506. package/dist/chunks/Powerline-Ak5AWUlK.js.map +0 -1
  507. package/dist/chunks/Prefs-CNC8tzyN.js +0 -308
  508. package/dist/chunks/Prefs-CNC8tzyN.js.map +0 -1
  509. package/dist/chunks/Properties-Rnb6TAbN.js +0 -891
  510. package/dist/chunks/Properties-Rnb6TAbN.js.map +0 -1
  511. package/dist/chunks/RadioGroup-CsVp3SEu.js.map +0 -1
  512. package/dist/chunks/RangeSlider-DNr-pJpZ.js.map +0 -1
  513. package/dist/chunks/ResizeHandle-RXFf5fXr.js.map +0 -1
  514. package/dist/chunks/Select-BEope086.js +0 -190
  515. package/dist/chunks/Select-BEope086.js.map +0 -1
  516. package/dist/chunks/SelectionPanel-CEbLS-0D.js.map +0 -1
  517. package/dist/chunks/Sidebar-qn_oSCNX.js.map +0 -1
  518. package/dist/chunks/SidebarPanel-Bs6V21hg.js.map +0 -1
  519. package/dist/chunks/Slider-CIIrqiFS.js.map +0 -1
  520. package/dist/chunks/StatusBar-B4L15DSm.js.map +0 -1
  521. package/dist/chunks/Switch-DH5POG0T.js.map +0 -1
  522. package/dist/chunks/Tabs-BFHikpml.js.map +0 -1
  523. package/dist/chunks/Timeline-DNKY_yiK.js.map +0 -1
  524. package/dist/chunks/Toast-CI1UDuK6.js.map +0 -1
  525. package/dist/chunks/ToggleBar-CClus5Cd.js +0 -75
  526. package/dist/chunks/ToggleBar-CClus5Cd.js.map +0 -1
  527. package/dist/chunks/TokenPanel-BPHq24dc.js.map +0 -1
  528. package/dist/chunks/ToolButton-9QzJCmuM.js.map +0 -1
  529. package/dist/chunks/ToolGroup-BJiDrH_i.js.map +0 -1
  530. package/dist/chunks/ToolOptionsBar-CAM6RcUH.js.map +0 -1
  531. package/dist/chunks/ToolPalette-DGkKwE7D.js +0 -97
  532. package/dist/chunks/ToolPalette-DGkKwE7D.js.map +0 -1
  533. package/dist/chunks/Tooltip-C4YBczLq.js +0 -42
  534. package/dist/chunks/Tooltip-C4YBczLq.js.map +0 -1
  535. package/dist/chunks/createKeyframeLayer-DKtO0Sw_.js.map +0 -1
  536. package/dist/chunks/dlog-CMYiRF3Q.js.map +0 -1
  537. package/dist/chunks/icons-DFLytcui.js +0 -165
  538. package/dist/chunks/icons-DFLytcui.js.map +0 -1
  539. package/dist/chunks/keyGlyph-Bp0wnLHn.js.map +0 -1
  540. package/dist/chunks/model-13kZ_-mE.js +0 -483
  541. package/dist/chunks/model-13kZ_-mE.js.map +0 -1
  542. package/dist/chunks/number-BHz66zQO.js.map +0 -1
  543. package/dist/chunks/portalHost-CjpCnuGU.js.map +0 -1
  544. package/dist/chunks/range.module-DSsOIq1R.js +0 -8
  545. package/dist/chunks/range.module-DSsOIq1R.js.map +0 -1
  546. package/dist/chunks/schema-Dft4Cu2p.js +0 -47
  547. package/dist/chunks/schema-Dft4Cu2p.js.map +0 -1
  548. package/dist/chunks/segmentedControl.module-DS72X1ns.js +0 -11
  549. package/dist/chunks/segmentedControl.module-DS72X1ns.js.map +0 -1
  550. package/dist/chunks/snap-CEjuWOhN.js.map +0 -1
  551. package/dist/chunks/useReorderDragList-CSQGd7zQ.js +0 -102
  552. package/dist/chunks/useReorderDragList-CSQGd7zQ.js.map +0 -1
  553. package/dist/chunks/useRovingTabIndex-Dkpf_KhN.js.map +0 -1
  554. package/dist/components/ActionsBar/ActionsBar.d.ts +0 -35
  555. package/dist/components/ActionsBar/ActionsBar.d.ts.map +0 -1
  556. package/dist/components/ActionsBar/index.d.ts +0 -3
  557. package/dist/components/ActionsBar/index.d.ts.map +0 -1
  558. package/dist/components/ActionsBar/index.js +0 -2
  559. package/dist/components/LayerStack/LayerStack.d.ts +0 -62
  560. package/dist/components/LayerStack/LayerStack.d.ts.map +0 -1
  561. package/dist/components/LayerStack/index.d.ts +0 -2
  562. package/dist/components/LayerStack/index.d.ts.map +0 -1
  563. package/dist/components/LayerStack/index.js +0 -2
  564. package/dist/components/Properties/EffectCard.d.ts +0 -69
  565. package/dist/components/Properties/EffectCard.d.ts.map +0 -1
@@ -0,0 +1,131 @@
1
+ import { n as e } from "./interactiveTarget-BNZmTow2.js";
2
+ import { startThresholdDrag as t } from "@weasel-js/core";
3
+ import { useCallback as n, useEffect as r, useRef as i, useState as a } from "react";
4
+ //#region src/useReorderDragList.ts
5
+ var o = {
6
+ draggedIds: null,
7
+ targetIndex: null,
8
+ ghost: null
9
+ };
10
+ function s(e, t) {
11
+ let n = 0;
12
+ for (let r = t - 1; r >= 0; r--) if (e[r]?.locked) {
13
+ n = r + 1;
14
+ break;
15
+ }
16
+ let r = e.length;
17
+ for (let n = t + 1; n < e.length; n++) if (e[n]?.locked) {
18
+ r = n;
19
+ break;
20
+ }
21
+ return [n, r];
22
+ }
23
+ function c(e, t, n, r) {
24
+ let [i, a] = s(e, r);
25
+ return (t.includes(n) ? [...t] : [n]).filter((t) => {
26
+ let n = e.findIndex((e) => e.id === t);
27
+ return n >= i && n < a;
28
+ });
29
+ }
30
+ function l(e, t, n) {
31
+ let r = t.map((t) => e.findIndex((e) => e.id === t)).filter((e) => e >= 0).sort((e, t) => e - t), i = r.length > 0 && r.every((e, t) => {
32
+ if (t === 0) return !0;
33
+ let n = r[t - 1];
34
+ return n !== void 0 && e === n + 1;
35
+ }), a = r[0], o = r[r.length - 1];
36
+ return i && a !== void 0 && o !== void 0 && n >= a && n <= o + 1;
37
+ }
38
+ function u(u) {
39
+ let f = i(u);
40
+ f.current = u;
41
+ let p = i(null), m = i(null), [h, g] = a(o);
42
+ r(() => () => {
43
+ m.current?.cancel();
44
+ }, []);
45
+ let _ = n((e, t) => {
46
+ let [n, r] = s(f.current.items, t), i = p.current;
47
+ if (!i) return n;
48
+ let a = f.current.rowSelector, o = a ? Array.from(i.children).filter((e) => e.matches(a)) : Array.from(i.children), c = o.length;
49
+ for (let t = 0; t < o.length; t++) {
50
+ let n = o[t];
51
+ if (n && e < n.getBoundingClientRect().bottom) {
52
+ c = t;
53
+ break;
54
+ }
55
+ }
56
+ return Math.max(n, Math.min(c, r));
57
+ }, []), v = n((e) => {
58
+ p.current = e;
59
+ }, []), y = n(() => {
60
+ m.current = null, g(o);
61
+ }, []), b = n((n, r, i) => {
62
+ let a = p.current;
63
+ if (!a || m.current || e(i.target, i.currentTarget)) return;
64
+ let o = {
65
+ shiftKey: i.shiftKey,
66
+ ctrlKey: i.ctrlKey,
67
+ metaKey: i.metaKey,
68
+ altKey: i.altKey
69
+ }, s = [], u = 0, h = i.currentTarget, v = (Array.from(a.children).find((e) => e.contains(h)) ?? h).getBoundingClientRect(), b = {
70
+ x: i.clientX - v.left,
71
+ y: i.clientY - v.top
72
+ }, x = (e) => ({
73
+ ids: s,
74
+ left: e.clientX - b.x,
75
+ top: e.clientY - b.y,
76
+ width: v.width
77
+ });
78
+ m.current = t(i, {
79
+ origin: a,
80
+ threshold: f.current.items[r]?.locked ? Infinity : f.current.threshold ?? 4,
81
+ onActivate: (e) => {
82
+ s = c(f.current.items, f.current.selectedIds, n, r), u = _(e.clientY, r), g({
83
+ draggedIds: s,
84
+ targetIndex: u,
85
+ ghost: x(e)
86
+ });
87
+ },
88
+ onMove: (e) => {
89
+ u = _(e.clientY, r), g({
90
+ draggedIds: s,
91
+ targetIndex: u,
92
+ ghost: x(e)
93
+ });
94
+ },
95
+ onCommit: (e) => {
96
+ let t = _(e.clientY, r);
97
+ l(f.current.items, s, t) || f.current.onReorder(s, t), y();
98
+ },
99
+ onClick: () => {
100
+ let { onPress: e } = f.current;
101
+ e && (e(n, o), d(a)), y();
102
+ },
103
+ onCancel: y
104
+ });
105
+ }, [_, y]);
106
+ return {
107
+ nudge: n((e, t, n) => {
108
+ let { items: r, selectedIds: i, onReorder: a } = f.current;
109
+ if (r[t]?.locked) return !1;
110
+ let o = c(r, i, e, t), u = o.map((e) => r.findIndex((t) => t.id === e)).sort((e, t) => e - t), d = u[0], p = u[u.length - 1];
111
+ if (d === void 0 || p === void 0) return !1;
112
+ let [m, h] = s(r, t), g = n < 0 ? d - 1 : p + 2;
113
+ return g < m || g > h || l(r, o, g) ? !1 : (a(o, g), !0);
114
+ }, []),
115
+ rowProps: (e, t) => ({ onPointerDown: (n) => b(e, t, n) }),
116
+ containerProps: { ref: v },
117
+ state: h
118
+ };
119
+ }
120
+ function d(e) {
121
+ let t = (e) => {
122
+ e.stopPropagation();
123
+ };
124
+ e.addEventListener("click", t, !0), setTimeout(() => {
125
+ e.removeEventListener("click", t, !0);
126
+ }, 0);
127
+ }
128
+ //#endregion
129
+ export { u as t };
130
+
131
+ //# sourceMappingURL=useReorderDragList-B_-5L5Gu.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useReorderDragList-B_-5L5Gu.js","names":["isInControlWithin","IDLE","unlockedSegment","lo","i","sourceIndex","items","hi","draggedIdsFor","index","selectedIds","id","it","x","isNoopDrop","indices","draggedIds","a","b","contiguous","prev","v","first","last","targetIndex","useReorderDragList","optsRef","useRef","opts","containerRef","dragRef","state","setState","useState","computeTargetIndex","useCallback","c","sel","rows","el","raw","row","clientY","refCb","reset","onPointerDownRow","container","e","mods","pressed","child","grab","ghostAt","ev","startThresholdDrag","drop","onPress","swallowNextClick","ids","at","target","delta","onReorder","swallow"],"sources":["../../src/useReorderDragList.ts"],"sourcesContent":["import { useCallback, useEffect, useRef, useState } from 'react';\nimport type { ReactNode, PointerEvent as ReactPointerEvent, RefCallback } from 'react';\nimport { startThresholdDrag, type ThresholdDragHandle } from '@weasel-js/core';\nimport { isInControlWithin } from './interactiveTarget';\n\n/** One row in a reorderable list. */\nexport interface ReorderItem {\n id: string;\n label: ReactNode;\n /** Locked rows cannot be dragged, cannot be crossed by drops, and\n * never combine with other rows in a multi-selection. */\n locked?: boolean;\n}\n\n/**\n * Options for {@link useReorderDragList}. `onReorder` receives the dragged ids\n * and the index they were dropped at, measured against the pre-drag `items`.\n */\nexport interface UseReorderDragListOptions {\n items: ReorderItem[];\n selectedIds: string[];\n onReorder(ids: string[], targetIndex: number): void;\n /** A press that was released without ever engaging a drag — the click a\n * list row means by it. Fires for locked rows too, which can be selected\n * but not dragged. Modifiers are read at press, not at release. When this\n * is given, the DOM click that follows the press is dropped, so a row that\n * also handles `click` sees one press, not two. A press that starts on a\n * control inside the row (a toggle) is left to the control. */\n onPress?(id: string, mods: PressModifiers): void;\n /** Pointer-move distance (px) before pending drag engages. Default 4. */\n threshold?: number;\n /** Selector matching the container's children that are rows, for a list\n * that interleaves other elements (a table's detail rows). Default: every\n * child is a row. */\n rowSelector?: string;\n}\n\n/** Modifier keys held when a press began. */\nexport interface PressModifiers {\n shiftKey: boolean;\n ctrlKey: boolean;\n metaKey: boolean;\n altKey: boolean;\n}\n\n/**\n * Where a drag's ghost goes: the dragged rows, drawn again with their top-left\n * at a client-space point, so the row that was grabbed stays under the pointer\n * where it was picked up. `width` is the grabbed row's.\n */\nexport interface ReorderGhost {\n ids: readonly string[];\n left: number;\n top: number;\n width: number;\n}\n\n/**\n * Live drag state for rendering feedback: which ids are being dragged, the\n * insertion index the drop would use, and where their ghost goes. All `null`\n * when no drag is engaged.\n */\nexport interface ReorderDragState {\n draggedIds: string[] | null;\n targetIndex: number | null;\n ghost: ReorderGhost | null;\n}\n\nconst IDLE: ReorderDragState = { draggedIds: null, targetIndex: null, ghost: null };\n\n/**\n * A `ref` for the list container, an `onPointerDown` for each row, and the\n * live {@link ReorderDragState}. The container ref is required, not optional\n * decoration: it is what the drop index is measured against and what the\n * pointer session is opened on.\n */\nexport interface ReorderDragHandlers {\n rowProps(id: string, index: number): { onPointerDown(e: ReactPointerEvent): void };\n containerProps: {\n ref: RefCallback<HTMLElement>;\n };\n state: ReorderDragState;\n /**\n * Move the row at `index` one place up (`-1`) or down (`1`) — the keyboard\n * reorder. It moves what a drag of that row would: the whole selection if\n * the row is in it, else the row alone, never across a locked row. Calls\n * `onReorder` and returns `true`, or returns `false` when nothing can move.\n */\n nudge(id: string, index: number, delta: -1 | 1): boolean;\n}\n\n/**\n * The half-open run of indices a row at `sourceIndex` may be dropped into:\n * bounded by the nearest locked row above and below it, so a locked row is a\n * wall in both directions rather than a global ceiling.\n */\nfunction unlockedSegment(items: readonly ReorderItem[], sourceIndex: number): [number, number] {\n let lo = 0;\n for (let i = sourceIndex - 1; i >= 0; i--) {\n if (items[i]?.locked) { lo = i + 1; break; }\n }\n let hi = items.length;\n for (let i = sourceIndex + 1; i < items.length; i++) {\n if (items[i]?.locked) { hi = i; break; }\n }\n return [lo, hi];\n}\n\n/** What a drag of the row at `index` carries: the selection within its segment if the row is selected, else the row. */\nfunction draggedIdsFor(\n items: readonly ReorderItem[],\n selectedIds: readonly string[],\n id: string,\n index: number,\n): string[] {\n const [lo, hi] = unlockedSegment(items, index);\n return (selectedIds.includes(id) ? [...selectedIds] : [id]).filter((x) => {\n const i = items.findIndex((it) => it.id === x);\n return i >= lo && i < hi;\n });\n}\n\n/** Would dropping `draggedIds` at `targetIndex` leave a contiguous block where it already is? */\nfunction isNoopDrop(items: readonly ReorderItem[], draggedIds: readonly string[], targetIndex: number): boolean {\n const indices = draggedIds\n .map((id) => items.findIndex((it) => it.id === id))\n .filter((i) => i >= 0)\n .sort((a, b) => a - b);\n const contiguous =\n indices.length > 0 &&\n indices.every((v, i) => {\n if (i === 0) return true;\n const prev = indices[i - 1];\n return prev !== undefined && v === prev + 1;\n });\n const first = indices[0];\n const last = indices[indices.length - 1];\n return contiguous\n && first !== undefined\n && last !== undefined\n && targetIndex >= first\n && targetIndex <= last + 1;\n}\n\n/**\n * Drag-to-reorder for a vertical list of rows. Dragging a row that is part of\n * the current selection drags the whole selection; dragging any other row\n * drags just that row. Locked rows can neither be dragged nor crossed by a\n * drop. A drop that would leave a contiguous block where it already is does\n * not call `onReorder`.\n *\n * The rows are the container's children, whatever they are: `ItemList` rows,\n * or the `PropertyGroup`s of a `PropertyList`. A row's `onPointerDown` can go\n * on the whole row or on a handle inside it.\n *\n * A press opens a `startThresholdDrag` on the *container*, which owns the\n * rest of the gesture: a drag that leaves the list still tracks, a release\n * anywhere still drops, and a release the window never delivered still ends\n * the drag. The container is the origin rather than the row because rows come\n * and go as the list re-renders, and a drag must outlive the row it grabbed.\n */\nexport function useReorderDragList(opts: UseReorderDragListOptions): ReorderDragHandlers {\n const optsRef = useRef(opts);\n optsRef.current = opts;\n const containerRef = useRef<HTMLElement | null>(null);\n const dragRef = useRef<ThresholdDragHandle | null>(null);\n const [state, setState] = useState<ReorderDragState>(IDLE);\n\n useEffect(() => () => { dragRef.current?.cancel(); }, []);\n\n const computeTargetIndex = useCallback((clientY: number, sourceIndex: number): number => {\n const [lo, hi] = unlockedSegment(optsRef.current.items, sourceIndex);\n const c = containerRef.current;\n if (!c) return lo;\n const sel = optsRef.current.rowSelector;\n const rows = (sel ? Array.from(c.children).filter((el) => el.matches(sel)) : Array.from(c.children)) as HTMLElement[];\n let raw = rows.length;\n for (let i = 0; i < rows.length; i++) {\n const row = rows[i];\n if (!row) continue;\n const r = row.getBoundingClientRect();\n if (clientY < r.bottom) { raw = i; break; }\n }\n return Math.max(lo, Math.min(raw, hi));\n }, []);\n\n const refCb = useCallback<RefCallback<HTMLElement>>((el) => {\n containerRef.current = el;\n }, []);\n\n const reset = useCallback(() => {\n dragRef.current = null;\n setState(IDLE);\n }, []);\n\n const onPointerDownRow = useCallback((id: string, index: number, e: ReactPointerEvent) => {\n const container = containerRef.current;\n if (!container || dragRef.current) return;\n if (isInControlWithin(e.target, e.currentTarget as Element)) return;\n\n const mods: PressModifiers = {\n shiftKey: e.shiftKey, ctrlKey: e.ctrlKey, metaKey: e.metaKey, altKey: e.altKey,\n };\n let draggedIds: string[] = [];\n let targetIndex = 0;\n // Where in the grabbed row the pointer went down, so the ghost keeps that point under it. The handler may sit on\n // a handle inside the row rather than the row itself, so the row is the container's child holding it.\n const pressed = e.currentTarget as Element;\n const rowEl = Array.from(container.children).find((child) => child.contains(pressed)) ?? pressed;\n const row = rowEl.getBoundingClientRect();\n const grab = { x: e.clientX - row.left, y: e.clientY - row.top };\n const ghostAt = (ev: { clientX: number; clientY: number }): ReorderGhost => ({\n ids: draggedIds,\n left: ev.clientX - grab.x,\n top: ev.clientY - grab.y,\n width: row.width,\n });\n\n dragRef.current = startThresholdDrag(e, {\n origin: container,\n // A locked row still opens a drag so its release reaches `onPress`, and\n // a threshold nothing can cross is what keeps it from ever engaging.\n threshold: optsRef.current.items[index]?.locked\n ? Number.POSITIVE_INFINITY\n : (optsRef.current.threshold ?? 4),\n onActivate: (ev) => {\n draggedIds = draggedIdsFor(optsRef.current.items, optsRef.current.selectedIds, id, index);\n targetIndex = computeTargetIndex(ev.clientY, index);\n setState({ draggedIds, targetIndex, ghost: ghostAt(ev) });\n },\n onMove: (ev) => {\n targetIndex = computeTargetIndex(ev.clientY, index);\n setState({ draggedIds, targetIndex, ghost: ghostAt(ev) });\n },\n onCommit: (ev) => {\n const drop = computeTargetIndex(ev.clientY, index);\n if (!isNoopDrop(optsRef.current.items, draggedIds, drop)) {\n optsRef.current.onReorder(draggedIds, drop);\n }\n reset();\n },\n onClick: () => {\n const { onPress } = optsRef.current;\n if (onPress) {\n onPress(id, mods);\n swallowNextClick(container);\n }\n reset();\n },\n // Every cancel reason — the browser's, a lost capture, an unmount —\n // says the gesture was interrupted rather than aimed, so the rows stay\n // where they were.\n onCancel: reset,\n });\n }, [computeTargetIndex, reset]);\n\n const nudge = useCallback((id: string, index: number, delta: -1 | 1): boolean => {\n const { items, selectedIds, onReorder } = optsRef.current;\n if (items[index]?.locked) return false;\n const ids = draggedIdsFor(items, selectedIds, id, index);\n const at = ids.map((x) => items.findIndex((it) => it.id === x)).sort((a, b) => a - b);\n const first = at[0];\n const last = at[at.length - 1];\n if (first === undefined || last === undefined) return false;\n const [lo, hi] = unlockedSegment(items, index);\n const target = delta < 0 ? first - 1 : last + 2;\n if (target < lo || target > hi || isNoopDrop(items, ids, target)) return false;\n onReorder(ids, target);\n return true;\n }, []);\n\n return {\n nudge,\n rowProps: (id, index) => ({\n onPointerDown: (e) => onPointerDownRow(id, index, e),\n }),\n containerProps: {\n ref: refCb,\n },\n state,\n };\n}\n\n/**\n * The session captured the pointer on the container, so browsers disagree on\n * where the release's click lands; it may still reach the row. `onPress` has\n * already reported this press, so that click is dropped rather than read as a\n * second one. It is dispatched in the same task as the release.\n */\nfunction swallowNextClick(container: HTMLElement): void {\n const swallow = (e: Event) => { e.stopPropagation(); };\n container.addEventListener('click', swallow, true);\n setTimeout(() => { container.removeEventListener('click', swallow, true); }, 0);\n}\n"],"mappings":";;;;AAoEA,IAAMC,IAAyB;CAAE,YAAY;CAAM,aAAa;CAAM,OAAO;AAAK;AA4BlF,SAASC,EAAgB,GAA+B,GAAuC;CAC7F,IAAIC,IAAK;CACT,KAAK,IAAIC,IAAIC,IAAc,GAAGD,KAAK,GAAG,KACpC,IAAI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B;GAC/E,IAAM,EAAE,UAAO,gBAAa,iBAAcT,EAAQ;GAClD,IAAIpB,EAAMG,EAAM,EAAE,QAAQ,OAAO;GACjC,IAAMiD,IAAMlD,EAAcF,GAAOI,GAAaC,GAAIF,CAAK,GACjDkD,IAAKD,EAAI,KAAK,MAAMpD,EAAM,WAAW,MAAOM,EAAG,OAAOC,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,MAAMI,IAAIC,CAAC,GAC9EI,IAAQqC,EAAG,IACXpC,IAAOoC,EAAGA,EAAG,SAAS;GAC5B,IAAIrC,MAAU,KAAA,KAAaC,MAAS,KAAA,GAAW,OAAO;GACtD,IAAM,CAACpB,GAAII,KAAML,EAAgBI,GAAOG,CAAK,GACvCmD,IAASC,IAAQ,IAAIvC,IAAQ,IAAIC,IAAO;GAG9C,OAFIqC,IAASzD,KAAMyD,IAASrD,KAAMO,EAAWR,GAAOoD,GAAKE,CAAM,IAAU,MACzEE,EAAUJ,GAAKE,CAAM,GACd;EACT,GAAG,CAAC,CAGF;EACA,WAAW,GAAI,OAAW,EACxB,gBAAgB,MAAMf,EAAiBlC,GAAIF,GAAOsC,CAAC,EACrD;EACA,gBAAgB,EACd,KAAKJ,EACP;EACA;CACF;AACF;AAQA,SAASc,EAAiB,GAA8B;CACtD,IAAMM,KAAW,MAAa;EAAE,EAAE,gBAAgB;CAAG;CAErD,AADAjB,EAAU,iBAAiB,SAASiB,GAAS,EAAI,GACjD,iBAAiB;EAAE,EAAU,oBAAoB,SAASA,GAAS,EAAI;CAAG,GAAG,CAAC;AAChF"}
@@ -62,4 +62,4 @@ function a(a) {
62
62
  //#endregion
63
63
  export { a as t };
64
64
 
65
- //# sourceMappingURL=useRovingTabIndex-Dkpf_KhN.js.map
65
+ //# sourceMappingURL=useRovingTabIndex-Bp_hYm_h.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useRovingTabIndex-Bp_hYm_h.js","names":["firstEnabledIndex","i","items","lastEnabledIndex","nextEnabledIndex","k","from","prevEnabledIndex","useRovingTabIndex","options","rootRef","useRef","tabStopIndex","focusItem","root","itemClassName","index","nextIndex","e","onActivate","onNavigate"],"sources":["../../src/useRovingTabIndex.ts"],"sourcesContent":["import { useRef, type KeyboardEvent as ReactKeyboardEvent, type RefObject } from 'react';\n\n/** The only thing the hook needs to know about a bar's items: which are\n * skipped by arrow navigation. */\nexport type RovingItem = { disabled?: boolean };\n\n/** Options for {@link useRovingTabIndex}. */\nexport type UseRovingTabIndexOptions = {\n /** In the same order as the elements carrying `itemClassName`. */\n items: readonly RovingItem[];\n /** Class on the focusable element of each item, inside the container the\n * returned `rootRef` is attached to. Their DOM order must match `items`. */\n itemClassName: string;\n /** Index that carries `tabIndex=0`. Defaults to the first enabled item; a\n * radiogroup-style bar passes its selected index so Tab lands on the\n * current value. */\n tabStopIndex?: number;\n /** Called with the new index as arrow/Home/End focus moves, before focus\n * moves. This is where a selection-follows-focus bar commits the value. */\n onNavigate?: (index: number) => void;\n /** Space/Enter on the item at `index`. When omitted the keypress is left\n * alone, which on a native `<button>` produces an ordinary click. */\n onActivate?: (index: number) => void;\n};\n\n/**\n * What {@link useRovingTabIndex} returns: a container ref plus the per-item\n * `tabIndex` and `onKeyDown` values to spread onto each item.\n */\nexport type RovingTabIndex<T extends HTMLElement = HTMLDivElement> = {\n /** Attach to the container element that holds the items. */\n rootRef: RefObject<T | null>;\n /** `tabIndex` value for the item at `index`. */\n tabIndexFor: (index: number) => 0 | -1;\n /** `onKeyDown` for the item at `index`. */\n onKeyDown: (index: number) => (e: ReactKeyboardEvent<HTMLElement>) => void;\n};\n\nfunction firstEnabledIndex(items: readonly RovingItem[]): number {\n for (let i = 0; i < items.length; i++) if (!items[i].disabled) return i;\n return -1;\n}\n\nfunction lastEnabledIndex(items: readonly RovingItem[]): number {\n for (let i = items.length - 1; i >= 0; i--) if (!items[i].disabled) return i;\n return -1;\n}\n\nfunction nextEnabledIndex(items: readonly RovingItem[], from: number): number {\n const n = items.length;\n for (let k = 1; k <= n; k++) {\n const i = (from + k + n) % n;\n if (!items[i].disabled) return i;\n }\n return from;\n}\n\nfunction prevEnabledIndex(items: readonly RovingItem[], from: number): number {\n const n = items.length;\n for (let k = 1; k <= n; k++) {\n const i = (from - k + n) % n;\n if (!items[i].disabled) return i;\n }\n return from;\n}\n\n/**\n * Roving tabindex for a bar of items: one item is in the tab order, and the\n * arrow keys move focus among the rest, skipping disabled ones and wrapping\n * at both ends. Home and End go to the first and last enabled item. Both axes\n * navigate, so the same bar works laid out either way.\n *\n * Backs `ButtonBar`, `OptionsBar`, and `ToggleBar`.\n *\n * **When a bar should not use this.** What decides it is the items, not who\n * owns them. A container of compound controls — a number field, a select, a\n * color field — must leave the arrow keys alone, because those controls edit\n * their own value with them; taking the arrows over would break the control\n * to navigate between controls. `ToolOptionsBar` is that case: it draws its\n * own controls from a tool's schema now rather than taking arbitrary\n * children, and a schema-drawn number field eats arrows exactly as a\n * hand-placed one did, so it keeps plain DOM tab order. A bar whose items are\n * all simple buttons is the case this hook is for.\n *\n * With every item disabled there is no tab stop and the bar drops out of the\n * tab order entirely.\n */\nexport function useRovingTabIndex<T extends HTMLElement = HTMLDivElement>(\n options: UseRovingTabIndexOptions,\n): RovingTabIndex<T> {\n const { items, itemClassName, onNavigate, onActivate } = options;\n const rootRef = useRef<T | null>(null);\n\n const tabStopIndex = options.tabStopIndex ?? firstEnabledIndex(items);\n\n const focusItem = (index: number): void => {\n const root = rootRef.current;\n if (!root) return;\n const elements = root.querySelectorAll<HTMLElement>(`.${itemClassName}`);\n elements[index]?.focus();\n };\n\n const onKeyDown = (index: number) => (e: ReactKeyboardEvent<HTMLElement>): void => {\n let nextIndex = -1;\n switch (e.key) {\n case 'ArrowLeft':\n case 'ArrowUp':\n nextIndex = prevEnabledIndex(items, index);\n break;\n case 'ArrowRight':\n case 'ArrowDown':\n nextIndex = nextEnabledIndex(items, index);\n break;\n case 'Home':\n nextIndex = firstEnabledIndex(items);\n break;\n case 'End':\n nextIndex = lastEnabledIndex(items);\n break;\n case ' ':\n case 'Enter':\n if (onActivate) {\n e.preventDefault();\n onActivate(index);\n }\n return;\n default:\n return;\n }\n if (nextIndex < 0 || nextIndex === index) return;\n e.preventDefault();\n onNavigate?.(nextIndex);\n focusItem(nextIndex);\n };\n\n return {\n rootRef,\n tabIndexFor: (index: number) => (index === tabStopIndex ? 0 : -1),\n onKeyDown,\n };\n}\n"],"mappings":";;AAsCA,SAASA,EAAkB,GAAsC;CAC/D,KAAK,IAAIC,IAAI,GAAGA,IAAIC,EAAM,QAAQ,KAAK,IAAI,CAACA,EAAMD,EAAE,CAAC,UAAU,OAAOA;CACtE,OAAO;AACT;AAEA,SAASE,EAAiB,GAAsC;CAC9D,KAAK,IAAIF,IAAIC,EAAM,SAAS,GAAGD,KAAK,GAAG,KAAK,IAAI,CAACC,EAAMD,EAAE,CAAC,UAAU,OAAOA;CAC3E,OAAO;AACT;AAEA,SAASG,EAAiB,GAA8B,GAAsB;CAC5E,IAAM,IAAIF,EAAM;CAChB,KAAK,IAAIG,IAAI,GAAGA,KAAK,GAAG,KAAK;EAC3B,IAAM,KAAKC,IAAOD,IAAI,KAAK;EAC3B,IAAI,CAACH,EAAM,EAAE,CAAC,UAAU,OAAO;CACjC;CACA,OAAOI;AACT;AAEA,SAASC,EAAiB,GAA8B,GAAsB;CAC5E,IAAM,IAAIL,EAAM;CAChB,KAAK,IAAIG,IAAI,GAAGA,KAAK,GAAG,KAAK;EAC3B,IAAM,KAAKC,IAAOD,IAAI,KAAK;EAC3B,IAAI,CAACH,EAAM,EAAE,CAAC,UAAU,OAAO;CACjC;CACA,OAAOI;AACT;AAuBA,SAAgBE,EACd,GACmB;CACnB,IAAM,EAAE,UAAO,kBAAe,eAAY,kBAAeC,GACnDC,IAAUC,EAAiB,IAAI,GAE/BC,IAAeH,EAAQ,gBAAgBT,EAAkBE,CAAK,GAE9DW,KAAa,MAAwB;EACzC,IAAMC,IAAOJ,EAAQ;EACrB,AAAKI,KAELA,EADsB,iBAA8B,IAAIC,GACxD,CAAA,CAASC,EAAM,EAAE,MAAM;CACzB;CAmCA,OAAO;EACL;EACA,cAAc,MAAmBA,MAAUJ,IAAe,IAAI;EAC9D,YApCiB,OAAmB,MAA6C;GACjF,IAAIK,IAAY;GAChB,QAAQC,EAAE,KAAV;IACE,KAAK;IACL,KAAK;KACH,IAAYX,EAAiBL,GAAOc,CAAK;KACzC;IACF,KAAK;IACL,KAAK;KACH,IAAYZ,EAAiBF,GAAOc,CAAK;KACzC;IACF,KAAK;KACH,IAAYhB,EAAkBE,CAAK;KACnC;IACF,KAAK;KACH,IAAYC,EAAiBD,CAAK;KAClC;IACF,KAAK;IACL,KAAK;KACH,AAAIiB,MACFD,EAAE,eAAe,GACjBC,EAAWH,CAAK;KAElB;IACF,SACE;GACJ;GACA,AAAIC,IAAY,KAAKA,MAAcD,MACnCE,EAAE,eAAe,GACjBE,IAAaH,CAAS,GACtBJ,EAAUI,CAAS;EACrB;CAMA;AACF"}
@@ -0,0 +1,38 @@
1
+ import { type ColorInterpolationSpace, type HueInterpolation } from '@weasel-js/core';
2
+ import { type ChromaCurve } from './oklch';
3
+ /**
4
+ * How {@link rampColor} and {@link colorRamp} travel between two endpoints.
5
+ *
6
+ * What each space interpolates:
7
+ *
8
+ * | `space` | components lerped | hue |
9
+ * | --------------- | ---------------------------- | -------------------- |
10
+ * | `'oklch'` | L, C, H | around the wheel |
11
+ * | `'hsl'` | H, S, L | around the wheel |
12
+ * | `'oklab'` | L, a, b | through the wheel |
13
+ * | `'srgb'` | gamma-encoded R, G, B | through the wheel |
14
+ * | `'srgb-linear'` | linear-light R, G, B | through the wheel |
15
+ *
16
+ * A lightness ramp is two endpoints that differ in lightness, and a hue ramp
17
+ * two that differ in hue: the polar spaces keep chroma or saturation fixed
18
+ * while they move, and the others cut a straight line between the two colors,
19
+ * which for a hue ramp passes through gray.
20
+ *
21
+ * `chroma` is an OKLCH envelope in every space, since {@link ChromaCurve}'s
22
+ * numbers are OKLCH chroma over OKLCH lightness. It runs after the
23
+ * interpolation: each sample keeps its lightness and hue, and its chroma is
24
+ * replaced with the curve's value at that lightness. A sample left with no
25
+ * hue (a gray midpoint) takes the hue an OKLCH ramp would have had there.
26
+ */
27
+ export interface ColorRampOptions {
28
+ /** Default `'oklch'`. */
29
+ space?: ColorInterpolationSpace;
30
+ /** Polar spaces only. Default `'shorter'`. */
31
+ hue?: HueInterpolation;
32
+ chroma?: ChromaCurve;
33
+ }
34
+ /** One sample of a ramp from `from` to `to` (`#rrggbb`), `t` in 0..1. */
35
+ export declare function rampColor(from: string, to: string, t: number, options?: ColorRampOptions): string;
36
+ /** `steps` evenly spaced samples from `from` to `to`, both ends included. */
37
+ export declare function colorRamp(from: string, to: string, steps: number, options?: ColorRampOptions): string[];
38
+ //# sourceMappingURL=ramp.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ramp.d.ts","sourceRoot":"","sources":["../../src/color/ramp.ts"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,uBAAuB,EAC5B,KAAK,gBAAgB,EACtB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAwB,KAAK,WAAW,EAAE,MAAM,SAAS,CAAC;AAEjE;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,WAAW,gBAAgB;IAC/B,yBAAyB;IACzB,KAAK,CAAC,EAAE,uBAAuB,CAAC;IAChC,8CAA8C;IAC9C,GAAG,CAAC,EAAE,gBAAgB,CAAC;IACvB,MAAM,CAAC,EAAE,WAAW,CAAC;CACtB;AAOD,yEAAyE;AACzE,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,OAAO,GAAE,gBAAqB,GAAG,MAAM,CASrG;AAED,6EAA6E;AAC7E,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,GAAE,gBAAqB,GAAG,MAAM,EAAE,CAG3G"}
@@ -6,15 +6,16 @@ export interface ActionBarProps {
6
6
  /** Layout direction. Defaults to `'horizontal'`. */
7
7
  orientation?: 'horizontal' | 'vertical';
8
8
  /**
9
- * Per-id icon overrides — keyed by `action.id`. When an entry is provided
9
+ * Per-entry icon overrides, keyed by `ActionItem.key` — the action id, or
10
+ * `id:variant` for one variant of a parametric action. When an entry is provided
10
11
  * it replaces the action's own `icon` for this bar only. Mirrors
11
12
  * `PathfinderPanelProps.icons` so call sites that ship custom glyph sets
12
13
  * can swap them in without re-registering actions.
13
14
  */
14
15
  icons?: Record<string, ReactNode>;
15
16
  /**
16
- * Per-id label overrides — keyed by `action.id`. Drives both `aria-label`
17
- * and `title`. When omitted, the action's own `label` is used.
17
+ * Per-entry label overrides, keyed like `icons`. Drives both `aria-label`
18
+ * and `title`. When omitted, the entry's own `label` is used.
18
19
  */
19
20
  labels?: Record<string, string>;
20
21
  /** Additional class for the toolbar root. */
@@ -23,7 +24,8 @@ export interface ActionBarProps {
23
24
  /**
24
25
  * Generic group-keyed action toolbar. Reads the parent `ActionsRegistry`,
25
26
  * filters to actions whose `group` matches `props.group`, and renders one
26
- * icon button per match. Disabled state is derived from each action's
27
+ * icon button per match — or per variant, for an action that declares
28
+ * `variants`. Disabled state is derived from each action's
27
29
  * `enabled` predicate via `evaluateEnabled` (so the button greys out and
28
30
  * swallows clicks while the keybinding — if any — still fires through the
29
31
  * registry's keydown listener; that's the registry's contract, not ours).
@@ -33,5 +35,5 @@ export interface ActionBarProps {
33
35
  * (roving tabindex) yet — bar consumers today are short flat strips. Add
34
36
  * if/when a long bar lands.
35
37
  */
36
- export declare function ActionBar(props: ActionBarProps): import("react/jsx-runtime").JSX.Element;
38
+ export declare function ActionBar(props: ActionBarProps): import("react").JSX.Element;
37
39
  //# sourceMappingURL=ActionBar.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ActionBar.d.ts","sourceRoot":"","sources":["../../../src/components/ActionBar/ActionBar.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAwB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAc7D,mCAAmC;AACnC,MAAM,WAAW,cAAc;IAC7B,2EAA2E;IAC3E,KAAK,EAAE,MAAM,CAAC;IACd,oDAAoD;IACpD,WAAW,CAAC,EAAE,YAAY,GAAG,UAAU,CAAC;IACxC;;;;;OAKG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAClC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,6CAA6C;IAC7C,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAaD;;;;;;;;;;;;GAYG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,cAAc,2CAiE9C"}
1
+ {"version":3,"file":"ActionBar.d.ts","sourceRoot":"","sources":["../../../src/components/ActionBar/ActionBar.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAwB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAmB7D,mCAAmC;AACnC,MAAM,WAAW,cAAc;IAC7B,2EAA2E;IAC3E,KAAK,EAAE,MAAM,CAAC;IACd,oDAAoD;IACpD,WAAW,CAAC,EAAE,YAAY,GAAG,UAAU,CAAC;IACxC;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAClC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,6CAA6C;IAC7C,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAcD;;;;;;;;;;;;;GAaG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,cAAc,+BAqD9C"}
@@ -1,2 +1,2 @@
1
- import { t as e } from "../../chunks/ActionBar-CLwiY3Jg.js";
1
+ import { t as e } from "../../chunks/ActionBar-DCq16yFA.js";
2
2
  export { e as ActionBar };
@@ -1,10 +1,12 @@
1
- import { type ReactNode, type CSSProperties } from 'react';
1
+ import { type CSSProperties, type HTMLAttributes, type ReactNode } from 'react';
2
2
  import { type BadgeShapeParams } from './shapes';
3
3
  import { type BadgeBase, type BadgeBaseParams } from './bases';
4
4
  import { type EffectSpec } from './effects';
5
- import type { BadgeShape, BadgeTone, BadgeVariant, BadgeSize } from './types';
6
- interface BadgeBaseProps {
7
- tone?: BadgeTone;
5
+ import type { BadgeShape, BadgeStatus, BadgeVariant, BadgeSize } from './types';
6
+ import { type StanceProps } from '../stance';
7
+ interface BadgeBaseProps extends StanceProps {
8
+ /** The status the badge reports. A peer `tone`, or a stance's accent, paints over it. */
9
+ status?: BadgeStatus;
8
10
  variant?: BadgeVariant;
9
11
  size?: BadgeSize;
10
12
  /** "Edge bloat": offset every base perimeter sample outward by N CSS px along the normal
@@ -34,12 +36,22 @@ interface BadgeBaseProps {
34
36
  children: ReactNode;
35
37
  className?: string;
36
38
  /** Optional style overrides merged with the badge's own style. Useful for setting CSS
37
- * custom properties (e.g. `--badge-edge` to inject a custom tone color). */
39
+ * custom properties (e.g. `--badge-edge` to inject a `custom` status color). */
38
40
  style?: CSSProperties;
39
41
  'aria-label'?: string;
42
+ /**
43
+ * Tooltip content. Wraps the badge in a kit tooltip trigger. A tooltip
44
+ * trigger must be focusable and carry a role that announces its
45
+ * description, so a badge that is neither a button nor a link joins the tab
46
+ * order as `role="img"`, named by `aria-label` or else by string content.
47
+ */
48
+ tooltip?: ReactNode;
40
49
  }
50
+ /** DOM attributes a badge passes through to its root element, e.g. the ones
51
+ * `Focusable` supplies when a badge sits under a `TooltipTrigger`. */
52
+ type BadgeDomProps = Omit<HTMLAttributes<HTMLElement>, keyof BadgeBaseProps | 'onClick' | 'children' | 'className' | 'style'>;
41
53
  type BadgePropsByShape = {
42
- [S in BadgeShape]: BadgeBaseProps & {
54
+ [S in BadgeShape]: BadgeBaseProps & BadgeDomProps & {
43
55
  shape?: S;
44
56
  shapeParams?: BadgeShapeParams[S];
45
57
  };
@@ -58,7 +70,9 @@ export type BadgeProps = BadgePropsByShape;
58
70
  * over it, which stack additively. `bloat` pushes the whole silhouette outward
59
71
  * along its normals before effects run, and `crawl` animates perimeter
60
72
  * patterns.
73
+ *
74
+ * `ref` and any other DOM attributes forward to the root element.
61
75
  */
62
- export declare function Badge(props: BadgeProps): import("react/jsx-runtime").JSX.Element;
76
+ export declare const Badge: import("react").ForwardRefExoticComponent<BadgePropsByShape & import("react").RefAttributes<HTMLElement>>;
63
77
  export {};
64
78
  //# sourceMappingURL=Badge.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Badge.d.ts","sourceRoot":"","sources":["../../../src/components/Badge/Badge.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAsC,KAAK,SAAS,EAAE,KAAK,aAAa,EAAE,MAAM,OAAO,CAAC;AAG/F,OAAO,EAAU,KAAK,gBAAgB,EAAE,MAAM,UAAU,CAAC;AACzD,OAAO,EAAS,KAAK,SAAS,EAAE,KAAK,eAAe,EAAE,MAAM,SAAS,CAAC;AACtE,OAAO,EAAW,KAAK,UAAU,EAAoB,MAAM,WAAW,CAAC;AACvE,OAAO,KAAK,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAG9E,UAAU,cAAc;IACtB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;wCAEoC;IACpC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC1B;;;;;OAKG;IACH,UAAU,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC;IAC/B,+GAA+G;IAC/G,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IACzB,mGAAmG;IACnG,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,UAA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G;KACtB,CAAC,IAAI,UAAU,GAAG,cAAc,GAAG,aAAa,GAAG;QAAE,KAAK,CAAC,EAAE,CAAC,CAAC;QAAC,WAAW,CAAC,EAAE,gBAAgB,CAAC,CAAC,CAAC,CAAA;KAAE;CACrG,CAAC,UAAU,CAAC,CAAC;AAEd;;;GAGG;AACH,MAAM,MAAM,UAAU,GAAG,iBAAiB,CAAC;AAS3C;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,KAAK,2GAwRhB,CAAC"}
@@ -20,7 +20,7 @@ import type { EffectModule } from '../bases/types';
20
20
  * `backdrop-filter: blur(...)` on the host element via CSS.
21
21
  */
22
22
  export interface AquaEffectParams {
23
- /** Body tint. Defaults to `var(--badge-edge)` so the badge's tone drives it. */
23
+ /** Body tint. Defaults to `var(--badge-edge)` so the badge's color drives it. */
24
24
  accent?: string;
25
25
  /** Stop opacities along the body gradient (0..1). */
26
26
  topAlpha?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"Aqua.d.ts","sourceRoot":"","sources":["../../../../src/components/Badge/effects/Aqua.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,WAAW,gBAAgB;IAC/B,gFAAgF;IAChF,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,qDAAqD;IACrD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,oDAAoD;IACpD,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,4EAA4E;IAC5E,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,gFAAgF;IAChF,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,6BAA6B;IAC7B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,0EAA0E;IAC1E,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F,eAAe,IAAI,CAAC"}
@@ -1,4 +1,4 @@
1
1
  export { Badge } from './Badge';
2
2
  export type { BadgeProps } from './Badge';
3
- export type { BadgeShape, BadgeTone, BadgeVariant, BadgeSize } from './types';
3
+ export type { BadgeShape, BadgeStatus, BadgeVariant, BadgeSize } from './types';
4
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Badge/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,YAAY,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,YAAY,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Badge/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,YAAY,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,YAAY,EAAE,UAAU,EAAE,WAAW,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC"}
@@ -1,2 +1,2 @@
1
- import { t as e } from "../../chunks/Badge-CW9pBPFl.js";
1
+ import { t as e } from "../../chunks/Badge-CyAIZSDo.js";
2
2
  export { e as Badge };
@@ -6,14 +6,15 @@ import type { ReactNode } from 'react';
6
6
  */
7
7
  export type BadgeShape = 'pill' | 'plain' | 'square' | 'notched' | 'perforated' | 'hexagon' | 'starburst' | 'scalloped' | 'shield' | 'ribbon' | 'beavis' | 'sparkler' | 'postage' | 'cloud' | 'house' | 'plaque' | 'crest' | 'urn' | 'coffin' | 'receipt' | 'wood' | 'quatrefoil';
8
8
  /**
9
- * Semantic color of a badge. `custom` paints from the `--badge-edge` custom
9
+ * Status color of a badge. `custom` paints from the `--badge-edge` custom
10
10
  * property instead of a theme token, so a call site can supply its own color.
11
11
  */
12
- export type BadgeTone = 'accent' | 'info' | 'warn' | 'danger' | 'muted' | 'neutral' | 'custom';
13
- /** How a badge's tone is applied: outline only, filled, or a soft tinted fill. */
12
+ export type BadgeStatus = 'accent' | 'info' | 'success' | 'warn' | 'danger' | 'muted' | 'neutral' | 'custom';
13
+ /** How a badge's color is applied: outline only, filled, or a soft tinted fill. */
14
14
  export type BadgeVariant = 'outline' | 'solid' | 'subtle';
15
- /** Badge type scale and padding step. */
16
- export type BadgeSize = 'sm' | 'md';
15
+ /** Badge type scale and padding step. `xs` is for counts and markers set
16
+ * inside a dense row, on the 2xs type step. */
17
+ export type BadgeSize = 'xs' | 'sm' | 'md';
17
18
  export interface ShapeRenderProps<P = Record<string, never>> {
18
19
  variant: BadgeVariant;
19
20
  focused: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/Badge/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;;;GAIG;AACH,MAAM,MAAM,UAAU,GAClB,MAAM,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,GAAG,YAAY,GACtD,SAAS,GACT,WAAW,GAAG,WAAW,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAC1D,UAAU,GAAG,SAAS,GAAG,OAAO,GAAG,OAAO,GAAG,QAAQ,GACrD,OAAO,GAAG,KAAK,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,YAAY,CAAC;AAEnE;;;GAGG;AACH,MAAM,MAAM,SAAS,GACjB,QAAQ,GAAG,MAAM,GAAG,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,CAAC;AAE3E,kFAAkF;AAClF,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,OAAO,GAAG,QAAQ,CAAC;AAC1D,yCAAyC;AACzC,MAAM,MAAM,SAAS,GAAG,IAAI,GAAG,IAAI,CAA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QAAC,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,EAAE,CAAC;CAChE;AAED,MAAM,WAAW,WAAW,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC;IACpD,2HAA2H;IAC3H,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,gBAAgB,CAAC,CAAC,CAAC,KAAK,SAAS,CAAC;IACtD,OAAO,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,KAAK,gBAAgB,CAAC;IAC1C,MAAM,EAAE,WAAW,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,WAAW,CAAC,CAAC;IACnD,SAAS,EAAE,OAAO,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,UAAU,CAAC,EAAE,KAAK,GAAG,KAAK,CAAC;IAC3B,QAAQ,CAAC,EAAE,CAAC,CAAC;CACd"}
@@ -1,2 +1,2 @@
1
- import { n as e, r as t, t as n } from "../../chunks/BandEditor-jY-PFKY6.js";
1
+ import { n as e, r as t, t as n } from "../../chunks/BandEditor-Dhm_Xrlr.js";
2
2
  export { n as BandEditor, e as linearScale, t as logScale };
@@ -1,11 +1,21 @@
1
1
  import { type ButtonHTMLAttributes, type ReactNode } from 'react';
2
- /** Visual weight of a button. Defaults to `secondary`. */
3
- export type ButtonVariant = 'primary' | 'secondary' | 'ghost';
2
+ import { type SegmentTooltipFields } from '../segmentTooltip';
3
+ import { type StanceProps } from '../stance';
4
+ /** Visual weight of a button. Defaults to `secondary`. `link` drops the
5
+ * control box entirely and reads as a hyperlink in running text -- for an
6
+ * in-page navigation that is still a button, not an `<a href>`. */
7
+ export type ButtonVariant = 'primary' | 'secondary' | 'ghost' | 'link';
8
+ /** Text color of a `link` button — the same set as `Code`'s statuses. */
9
+ export type ButtonStatus = 'neutral' | 'muted' | 'accent' | 'success' | 'warn' | 'danger';
4
10
  /** Button height and type scale. */
5
11
  export type ButtonSize = 'sm' | 'md';
6
12
  type ButtonBase = {
7
13
  variant?: ButtonVariant;
8
14
  size?: ButtonSize;
15
+ /** Text color of the `link` variant, which is `accent` unless told
16
+ * otherwise. The boxed variants carry their weight in their fill and
17
+ * ignore it. A peer `tone`, or a stance's accent, paints over it. */
18
+ status?: ButtonStatus;
9
19
  /** A button that stays down: renders `aria-pressed` and holds the active
10
20
  * treatment while it is on. For a control that reports a state rather than
11
21
  * firing an action -- a panel toggle, a mode switch. Left off, the button
@@ -21,7 +31,7 @@ type ButtonBase = {
21
31
  style?: ButtonHTMLAttributes<HTMLButtonElement>['style'];
22
32
  children?: ReactNode;
23
33
  onClick?: ButtonHTMLAttributes<HTMLButtonElement>['onClick'];
24
- };
34
+ } & StanceProps & SegmentTooltipFields;
25
35
  type ButtonRegular = ButtonBase & {
26
36
  iconOnly?: false;
27
37
  ariaLabel?: string;
@@ -40,6 +50,10 @@ export type ButtonProps = ButtonRegular | ButtonIconOnly;
40
50
  * button `aria-busy`, and leaves the label in place; it does not disable the
41
51
  * button, so pass `disabled` too if the click should be blocked.
42
52
  *
53
+ * `shortcut` adds a kit tooltip reading `Name (⌘S)`, named by `ariaLabel` or
54
+ * string children, the way `ToolButton` and `ButtonBar` items show theirs;
55
+ * `tooltip` replaces that text with any content.
56
+ *
43
57
  * `ref` forwards to the underlying `<button>`.
44
58
  */
45
59
  export declare const Button: import("react").ForwardRefExoticComponent<ButtonProps & import("react").RefAttributes<HTMLButtonElement>>;
@@ -1 +1 @@
1
- {"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/components/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAc,KAAK,oBAAoB,EAAE,KAAK,SAAS,EAAY,MAAM,OAAO,CAAC;AAGxF,0DAA0D;AAC1D,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,OAAO,CAAC;AAC9D,oCAAoC;AACpC,MAAM,MAAM,UAAU,GAAG,IAAI,GAAG,IAAI,CAAC;AAErC,KA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C;CACnB,CAAC;AAEF;;;GAGG;AACH,MAAM,MAAM,WAAW,GAAG,aAAa,GAAG,cAAc,CAAC;AA2BzD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,MAAM,2GA4EjB,CAAC"}
@@ -1,3 +1,3 @@
1
1
  export { Button } from './Button';
2
- export type { ButtonProps, ButtonVariant, ButtonSize } from './Button';
2
+ export type { ButtonProps, ButtonVariant, ButtonSize, ButtonStatus } from './Button';
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Button/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,YAAY,EAAE,WAAW,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Button/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,YAAY,EAAE,WAAW,EAAE,aAAa,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC"}
@@ -1,2 +1,2 @@
1
- import { t as e } from "../../chunks/Button-DRSApvnK.js";
1
+ import { t as e } from "../../chunks/Button-BIdXHQOx.js";
2
2
  export { e as Button };
@@ -0,0 +1,36 @@
1
+ import { type ReactElement, type ReactNode } from 'react';
2
+ import { type SegmentTooltipFields } from '../segmentTooltip';
3
+ /**
4
+ * One button in an {@link ButtonBar}. `value` is only a React key; the item
5
+ * carries no selected state.
6
+ */
7
+ export type ButtonBarItem<V extends string | number = string> = {
8
+ value: V;
9
+ label?: ReactNode;
10
+ ariaLabel?: string;
11
+ disabled?: boolean;
12
+ onAction: () => void;
13
+ } & SegmentTooltipFields;
14
+ /** Segment height and type scale for an {@link ButtonBar}. */
15
+ export type ButtonBarSize = 'sm' | 'md';
16
+ /** Visual treatment of an {@link ButtonBar}. */
17
+ export type ButtonBarVariant = 'default' | 'minimal';
18
+ /** Props for {@link ButtonBar}. */
19
+ export type ButtonBarProps<V extends string | number = string> = {
20
+ items: readonly ButtonBarItem<V>[];
21
+ ariaLabel?: string;
22
+ className?: string;
23
+ height?: number;
24
+ size?: ButtonBarSize;
25
+ variant?: ButtonBarVariant;
26
+ };
27
+ /**
28
+ * Segmented strip of momentary buttons — each press fires and nothing stays
29
+ * selected. Shares the look and the arrow-key navigation of `ToggleBar` and
30
+ * `OptionsBar`.
31
+ *
32
+ * This is a plain callback bar. For buttons driven by the kit's actions
33
+ * registry, use `ActionBar` instead.
34
+ */
35
+ export declare function ButtonBar<V extends string | number = string>(props: ButtonBarProps<V>): ReactElement;
36
+ //# sourceMappingURL=ButtonBar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ButtonBar.d.ts","sourceRoot":"","sources":["../../../src/components/ButtonBar/ButtonBar.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAsB,KAAK,YAAY,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAG9E,OAAO,EAAyC,KAAK,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAErG;;;GAGG;AACH,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,GAAG,MAAM,IAAI;IAC9D,KAAK,EAAE,CAAC,CAAC;IACT,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB,GAAG,oBAAoB,CAAC;AAEzB,8DAA8D;AAC9D,MAAM,MAAM,aAAa,GAAG,IAAI,GAAG,IAAI,CAAC;AACxC,gDAAgD;AAChD,MAAM,MAAM,gBAAgB,GAAG,SAAS,GAAG,SAAS,CAAC;AAErD,mCAAmC;AACnC,MAAM,MAAM,cAAc,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,GAAG,MAAM,IAAI;IAC/D,KAAK,EAAE,SAAS,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC;IACnC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,aAAa,CAAC;IACrB,OAAO,CAAC,EAAE,gBAAgB,CAAC;CAC5B,CAAC;AAEF;;;;;;;GAOG;AACH,wBAAgB,SAAS,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,KAAK,EAAE,cAAc,CAAC,CAAC,CAAC,GAAG,YAAY,CA+CpG"}
@@ -0,0 +1,3 @@
1
+ export { ButtonBar } from './ButtonBar';
2
+ export type { ButtonBarItem, ButtonBarProps, ButtonBarSize, ButtonBarVariant } from './ButtonBar';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ButtonBar/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,aAAa,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC"}
@@ -0,0 +1,2 @@
1
+ import { t as e } from "../../chunks/ButtonBar-D5Vi0aj_.js";
2
+ export { e as ButtonBar };
@@ -1,8 +1,7 @@
1
1
  import { type ReactNode, type RefObject } from 'react';
2
2
  import { DialogTrigger, type PopoverProps as RACPopoverProps } from 'react-aria-components';
3
3
  import { type OverlayPortalProps, type WithoutPortalTarget } from '../../overlays/portalHost';
4
- /** Accent color of a {@link Callout}'s border and arrow. */
5
- export type CalloutTone = 'info' | 'warning' | 'danger';
4
+ import { type StanceProps } from '../stance';
6
5
  /**
7
6
  * Composition wrapper for press-to-open callouts:
8
7
  * `<CalloutTrigger><Pressable>…</Pressable><Callout>…</Callout></CalloutTrigger>`.
@@ -13,15 +12,13 @@ export type CalloutTone = 'info' | 'warning' | 'danger';
13
12
  */
14
13
  export { DialogTrigger as CalloutTrigger };
15
14
  /** Props for {@link Callout}, on top of React Aria's `Popover` props. */
16
- export type CalloutProps = Omit<WithoutPortalTarget<RACPopoverProps>, 'children' | 'className' | 'isNonModal' | 'triggerRef'> & OverlayPortalProps & {
15
+ export type CalloutProps = Omit<WithoutPortalTarget<RACPopoverProps>, 'children' | 'className' | 'isNonModal' | 'triggerRef'> & OverlayPortalProps & StanceProps & {
17
16
  children?: ReactNode;
18
17
  className?: string;
19
18
  /** Optional heading rendered above the body. */
20
19
  title?: ReactNode;
21
20
  /** Footer slot — typically action buttons. */
22
21
  footer?: ReactNode;
23
- /** Accent tone for border + arrow. Default `info`. */
24
- tone?: CalloutTone;
25
22
  /**
26
23
  * `true` — blocks interaction with the rest of the app until dismissed;
27
24
  * inner dialog is `role="alertdialog"`. `false` (default) — non-blocking:
@@ -66,5 +63,5 @@ export type CalloutProps = Omit<WithoutPortalTarget<RACPopoverProps>, 'children'
66
63
  * Wraps React Aria Popover + Dialog; positioning, collision flipping,
67
64
  * dismissal, and focus behavior come from the underlying primitives.
68
65
  */
69
- export declare function Callout(props: CalloutProps): import("react/jsx-runtime").JSX.Element;
66
+ export declare function Callout(props: CalloutProps): import("react").JSX.Element;
70
67
  //# sourceMappingURL=Callout.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Callout.d.ts","sourceRoot":"","sources":["../../../src/components/Callout/Callout.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAyC,KAAK,SAAS,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAE9F,OAAO,EACL,aAAa,EAKb,KAAK,YAAY,IAAI,eAAe,EACrC,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAoB,KAAK,kBAAkB,EAAE,KAAK,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAGhH,4DAA4D;AAC5D,MAAM,MAAM,WAAW,GAAG,MAA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AAO,EAAoB,KAAK,kBAAkB,EAAE,KAAK,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAChH,OAAO,EAAE,KAAK,WAAW,EAAa,MAAM,WAAW,CAAC;AAGxD;;;;;;;GAOG;AACH,OAAO,EAAE,aAAa,IAAI,cAAc,EAAE,CAAC;AAE3C,yEAAyE;AACzE,MAAM,MAAM,YAAY,GAAG,IAAI,CAC7B,mBAAmB,CAAC,eAAe,CAAC,EACpC,UAAU,GAAG,WAAW,GAAG,YAAY,GAAG,YAAY,CACvD,GACC,kBAAkB,GAClB,WAAW,GAAG;IACd,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,gDAAgD;IAChD,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,8CAA8C;IAC9C,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB;;;;OAIG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB;;;;;OAKG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;;;;;;OAQG;IACH,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB,wEAAwE;IACxE,UAAU,CAAC,EAAE,SAAS,CAAC,OAAO,GAAG,IAAI,CAAC,CAAC;IACvC;;;;;OAKG;IACD,UAAU,CAAC,EAAE;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;CACtE,CAAC;AAEJ;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,YAAY,+BAoJ1C"}
@@ -1,3 +1,3 @@
1
1
  export { Callout, CalloutTrigger } from './Callout';
2
- export type { CalloutProps, CalloutTone } from './Callout';
2
+ export type { CalloutProps } from './Callout';
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Callout/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AACpD,YAAY,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Callout/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AACpD,YAAY,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC"}