efficient-shell 11.5.0 → 11.10.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 (353) hide show
  1. package/README.md +15 -0
  2. package/dist/{Browser-URFWAJYZ.js → Browser-FIRNNCSC.js} +17 -17
  3. package/dist/Calculator-ELI5Z3XW.js +29 -0
  4. package/dist/{CurrencyConverter-CUIFL32O.js → CurrencyConverter-LU7QXMOI.js} +11 -11
  5. package/dist/{Documents-Y62EQJWN.js → Documents-CE7YKNJM.js} +24 -24
  6. package/dist/Files-ARRIIZZ6.js +88 -0
  7. package/dist/{Notepad-LYK7OAGU.js → Notepad-HNED2SWM.js} +10 -10
  8. package/dist/PdfViewer-ZRDIG2L2.js +1 -0
  9. package/dist/{PomodoroTimer-IMNUQQAC.js → PomodoroTimer-ZJ432VPC.js} +43 -43
  10. package/dist/{Preview-ZKPVPYYL.js → Preview-OGSYTTKC.js} +32 -32
  11. package/dist/Sidebar-ETWHTFNP.js +44 -0
  12. package/dist/Spreadsheet-4HZR2TUV.js +75 -0
  13. package/dist/{Stock-S6URCQBQ.js → Stock-4BOTUHWE.js} +3 -3
  14. package/dist/{Weather-SM5ZQUE2.js → Weather-NDUOK3P3.js} +18 -18
  15. package/dist/{WorldClock-I26FGYJO.js → WorldClock-FH6NFTOM.js} +4 -4
  16. package/dist/ai/index.js +62 -62
  17. package/dist/apps/index.js +1 -1
  18. package/dist/bin/media-host-check.js +1 -1
  19. package/dist/bin/ui-check.js +1 -1
  20. package/dist/borderLineStyles-C-W0uSzL.d.ts +12 -0
  21. package/dist/brand.css +1 -1
  22. package/dist/charts/BoxPlotChart.js +1 -1
  23. package/dist/charts/CandlestickChart.js +1 -1
  24. package/dist/charts/CartesianPlot.js +1 -1
  25. package/dist/charts/ChartBrush.js +1 -1
  26. package/dist/charts/ChartFrame.js +1 -1
  27. package/dist/charts/ChartSkeleton.js +1 -1
  28. package/dist/charts/ChordChart.js +1 -1
  29. package/dist/charts/ColumnChart.js +1 -1
  30. package/dist/charts/FunnelChart.js +1 -1
  31. package/dist/charts/HeatmapChart.js +1 -1
  32. package/dist/charts/HistogramChart.js +1 -1
  33. package/dist/charts/Meter.js +1 -1
  34. package/dist/charts/PieChart.js +1 -1
  35. package/dist/charts/RadarChart.js +1 -1
  36. package/dist/charts/RadialBarChart.js +1 -1
  37. package/dist/charts/RangeChart.js +1 -1
  38. package/dist/charts/RankedBars.js +1 -1
  39. package/dist/charts/SankeyChart.js +1 -1
  40. package/dist/charts/ScatterChart.js +1 -1
  41. package/dist/charts/SpecChart.js +1 -1
  42. package/dist/charts/StatTile.js +1 -1
  43. package/dist/charts/SunburstChart.js +1 -1
  44. package/dist/charts/TimeSeriesChart.js +1 -1
  45. package/dist/charts/TreemapChart.js +1 -1
  46. package/dist/charts/WaterfallChart.js +1 -1
  47. package/dist/{chunk-QOI4GQVH.js → chunk-276JUQXK.js} +1 -1
  48. package/dist/{chunk-G66SG6JN.js → chunk-2CPYXRR2.js} +8 -8
  49. package/dist/{chunk-SXNQHIBY.js → chunk-2JTG3U5L.js} +1 -1
  50. package/dist/{chunk-HNUKXGYP.js → chunk-2UTCGWMZ.js} +4 -4
  51. package/dist/chunk-2V3LKX7G.js +6 -0
  52. package/dist/{chunk-LCSMBVMU.js → chunk-37JAU3U7.js} +1 -1
  53. package/dist/{chunk-MCAPJSB6.js → chunk-4L4GQW7P.js} +1 -1
  54. package/dist/chunk-4LQRLYB4.js +22 -0
  55. package/dist/{chunk-4EZIWLJJ.js → chunk-4UKPDURO.js} +1 -1
  56. package/dist/{chunk-SDDV3UCN.js → chunk-4VF66WBB.js} +12 -12
  57. package/dist/chunk-5CPRZ27M.js +28 -0
  58. package/dist/{chunk-XBHXGBJR.js → chunk-5DZN6ZDE.js} +9 -9
  59. package/dist/{chunk-AIJ6OR6X.js → chunk-5MGNT7XM.js} +2 -2
  60. package/dist/chunk-5XVXYBIQ.js +8 -0
  61. package/dist/{chunk-EOWUUOVE.js → chunk-7N4P6LGD.js} +1 -1
  62. package/dist/{chunk-YQOVUH5W.js → chunk-7QRKZOXR.js} +8 -8
  63. package/dist/{chunk-7TZV6G2F.js → chunk-A2SP4IZV.js} +1 -1
  64. package/dist/chunk-A4FCXZSY.js +8 -0
  65. package/dist/{chunk-JFV5CQN4.js → chunk-A65PRSKV.js} +4 -4
  66. package/dist/chunk-ABKCC7VB.js +9 -0
  67. package/dist/chunk-ABKFALDE.js +8 -0
  68. package/dist/{chunk-F56UUBKG.js → chunk-AFROFSDW.js} +1 -1
  69. package/dist/chunk-AJ6HMM4P.js +20 -0
  70. package/dist/{chunk-A6FR2D46.js → chunk-ALMBY7QO.js} +5 -5
  71. package/dist/{chunk-ILY4DU3D.js → chunk-B4D23ZLJ.js} +1 -1
  72. package/dist/{chunk-UNQ54QOF.js → chunk-BAT5B2LE.js} +1 -1
  73. package/dist/{chunk-36PJGT4W.js → chunk-BXTSBORU.js} +1 -1
  74. package/dist/{chunk-WDQEUNGE.js → chunk-CFFT5OCV.js} +1 -1
  75. package/dist/{chunk-2N64TKI5.js → chunk-D2BXHFYK.js} +1 -1
  76. package/dist/chunk-DGA4SO27.js +3 -0
  77. package/dist/{chunk-4DDL6NXB.js → chunk-DH2DKQKS.js} +1 -1
  78. package/dist/{chunk-VAK5FQXH.js → chunk-DWR6RVX5.js} +4 -4
  79. package/dist/{chunk-HAYGUFNM.js → chunk-DXFG4H4V.js} +1 -1
  80. package/dist/{chunk-4TYIYL56.js → chunk-E2LRAOCL.js} +10 -10
  81. package/dist/{chunk-MS5APD3V.js → chunk-ED6HJBCO.js} +1 -1
  82. package/dist/{chunk-C764JODK.js → chunk-EMUZJMR3.js} +1 -1
  83. package/dist/{chunk-XCAUDTCC.js → chunk-EOYGTVNS.js} +2 -2
  84. package/dist/{chunk-7JVGF555.js → chunk-EP5BHBZQ.js} +1 -1
  85. package/dist/chunk-FBACFP4U.js +4 -0
  86. package/dist/{chunk-JFBL4PR3.js → chunk-FNMF42DQ.js} +2 -2
  87. package/dist/{chunk-ORIXCEKO.js → chunk-FOHOSUK3.js} +1 -1
  88. package/dist/{chunk-ECJKIPWU.js → chunk-FRNSCVPN.js} +1 -1
  89. package/dist/{chunk-4BCFBF3C.js → chunk-FSRHVB4A.js} +7 -7
  90. package/dist/{chunk-YQFGRYEF.js → chunk-FTGA5IPI.js} +14 -14
  91. package/dist/chunk-G2BZ7NCM.js +19 -0
  92. package/dist/{chunk-AWGJIDBR.js → chunk-GNWK77U7.js} +1 -1
  93. package/dist/{chunk-OPN4I565.js → chunk-GPCTDEXQ.js} +1 -1
  94. package/dist/{chunk-QRU55BUS.js → chunk-GV5VNWPG.js} +2 -2
  95. package/dist/{chunk-JSG2AKCG.js → chunk-H5YD72OP.js} +1 -1
  96. package/dist/{chunk-RDYFZHT3.js → chunk-HBS4HYQM.js} +1 -1
  97. package/dist/{chunk-DVYIBJ3S.js → chunk-HRXQCHKI.js} +2 -2
  98. package/dist/chunk-HTTICQBP.js +27 -0
  99. package/dist/{chunk-LJN77RG6.js → chunk-HWFBNYNI.js} +1 -1
  100. package/dist/chunk-HYNUJY6W.js +13 -0
  101. package/dist/{chunk-T6BGS26U.js → chunk-HYXDKY2L.js} +1 -1
  102. package/dist/{chunk-E3EJWNNK.js → chunk-IAUEISDQ.js} +7 -7
  103. package/dist/{chunk-OBJGUJIE.js → chunk-IDRAW6MT.js} +2 -2
  104. package/dist/chunk-IEHTZR5M.js +7 -0
  105. package/dist/chunk-IH2KC3NQ.js +5 -0
  106. package/dist/{chunk-BUO7XCYR.js → chunk-IKKQ4P4R.js} +12 -12
  107. package/dist/{chunk-MDYJVXWD.js → chunk-IW2QNPDG.js} +2 -2
  108. package/dist/{chunk-SX3SG522.js → chunk-IXSSBGRD.js} +9 -9
  109. package/dist/{chunk-54NMFQMW.js → chunk-JADBOQ7S.js} +5 -5
  110. package/dist/{chunk-ZGOHRLXG.js → chunk-JGVKGEIV.js} +1 -1
  111. package/dist/{chunk-XYECIBVX.js → chunk-JJHPPTM6.js} +1 -1
  112. package/dist/{chunk-TMMNCXQT.js → chunk-KMSK6QQB.js} +1 -1
  113. package/dist/{chunk-OEPYQUXZ.js → chunk-KPFYXVCO.js} +9 -9
  114. package/dist/{chunk-4RGMRXYH.js → chunk-KZ6JVHFI.js} +1 -1
  115. package/dist/{chunk-4ULRP4Y4.js → chunk-L3RLB37Y.js} +1 -1
  116. package/dist/{chunk-H5NIW2KS.js → chunk-L433UT5E.js} +1 -1
  117. package/dist/{chunk-V6Y4OC6K.js → chunk-LCHU3ZG4.js} +8 -8
  118. package/dist/{chunk-VHF3CJVO.js → chunk-LLNWE7DR.js} +30 -30
  119. package/dist/{chunk-D5HGRACW.js → chunk-LNGLJA6K.js} +1 -1
  120. package/dist/{chunk-QVZKRROQ.js → chunk-LPTN55KO.js} +1 -1
  121. package/dist/chunk-LVHQJ5TW.js +9 -0
  122. package/dist/{chunk-AFYLVV74.js → chunk-LZJCULO7.js} +1 -1
  123. package/dist/{chunk-E6GDAV5R.js → chunk-MFDOGLFO.js} +3 -3
  124. package/dist/{chunk-P7H2DXJB.js → chunk-MG4IUKVP.js} +10 -10
  125. package/dist/{chunk-AFG34RBV.js → chunk-MOL2ND6G.js} +6 -6
  126. package/dist/{chunk-U44DVPGB.js → chunk-MQHUVZWM.js} +1 -1
  127. package/dist/{chunk-7ELJQL7J.js → chunk-MWKLLAJT.js} +1 -1
  128. package/dist/chunk-N3OJ47VK.js +1 -0
  129. package/dist/chunk-N7645DNN.js +6 -0
  130. package/dist/{chunk-TFSLPAGB.js → chunk-NFNDXE5O.js} +3 -3
  131. package/dist/{chunk-5XFBZ7C3.js → chunk-NGUXPP5Q.js} +54 -54
  132. package/dist/chunk-NOMWJTN2.js +1 -0
  133. package/dist/{chunk-QYL26AB4.js → chunk-NSYCJTHE.js} +1 -1
  134. package/dist/{chunk-4EBJO7ER.js → chunk-NTKNM25F.js} +9 -9
  135. package/dist/{chunk-IMDGMUE3.js → chunk-O4OFURPC.js} +1 -1
  136. package/dist/{chunk-5H4SWQGM.js → chunk-OE77XFOV.js} +1 -1
  137. package/dist/{chunk-WLYYC3AP.js → chunk-ONIL7WXO.js} +1 -1
  138. package/dist/{chunk-2E2SUEEE.js → chunk-OQG3XO4Y.js} +1 -1
  139. package/dist/{chunk-TDAI4J27.js → chunk-OS2KE6QG.js} +4 -4
  140. package/dist/{chunk-NZ34BQKH.js → chunk-OUXSI6X4.js} +1 -1
  141. package/dist/{chunk-CLTRQ7AQ.js → chunk-OYTRB237.js} +1 -1
  142. package/dist/{chunk-KXU4ORKE.js → chunk-OZEPYQ7E.js} +1 -1
  143. package/dist/{chunk-DZOJQURG.js → chunk-P7NO3NGC.js} +10 -10
  144. package/dist/{chunk-BMXTPJ7T.js → chunk-PAC4LK2N.js} +5 -5
  145. package/dist/{chunk-UEISJFZH.js → chunk-PBMAMVSE.js} +5 -5
  146. package/dist/{chunk-O3MBPAWZ.js → chunk-PC44XTGN.js} +1 -1
  147. package/dist/{chunk-7LU3H72S.js → chunk-PEVWAJUR.js} +6 -6
  148. package/dist/{chunk-RNBS6QGP.js → chunk-PMKR2BF2.js} +21 -21
  149. package/dist/{chunk-JH4ZCPHW.js → chunk-PR42NIDL.js} +10 -10
  150. package/dist/{chunk-6IOFNPR6.js → chunk-PTWKG635.js} +3 -3
  151. package/dist/{chunk-DIEH76MB.js → chunk-QIEAZN6Z.js} +1 -1
  152. package/dist/{chunk-DQQKG46I.js → chunk-QIVIQUKB.js} +7 -7
  153. package/dist/{chunk-PLC656AN.js → chunk-QL5E3MU3.js} +1 -1
  154. package/dist/chunk-QRZBLNOQ.js +4 -0
  155. package/dist/{chunk-6KGIHI6X.js → chunk-QVAOSKFO.js} +10 -10
  156. package/dist/{chunk-2UO47XB4.js → chunk-R64OZ6TC.js} +26 -12
  157. package/dist/{chunk-JTMEFXRL.js → chunk-RDTKMSEK.js} +1 -1
  158. package/dist/{chunk-IPO4LHSB.js → chunk-RKL47W7I.js} +6 -6
  159. package/dist/{chunk-QALPUJR2.js → chunk-RPTOAKLB.js} +1 -1
  160. package/dist/{chunk-3BFZVVAT.js → chunk-RQ6TC6RM.js} +1 -1
  161. package/dist/{chunk-4P3324KU.js → chunk-RSJLN3EG.js} +1 -1
  162. package/dist/{chunk-SAP4YI2Y.js → chunk-SDAX6BXF.js} +1 -1
  163. package/dist/{chunk-OA54HARK.js → chunk-SIA3W7VE.js} +6 -6
  164. package/dist/{chunk-DWAA4YZV.js → chunk-SJQKEIS7.js} +3 -3
  165. package/dist/{chunk-OH5L6HYW.js → chunk-SXBOODCJ.js} +4 -4
  166. package/dist/{chunk-3IUPYCW3.js → chunk-SZTIP6T7.js} +1 -1
  167. package/dist/{chunk-KYBXJL6A.js → chunk-T2ZFXPQV.js} +21 -21
  168. package/dist/{chunk-VX6TKEEK.js → chunk-TKE3EF2U.js} +1 -1
  169. package/dist/{chunk-XQZL6JDD.js → chunk-TURECNEK.js} +4 -4
  170. package/dist/{chunk-AWKJZSTO.js → chunk-U6IJL4Q5.js} +1 -1
  171. package/dist/{chunk-7FW2BQTV.js → chunk-U7T2ONAY.js} +1 -1
  172. package/dist/chunk-UGOSZLCD.js +14 -0
  173. package/dist/{chunk-HNVSVTNC.js → chunk-UIN2LUCZ.js} +14 -14
  174. package/dist/{chunk-55AEZX6K.js → chunk-UZ7TKJRO.js} +1 -1
  175. package/dist/{chunk-BBXFIBXB.js → chunk-V6LPIDZ6.js} +1 -1
  176. package/dist/chunk-VNTJ7QO5.js +1 -0
  177. package/dist/{chunk-SL77N7VT.js → chunk-VTXCCFJ4.js} +3 -3
  178. package/dist/{chunk-PSR6SXCC.js → chunk-WB6E6CSH.js} +13 -13
  179. package/dist/{chunk-CRILBBSU.js → chunk-WDZUPDNC.js} +1 -1
  180. package/dist/{chunk-6M5O2P64.js → chunk-WMS2DCRV.js} +9 -9
  181. package/dist/chunk-WQGBYFS3.js +8 -0
  182. package/dist/{chunk-PCTOL2FX.js → chunk-WTTXLWMK.js} +8 -8
  183. package/dist/{chunk-WPCNJ4UL.js → chunk-WYSNMIZN.js} +1 -1
  184. package/dist/{chunk-Z44JWU75.js → chunk-WZMZ3N5B.js} +2 -2
  185. package/dist/chunk-Y2LWUBXX.js +2 -0
  186. package/dist/{chunk-OKHKY3ZZ.js → chunk-YGCVMPIU.js} +1 -1
  187. package/dist/{chunk-NRALUW6P.js → chunk-YIFRSPUM.js} +10 -10
  188. package/dist/{chunk-EN5NXWT6.js → chunk-YKEB576T.js} +1 -1
  189. package/dist/{chunk-COF33H6J.js → chunk-YM4XIO4K.js} +5 -5
  190. package/dist/chunk-YMBNVMFU.js +11 -0
  191. package/dist/{chunk-2PGR2276.js → chunk-YY5TUQS4.js} +3 -3
  192. package/dist/{chunk-LXL2UCUR.js → chunk-Z32K3LIJ.js} +1 -1
  193. package/dist/{chunk-P3RXXWXN.js → chunk-ZDDYTXPK.js} +6 -6
  194. package/dist/{chunk-V2J2AHDW.js → chunk-ZGQ6H2PU.js} +4 -4
  195. package/dist/{chunk-NU5HN3FZ.js → chunk-ZM2NOLT6.js} +12 -12
  196. package/dist/chunk-ZQJTLJUF.js +2 -0
  197. package/dist/chunk-ZVEDA462.js +3 -0
  198. package/dist/{chunk-TGGUYAWA.js → chunk-ZWLOVJWN.js} +1 -1
  199. package/dist/data/DataTable.js +1 -1
  200. package/dist/data/EntityList.js +1 -1
  201. package/dist/data/Kanban.js +1 -1
  202. package/dist/data/ListFooter.js +1 -1
  203. package/dist/data/ListLoadError.js +1 -1
  204. package/dist/data/Pagination.js +1 -1
  205. package/dist/data/ResizableTable.js +1 -1
  206. package/dist/file-intake/index.js +1 -1
  207. package/dist/format/index.d.ts +1 -0
  208. package/dist/format/index.js +1 -1
  209. package/dist/forms/BorderInput.d.ts +3 -3
  210. package/dist/forms/BorderInput.js +1 -1
  211. package/dist/forms/BrandAssetEditor.js +1 -1
  212. package/dist/forms/Calendar.js +1 -1
  213. package/dist/forms/ColorPicker.js +1 -1
  214. package/dist/forms/ComposerAttachments.js +1 -1
  215. package/dist/forms/CornersInput.js +1 -1
  216. package/dist/forms/DatePicker.js +1 -1
  217. package/dist/forms/DateRangePicker.js +1 -1
  218. package/dist/forms/DateTimePicker.js +1 -1
  219. package/dist/forms/DisplayChips.js +1 -1
  220. package/dist/forms/FilePicker.js +1 -1
  221. package/dist/forms/FormErrorSummary.js +1 -1
  222. package/dist/forms/IconPicker.d.ts +12 -1
  223. package/dist/forms/IconPicker.js +1 -1
  224. package/dist/forms/ImageFocusPoint.js +1 -1
  225. package/dist/forms/Input.js +1 -1
  226. package/dist/forms/InputNumber.js +1 -1
  227. package/dist/forms/LinkPicker.d.ts +22 -0
  228. package/dist/forms/LinkPicker.js +1 -1
  229. package/dist/forms/MediaLibrary.js +1 -1
  230. package/dist/forms/MediaUploadField.js +1 -1
  231. package/dist/forms/MediaUploadGrid.js +1 -1
  232. package/dist/forms/MediaUsedInList.js +1 -1
  233. package/dist/forms/NumericKeypad.js +1 -1
  234. package/dist/forms/PositionInput.js +1 -1
  235. package/dist/forms/RenameField.js +1 -1
  236. package/dist/forms/Select.js +1 -1
  237. package/dist/forms/SidesInput.js +1 -1
  238. package/dist/forms/Slider.js +1 -1
  239. package/dist/forms/Snippet.js +1 -1
  240. package/dist/forms/SplitButton.js +1 -1
  241. package/dist/forms/TagInput.js +1 -1
  242. package/dist/forms/TextToolbar.js +1 -1
  243. package/dist/forms/TimePicker.js +1 -1
  244. package/dist/forms/WidthsBar.js +1 -1
  245. package/dist/forms/mediaLibraryMenu.js +1 -1
  246. package/dist/forms/mediaMoveItems.js +1 -1
  247. package/dist/forms/textAlign.js +1 -1
  248. package/dist/forms/useFileIntake.js +1 -1
  249. package/dist/icons/index.js +1 -1
  250. package/dist/index.d.ts +2 -1
  251. package/dist/index.js +509 -509
  252. package/dist/locales/zh-Hans.js +1 -1
  253. package/dist/map/index.js +3 -3
  254. package/dist/markdown/index.js +1 -1
  255. package/dist/page-tabs/index.js +5 -5
  256. package/dist/pdf/index.js +1 -1
  257. package/dist/shell/Accordion.js +1 -1
  258. package/dist/shell/AppUpdateBanner.js +1 -1
  259. package/dist/shell/Avatar.js +1 -1
  260. package/dist/shell/Banner.js +1 -1
  261. package/dist/shell/Breadcrumbs.js +1 -1
  262. package/dist/shell/BudgetBar.js +1 -1
  263. package/dist/shell/Card.js +1 -1
  264. package/dist/shell/ColoredBadge.js +1 -1
  265. package/dist/shell/ConfirmDialog.js +1 -1
  266. package/dist/shell/ContainerFillChart.js +1 -1
  267. package/dist/shell/ContextMenu.js +1 -1
  268. package/dist/shell/CountBadge.js +1 -1
  269. package/dist/shell/Dialog.js +1 -1
  270. package/dist/shell/Drawer.js +1 -1
  271. package/dist/shell/DropdownMenu.js +1 -1
  272. package/dist/shell/EditableGrid.js +1 -1
  273. package/dist/shell/EmptyState.js +1 -1
  274. package/dist/shell/GlobalSearch.js +1 -1
  275. package/dist/shell/HelpCenter.js +1 -1
  276. package/dist/shell/IconRail.js +1 -1
  277. package/dist/shell/ImageLightbox.js +1 -1
  278. package/dist/shell/ItemCount.js +1 -1
  279. package/dist/shell/LanguageSelect.js +1 -1
  280. package/dist/shell/Markdown.js +1 -1
  281. package/dist/shell/MetricBar.js +1 -1
  282. package/dist/shell/MetricBarLegend.js +1 -1
  283. package/dist/shell/MilestoneTimeline.js +1 -1
  284. package/dist/shell/PageHeader.js +1 -1
  285. package/dist/shell/PopupMenu.js +1 -1
  286. package/dist/shell/ProductionTimeline.js +1 -1
  287. package/dist/shell/ResizeHandle.js +1 -1
  288. package/dist/shell/Result.js +1 -1
  289. package/dist/shell/SearchableSelect.js +1 -1
  290. package/dist/shell/SettingReset.js +1 -1
  291. package/dist/shell/SettingRow.js +1 -1
  292. package/dist/shell/SidebarLayout.js +1 -1
  293. package/dist/shell/SidebarNav.js +1 -1
  294. package/dist/shell/SortableList.js +1 -1
  295. package/dist/shell/Statistic.js +1 -1
  296. package/dist/shell/StepChain.js +1 -1
  297. package/dist/shell/Stepper.js +1 -1
  298. package/dist/shell/TimeAgo.js +1 -1
  299. package/dist/shell/TimelineTrack.js +1 -1
  300. package/dist/shell/TopNav.js +1 -1
  301. package/dist/shell/TransferProgress.js +1 -1
  302. package/dist/shell/Tree.js +1 -1
  303. package/dist/shell/discardGuard.js +1 -1
  304. package/dist/shell/language.js +1 -1
  305. package/dist/shell/strings.d.ts +129 -0
  306. package/dist/shell/strings.js +1 -1
  307. package/dist/shell/toast.js +1 -1
  308. package/dist/telemetry/index.js +1 -1
  309. package/dist/templates/AuthScreen.js +1 -1
  310. package/dist/templates/ChatTemplate.js +1 -1
  311. package/dist/templates/CheckoutTemplate.js +1 -1
  312. package/dist/templates/DashboardTemplate.js +1 -1
  313. package/dist/templates/DataTablePage.js +1 -1
  314. package/dist/templates/EmailTemplate.js +1 -1
  315. package/dist/templates/ErrorBoundary.js +1 -1
  316. package/dist/templates/ErrorPage.js +1 -1
  317. package/dist/templates/FormLayoutPage.js +1 -1
  318. package/dist/templates/GalleryTemplate.js +1 -1
  319. package/dist/ui/index.d.ts +2 -1
  320. package/dist/ui/index.js +1 -1
  321. package/dist/version.js +1 -1
  322. package/package.json +1 -1
  323. package/dist/Calculator-OJSMHQKW.js +0 -29
  324. package/dist/Files-NXY7XRZD.js +0 -88
  325. package/dist/PdfViewer-Y3SAVADX.js +0 -1
  326. package/dist/Sidebar-BCTWRG7P.js +0 -44
  327. package/dist/Spreadsheet-BPW2TLVQ.js +0 -37
  328. package/dist/chunk-3XZFWR6T.js +0 -13
  329. package/dist/chunk-4P57TIFK.js +0 -2
  330. package/dist/chunk-5PDHKH2A.js +0 -3
  331. package/dist/chunk-77AQNJE2.js +0 -9
  332. package/dist/chunk-7INZ7O3A.js +0 -5
  333. package/dist/chunk-CH3JQUDW.js +0 -8
  334. package/dist/chunk-DOF56HTO.js +0 -6
  335. package/dist/chunk-EVX7AZII.js +0 -9
  336. package/dist/chunk-EXLHFM3V.js +0 -6
  337. package/dist/chunk-GBATZZX7.js +0 -1
  338. package/dist/chunk-GDQJBQ5B.js +0 -1
  339. package/dist/chunk-K4JQ3FQI.js +0 -2
  340. package/dist/chunk-LDZQJLMC.js +0 -3
  341. package/dist/chunk-M66ACZXQ.js +0 -5
  342. package/dist/chunk-MHPFBVDD.js +0 -8
  343. package/dist/chunk-NWC6YCIJ.js +0 -11
  344. package/dist/chunk-NZISMTQE.js +0 -7
  345. package/dist/chunk-PLK2WHZG.js +0 -27
  346. package/dist/chunk-QO5E33DH.js +0 -8
  347. package/dist/chunk-RBZKV3ED.js +0 -14
  348. package/dist/chunk-TNJ2VCH4.js +0 -8
  349. package/dist/chunk-VX4COEWP.js +0 -4
  350. package/dist/chunk-WOAMPTZI.js +0 -20
  351. package/dist/chunk-XFH64VIG.js +0 -19
  352. package/dist/chunk-XKGEI6NL.js +0 -28
  353. package/dist/chunk-XXL5RLNM.js +0 -22
@@ -0,0 +1 @@
1
+ var d=["solid","dashed","dotted"];export{d as BORDER_LINE_STYLES};
@@ -1,4 +1,4 @@
1
- import{Icon as e}from"./chunk-2UO47XB4.js";import{useShellStrings as r}from"./chunk-GDQJBQ5B.js";import{jsxs as t,jsx as n}from"react/jsx-runtime";var s={success:"success",error:"error",warning:"warning",info:"info",404:"info",403:"warning",500:"error"},c={success:"text-green-600 bg-green-100",error:"text-red-600 bg-red-100",warning:"text-amber-600 bg-amber-100",info:"text-blue-600 bg-blue-100"},a={404:e=>e.notFound,403:e=>e.noAccess,500:e=>e.serverError};function i({tone:r}){const t={className:"h-6 w-6",strokeWidth:1.5,"aria-hidden":!0};switch(r){case"success":/* @__PURE__ */
1
+ import{Icon as e}from"./chunk-R64OZ6TC.js";import{useShellStrings as r}from"./chunk-VNTJ7QO5.js";import{jsxs as t,jsx as n}from"react/jsx-runtime";var s={success:"success",error:"error",warning:"warning",info:"info",404:"info",403:"warning",500:"error"},c={success:"text-green-600 bg-green-100",error:"text-red-600 bg-red-100",warning:"text-amber-600 bg-amber-100",info:"text-blue-600 bg-blue-100"},a={404:e=>e.notFound,403:e=>e.noAccess,500:e=>e.serverError};function i({tone:r}){const t={className:"h-6 w-6",strokeWidth:1.5,"aria-hidden":!0};switch(r){case"success":/* @__PURE__ */
2
2
  return n(e,{name:"check",...t});case"error":/* @__PURE__ */
3
3
  return n(e,{name:"close",...t});case"warning":/* @__PURE__ */
4
4
  return n(e,{name:"error",...t});default:/* @__PURE__ */
@@ -1,14 +1,14 @@
1
- import{AccessibleTable as e}from"./chunk-5PP435FL.js";import{polygonPoints as t}from"./chunk-VFC6QUEN.js";import{ChartDefs as r,maskId as l}from"./chunk-465RRWBY.js";import{useHighlight as a}from"./chunk-CNYAHYE6.js";import{ChartTooltip as o}from"./chunk-36VIGB6J.js";import{angleScale as n}from"./chunk-2JWPNR2U.js";import{CHART_INK as i,resolveSeriesColorWithin as s}from"./chunk-TZFACUMR.js";import{useShellStrings as m,useShellLocale as c}from"./chunk-GDQJBQ5B.js";import{formatPlain as h}from"./chunk-C3QOHMR6.js";import{useId as p,useState as u}from"react";import{jsx as d,jsxs as f}from"react/jsx-runtime";var k=3,g=e=>`${e.map(([e,t],r)=>`${0===r?"M":"L"}${e.toFixed(2)},${t.toFixed(2)}`).join(" ")} Z`;function x({axes:k,series:x,size:y=300,mode:b="area",grid:v="polygon",rings:M=4,formatValue:N,animate:j=!0,className:$,emptyLabel:C}){const F=m().charts,W=c(),w=N??(e=>h(e,W)),B=C??F.nothingToCompare,L=p(),[R,A]=u(null),{highlighted:Q}=a(),z=x;if(k.length<3||0===z.length)/* @__PURE__ */
2
- return d("p",{className:`text-sm text-gray-500 ${$??""}`,children:B});const E=y/2,J=y/2,P=y/2-46,T=n(k.length),U=k.map((e,t)=>null!=e.max&&Number.isFinite(e.max)&&e.max>0?e.max:Math.max(1,...z.map(e=>e.values[t]??0).filter(Number.isFinite))),V=(e,t)=>{const r=Math.max(0,Math.min(1,t/U[e])),l=T.center(e)-T.step/2;return[E+P*r*Math.cos(l),J+P*r*Math.sin(l)]},Y=(e,t)=>null!==R?R!==e:null!==Q&&Q!==t,G=null!==R?z[R]:void 0;/* @__PURE__ */
1
+ import{AccessibleTable as e}from"./chunk-5PP435FL.js";import{polygonPoints as t}from"./chunk-VFC6QUEN.js";import{ChartDefs as r,maskId as l}from"./chunk-465RRWBY.js";import{useHighlight as a}from"./chunk-CNYAHYE6.js";import{ChartTooltip as o}from"./chunk-36VIGB6J.js";import{angleScale as n}from"./chunk-2JWPNR2U.js";import{CHART_INK as i,resolveSeriesColorWithin as s}from"./chunk-TZFACUMR.js";import{useShellStrings as m,useShellLocale as c}from"./chunk-VNTJ7QO5.js";import{formatPlain as h}from"./chunk-C3QOHMR6.js";import{useId as p,useState as u}from"react";import{jsx as d,jsxs as f}from"react/jsx-runtime";var k=3,g=e=>`${e.map(([e,t],r)=>`${0===r?"M":"L"}${e.toFixed(2)},${t.toFixed(2)}`).join(" ")} Z`;function x({axes:k,series:x,size:y=300,mode:b="area",grid:v="polygon",rings:M=4,formatValue:N,animate:j=!0,className:$,emptyLabel:C}){const F=m().charts,W=c(),w=N??(e=>h(e,W)),L=C??F.nothingToCompare,R=p(),[A,T]=u(null),{highlighted:V}=a(),z=x;if(k.length<3||0===z.length)/* @__PURE__ */
2
+ return d("p",{className:`text-sm text-gray-500 ${$??""}`,children:L});const B=y/2,E=y/2,J=y/2-46,O=n(k.length),P=k.map((e,t)=>null!=e.max&&Number.isFinite(e.max)&&e.max>0?e.max:Math.max(1,...z.map(e=>e.values[t]??0).filter(Number.isFinite))),Q=(e,t)=>{const r=Math.max(0,Math.min(1,t/P[e])),l=O.center(e)-O.step/2;return[B+J*r*Math.cos(l),E+J*r*Math.sin(l)]},U=(e,t)=>null!==A?A!==e:null!==V&&V!==t,Y=null!==A?z[A]:void 0;/* @__PURE__ */
3
3
  return f("div",{className:`relative ${$??""}`,children:[
4
- /* @__PURE__ */f("svg",{width:"100%",height:y,viewBox:`0 0 ${y} ${y}`,role:"img","aria-labelledby":L,onMouseLeave:()=>A(null),children:[
5
- /* @__PURE__ */d("title",{id:L,children:F.acrossMeasures(z.map(e=>e.label),k.length)}),Array.from({length:M},(e,r)=>{const l=P*(r+1)/M;return"circle"===v?/* @__PURE__ */d("circle",{cx:E,cy:J,r:l,fill:"none",stroke:i.grid,strokeWidth:1},r):/* @__PURE__ */d("path",{d:g(t(E,J,l,k.length)),fill:"none",stroke:i.grid,strokeWidth:1},r)}),k.map((e,t)=>{const[r,l]=V(t,U[t]);/* @__PURE__ */
4
+ /* @__PURE__ */f("svg",{width:"100%",height:y,viewBox:`0 0 ${y} ${y}`,role:"img","aria-labelledby":R,onMouseLeave:()=>T(null),children:[
5
+ /* @__PURE__ */d("title",{id:R,children:F.acrossMeasures(z.map(e=>e.label),k.length)}),Array.from({length:M},(e,r)=>{const l=J*(r+1)/M;return"circle"===v?/* @__PURE__ */d("circle",{cx:B,cy:E,r:l,fill:"none",stroke:i.grid,strokeWidth:1},r):/* @__PURE__ */d("path",{d:g(t(B,E,l,k.length)),fill:"none",stroke:i.grid,strokeWidth:1},r)}),k.map((e,t)=>{const[r,l]=Q(t,P[t]);/* @__PURE__ */
6
6
  return f("g",{children:[
7
- /* @__PURE__ */d("line",{x1:E,y1:J,x2:r,y2:l,stroke:i.grid,strokeWidth:1}),
8
- /* @__PURE__ */d("text",{x:E+(P+18)*Math.cos(T.center(t)-T.step/2),y:J+(P+18)*Math.sin(T.center(t)-T.step/2)+4,textAnchor:"middle",fontSize:11,fill:i.label,children:e.label})]},e.key)}),
9
- /* @__PURE__ */d(r,{id:L,reveal:!!j&&"center-out"}),z.map((e,t)=>{const r=s(t,3,e.color,e.tone),a=k.map((t,r)=>V(r,e.values[r]??0));/* @__PURE__ */
10
- return f("g",{opacity:Y(t,e.key)?.3:1,onMouseEnter:()=>A(t),mask:j?`url(#${l(L)})`:void 0,children:["area"===b&&/* @__PURE__ */d("path",{d:g(a),fill:r,fillOpacity:.18,stroke:"none"}),
11
- /* @__PURE__ */d("path",{d:g(a),fill:"none",stroke:r,strokeWidth:2,strokeLinejoin:"round"}),a.map(([e,t],l)=>/* @__PURE__ */d("circle",{cx:e,cy:t,r:3.5,fill:r,stroke:i.surface,strokeWidth:1.5},l))]},e.key)})]}),G&&/* @__PURE__ */d("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */d(o,{title:G.label,rows:k.map((e,t)=>({key:e.key,label:e.label,color:s(R,3,G.color,G.tone),value:w(G.values[t]??0)}))})}),
7
+ /* @__PURE__ */d("line",{x1:B,y1:E,x2:r,y2:l,stroke:i.grid,strokeWidth:1}),
8
+ /* @__PURE__ */d("text",{x:B+(J+18)*Math.cos(O.center(t)-O.step/2),y:E+(J+18)*Math.sin(O.center(t)-O.step/2)+4,textAnchor:"middle",fontSize:11,fill:i.label,children:e.label})]},e.key)}),
9
+ /* @__PURE__ */d(r,{id:R,reveal:!!j&&"center-out"}),z.map((e,t)=>{const r=s(t,3,e.color,e.tone),a=k.map((t,r)=>Q(r,e.values[r]??0));/* @__PURE__ */
10
+ return f("g",{opacity:U(t,e.key)?.3:1,onMouseEnter:()=>T(t),mask:j?`url(#${l(R)})`:void 0,children:["area"===b&&/* @__PURE__ */d("path",{d:g(a),fill:r,fillOpacity:.18,stroke:"none"}),
11
+ /* @__PURE__ */d("path",{d:g(a),fill:"none",stroke:r,strokeWidth:2,strokeLinejoin:"round"}),a.map(([e,t],l)=>/* @__PURE__ */d("circle",{cx:e,cy:t,r:3.5,fill:r,stroke:i.surface,strokeWidth:1.5},l))]},e.key)})]}),Y&&/* @__PURE__ */d("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */d(o,{title:Y.label,rows:k.map((e,t)=>({key:e.key,label:e.label,color:s(A,3,Y.color,Y.tone),value:w(Y.values[t]??0)}))})}),
12
12
  /* @__PURE__ */d("ul",{className:"m-0 mt-3 grid gap-1 p-0",style:{gridTemplateColumns:"repeat(auto-fit,minmax(140px,1fr))"},children:z.map((e,t)=>/* @__PURE__ */f("li",{className:"flex list-none items-center gap-2 text-xs text-gray-600",children:[
13
13
  /* @__PURE__ */d("span",{className:"h-2.5 w-2.5 shrink-0 rounded-sm",style:{backgroundColor:s(t,3,e.color,e.tone)}}),
14
14
  /* @__PURE__ */d("span",{className:"flex-1 truncate",children:e.label})]},e.key))}),
@@ -1,4 +1,4 @@
1
- import{TICK_INK as e}from"./chunk-URBCGEXG.js";import{useShellStrings as n}from"./chunk-GDQJBQ5B.js";import{jsxs as r,jsx as i}from"react/jsx-runtime";function a({ink:e}){/* @__PURE__ */
1
+ import{TICK_INK as e}from"./chunk-URBCGEXG.js";import{useShellStrings as n}from"./chunk-VNTJ7QO5.js";import{jsxs as r,jsx as i}from"react/jsx-runtime";function a({ink:e}){/* @__PURE__ */
2
2
  return i("span",{"aria-hidden":"true",className:`h-3 w-0.5 shrink-0 rounded-[1px] ${e}`})}function t({link:t,className:l=""}){const c=n().meter;/* @__PURE__ */
3
3
  return r("div",{className:`flex flex-wrap items-center gap-x-3 gap-y-1 text-xs text-gray-500 ${l}`.trim(),children:[
4
4
  /* @__PURE__ */r("span",{className:"inline-flex items-center gap-1",children:[
@@ -1 +1 @@
1
- import{requestFilesTrashView as n}from"./chunk-JFBL4PR3.js";var o=null;function r(n){o=n}function t(){return o}function u(){n()}export{t as getFilesDemoTree,u as openFilesInTrashMode,r as setFilesDemoTree};
1
+ import{requestFilesTrashView as n}from"./chunk-FNMF42DQ.js";var o=null;function r(n){o=n}function t(){return o}function u(){n()}export{t as getFilesDemoTree,u as openFilesInTrashMode,r as setFilesDemoTree};
@@ -1,2 +1,2 @@
1
- import{InputNumber_default as a}from"./chunk-QRU55BUS.js";import{Icon as e}from"./chunk-2UO47XB4.js";import{jsxs as r,jsx as i}from"react/jsx-runtime";var n="h-3.5 w-3.5",l={x:/* @__PURE__ */i(e,{name:"nudge-x","aria-hidden":"true",className:n}),y:/* @__PURE__ */i(e,{name:"nudge-y","aria-hidden":"true",className:n})};function s({label:e,value:n,onChange:s,words:m,placeholder:o,min:d=-200,max:c=200,step:t=1,readOnly:p}){const u=e=>/* @__PURE__ */i("div",{"data-axis":e,className:"min-w-0",children:/* @__PURE__ */i(a,{value:n[e],onChange:a=>s({...n,[e]:a}),min:d,max:c,step:t,precision:0,steppers:"compact",readOnly:p,placeholder:o[e],prefix:l[e],suffix:m.unit,"aria-label":m[e]})});/* @__PURE__ */
1
+ import{InputNumber_default as a}from"./chunk-GV5VNWPG.js";import{Icon as e}from"./chunk-R64OZ6TC.js";import{jsxs as r,jsx as i}from"react/jsx-runtime";var n="h-3.5 w-3.5",l={x:/* @__PURE__ */i(e,{name:"nudge-x","aria-hidden":"true",className:n}),y:/* @__PURE__ */i(e,{name:"nudge-y","aria-hidden":"true",className:n})};function s({label:e,value:n,onChange:s,words:m,placeholder:o,min:d=-200,max:c=200,step:t=1,readOnly:p}){const u=e=>/* @__PURE__ */i("div",{"data-axis":e,className:"min-w-0",children:/* @__PURE__ */i(a,{value:n[e],onChange:a=>s({...n,[e]:a}),min:d,max:c,step:t,precision:0,steppers:"compact",readOnly:p,placeholder:o[e],prefix:l[e],suffix:m.unit,"aria-label":m[e]})});/* @__PURE__ */
2
2
  return r("div",{role:"group","aria-label":e,className:"grid min-w-0 grid-cols-2 gap-2",children:[u("x"),u("y")]})}export{s as PositionInput};
@@ -1,3 +1,3 @@
1
- import{Icon as e}from"./chunk-2UO47XB4.js";import{useShellStrings as t}from"./chunk-GDQJBQ5B.js";import{useState as r,useRef as o,useEffect as c,useCallback as i}from"react";import{jsx as n}from"react/jsx-runtime";function a(e){const[t,n]=r(!1),a=o(void 0);c(()=>()=>clearTimeout(a.current),[]);return{copied:t,copy:i(t=>{t?.stopPropagation(),navigator.clipboard?.writeText(e).then(()=>{n(!0),clearTimeout(a.current),a.current=setTimeout(()=>n(!1),1500)},()=>{})},[e])}}function u({copied:t,className:r="w-4 h-4"}){/* @__PURE__ */
1
+ import{Icon as e}from"./chunk-R64OZ6TC.js";import{useShellStrings as t}from"./chunk-VNTJ7QO5.js";import{useState as r,useRef as o,useEffect as c,useCallback as i}from"react";import{jsx as n}from"react/jsx-runtime";function a(e){const[t,n]=r(!1),a=o(void 0);c(()=>()=>clearTimeout(a.current),[]);return{copied:t,copy:i(t=>{t?.stopPropagation(),navigator.clipboard?.writeText(e).then(()=>{n(!0),clearTimeout(a.current),a.current=setTimeout(()=>n(!1),1500)},()=>{})},[e])}}function u({copied:t,className:r="w-4 h-4"}){/* @__PURE__ */
2
2
  return n(e,t?{name:"check",className:`${r} text-green-600`,"aria-hidden":"true"}:{name:"copy",className:r,"aria-hidden":"true"})}function m({text:e}){const{copied:r,copy:o}=a(e),c=t().copy;/* @__PURE__ */
3
3
  return n("button",{onClick:o,title:r?c.copiedValue:c.copyValue(e),className:"shrink-0 text-gray-400 hover:text-gray-600 transition-colors",children:/* @__PURE__ */n(u,{copied:r})})}export{m as CopyButton,u as CopyGlyph,a as useCopyText};
@@ -1,6 +1,6 @@
1
- import{GROUP_COLORS as e}from"./chunk-FZM3ZPW3.js";import{SpinnerRing as r}from"./chunk-R2VKEMZH.js";import{Tooltip as n}from"./chunk-NJN5IKWO.js";import{useShellStrings as l}from"./chunk-GDQJBQ5B.js";import{jsx as t,jsxs as i,Fragment as a}from"react/jsx-runtime";var s="inline-flex items-center gap-1 whitespace-nowrap rounded-md border border-current/20 py-0.5 pl-2 pr-1 text-2xs font-medium";function o({label:e,glyph:r,onClick:l}){/* @__PURE__ */
1
+ import{GROUP_COLORS as e}from"./chunk-FZM3ZPW3.js";import{SpinnerRing as r}from"./chunk-R2VKEMZH.js";import{Tooltip as n}from"./chunk-NJN5IKWO.js";import{useShellStrings as l}from"./chunk-VNTJ7QO5.js";import{jsx as t,jsxs as i,Fragment as a}from"react/jsx-runtime";var s="inline-flex items-center gap-1 whitespace-nowrap rounded-md border border-current/20 py-0.5 pl-2 pr-1 text-2xs font-medium";function o({label:e,glyph:r,onClick:l}){/* @__PURE__ */
2
2
  return t(n,{content:e,describe:!1,children:/* @__PURE__ */t("button",{type:"button",onClick:l,"aria-label":e,className:"flex h-4 w-4 items-center justify-center rounded-full leading-none hover:bg-current/10 rosh-focus-ring focus-visible:ring-2",children:/* @__PURE__ */t("span",{"aria-hidden":"true",children:r})})})}function c({state:n,label:c,verb:u,subject:m,pct:p,onCancel:d,onRetry:h,onDismiss:f,className:b=""}){const g=l().transfer;if("idle"===n)return null==c?null:/* @__PURE__ */t("span",{className:`${s} ${e.neutral} pr-2 ${b}`.trim(),children:c});if("error"===n)/* @__PURE__ */
3
3
  return i("span",{role:"status",className:`${s} ${e.danger} ${b}`.trim(),children:[
4
- /* @__PURE__ */t("span",{children:g.error}),h&&/* @__PURE__ */t(o,{label:g.retry,glyph:"↻",onClick:h}),f&&/* @__PURE__ */t(o,{label:g.dismiss,glyph:"×",onClick:f})]});const y=u??g.uploading,N=null==p||Number.isNaN(p)?null:Math.max(0,Math.min(100,Math.round(p))),$="string"==typeof y?g.cancelVerb(y.toLowerCase()):g.cancel,k=e=>[e,m,null==N?"":`${N}%`].filter(Boolean).join(" ");/* @__PURE__ */
5
- return i("span",{role:"status","aria-live":"polite",className:`${s} ${e.info} ${b}`.trim(),children:[null==N&&/* @__PURE__ */t(r,{ink:""}),
6
- /* @__PURE__ */t("span",{className:"tabular-nums",children:"string"==typeof y?k(y):/* @__PURE__ */i(a,{children:[y,k("")&&` ${k("")}`]})}),d&&/* @__PURE__ */t(o,{label:$,glyph:"×",onClick:d})]})}export{c as TransferProgress};
4
+ /* @__PURE__ */t("span",{children:g.error}),h&&/* @__PURE__ */t(o,{label:g.retry,glyph:"↻",onClick:h}),f&&/* @__PURE__ */t(o,{label:g.dismiss,glyph:"×",onClick:f})]});const N=u??g.uploading,y=null==p||Number.isNaN(p)?null:Math.max(0,Math.min(100,Math.round(p))),$="string"==typeof N?g.cancelVerb(N.toLowerCase()):g.cancel,k=e=>[e,m,null==y?"":`${y}%`].filter(Boolean).join(" ");/* @__PURE__ */
5
+ return i("span",{role:"status","aria-live":"polite",className:`${s} ${e.info} ${b}`.trim(),children:[null==y&&/* @__PURE__ */t(r,{ink:""}),
6
+ /* @__PURE__ */t("span",{className:"tabular-nums",children:"string"==typeof N?k(N):/* @__PURE__ */i(a,{children:[N,k("")&&` ${k("")}`]})}),d&&/* @__PURE__ */t(o,{label:$,glyph:"×",onClick:d})]})}export{c as TransferProgress};
@@ -1,3 +1,3 @@
1
- import{ColoredBadge as e}from"./chunk-OKHKY3ZZ.js";import{Button_default as n}from"./chunk-EOVXFXVV.js";import{useShellStrings as i}from"./chunk-GDQJBQ5B.js";import{useId as t}from"react";import{jsx as m,jsxs as a}from"react/jsx-runtime";function s({items:s,heading:l,emptyText:r,className:c=""}){const o=i().media,d=t();return s.length?/* @__PURE__ */a("div",{className:c||void 0,children:[
1
+ import{ColoredBadge as e}from"./chunk-YGCVMPIU.js";import{Button_default as n}from"./chunk-EOVXFXVV.js";import{useShellStrings as i}from"./chunk-VNTJ7QO5.js";import{useId as t}from"react";import{jsx as m,jsxs as a}from"react/jsx-runtime";function s({items:s,heading:l,emptyText:r,className:c=""}){const o=i().media,d=t();return s.length?/* @__PURE__ */a("div",{className:c||void 0,children:[
2
2
  /* @__PURE__ */m("p",{id:d,className:"text-xs font-medium text-ink-faint",children:l??o.usedIn(s.length)}),
3
3
  /* @__PURE__ */m("ul",{"aria-labelledby":d,className:"mt-2 flex flex-col gap-1",children:s.map(i=>/* @__PURE__ */a("li",{className:"flex min-w-0 items-center gap-2 text-sm",children:[null!=i.kind&&/* @__PURE__ */m(e,{size:"xs",className:"flex-none",children:i.kind}),i.onOpen?/* @__PURE__ */m(n,{variant:"link",size:"sm",onClick:i.onOpen,className:"min-w-0 text-left",children:i.name}):/* @__PURE__ */m("span",{className:"min-w-0 break-words text-ink",children:i.name})]},i.key))})]}):/* @__PURE__ */m("p",{className:`text-sm text-ink-faint ${c}`.trim(),children:r??o.notUsed})}export{s as MediaUsedInList};
@@ -1 +1 @@
1
- import{useShellLocale as e}from"./chunk-GDQJBQ5B.js";import{formatPlain as t}from"./chunk-C3QOHMR6.js";import{jsx as r,jsxs as n}from"react/jsx-runtime";var i={danger:"bg-red-600 text-white",neutral:"bg-gray-600 text-white",accent:"bg-blue-600 text-white"};function a({count:a=0,max:l=99,dot:s=!1,tone:o="danger",showZero:c=!1,children:m,className:u=""}){const h=s||a>0||0===a&&c,d=e(),x=a>l?`${t(l,d)}+`:t(a,d),f=m?"":u,g=h?/* @__PURE__ */r("span",s?{className:`block h-2.5 w-2.5 rounded-full ring-2 ring-white ${i[o]} ${f}`.trim(),"aria-hidden":m?"true":void 0}:{className:`flex h-5 min-w-[1.25rem] items-center justify-center whitespace-nowrap rounded-full px-1 text-xs font-semibold tabular-nums ring-2 ring-white ${i[o]} ${f}`.trim(),children:x}):null;return m?/* @__PURE__ */n("span",{className:`relative inline-flex ${u}`.trim(),children:[m,g&&/* @__PURE__ */r("span",{className:"absolute -right-1.5 -top-1.5 flex",children:g})]}):g}export{a as CountBadge};
1
+ import{useShellLocale as e}from"./chunk-VNTJ7QO5.js";import{formatPlain as t}from"./chunk-C3QOHMR6.js";import{jsx as r,jsxs as n}from"react/jsx-runtime";var i={danger:"bg-red-600 text-white",neutral:"bg-gray-600 text-white",accent:"bg-blue-600 text-white"};function a({count:a=0,max:l=99,dot:s=!1,tone:o="danger",showZero:c=!1,children:m,className:u=""}){const h=s||a>0||0===a&&c,d=e(),x=a>l?`${t(l,d)}+`:t(a,d),f=m?"":u,g=h?/* @__PURE__ */r("span",s?{className:`block h-2.5 w-2.5 rounded-full ring-2 ring-white ${i[o]} ${f}`.trim(),"aria-hidden":m?"true":void 0}:{className:`flex h-5 min-w-[1.25rem] items-center justify-center whitespace-nowrap rounded-full px-1 text-xs font-semibold tabular-nums ring-2 ring-white ${i[o]} ${f}`.trim(),children:x}):null;return m?/* @__PURE__ */n("span",{className:`relative inline-flex ${u}`.trim(),children:[m,g&&/* @__PURE__ */r("span",{className:"absolute -right-1.5 -top-1.5 flex",children:g})]}):g}export{a as CountBadge};
@@ -1,4 +1,4 @@
1
- import{Card as e}from"./chunk-P3RXXWXN.js";import{FormField as t}from"./chunk-6KBDNYRW.js";import{Checkbox_default as r}from"./chunk-CGZBDI6C.js";import{Input_default as l}from"./chunk-HNUKXGYP.js";import{Button_default as a}from"./chunk-EOVXFXVV.js";import{useState as i}from"react";import{jsx as c,jsxs as n,Fragment as s}from"react/jsx-runtime";var o={login:{title:"Welcome back",subtitle:"Sign in to your account",cta:"Sign in"},register:{title:"Create your account",subtitle:"Start your 14-day free trial",cta:"Create account"},forgot:{title:"Reset password",subtitle:"We'll email you a reset link",cta:"Send reset link"}};function m({mode:m="login"}){const[u,d]=i(!0),h=o[m];/* @__PURE__ */
1
+ import{Card as e}from"./chunk-ZDDYTXPK.js";import{FormField as t}from"./chunk-6KBDNYRW.js";import{Checkbox_default as r}from"./chunk-CGZBDI6C.js";import{Input_default as l}from"./chunk-2UTCGWMZ.js";import{Button_default as a}from"./chunk-EOVXFXVV.js";import{useState as i}from"react";import{jsx as c,jsxs as n,Fragment as s}from"react/jsx-runtime";var o={login:{title:"Welcome back",subtitle:"Sign in to your account",cta:"Sign in"},register:{title:"Create your account",subtitle:"Start your 14-day free trial",cta:"Create account"},forgot:{title:"Reset password",subtitle:"We'll email you a reset link",cta:"Send reset link"}};function m({mode:m="login"}){const[u,d]=i(!0),h=o[m];/* @__PURE__ */
2
2
  return c("div",{className:"flex h-full items-center justify-center overflow-auto bg-gray-50 p-6",children:/* @__PURE__ */n("div",{className:"w-full max-w-sm",children:[
3
3
  /* @__PURE__ */n("div",{className:"mb-6 text-center",children:[
4
4
  /* @__PURE__ */c("div",{className:"mx-auto mb-3 flex h-10 w-10 items-center justify-center rounded-lg bg-blue-600 text-sm font-bold text-white",children:"A"}),
@@ -1,27 +1,27 @@
1
- import{buildQuerySections as e,buildEmptySections as t,flattenRows as r,DEFAULT_MAGNIFIER as n,stepIndex as a,nextGroupIndex as s,SEE_ALL_ICON as l,resultTypeKey as o}from"./chunk-WGRS6QBT.js";import{useDismissPopupsOnOpen as i}from"./chunk-7QSDPSXP.js";import{SpinnerRing as c,LoadingSpinner as d}from"./chunk-R2VKEMZH.js";import{Z_LAYERS as u}from"./chunk-62LW225J.js";import{glassStyle as p}from"./chunk-5FYDNH4Y.js";import{useShellStrings as m}from"./chunk-GDQJBQ5B.js";import{useState as h,useRef as f,useEffect as y,useMemo as g,useId as x,useCallback as b}from"react";import{createPortal as k}from"react-dom";import{jsxs as v,jsx as w}from"react/jsx-runtime";function N(e){if(Array.isArray(e))return{results:e,truncatedTypes:[]};if(e&&"object"==typeof e&&Array.isArray(e.results)){const{results:t,truncatedTypes:r}=e;return{results:t,truncatedTypes:Array.isArray(r)?r:[]}}return{results:[],truncatedTypes:[]}}var A=[];function L(e,t,r){const[n,a]=h([]),[s,l]=h(A),[o,i]=h(!1),[c,d]=h("none"),u=f(function(){let e=0,t=null;const r=()=>{e+=1,t?.abort(),t=null};return{begin:()=>{r();const n=e,a=new AbortController;return t=a,{signal:a.signal,isCurrent:()=>n===e}},cancel:r}}());y(()=>{const n=u.current;if(e.length<r||!t||0===t.length)return n.cancel(),a(e=>0===e.length?e:[]),l(A),d("none"),void i(!1);i(!0);const s=setTimeout(async()=>{const r=n.begin(),s=await async function(e,t,r){const n=await Promise.all(e.map(async e=>{try{return{failed:!1,...N(await e(t,{signal:r}))}}catch(e){const t=r.aborted||function(e){if(!e||"object"!=typeof e)return!1;const{name:t,code:r}=e;return"AbortError"===t||"CanceledError"===t||"ERR_CANCELED"===r}(e);return{failed:!t,results:[],truncatedTypes:[]}}}));return{results:n.flatMap(e=>e.results),truncatedTypes:Array.from(new Set(n.flatMap(e=>e.truncatedTypes))),failed:n.filter(e=>e.failed).length}}(t,e,r.signal);r.isCurrent()&&(a(s.results),l(s.truncatedTypes),d(0===s.failed?"none":s.failed>=t.length?"all":"some"),i(!1))},250);return()=>{clearTimeout(s),n.cancel()}},[e,t,r]);return{results:n,truncatedTypes:s,loading:o,failure:c,reset:b(()=>{u.current.cancel(),a(e=>0===e.length?e:[]),l(A),d("none"),i(!1)},[])}}var C=(e,t)=>`${e}-opt-${t}`;function E(e,t){if("seeAll"===e.kind)return l;if("action"===e.kind)return e.icon??n;if(e.icon)return e.icon;const r=t?.[o(e.result)];return r||n}function T({sections:e,activeIdx:t,listId:r,label:n,typeIcons:a,groupCount:s,groupLabel:l,onHover:o,onPick:i}){let c=0;/* @__PURE__ */
1
+ import{buildQuerySections as e,buildEmptySections as t,flattenRows as r,DEFAULT_MAGNIFIER as n,stepIndex as a,nextGroupIndex as s,SEE_ALL_ICON as l,resultTypeKey as o}from"./chunk-WGRS6QBT.js";import{useDismissPopupsOnOpen as i}from"./chunk-7QSDPSXP.js";import{SpinnerRing as c,LoadingSpinner as d}from"./chunk-R2VKEMZH.js";import{Z_LAYERS as u}from"./chunk-62LW225J.js";import{glassStyle as p}from"./chunk-5FYDNH4Y.js";import{useShellStrings as m}from"./chunk-VNTJ7QO5.js";import{useState as h,useRef as f,useEffect as y,useMemo as g,useId as x,useCallback as b}from"react";import{createPortal as k}from"react-dom";import{jsxs as v,jsx as w}from"react/jsx-runtime";function N(e){if(Array.isArray(e))return{results:e,truncatedTypes:[]};if(e&&"object"==typeof e&&Array.isArray(e.results)){const{results:t,truncatedTypes:r}=e;return{results:t,truncatedTypes:Array.isArray(r)?r:[]}}return{results:[],truncatedTypes:[]}}var A=[];function L(e,t,r){const[n,a]=h([]),[s,l]=h(A),[o,i]=h(!1),[c,d]=h("none"),u=f(function(){let e=0,t=null;const r=()=>{e+=1,t?.abort(),t=null};return{begin:()=>{r();const n=e,a=new AbortController;return t=a,{signal:a.signal,isCurrent:()=>n===e}},cancel:r}}());y(()=>{const n=u.current;if(e.length<r||!t||0===t.length)return n.cancel(),a(e=>0===e.length?e:[]),l(A),d("none"),void i(!1);i(!0);const s=setTimeout(async()=>{const r=n.begin(),s=await async function(e,t,r){const n=await Promise.all(e.map(async e=>{try{return{failed:!1,...N(await e(t,{signal:r}))}}catch(e){const t=r.aborted||function(e){if(!e||"object"!=typeof e)return!1;const{name:t,code:r}=e;return"AbortError"===t||"CanceledError"===t||"ERR_CANCELED"===r}(e);return{failed:!t,results:[],truncatedTypes:[]}}}));return{results:n.flatMap(e=>e.results),truncatedTypes:Array.from(new Set(n.flatMap(e=>e.truncatedTypes))),failed:n.filter(e=>e.failed).length}}(t,e,r.signal);r.isCurrent()&&(a(s.results),l(s.truncatedTypes),d(0===s.failed?"none":s.failed>=t.length?"all":"some"),i(!1))},250);return()=>{clearTimeout(s),n.cancel()}},[e,t,r]);return{results:n,truncatedTypes:s,loading:o,failure:c,reset:b(()=>{u.current.cancel(),a(e=>0===e.length?e:[]),l(A),d("none"),i(!1)},[])}}var C=(e,t)=>`${e}-opt-${t}`;function T(e,t){if("seeAll"===e.kind)return l;if("action"===e.kind)return e.icon??n;if(e.icon)return e.icon;const r=t?.[o(e.result)];return r||n}function E({sections:e,activeIdx:t,listId:r,label:n,typeIcons:a,groupCount:s,groupLabel:l,onHover:o,onPick:i}){let c=0;/* @__PURE__ */
2
2
  return w("div",{id:r,role:"listbox","aria-label":n,className:"py-1",children:e.map(e=>/* @__PURE__ */v("div",{role:"group","aria-label":l(e.title,e.count,!!e.truncated),children:[
3
3
  /* @__PURE__ */v("div",{"aria-hidden":"true",className:"flex items-center justify-between px-4 pt-2 pb-1 text-2xs font-semibold uppercase tracking-wide text-ink-faintest",children:[
4
4
  /* @__PURE__ */w("span",{children:e.title}),
5
5
  /* @__PURE__ */w("span",{className:"font-medium normal-case tracking-normal",children:s(e.count,!!e.truncated)})]}),e.rows.map(e=>{const n=c++,s=n===t,l="action"===e.kind||"seeAll"===e.kind?void 0:e.badge,d="action"===e.kind||"seeAll"===e.kind?void 0:e.sub,u="seeAll"===e.kind;/* @__PURE__ */
6
6
  return v("div",{id:C(r,n),role:"option","aria-selected":s,className:"flex items-center gap-3 w-full px-4 py-3 text-left cursor-pointer transition-colors "+(s?"bg-blue-50":"hover:bg-gray-50"),onMouseDown:e=>e.preventDefault(),onClick:()=>i(e),onMouseEnter:()=>o(n),children:[
7
- /* @__PURE__ */w("svg",{className:"h-4 w-4 text-gray-400 shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,"aria-hidden":"true",children:/* @__PURE__ */w("path",{strokeLinecap:"round",strokeLinejoin:"round",d:E(e,a)})}),
7
+ /* @__PURE__ */w("svg",{className:"h-4 w-4 text-gray-400 shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,"aria-hidden":"true",children:/* @__PURE__ */w("path",{strokeLinecap:"round",strokeLinejoin:"round",d:T(e,a)})}),
8
8
  /* @__PURE__ */v("div",{className:"flex-1 min-w-0",children:[
9
- /* @__PURE__ */w("p",{className:"text-sm font-medium truncate "+(u?"text-blue-600":"text-gray-900"),children:e.label}),d&&/* @__PURE__ */w("p",{className:"text-xs text-gray-400 truncate",children:d})]}),l&&/* @__PURE__ */w("span",{className:"shrink-0 rounded-full bg-gray-100 px-2 py-0.5 text-3xs font-medium text-ink-faint",children:l})]},e.key)})]},e.key))})}var j="react-os-shell:open-global-search";function D(){"undefined"!=typeof window&&window.dispatchEvent(new CustomEvent(j))}function I({providers:l,typeIcons:o,typeLabels:N,listRoutes:A,placeholder:E,quickActions:D,onSelect:I,recent:K,onRecord:R,favorites:B,hotkey:M=!0}={}){const P=m().search,S=E??P.placeholder,[$,H]=h(!1),[Q,W]=h(""),[z,F]=h(0),G=f(null),{results:J,truncatedTypes:V,loading:Y,failure:q,reset:U}=L(Q,l,2);y(()=>{const e=e=>{M&&!e.defaultPrevented&&(e.ctrlKey||e.metaKey)&&"k"===e.key&&(e.preventDefault(),H(e=>!e)),"Escape"===e.key&&$&&H(!1)},t=()=>H(!0);return window.addEventListener("keydown",e),window.addEventListener(j,t),()=>{window.removeEventListener("keydown",e),window.removeEventListener(j,t)}},[$,M]),i($);const[X,Z]=h(!1);$!==X&&(Z($),$&&(W(""),F(0),U())),y(()=>{$?setTimeout(()=>G.current?.focus(),50):W("")},[$]),y(()=>{F(0)},[J]);const _=Q.length>=2,O=g(()=>_?e(J,D,Q,P.actions,{truncatedTypes:V,listRoutes:A,typeLabels:N,seeAllLabel:P.seeAll}):t({recent:K,favorites:B,actions:D,typeLabels:N},P),[_,J,V,A,N,D,Q,K,B,P]),ee=g(()=>r(O),[O]),te=Math.min(z,Math.max(ee.length-1,0)),re=x(),ne=ee.length>0;y(()=>{$&&0!==ee.length&&document.getElementById(C(re,te))?.scrollIntoView?.({block:"nearest"})},[$,te,ee.length,re]);const ae=b(e=>{H(!1),"action"!==e.kind?("result"!==e.kind&&"recent"!==e.kind||R?.(e.result),I?.(e.result)):e.action.onSelect()},[I,R]);return $?k(
9
+ /* @__PURE__ */w("p",{className:"text-sm font-medium truncate "+(u?"text-blue-600":"text-gray-900"),children:e.label}),d&&/* @__PURE__ */w("p",{className:"text-xs text-gray-400 truncate",children:d})]}),l&&/* @__PURE__ */w("span",{className:"shrink-0 rounded-full bg-gray-100 px-2 py-0.5 text-3xs font-medium text-ink-faint",children:l})]},e.key)})]},e.key))})}var j="react-os-shell:open-global-search";function D(){"undefined"!=typeof window&&window.dispatchEvent(new CustomEvent(j))}function I({providers:l,typeIcons:o,typeLabels:N,listRoutes:A,placeholder:T,quickActions:D,onSelect:I,recent:K,onRecord:R,favorites:M,hotkey:P=!0}={}){const S=m().search,$=T??S.placeholder,[B,H]=h(!1),[W,z]=h(""),[F,Q]=h(0),V=f(null),{results:G,truncatedTypes:J,loading:Y,failure:q,reset:O}=L(W,l,2);y(()=>{const e=e=>{P&&!e.defaultPrevented&&(e.ctrlKey||e.metaKey)&&"k"===e.key&&(e.preventDefault(),H(e=>!e)),"Escape"===e.key&&B&&H(!1)},t=()=>H(!0);return window.addEventListener("keydown",e),window.addEventListener(j,t),()=>{window.removeEventListener("keydown",e),window.removeEventListener(j,t)}},[B,P]),i(B);const[U,X]=h(!1);B!==U&&(X(B),B&&(z(""),Q(0),O())),y(()=>{B?setTimeout(()=>V.current?.focus(),50):z("")},[B]),y(()=>{Q(0)},[G]);const Z=W.length>=2,_=g(()=>Z?e(G,D,W,S.actions,{truncatedTypes:J,listRoutes:A,typeLabels:N,seeAllLabel:S.seeAll}):t({recent:K,favorites:M,actions:D,typeLabels:N},S),[Z,G,J,A,N,D,W,K,M,S]),ee=g(()=>r(_),[_]),te=Math.min(F,Math.max(ee.length-1,0)),re=x(),ne=ee.length>0;y(()=>{B&&0!==ee.length&&document.getElementById(C(re,te))?.scrollIntoView?.({block:"nearest"})},[B,te,ee.length,re]);const ae=b(e=>{H(!1),"action"!==e.kind?("result"!==e.kind&&"recent"!==e.kind||R?.(e.result),I?.(e.result)):e.action.onSelect()},[I,R]);return B?k(
10
10
  /* @__PURE__ */v("div",{"data-global-search":"",className:"fixed inset-0 flex items-start justify-center pt-[15vh]",style:{zIndex:u.overlay},onClick:()=>H(!1),children:[
11
11
  /* @__PURE__ */w("div",{"data-global-search-backdrop":"",className:"absolute inset-0 bg-black/50 backdrop-blur-sm"}),
12
12
  /* @__PURE__ */v("div",{className:"relative z-10 w-full max-w-xl rounded-(--radius-popup) overflow-hidden",onClick:e=>e.stopPropagation(),style:p(),children:[
13
13
  /* @__PURE__ */v("div",{className:"flex items-center gap-3 px-4 py-3 border-b border-gray-200",children:[
14
14
  /* @__PURE__ */w("svg",{className:"h-5 w-5 text-gray-400 shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:/* @__PURE__ */w("path",{strokeLinecap:"round",strokeLinejoin:"round",d:n})}),
15
- /* @__PURE__ */w("input",{ref:G,type:"text",value:Q,onChange:e=>{W(e.target.value),F(0)},onKeyDown:e=>{"ArrowDown"===e.key?(e.preventDefault(),F(a(te,1,ee.length))):"ArrowUp"===e.key?(e.preventDefault(),F(a(te,-1,ee.length))):"Tab"===e.key&&ee.length>0?(e.preventDefault(),F(s(O.map(e=>e.rows.length),te,e.shiftKey?-1:1))):"Enter"===e.key&&ee[te]&&ae(ee[te])},placeholder:S,role:"combobox","aria-expanded":ne,"aria-controls":ne?re:void 0,"aria-activedescendant":ne?C(re,te):void 0,"aria-autocomplete":"list",className:"flex-1 text-sm bg-transparent border-0 rosh-focus-ring placeholder-gray-400"}),Y&&/* @__PURE__ */w("span",{"data-global-search-spinner":"",role:"status","aria-label":P.searching,className:"flex shrink-0",children:/* @__PURE__ */w(c,{className:"h-4 w-4",ink:"text-ink-faint"})}),
16
- /* @__PURE__ */w("kbd",{className:"hidden sm:inline-flex items-center rounded border border-line-strong px-2 py-0.5 text-2xs font-medium text-ink-faintest",children:P.escBadge})]}),
17
- /* @__PURE__ */v("div",{className:"max-h-[50vh] overflow-y-auto",children:[Y&&0===ee.length&&/* @__PURE__ */w(d,{size:"sm",padding:"py-6",label:P.searching}),!Y&&"all"===q&&_&&/* @__PURE__ */w("div",{role:"alert",className:"px-4 py-3 text-center text-sm text-red-600",children:P.searchFailed}),!Y&&_&&0===ee.length&&"all"!==q&&/* @__PURE__ */w("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:P.noResults}),ne&&/* @__PURE__ */w(T,{sections:O,activeIdx:te,listId:re,label:P.listLabel,typeIcons:o,groupCount:P.groupCount,groupLabel:P.groupLabel,onHover:F,onPick:ae}),!Y&&"some"===q&&_&&/* @__PURE__ */w("div",{role:"status",className:"px-4 py-2 text-xs text-amber-600",children:P.partialFailure}),!Y&&!_&&0===ee.length&&/* @__PURE__ */w("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:P.minChars(2)})]}),
15
+ /* @__PURE__ */w("input",{ref:V,type:"text",value:W,onChange:e=>{z(e.target.value),Q(0)},onKeyDown:e=>{"ArrowDown"===e.key?(e.preventDefault(),Q(a(te,1,ee.length))):"ArrowUp"===e.key?(e.preventDefault(),Q(a(te,-1,ee.length))):"Tab"===e.key&&ee.length>0?(e.preventDefault(),Q(s(_.map(e=>e.rows.length),te,e.shiftKey?-1:1))):"Enter"===e.key&&ee[te]&&ae(ee[te])},placeholder:$,role:"combobox","aria-expanded":ne,"aria-controls":ne?re:void 0,"aria-activedescendant":ne?C(re,te):void 0,"aria-autocomplete":"list",className:"flex-1 text-sm bg-transparent border-0 rosh-focus-ring placeholder-gray-400"}),Y&&/* @__PURE__ */w("span",{"data-global-search-spinner":"",role:"status","aria-label":S.searching,className:"flex shrink-0",children:/* @__PURE__ */w(c,{className:"h-4 w-4",ink:"text-ink-faint"})}),
16
+ /* @__PURE__ */w("kbd",{className:"hidden sm:inline-flex items-center rounded border border-line-strong px-2 py-0.5 text-2xs font-medium text-ink-faintest",children:S.escBadge})]}),
17
+ /* @__PURE__ */v("div",{className:"max-h-[50vh] overflow-y-auto",children:[Y&&0===ee.length&&/* @__PURE__ */w(d,{size:"sm",padding:"py-6",label:S.searching}),!Y&&"all"===q&&Z&&/* @__PURE__ */w("div",{role:"alert",className:"px-4 py-3 text-center text-sm text-red-600",children:S.searchFailed}),!Y&&Z&&0===ee.length&&"all"!==q&&/* @__PURE__ */w("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:S.noResults}),ne&&/* @__PURE__ */w(E,{sections:_,activeIdx:te,listId:re,label:S.listLabel,typeIcons:o,groupCount:S.groupCount,groupLabel:S.groupLabel,onHover:Q,onPick:ae}),!Y&&"some"===q&&Z&&/* @__PURE__ */w("div",{role:"status",className:"px-4 py-2 text-xs text-amber-600",children:S.partialFailure}),!Y&&!Z&&0===ee.length&&/* @__PURE__ */w("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:S.minChars(2)})]}),
18
18
  /* @__PURE__ */v("div",{className:"flex items-center justify-between px-4 py-2 border-t border-line-subtle bg-surface-sunken text-2xs text-ink-faintest",children:[
19
19
  /* @__PURE__ */v("div",{className:"flex items-center gap-3",children:[
20
20
  /* @__PURE__ */v("span",{className:"flex items-center gap-1",children:[
21
21
  /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:"↑"}),
22
- /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:"↓"}),` ${P.navigate}`]}),
22
+ /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:"↓"}),` ${S.navigate}`]}),
23
23
  /* @__PURE__ */v("span",{className:"flex items-center gap-1",children:[
24
- /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:P.enterKey}),` ${P.open}`]}),O.length>1&&/* @__PURE__ */v("span",{className:"flex items-center gap-1",children:[
25
- /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:P.tabKey}),` ${P.nextGroup}`]})]}),
24
+ /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:S.enterKey}),` ${S.open}`]}),_.length>1&&/* @__PURE__ */v("span",{className:"flex items-center gap-1",children:[
25
+ /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:S.tabKey}),` ${S.nextGroup}`]})]}),
26
26
  /* @__PURE__ */v("span",{className:"flex items-center gap-1",children:[
27
- /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:P.escKey}),` ${P.close}`]})]})]})]}),document.body):null}export{I as GlobalSearch,D as openGlobalSearch};
27
+ /* @__PURE__ */w("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:S.escKey}),` ${S.close}`]})]})]})]}),document.body):null}export{I as GlobalSearch,D as openGlobalSearch};
@@ -1,9 +1,9 @@
1
- import{ChartDefs as t,MOTION as e,stagger as a,glowId as i}from"./chunk-465RRWBY.js";import{ChartSkeleton as n}from"./chunk-3IUPYCW3.js";import{useHighlight as o,autoHighlightIndex as l,highlightOpacity as r}from"./chunk-CNYAHYE6.js";import{ChartTooltip as s}from"./chunk-36VIGB6J.js";import{CartesianPlot as m}from"./chunk-QO5E33DH.js";import{useDragZoom as u,ChartZoomSummary as c}from"./chunk-C764JODK.js";import{CHART_INK as d,resolveSeriesColor as h,STATUS_VARS as f}from"./chunk-TZFACUMR.js";import{useShellStrings as p,useShellLocale as b}from"./chunk-GDQJBQ5B.js";import{formatPercent as x,formatPlain as y}from"./chunk-C3QOHMR6.js";import{useId as v}from"react";import{jsx as M,jsxs as g,Fragment as k}from"react/jsx-runtime";function w({stacked:w=!1,stackMode:N="value",height:$=220,width:C,max:j,formatValue:F,yAxisLabel:L,className:A,emptyLabel:z,radius:T=3,loading:V=!1,animate:B=!0,glow:O=!1,emphasise:S=!1,activeKey:E,highlight:Q="none",valueLabels:R=!1,onSelect:Y,min:D,formatTooltipValue:G,tooltipLabels:H,barGap:J=4,seriesLabels:W=!1,zoomable:I=!0,series:K,labels:U}){const P=v(),Z=u(U.length,I),q=Z.view?.[0]??0,X=Z.slice(U),_=H?Z.slice(H):void 0,tt=K.map(t=>({...t,data:Z.slice(t.data),pointTones:t.pointTones?Z.slice(t.pointTones):void 0,pointColors:t.pointColors?Z.slice(t.pointColors):void 0})),{highlighted:et}=o(),at=p().charts,it=b(),nt=F??(t=>y(t,it)),ot=G??nt;if(V)/* @__PURE__ */return M(n,{height:$,width:C,variant:"bars",className:A});const lt=(t,e)=>{const a=t.pointColors?.[e];if(a)return a;const i=t.pointTones?.[e];return i?f[i]:h(t.slot,t.color,t.tone)},rt=tt.map((t,e)=>({...t,slot:e})).filter(t=>t.data.some(t=>Number.isFinite(t))),st=(t,e)=>{const a=t.data[e];return"number"==typeof a&&Number.isFinite(a)?a:0},mt=X.map((t,e)=>rt.reduce((t,a)=>t+st(a,e),0)),ut=X.map((t,e)=>rt.reduce((t,a)=>t+Math.max(0,st(a,e)),0)),ct=X.map((t,e)=>rt.reduce((t,a)=>t+Math.min(0,st(a,e)),0)),dt=w&&"percent"===N,ht=(t,e)=>mt[e]>0?t/mt[e]:null,ft=dt?[1]:w?[...ut,...ct]:rt.flatMap(t=>t.data.filter(Number.isFinite)),pt=(t,e)=>{const a=t.bandwidth/Math.max(1,rt.length),i=rt.length>1?Math.min(J,.25*a):0;return{offset:e*a+i/2,width:Math.max(1,a-i)}},bt=W&&!w?({x:t,y:e})=>{const a=Math.min(e.domain[1],Math.max(e.domain[0],0));return X.map((i,n)=>rt.map((i,o)=>{const l=i.data[n];if(!Number.isFinite(l))return null;const r=Math.min(e.domain[1],Math.max(e.domain[0],l)),{offset:s,width:m}=pt(t,o),u=t(n)+s+m/2,c=Math.min(e(r),e(a)),h=Math.max(e(r),e(a));if(m<13)return null;const f=Math.floor((h-c-12)/6.6),p=f>=Math.min(4,i.label.length),b=p&&i.label.length>f?`${i.label.slice(0,f-1).trimEnd()}…`:i.label,x=p?h-6:c-4;/* @__PURE__ */
1
+ import{ChartDefs as t,MOTION as e,stagger as a,glowId as i}from"./chunk-465RRWBY.js";import{ChartSkeleton as n}from"./chunk-SZTIP6T7.js";import{useHighlight as o,autoHighlightIndex as l,highlightOpacity as r}from"./chunk-CNYAHYE6.js";import{ChartTooltip as s}from"./chunk-36VIGB6J.js";import{CartesianPlot as m}from"./chunk-WQGBYFS3.js";import{useDragZoom as u,ChartZoomSummary as c}from"./chunk-EMUZJMR3.js";import{CHART_INK as d,resolveSeriesColor as h,STATUS_VARS as f}from"./chunk-TZFACUMR.js";import{useShellStrings as p,useShellLocale as b}from"./chunk-VNTJ7QO5.js";import{formatPercent as x,formatPlain as y}from"./chunk-C3QOHMR6.js";import{useId as v}from"react";import{jsx as M,jsxs as g,Fragment as k}from"react/jsx-runtime";function w({stacked:w=!1,stackMode:N="value",height:$=220,width:j,max:C,formatValue:F,yAxisLabel:T,className:L,emptyLabel:A,radius:S=3,loading:V=!1,animate:z=!0,glow:R=!1,emphasise:B=!1,activeKey:E,highlight:O="none",valueLabels:Y=!1,onSelect:G,min:J,formatTooltipValue:Q,tooltipLabels:W,barGap:Z=4,seriesLabels:H=!1,zoomable:I=!0,series:U,labels:K}){const P=v(),q=u(K.length,I),D=q.view?.[0]??0,X=q.slice(K),_=W?q.slice(W):void 0,tt=U.map(t=>({...t,data:q.slice(t.data),pointTones:t.pointTones?q.slice(t.pointTones):void 0,pointColors:t.pointColors?q.slice(t.pointColors):void 0})),{highlighted:et}=o(),at=p().charts,it=b(),nt=F??(t=>y(t,it)),ot=Q??nt;if(V)/* @__PURE__ */return M(n,{height:$,width:j,variant:"bars",className:L});const lt=(t,e)=>{const a=t.pointColors?.[e];if(a)return a;const i=t.pointTones?.[e];return i?f[i]:h(t.slot,t.color,t.tone)},rt=tt.map((t,e)=>({...t,slot:e})).filter(t=>t.data.some(t=>Number.isFinite(t))),st=(t,e)=>{const a=t.data[e];return"number"==typeof a&&Number.isFinite(a)?a:0},mt=X.map((t,e)=>rt.reduce((t,a)=>t+st(a,e),0)),ut=X.map((t,e)=>rt.reduce((t,a)=>t+Math.max(0,st(a,e)),0)),ct=X.map((t,e)=>rt.reduce((t,a)=>t+Math.min(0,st(a,e)),0)),dt=w&&"percent"===N,ht=(t,e)=>mt[e]>0?t/mt[e]:null,ft=dt?[1]:w?[...ut,...ct]:rt.flatMap(t=>t.data.filter(Number.isFinite)),pt=(t,e)=>{const a=t.bandwidth/Math.max(1,rt.length),i=rt.length>1?Math.min(Z,.25*a):0;return{offset:e*a+i/2,width:Math.max(1,a-i)}},bt=H&&!w?({x:t,y:e})=>{const a=Math.min(e.domain[1],Math.max(e.domain[0],0));return X.map((i,n)=>rt.map((i,o)=>{const l=i.data[n];if(!Number.isFinite(l))return null;const r=Math.min(e.domain[1],Math.max(e.domain[0],l)),{offset:s,width:m}=pt(t,o),u=t(n)+s+m/2,c=Math.min(e(r),e(a)),h=Math.max(e(r),e(a));if(m<13)return null;const f=Math.floor((h-c-12)/6.6),p=f>=Math.min(4,i.label.length),b=p&&i.label.length>f?`${i.label.slice(0,f-1).trimEnd()}…`:i.label,x=p?h-6:c-4;/* @__PURE__ */
2
2
  return M("text",{"data-series-label":"true",x:u,y:x,transform:`rotate(-90 ${u} ${x})`,textAnchor:"start",dominantBaseline:"central",fontSize:11,fill:p?d.surface:d.label,children:b},`n${i.key}-${n}`)}))}:null;/* @__PURE__ */
3
3
  return g(k,{children:[
4
- /* @__PURE__ */M(m,{labels:X,values:ft,height:$,width:C,max:dt?1:j,min:dt?void 0:D,formatValue:dt?t=>x(Math.round(100*t),0,it):nt,yAxisLabel:L,className:A,emptyLabel:z,onSelect:Y?t=>Y(q+t):void 0,zoom:I?Z:void 0,ariaLabel:at.acrossCategories(rt.map(t=>t.label),X.length),tooltip:t=>/* @__PURE__ */M(s,{title:_?.[t]??X[t],rows:rt.map(e=>({key:e.key,label:e.label,color:lt(e,t),value:Number.isFinite(e.data[t])?dt?`${x(100*(ht(e.data[t],t)??0),1,it)} · ${ot(e.data[t])}`:ot(e.data[t]):void 0})),footnote:dt?at.inCategory(ot(mt[t])):void 0}),overlay:R&&!dt||bt?({x:t,y:e})=>/* @__PURE__ */g("g",{pointerEvents:"none",children:[bt?.({x:t,y:e}),R&&!dt&&X.map((a,i)=>{if(w){if(!rt.some(t=>Number.isFinite(t.data[i])))return null;const a=rt.reduce((t,e)=>t+st(e,i),0),n=a>=0?ut[i]:ct[i];/* @__PURE__ */
4
+ /* @__PURE__ */M(m,{labels:X,values:ft,height:$,width:j,max:dt?1:C,min:dt?void 0:J,formatValue:dt?t=>x(Math.round(100*t),0,it):nt,yAxisLabel:T,className:L,emptyLabel:A,onSelect:G?t=>G(D+t):void 0,zoom:I?q:void 0,ariaLabel:at.acrossCategories(rt.map(t=>t.label),X.length),tooltip:t=>/* @__PURE__ */M(s,{title:_?.[t]??X[t],rows:rt.map(e=>({key:e.key,label:e.label,color:lt(e,t),value:Number.isFinite(e.data[t])?dt?`${x(100*(ht(e.data[t],t)??0),1,it)} · ${ot(e.data[t])}`:ot(e.data[t]):void 0})),footnote:dt?at.inCategory(ot(mt[t])):void 0}),overlay:Y&&!dt||bt?({x:t,y:e})=>/* @__PURE__ */g("g",{pointerEvents:"none",children:[bt?.({x:t,y:e}),Y&&!dt&&X.map((a,i)=>{if(w){if(!rt.some(t=>Number.isFinite(t.data[i])))return null;const a=rt.reduce((t,e)=>t+st(e,i),0),n=a>=0?ut[i]:ct[i];/* @__PURE__ */
5
5
  return M("text",{"data-value-label":"true",x:t.center(i),y:a>=0?e(n)-4:e(n)+12,textAnchor:"middle",fontSize:11,fill:d.label,style:{fontVariantNumeric:"tabular-nums"},children:nt(a)},`v${i}`)}return rt.map((a,n)=>{const o=a.data[i];if(!Number.isFinite(o))return null;const l=o,{offset:r,width:s}=pt(t,n);/* @__PURE__ */
6
- return M("text",{"data-value-label":"true",x:t(i)+r+s/2,y:l>=0?e(l)-4:e(l)+12,textAnchor:"middle",fontSize:11,fill:d.label,style:{fontVariantNumeric:"tabular-nums"},children:nt(l)},`v${a.key}-${i}`)})})]}):void 0,children:({x:n,y:o,bottom:s,active:m})=>{const u=E?X.indexOf(E):-1,c=l(w?mt:rt[0]?.data??[],Q),h=m??(u>=0?u:c);/* @__PURE__ */
6
+ return M("text",{"data-value-label":"true",x:t(i)+r+s/2,y:l>=0?e(l)-4:e(l)+12,textAnchor:"middle",fontSize:11,fill:d.label,style:{fontVariantNumeric:"tabular-nums"},children:nt(l)},`v${a.key}-${i}`)})})]}):void 0,children:({x:n,y:o,bottom:s,active:m})=>{const u=E?X.indexOf(E):-1,c=l(w?mt:rt[0]?.data??[],O),h=m??(u>=0?u:c);/* @__PURE__ */
7
7
  return g("g",{children:[
8
- /* @__PURE__ */M(t,{id:P,glow:O}),X.map((t,l)=>{let s=0,m=0;const u=o(Math.min(o.domain[1],Math.max(o.domain[0],0)));return rt.map((t,c)=>{const f=t.data[l];if(!Number.isFinite(f))return null;const p=dt?ht(f,l):f;if(null===p)return null;const b=lt(t,l),x=pt(n,c),y=w?n(l):n(l)+x.offset,v=w?Math.max(1,n.bandwidth):x.width;let g,k,N=!0;if(w){const t=p>=0?s:m,e=t+p;p>=0?s=e:m=e,g=o(Math.max(t,e)),k=o(Math.min(t,e)),N=0===t}else g=Math.min(o(p),u),k=Math.max(o(p),u);const $=Math.max(0,k-g-(w&&!N?2:0)),C=null===h||h===l,j=C?b:S?d.muted:b,F=r(t.key,et);/* @__PURE__ */
9
- return M("rect",{x:y,y:g,width:v,height:$,rx:T,fill:j,fillOpacity:F??(C?1:S?.32:.45),filter:O&&h===l?`url(#${i(P)})`:void 0,className:"rosh-viz-mark"+(B?` ${e.rise}`:""),style:B?a(l*(w?1:rt.length)+c,26):void 0},`${t.key}-${l}`)})}),null!==m&&!S&&/* @__PURE__ */M("line",{x1:n.center(m),y1:o(o.domain[1]),x2:n.center(m),y2:s,stroke:d.axis,strokeWidth:1})]})}}),Z.view&&/* @__PURE__ */M(c,{from:_?.[0]??X[0],to:_?.at(-1)??X[X.length-1],count:X.length,total:w?ot(mt.reduce((t,e)=>t+e,0)):void 0,rows:rt.map(t=>({s:t,sum:t.data.reduce((e,a,i)=>e+st(t,i),0)})).sort((t,e)=>e.sum-t.sum).map(({s:t,sum:e})=>({key:t.key,label:t.label,color:h(t.slot,t.color,t.tone),value:ot(e)})),onClear:Z.clear})]})}export{w as ColumnChart};
8
+ /* @__PURE__ */M(t,{id:P,glow:R}),X.map((t,l)=>{let s=0,m=0;const u=o(Math.min(o.domain[1],Math.max(o.domain[0],0)));return rt.map((t,c)=>{const f=t.data[l];if(!Number.isFinite(f))return null;const p=dt?ht(f,l):f;if(null===p)return null;const b=lt(t,l),x=pt(n,c),y=w?n(l):n(l)+x.offset,v=w?Math.max(1,n.bandwidth):x.width;let g,k,N=!0;if(w){const t=p>=0?s:m,e=t+p;p>=0?s=e:m=e,g=o(Math.max(t,e)),k=o(Math.min(t,e)),N=0===t}else g=Math.min(o(p),u),k=Math.max(o(p),u);const $=Math.max(0,k-g-(w&&!N?2:0)),j=null===h||h===l,C=j?b:B?d.muted:b,F=r(t.key,et);/* @__PURE__ */
9
+ return M("rect",{x:y,y:g,width:v,height:$,rx:S,fill:C,fillOpacity:F??(j?1:B?.32:.45),filter:R&&h===l?`url(#${i(P)})`:void 0,className:"rosh-viz-mark"+(z?` ${e.rise}`:""),style:z?a(l*(w?1:rt.length)+c,26):void 0},`${t.key}-${l}`)})}),null!==m&&!B&&/* @__PURE__ */M("line",{x1:n.center(m),y1:o(o.domain[1]),x2:n.center(m),y2:s,stroke:d.axis,strokeWidth:1})]})}}),q.view&&/* @__PURE__ */M(c,{from:_?.[0]??X[0],to:_?.at(-1)??X[X.length-1],count:X.length,total:w?ot(mt.reduce((t,e)=>t+e,0)):void 0,rows:rt.map(t=>({s:t,sum:t.data.reduce((e,a,i)=>e+st(t,i),0)})).sort((t,e)=>e.sum-t.sum).map(({s:t,sum:e})=>({key:t.key,label:t.label,color:h(t.slot,t.color,t.tone),value:ot(e)})),onClear:q.clear})]})}export{w as ColumnChart};
@@ -1,8 +1,8 @@
1
- import{useShellStrings as l,useShellLocale as e,DEFAULT_SHELL_STRINGS as t}from"./chunk-GDQJBQ5B.js";import{formatPercent as n}from"./chunk-C3QOHMR6.js";import{jsxs as a,jsx as u}from"react/jsx-runtime";function s(l){return null!=l&&Number.isFinite(l)&&l>=0?l:null}function i(l,e){const t=s(l);if(null==t)return"no-reading";const n=s(e);return null==n||0===n?"no-budget":t>n?"over":"within"}var r=l=>Math.min(100,Math.max(0,l));function m({label:m,elapsed:o,budget:d,grace:c,detail:f,formatDuration:h,formatValue:x,pace:b,emptyLabel:g,noBudgetLabel:p,size:v="sm",ariaLabel:N,className:y=""}){const w=l().meter,M=e(),$=x??h??(l=>function(l,e=t.meter){const n=Math.round(l),a=Math.floor(n/3600),u=Math.floor(n%3600/60),s=n%60;return a>0?e.hoursMinutes(a,u):u>0?e.minutesSeconds(u,s):e.seconds(s)}(l,w)),k=g??w.noReading,B=p??w.noBudget,j=s(o),L=s(d),Q=null!=L&&L>0?L:null,D=s(c)??0,R="over"===i(o,d),z=null!=Q?Q+D:null,C=null!=Q&&null!=z?r(Q/z*100):null,F=R&&D>0,G=null==z||null==j?0:R?F?C??0:0:r(j/z*100),H=F?C??0:0,J=R?F&&null!=z&&null!=j?r(j/z*100):100:0,O=Math.max(0,J-H),S=s(b),V=null!=S&&null!=z?r(S/z*100):null,q=null!=j&&null!=Q?j/Q*100:null,A=null!=q?n(Math.round(q),0,M):null!=j?$(j):"—",E=f??(null==j?k:null==Q?B:`${$(j)} / ${$(Q)}`),I="md"===v?"h-2":"h-1.5",K=R?"text-red-600":null!=j?"text-gray-900":"text-gray-400",P=null!=j&&null!=Q&&null!=z?/* @__PURE__ */a("div",{role:"meter","aria-label":N??("string"==typeof m?m:void 0),"aria-valuemin":0,"aria-valuemax":z,"aria-valuenow":Math.min(z,j),"aria-valuetext":w.ofBudget(A),className:`relative mt-2 ${I} overflow-hidden rounded-full bg-gray-200`,children:[(!R||F)&&/* @__PURE__ */u("div",{className:"absolute inset-y-0 left-0 rounded-full bg-blue-600",style:{width:`${G}%`}}),O>0&&/* @__PURE__ */u("div",{className:"rosh-budget-overrun absolute inset-y-0",style:{left:`${H}%`,width:`${O}%`}}),D>0&&null!=C&&/* @__PURE__ */u("div",{title:w.budget,className:"absolute inset-y-0 w-0.5 bg-gray-700",style:{left:`${C}%`}}),null!=V&&/* @__PURE__ */u("div",{title:w.pace,"data-pace":"true",className:"absolute inset-y-0 w-0.5 -translate-x-1/2 bg-gray-700",style:{left:`${V}%`}})]}):null;/* @__PURE__ */
1
+ import{useShellStrings as l,useShellLocale as e,DEFAULT_SHELL_STRINGS as t}from"./chunk-VNTJ7QO5.js";import{formatPercent as n}from"./chunk-C3QOHMR6.js";import{jsxs as a,jsx as u}from"react/jsx-runtime";function s(l){return null!=l&&Number.isFinite(l)&&l>=0?l:null}function i(l,e){const t=s(l);if(null==t)return"no-reading";const n=s(e);return null==n||0===n?"no-budget":t>n?"over":"within"}var r=l=>Math.min(100,Math.max(0,l));function m({label:m,elapsed:o,budget:d,grace:c,detail:f,formatDuration:h,formatValue:x,pace:b,emptyLabel:g,noBudgetLabel:p,size:v="sm",ariaLabel:N,className:y=""}){const w=l().meter,M=e(),$=x??h??(l=>function(l,e=t.meter){const n=Math.round(l),a=Math.floor(n/3600),u=Math.floor(n%3600/60),s=n%60;return a>0?e.hoursMinutes(a,u):u>0?e.minutesSeconds(u,s):e.seconds(s)}(l,w)),k=g??w.noReading,j=p??w.noBudget,B=s(o),L=s(d),O=null!=L&&L>0?L:null,Q=s(c)??0,R="over"===i(o,d),V=null!=O?O+Q:null,z=null!=O&&null!=V?r(O/V*100):null,C=R&&Q>0,D=null==V||null==B?0:R?C?z??0:0:r(B/V*100),F=C?z??0:0,H=R?C&&null!=V&&null!=B?r(B/V*100):100:0,J=Math.max(0,H-F),S=s(b),T=null!=S&&null!=V?r(S/V*100):null,q=null!=B&&null!=O?B/O*100:null,A=null!=q?n(Math.round(q),0,M):null!=B?$(B):"—",E=f??(null==B?k:null==O?j:`${$(B)} / ${$(O)}`),G="md"===v?"h-2":"h-1.5",I=R?"text-red-600":null!=B?"text-gray-900":"text-gray-400",K=null!=B&&null!=O&&null!=V?/* @__PURE__ */a("div",{role:"meter","aria-label":N??("string"==typeof m?m:void 0),"aria-valuemin":0,"aria-valuemax":V,"aria-valuenow":Math.min(V,B),"aria-valuetext":w.ofBudget(A),className:`relative mt-2 ${G} overflow-hidden rounded-full bg-gray-200`,children:[(!R||C)&&/* @__PURE__ */u("div",{className:"absolute inset-y-0 left-0 rounded-full bg-blue-600",style:{width:`${D}%`}}),J>0&&/* @__PURE__ */u("div",{className:"rosh-budget-overrun absolute inset-y-0",style:{left:`${F}%`,width:`${J}%`}}),Q>0&&null!=z&&/* @__PURE__ */u("div",{title:w.budget,className:"absolute inset-y-0 w-0.5 bg-gray-700",style:{left:`${z}%`}}),null!=T&&/* @__PURE__ */u("div",{title:w.pace,"data-pace":"true",className:"absolute inset-y-0 w-0.5 -translate-x-1/2 bg-gray-700",style:{left:`${T}%`}})]}):null;/* @__PURE__ */
2
2
  return a("div","md"===v?{className:y,children:[null!=m&&/* @__PURE__ */u("div",{className:"text-3xs font-medium uppercase tracking-wide text-ink-faint",children:m}),
3
3
  /* @__PURE__ */a("div",{className:"mt-1 flex items-baseline gap-2",children:[
4
- /* @__PURE__ */u("span",{className:`text-2xl font-semibold leading-[30px] tabular-nums ${K}`,children:A}),
5
- /* @__PURE__ */u("span",{className:"min-w-0 truncate text-2xs tabular-nums text-ink-faintest",children:E})]}),P]}:{className:y,children:[
4
+ /* @__PURE__ */u("span",{className:`text-2xl font-semibold leading-[30px] tabular-nums ${I}`,children:A}),
5
+ /* @__PURE__ */u("span",{className:"min-w-0 truncate text-2xs tabular-nums text-ink-faintest",children:E})]}),K]}:{className:y,children:[
6
6
  /* @__PURE__ */a("div",{className:"flex items-baseline gap-2",children:[null!=m&&/* @__PURE__ */u("span",{className:"w-14 shrink-0 truncate text-3xs font-medium uppercase tracking-wide text-ink-faint",children:m}),
7
- /* @__PURE__ */u("span",{className:`text-sm font-semibold tabular-nums ${K}`,children:A}),
8
- /* @__PURE__ */u("span",{className:"ml-auto min-w-0 truncate text-2xs tabular-nums text-ink-faintest",children:E})]}),P]})}export{m as BudgetBar,i as budgetState};
7
+ /* @__PURE__ */u("span",{className:`text-sm font-semibold tabular-nums ${I}`,children:A}),
8
+ /* @__PURE__ */u("span",{className:"ml-auto min-w-0 truncate text-2xs tabular-nums text-ink-faintest",children:E})]}),K]})}export{m as BudgetBar,i as budgetState};
@@ -1,2 +1,2 @@
1
- import{LoadingSpinner as n}from"./chunk-R2VKEMZH.js";import{useShellStrings as r}from"./chunk-GDQJBQ5B.js";import{jsx as o}from"react/jsx-runtime";function i(){const i=r().loading;/* @__PURE__ */
1
+ import{LoadingSpinner as n}from"./chunk-R2VKEMZH.js";import{useShellStrings as r}from"./chunk-VNTJ7QO5.js";import{jsx as o}from"react/jsx-runtime";function i(){const i=r().loading;/* @__PURE__ */
2
2
  return o(n,{size:"sm",padding:"p-8",label:i.label})}export{i as LoadingSpinner};
@@ -1,7 +1,7 @@
1
- import{squarify as e}from"./chunk-46BYGPGD.js";import{AccessibleTable as t}from"./chunk-5PP435FL.js";import{useHighlight as l}from"./chunk-CNYAHYE6.js";import{ChartTooltip as a}from"./chunk-36VIGB6J.js";import{usePlotWidth as r}from"./chunk-MAFUXCPZ.js";import{resolveSeriesColor as i,CHART_INK as o}from"./chunk-TZFACUMR.js";import{useShellStrings as n,useShellLocale as m}from"./chunk-GDQJBQ5B.js";import{formatPlain as h}from"./chunk-C3QOHMR6.js";import{useRef as c,useState as u}from"react";import{jsx as s,jsxs as f}from"react/jsx-runtime";function p({items:p,height:d=320,width:v,gap:x=2,radius:g=3,formatValue:y,color:k,className:b,emptyLabel:j}){const w=n().charts,M=m(),N=y??(e=>h(e,M)),B=j??w.nothingToBreakDown,$=c(null),C=r($),F=v??C,[G,P]=u(null),{highlighted:z}=l(),A=e(p,F,d);if(0===A.length)/* @__PURE__ */
2
- return s("div",{className:b,ref:$,children:/* @__PURE__ */s("p",{className:"py-8 text-center text-sm text-gray-500",children:B})});const D=k??i(0),L=Math.max(...A.map(e=>e.value),1),Q=e=>34+e/L*62,V=e=>`color-mix(in oklab, ${D} ${Q(e).toFixed(0)}%, ${o.surface})`,Y=e=>Q(e)>=55?o.surface:o.label,E=G??z,H=G?A.find(e=>e.key===G):void 0;/* @__PURE__ */
3
- return f("div",{className:`relative ${b??""}`,ref:$,children:[
4
- /* @__PURE__ */s("svg",{width:"100%",height:d,viewBox:`0 0 ${F} ${d}`,role:"img","aria-label":w.treemap(p.length),onMouseLeave:()=>P(null),children:A.map(e=>{const t=Math.max(0,e.width-x),l=Math.max(0,e.height-x),a=t>6.2*e.label.length+12&&l>30,r=a&&l>44;/* @__PURE__ */
5
- return f("g",{opacity:E&&E!==e.key?.55:1,onMouseEnter:()=>P(e.key),children:[
6
- /* @__PURE__ */s("rect",{x:e.x+x/2,y:e.y+x/2,width:t,height:l,rx:g,fill:V(e.value)}),a&&/* @__PURE__ */s("text",{x:e.x+x/2+8,y:e.y+x/2+18,fontSize:12,fontWeight:600,fill:Y(e.value),children:e.label}),r&&/* @__PURE__ */s("text",{x:e.x+x/2+8,y:e.y+x/2+34,fontSize:11,fill:Y(e.value),fillOpacity:.85,style:{fontVariantNumeric:"tabular-nums"},children:N(e.value)})]},e.key)})}),H&&/* @__PURE__ */s("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */s(a,{title:H.label,rows:[{key:"value",label:w.value,color:V(H.value),value:N(H.value)}]})}),
1
+ import{squarify as e}from"./chunk-46BYGPGD.js";import{AccessibleTable as t}from"./chunk-5PP435FL.js";import{useHighlight as l}from"./chunk-CNYAHYE6.js";import{ChartTooltip as a}from"./chunk-36VIGB6J.js";import{usePlotWidth as r}from"./chunk-MAFUXCPZ.js";import{resolveSeriesColor as i,CHART_INK as o}from"./chunk-TZFACUMR.js";import{useShellStrings as n,useShellLocale as m}from"./chunk-VNTJ7QO5.js";import{formatPlain as h}from"./chunk-C3QOHMR6.js";import{useRef as c,useState as u}from"react";import{jsx as s,jsxs as f}from"react/jsx-runtime";function p({items:p,height:d=320,width:v,gap:x=2,radius:g=3,formatValue:y,color:k,className:b,emptyLabel:j}){const w=n().charts,M=m(),N=y??(e=>h(e,M)),$=j??w.nothingToBreakDown,B=c(null),C=r(B),F=v??C,[P,V]=u(null),{highlighted:z}=l(),A=e(p,F,d);if(0===A.length)/* @__PURE__ */
2
+ return s("div",{className:b,ref:B,children:/* @__PURE__ */s("p",{className:"py-8 text-center text-sm text-gray-500",children:$})});const G=k??i(0),L=Math.max(...A.map(e=>e.value),1),O=e=>34+e/L*62,T=e=>`color-mix(in oklab, ${G} ${O(e).toFixed(0)}%, ${o.surface})`,Y=e=>O(e)>=55?o.surface:o.label,D=P??z,E=P?A.find(e=>e.key===P):void 0;/* @__PURE__ */
3
+ return f("div",{className:`relative ${b??""}`,ref:B,children:[
4
+ /* @__PURE__ */s("svg",{width:"100%",height:d,viewBox:`0 0 ${F} ${d}`,role:"img","aria-label":w.treemap(p.length),onMouseLeave:()=>V(null),children:A.map(e=>{const t=Math.max(0,e.width-x),l=Math.max(0,e.height-x),a=t>6.2*e.label.length+12&&l>30,r=a&&l>44;/* @__PURE__ */
5
+ return f("g",{opacity:D&&D!==e.key?.55:1,onMouseEnter:()=>V(e.key),children:[
6
+ /* @__PURE__ */s("rect",{x:e.x+x/2,y:e.y+x/2,width:t,height:l,rx:g,fill:T(e.value)}),a&&/* @__PURE__ */s("text",{x:e.x+x/2+8,y:e.y+x/2+18,fontSize:12,fontWeight:600,fill:Y(e.value),children:e.label}),r&&/* @__PURE__ */s("text",{x:e.x+x/2+8,y:e.y+x/2+34,fontSize:11,fill:Y(e.value),fillOpacity:.85,style:{fontVariantNumeric:"tabular-nums"},children:N(e.value)})]},e.key)})}),E&&/* @__PURE__ */s("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */s(a,{title:E.label,rows:[{key:"value",label:w.value,color:T(E.value),value:N(E.value)}]})}),
7
7
  /* @__PURE__ */s(t,{caption:w.treemap(p.length),head:[w.tableItem,w.value],rows:A.map(e=>[e.label,N(e.value)])})]})}export{p as TreemapChart};
@@ -1,31 +1,31 @@
1
- import{useCopyText as e,CopyGlyph as n}from"./chunk-2E2SUEEE.js";import{ItemCount as t}from"./chunk-55AEZX6K.js";import{PopupMenu as r,PopupMenuItem as i,PopupMenuDivider as l}from"./chunk-6KGIHI6X.js";import{Icon as a}from"./chunk-2UO47XB4.js";import{useShellStrings as o}from"./chunk-GDQJBQ5B.js";import{useState as s,useMemo as d,useEffect as c,useRef as u,Fragment as m,useLayoutEffect as f}from"react";import{jsxs as p,jsx as y,Fragment as h}from"react/jsx-runtime";function g(e){const n=[];let t=0;for(;t<e.length;){const r=e[t].group;let i=t;for(;void 0!==r&&i+1<e.length&&e[i+1].group===r;)i++;n.push(i>t?{group:r,start:t,end:i}:{start:t,end:t}),t=i+1}return n}function k(e,n){return e.find(e=>n>=e.start&&n<=e.end)}function b(e,n,t,r){const i=e.findIndex(e=>e.key===n.key);let l=e.findIndex(e=>e.key===t);if(i<0||l<0)return null;const a=g(e),o=k(a,i),s="group"===n.kind&&void 0!==o.group?e.slice(o.start,o.end+1).map(e=>e.key):[n.key];if(s.includes(t))return null;const d=k(a,l);if("tab"===n.kind&&void 0!==o.group){if(d!==o)return null}else void 0!==d.group&&(l="before"===r?d.start:d.end);return{key:e[l].key,side:r,moving:s}}function x(e,n,t,r){const i=b(e,n,t,r);if(!i)return null;const l=e.map(e=>e.key).filter(e=>!i.moving.includes(e)),a=l.indexOf(i.key)+("after"===i.side?1:0),o=[...l.slice(0,a),...i.moving,...l.slice(a)];return o.every((n,t)=>n===e[t].key)?null:o}var v="flex-[0_1_15rem] [contain-intrinsic-inline-size:15rem]",w=v,N="outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-blue-500",$="pointer-events-none absolute bottom-0 size-2 [background:inherit]";function C(){/* @__PURE__ */
1
+ import{useCopyText as e,CopyGlyph as n}from"./chunk-OQG3XO4Y.js";import{ItemCount as t}from"./chunk-UZ7TKJRO.js";import{PopupMenu as r,PopupMenuItem as i,PopupMenuDivider as l}from"./chunk-QVAOSKFO.js";import{Icon as a}from"./chunk-R64OZ6TC.js";import{useShellStrings as o}from"./chunk-VNTJ7QO5.js";import{useState as s,useMemo as d,useEffect as c,useRef as u,Fragment as m,useLayoutEffect as f}from"react";import{jsxs as p,jsx as y,Fragment as h}from"react/jsx-runtime";function g(e){const n=[];let t=0;for(;t<e.length;){const r=e[t].group;let i=t;for(;void 0!==r&&i+1<e.length&&e[i+1].group===r;)i++;n.push(i>t?{group:r,start:t,end:i}:{start:t,end:t}),t=i+1}return n}function k(e,n){return e.find(e=>n>=e.start&&n<=e.end)}function b(e,n,t,r){const i=e.findIndex(e=>e.key===n.key);let l=e.findIndex(e=>e.key===t);if(i<0||l<0)return null;const a=g(e),o=k(a,i),s="group"===n.kind&&void 0!==o.group?e.slice(o.start,o.end+1).map(e=>e.key):[n.key];if(s.includes(t))return null;const d=k(a,l);if("tab"===n.kind&&void 0!==o.group){if(d!==o)return null}else void 0!==d.group&&(l="before"===r?d.start:d.end);return{key:e[l].key,side:r,moving:s}}function x(e,n,t,r){const i=b(e,n,t,r);if(!i)return null;const l=e.map(e=>e.key).filter(e=>!i.moving.includes(e)),a=l.indexOf(i.key)+("after"===i.side?1:0),o=[...l.slice(0,a),...i.moving,...l.slice(a)];return o.every((n,t)=>n===e[t].key)?null:o}var v="flex-[0_1_15rem] [contain-intrinsic-inline-size:15rem]",N=v,w="outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-blue-500",C="pointer-events-none absolute bottom-0 size-2 [background:inherit]";function $(){/* @__PURE__ */
2
2
  return p(h,{children:[
3
- /* @__PURE__ */y("span",{"aria-hidden":"true",className:`${$} -left-2 [mask-image:radial-gradient(circle_at_0_0,transparent_0.5rem,#000_calc(0.5rem+0.5px))]`}),
4
- /* @__PURE__ */y("span",{"aria-hidden":"true",className:`${$} -right-2 [mask-image:radial-gradient(circle_at_100%_0,transparent_0.5rem,#000_calc(0.5rem+0.5px))]`})]})}function z(){/* @__PURE__ */
3
+ /* @__PURE__ */y("span",{"aria-hidden":"true",className:`${C} -left-2 [mask-image:radial-gradient(circle_at_0_0,transparent_0.5rem,#000_calc(0.5rem+0.5px))]`}),
4
+ /* @__PURE__ */y("span",{"aria-hidden":"true",className:`${C} -right-2 [mask-image:radial-gradient(circle_at_100%_0,transparent_0.5rem,#000_calc(0.5rem+0.5px))]`})]})}function z(){/* @__PURE__ */
5
5
  return y(a,{name:"close",look:"mini","aria-hidden":"true",className:"size-3.5"})}function I({text:t,label:r,copiedLabel:i}){const{copied:l,copy:a}=e(t);/* @__PURE__ */
6
- return y("button",{type:"button",tabIndex:-1,"aria-label":l?i:r,title:l?i:r,onClick:a,className:"flex size-5 shrink-0 items-center justify-center rounded text-gray-400 hover:bg-gray-200 hover:text-gray-700 @max-[10rem]:hidden",children:/* @__PURE__ */y(n,{copied:l,className:"size-3.5"})})}function _({node:e}){const n=u(null);return f(()=>{const t=n.current;if(t)return t.appendChild(e),()=>{e.parentNode===t&&t.removeChild(e)}},[e]),/* @__PURE__ */y("span",{ref:n,className:"ml-1 flex shrink-0 items-center"})}function j({tabs:e,activeKey:n,idFor:f,panelMounted:k,onActivate:$,onClose:j,onCloseMany:D,label:E,className:A,activeClassName:B,end:T,afterPinned:K,onIconMenu:M,menuItems:S,sizing:G="even",tall:O=!1,onReorder:R,groupInfo:X}){const L=o().pageTabs,F=o().count,[H,Q]=s(null),U=O?"h-[34px]":"h-8",W=d(()=>e.map(e=>({key:e.key,group:X?e.group:void 0})),[e,X]),J=d(()=>g(W),[W]),[P,V]=s(()=>/* @__PURE__ */new Set),Y=t=>{if(!P.has(t)){const r=J.find(e=>e.group===t),i=e.findIndex(e=>e.key===n);if(r&&i>=r.start&&i<=r.end){const n=e[r.end+1]??e[r.start-1];n&&$(n.key)}}V(e=>{const n=new Set(e);return n.has(t)?n.delete(t):n.add(t),n})},Z=n?W.find(e=>e.key===n)?.group:void 0;c(()=>{void 0!==Z&&V(e=>{if(!e.has(Z))return e;const n=new Set(e);return n.delete(Z),n})},[n]);const q=d(()=>{const n=[];for(const t of J)for(let r=t.start;r<=t.end;r++)void 0!==t.group&&P.has(t.group)||n.push(e[r]);return n},[J,P,e]),ee=u(null),[ne,te]=s(null),re=(n,t)=>R?{draggable:!0,onDragStart:t=>{ee.current=n,t.dataTransfer.effectAllowed="move",t.dataTransfer.setData("text/plain",e.find(e=>e.key===n.key)?.title??"")},onDragOver:e=>{const r=ee.current;if(!r)return;const i=e.currentTarget.getBoundingClientRect(),l=t!==n.key||"tab"===n.kind?e.clientX<i.left+i.width/2?"before":"after":"before",a=x(W,r,t,l)?b(W,r,t,l):null;if(!a)return void(ne&&te(null));e.preventDefault(),e.dataTransfer.dropEffect="move";const o=e=>W.find(n=>n.key===e)?.group,s="tab"===r.kind&&void 0!==o(r.key)&&o(r.key)===o(a.key);ne?.key===a.key&&ne.side===a.side&&ne.inGroup===s||te({key:a.key,side:a.side,inGroup:s})},onDrop:e=>{const n=ee.current;if(!n||!ne)return;e.preventDefault();const t=x(W,n,ne.key,ne.side);ee.current=null,te(null),t&&R(t)},onDragEnd:()=>{ee.current=null,te(null)}}:{},ie=d(()=>new Set(J.filter(e=>void 0!==e.group&&X).map(n=>e[n.start].key)),[J,e,X]),le=e=>"pointer-events-none absolute inset-y-1 z-[3] w-0.5 rounded-full bg-blue-500 "+("before"===e?"-left-px":"-right-px"),ae=e=>ne?.key===e&&!("before"===ne.side&&ie.has(e)&&!ne.inGroup)&&/* @__PURE__ */y("span",{"aria-hidden":"true",className:le(ne.side)}),oe=e.length;c(()=>{if(!n)return;const e=document.getElementById(f(n,"tab"));e?.scrollIntoView?.({block:"nearest",inline:"nearest"})},[f,n,oe]);const se=K?q.findIndex(e=>!e.pinned):-1,de=q.some(e=>e.key===n)?n:q[0]?.key,ce=e=>{const n=q[(e+q.length)%q.length];n&&document.getElementById(f(n.key,"tab"))?.focus()},ue=(e,n)=>{const t=q[e+n];if(!R||!t)return;const r=x(W,{kind:"tab",key:q[e].key},t.key,n<0?"before":"after");r&&(R(r),setTimeout(()=>document.getElementById(f(q[e].key,"tab"))?.focus(),0))},me=H?e.find(e=>e.key===H.key):void 0,fe=me&&S?S(me.key):[],pe=me?e.indexOf(me):-1,ye=e=>e.some(e=>!e.pinned),he=e=>()=>{Q(null),e()},ge=(e,t)=>{const r=e.key===n,i=!!e.dirty,l=e.icon,o=r?B??"z-[1] border-transparent bg-gray-50 text-gray-900":"border-transparent text-gray-600 hover:bg-gray-200/70 hover:text-gray-900",s=!!t&&!r&&t.key!==n,d={type:"button",role:"tab",id:f(e.key,"tab"),"aria-selected":r,"aria-controls":k?.(e.key)?f(e.key,"panel"):void 0,tabIndex:e.key===de?0:-1,title:e.title,onClick:()=>$(e.key)},c={onContextMenu:n=>((e,n)=>{e.preventDefault(),Q({x:e.clientX,y:e.clientY,key:n.key})})(n,e),onAuxClick:n=>((e,n)=>{1!==e.button||n.pinned||(e.preventDefault(),j(n.key))})(n,e),onMouseDown:e=>{1===e.button&&e.preventDefault()}},u=l&&
6
+ return y("button",{type:"button",tabIndex:-1,"aria-label":l?i:r,title:l?i:r,onClick:a,className:"flex size-5 shrink-0 items-center justify-center rounded text-gray-400 hover:bg-gray-200 hover:text-gray-700 @max-[10rem]:hidden",children:/* @__PURE__ */y(n,{copied:l,className:"size-3.5"})})}function _({node:e}){const n=u(null);return f(()=>{const t=n.current;if(t)return t.appendChild(e),()=>{e.parentNode===t&&t.removeChild(e)}},[e]),/* @__PURE__ */y("span",{ref:n,className:"ml-1 flex shrink-0 items-center"})}function j({tabs:e,activeKey:n,idFor:f,panelMounted:k,onActivate:C,onClose:j,onCloseMany:D,label:O,className:T,activeClassName:A,end:R,afterPinned:E,onIconMenu:K,menuItems:M,sizing:S="even",tall:B=!1,onReorder:G,groupInfo:L}){const F=o().pageTabs,Q=o().count,[V,X]=s(null),J=B?"h-[34px]":"h-8",W=d(()=>e.map(e=>({key:e.key,group:L?e.group:void 0})),[e,L]),Y=d(()=>g(W),[W]),[Z,H]=s(()=>/* @__PURE__ */new Set),P=t=>{if(!Z.has(t)){const r=Y.find(e=>e.group===t),i=e.findIndex(e=>e.key===n);if(r&&i>=r.start&&i<=r.end){const n=e[r.end+1]??e[r.start-1];n&&C(n.key)}}H(e=>{const n=new Set(e);return n.has(t)?n.delete(t):n.add(t),n})},U=n?W.find(e=>e.key===n)?.group:void 0;c(()=>{void 0!==U&&H(e=>{if(!e.has(U))return e;const n=new Set(e);return n.delete(U),n})},[n]);const q=d(()=>{const n=[];for(const t of Y)for(let r=t.start;r<=t.end;r++)void 0!==t.group&&Z.has(t.group)||n.push(e[r]);return n},[Y,Z,e]),ee=u(null),[ne,te]=s(null),re=(n,t)=>G?{draggable:!0,onDragStart:t=>{ee.current=n,t.dataTransfer.effectAllowed="move",t.dataTransfer.setData("text/plain",e.find(e=>e.key===n.key)?.title??"")},onDragOver:e=>{const r=ee.current;if(!r)return;const i=e.currentTarget.getBoundingClientRect(),l=t!==n.key||"tab"===n.kind?e.clientX<i.left+i.width/2?"before":"after":"before",a=x(W,r,t,l)?b(W,r,t,l):null;if(!a)return void(ne&&te(null));e.preventDefault(),e.dataTransfer.dropEffect="move";const o=e=>W.find(n=>n.key===e)?.group,s="tab"===r.kind&&void 0!==o(r.key)&&o(r.key)===o(a.key);ne?.key===a.key&&ne.side===a.side&&ne.inGroup===s||te({key:a.key,side:a.side,inGroup:s})},onDrop:e=>{const n=ee.current;if(!n||!ne)return;e.preventDefault();const t=x(W,n,ne.key,ne.side);ee.current=null,te(null),t&&G(t)},onDragEnd:()=>{ee.current=null,te(null)}}:{},ie=d(()=>new Set(Y.filter(e=>void 0!==e.group&&L).map(n=>e[n.start].key)),[Y,e,L]),le=e=>"pointer-events-none absolute inset-y-1 z-[3] w-0.5 rounded-full bg-blue-500 "+("before"===e?"-left-px":"-right-px"),ae=e=>ne?.key===e&&!("before"===ne.side&&ie.has(e)&&!ne.inGroup)&&/* @__PURE__ */y("span",{"aria-hidden":"true",className:le(ne.side)}),oe=e.length;c(()=>{if(!n)return;const e=document.getElementById(f(n,"tab"));e?.scrollIntoView?.({block:"nearest",inline:"nearest"})},[f,n,oe]);const se=E?q.findIndex(e=>!e.pinned):-1,de=q.some(e=>e.key===n)?n:q[0]?.key,ce=e=>{const n=q[(e+q.length)%q.length];n&&document.getElementById(f(n.key,"tab"))?.focus()},ue=(e,n)=>{const t=q[e+n];if(!G||!t)return;const r=x(W,{kind:"tab",key:q[e].key},t.key,n<0?"before":"after");r&&(G(r),setTimeout(()=>document.getElementById(f(q[e].key,"tab"))?.focus(),0))},me=V?e.find(e=>e.key===V.key):void 0,fe=me&&M?M(me.key):[],pe=me?e.indexOf(me):-1,ye=e=>e.some(e=>!e.pinned),he=e=>()=>{X(null),e()},ge=(e,t)=>{const r=e.key===n,i=!!e.dirty,l=e.icon,o=r?A??"z-[1] border-transparent bg-gray-50 text-gray-900":"border-transparent text-gray-600 hover:bg-gray-200/70 hover:text-gray-900",s=!!t&&!r&&t.key!==n,d={type:"button",role:"tab",id:f(e.key,"tab"),"aria-selected":r,"aria-controls":k?.(e.key)?f(e.key,"panel"):void 0,tabIndex:e.key===de?0:-1,title:e.title,onClick:()=>C(e.key)},c={onContextMenu:n=>((e,n)=>{e.preventDefault(),X({x:e.clientX,y:e.clientY,key:n.key})})(n,e),onAuxClick:n=>((e,n)=>{1!==e.button||n.pinned||(e.preventDefault(),j(n.key))})(n,e),onMouseDown:e=>{1===e.button&&e.preventDefault()}},u=l&&
7
7
  /* @__PURE__ */p("span",{className:"relative flex size-4 shrink-0 items-center justify-center text-gray-500 [&>svg]:size-4","aria-hidden":"true",children:[l,i&&!r&&!e.pinned&&
8
- /* @__PURE__ */y("span",{className:"absolute -right-1 -top-1 hidden size-2 rounded-full bg-gray-500 ring-2 ring-gray-100 @max-[6.5rem]:block @max-[6.5rem]:group-hover:hidden"})]}),h=r&&!!M&&!!l;return e.pinned?/* @__PURE__ */p("div",{role:"presentation",className:`group relative flex flex-none items-center justify-center rounded-t-lg border border-b-0 transition-colors ${U} ${l?"w-10":""} ${o}`,...c,...re({kind:"tab",key:e.key},e.key),children:[ae(e.key),r&&/* @__PURE__ */y(C,{}),
9
- /* @__PURE__ */p("button",{...d,className:`flex h-full items-center justify-center rounded-t-lg ${l?"w-full":"px-3"} ${N}`,children:[u,
8
+ /* @__PURE__ */y("span",{className:"absolute -right-1 -top-1 hidden size-2 rounded-full bg-gray-500 ring-2 ring-gray-100 @max-[6.5rem]:block @max-[6.5rem]:group-hover:hidden"})]}),h=r&&!!K&&!!l;return e.pinned?/* @__PURE__ */p("div",{role:"presentation",className:`group relative flex flex-none items-center justify-center rounded-t-lg border border-b-0 transition-colors ${J} ${l?"w-10":""} ${o}`,...c,...re({kind:"tab",key:e.key},e.key),children:[ae(e.key),r&&/* @__PURE__ */y($,{}),
9
+ /* @__PURE__ */p("button",{...d,className:`flex h-full items-center justify-center rounded-t-lg ${l?"w-full":"px-3"} ${w}`,children:[u,
10
10
  /* @__PURE__ */y("span",{className:l?"sr-only":"whitespace-nowrap text-sm",children:e.title})]})]},e.key):/* @__PURE__ */p(m,{children:[s&&/* @__PURE__ */y("span",{"aria-hidden":"true",className:"mb-3 h-4 w-px shrink-0 self-end border-l border-gray-300"}),
11
- /* @__PURE__ */p("div",{role:"presentation",className:`group relative flex items-center rounded-t-lg border border-b-0 text-sm transition-colors ${U} ${"active-full"===G&&r?"":"@container"} ${"active-full"===G?r?"flex-[0_0_15rem] min-w-0":w:r&&(e.copy||h)?"flex-[0_1_20rem]":v} ${r?"active-full"===G?"":"min-w-[4.25rem]":"min-w-[4rem]"} ${o}`,...c,...re({kind:"tab",key:e.key},e.key),children:[ae(e.key),r&&/* @__PURE__ */y(C,{}),h&&
12
- /* @__PURE__ */y("button",{type:"button",tabIndex:-1,"aria-haspopup":"menu","aria-label":L.tabMenu,title:L.tabMenu,onClick:n=>{const t=n.currentTarget.getBoundingClientRect();M?.(e.key,t.left,t.bottom+4)},className:`ml-2 flex size-6 shrink-0 items-center justify-center rounded hover:bg-gray-200 @max-[5rem]:ml-2 ${N}`,children:u}),
13
- /* @__PURE__ */p("button",{...d,className:`flex h-full min-w-0 flex-1 items-center gap-2 rounded-t-lg pr-1 text-left ${h?"pl-2":"pl-3"} ${N} ${r?h?"":"@max-[5rem]:pl-3":"@max-[6.5rem]:pr-3 @max-[4.5rem]:justify-center @max-[4.5rem]:px-0 @max-[4.5rem]:group-hover:pl-2 @max-[4.5rem]:group-hover:pr-3"}`,children:[!h&&u,
14
- /* @__PURE__ */p("span",{className:`min-w-0 flex-1 overflow-hidden whitespace-nowrap [mask-image:linear-gradient(to_right,#000_calc(100%-1rem),transparent)] ${"active-full"===G&&r?"pr-4":""} ${l?r?"@max-[5rem]:sr-only":"@max-[4.5rem]:sr-only":""}`,children:[e.title,e.favorite&&
15
- /* @__PURE__ */y("span",{role:"img","aria-label":L.favorite,title:L.favorite,className:"ml-1 inline-flex align-[-0.125em] text-yellow-500",children:/* @__PURE__ */y(a,{name:"star","aria-hidden":"true",className:"size-3.5",fill:"currentColor",strokeWidth:1.5})})]})]}),r&&e.actions&&/* @__PURE__ */y(_,{node:e.actions}),r&&e.copy&&/* @__PURE__ */y(I,{text:e.copy,label:L.copy(e.copy),copiedLabel:L.copied}),
16
- /* @__PURE__ */p("span",{className:"mr-2 flex size-5 shrink-0 items-center justify-center "+(r?"":"@max-[6.5rem]:hidden @max-[6.5rem]:group-hover:flex"),children:[i&&/* @__PURE__ */y("span",{role:"img","aria-label":L.unsaved,className:"size-2 rounded-full bg-gray-500 group-hover:hidden"}),
17
- /* @__PURE__ */y("button",{type:"button",tabIndex:-1,"aria-label":L.closeTab?.(e.title)??`${L.close} ${e.title}`,onClick:()=>j(e.key),className:"size-5 items-center justify-center rounded text-gray-400 hover:bg-gray-200 hover:text-gray-700 "+(i?"hidden group-hover:flex":r?"flex":"flex opacity-0 group-hover:opacity-100 focus-visible:opacity-100"),children:/* @__PURE__ */y(z,{})})]})]})]},e.key)},ke=[];let be,xe=0,ve=!K;for(const r of J){const i=q.filter(n=>{const t=e.indexOf(n);return t>=r.start&&t<=r.end});if(ve||xe!==se||(ve=!0,ke.push(/* @__PURE__ */y(m,{children:K},"rosh-after-pinned")),be=void 0),xe+=i.length,void 0===r.group||!X){for(const e of i)ke.push(ge(e,be)),be=e;continue}be=void 0;const l=r.group,o=X(l),s=r.end-r.start+1,d=!P.has(l),c=e[r.start].key,u=i.some(e=>e.key===n);ke.push(
11
+ /* @__PURE__ */p("div",{role:"presentation",className:`group relative flex items-center rounded-t-lg border border-b-0 text-sm transition-colors ${J} ${"active-full"===S&&r?"":"@container"} ${"active-full"===S?r?"flex-[0_0_15rem] min-w-0":N:r&&(e.copy||h)?"flex-[0_1_20rem]":v} ${r?"active-full"===S?"":"min-w-[4.25rem]":"min-w-[4rem]"} ${o}`,...c,...re({kind:"tab",key:e.key},e.key),children:[ae(e.key),r&&/* @__PURE__ */y($,{}),h&&
12
+ /* @__PURE__ */y("button",{type:"button",tabIndex:-1,"aria-haspopup":"menu","aria-label":F.tabMenu,title:F.tabMenu,onClick:n=>{const t=n.currentTarget.getBoundingClientRect();K?.(e.key,t.left,t.bottom+4)},className:`ml-2 flex size-6 shrink-0 items-center justify-center rounded hover:bg-gray-200 @max-[5rem]:ml-2 ${w}`,children:u}),
13
+ /* @__PURE__ */p("button",{...d,className:`flex h-full min-w-0 flex-1 items-center gap-2 rounded-t-lg pr-1 text-left ${h?"pl-2":"pl-3"} ${w} ${r?h?"":"@max-[5rem]:pl-3":"@max-[6.5rem]:pr-3 @max-[4.5rem]:justify-center @max-[4.5rem]:px-0 @max-[4.5rem]:group-hover:pl-2 @max-[4.5rem]:group-hover:pr-3"}`,children:[!h&&u,
14
+ /* @__PURE__ */p("span",{className:`min-w-0 flex-1 overflow-hidden whitespace-nowrap [mask-image:linear-gradient(to_right,#000_calc(100%-1rem),transparent)] ${"active-full"===S&&r?"pr-4":""} ${l?r?"@max-[5rem]:sr-only":"@max-[4.5rem]:sr-only":""}`,children:[e.title,e.favorite&&
15
+ /* @__PURE__ */y("span",{role:"img","aria-label":F.favorite,title:F.favorite,className:"ml-1 inline-flex align-[-0.125em] text-yellow-500",children:/* @__PURE__ */y(a,{name:"star","aria-hidden":"true",className:"size-3.5",fill:"currentColor",strokeWidth:1.5})})]})]}),r&&e.actions&&/* @__PURE__ */y(_,{node:e.actions}),r&&e.copy&&/* @__PURE__ */y(I,{text:e.copy,label:F.copy(e.copy),copiedLabel:F.copied}),
16
+ /* @__PURE__ */p("span",{className:"mr-2 flex size-5 shrink-0 items-center justify-center "+(r?"":"@max-[6.5rem]:hidden @max-[6.5rem]:group-hover:flex"),children:[i&&/* @__PURE__ */y("span",{role:"img","aria-label":F.unsaved,className:"size-2 rounded-full bg-gray-500 group-hover:hidden"}),
17
+ /* @__PURE__ */y("button",{type:"button",tabIndex:-1,"aria-label":F.closeTab?.(e.title)??`${F.close} ${e.title}`,onClick:()=>j(e.key),className:"size-5 items-center justify-center rounded text-gray-400 hover:bg-gray-200 hover:text-gray-700 "+(i?"hidden group-hover:flex":r?"flex":"flex opacity-0 group-hover:opacity-100 focus-visible:opacity-100"),children:/* @__PURE__ */y(z,{})})]})]})]},e.key)},ke=[];let be,xe=0,ve=!E;for(const r of Y){const i=q.filter(n=>{const t=e.indexOf(n);return t>=r.start&&t<=r.end});if(ve||xe!==se||(ve=!0,ke.push(/* @__PURE__ */y(m,{children:E},"rosh-after-pinned")),be=void 0),xe+=i.length,void 0===r.group||!L){for(const e of i)ke.push(ge(e,be)),be=e;continue}be=void 0;const l=r.group,o=L(l),s=r.end-r.start+1,d=!Z.has(l),c=e[r.start].key,u=i.some(e=>e.key===n);ke.push(
18
18
  /* @__PURE__ */p("div",{role:"group","aria-label":o.label,"data-tab-group":l,className:"relative mx-1 flex items-end first:ml-0 min-w-0 "+(u?"shrink-[0.01]":"shrink"),children:[
19
- /* @__PURE__ */p("button",{type:"button",tabIndex:-1,"aria-expanded":d,title:L.groupToggle(o.label,s),onClick:()=>Y(l),...re({kind:"group",key:c},c),className:`relative mb-1 mr-1 flex h-6 shrink-0 items-center gap-1 rounded-full bg-blue-100 px-2 text-xs font-medium text-blue-700 hover:bg-blue-200 ${N}`,children:[
19
+ /* @__PURE__ */p("button",{type:"button",tabIndex:-1,"aria-expanded":d,title:F.groupToggle(o.label,s),onClick:()=>P(l),...re({kind:"group",key:c},c),className:`relative mb-1 mr-1 flex h-6 shrink-0 items-center gap-1 rounded-full bg-blue-100 px-2 text-xs font-medium text-blue-700 hover:bg-blue-200 ${w}`,children:[
20
20
  /* @__PURE__ */y(a,{name:d?"chevron-down":"chevron-right","aria-hidden":"true",className:"size-3",strokeWidth:2}),o.icon&&/* @__PURE__ */y("span",{className:"flex size-3.5 items-center justify-center [&>svg]:size-3.5","aria-hidden":"true",children:o.icon}),
21
21
  /* @__PURE__ */y("span",{className:d?"sr-only":"max-w-[12rem] truncate",children:o.label}),
22
- /* @__PURE__ */y(t,{count:s,label:F.tabs(s),active:!0})]}),ne?.key===c&&"before"===ne.side&&!ne.inGroup&&/* @__PURE__ */y("span",{"aria-hidden":"true",className:le("before")}),i.map((e,n)=>ge(e,n>0?i[n-1]:void 0)),
23
- /* @__PURE__ */y("span",{"aria-hidden":"true",className:"pointer-events-none absolute inset-x-0 bottom-0 z-0 h-0.5 bg-blue-500"})]},`rosh-group-${c}`))}return ve||ke.push(/* @__PURE__ */y(m,{children:K},"rosh-after-pinned")),/* @__PURE__ */p("div",{className:A??"relative flex h-10 shrink-0 items-end gap-3 bg-gray-100 px-3",children:[
22
+ /* @__PURE__ */y(t,{count:s,label:Q.tabs(s),active:!0})]}),ne?.key===c&&"before"===ne.side&&!ne.inGroup&&/* @__PURE__ */y("span",{"aria-hidden":"true",className:le("before")}),i.map((e,n)=>ge(e,n>0?i[n-1]:void 0)),
23
+ /* @__PURE__ */y("span",{"aria-hidden":"true",className:"pointer-events-none absolute inset-x-0 bottom-0 z-0 h-0.5 bg-blue-500"})]},`rosh-group-${c}`))}return ve||ke.push(/* @__PURE__ */y(m,{children:E},"rosh-after-pinned")),/* @__PURE__ */p("div",{className:T??"relative flex h-10 shrink-0 items-end gap-3 bg-gray-100 px-3",children:[
24
24
  /* @__PURE__ */y("div",{"aria-hidden":"true",className:"pointer-events-none absolute inset-x-0 bottom-0 h-px bg-gray-200"}),
25
- /* @__PURE__ */y("div",{role:"tablist","aria-label":E,onKeyDown:e=>{const n=q.findIndex(n=>document.getElementById(f(n.key,"tab"))===e.target);if(n<0)return;const t=e.shiftKey&&(e.ctrlKey||e.metaKey);if(t&&"ArrowRight"===e.key)ue(n,1);else if(t&&"ArrowLeft"===e.key)ue(n,-1);else if("ArrowRight"===e.key)ce(n+1);else if("ArrowLeft"===e.key)ce(n-1);else if("Home"===e.key)ce(0);else if("End"===e.key)ce(q.length-1);else{if("Delete"!==e.key||q[n].pinned)return;j(q[n].key)}e.preventDefault()},className:"flex min-w-0 flex-1 items-end -mx-2 px-2 scroll-px-2 overflow-x-auto overflow-y-hidden [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",children:ke}),T&&/* @__PURE__ */y("div",{className:"flex shrink-0 items-center gap-2 self-center",children:T}),H&&me&&/* @__PURE__ */p(r,{portal:!0,style:{left:H.x,top:H.y},onClose:()=>Q(null),children:[fe.length>0&&/* @__PURE__ */p(h,{children:[fe.map((e,n)=>/* @__PURE__ */p(i,{onClick:he(e.onSelect),children:[e.icon,e.label]},n)),
25
+ /* @__PURE__ */y("div",{role:"tablist","aria-label":O,onKeyDown:e=>{const n=q.findIndex(n=>document.getElementById(f(n.key,"tab"))===e.target);if(n<0)return;const t=e.shiftKey&&(e.ctrlKey||e.metaKey);if(t&&"ArrowRight"===e.key)ue(n,1);else if(t&&"ArrowLeft"===e.key)ue(n,-1);else if("ArrowRight"===e.key)ce(n+1);else if("ArrowLeft"===e.key)ce(n-1);else if("Home"===e.key)ce(0);else if("End"===e.key)ce(q.length-1);else{if("Delete"!==e.key||q[n].pinned)return;j(q[n].key)}e.preventDefault()},className:"flex min-w-0 flex-1 items-end -mx-2 px-2 scroll-px-2 overflow-x-auto overflow-y-hidden [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",children:ke}),R&&/* @__PURE__ */y("div",{className:"flex shrink-0 items-center gap-2 self-center",children:R}),V&&me&&/* @__PURE__ */p(r,{portal:!0,style:{left:V.x,top:V.y},onClose:()=>X(null),children:[fe.length>0&&/* @__PURE__ */p(h,{children:[fe.map((e,n)=>/* @__PURE__ */p(i,{onClick:he(e.onSelect),children:[e.icon,e.label]},n)),
26
26
  /* @__PURE__ */y(l,{})]}),
27
- /* @__PURE__ */y(i,{disabled:me.pinned,onClick:he(()=>j(me.key)),children:L.close}),
27
+ /* @__PURE__ */y(i,{disabled:me.pinned,onClick:he(()=>j(me.key)),children:F.close}),
28
28
  /* @__PURE__ */y(l,{}),
29
- /* @__PURE__ */y(i,{disabled:!ye(e.filter(e=>e.key!==me.key)),onClick:he(()=>D("others",me.key)),children:L.closeOthers}),
30
- /* @__PURE__ */y(i,{disabled:!ye(e.slice(pe+1)),onClick:he(()=>D("right",me.key)),children:L.closeRight}),
31
- /* @__PURE__ */y(i,{disabled:!ye(e),onClick:he(()=>D("all",null)),children:L.closeAll})]})]})}export{j as TabStrip};
29
+ /* @__PURE__ */y(i,{disabled:!ye(e.filter(e=>e.key!==me.key)),onClick:he(()=>D("others",me.key)),children:F.closeOthers}),
30
+ /* @__PURE__ */y(i,{disabled:!ye(e.slice(pe+1)),onClick:he(()=>D("right",me.key)),children:F.closeRight}),
31
+ /* @__PURE__ */y(i,{disabled:!ye(e),onClick:he(()=>D("all",null)),children:F.closeAll})]})]})}export{j as TabStrip};
@@ -1,14 +1,14 @@
1
- import{fromDateKey as e,toMonthKey as t,toDateKey as r,fromMonthKey as a}from"./chunk-2HMNOLKX.js";import{calendarNames as n,firstDayOfWeek as o}from"./chunk-Y3JW2GW5.js";import{Icon as l}from"./chunk-2UO47XB4.js";import{useBrowserValue as i}from"./chunk-D65T4H6J.js";import{useShellStrings as s,useShellLocale as c}from"./chunk-GDQJBQ5B.js";import{useMemo as g,useState as u,useRef as d,useEffect as h}from"react";import{jsxs as m,jsx as f,Fragment as b}from"react/jsx-runtime";var y="grid grid-cols-[repeat(7,minmax(0,40px))] sm:grid-cols-[repeat(7,minmax(0,32px))] justify-center gap-1";var v=()=>r(/* @__PURE__ */new Date);var p=(e,t)=>new Date(e.getFullYear(),e.getMonth(),e.getDate()+t),x=(e,t)=>{const r=new Date(e.getFullYear(),e.getMonth()+t,1),a=new Date(r.getFullYear(),r.getMonth()+1,0).getDate();return new Date(r.getFullYear(),r.getMonth(),Math.min(e.getDate(),a))};function w({value:w,endValue:D,mode:M="single",onSelect:N,min:Y,max:k,month:F,defaultMonth:j,onMonthChange:A,weekStartsOn:C,quickJump:S=!0,markedDates:q,readOnly:B=!1,"aria-label":J,className:K=""}){const O=g(()=>new Set(q??[]),[q]),P=e(w),W=i(v,null),H=e(W),U=s().calendar,$=c(),E=n($),G=i(()=>o($),0),L=C??G,Q=()=>{if(!H)return null;const e=t(H);return Y&&e<Y.slice(0,7)?Y.slice(0,7):k&&e>k.slice(0,7)?k.slice(0,7):e},[X,I]=u(()=>j||(P?t(P):Q())),R=F??X??Q(),T=null===R?null:function(e,t){return a(e)??t}(R,H),[V,z]=u(()=>w??W),Z=d(null),_=d(!1),[ee,te]=u("days"),re=g(()=>T?function(e,t){const r=new Date(e.getFullYear(),e.getMonth(),1),a=(r.getDay()-t+7)%7,n=new Date(r.getFullYear(),r.getMonth(),1-a);return Array.from({length:42},(e,t)=>new Date(n.getFullYear(),n.getMonth(),n.getDate()+t))}(T,L):[],[R,L]),ae=e=>!!Y&&e<Y||!!k&&e>k,ne=V??W,oe=re.some(e=>r(e)===ne),le=T?re.find(e=>e.getMonth()===T.getMonth())??re[0]:null,ie=oe&&ne?ne:le?r(le):"";if(h(()=>{_.current&&(_.current=!1,Z.current?.querySelector('[data-active="true"]')?.focus())},[ie,R]),!T)/* @__PURE__ */
1
+ import{fromDateKey as e,toMonthKey as t,toDateKey as r,fromMonthKey as a}from"./chunk-2HMNOLKX.js";import{calendarNames as n,firstDayOfWeek as o}from"./chunk-Y3JW2GW5.js";import{Icon as l}from"./chunk-R64OZ6TC.js";import{useBrowserValue as i}from"./chunk-D65T4H6J.js";import{useShellStrings as s,useShellLocale as c}from"./chunk-VNTJ7QO5.js";import{useMemo as g,useState as u,useRef as d,useEffect as h}from"react";import{jsxs as m,jsx as f,Fragment as b}from"react/jsx-runtime";var y="grid grid-cols-[repeat(7,minmax(0,40px))] sm:grid-cols-[repeat(7,minmax(0,32px))] justify-center gap-1";var v=()=>r(/* @__PURE__ */new Date);var p=(e,t)=>new Date(e.getFullYear(),e.getMonth(),e.getDate()+t),x=(e,t)=>{const r=new Date(e.getFullYear(),e.getMonth()+t,1),a=new Date(r.getFullYear(),r.getMonth()+1,0).getDate();return new Date(r.getFullYear(),r.getMonth(),Math.min(e.getDate(),a))};function w({value:w,endValue:D,mode:M="single",onSelect:N,min:Y,max:k,month:F,defaultMonth:j,onMonthChange:A,weekStartsOn:C,quickJump:S=!0,markedDates:O,readOnly:q=!1,"aria-label":J,className:K=""}){const P=g(()=>new Set(O??[]),[O]),W=e(w),H=i(v,null),T=e(H),$=s().calendar,E=c(),L=n(E),R=i(()=>o(E),0),U=C??R,V=()=>{if(!T)return null;const e=t(T);return Y&&e<Y.slice(0,7)?Y.slice(0,7):k&&e>k.slice(0,7)?k.slice(0,7):e},[B,G]=u(()=>j||(W?t(W):V())),I=F??B??V(),Q=null===I?null:function(e,t){return a(e)??t}(I,T),[X,Z]=u(()=>w??H),z=d(null),_=d(!1),[ee,te]=u("days"),re=g(()=>Q?function(e,t){const r=new Date(e.getFullYear(),e.getMonth(),1),a=(r.getDay()-t+7)%7,n=new Date(r.getFullYear(),r.getMonth(),1-a);return Array.from({length:42},(e,t)=>new Date(n.getFullYear(),n.getMonth(),n.getDate()+t))}(Q,U):[],[I,U]),ae=e=>!!Y&&e<Y||!!k&&e>k,ne=X??H,oe=re.some(e=>r(e)===ne),le=Q?re.find(e=>e.getMonth()===Q.getMonth())??re[0]:null,ie=oe&&ne?ne:le?r(le):"";if(h(()=>{_.current&&(_.current=!1,z.current?.querySelector('[data-active="true"]')?.focus())},[ie,I]),!Q)/* @__PURE__ */
2
2
  return m("div",{className:K,"aria-hidden":"true","data-calendar-pending":"",children:[
3
3
  /* @__PURE__ */f("div",{className:"mb-2 h-6"}),
4
- /* @__PURE__ */f("div",{className:"space-y-1",children:Array.from({length:7},(e,t)=>/* @__PURE__ */f("div",0===t?{className:"py-1 text-xs",children:" "}:{className:y,children:/* @__PURE__ */f("span",{className:"aspect-square"})},t))})]});const se=e=>"years"===ee?new Date(T.getFullYear()+12*e,T.getMonth(),1):"months"===ee?new Date(T.getFullYear()+e,T.getMonth(),1):x(T,e),ce=e=>{const r=t(e);void 0===F&&I(r),A?.(r)},ge=J??E.monthYear(T.getFullYear(),T.getMonth());/* @__PURE__ */
4
+ /* @__PURE__ */f("div",{className:"space-y-1",children:Array.from({length:7},(e,t)=>/* @__PURE__ */f("div",0===t?{className:"py-1 text-xs",children:" "}:{className:y,children:/* @__PURE__ */f("span",{className:"aspect-square"})},t))})]});const se=e=>"years"===ee?new Date(Q.getFullYear()+12*e,Q.getMonth(),1):"months"===ee?new Date(Q.getFullYear()+e,Q.getMonth(),1):x(Q,e),ce=e=>{const r=t(e);void 0===F&&G(r),A?.(r)},ge=J??L.monthYear(Q.getFullYear(),Q.getMonth());/* @__PURE__ */
5
5
  return m("div",{className:K,children:[
6
6
  /* @__PURE__ */m("div",{className:"mb-2 flex items-center justify-between px-1",children:[
7
- /* @__PURE__ */f("button",{type:"button","aria-label":"years"===ee?U.previousYears:"months"===ee?U.previousYear:U.previousMonth,onClick:()=>ce(se(-1)),className:"rounded-full p-1 text-gray-600 hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:/* @__PURE__ */f(l,{name:"chevron-left",className:"h-4 w-4",strokeWidth:"2","aria-hidden":"true"})}),
8
- /* @__PURE__ */f("div",{"aria-live":"polite",className:"flex items-center gap-1 text-sm font-semibold text-gray-800",children:S?/* @__PURE__ */m(b,{children:["years"!==ee&&/* @__PURE__ */f("button",{type:"button","aria-label":U.chooseMonth(E.months[T.getMonth()]),onClick:()=>te(e=>"months"===e?"days":"months"),className:"rounded-md px-2 py-0.5 transition-colors hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:E.months[T.getMonth()]}),
9
- /* @__PURE__ */f("button",{type:"button","aria-label":U.chooseYear(T.getFullYear()),onClick:()=>te(e=>"years"===e?"days":"years"),className:"rounded-md px-2 py-0.5 transition-colors hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:T.getFullYear()})]}):/* @__PURE__ */f("span",{children:E.monthYear(T.getFullYear(),T.getMonth())})}),
10
- /* @__PURE__ */f("button",{type:"button","aria-label":"years"===ee?U.nextYears:"months"===ee?U.nextYear:U.nextMonth,onClick:()=>ce(se(1)),className:"rounded-full p-1 text-gray-600 hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:/* @__PURE__ */f(l,{name:"chevron-right",className:"h-4 w-4",strokeWidth:"2","aria-hidden":"true"})})]}),"months"===ee&&/* @__PURE__ */f("div",{role:"group","aria-label":U.monthPanel,className:"grid grid-cols-3 gap-1 text-center text-sm",children:E.monthsShort.map((e,t)=>/* @__PURE__ */f("button",{type:"button","aria-pressed":t===T.getMonth(),onClick:()=>{ce(new Date(T.getFullYear(),t,1)),te("days")},className:["rounded-md py-4 transition-colors rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",t===T.getMonth()?"bg-blue-600 font-semibold text-white":H&&t===H.getMonth()&&T.getFullYear()===H.getFullYear()?"font-medium text-blue-600 hover:bg-gray-100":"text-gray-700 hover:bg-gray-100"].join(" "),children:e},e))}),"years"===ee&&/* @__PURE__ */f("div",{role:"group","aria-label":U.yearPanel,className:"grid grid-cols-3 gap-1 text-center text-sm",children:Array.from({length:12},(e,t)=>{return r=T.getFullYear(),12*Math.floor(r/12)+t;var r}).map(e=>/* @__PURE__ */f("button",{type:"button","aria-pressed":e===T.getFullYear(),onClick:()=>{ce(new Date(e,T.getMonth(),1)),te("months")},className:["rounded-md py-4 transition-colors rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",e===T.getFullYear()?"bg-blue-600 font-semibold text-white":e===H?.getFullYear()?"font-medium text-blue-600 hover:bg-gray-100":"text-gray-700 hover:bg-gray-100"].join(" "),children:e},e))}),
11
- /* @__PURE__ */m("div",{ref:Z,role:"grid","aria-label":ge,className:"space-y-1","aria-readonly":B||void 0,onKeyDown:a=>{const n=e(ie)??H??T,o={ArrowLeft:()=>p(n,-1),ArrowRight:()=>p(n,1),ArrowUp:()=>p(n,-7),ArrowDown:()=>p(n,7),Home:()=>p(n,-(n.getDay()-L+7)%7),End:()=>p(n,6-(n.getDay()-L+7)%7),PageUp:()=>x(n,a.shiftKey?-12:-1),PageDown:()=>x(n,a.shiftKey?12:1)};if(o[a.key])return a.preventDefault(),l=o[a.key](),_.current=!0,z(r(l)),void(t(l)!==R&&ce(l));var l;"Enter"!==a.key&&" "!==a.key||(a.preventDefault(),B||ae(ie)||N(ie))},hidden:"days"!==ee,children:[
12
- /* @__PURE__ */f("div",{role:"row",className:`${y} text-center text-xs font-medium text-ink-faint`,children:Array.from({length:7},(e,t)=>(t+L)%7).map(e=>
13
- /* @__PURE__ */f("div",{role:"columnheader","aria-label":E.weekdays[e],className:"py-1",children:/* @__PURE__ */f("abbr",{title:E.weekdays[e],className:"no-underline",children:E.weekdaysShort[e]})},e))}),Array.from({length:6},(e,t)=>/* @__PURE__ */f("div",{role:"row",className:`${y} text-center text-sm`,children:re.slice(7*t,7*t+7).map(e=>{const t=r(e),a=e.getMonth()!==T.getMonth(),n=t===w||"range"===M&&t===D,o=(e=>!("range"!==M||!w||!D)&&e>w&&e<D)(t),l=ae(t),i=E.longDate(e.getFullYear(),e.getMonth(),e.getDate()),s=e=>["relative w-full aspect-square rounded-md transition-colors",e?"rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]":"",l?"cursor-not-allowed text-gray-300":n?"bg-accent-fill font-semibold text-on-accent":o?"bg-accent-tint-strong text-blue-800":a?"text-ink-faint"+(e?" hover:bg-gray-100":""):"text-ink"+(e?" hover:bg-gray-100":""),t!==W||n?"":"font-semibold text-blue-600"].filter(Boolean).join(" "),c=O.has(t)&&/* @__PURE__ */f("span",{"data-marked":"","aria-hidden":"true",className:"absolute bottom-1 left-1/2 h-1 w-1 -translate-x-1/2 rounded-full "+(n?"bg-surface":a?"bg-gray-400":"bg-blue-500")});/* @__PURE__ */
14
- return f("div",{role:"gridcell","aria-selected":n,"aria-label":B?i:void 0,children:B?/* @__PURE__ */m("span",{"aria-hidden":"true",className:`grid place-items-center ${s(!1)}`,children:[e.getDate(),c]}):/* @__PURE__ */m("button",{type:"button","data-active":t===ie,tabIndex:t===ie?0:-1,disabled:l,"aria-label":i,"aria-current":t===W?"date":void 0,onClick:()=>{z(t),N(t)},className:s(!0),children:[e.getDate(),c]})},t)})},t))]})]})}export{w as Calendar};
7
+ /* @__PURE__ */f("button",{type:"button","aria-label":"years"===ee?$.previousYears:"months"===ee?$.previousYear:$.previousMonth,onClick:()=>ce(se(-1)),className:"rounded-full p-1 text-gray-600 hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:/* @__PURE__ */f(l,{name:"chevron-left",className:"h-4 w-4",strokeWidth:"2","aria-hidden":"true"})}),
8
+ /* @__PURE__ */f("div",{"aria-live":"polite",className:"flex items-center gap-1 text-sm font-semibold text-gray-800",children:S?/* @__PURE__ */m(b,{children:["years"!==ee&&/* @__PURE__ */f("button",{type:"button","aria-label":$.chooseMonth(L.months[Q.getMonth()]),onClick:()=>te(e=>"months"===e?"days":"months"),className:"rounded-md px-2 py-0.5 transition-colors hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:L.months[Q.getMonth()]}),
9
+ /* @__PURE__ */f("button",{type:"button","aria-label":$.chooseYear(Q.getFullYear()),onClick:()=>te(e=>"years"===e?"days":"years"),className:"rounded-md px-2 py-0.5 transition-colors hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:Q.getFullYear()})]}):/* @__PURE__ */f("span",{children:L.monthYear(Q.getFullYear(),Q.getMonth())})}),
10
+ /* @__PURE__ */f("button",{type:"button","aria-label":"years"===ee?$.nextYears:"months"===ee?$.nextYear:$.nextMonth,onClick:()=>ce(se(1)),className:"rounded-full p-1 text-gray-600 hover:bg-gray-100 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:/* @__PURE__ */f(l,{name:"chevron-right",className:"h-4 w-4",strokeWidth:"2","aria-hidden":"true"})})]}),"months"===ee&&/* @__PURE__ */f("div",{role:"group","aria-label":$.monthPanel,className:"grid grid-cols-3 gap-1 text-center text-sm",children:L.monthsShort.map((e,t)=>/* @__PURE__ */f("button",{type:"button","aria-pressed":t===Q.getMonth(),onClick:()=>{ce(new Date(Q.getFullYear(),t,1)),te("days")},className:["rounded-md py-4 transition-colors rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",t===Q.getMonth()?"bg-blue-600 font-semibold text-white":T&&t===T.getMonth()&&Q.getFullYear()===T.getFullYear()?"font-medium text-blue-600 hover:bg-gray-100":"text-gray-700 hover:bg-gray-100"].join(" "),children:e},e))}),"years"===ee&&/* @__PURE__ */f("div",{role:"group","aria-label":$.yearPanel,className:"grid grid-cols-3 gap-1 text-center text-sm",children:Array.from({length:12},(e,t)=>{return r=Q.getFullYear(),12*Math.floor(r/12)+t;var r}).map(e=>/* @__PURE__ */f("button",{type:"button","aria-pressed":e===Q.getFullYear(),onClick:()=>{ce(new Date(e,Q.getMonth(),1)),te("months")},className:["rounded-md py-4 transition-colors rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",e===Q.getFullYear()?"bg-blue-600 font-semibold text-white":e===T?.getFullYear()?"font-medium text-blue-600 hover:bg-gray-100":"text-gray-700 hover:bg-gray-100"].join(" "),children:e},e))}),
11
+ /* @__PURE__ */m("div",{ref:z,role:"grid","aria-label":ge,className:"space-y-1","aria-readonly":q||void 0,onKeyDown:a=>{const n=e(ie)??T??Q,o={ArrowLeft:()=>p(n,-1),ArrowRight:()=>p(n,1),ArrowUp:()=>p(n,-7),ArrowDown:()=>p(n,7),Home:()=>p(n,-(n.getDay()-U+7)%7),End:()=>p(n,6-(n.getDay()-U+7)%7),PageUp:()=>x(n,a.shiftKey?-12:-1),PageDown:()=>x(n,a.shiftKey?12:1)};if(o[a.key])return a.preventDefault(),l=o[a.key](),_.current=!0,Z(r(l)),void(t(l)!==I&&ce(l));var l;"Enter"!==a.key&&" "!==a.key||(a.preventDefault(),q||ae(ie)||N(ie))},hidden:"days"!==ee,children:[
12
+ /* @__PURE__ */f("div",{role:"row",className:`${y} text-center text-xs font-medium text-ink-faint`,children:Array.from({length:7},(e,t)=>(t+U)%7).map(e=>
13
+ /* @__PURE__ */f("div",{role:"columnheader","aria-label":L.weekdays[e],className:"py-1",children:/* @__PURE__ */f("abbr",{title:L.weekdays[e],className:"no-underline",children:L.weekdaysShort[e]})},e))}),Array.from({length:6},(e,t)=>/* @__PURE__ */f("div",{role:"row",className:`${y} text-center text-sm`,children:re.slice(7*t,7*t+7).map(e=>{const t=r(e),a=e.getMonth()!==Q.getMonth(),n=t===w||"range"===M&&t===D,o=(e=>!("range"!==M||!w||!D)&&e>w&&e<D)(t),l=ae(t),i=L.longDate(e.getFullYear(),e.getMonth(),e.getDate()),s=e=>["relative w-full aspect-square rounded-md transition-colors",e?"rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]":"",l?"cursor-not-allowed text-gray-300":n?"bg-accent-fill font-semibold text-on-accent":o?"bg-accent-tint-strong text-blue-800":a?"text-ink-faint"+(e?" hover:bg-gray-100":""):"text-ink"+(e?" hover:bg-gray-100":""),t!==H||n?"":"font-semibold text-blue-600"].filter(Boolean).join(" "),c=P.has(t)&&/* @__PURE__ */f("span",{"data-marked":"","aria-hidden":"true",className:"absolute bottom-1 left-1/2 h-1 w-1 -translate-x-1/2 rounded-full "+(n?"bg-surface":a?"bg-gray-400":"bg-blue-500")});/* @__PURE__ */
14
+ return f("div",{role:"gridcell","aria-selected":n,"aria-label":q?i:void 0,children:q?/* @__PURE__ */m("span",{"aria-hidden":"true",className:`grid place-items-center ${s(!1)}`,children:[e.getDate(),c]}):/* @__PURE__ */m("button",{type:"button","data-active":t===ie,tabIndex:t===ie?0:-1,disabled:l,"aria-label":i,"aria-current":t===H?"date":void 0,onClick:()=>{Z(t),N(t)},className:s(!0),children:[e.getDate(),c]})},t)})},t))]})]})}export{w as Calendar};
@@ -1,4 +1,4 @@
1
- import{InputNumber_default as e}from"./chunk-QRU55BUS.js";import{IconButton_default as r}from"./chunk-LE5LWALR.js";import{Icon as a}from"./chunk-2UO47XB4.js";import{Tooltip as i}from"./chunk-NJN5IKWO.js";import{useShellStrings as n}from"./chunk-GDQJBQ5B.js";import{useState as l,useRef as o}from"react";import{jsxs as t,jsx as s}from"react/jsx-runtime";var d={tl:"",tr:"rotate-90",br:"rotate-180",bl:"-rotate-90"},c=["tl","tr","bl","br"];function u({label:u,value:m,corners:f,onChange:p,radius:h=null,onRadiusChange:v,radiusLabel:b,radiusMin:k=0,radiusMax:g,radiusStep:x=1,radiusPlaceholder:w,disabled:y=!1,disabledReason:j,id:A,className:N=""}){const R=n(),B=function(e){const r=c.map(r=>e.find(e=>e.value===r));for(const a of e){if(c.includes(a.value))continue;const e=r.findIndex(e=>void 0===e);-1===e?r.push(a):r[e]=a}return r.filter(e=>void 0!==e)}(f),[K,L]=l(0),C=o(null);/* @__PURE__ */
2
- return t("div",{id:A,role:"group","aria-label":u,className:`flex min-w-0 flex-wrap items-center gap-2 ${N}`.trim(),children:[v&&
1
+ import{InputNumber_default as e}from"./chunk-GV5VNWPG.js";import{IconButton_default as r}from"./chunk-LE5LWALR.js";import{Icon as a}from"./chunk-R64OZ6TC.js";import{Tooltip as i}from"./chunk-NJN5IKWO.js";import{useShellStrings as n}from"./chunk-VNTJ7QO5.js";import{useState as l,useRef as o}from"react";import{jsxs as t,jsx as s}from"react/jsx-runtime";var d={tl:"",tr:"rotate-90",br:"rotate-180",bl:"-rotate-90"},c=["tl","tr","bl","br"];function u({label:u,value:m,corners:f,onChange:p,radius:h=null,onRadiusChange:v,radiusLabel:b,radiusMin:k=0,radiusMax:g,radiusStep:x=1,radiusPlaceholder:w,disabled:y=!1,disabledReason:N,id:j,className:A=""}){const R=n(),C=function(e){const r=c.map(r=>e.find(e=>e.value===r));for(const a of e){if(c.includes(a.value))continue;const e=r.findIndex(e=>void 0===e);-1===e?r.push(a):r[e]=a}return r.filter(e=>void 0!==e)}(f),[K,L]=l(0),M=o(null);/* @__PURE__ */
2
+ return t("div",{id:j,role:"group","aria-label":u,className:`flex min-w-0 flex-wrap items-center gap-2 ${A}`.trim(),children:[v&&
3
3
  /* @__PURE__ */s("div",{className:"w-30 shrink-0",children:/* @__PURE__ */s(e,{value:h,onChange:v,min:k,max:g,step:x,precision:0,placeholder:w,prefix:/* @__PURE__ */s("span",{"data-radius-mark":"","aria-hidden":"true",children:R.corners.radiusMark}),suffix:R.corners.unit,steppers:"compact",disabled:y,"aria-label":b??R.corners.radius})}),
4
- /* @__PURE__ */s("div",{ref:C,"data-corners-grid":"",className:"grid shrink-0 grid-cols-2 gap-1",onKeyDown:e=>{if(e.altKey||e.ctrlKey||e.metaKey)return;const r=Array.from(C.current?.querySelectorAll("button[data-corner]")??[]),a=r.indexOf(document.activeElement);if(-1===a)return;const i=a%2,n=Math.floor(a/2),l="ArrowRight"===e.key?2*n+1:"ArrowLeft"===e.key?2*n:"ArrowDown"===e.key?2+i:"ArrowUp"===e.key?i:null;null!==l&&(e.preventDefault(),l<r.length&&r[l].focus())},children:B.map((e,n)=>{const l=m.includes(e.value),o=y||!0===e.disabled,t=o&&(!0===e.disabled&&e.title||(y?j:void 0))||void 0,c=/* @__PURE__ */s(r,{"aria-pressed":l,"aria-label":e.label,"aria-disabled":o||void 0,disabledReason:t,"data-corner":e.value,size:"sm",tabIndex:n===K?0:-1,onFocus:()=>L(n),onClick:()=>{o||p(l?m.filter(r=>r!==e.value):[...m,e.value])},children:/* @__PURE__ */s(a,{name:"corner",strokeWidth:2,className:["h-4 w-4",d[e.value]??""].filter(Boolean).join(" ")})},e.value);return t?c:/* @__PURE__ */s(i,{content:e.title??e.label,children:c},e.value)})})]})}export{u as CornersInput};
4
+ /* @__PURE__ */s("div",{ref:M,"data-corners-grid":"",className:"grid shrink-0 grid-cols-2 gap-1",onKeyDown:e=>{if(e.altKey||e.ctrlKey||e.metaKey)return;const r=Array.from(M.current?.querySelectorAll("button[data-corner]")??[]),a=r.indexOf(document.activeElement);if(-1===a)return;const i=a%2,n=Math.floor(a/2),l="ArrowRight"===e.key?2*n+1:"ArrowLeft"===e.key?2*n:"ArrowDown"===e.key?2+i:"ArrowUp"===e.key?i:null;null!==l&&(e.preventDefault(),l<r.length&&r[l].focus())},children:C.map((e,n)=>{const l=m.includes(e.value),o=y||!0===e.disabled,t=o&&(!0===e.disabled&&e.title||(y?N:void 0))||void 0,c=/* @__PURE__ */s(r,{"aria-pressed":l,"aria-label":e.label,"aria-disabled":o||void 0,disabledReason:t,"data-corner":e.value,size:"sm",tabIndex:n===K?0:-1,onFocus:()=>L(n),onClick:()=>{o||p(l?m.filter(r=>r!==e.value):[...m,e.value])},children:/* @__PURE__ */s(a,{name:"corner",strokeWidth:2,className:["h-4 w-4",d[e.value]??""].filter(Boolean).join(" ")})},e.value);return t?c:/* @__PURE__ */s(i,{content:e.title??e.label,children:c},e.value)})})]})}export{u as CornersInput};
@@ -1,4 +1,4 @@
1
- import{Banner as e}from"./chunk-ZGOHRLXG.js";import{Button_default as t}from"./chunk-EOVXFXVV.js";import{useShellStrings as n}from"./chunk-GDQJBQ5B.js";import{useState as r,useEffect as i}from"react";import{jsx as o,jsxs as a}from"react/jsx-runtime";var s=6e4;function c({currentVersion:e,versionUrl:t="/version.json",pollMs:n=6e4}){const[o,a]=r(null);return i(()=>{if(!e||null!==o)return;let r=!1;const i=async()=>{if("undefined"==typeof document||"hidden"!==document.visibilityState)try{const n=t.includes("?")?"&":"?",i=await fetch(`${t}${n}t=${Date.now()}`,{cache:"no-store"});if(!i.ok)return;const o=await i.json(),s=o&&"object"==typeof o&&"string"==typeof o.version?o.version:null;!r&&s&&s!==e&&a(s)}catch{}};i();const s=setInterval(()=>{i()},n),c=()=>{"visible"===document.visibilityState&&i()};return document.addEventListener("visibilitychange",c),()=>{r=!0,clearInterval(s),document.removeEventListener("visibilitychange",c)}},[e,t,n,o]),o}function l({currentVersion:r,versionUrl:i,pollMs:s,message:l,onRefresh:m,className:u=""}){const d=c({currentVersion:r,versionUrl:i,pollMs:s}),p=n();if(null===d)return null;const f=m??(()=>window.location.reload());/* @__PURE__ */
1
+ import{Banner as e}from"./chunk-JGVKGEIV.js";import{Button_default as t}from"./chunk-EOVXFXVV.js";import{useShellStrings as n}from"./chunk-VNTJ7QO5.js";import{useState as r,useEffect as i}from"react";import{jsx as o,jsxs as a}from"react/jsx-runtime";var s=6e4;function c({currentVersion:e,versionUrl:t="/version.json",pollMs:n=6e4}){const[o,a]=r(null);return i(()=>{if(!e||null!==o)return;let r=!1;const i=async()=>{if("undefined"==typeof document||"hidden"!==document.visibilityState)try{const n=t.includes("?")?"&":"?",i=await fetch(`${t}${n}t=${Date.now()}`,{cache:"no-store"});if(!i.ok)return;const o=await i.json(),s=o&&"object"==typeof o&&"string"==typeof o.version?o.version:null;!r&&s&&s!==e&&a(s)}catch{}};i();const s=setInterval(()=>{i()},n),c=()=>{"visible"===document.visibilityState&&i()};return document.addEventListener("visibilitychange",c),()=>{r=!0,clearInterval(s),document.removeEventListener("visibilitychange",c)}},[e,t,n,o]),o}function l({currentVersion:r,versionUrl:i,pollMs:s,message:l,onRefresh:m,className:u=""}){const d=c({currentVersion:r,versionUrl:i,pollMs:s}),p=n();if(null===d)return null;const f=m??(()=>window.location.reload());/* @__PURE__ */
2
2
  return o("div",{"data-app-update-banner":"",className:`fixed left-1/2 top-3 z-(--z-toast) w-max max-w-[calc(100vw-1.5rem)] -translate-x-1/2 ${u}`.trim(),children:/* @__PURE__ */a(e,{tone:"warning",className:"shadow-lg",action:/* @__PURE__ */o(t,{type:"button",variant:"primary",size:"md",onClick:f,children:p.update.refreshNow}),children:[
3
3
  /* @__PURE__ */o("span",{className:"font-medium",children:l??p.update.available}),
4
4
  /* @__PURE__ */a("span",{className:"ml-2 whitespace-nowrap font-mono text-xs text-gray-500",children:[r," → ",d]})]})})}export{s as APP_UPDATE_POLL_MS,l as AppUpdateBanner,c as useAppUpdate};