@weasel-js/ui 1.6.1 → 1.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (340) hide show
  1. package/dist/chunks/Badge-CTc9Lkwn.js +14 -0
  2. package/dist/chunks/Badge-CTc9Lkwn.js.map +1 -0
  3. package/dist/chunks/{Badge-CyAIZSDo.js → Badge-D2aD7xVL.js} +277 -228
  4. package/dist/chunks/Badge-D2aD7xVL.js.map +1 -0
  5. package/dist/chunks/BandEditor-Dd0egAgE.js +292 -0
  6. package/dist/chunks/BandEditor-Dd0egAgE.js.map +1 -0
  7. package/dist/chunks/{ButtonBar-D5Vi0aj_.js → ButtonBar-DIQTe5GQ.js} +2 -2
  8. package/dist/chunks/{ButtonBar-D5Vi0aj_.js.map → ButtonBar-DIQTe5GQ.js.map} +1 -1
  9. package/dist/chunks/Callout-ndW5_Bqx.js +116 -0
  10. package/dist/chunks/Callout-ndW5_Bqx.js.map +1 -0
  11. package/dist/chunks/CloseButton-C2J7wVfo.js +26 -0
  12. package/dist/chunks/CloseButton-C2J7wVfo.js.map +1 -0
  13. package/dist/chunks/ColorField-Yz_BkcCT.js +69 -0
  14. package/dist/chunks/ColorField-Yz_BkcCT.js.map +1 -0
  15. package/dist/chunks/{ColorModeControl-ke5PXbBa.js → ColorModeControl-BewxA0rX.js} +3 -3
  16. package/dist/chunks/{ColorModeControl-ke5PXbBa.js.map → ColorModeControl-BewxA0rX.js.map} +1 -1
  17. package/dist/chunks/{ComboBox-DpT8lc3p.js → ComboBox-B34H76CW.js} +12 -12
  18. package/dist/chunks/ComboBox-B34H76CW.js.map +1 -0
  19. package/dist/chunks/{CurveEditor-BDJXjEvK.js → CurveEditor-DUVjd25R.js} +2 -2
  20. package/dist/chunks/{CurveEditor-BDJXjEvK.js.map → CurveEditor-DUVjd25R.js.map} +1 -1
  21. package/dist/chunks/{DataGrid-D-dZj1BD.js → DataGrid-LZ2JgY2Y.js} +17 -17
  22. package/dist/chunks/DataGrid-LZ2JgY2Y.js.map +1 -0
  23. package/dist/chunks/DetailList-BKomDzg5.js +52 -0
  24. package/dist/chunks/DetailList-BKomDzg5.js.map +1 -0
  25. package/dist/chunks/{DetentSlider-CL8TlX3S.js → DetentSlider-5uQPFucv.js} +2 -2
  26. package/dist/chunks/{DetentSlider-CL8TlX3S.js.map → DetentSlider-5uQPFucv.js.map} +1 -1
  27. package/dist/chunks/Dialog-DGFutQ--.js +63 -0
  28. package/dist/chunks/Dialog-DGFutQ--.js.map +1 -0
  29. package/dist/chunks/{Disclosure-0G0uh2fa.js → Disclosure-Ch2KxYuB.js} +7 -7
  30. package/dist/chunks/Disclosure-Ch2KxYuB.js.map +1 -0
  31. package/dist/chunks/{DragHandleGlyph-Dr7Fgo0I.js → DragGrip-AoIZXfZb.js} +2 -2
  32. package/dist/chunks/DragGrip-AoIZXfZb.js.map +1 -0
  33. package/dist/chunks/FallthroughDiagram-BEHiM5IS.js +284 -0
  34. package/dist/chunks/FallthroughDiagram-BEHiM5IS.js.map +1 -0
  35. package/dist/chunks/{FontFamilySelect-DXlMKWfK.js → FontFamilySelect-DkRgNtag.js} +2 -2
  36. package/dist/chunks/{FontFamilySelect-DXlMKWfK.js.map → FontFamilySelect-DkRgNtag.js.map} +1 -1
  37. package/dist/chunks/GestureRoute-C_YGl7bJ.js +82 -0
  38. package/dist/chunks/GestureRoute-C_YGl7bJ.js.map +1 -0
  39. package/dist/chunks/GradientEditor-b7v4Ph3i.js +363 -0
  40. package/dist/chunks/GradientEditor-b7v4Ph3i.js.map +1 -0
  41. package/dist/chunks/{Icon-Cgzy8VgC.js → Icon-CcVjdq2C.js} +31 -1
  42. package/dist/chunks/Icon-CcVjdq2C.js.map +1 -0
  43. package/dist/chunks/{InlineRange-eOj6JpJl.js → InlineRange-P01ABSzo.js} +3 -3
  44. package/dist/chunks/InlineRange-P01ABSzo.js.map +1 -0
  45. package/dist/chunks/{Jog-DESxZ44P.js → Jog-DRmfrkCg.js} +3 -3
  46. package/dist/chunks/{Jog-DESxZ44P.js.map → Jog-DRmfrkCg.js.map} +1 -1
  47. package/dist/chunks/{Keycaps-C0H_v2gO.js → Keycaps-C-FJyG8k.js} +14 -14
  48. package/dist/chunks/Keycaps-C-FJyG8k.js.map +1 -0
  49. package/dist/chunks/{LayerList-nz-QYvTF.js → LayerList-wCI1EueM.js} +148 -152
  50. package/dist/chunks/LayerList-wCI1EueM.js.map +1 -0
  51. package/dist/chunks/ListEditor-BeA60TAA.js +71 -0
  52. package/dist/chunks/ListEditor-BeA60TAA.js.map +1 -0
  53. package/dist/chunks/{MenuButton-DtaGenKf.js → MenuButton-BSqEChJE.js} +7 -7
  54. package/dist/chunks/MenuButton-BSqEChJE.js.map +1 -0
  55. package/dist/chunks/{MeshEditor-qqGc6hlD.js → MeshEditor-D1HLZcAh.js} +3 -3
  56. package/dist/chunks/{MeshEditor-qqGc6hlD.js.map → MeshEditor-D1HLZcAh.js.map} +1 -1
  57. package/dist/chunks/NumberField-BnJxcazc.js +206 -0
  58. package/dist/chunks/NumberField-BnJxcazc.js.map +1 -0
  59. package/dist/chunks/{OptionsBar-DbzAgIln.js → OptionsBar-ujxYidhj.js} +2 -2
  60. package/dist/chunks/{OptionsBar-DbzAgIln.js.map → OptionsBar-ujxYidhj.js.map} +1 -1
  61. package/dist/chunks/{PaintField-DaJukRc6.js → PaintField-DadOELMg.js} +2 -2
  62. package/dist/chunks/{PaintField-DaJukRc6.js.map → PaintField-DadOELMg.js.map} +1 -1
  63. package/dist/chunks/PaintInput-v8Y7MDbH.js +121 -0
  64. package/dist/chunks/PaintInput-v8Y7MDbH.js.map +1 -0
  65. package/dist/chunks/{PatternPicker-B-cUt-JT.js → PatternPicker-R_EQtw2Q.js} +2 -2
  66. package/dist/chunks/{PatternPicker-B-cUt-JT.js.map → PatternPicker-R_EQtw2Q.js.map} +1 -1
  67. package/dist/chunks/{PointPlotter-Bxo6haKe.js → PointPlotter-ldI4RrU1.js} +2 -2
  68. package/dist/chunks/{PointPlotter-Bxo6haKe.js.map → PointPlotter-ldI4RrU1.js.map} +1 -1
  69. package/dist/chunks/{Powerline-ExO5GwEr.js → Powerline-DNyH885r.js} +2 -2
  70. package/dist/chunks/{Powerline-ExO5GwEr.js.map → Powerline-DNyH885r.js.map} +1 -1
  71. package/dist/chunks/{Prefs-DpqFKiwY.js → Prefs-ByA-x51i.js} +46 -34
  72. package/dist/chunks/Prefs-ByA-x51i.js.map +1 -0
  73. package/dist/chunks/{Properties-D_KzDN9K.js → Properties-DmAeQ3mk.js} +35 -29
  74. package/dist/chunks/Properties-DmAeQ3mk.js.map +1 -0
  75. package/dist/chunks/PropertyField-DfIJJ5GS.js +673 -0
  76. package/dist/chunks/PropertyField-DfIJJ5GS.js.map +1 -0
  77. package/dist/chunks/{RangeSlider-BKRRTPTZ.js → RangeSlider-SEGE-7VF.js} +8 -8
  78. package/dist/chunks/RangeSlider-SEGE-7VF.js.map +1 -0
  79. package/dist/chunks/{ResizeHandle-BKT0XYpx.js → ResizeHandle-rKVWyeTG.js} +3 -3
  80. package/dist/chunks/ResizeHandle-rKVWyeTG.js.map +1 -0
  81. package/dist/chunks/Select-ClmKtyWg.js +229 -0
  82. package/dist/chunks/Select-ClmKtyWg.js.map +1 -0
  83. package/dist/chunks/SelectionPanel-BaQnX4Bs.js +106 -0
  84. package/dist/chunks/SelectionPanel-BaQnX4Bs.js.map +1 -0
  85. package/dist/chunks/SidebarPanel-BblDEz4G.js +53 -0
  86. package/dist/chunks/SidebarPanel-BblDEz4G.js.map +1 -0
  87. package/dist/chunks/Slider-YofwGOI4.js +389 -0
  88. package/dist/chunks/Slider-YofwGOI4.js.map +1 -0
  89. package/dist/chunks/{StatusBar-DzoPDY4k.js → StatusBar-Ca9Dvhhq.js} +6 -6
  90. package/dist/chunks/StatusBar-Ca9Dvhhq.js.map +1 -0
  91. package/dist/chunks/{SwatchGrid-BARC3rnF.js → SwatchGrid-BYvA8Bmh.js} +3 -3
  92. package/dist/chunks/SwatchGrid-BYvA8Bmh.js.map +1 -0
  93. package/dist/chunks/ThemeSwitcher-BlsInAmR.js +38 -0
  94. package/dist/chunks/ThemeSwitcher-BlsInAmR.js.map +1 -0
  95. package/dist/chunks/{Timeline--58F7MED.js → Timeline-B39cwfMB.js} +207 -203
  96. package/dist/chunks/Timeline-B39cwfMB.js.map +1 -0
  97. package/dist/chunks/{Toast-DNBb-24H.js → Toast-BF9GE0HC.js} +25 -27
  98. package/dist/chunks/Toast-BF9GE0HC.js.map +1 -0
  99. package/dist/chunks/{ToggleBar-DTjGeS0Q.js → ToggleBar-BTYkBXU9.js} +8 -8
  100. package/dist/chunks/ToggleBar-BTYkBXU9.js.map +1 -0
  101. package/dist/chunks/{TokenPanel-CMq7uydV.js → TokenPanel-CMDAOfYH.js} +5 -5
  102. package/dist/chunks/{TokenPanel-CMq7uydV.js.map → TokenPanel-CMDAOfYH.js.map} +1 -1
  103. package/dist/chunks/{ToolButton-CR4sQlxF.js → ToolButton-CAHBa08P.js} +6 -6
  104. package/dist/chunks/ToolButton-CAHBa08P.js.map +1 -0
  105. package/dist/chunks/{ToolOptionsBar-CtzTlaN2.js → ToolOptionsBar-D_GCrBAN.js} +8 -7
  106. package/dist/chunks/ToolOptionsBar-D_GCrBAN.js.map +1 -0
  107. package/dist/chunks/{ToolPalette-CKG9qY6P.js → ToolPalette-OOWN51Xx.js} +3 -3
  108. package/dist/chunks/ToolPalette-OOWN51Xx.js.map +1 -0
  109. package/dist/chunks/{Tree-DVOtc9R5.js → Tree-Cc8lIzgM.js} +2 -2
  110. package/dist/chunks/{Tree-DVOtc9R5.js.map → Tree-Cc8lIzgM.js.map} +1 -1
  111. package/dist/chunks/{createKeyframeLayer-Czj6Y235.js → createKeyframeLayer-DVl321_l.js} +15 -16
  112. package/dist/chunks/createKeyframeLayer-DVl321_l.js.map +1 -0
  113. package/dist/chunks/{icons-Dk8SRS8g.js → icons-BhcR1l64.js} +2 -2
  114. package/dist/chunks/icons-BhcR1l64.js.map +1 -0
  115. package/dist/chunks/{model-Du7Lta4C.js → model-BaF65rnX.js} +95 -90
  116. package/dist/chunks/model-BaF65rnX.js.map +1 -0
  117. package/dist/chunks/{prefField-Dnl7nmjQ.js → prefField-BopW9bjx.js} +17 -13
  118. package/dist/chunks/prefField-BopW9bjx.js.map +1 -0
  119. package/dist/chunks/segmentedControl.module-D6SzYJD7.js +11 -0
  120. package/dist/chunks/segmentedControl.module-D6SzYJD7.js.map +1 -0
  121. package/dist/chunks/{useReorderDragList-B_-5L5Gu.js → useReorderDragList-FCMoFIzH.js} +2 -2
  122. package/dist/chunks/useReorderDragList-FCMoFIzH.js.map +1 -0
  123. package/dist/components/Badge/bases/Powerline.d.ts.map +1 -1
  124. package/dist/components/Badge/bases/edgeProfiles.d.ts +31 -4
  125. package/dist/components/Badge/bases/edgeProfiles.d.ts.map +1 -1
  126. package/dist/components/Badge/index.d.ts +1 -0
  127. package/dist/components/Badge/index.d.ts.map +1 -1
  128. package/dist/components/Badge/index.js +3 -2
  129. package/dist/components/Badge/statusIcons.d.ts +5 -0
  130. package/dist/components/Badge/statusIcons.d.ts.map +1 -0
  131. package/dist/components/BandEditor/BandEditor.d.ts +16 -7
  132. package/dist/components/BandEditor/BandEditor.d.ts.map +1 -1
  133. package/dist/components/BandEditor/bands.d.ts +5 -2
  134. package/dist/components/BandEditor/bands.d.ts.map +1 -1
  135. package/dist/components/BandEditor/index.js +1 -1
  136. package/dist/components/ButtonBar/index.js +1 -1
  137. package/dist/components/Callout/Callout.d.ts +2 -2
  138. package/dist/components/Callout/Callout.d.ts.map +1 -1
  139. package/dist/components/Callout/index.js +1 -1
  140. package/dist/components/CloseButton/CloseButton.d.ts +21 -0
  141. package/dist/components/CloseButton/CloseButton.d.ts.map +1 -0
  142. package/dist/components/CloseButton/index.d.ts +3 -0
  143. package/dist/components/CloseButton/index.d.ts.map +1 -0
  144. package/dist/components/CloseButton/index.js +2 -0
  145. package/dist/components/ColorField/ColorField.d.ts +5 -1
  146. package/dist/components/ColorField/ColorField.d.ts.map +1 -1
  147. package/dist/components/ColorField/index.js +1 -1
  148. package/dist/components/ColorModeControl/index.js +1 -1
  149. package/dist/components/ComboBox/index.js +1 -1
  150. package/dist/components/CurveEditor/index.js +2 -2
  151. package/dist/components/DataGrid/index.js +1 -1
  152. package/dist/components/DetailList/DetailList.d.ts +31 -5
  153. package/dist/components/DetailList/DetailList.d.ts.map +1 -1
  154. package/dist/components/DetailList/index.d.ts +1 -1
  155. package/dist/components/DetailList/index.d.ts.map +1 -1
  156. package/dist/components/DetailList/index.js +1 -1
  157. package/dist/components/DetentSlider/index.js +1 -1
  158. package/dist/components/Dialog/Dialog.d.ts.map +1 -1
  159. package/dist/components/Dialog/index.js +1 -1
  160. package/dist/components/Disclosure/Disclosure.d.ts +1 -1
  161. package/dist/components/Disclosure/index.js +1 -1
  162. package/dist/components/{DragHandleGlyph/DragHandleGlyph.d.ts → DragGrip/DragGrip.d.ts} +4 -4
  163. package/dist/components/DragGrip/DragGrip.d.ts.map +1 -0
  164. package/dist/components/DragGrip/index.d.ts +3 -0
  165. package/dist/components/DragGrip/index.d.ts.map +1 -0
  166. package/dist/components/DragGrip/index.js +2 -0
  167. package/dist/components/FallthroughDiagram/FallthroughDiagram.d.ts +14 -0
  168. package/dist/components/FallthroughDiagram/FallthroughDiagram.d.ts.map +1 -0
  169. package/dist/components/FallthroughDiagram/fixtures.d.ts +17 -0
  170. package/dist/components/FallthroughDiagram/fixtures.d.ts.map +1 -0
  171. package/dist/components/FallthroughDiagram/index.d.ts +3 -0
  172. package/dist/components/FallthroughDiagram/index.d.ts.map +1 -0
  173. package/dist/components/FallthroughDiagram/index.js +2 -0
  174. package/dist/components/FontFamilySelect/index.js +1 -1
  175. package/dist/components/GestureRoute/GestureRoute.d.ts +19 -0
  176. package/dist/components/GestureRoute/GestureRoute.d.ts.map +1 -0
  177. package/dist/components/GestureRoute/index.d.ts +3 -0
  178. package/dist/components/GestureRoute/index.d.ts.map +1 -0
  179. package/dist/components/GestureRoute/index.js +2 -0
  180. package/dist/components/GradientEditor/GradientEditor.d.ts +22 -8
  181. package/dist/components/GradientEditor/GradientEditor.d.ts.map +1 -1
  182. package/dist/components/GradientEditor/index.js +1 -1
  183. package/dist/components/InlineRange/index.js +1 -1
  184. package/dist/components/Jog/index.js +1 -1
  185. package/dist/components/Keycaps/Keycaps.d.ts +11 -5
  186. package/dist/components/Keycaps/Keycaps.d.ts.map +1 -1
  187. package/dist/components/Keycaps/index.d.ts +1 -1
  188. package/dist/components/Keycaps/index.d.ts.map +1 -1
  189. package/dist/components/Keycaps/index.js +1 -1
  190. package/dist/components/LayerList/LayerList.d.ts +1 -1
  191. package/dist/components/LayerList/LayerList.d.ts.map +1 -1
  192. package/dist/components/LayerList/index.js +1 -1
  193. package/dist/components/ListEditor/ListEditor.d.ts.map +1 -1
  194. package/dist/components/ListEditor/index.js +1 -1
  195. package/dist/components/MenuButton/index.js +1 -1
  196. package/dist/components/MeshEditor/index.js +1 -1
  197. package/dist/components/NumberField/UnitField.d.ts +20 -7
  198. package/dist/components/NumberField/UnitField.d.ts.map +1 -1
  199. package/dist/components/NumberField/index.js +1 -1
  200. package/dist/components/OptionsBar/index.js +1 -1
  201. package/dist/components/PaintField/index.js +1 -1
  202. package/dist/components/PaintInput/PaintInput.d.ts.map +1 -1
  203. package/dist/components/PaintInput/index.js +1 -1
  204. package/dist/components/PatternPicker/index.js +1 -1
  205. package/dist/components/PointPlotter/index.js +1 -1
  206. package/dist/components/Powerline/index.d.ts +1 -1
  207. package/dist/components/Powerline/index.d.ts.map +1 -1
  208. package/dist/components/Powerline/index.js +2 -2
  209. package/dist/components/Prefs/PrefsRow.d.ts.map +1 -1
  210. package/dist/components/Prefs/index.d.ts +1 -1
  211. package/dist/components/Prefs/index.d.ts.map +1 -1
  212. package/dist/components/Prefs/index.js +2 -2
  213. package/dist/components/Prefs/prefField.d.ts.map +1 -1
  214. package/dist/components/Prefs/schema.d.ts +2 -2
  215. package/dist/components/Prefs/schema.d.ts.map +1 -1
  216. package/dist/components/Properties/PropertyField.d.ts +22 -30
  217. package/dist/components/Properties/PropertyField.d.ts.map +1 -1
  218. package/dist/components/Properties/PropertyGroup.d.ts.map +1 -1
  219. package/dist/components/Properties/PropertyPanel.d.ts +1 -8
  220. package/dist/components/Properties/PropertyPanel.d.ts.map +1 -1
  221. package/dist/components/Properties/index.d.ts +1 -1
  222. package/dist/components/Properties/index.d.ts.map +1 -1
  223. package/dist/components/Properties/index.js +2 -2
  224. package/dist/components/RangeSlider/index.js +1 -1
  225. package/dist/components/ResizeHandle/index.js +1 -1
  226. package/dist/components/Select/Select.d.ts.map +1 -1
  227. package/dist/components/Select/index.js +1 -1
  228. package/dist/components/SelectionPanel/SelectionPanel.d.ts.map +1 -1
  229. package/dist/components/SelectionPanel/index.js +2 -2
  230. package/dist/components/SelectionPanel/renderLeaf.d.ts +7 -0
  231. package/dist/components/SelectionPanel/renderLeaf.d.ts.map +1 -1
  232. package/dist/components/SidebarPanel/SidebarPanel.d.ts +1 -1
  233. package/dist/components/SidebarPanel/SidebarPanel.d.ts.map +1 -1
  234. package/dist/components/SidebarPanel/index.js +1 -1
  235. package/dist/components/Slider/Slider.d.ts +19 -2
  236. package/dist/components/Slider/Slider.d.ts.map +1 -1
  237. package/dist/components/Slider/index.js +1 -1
  238. package/dist/components/StatusBar/index.js +1 -1
  239. package/dist/components/SwatchGrid/index.js +1 -1
  240. package/dist/components/ThemeSwitcher/ThemeSwitcher.d.ts +38 -0
  241. package/dist/components/ThemeSwitcher/ThemeSwitcher.d.ts.map +1 -0
  242. package/dist/components/ThemeSwitcher/index.d.ts +3 -0
  243. package/dist/components/ThemeSwitcher/index.d.ts.map +1 -0
  244. package/dist/components/ThemeSwitcher/index.js +2 -0
  245. package/dist/components/Timeline/Transport.d.ts.map +1 -1
  246. package/dist/components/Timeline/index.js +1 -1
  247. package/dist/components/Toast/Toast.d.ts.map +1 -1
  248. package/dist/components/Toast/index.js +1 -1
  249. package/dist/components/ToggleBar/index.js +1 -1
  250. package/dist/components/TokenPanel/index.js +1 -1
  251. package/dist/components/ToolButton/index.js +1 -1
  252. package/dist/components/ToolOptionsBar/index.js +1 -1
  253. package/dist/components/ToolPalette/ToolPalette.d.ts +2 -1
  254. package/dist/components/ToolPalette/ToolPalette.d.ts.map +1 -1
  255. package/dist/components/ToolPalette/index.js +1 -1
  256. package/dist/components/Tree/index.js +1 -1
  257. package/dist/components/spin.d.ts +16 -0
  258. package/dist/components/spin.d.ts.map +1 -0
  259. package/dist/components/stanceSurfaces.d.ts.map +1 -1
  260. package/dist/icons/index.d.ts +0 -2
  261. package/dist/icons/index.d.ts.map +1 -1
  262. package/dist/icons/paths.d.ts +10 -0
  263. package/dist/icons/paths.d.ts.map +1 -1
  264. package/dist/index.d.ts +5 -2
  265. package/dist/index.d.ts.map +1 -1
  266. package/dist/index.js +83 -99
  267. package/dist/index.js.map +1 -1
  268. package/dist/paintGradientTrack.d.ts +5 -2
  269. package/dist/paintGradientTrack.d.ts.map +1 -1
  270. package/dist/style.css +1 -1
  271. package/dist/useReorderDragList.d.ts +1 -1
  272. package/dist/useReorderDragList.d.ts.map +1 -1
  273. package/package.json +9 -8
  274. package/dist/chunks/Badge-CyAIZSDo.js.map +0 -1
  275. package/dist/chunks/BandEditor-Dhm_Xrlr.js +0 -248
  276. package/dist/chunks/BandEditor-Dhm_Xrlr.js.map +0 -1
  277. package/dist/chunks/Callout-yEn9iPlh.js +0 -119
  278. package/dist/chunks/Callout-yEn9iPlh.js.map +0 -1
  279. package/dist/chunks/ColorField-BcMcW8Sa.js +0 -60
  280. package/dist/chunks/ColorField-BcMcW8Sa.js.map +0 -1
  281. package/dist/chunks/ComboBox-DpT8lc3p.js.map +0 -1
  282. package/dist/chunks/DataGrid-D-dZj1BD.js.map +0 -1
  283. package/dist/chunks/DetailList-BMER1LUZ.js +0 -43
  284. package/dist/chunks/DetailList-BMER1LUZ.js.map +0 -1
  285. package/dist/chunks/Dialog-BWyNMgpf.js +0 -66
  286. package/dist/chunks/Dialog-BWyNMgpf.js.map +0 -1
  287. package/dist/chunks/Disclosure-0G0uh2fa.js.map +0 -1
  288. package/dist/chunks/DragHandleGlyph-Dr7Fgo0I.js.map +0 -1
  289. package/dist/chunks/GradientEditor-B3a-MsVJ.js +0 -335
  290. package/dist/chunks/GradientEditor-B3a-MsVJ.js.map +0 -1
  291. package/dist/chunks/Icon-Cgzy8VgC.js.map +0 -1
  292. package/dist/chunks/InlineRange-eOj6JpJl.js.map +0 -1
  293. package/dist/chunks/Keycaps-C0H_v2gO.js.map +0 -1
  294. package/dist/chunks/LayerList-nz-QYvTF.js.map +0 -1
  295. package/dist/chunks/ListEditor-BQ6AV3Ac.js +0 -74
  296. package/dist/chunks/ListEditor-BQ6AV3Ac.js.map +0 -1
  297. package/dist/chunks/MenuButton-DtaGenKf.js.map +0 -1
  298. package/dist/chunks/NumberField-CwJOMmQR.js +0 -117
  299. package/dist/chunks/NumberField-CwJOMmQR.js.map +0 -1
  300. package/dist/chunks/PaintInput-Byhna3H-.js +0 -131
  301. package/dist/chunks/PaintInput-Byhna3H-.js.map +0 -1
  302. package/dist/chunks/Prefs-DpqFKiwY.js.map +0 -1
  303. package/dist/chunks/Properties-D_KzDN9K.js.map +0 -1
  304. package/dist/chunks/PropertyField-DGCecAnV.js +0 -758
  305. package/dist/chunks/PropertyField-DGCecAnV.js.map +0 -1
  306. package/dist/chunks/RangeSlider-BKRRTPTZ.js.map +0 -1
  307. package/dist/chunks/ResizeHandle-BKT0XYpx.js.map +0 -1
  308. package/dist/chunks/Select-CzyfaXzp.js +0 -225
  309. package/dist/chunks/Select-CzyfaXzp.js.map +0 -1
  310. package/dist/chunks/SelectionPanel-BgUM1h03.js +0 -103
  311. package/dist/chunks/SelectionPanel-BgUM1h03.js.map +0 -1
  312. package/dist/chunks/SidebarPanel-aoIqxbtq.js +0 -55
  313. package/dist/chunks/SidebarPanel-aoIqxbtq.js.map +0 -1
  314. package/dist/chunks/Slider-CFwQYQ10.js +0 -383
  315. package/dist/chunks/Slider-CFwQYQ10.js.map +0 -1
  316. package/dist/chunks/StatusBar-DzoPDY4k.js.map +0 -1
  317. package/dist/chunks/SwatchGrid-BARC3rnF.js.map +0 -1
  318. package/dist/chunks/Timeline--58F7MED.js.map +0 -1
  319. package/dist/chunks/Toast-DNBb-24H.js.map +0 -1
  320. package/dist/chunks/ToggleBar-DTjGeS0Q.js.map +0 -1
  321. package/dist/chunks/ToolButton-CR4sQlxF.js.map +0 -1
  322. package/dist/chunks/ToolOptionsBar-CtzTlaN2.js.map +0 -1
  323. package/dist/chunks/ToolPalette-CKG9qY6P.js.map +0 -1
  324. package/dist/chunks/createKeyframeLayer-Czj6Y235.js.map +0 -1
  325. package/dist/chunks/icons-Dk8SRS8g.js.map +0 -1
  326. package/dist/chunks/model-Du7Lta4C.js.map +0 -1
  327. package/dist/chunks/number-D3NEx_8r.js +0 -89
  328. package/dist/chunks/number-D3NEx_8r.js.map +0 -1
  329. package/dist/chunks/prefField-Dnl7nmjQ.js.map +0 -1
  330. package/dist/chunks/segmentedControl.module-Bv7DEg8f.js +0 -11
  331. package/dist/chunks/segmentedControl.module-Bv7DEg8f.js.map +0 -1
  332. package/dist/chunks/useReorderDragList-B_-5L5Gu.js.map +0 -1
  333. package/dist/components/DragHandleGlyph/DragHandleGlyph.d.ts.map +0 -1
  334. package/dist/components/DragHandleGlyph/index.d.ts +0 -3
  335. package/dist/components/DragHandleGlyph/index.d.ts.map +0 -1
  336. package/dist/components/DragHandleGlyph/index.js +0 -2
  337. package/dist/format/number.d.ts +0 -56
  338. package/dist/format/number.d.ts.map +0 -1
  339. package/dist/icons/ShapeKindIcon.d.ts +0 -10
  340. package/dist/icons/ShapeKindIcon.d.ts.map +0 -1
@@ -0,0 +1,673 @@
1
+ import { t as e } from "./dlog-F0I8KsIW.js";
2
+ import { n as t, r as n } from "./Tooltip-Clg2mhSt.js";
3
+ import { t as r } from "./stance-BFQpS_fL.js";
4
+ import { n as i } from "./InlineRange-P01ABSzo.js";
5
+ import { t as a } from "./ColorField-Yz_BkcCT.js";
6
+ import { t as o } from "./Select-ClmKtyWg.js";
7
+ import { t as s } from "./FontFamilySelect-DkRgNtag.js";
8
+ import { t as c } from "./Input-CHmkfYaD.js";
9
+ import { n as l, t as u } from "./NumberField-BnJxcazc.js";
10
+ import { t as d } from "./ToggleBar-BTYkBXU9.js";
11
+ import { t as f } from "./PaintInput-v8Y7MDbH.js";
12
+ import { t as p } from "./PaintField-DadOELMg.js";
13
+ import { n as m, t as h } from "./RadioGroup-Bh4-12e-.js";
14
+ import { t as g } from "./Switch-CSYmcM8y.js";
15
+ import { getAlpha01 as _, toHex8 as v, withAlpha01 as y } from "@weasel-js/core";
16
+ import { Fragment as b, jsx as x, jsxs as S } from "react/jsx-runtime";
17
+ import { createContext as C, forwardRef as ee, useContext as te, useEffect as w, useId as ne, useRef as T, useState as E } from "react";
18
+ import { Focusable as D } from "react-aria-components";
19
+ import { decimal as O, parseAs as k, qty as A } from "@weasel-js/quantity";
20
+ var j = {
21
+ panel: "_panel_qyg4g_9",
22
+ list: "_list_qyg4g_3",
23
+ row: "_row_qyg4g_4",
24
+ group: "_group_qyg4g_4",
25
+ subpanel: "_subpanel_qyg4g_3",
26
+ card: "_card_qyg4g_37",
27
+ cardList: "_cardList_qyg4g_37",
28
+ readout: "_readout_qyg4g_42",
29
+ readoutInput: "_readoutInput_qyg4g_43",
30
+ panelTitle: "_panelTitle_qyg4g_72",
31
+ panelHeader: "_panelHeader_qyg4g_84",
32
+ panelActions: "_panelActions_qyg4g_97",
33
+ listPairs: "_listPairs_qyg4g_3",
34
+ rowColor: "_rowColor_qyg4g_4",
35
+ span: "_span_qyg4g_505",
36
+ listOneUp: "_listOneUp_qyg4g_513",
37
+ densityTight: "_densityTight_qyg4g_524",
38
+ densityNormal: "_densityNormal_qyg4g_536",
39
+ densityRoomy: "_densityRoomy_qyg4g_548",
40
+ alignStart: "_alignStart_qyg4g_574",
41
+ alignCenter: "_alignCenter_qyg4g_580",
42
+ alignEnd: "_alignEnd_qyg4g_586",
43
+ alignBaseline: "_alignBaseline_qyg4g_592",
44
+ rowInline: "_rowInline_qyg4g_623",
45
+ rowLabel: "_rowLabel_qyg4g_629",
46
+ rowBlock: "_rowBlock_qyg4g_654",
47
+ rowCheckbox: "_rowCheckbox_qyg4g_655",
48
+ readoutAfter: "_readoutAfter_qyg4g_674",
49
+ readoutText: "_readoutText_qyg4g_685",
50
+ help: "_help_qyg4g_698",
51
+ autoToggle: "_autoToggle_qyg4g_732",
52
+ readoutGroup: "_readoutGroup_qyg4g_680",
53
+ readoutUnit: "_readoutUnit_qyg4g_809",
54
+ fieldUnitGroup: "_fieldUnitGroup_qyg4g_834",
55
+ numberField: "_numberField_qyg4g_842",
56
+ toggleBar: "_toggleBar_qyg4g_882",
57
+ textField: "_textField_qyg4g_900",
58
+ select: "_select_qyg4g_913",
59
+ dialogTrigger: "_dialogTrigger_qyg4g_1034",
60
+ dialogSummary: "_dialogSummary_qyg4g_1069",
61
+ dialogGlyph: "_dialogGlyph_qyg4g_1077",
62
+ colorField: "_colorField_qyg4g_1151",
63
+ dimmed: "_dimmed_qyg4g_1232",
64
+ cellReadout: "_cellReadout_qyg4g_1238",
65
+ textarea: "_textarea_qyg4g_1244",
66
+ checkbox: "_checkbox_qyg4g_1267",
67
+ groupHeadRow: "_groupHeadRow_qyg4g_1337",
68
+ groupTitle: "_groupTitle_qyg4g_1345",
69
+ groupLeading: "_groupLeading_qyg4g_1351",
70
+ groupActions: "_groupActions_qyg4g_1352",
71
+ note: "_note_qyg4g_1549",
72
+ groupTitleMid: "_groupTitleMid_qyg4g_1579",
73
+ groupTwisty: "_groupTwisty_qyg4g_1585",
74
+ groupBody: "_groupBody_qyg4g_4",
75
+ groupPairs: "_groupPairs_qyg4g_1614",
76
+ groupOneUp: "_groupOneUp_qyg4g_1627",
77
+ subpanelTitle: "_subpanelTitle_qyg4g_1767",
78
+ rowAuto: "_rowAuto_qyg4g_1804"
79
+ }, M = {
80
+ tight: j.densityTight,
81
+ normal: j.densityNormal,
82
+ roomy: j.densityRoomy
83
+ }, N = {
84
+ start: j.alignStart,
85
+ center: j.alignCenter,
86
+ end: j.alignEnd,
87
+ baseline: j.alignBaseline
88
+ };
89
+ function P(e, { density: t, align: n }, r) {
90
+ return [
91
+ e,
92
+ t && M[t],
93
+ n && N[n],
94
+ r
95
+ ].filter(Boolean).join(" ");
96
+ }
97
+ var F = C(!1);
98
+ function re({ title: e, actions: t, selectable: n, children: i, className: a, density: o, align: s, stance: c, tone: l }) {
99
+ let u = te(F), d = r({
100
+ stance: c,
101
+ tone: l
102
+ }), f = e != null && /* @__PURE__ */ x("h2", {
103
+ className: j.panelTitle,
104
+ children: e
105
+ });
106
+ return /* @__PURE__ */ S("div", {
107
+ className: P(j.panel, {
108
+ density: o,
109
+ align: s
110
+ }, a),
111
+ ...d,
112
+ "data-nested": u || void 0,
113
+ "data-selectable": (n ?? c === "debug") || void 0,
114
+ children: [t == null ? f : /* @__PURE__ */ S("div", {
115
+ className: j.panelHeader,
116
+ children: [f, /* @__PURE__ */ x("div", {
117
+ className: j.panelActions,
118
+ children: t
119
+ })]
120
+ }), /* @__PURE__ */ x(F.Provider, {
121
+ value: !0,
122
+ children: i
123
+ })]
124
+ });
125
+ }
126
+ var ie = ee(function({ children: e, className: t, pack: n = "auto-color", density: r, align: i }, a) {
127
+ let o = `${j.list}${n === "pairs" ? ` ${j.listPairs}` : n === "one-up" ? ` ${j.listOneUp}` : ""}`;
128
+ return /* @__PURE__ */ x("div", {
129
+ ref: a,
130
+ className: P(o, {
131
+ density: r,
132
+ align: i
133
+ }, t),
134
+ children: e
135
+ });
136
+ });
137
+ function ae({ children: e, className: t }) {
138
+ return /* @__PURE__ */ x("div", {
139
+ className: t ? `${j.span} ${t}` : j.span,
140
+ children: e
141
+ });
142
+ }
143
+ function oe({ children: e, className: t }) {
144
+ return /* @__PURE__ */ x("p", {
145
+ className: t ? `${j.note} ${t}` : j.note,
146
+ children: e
147
+ });
148
+ }
149
+ function I({ label: e, readout: t, description: n, variant: r = "default", layout: i, span: a, children: o, htmlFor: s, group: c, className: l, density: u, align: d, auto: f, onAutoChange: p }) {
150
+ let m = r === "color" ? j.rowColor : r === "checkbox" ? j.rowCheckbox : "", h = r === "default" ? "block" : "inline", g = i ?? h, _ = g === h ? "" : g === "inline" ? j.rowInline : j.rowBlock, v = P([
151
+ j.row,
152
+ m,
153
+ _,
154
+ a && j.span,
155
+ f && j.rowAuto
156
+ ].filter(Boolean).join(" "), {
157
+ density: u,
158
+ align: d
159
+ }, l), y = g === "inline" && t != null, b = /* @__PURE__ */ S("span", {
160
+ className: j.rowLabel,
161
+ children: [
162
+ p ? /* @__PURE__ */ x(se, {
163
+ auto: f ?? !1,
164
+ label: e,
165
+ onChange: p
166
+ }) : e,
167
+ n ? /* @__PURE__ */ x(L, {
168
+ label: e,
169
+ description: n
170
+ }) : null,
171
+ t != null && !y && /* @__PURE__ */ x("em", {
172
+ className: j.readout,
173
+ children: t
174
+ })
175
+ ]
176
+ }), C = y ? /* @__PURE__ */ x("em", {
177
+ className: `${j.readout} ${j.readoutAfter}`,
178
+ children: t
179
+ }) : null;
180
+ return c ? /* @__PURE__ */ S("div", {
181
+ className: v,
182
+ children: [
183
+ b,
184
+ o,
185
+ C
186
+ ]
187
+ }) : /* @__PURE__ */ S("label", {
188
+ className: v,
189
+ htmlFor: s,
190
+ children: [
191
+ b,
192
+ o,
193
+ C
194
+ ]
195
+ });
196
+ }
197
+ function se({ auto: e, label: t, onChange: n }) {
198
+ let r = typeof t == "string" ? t : "this setting", i = (t) => {
199
+ t.preventDefault(), t.stopPropagation(), n(!e);
200
+ };
201
+ return /* @__PURE__ */ x("span", {
202
+ role: "button",
203
+ tabIndex: 0,
204
+ className: j.autoToggle,
205
+ "aria-pressed": !e,
206
+ "aria-label": `Pin ${r}`,
207
+ onClick: i,
208
+ onKeyDown: (e) => {
209
+ (e.key === "Enter" || e.key === " ") && i(e);
210
+ },
211
+ onMouseDown: (e) => e.stopPropagation(),
212
+ children: t
213
+ });
214
+ }
215
+ function L({ label: e, description: r }) {
216
+ let i = typeof e == "string" ? e : "this setting";
217
+ return /* @__PURE__ */ S(n, { children: [/* @__PURE__ */ x(D, { children: /* @__PURE__ */ x("button", {
218
+ type: "button",
219
+ className: j.help,
220
+ "aria-label": `About ${i}`,
221
+ onClick: (e) => {
222
+ e.preventDefault(), e.stopPropagation();
223
+ },
224
+ onMouseDown: (e) => e.stopPropagation(),
225
+ children: "ⓘ"
226
+ }) }), /* @__PURE__ */ x(t, { children: r })] });
227
+ }
228
+ //#endregion
229
+ //#region src/components/Properties/PropertyField.tsx
230
+ function R(e) {
231
+ let { label: t, readout: n, description: r, layout: i, span: a, density: o, align: s, auto: c, onAutoChange: l, rowClassName: u, controlClassName: d, ...f } = e, p = ne(), m = {
232
+ ...f,
233
+ name: f.name ?? Z(t),
234
+ className: d,
235
+ id: p
236
+ }, h = B(m), g = {
237
+ label: t,
238
+ description: r,
239
+ layout: i,
240
+ span: a,
241
+ density: o,
242
+ align: s,
243
+ auto: c,
244
+ onAutoChange: l,
245
+ className: u,
246
+ variant: h.variant,
247
+ group: h.group,
248
+ htmlFor: h.group || m.kind === "font-family" ? void 0 : p
249
+ };
250
+ return m.kind === "number" && m.control === "slider" ? /* @__PURE__ */ x(I, {
251
+ ...g,
252
+ readout: X(n) ?? /* @__PURE__ */ x(Y, { ...m }),
253
+ children: /* @__PURE__ */ x(J, { ...m })
254
+ }) : /* @__PURE__ */ x(I, {
255
+ ...g,
256
+ readout: n,
257
+ children: /* @__PURE__ */ x(V, { ...m })
258
+ });
259
+ }
260
+ function z(e) {
261
+ let t = e;
262
+ return t.kind === "number" && t.control === "slider" ? /* @__PURE__ */ S(b, { children: [/* @__PURE__ */ x(J, { ...t }), /* @__PURE__ */ x("span", {
263
+ className: j.cellReadout,
264
+ children: /* @__PURE__ */ x(Y, { ...t })
265
+ })] }) : /* @__PURE__ */ x(V, { ...t });
266
+ }
267
+ function B(e) {
268
+ switch (e.kind) {
269
+ case "boolean": return {
270
+ variant: "checkbox",
271
+ group: e.control === "switch" || e.control === "toggle"
272
+ };
273
+ case "enum": return {
274
+ variant: "default",
275
+ group: e.control === "radio" || e.control === "toggle"
276
+ };
277
+ case "color": return {
278
+ variant: "color",
279
+ group: !1
280
+ };
281
+ case "paint": return {
282
+ variant: "default",
283
+ group: !0
284
+ };
285
+ default: return {
286
+ variant: "default",
287
+ group: !1
288
+ };
289
+ }
290
+ }
291
+ function V(e) {
292
+ switch (e.kind) {
293
+ case "boolean": return /* @__PURE__ */ x(U, { ...e });
294
+ case "number": return /* @__PURE__ */ x(ce, { ...e });
295
+ case "string": return /* @__PURE__ */ x(de, { ...e });
296
+ case "enum": return /* @__PURE__ */ x(fe, { ...e });
297
+ case "color": return /* @__PURE__ */ x(pe, { ...e });
298
+ case "paint": return /* @__PURE__ */ x(me, { ...e });
299
+ case "font-family": return /* @__PURE__ */ x(s, {
300
+ className: e.className,
301
+ value: e.mixed ? void 0 : e.value,
302
+ mixed: e.mixed,
303
+ onChange: e.onChange,
304
+ weight: e.weight,
305
+ fontStyle: e.fontStyle,
306
+ "aria-label": e.name
307
+ });
308
+ default: throw Error(`PropertyControl: no control for kind "${e.kind}"`);
309
+ }
310
+ }
311
+ function H({ mixed: e, unset: t, children: n }) {
312
+ return !e && !t ? /* @__PURE__ */ x(b, { children: n }) : /* @__PURE__ */ x("span", {
313
+ className: j.dimmed,
314
+ title: e ? "Mixed" : "Not set",
315
+ children: n
316
+ });
317
+ }
318
+ function U(e) {
319
+ let t = !e.mixed && e.value === !0, n = T(null);
320
+ return w(() => {
321
+ n.current && (n.current.indeterminate = e.mixed === !0);
322
+ }), e.control === "toggle" ? /* @__PURE__ */ x(d, {
323
+ mode: "multiple",
324
+ size: "sm",
325
+ variant: "flat",
326
+ className: e.className,
327
+ ariaLabel: e.name,
328
+ items: [{
329
+ value: "on",
330
+ label: e.glyph ?? e.name?.slice(0, 1),
331
+ ariaLabel: e.name
332
+ }],
333
+ value: t ? ["on"] : [],
334
+ mixedValues: e.mixed ? ["on"] : [],
335
+ onChange: (t) => e.onChange(t.includes("on"))
336
+ }) : e.control === "switch" ? /* @__PURE__ */ x(H, {
337
+ mixed: e.mixed,
338
+ unset: e.unset,
339
+ children: /* @__PURE__ */ x(g, {
340
+ className: e.className,
341
+ isSelected: t,
342
+ onChange: e.onChange,
343
+ "aria-label": e.name
344
+ })
345
+ }) : /* @__PURE__ */ x(H, {
346
+ unset: e.unset,
347
+ children: /* @__PURE__ */ x("input", {
348
+ ref: n,
349
+ id: e.id,
350
+ type: "checkbox",
351
+ className: e.className ? `${j.checkbox} ${e.className}` : j.checkbox,
352
+ "aria-label": e.name,
353
+ checked: t,
354
+ onChange: (t) => e.onChange(t.target.checked)
355
+ })
356
+ });
357
+ }
358
+ function W(e) {
359
+ let t = T(null), n = T(e);
360
+ return w(() => {
361
+ n.current = e;
362
+ }), w(() => {
363
+ let e = t.current;
364
+ if (!e) return;
365
+ let r = () => n.current?.(e.value);
366
+ return e.addEventListener("change", r), () => e.removeEventListener("change", r);
367
+ }, []), t;
368
+ }
369
+ function G(e, t) {
370
+ return e == null ? null : typeof e == "string" ? /* @__PURE__ */ x("span", {
371
+ className: t,
372
+ children: e
373
+ }) : e;
374
+ }
375
+ var K = () => {};
376
+ function ce(e) {
377
+ let t = !e.mixed && typeof e.value == "number" && Number.isFinite(e.value), n = /* @__PURE__ */ x(u, {
378
+ id: e.id,
379
+ className: e.className ? `${j.numberField} ${e.className}` : j.numberField,
380
+ value: t ? e.value : NaN,
381
+ placeholder: e.mixed ? "Mixed" : e.placeholder,
382
+ minValue: e.min,
383
+ maxValue: e.max,
384
+ step: e.step,
385
+ accepts: e.accepts,
386
+ display: e.display,
387
+ steppers: e.steppers,
388
+ "aria-label": e.name,
389
+ onInput: e.onInput ?? e.onChange,
390
+ onChange: e.onInput ? e.onChange : K
391
+ });
392
+ return e.unit == null ? n : /* @__PURE__ */ S("span", {
393
+ className: j.fieldUnitGroup,
394
+ children: [n, G(e.unit, j.readoutUnit)]
395
+ });
396
+ }
397
+ function q(e) {
398
+ return {
399
+ min: e.min ?? 0,
400
+ max: e.max ?? 100,
401
+ step: e.step ?? 1
402
+ };
403
+ }
404
+ function J(t) {
405
+ let { min: n, max: r, step: a } = q(t), o = t.onInput ?? t.onChange, s = t.onInput ? t.onChange : void 0, c = W(s && ((e) => s(Number(e)))), l = !t.mixed && typeof t.value == "number" && Number.isFinite(t.value) ? Math.min(Math.max(t.value, n), r) : n;
406
+ return /* @__PURE__ */ x("input", {
407
+ ref: c,
408
+ type: "range",
409
+ id: t.id,
410
+ className: t.className ? `${i.range} ${t.className}` : i.range,
411
+ "aria-label": t.name,
412
+ tabIndex: -1,
413
+ min: n,
414
+ max: r,
415
+ step: a,
416
+ value: l,
417
+ disabled: t.mixed,
418
+ onChange: (n) => {
419
+ let r = Number(n.target.value);
420
+ e("property-panel", "slider", {
421
+ name: t.name,
422
+ value: r
423
+ }), o(r);
424
+ }
425
+ });
426
+ }
427
+ function Y(e) {
428
+ let { min: t, max: n, step: r } = q(e);
429
+ if (e.mixed || typeof e.value != "number" || !Number.isFinite(e.value)) return /* @__PURE__ */ x(b, { children: X("—") });
430
+ let i = r >= 1 ? 0 : Math.min(6, Math.max(0, Math.ceil(-Math.log10(r)))), a = e.display ?? O({
431
+ places: i,
432
+ grouping: !1
433
+ });
434
+ return /* @__PURE__ */ x(le, {
435
+ name: e.name,
436
+ value: e.value,
437
+ min: t,
438
+ max: n,
439
+ step: r,
440
+ display: a,
441
+ format: e.format,
442
+ unit: e.unit,
443
+ onCommit: (t) => {
444
+ e.onInput?.(t), e.onChange(t);
445
+ }
446
+ });
447
+ }
448
+ function X(e) {
449
+ return typeof e != "string" && typeof e != "number" ? e : /* @__PURE__ */ x("span", {
450
+ className: j.readoutGroup,
451
+ children: /* @__PURE__ */ x("span", {
452
+ className: j.readoutText,
453
+ children: e
454
+ })
455
+ });
456
+ }
457
+ function le({ name: e, value: t, min: n, max: r, step: i, display: a, format: o, unit: s, onCommit: c }) {
458
+ let [u, d] = E(null), f = (e) => o ? String(o(e)) : A(e, a).text, p = (e) => k(e, a), m = u === null ? f(t) : u, h = { "--wzl-property-readout-fit": `${Math.max(f(n).length, f(r).length)}ch` }, g = () => {
459
+ if (u !== null) {
460
+ let e = p(u);
461
+ Number.isFinite(e) && c(Math.min(r, Math.max(n, e)));
462
+ }
463
+ d(null);
464
+ };
465
+ return /* @__PURE__ */ S("span", {
466
+ className: j.readoutGroup,
467
+ children: [/* @__PURE__ */ x("input", {
468
+ type: "text",
469
+ role: "spinbutton",
470
+ "aria-label": e,
471
+ "aria-valuenow": t,
472
+ "aria-valuetext": o ? f(t) : A(t, a).spoken,
473
+ "aria-valuemin": n,
474
+ "aria-valuemax": r,
475
+ inputMode: "decimal",
476
+ className: j.readoutInput,
477
+ style: h,
478
+ value: m,
479
+ onFocus: (e) => {
480
+ d(f(t)), e.currentTarget.select();
481
+ },
482
+ onChange: (e) => d(e.target.value.replace(/-/g, "−")),
483
+ onBlur: g,
484
+ onClick: (e) => {
485
+ e.preventDefault(), e.stopPropagation(), e.currentTarget.focus();
486
+ },
487
+ onMouseDown: (e) => e.stopPropagation(),
488
+ onKeyDown: (e) => {
489
+ if (e.key === "Enter") g(), e.currentTarget.blur();
490
+ else if (e.key === "Escape") d(null), e.currentTarget.blur();
491
+ else {
492
+ let a = u === null ? t : p(u), o = l(e.key, Number.isFinite(a) ? a : t, {
493
+ step: i,
494
+ min: n,
495
+ max: r
496
+ });
497
+ if (o === null) return;
498
+ e.preventDefault(), c(o), d(null);
499
+ }
500
+ }
501
+ }), G(s, j.readoutUnit)]
502
+ });
503
+ }
504
+ function ue(e) {
505
+ let [t, n] = E(null), r = e.mixed ? "" : e.value ?? "", i = e.onInput !== void 0;
506
+ return {
507
+ shown: t ?? r,
508
+ type: (t) => {
509
+ if (!i) {
510
+ e.onChange(t);
511
+ return;
512
+ }
513
+ n(t), e.onInput?.(t);
514
+ },
515
+ settle: () => {
516
+ t !== null && t !== r && e.onChange(t), n(null);
517
+ }
518
+ };
519
+ }
520
+ function de(e) {
521
+ let t = ue(e), n = e.mixed ? "Mixed" : e.placeholder;
522
+ return e.control === "textarea" ? /* @__PURE__ */ x("textarea", {
523
+ id: e.id,
524
+ className: e.className ? `${j.textarea} ${e.className}` : j.textarea,
525
+ "aria-label": e.name,
526
+ value: t.shown,
527
+ placeholder: n,
528
+ maxLength: e.maxLength,
529
+ rows: 3,
530
+ onChange: (e) => t.type(e.target.value),
531
+ onBlur: t.settle
532
+ }) : /* @__PURE__ */ x(c, {
533
+ id: e.id,
534
+ className: e.className ? `${j.textField} ${e.className}` : j.textField,
535
+ value: t.shown,
536
+ placeholder: n,
537
+ maxLength: e.maxLength,
538
+ "aria-label": e.name,
539
+ onChange: t.type,
540
+ onBlur: t.settle,
541
+ onKeyDown: (e) => {
542
+ e.key === "Enter" && e.target.blur();
543
+ }
544
+ });
545
+ }
546
+ function Z(e) {
547
+ return typeof e == "string" ? e : void 0;
548
+ }
549
+ function Q(e) {
550
+ return e.glyph === void 0 || e.glyph === null ? void 0 : e.label;
551
+ }
552
+ function fe(t) {
553
+ let n = !t.mixed && t.options.some((e) => e.value === t.value) ? t.value : null;
554
+ if (t.control === "radio") return /* @__PURE__ */ x(m, {
555
+ className: t.className,
556
+ value: n,
557
+ onChange: t.onChange,
558
+ "aria-label": t.name,
559
+ children: t.options.map((e) => /* @__PURE__ */ x(h, {
560
+ value: e.value,
561
+ isDisabled: e.disabled,
562
+ children: e.label
563
+ }, e.value))
564
+ });
565
+ if (t.control === "toggle" && t.onClear) {
566
+ let { onClear: e } = t, r = n === null ? [] : [n];
567
+ return /* @__PURE__ */ x(d, {
568
+ mode: "multiple",
569
+ size: "sm",
570
+ variant: "flat",
571
+ className: t.className ? `${j.toggleBar} ${t.className}` : j.toggleBar,
572
+ ariaLabel: t.name,
573
+ items: t.options.map((e) => ({
574
+ value: e.value,
575
+ label: e.glyph ?? e.label,
576
+ ariaLabel: Z(e.label),
577
+ tooltip: Q(e),
578
+ disabled: e.disabled
579
+ })),
580
+ value: r,
581
+ mixedValues: t.mixed ? t.options.map((e) => e.value) : [],
582
+ onChange: (n) => {
583
+ let i = n.find((e) => !r.includes(e));
584
+ i === void 0 ? e() : t.onChange(i);
585
+ }
586
+ });
587
+ }
588
+ return t.control === "toggle" ? /* @__PURE__ */ x(d, {
589
+ size: "sm",
590
+ variant: "flat",
591
+ className: t.className ? `${j.toggleBar} ${t.className}` : j.toggleBar,
592
+ ariaLabel: t.name,
593
+ items: t.options.map((e) => ({
594
+ value: e.value,
595
+ label: e.glyph ?? e.label,
596
+ ariaLabel: Z(e.label),
597
+ tooltip: Q(e),
598
+ disabled: e.disabled
599
+ })),
600
+ value: n,
601
+ onChange: (e) => {
602
+ e !== null && t.onChange(e);
603
+ }
604
+ }) : /* @__PURE__ */ x(o, {
605
+ className: t.className ? `${j.select} ${t.className}` : j.select,
606
+ triggerId: t.id,
607
+ "aria-label": t.name,
608
+ placeholder: t.mixed ? "Mixed" : t.placeholder ?? (t.unset ? "—" : "Choose option…"),
609
+ selectedKey: n,
610
+ options: t.options.map((e) => ({
611
+ value: e.value,
612
+ label: e.label,
613
+ isDisabled: e.disabled
614
+ })),
615
+ onSelectionChange: (n) => {
616
+ e("property-panel", "select", {
617
+ name: t.name,
618
+ value: n
619
+ }), t.onChange(n);
620
+ }
621
+ });
622
+ }
623
+ function $(e) {
624
+ let t = v(e?.trim() ?? "");
625
+ return /^#[0-9a-f]{8}$/i.test(t) ? {
626
+ rgb: t.slice(0, 7).toLowerCase(),
627
+ alpha: _(t)
628
+ } : {
629
+ rgb: "#000000",
630
+ alpha: 1
631
+ };
632
+ }
633
+ function pe(e) {
634
+ let t = e.alpha !== void 0 && e.alpha !== !1, n = typeof e.alpha == "number", r = $(e.value), i = n ? e.alpha : r.alpha, o = (e, t) => (a) => {
635
+ if (!n) {
636
+ e(a);
637
+ return;
638
+ }
639
+ let o = $(a);
640
+ (o.rgb !== r.rgb || !t) && e(o.rgb);
641
+ let s = Math.round(o.alpha * 100) / 100;
642
+ s !== Math.round(i * 100) / 100 && t?.(s);
643
+ }, s = e.onInput !== void 0 || e.onAlphaInput !== void 0, c = o(e.onInput ?? e.onChange, e.onAlphaInput ?? e.onAlphaChange), l = s ? o(e.onChange, e.onAlphaChange) : K;
644
+ return /* @__PURE__ */ x(a, {
645
+ id: e.id,
646
+ className: e.className ? `${j.colorField} ${e.className}` : j.colorField,
647
+ value: e.mixed ? void 0 : t ? y(r.rgb, i) : e.value ?? "#000000",
648
+ mixed: e.mixed,
649
+ alpha: t,
650
+ alphaDisabled: e.alphaDisabled,
651
+ onInput: c,
652
+ onChange: l,
653
+ "aria-label": e.name
654
+ });
655
+ }
656
+ function me(e) {
657
+ let t = e.control === "inline" ? f : p;
658
+ return /* @__PURE__ */ x(t, {
659
+ className: e.className,
660
+ value: e.value,
661
+ mixed: e.mixed,
662
+ unset: e.unset,
663
+ kinds: e.kinds,
664
+ allowNone: e.allowNone,
665
+ onChange: e.onChange,
666
+ onInput: e.onInput,
667
+ "aria-label": e.name
668
+ });
669
+ }
670
+ //#endregion
671
+ export { re as a, P as c, oe as i, j as l, R as n, I as o, ie as r, ae as s, z as t };
672
+
673
+ //# sourceMappingURL=PropertyField-DfIJJ5GS.js.map