@ryuzaki13/react-foundation-ui 2.1.0 → 3.0.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 (461) hide show
  1. package/COLOR_TOKENS_MIGRATION.md +224 -0
  2. package/README.md +14 -18
  3. package/dist/advanced-search/index.js +8 -8
  4. package/dist/badge/index.js +1 -1
  5. package/dist/barcode-scanner/index.js +2 -2
  6. package/dist/base-table/index.js +1 -1
  7. package/dist/button/index.js +1 -1
  8. package/dist/check-box/index.js +1 -1
  9. package/dist/chunks/{CalendarView-Bhaov_XE.js → CalendarView-Dm55k0bN.js} +2 -2
  10. package/dist/chunks/CalendarView-Dm55k0bN.js.map +1 -0
  11. package/dist/chunks/ImageViewerRuntime-HGBWp9NM.js.map +1 -1
  12. package/dist/chunks/{TextEditorLexicalClient-CSXZQOYo.js → TextEditorLexicalClient-D46Zed55.js} +6 -6
  13. package/dist/chunks/TextEditorLexicalClient-D46Zed55.js.map +1 -0
  14. package/dist/chunks/{badge-DUI2ET6q.js → badge-6mXO9BWP.js} +2 -2
  15. package/dist/chunks/badge-6mXO9BWP.js.map +1 -0
  16. package/dist/chunks/{base-table-BqW1n7tv.js → base-table-BWvKfI2W.js} +2 -2
  17. package/dist/chunks/{base-table-BqW1n7tv.js.map → base-table-BWvKfI2W.js.map} +1 -1
  18. package/dist/chunks/{button-BaUlN-nt.js → button-DF21yxVp.js} +3 -3
  19. package/dist/chunks/{button-BaUlN-nt.js.map → button-DF21yxVp.js.map} +1 -1
  20. package/dist/chunks/{check-box-CC8CDnSR.js → check-box-CZyhzmR0.js} +3 -3
  21. package/dist/chunks/{check-box-CC8CDnSR.js.map → check-box-CZyhzmR0.js.map} +1 -1
  22. package/dist/chunks/{context-menu-Dj6MXgv6.js → context-menu-DgvXGCuI.js} +3 -3
  23. package/dist/chunks/context-menu-DgvXGCuI.js.map +1 -0
  24. package/dist/chunks/{date-input-DkLfO3Ng.js → date-input-BwLOiGXp.js} +5 -5
  25. package/dist/chunks/{date-input-DkLfO3Ng.js.map → date-input-BwLOiGXp.js.map} +1 -1
  26. package/dist/chunks/dialog-Dqq8ZN99.js +50 -0
  27. package/dist/chunks/dialog-Dqq8ZN99.js.map +1 -0
  28. package/dist/chunks/{input-D1jOxm0t.js → input-DSPKgiCK.js} +2 -2
  29. package/dist/chunks/input-DSPKgiCK.js.map +1 -0
  30. package/dist/chunks/{input-files-CDGpJaUm.js → input-files-tIS17-zX.js} +3 -3
  31. package/dist/chunks/input-files-tIS17-zX.js.map +1 -0
  32. package/dist/chunks/{input-search-Ci1ubGox.js → input-search-Cat4c7SM.js} +2 -2
  33. package/dist/chunks/{input-search-Ci1ubGox.js.map → input-search-Cat4c7SM.js.map} +1 -1
  34. package/dist/chunks/misc-DeGboAt-.js.map +1 -1
  35. package/dist/chunks/{modal-CbAwLHlM.js → modal-dplfAaER.js} +2 -2
  36. package/dist/chunks/{modal-CbAwLHlM.js.map → modal-dplfAaER.js.map} +1 -1
  37. package/dist/chunks/{multi-select-V7SLAduU.js → multi-select-BZ9N6Dal.js} +4 -4
  38. package/dist/chunks/{multi-select-V7SLAduU.js.map → multi-select-BZ9N6Dal.js.map} +1 -1
  39. package/dist/chunks/{picker-DZ4-1BvK.js → picker-lvm82d0A.js} +3 -3
  40. package/dist/chunks/picker-lvm82d0A.js.map +1 -0
  41. package/dist/chunks/popover-Bne-Ljbs.js.map +1 -1
  42. package/dist/chunks/{radio-group-DhpP7JSJ.js → radio-group-CRk_1ODZ.js} +2 -2
  43. package/dist/chunks/radio-group-CRk_1ODZ.js.map +1 -0
  44. package/dist/chunks/{select-B7cWlJxL.js → select-aTGupQan.js} +4 -4
  45. package/dist/chunks/{select-B7cWlJxL.js.map → select-aTGupQan.js.map} +1 -1
  46. package/dist/chunks/{table-DMLFUBlb.js → table-DxoSOvQK.js} +2 -2
  47. package/dist/chunks/table-DxoSOvQK.js.map +1 -0
  48. package/dist/chunks/{ui.module-BsDio9A3.js → ui.module-oRwY3Zli.js} +2 -1
  49. package/dist/chunks/ui.module-oRwY3Zli.js.map +1 -0
  50. package/dist/chunks/{uiClasses-BVwFzzsr.js → uiClasses-CQj47jkF.js} +11 -2
  51. package/dist/chunks/uiClasses-CQj47jkF.js.map +1 -0
  52. package/dist/chunks/wheel-picker-FS58cRsQ.js.map +1 -1
  53. package/dist/context-menu/index.js +1 -1
  54. package/dist/date-input/index.js +2 -2
  55. package/dist/date-time-input/index.js +3 -3
  56. package/dist/dialog/index.js +2 -50
  57. package/dist/disclosure/index.js +2 -2
  58. package/dist/disclosure/index.js.map +1 -1
  59. package/dist/drop-zone/index.js +1 -1
  60. package/dist/drop-zone/index.js.map +1 -1
  61. package/dist/errors/index.js +4 -4
  62. package/dist/errors/index.js.map +1 -1
  63. package/dist/expandable-action-panel/index.js +1 -1
  64. package/dist/image/index.js +5 -5
  65. package/dist/image/index.js.map +1 -1
  66. package/dist/input/index.js +1 -1
  67. package/dist/input-date-time/index.js +2 -2
  68. package/dist/input-file/index.js +2 -2
  69. package/dist/input-files/index.js +1 -1
  70. package/dist/input-image/index.js +2 -2
  71. package/dist/input-search/index.js +1 -1
  72. package/dist/layout-picker/index.js +1 -1
  73. package/dist/layout-picker/index.js.map +1 -1
  74. package/dist/listbox/index.js +1 -1
  75. package/dist/modal/index.js +1 -1
  76. package/dist/multi-select/index.js +1 -1
  77. package/dist/notifications/index.js +1 -1
  78. package/dist/notifications/index.js.map +1 -1
  79. package/dist/option/index.js +1 -1
  80. package/dist/picker/index.js +1 -1
  81. package/dist/preset-range-date-input/index.js +1 -1
  82. package/dist/preset-select/index.js +1 -1
  83. package/dist/radio-button/index.js +2 -2
  84. package/dist/radio-group/index.js +1 -1
  85. package/dist/select/index.js +1 -1
  86. package/dist/simple-table/index.js +1 -1
  87. package/dist/slider/index.js +3 -3
  88. package/dist/slider/index.js.map +1 -1
  89. package/dist/state-select/index.js +1 -1
  90. package/dist/status-indicator/StatusIndicator.d.ts.map +1 -1
  91. package/dist/status-indicator/index.js +2 -0
  92. package/dist/status-indicator/index.js.map +1 -1
  93. package/dist/styles.css +1 -1
  94. package/dist/switch/index.js +1 -1
  95. package/dist/table/index.js +1 -1
  96. package/dist/table-editor/index.d.ts +3 -0
  97. package/dist/table-editor/index.d.ts.map +1 -0
  98. package/dist/table-editor/index.js +462 -0
  99. package/dist/table-editor/index.js.map +1 -0
  100. package/dist/table-editor/model/useTableEditor.d.ts +25 -0
  101. package/dist/table-editor/model/useTableEditor.d.ts.map +1 -0
  102. package/dist/table-editor/model/useTableEditorTable.d.ts +10 -0
  103. package/dist/table-editor/model/useTableEditorTable.d.ts.map +1 -0
  104. package/dist/table-editor/ui/TableEditor.d.ts +21 -0
  105. package/dist/table-editor/ui/TableEditor.d.ts.map +1 -0
  106. package/dist/table-editor/ui/TableEditorGrid.d.ts +14 -0
  107. package/dist/table-editor/ui/TableEditorGrid.d.ts.map +1 -0
  108. package/dist/table-editor/ui/TableEditorStructure.d.ts +10 -0
  109. package/dist/table-editor/ui/TableEditorStructure.d.ts.map +1 -0
  110. package/dist/table-editor/ui/TableEditorToolbar.d.ts +11 -0
  111. package/dist/table-editor/ui/TableEditorToolbar.d.ts.map +1 -0
  112. package/dist/table-sorting/index.js +1 -1
  113. package/dist/tabs/index.js +2 -2
  114. package/dist/tabs/index.js.map +1 -1
  115. package/dist/tag-input/index.js +2 -2
  116. package/dist/tag-input/index.js.map +1 -1
  117. package/dist/text-editor/index.js +1 -1
  118. package/dist/textarea/index.js +2 -2
  119. package/dist/toggle/index.js +1 -1
  120. package/dist/toggle/index.js.map +1 -1
  121. package/dist/tree-select/index.js +3 -3
  122. package/dist/tree-select/index.js.map +1 -1
  123. package/dist/tree-table/index.js +1 -1
  124. package/dist/tree-table/index.js.map +1 -1
  125. package/dist/types.d.ts +3 -3
  126. package/dist/types.d.ts.map +1 -1
  127. package/dist/uiClasses.d.ts.map +1 -1
  128. package/package.json +8 -3
  129. package/src/styles/_border.scss +2 -2
  130. package/src/styles/_color.scss +8 -8
  131. package/src/styles/_components.scss +2 -2
  132. package/src/styles/_normalize.scss +4 -4
  133. package/src/styles/config/_index.scss +95 -182
  134. package/src/styles/mixins/_controls.scss +43 -26
  135. package/src/styles/mixins/_mixin.scss +0 -187
  136. package/src/styles/mixins/controls.test.ts +28 -6
  137. package/src/styles/themes/_interactive-surface.scss +12 -12
  138. package/src/styles/themes/_theme.scss +21 -157
  139. package/src/styles/themes/theme.test.ts +66 -48
  140. package/storybook-static/assets/{Badge-BXbiidny.js → Badge-DLpkFLAr.js} +8 -2
  141. package/storybook-static/assets/{Badge.stories-DCOkVsyk.js → Badge.stories-DwwZ0O7j.js} +7 -1
  142. package/storybook-static/assets/{BadgeList-DgUScGRc.js → BadgeList-C0bhovUR.js} +2 -2
  143. package/storybook-static/assets/{BadgeList-CD5894x5.css → BadgeList-DbjeNuw0.css} +1 -1
  144. package/storybook-static/assets/{BarcodeScannerDialog.stories-7Bv_TejN.js → BarcodeScannerDialog.stories-DYXaW4Vw.js} +1 -1
  145. package/storybook-static/assets/{Button-0UDcBhBt.js → Button-B1nvnaMI.js} +12 -2
  146. package/storybook-static/assets/{Button-BpQRrzrS.js → Button-PAj4mH8o.js} +4 -2
  147. package/storybook-static/assets/Button.stories-CNvWyh5M.js +106 -0
  148. package/storybook-static/assets/{CalendarView-B93LI4f_.js → CalendarView-WUXapLvN.js} +1 -1
  149. package/storybook-static/assets/CalendarView-dgpVDRJR.css +1 -0
  150. package/storybook-static/assets/{CheckBox-BaAouU5d.js → CheckBox-B9f_n0Nh.js} +2 -2
  151. package/storybook-static/assets/{CheckBox-CFusvDS8.js → CheckBox-C3r_FdXc.js} +1 -1
  152. package/storybook-static/assets/{CheckBox.stories-Bdr_GC0M.js → CheckBox.stories-B5CFQBFx.js} +1 -1
  153. package/storybook-static/assets/{Color-6AOWCN3U-B8A6Hc7V.js → Color-6AOWCN3U-tYUAsbHo.js} +1 -1
  154. package/storybook-static/assets/{ContextMenu-CvHpWBGV.js → ContextMenu-C-T3O2d9.js} +1 -1
  155. package/storybook-static/assets/{ContextMenu-BcNU89-b.js → ContextMenu-PIvPPvq1.js} +1 -1
  156. package/storybook-static/assets/ContextMenu-yhWq2uJ3.css +1 -0
  157. package/storybook-static/assets/{ContextMenu.stories-DQDlVNxB.js → ContextMenu.stories-Bmy_0Oug.js} +1 -1
  158. package/storybook-static/assets/{CustomOptionButton-DkGlBvWP.js → CustomOptionButton-D_qTIop3.js} +1 -1
  159. package/storybook-static/assets/{DateInput-NkrPSWMl.js → DateInput-B7GZSkR3.js} +1 -1
  160. package/storybook-static/assets/{DateInput-CWsb-NhT.js → DateInput-C-goSdP-.js} +1 -1
  161. package/storybook-static/assets/{DateInput.stories-Bvz465d-.js → DateInput.stories-CeAMz_x1.js} +1 -1
  162. package/storybook-static/assets/{DateRangePresetSelect-DC6_r8SQ.js → DateRangePresetSelect-BZ9U_l_x.js} +1 -1
  163. package/storybook-static/assets/{DateRangePresetSelect-DQlphKzc.js → DateRangePresetSelect-BmjgWIxM.js} +1 -1
  164. package/storybook-static/assets/{DateRangePresetSelect.stories-DVfqPYN5.js → DateRangePresetSelect.stories-5UGP9HcH.js} +1 -1
  165. package/storybook-static/assets/{Detail-CXQYyd94.js → Detail-C6duvCft.js} +1 -1
  166. package/storybook-static/assets/{Detail.stories-BEXByYXt.js → Detail.stories-DQZciNeZ.js} +1 -1
  167. package/storybook-static/assets/{Dialog-CyYTYgbp.js → Dialog-87D5Shqd.js} +1 -1
  168. package/storybook-static/assets/{Dialog-B2UTbDCv.js → Dialog-Bx4-acbv.js} +1 -1
  169. package/storybook-static/assets/{Dialog.stories-BWluB4Ya.js → Dialog.stories-BgOQABzP.js} +1 -1
  170. package/storybook-static/assets/{Disclosure-Dv5XOsna.js → Disclosure-ZctFZjdw.js} +1 -1
  171. package/storybook-static/assets/{Disclosure.stories-BxK_fmJE.js → Disclosure.stories-BioI8Dpv.js} +1 -1
  172. package/storybook-static/assets/{DisclosureGroup-B2O8D8CG.js → DisclosureGroup-Cn2EEocA.js} +1 -1
  173. package/storybook-static/assets/DisclosureGroup-D_ldcGgp.css +1 -0
  174. package/storybook-static/assets/{DocsRenderer-JROSPFPF-7N0jH0Oi.js → DocsRenderer-JROSPFPF-CoppGUHs.js} +1 -1
  175. package/storybook-static/assets/{DropZone-DL34ooyF.js → DropZone-68BioqBN.js} +1 -1
  176. package/storybook-static/assets/{DropZone-ZlPjdEuO.js → DropZone-BpInQyuE.js} +1 -1
  177. package/storybook-static/assets/{DropZone-C7HIN5ml.css → DropZone-C4gPTIz0.css} +1 -1
  178. package/storybook-static/assets/{DropZone.stories-BT9JvF9d.js → DropZone.stories-DhVyaedf.js} +1 -1
  179. package/storybook-static/assets/{DropdownMenu-BhC5f2Qc.js → DropdownMenu-Dw-i5abQ.js} +1 -1
  180. package/storybook-static/assets/{ExpandableActionPanel-C77qVHBP.js → ExpandableActionPanel-Bb7Eo_iW.js} +1 -1
  181. package/storybook-static/assets/{ExpandableActionPanel.stories-D1MJEw6F.js → ExpandableActionPanel.stories-B0XABlVT.js} +1 -1
  182. package/storybook-static/assets/{Flex-BHt3-yoh.js → Flex-CG5yKEBH.js} +1 -1
  183. package/storybook-static/assets/{Flex.stories-M8QVGuVA.js → Flex.stories-Cfx4TAqp.js} +1 -1
  184. package/storybook-static/assets/{FloatingPopover-Dch6_6e0.js → FloatingPopover-B8zZ8eYf.js} +1 -1
  185. package/storybook-static/assets/FloatingPopover-Di16BZj-.css +1 -0
  186. package/storybook-static/assets/FormattedTableCell-BzBZlmxd.js +15 -0
  187. package/storybook-static/assets/FormattedTableCell-CTIL_ueu.css +1 -0
  188. package/storybook-static/assets/{Grid-CcyaioK_.js → Grid-3MdRiyY4.js} +1 -1
  189. package/storybook-static/assets/{Grid.stories-CTHcYkKa.js → Grid.stories-DUfosHcu.js} +1 -1
  190. package/storybook-static/assets/{ImageCropper.stories-B84lQIPy.js → ImageCropper.stories-DBLj9S4C.js} +1 -1
  191. package/storybook-static/assets/{ImageRenderer-kTsPC-b5.js → ImageRenderer-bZHWE6lq.js} +1 -1
  192. package/storybook-static/assets/{ImageRenderer.stories-pozsCEPL.js → ImageRenderer.stories-BU2tt9QR.js} +1 -1
  193. package/storybook-static/assets/{ImageView.stories-CNttofCE.js → ImageView.stories-t_ree_kB.js} +1 -1
  194. package/storybook-static/assets/{ImageViewer.stories-D_7oQpyX.js → ImageViewer.stories-kodL93QT.js} +2 -2
  195. package/storybook-static/assets/{ImageViewerRuntime-Dnc70fBS.js → ImageViewerRuntime-Dkw7fwZ1.js} +1 -1
  196. package/storybook-static/assets/ImageViewerRuntime-MxAd4mC-.css +1 -0
  197. package/storybook-static/assets/{Input-DvRmrrtj.js → Input-C-Q_V0Uc.js} +1 -1
  198. package/storybook-static/assets/{Input-CYgnggvb.css → Input-CIA3PkB4.css} +1 -1
  199. package/storybook-static/assets/{Input-BO9q-b1i.js → Input-Ckb0G4jj.js} +1 -1
  200. package/storybook-static/assets/{Input.stories-DeKdGxIC.js → Input.stories-BZITY0Np.js} +1 -1
  201. package/storybook-static/assets/{InputDateTime-hqRtizlN.js → InputDateTime-DF-R-IPb.js} +1 -1
  202. package/storybook-static/assets/{InputDateTime.stories-BpGhWbRp.js → InputDateTime.stories-2ELFc29n.js} +1 -1
  203. package/storybook-static/assets/{InputFile-CExDbGYJ.js → InputFile-3Sn8IwRI.js} +1 -1
  204. package/storybook-static/assets/{InputFile-CTDHdo2g.js → InputFile-Xo-rxvud.js} +1 -1
  205. package/storybook-static/assets/{InputFile.stories-BIinoG-U.js → InputFile.stories-B4EHuTtj.js} +1 -1
  206. package/storybook-static/assets/{InputFiles-Cvdn_5IV.js → InputFiles-CRFuoEBd.js} +1 -1
  207. package/storybook-static/assets/{InputFiles-BWeRuTCh.js → InputFiles-DzdnkOiD.js} +1 -1
  208. package/storybook-static/assets/{InputFiles.stories-J2bb48sN.js → InputFiles.stories-BRCSXgg-.js} +1 -1
  209. package/storybook-static/assets/{InputFilesList-ByK52qUe.css → InputFilesList-BbwB0oHE.css} +1 -1
  210. package/storybook-static/assets/{InputFilesList-DO6IJW98.js → InputFilesList-CvL4pjsZ.js} +1 -1
  211. package/storybook-static/assets/{InputImage-C7zaIkCa.js → InputImage-B1v_PWfN.js} +1 -1
  212. package/storybook-static/assets/{InputImage-BtsIbqEc.js → InputImage-qAzSyHzj.js} +1 -1
  213. package/storybook-static/assets/{InputImage.stories--ewdBKin.js → InputImage.stories-4NLpODaa.js} +1 -1
  214. package/storybook-static/assets/{InteractiveComponents-Cy9Y2J_q.js → InteractiveComponents-Bdy-KTOF.js} +1 -1
  215. package/storybook-static/assets/{InteractiveComponents.stories-CgC4nhd3.js → InteractiveComponents.stories-C_ZAVn0R.js} +1 -1
  216. package/storybook-static/assets/{LayoutPicker-CfgWKTDC.js → LayoutPicker-8wwVLPom.js} +1 -1
  217. package/storybook-static/assets/{LayoutPicker-DhJgMxdf.js → LayoutPicker-B4eblsaF.js} +1 -1
  218. package/storybook-static/assets/{LayoutPicker-BY4-fUQa.css → LayoutPicker-DaPDA0_s.css} +1 -1
  219. package/storybook-static/assets/{LayoutPicker.stories-Bli7rQRh.js → LayoutPicker.stories-BkA-VmHP.js} +1 -1
  220. package/storybook-static/assets/{Listbox-bq5sSQnZ.js → Listbox-ChaW3JrO.js} +1 -1
  221. package/storybook-static/assets/{Listbox-_MNXWNW7.js → Listbox-CyH7MftX.js} +1 -1
  222. package/storybook-static/assets/{Listbox.stories-BP9mqHoo.js → Listbox.stories-_31FVhoW.js} +1 -1
  223. package/storybook-static/assets/{Modal-CNt7-iWI.js → Modal-CaGOliEb.js} +1 -1
  224. package/storybook-static/assets/{Modal-Dwqp7agw.js → Modal-DGR9lZ4E.js} +1 -1
  225. package/storybook-static/assets/{Modal.stories-D2Hj75pl.js → Modal.stories-C1yvEVNj.js} +1 -1
  226. package/storybook-static/assets/{ModalManagerProvider-BoCpnUex.js → ModalManagerProvider-BrPY3nRM.js} +1 -1
  227. package/storybook-static/assets/{MultiSelect-B1BckUGX.js → MultiSelect-D-O71OBm.js} +1 -1
  228. package/storybook-static/assets/{MultiSelect-CTfbXQVD.js → MultiSelect-D4S4B3va.js} +1 -1
  229. package/storybook-static/assets/{MultiSelect.stories-BdMJk22c.js → MultiSelect.stories-B0QY0_Ru.js} +1 -1
  230. package/storybook-static/assets/{NoData-CNK8-UBc.js → NoData-B6xgAMXh.js} +1 -1
  231. package/storybook-static/assets/NotificationsHost-BIyd1XQ0.css +1 -0
  232. package/storybook-static/assets/{NotificationsHost-Cczj_pFY.js → NotificationsHost-DJ3Y-Bov.js} +1 -1
  233. package/storybook-static/assets/{NotificationsHost.stories-BPB6hfSI.js → NotificationsHost.stories-B2ULIi8d.js} +1 -1
  234. package/storybook-static/assets/{ODataMultiSelect-CahWMsCQ.js → ODataMultiSelect-0SfdyLn9.js} +1 -1
  235. package/storybook-static/assets/{ODataMultiSelect.stories-Dnyu2-gz.js → ODataMultiSelect.stories-BLq2Lzuq.js} +1 -1
  236. package/storybook-static/assets/{ODataSelect-DxbjbdNx.js → ODataSelect-CkdBSdJ6.js} +1 -1
  237. package/storybook-static/assets/{ODataSelect.stories-DfK9yHK7.js → ODataSelect.stories-OLMZHd_q.js} +1 -1
  238. package/storybook-static/assets/{ODataTreeMultiSelect-DOgHyKon.js → ODataTreeMultiSelect-DMLCMhQn.js} +1 -1
  239. package/storybook-static/assets/{ODataTreeMultiSelect.stories-Dv0-ackb.js → ODataTreeMultiSelect.stories-aY5Q0IHe.js} +1 -1
  240. package/storybook-static/assets/{ODataTreeSelect-DIoygv27.js → ODataTreeSelect-ME1K7NL2.js} +1 -1
  241. package/storybook-static/assets/{ODataTreeSelect.stories-D4mZcW9Z.js → ODataTreeSelect.stories-C7UPHKEr.js} +1 -1
  242. package/storybook-static/assets/{OneStepScroller-DNTilSDM.js → OneStepScroller-RRsghqzx.js} +1 -1
  243. package/storybook-static/assets/{Option-qcKM13Ly.js → Option-CcZ3aKLZ.js} +1 -1
  244. package/storybook-static/assets/Option-DD2t6DLq.css +1 -0
  245. package/storybook-static/assets/{OptionButton-DrNo-DMV.js → OptionButton-B-RTb3Ua.js} +1 -1
  246. package/storybook-static/assets/{PeriodSelect-Dk-_iKeR.js → PeriodSelect-B-89h-o8.js} +1 -1
  247. package/storybook-static/assets/{PeriodSelect-DjzmUohy.js → PeriodSelect-CUUixF0M.js} +1 -1
  248. package/storybook-static/assets/{PeriodSelect.stories-d58Lz3DJ.js → PeriodSelect.stories-CU1V-pP4.js} +1 -1
  249. package/storybook-static/assets/{PickerField-Dv1S8Wit.js → PickerField-DykK8Xgu.js} +1 -1
  250. package/storybook-static/assets/{PickerTriggerActions-dbXPGPRy.js → PickerTriggerActions-C2qYXlH1.js} +1 -1
  251. package/storybook-static/assets/{Popover-tPH8grZD.js → Popover-Bg-XuklM.js} +1 -1
  252. package/storybook-static/assets/{Popover-DMrefrsO.js → Popover-D_MNKdnD.js} +1 -1
  253. package/storybook-static/assets/{Popover.stories-BGgMddUi.js → Popover.stories-D2Asjc6d.js} +1 -1
  254. package/storybook-static/assets/{PresetRangeDateInput-Bi01AT1-.js → PresetRangeDateInput-B1KqD3aB.js} +1 -1
  255. package/storybook-static/assets/{PresetRangeDateInput-Bi5D7AvA.js → PresetRangeDateInput-CYXkpgts.js} +1 -1
  256. package/storybook-static/assets/{PresetRangeDateInput.stories-BK9PG5Us.js → PresetRangeDateInput.stories-CTML1dIg.js} +1 -1
  257. package/storybook-static/assets/{PresetSelect-Bo_urWXj.js → PresetSelect-4PvR0s4U.js} +1 -1
  258. package/storybook-static/assets/{README-CsYvQc-H.js → README--I7LDhOP.js} +1 -1
  259. package/storybook-static/assets/{README-DQzhOQJs.js → README-1Ks0ldtQ.js} +1 -1
  260. package/storybook-static/assets/{README-BCXhBI3h.js → README-44qHXI_X.js} +1 -1
  261. package/storybook-static/assets/{README-oTjX8jJr.js → README-B3Q9ZlQz.js} +1 -1
  262. package/storybook-static/assets/{README-C1EYYUCN.js → README-B5MLKvrO.js} +1 -1
  263. package/storybook-static/assets/{README-CvomZuv4.js → README-B5vVbHbw.js} +1 -1
  264. package/storybook-static/assets/{README-CiRdh2G1.js → README-BJsszjH8.js} +1 -1
  265. package/storybook-static/assets/{README-CAYUX5Nb.js → README-BK-2_7T4.js} +1 -1
  266. package/storybook-static/assets/{README-qyGL-RQj.js → README-BKGcgtnD.js} +1 -1
  267. package/storybook-static/assets/{README-DJeVd42x.js → README-BNUdkNxv.js} +1 -1
  268. package/storybook-static/assets/{README-CUw7AGFv.js → README-BSSrY3Ri.js} +1 -1
  269. package/storybook-static/assets/{README-Bccm-jZn.js → README-BVOzG1wf.js} +1 -1
  270. package/storybook-static/assets/{README-BatM3k6o.js → README-BZbDJrol.js} +1 -1
  271. package/storybook-static/assets/{README-BrnWLQ7I.js → README-BcReoeGQ.js} +1 -1
  272. package/storybook-static/assets/{README-C9LAWG5A.js → README-BdgUDdVT.js} +1 -1
  273. package/storybook-static/assets/{README-DnE0W6xN.js → README-BpSdRy6R.js} +1 -1
  274. package/storybook-static/assets/{README-CHOXjCGT.js → README-BrduLUi1.js} +1 -1
  275. package/storybook-static/assets/{README-WDknu02X.js → README-Bt44WdOn.js} +1 -1
  276. package/storybook-static/assets/{README-DXV0j4Y9.js → README-Bta2DZoW.js} +1 -1
  277. package/storybook-static/assets/{README-BbwNWG_A.js → README-Bwa8ai1X.js} +1 -1
  278. package/storybook-static/assets/{README-DRTv3qN5.js → README-C1TqCBPf.js} +1 -1
  279. package/storybook-static/assets/{README-B2NTIwVC.js → README-C5Cq8Lo7.js} +1 -1
  280. package/storybook-static/assets/{README-BOY9oCZ5.js → README-CE0sa_3S.js} +1 -1
  281. package/storybook-static/assets/{README-DENkRq75.js → README-COnopkzM.js} +1 -1
  282. package/storybook-static/assets/{README-BRxnSb_H.js → README-CUEwtG21.js} +1 -1
  283. package/storybook-static/assets/{README-DOqinQqt.js → README-CVEiXGCU.js} +1 -1
  284. package/storybook-static/assets/{README-CSkB_qWo.js → README-CWxf5v2C.js} +1 -1
  285. package/storybook-static/assets/{README-DNkooR8C.js → README-CjbqfpYX.js} +1 -1
  286. package/storybook-static/assets/{README-XlmyqVIs.js → README-CnE5ZG98.js} +1 -1
  287. package/storybook-static/assets/{README-CLfxQA5V.js → README-Co-LXT0Y.js} +1 -1
  288. package/storybook-static/assets/{README-BPDYLPfh.js → README-CoJlt7mW.js} +1 -1
  289. package/storybook-static/assets/{README-G5BEMzLO.js → README-DFiFAUAq.js} +1 -1
  290. package/storybook-static/assets/{README-cmKi-NfO.js → README-DMCaXjMn.js} +1 -1
  291. package/storybook-static/assets/{README-ChyNimpn.js → README-DecmlELk.js} +3 -3
  292. package/storybook-static/assets/{README-Bsm0nJfv.js → README-Diow36TX.js} +1 -1
  293. package/storybook-static/assets/{README-BO0pPMhH.js → README-DlE5gepf.js} +1 -1
  294. package/storybook-static/assets/{README-DLL_V1qq.js → README-Dl_id19k.js} +1 -1
  295. package/storybook-static/assets/{README-D7IkoGLE.js → README-DpxWpc-I.js} +1 -1
  296. package/storybook-static/assets/{README-DI6PuVn_.js → README-Dqpnap9b.js} +1 -1
  297. package/storybook-static/assets/{README-DSx__uJY.js → README-DrSuJ2Ll.js} +1 -1
  298. package/storybook-static/assets/{README-CIy0Pj6l.js → README-Dtb7kJXX.js} +1 -1
  299. package/storybook-static/assets/{README-CgvojwYv.js → README-Ib9AxEso.js} +1 -1
  300. package/storybook-static/assets/{README-5MsrC0tc.js → README-NCp7adRE.js} +1 -1
  301. package/storybook-static/assets/{README-CDXBNJlU.js → README-SHZwgJhZ.js} +1 -1
  302. package/storybook-static/assets/{README-Bzz8tDjY.js → README-VY7CL7vi.js} +1 -1
  303. package/storybook-static/assets/{README-BIYrg5Jw.js → README-Ve2RJTbZ.js} +1 -1
  304. package/storybook-static/assets/{README-BTCDTs4l.js → README-bU5ZgdrN.js} +1 -1
  305. package/storybook-static/assets/{README-DqTSHU_3.js → README-kpAlQZLM.js} +1 -1
  306. package/storybook-static/assets/{README-iy7SbqPS.js → README-l0W43XHl.js} +1 -1
  307. package/storybook-static/assets/{README-BxY8B5jC.js → README-tetbJraG.js} +1 -1
  308. package/storybook-static/assets/{README-DnjCb77l.js → README-vUJFU3Tw.js} +1 -1
  309. package/storybook-static/assets/{README-lyLRoc9A.js → README-vjP8Z9fC.js} +1 -1
  310. package/storybook-static/assets/{README-DCitesDJ.js → README-ypHLhhny.js} +1 -1
  311. package/storybook-static/assets/{RadioButton-C5lYvVIl.js → RadioButton-ByRN6fXm.js} +1 -1
  312. package/storybook-static/assets/{RadioButton-_-grgF60.js → RadioButton-DRIJvobR.js} +1 -1
  313. package/storybook-static/assets/{RadioButton.stories-BNifE29D.js → RadioButton.stories-C6lOZsje.js} +1 -1
  314. package/storybook-static/assets/{RadioGroup-DWfHyBaQ.js → RadioGroup-5P3FMqFW.js} +1 -1
  315. package/storybook-static/assets/{RadioGroup-BU95Hbl0.css → RadioGroup-DHnDIEgi.css} +1 -1
  316. package/storybook-static/assets/{RadioGroup-CmDrRqLi.js → RadioGroup-Dskh-JZM.js} +1 -1
  317. package/storybook-static/assets/{RadioGroup.stories-1PW9Krj9.js → RadioGroup.stories-BDbOjwVa.js} +1 -1
  318. package/storybook-static/assets/{Scrollable-CWkMU4wH.js → Scrollable-Cat0ixOK.js} +1 -1
  319. package/storybook-static/assets/{Select-BCGnO525.js → Select-BiIixkSk.js} +1 -1
  320. package/storybook-static/assets/{Select-DYtEG5uI.js → Select-ImY9WR7I.js} +1 -1
  321. package/storybook-static/assets/{Select.stories-CgldXYRU.js → Select.stories-DR8qQrXW.js} +1 -1
  322. package/storybook-static/assets/{SerializableSelect-MmvKHZiv.js → SerializableSelect-C2swvXju.js} +1 -1
  323. package/storybook-static/assets/{SerializableSelect.stories-Di0iM37P.js → SerializableSelect.stories-CvoyFECC.js} +1 -1
  324. package/storybook-static/assets/{SingleDateTimeInput-Ds5YsLHg.js → SingleDateTimeInput-CjixqW_K.js} +1 -1
  325. package/storybook-static/assets/{SingleDateTimeInput-Cz2Y7KEq.js → SingleDateTimeInput-hV5Om2LV.js} +1 -1
  326. package/storybook-static/assets/{SingleDateTimeInput.stories-BnuERNSZ.js → SingleDateTimeInput.stories-CPDP-M6P.js} +1 -1
  327. package/storybook-static/assets/Slider-DxdPx1Pb.css +1 -0
  328. package/storybook-static/assets/{Slider-Csaz4BeY.js → Slider-FbV_mr1Y.js} +1 -1
  329. package/storybook-static/assets/{Slider-CiZ7R_NX.js → Slider-PcbxPCWE.js} +1 -1
  330. package/storybook-static/assets/{Slider.stories-7Heg0Pgz.js → Slider.stories-CH9grPep.js} +1 -1
  331. package/storybook-static/assets/{SliderInput-bTh2JTHG.js → SliderInput-DPYcLCwD.js} +1 -1
  332. package/storybook-static/assets/{SliderInput-qWpLFzxj.js → SliderInput-iqnLqNiU.js} +1 -1
  333. package/storybook-static/assets/{SliderInput.stories-DR_zyE-u.js → SliderInput.stories-qVDa0KhJ.js} +1 -1
  334. package/storybook-static/assets/{Sortable-P86Ancoa.js → Sortable-DzJSN0MG.js} +1 -1
  335. package/storybook-static/assets/{Sortable.stories-iiOkIM-G.js → Sortable.stories-BaQ2T15L.js} +1 -1
  336. package/storybook-static/assets/{Splitter-mG3bB-U4.js → Splitter-Ka7c1ZDV.js} +1 -1
  337. package/storybook-static/assets/{Splitter.stories-WhQOQVRq.js → Splitter.stories-BbjjUT39.js} +1 -1
  338. package/storybook-static/assets/{StateSelect-De2PQDzp.js → StateSelect-CfyyDUiq.js} +1 -1
  339. package/storybook-static/assets/{StateSelect-u1kaZwdD.js → StateSelect-DSzDU5Jy.js} +1 -1
  340. package/storybook-static/assets/{StateSelect.stories-BO-C9UTF.js → StateSelect.stories-0c32Rlr2.js} +1 -1
  341. package/storybook-static/assets/{StatusIndicator-BiTbPB5o.js → StatusIndicator-CcCdDffH.js} +1 -1
  342. package/storybook-static/assets/StatusIndicator-CpCGmnO7.css +1 -0
  343. package/storybook-static/assets/StatusIndicator.stories-Bazi6rxF.js +31 -0
  344. package/storybook-static/assets/{StringToggle.stories-CBt8bXzz.js → StringToggle.stories-Bl6HAr4o.js} +1 -1
  345. package/storybook-static/assets/{Switch-BRKFbtp4.js → Switch-BqAkQzIJ.js} +1 -1
  346. package/storybook-static/assets/{Switch-BC2KYLX2.js → Switch-Vl7s55bO.js} +1 -1
  347. package/storybook-static/assets/{Switch.stories-BAmX4W8J.js → Switch.stories-Cq2n8Vr4.js} +1 -1
  348. package/storybook-static/assets/{Table-D1OJnVmO.js → Table-BgxoZKJs.js} +1 -1
  349. package/storybook-static/assets/Table-j_3ID7Xq.css +1 -0
  350. package/storybook-static/assets/{Table.stories-C_JSdhJl.js → Table.stories-DxnnXMZX.js} +3 -3
  351. package/storybook-static/assets/TableEditor-CaZCZgKf.css +1 -0
  352. package/storybook-static/assets/TableEditor.stories-D5Ke41-O.js +61 -0
  353. package/storybook-static/assets/{Tabs-DiUKiz-h.js → Tabs-BPJG7wBI.js} +1 -1
  354. package/storybook-static/assets/{Tabs.stories-DGys1vSD.js → Tabs.stories-cQ4RTo0w.js} +1 -1
  355. package/storybook-static/assets/{TabsBox-D-bkJX9j.css → TabsBox-B3REnb6D.css} +1 -1
  356. package/storybook-static/assets/{TabsBox-D4yfPiDY.js → TabsBox-CGgEovb9.js} +1 -1
  357. package/storybook-static/assets/{TagInput-ZyC-89b3.js → TagInput-CGHC-7Rv.js} +1 -1
  358. package/storybook-static/assets/{TagInput-ChmW4s9O.css → TagInput-RJbbcfoR.css} +1 -1
  359. package/storybook-static/assets/{TagInput.stories-hVoLW5qr.js → TagInput.stories-BSy_dJ5n.js} +1 -1
  360. package/storybook-static/assets/{Text-CMJA_7QZ.js → Text-D5fn4NbN.js} +1 -1
  361. package/storybook-static/assets/{Textarea-Du012ObX.js → Textarea-CbWAz4J8.js} +1 -1
  362. package/storybook-static/assets/{Textarea-DjKw5r4e.js → Textarea-pXxz-925.js} +1 -1
  363. package/storybook-static/assets/{Textarea.stories-ShFda4o7.js → Textarea.stories-BkPejDdf.js} +1 -1
  364. package/storybook-static/assets/{TimePanel-Bfkpbjrx.js → TimePanel-BJulRHL2.js} +1 -1
  365. package/storybook-static/assets/{TimePanel-Bh98qsCo.css → TimePanel-D9_hb7w4.css} +1 -1
  366. package/storybook-static/assets/{TimePanel.stories-4pV3fQVB.js → TimePanel.stories-CJmuKdfu.js} +1 -1
  367. package/storybook-static/assets/{Toggle-CPohFihI.js → Toggle-B2S8eW_z.js} +1 -1
  368. package/storybook-static/assets/Toggle-ClE8Zovo.css +1 -0
  369. package/storybook-static/assets/{Toggle-ChC8G1Et.js → Toggle-DjqQBHtJ.js} +1 -1
  370. package/storybook-static/assets/{Toggle.stories-B3H1M8Ra.js → Toggle.stories-7KRSUGU9.js} +1 -1
  371. package/storybook-static/assets/{TreeMultiSelect-CbNz09Jk.js → TreeMultiSelect-B7Dd0sH5.js} +1 -1
  372. package/storybook-static/assets/{TreeMultiSelect-BpuHCHgJ.js → TreeMultiSelect-DfvInPvn.js} +1 -1
  373. package/storybook-static/assets/{TreeMultiSelect.stories-Cmt05HgT.js → TreeMultiSelect.stories-DrokeiS6.js} +1 -1
  374. package/storybook-static/assets/{TreePickerBase-DGvBAQiy.js → TreePickerBase-CN9UeNWV.js} +1 -1
  375. package/storybook-static/assets/{TreePickerBase-B6DED6Hz.css → TreePickerBase-CmFF9pWE.css} +1 -1
  376. package/storybook-static/assets/{TreeSelect-DvAlRur3.js → TreeSelect-D3s-_McF.js} +1 -1
  377. package/storybook-static/assets/{TreeSelect-C_GCYsA3.js → TreeSelect-DPX2Q1Sv.js} +1 -1
  378. package/storybook-static/assets/{TreeSelect.stories-Cch2A2z5.js → TreeSelect.stories-DvUGVU34.js} +1 -1
  379. package/storybook-static/assets/TreeTable-BvB3kj4h.css +1 -0
  380. package/storybook-static/assets/{TreeTable-CmVxMvld.js → TreeTable-By3223dp.js} +1 -1
  381. package/storybook-static/assets/{TreeTable.stories-B46N8o8E.js → TreeTable.stories-DKAKV_e2.js} +2 -2
  382. package/storybook-static/assets/{array-D-_yMMUK-DYqn1Ozn.js → array-D-_yMMUK-DnJ_b27D.js} +1 -1
  383. package/storybook-static/assets/{blocks-Bu5I-6jJ.js → blocks-C4R1QC9R.js} +3 -3
  384. package/storybook-static/assets/{check-BdRTIK6S.js → check-DkXl--jW.js} +1 -1
  385. package/storybook-static/assets/{chevron-down-EtmpBUf8.js → chevron-down-DnX0I3Pg.js} +1 -1
  386. package/storybook-static/assets/{chevron-left-CTLa8HIb.js → chevron-left-18ya0d2d.js} +1 -1
  387. package/storybook-static/assets/{chevron-right-D_c_Cvi0.js → chevron-right-DilGYzJ6.js} +1 -1
  388. package/storybook-static/assets/{chunk-W22LQPXL-B7ERYz6B.js → chunk-W22LQPXL-WTP7vHyr.js} +1 -1
  389. package/storybook-static/assets/{circle-alert-Dj1kZNNX.js → circle-alert-DVNv_dVS.js} +1 -1
  390. package/storybook-static/assets/{circle-check-B1w7Ls8y.js → circle-check-vIdCi5Zq.js} +1 -1
  391. package/storybook-static/assets/{components-DqRn1i2k.js → components-BtEbmBZQ.js} +3 -3
  392. package/storybook-static/assets/{contextMenu-ylNgC9hS.js → contextMenu-1dx6rzYN.js} +1 -1
  393. package/storybook-static/assets/{defaultRenderers-CyUQG_f-.js → defaultRenderers-UxEpV_2H.js} +1 -1
  394. package/storybook-static/assets/{download-dw_WzNlC.js → download-37V1rEcU.js} +1 -1
  395. package/storybook-static/assets/{floating-ui.react-C9sdi3nv.js → floating-ui.react-DT-xu5am.js} +1 -1
  396. package/storybook-static/assets/{formatters-DVE1YVNQ-CMsbb5-m.js → formatters-DVE1YVNQ-YIdRxgw-.js} +1 -1
  397. package/storybook-static/assets/{foundationApi-BJETphYp.js → foundationApi-FaYaPMaR.js} +1 -1
  398. package/storybook-static/assets/{foundationLib-DfRlYoD7.js → foundationLib-DLCLUXOF.js} +1 -1
  399. package/storybook-static/assets/{hooks-B-ZW7F36.js → hooks-BuU9-pEZ.js} +1 -1
  400. package/storybook-static/assets/{iframe-D0R9pFj7.js → iframe-0M2vpakb.js} +4 -4
  401. package/storybook-static/assets/iframe-BMXB4CtM.js +1 -0
  402. package/storybook-static/assets/iframe-BT_jngkf.css +1 -0
  403. package/storybook-static/assets/{info-B0qzF0Mr.js → info-2PUHH67D.js} +1 -1
  404. package/storybook-static/assets/odata-DIkxH78d.js +1 -0
  405. package/storybook-static/assets/odataStoryFixtures-BDQiSxyk.js +25 -0
  406. package/storybook-static/assets/{react-ClkCNz5L.js → react-CfjIdTfH.js} +1 -1
  407. package/storybook-static/assets/{refresh-cw-K68D1zRy.js → refresh-cw-CHFG8NIc.js} +1 -1
  408. package/storybook-static/assets/{settings-2-D0jFfhpt.js → settings-2-CYde2-4U.js} +1 -1
  409. package/storybook-static/assets/{sortable-fWu4d9fl.js → sortable-Cy9ZqA3f.js} +1 -1
  410. package/storybook-static/assets/{syntaxhighlighter-QEQV7K2Y-Cs3Bxe3I.js → syntaxhighlighter-QEQV7K2Y-C2U-3XXV.js} +1 -1
  411. package/storybook-static/assets/tableFeatures-Dx3U-F9E.js +1 -0
  412. package/storybook-static/assets/{trash-2-Bj60L0sq.js → trash-2-7-oMZEr8.js} +1 -1
  413. package/storybook-static/assets/{triangle-alert-CmzQ-r9i.js → triangle-alert-BSmuthen.js} +1 -1
  414. package/storybook-static/assets/ui-DSS1yTEO.css +1 -0
  415. package/storybook-static/assets/ui.module-SH8ehXul.js +1 -0
  416. package/storybook-static/assets/uiClasses-e9OQfdw2.js +1 -0
  417. package/storybook-static/assets/{useODataSelectBase-CC4MnYeK.js → useODataSelectBase-C3B3Xw87.js} +1 -1
  418. package/storybook-static/assets/{useODataTreeData-DsQmGQij.js → useODataTreeData-deUW5mSv.js} +1 -1
  419. package/storybook-static/assets/{usePickerDefaultFilter-BMBLqfz8.js → usePickerDefaultFilter-ien2ZY7g.js} +1 -1
  420. package/storybook-static/assets/{usePickerQuery-Qg7qGfmP.js → usePickerQuery-DdE3I7AV.js} +1 -1
  421. package/storybook-static/assets/{usePickerTriggerController-D-mhhmpS.js → usePickerTriggerController-ZRvj4FHy.js} +1 -1
  422. package/storybook-static/assets/useTable-CK68Q4S4.js +1 -0
  423. package/storybook-static/assets/{x-DU3Tpzms.js → x-NXcyLtyX.js} +1 -1
  424. package/storybook-static/iframe.html +3 -3
  425. package/storybook-static/index.json +1 -1
  426. package/storybook-static/project.json +1 -1
  427. package/dist/chunks/CalendarView-Bhaov_XE.js.map +0 -1
  428. package/dist/chunks/TextEditorLexicalClient-CSXZQOYo.js.map +0 -1
  429. package/dist/chunks/badge-DUI2ET6q.js.map +0 -1
  430. package/dist/chunks/context-menu-Dj6MXgv6.js.map +0 -1
  431. package/dist/chunks/input-D1jOxm0t.js.map +0 -1
  432. package/dist/chunks/input-files-CDGpJaUm.js.map +0 -1
  433. package/dist/chunks/picker-DZ4-1BvK.js.map +0 -1
  434. package/dist/chunks/radio-group-DhpP7JSJ.js.map +0 -1
  435. package/dist/chunks/table-DMLFUBlb.js.map +0 -1
  436. package/dist/chunks/ui.module-BsDio9A3.js.map +0 -1
  437. package/dist/chunks/uiClasses-BVwFzzsr.js.map +0 -1
  438. package/dist/dialog/index.js.map +0 -1
  439. package/storybook-static/assets/Button.stories-CLMnxj3w.js +0 -93
  440. package/storybook-static/assets/CalendarView-DKvrkS40.css +0 -1
  441. package/storybook-static/assets/ContextMenu-CFPrlO2u.css +0 -1
  442. package/storybook-static/assets/DisclosureGroup-CVFMwx22.css +0 -1
  443. package/storybook-static/assets/FloatingPopover-jwILx9b0.css +0 -1
  444. package/storybook-static/assets/FormattedTableCell-AZc2IHfK.css +0 -1
  445. package/storybook-static/assets/FormattedTableCell-CXyG4Yj2.js +0 -15
  446. package/storybook-static/assets/ImageViewerRuntime-CRmlrtpL.css +0 -1
  447. package/storybook-static/assets/NotificationsHost-D5Pvn4eu.css +0 -1
  448. package/storybook-static/assets/Option-DXh7BISz.css +0 -1
  449. package/storybook-static/assets/Slider-CK-W2ZTO.css +0 -1
  450. package/storybook-static/assets/StatusIndicator-CU9ICMrC.css +0 -1
  451. package/storybook-static/assets/StatusIndicator.stories-COaZnrFa.js +0 -31
  452. package/storybook-static/assets/Table-BGvRn9y0.css +0 -1
  453. package/storybook-static/assets/Toggle-fKG2dFY0.css +0 -1
  454. package/storybook-static/assets/TreeTable--ZoksUiw.css +0 -1
  455. package/storybook-static/assets/iframe-COgZ5GwG.js +0 -1
  456. package/storybook-static/assets/iframe-IhWQT6NX.css +0 -1
  457. package/storybook-static/assets/odata-tqjAk19x.js +0 -1
  458. package/storybook-static/assets/odataStoryFixtures-D2yHs_jK.js +0 -25
  459. package/storybook-static/assets/ui-C3BskXT9.css +0 -1
  460. package/storybook-static/assets/ui.module-31LPbZGK.js +0 -1
  461. package/storybook-static/assets/uiClasses-Bz6cvlDQ.js +0 -1
@@ -42,8 +42,8 @@ function f() {
42
42
  },
43
43
  children: /* @__PURE__ */ s("polygon", {
44
44
  points: "\n150,10 170,60 230,40 200,100 270,110 210,150 270,190 200,200 230,260 170,240 150,290 130,240\n70,260 100,200 30,190 90,150 30,110 100,100 70,40 130,60",
45
- fill: "var(--status-error-on-fill)",
46
- stroke: "var(--status-error-fill)",
45
+ fill: "var(--error-on-fill)",
46
+ stroke: "var(--error-fill)",
47
47
  strokeWidth: "5",
48
48
  strokeLinejoin: "round"
49
49
  })
@@ -108,7 +108,7 @@ var _ = ({ error: e, componentStack: t, draftId: n }) => {
108
108
  style: {
109
109
  zIndex: 1,
110
110
  position: "relative",
111
- textShadow: "1px -1px 1px var(--status-warning-border-focus), -1px 1px 1px var(--status-info-border-focus)"
111
+ textShadow: "1px -1px 1px var(--warning-border), -1px 1px 1px var(--info-border)"
112
112
  },
113
113
  children: p[Math.floor(u * p.length)]
114
114
  })]
@@ -175,7 +175,7 @@ var _ = ({ error: e, componentStack: t, draftId: n }) => {
175
175
  style: {
176
176
  zIndex: 1,
177
177
  position: "relative",
178
- textShadow: "1px 0 1px var(--status-error-fill), -1px 0 1px var(--status-info-fill)"
178
+ textShadow: "1px 0 1px var(--error-fill), -1px 0 1px var(--info-fill)"
179
179
  },
180
180
  children: p[Math.floor(n * p.length)]
181
181
  })]
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/errors/PageError.tsx","../../src/errors/BadRequestPage.tsx","../../src/errors/BoomExplosion.tsx","../../src/errors/constants.ts","../../src/errors/ForbiddenPage.tsx","../../src/errors/NotFoundPage.tsx","../../src/errors/ErrorDisplay.tsx","../../src/errors/ErrorBoundary.tsx","../../src/errors/ErrorExplosion.tsx","../../src/errors/SimpleErrorDisplay.tsx","../../src/errors/UnauthorizedPage.tsx","../../src/errors/ViewNotChanged.tsx"],"sourcesContent":["import React from \"react\";\n\nimport { Flex } from \"../flex\";\n\ninterface PageErrorProps {\n\tcode: string | number;\n\ttitle: string;\n\tdescription: string;\n}\n\nexport const PageError: React.FC<PageErrorProps> = ({ code, title, description }) => {\n\treturn (\n\t\t<Flex.Predefined variant=\"columnCenter\" className=\"paddingXl\">\n\t\t\t<div aria-hidden=\"true\" className=\"content2 fontBolded\" style={{ fontSize: \"5em\" }}>\n\t\t\t\t{code}\n\t\t\t</div>\n\t\t\t<h2>{title}</h2>\n\t\t\t<p>{description}</p>\n\t\t\t{/* <Link to=\"/\">Вернуться на главную</Link> */}\n\t\t</Flex.Predefined>\n\t);\n};\n","import { PageError } from \"./PageError\";\n\nexport const BadRequestPage: React.FC = () => {\n\treturn (\n\t\t<PageError\n\t\t\tcode={400}\n\t\t\ttitle=\"Некорректный запрос\"\n\t\t\tdescription=\"Похоже, что запрос был сформирован неверно. Попробуйте обновить страницу или вернуться на главную.\"\n\t\t/>\n\t);\n};\n","import { useState } from \"react\";\n\nexport function BoomExplosion() {\n\tconst [transform] = useState(() => {\n\t\tconst scale = 0.7 + Math.random() * 0.3;\n\t\tconst rotate = Math.random() * 45 - 15;\n\t\treturn `scale(${scale}) rotateZ(${rotate}deg)`;\n\t});\n\n\treturn (\n\t\t<svg\n\t\t\tviewBox=\"0 0 300 300\"\n\t\t\twidth=\"300\"\n\t\t\theight=\"300\"\n\t\t\tstyle={{\n\t\t\t\tposition: \"absolute\",\n\t\t\t\ttop: \"50%\",\n\t\t\t\tleft: \"50%\",\n\t\t\t\ttransform: `translate(-50%, -50%) ${transform}`,\n\t\t\t\tzIndex: 0,\n\t\t\t\topacity: 0.5\n\t\t\t}}>\n\t\t\t<polygon\n\t\t\t\tpoints=\"\n150,10 170,60 230,40 200,100 270,110 210,150 270,190 200,200 230,260 170,240 150,290 130,240\n70,260 100,200 30,190 90,150 30,110 100,100 70,40 130,60\"\n\t\t\t\tfill=\"var(--status-error-on-fill)\"\n\t\t\t\tstroke=\"var(--status-error-fill)\"\n\t\t\t\tstrokeWidth=\"5\"\n\t\t\t\tstrokeLinejoin=\"round\"\n\t\t\t/>\n\t\t</svg>\n\t);\n}\n","export const ERROR_BOOM_MESSAGES = [\"Упс!\", \"Ой!\", \"Эх!\", \"Ай-ай-ай!\", \"Бах!\", \"Бум!\", \"Ого!\", \"Облом!\", \"Ёлки-палки!\", \"Хлоп!\"];\n","import { PageError } from \"./PageError\";\n\nexport const ForbiddenPage: React.FC = () => {\n\treturn <PageError code={403} title=\"Доступ запрещён\" description=\"У вас нет прав для просмотра этой страницы.\" />;\n};\n","import { PageError } from \"./PageError\";\n\nexport const NotFoundPage: React.FC = () => {\n\treturn <PageError code={404} title=\"Страница не найдена\" description=\"Извините, запрашиваемая страница не существует\" />;\n};\n","import { useEffect, useState } from \"react\";\n\nimport { captureRuntimeErrorReport } from \"@ryuzaki13/react-foundation-lib/error-report\";\nimport { logError } from \"@ryuzaki13/react-foundation-lib/utils\";\nimport { useQueryClient } from \"@tanstack/react-query\";\n\nimport { BadRequestPage } from \"./BadRequestPage\";\nimport { BoomExplosion } from \"./BoomExplosion\";\nimport { ERROR_BOOM_MESSAGES } from \"./constants\";\nimport { ForbiddenPage } from \"./ForbiddenPage\";\nimport { NotFoundPage } from \"./NotFoundPage\";\n\nfunction getHttpStatusCode(error: Error): number | undefined {\n\tif (!(\"status\" in error) || typeof error.status !== \"number\") return undefined;\n\treturn error.status;\n}\n\nexport const ErrorDisplay: React.FC<{ error: Error; componentStack?: string; draftId?: string | null }> = ({\n\terror,\n\tcomponentStack,\n\tdraftId\n}) => {\n\tconst [randomValue] = useState(() => Math.random());\n\tconst queryClient = useQueryClient();\n\n\tuseEffect(() => {\n\t\tif (draftId !== undefined) return;\n\n\t\tvoid captureRuntimeErrorReport(\n\t\t\terror,\n\t\t\t{\n\t\t\t\tcategory: \"react\",\n\t\t\t\tcomponentStack\n\t\t\t},\n\t\t\tqueryClient\n\t\t);\n\t}, [componentStack, draftId, error, queryClient]);\n\n\tconst httpStatusCode = getHttpStatusCode(error);\n\n\tif (httpStatusCode) {\n\t\tswitch (httpStatusCode) {\n\t\t\tcase 400:\n\t\t\t\treturn <BadRequestPage />;\n\t\t\tcase 403:\n\t\t\t\treturn <ForbiddenPage />;\n\t\t\tcase 404:\n\t\t\t\treturn <NotFoundPage />;\n\t\t}\n\t}\n\n\tlogError(error.stack);\n\n\treturn (\n\t\t<section className=\"w100 h100 flexColumn justifyContentCenter paddingMd\">\n\t\t\t<div aria-hidden=\"true\" className=\"textCenter relative fontBolded statusError\" style={{ fontSize: \"4em\", marginBlock: \"2em\" }}>\n\t\t\t\t<BoomExplosion />\n\t\t\t\t<div\n\t\t\t\t\tstyle={{\n\t\t\t\t\t\tzIndex: 1,\n\t\t\t\t\t\tposition: \"relative\",\n\t\t\t\t\t\ttextShadow: \"1px -1px 1px var(--status-warning-border-focus), -1px 1px 1px var(--status-info-border-focus)\"\n\t\t\t\t\t}}>\n\t\t\t\t\t{ERROR_BOOM_MESSAGES[Math.floor(randomValue * ERROR_BOOM_MESSAGES.length)]}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div className=\"textCenter\">\n\t\t\t\t<h2 className=\"statusError\">Критическая ошибка</h2>\n\t\t\t\t<p className=\"statusError fontSizeLg\">\n\t\t\t\t\t<code>{error.message}</code>\n\t\t\t\t</p>\n\t\t\t\t<p>Попробуйте перезагрузить страницу или вернуться позже.</p>\n\t\t\t</div>\n\t\t</section>\n\t);\n};\n","import React, { Component } from \"react\";\n\nimport { captureRuntimeErrorReport } from \"@ryuzaki13/react-foundation-lib/error-report\";\n\nimport { ErrorDisplay } from \"./ErrorDisplay\";\n\ninterface ErrorBoundaryProps {\n\tchildren: React.ReactNode;\n\tcustomComponent?: React.ComponentType<{ error: Error }>;\n}\n\ntype ErrorBoundaryState = {\n\terror: Error | null;\n\tcomponentStack?: string;\n\tdraftId?: string | null;\n};\n\nexport class ErrorBoundary extends Component<ErrorBoundaryProps, ErrorBoundaryState> {\n\tconstructor(props: ErrorBoundaryProps) {\n\t\tsuper(props);\n\t\tthis.state = { error: null };\n\t}\n\n\tstatic getDerivedStateFromError(error: Error) {\n\t\treturn { error };\n\t}\n\n\tcomponentDidUpdate(prevProps: ErrorBoundaryProps) {\n\t\t// Сбрасываем ошибку при изменении children\n\t\tif (this.state.error && prevProps.children !== this.props.children) {\n\t\t\tthis.setState({ error: null, componentStack: undefined, draftId: undefined });\n\t\t}\n\t}\n\n\tcomponentDidCatch(error: Error, errorInfo: React.ErrorInfo) {\n\t\tthis.setState({ componentStack: errorInfo.componentStack ?? undefined, draftId: null });\n\n\t\tcaptureRuntimeErrorReport(error, {\n\t\t\tcategory: \"react\",\n\t\t\tcomponentStack: errorInfo.componentStack ?? undefined\n\t\t}).then((draft) => {\n\t\t\tif (draft && this.state.error === error) {\n\t\t\t\tthis.setState({ draftId: draft.reportId });\n\t\t\t}\n\t\t});\n\t}\n\n\trender() {\n\t\tif (this.state.error) {\n\t\t\tconst CustomComponent = this.props.customComponent;\n\t\t\treturn CustomComponent ? (\n\t\t\t\t<CustomComponent error={this.state.error} />\n\t\t\t) : (\n\t\t\t\t<ErrorDisplay error={this.state.error} componentStack={this.state.componentStack} draftId={this.state.draftId} />\n\t\t\t);\n\t\t}\n\n\t\treturn this.props.children;\n\t}\n}\n","import React, { useState } from \"react\";\n\nimport { BoomExplosion } from \"./BoomExplosion\";\nimport { ERROR_BOOM_MESSAGES } from \"./constants\";\n\ninterface ErrorExplosionProps {\n\theader?: string;\n\tdescription?: string;\n}\n\nexport const ErrorExplosion: React.FC<ErrorExplosionProps> = ({ header, description }) => {\n\tconst [randomValue] = useState(() => Math.random());\n\n\treturn (\n\t\t<div className=\"container marginBlockLg\">\n\t\t\t<div aria-hidden=\"true\" className={\"textCenter relative fontBolded statusWarning marginBlockMd\"} style={{ fontSize: \"6em\" }}>\n\t\t\t\t<BoomExplosion />\n\t\t\t\t<div\n\t\t\t\t\tstyle={{\n\t\t\t\t\t\tzIndex: 1,\n\t\t\t\t\t\tposition: \"relative\",\n\t\t\t\t\t\ttextShadow: \"1px 0 1px var(--status-error-fill), -1px 0 1px var(--status-info-fill)\"\n\t\t\t\t\t}}>\n\t\t\t\t\t{ERROR_BOOM_MESSAGES[Math.floor(randomValue * ERROR_BOOM_MESSAGES.length)]}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div className=\"flexColumn alignItemsCenter textCenter marginBlockMd\">\n\t\t\t\t{header && <h2 className=\"statusWarning\">{header}</h2>}\n\t\t\t\t{description && <p>{description}</p>}\n\t\t\t</div>\n\t\t</div>\n\t);\n};\n","import { logError } from \"@ryuzaki13/react-foundation-lib/utils\";\n\nimport { Text } from \"../text\";\n\nexport function SimpleErrorDisplay({ error }: { error: Error }) {\n\tlogError(error.stack);\n\n\treturn (\n\t\t<Text color=\"error\">\n\t\t\t<code>{error.message}</code>\n\t\t</Text>\n\t);\n}\n","import { PageError } from \"./PageError\";\n\nexport const UnauthorizedPage: React.FC = () => {\n\treturn (\n\t\t<PageError\n\t\t\tcode={401}\n\t\t\ttitle=\"Необходима авторизация\"\n\t\t\tdescription=\"Для доступа к этой странице нужно войти в систему. Пожалуйста, авторизуйтесь и попробуйте снова.\"\n\t\t/>\n\t);\n};\n","import React from \"react\";\n\nimport { Flex } from \"../flex\";\n\nexport const ViewNotChanged: React.FC = () => {\n\treturn (\n\t\t<Flex.Predefined variant=\"columnCenter\" className=\"paddingXl\">\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CAAA,GACpD,KAAe,kBAAC,KAAD,EAAA,UAAI,EAAe,CAAA,CAC/B;EACD,CAAA,CAAA;;AAEP;;;AC5BA,SAAgB,EAAmB,EAAE,YAA2B;CAG/D,OAFA,EAAS,EAAM,KAAK,GAGnB,kBAAC,GAAD;EAAM,OAAM;EACX,UAAA,kBAAC,QAAD,EAAA,UAAO,EAAM,QAAc,CAAA;CACtB,CAAA;AAER;;;ACVA,IAAa,UAEX,kBAAC,GAAD;CACC,MAAM;CACN,OAAM;CACN,aAAY;AACZ,CAAA,GCJU,UAEX,kBAAC,EAAK,YAAN;CAAiB,SAAQ;CAAe,WAAU;CACjD,UAAA,kBAAC,MAAD;EAAI,WAAU;EAAW,UAAA;CAAmB,CAAA;AAC5B,CAAA"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/errors/PageError.tsx","../../src/errors/BadRequestPage.tsx","../../src/errors/BoomExplosion.tsx","../../src/errors/constants.ts","../../src/errors/ForbiddenPage.tsx","../../src/errors/NotFoundPage.tsx","../../src/errors/ErrorDisplay.tsx","../../src/errors/ErrorBoundary.tsx","../../src/errors/ErrorExplosion.tsx","../../src/errors/SimpleErrorDisplay.tsx","../../src/errors/UnauthorizedPage.tsx","../../src/errors/ViewNotChanged.tsx"],"sourcesContent":["import React from \"react\";\n\nimport { Flex } from \"../flex\";\n\ninterface PageErrorProps {\n\tcode: string | number;\n\ttitle: string;\n\tdescription: string;\n}\n\nexport const PageError: React.FC<PageErrorProps> = ({ code, title, description }) => {\n\treturn (\n\t\t<Flex.Predefined variant=\"columnCenter\" className=\"paddingXl\">\n\t\t\t<div aria-hidden=\"true\" className=\"content2 fontBolded\" style={{ fontSize: \"5em\" }}>\n\t\t\t\t{code}\n\t\t\t</div>\n\t\t\t<h2>{title}</h2>\n\t\t\t<p>{description}</p>\n\t\t\t{/* <Link to=\"/\">Вернуться на главную</Link> */}\n\t\t</Flex.Predefined>\n\t);\n};\n","import { PageError } from \"./PageError\";\n\nexport const BadRequestPage: React.FC = () => {\n\treturn (\n\t\t<PageError\n\t\t\tcode={400}\n\t\t\ttitle=\"Некорректный запрос\"\n\t\t\tdescription=\"Похоже, что запрос был сформирован неверно. Попробуйте обновить страницу или вернуться на главную.\"\n\t\t/>\n\t);\n};\n","import { useState } from \"react\";\n\nexport function BoomExplosion() {\n\tconst [transform] = useState(() => {\n\t\tconst scale = 0.7 + Math.random() * 0.3;\n\t\tconst rotate = Math.random() * 45 - 15;\n\t\treturn `scale(${scale}) rotateZ(${rotate}deg)`;\n\t});\n\n\treturn (\n\t\t<svg\n\t\t\tviewBox=\"0 0 300 300\"\n\t\t\twidth=\"300\"\n\t\t\theight=\"300\"\n\t\t\tstyle={{\n\t\t\t\tposition: \"absolute\",\n\t\t\t\ttop: \"50%\",\n\t\t\t\tleft: \"50%\",\n\t\t\t\ttransform: `translate(-50%, -50%) ${transform}`,\n\t\t\t\tzIndex: 0,\n\t\t\t\topacity: 0.5\n\t\t\t}}>\n\t\t\t<polygon\n\t\t\t\tpoints=\"\n150,10 170,60 230,40 200,100 270,110 210,150 270,190 200,200 230,260 170,240 150,290 130,240\n70,260 100,200 30,190 90,150 30,110 100,100 70,40 130,60\"\n\t\t\t\tfill=\"var(--error-on-fill)\"\n\t\t\t\tstroke=\"var(--error-fill)\"\n\t\t\t\tstrokeWidth=\"5\"\n\t\t\t\tstrokeLinejoin=\"round\"\n\t\t\t/>\n\t\t</svg>\n\t);\n}\n","export const ERROR_BOOM_MESSAGES = [\"Упс!\", \"Ой!\", \"Эх!\", \"Ай-ай-ай!\", \"Бах!\", \"Бум!\", \"Ого!\", \"Облом!\", \"Ёлки-палки!\", \"Хлоп!\"];\n","import { PageError } from \"./PageError\";\n\nexport const ForbiddenPage: React.FC = () => {\n\treturn <PageError code={403} title=\"Доступ запрещён\" description=\"У вас нет прав для просмотра этой страницы.\" />;\n};\n","import { PageError } from \"./PageError\";\n\nexport const NotFoundPage: React.FC = () => {\n\treturn <PageError code={404} title=\"Страница не найдена\" description=\"Извините, запрашиваемая страница не существует\" />;\n};\n","import { useEffect, useState } from \"react\";\n\nimport { captureRuntimeErrorReport } from \"@ryuzaki13/react-foundation-lib/error-report\";\nimport { logError } from \"@ryuzaki13/react-foundation-lib/utils\";\nimport { useQueryClient } from \"@tanstack/react-query\";\n\nimport { BadRequestPage } from \"./BadRequestPage\";\nimport { BoomExplosion } from \"./BoomExplosion\";\nimport { ERROR_BOOM_MESSAGES } from \"./constants\";\nimport { ForbiddenPage } from \"./ForbiddenPage\";\nimport { NotFoundPage } from \"./NotFoundPage\";\n\nfunction getHttpStatusCode(error: Error): number | undefined {\n\tif (!(\"status\" in error) || typeof error.status !== \"number\") return undefined;\n\treturn error.status;\n}\n\nexport const ErrorDisplay: React.FC<{ error: Error; componentStack?: string; draftId?: string | null }> = ({\n\terror,\n\tcomponentStack,\n\tdraftId\n}) => {\n\tconst [randomValue] = useState(() => Math.random());\n\tconst queryClient = useQueryClient();\n\n\tuseEffect(() => {\n\t\tif (draftId !== undefined) return;\n\n\t\tvoid captureRuntimeErrorReport(\n\t\t\terror,\n\t\t\t{\n\t\t\t\tcategory: \"react\",\n\t\t\t\tcomponentStack\n\t\t\t},\n\t\t\tqueryClient\n\t\t);\n\t}, [componentStack, draftId, error, queryClient]);\n\n\tconst httpStatusCode = getHttpStatusCode(error);\n\n\tif (httpStatusCode) {\n\t\tswitch (httpStatusCode) {\n\t\t\tcase 400:\n\t\t\t\treturn <BadRequestPage />;\n\t\t\tcase 403:\n\t\t\t\treturn <ForbiddenPage />;\n\t\t\tcase 404:\n\t\t\t\treturn <NotFoundPage />;\n\t\t}\n\t}\n\n\tlogError(error.stack);\n\n\treturn (\n\t\t<section className=\"w100 h100 flexColumn justifyContentCenter paddingMd\">\n\t\t\t<div aria-hidden=\"true\" className=\"textCenter relative fontBolded statusError\" style={{ fontSize: \"4em\", marginBlock: \"2em\" }}>\n\t\t\t\t<BoomExplosion />\n\t\t\t\t<div\n\t\t\t\t\tstyle={{\n\t\t\t\t\t\tzIndex: 1,\n\t\t\t\t\t\tposition: \"relative\",\n\t\t\t\t\t\ttextShadow: \"1px -1px 1px var(--warning-border), -1px 1px 1px var(--info-border)\"\n\t\t\t\t\t}}>\n\t\t\t\t\t{ERROR_BOOM_MESSAGES[Math.floor(randomValue * ERROR_BOOM_MESSAGES.length)]}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div className=\"textCenter\">\n\t\t\t\t<h2 className=\"statusError\">Критическая ошибка</h2>\n\t\t\t\t<p className=\"statusError fontSizeLg\">\n\t\t\t\t\t<code>{error.message}</code>\n\t\t\t\t</p>\n\t\t\t\t<p>Попробуйте перезагрузить страницу или вернуться позже.</p>\n\t\t\t</div>\n\t\t</section>\n\t);\n};\n","import React, { Component } from \"react\";\n\nimport { captureRuntimeErrorReport } from \"@ryuzaki13/react-foundation-lib/error-report\";\n\nimport { ErrorDisplay } from \"./ErrorDisplay\";\n\ninterface ErrorBoundaryProps {\n\tchildren: React.ReactNode;\n\tcustomComponent?: React.ComponentType<{ error: Error }>;\n}\n\ntype ErrorBoundaryState = {\n\terror: Error | null;\n\tcomponentStack?: string;\n\tdraftId?: string | null;\n};\n\nexport class ErrorBoundary extends Component<ErrorBoundaryProps, ErrorBoundaryState> {\n\tconstructor(props: ErrorBoundaryProps) {\n\t\tsuper(props);\n\t\tthis.state = { error: null };\n\t}\n\n\tstatic getDerivedStateFromError(error: Error) {\n\t\treturn { error };\n\t}\n\n\tcomponentDidUpdate(prevProps: ErrorBoundaryProps) {\n\t\t// Сбрасываем ошибку при изменении children\n\t\tif (this.state.error && prevProps.children !== this.props.children) {\n\t\t\tthis.setState({ error: null, componentStack: undefined, draftId: undefined });\n\t\t}\n\t}\n\n\tcomponentDidCatch(error: Error, errorInfo: React.ErrorInfo) {\n\t\tthis.setState({ componentStack: errorInfo.componentStack ?? undefined, draftId: null });\n\n\t\tcaptureRuntimeErrorReport(error, {\n\t\t\tcategory: \"react\",\n\t\t\tcomponentStack: errorInfo.componentStack ?? undefined\n\t\t}).then((draft) => {\n\t\t\tif (draft && this.state.error === error) {\n\t\t\t\tthis.setState({ draftId: draft.reportId });\n\t\t\t}\n\t\t});\n\t}\n\n\trender() {\n\t\tif (this.state.error) {\n\t\t\tconst CustomComponent = this.props.customComponent;\n\t\t\treturn CustomComponent ? (\n\t\t\t\t<CustomComponent error={this.state.error} />\n\t\t\t) : (\n\t\t\t\t<ErrorDisplay error={this.state.error} componentStack={this.state.componentStack} draftId={this.state.draftId} />\n\t\t\t);\n\t\t}\n\n\t\treturn this.props.children;\n\t}\n}\n","import React, { useState } from \"react\";\n\nimport { BoomExplosion } from \"./BoomExplosion\";\nimport { ERROR_BOOM_MESSAGES } from \"./constants\";\n\ninterface ErrorExplosionProps {\n\theader?: string;\n\tdescription?: string;\n}\n\nexport const ErrorExplosion: React.FC<ErrorExplosionProps> = ({ header, description }) => {\n\tconst [randomValue] = useState(() => Math.random());\n\n\treturn (\n\t\t<div className=\"container marginBlockLg\">\n\t\t\t<div aria-hidden=\"true\" className={\"textCenter relative fontBolded statusWarning marginBlockMd\"} style={{ fontSize: \"6em\" }}>\n\t\t\t\t<BoomExplosion />\n\t\t\t\t<div\n\t\t\t\t\tstyle={{\n\t\t\t\t\t\tzIndex: 1,\n\t\t\t\t\t\tposition: \"relative\",\n\t\t\t\t\t\ttextShadow: \"1px 0 1px var(--error-fill), -1px 0 1px var(--info-fill)\"\n\t\t\t\t\t}}>\n\t\t\t\t\t{ERROR_BOOM_MESSAGES[Math.floor(randomValue * ERROR_BOOM_MESSAGES.length)]}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div className=\"flexColumn alignItemsCenter textCenter marginBlockMd\">\n\t\t\t\t{header && <h2 className=\"statusWarning\">{header}</h2>}\n\t\t\t\t{description && <p>{description}</p>}\n\t\t\t</div>\n\t\t</div>\n\t);\n};\n","import { logError } from \"@ryuzaki13/react-foundation-lib/utils\";\n\nimport { Text } from \"../text\";\n\nexport function SimpleErrorDisplay({ error }: { error: Error }) {\n\tlogError(error.stack);\n\n\treturn (\n\t\t<Text color=\"error\">\n\t\t\t<code>{error.message}</code>\n\t\t</Text>\n\t);\n}\n","import { PageError } from \"./PageError\";\n\nexport const UnauthorizedPage: React.FC = () => {\n\treturn (\n\t\t<PageError\n\t\t\tcode={401}\n\t\t\ttitle=\"Необходима авторизация\"\n\t\t\tdescription=\"Для доступа к этой странице нужно войти в систему. Пожалуйста, авторизуйтесь и попробуйте снова.\"\n\t\t/>\n\t);\n};\n","import React from \"react\";\n\nimport { Flex } from \"../flex\";\n\nexport const ViewNotChanged: React.FC = () => {\n\treturn (\n\t\t<Flex.Predefined variant=\"columnCenter\" className=\"paddingXl\">\n\t\t\t<h2 className=\"content2\">Выберите ракурс</h2>\n\t\t</Flex.Predefined>\n\t);\n};\n"],"mappings":";;;;;;;;AAUA,IAAa,KAAuC,EAAE,SAAM,UAAO,qBAEjE,kBAAC,EAAK,YAAN;CAAiB,SAAQ;CAAe,WAAU;CAAlD,UAAA;EACC,kBAAC,OAAD;GAAK,eAAY;GAAO,WAAU;GAAsB,OAAO,EAAE,UAAU,MAAM;GAC/E,UAAA;EACG,CAAA;EACL,kBAAC,MAAD,EAAA,UAAK,EAAU,CAAA;EACf,kBAAC,KAAD,EAAA,UAAI,EAAe,CAAA;CAEH;ICjBN,UAEX,kBAAC,GAAD;CACC,MAAM;CACN,OAAM;CACN,aAAY;AACZ,CAAA;;;ACNH,SAAgB,IAAgB;CAC/B,IAAM,CAAC,KAAa,QAGZ,SAFO,KAAM,KAAK,OAAO,IAAI,GAEd,YADP,KAAK,OAAO,IAAI,KAAK,GACK,KACzC;CAED,OACC,kBAAC,OAAD;EACC,SAAQ;EACR,OAAM;EACN,QAAO;EACP,OAAO;GACN,UAAU;GACV,KAAK;GACL,MAAM;GACN,WAAW,yBAAyB;GACpC,QAAQ;GACR,SAAS;EACV;EACA,UAAA,kBAAC,WAAD;GACC,QAAO;GAGP,MAAK;GACL,QAAO;GACP,aAAY;GACZ,gBAAe;EAC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O,CAAC;CAElD,OACC,kBAAC,OAAD;EAAK,WAAU;EAAf,UAAA,CACC,kBAAC,OAAD;GAAK,eAAY;GAAO,WAAW;GAA8D,OAAO,EAAE,UAAU,MAAM;GAA1H,UAAA,CACC,kBAAC,GAAD,CAAgB,CAAA,GAChB,kBAAC,OAAD;IACC,OAAO;KACN,QAAQ;KACR,UAAU;KACV,YAAY;IACb;IACC,UAAA,EAAoB,KAAK,MAAM,IAAc,EAAoB,MAAM;GACpE,CAAA,CACD;EACL,CAAA,GAAA,kBAAC,OAAD;GAAK,WAAU;GAAf,UAAA,CACE,KAAU,kBAAC,MAAD;IAAI,WAAU;IAAiB,UAAA;GAAW,CAAA,GACpD,KAAe,kBAAC,KAAD,EAAA,UAAI,EAAe,CAAA,CAC/B;EACD,CAAA,CAAA;;AAEP;;;AC5BA,SAAgB,EAAmB,EAAE,YAA2B;CAG/D,OAFA,EAAS,EAAM,KAAK,GAGnB,kBAAC,GAAD;EAAM,OAAM;EACX,UAAA,kBAAC,QAAD,EAAA,UAAO,EAAM,QAAc,CAAA;CACtB,CAAA;AAER;;;ACVA,IAAa,UAEX,kBAAC,GAAD;CACC,MAAM;CACN,OAAM;CACN,aAAY;AACZ,CAAA,GCJU,UAEX,kBAAC,EAAK,YAAN;CAAiB,SAAQ;CAAe,WAAU;CACjD,UAAA,kBAAC,MAAD;EAAI,WAAU;EAAW,UAAA;CAAmB,CAAA;AAC5B,CAAA"}
@@ -1,4 +1,4 @@
1
- import { n as e } from "../chunks/button-BaUlN-nt.js";
1
+ import { n as e } from "../chunks/button-DF21yxVp.js";
2
2
  import { l as t } from "../chunks/misc-DeGboAt-.js";
3
3
  import { useCallback as n, useId as r, useState as i } from "react";
4
4
  import { cn as a } from "@ryuzaki13/react-foundation-lib/utils";
@@ -1,8 +1,8 @@
1
- import { n as e } from "../chunks/button-BaUlN-nt.js";
1
+ import { n as e } from "../chunks/button-DF21yxVp.js";
2
2
  import { r as t } from "../chunks/grid-dI94AAbi.js";
3
- import { i as n, n as r, r as i } from "../chunks/modal-CbAwLHlM.js";
4
- import { s as a } from "../chunks/input-D1jOxm0t.js";
5
- import { t as o } from "../chunks/input-files-CDGpJaUm.js";
3
+ import { i as n, n as r, r as i } from "../chunks/modal-dplfAaER.js";
4
+ import { s as a } from "../chunks/input-DSPKgiCK.js";
5
+ import { t as o } from "../chunks/input-files-tIS17-zX.js";
6
6
  import { Suspense as s, lazy as c, useCallback as l, useEffect as u, useMemo as d, useRef as f, useState as p } from "react";
7
7
  import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
8
8
  import _ from "react-easy-crop";
@@ -352,7 +352,7 @@ function k({ aspect: e = 16 / 9, disabled: n, allowedMime: r = O, maxBytes: i, m
352
352
  onClick: () => l.setActiveIndex(r),
353
353
  style: {
354
354
  padding: 0,
355
- border: r === l.activeIndex ? "2px solid var(--border-accent)" : "2px solid transparent",
355
+ border: r === l.activeIndex ? "2px solid var(--accent-border)" : "2px solid transparent",
356
356
  background: "transparent",
357
357
  cursor: n ? "default" : "pointer"
358
358
  },
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/image/lib/buildImageSrcSet.ts","../../src/image/lib/buildImageSources.ts","../../src/image/ui/ImageCropper.tsx","../../src/image/ui/ImagePlaceholder.tsx","../../src/image/ui/ImageRenderer.tsx","../../src/image/lib/getImageSelectionKey.ts","../../src/image/model/useImageSelectionState.ts","../../src/image/lib/getImageCropPreviewStyle.ts","../../src/image/ui/ImageSelectionFields.tsx","../../src/image/ui/ImageSelectionModal.tsx","../../src/image/ui/ImageSelectionPanel.tsx","../../src/image/ui/ImageView.tsx","../../src/image/ui/ImageViewer.tsx"],"sourcesContent":["import { type ImageCandidate } from \"../model/imageTypes\";\n\n/** Собирает валидный srcset из уже разрешённых вызывающим кодом URL вариантов. */\nexport function buildImageSrcSet(candidates: readonly ImageCandidate[]): string {\n\treturn candidates\n\t\t.map((candidate) => (\"width\" in candidate ? `${candidate.src} ${candidate.width}w` : `${candidate.src} ${candidate.density}x`))\n\t\t.join(\", \");\n}\n","import { type ImageSource, type ResponsiveImageSource } from \"../model/imageTypes\";\n\nimport { buildImageSrcSet } from \"./buildImageSrcSet\";\n\n/** Преобразует декларативные наборы кандидатов в готовые source-дескрипторы. */\nexport function buildImageSources(sources: readonly ResponsiveImageSource[] | undefined, defaultSizes?: string): ImageSource[] {\n\treturn (sources ?? [])\n\t\t.map((source) => ({\n\t\t\tsrcSet: buildImageSrcSet(source.candidates),\n\t\t\ttype: source.type,\n\t\t\tsizes: source.sizes ?? defaultSizes\n\t\t}))\n\t\t.filter((source) => source.srcSet.length > 0);\n}\n","import { useCallback, useState } from \"react\";\n\nimport Cropper from \"react-easy-crop\";\n\nimport { type ImageCropArea, type ImageCropperProps, type ImageCropPoint } from \"../model/imageCropTypes\";\n\nconst DEFAULT_CROP: ImageCropPoint = { x: 0, y: 0 };\n\n/**\n * Управляемая или автономная область обрезки изображения.\n * Числовой aspect задаётся вызывающим кодом и не связан с назначением изображения.\n */\nexport function ImageCropper({\n\timage,\n\taspect = 16 / 9,\n\twidth = \"100%\",\n\tclassName,\n\tstyle,\n\tcrop,\n\tdefaultCrop = DEFAULT_CROP,\n\tzoom,\n\tdefaultZoom = 1,\n\tminZoom = 1,\n\tmaxZoom = 3,\n\tzoomSpeed = 0.1,\n\tobjectFit = \"contain\",\n\tdisabled = false,\n\tonCropChange,\n\tonZoomChange,\n\tonCropComplete\n}: ImageCropperProps) {\n\tconst [uncontrolledCrop, setUncontrolledCrop] = useState(defaultCrop);\n\tconst [uncontrolledZoom, setUncontrolledZoom] = useState(defaultZoom);\n\tconst resolvedCrop = crop ?? uncontrolledCrop;\n\tconst resolvedZoom = zoom ?? uncontrolledZoom;\n\n\tconst handleCropChange = useCallback(\n\t\t(nextCrop: ImageCropPoint) => {\n\t\t\tif (disabled) return;\n\n\t\t\tif (crop === undefined) {\n\t\t\t\tsetUncontrolledCrop(nextCrop);\n\t\t\t}\n\n\t\t\tonCropChange?.(nextCrop);\n\t\t},\n\t\t[crop, disabled, onCropChange]\n\t);\n\n\tconst handleZoomChange = useCallback(\n\t\t(nextZoom: number) => {\n\t\t\tif (disabled) return;\n\n\t\t\tif (zoom === undefined) {\n\t\t\t\tsetUncontrolledZoom(nextZoom);\n\t\t\t}\n\n\t\t\tonZoomChange?.(nextZoom);\n\t\t},\n\t\t[disabled, onZoomChange, zoom]\n\t);\n\n\tconst handleCropComplete = useCallback(\n\t\t(croppedAreaPercentages: ImageCropArea, croppedAreaPixels: ImageCropArea) => {\n\t\t\tif (disabled) return;\n\n\t\t\tonCropComplete?.(croppedAreaPixels, croppedAreaPercentages);\n\t\t},\n\t\t[disabled, onCropComplete]\n\t);\n\n\treturn (\n\t\t<div\n\t\t\tclassName={className}\n\t\t\tstyle={{ position: \"relative\", width, aspectRatio: aspect, pointerEvents: disabled ? \"none\" : undefined, ...style }}>\n\t\t\t<Cropper\n\t\t\t\timage={image}\n\t\t\t\tcrop={resolvedCrop}\n\t\t\t\tzoom={resolvedZoom}\n\t\t\t\taspect={aspect}\n\t\t\t\tminZoom={minZoom}\n\t\t\t\tmaxZoom={maxZoom}\n\t\t\t\tzoomSpeed={zoomSpeed}\n\t\t\t\tobjectFit={objectFit}\n\t\t\t\tonCropChange={handleCropChange}\n\t\t\t\tonZoomChange={handleZoomChange}\n\t\t\t\tonCropComplete={handleCropComplete}\n\t\t\t\tcropperProps={{ \"aria-disabled\": disabled || undefined }}\n\t\t\t/>\n\t\t</div>\n\t);\n}\n","export interface ImagePlaceholderProps {\n\twidth?: number | string;\n\theight?: number | string;\n\taspectRatio?: string | \"unset\";\n\tclassName?: string;\n}\n\nexport function ImagePlaceholder({ width = \"100%\", height = \"100%\", aspectRatio = \"16 / 9\", className }: ImagePlaceholderProps) {\n\treturn (\n\t\t<div style={{ width, height, aspectRatio }} className={className}>\n\t\t\t<svg\n\t\t\t\twidth={width}\n\t\t\t\theight={height}\n\t\t\t\tviewBox=\"0 0 200 200\"\n\t\t\t\txmlns=\"http://www.w3.org/2000/svg\"\n\t\t\t\trole=\"img\"\n\t\t\t\tfill=\"none\"\n\t\t\t\trx=\"10\"\n\t\t\t\try=\"10\"\n\t\t\t\tstyle={{ display: \"block\" }}\n\t\t\t\taria-label=\"Изображение недоступно\">\n\t\t\t\t{/* <rect width=\"200\" height=\"200\" fill=\"var(--surface-2)\" rx=\"10\" ry=\"10\" /> */}\n\t\t\t\t<g fill=\"var(--surface-0)\">\n\t\t\t\t\t<rect x=\"40\" y=\"50\" width=\"120\" height=\"100\" rx=\"10\" />\n\n\t\t\t\t\t<circle cx=\"60\" cy=\"70\" r=\"8\" fill=\"var(--surface-2)\" />\n\n\t\t\t\t\t<path d=\"M50 130 L75 100 L100 130 Z\" fill=\"var(--surface-2)\" />\n\t\t\t\t\t<path d=\"M90 130 L120 90 L150 130 Z\" fill=\"var(--surface-2)\" />\n\n\t\t\t\t\t<line x1=\"160\" y1=\"40\" x2=\"40\" y2=\"160\" stroke=\"var(--surface-0)\" strokeWidth=\"15\" strokeLinecap=\"round\" />\n\t\t\t\t\t<line x1=\"160\" y1=\"40\" x2=\"40\" y2=\"160\" stroke=\"var(--surface-2)\" strokeWidth=\"5\" strokeLinecap=\"round\" />\n\t\t\t\t</g>\n\t\t\t</svg>\n\t\t</div>\n\t);\n}\n","import { type CSSProperties, type ImgHTMLAttributes, type ReactNode, useEffect, useRef, useState } from \"react\";\n\nimport { type ImageLayout, type ImageSource } from \"../model/imageTypes\";\n\nimport { ImagePlaceholder } from \"./ImagePlaceholder\";\n\nexport interface ImageRendererProps extends Omit<ImgHTMLAttributes<HTMLImageElement>, \"src\" | \"width\" | \"height\"> {\n\tsrc: string;\n\tsources?: readonly ImageSource[];\n\tlayout?: ImageLayout;\n\talt?: string;\n\trole?: string;\n\tariaLabel?: string;\n\tcaption?: string;\n\tfallback?: ReactNode;\n\tuseFigure?: boolean;\n\taspectRatio?: string | \"unset\";\n\twidth?: CSSProperties[\"width\"];\n\theight?: CSSProperties[\"height\"];\n\tintrinsicWidth?: number;\n\tintrinsicHeight?: number;\n\twrapperStyle?: CSSProperties;\n}\n\n/**\n * Базовый рендер изображения: lazy-появление, placeholder, обработка ошибки и figure/caption.\n * Компонент не знает, как устроено хранилище и какие форматы/размеры доступны.\n */\nexport function ImageRenderer({\n\tsrc,\n\tsources,\n\talt,\n\trole,\n\tariaLabel,\n\tcaption,\n\tfallback,\n\tuseFigure = false,\n\tlayout = \"cover\",\n\twidth = \"100%\",\n\theight = \"100%\",\n\taspectRatio,\n\tintrinsicWidth,\n\tintrinsicHeight,\n\tonLoad,\n\tonError,\n\tstyle,\n\twrapperStyle,\n\t...imgProps\n}: ImageRendererProps) {\n\tconst wrapperRef = useRef<HTMLDivElement | null>(null);\n\tconst [containerWidth, setContainerWidth] = useState(0);\n\tconst [isVisible, setIsVisible] = useState(false);\n\tconst [hasLoaded, setHasLoaded] = useState(false);\n\tconst [hasError, setHasError] = useState(false);\n\n\tuseEffect(() => {\n\t\tif (typeof IntersectionObserver === \"undefined\") {\n\t\t\t// Отложенный fallback сохраняет одинаковый первый render на сервере и в браузере без IntersectionObserver.\n\t\t\tconst timeoutId = window.setTimeout(() => setIsVisible(true), 0);\n\n\t\t\treturn () => window.clearTimeout(timeoutId);\n\t\t}\n\n\t\tconst observer = new IntersectionObserver(\n\t\t\t([entry]) => {\n\t\t\t\tif (entry.isIntersecting) {\n\t\t\t\t\tconst parentWidth = Math.round(entry.boundingClientRect.width);\n\n\t\t\t\t\tsetContainerWidth(parentWidth);\n\t\t\t\t\tsetIsVisible(true);\n\t\t\t\t\tobserver.disconnect();\n\t\t\t\t}\n\t\t\t},\n\t\t\t{ rootMargin: \"100px\", threshold: 0.01 }\n\t\t);\n\n\t\tif (wrapperRef.current) {\n\t\t\tobserver.observe(wrapperRef.current);\n\t\t}\n\n\t\treturn () => observer.disconnect();\n\t}, []);\n\n\tconst isIntrinsic = layout === \"intrinsic\";\n\tconst resolvedHeight = isIntrinsic ? \"auto\" : height;\n\tconst intrinsicAspectRatio = intrinsicWidth && intrinsicHeight ? `${intrinsicWidth} / ${intrinsicHeight}` : undefined;\n\tconst resolvedAspectRatio = isIntrinsic ? (intrinsicAspectRatio ?? aspectRatio ?? \"auto\") : (aspectRatio ?? \"16 / 9\");\n\tconst placeholderHeight = isIntrinsic && resolvedAspectRatio !== \"auto\" && resolvedAspectRatio !== \"unset\" ? \"100%\" : resolvedHeight;\n\tconst sizesAttr = containerWidth ? `${containerWidth}px` : \"100vw\";\n\tconst defaultFallback = <ImagePlaceholder width={width} height={placeholderHeight} aspectRatio={resolvedAspectRatio} />;\n\tconst loadedImageStyle: CSSProperties = isIntrinsic\n\t\t? {\n\t\t\t\t...style,\n\t\t\t\tdisplay: \"block\",\n\t\t\t\twidth: \"100%\",\n\t\t\t\theight: \"auto\",\n\t\t\t\tobjectFit: undefined\n\t\t\t}\n\t\t: {\n\t\t\t\tdisplay: \"block\",\n\t\t\t\twidth: \"100%\",\n\t\t\t\theight: \"100%\",\n\t\t\t\tobjectFit: layout,\n\t\t\t\t...style\n\t\t\t};\n\n\tconst content = (\n\t\t<>\n\t\t\t{!hasLoaded && !hasError && (fallback || defaultFallback)}\n\t\t\t{isVisible && !hasError && (\n\t\t\t\t<picture>\n\t\t\t\t\t{sources?.map((source) => (\n\t\t\t\t\t\t<source\n\t\t\t\t\t\t\tkey={`${source.type ?? \"source\"}-${source.srcSet}`}\n\t\t\t\t\t\t\tsrcSet={source.srcSet}\n\t\t\t\t\t\t\ttype={source.type}\n\t\t\t\t\t\t\tsizes={source.sizes ?? sizesAttr}\n\t\t\t\t\t\t/>\n\t\t\t\t\t))}\n\t\t\t\t\t<img\n\t\t\t\t\t\tsrc={src}\n\t\t\t\t\t\talt={alt}\n\t\t\t\t\t\trole={role}\n\t\t\t\t\t\taria-label={ariaLabel}\n\t\t\t\t\t\tonLoad={(event) => {\n\t\t\t\t\t\t\tsetHasLoaded(true);\n\t\t\t\t\t\t\tonLoad?.(event);\n\t\t\t\t\t\t}}\n\t\t\t\t\t\tonError={(event) => {\n\t\t\t\t\t\t\tsetHasError(true);\n\t\t\t\t\t\t\tonError?.(event);\n\t\t\t\t\t\t}}\n\t\t\t\t\t\tstyle={!hasLoaded ? { display: \"none\" } : loadedImageStyle}\n\t\t\t\t\t\taria-busy={!hasLoaded}\n\t\t\t\t\t\twidth={intrinsicWidth}\n\t\t\t\t\t\theight={intrinsicHeight}\n\t\t\t\t\t\t{...imgProps}\n\t\t\t\t\t/>\n\t\t\t\t</picture>\n\t\t\t)}\n\t\t\t{hasError && defaultFallback}\n\t\t</>\n\t);\n\n\tconst wrapped = (\n\t\t<div ref={wrapperRef} style={{ width, height: resolvedHeight, aspectRatio: resolvedAspectRatio, ...wrapperStyle }}>\n\t\t\t{content}\n\t\t</div>\n\t);\n\n\treturn useFigure ? (\n\t\t<figure className=\"relative\">\n\t\t\t{wrapped}\n\t\t\t{caption && (\n\t\t\t\t<figcaption\n\t\t\t\t\tstyle={{ bottom: 2, right: 2, maxWidth: \"calc(100% - 4px)\" }}\n\t\t\t\t\tclassName=\"absolute paddingInlineMd textRight radiusSm fontSizeSm\">\n\t\t\t\t\t{caption}\n\t\t\t\t</figcaption>\n\t\t\t)}\n\t\t</figure>\n\t) : (\n\t\twrapped\n\t);\n}\n","import { type SelectedImageData } from \"../model/imageSelectionTypes\";\n\n/** Возвращает устойчивый ключ файла внутри текущего набора выбранных изображений. */\nexport function getImageSelectionKey(image: SelectedImageData, index: number): string {\n\treturn `${image.file.meta.name}-${image.file.meta.size}-${image.file.meta.lastModified}-${index}`;\n}\n","import { useCallback, useMemo, useState } from \"react\";\n\nimport { getImageSelectionKey } from \"../lib/getImageSelectionKey\";\n\nimport { type ImageCropArea, type ImageCropPoint } from \"./imageCropTypes\";\nimport {\n\ttype ImageCropperState,\n\ttype ImageSelectionPanelProps,\n\ttype ImageSelectionState,\n\ttype SelectedImageData,\n\ttype SelectedImageFile\n} from \"./imageSelectionTypes\";\n\nconst INITIAL_CROPPER_STATE: ImageCropperState = { crop: { x: 0, y: 0 }, zoom: 1 };\n\n/**\n * Управляет набором изображений в conventional controlled/uncontrolled-режиме.\n * В controlled-режиме каждое изменение сразу передаётся через onChange, а источник истины остаётся у вызывающего кода.\n */\nexport function useImageSelectionState({\n\tvalue,\n\tdefaultValue,\n\tdisabled,\n\tonChange,\n\tonApply\n}: Pick<ImageSelectionPanelProps, \"value\" | \"defaultValue\" | \"disabled\" | \"onChange\" | \"onApply\">): ImageSelectionState {\n\tconst [uncontrolledValue, setUncontrolledValue] = useState<SelectedImageData[]>(defaultValue ?? []);\n\tconst [requestedActiveIndex, setActiveIndex] = useState(0);\n\tconst [cropperStateByImage, setCropperStateByImage] = useState<Record<string, ImageCropperState>>({});\n\tconst resolvedValue = value ?? uncontrolledValue;\n\n\tconst updateValue = useCallback(\n\t\t(updater: (currentValue: SelectedImageData[]) => SelectedImageData[]) => {\n\t\t\tconst nextValue = updater(resolvedValue);\n\n\t\t\tif (value === undefined) {\n\t\t\t\tsetUncontrolledValue(nextValue);\n\t\t\t}\n\n\t\t\tonChange?.(nextValue);\n\t\t},\n\t\t[onChange, resolvedValue, value]\n\t);\n\n\tconst files = useMemo(() => resolvedValue.map((image) => image.file), [resolvedValue]);\n\tconst activeIndex = resolvedValue.length === 0 ? 0 : Math.min(requestedActiveIndex, resolvedValue.length - 1);\n\tconst activeImage = resolvedValue[activeIndex];\n\tconst activeImageKey = activeImage ? getImageSelectionKey(activeImage, activeIndex) : undefined;\n\tconst activeCropperState = activeImageKey ? (cropperStateByImage[activeImageKey] ?? INITIAL_CROPPER_STATE) : INITIAL_CROPPER_STATE;\n\tconst hasSelected = resolvedValue.length > 0;\n\tconst canApply = !disabled && hasSelected && resolvedValue.every((image) => image.alt.trim() && image.crop);\n\n\tconst setFiles = useCallback(\n\t\t(nextFiles: SelectedImageFile[]) => {\n\t\t\tupdateValue((currentValue) =>\n\t\t\t\tnextFiles.map((file) => {\n\t\t\t\t\t// Сохраняем описание и crop для файлов, которые остались в выборе.\n\t\t\t\t\tconst existingImage = currentValue.find((image) => image.file.file === file.file);\n\n\t\t\t\t\treturn existingImage ? { ...existingImage, file } : { file, alt: \"\" };\n\t\t\t\t})\n\t\t\t);\n\t\t},\n\t\t[updateValue]\n\t);\n\n\tconst setActiveAlt = useCallback(\n\t\t(alt: string) => {\n\t\t\tupdateValue((currentValue) => currentValue.map((image, index) => (index === activeIndex ? { ...image, alt } : image)));\n\t\t},\n\t\t[activeIndex, updateValue]\n\t);\n\n\tconst setActiveCrop = useCallback(\n\t\t(crop: ImageCropArea) => {\n\t\t\tupdateValue((currentValue) => currentValue.map((image, index) => (index === activeIndex ? { ...image, crop } : image)));\n\t\t},\n\t\t[activeIndex, updateValue]\n\t);\n\n\tconst setActiveCropperCrop = useCallback(\n\t\t(crop: ImageCropPoint) => {\n\t\t\tif (!activeImageKey) return;\n\n\t\t\tsetCropperStateByImage((currentState) => ({\n\t\t\t\t...currentState,\n\t\t\t\t[activeImageKey]: {\n\t\t\t\t\tcrop,\n\t\t\t\t\tzoom: currentState[activeImageKey]?.zoom ?? 1\n\t\t\t\t}\n\t\t\t}));\n\t\t},\n\t\t[activeImageKey]\n\t);\n\n\tconst setActiveCropperZoom = useCallback(\n\t\t(zoom: number) => {\n\t\t\tif (!activeImageKey) return;\n\n\t\t\tsetCropperStateByImage((currentState) => ({\n\t\t\t\t...currentState,\n\t\t\t\t[activeImageKey]: {\n\t\t\t\t\tcrop: currentState[activeImageKey]?.crop ?? { x: 0, y: 0 },\n\t\t\t\t\tzoom\n\t\t\t\t}\n\t\t\t}));\n\t\t},\n\t\t[activeImageKey]\n\t);\n\n\tconst apply = useCallback(() => {\n\t\tonApply?.(resolvedValue);\n\t}, [onApply, resolvedValue]);\n\n\treturn {\n\t\tvalue: resolvedValue,\n\t\tfiles,\n\t\tactiveIndex,\n\t\tactiveImage,\n\t\tactiveCropperState,\n\t\thasSelected,\n\t\tcanApply,\n\t\tapply,\n\t\tsetFiles,\n\t\tsetActiveIndex,\n\t\tsetActiveAlt,\n\t\tsetActiveCrop,\n\t\tsetActiveCropperCrop,\n\t\tsetActiveCropperZoom\n\t};\n}\n","import { type CSSProperties } from \"react\";\n\nimport { type SelectedImageData } from \"../model/imageSelectionTypes\";\n\nexport type ImageNaturalSize = {\n\twidth: number;\n\theight: number;\n};\n\n/** Масштабирует preview так, чтобы контейнер показывал только выбранную область crop. */\nexport function getImageCropPreviewStyle(image: SelectedImageData, size: ImageNaturalSize | undefined, aspect: number): CSSProperties {\n\tif (!image.crop || !size) {\n\t\treturn {\n\t\t\twidth: \"100%\",\n\t\t\taspectRatio: aspect,\n\t\t\tobjectFit: \"cover\",\n\t\t\tdisplay: \"block\"\n\t\t};\n\t}\n\n\tconst crop = image.crop;\n\n\treturn {\n\t\tposition: \"absolute\",\n\t\tleft: `${-(crop.x / crop.width) * 100}%`,\n\t\ttop: `${-(crop.y / crop.height) * 100}%`,\n\t\twidth: `${(size.width / crop.width) * 100}%`,\n\t\theight: `${(size.height / crop.height) * 100}%`,\n\t\tmaxWidth: \"none\"\n\t};\n}\n","import { useState } from \"react\";\n\nimport { GridContainer } from \"../../grid\";\nimport { InputText } from \"../../input\";\nimport { InputFiles } from \"../../input-files\";\nimport { getImageCropPreviewStyle, type ImageNaturalSize } from \"../lib/getImageCropPreviewStyle\";\nimport { getImageSelectionKey } from \"../lib/getImageSelectionKey\";\nimport { type ImageSelectionPanelProps, type ImageSelectionState } from \"../model/imageSelectionTypes\";\n\nimport { ImageCropper } from \"./ImageCropper\";\n\nconst DEFAULT_ALLOWED_IMAGE_MIME = [\"image/jpeg\", \"image/png\", \"image/webp\", \"image/avif\"] as const;\n\ninterface ImageSelectionFieldsProps extends Pick<\n\tImageSelectionPanelProps,\n\t\"aspect\" | \"disabled\" | \"allowedMime\" | \"maxBytes\" | \"minimumCropWidth\" | \"onReadError\"\n> {\n\tstate: ImageSelectionState;\n}\n\n/** Поля выбора файлов, crop и альтернативного текста для активного изображения. */\nexport function ImageSelectionFields({\n\taspect = 16 / 9,\n\tdisabled,\n\tallowedMime = DEFAULT_ALLOWED_IMAGE_MIME,\n\tmaxBytes,\n\tminimumCropWidth,\n\tonReadError,\n\tstate\n}: ImageSelectionFieldsProps) {\n\tconst area = state.activeImage?.crop;\n\tconst [imageSizes, setImageSizes] = useState<Record<string, ImageNaturalSize>>({});\n\n\treturn (\n\t\t<GridContainer gap=\"md\">\n\t\t\t<InputFiles\n\t\t\t\tlabel=\"Файл изображения\"\n\t\t\t\tallowedMime={allowedMime}\n\t\t\t\tvalue={state.files}\n\t\t\t\tonChange={state.setFiles}\n\t\t\t\tmaxBytes={maxBytes}\n\t\t\t\tdisabled={disabled}\n\t\t\t\tonReadError={onReadError}\n\t\t\t/>\n\n\t\t\t{state.hasSelected && state.activeImage && (\n\t\t\t\t<div>\n\t\t\t\t\t<GridContainer templateColumns=\"repeat(auto-fill, minmax(10em, 1fr))\" gap=\"xs\">\n\t\t\t\t\t\t{state.value.map((image, index) => {\n\t\t\t\t\t\t\tconst imageKey = getImageSelectionKey(image, index);\n\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\tkey={imageKey}\n\t\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t\t\t\t\tonClick={() => state.setActiveIndex(index)}\n\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\tpadding: 0,\n\t\t\t\t\t\t\t\t\t\tborder: index === state.activeIndex ? \"2px solid var(--border-accent)\" : \"2px solid transparent\",\n\t\t\t\t\t\t\t\t\t\tbackground: \"transparent\",\n\t\t\t\t\t\t\t\t\t\tcursor: disabled ? \"default\" : \"pointer\"\n\t\t\t\t\t\t\t\t\t}}>\n\t\t\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\t\tposition: \"relative\",\n\t\t\t\t\t\t\t\t\t\t\tdisplay: \"block\",\n\t\t\t\t\t\t\t\t\t\t\twidth: \"100%\",\n\t\t\t\t\t\t\t\t\t\t\taspectRatio: aspect,\n\t\t\t\t\t\t\t\t\t\t\toverflow: \"hidden\"\n\t\t\t\t\t\t\t\t\t\t}}>\n\t\t\t\t\t\t\t\t\t\t<img\n\t\t\t\t\t\t\t\t\t\t\tsrc={image.file.dataUrl}\n\t\t\t\t\t\t\t\t\t\t\talt={image.alt || `Предпросмотр изображения ${index + 1}`}\n\t\t\t\t\t\t\t\t\t\t\tstyle={getImageCropPreviewStyle(image, imageSizes[imageKey], aspect)}\n\t\t\t\t\t\t\t\t\t\t\tonLoad={(event) => {\n\t\t\t\t\t\t\t\t\t\t\t\tconst target = event.currentTarget;\n\n\t\t\t\t\t\t\t\t\t\t\t\tsetImageSizes((currentSizes) => ({\n\t\t\t\t\t\t\t\t\t\t\t\t\t...currentSizes,\n\t\t\t\t\t\t\t\t\t\t\t\t\t[imageKey]: {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\twidth: target.naturalWidth,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\theight: target.naturalHeight\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t}));\n\t\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t})}\n\t\t\t\t\t</GridContainer>\n\n\t\t\t\t\t<div>\n\t\t\t\t\t\tВыберите область изображения{\" \"}\n\t\t\t\t\t\t{area && (\n\t\t\t\t\t\t\t<code className={minimumCropWidth && area.width < minimumCropWidth ? \"statusError\" : \"statusSuccess\"}>\n\t\t\t\t\t\t\t\t{area.width}x{area.height}\n\t\t\t\t\t\t\t\t{minimumCropWidth && area.width < minimumCropWidth ? \" — недостаточная ширина\" : \"\"}\n\t\t\t\t\t\t\t</code>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</div>\n\n\t\t\t\t\t<ImageCropper\n\t\t\t\t\t\tkey={getImageSelectionKey(state.activeImage, state.activeIndex)}\n\t\t\t\t\t\timage={state.activeImage.file.dataUrl}\n\t\t\t\t\t\tcrop={state.activeCropperState.crop}\n\t\t\t\t\t\tzoom={state.activeCropperState.zoom}\n\t\t\t\t\t\taspect={aspect}\n\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t\tonCropChange={state.setActiveCropperCrop}\n\t\t\t\t\t\tonZoomChange={state.setActiveCropperZoom}\n\t\t\t\t\t\tonCropComplete={state.setActiveCrop}\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t)}\n\n\t\t\t<InputText\n\t\t\t\trequired\n\t\t\t\tdisabled={!state.hasSelected || disabled}\n\t\t\t\tlabel=\"Краткое описание изображения\"\n\t\t\t\tplaceholder=\"\"\n\t\t\t\tvalue={state.activeImage?.alt ?? \"\"}\n\t\t\t\tonChange={state.setActiveAlt}\n\t\t\t/>\n\t\t</GridContainer>\n\t);\n}\n","import { Button } from \"../../button\";\nimport { Modal, ModalContent, ModalFooter } from \"../../modal\";\nimport { type ImageSelectionModalProps } from \"../model/imageSelectionTypes\";\nimport { useImageSelectionState } from \"../model/useImageSelectionState\";\n\nimport { ImageSelectionFields } from \"./ImageSelectionFields\";\n\n/** Модальная форма выбора изображений с необязательным этапом подтверждения. */\nexport function ImageSelectionModal({\n\tdisabled,\n\tisOpen = true,\n\tonClose = () => {},\n\ttitle = \"Загрузка нового изображения\",\n\t...props\n}: ImageSelectionModalProps) {\n\tconst state = useImageSelectionState({ ...props, disabled });\n\n\tif (!props.onApply) {\n\t\treturn (\n\t\t\t<Modal isOpen={isOpen} onClose={onClose} title={title} size=\"xl\">\n\t\t\t\t<ModalContent scrollable>\n\t\t\t\t\t<ImageSelectionFields {...props} disabled={disabled} state={state} />\n\t\t\t\t</ModalContent>\n\t\t\t</Modal>\n\t\t);\n\t}\n\n\treturn (\n\t\t<Modal isOpen={isOpen} onClose={onClose} title={title} size=\"xl\">\n\t\t\t<ModalContent scrollable>\n\t\t\t\t<ImageSelectionFields {...props} disabled={disabled} state={state} />\n\t\t\t</ModalContent>\n\t\t\t<ModalFooter>\n\t\t\t\t<Button disabled={!state.canApply} tone=\"success\" onClick={state.apply}>\n\t\t\t\t\tПрименить\n\t\t\t\t</Button>\n\t\t\t</ModalFooter>\n\t\t</Modal>\n\t);\n}\n","import { Button } from \"../../button\";\nimport { type ImageSelectionActionsData, type ImageSelectionPanelProps } from \"../model/imageSelectionTypes\";\nimport { useImageSelectionState } from \"../model/useImageSelectionState\";\n\nimport { ImageSelectionFields } from \"./ImageSelectionFields\";\n\n/** Встраиваемая форма выбора и обрезки одного или нескольких изображений. */\nexport function ImageSelectionPanel({ disabled, renderActions, ...props }: ImageSelectionPanelProps) {\n\tconst state = useImageSelectionState({ ...props, disabled });\n\tconst actionsData: ImageSelectionActionsData = {\n\t\tvalue: state.value,\n\t\tactiveIndex: state.activeIndex,\n\t\thasSelected: state.hasSelected,\n\t\tcanApply: state.canApply,\n\t\tapply: state.apply\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t<ImageSelectionFields {...props} disabled={disabled} state={state} />\n\t\t\t{renderActions\n\t\t\t\t? renderActions(actionsData)\n\t\t\t\t: props.onApply && (\n\t\t\t\t\t\t<div>\n\t\t\t\t\t\t\t<Button disabled={!state.canApply} tone=\"success\" onClick={state.apply}>\n\t\t\t\t\t\t\t\tПрименить\n\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t)}\n\t\t</>\n\t);\n}\n","import { type ImgHTMLAttributes } from \"react\";\n\nimport { buildImageSources } from \"../lib/buildImageSources\";\nimport { buildImageSrcSet } from \"../lib/buildImageSrcSet\";\nimport { type ResponsiveImageData } from \"../model/imageTypes\";\n\nimport { ImageRenderer, type ImageRendererProps } from \"./ImageRenderer\";\n\nexport interface ImageViewProps\n\textends\n\t\tOmit<ImageRendererProps, \"src\" | \"sources\" | \"alt\" | \"intrinsicWidth\" | \"intrinsicHeight\" | \"srcSet\" | \"sizes\">,\n\t\tPick<ImgHTMLAttributes<HTMLImageElement>, \"sizes\"> {\n\timage: ResponsiveImageData;\n\talt?: string;\n}\n\n/**\n * Собирает picture/srcset из готовых URL и делегирует отображение ImageRenderer.\n * Компонент не формирует имена файлов и не знает о форматах или размерах хранилища.\n */\nexport function ImageView({ image, alt, sizes, aspectRatio, ...props }: ImageViewProps) {\n\tconst sources = buildImageSources(image.sources, sizes);\n\tconst srcSet = image.candidates ? buildImageSrcSet(image.candidates) : undefined;\n\tconst resolvedAspectRatio =\n\t\taspectRatio ?? (image.intrinsicWidth && image.intrinsicHeight ? `${image.intrinsicWidth} / ${image.intrinsicHeight}` : undefined);\n\n\treturn (\n\t\t<ImageRenderer\n\t\t\t{...props}\n\t\t\tsrc={image.src}\n\t\t\tsrcSet={srcSet || undefined}\n\t\t\tsources={sources}\n\t\t\tsizes={sizes}\n\t\t\talt={alt ?? image.alt}\n\t\t\tintrinsicWidth={image.intrinsicWidth}\n\t\t\tintrinsicHeight={image.intrinsicHeight}\n\t\t\taspectRatio={resolvedAspectRatio}\n\t\t/>\n\t);\n}\n","import { lazy, Suspense, useCallback, useState } from \"react\";\n\nimport { type ImageViewerProps } from \"../model/imageViewerTypes\";\n\nimport \"yet-another-react-lightbox/plugins/captions.css\";\nimport \"yet-another-react-lightbox/plugins/counter.css\";\nimport \"yet-another-react-lightbox/plugins/thumbnails.css\";\nimport \"yet-another-react-lightbox/styles.css\";\n\nconst LazyImageViewerRuntime = lazy(() => import(\"./ImageViewerRuntime\"));\n\n/**\n * Управляемый полноэкранный viewer с ленивой границей vendor runtime.\n * YARL и его плагины загружаются только при первом открытии, а после mount runtime остаётся в React-дереве,\n * чтобы закрытие успело завершить анимацию, снять inert и вернуть focus исходному trigger.\n */\nexport function ImageViewer(props: ImageViewerProps) {\n\tconst [runtimeMounted, setRuntimeMounted] = useState(false);\n\tconst handleRuntimeMounted = useCallback(() => setRuntimeMounted(true), []);\n\tconst canRenderRuntime = typeof document !== \"undefined\" && (props.open || runtimeMounted);\n\n\tif (!canRenderRuntime) return null;\n\n\treturn (\n\t\t<Suspense fallback={null}>\n\t\t\t<LazyImageViewerRuntime {...props} onRuntimeMounted={handleRuntimeMounted} />\n\t\t</Suspense>\n\t);\n}\n"],"mappings":";;;;;;;;;AAGA,SAAgB,EAAiB,GAA+C;CAC/E,OAAO,EACL,KAAK,MAAe,WAAW,IAAY,GAAG,EAAU,IAAI,GAAG,EAAU,MAAM,KAAK,GAAG,EAAU,IAAI,GAAG,EAAU,QAAQ,EAAG,CAAC,CAC9H,KAAK,IAAI;AACZ;;;ACFA,SAAgB,EAAkB,GAAuD,GAAsC;CAC9H,QAAQ,KAAW,CAAC,EAAA,CAClB,KAAK,OAAY;EACjB,QAAQ,EAAiB,EAAO,UAAU;EAC1C,MAAM,EAAO;EACb,OAAO,EAAO,SAAS;CACxB,EAAE,CAAC,CACF,QAAQ,MAAW,EAAO,OAAO,SAAS,CAAC;AAC9C;;;ACPA,IAAM,IAA+B;CAAE,GAAG;CAAG,GAAG;AAAE;AAMlD,SAAgB,EAAa,EAC5B,UACA,YAAS,KAAK,GACd,WAAQ,QACR,cACA,UACA,SACA,iBAAc,GACd,SACA,iBAAc,GACd,aAAU,GACV,aAAU,GACV,eAAY,IACZ,eAAY,WACZ,cAAW,IACX,iBACA,iBACA,qBACqB;CACrB,IAAM,CAAC,GAAkB,KAAuB,EAAS,CAAW,GAC9D,CAAC,GAAkB,KAAuB,EAAS,CAAW,GAC9D,IAAe,KAAQ,GACvB,IAAe,KAAQ,GAEvB,IAAmB,GACvB,MAA6B;EACzB,MAEA,MAAS,KAAA,KACZ,EAAoB,CAAQ,GAG7B,IAAe,CAAQ;CACxB,GACA;EAAC;EAAM;EAAU;CAAY,CAC9B,GAEM,IAAmB,GACvB,MAAqB;EACjB,MAEA,MAAS,KAAA,KACZ,EAAoB,CAAQ,GAG7B,IAA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buildImageSources.ts","../../src/image/ui/ImageCropper.tsx","../../src/image/ui/ImagePlaceholder.tsx","../../src/image/ui/ImageRenderer.tsx","../../src/image/lib/getImageSelectionKey.ts","../../src/image/model/useImageSelectionState.ts","../../src/image/lib/getImageCropPreviewStyle.ts","../../src/image/ui/ImageSelectionFields.tsx","../../src/image/ui/ImageSelectionModal.tsx","../../src/image/ui/ImageSelectionPanel.tsx","../../src/image/ui/ImageView.tsx","../../src/image/ui/ImageViewer.tsx"],"sourcesContent":["import { type ImageCandidate } from \"../model/imageTypes\";\n\n/** Собирает валидный srcset из уже разрешённых вызывающим кодом URL вариантов. */\nexport function buildImageSrcSet(candidates: readonly ImageCandidate[]): string {\n\treturn candidates\n\t\t.map((candidate) => (\"width\" in candidate ? `${candidate.src} ${candidate.width}w` : `${candidate.src} ${candidate.density}x`))\n\t\t.join(\", \");\n}\n","import { type ImageSource, type ResponsiveImageSource } from \"../model/imageTypes\";\n\nimport { buildImageSrcSet } from \"./buildImageSrcSet\";\n\n/** Преобразует декларативные наборы кандидатов в готовые source-дескрипторы. */\nexport function buildImageSources(sources: readonly ResponsiveImageSource[] | undefined, defaultSizes?: string): ImageSource[] {\n\treturn (sources ?? [])\n\t\t.map((source) => ({\n\t\t\tsrcSet: buildImageSrcSet(source.candidates),\n\t\t\ttype: source.type,\n\t\t\tsizes: source.sizes ?? defaultSizes\n\t\t}))\n\t\t.filter((source) => source.srcSet.length > 0);\n}\n","import { useCallback, useState } from \"react\";\n\nimport Cropper from \"react-easy-crop\";\n\nimport { type ImageCropArea, type ImageCropperProps, type ImageCropPoint } from \"../model/imageCropTypes\";\n\nconst DEFAULT_CROP: ImageCropPoint = { x: 0, y: 0 };\n\n/**\n * Управляемая или автономная область обрезки изображения.\n * Числовой aspect задаётся вызывающим кодом и не связан с назначением изображения.\n */\nexport function ImageCropper({\n\timage,\n\taspect = 16 / 9,\n\twidth = \"100%\",\n\tclassName,\n\tstyle,\n\tcrop,\n\tdefaultCrop = DEFAULT_CROP,\n\tzoom,\n\tdefaultZoom = 1,\n\tminZoom = 1,\n\tmaxZoom = 3,\n\tzoomSpeed = 0.1,\n\tobjectFit = \"contain\",\n\tdisabled = false,\n\tonCropChange,\n\tonZoomChange,\n\tonCropComplete\n}: ImageCropperProps) {\n\tconst [uncontrolledCrop, setUncontrolledCrop] = useState(defaultCrop);\n\tconst [uncontrolledZoom, setUncontrolledZoom] = useState(defaultZoom);\n\tconst resolvedCrop = crop ?? uncontrolledCrop;\n\tconst resolvedZoom = zoom ?? uncontrolledZoom;\n\n\tconst handleCropChange = useCallback(\n\t\t(nextCrop: ImageCropPoint) => {\n\t\t\tif (disabled) return;\n\n\t\t\tif (crop === undefined) {\n\t\t\t\tsetUncontrolledCrop(nextCrop);\n\t\t\t}\n\n\t\t\tonCropChange?.(nextCrop);\n\t\t},\n\t\t[crop, disabled, onCropChange]\n\t);\n\n\tconst handleZoomChange = useCallback(\n\t\t(nextZoom: number) => {\n\t\t\tif (disabled) return;\n\n\t\t\tif (zoom === undefined) {\n\t\t\t\tsetUncontrolledZoom(nextZoom);\n\t\t\t}\n\n\t\t\tonZoomChange?.(nextZoom);\n\t\t},\n\t\t[disabled, onZoomChange, zoom]\n\t);\n\n\tconst handleCropComplete = useCallback(\n\t\t(croppedAreaPercentages: ImageCropArea, croppedAreaPixels: ImageCropArea) => {\n\t\t\tif (disabled) return;\n\n\t\t\tonCropComplete?.(croppedAreaPixels, croppedAreaPercentages);\n\t\t},\n\t\t[disabled, onCropComplete]\n\t);\n\n\treturn (\n\t\t<div\n\t\t\tclassName={className}\n\t\t\tstyle={{ position: \"relative\", width, aspectRatio: aspect, pointerEvents: disabled ? \"none\" : undefined, ...style }}>\n\t\t\t<Cropper\n\t\t\t\timage={image}\n\t\t\t\tcrop={resolvedCrop}\n\t\t\t\tzoom={resolvedZoom}\n\t\t\t\taspect={aspect}\n\t\t\t\tminZoom={minZoom}\n\t\t\t\tmaxZoom={maxZoom}\n\t\t\t\tzoomSpeed={zoomSpeed}\n\t\t\t\tobjectFit={objectFit}\n\t\t\t\tonCropChange={handleCropChange}\n\t\t\t\tonZoomChange={handleZoomChange}\n\t\t\t\tonCropComplete={handleCropComplete}\n\t\t\t\tcropperProps={{ \"aria-disabled\": disabled || undefined }}\n\t\t\t/>\n\t\t</div>\n\t);\n}\n","export interface ImagePlaceholderProps {\n\twidth?: number | string;\n\theight?: number | string;\n\taspectRatio?: string | \"unset\";\n\tclassName?: string;\n}\n\nexport function ImagePlaceholder({ width = \"100%\", height = \"100%\", aspectRatio = \"16 / 9\", className }: ImagePlaceholderProps) {\n\treturn (\n\t\t<div style={{ width, height, aspectRatio }} className={className}>\n\t\t\t<svg\n\t\t\t\twidth={width}\n\t\t\t\theight={height}\n\t\t\t\tviewBox=\"0 0 200 200\"\n\t\t\t\txmlns=\"http://www.w3.org/2000/svg\"\n\t\t\t\trole=\"img\"\n\t\t\t\tfill=\"none\"\n\t\t\t\trx=\"10\"\n\t\t\t\try=\"10\"\n\t\t\t\tstyle={{ display: \"block\" }}\n\t\t\t\taria-label=\"Изображение недоступно\">\n\t\t\t\t{/* <rect width=\"200\" height=\"200\" fill=\"var(--surface-2)\" rx=\"10\" ry=\"10\" /> */}\n\t\t\t\t<g fill=\"var(--surface-0)\">\n\t\t\t\t\t<rect x=\"40\" y=\"50\" width=\"120\" height=\"100\" rx=\"10\" />\n\n\t\t\t\t\t<circle cx=\"60\" cy=\"70\" r=\"8\" fill=\"var(--surface-2)\" />\n\n\t\t\t\t\t<path d=\"M50 130 L75 100 L100 130 Z\" fill=\"var(--surface-2)\" />\n\t\t\t\t\t<path d=\"M90 130 L120 90 L150 130 Z\" fill=\"var(--surface-2)\" />\n\n\t\t\t\t\t<line x1=\"160\" y1=\"40\" x2=\"40\" y2=\"160\" stroke=\"var(--surface-0)\" strokeWidth=\"15\" strokeLinecap=\"round\" />\n\t\t\t\t\t<line x1=\"160\" y1=\"40\" x2=\"40\" y2=\"160\" stroke=\"var(--surface-2)\" strokeWidth=\"5\" strokeLinecap=\"round\" />\n\t\t\t\t</g>\n\t\t\t</svg>\n\t\t</div>\n\t);\n}\n","import { type CSSProperties, type ImgHTMLAttributes, type ReactNode, useEffect, useRef, useState } from \"react\";\n\nimport { type ImageLayout, type ImageSource } from \"../model/imageTypes\";\n\nimport { ImagePlaceholder } from \"./ImagePlaceholder\";\n\nexport interface ImageRendererProps extends Omit<ImgHTMLAttributes<HTMLImageElement>, \"src\" | \"width\" | \"height\"> {\n\tsrc: string;\n\tsources?: readonly ImageSource[];\n\tlayout?: ImageLayout;\n\talt?: string;\n\trole?: string;\n\tariaLabel?: string;\n\tcaption?: string;\n\tfallback?: ReactNode;\n\tuseFigure?: boolean;\n\taspectRatio?: string | \"unset\";\n\twidth?: CSSProperties[\"width\"];\n\theight?: CSSProperties[\"height\"];\n\tintrinsicWidth?: number;\n\tintrinsicHeight?: number;\n\twrapperStyle?: CSSProperties;\n}\n\n/**\n * Базовый рендер изображения: lazy-появление, placeholder, обработка ошибки и figure/caption.\n * Компонент не знает, как устроено хранилище и какие форматы/размеры доступны.\n */\nexport function ImageRenderer({\n\tsrc,\n\tsources,\n\talt,\n\trole,\n\tariaLabel,\n\tcaption,\n\tfallback,\n\tuseFigure = false,\n\tlayout = \"cover\",\n\twidth = \"100%\",\n\theight = \"100%\",\n\taspectRatio,\n\tintrinsicWidth,\n\tintrinsicHeight,\n\tonLoad,\n\tonError,\n\tstyle,\n\twrapperStyle,\n\t...imgProps\n}: ImageRendererProps) {\n\tconst wrapperRef = useRef<HTMLDivElement | null>(null);\n\tconst [containerWidth, setContainerWidth] = useState(0);\n\tconst [isVisible, setIsVisible] = useState(false);\n\tconst [hasLoaded, setHasLoaded] = useState(false);\n\tconst [hasError, setHasError] = useState(false);\n\n\tuseEffect(() => {\n\t\tif (typeof IntersectionObserver === \"undefined\") {\n\t\t\t// Отложенный fallback сохраняет одинаковый первый render на сервере и в браузере без IntersectionObserver.\n\t\t\tconst timeoutId = window.setTimeout(() => setIsVisible(true), 0);\n\n\t\t\treturn () => window.clearTimeout(timeoutId);\n\t\t}\n\n\t\tconst observer = new IntersectionObserver(\n\t\t\t([entry]) => {\n\t\t\t\tif (entry.isIntersecting) {\n\t\t\t\t\tconst parentWidth = Math.round(entry.boundingClientRect.width);\n\n\t\t\t\t\tsetContainerWidth(parentWidth);\n\t\t\t\t\tsetIsVisible(true);\n\t\t\t\t\tobserver.disconnect();\n\t\t\t\t}\n\t\t\t},\n\t\t\t{ rootMargin: \"100px\", threshold: 0.01 }\n\t\t);\n\n\t\tif (wrapperRef.current) {\n\t\t\tobserver.observe(wrapperRef.current);\n\t\t}\n\n\t\treturn () => observer.disconnect();\n\t}, []);\n\n\tconst isIntrinsic = layout === \"intrinsic\";\n\tconst resolvedHeight = isIntrinsic ? \"auto\" : height;\n\tconst intrinsicAspectRatio = intrinsicWidth && intrinsicHeight ? `${intrinsicWidth} / ${intrinsicHeight}` : undefined;\n\tconst resolvedAspectRatio = isIntrinsic ? (intrinsicAspectRatio ?? aspectRatio ?? \"auto\") : (aspectRatio ?? \"16 / 9\");\n\tconst placeholderHeight = isIntrinsic && resolvedAspectRatio !== \"auto\" && resolvedAspectRatio !== \"unset\" ? \"100%\" : resolvedHeight;\n\tconst sizesAttr = containerWidth ? `${containerWidth}px` : \"100vw\";\n\tconst defaultFallback = <ImagePlaceholder width={width} height={placeholderHeight} aspectRatio={resolvedAspectRatio} />;\n\tconst loadedImageStyle: CSSProperties = isIntrinsic\n\t\t? {\n\t\t\t\t...style,\n\t\t\t\tdisplay: \"block\",\n\t\t\t\twidth: \"100%\",\n\t\t\t\theight: \"auto\",\n\t\t\t\tobjectFit: undefined\n\t\t\t}\n\t\t: {\n\t\t\t\tdisplay: \"block\",\n\t\t\t\twidth: \"100%\",\n\t\t\t\theight: \"100%\",\n\t\t\t\tobjectFit: layout,\n\t\t\t\t...style\n\t\t\t};\n\n\tconst content = (\n\t\t<>\n\t\t\t{!hasLoaded && !hasError && (fallback || defaultFallback)}\n\t\t\t{isVisible && !hasError && (\n\t\t\t\t<picture>\n\t\t\t\t\t{sources?.map((source) => (\n\t\t\t\t\t\t<source\n\t\t\t\t\t\t\tkey={`${source.type ?? \"source\"}-${source.srcSet}`}\n\t\t\t\t\t\t\tsrcSet={source.srcSet}\n\t\t\t\t\t\t\ttype={source.type}\n\t\t\t\t\t\t\tsizes={source.sizes ?? sizesAttr}\n\t\t\t\t\t\t/>\n\t\t\t\t\t))}\n\t\t\t\t\t<img\n\t\t\t\t\t\tsrc={src}\n\t\t\t\t\t\talt={alt}\n\t\t\t\t\t\trole={role}\n\t\t\t\t\t\taria-label={ariaLabel}\n\t\t\t\t\t\tonLoad={(event) => {\n\t\t\t\t\t\t\tsetHasLoaded(true);\n\t\t\t\t\t\t\tonLoad?.(event);\n\t\t\t\t\t\t}}\n\t\t\t\t\t\tonError={(event) => {\n\t\t\t\t\t\t\tsetHasError(true);\n\t\t\t\t\t\t\tonError?.(event);\n\t\t\t\t\t\t}}\n\t\t\t\t\t\tstyle={!hasLoaded ? { display: \"none\" } : loadedImageStyle}\n\t\t\t\t\t\taria-busy={!hasLoaded}\n\t\t\t\t\t\twidth={intrinsicWidth}\n\t\t\t\t\t\theight={intrinsicHeight}\n\t\t\t\t\t\t{...imgProps}\n\t\t\t\t\t/>\n\t\t\t\t</picture>\n\t\t\t)}\n\t\t\t{hasError && defaultFallback}\n\t\t</>\n\t);\n\n\tconst wrapped = (\n\t\t<div ref={wrapperRef} style={{ width, height: resolvedHeight, aspectRatio: resolvedAspectRatio, ...wrapperStyle }}>\n\t\t\t{content}\n\t\t</div>\n\t);\n\n\treturn useFigure ? (\n\t\t<figure className=\"relative\">\n\t\t\t{wrapped}\n\t\t\t{caption && (\n\t\t\t\t<figcaption\n\t\t\t\t\tstyle={{ bottom: 2, right: 2, maxWidth: \"calc(100% - 4px)\" }}\n\t\t\t\t\tclassName=\"absolute paddingInlineMd textRight radiusSm fontSizeSm\">\n\t\t\t\t\t{caption}\n\t\t\t\t</figcaption>\n\t\t\t)}\n\t\t</figure>\n\t) : (\n\t\twrapped\n\t);\n}\n","import { type SelectedImageData } from \"../model/imageSelectionTypes\";\n\n/** Возвращает устойчивый ключ файла внутри текущего набора выбранных изображений. */\nexport function getImageSelectionKey(image: SelectedImageData, index: number): string {\n\treturn `${image.file.meta.name}-${image.file.meta.size}-${image.file.meta.lastModified}-${index}`;\n}\n","import { useCallback, useMemo, useState } from \"react\";\n\nimport { getImageSelectionKey } from \"../lib/getImageSelectionKey\";\n\nimport { type ImageCropArea, type ImageCropPoint } from \"./imageCropTypes\";\nimport {\n\ttype ImageCropperState,\n\ttype ImageSelectionPanelProps,\n\ttype ImageSelectionState,\n\ttype SelectedImageData,\n\ttype SelectedImageFile\n} from \"./imageSelectionTypes\";\n\nconst INITIAL_CROPPER_STATE: ImageCropperState = { crop: { x: 0, y: 0 }, zoom: 1 };\n\n/**\n * Управляет набором изображений в conventional controlled/uncontrolled-режиме.\n * В controlled-режиме каждое изменение сразу передаётся через onChange, а источник истины остаётся у вызывающего кода.\n */\nexport function useImageSelectionState({\n\tvalue,\n\tdefaultValue,\n\tdisabled,\n\tonChange,\n\tonApply\n}: Pick<ImageSelectionPanelProps, \"value\" | \"defaultValue\" | \"disabled\" | \"onChange\" | \"onApply\">): ImageSelectionState {\n\tconst [uncontrolledValue, setUncontrolledValue] = useState<SelectedImageData[]>(defaultValue ?? []);\n\tconst [requestedActiveIndex, setActiveIndex] = useState(0);\n\tconst [cropperStateByImage, setCropperStateByImage] = useState<Record<string, ImageCropperState>>({});\n\tconst resolvedValue = value ?? uncontrolledValue;\n\n\tconst updateValue = useCallback(\n\t\t(updater: (currentValue: SelectedImageData[]) => SelectedImageData[]) => {\n\t\t\tconst nextValue = updater(resolvedValue);\n\n\t\t\tif (value === undefined) {\n\t\t\t\tsetUncontrolledValue(nextValue);\n\t\t\t}\n\n\t\t\tonChange?.(nextValue);\n\t\t},\n\t\t[onChange, resolvedValue, value]\n\t);\n\n\tconst files = useMemo(() => resolvedValue.map((image) => image.file), [resolvedValue]);\n\tconst activeIndex = resolvedValue.length === 0 ? 0 : Math.min(requestedActiveIndex, resolvedValue.length - 1);\n\tconst activeImage = resolvedValue[activeIndex];\n\tconst activeImageKey = activeImage ? getImageSelectionKey(activeImage, activeIndex) : undefined;\n\tconst activeCropperState = activeImageKey ? (cropperStateByImage[activeImageKey] ?? INITIAL_CROPPER_STATE) : INITIAL_CROPPER_STATE;\n\tconst hasSelected = resolvedValue.length > 0;\n\tconst canApply = !disabled && hasSelected && resolvedValue.every((image) => image.alt.trim() && image.crop);\n\n\tconst setFiles = useCallback(\n\t\t(nextFiles: SelectedImageFile[]) => {\n\t\t\tupdateValue((currentValue) =>\n\t\t\t\tnextFiles.map((file) => {\n\t\t\t\t\t// Сохраняем описание и crop для файлов, которые остались в выборе.\n\t\t\t\t\tconst existingImage = currentValue.find((image) => image.file.file === file.file);\n\n\t\t\t\t\treturn existingImage ? { ...existingImage, file } : { file, alt: \"\" };\n\t\t\t\t})\n\t\t\t);\n\t\t},\n\t\t[updateValue]\n\t);\n\n\tconst setActiveAlt = useCallback(\n\t\t(alt: string) => {\n\t\t\tupdateValue((currentValue) => currentValue.map((image, index) => (index === activeIndex ? { ...image, alt } : image)));\n\t\t},\n\t\t[activeIndex, updateValue]\n\t);\n\n\tconst setActiveCrop = useCallback(\n\t\t(crop: ImageCropArea) => {\n\t\t\tupdateValue((currentValue) => currentValue.map((image, index) => (index === activeIndex ? { ...image, crop } : image)));\n\t\t},\n\t\t[activeIndex, updateValue]\n\t);\n\n\tconst setActiveCropperCrop = useCallback(\n\t\t(crop: ImageCropPoint) => {\n\t\t\tif (!activeImageKey) return;\n\n\t\t\tsetCropperStateByImage((currentState) => ({\n\t\t\t\t...currentState,\n\t\t\t\t[activeImageKey]: {\n\t\t\t\t\tcrop,\n\t\t\t\t\tzoom: currentState[activeImageKey]?.zoom ?? 1\n\t\t\t\t}\n\t\t\t}));\n\t\t},\n\t\t[activeImageKey]\n\t);\n\n\tconst setActiveCropperZoom = useCallback(\n\t\t(zoom: number) => {\n\t\t\tif (!activeImageKey) return;\n\n\t\t\tsetCropperStateByImage((currentState) => ({\n\t\t\t\t...currentState,\n\t\t\t\t[activeImageKey]: {\n\t\t\t\t\tcrop: currentState[activeImageKey]?.crop ?? { x: 0, y: 0 },\n\t\t\t\t\tzoom\n\t\t\t\t}\n\t\t\t}));\n\t\t},\n\t\t[activeImageKey]\n\t);\n\n\tconst apply = useCallback(() => {\n\t\tonApply?.(resolvedValue);\n\t}, [onApply, resolvedValue]);\n\n\treturn {\n\t\tvalue: resolvedValue,\n\t\tfiles,\n\t\tactiveIndex,\n\t\tactiveImage,\n\t\tactiveCropperState,\n\t\thasSelected,\n\t\tcanApply,\n\t\tapply,\n\t\tsetFiles,\n\t\tsetActiveIndex,\n\t\tsetActiveAlt,\n\t\tsetActiveCrop,\n\t\tsetActiveCropperCrop,\n\t\tsetActiveCropperZoom\n\t};\n}\n","import { type CSSProperties } from \"react\";\n\nimport { type SelectedImageData } from \"../model/imageSelectionTypes\";\n\nexport type ImageNaturalSize = {\n\twidth: number;\n\theight: number;\n};\n\n/** Масштабирует preview так, чтобы контейнер показывал только выбранную область crop. */\nexport function getImageCropPreviewStyle(image: SelectedImageData, size: ImageNaturalSize | undefined, aspect: number): CSSProperties {\n\tif (!image.crop || !size) {\n\t\treturn {\n\t\t\twidth: \"100%\",\n\t\t\taspectRatio: aspect,\n\t\t\tobjectFit: \"cover\",\n\t\t\tdisplay: \"block\"\n\t\t};\n\t}\n\n\tconst crop = image.crop;\n\n\treturn {\n\t\tposition: \"absolute\",\n\t\tleft: `${-(crop.x / crop.width) * 100}%`,\n\t\ttop: `${-(crop.y / crop.height) * 100}%`,\n\t\twidth: `${(size.width / crop.width) * 100}%`,\n\t\theight: `${(size.height / crop.height) * 100}%`,\n\t\tmaxWidth: \"none\"\n\t};\n}\n","import { useState } from \"react\";\n\nimport { GridContainer } from \"../../grid\";\nimport { InputText } from \"../../input\";\nimport { InputFiles } from \"../../input-files\";\nimport { getImageCropPreviewStyle, type ImageNaturalSize } from \"../lib/getImageCropPreviewStyle\";\nimport { getImageSelectionKey } from \"../lib/getImageSelectionKey\";\nimport { type ImageSelectionPanelProps, type ImageSelectionState } from \"../model/imageSelectionTypes\";\n\nimport { ImageCropper } from \"./ImageCropper\";\n\nconst DEFAULT_ALLOWED_IMAGE_MIME = [\"image/jpeg\", \"image/png\", \"image/webp\", \"image/avif\"] as const;\n\ninterface ImageSelectionFieldsProps extends Pick<\n\tImageSelectionPanelProps,\n\t\"aspect\" | \"disabled\" | \"allowedMime\" | \"maxBytes\" | \"minimumCropWidth\" | \"onReadError\"\n> {\n\tstate: ImageSelectionState;\n}\n\n/** Поля выбора файлов, crop и альтернативного текста для активного изображения. */\nexport function ImageSelectionFields({\n\taspect = 16 / 9,\n\tdisabled,\n\tallowedMime = DEFAULT_ALLOWED_IMAGE_MIME,\n\tmaxBytes,\n\tminimumCropWidth,\n\tonReadError,\n\tstate\n}: ImageSelectionFieldsProps) {\n\tconst area = state.activeImage?.crop;\n\tconst [imageSizes, setImageSizes] = useState<Record<string, ImageNaturalSize>>({});\n\n\treturn (\n\t\t<GridContainer gap=\"md\">\n\t\t\t<InputFiles\n\t\t\t\tlabel=\"Файл изображения\"\n\t\t\t\tallowedMime={allowedMime}\n\t\t\t\tvalue={state.files}\n\t\t\t\tonChange={state.setFiles}\n\t\t\t\tmaxBytes={maxBytes}\n\t\t\t\tdisabled={disabled}\n\t\t\t\tonReadError={onReadError}\n\t\t\t/>\n\n\t\t\t{state.hasSelected && state.activeImage && (\n\t\t\t\t<div>\n\t\t\t\t\t<GridContainer templateColumns=\"repeat(auto-fill, minmax(10em, 1fr))\" gap=\"xs\">\n\t\t\t\t\t\t{state.value.map((image, index) => {\n\t\t\t\t\t\t\tconst imageKey = getImageSelectionKey(image, index);\n\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\tkey={imageKey}\n\t\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t\t\t\t\tonClick={() => state.setActiveIndex(index)}\n\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\tpadding: 0,\n\t\t\t\t\t\t\t\t\t\tborder: index === state.activeIndex ? \"2px solid var(--accent-border)\" : \"2px solid transparent\",\n\t\t\t\t\t\t\t\t\t\tbackground: \"transparent\",\n\t\t\t\t\t\t\t\t\t\tcursor: disabled ? \"default\" : \"pointer\"\n\t\t\t\t\t\t\t\t\t}}>\n\t\t\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\t\tposition: \"relative\",\n\t\t\t\t\t\t\t\t\t\t\tdisplay: \"block\",\n\t\t\t\t\t\t\t\t\t\t\twidth: \"100%\",\n\t\t\t\t\t\t\t\t\t\t\taspectRatio: aspect,\n\t\t\t\t\t\t\t\t\t\t\toverflow: \"hidden\"\n\t\t\t\t\t\t\t\t\t\t}}>\n\t\t\t\t\t\t\t\t\t\t<img\n\t\t\t\t\t\t\t\t\t\t\tsrc={image.file.dataUrl}\n\t\t\t\t\t\t\t\t\t\t\talt={image.alt || `Предпросмотр изображения ${index + 1}`}\n\t\t\t\t\t\t\t\t\t\t\tstyle={getImageCropPreviewStyle(image, imageSizes[imageKey], aspect)}\n\t\t\t\t\t\t\t\t\t\t\tonLoad={(event) => {\n\t\t\t\t\t\t\t\t\t\t\t\tconst target = event.currentTarget;\n\n\t\t\t\t\t\t\t\t\t\t\t\tsetImageSizes((currentSizes) => ({\n\t\t\t\t\t\t\t\t\t\t\t\t\t...currentSizes,\n\t\t\t\t\t\t\t\t\t\t\t\t\t[imageKey]: {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\twidth: target.naturalWidth,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\theight: target.naturalHeight\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t}));\n\t\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t})}\n\t\t\t\t\t</GridContainer>\n\n\t\t\t\t\t<div>\n\t\t\t\t\t\tВыберите область изображения{\" \"}\n\t\t\t\t\t\t{area && (\n\t\t\t\t\t\t\t<code className={minimumCropWidth && area.width < minimumCropWidth ? \"statusError\" : \"statusSuccess\"}>\n\t\t\t\t\t\t\t\t{area.width}x{area.height}\n\t\t\t\t\t\t\t\t{minimumCropWidth && area.width < minimumCropWidth ? \" — недостаточная ширина\" : \"\"}\n\t\t\t\t\t\t\t</code>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</div>\n\n\t\t\t\t\t<ImageCropper\n\t\t\t\t\t\tkey={getImageSelectionKey(state.activeImage, state.activeIndex)}\n\t\t\t\t\t\timage={state.activeImage.file.dataUrl}\n\t\t\t\t\t\tcrop={state.activeCropperState.crop}\n\t\t\t\t\t\tzoom={state.activeCropperState.zoom}\n\t\t\t\t\t\taspect={aspect}\n\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t\tonCropChange={state.setActiveCropperCrop}\n\t\t\t\t\t\tonZoomChange={state.setActiveCropperZoom}\n\t\t\t\t\t\tonCropComplete={state.setActiveCrop}\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t)}\n\n\t\t\t<InputText\n\t\t\t\trequired\n\t\t\t\tdisabled={!state.hasSelected || disabled}\n\t\t\t\tlabel=\"Краткое описание изображения\"\n\t\t\t\tplaceholder=\"\"\n\t\t\t\tvalue={state.activeImage?.alt ?? \"\"}\n\t\t\t\tonChange={state.setActiveAlt}\n\t\t\t/>\n\t\t</GridContainer>\n\t);\n}\n","import { Button } from \"../../button\";\nimport { Modal, ModalContent, ModalFooter } from \"../../modal\";\nimport { type ImageSelectionModalProps } from \"../model/imageSelectionTypes\";\nimport { useImageSelectionState } from \"../model/useImageSelectionState\";\n\nimport { ImageSelectionFields } from \"./ImageSelectionFields\";\n\n/** Модальная форма выбора изображений с необязательным этапом подтверждения. */\nexport function ImageSelectionModal({\n\tdisabled,\n\tisOpen = true,\n\tonClose = () => {},\n\ttitle = \"Загрузка нового изображения\",\n\t...props\n}: ImageSelectionModalProps) {\n\tconst state = useImageSelectionState({ ...props, disabled });\n\n\tif (!props.onApply) {\n\t\treturn (\n\t\t\t<Modal isOpen={isOpen} onClose={onClose} title={title} size=\"xl\">\n\t\t\t\t<ModalContent scrollable>\n\t\t\t\t\t<ImageSelectionFields {...props} disabled={disabled} state={state} />\n\t\t\t\t</ModalContent>\n\t\t\t</Modal>\n\t\t);\n\t}\n\n\treturn (\n\t\t<Modal isOpen={isOpen} onClose={onClose} title={title} size=\"xl\">\n\t\t\t<ModalContent scrollable>\n\t\t\t\t<ImageSelectionFields {...props} disabled={disabled} state={state} />\n\t\t\t</ModalContent>\n\t\t\t<ModalFooter>\n\t\t\t\t<Button disabled={!state.canApply} tone=\"success\" onClick={state.apply}>\n\t\t\t\t\tПрименить\n\t\t\t\t</Button>\n\t\t\t</ModalFooter>\n\t\t</Modal>\n\t);\n}\n","import { Button } from \"../../button\";\nimport { type ImageSelectionActionsData, type ImageSelectionPanelProps } from \"../model/imageSelectionTypes\";\nimport { useImageSelectionState } from \"../model/useImageSelectionState\";\n\nimport { ImageSelectionFields } from \"./ImageSelectionFields\";\n\n/** Встраиваемая форма выбора и обрезки одного или нескольких изображений. */\nexport function ImageSelectionPanel({ disabled, renderActions, ...props }: ImageSelectionPanelProps) {\n\tconst state = useImageSelectionState({ ...props, disabled });\n\tconst actionsData: ImageSelectionActionsData = {\n\t\tvalue: state.value,\n\t\tactiveIndex: state.activeIndex,\n\t\thasSelected: state.hasSelected,\n\t\tcanApply: state.canApply,\n\t\tapply: state.apply\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t<ImageSelectionFields {...props} disabled={disabled} state={state} />\n\t\t\t{renderActions\n\t\t\t\t? renderActions(actionsData)\n\t\t\t\t: props.onApply && (\n\t\t\t\t\t\t<div>\n\t\t\t\t\t\t\t<Button disabled={!state.canApply} tone=\"success\" onClick={state.apply}>\n\t\t\t\t\t\t\t\tПрименить\n\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t)}\n\t\t</>\n\t);\n}\n","import { type ImgHTMLAttributes } from \"react\";\n\nimport { buildImageSources } from \"../lib/buildImageSources\";\nimport { buildImageSrcSet } from \"../lib/buildImageSrcSet\";\nimport { type ResponsiveImageData } from \"../model/imageTypes\";\n\nimport { ImageRenderer, type ImageRendererProps } from \"./ImageRenderer\";\n\nexport interface ImageViewProps\n\textends\n\t\tOmit<ImageRendererProps, \"src\" | \"sources\" | \"alt\" | \"intrinsicWidth\" | \"intrinsicHeight\" | \"srcSet\" | \"sizes\">,\n\t\tPick<ImgHTMLAttributes<HTMLImageElement>, \"sizes\"> {\n\timage: ResponsiveImageData;\n\talt?: string;\n}\n\n/**\n * Собирает picture/srcset из готовых URL и делегирует отображение ImageRenderer.\n * Компонент не формирует имена файлов и не знает о форматах или размерах хранилища.\n */\nexport function ImageView({ image, alt, sizes, aspectRatio, ...props }: ImageViewProps) {\n\tconst sources = buildImageSources(image.sources, sizes);\n\tconst srcSet = image.candidates ? buildImageSrcSet(image.candidates) : undefined;\n\tconst resolvedAspectRatio =\n\t\taspectRatio ?? (image.intrinsicWidth && image.intrinsicHeight ? `${image.intrinsicWidth} / ${image.intrinsicHeight}` : undefined);\n\n\treturn (\n\t\t<ImageRenderer\n\t\t\t{...props}\n\t\t\tsrc={image.src}\n\t\t\tsrcSet={srcSet || undefined}\n\t\t\tsources={sources}\n\t\t\tsizes={sizes}\n\t\t\talt={alt ?? image.alt}\n\t\t\tintrinsicWidth={image.intrinsicWidth}\n\t\t\tintrinsicHeight={image.intrinsicHeight}\n\t\t\taspectRatio={resolvedAspectRatio}\n\t\t/>\n\t);\n}\n","import { lazy, Suspense, useCallback, useState } from \"react\";\n\nimport { type ImageViewerProps } from \"../model/imageViewerTypes\";\n\nimport \"yet-another-react-lightbox/plugins/captions.css\";\nimport \"yet-another-react-lightbox/plugins/counter.css\";\nimport \"yet-another-react-lightbox/plugins/thumbnails.css\";\nimport \"yet-another-react-lightbox/styles.css\";\n\nconst LazyImageViewerRuntime = lazy(() => import(\"./ImageViewerRuntime\"));\n\n/**\n * Управляемый полноэкранный viewer с ленивой границей vendor runtime.\n * YARL и его плагины загружаются только при первом открытии, а после mount runtime остаётся в React-дереве,\n * чтобы закрытие успело завершить анимацию, снять inert и вернуть focus исходному trigger.\n */\nexport function ImageViewer(props: ImageViewerProps) {\n\tconst [runtimeMounted, setRuntimeMounted] = useState(false);\n\tconst handleRuntimeMounted = useCallback(() => setRuntimeMounted(true), []);\n\tconst canRenderRuntime = typeof document !== \"undefined\" && (props.open || runtimeMounted);\n\n\tif (!canRenderRuntime) return null;\n\n\treturn (\n\t\t<Suspense fallback={null}>\n\t\t\t<LazyImageViewerRuntime {...props} onRuntimeMounted={handleRuntimeMounted} />\n\t\t</Suspense>\n\t);\n}\n"],"mappings":";;;;;;;;;AAGA,SAAgB,EAAiB,GAA+C;CAC/E,OAAO,EACL,KAAK,MAAe,WAAW,IAAY,GAAG,EAAU,IAAI,GAAG,EAAU,MAAM,KAAK,GAAG,EAAU,IAAI,GAAG,EAAU,QAAQ,EAAG,CAAC,CAC9H,KAAK,IAAI;AACZ;;;ACFA,SAAgB,EAAkB,GAAuD,GAAsC;CAC9H,QAAQ,KAAW,CAAC,EAAA,CAClB,KAAK,OAAY;EACjB,QAAQ,EAAiB,EAAO,UAAU;EAC1C,MAAM,EAAO;EACb,OAAO,EAAO,SAAS;CACxB,EAAE,CAAC,CACF,QAAQ,MAAW,EAAO,OAAO,SAAS,CAAC;AAC9C;;;ACPA,IAAM,IAA+B;CAAE,GAAG;CAAG,GAAG;AAAE;AAMlD,SAAgB,EAAa,EAC5B,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,KAAO,EAAM;EAClB,gBAAgB,EAAM;EACtB,iBAAiB,EAAM;EACvB,aAAa;CACb,CAAA;AAEH;;;AC9BA,IAAM,IAAyB,QAAW,OAAO,2CAAuB;AAOxE,SAAgB,EAAY,GAAyB;CACpD,IAAM,CAAC,GAAgB,KAAqB,EAAS,EAAK,GACpD,IAAuB,QAAkB,EAAkB,EAAI,GAAG,CAAC,CAAC;CAK1E,OAJyB,OAAO,WAAa,QAAgB,EAAM,QAAQ,KAK1E,kBAAC,GAAD;EAAU,UAAU;EACnB,UAAA,kBAAC,GAAD;GAAwB,GAAI;GAAO,kBAAkB;EAAuB,CAAA;CACnE,CAAA,IALmB;AAO/B"}
@@ -1,2 +1,2 @@
1
- import { a as e, c as t, d as n, i as r, l as i, n as a, o, r as s, s as c, t as l, u } from "../chunks/input-D1jOxm0t.js";
1
+ import { a as e, c as t, d as n, i as r, l as i, n as a, o, r as s, s as c, t as l, u } from "../chunks/input-DSPKgiCK.js";
2
2
  export { a as Input, s as InputClearButton, r as InputControl, l as InputErrorComponent, e as InputLoadingFrame, o as InputNumber, c as InputText, t as InputUI, i as InputUIFrame, u as InputUILoading, n as useInputFieldIds };
@@ -1,5 +1,5 @@
1
- import { t as e } from "../chunks/ui.module-BsDio9A3.js";
2
- import { c as t, d as n, i as r, r as i } from "../chunks/input-D1jOxm0t.js";
1
+ import { t as e } from "../chunks/ui.module-oRwY3Zli.js";
2
+ import { c as t, d as n, i as r, r as i } from "../chunks/input-DSPKgiCK.js";
3
3
  import { useCallback as a, useMemo as o, useRef as s, useState as c } from "react";
4
4
  import { cn as l } from "@ryuzaki13/react-foundation-lib/utils";
5
5
  import { jsx as u } from "react/jsx-runtime";
@@ -1,5 +1,5 @@
1
- import { t as e } from "../chunks/ui.module-BsDio9A3.js";
2
- import { c as t, d as n, i as r, r as i } from "../chunks/input-D1jOxm0t.js";
1
+ import { t as e } from "../chunks/ui.module-oRwY3Zli.js";
2
+ import { c as t, d as n, i as r, r as i } from "../chunks/input-DSPKgiCK.js";
3
3
  import { useCallback as a, useRef as o } from "react";
4
4
  import { cn as s, handleKeyboardActivation as c } from "@ryuzaki13/react-foundation-lib/utils";
5
5
  import { jsx as l, jsxs as u } from "react/jsx-runtime";
@@ -1,2 +1,2 @@
1
- import { n as e, t } from "../chunks/input-files-CDGpJaUm.js";
1
+ import { n as e, t } from "../chunks/input-files-tIS17-zX.js";
2
2
  export { t as InputFiles, e as InputFilesList };
@@ -1,5 +1,5 @@
1
- import { t as e } from "../chunks/ui.module-BsDio9A3.js";
2
- import { c as t, d as n, i as r, r as i } from "../chunks/input-D1jOxm0t.js";
1
+ import { t as e } from "../chunks/ui.module-oRwY3Zli.js";
2
+ import { c as t, d as n, i as r, r as i } from "../chunks/input-DSPKgiCK.js";
3
3
  import { useCallback as a, useMemo as o, useRef as s } from "react";
4
4
  import { cn as c, handleKeyboardActivation as l } from "@ryuzaki13/react-foundation-lib/utils";
5
5
  import { jsx as u, jsxs as d } from "react/jsx-runtime";
@@ -1,2 +1,2 @@
1
- import { t as e } from "../chunks/input-search-Ci1ubGox.js";
1
+ import { t as e } from "../chunks/input-search-Cat4c7SM.js";
2
2
  export { e as InputSearch };
@@ -1,5 +1,5 @@
1
1
  import { CustomOptionButton as e, Option as t } from "../option/index.js";
2
- import { f as n, i as r, s as i, t as a, v as o } from "../chunks/picker-DZ4-1BvK.js";
2
+ import { f as n, i as r, s as i, t as a, v as o } from "../chunks/picker-lvm82d0A.js";
3
3
  import { useRef as s, useState as c } from "react";
4
4
  import { cn as l } from "@ryuzaki13/react-foundation-lib/utils";
5
5
  import { Fragment as u, jsx as d, jsxs as f } from "react/jsx-runtime";
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/layout-picker/lib/layout.ts","../../src/layout-picker/lib/presets.ts","../../src/layout-picker/ui/LayoutPicker.module.scss","../../src/layout-picker/ui/LayoutPicker.tsx"],"sourcesContent":["import { type CSSProperties } from \"react\";\n\nimport { type LayoutPickerPreset, type LayoutPickerPresetCell } from \"./types\";\n\n/**\n * Возвращает CSS Grid-стиль для схематичного layout-пресета.\n */\nexport function getLayoutStyle(preset: LayoutPickerPreset, rowMinHeightInEm?: number): CSSProperties {\n\treturn {\n\t\tgridTemplateColumns: `repeat(${preset.columns}, minmax(0, 1fr))`,\n\t\tgridTemplateRows: `repeat(${preset.rows}, minmax(${rowMinHeightInEm ?? 0}em, 1fr))`\n\t};\n}\n\n/**\n * Возвращает позиционирование ячейки внутри CSS Grid.\n */\nexport function getLayoutCellStyle(cell: LayoutPickerPresetCell): CSSProperties {\n\treturn {\n\t\tgridColumn: `${cell.column} / span ${cell.columnSpan ?? 1}`,\n\t\tgridRow: `${cell.row} / span ${cell.rowSpan ?? 1}`\n\t};\n}\n","import { type LayoutPickerPreset } from \"./types\";\n\n/**\n * Базовый набор layout-пресетов для первого среза выбора схемы.\n *\n * id формата:\n * - \"2x3\" — 2 строки, 3 колонки\n * - \"2x2-l\" — 2x2 с большой ячейкой слева\n * - \"3x2-b\" — 3x2 с широкой нижней ячейкой\n */\nexport const DEFAULT_LAYOUT_PICKER_PRESETS = [\n\t{\n\t\tid: \"1x1\",\n\t\tlabel: \"1x1\",\n\t\tcolumns: 1,\n\t\trows: 1,\n\t\tcells: [{ id: \"c11\", row: 1, column: 1 }]\n\t},\n\t{\n\t\tid: \"1x2\",\n\t\tlabel: \"1x2\",\n\t\tcolumns: 2,\n\t\trows: 1,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"1x3\",\n\t\tlabel: \"1x3\",\n\t\tcolumns: 3,\n\t\trows: 1,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x1\",\n\t\tlabel: \"2x1\",\n\t\tcolumns: 1,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2\",\n\t\tlabel: \"2x2\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x3\",\n\t\tlabel: \"2x3\",\n\t\tcolumns: 3,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x1\",\n\t\tlabel: \"3x1\",\n\t\tcolumns: 1,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x2\",\n\t\tlabel: \"3x2\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3\",\n\t\tlabel: \"3x3\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x1\",\n\t\tlabel: \"4x1\",\n\t\tcolumns: 1,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x2\",\n\t\tlabel: \"4x2\",\n\t\tcolumns: 2,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x3\",\n\t\tlabel: \"4x3\",\n\t\tcolumns: 3,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 },\n\t\t\t{ id: \"c43\", row: 4, column: 3 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"2x2-l\",\n\t\tlabel: \"Большая слева + две справа\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"left\", row: 1, column: 1, rowSpan: 2 },\n\t\t\t{ id: \"rt\", row: 1, column: 2 },\n\t\t\t{ id: \"rb\", row: 2, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2-r\",\n\t\tlabel: \"Две слева + большая справа\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"lt\", row: 1, column: 1 },\n\t\t\t{ id: \"lb\", row: 2, column: 1 },\n\t\t\t{ id: \"right\", row: 1, column: 2, rowSpan: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2-t\",\n\t\tlabel: \"Широкая сверху + две снизу\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"bl\", row: 2, column: 1 },\n\t\t\t{ id: \"br\", row: 2, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2-b\",\n\t\tlabel: \"Две сверху + широкая снизу\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"tl\", row: 1, column: 1 },\n\t\t\t{ id: \"tr\", row: 1, column: 2 },\n\t\t\t{ id: \"bottom\", row: 2, column: 1, columnSpan: 2 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"3x2-t\",\n\t\tlabel: \"Широкая сверху + 2x2\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x2-b\",\n\t\tlabel: \"2x2 + широкая снизу\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"bottom\", row: 3, column: 1, columnSpan: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x2-m\",\n\t\tlabel: \"Широкая по центру\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"tl\", row: 1, column: 1 },\n\t\t\t{ id: \"tr\", row: 1, column: 2 },\n\t\t\t{ id: \"middle\", row: 2, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"bl\", row: 3, column: 1 },\n\t\t\t{ id: \"br\", row: 3, column: 2 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"3x3-l\",\n\t\tlabel: \"Большая слева + 2x3 справа\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"left\", row: 1, column: 1, rowSpan: 3 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3-r\",\n\t\tlabel: \"2x3 слева + большая справа\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"right\", row: 1, column: 3, rowSpan: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3-t\",\n\t\tlabel: \"Широкая сверху + 2x3\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3-b\",\n\t\tlabel: \"2x3 + широкая снизу\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"bottom\", row: 3, column: 1, columnSpan: 3 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"4x2-t\",\n\t\tlabel: \"Широкая сверху + 3x2\",\n\t\tcolumns: 2,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x2-b\",\n\t\tlabel: \"3x2 + широкая снизу\",\n\t\tcolumns: 2,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"bottom\", row: 4, column: 1, columnSpan: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x3-t\",\n\t\tlabel: \"Широкая сверху + 3x3\",\n\t\tcolumns: 3,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 },\n\t\t\t{ id: \"c43\", row: 4, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x3-b\",\n\t\tlabel: \"3x3 + широкая снизу\",\n\t\tcolumns: 3,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 },\n\t\t\t{ id: \"bottom\", row: 4, column: 1, columnSpan: 3 }\n\t\t]\n\t}\n] as const satisfies readonly LayoutPickerPreset[];\n\nexport type DefaultLayoutPickerPresetId = (typeof DEFAULT_LAYOUT_PICKER_PRESETS)[number][\"id\"];\n\nexport function getDefaultLayoutPickerPresetId(): DefaultLayoutPickerPresetId {\n\treturn DEFAULT_LAYOUT_PICKER_PRESETS[0].id;\n}\n\n/** Возвращает layout-пресет по id с fallback на дефолт chart-ракурса. */\nexport function resolveLayoutPreset(layoutId: string | undefined): LayoutPickerPreset {\n\treturn DEFAULT_LAYOUT_PICKER_PRESETS.find((preset) => preset.id === layoutId) ?? DEFAULT_LAYOUT_PICKER_PRESETS[0];\n}\n\nexport function resolveLayoutCellCount(layoutId: string): number {\n\treturn DEFAULT_LAYOUT_PICKER_PRESETS.find((preset) => preset.id === layoutId)?.cells.length ?? 1;\n}\n","@use \"@/styles/mixins\" as *;\n\n.triggerText {\n\tmin-width: 0;\n\tflex: 1 1 auto;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n}\n\n.popup {\n\twidth: min(calc(100vw - var(--space-lg) * 2), 44em);\n\tmax-height: min(75vh, 34em);\n}\n\n.popupLayout {\n\tmax-height: inherit;\n}\n\n.popupBody {\n\toverflow: auto;\n\tpadding: var(--space-xs);\n}\n\n.options {\n\tdisplay: grid;\n\tgrid-template-columns: repeat(auto-fit, minmax(min(100%, 5em), 1fr));\n\tgap: var(--space-sm);\n}\n\n.option {\n\tposition: relative;\n\tpadding: var(--space-sm);\n\t// border: var(--border);\n\tborder-radius: var(--radius-sm);\n\t// background-color: var(--surface-1);\n\ttransition:\n\t\tbackground-color var(--transition-fast) ease,\n\t\tborder-color var(--transition-fast) ease,\n\t\tcolor var(--transition-fast) ease;\n\n\t@include hover(true) {\n\t\tbackground-color: var(--surface-2);\n\t\tborder-color: var(--border-2);\n\t}\n\n\t&:disabled {\n\t\tcursor: default;\n\t\topacity: var(--disabled-opacity);\n\t}\n}\n\n.option[data-selected] {\n\tborder-color: var(--border-1);\n\tbackground-color: var(--surface-1);\n\n\t.previewCell {\n\t\tbackground-color: var(--surface-accent);\n\t\tborder: var(--border-width) solid var(--border-accent);\n\t}\n}\n\n.optionPreviewWrap {\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n.preview,\n.previewPlaceholder {\n\t--layout-picker-preview-size: 3.5em;\n\n\twidth: var(--layout-picker-preview-size);\n\theight: calc(var(--layout-picker-preview-size) * 0.72);\n\tflex: 0 0 auto;\n}\n\n.preview {\n\tdisplay: grid;\n\tgap: calc(var(--border-width) * 2);\n}\n\n.previewCompact,\n.previewPlaceholder {\n\t--layout-picker-preview-size: 1.75rem;\n}\n\n.previewCell {\n\tmin-width: 0;\n\tmin-height: 0;\n\tborder-radius: var(--radius-xs);\n\tbackground-color: var(--surface-1);\n\tborder: var(--border-width) solid var(--border-1);\n}\n\n.previewCompact {\n\t.previewCell {\n\t\tbackground-color: var(--status-brand-fill);\n\t\tborder: none;\n\t}\n}\n","import { useRef, useState } from \"react\";\n\nimport { type Placement } from \"@floating-ui/react\";\nimport { cn } from \"@ryuzaki13/react-foundation-lib/utils\";\n\nimport { CustomOptionButton, Option } from \"../../option\";\nimport { PickerField, PickerPopup, PickerTrigger, usePickerFloatingListbox, usePickerTriggerController } from \"../../picker\";\nimport { type UiBaseProps } from \"../../types\";\nimport { DEFAULT_LAYOUT_PICKER_PRESETS, getLayoutCellStyle, getLayoutStyle, type LayoutPickerPreset } from \"../lib\";\n\nimport styles from \"./LayoutPicker.module.scss\";\n\nexport interface LayoutPickerProps extends UiBaseProps<string> {\n\tid?: string;\n\tpresets?: readonly LayoutPickerPreset[];\n\tgetPresetDisabled?: (preset: LayoutPickerPreset) => boolean;\n\t/**\n\t * Показывает рядом с превью переданный текст `placeholder`.\n\t * По умолчанию текст скрыт, поэтому trigger отображает только иконку раскладки.\n\t */\n\tshowPlaceholder?: boolean;\n\tariaLabel?: string;\n\tclassName?: string;\n\ttriggerClassName?: string;\n\tpopupClassName?: string;\n\tplacement?: Placement;\n}\n\nconst DEFAULT_PLACEHOLDER = \"Выберите раскладку\";\n\nfunction LayoutPresetPreview({ preset, compact = false }: { preset: LayoutPickerPreset; compact?: boolean }) {\n\treturn (\n\t\t<span\n\t\t\tclassName={cn(styles.preview, compact && styles.previewCompact)}\n\t\t\tstyle={getLayoutStyle(preset)}\n\t\t\taria-hidden=\"true\"\n\t\t\tdata-ui=\"layout-picker-preview\">\n\t\t\t{preset.cells.map((cell) => (\n\t\t\t\t<span key={`${preset.id}:${cell.id}`} className={styles.previewCell} style={getLayoutCellStyle(cell)} />\n\t\t\t))}\n\t\t</span>\n\t);\n}\n\n/**\n * Контрол выбора layout-пресета. Не хранит бизнес-логику содержимого ячеек.\n */\nexport function LayoutPicker({\n\tid,\n\tlabel,\n\tdescription,\n\tvalue,\n\tonChange,\n\tpresets = DEFAULT_LAYOUT_PICKER_PRESETS,\n\tdisabled,\n\tgetPresetDisabled,\n\tplaceholder = DEFAULT_PLACEHOLDER,\n\tshowPlaceholder = false,\n\tsize,\n\tariaLabel,\n\tclassName,\n\ttriggerClassName,\n\tpopupClassName,\n\tplacement = \"bottom-start\"\n}: LayoutPickerProps) {\n\tconst inputRef = useRef<HTMLInputElement | null>(null);\n\tconst [open, setOpen] = useState(false);\n\tconst selectedIndex = presets.findIndex((preset) => preset.id === value);\n\tconst selectedPreset = selectedIndex >= 0 ? presets[selectedIndex] : undefined;\n\tconst triggerLabel = selectedPreset?.label ?? placeholder;\n\tconst {\n\t\tactiveIndex,\n\t\tcontext,\n\t\tfloatingStyles,\n\t\tgetFloatingProps,\n\t\tsetReference,\n\t\tsetFloating,\n\t\tsetOptionRef,\n\t\tclose,\n\t\topenList,\n\t\ttoggleOpen,\n\t\tselectOption,\n\t\tselectActiveOption,\n\t\thandleReferenceKeyDown,\n\t\thandleFloatingKeyDown,\n\t\tgetOptionId,\n\t\tgetActiveOptionId\n\t} = usePickerFloatingListbox({\n\t\toptions: presets,\n\t\tselectedIndex,\n\t\topen,\n\t\tonOpenChange: setOpen,\n\t\tgetOptionDisabled: getPresetDisabled,\n\t\tonSelect: (preset) => onChange(preset.id),\n\t\tdisabled,\n\t\tplacement,\n\t\ttriggerMode: \"display\"\n\t});\n\tconst triggerController = usePickerTriggerController({\n\t\tmode: \"display\",\n\t\topen,\n\t\tcurrentQuery: \"\",\n\t\thasDisplayValue: selectedPreset !== undefined,\n\t\tinputRef,\n\t\topenList,\n\t\tclose,\n\t\ttoggleOpen\n\t});\n\tconst setInputNode = (node: HTMLInputElement | null) => {\n\t\tinputRef.current = node;\n\t};\n\n\treturn (\n\t\t<PickerField id={id} label={label} description={description} disabled={disabled} size={size} className={className}>\n\t\t\t{({ controlId, labelId, describedBy }) => {\n\t\t\t\tconst listId = `${controlId}-listbox`;\n\n\t\t\t\treturn (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<PickerTrigger\n\t\t\t\t\t\t\tref={setInputNode}\n\t\t\t\t\t\t\trootRef={setReference}\n\t\t\t\t\t\t\tid={controlId}\n\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t\t\topen={open}\n\t\t\t\t\t\t\toptionCount={presets.length}\n\t\t\t\t\t\t\tlabel={label}\n\t\t\t\t\t\t\tplaceholder={placeholder}\n\t\t\t\t\t\t\treadOnly\n\t\t\t\t\t\t\tautoComplete=\"off\"\n\t\t\t\t\t\t\trole=\"combobox\"\n\t\t\t\t\t\t\tvalue={triggerLabel}\n\t\t\t\t\t\t\tselectedValue={\n\t\t\t\t\t\t\t\tselectedPreset ? (\n\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t<LayoutPresetPreview preset={selectedPreset} compact />\n\t\t\t\t\t\t\t\t\t\t{showPlaceholder ? (\n\t\t\t\t\t\t\t\t\t\t\t<span className={styles.triggerText} data-ui=\"layout-picker-selected-label\">\n\t\t\t\t\t\t\t\t\t\t\t\t{selectedPreset.label}\n\t\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t) : undefined\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\thasSelection={selectedPreset !== undefined}\n\t\t\t\t\t\t\tshowSelectedValue={selectedPreset !== undefined}\n\t\t\t\t\t\t\tonToggleMouseDown={triggerController.handleToggleMouseDown}\n\t\t\t\t\t\t\tonToggleClick={triggerController.handleToggleClick}\n\t\t\t\t\t\t\topenAriaLabel=\"Открыть список layout\"\n\t\t\t\t\t\t\tcloseAriaLabel=\"Закрыть список layout\"\n\t\t\t\t\t\t\taria-haspopup=\"listbox\"\n\t\t\t\t\t\t\taria-expanded={open}\n\t\t\t\t\t\t\taria-controls={open ? listId : undefined}\n\t\t\t\t\t\t\taria-labelledby={labelId}\n\t\t\t\t\t\t\taria-describedby={describedBy}\n\t\t\t\t\t\t\taria-autocomplete=\"none\"\n\t\t\t\t\t\t\taria-activedescendant={open ? getActiveOptionId(listId) : undefined}\n\t\t\t\t\t\t\taria-label={!labelId ? (ariaLabel ?? `Выбрать layout. Текущее значение: ${triggerLabel}`) : undefined}\n\t\t\t\t\t\t\tdata-ui=\"layout-picker-trigger\"\n\t\t\t\t\t\t\trootClassName={triggerClassName}\n\t\t\t\t\t\t\tonClick={triggerController.handleTriggerClick}\n\t\t\t\t\t\t\tonFocus={(event) => {\n\t\t\t\t\t\t\t\ttriggerController.handleTriggerFocus(event.currentTarget);\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tonKeyDown={(event) => {\n\t\t\t\t\t\t\t\thandleReferenceKeyDown(event);\n\n\t\t\t\t\t\t\t\tif (event.defaultPrevented) {\n\t\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\ttriggerController.handleTriggerKeyDown({\n\t\t\t\t\t\t\t\t\tevent,\n\t\t\t\t\t\t\t\t\tonActivateWhenOpen: selectActiveOption,\n\t\t\t\t\t\t\t\t\tenableSpaceActivation: true\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t<PickerPopup\n\t\t\t\t\t\t\topen={open}\n\t\t\t\t\t\t\tcontext={context}\n\t\t\t\t\t\t\tfloatingStyles={floatingStyles}\n\t\t\t\t\t\t\tlistId={listId}\n\t\t\t\t\t\t\tlabelId={labelId}\n\t\t\t\t\t\t\tdescriptionId={describedBy}\n\t\t\t\t\t\t\tactiveOptionId={getActiveOptionId(listId)}\n\t\t\t\t\t\t\tsetFloating={setFloating}\n\t\t\t\t\t\t\tgetFloatingProps={getFloatingProps}\n\t\t\t\t\t\t\tonKeyDown={handleFloatingKeyDown}\n\t\t\t\t\t\t\tclassName={cn(styles.popup, popupClassName)}\n\t\t\t\t\t\t\tlayoutClassName={styles.popupLayout}\n\t\t\t\t\t\t\tbodyClassName={styles.popupBody}>\n\t\t\t\t\t\t\t<div className={styles.options}>\n\t\t\t\t\t\t\t\t{presets.map((preset, index) => {\n\t\t\t\t\t\t\t\t\tconst selected = index === selectedIndex;\n\t\t\t\t\t\t\t\t\tconst active = index === activeIndex;\n\t\t\t\t\t\t\t\t\tconst presetDisabled = getPresetDisabled?.(preset) ?? false;\n\t\t\t\t\t\t\t\t\tconst optionId = getOptionId(listId, index);\n\n\t\t\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\t\t<Option\n\t\t\t\t\t\t\t\t\t\t\tkey={preset.id}\n\t\t\t\t\t\t\t\t\t\t\tid={optionId}\n\t\t\t\t\t\t\t\t\t\t\tref={(node) => setOptionRef(index, node)}\n\t\t\t\t\t\t\t\t\t\t\trole=\"option\"\n\t\t\t\t\t\t\t\t\t\t\taria-selected={selected}\n\t\t\t\t\t\t\t\t\t\t\taria-disabled={presetDisabled || undefined}\n\t\t\t\t\t\t\t\t\t\t\taria-label={preset.description ? `${preset.label}. ${preset.description}` : preset.label}\n\t\t\t\t\t\t\t\t\t\t\tclassName={styles.option}\n\t\t\t\t\t\t\t\t\t\t\tactive={active}\n\t\t\t\t\t\t\t\t\t\t\tselected={selected}\n\t\t\t\t\t\t\t\t\t\t\tdisabled={presetDisabled}\n\t\t\t\t\t\t\t\t\t\t\tdata-ui=\"layout-picker-option\"\n\t\t\t\t\t\t\t\t\t\t\tdata-selected={selected || undefined}>\n\t\t\t\t\t\t\t\t\t\t\t<CustomOptionButton\n\t\t\t\t\t\t\t\t\t\t\t\ttabIndex={-1}\n\t\t\t\t\t\t\t\t\t\t\t\tdisabled={presetDisabled}\n\n\t\t\t\t\t\t\t\t\t\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() => selectOption(preset)}>\n\t\t\t\t\t\t\t\t\t\t\t\t<span className={styles.optionPreviewWrap}>\n\t\t\t\t\t\t\t\t\t\t\t\t\t<LayoutPresetPreview preset={preset} />\n\t\t\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t\t</CustomOptionButton>\n\t\t\t\t\t\t\t\t\t\t</Option>\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t})}\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</PickerPopup>\n\t\t\t\t\t</>\n\t\t\t\t);\n\t\t\t}}\n\t\t</PickerField>\n\t);\n}\n"],"mappings":";;;;;;AAOA,SAAgB,EAAe,GAA4B,GAA0C;CACpG,OAAO;EACN,qBAAqB,UAAU,EAAO,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ACK;IAClB,WAAW;IACX,WAAW,EAAG,EAAO,OAAO,EAAc;IAC1C,iBAAiB,EAAO;IACxB,eAAe,EAAO;IACtB,UAAA,kBAAC,OAAD;KAAK,WAAW,EAAO;KACrB,UAAA,EAAQ,KAAK,GAAQ,MAAU;MAC/B,IAAM,IAAW,MAAU,GACrB,IAAS,MAAU,GACnB,IAAiB,IAAoB,CAAM,KAAK,IAChD,IAAW,EAAY,GAAQ,CAAK;MAE1C,OACC,kBAAC,GAAD;OAEC,IAAI;OACJ,MAAM,MAAS,EAAa,GAAO,CAAI;OACvC,MAAK;OACL,iBAAe;OACf,iBAAe,KAAkB,KAAA;OACjC,cAAY,EAAO,cAAc,GAAG,EAAO,MAAM,IAAI,EAAO,gBAAgB,EAAO;OACnF,WAAW,EAAO;OACV;OACE;OACV,UAAU;OACV,WAAQ;OACR,iBAAe,KAAY,KAAA;OAC3B,UAAA,kBAAC,GAAD;QACC,UAAU;QACV,UAAU;QAEV,cAAc,MAAU,EAAM,eAAe;QAC7C,eAAe,EAAa,CAAM;QAClC,UAAA,kBAAC,QAAD;SAAM,WAAW,EAAO;SACvB,UAAA,kBAAC,GAAD,EAA6B,UAAS,CAAA;QACjC,CAAA;OACa,CAAA;MACb,GAvBF,EAAO,EAuBL;KAEV,CAAC;IACG,CAAA;GACO,CAAA,CACZ,EAAA,CAAA;EAEJ;CACY,CAAA;AAEf"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/layout-picker/lib/layout.ts","../../src/layout-picker/lib/presets.ts","../../src/layout-picker/ui/LayoutPicker.module.scss","../../src/layout-picker/ui/LayoutPicker.tsx"],"sourcesContent":["import { type CSSProperties } from \"react\";\n\nimport { type LayoutPickerPreset, type LayoutPickerPresetCell } from \"./types\";\n\n/**\n * Возвращает CSS Grid-стиль для схематичного layout-пресета.\n */\nexport function getLayoutStyle(preset: LayoutPickerPreset, rowMinHeightInEm?: number): CSSProperties {\n\treturn {\n\t\tgridTemplateColumns: `repeat(${preset.columns}, minmax(0, 1fr))`,\n\t\tgridTemplateRows: `repeat(${preset.rows}, minmax(${rowMinHeightInEm ?? 0}em, 1fr))`\n\t};\n}\n\n/**\n * Возвращает позиционирование ячейки внутри CSS Grid.\n */\nexport function getLayoutCellStyle(cell: LayoutPickerPresetCell): CSSProperties {\n\treturn {\n\t\tgridColumn: `${cell.column} / span ${cell.columnSpan ?? 1}`,\n\t\tgridRow: `${cell.row} / span ${cell.rowSpan ?? 1}`\n\t};\n}\n","import { type LayoutPickerPreset } from \"./types\";\n\n/**\n * Базовый набор layout-пресетов для первого среза выбора схемы.\n *\n * id формата:\n * - \"2x3\" — 2 строки, 3 колонки\n * - \"2x2-l\" — 2x2 с большой ячейкой слева\n * - \"3x2-b\" — 3x2 с широкой нижней ячейкой\n */\nexport const DEFAULT_LAYOUT_PICKER_PRESETS = [\n\t{\n\t\tid: \"1x1\",\n\t\tlabel: \"1x1\",\n\t\tcolumns: 1,\n\t\trows: 1,\n\t\tcells: [{ id: \"c11\", row: 1, column: 1 }]\n\t},\n\t{\n\t\tid: \"1x2\",\n\t\tlabel: \"1x2\",\n\t\tcolumns: 2,\n\t\trows: 1,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"1x3\",\n\t\tlabel: \"1x3\",\n\t\tcolumns: 3,\n\t\trows: 1,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x1\",\n\t\tlabel: \"2x1\",\n\t\tcolumns: 1,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2\",\n\t\tlabel: \"2x2\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x3\",\n\t\tlabel: \"2x3\",\n\t\tcolumns: 3,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x1\",\n\t\tlabel: \"3x1\",\n\t\tcolumns: 1,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x2\",\n\t\tlabel: \"3x2\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3\",\n\t\tlabel: \"3x3\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x1\",\n\t\tlabel: \"4x1\",\n\t\tcolumns: 1,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x2\",\n\t\tlabel: \"4x2\",\n\t\tcolumns: 2,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x3\",\n\t\tlabel: \"4x3\",\n\t\tcolumns: 3,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 },\n\t\t\t{ id: \"c43\", row: 4, column: 3 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"2x2-l\",\n\t\tlabel: \"Большая слева + две справа\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"left\", row: 1, column: 1, rowSpan: 2 },\n\t\t\t{ id: \"rt\", row: 1, column: 2 },\n\t\t\t{ id: \"rb\", row: 2, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2-r\",\n\t\tlabel: \"Две слева + большая справа\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"lt\", row: 1, column: 1 },\n\t\t\t{ id: \"lb\", row: 2, column: 1 },\n\t\t\t{ id: \"right\", row: 1, column: 2, rowSpan: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2-t\",\n\t\tlabel: \"Широкая сверху + две снизу\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"bl\", row: 2, column: 1 },\n\t\t\t{ id: \"br\", row: 2, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"2x2-b\",\n\t\tlabel: \"Две сверху + широкая снизу\",\n\t\tcolumns: 2,\n\t\trows: 2,\n\t\tcells: [\n\t\t\t{ id: \"tl\", row: 1, column: 1 },\n\t\t\t{ id: \"tr\", row: 1, column: 2 },\n\t\t\t{ id: \"bottom\", row: 2, column: 1, columnSpan: 2 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"3x2-t\",\n\t\tlabel: \"Широкая сверху + 2x2\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x2-b\",\n\t\tlabel: \"2x2 + широкая снизу\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"bottom\", row: 3, column: 1, columnSpan: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x2-m\",\n\t\tlabel: \"Широкая по центру\",\n\t\tcolumns: 2,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"tl\", row: 1, column: 1 },\n\t\t\t{ id: \"tr\", row: 1, column: 2 },\n\t\t\t{ id: \"middle\", row: 2, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"bl\", row: 3, column: 1 },\n\t\t\t{ id: \"br\", row: 3, column: 2 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"3x3-l\",\n\t\tlabel: \"Большая слева + 2x3 справа\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"left\", row: 1, column: 1, rowSpan: 3 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3-r\",\n\t\tlabel: \"2x3 слева + большая справа\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"right\", row: 1, column: 3, rowSpan: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3-t\",\n\t\tlabel: \"Широкая сверху + 2x3\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"3x3-b\",\n\t\tlabel: \"2x3 + широкая снизу\",\n\t\tcolumns: 3,\n\t\trows: 3,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"bottom\", row: 3, column: 1, columnSpan: 3 }\n\t\t]\n\t},\n\n\t{\n\t\tid: \"4x2-t\",\n\t\tlabel: \"Широкая сверху + 3x2\",\n\t\tcolumns: 2,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x2-b\",\n\t\tlabel: \"3x2 + широкая снизу\",\n\t\tcolumns: 2,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"bottom\", row: 4, column: 1, columnSpan: 2 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x3-t\",\n\t\tlabel: \"Широкая сверху + 3x3\",\n\t\tcolumns: 3,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"top\", row: 1, column: 1, columnSpan: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 },\n\t\t\t{ id: \"c41\", row: 4, column: 1 },\n\t\t\t{ id: \"c42\", row: 4, column: 2 },\n\t\t\t{ id: \"c43\", row: 4, column: 3 }\n\t\t]\n\t},\n\t{\n\t\tid: \"4x3-b\",\n\t\tlabel: \"3x3 + широкая снизу\",\n\t\tcolumns: 3,\n\t\trows: 4,\n\t\tcells: [\n\t\t\t{ id: \"c11\", row: 1, column: 1 },\n\t\t\t{ id: \"c12\", row: 1, column: 2 },\n\t\t\t{ id: \"c13\", row: 1, column: 3 },\n\t\t\t{ id: \"c21\", row: 2, column: 1 },\n\t\t\t{ id: \"c22\", row: 2, column: 2 },\n\t\t\t{ id: \"c23\", row: 2, column: 3 },\n\t\t\t{ id: \"c31\", row: 3, column: 1 },\n\t\t\t{ id: \"c32\", row: 3, column: 2 },\n\t\t\t{ id: \"c33\", row: 3, column: 3 },\n\t\t\t{ id: \"bottom\", row: 4, column: 1, columnSpan: 3 }\n\t\t]\n\t}\n] as const satisfies readonly LayoutPickerPreset[];\n\nexport type DefaultLayoutPickerPresetId = (typeof DEFAULT_LAYOUT_PICKER_PRESETS)[number][\"id\"];\n\nexport function getDefaultLayoutPickerPresetId(): DefaultLayoutPickerPresetId {\n\treturn DEFAULT_LAYOUT_PICKER_PRESETS[0].id;\n}\n\n/** Возвращает layout-пресет по id с fallback на дефолт chart-ракурса. */\nexport function resolveLayoutPreset(layoutId: string | undefined): LayoutPickerPreset {\n\treturn DEFAULT_LAYOUT_PICKER_PRESETS.find((preset) => preset.id === layoutId) ?? DEFAULT_LAYOUT_PICKER_PRESETS[0];\n}\n\nexport function resolveLayoutCellCount(layoutId: string): number {\n\treturn DEFAULT_LAYOUT_PICKER_PRESETS.find((preset) => preset.id === layoutId)?.cells.length ?? 1;\n}\n","@use \"@/styles/mixins\" as *;\n\n.triggerText {\n\tmin-width: 0;\n\tflex: 1 1 auto;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n}\n\n.popup {\n\twidth: min(calc(100vw - var(--space-lg) * 2), 44em);\n\tmax-height: min(75vh, 34em);\n}\n\n.popupLayout {\n\tmax-height: inherit;\n}\n\n.popupBody {\n\toverflow: auto;\n\tpadding: var(--space-xs);\n}\n\n.options {\n\tdisplay: grid;\n\tgrid-template-columns: repeat(auto-fit, minmax(min(100%, 5em), 1fr));\n\tgap: var(--space-sm);\n}\n\n.option {\n\tposition: relative;\n\tpadding: var(--space-sm);\n\t// border: var(--border);\n\tborder-radius: var(--radius-sm);\n\t// background-color: var(--surface-1);\n\ttransition:\n\t\tbackground-color var(--transition-fast) ease,\n\t\tborder-color var(--transition-fast) ease,\n\t\tcolor var(--transition-fast) ease;\n\n\t@include hover(true) {\n\t\tbackground-color: var(--surface-2);\n\t\tborder-color: var(--border-2);\n\t}\n\n\t&:disabled {\n\t\tcursor: default;\n\t\topacity: var(--disabled-opacity);\n\t}\n}\n\n.option[data-selected] {\n\tborder-color: var(--border-1);\n\tbackground-color: var(--surface-1);\n\n\t.previewCell {\n\t\tbackground-color: var(--accent-fill);\n\t\tborder: var(--border-width) solid var(--accent-border);\n\t}\n}\n\n.optionPreviewWrap {\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n.preview,\n.previewPlaceholder {\n\t--layout-picker-preview-size: 3.5em;\n\n\twidth: var(--layout-picker-preview-size);\n\theight: calc(var(--layout-picker-preview-size) * 0.72);\n\tflex: 0 0 auto;\n}\n\n.preview {\n\tdisplay: grid;\n\tgap: calc(var(--border-width) * 2);\n}\n\n.previewCompact,\n.previewPlaceholder {\n\t--layout-picker-preview-size: 1.75rem;\n}\n\n.previewCell {\n\tmin-width: 0;\n\tmin-height: 0;\n\tborder-radius: var(--radius-xs);\n\tbackground-color: var(--surface-1);\n\tborder: var(--border-width) solid var(--border-1);\n}\n\n.previewCompact {\n\t.previewCell {\n\t\tbackground-color: var(--brand-fill);\n\t\tborder: none;\n\t}\n}\n","import { useRef, useState } from \"react\";\n\nimport { type Placement } from \"@floating-ui/react\";\nimport { cn } from \"@ryuzaki13/react-foundation-lib/utils\";\n\nimport { CustomOptionButton, Option } from \"../../option\";\nimport { PickerField, PickerPopup, PickerTrigger, usePickerFloatingListbox, usePickerTriggerController } from \"../../picker\";\nimport { type UiBaseProps } from \"../../types\";\nimport { DEFAULT_LAYOUT_PICKER_PRESETS, getLayoutCellStyle, getLayoutStyle, type LayoutPickerPreset } from \"../lib\";\n\nimport styles from \"./LayoutPicker.module.scss\";\n\nexport interface LayoutPickerProps extends UiBaseProps<string> {\n\tid?: string;\n\tpresets?: readonly LayoutPickerPreset[];\n\tgetPresetDisabled?: (preset: LayoutPickerPreset) => boolean;\n\t/**\n\t * Показывает рядом с превью переданный текст `placeholder`.\n\t * По умолчанию текст скрыт, поэтому trigger отображает только иконку раскладки.\n\t */\n\tshowPlaceholder?: boolean;\n\tariaLabel?: string;\n\tclassName?: string;\n\ttriggerClassName?: string;\n\tpopupClassName?: string;\n\tplacement?: Placement;\n}\n\nconst DEFAULT_PLACEHOLDER = \"Выберите раскладку\";\n\nfunction LayoutPresetPreview({ preset, compact = false }: { preset: LayoutPickerPreset; compact?: boolean }) {\n\treturn (\n\t\t<span\n\t\t\tclassName={cn(styles.preview, compact && styles.previewCompact)}\n\t\t\tstyle={getLayoutStyle(preset)}\n\t\t\taria-hidden=\"true\"\n\t\t\tdata-ui=\"layout-picker-preview\">\n\t\t\t{preset.cells.map((cell) => (\n\t\t\t\t<span key={`${preset.id}:${cell.id}`} className={styles.previewCell} style={getLayoutCellStyle(cell)} />\n\t\t\t))}\n\t\t</span>\n\t);\n}\n\n/**\n * Контрол выбора layout-пресета. Не хранит бизнес-логику содержимого ячеек.\n */\nexport function LayoutPicker({\n\tid,\n\tlabel,\n\tdescription,\n\tvalue,\n\tonChange,\n\tpresets = DEFAULT_LAYOUT_PICKER_PRESETS,\n\tdisabled,\n\tgetPresetDisabled,\n\tplaceholder = DEFAULT_PLACEHOLDER,\n\tshowPlaceholder = false,\n\tsize,\n\tariaLabel,\n\tclassName,\n\ttriggerClassName,\n\tpopupClassName,\n\tplacement = \"bottom-start\"\n}: LayoutPickerProps) {\n\tconst inputRef = useRef<HTMLInputElement | null>(null);\n\tconst [open, setOpen] = useState(false);\n\tconst selectedIndex = presets.findIndex((preset) => preset.id === value);\n\tconst selectedPreset = selectedIndex >= 0 ? presets[selectedIndex] : undefined;\n\tconst triggerLabel = selectedPreset?.label ?? placeholder;\n\tconst {\n\t\tactiveIndex,\n\t\tcontext,\n\t\tfloatingStyles,\n\t\tgetFloatingProps,\n\t\tsetReference,\n\t\tsetFloating,\n\t\tsetOptionRef,\n\t\tclose,\n\t\topenList,\n\t\ttoggleOpen,\n\t\tselectOption,\n\t\tselectActiveOption,\n\t\thandleReferenceKeyDown,\n\t\thandleFloatingKeyDown,\n\t\tgetOptionId,\n\t\tgetActiveOptionId\n\t} = usePickerFloatingListbox({\n\t\toptions: presets,\n\t\tselectedIndex,\n\t\topen,\n\t\tonOpenChange: setOpen,\n\t\tgetOptionDisabled: getPresetDisabled,\n\t\tonSelect: (preset) => onChange(preset.id),\n\t\tdisabled,\n\t\tplacement,\n\t\ttriggerMode: \"display\"\n\t});\n\tconst triggerController = usePickerTriggerController({\n\t\tmode: \"display\",\n\t\topen,\n\t\tcurrentQuery: \"\",\n\t\thasDisplayValue: selectedPreset !== undefined,\n\t\tinputRef,\n\t\topenList,\n\t\tclose,\n\t\ttoggleOpen\n\t});\n\tconst setInputNode = (node: HTMLInputElement | null) => {\n\t\tinputRef.current = node;\n\t};\n\n\treturn (\n\t\t<PickerField id={id} label={label} description={description} disabled={disabled} size={size} className={className}>\n\t\t\t{({ controlId, labelId, describedBy }) => {\n\t\t\t\tconst listId = `${controlId}-listbox`;\n\n\t\t\t\treturn (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<PickerTrigger\n\t\t\t\t\t\t\tref={setInputNode}\n\t\t\t\t\t\t\trootRef={setReference}\n\t\t\t\t\t\t\tid={controlId}\n\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t\t\topen={open}\n\t\t\t\t\t\t\toptionCount={presets.length}\n\t\t\t\t\t\t\tlabel={label}\n\t\t\t\t\t\t\tplaceholder={placeholder}\n\t\t\t\t\t\t\treadOnly\n\t\t\t\t\t\t\tautoComplete=\"off\"\n\t\t\t\t\t\t\trole=\"combobox\"\n\t\t\t\t\t\t\tvalue={triggerLabel}\n\t\t\t\t\t\t\tselectedValue={\n\t\t\t\t\t\t\t\tselectedPreset ? (\n\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t<LayoutPresetPreview preset={selectedPreset} compact />\n\t\t\t\t\t\t\t\t\t\t{showPlaceholder ? (\n\t\t\t\t\t\t\t\t\t\t\t<span className={styles.triggerText} data-ui=\"layout-picker-selected-label\">\n\t\t\t\t\t\t\t\t\t\t\t\t{selectedPreset.label}\n\t\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t) : undefined\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\thasSelection={selectedPreset !== undefined}\n\t\t\t\t\t\t\tshowSelectedValue={selectedPreset !== undefined}\n\t\t\t\t\t\t\tonToggleMouseDown={triggerController.handleToggleMouseDown}\n\t\t\t\t\t\t\tonToggleClick={triggerController.handleToggleClick}\n\t\t\t\t\t\t\topenAriaLabel=\"Открыть список layout\"\n\t\t\t\t\t\t\tcloseAriaLabel=\"Закрыть список layout\"\n\t\t\t\t\t\t\taria-haspopup=\"listbox\"\n\t\t\t\t\t\t\taria-expanded={open}\n\t\t\t\t\t\t\taria-controls={open ? listId : undefined}\n\t\t\t\t\t\t\taria-labelledby={labelId}\n\t\t\t\t\t\t\taria-describedby={describedBy}\n\t\t\t\t\t\t\taria-autocomplete=\"none\"\n\t\t\t\t\t\t\taria-activedescendant={open ? getActiveOptionId(listId) : undefined}\n\t\t\t\t\t\t\taria-label={!labelId ? (ariaLabel ?? `Выбрать layout. Текущее значение: ${triggerLabel}`) : undefined}\n\t\t\t\t\t\t\tdata-ui=\"layout-picker-trigger\"\n\t\t\t\t\t\t\trootClassName={triggerClassName}\n\t\t\t\t\t\t\tonClick={triggerController.handleTriggerClick}\n\t\t\t\t\t\t\tonFocus={(event) => {\n\t\t\t\t\t\t\t\ttriggerController.handleTriggerFocus(event.currentTarget);\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tonKeyDown={(event) => {\n\t\t\t\t\t\t\t\thandleReferenceKeyDown(event);\n\n\t\t\t\t\t\t\t\tif (event.defaultPrevented) {\n\t\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\ttriggerController.handleTriggerKeyDown({\n\t\t\t\t\t\t\t\t\tevent,\n\t\t\t\t\t\t\t\t\tonActivateWhenOpen: selectActiveOption,\n\t\t\t\t\t\t\t\t\tenableSpaceActivation: true\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t<PickerPopup\n\t\t\t\t\t\t\topen={open}\n\t\t\t\t\t\t\tcontext={context}\n\t\t\t\t\t\t\tfloatingStyles={floatingStyles}\n\t\t\t\t\t\t\tlistId={listId}\n\t\t\t\t\t\t\tlabelId={labelId}\n\t\t\t\t\t\t\tdescriptionId={describedBy}\n\t\t\t\t\t\t\tactiveOptionId={getActiveOptionId(listId)}\n\t\t\t\t\t\t\tsetFloating={setFloating}\n\t\t\t\t\t\t\tgetFloatingProps={getFloatingProps}\n\t\t\t\t\t\t\tonKeyDown={handleFloatingKeyDown}\n\t\t\t\t\t\t\tclassName={cn(styles.popup, popupClassName)}\n\t\t\t\t\t\t\tlayoutClassName={styles.popupLayout}\n\t\t\t\t\t\t\tbodyClassName={styles.popupBody}>\n\t\t\t\t\t\t\t<div className={styles.options}>\n\t\t\t\t\t\t\t\t{presets.map((preset, index) => {\n\t\t\t\t\t\t\t\t\tconst selected = index === selectedIndex;\n\t\t\t\t\t\t\t\t\tconst active = index === activeIndex;\n\t\t\t\t\t\t\t\t\tconst presetDisabled = getPresetDisabled?.(preset) ?? false;\n\t\t\t\t\t\t\t\t\tconst optionId = getOptionId(listId, index);\n\n\t\t\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\t\t<Option\n\t\t\t\t\t\t\t\t\t\t\tkey={preset.id}\n\t\t\t\t\t\t\t\t\t\t\tid={optionId}\n\t\t\t\t\t\t\t\t\t\t\tref={(node) => setOptionRef(index, node)}\n\t\t\t\t\t\t\t\t\t\t\trole=\"option\"\n\t\t\t\t\t\t\t\t\t\t\taria-selected={selected}\n\t\t\t\t\t\t\t\t\t\t\taria-disabled={presetDisabled || undefined}\n\t\t\t\t\t\t\t\t\t\t\taria-label={preset.description ? `${preset.label}. ${preset.description}` : preset.label}\n\t\t\t\t\t\t\t\t\t\t\tclassName={styles.option}\n\t\t\t\t\t\t\t\t\t\t\tactive={active}\n\t\t\t\t\t\t\t\t\t\t\tselected={selected}\n\t\t\t\t\t\t\t\t\t\t\tdisabled={presetDisabled}\n\t\t\t\t\t\t\t\t\t\t\tdata-ui=\"layout-picker-option\"\n\t\t\t\t\t\t\t\t\t\t\tdata-selected={selected || undefined}>\n\t\t\t\t\t\t\t\t\t\t\t<CustomOptionButton\n\t\t\t\t\t\t\t\t\t\t\t\ttabIndex={-1}\n\t\t\t\t\t\t\t\t\t\t\t\tdisabled={presetDisabled}\n\n\t\t\t\t\t\t\t\t\t\t\t\tonMouseDown={(event) => event.preventDefault()}\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() => selectOption(preset)}>\n\t\t\t\t\t\t\t\t\t\t\t\t<span className={styles.optionPreviewWrap}>\n\t\t\t\t\t\t\t\t\t\t\t\t\t<LayoutPresetPreview preset={preset} />\n\t\t\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t\t</CustomOptionButton>\n\t\t\t\t\t\t\t\t\t\t</Option>\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t})}\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</PickerPopup>\n\t\t\t\t\t</>\n\t\t\t\t);\n\t\t\t}}\n\t\t</PickerField>\n\t);\n}\n"],"mappings":";;;;;;AAOA,SAAgB,EAAe,GAA4B,GAA0C;CACpG,OAAO;EACN,qBAAqB,UAAU,EAAO,QAAQ;EAC9C,kBAAkB,UAAU,EAAO,KAAK,WAAW,KAAoB,EAAE;CAC1E;AACD;AAKA,SAAgB,EAAmB,GAA6C;CAC/E,OAAO;EACN,YAAY,GAAG,EAAK,OAAO,UAAU,EAAK,cAAc;EACxD,SAAS,GAA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/B,IAAM,IAAW,MAAU,GACrB,IAAS,MAAU,GACnB,IAAiB,IAAoB,CAAM,KAAK,IAChD,IAAW,EAAY,GAAQ,CAAK;MAE1C,OACC,kBAAC,GAAD;OAEC,IAAI;OACJ,MAAM,MAAS,EAAa,GAAO,CAAI;OACvC,MAAK;OACL,iBAAe;OACf,iBAAe,KAAkB,KAAA;OACjC,cAAY,EAAO,cAAc,GAAG,EAAO,MAAM,IAAI,EAAO,gBAAgB,EAAO;OACnF,WAAW,EAAO;OACV;OACE;OACV,UAAU;OACV,WAAQ;OACR,iBAAe,KAAY,KAAA;OAC3B,UAAA,kBAAC,GAAD;QACC,UAAU;QACV,UAAU;QAEV,cAAc,MAAU,EAAM,eAAe;QAC7C,eAAe,EAAa,CAAM;QAClC,UAAA,kBAAC,QAAD;SAAM,WAAW,EAAO;SACvB,UAAA,kBAAC,GAAD,EAA6B,UAAS,CAAA;QACjC,CAAA;OACa,CAAA;MACb,GAvBF,EAAO,EAuBL;KAEV,CAAC;IACG,CAAA;GACO,CAAA,CACZ,EAAA,CAAA;EAEJ;CACY,CAAA;AAEf"}
@@ -1,5 +1,5 @@
1
1
  import { CustomOptionButton as e, Option as t, OptionButton as n } from "../option/index.js";
2
- import { h as r, v as i } from "../chunks/picker-DZ4-1BvK.js";
2
+ import { h as r, v as i } from "../chunks/picker-lvm82d0A.js";
3
3
  import { useEffect as a, useLayoutEffect as o, useMemo as s, useRef as c, useState as l } from "react";
4
4
  import { findFirstEnabledIndex as u, findLastEnabledIndex as d, findNextEnabledIndex as f, handleKeyboardActivation as p } from "@ryuzaki13/react-foundation-lib/utils";
5
5
  import { jsx as m } from "react/jsx-runtime";
@@ -1,2 +1,2 @@
1
- import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "../chunks/modal-CbAwLHlM.js";
1
+ import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "../chunks/modal-dplfAaER.js";
2
2
  export { n as Modal, i as ModalContent, t as ModalFooter, r as ModalManagerContext, o as ModalManagerProvider, e as ModalToolbar, a as useModalManager };
@@ -1,2 +1,2 @@
1
- import { a as e, i as t, n, r, t as i } from "../chunks/multi-select-V7SLAduU.js";
1
+ import { a as e, i as t, n, r, t as i } from "../chunks/multi-select-BZ9N6Dal.js";
2
2
  export { e as MultiSelect, n as ODataDependentMultiSelect, r as ODataDependentSegmentMultiSelect, t as ODataMultiSelect, i as SerializableMultiSelect };
@@ -1,4 +1,4 @@
1
- import { n as e } from "../chunks/button-BaUlN-nt.js";
1
+ import { n as e } from "../chunks/button-DF21yxVp.js";
2
2
  import { o as t } from "../chunks/flex-C7njxZ74.js";
3
3
  import { createContext as n, useContext as r, useEffect as i, useMemo as a } from "react";
4
4
  import { cn as o } from "@ryuzaki13/react-foundation-lib/utils";