efficient-shell 10.17.1 → 10.18.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 (254) hide show
  1. package/dist/{Browser-4B76MFTG.js → Browser-UWCA2UQO.js} +13 -13
  2. package/dist/Calculator-6NJNSIRN.js +29 -0
  3. package/dist/{CurrencyConverter-36BFSFRS.js → CurrencyConverter-42IHLJVV.js} +8 -8
  4. package/dist/{Documents-VKAMBKSP.js → Documents-NRS6FCCD.js} +25 -25
  5. package/dist/{Files-NRYZG4KY.js → Files-OGBZKSHI.js} +88 -88
  6. package/dist/{Notepad-AQXGH6VP.js → Notepad-CMLPGGRI.js} +9 -9
  7. package/dist/{PomodoroTimer-RHDLKJBY.js → PomodoroTimer-PD7POYX5.js} +20 -20
  8. package/dist/{Preview-DEBTZQP5.js → Preview-XPSNRIYM.js} +51 -51
  9. package/dist/Sidebar-2HHICMZZ.js +44 -0
  10. package/dist/{Spreadsheet-FSHLWXYP.js → Spreadsheet-WLRVB7LK.js} +11 -11
  11. package/dist/{Stock-CV53A432.js → Stock-IABQRSXZ.js} +3 -3
  12. package/dist/{Weather-R4MCLH7F.js → Weather-4QPYOENN.js} +22 -22
  13. package/dist/{WorldClock-CSFPCZHU.js → WorldClock-3ZVRBLEW.js} +6 -6
  14. package/dist/ai/index.d.ts +19 -3
  15. package/dist/ai/index.js +91 -81
  16. package/dist/ai.css +1 -1
  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/brand.css +1 -1
  21. package/dist/charts/BoxPlotChart.js +1 -1
  22. package/dist/charts/CandlestickChart.js +1 -1
  23. package/dist/charts/ChartTooltip.js +1 -1
  24. package/dist/charts/ChordChart.js +1 -1
  25. package/dist/charts/ColumnChart.js +1 -1
  26. package/dist/charts/FunnelChart.js +1 -1
  27. package/dist/charts/HeatmapChart.js +1 -1
  28. package/dist/charts/HistogramChart.js +1 -1
  29. package/dist/charts/PieChart.js +1 -1
  30. package/dist/charts/RadarChart.js +1 -1
  31. package/dist/charts/RadialBarChart.js +1 -1
  32. package/dist/charts/RangeChart.js +1 -1
  33. package/dist/charts/SankeyChart.js +1 -1
  34. package/dist/charts/ScatterChart.js +1 -1
  35. package/dist/charts/SpecChart.js +1 -1
  36. package/dist/charts/SunburstChart.js +1 -1
  37. package/dist/charts/TimeSeriesChart.js +1 -1
  38. package/dist/charts/TreemapChart.js +1 -1
  39. package/dist/charts/WaterfallChart.js +1 -1
  40. package/dist/chunk-22RQC4EW.js +20 -0
  41. package/dist/chunk-2H6YNMBE.js +14 -0
  42. package/dist/{chunk-XTV3CAV7.js → chunk-2VGQS6CW.js} +1 -1
  43. package/dist/{chunk-5VAIVRK6.js → chunk-2YSGXZOL.js} +48 -48
  44. package/dist/{chunk-SQCUN2DX.js → chunk-34URULVW.js} +1 -1
  45. package/dist/{chunk-5LCDCO46.js → chunk-3ELLBQPS.js} +1 -1
  46. package/dist/{chunk-NZQCDFDG.js → chunk-3NW5LD7D.js} +3 -3
  47. package/dist/{chunk-IX7QXMNJ.js → chunk-3PR5YMWZ.js} +1 -1
  48. package/dist/{chunk-ILP7QVW5.js → chunk-3UXXA2CS.js} +8 -8
  49. package/dist/{chunk-NRI26RYC.js → chunk-4HBSQGRI.js} +2 -2
  50. package/dist/{chunk-BZUA5F33.js → chunk-4UKGVLFP.js} +1 -1
  51. package/dist/{chunk-3VLG6LR3.js → chunk-4WEFGKJL.js} +4 -4
  52. package/dist/{chunk-UABVKJK7.js → chunk-54NMFQMW.js} +1 -1
  53. package/dist/{chunk-IDV32UV7.js → chunk-5HO53ZE7.js} +26 -26
  54. package/dist/{chunk-U32J7D4Q.js → chunk-5QGBVTGS.js} +2 -2
  55. package/dist/{chunk-BE777IO7.js → chunk-5SIOCKCK.js} +2 -2
  56. package/dist/{chunk-D6OYQM4V.js → chunk-5TDQPZDB.js} +5 -5
  57. package/dist/chunk-5TQLUPZD.js +6 -0
  58. package/dist/{chunk-AEJYSUVQ.js → chunk-5WYRAJ5F.js} +1 -1
  59. package/dist/chunk-67MQ5S32.js +8 -0
  60. package/dist/chunk-6JSXIEH2.js +4 -0
  61. package/dist/{chunk-Q3IR5SKD.js → chunk-6XBWM453.js} +1 -1
  62. package/dist/{chunk-L2RS2UQM.js → chunk-77AQNJE2.js} +1 -1
  63. package/dist/chunk-77MOYIQW.js +15 -0
  64. package/dist/chunk-7INZ7O3A.js +5 -0
  65. package/dist/{chunk-G4JTO5PB.js → chunk-7JGR7WPD.js} +1 -1
  66. package/dist/{chunk-3PR7FLTZ.js → chunk-7VBXIIEC.js} +2 -2
  67. package/dist/{chunk-MAFSELZK.js → chunk-A42MKJA3.js} +1 -1
  68. package/dist/{chunk-SOJEQHZ2.js → chunk-AYDW63LV.js} +1 -1
  69. package/dist/{chunk-XCAO2F3H.js → chunk-C6Y7B73Q.js} +1 -1
  70. package/dist/{chunk-EC527NE3.js → chunk-DCRLJMQ6.js} +1 -1
  71. package/dist/chunk-DESWIPOZ.js +3 -0
  72. package/dist/{chunk-WWLKVGV7.js → chunk-DGZAQXTW.js} +4 -4
  73. package/dist/{chunk-TLWGOQI3.js → chunk-DHIQ46C5.js} +3 -3
  74. package/dist/chunk-DYNJ2H6R.js +8 -0
  75. package/dist/chunk-EJUNGVK2.js +22 -0
  76. package/dist/{chunk-CNUHLJYD.js → chunk-EPY34L26.js} +1 -1
  77. package/dist/{chunk-XKJ7GEVA.js → chunk-FACWYKL6.js} +6 -6
  78. package/dist/{chunk-ZI3DGOW6.js → chunk-FKRPQDFX.js} +16 -16
  79. package/dist/{chunk-HS2E7DVI.js → chunk-FOFZI62F.js} +1 -1
  80. package/dist/{chunk-Q5QS5MFX.js → chunk-FS6EOU4G.js} +1 -1
  81. package/dist/{chunk-RBEI4CKX.js → chunk-FTF6JKD5.js} +5 -5
  82. package/dist/{chunk-WZ5QSSUM.js → chunk-G4GVLK44.js} +6 -6
  83. package/dist/{chunk-K7L3ZCPB.js → chunk-GEP4FROW.js} +3 -3
  84. package/dist/{chunk-5N5AAYQV.js → chunk-GISDIVFK.js} +1 -1
  85. package/dist/{chunk-NZGNOMWX.js → chunk-GMOEYB4X.js} +11 -11
  86. package/dist/{chunk-5IPFQV34.js → chunk-GNNY35U6.js} +1 -1
  87. package/dist/{chunk-VHPT7ZS5.js → chunk-HV47GP2C.js} +5 -5
  88. package/dist/{chunk-TIGTIT3L.js → chunk-I33SVQ7P.js} +6 -6
  89. package/dist/chunk-I4VIEGCX.js +2 -0
  90. package/dist/chunk-JIGFR7Z3.js +11 -0
  91. package/dist/{chunk-YG6Y5X7S.js → chunk-JNQKBN5M.js} +5 -5
  92. package/dist/{chunk-QEB2UTHO.js → chunk-JYIH2EBG.js} +7 -7
  93. package/dist/{chunk-2EVTN26H.js → chunk-K4JQ3FQI.js} +2 -2
  94. package/dist/{chunk-BVIOCAEU.js → chunk-KDXH6FLQ.js} +1 -1
  95. package/dist/chunk-LAO5ZHQ6.js +14 -0
  96. package/dist/{chunk-QJLBBDX2.js → chunk-LYHJHUQH.js} +1 -1
  97. package/dist/chunk-MJGK6QTO.js +7 -0
  98. package/dist/{chunk-LAMRQE2P.js → chunk-MNNZGO2E.js} +1 -1
  99. package/dist/{chunk-S5SRXI4V.js → chunk-MVZRZTQP.js} +1 -1
  100. package/dist/{chunk-MMQ6ETRD.js → chunk-N67QX3WW.js} +2 -2
  101. package/dist/{chunk-3TKMH5VR.js → chunk-N6CS2FO2.js} +1 -1
  102. package/dist/{chunk-FEATDGFD.js → chunk-NFB7PARJ.js} +1 -1
  103. package/dist/{chunk-WON5GBJY.js → chunk-NU5HN3FZ.js} +7 -7
  104. package/dist/{chunk-AFINCNY3.js → chunk-NVD4AI5Y.js} +1 -1
  105. package/dist/{chunk-QLVJ5W4G.js → chunk-O47HKK6E.js} +1 -1
  106. package/dist/{chunk-M5LR7ZZX.js → chunk-O6JJIR4H.js} +1 -1
  107. package/dist/{chunk-EZUQ5NXE.js → chunk-OORL6BIG.js} +1 -1
  108. package/dist/{chunk-SDATPJM2.js → chunk-OP5DOO3K.js} +4 -4
  109. package/dist/{chunk-XQMPLXGG.js → chunk-PLK2WHZG.js} +16 -16
  110. package/dist/chunk-PN5FQVMB.js +7 -0
  111. package/dist/chunk-PUF75SMJ.js +1 -0
  112. package/dist/{chunk-NYEMGKAE.js → chunk-PW52RXPI.js} +1 -1
  113. package/dist/chunk-QDKAA3HR.js +2 -0
  114. package/dist/{chunk-CCIGAU5Y.js → chunk-QHPVAXHR.js} +3 -3
  115. package/dist/{chunk-NVFYLTJ6.js → chunk-QRYSL6QU.js} +2 -2
  116. package/dist/{chunk-HLQVB7FG.js → chunk-RBBIAIPH.js} +8 -8
  117. package/dist/{chunk-G4PGEQOX.js → chunk-RUGQO7YF.js} +9 -9
  118. package/dist/{chunk-ENDCV7B3.js → chunk-RVRDDTEG.js} +9 -9
  119. package/dist/{chunk-WS7XIJS6.js → chunk-RXCGE2AY.js} +1 -1
  120. package/dist/{chunk-SOBGCIPF.js → chunk-S74LKSUB.js} +1 -1
  121. package/dist/{chunk-CF7BMDU3.js → chunk-SDDV3UCN.js} +3 -3
  122. package/dist/{chunk-CUKDQPEN.js → chunk-SLU45G5J.js} +3 -3
  123. package/dist/{chunk-ZMRGHVKS.js → chunk-TKJBZIHT.js} +1 -1
  124. package/dist/chunk-TLMFVEMC.js +9 -0
  125. package/dist/{chunk-EQZZ4V5X.js → chunk-TXDA7TTP.js} +1 -1
  126. package/dist/{chunk-B4HSNEBK.js → chunk-UDKTAG57.js} +1 -1
  127. package/dist/{chunk-4D66DUU5.js → chunk-UYRMW5MO.js} +5 -5
  128. package/dist/{chunk-5W2OEDUD.js → chunk-V6Y4OC6K.js} +8 -8
  129. package/dist/{chunk-H7BKSATJ.js → chunk-VDUXPMOQ.js} +1 -1
  130. package/dist/{chunk-4V73LGZG.js → chunk-VIQ6OME2.js} +8 -8
  131. package/dist/{chunk-ZF2MNQXY.js → chunk-VN4KSRZ5.js} +1 -1
  132. package/dist/chunk-VNKAIEJ6.js +1 -0
  133. package/dist/{chunk-HLVOHOBC.js → chunk-VQCSHJEF.js} +5 -5
  134. package/dist/{chunk-7AZAMDGG.js → chunk-VWIYC2NB.js} +7 -7
  135. package/dist/{chunk-GD7ILVPF.js → chunk-W3OWPBQL.js} +2 -2
  136. package/dist/{chunk-N4ZEB4UD.js → chunk-WYFMSL4Q.js} +9 -9
  137. package/dist/{chunk-OUIE2N2Z.js → chunk-XCHAU2UN.js} +5 -5
  138. package/dist/{chunk-HJ2BDUO6.js → chunk-XK42AQOJ.js} +4 -4
  139. package/dist/{chunk-7X4QNWA7.js → chunk-XLWMM53L.js} +2 -2
  140. package/dist/chunk-XYBI57KO.js +12 -0
  141. package/dist/{chunk-X2KMUHBB.js → chunk-Y62TTKSY.js} +3 -3
  142. package/dist/{chunk-TXDBOSSB.js → chunk-YILGAEW3.js} +1 -1
  143. package/dist/{chunk-4MJA2SPJ.js → chunk-YJXS7BR5.js} +13 -13
  144. package/dist/{chunk-EQCFPRKJ.js → chunk-YSDPFDAG.js} +1 -1
  145. package/dist/{chunk-UG6RI525.js → chunk-Z5A4EY2R.js} +1 -1
  146. package/dist/{chunk-JFH5HW2G.js → chunk-ZQKA2XKH.js} +7 -7
  147. package/dist/{chunk-HYDVHGVT.js → chunk-ZWMODDVE.js} +2 -2
  148. package/dist/data/DataTable.js +1 -1
  149. package/dist/data/Kanban.js +1 -1
  150. package/dist/data/ListLoadError.js +1 -1
  151. package/dist/forms/AlignmentGrid.js +1 -1
  152. package/dist/forms/BorderInput.js +1 -1
  153. package/dist/forms/BrandAssetEditor.js +1 -1
  154. package/dist/forms/Button.js +1 -1
  155. package/dist/forms/ColorPicker.js +1 -1
  156. package/dist/forms/ComposerAttachments.js +1 -1
  157. package/dist/forms/CornersInput.js +1 -1
  158. package/dist/forms/DatePicker.js +1 -1
  159. package/dist/forms/DateRangePicker.js +1 -1
  160. package/dist/forms/DisplayChips.js +1 -1
  161. package/dist/forms/FilePicker.js +1 -1
  162. package/dist/forms/IconButton.js +1 -1
  163. package/dist/forms/IconPicker.js +1 -1
  164. package/dist/forms/InputNumber.js +1 -1
  165. package/dist/forms/LinkPicker.js +1 -1
  166. package/dist/forms/MediaLibrary.js +1 -1
  167. package/dist/forms/MediaUploadField.js +1 -1
  168. package/dist/forms/MediaUploadGrid.js +1 -1
  169. package/dist/forms/MediaUsedInList.js +1 -1
  170. package/dist/forms/NumericKeypad.js +1 -1
  171. package/dist/forms/PictureTiles.js +1 -1
  172. package/dist/forms/PositionInput.js +1 -1
  173. package/dist/forms/Segmented.js +1 -1
  174. package/dist/forms/Select.js +1 -1
  175. package/dist/forms/SidesInput.js +1 -1
  176. package/dist/forms/Slider.js +1 -1
  177. package/dist/forms/Snippet.js +1 -1
  178. package/dist/forms/SplitButton.js +1 -1
  179. package/dist/forms/TagInput.js +1 -1
  180. package/dist/forms/TextToolbar.js +1 -1
  181. package/dist/forms/WidthsBar.js +1 -1
  182. package/dist/index.js +222 -222
  183. package/dist/map/index.js +7 -7
  184. package/dist/page-tabs/index.js +5 -5
  185. package/dist/shell/AppUpdateBanner.js +1 -1
  186. package/dist/shell/ColoredBadge.js +1 -1
  187. package/dist/shell/ConfirmDialog.js +1 -1
  188. package/dist/shell/ContextMenu.js +1 -1
  189. package/dist/shell/Dialog.js +1 -1
  190. package/dist/shell/Drawer.js +1 -1
  191. package/dist/shell/DropdownMenu.js +1 -1
  192. package/dist/shell/EditableGrid.js +1 -1
  193. package/dist/shell/FloatingBar.js +1 -1
  194. package/dist/shell/GlobalSearch.js +1 -1
  195. package/dist/shell/HelpCenter.js +1 -1
  196. package/dist/shell/IconRail.js +1 -1
  197. package/dist/shell/ImageLightbox.js +1 -1
  198. package/dist/shell/ItemCount.js +1 -1
  199. package/dist/shell/LanguageSelect.js +1 -1
  200. package/dist/shell/Markdown.js +1 -1
  201. package/dist/shell/MilestoneTimeline.js +1 -1
  202. package/dist/shell/Popover.js +1 -1
  203. package/dist/shell/PopupMenu.js +1 -1
  204. package/dist/shell/ProductionTimeline.js +1 -1
  205. package/dist/shell/ResizeHandle.js +1 -1
  206. package/dist/shell/SearchableSelect.js +1 -1
  207. package/dist/shell/SettingReset.js +1 -1
  208. package/dist/shell/SidebarLayout.js +1 -1
  209. package/dist/shell/SidebarNav.js +1 -1
  210. package/dist/shell/SortableList.js +1 -1
  211. package/dist/shell/StatusBadge.js +1 -1
  212. package/dist/shell/Tabs.js +1 -1
  213. package/dist/shell/TimelineTrack.js +1 -1
  214. package/dist/shell/Tooltip.js +1 -1
  215. package/dist/shell/TopNav.js +1 -1
  216. package/dist/shell/TransferProgress.js +1 -1
  217. package/dist/shell/Tree.js +1 -1
  218. package/dist/shell/discardGuard.js +1 -1
  219. package/dist/telemetry/index.js +1 -1
  220. package/dist/templates/AuthScreen.js +1 -1
  221. package/dist/templates/ChatTemplate.js +1 -1
  222. package/dist/templates/CheckoutTemplate.js +1 -1
  223. package/dist/templates/DashboardTemplate.js +1 -1
  224. package/dist/templates/DataTablePage.js +1 -1
  225. package/dist/templates/EmailTemplate.js +1 -1
  226. package/dist/templates/ErrorBoundary.js +1 -1
  227. package/dist/templates/FormLayoutPage.js +1 -1
  228. package/dist/templates/GalleryTemplate.js +1 -1
  229. package/dist/ui/index.js +1 -1
  230. package/dist/version.js +1 -1
  231. package/package.json +1 -1
  232. package/dist/Calculator-AXFKAC7G.js +0 -29
  233. package/dist/Sidebar-CB6KRPW2.js +0 -44
  234. package/dist/chunk-4Q25UHWB.js +0 -22
  235. package/dist/chunk-6ACS4S4P.js +0 -15
  236. package/dist/chunk-7RPYVQEV.js +0 -2
  237. package/dist/chunk-DOC52JBV.js +0 -20
  238. package/dist/chunk-EDMDKQNO.js +0 -4
  239. package/dist/chunk-F7Z47OIF.js +0 -12
  240. package/dist/chunk-FX6DBXXD.js +0 -1
  241. package/dist/chunk-GLBLKHYA.js +0 -5
  242. package/dist/chunk-HXNMRJQ4.js +0 -2
  243. package/dist/chunk-HXZ5XPBS.js +0 -3
  244. package/dist/chunk-IHFZ7OXO.js +0 -14
  245. package/dist/chunk-KLBJ646Z.js +0 -8
  246. package/dist/chunk-NXVFY22L.js +0 -9
  247. package/dist/chunk-RAAH4TQU.js +0 -1
  248. package/dist/chunk-SRWZE3WA.js +0 -6
  249. package/dist/chunk-TNDRHHKN.js +0 -14
  250. package/dist/chunk-UXPBVRSE.js +0 -7
  251. package/dist/chunk-XPTOKPUM.js +0 -11
  252. package/dist/chunk-YUECA3XB.js +0 -8
  253. package/dist/chunk-YYZ73H64.js +0 -7
  254. /package/dist/{chunk-3J2PO3KW.js → chunk-ECJKIPWU.js} +0 -0
@@ -1,29 +1,29 @@
1
- import{peekBrowserStartUrl as e,claimBrowserStartUrl as t}from"./chunk-LWLCNQY7.js";import{AboutApp as o}from"./chunk-5IPFQV34.js";import{WindowTitle as r}from"./chunk-5VAIVRK6.js";import"./chunk-CY5N5OA3.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-QYL26AB4.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-2E2SUEEE.js";import{confirm as n}from"./chunk-XQMPLXGG.js";import"./chunk-GLBLKHYA.js";import"./chunk-KC3EX26K.js";import"./chunk-HS2E7DVI.js";import"./chunk-3DVNXNTF.js";import"./chunk-3J2PO3KW.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-UGTRSRIW.js";import"./chunk-CNUHLJYD.js";import"./chunk-CDAJKLGL.js";import"./chunk-RAAH4TQU.js";import"./chunk-3VLG6LR3.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-EQZZ4V5X.js";import"./chunk-HXNMRJQ4.js";import"./chunk-UQYNPYF4.js";import"./chunk-SQCUN2DX.js";import{Icon as s}from"./chunk-2UO47XB4.js";import"./chunk-J75ZT2JQ.js";import"./chunk-S5SRXI4V.js";import"./chunk-Q3IR5SKD.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-F27JJHNJ.js";import"./chunk-TWVUQUUD.js";import"./chunk-D65T4H6J.js";import"./chunk-R2VKEMZH.js";import"./chunk-MRJKZWWV.js";import"./chunk-GDQJBQ5B.js";import"./chunk-C3QOHMR6.js";import{useRef as a,useEffect as i,useState as l}from"react";import{jsxs as c,jsx as m,Fragment as u}from"react/jsx-runtime";var d="react-os-shell:browser-bookmarks",h="react-os-shell:browser-homepage",p="https://en.wikipedia.org/wiki/Main_Page",b=[{label:"Wikipedia",url:"https://en.wikipedia.org/wiki/Main_Page"},{label:"DevDocs",url:"https://devdocs.io"},{label:"Example",url:"https://example.com"}],k=new Set(["ac ad ae af ag ai al am ao aq ar as at au aw ax az ba bb bd be bf bg bh bi","bj bm bn bo br bs bt bw by bz ca cc cd cf cg ch ci ck cl cm cn co cr cu cv","cw cx cy cz de dj dk dm do dz ec ee eg er es et eu fi fj fk fm fo fr ga gd","ge gf gg gh gi gl gm gn gp gq gr gs gt gu gw gy hk hm hn hr ht hu id ie il","im in io iq ir is it je jm jo jp ke kg kh ki km kn kp kr kw ky kz la lb lc","li lk lr ls lt lu lv ly ma mc md me mg mh mk ml mm mn mo mp mq mr ms mt mu","mv mw mx my mz na nc ne nf ng ni nl no np nr nu nz om pa pe pf pg ph pk pl","pm pn pr ps pt pw py qa re ro rs ru rw sa sb sc sd se sg sh si sk sl sm sn","so sr ss st su sv sx sy sz tc td tf tg th tj tk tl tm tn to tr tt tv tw tz","ua ug uk us uy uz va vc ve vg vi vn vu wf ws ye yt za zm zw","com net org edu gov mil int info biz name pro app dev xyz online site tech","store shop cloud design digital agency studio media news blog live life","world today email systems solutions services software page link space host","press wiki team group works careers finance capital energy academy"].join(" ").split(" "));function g(e){let t=e.trim();return t?/^[a-z][a-z0-9+.-]*:\/\//i.test(t)?t:function(e){const t=/^([\w-]+\.)+([a-z]{2,})(\/.*)?$/i.exec(e);return null!==t&&k.has(t[2].toLowerCase())}(t)?"https://"+t:"https://duckduckgo.com/?q="+encodeURIComponent(t):""}var f=["duckduckgo.com","developer.mozilla.org","google.com","gmail.com","youtube.com","facebook.com","instagram.com","whatsapp.com","twitter.com","x.com","github.com","gitlab.com","linkedin.com","reddit.com","pinterest.com","amazon.com","amazon.ca","amazon.co.uk","apple.com","icloud.com","microsoft.com","outlook.com","live.com","office.com","netflix.com","spotify.com","paypal.com","stripe.com","chat.openai.com","chatgpt.com","claude.ai"];function x(){if("undefined"==typeof window)return b;try{const e=localStorage.getItem(d);if(!e)return b;const t=JSON.parse(e);if(Array.isArray(t)&&t.every(e=>"string"==typeof e?.url))return t}catch{}return b}function w(){return"undefined"==typeof window?p:localStorage.getItem(h)||p}function y(){const u=a(void 0);void 0===u.current&&(u.current=e()),i(()=>{null!=u.current&&t(u.current)},[]);const p=u.current?g(u.current.url):"",[b,k]=l(w),[f,y]=l(p||b),[j,C]=l(f),[R,W]=l([f]),[z,S]=l(0),[L,D]=l(0),[E,H]=l(x),[U,Q]=l(!1),[J,G]=l(null),T=a(null),X=a(null);i(()=>{try{localStorage.setItem(d,JSON.stringify(E))}catch{}},[E]);const M=e=>{const t=g(e);t&&(y(t),C(t),W(e=>{const o=e.slice(0,z+1);return o.push(t),o}),S(e=>e+1),Q(!1))},A=()=>{"undefined"!=typeof window&&window.open(f,"_blank","noopener,noreferrer")},K=()=>{const e=J?.trim();e?(H(t=>[...t,{label:e,url:f}]),G(null)):G(null)};i(()=>{if(null===J)return;T.current?.focus(),T.current?.select();const e=e=>{const t=e.target;t?.closest("[data-bookmark-popover]")||G(null)},t=setTimeout(()=>document.addEventListener("mousedown",e),0);return()=>{clearTimeout(t),document.removeEventListener("mousedown",e)}},[null!==J]);const P=e=>{H(t=>t.filter((t,o)=>o!==e))},V=z>0,I=z<R.length-1,B=E.some(e=>e.url===f),O="p-2 rounded hover:bg-gray-200 transition-colors text-gray-600 disabled:opacity-30";/* @__PURE__ */
1
+ import{peekBrowserStartUrl as e,claimBrowserStartUrl as t}from"./chunk-LWLCNQY7.js";import{AboutApp as o}from"./chunk-GNNY35U6.js";import{WindowTitle as r}from"./chunk-2YSGXZOL.js";import"./chunk-CY5N5OA3.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-QYL26AB4.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-2E2SUEEE.js";import{confirm as n}from"./chunk-PLK2WHZG.js";import"./chunk-7INZ7O3A.js";import"./chunk-KC3EX26K.js";import"./chunk-FOFZI62F.js";import"./chunk-3DVNXNTF.js";import"./chunk-ECJKIPWU.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-UGTRSRIW.js";import"./chunk-EPY34L26.js";import"./chunk-CDAJKLGL.js";import"./chunk-VNKAIEJ6.js";import"./chunk-4WEFGKJL.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-TXDA7TTP.js";import"./chunk-I4VIEGCX.js";import"./chunk-UQYNPYF4.js";import"./chunk-34URULVW.js";import{Icon as s}from"./chunk-2UO47XB4.js";import"./chunk-J75ZT2JQ.js";import"./chunk-R2VKEMZH.js";import"./chunk-MRJKZWWV.js";import"./chunk-MVZRZTQP.js";import"./chunk-6XBWM453.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-F27JJHNJ.js";import"./chunk-TWVUQUUD.js";import"./chunk-GDQJBQ5B.js";import"./chunk-C3QOHMR6.js";import{useRef as a,useEffect as i,useState as l}from"react";import{jsxs as c,jsx as m,Fragment as u}from"react/jsx-runtime";var d="react-os-shell:browser-bookmarks",h="react-os-shell:browser-homepage",p="https://en.wikipedia.org/wiki/Main_Page",b=[{label:"Wikipedia",url:"https://en.wikipedia.org/wiki/Main_Page"},{label:"DevDocs",url:"https://devdocs.io"},{label:"Example",url:"https://example.com"}],k=new Set(["ac ad ae af ag ai al am ao aq ar as at au aw ax az ba bb bd be bf bg bh bi","bj bm bn bo br bs bt bw by bz ca cc cd cf cg ch ci ck cl cm cn co cr cu cv","cw cx cy cz de dj dk dm do dz ec ee eg er es et eu fi fj fk fm fo fr ga gd","ge gf gg gh gi gl gm gn gp gq gr gs gt gu gw gy hk hm hn hr ht hu id ie il","im in io iq ir is it je jm jo jp ke kg kh ki km kn kp kr kw ky kz la lb lc","li lk lr ls lt lu lv ly ma mc md me mg mh mk ml mm mn mo mp mq mr ms mt mu","mv mw mx my mz na nc ne nf ng ni nl no np nr nu nz om pa pe pf pg ph pk pl","pm pn pr ps pt pw py qa re ro rs ru rw sa sb sc sd se sg sh si sk sl sm sn","so sr ss st su sv sx sy sz tc td tf tg th tj tk tl tm tn to tr tt tv tw tz","ua ug uk us uy uz va vc ve vg vi vn vu wf ws ye yt za zm zw","com net org edu gov mil int info biz name pro app dev xyz online site tech","store shop cloud design digital agency studio media news blog live life","world today email systems solutions services software page link space host","press wiki team group works careers finance capital energy academy"].join(" ").split(" "));function g(e){let t=e.trim();return t?/^[a-z][a-z0-9+.-]*:\/\//i.test(t)?t:function(e){const t=/^([\w-]+\.)+([a-z]{2,})(\/.*)?$/i.exec(e);return null!==t&&k.has(t[2].toLowerCase())}(t)?"https://"+t:"https://duckduckgo.com/?q="+encodeURIComponent(t):""}var f=["duckduckgo.com","developer.mozilla.org","google.com","gmail.com","youtube.com","facebook.com","instagram.com","whatsapp.com","twitter.com","x.com","github.com","gitlab.com","linkedin.com","reddit.com","pinterest.com","amazon.com","amazon.ca","amazon.co.uk","apple.com","icloud.com","microsoft.com","outlook.com","live.com","office.com","netflix.com","spotify.com","paypal.com","stripe.com","chat.openai.com","chatgpt.com","claude.ai"];function x(){if("undefined"==typeof window)return b;try{const e=localStorage.getItem(d);if(!e)return b;const t=JSON.parse(e);if(Array.isArray(t)&&t.every(e=>"string"==typeof e?.url))return t}catch{}return b}function w(){return"undefined"==typeof window?p:localStorage.getItem(h)||p}function y(){const u=a(void 0);void 0===u.current&&(u.current=e()),i(()=>{null!=u.current&&t(u.current)},[]);const p=u.current?g(u.current.url):"",[b,k]=l(w),[f,y]=l(p||b),[j,C]=l(f),[W,z]=l([f]),[E,L]=l(0),[R,U]=l(0),[S,D]=l(x),[T,G]=l(!1),[J,H]=l(null),P=a(null),M=a(null);i(()=>{try{localStorage.setItem(d,JSON.stringify(S))}catch{}},[S]);const F=e=>{const t=g(e);t&&(y(t),C(t),z(e=>{const o=e.slice(0,E+1);return o.push(t),o}),L(e=>e+1),G(!1))},I=()=>{"undefined"!=typeof window&&window.open(f,"_blank","noopener,noreferrer")},K=()=>{const e=J?.trim();e?(D(t=>[...t,{label:e,url:f}]),H(null)):H(null)};i(()=>{if(null===J)return;P.current?.focus(),P.current?.select();const e=e=>{const t=e.target;t?.closest("[data-bookmark-popover]")||H(null)},t=setTimeout(()=>document.addEventListener("mousedown",e),0);return()=>{clearTimeout(t),document.removeEventListener("mousedown",e)}},[null!==J]);const O=e=>{D(t=>t.filter((t,o)=>o!==e))},X=E>0,A=E<W.length-1,Q=S.some(e=>e.url===f),Z="p-2 rounded hover:bg-gray-200 transition-colors text-gray-600 disabled:opacity-30";/* @__PURE__ */
2
2
  return c("div",{className:"relative flex flex-col h-full bg-white",children:[
3
3
  /* @__PURE__ */m(r,{title:`Browser - ${v(f)}`}),
4
4
  /* @__PURE__ */m(o,{app:"browser"}),
5
5
  /* @__PURE__ */c("div",{className:"flex items-center gap-1 px-2 py-2 border-b border-line bg-surface-sunken shrink-0",children:[
6
- /* @__PURE__ */m("button",{onClick:()=>{if(z>0){const e=z-1;S(e),y(R[e]),C(R[e]),Q(!1)}},disabled:!V,className:O,title:"Back",children:/* @__PURE__ */m(s,{name:"chevron-left",className:"h-4 w-4",strokeWidth:2})}),
7
- /* @__PURE__ */m("button",{onClick:()=>{if(z<R.length-1){const e=z+1;S(e),y(R[e]),C(R[e]),Q(!1)}},disabled:!I,className:O,title:"Forward",children:/* @__PURE__ */m(s,{name:"chevron-right",className:"h-4 w-4",strokeWidth:2})}),
8
- /* @__PURE__ */m("button",{onClick:()=>D(e=>e+1),className:O,title:"Refresh",children:/* @__PURE__ */m(s,{name:"refresh",className:"h-4 w-4",strokeWidth:1.8})}),
9
- /* @__PURE__ */m("button",{onClick:()=>M(b),className:O,title:"Home",children:/* @__PURE__ */m(s,{name:"home",className:"h-4 w-4",strokeWidth:1.8})}),
10
- /* @__PURE__ */m("form",{onSubmit:e=>{e.preventDefault(),M(j)},className:"flex-1 flex items-center mx-1",children:/* @__PURE__ */c("div",{className:"flex items-center w-full bg-white border border-gray-300 rounded focus-within:border-blue-400 focus-within:ring-1 focus-within:ring-blue-200",children:[
6
+ /* @__PURE__ */m("button",{onClick:()=>{if(E>0){const e=E-1;L(e),y(W[e]),C(W[e]),G(!1)}},disabled:!X,className:Z,title:"Back",children:/* @__PURE__ */m(s,{name:"chevron-left",className:"h-4 w-4",strokeWidth:2})}),
7
+ /* @__PURE__ */m("button",{onClick:()=>{if(E<W.length-1){const e=E+1;L(e),y(W[e]),C(W[e]),G(!1)}},disabled:!A,className:Z,title:"Forward",children:/* @__PURE__ */m(s,{name:"chevron-right",className:"h-4 w-4",strokeWidth:2})}),
8
+ /* @__PURE__ */m("button",{onClick:()=>U(e=>e+1),className:Z,title:"Refresh",children:/* @__PURE__ */m(s,{name:"refresh",className:"h-4 w-4",strokeWidth:1.8})}),
9
+ /* @__PURE__ */m("button",{onClick:()=>F(b),className:Z,title:"Home",children:/* @__PURE__ */m(s,{name:"home",className:"h-4 w-4",strokeWidth:1.8})}),
10
+ /* @__PURE__ */m("form",{onSubmit:e=>{e.preventDefault(),F(j)},className:"flex-1 flex items-center mx-1",children:/* @__PURE__ */c("div",{className:"flex items-center w-full bg-white border border-gray-300 rounded focus-within:border-blue-400 focus-within:ring-1 focus-within:ring-blue-200",children:[
11
11
  /* @__PURE__ */m("span",{className:"px-2 text-gray-400 text-xs",children:f.startsWith("https://")?"🔒":"⚠️"}),
12
12
  /* @__PURE__ */m("input",{type:"text",value:j,onChange:e=>C(e.target.value),onFocus:e=>e.target.select(),className:"flex-1 px-1 py-1 text-sm bg-transparent outline-none font-mono",spellCheck:!1,placeholder:"Enter URL or search…"}),f!==j&&/* @__PURE__ */m("button",{type:"button",onClick:()=>C(f),className:"px-2 text-2xs text-ink-faintest hover:text-ink",title:"Reset to current URL",children:"×"})]})}),
13
- /* @__PURE__ */m("button",{"data-bookmark-popover":!0,onClick:()=>B?P(E.findIndex(e=>e.url===f)):void G(v(f)),className:O+" "+(B?"text-yellow-500":""),title:B?"Remove bookmark":"Add bookmark",children:/* @__PURE__ */m(s,{name:"star",className:"h-4 w-4",fill:B?"currentColor":"none",strokeWidth:1.5})}),
14
- /* @__PURE__ */m("button",{onClick:A,className:O,title:"Open in new tab",children:/* @__PURE__ */m(s,{name:"external",className:"h-4 w-4",strokeWidth:1.5})}),
15
- /* @__PURE__ */m("button",{onClick:()=>Q(e=>!e),className:O,title:"Embedding help",children:/* @__PURE__ */m(s,{name:"help",className:"h-4 w-4",strokeWidth:1.5})})]}),null!==J&&/* @__PURE__ */c("div",{"data-bookmark-popover":!0,className:"absolute right-3 top-12 z-30 w-72 bg-white border border-gray-200 rounded-md shadow-lg p-3",children:[
13
+ /* @__PURE__ */m("button",{"data-bookmark-popover":!0,onClick:()=>Q?O(S.findIndex(e=>e.url===f)):void H(v(f)),className:Z+" "+(Q?"text-yellow-500":""),title:Q?"Remove bookmark":"Add bookmark",children:/* @__PURE__ */m(s,{name:"star",className:"h-4 w-4",fill:Q?"currentColor":"none",strokeWidth:1.5})}),
14
+ /* @__PURE__ */m("button",{onClick:I,className:Z,title:"Open in new tab",children:/* @__PURE__ */m(s,{name:"external",className:"h-4 w-4",strokeWidth:1.5})}),
15
+ /* @__PURE__ */m("button",{onClick:()=>G(e=>!e),className:Z,title:"Embedding help",children:/* @__PURE__ */m(s,{name:"help",className:"h-4 w-4",strokeWidth:1.5})})]}),null!==J&&/* @__PURE__ */c("div",{"data-bookmark-popover":!0,className:"absolute right-3 top-12 z-30 w-72 bg-white border border-gray-200 rounded-md shadow-lg p-3",children:[
16
16
  /* @__PURE__ */m("div",{className:"text-2xs font-semibold uppercase tracking-wide text-ink-faint mb-1",children:"Bookmark this page"}),
17
17
  /* @__PURE__ */m("div",{className:"text-2xs text-ink-faintest truncate mb-2 font-mono",title:f,children:f}),
18
- /* @__PURE__ */m("input",{ref:T,type:"text",value:J,onChange:e=>G(e.target.value),onKeyDown:e=>{"Enter"===e.key?K():"Escape"===e.key&&G(null)},placeholder:"Name",className:"w-full text-sm px-2 h-8 border border-line-strong rounded focus:outline-none focus:border-blue-400 focus:ring-1 focus:ring-blue-200"}),
18
+ /* @__PURE__ */m("input",{ref:P,type:"text",value:J,onChange:e=>H(e.target.value),onKeyDown:e=>{"Enter"===e.key?K():"Escape"===e.key&&H(null)},placeholder:"Name",className:"w-full text-sm px-2 h-8 border border-line-strong rounded focus:outline-none focus:border-blue-400 focus:ring-1 focus:ring-blue-200"}),
19
19
  /* @__PURE__ */c("div",{className:"flex justify-end gap-1 mt-2",children:[
20
- /* @__PURE__ */m("button",{onClick:()=>G(null),className:"px-2 py-1 text-xs text-gray-600 hover:bg-gray-100 rounded",children:"Cancel"}),
20
+ /* @__PURE__ */m("button",{onClick:()=>H(null),className:"px-2 py-1 text-xs text-gray-600 hover:bg-gray-100 rounded",children:"Cancel"}),
21
21
  /* @__PURE__ */m("button",{onClick:K,disabled:!J.trim(),className:"px-2 py-1 text-xs bg-blue-500 text-white rounded hover:bg-blue-600 disabled:opacity-40",children:"Save"})]})]}),
22
- /* @__PURE__ */c("div",{className:"flex items-center gap-0.5 px-2 py-1 border-b border-gray-200 bg-white shrink-0 overflow-x-auto",children:[0===E.length&&/* @__PURE__ */m("span",{className:"text-2xs text-ink-faintest italic px-2",children:"No bookmarks yet — star the address bar to add one."}),E.map((e,t)=>/* @__PURE__ */c("button",{onClick:()=>M(e.url),onContextMenu:async o=>{o.preventDefault();await n({title:"Remove bookmark",message:`"${e.label}" will be removed from your bookmarks.`,confirmLabel:"Remove",variant:"danger"})&&P(t)},className:"flex items-center gap-2 px-2 py-0.5 rounded text-xs text-ink hover:bg-gray-100 whitespace-nowrap",title:`${e.url}\n(right-click to remove)`,children:[
22
+ /* @__PURE__ */c("div",{className:"flex items-center gap-0.5 px-2 py-1 border-b border-gray-200 bg-white shrink-0 overflow-x-auto",children:[0===S.length&&/* @__PURE__ */m("span",{className:"text-2xs text-ink-faintest italic px-2",children:"No bookmarks yet — star the address bar to add one."}),S.map((e,t)=>/* @__PURE__ */c("button",{onClick:()=>F(e.url),onContextMenu:async o=>{o.preventDefault();await n({title:"Remove bookmark",message:`"${e.label}" will be removed from your bookmarks.`,confirmLabel:"Remove",variant:"danger"})&&O(t)},className:"flex items-center gap-2 px-2 py-0.5 rounded text-xs text-ink hover:bg-gray-100 whitespace-nowrap",title:`${e.url}\n(right-click to remove)`,children:[
23
23
  /* @__PURE__ */m("img",{src:`https://icons.duckduckgo.com/ip3/${new URL(e.url).hostname}.ico`,alt:"",className:"h-3.5 w-3.5",onError:e=>{e.target.style.visibility="hidden"}}),e.label]},t)),
24
24
  /* @__PURE__ */m("div",{className:"flex-1"}),
25
25
  /* @__PURE__ */m("button",{onClick:()=>{k(f);try{localStorage.setItem(h,f)}catch{}},className:"px-2 py-0.5 text-2xs text-ink-faint hover:text-ink-strong",title:"Set current page as homepage",children:"Set as home"})]}),
26
- /* @__PURE__ */m("div",{className:"flex-1 relative min-h-0 bg-gray-50",children:/* @__PURE__ */m(N,{url:f,iframeKey:L,iframeRef:X,openExternal:A,showHelp:U,dismissHelp:()=>Q(!1)})})]})}function v(e){try{return new URL(e).hostname.replace(/^www\./,"")}catch{return e}}function N({url:e,iframeKey:t,iframeRef:o,openExternal:r,showHelp:n,dismissHelp:a}){const[d,h]=l(!1);i(()=>{h(!1)},[e]);return function(e){try{const t=new URL(e).hostname.toLowerCase();return f.some(e=>t===e||t.endsWith("."+e))}catch{return!1}}(e)&&!d?/* @__PURE__ */m("div",{className:"absolute inset-0 flex items-center justify-center bg-white p-8",children:/* @__PURE__ */c("div",{className:"max-w-md text-center",children:[
26
+ /* @__PURE__ */m("div",{className:"flex-1 relative min-h-0 bg-gray-50",children:/* @__PURE__ */m(N,{url:f,iframeKey:R,iframeRef:M,openExternal:I,showHelp:T,dismissHelp:()=>G(!1)})})]})}function v(e){try{return new URL(e).hostname.replace(/^www\./,"")}catch{return e}}function N({url:e,iframeKey:t,iframeRef:o,openExternal:r,showHelp:n,dismissHelp:a}){const[d,h]=l(!1);i(()=>{h(!1)},[e]);return function(e){try{const t=new URL(e).hostname.toLowerCase();return f.some(e=>t===e||t.endsWith("."+e))}catch{return!1}}(e)&&!d?/* @__PURE__ */m("div",{className:"absolute inset-0 flex items-center justify-center bg-white p-8",children:/* @__PURE__ */c("div",{className:"max-w-md text-center",children:[
27
27
  /* @__PURE__ */m(s,{name:"no-symbol",className:"h-14 w-14 mx-auto text-gray-300 mb-3",strokeWidth:1.2}),
28
28
  /* @__PURE__ */c("h3",{className:"text-base font-semibold text-gray-800 mb-1",children:[v(e)," can't be embedded"]}),
29
29
  /* @__PURE__ */c("p",{className:"text-sm text-gray-500 mb-4",children:["This site sends an ",
@@ -0,0 +1,29 @@
1
+ import{loadAppearance as e,WidgetSettingsModal as t}from"./chunk-DCRLJMQ6.js";import{useWidgetSettings as n}from"./chunk-2YSGXZOL.js";import"./chunk-CY5N5OA3.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-QYL26AB4.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-2E2SUEEE.js";import"./chunk-PLK2WHZG.js";import"./chunk-7INZ7O3A.js";import"./chunk-KC3EX26K.js";import"./chunk-FOFZI62F.js";import"./chunk-3DVNXNTF.js";import"./chunk-ECJKIPWU.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-UGTRSRIW.js";import"./chunk-EPY34L26.js";import"./chunk-CDAJKLGL.js";import"./chunk-4WEFGKJL.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-TXDA7TTP.js";import"./chunk-I4VIEGCX.js";import"./chunk-UQYNPYF4.js";import"./chunk-34URULVW.js";import{Icon as r}from"./chunk-2UO47XB4.js";import"./chunk-J75ZT2JQ.js";import"./chunk-R2VKEMZH.js";import"./chunk-MRJKZWWV.js";import"./chunk-MVZRZTQP.js";import"./chunk-6XBWM453.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-F27JJHNJ.js";import"./chunk-TWVUQUUD.js";import"./chunk-GDQJBQ5B.js";import"./chunk-C3QOHMR6.js";import{useState as c,useRef as i,useCallback as l,useEffect as o}from"react";import{jsxs as s,Fragment as a,jsx as u}from"react/jsx-runtime";var h="calc_appearance";function m(){const[m,k]=c("0"),[p,d]=c(null),[b,g]=c(null),[j,N]=c(!1),[y,x]=c(""),[f,C]=c([]),[v,$]=c(!1),[E,W]=c(()=>e(h)),[T,J]=c(!1),[D,U]=c(E),w=i(null);n(l(()=>{U({...E}),J(!0)},[E]));const F=l(e=>{x(""),k(t=>j||"0"===t?(N(!1),"."===e?"0.":e):"."===e&&t.includes(".")?t:t+e)},[j]),L=l(()=>{k("0"),d(null),g(null),N(!1)},[]),S=l((e,t,n)=>{switch(n){case"+":return e+t;case"-":return e-t;case"×":return e*t;case"÷":return 0===t?0:e/t;default:return t}},[]),G=l(e=>{const t=parseFloat(m);if(null!==p&&b&&!j){const e=S(p,t,b);k(String(e)),d(e),C(n=>[`${p} ${b} ${t} = ${e}`,...n].slice(0,20))}else d(t);g(e),N(!0)},[m,p,b,j,S]),A=l(()=>{if(null===p||!b)return;const e=parseFloat(m),t=S(p,e,b),n=`${p} ${b} ${e} =`;C(e=>[`${n} ${t}`,...e].slice(0,20)),x(n),k(String(t)),d(null),g(null),N(!0)},[m,p,b,S]),M=l(()=>{k(e=>String(parseFloat(e)/100))},[]),Q=l(()=>{k(e=>e.startsWith("-")?e.slice(1):"0"===e?e:"-"+e)},[]);o(()=>{const e=e=>{const t=e.target.tagName;"INPUT"!==t&&"TEXTAREA"!==t&&"SELECT"!==t&&(e.key>="0"&&e.key<="9"?F(e.key):"."===e.key?F("."):"+"===e.key?G("+"):"-"===e.key?G("-"):"*"===e.key?G("×"):"/"===e.key?(e.preventDefault(),G("÷")):"Enter"===e.key||"="===e.key?("Enter"===e.key&&e.target instanceof Node&&w.current?.contains(e.target)&&e.preventDefault(),A()):"Escape"===e.key?L():"Backspace"===e.key?k(e=>e.length>1?e.slice(0,-1):"0"):"%"===e.key&&M())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[F,G,A,L,M]);const X="flex items-center justify-center rounded-lg text-sm font-medium transition-colors",Z=`${X} bg-white border border-gray-200 text-gray-900 hover:bg-gray-50 active:bg-gray-100`,B=`${X} bg-blue-50 border border-blue-200 text-blue-700 hover:bg-blue-100 active:bg-blue-200`,P=`${X} bg-gray-100 border border-gray-200 text-gray-600 hover:bg-gray-200 active:bg-gray-300`,R=`${X} bg-blue-600 text-white hover:bg-blue-700 active:bg-blue-800`;/* @__PURE__ */
2
+ return s(a,{children:[
3
+ /* @__PURE__ */s("div",{ref:w,className:"flex flex-col h-full",style:{opacity:E.activeOpacity/100,backdropFilter:E.activeBlur>0?`blur(${E.activeBlur}px)`:void 0},children:[
4
+ /* @__PURE__ */s("div",{className:"bg-slate-200 rounded-t-lg px-4 py-2 group/display relative flex flex-col justify-end min-h-[120px] border-b border-slate-300",children:[
5
+ /* @__PURE__ */u("div",{className:"flex flex-col justify-end flex-1 overflow-hidden",children:f.slice(0,3).reverse().map((e,t)=>/* @__PURE__ */u("div",{className:"text-2xs text-slate-400 text-right font-mono truncate",children:e},t))}),(y||b&&null!==p)&&/* @__PURE__ */u("div",{className:"text-base text-slate-600 text-right font-mono",children:y||`${p} ${b} ${j?"":m}`}),
6
+ /* @__PURE__ */s("div",{className:"flex items-center gap-2",children:[
7
+ /* @__PURE__ */u("button",{onClick:()=>{navigator.clipboard.writeText(m),$(!0),setTimeout(()=>$(!1),1200)},title:"Copy result",className:"shrink-0 text-slate-300 hover:text-slate-500 transition-colors opacity-0 group-hover/display:opacity-100",children:/* @__PURE__ */u(r,v?{name:"check",className:"h-5 w-5 text-green-500",strokeWidth:2}:{name:"copy",className:"h-5 w-5",strokeWidth:2})}),
8
+ /* @__PURE__ */u("div",{className:"text-right text-4xl font-mono font-bold text-slate-800 truncate flex-1",children:(e=>{const t=parseFloat(e);return isNaN(t)||e.endsWith(".")||e.endsWith(".0")||Math.abs(t)<1e15&&e.length<16?e:t.toExponential(6)})(m)})]})]}),
9
+ /* @__PURE__ */s("div",{className:"grid grid-cols-4 grid-rows-5 gap-2 flex-1 min-h-0 p-2",children:[
10
+ /* @__PURE__ */u("button",{onClick:L,className:P,children:"AC"}),
11
+ /* @__PURE__ */u("button",{onClick:Q,className:P,children:"+/−"}),
12
+ /* @__PURE__ */u("button",{onClick:M,className:P,children:"%"}),
13
+ /* @__PURE__ */u("button",{onClick:()=>G("÷"),className:`${B} ${"÷"===b?"ring-2 ring-blue-400":""}`,children:"÷"}),
14
+ /* @__PURE__ */u("button",{onClick:()=>F("7"),className:Z,children:"7"}),
15
+ /* @__PURE__ */u("button",{onClick:()=>F("8"),className:Z,children:"8"}),
16
+ /* @__PURE__ */u("button",{onClick:()=>F("9"),className:Z,children:"9"}),
17
+ /* @__PURE__ */u("button",{onClick:()=>G("×"),className:`${B} ${"×"===b?"ring-2 ring-blue-400":""}`,children:"×"}),
18
+ /* @__PURE__ */u("button",{onClick:()=>F("4"),className:Z,children:"4"}),
19
+ /* @__PURE__ */u("button",{onClick:()=>F("5"),className:Z,children:"5"}),
20
+ /* @__PURE__ */u("button",{onClick:()=>F("6"),className:Z,children:"6"}),
21
+ /* @__PURE__ */u("button",{onClick:()=>G("-"),className:`${B} ${"-"===b?"ring-2 ring-blue-400":""}`,children:"−"}),
22
+ /* @__PURE__ */u("button",{onClick:()=>F("1"),className:Z,children:"1"}),
23
+ /* @__PURE__ */u("button",{onClick:()=>F("2"),className:Z,children:"2"}),
24
+ /* @__PURE__ */u("button",{onClick:()=>F("3"),className:Z,children:"3"}),
25
+ /* @__PURE__ */u("button",{onClick:()=>G("+"),className:`${B} ${"+"===b?"ring-2 ring-blue-400":""}`,children:"+"}),
26
+ /* @__PURE__ */u("button",{onClick:()=>F("0"),className:`${Z} col-span-2`,children:"0"}),
27
+ /* @__PURE__ */u("button",{onClick:()=>F("."),className:Z,children:"."}),
28
+ /* @__PURE__ */u("button",{onClick:A,className:R,children:"="})]})]}),
29
+ /* @__PURE__ */u(t,{open:T,onClose:()=>J(!1),title:"Calculator Settings",appearance:D,onAppearanceChange:U,onSave:()=>{W(D),localStorage.setItem(h,JSON.stringify(D)),J(!1)}})]})}export{m as default};
@@ -1,4 +1,4 @@
1
- import{loadAppearance as t,WidgetSettingsModal as e}from"./chunk-EC527NE3.js";import{useWidgetSettings as r}from"./chunk-5VAIVRK6.js";import"./chunk-CY5N5OA3.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-QYL26AB4.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-2E2SUEEE.js";import"./chunk-XQMPLXGG.js";import"./chunk-GLBLKHYA.js";import"./chunk-KC3EX26K.js";import"./chunk-HS2E7DVI.js";import"./chunk-3DVNXNTF.js";import"./chunk-3J2PO3KW.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-UGTRSRIW.js";import"./chunk-CNUHLJYD.js";import"./chunk-CDAJKLGL.js";import"./chunk-3VLG6LR3.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-EQZZ4V5X.js";import"./chunk-HXNMRJQ4.js";import"./chunk-UQYNPYF4.js";import"./chunk-SQCUN2DX.js";import"./chunk-2UO47XB4.js";import"./chunk-J75ZT2JQ.js";import"./chunk-S5SRXI4V.js";import"./chunk-Q3IR5SKD.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-F27JJHNJ.js";import"./chunk-TWVUQUUD.js";import"./chunk-D65T4H6J.js";import{LoadingSpinner as n}from"./chunk-R2VKEMZH.js";import"./chunk-MRJKZWWV.js";import"./chunk-GDQJBQ5B.js";import"./chunk-C3QOHMR6.js";import{useState as s,useCallback as o,useEffect as c}from"react";import{jsxs as a,Fragment as i,jsx as l}from"react/jsx-runtime";var m=["USD","CNY","AUD","GBP","EUR","JPY","CAD","THB","NZD","SGD","HKD","CHF","KRW","INR","MXN","BRL"],u=[["USD","CNY"],["USD","AUD"],["GBP","USD"],["USD","JPY"]],p="currency_pairs",h="currency_appearance",d="currency_rates_cache";function g(t){try{const e=JSON.parse(localStorage.getItem(d)||"{}")[t];if(e&&Date.now()-e.timestamp<36e5)return e.rates}catch{}return null}function k(t,e){try{const r=JSON.parse(localStorage.getItem(d)||"{}");r[t]={rates:e,timestamp:Date.now()},localStorage.setItem(d,JSON.stringify(r))}catch{}}function N(){try{const t=JSON.parse(localStorage.getItem(p)||"");if(Array.isArray(t)&&t.length)return t.slice(0,4)}catch{}return u}var j={USD:"🇺🇸",CNY:"🇨🇳",AUD:"🇦🇺",GBP:"🇬🇧",JPY:"🇯🇵",CAD:"🇨🇦",EUR:"🇪🇺",THB:"🇹🇭",NZD:"🇳🇿",SGD:"🇸🇬",HKD:"🇭🇰",CHF:"🇨🇭",KRW:"🇰🇷",INR:"🇮🇳",MXN:"🇲🇽",BRL:"🇧🇷"};function f(){const[u,d]=s(N),[f,x]=s(()=>t(h)),[y,b]=s({}),[D,S]=s(!1),[v,C]=s(!1),[J,U]=s([]),[R,B]=s(f),[G,H]=s("USD"),[L,A]=s("CNY");r(o(()=>{U([...u]),B({...f}),C(!0)},[u,f])),c(()=>{const t=[...new Set(u.map(([t])=>t))];let e=!0;return async function(){S(!0);const r={};for(const e of t){const t=g(e);if(t)r[e]=t;else try{const t=await fetch(`https://open.er-api.com/v6/latest/${e}`),n=await t.json();n.rates&&(r[e]=n.rates,k(e,n.rates))}catch{}}e&&(b(r),S(!1))}(),()=>{e=!1}},[u]);/* @__PURE__ */
1
+ import{loadAppearance as t,WidgetSettingsModal as e}from"./chunk-DCRLJMQ6.js";import{useWidgetSettings as r}from"./chunk-2YSGXZOL.js";import"./chunk-CY5N5OA3.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-QYL26AB4.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-2E2SUEEE.js";import"./chunk-PLK2WHZG.js";import"./chunk-7INZ7O3A.js";import"./chunk-KC3EX26K.js";import"./chunk-FOFZI62F.js";import"./chunk-3DVNXNTF.js";import"./chunk-ECJKIPWU.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-UGTRSRIW.js";import"./chunk-EPY34L26.js";import"./chunk-CDAJKLGL.js";import"./chunk-4WEFGKJL.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-TXDA7TTP.js";import"./chunk-I4VIEGCX.js";import"./chunk-UQYNPYF4.js";import"./chunk-34URULVW.js";import"./chunk-2UO47XB4.js";import"./chunk-J75ZT2JQ.js";import{LoadingSpinner as n}from"./chunk-R2VKEMZH.js";import"./chunk-MRJKZWWV.js";import"./chunk-MVZRZTQP.js";import"./chunk-6XBWM453.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-F27JJHNJ.js";import"./chunk-TWVUQUUD.js";import"./chunk-GDQJBQ5B.js";import"./chunk-C3QOHMR6.js";import{useState as s,useCallback as o,useEffect as c}from"react";import{jsxs as a,Fragment as i,jsx as l}from"react/jsx-runtime";var m=["USD","CNY","AUD","GBP","EUR","JPY","CAD","THB","NZD","SGD","HKD","CHF","KRW","INR","MXN","BRL"],u=[["USD","CNY"],["USD","AUD"],["GBP","USD"],["USD","JPY"]],p="currency_pairs",h="currency_appearance",d="currency_rates_cache";function g(t){try{const e=JSON.parse(localStorage.getItem(d)||"{}")[t];if(e&&Date.now()-e.timestamp<36e5)return e.rates}catch{}return null}function k(t,e){try{const r=JSON.parse(localStorage.getItem(d)||"{}");r[t]={rates:e,timestamp:Date.now()},localStorage.setItem(d,JSON.stringify(r))}catch{}}function N(){try{const t=JSON.parse(localStorage.getItem(p)||"");if(Array.isArray(t)&&t.length)return t.slice(0,4)}catch{}return u}var j={USD:"🇺🇸",CNY:"🇨🇳",AUD:"🇦🇺",GBP:"🇬🇧",JPY:"🇯🇵",CAD:"🇨🇦",EUR:"🇪🇺",THB:"🇹🇭",NZD:"🇳🇿",SGD:"🇸🇬",HKD:"🇭🇰",CHF:"🇨🇭",KRW:"🇰🇷",INR:"🇮🇳",MXN:"🇲🇽",BRL:"🇧🇷"};function f(){const[u,d]=s(N),[f,x]=s(()=>t(h)),[y,b]=s({}),[D,S]=s(!1),[v,C]=s(!1),[U,J]=s([]),[B,G]=s(f),[L,R]=s("USD"),[A,P]=s("CNY");r(o(()=>{J([...u]),G({...f}),C(!0)},[u,f])),c(()=>{const t=[...new Set(u.map(([t])=>t))];let e=!0;return async function(){S(!0);const r={};for(const e of t){const t=g(e);if(t)r[e]=t;else try{const t=await fetch(`https://open.er-api.com/v6/latest/${e}`),n=await t.json();n.rates&&(r[e]=n.rates,k(e,n.rates))}catch{}}e&&(b(r),S(!1))}(),()=>{e=!1}},[u]);/* @__PURE__ */
2
2
  return a(i,{children:[
3
3
  /* @__PURE__ */l("div",{style:{backgroundColor:`rgb(var(--taskbar-bg-rgb, 243 244 246) / ${f.activeOpacity/100})`,backdropFilter:f.activeBlur>0?`blur(${f.activeBlur}px)`:void 0},children:/* @__PURE__ */a("div",{className:"px-4 py-3 space-y-1",children:[D&&/* @__PURE__ */l(n,{size:"sm",padding:"py-4",label:"Loading rates"}),u.map(([t,e],r)=>{const n=y[t]?.[e];/* @__PURE__ */
4
4
  return a("button",{onClick:()=>{const t=u.map((t,e)=>e===r?[t[1],t[0]]:t);d(t),localStorage.setItem(p,JSON.stringify(t))},className:"flex items-center justify-between px-2 py-2 border-b border-gray-200 last:border-0 w-full hover:bg-gray-100 rounded transition-colors cursor-pointer",children:[
@@ -9,13 +9,13 @@ return a("button",{onClick:()=>{const t=u.map((t,e)=>e===r?[t[1],t[0]]:t);d(t),l
9
9
  /* @__PURE__ */l("span",{className:"text-base",children:j[e]||""}),
10
10
  /* @__PURE__ */l("span",{className:"text-sm font-semibold text-gray-700",children:e})]}),
11
11
  /* @__PURE__ */l("div",{className:"text-base font-mono font-semibold text-gray-900 tabular-nums",children:null!=n?n.toLocaleString(void 0,{minimumFractionDigits:2,maximumFractionDigits:4}):"—"})]},`${t}-${e}-${r}`)})]})}),
12
- /* @__PURE__ */l(e,{open:v,onClose:()=>C(!1),title:"Currency Settings",appearance:R,onAppearanceChange:B,onSave:()=>{if(0===J.length)return;const t=J.slice(0,4);d(t),x(R),localStorage.setItem(p,JSON.stringify(t)),localStorage.setItem(h,JSON.stringify(R)),C(!1)},children:/* @__PURE__ */a("div",{children:[
12
+ /* @__PURE__ */l(e,{open:v,onClose:()=>C(!1),title:"Currency Settings",appearance:B,onAppearanceChange:G,onSave:()=>{if(0===U.length)return;const t=U.slice(0,4);d(t),x(B),localStorage.setItem(p,JSON.stringify(t)),localStorage.setItem(h,JSON.stringify(B)),C(!1)},children:/* @__PURE__ */a("div",{children:[
13
13
  /* @__PURE__ */a("h3",{className:"text-sm font-semibold text-ink mb-2",children:["Currency Pairs ",
14
- /* @__PURE__ */a("span",{className:"text-2xs font-normal text-ink-faintest",children:["(",J.length,"/",4,")"]})]}),
15
- /* @__PURE__ */l("div",{className:"space-y-1 mb-2",children:J.map(([t,e],r)=>/* @__PURE__ */a("div",{className:"flex items-center justify-between py-1 px-2 bg-gray-50 rounded",children:[
14
+ /* @__PURE__ */a("span",{className:"text-2xs font-normal text-ink-faintest",children:["(",U.length,"/",4,")"]})]}),
15
+ /* @__PURE__ */l("div",{className:"space-y-1 mb-2",children:U.map(([t,e],r)=>/* @__PURE__ */a("div",{className:"flex items-center justify-between py-1 px-2 bg-gray-50 rounded",children:[
16
16
  /* @__PURE__ */a("span",{className:"text-sm",children:[j[t]||""," ",t," → ",j[e]||""," ",e]}),
17
- /* @__PURE__ */l("button",{onClick:()=>U(t=>t.filter((t,e)=>e!==r)),className:"text-red-400 hover:text-red-600",children:"×"})]},r))}),J.length<4?/* @__PURE__ */a("div",{className:"flex items-center gap-2",children:[
18
- /* @__PURE__ */l("select",{value:G,onChange:t=>H(t.target.value),className:"bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:m.map(t=>/* @__PURE__ */l("option",{children:t},t))}),
17
+ /* @__PURE__ */l("button",{onClick:()=>J(t=>t.filter((t,e)=>e!==r)),className:"text-red-400 hover:text-red-600",children:"×"})]},r))}),U.length<4?/* @__PURE__ */a("div",{className:"flex items-center gap-2",children:[
18
+ /* @__PURE__ */l("select",{value:L,onChange:t=>R(t.target.value),className:"bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:m.map(t=>/* @__PURE__ */l("option",{children:t},t))}),
19
19
  /* @__PURE__ */l("span",{className:"text-gray-400",children:"→"}),
20
- /* @__PURE__ */l("select",{value:L,onChange:t=>A(t.target.value),className:"bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:m.map(t=>/* @__PURE__ */l("option",{children:t},t))}),
21
- /* @__PURE__ */l("button",{onClick:()=>{G!==L&&J.length<4&&U(t=>[...t,[G,L]])},className:"text-sm font-medium text-blue-600 hover:text-blue-800 px-2",children:"+ Add"})]}):/* @__PURE__ */a("p",{className:"text-2xs text-ink-faintest italic",children:["Max ",4," pairs — remove one to add another."]})]})})]})}export{f as default};
20
+ /* @__PURE__ */l("select",{value:A,onChange:t=>P(t.target.value),className:"bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:m.map(t=>/* @__PURE__ */l("option",{children:t},t))}),
21
+ /* @__PURE__ */l("button",{onClick:()=>{L!==A&&U.length<4&&J(t=>[...t,[L,A]])},className:"text-sm font-medium text-blue-600 hover:text-blue-800 px-2",children:"+ Add"})]}):/* @__PURE__ */a("p",{className:"text-2xs text-ink-faintest italic",children:["Max ",4," pairs — remove one to add another."]})]})})]})}export{f as default};
@@ -1,11 +1,11 @@
1
- import{escapeHtml as e}from"./chunk-G6DKCCWH.js";import{AboutApp as t}from"./chunk-5IPFQV34.js";import{WindowTitle as n}from"./chunk-5VAIVRK6.js";import"./chunk-CY5N5OA3.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-QYL26AB4.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-2E2SUEEE.js";import"./chunk-XQMPLXGG.js";import"./chunk-GLBLKHYA.js";import"./chunk-KC3EX26K.js";import"./chunk-HS2E7DVI.js";import"./chunk-3DVNXNTF.js";import"./chunk-3J2PO3KW.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import{toast_default as r}from"./chunk-7ELJQL7J.js";import"./chunk-UGTRSRIW.js";import"./chunk-CNUHLJYD.js";import"./chunk-CDAJKLGL.js";import"./chunk-RAAH4TQU.js";import{PopupMenu as o,PopupMenuLabel as i,PopupMenuItem as l,PopupMenuDivider as a}from"./chunk-3VLG6LR3.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-EQZZ4V5X.js";import"./chunk-HXNMRJQ4.js";import"./chunk-UQYNPYF4.js";import"./chunk-SQCUN2DX.js";import{Icon as s}from"./chunk-2UO47XB4.js";import"./chunk-J75ZT2JQ.js";import"./chunk-S5SRXI4V.js";import"./chunk-Q3IR5SKD.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-F27JJHNJ.js";import"./chunk-TWVUQUUD.js";import"./chunk-D65T4H6J.js";import{LoadingSpinner as c}from"./chunk-R2VKEMZH.js";import"./chunk-MRJKZWWV.js";import"./chunk-GDQJBQ5B.js";import"./chunk-C3QOHMR6.js";import{useState as m,useRef as h}from"react";import{jsxs as u,jsx as d}from"react/jsx-runtime";var p=/* @__PURE__ */new Set(["txt","md","markdown","csv","tsv","log","json","xml","html","htm","css","js","jsx","ts","tsx","py","rb","go","rs","java","c","h","cpp","hpp","sh","bash","yml","yaml","toml","ini","conf","env","sql"]),g=/* @__PURE__ */new Set(["docx"]),x={filename:"Untitled",kind:"docx",content:"",ext:"docx"};function f(){const[f,y]=m(x),[k,v]=m(!1),[b,j]=m(!1),[w,N]=m(!1),[D,C]=m(null),L=h(null),M=h(null),U=h(null),R=(e,t)=>{U.current?.focus(),document.execCommand(e,!1,t),N(!0)},W=e=>{for(const t of e){if(!t.type.startsWith("image/"))continue;const e=new FileReader;e.onload=()=>{U.current?.focus(),document.execCommand("insertImage",!1,String(e.result)),N(!0)},e.readAsDataURL(t)}},S=e=>{D&&(D.el.removeAttribute("width"),D.el.removeAttribute("height"),D.el.style.width=e??"",D.el.style.height=e?"auto":"",N(!0),C(null))},A=async t=>{const n=(t.name.split(".").pop()||"").toLowerCase();v(!0);try{if(p.has(n)||!g.has(n)&&t.type.startsWith("text/")){const r=await t.text(),o=e(r).replace(/\n/g,"<br>");y({filename:t.name,kind:"text",content:o,ext:n}),N(!1)}else if(g.has(n))try{const e=await(import(
1
+ import{escapeHtml as e}from"./chunk-G6DKCCWH.js";import{AboutApp as t}from"./chunk-GNNY35U6.js";import{WindowTitle as n}from"./chunk-2YSGXZOL.js";import"./chunk-CY5N5OA3.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-QYL26AB4.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-2E2SUEEE.js";import"./chunk-PLK2WHZG.js";import"./chunk-7INZ7O3A.js";import"./chunk-KC3EX26K.js";import"./chunk-FOFZI62F.js";import"./chunk-3DVNXNTF.js";import"./chunk-ECJKIPWU.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import{toast_default as r}from"./chunk-7ELJQL7J.js";import"./chunk-UGTRSRIW.js";import"./chunk-EPY34L26.js";import"./chunk-CDAJKLGL.js";import"./chunk-VNKAIEJ6.js";import{PopupMenu as o,PopupMenuLabel as i,PopupMenuItem as l,PopupMenuDivider as a}from"./chunk-4WEFGKJL.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-TXDA7TTP.js";import"./chunk-I4VIEGCX.js";import"./chunk-UQYNPYF4.js";import"./chunk-34URULVW.js";import{Icon as s}from"./chunk-2UO47XB4.js";import"./chunk-J75ZT2JQ.js";import{LoadingSpinner as c}from"./chunk-R2VKEMZH.js";import"./chunk-MRJKZWWV.js";import"./chunk-MVZRZTQP.js";import"./chunk-6XBWM453.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-F27JJHNJ.js";import"./chunk-TWVUQUUD.js";import"./chunk-GDQJBQ5B.js";import"./chunk-C3QOHMR6.js";import{useState as m,useRef as h}from"react";import{jsxs as u,jsx as d}from"react/jsx-runtime";var p=/* @__PURE__ */new Set(["txt","md","markdown","csv","tsv","log","json","xml","html","htm","css","js","jsx","ts","tsx","py","rb","go","rs","java","c","h","cpp","hpp","sh","bash","yml","yaml","toml","ini","conf","env","sql"]),g=/* @__PURE__ */new Set(["docx"]),x={filename:"Untitled",kind:"docx",content:"",ext:"docx"};function f(){const[f,y]=m(x),[k,v]=m(!1),[b,j]=m(!1),[w,N]=m(!1),[C,D]=m(null),L=h(null),M=h(null),U=h(null),W=(e,t)=>{U.current?.focus(),document.execCommand(e,!1,t),N(!0)},R=e=>{for(const t of e){if(!t.type.startsWith("image/"))continue;const e=new FileReader;e.onload=()=>{U.current?.focus(),document.execCommand("insertImage",!1,String(e.result)),N(!0)},e.readAsDataURL(t)}},T=e=>{C&&(C.el.removeAttribute("width"),C.el.removeAttribute("height"),C.el.style.width=e??"",C.el.style.height=e?"auto":"",N(!0),D(null))},B=async t=>{const n=(t.name.split(".").pop()||"").toLowerCase();v(!0);try{if(p.has(n)||!g.has(n)&&t.type.startsWith("text/")){const r=await t.text(),o=e(r).replace(/\n/g,"<br>");y({filename:t.name,kind:"text",content:o,ext:n}),N(!1)}else if(g.has(n))try{const e=await(import(
2
2
  /* @vite-ignore */
3
- "mammoth")),r=await t.arrayBuffer(),o=await e.convertToHtml({arrayBuffer:r});y({filename:t.name,kind:"docx",content:o.value||"<p><em>(empty document)</em></p>",ext:n}),N(!1)}catch(e){r.error('Install the optional "mammoth" peer dep to read .docx files.')}else"doc"===n?r.error(".doc is the legacy Word binary format — convert to .docx first."):r.error(`Unsupported file type: .${n||"unknown"}`)}finally{v(!1)}},B=f?.filename?(T=f.filename).length>24?`${T.slice(0,23)}…`:T:"Untitled";var T;/* @__PURE__ */
4
- return u("div",{className:"relative flex flex-col h-full",onDragOver:e=>{e.preventDefault(),b||j(!0)},onDragLeave:e=>{e.currentTarget===e.target&&j(!1)},onDrop:e=>{e.preventDefault(),j(!1);const t=Array.from(e.dataTransfer.files??[]);0!==t.length&&(t.every(e=>e.type.startsWith("image/"))?W(t):A(t[0]))},children:[
5
- /* @__PURE__ */d(n,{title:`${B}${w?" •":""} - Documents`}),
3
+ "mammoth")),r=await t.arrayBuffer(),o=await e.convertToHtml({arrayBuffer:r});y({filename:t.name,kind:"docx",content:o.value||"<p><em>(empty document)</em></p>",ext:n}),N(!1)}catch(e){r.error('Install the optional "mammoth" peer dep to read .docx files.')}else"doc"===n?r.error(".doc is the legacy Word binary format — convert to .docx first."):r.error(`Unsupported file type: .${n||"unknown"}`)}finally{v(!1)}},A=f?.filename?(E=f.filename).length>24?`${E.slice(0,23)}…`:E:"Untitled";var E;/* @__PURE__ */
4
+ return u("div",{className:"relative flex flex-col h-full",onDragOver:e=>{e.preventDefault(),b||j(!0)},onDragLeave:e=>{e.currentTarget===e.target&&j(!1)},onDrop:e=>{e.preventDefault(),j(!1);const t=Array.from(e.dataTransfer.files??[]);0!==t.length&&(t.every(e=>e.type.startsWith("image/"))?R(t):B(t[0]))},children:[
5
+ /* @__PURE__ */d(n,{title:`${A}${w?" •":""} - Documents`}),
6
6
  /* @__PURE__ */d(t,{app:"documents"}),
7
7
  /* @__PURE__ */u("div",{className:"flex items-center flex-wrap gap-x-2 gap-y-1 px-3 py-2 border-b border-gray-200 bg-gray-50 shrink-0",children:[
8
- /* @__PURE__ */d("input",{ref:L,type:"file",accept:".txt,.md,.csv,.tsv,.log,.json,.xml,.html,.htm,.css,.js,.jsx,.ts,.tsx,.py,.rb,.go,.rs,.java,.c,.h,.cpp,.hpp,.sh,.bash,.yml,.yaml,.toml,.ini,.conf,.env,.sql,.docx,text/*",onChange:e=>{const t=e.target.files?.[0];t&&A(t),L.current&&(L.current.value="")},className:"hidden"}),
8
+ /* @__PURE__ */d("input",{ref:L,type:"file",accept:".txt,.md,.csv,.tsv,.log,.json,.xml,.html,.htm,.css,.js,.jsx,.ts,.tsx,.py,.rb,.go,.rs,.java,.c,.h,.cpp,.hpp,.sh,.bash,.yml,.yaml,.toml,.ini,.conf,.env,.sql,.docx,text/*",onChange:e=>{const t=e.target.files?.[0];t&&B(t),L.current&&(L.current.value="")},className:"hidden"}),
9
9
  /* @__PURE__ */u("button",{onClick:()=>L.current?.click(),className:"text-xs text-gray-700 hover:text-gray-900 px-2 py-1 rounded hover:bg-gray-200 transition-colors flex items-center gap-1",children:[
10
10
  /* @__PURE__ */d(s,{name:"folder-open",className:"h-3.5 w-3.5",strokeWidth:1.5}),"Open"]}),
11
11
  /* @__PURE__ */d("button",{onClick:()=>{if(!f)return;const t=U.current?.innerHTML??"";if("text"===f.kind){if(/<(b|strong|i|em|u|font|span style|ul|ol|img)|style="[^"]*text-align/i.test(t)){const n=new Blob([`<!doctype html><meta charset="utf-8"><title>${e(f.filename)}</title><body style="font-family:ui-monospace,monospace;white-space:pre-wrap">${t}`],{type:"text/html"}),r=URL.createObjectURL(n),o=document.createElement("a");o.href=r,o.download=`${f.filename.replace(/\.[^.]+$/,"")}.html`,o.click(),URL.revokeObjectURL(r)}else{const e=U.current?.innerText??"",t=new Blob([e],{type:"text/plain"}),n=URL.createObjectURL(t),r=document.createElement("a");r.href=n,r.download=f.filename,r.click(),URL.revokeObjectURL(n)}}else{const n=new Blob([`<!doctype html><meta charset="utf-8"><title>${e(f.filename)}</title>${t}`],{type:"text/html"}),r=URL.createObjectURL(n),o=document.createElement("a");o.href=r,o.download=`${f.filename.replace(/\.docx$/i,"")}.html`,o.click(),URL.revokeObjectURL(r)}},className:"text-xs text-gray-700 hover:text-gray-900 px-2 py-1 rounded hover:bg-gray-200 transition-colors",children:"Save"}),
@@ -14,12 +14,12 @@ return u("div",{className:"relative flex flex-col h-full",onDragOver:e=>{e.preve
14
14
  /* @__PURE__ */u("span",{className:"text-xs font-medium text-gray-700 truncate max-w-[200px]",title:f.filename,children:[f.filename,w?" •":""]}),
15
15
  /* @__PURE__ */d("div",{className:"h-4 w-px bg-gray-300 mx-1"}),
16
16
  /* @__PURE__ */u("div",{className:"flex items-center gap-0.5",children:[
17
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("bold"),className:"px-2 py-1 text-xs rounded font-bold text-gray-700 hover:bg-gray-200 transition-colors",title:"Bold",children:"B"}),
18
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("italic"),className:"px-2 py-1 text-xs rounded italic text-gray-700 hover:bg-gray-200 transition-colors",title:"Italic",children:"I"}),
19
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("underline"),className:"px-2 py-1 text-xs rounded underline text-gray-700 hover:bg-gray-200 transition-colors",title:"Underline",children:"U"}),
20
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("strikeThrough"),className:"px-2 py-1 text-xs rounded line-through text-gray-700 hover:bg-gray-200 transition-colors",title:"Strikethrough",children:"S"})]}),
17
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("bold"),className:"px-2 py-1 text-xs rounded font-bold text-gray-700 hover:bg-gray-200 transition-colors",title:"Bold",children:"B"}),
18
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("italic"),className:"px-2 py-1 text-xs rounded italic text-gray-700 hover:bg-gray-200 transition-colors",title:"Italic",children:"I"}),
19
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("underline"),className:"px-2 py-1 text-xs rounded underline text-gray-700 hover:bg-gray-200 transition-colors",title:"Underline",children:"U"}),
20
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("strikeThrough"),className:"px-2 py-1 text-xs rounded line-through text-gray-700 hover:bg-gray-200 transition-colors",title:"Strikethrough",children:"S"})]}),
21
21
  /* @__PURE__ */d("div",{className:"h-4 w-px bg-gray-300 mx-1"}),
22
- /* @__PURE__ */u("select",{onMouseDown:e=>e.preventDefault(),onChange:e=>{R("fontSize",e.target.value),e.currentTarget.value=""},defaultValue:"",className:"text-xs border border-gray-300 rounded px-1 py-0.5 bg-white",children:[
22
+ /* @__PURE__ */u("select",{onMouseDown:e=>e.preventDefault(),onChange:e=>{W("fontSize",e.target.value),e.currentTarget.value=""},defaultValue:"",className:"text-xs border border-gray-300 rounded px-1 py-0.5 bg-white",children:[
23
23
  /* @__PURE__ */d("option",{value:"",disabled:!0,children:"Size"}),
24
24
  /* @__PURE__ */d("option",{value:"1",children:"XS"}),
25
25
  /* @__PURE__ */d("option",{value:"2",children:"S"}),
@@ -27,26 +27,26 @@ return u("div",{className:"relative flex flex-col h-full",onDragOver:e=>{e.preve
27
27
  /* @__PURE__ */d("option",{value:"4",children:"L"}),
28
28
  /* @__PURE__ */d("option",{value:"5",children:"XL"}),
29
29
  /* @__PURE__ */d("option",{value:"6",children:"2XL"})]}),
30
- /* @__PURE__ */d("input",{type:"color",defaultValue:"#000000",onChange:e=>R("foreColor",e.target.value),className:"w-7 h-6 border border-gray-300 rounded cursor-pointer",title:"Text color"}),
30
+ /* @__PURE__ */d("input",{type:"color",defaultValue:"#000000",onChange:e=>W("foreColor",e.target.value),className:"w-7 h-6 border border-gray-300 rounded cursor-pointer",title:"Text color"}),
31
31
  /* @__PURE__ */d("div",{className:"h-4 w-px bg-gray-300 mx-1"}),
32
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("insertUnorderedList"),className:"px-2 py-1 text-xs rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Bulleted list",children:"• List"}),
33
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("insertOrderedList"),className:"px-2 py-1 text-xs rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Numbered list",children:"1."}),
32
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("insertUnorderedList"),className:"px-2 py-1 text-xs rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Bulleted list",children:"• List"}),
33
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("insertOrderedList"),className:"px-2 py-1 text-xs rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Numbered list",children:"1."}),
34
34
  /* @__PURE__ */d("div",{className:"h-4 w-px bg-gray-300 mx-1"}),
35
35
  /* @__PURE__ */u("div",{className:"flex items-center gap-0.5",children:[
36
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("justifyLeft"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Align left",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M3.75 12h9.75M3.75 18h14.25"})})}),
37
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("justifyCenter"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Align center",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M7.125 12h9.75M4.875 18h14.25"})})}),
38
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("justifyRight"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Align right",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M10.5 12h9.75M6 18h14.25"})})}),
39
- /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>R("justifyFull"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Justify",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M3.75 12h16.5M3.75 18h16.5"})})})]}),
36
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("justifyLeft"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Align left",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M3.75 12h9.75M3.75 18h14.25"})})}),
37
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("justifyCenter"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Align center",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M7.125 12h9.75M4.875 18h14.25"})})}),
38
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("justifyRight"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Align right",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M10.5 12h9.75M6 18h14.25"})})}),
39
+ /* @__PURE__ */d("button",{onMouseDown:e=>e.preventDefault(),onClick:()=>W("justifyFull"),className:"px-2 py-1 rounded text-gray-700 hover:bg-gray-200 transition-colors",title:"Justify",children:/* @__PURE__ */d("svg",{className:"h-3.5 w-3.5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */d("path",{strokeLinecap:"round",d:"M3.75 6h16.5M3.75 12h16.5M3.75 18h16.5"})})})]}),
40
40
  /* @__PURE__ */d("div",{className:"h-4 w-px bg-gray-300 mx-1"}),
41
- /* @__PURE__ */d("input",{ref:M,type:"file",accept:"image/*",multiple:!0,className:"hidden",onChange:e=>{e.target.files?.length&&W(Array.from(e.target.files)),M.current&&(M.current.value="")}}),
41
+ /* @__PURE__ */d("input",{ref:M,type:"file",accept:"image/*",multiple:!0,className:"hidden",onChange:e=>{e.target.files?.length&&R(Array.from(e.target.files)),M.current&&(M.current.value="")}}),
42
42
  /* @__PURE__ */u("button",{onClick:()=>M.current?.click(),className:"px-2 py-1 text-xs rounded text-gray-700 hover:bg-gray-200 transition-colors flex items-center gap-1",title:"Insert image (or paste / drop one)",children:[
43
43
  /* @__PURE__ */d(s,{name:"image",className:"h-3.5 w-3.5",strokeWidth:1.5}),"Image"]})]}),
44
- /* @__PURE__ */d("div",{className:"flex-1 min-h-0 overflow-hidden",children:k?/* @__PURE__ */d(c,{size:"sm",padding:"",className:"h-full",label:"Loading"}):/* @__PURE__ */d("div",{className:"h-full overflow-auto "+("docx"===f.kind?"bg-gray-100 px-6 py-8":"bg-white"),children:/* @__PURE__ */d("div",{ref:U,contentEditable:!0,suppressContentEditableWarning:!0,spellCheck:!1,onInput:()=>N(!0),onPaste:e=>{const t=Array.from(e.clipboardData?.items??[]).filter(e=>"file"===e.kind&&e.type.startsWith("image/")).map(e=>e.getAsFile()).filter(e=>!!e);t.length&&(e.preventDefault(),W(t))},onClick:e=>{const t=e.target;"IMG"===t.tagName&&(e.preventDefault(),C({x:e.clientX,y:e.clientY,el:t}))},dangerouslySetInnerHTML:{__html:f.content},className:"docx"===f.kind?"docs-editor mx-auto w-[8.5in] min-h-[11in] bg-surface p-[1in] shadow text-sm leading-relaxed text-ink-strong outline-none focus:ring-2 focus:ring-blue-400/40":"docs-editor block w-full min-h-full p-4 font-mono text-sm leading-relaxed text-ink-strong bg-surface outline-none whitespace-pre-wrap"})})}),b&&/* @__PURE__ */d("div",{className:"absolute inset-0 bg-blue-500/15 border-4 border-dashed border-blue-500 pointer-events-none flex items-center justify-center z-20",children:/* @__PURE__ */d("div",{className:"px-4 py-2 rounded-md bg-blue-600 text-white text-sm font-medium shadow-lg",children:"Drop a document to open · images insert into the page"})}),D&&/* @__PURE__ */u(o,{minWidth:150,style:{left:D.x,top:D.y},onClose:()=>C(null),children:[
44
+ /* @__PURE__ */d("div",{className:"flex-1 min-h-0 overflow-hidden",children:k?/* @__PURE__ */d(c,{size:"sm",padding:"",className:"h-full",label:"Loading"}):/* @__PURE__ */d("div",{className:"h-full overflow-auto "+("docx"===f.kind?"bg-gray-100 px-6 py-8":"bg-white"),children:/* @__PURE__ */d("div",{ref:U,contentEditable:!0,suppressContentEditableWarning:!0,spellCheck:!1,onInput:()=>N(!0),onPaste:e=>{const t=Array.from(e.clipboardData?.items??[]).filter(e=>"file"===e.kind&&e.type.startsWith("image/")).map(e=>e.getAsFile()).filter(e=>!!e);t.length&&(e.preventDefault(),R(t))},onClick:e=>{const t=e.target;"IMG"===t.tagName&&(e.preventDefault(),D({x:e.clientX,y:e.clientY,el:t}))},dangerouslySetInnerHTML:{__html:f.content},className:"docx"===f.kind?"docs-editor mx-auto w-[8.5in] min-h-[11in] bg-surface p-[1in] shadow text-sm leading-relaxed text-ink-strong outline-none focus:ring-2 focus:ring-blue-400/40":"docs-editor block w-full min-h-full p-4 font-mono text-sm leading-relaxed text-ink-strong bg-surface outline-none whitespace-pre-wrap"})})}),b&&/* @__PURE__ */d("div",{className:"absolute inset-0 bg-blue-500/15 border-4 border-dashed border-blue-500 pointer-events-none flex items-center justify-center z-20",children:/* @__PURE__ */d("div",{className:"px-4 py-2 rounded-md bg-blue-600 text-white text-sm font-medium shadow-lg",children:"Drop a document to open · images insert into the page"})}),C&&/* @__PURE__ */u(o,{minWidth:150,style:{left:C.x,top:C.y},onClose:()=>D(null),children:[
45
45
  /* @__PURE__ */d(i,{children:"Image width"}),
46
- /* @__PURE__ */d(l,{onClick:()=>S("25%"),children:"25%"}),
47
- /* @__PURE__ */d(l,{onClick:()=>S("50%"),children:"50%"}),
48
- /* @__PURE__ */d(l,{onClick:()=>S("75%"),children:"75%"}),
49
- /* @__PURE__ */d(l,{onClick:()=>S("100%"),children:"100%"}),
50
- /* @__PURE__ */d(l,{onClick:()=>S(null),children:"Original size"}),
46
+ /* @__PURE__ */d(l,{onClick:()=>T("25%"),children:"25%"}),
47
+ /* @__PURE__ */d(l,{onClick:()=>T("50%"),children:"50%"}),
48
+ /* @__PURE__ */d(l,{onClick:()=>T("75%"),children:"75%"}),
49
+ /* @__PURE__ */d(l,{onClick:()=>T("100%"),children:"100%"}),
50
+ /* @__PURE__ */d(l,{onClick:()=>T(null),children:"Original size"}),
51
51
  /* @__PURE__ */d(a,{}),
52
- /* @__PURE__ */d(l,{danger:!0,onClick:()=>{D?.el.remove(),N(!0),C(null)},children:"Remove image"})]})]})}export{f as default};
52
+ /* @__PURE__ */d(l,{danger:!0,onClick:()=>{C?.el.remove(),N(!0),D(null)},children:"Remove image"})]})]})}export{f as default};