@sheetxl/studio-vanilla 0.7.28-beta.4 → 0.8.0-beta.10

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 (539) hide show
  1. package/browser/esm/-LoBx7J6imeqaxCq.mjs +236 -0
  2. package/browser/esm/8-jmVNNbOHuXFdVQ.mjs +392 -0
  3. package/{cdn/assets/DJSXXWTUJGbXqLLx.js → browser/esm/B00ixdmb8-O5ijEp.mjs} +1 -1
  4. package/browser/esm/{ByJMrAYRARLc7uZQ2.mjs → B0Wjc3lwtjKMwnvn.mjs} +27 -29
  5. package/browser/esm/B3Ii8x6RquHW1jMc.mjs +299 -0
  6. package/{cdn/assets/BF9yh58xfvR0KbSo.js → browser/esm/B7iV5qzlmJlM2nQv.mjs} +179 -202
  7. package/{cdn/assets/C7xBBqvPqat9oEft2.js → browser/esm/BAH_cWcQEIBKWnl6.mjs} +101 -55
  8. package/browser/esm/BAdRecWK1maKGOZd.mjs +142 -0
  9. package/browser/esm/BBjgqNlHm-ssbSAG.mjs +47 -0
  10. package/browser/esm/BCWTI3jdTPG37r8W.mjs +46 -0
  11. package/{cdn/assets/CJGlwQusOCSy9ZAb.js → browser/esm/BMlPFJ1glExv-70Z.mjs} +5 -5
  12. package/browser/esm/{BrUe0MnOhxzeOngn2.mjs → BN2d5U1nw7pRtOrn.mjs} +1 -1
  13. package/browser/esm/BNIInlJQbJjH8B6G.mjs +84250 -0
  14. package/browser/esm/BPrHgyAsm2Htx15h.mjs +67 -0
  15. package/browser/esm/BRfat1fV3oGLwvin.mjs +76 -0
  16. package/browser/esm/{CXDtDYyREwoFwtMJ2.mjs → BSCja5yvevmKZPBB.mjs} +1 -1
  17. package/browser/esm/BThOwSja2ra4xejQ.mjs +6306 -0
  18. package/browser/esm/BVJUL2HhoedhbwVy.mjs +77 -0
  19. package/{cdn/assets/MHuhAgQAA8zcnWkd2.js → browser/esm/BWo1N4YbK_zGU0nu.mjs} +1 -1
  20. package/browser/esm/B_HB4y7AA88Z775Z.mjs +91 -0
  21. package/browser/esm/BaEZmurTZnX_yfKD.mjs +1082 -0
  22. package/browser/esm/BeMLfv6hWo15VCIL.mjs +239 -0
  23. package/browser/esm/{BjYIAiuzZbD-dk822.mjs → BhkeuRcx8RlLCQ5E.mjs} +1 -1
  24. package/browser/esm/Bi5-feQLtwpV6Ai8.mjs +57 -0
  25. package/browser/esm/BlPn_DXaEXOPxMxC.mjs +540 -0
  26. package/{cdn/assets/DY9zG4TdF0FAs_QP2.js → browser/esm/BsUrrzAgfyAdcCJW.mjs} +28 -13
  27. package/{cdn/assets/CBC_MJL6Bwk7bzQz2.js → browser/esm/BtGmrIqU9W1L8zfZ.mjs} +1 -1
  28. package/browser/esm/BtdRr6IbtO6Gypsk.mjs +27 -0
  29. package/browser/esm/BwOxnbR61WFJwy0A.mjs +607 -0
  30. package/browser/esm/BxhKgo_rPQ2d12HT.mjs +35 -0
  31. package/browser/esm/By3a43qwWICwXRmw.mjs +8035 -0
  32. package/browser/esm/{Cd8G1nX1dKzp-mho2.mjs → ByUcqyCNfqi5Mm7w.mjs} +2 -2
  33. package/{cdn/assets/DP9sLYfGGWMDI7hL2.js → browser/esm/ByqhqEMBLrnkaPKE.mjs} +26 -26
  34. package/browser/esm/{5LJ1sC7IPn109Ien.mjs → C-0viTjg1dT2F-sk.mjs} +2 -2
  35. package/browser/esm/{DnMUizHKSRwWpO_7.mjs → C3r_9RqlWrEmlXZ1.mjs} +37 -3
  36. package/browser/esm/C4VT6lNbpaDXCpBb.mjs +8820 -0
  37. package/browser/esm/{B3tC7wY_kUGXf5sb2.mjs → C5EKgE9Owsc_juw-.mjs} +1 -1
  38. package/{cdn/assets/BzktrYJH7SQ9GyUI2.js → browser/esm/C9NyIoUahFiyRCxP.mjs} +2 -2
  39. package/{cdn/assets/D5BuXc-kVnr6Xiae2.js → browser/esm/CBdNC7BOfc5TewHU.mjs} +1 -1
  40. package/browser/esm/CCd192S7yVpc6iOe.mjs +118 -0
  41. package/browser/esm/{Eszk9OugmYOhaS2s.mjs → CDsuiN--qdALFyql.mjs} +179 -202
  42. package/{cdn/assets/DtkqR-Hu7K4agnCs2.js → browser/esm/CFvKDDbrL3wpXnQH.mjs} +1 -1
  43. package/browser/esm/{DjS4iUli-T3uuUfK.mjs → CHMqT9DzYKTxPfP6.mjs} +2 -2
  44. package/{cdn/assets/BetL7yI63lEdQ0gM2.js → browser/esm/CMxbiQ5J79M3n1tk.mjs} +604 -405
  45. package/{cdn/assets/B4fSPDN923nqCDVE.js → browser/esm/CQOyeq_-pg3CM-uA.mjs} +6 -7
  46. package/browser/esm/CQuv-nk5jtXUfu7C.mjs +7 -0
  47. package/browser/esm/CRAzVh3CaAa16avf.mjs +521 -0
  48. package/browser/esm/{g8dDbkwbYjhKWJM22.mjs → CSEMxasVyGCekxKf.mjs} +6 -7
  49. package/browser/esm/CTI-mCJbJzitJZwj.mjs +25 -0
  50. package/browser/esm/{DrKUGkrCTKZHu8XC.mjs → CTdFZ_I-41Vr6Dy4.mjs} +1 -1
  51. package/browser/esm/CVcCUfSRsiZ1-6hs.mjs +119 -0
  52. package/browser/esm/CVxlfyE-gnJM8hOz.mjs +177 -0
  53. package/browser/esm/CWJzHmEgahdOfNjH.mjs +527 -0
  54. package/browser/esm/CWoPWWRwMgkGPFFP.mjs +7393 -0
  55. package/browser/esm/CZOJogyZqMfUxcXj.mjs +1141 -0
  56. package/{cdn/assets/Dy5Z2XIqS7-0tdjc2.js → browser/esm/CaS8_J5HfBRk5_Nw.mjs} +86 -86
  57. package/browser/esm/CdeXXPCp5cCYvGyD.mjs +14 -0
  58. package/browser/esm/{B9t9fF8FNCLomgK_.mjs → CfltjY8hY-RPwwpd.mjs} +582 -551
  59. package/browser/esm/Chr_TXM-48IsK8Va.mjs +155 -0
  60. package/browser/esm/{Ca6NSkWoi9DvRJjQ.mjs → ClJvUf8aR8vNC_3Z.mjs} +6 -6
  61. package/browser/esm/Clx8vvGDOTWK_M2l.mjs +484 -0
  62. package/browser/esm/CnWNviK4qlX2GVl6.mjs +73 -0
  63. package/browser/esm/{BsP1iPcd49wYIIoP.mjs → Cpza4AeltEVHASij.mjs} +3 -3
  64. package/browser/esm/{Dwko6HB2zePBBeBu2.mjs → CqoHxlGpZ3yzPj5V.mjs} +22 -21
  65. package/browser/esm/{XBb7Mxqf0beXaSJt.mjs → CtZPEkaldpJpoGtW.mjs} +2197 -2011
  66. package/browser/esm/CvWGtHslTdesJik-.mjs +69 -0
  67. package/browser/esm/Cw-4uoMuq_m7ziA3.mjs +36 -0
  68. package/browser/esm/CxCipDFamYSOctBo.mjs +299 -0
  69. package/browser/esm/Cy00y9b9j17Txyv1.mjs +466 -0
  70. package/browser/esm/D-55MlIn7Wo_hdjI.mjs +905 -0
  71. package/browser/esm/D-9f1NKcpuYSgond.mjs +412 -0
  72. package/browser/esm/D-KZpU6HMaP4VUva.mjs +357 -0
  73. package/browser/esm/D0r2MPlWLnStWJNW.mjs +622 -0
  74. package/browser/esm/{CXlA71yGA1Hqvp_S.mjs → D2aQPiGg0ZoMYzuf.mjs} +22 -21
  75. package/{cdn/assets/KJzdwvEWwCwAXuo4.js → browser/esm/D2coM-dNrlLpnUu5.mjs} +1000 -1010
  76. package/browser/esm/D7CGuQcwpkiuesEI.mjs +229 -0
  77. package/browser/esm/{BQt5lpPjssz4Lvhs.mjs → D7DWH3-5fBNx8jtc.mjs} +182 -132
  78. package/browser/esm/D7kkzIFPqKBK94kO.mjs +17952 -0
  79. package/browser/esm/D88StfSjZJi5E8Xb.mjs +5153 -0
  80. package/browser/esm/D8exjrado9TJrBp-.mjs +1946 -0
  81. package/browser/esm/DAE3Kv0Vs0VuBecT.mjs +32 -0
  82. package/browser/esm/DAprxR00V9qvNLL2.mjs +6607 -0
  83. package/browser/esm/DEvZj68igS7Q8SZE.mjs +763 -0
  84. package/browser/esm/DG3BfxRsbjey-B7E.mjs +441 -0
  85. package/browser/esm/DGCOPbZbEmt0x9z0.mjs +155 -0
  86. package/browser/esm/DGcvio2uhlrsE3ZY.mjs +236 -0
  87. package/browser/esm/DGuynZFJ9tqziqQs.mjs +92 -0
  88. package/browser/esm/DJqj66SnUcx0QmSN.mjs +15 -0
  89. package/browser/esm/DLhK_oSGg71ry6-m.mjs +86 -0
  90. package/browser/esm/{B_U_UpQXdbjNRthb.mjs → DLqc11Pf8vaE4Q5B.mjs} +2 -2
  91. package/browser/esm/DNCqTF9EbT-U1TdV.mjs +20 -0
  92. package/browser/esm/{DM4g0nYgYXgI44dL2.mjs → DNaPo7BQu6hr1fWq.mjs} +1 -1
  93. package/{cdn/assets/DRAYZ0SGlbCLkftR.js → browser/esm/DQEjvIGMgEkiaP6J.mjs} +1 -1
  94. package/browser/esm/{Ykh10IaXTKA2XWot.mjs → DQIRFXG4MveFkK3I.mjs} +1 -1
  95. package/{cdn/assets/DJk14sSSnSHiEXZ7.js → browser/esm/DRm1R4uVOkaMfXNI.mjs} +51 -11
  96. package/browser/esm/DSf-Db1h8rlW2A6n.mjs +122 -0
  97. package/browser/esm/DSviq1TNoiIAGW7W.mjs +32 -0
  98. package/{cdn/assets/CuIUyLNDoHvYMJaQ2.js → browser/esm/DTn9oYyiIYgyijAk.mjs} +110 -83
  99. package/browser/esm/{BxecIrskOMQZB-Xc.mjs → DVpi1vC8ixXvUQG_.mjs} +3 -3
  100. package/browser/esm/{esX6dx06TUUL-cRt.mjs → DWgp4t9N9u0eWthH.mjs} +1 -1
  101. package/browser/esm/{DLArQtAbWAarI8od2.mjs → DXo8mR6t5HGsmTcu.mjs} +1 -1
  102. package/browser/esm/DZRmBfjn2TgOTu5e.mjs +3604 -0
  103. package/browser/esm/{BJQfvwvEke-uN0_02.mjs → D_7BWdsu8yejhUxy.mjs} +184 -11
  104. package/browser/esm/D_thhK0vSez8Yfle.mjs +798 -0
  105. package/browser/esm/DaMKWQQTgIF08cT7.mjs +105 -0
  106. package/browser/esm/Db6Tvr45TS9J5Qsb.mjs +259 -0
  107. package/browser/esm/{Bc2Dp6W4U_22cv7c.mjs → Dc2ZwgbIEgYWwAsF.mjs} +1 -1
  108. package/{cdn/assets/BGWyNjrM55ce-D1o.js → browser/esm/DeUXRggj8Oz9ru_i.mjs} +2 -2
  109. package/{cdn/assets/CmYCYFWjq9KP6xw7.js → browser/esm/DfESVLC8CAi8m8A7.mjs} +6 -6
  110. package/browser/esm/{hsy1zALC1oNNm5Sf.mjs → DjdkGy-EI1kSo226.mjs} +7 -5
  111. package/browser/esm/DjtXfgbmXjUAoG0y.mjs +58 -0
  112. package/browser/esm/DlOVZD0OiAjouS6-.mjs +3563 -0
  113. package/browser/esm/Dme0qpRinBnhzp53.mjs +519 -0
  114. package/browser/esm/DnyZmrwPxShyeUjm.mjs +849 -0
  115. package/browser/esm/DoS1sE431fEhdOQb.mjs +216 -0
  116. package/browser/esm/DqBj-9o7UdXu4qhb.mjs +33 -0
  117. package/{cdn/assets/FVJ1akngxeMiYwPa.js → browser/esm/DrI_S0A9TQvriTua.mjs} +1 -1
  118. package/browser/esm/Dv2z0548SZRGTN3l.mjs +149 -0
  119. package/browser/esm/{Bjx-9lUaScF5-Hki2.mjs → Dv8aQFTTaQBJKDDk.mjs} +2 -5
  120. package/browser/esm/DvWCBuY0jAL-RmJV.mjs +3363 -0
  121. package/browser/esm/Dwxz0s23ra1tRtsH.mjs +7 -0
  122. package/{cdn/assets/D4aK0uTRJQpM63922.js → browser/esm/DxcRLd7wmBGDgJsA.mjs} +1 -1
  123. package/{cdn/assets/CIgn8uIPaadIJP4a2.js → browser/esm/DxwprgjYhcmfDbXH.mjs} +24 -24
  124. package/browser/esm/{DENx9Ts-f8adXw3Y2.mjs → Dy44qJVkwNseMG-3.mjs} +1 -1
  125. package/browser/esm/DyeY6XwMQ_XNUHiW.mjs +89 -0
  126. package/browser/esm/{BOMct7uvqiNJIS63.mjs → ErIXJFPDFXwGEL8V.mjs} +2 -2
  127. package/browser/esm/{C4vqrW3EmJDy1otX.mjs → FO1Jezau486fH4kN.mjs} +7 -6
  128. package/browser/esm/FjNOhkR7-JAIaRP6.mjs +19 -0
  129. package/browser/esm/H-JnJQMcZQbpvjdb.mjs +2706 -0
  130. package/browser/esm/J9i3r1fU0H10b2hX.mjs +1001 -0
  131. package/browser/esm/LAbUYeLiPG8z9cmA.mjs +277 -0
  132. package/browser/esm/M7RYrx20B_Yl_euJ.mjs +400 -0
  133. package/browser/esm/{PzCXbVRf1jOHVOAw.mjs → PtGiIWFBYP-ujLmf.mjs} +1 -1
  134. package/browser/esm/RLU85PsAYtKPUf6N.mjs +71 -0
  135. package/browser/esm/{CTwLETvNO4KeXbkK2.mjs → RfHd1JATBlcsfLPv.mjs} +5 -5
  136. package/{cdn/assets/Bce8ZTUCpXr5Y_zl2.js → browser/esm/SNze-adFJwKuGSQW.mjs} +48 -2
  137. package/browser/esm/UTZcodQydbuMfCOS.mjs +171 -0
  138. package/{cdn/assets/BGAXiHOiX_PZ1ww1.js → browser/esm/VwGokBaawZfZiV2X.mjs} +1 -1
  139. package/browser/esm/WMYR09ZOR8JbZEnx.mjs +4748 -0
  140. package/browser/esm/{DOIVDuyf7YyJZjcD.mjs → ZbGPiRN9j0629JJQ.mjs} +2 -2
  141. package/{cdn/assets/BPAEbeXV75XIAS4n.js → browser/esm/ZxsFYopF0_WWqw4Q.mjs} +1 -1
  142. package/browser/esm/_MPToH4oMe4rhTdZ.mjs +63 -0
  143. package/browser/esm/{L6LjzOx1G9Idjtxa2.mjs → _t0Mx-mUFVtmVNkU.mjs} +2 -2
  144. package/{cdn/assets/CgsQuAbp76UOAPHm2.js → browser/esm/_zRV52yhE4gPf3XI.mjs} +211 -189
  145. package/browser/esm/aUREGNA8H7p4BpMK.mjs +33 -0
  146. package/browser/esm/cwuYkcKwsKkPe3gG.mjs +598 -0
  147. package/browser/esm/{CY4ANhbzXqZMJPnL2.mjs → djM9mJznx8GzVq51.mjs} +16 -15
  148. package/browser/esm/{6A8iYjFWJzx5PaTP2.mjs → f1OJemsiZnbwnds-.mjs} +16 -15
  149. package/{cdn/assets/DOsKUeLPwFIdzQv32.js → browser/esm/i0P63Wd0RRlgJotb.mjs} +1 -1
  150. package/browser/esm/{BZSAb1WGbwagUKGv2.mjs → iC69oOND5T8khIWf.mjs} +18 -17
  151. package/browser/esm/index.mjs +644 -48
  152. package/browser/esm/{pFBVGSvmImMMDMuJ.mjs → kVBPUUnVyZfb8pf3.mjs} +52 -52
  153. package/browser/esm/{BZkd8LNLgEd5WQXO2.mjs → lqknEt3DTma5Juxs.mjs} +69 -4
  154. package/browser/esm/mZ92wNrHVpYdli1U.mjs +182 -0
  155. package/browser/esm/{CBuulf8RrSItPZJi.mjs → pKc_RPdZPLAgvNDh.mjs} +2 -2
  156. package/{cdn/assets/D2Ls6urWeByV5W-B.js → browser/esm/pc49xtHdprXZLW2X.mjs} +1 -1
  157. package/browser/esm/px-aQ8dMjiWag_pV.mjs +167 -0
  158. package/browser/esm/qYca4mdySLkACfo1.mjs +37 -0
  159. package/browser/esm/r2Az2Yc4_qj2-sn0.mjs +398 -0
  160. package/browser/esm/{CHmSnCPoww1StSta.mjs → rY-dC3WB558TIbum.mjs} +4 -4
  161. package/browser/esm/rkTVQiYG3wd8oPom.mjs +2452 -0
  162. package/browser/esm/sDVzjXC1mS5rucF5.mjs +2447 -0
  163. package/browser/esm/sxxbiJiCMOW2Eivd.mjs +24952 -0
  164. package/{cdn/assets/BZXvEddjoz4C8y4w.js → browser/esm/vGKTE7yjY8y-XnsW.mjs} +16 -11
  165. package/{cdn/assets/BRBHACVjnV1_6VLQ.js → browser/esm/x6GcENwqoUVbd60j.mjs} +1 -1
  166. package/{cdn/assets/CsKCqLuggHhYC93k.js → browser/esm/ycmpAs4kQfeh78Pa.mjs} +1 -1
  167. package/browser/esm/ztqpWR65YYMZ3EPk.mjs +811 -0
  168. package/cdn/assets/0vqRTRN0wEzWao1c.js +522 -0
  169. package/cdn/assets/514mXPTuNvdNgw35.js +412 -0
  170. package/{browser/esm/B6bX01HNxwBooBTX2.mjs → cdn/assets/7Sg0ht_ZCMJkPurt.js} +89 -87
  171. package/cdn/assets/{CY7qR8ENX314HrrD.js → 7i4WSxDsu2ApJJ2_.js} +6 -6
  172. package/cdn/assets/AjMG7Fb9r4Fk7Hsf.js +78 -0
  173. package/{browser/esm/DJSXXWTUJGbXqLLx.mjs → cdn/assets/B00ixdmb8-O5ijEp.js} +1 -1
  174. package/cdn/assets/{ByJMrAYRARLc7uZQ.js → B0Wjc3lwtjKMwnvn.js} +27 -29
  175. package/cdn/assets/B27vTQlxbHhSQJx8.js +24953 -0
  176. package/cdn/assets/B3NWCYKXucbHhOix.js +93 -0
  177. package/{browser/esm/C7xBBqvPqat9oEft.mjs → cdn/assets/BAH_cWcQEIBKWnl6.js} +101 -55
  178. package/cdn/assets/BAdRecWK1maKGOZd.js +142 -0
  179. package/cdn/assets/BB4MW8sSYEXjPvvf.js +64 -0
  180. package/cdn/assets/BBjgqNlHm-ssbSAG.js +47 -0
  181. package/cdn/assets/BI6afPOpgNYkzIWv.js +6609 -0
  182. package/cdn/assets/{Dgt8kua8CYlMRfdw.js → BIsbcP5RXRU2XPfx.js} +2 -2
  183. package/{browser/esm/CJGlwQusOCSy9ZAb2.mjs → cdn/assets/BMlPFJ1glExv-70Z.js} +5 -5
  184. package/cdn/assets/{BrUe0MnOhxzeOngn.js → BN2d5U1nw7pRtOrn.js} +1 -1
  185. package/cdn/assets/BNsqqoZY7a4N1wWC.js +905 -0
  186. package/cdn/assets/BPrHgyAsm2Htx15h.js +67 -0
  187. package/cdn/assets/{CXDtDYyREwoFwtMJ.js → BSCja5yvevmKZPBB.js} +1 -1
  188. package/{browser/esm/MHuhAgQAA8zcnWkd.mjs → cdn/assets/BWo1N4YbK_zGU0nu.js} +1 -1
  189. package/cdn/assets/B_3Musz0q2MSZ5H-.js +799 -0
  190. package/cdn/assets/Ba8taVvLslFcKS72.js +119 -0
  191. package/cdn/assets/{B0N6rTGGJN2DZPaf.js → BeQ95CzwR65il0CK.js} +2 -2
  192. package/cdn/assets/BelX6bvQPsGuo-x3.js +7 -0
  193. package/cdn/assets/{DGWhm91XZlY1GWHe2.js → Bgbi7BFR3rN5qj51.js} +22 -21
  194. package/cdn/assets/BgyY4zVPZSXljoCZ.js +14 -0
  195. package/cdn/assets/{BjYIAiuzZbD-dk82.js → BhkeuRcx8RlLCQ5E.js} +1 -1
  196. package/cdn/assets/BlIZ30huelIxNo6S.js +91 -0
  197. package/cdn/assets/BlPn_DXaEXOPxMxC.js +540 -0
  198. package/cdn/assets/BoFx07POTorOb5g-.js +7393 -0
  199. package/cdn/assets/{hClmI7sWeaBbHo3W2.js → BpZ7P0CO148rR4zW.js} +24 -23
  200. package/cdn/assets/BsTFy_iJXJYmaO3Z.js +763 -0
  201. package/cdn/assets/{DiKc6jzGM1isrN02.js → Bsn-tUx172sEG2kR.js} +59 -47
  202. package/{browser/esm/CBC_MJL6Bwk7bzQz.mjs → cdn/assets/BtGmrIqU9W1L8zfZ.js} +1 -1
  203. package/cdn/assets/BuYS_ZjSlcvWZ1JC.js +8035 -0
  204. package/cdn/assets/BvlfKrfrDhE9Jw4d.js +598 -0
  205. package/cdn/assets/BwOxnbR61WFJwy0A.js +607 -0
  206. package/cdn/assets/BxqXOiOyI_XiOmvN.js +156 -0
  207. package/cdn/assets/{Cd8G1nX1dKzp-mho.js → ByUcqyCNfqi5Mm7w.js} +2 -2
  208. package/{browser/esm/D8zyGG6yt4CsyA8K.mjs → cdn/assets/BzbP4jaN13wC9aSi.js} +58 -55
  209. package/cdn/assets/{5LJ1sC7IPn109Ien.js → C-0viTjg1dT2F-sk.js} +2 -2
  210. package/cdn/assets/C0CeCYdLWLjySEFe.js +123 -0
  211. package/cdn/assets/{DjfBSoaKM-vtbeqT.js → C32co-XulWTkEKrW.js} +2 -2
  212. package/cdn/assets/{DnMUizHKSRwWpO_72.js → C3r_9RqlWrEmlXZ1.js} +37 -3
  213. package/cdn/assets/{B3tC7wY_kUGXf5sb.js → C5EKgE9Owsc_juw-.js} +1 -1
  214. package/cdn/assets/C6INLvBy8kdzFpsX.js +2447 -0
  215. package/cdn/assets/C7fu6LrSMBlHqwUy.js +46 -0
  216. package/{browser/esm/BzktrYJH7SQ9GyUI.mjs → cdn/assets/C9NyIoUahFiyRCxP.js} +2 -2
  217. package/{browser/esm/D5BuXc-kVnr6Xiae.mjs → cdn/assets/CBdNC7BOfc5TewHU.js} +1 -1
  218. package/cdn/assets/{DJHOKENCVOJMx3aE2.js → CCvBdPu7W2ZF6A9J.js} +9 -9
  219. package/{browser/esm/DmqS0kz7jvlOw3qr.mjs → cdn/assets/CDAYVaQYywqaxg4O.js} +28 -13
  220. package/cdn/assets/CEYyp6Qrr_IopxpL.js +22597 -0
  221. package/cdn/assets/CFBgmXap8kmumhoz.js +622 -0
  222. package/{browser/esm/DtkqR-Hu7K4agnCs.mjs → cdn/assets/CFvKDDbrL3wpXnQH.js} +1 -1
  223. package/{browser/esm/BBhB25AlKEzdoI0V.mjs → cdn/assets/CHMqT9DzYKTxPfP6.js} +2 -2
  224. package/cdn/assets/CILUMtSddGz7WXEv.js +240 -0
  225. package/cdn/assets/{BynqRVXFRplO7XgC.js → CIyaijfp6itgRpFM.js} +95 -87
  226. package/cdn/assets/{DpNYiOK112bFC3KK2.js → CL6Tgu_rUO6G-fyq.js} +183 -10
  227. package/cdn/assets/CMVTwWHsRgyfSEDM.js +300 -0
  228. package/{browser/esm/BetL7yI63lEdQ0gM.mjs → cdn/assets/CMxbiQ5J79M3n1tk.js} +604 -405
  229. package/cdn/assets/COMOqucXq7X1vi0P.js +230 -0
  230. package/{browser/esm/B4fSPDN923nqCDVE2.mjs → cdn/assets/CQOyeq_-pg3CM-uA.js} +6 -7
  231. package/cdn/assets/{DaX0_AkJxkaUnNT7.js → CRXSrbGNABtzf532.js} +141 -126
  232. package/cdn/assets/{g8dDbkwbYjhKWJM2.js → CSEMxasVyGCekxKf.js} +6 -7
  233. package/cdn/assets/CSIZpJClc66_20kP.js +849 -0
  234. package/cdn/assets/CTI-mCJbJzitJZwj.js +25 -0
  235. package/cdn/assets/{DrKUGkrCTKZHu8XC.js → CTdFZ_I-41Vr6Dy4.js} +1 -1
  236. package/cdn/assets/CTvPIYWTcjwlJeEA.js +237 -0
  237. package/cdn/assets/CU5cKipVT1X8Xz7F.js +156 -0
  238. package/cdn/assets/CVcCUfSRsiZ1-6hs.js +119 -0
  239. package/cdn/assets/CWJzHmEgahdOfNjH.js +527 -0
  240. package/cdn/assets/CZOJogyZqMfUxcXj.js +1141 -0
  241. package/{browser/esm/DER7-kADXFnTmK-32.mjs → cdn/assets/CakrxSS_RXtKmcUX.js} +123 -94
  242. package/cdn/assets/{Bj8bWbLg1IY965tK.js → CbTN0q6XnYGJqyEp.js} +2215 -2029
  243. package/cdn/assets/{DQhvG3cP0HPB6giA2.js → Cfg4Dtndwurxv9LM.js} +8 -8
  244. package/{browser/esm/BgwHVPZp494SgQ0d2.mjs → cdn/assets/ChAKLV5zrGAHAof2.js} +44 -42
  245. package/cdn/assets/{BO2NRW9sjHGE9tg-2.js → CsrTRThObSryov1b.js} +182 -132
  246. package/cdn/assets/Cv5PLuhEmh5IDHjb.js +75 -0
  247. package/cdn/assets/Cw-4uoMuq_m7ziA3.js +36 -0
  248. package/cdn/assets/Cw7AJWd0S2sjRmr6.js +6309 -0
  249. package/cdn/assets/CwqRA5h1u92Cyit-.js +7 -0
  250. package/cdn/assets/Cy00y9b9j17Txyv1.js +466 -0
  251. package/cdn/assets/{CnfGgjuCEyX-PYs_2.js → D-bNmX0QsA8SuT0m.js} +33 -32
  252. package/{browser/esm/PAu9erpoOTNzgNbN.mjs → cdn/assets/D-yz3V2UC54rwctD.js} +16 -11
  253. package/cdn/assets/D32D_biNXRCZ24vG.js +87 -0
  254. package/cdn/assets/D8DghdqjOtBzO2Wx.js +35 -0
  255. package/cdn/assets/DAE3Kv0Vs0VuBecT.js +32 -0
  256. package/cdn/assets/DCnWyVXikb_8Dat3.js +61 -0
  257. package/cdn/assets/DHH_uKVzQ_kRYO2N.js +57 -0
  258. package/cdn/assets/DHugYwX4_ZyqGn-C.js +1947 -0
  259. package/cdn/assets/DJqj66SnUcx0QmSN.js +15 -0
  260. package/cdn/assets/{DM4g0nYgYXgI44dL.js → DNaPo7BQu6hr1fWq.js} +1 -1
  261. package/cdn/assets/DOHh3pUXxMM09UY5.js +3604 -0
  262. package/cdn/assets/DONxZZT2Iwu7psS5.js +27 -0
  263. package/{browser/esm/DRAYZ0SGlbCLkftR2.mjs → cdn/assets/DQEjvIGMgEkiaP6J.js} +1 -1
  264. package/cdn/assets/{Ykh10IaXTKA2XWot2.js → DQIRFXG4MveFkK3I.js} +1 -1
  265. package/cdn/assets/DQjxp9lDP9DzP8ah.js +357 -0
  266. package/{browser/esm/DJk14sSSnSHiEXZ72.mjs → cdn/assets/DRm1R4uVOkaMfXNI.js} +51 -11
  267. package/cdn/assets/DSXJHEORGmMQX_Mb.js +8391 -0
  268. package/cdn/assets/DSviq1TNoiIAGW7W.js +32 -0
  269. package/cdn/assets/{BxecIrskOMQZB-Xc.js → DVpi1vC8ixXvUQG_.js} +3 -3
  270. package/cdn/assets/{esX6dx06TUUL-cRt.js → DWgp4t9N9u0eWthH.js} +1 -1
  271. package/cdn/assets/{DLArQtAbWAarI8od.js → DXo8mR6t5HGsmTcu.js} +1 -1
  272. package/cdn/assets/DYvBgX17ZerZSHEJ.js +300 -0
  273. package/cdn/assets/DZRm4H75lnEtOG8e.js +260 -0
  274. package/cdn/assets/D_pMOq6FdH4RSBLc.js +3364 -0
  275. package/cdn/assets/{Bc2Dp6W4U_22cv7c2.js → Dc2ZwgbIEgYWwAsF.js} +1 -1
  276. package/cdn/assets/DckmFyHxGX4Y1gOq.js +70 -0
  277. package/cdn/assets/{D-tQc4bi3FzGVnFg.js → De2z8LdHaWRFiR5T.js} +179 -202
  278. package/{browser/esm/BGWyNjrM55ce-D1o2.mjs → cdn/assets/DeUXRggj8Oz9ru_i.js} +2 -2
  279. package/{browser/esm/CmYCYFWjq9KP6xw72.mjs → cdn/assets/DfESVLC8CAi8m8A7.js} +6 -6
  280. package/cdn/assets/DicTo_3G-KZyWDiE.js +1084 -0
  281. package/cdn/assets/{hsy1zALC1oNNm5Sf.js → DjdkGy-EI1kSo226.js} +7 -5
  282. package/cdn/assets/DjtXfgbmXjUAoG0y.js +58 -0
  283. package/cdn/assets/DlpgIJxNq2V4gdDq.js +74 -0
  284. package/cdn/assets/{Bh4hZt6639QZusIG.js → Dp-GJXOMz_b8qAxD.js} +2 -2
  285. package/cdn/assets/DqBj-9o7UdXu4qhb.js +33 -0
  286. package/{browser/esm/FVJ1akngxeMiYwPa.mjs → cdn/assets/DrI_S0A9TQvriTua.js} +1 -1
  287. package/cdn/assets/DuAbY54w5gJpQgss.js +84250 -0
  288. package/cdn/assets/{Bjx-9lUaScF5-Hki.js → Dv8aQFTTaQBJKDDk.js} +2 -5
  289. package/cdn/assets/DviEoeWW0EvDg1hr.js +149 -0
  290. package/{browser/esm/D4aK0uTRJQpM6392.mjs → cdn/assets/DxcRLd7wmBGDgJsA.js} +1 -1
  291. package/cdn/assets/DxisV9_27l_WU-nk.js +21 -0
  292. package/cdn/assets/{DENx9Ts-f8adXw3Y.js → Dy44qJVkwNseMG-3.js} +1 -1
  293. package/cdn/assets/ENtt4kmaU9mJfVEp.js +236 -0
  294. package/cdn/assets/{C4vqrW3EmJDy1otX.js → FO1Jezau486fH4kN.js} +7 -6
  295. package/cdn/assets/FjNOhkR7-JAIaRP6.js +19 -0
  296. package/{browser/esm/BmTSjuGI87QqMA-a.mjs → cdn/assets/G5z0uVlyF6CLw_PA.js} +179 -202
  297. package/cdn/assets/H-JnJQMcZQbpvjdb.js +2706 -0
  298. package/cdn/assets/J3hutJxqQiHENpIe.js +392 -0
  299. package/cdn/assets/J9i3r1fU0H10b2hX.js +1001 -0
  300. package/cdn/assets/{PzCXbVRf1jOHVOAw.js → PtGiIWFBYP-ujLmf.js} +1 -1
  301. package/cdn/assets/PzWqv-oXxEuzKdaT.js +484 -0
  302. package/cdn/assets/QJ4AkDD269D1MzmI.js +89 -0
  303. package/cdn/assets/{CTwLETvNO4KeXbkK.js → RfHd1JATBlcsfLPv.js} +5 -5
  304. package/{browser/esm/Bce8ZTUCpXr5Y_zl.mjs → cdn/assets/SNze-adFJwKuGSQW.js} +48 -2
  305. package/cdn/assets/UTZcodQydbuMfCOS.js +171 -0
  306. package/{browser/esm/DSWdYe7SDB5cYWo5.mjs → cdn/assets/VCiu_neIjCTg2NUa.js} +998 -1006
  307. package/{browser/esm/BGAXiHOiX_PZ1ww12.mjs → cdn/assets/VwGokBaawZfZiV2X.js} +1 -1
  308. package/cdn/assets/W1d6GQyySAHrtjEu.js +3563 -0
  309. package/cdn/assets/ZSYS1J3uR7UQuHwZ.js +217 -0
  310. package/{browser/esm/BPAEbeXV75XIAS4n2.mjs → cdn/assets/ZxsFYopF0_WWqw4Q.js} +1 -1
  311. package/cdn/assets/{L6LjzOx1G9Idjtxa.js → _t0Mx-mUFVtmVNkU.js} +2 -2
  312. package/cdn/assets/aHTKr1ijZ6bRi3Zg.js +33 -0
  313. package/cdn/assets/anQDUZhHMDPi1eha.js +812 -0
  314. package/cdn/assets/{Dr1U0I01_KIa9vgR2.js → dn69mDhY7Xcc91kF.js} +20 -19
  315. package/cdn/assets/fm3mUdTDo-STB36M.js +4749 -0
  316. package/cdn/assets/gpQ4FdJMbIScKnS_.js +400 -0
  317. package/cdn/assets/{DeFts-aGqB-RDuV1.js → hg8WYI0Yy4WPPPoP.js} +28 -27
  318. package/{browser/esm/DOsKUeLPwFIdzQv32.mjs → cdn/assets/i0P63Wd0RRlgJotb.js} +1 -1
  319. package/cdn/assets/lWY3TbG2NDscy9He.js +72 -0
  320. package/cdn/assets/{BZkd8LNLgEd5WQXO.js → lqknEt3DTma5Juxs.js} +69 -4
  321. package/cdn/assets/mK8HcIZyXkOTvL6E.js +2453 -0
  322. package/{browser/esm/D2Ls6urWeByV5W-B2.mjs → cdn/assets/pc49xtHdprXZLW2X.js} +1 -1
  323. package/cdn/assets/px-aQ8dMjiWag_pV.js +167 -0
  324. package/cdn/assets/qYca4mdySLkACfo1.js +37 -0
  325. package/{browser/esm/DHQcJqD-EtJ0Efug2.mjs → cdn/assets/w5IQWbJETgHhqMsY.js} +33 -31
  326. package/cdn/assets/wM7DzeOpoEGBVDBe.js +441 -0
  327. package/{browser/esm/BRBHACVjnV1_6VLQ2.mjs → cdn/assets/x6GcENwqoUVbd60j.js} +1 -1
  328. package/cdn/assets/xlXDq-qoj7eOE6_T.js +5153 -0
  329. package/{browser/esm/CsKCqLuggHhYC93k2.mjs → cdn/assets/ycmpAs4kQfeh78Pa.js} +1 -1
  330. package/cdn/index.js +2 -2
  331. package/package.json +13 -14
  332. package/browser/cjs/1XrWGMP3GmsQOMIX.cjs +0 -1
  333. package/browser/cjs/49_x589Na12sizKK2.cjs +0 -1
  334. package/browser/cjs/4nReftSsKWmnRdtf2.cjs +0 -1
  335. package/browser/cjs/507hQYooKKjnRzsZ2.cjs +0 -1
  336. package/browser/cjs/B4JJfKSI4ppwU8552.cjs +0 -1
  337. package/browser/cjs/B7_pDFYCVzt-3hUs.cjs +0 -1
  338. package/browser/cjs/BAxVLKkxFgI6cXnR2.cjs +0 -1
  339. package/browser/cjs/BClFnd-voK5qaz1I.cjs +0 -88
  340. package/browser/cjs/BEJFcqVMDMKOvs11.cjs +0 -1
  341. package/browser/cjs/BF-38Z7Z0FZOPl192.cjs +0 -1
  342. package/browser/cjs/BF14ZEAnaqxXroSj.cjs +0 -1
  343. package/browser/cjs/BFdq8CHyR6FQvmQA2.cjs +0 -1
  344. package/browser/cjs/BK0SCfN_VZYqBxoQ2.cjs +0 -1
  345. package/browser/cjs/BKXFdLiztqEHIjQ_2.cjs +0 -1
  346. package/browser/cjs/BVN0uo1XwTCtE2mh.cjs +0 -7
  347. package/browser/cjs/BWDfauDHqB6U_2ka2.cjs +0 -1
  348. package/browser/cjs/B_WV3e3yexp3dKaz.cjs +0 -9
  349. package/browser/cjs/BbEwESVyRYXzMlW7.cjs +0 -5
  350. package/browser/cjs/BjgiE9MBDkKiRL6q.cjs +0 -3
  351. package/browser/cjs/BnccBYHCCq9TGFx4.cjs +0 -8
  352. package/browser/cjs/Btc0Nzu40VYOpzLX2.cjs +0 -1
  353. package/browser/cjs/BvG8N7G_8CXIAlT-.cjs +0 -1
  354. package/browser/cjs/BwLx9ix5Sq7suAYP2.cjs +0 -1
  355. package/browser/cjs/Byl4bQWpLnjthChn2.cjs +0 -7
  356. package/browser/cjs/BzsAbsb35hYT3xUc.cjs +0 -5
  357. package/browser/cjs/C-bW8lKUTFFUVap4.cjs +0 -1
  358. package/browser/cjs/C0hGnOYkvrwxaGrw.cjs +0 -1
  359. package/browser/cjs/C2uDl8VIJqh58YF_2.cjs +0 -1
  360. package/browser/cjs/C7GpcB_YgM-RLa2P.cjs +0 -1
  361. package/browser/cjs/C8GZf3UAOhfisYCs.cjs +0 -1
  362. package/browser/cjs/C9C-pr-T_ThweQX9.cjs +0 -1
  363. package/browser/cjs/C9L-xibuJ434Mqqq2.cjs +0 -1
  364. package/browser/cjs/CEXs4eRDOv4EjbSw2.cjs +0 -1
  365. package/browser/cjs/CEpXnHhrczUmIwMa2.cjs +0 -1
  366. package/browser/cjs/CHFOXPbNUaeZbrXn.cjs +0 -1
  367. package/browser/cjs/CHMgm0vAbEBS1mVW.cjs +0 -1
  368. package/browser/cjs/CJYewYJ5Z3iojl7J.cjs +0 -1
  369. package/browser/cjs/CLXzYSmhCHV5LQh7.cjs +0 -1
  370. package/browser/cjs/CN-dCAHVcxuMSyFz.cjs +0 -1
  371. package/browser/cjs/CPcBvw4ZPwHVTUZF.cjs +0 -1
  372. package/browser/cjs/CRx1WvmgBjT8WVyB2.cjs +0 -1
  373. package/browser/cjs/CV4KQsHluMqo1I2Q2.cjs +0 -1
  374. package/browser/cjs/CW-b31_-r-_raT8Y.cjs +0 -1
  375. package/browser/cjs/CXlzsh_WHCOsErJ12.cjs +0 -1
  376. package/browser/cjs/CZfNBCd62H_Jpkhl.cjs +0 -12
  377. package/browser/cjs/C_7w8EJZpHw8ueuq.cjs +0 -1
  378. package/browser/cjs/C_IEgjM-hSJCv6Gm.cjs +0 -1
  379. package/browser/cjs/CbLXP9WY38wTcGn5.cjs +0 -10
  380. package/browser/cjs/CeF0DZ-k4DB8M47I.cjs +0 -1
  381. package/browser/cjs/Ck7Tc5npWk73wrF3.cjs +0 -57
  382. package/browser/cjs/Clu7XiAsCB48GDXN.cjs +0 -1
  383. package/browser/cjs/CnZfa45XxA-9Jhmp.cjs +0 -1
  384. package/browser/cjs/CnjaTz8HJXStwuH8.cjs +0 -1
  385. package/browser/cjs/CoiPEZabJyiXxLta.cjs +0 -1
  386. package/browser/cjs/CpJJh4UnFl1_qFui.cjs +0 -1
  387. package/browser/cjs/CrZlUtdX1h2RUnCP.cjs +0 -1
  388. package/browser/cjs/Cty5pi0fwToP1GWe.cjs +0 -7
  389. package/browser/cjs/Cu0UCwSpRK4OnCuP.cjs +0 -1
  390. package/browser/cjs/CxWeFfNAUvhHe9F-.cjs +0 -21
  391. package/browser/cjs/D-o-mlG9tYSuZrvy2.cjs +0 -1
  392. package/browser/cjs/D8-KovdJ0LjxqCe2.cjs +0 -1
  393. package/browser/cjs/DAA0zpvkrMOLDPxr.cjs +0 -1
  394. package/browser/cjs/DAXgAEDtRrsWAePT.cjs +0 -1
  395. package/browser/cjs/DCIlWcGDrp-5PDoA2.cjs +0 -1
  396. package/browser/cjs/DDPxHIqx8aIbqTRE.cjs +0 -1
  397. package/browser/cjs/DDnGLOLTqLFsdUDS.cjs +0 -1
  398. package/browser/cjs/DEOu_cHJ1FfTA9R_2.cjs +0 -1
  399. package/browser/cjs/DG-AY_xO8RKHtEBE.cjs +0 -2
  400. package/browser/cjs/DG2kqsWRUtVugjay.cjs +0 -1
  401. package/browser/cjs/DIbdDzNf_3S2RYZN.cjs +0 -1
  402. package/browser/cjs/DLYEQZzAGuSAmJsp.cjs +0 -6
  403. package/browser/cjs/DM7-R_ltoLbA9jde2.cjs +0 -1
  404. package/browser/cjs/DMp9wql2kbZKAbGe.cjs +0 -3
  405. package/browser/cjs/DNCC-QNp2I7saV-I.cjs +0 -1
  406. package/browser/cjs/DNKyaSruDogoBd2H.cjs +0 -1
  407. package/browser/cjs/DQTBgNqDHInvxrwS.cjs +0 -1
  408. package/browser/cjs/DYqvGm5rx1DB53p7.cjs +0 -1
  409. package/browser/cjs/DZSvmqU8nRas1uz62.cjs +0 -1
  410. package/browser/cjs/DcHxh5QxfVitzdhv.cjs +0 -1
  411. package/browser/cjs/DgGGzl7jq3i7Cqfi.cjs +0 -1
  412. package/browser/cjs/Dkgu60euhL6wPoYa2.cjs +0 -1
  413. package/browser/cjs/DsFZgtSQpC75d1M02.cjs +0 -1
  414. package/browser/cjs/DsgqbxMOVQmAFSDy2.cjs +0 -1
  415. package/browser/cjs/DtaFdoK4CppKRF6F2.cjs +0 -20
  416. package/browser/cjs/Dtc_8P-koQRmNT2s.cjs +0 -33
  417. package/browser/cjs/Du4jBiFxRIF1OjD42.cjs +0 -1
  418. package/browser/cjs/Dx79LP1-YCQg8B87.cjs +0 -1
  419. package/browser/cjs/EeOVMRq7TuptFKTc2.cjs +0 -1
  420. package/browser/cjs/FUM_3mQlC-6WPjkT.cjs +0 -4
  421. package/browser/cjs/IbciPMJP2Pam3ERm.cjs +0 -1
  422. package/browser/cjs/J7LQgueGGNUE9emR.cjs +0 -1
  423. package/browser/cjs/JfM6P_qoQQTWakZf2.cjs +0 -1
  424. package/browser/cjs/Kvn916ebqGc4t6hv2.cjs +0 -1
  425. package/browser/cjs/M19oMY91yZxf2WAR.cjs +0 -1
  426. package/browser/cjs/NcNz8RfT5V889CMT.cjs +0 -10
  427. package/browser/cjs/NzAMMcPT7SETmqPg.cjs +0 -2
  428. package/browser/cjs/QK9BfdSZPLmyRpGi2.cjs +0 -1
  429. package/browser/cjs/X1LnR885SNQaK5HZ.cjs +0 -1
  430. package/browser/cjs/Y78-VwYSNffwXRVz2.cjs +0 -2
  431. package/browser/cjs/Ytzw6iUYx5f19wfK.cjs +0 -9
  432. package/browser/cjs/aONv0Ys3C8xmnaR8.cjs +0 -1
  433. package/browser/cjs/bM25C5avKgBAJVfk2.cjs +0 -1
  434. package/browser/cjs/bpcQTcfzGVBK-rfT2.cjs +0 -1
  435. package/browser/cjs/fqTQ_p3ehzUvc1tF2.cjs +0 -1
  436. package/browser/cjs/h3dw1jAp2J5Pu4p32.cjs +0 -1
  437. package/browser/cjs/index.cjs +0 -79
  438. package/browser/cjs/iyvcAhhnDFxkR8tW.cjs +0 -1
  439. package/browser/cjs/jIxFDc3EQDDXisAC2.cjs +0 -1
  440. package/browser/cjs/jev6VGWTdgEgm4Yk2.cjs +0 -1
  441. package/browser/cjs/kqP-W5qRIy-d-ChZ.cjs +0 -1
  442. package/browser/cjs/lEQC21-Sk4lwHy2r2.cjs +0 -1
  443. package/browser/cjs/mXzhcays1ok40iiU.cjs +0 -1
  444. package/browser/cjs/n4ZQ0-3uSrEsInbg.cjs +0 -1
  445. package/browser/cjs/ppSJKdLn646BZOzg.cjs +0 -1
  446. package/browser/cjs/sFD2bsTPq558FCMx.cjs +0 -126
  447. package/browser/cjs/stXrcKZOIHl0fq5U2.cjs +0 -2
  448. package/browser/cjs/xQ6-wbTw5UzZUM1Y.cjs +0 -1
  449. package/browser/cjs/zEytED4Eleo5DVvS.cjs +0 -1
  450. package/browser/cjs/z_rZE1OHFPpdGBh42.cjs +0 -1
  451. package/browser/esm/-9NsA_4pZqcEQBX7.mjs +0 -383
  452. package/browser/esm/B-dSKzg5shPDd733.mjs +0 -25
  453. package/browser/esm/BPwpFe7c1-F62aAU.mjs +0 -518
  454. package/browser/esm/BT2mYkpZGrhWovkv2.mjs +0 -238
  455. package/browser/esm/BUKNpzG26V0YaAzW.mjs +0 -219
  456. package/browser/esm/BaIe3fLfPLw3FbYP2.mjs +0 -1149
  457. package/browser/esm/BgNWvKfVoVgVVDB4.mjs +0 -134
  458. package/browser/esm/Bj3gyDL2ZJUDcxt72.mjs +0 -82
  459. package/browser/esm/BkBT2LB95lonIiBu.mjs +0 -152
  460. package/browser/esm/BqMvXD8dX4ksYjnj.mjs +0 -53
  461. package/browser/esm/Bz3-FDGVU67Izdnv2.mjs +0 -106
  462. package/browser/esm/C3dXBjR3SrDCdJlm.mjs +0 -105
  463. package/browser/esm/CElACTFuqPAnCAMJ.mjs +0 -99
  464. package/browser/esm/CFVzVz9BCRBowBea.mjs +0 -6104
  465. package/browser/esm/CFtsbobCiLpZIzCh.mjs +0 -34
  466. package/browser/esm/CJ-lOo2cXlcYrg2P.mjs +0 -8255
  467. package/browser/esm/CRsnKeHAnKrWvuG52.mjs +0 -6713
  468. package/browser/esm/CbJ_xQftC08KrH3E2.mjs +0 -20
  469. package/browser/esm/CfjG7gHJ4oN60Clj.mjs +0 -4423
  470. package/browser/esm/CpEgh9EOkeMvwAuj.mjs +0 -304
  471. package/browser/esm/CxKAnYBWCYMkUpnr.mjs +0 -824
  472. package/browser/esm/Cye91DfKIFwRdDpF.mjs +0 -224
  473. package/browser/esm/DFQGftDcmDwUGxV8.mjs +0 -27
  474. package/browser/esm/DGfzktq0BrIwcb8j.mjs +0 -7813
  475. package/browser/esm/D_8B8jIlshd3eTIO2.mjs +0 -471
  476. package/browser/esm/DdaO25i-WWFSh1W0.mjs +0 -3188
  477. package/browser/esm/DdtDlBp6KJZjL28o.mjs +0 -4745
  478. package/browser/esm/DhW7Cqyuxk7D6zsW.mjs +0 -509
  479. package/browser/esm/DhgwMDb052opCiAA.mjs +0 -11273
  480. package/browser/esm/DimkHq0_x-d4uNdV.mjs +0 -50758
  481. package/browser/esm/DnCkPg9-xb3RvxD-.mjs +0 -44
  482. package/browser/esm/DuJ_gK9f35IbKDd6.mjs +0 -3651
  483. package/browser/esm/Duo6t8_BzIiBDrFm.mjs +0 -28435
  484. package/browser/esm/DxxlSejA2S6YUPWD.mjs +0 -2211
  485. package/browser/esm/DygUxASTETZM60uN2.mjs +0 -47
  486. package/browser/esm/FAHIw2t7_M_rvRio.mjs +0 -149
  487. package/browser/esm/HFqcMD9nTL0jdLxT.mjs +0 -15
  488. package/browser/esm/N-koparnupMSl92y.mjs +0 -2687
  489. package/browser/esm/O982fBwJ80FSdhad.mjs +0 -615
  490. package/browser/esm/evPbHV86yom22yGf2.mjs +0 -16301
  491. package/browser/esm/ohVj-y1gCC9PEHJI.mjs +0 -87
  492. package/browser/esm/s4trFf5sOSGNEzr3.mjs +0 -235
  493. package/cdn/assets/6L6HfOFw1xzxXtf22.js +0 -2211
  494. package/cdn/assets/B-dSKzg5shPDd733.js +0 -25
  495. package/cdn/assets/B2BvBxjz3Kfii_Gn2.js +0 -6715
  496. package/cdn/assets/B3ZyfwskutLZMYfl2.js +0 -44
  497. package/cdn/assets/B4492m5zRjz4JWIo2.js +0 -4745
  498. package/cdn/assets/B6Y_HasaiihQLVYz2.js +0 -3188
  499. package/cdn/assets/B8ok93z6wOu1Mo5H.js +0 -27
  500. package/cdn/assets/BIPjogMyMmLRly43.js +0 -106
  501. package/cdn/assets/BOTU30yJHbaNehFS.js +0 -176
  502. package/cdn/assets/B_U_UpQXdbjNRthb.js +0 -24
  503. package/cdn/assets/BaIe3fLfPLw3FbYP2.js +0 -1149
  504. package/cdn/assets/BdhFhDEa7Xed6dFE.js +0 -28436
  505. package/cdn/assets/BdmCBWTVHb7KuHxO2.js +0 -2687
  506. package/cdn/assets/Bfd3T36ocASPZddR.js +0 -3651
  507. package/cdn/assets/BjN8kU7URKZwGlmk2.js +0 -4423
  508. package/cdn/assets/BouCHi6QnBrUDYkx.js +0 -16301
  509. package/cdn/assets/CDqMmEdh_CPaFCCi2.js +0 -2199
  510. package/cdn/assets/CLhSKL0Xdm8miSTy.js +0 -34
  511. package/cdn/assets/CSkSOhGT8E29E2Nh2.js +0 -99
  512. package/cdn/assets/CXrcgTVB77CopjOJ.js +0 -518
  513. package/cdn/assets/Cb71rZAQvCk3wnfp.js +0 -220
  514. package/cdn/assets/CbJ_xQftC08KrH3E.js +0 -20
  515. package/cdn/assets/CblzazoiTtSuaAkj.js +0 -225
  516. package/cdn/assets/CdPxVRKpCOqCDHI8.js +0 -824
  517. package/cdn/assets/CimYGZTVXcjbjrBU2.js +0 -83
  518. package/cdn/assets/CpEgh9EOkeMvwAuj.js +0 -304
  519. package/cdn/assets/D57KcDfTbBzf_NGr.js +0 -150
  520. package/cdn/assets/DEFEOS3OuA23llF92.js +0 -472
  521. package/cdn/assets/DEyeWdXLwDRo2yYf2.js +0 -107
  522. package/cdn/assets/DW2yQm-sEcHogX7E.js +0 -8258
  523. package/cdn/assets/Dhq9e6LCpmlIkFod.js +0 -220
  524. package/cdn/assets/DjS4iUli-T3uuUfK.js +0 -24
  525. package/cdn/assets/DjS4iUli-T3uuUfK2.js +0 -24
  526. package/cdn/assets/DlLXCXDokJ72EW-E.js +0 -236
  527. package/cdn/assets/DoJfPxuL3zziG4p62.js +0 -134
  528. package/cdn/assets/Dq7WxMef5CTJ47QI2.js +0 -48
  529. package/cdn/assets/HFqcMD9nTL0jdLxT2.js +0 -15
  530. package/cdn/assets/HeznPoDlSj26Q4lq.js +0 -11274
  531. package/cdn/assets/JL1xk8XqkuTOA_as2.js +0 -239
  532. package/cdn/assets/NZO3-fDBtqhmCsbB2.js +0 -50758
  533. package/cdn/assets/Wb48SedqaKMZnxym.js +0 -7404
  534. package/cdn/assets/Wsgx1I_j1chJ6hwn.js +0 -152
  535. package/cdn/assets/XSUr59k0gaFIS1Qf2.js +0 -53
  536. package/cdn/assets/llvXNxZaCMnYqvSm.js +0 -6104
  537. package/cdn/assets/omgRvCRxe7suvog8.js +0 -510
  538. package/cdn/assets/xMskoOI2CK9-AmBF2.js +0 -44
  539. package/cdn/assets/zrS_ERBQML_OXJ4J.js +0 -87
@@ -0,0 +1,4748 @@
1
+ /**
2
+ * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.8.0-beta.10
3
+ *
4
+ * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
+ * License: The license can be found at https://www.sheetxl.com/license.
6
+ */
7
+ import { r as e } from "./DLqc11Pf8vaE4Q5B.mjs";
8
+ import { i as t, n, r } from "./C4VT6lNbpaDXCpBb.mjs";
9
+ import { M as i, O as a, P as o, T as s, X as c, a as l, b as u, o as d, u as f, w as p } from "./CMxbiQ5J79M3n1tk.mjs";
10
+ import { r as m, t as h } from "./D2aQPiGg0ZoMYzuf.mjs";
11
+ import { Et as g, J as _, K as v, R as y, at as b, ct as x, dt as S, et as C, g as ee, h as w, ht as te, i as T, l as E, m as D, rt as O, tt as k, ut as A, v as j, w as ne, xt as re, y as ie, z as ae } from "./BThOwSja2ra4xejQ.mjs";
12
+ import { t as M } from "./DjdkGy-EI1kSo226.mjs";
13
+ import { t as N } from "./BCWTI3jdTPG37r8W.mjs";
14
+ import { h as oe } from "./DAprxR00V9qvNLL2.mjs";
15
+ import { E as se, N as ce, W as le, bt as P } from "./CWoPWWRwMgkGPFFP.mjs";
16
+ import { $ as F, It as I, zt as L } from "./BNIInlJQbJjH8B6G.mjs";
17
+ import { B as ue, C as de, Ct as fe, D as pe, E as me, F as he, Ft as ge, H as _e, M as ve, Nt as ye, O as be, Ot as xe, W as Se, Y as Ce, _ as we, ct as Te, d as Ee, et as R, h as De, it as Oe, jt as ke, k as z, kt as Ae, lt as je, n as Me, nt as Ne, o as Pe, pt as Fe, q as Ie, ut as Le, vt as Re, w as ze, x as Be, y as Ve } from "./sxxbiJiCMOW2Eivd.mjs";
18
+ import { M as He, S as Ue, _ as We, b as Ge, d as Ke, g as qe, i as Je, n as Ye, s as Xe, t as B, v as V, z as Ze } from "./rkTVQiYG3wd8oPom.mjs";
19
+ import { B as Qe, N as $e, Q as et, _ as tt, _t as nt, a as rt, b as it, gt as at, i as ot, j as H, lt as st, st as U, vt as W, xt as G, yt as K } from "./CtZPEkaldpJpoGtW.mjs";
20
+ import { D as ct, E as lt, T as ut, m as dt, t as ft, y as pt } from "./D2coM-dNrlLpnUu5.mjs";
21
+ import { $t as mt, A as ht, An as gt, Bt as _t, Cn as vt, Et as q, Ft as J, G as yt, Jt as bt, Lt as xt, Mn as Y, Nn as St, Nt as Ct, Ot as wt, P as Tt, Pn as Et, Qt as Dt, Rt as Ot, St as kt, T as At, V as jt, Wt as Mt, Z as Nt, _n as Pt, c as Ft, cn as It, en as Lt, f as Rt, ft as zt, gn as Bt, jn as Vt, jt as Ht, lt as Ut, m as Wt, nn as Gt, nt as Kt, on as qt, p as Jt, pn as Yt, rn as Xt, rt as Zt, tt as Qt, vn as $t, vt as en, wt as tn, xn as nn, yn as rn, yt as an } from "./D7kkzIFPqKBK94kO.mjs";
22
+ import { n as on, t as sn } from "./r2Az2Yc4_qj2-sn0.mjs";
23
+ import { t as cn } from "./-LoBx7J6imeqaxCq.mjs";
24
+ import { D as ln, N as un, S as dn, c as fn, f as pn, g as mn, h as hn, i as gn, l as _n, m as vn, o as yn, s as bn, t as xn, u as Sn, z as Cn } from "./DvWCBuY0jAL-RmJV.mjs";
25
+ import { t as X } from "./CVxlfyE-gnJM8hOz.mjs";
26
+ import { t as wn } from "./kVBPUUnVyZfb8pf3.mjs";
27
+ import { i as Tn, p as En } from "./D8exjrado9TJrBp-.mjs";
28
+ import { n as Dn } from "./D7CGuQcwpkiuesEI.mjs";
29
+ var Z = e(t(), 1), On = Z.createContext(null);
30
+ function kn() {
31
+ return Z.useContext(On);
32
+ }
33
+ var An = typeof Symbol == "function" && Symbol.for ? Symbol.for("mui.nested") : "__THEME_NESTED__", Q = e(r(), 1);
34
+ function jn(e) {
35
+ let { children: t, theme: n } = e, r = kn(), i = Z.useMemo(() => {
36
+ let e = r === null ? { ...n } : function(e, t) {
37
+ return typeof t == "function" ? t(e) : {
38
+ ...e,
39
+ ...t
40
+ };
41
+ }(r, n);
42
+ return e != null && (e[An] = r !== null), e;
43
+ }, [n, r]);
44
+ return (0, Q.jsx)(On.Provider, {
45
+ value: i,
46
+ children: t
47
+ });
48
+ }
49
+ var Mn = {};
50
+ function Nn(e, t, n, r = !1) {
51
+ return Z.useMemo(() => {
52
+ let i = e && t[e] || t;
53
+ if (typeof n == "function") {
54
+ let a = n(i), o = e ? {
55
+ ...t,
56
+ [e]: a
57
+ } : a;
58
+ return r ? () => o : o;
59
+ }
60
+ return e ? {
61
+ ...t,
62
+ [e]: n
63
+ } : {
64
+ ...t,
65
+ ...n
66
+ };
67
+ }, [
68
+ e,
69
+ t,
70
+ n,
71
+ r
72
+ ]);
73
+ }
74
+ function Pn(e) {
75
+ let { children: t, theme: n, themeId: r } = e, i = Ge(Mn), a = kn() || Mn, o = Nn(r, i, n), s = Nn(r, a, n, !0), c = (r ? o[r] : o).direction === "rtl", l = function(e) {
76
+ let t = Ge(), n = nt() || "", { modularCssLayers: r } = e, i = "mui.global, mui.components, mui.theme, mui.custom, mui.sx";
77
+ return i = r && t === null ? typeof r == "string" ? r.replace(/mui(?!\.)/g, i) : `@layer ${i};` : "", G(() => {
78
+ let e = document.querySelector("head");
79
+ if (!e) return;
80
+ let t = e.firstChild;
81
+ if (i) {
82
+ if (t && t.hasAttribute?.("data-mui-layer-order") && t.getAttribute("data-mui-layer-order") === n) return;
83
+ let r = document.createElement("style");
84
+ r.setAttribute("data-mui-layer-order", n), r.textContent = i, e.prepend(r);
85
+ } else e.querySelector(`style[data-mui-layer-order="${n}"]`)?.remove();
86
+ }, [i, n]), i ? (0, Q.jsx)(lt, { styles: i }) : null;
87
+ }(o);
88
+ return (0, Q.jsx)(jn, {
89
+ theme: s,
90
+ children: (0, Q.jsx)(He.Provider, {
91
+ value: o,
92
+ children: (0, Q.jsx)(K, {
93
+ value: c,
94
+ children: (0, Q.jsxs)(W, {
95
+ value: r ? o[r].components : o.components,
96
+ children: [l, t]
97
+ })
98
+ })
99
+ })
100
+ });
101
+ }
102
+ var Fn = "mode", In = "color-scheme", Ln = "data-color-scheme";
103
+ ({ ...Z }).useSyncExternalStore;
104
+ function Rn(e) {
105
+ return JSON.stringify(e).replace(/</g, "\\u003c").replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029");
106
+ }
107
+ function zn(e, t) {
108
+ let n = e.split("%s"), r = [];
109
+ for (let e = 0; e < n.length; e += 1) e > 0 && r.push(t), n[e] && r.push(Rn(n[e]));
110
+ return r.join(" + ") || "\"\"";
111
+ }
112
+ function Bn() {}
113
+ var Vn = ({ key: e, storageWindow: t }) => (t || typeof window > "u" || (t = window), {
114
+ get(n) {
115
+ if (typeof window > "u") return;
116
+ if (!t) return n;
117
+ let r;
118
+ try {
119
+ r = t.localStorage.getItem(e);
120
+ } catch {}
121
+ return r || n;
122
+ },
123
+ set: (n) => {
124
+ if (t) try {
125
+ t.localStorage.setItem(e, n);
126
+ } catch {}
127
+ },
128
+ subscribe: (n) => {
129
+ if (!t) return Bn;
130
+ let r = (t) => {
131
+ let r = t.newValue;
132
+ t.key === e && n(r);
133
+ };
134
+ return t.addEventListener("storage", r), () => {
135
+ t.removeEventListener("storage", r);
136
+ };
137
+ }
138
+ });
139
+ function Hn() {}
140
+ function Un(e) {
141
+ if (typeof window < "u" && typeof window.matchMedia == "function" && e === "system") return window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
142
+ }
143
+ function Wn(e, t) {
144
+ return e.mode === "light" || e.mode === "system" && e.systemMode === "light" ? t("light") : e.mode === "dark" || e.mode === "system" && e.systemMode === "dark" ? t("dark") : void 0;
145
+ }
146
+ function Gn(e) {
147
+ let { defaultMode: t = "light", defaultLightColorScheme: n, defaultDarkColorScheme: r, supportedColorSchemes: i = [], modeStorageKey: a = Fn, colorSchemeStorageKey: o = In, storageWindow: s = typeof window > "u" ? void 0 : window, storageManager: c = Vn, noSsr: l = !1 } = e, u = i.join(","), d = i.length > 1, f = Z.useMemo(() => c?.({
148
+ key: a,
149
+ storageWindow: s
150
+ }), [
151
+ c,
152
+ a,
153
+ s
154
+ ]), p = Z.useMemo(() => c?.({
155
+ key: `${o}-light`,
156
+ storageWindow: s
157
+ }), [
158
+ c,
159
+ o,
160
+ s
161
+ ]), m = Z.useMemo(() => c?.({
162
+ key: `${o}-dark`,
163
+ storageWindow: s
164
+ }), [
165
+ c,
166
+ o,
167
+ s
168
+ ]), [h, g] = Z.useState(() => {
169
+ let e = f?.get(t) || t, i = p?.get(n) || n, a = m?.get(r) || r;
170
+ return {
171
+ mode: e,
172
+ systemMode: Un(e),
173
+ lightColorScheme: i,
174
+ darkColorScheme: a
175
+ };
176
+ }), [_, v] = Z.useState(l || !d);
177
+ Z.useEffect(() => {
178
+ v(!0);
179
+ }, []);
180
+ let y = function(e) {
181
+ return Wn(e, (t) => t === "light" ? e.lightColorScheme : t === "dark" ? e.darkColorScheme : void 0);
182
+ }(h), b = Z.useCallback((e) => {
183
+ g((n) => {
184
+ if (e === n.mode) return n;
185
+ let r = e ?? t;
186
+ return f?.set(r), {
187
+ ...n,
188
+ mode: r,
189
+ systemMode: Un(r)
190
+ };
191
+ });
192
+ }, [f, t]), x = Z.useCallback((e) => {
193
+ e ? typeof e == "string" ? e && !u.includes(e) ? console.error(`\`${e}\` does not exist in \`theme.colorSchemes\`.`) : g((t) => {
194
+ let n = { ...t };
195
+ return Wn(t, (t) => {
196
+ t === "light" && (p?.set(e), n.lightColorScheme = e), t === "dark" && (m?.set(e), n.darkColorScheme = e);
197
+ }), n;
198
+ }) : g((t) => {
199
+ let i = { ...t }, a = e.light === null ? n : e.light, o = e.dark === null ? r : e.dark;
200
+ return a && (u.includes(a) ? (i.lightColorScheme = a, p?.set(a)) : console.error(`\`${a}\` does not exist in \`theme.colorSchemes\`.`)), o && (u.includes(o) ? (i.darkColorScheme = o, m?.set(o)) : console.error(`\`${o}\` does not exist in \`theme.colorSchemes\`.`)), i;
201
+ }) : g((e) => (p?.set(n), m?.set(r), {
202
+ ...e,
203
+ lightColorScheme: n,
204
+ darkColorScheme: r
205
+ }));
206
+ }, [
207
+ u,
208
+ p,
209
+ m,
210
+ n,
211
+ r
212
+ ]), S = Z.useCallback((e) => {
213
+ h.mode === "system" && g((t) => {
214
+ let n = e?.matches ? "dark" : "light";
215
+ return t.systemMode === n ? t : {
216
+ ...t,
217
+ systemMode: n
218
+ };
219
+ });
220
+ }, [h.mode]), C = Z.useRef(S);
221
+ return C.current = S, Z.useEffect(() => {
222
+ if (typeof window.matchMedia != "function" || !d) return;
223
+ let e = (...e) => C.current(...e), t = window.matchMedia("(prefers-color-scheme: dark)");
224
+ return t.addListener(e), e(t), () => {
225
+ t.removeListener(e);
226
+ };
227
+ }, [d]), Z.useEffect(() => {
228
+ if (d) {
229
+ let e = f?.subscribe((e) => {
230
+ e && ![
231
+ "light",
232
+ "dark",
233
+ "system"
234
+ ].includes(e) || b(e || t);
235
+ }) || Hn, n = p?.subscribe((e) => {
236
+ e && !u.match(e) || x({ light: e });
237
+ }) || Hn, r = m?.subscribe((e) => {
238
+ e && !u.match(e) || x({ dark: e });
239
+ }) || Hn;
240
+ return () => {
241
+ e(), n(), r();
242
+ };
243
+ }
244
+ }, [
245
+ x,
246
+ b,
247
+ u,
248
+ t,
249
+ s,
250
+ d,
251
+ f,
252
+ p,
253
+ m
254
+ ]), {
255
+ ...h,
256
+ mode: _ ? h.mode : void 0,
257
+ systemMode: _ ? h.systemMode : void 0,
258
+ colorScheme: _ ? y : void 0,
259
+ setMode: b,
260
+ setColorScheme: x
261
+ };
262
+ }
263
+ function Kn({ theme: e, ...t }) {
264
+ let n = "$$material" in e ? e[Ze] : void 0;
265
+ return (0, Q.jsx)(Pn, {
266
+ ...t,
267
+ themeId: n ? Ze : void 0,
268
+ theme: n || e
269
+ });
270
+ }
271
+ var { CssVarsProvider: qn, useColorScheme: Jn, getInitColorSchemeScript: Yn } = function(e) {
272
+ let { themeId: t, theme: n = {}, modeStorageKey: r = Fn, colorSchemeStorageKey: i = In, disableTransitionOnChange: a = !1, defaultColorScheme: o, resolveTheme: s } = e, c = {
273
+ allColorSchemes: [],
274
+ colorScheme: void 0,
275
+ darkColorScheme: void 0,
276
+ lightColorScheme: void 0,
277
+ mode: void 0,
278
+ setColorScheme: () => {},
279
+ setMode: () => {},
280
+ systemMode: void 0
281
+ }, l = Z.createContext(void 0), u = {}, d = {}, f = typeof o == "string" ? o : o.light, p = typeof o == "string" ? o : o.dark;
282
+ return {
283
+ CssVarsProvider: function(e) {
284
+ let { children: c, theme: f, modeStorageKey: p = r, colorSchemeStorageKey: m = i, disableTransitionOnChange: h = a, storageManager: g, storageWindow: _ = typeof window > "u" ? void 0 : window, documentNode: v = typeof document > "u" ? void 0 : document, colorSchemeNode: y = typeof document > "u" ? void 0 : document.documentElement, disableNestedContext: b = !1, disableStyleSheetGeneration: x = !1, defaultMode: S = "system", forceThemeRerender: C = !1, noSsr: ee } = e, w = Z.useRef(!1), te = kn(), T = Z.useContext(l), E = !!T && !b, D = Z.useMemo(() => f || (typeof n == "function" ? n() : n), [f]), O = D[t], k = O || D, { colorSchemes: A = u, components: j = d, cssVarPrefix: ne } = k, re = Object.keys(A).filter((e) => !!A[e]).join(","), ie = Z.useMemo(() => re.split(","), [re]), ae = typeof o == "string" ? o : o.light, M = typeof o == "string" ? o : o.dark, { mode: N, setMode: oe, systemMode: se, lightColorScheme: ce, darkColorScheme: le, colorScheme: P, setColorScheme: F } = Gn({
285
+ supportedColorSchemes: ie,
286
+ defaultLightColorScheme: ae,
287
+ defaultDarkColorScheme: M,
288
+ modeStorageKey: p,
289
+ colorSchemeStorageKey: m,
290
+ defaultMode: A[ae] && A[M] ? S : A[k.defaultColorScheme]?.palette?.mode || k.palette?.mode,
291
+ storageManager: g,
292
+ storageWindow: _,
293
+ noSsr: ee
294
+ }), I = N, L = P;
295
+ E && (I = T.mode, L = T.colorScheme);
296
+ let ue = L || k.defaultColorScheme;
297
+ k.vars && !C && (ue = k.defaultColorScheme);
298
+ let de = Z.useMemo(() => {
299
+ let e = k.generateThemeVars?.() || k.vars, t = {
300
+ ...k,
301
+ components: j,
302
+ colorSchemes: A,
303
+ cssVarPrefix: ne,
304
+ vars: e
305
+ };
306
+ if (typeof t.generateSpacing == "function" && (t.spacing = t.generateSpacing()), ue) {
307
+ let e = A[ue];
308
+ e && typeof e == "object" && Object.keys(e).forEach((n) => {
309
+ e[n] && typeof e[n] == "object" ? t[n] = {
310
+ ...t[n],
311
+ ...e[n]
312
+ } : t[n] = e[n];
313
+ });
314
+ }
315
+ return s ? s(t) : t;
316
+ }, [
317
+ k,
318
+ ue,
319
+ j,
320
+ A,
321
+ ne
322
+ ]), fe = k.colorSchemeSelector;
323
+ G(() => {
324
+ if (L && y && fe && fe !== "media") {
325
+ let e = fe, t = fe;
326
+ if (e === "class" && (t = ".%s"), e === "data" && (t = "[data-%s]"), e?.startsWith("data-") && !e.includes("%s") && (t = `[${e}="%s"]`), t.startsWith(".")) y.classList.remove(...ie.map((e) => t.substring(1).replace("%s", e))), y.classList.add(t.substring(1).replace("%s", L));
327
+ else {
328
+ let e = t.replace("%s", L).match(/\[([^\]]+)\]/);
329
+ if (e) {
330
+ let [t, n] = e[1].split("=");
331
+ n || ie.forEach((e) => {
332
+ y.removeAttribute(t.replace(L, e));
333
+ }), y.setAttribute(t, n ? n.replace(/"|'/g, "") : "");
334
+ } else y.setAttribute(t, L);
335
+ }
336
+ }
337
+ }, [
338
+ L,
339
+ fe,
340
+ y,
341
+ ie
342
+ ]), Z.useEffect(() => {
343
+ let e;
344
+ if (h && w.current && v) {
345
+ let t = v.createElement("style");
346
+ t.appendChild(v.createTextNode("*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}")), v.head.appendChild(t), window.getComputedStyle(v.body), e = setTimeout(() => {
347
+ v.head.removeChild(t);
348
+ }, 1);
349
+ }
350
+ return () => {
351
+ clearTimeout(e);
352
+ };
353
+ }, [
354
+ L,
355
+ h,
356
+ v
357
+ ]), Z.useEffect(() => (w.current = !0, () => {
358
+ w.current = !1;
359
+ }), []);
360
+ let pe = Z.useMemo(() => ({
361
+ allColorSchemes: ie,
362
+ colorScheme: L,
363
+ darkColorScheme: le,
364
+ lightColorScheme: ce,
365
+ mode: I,
366
+ setColorScheme: F,
367
+ setMode: oe,
368
+ systemMode: se
369
+ }), [
370
+ ie,
371
+ L,
372
+ le,
373
+ ce,
374
+ I,
375
+ F,
376
+ oe,
377
+ se,
378
+ de.colorSchemeSelector
379
+ ]), me = !0;
380
+ (x || !1 === k.cssVariables || E && te?.cssVarPrefix === ne) && (me = !1);
381
+ let he = (0, Q.jsxs)(Z.Fragment, { children: [(0, Q.jsx)(Pn, {
382
+ themeId: O ? t : void 0,
383
+ theme: de,
384
+ children: c
385
+ }), me && (0, Q.jsx)(ct, { styles: de.generateStyleSheets?.() || [] })] });
386
+ return E ? he : (0, Q.jsx)(l.Provider, {
387
+ value: pe,
388
+ children: he
389
+ });
390
+ },
391
+ useColorScheme: () => Z.useContext(l) || c,
392
+ getInitColorSchemeScript: (e) => function(e) {
393
+ let { defaultMode: t = "system", defaultLightColorScheme: n = "light", defaultDarkColorScheme: r = "dark", modeStorageKey: i = Fn, colorSchemeStorageKey: a = In, attribute: o = Ln, colorSchemeNode: s = "document.documentElement", nonce: c } = e || {}, l = "", u = o;
394
+ if (o === "class" && (u = ".%s"), o === "data" && (u = "[data-%s]"), u.startsWith(".")) {
395
+ let e = u.substring(1);
396
+ l += `${s}.classList.remove(${zn(e, "light")}, ${zn(e, "dark")});\n ${s}.classList.add(${zn(e, "colorScheme")});`;
397
+ }
398
+ let d = u.match(/\[([^[\]]+)\]/);
399
+ if (d) {
400
+ let e = d[1].indexOf("="), t = e === -1 ? d[1] : d[1].slice(0, e), n = e === -1 ? void 0 : d[1].slice(e + 1);
401
+ n || (l += `${s}.removeAttribute(${zn(t, "light")});\n ${s}.removeAttribute(${zn(t, "dark")});`);
402
+ let r = n ? zn(n.replace(/^(['"])(.*)\1$/, "$2"), "colorScheme") : "\"\"";
403
+ l += `\n ${s}.setAttribute(${zn(t, "colorScheme")}, ${r});`;
404
+ } else u.startsWith(".") || (l += `${s}.setAttribute(${Rn(u)}, colorScheme);`);
405
+ return (0, Q.jsx)("script", {
406
+ suppressHydrationWarning: !0,
407
+ nonce: typeof window > "u" ? c : "",
408
+ dangerouslySetInnerHTML: { __html: `(function() {\ntry {\n let colorScheme = '';\n const mode = localStorage.getItem(${Rn(i)}) || ${Rn(t)};\n const dark = localStorage.getItem(${Rn(`${a}-dark`)}) || ${Rn(r)};\n const light = localStorage.getItem(${Rn(`${a}-light`)}) || ${Rn(n)};\n if (mode === 'system') {\n // handle system mode\n const mql = window.matchMedia('(prefers-color-scheme: dark)');\n if (mql.matches) {\n colorScheme = dark\n } else {\n colorScheme = light\n }\n }\n if (mode === 'light') {\n colorScheme = light;\n }\n if (mode === 'dark') {\n colorScheme = dark;\n }\n if (colorScheme) {\n ${l}\n }\n} catch(e){}})();` }
409
+ }, "mui-color-scheme-init");
410
+ }({
411
+ colorSchemeStorageKey: i,
412
+ defaultLightColorScheme: f,
413
+ defaultDarkColorScheme: p,
414
+ modeStorageKey: r,
415
+ ...e
416
+ })
417
+ };
418
+ }({
419
+ themeId: Ze,
420
+ theme: () => Je({ cssVariables: !0 }),
421
+ colorSchemeStorageKey: "mui-color-scheme",
422
+ modeStorageKey: "mui-mode",
423
+ defaultColorScheme: {
424
+ light: "light",
425
+ dark: "dark"
426
+ },
427
+ resolveTheme: (e) => {
428
+ let t = {
429
+ ...e,
430
+ typography: Xe(e.palette, e.typography)
431
+ };
432
+ return t.unstable_sx = function(e) {
433
+ return Ue({
434
+ sx: e,
435
+ theme: this
436
+ });
437
+ }, t;
438
+ }
439
+ }), Xn = qn;
440
+ function Zn({ theme: e, ...t }) {
441
+ let n = Z.useMemo(() => {
442
+ if (typeof e == "function") return e;
443
+ let t = "$$material" in e ? e[Ze] : e;
444
+ return "colorSchemes" in t ? null : "vars" in t ? e : {
445
+ ...e,
446
+ vars: null
447
+ };
448
+ }, [e]);
449
+ return n ? (0, Q.jsx)(Kn, {
450
+ theme: n,
451
+ ...t
452
+ }) : (0, Q.jsx)(Xn, {
453
+ theme: e,
454
+ ...t
455
+ });
456
+ }
457
+ function Qn(e) {
458
+ return We("MuiCard", e);
459
+ }
460
+ qe("MuiCard", ["root"]);
461
+ var $n = st(Qe, {
462
+ name: "MuiCard",
463
+ slot: "Root"
464
+ })({ overflow: "hidden" }), er = Z.forwardRef(function(e, t) {
465
+ let n = U({
466
+ props: e,
467
+ name: "MuiCard"
468
+ }), { className: r, raised: i = !1, ...a } = n, o = {
469
+ ...n,
470
+ raised: i
471
+ }, s = ((e) => {
472
+ let { classes: t } = e;
473
+ return at({ root: ["root"] }, Qn, t);
474
+ })(o);
475
+ return (0, Q.jsx)($n, {
476
+ className: V(s.root, r),
477
+ elevation: i ? 8 : void 0,
478
+ ref: t,
479
+ ownerState: o,
480
+ ...a
481
+ });
482
+ });
483
+ function tr(e) {
484
+ return We("MuiCardActions", e);
485
+ }
486
+ qe("MuiCardActions", ["root", "spacing"]);
487
+ var nr = st("div", {
488
+ name: "MuiCardActions",
489
+ slot: "Root",
490
+ overridesResolver: (e, t) => {
491
+ let { ownerState: n } = e;
492
+ return [t.root, !n.disableSpacing && t.spacing];
493
+ }
494
+ })({
495
+ display: "flex",
496
+ alignItems: "center",
497
+ padding: 8,
498
+ variants: [{
499
+ props: { disableSpacing: !1 },
500
+ style: { "& > :not(style) ~ :not(style)": { marginLeft: 8 } }
501
+ }]
502
+ }), rr = Z.forwardRef(function(e, t) {
503
+ let n = U({
504
+ props: e,
505
+ name: "MuiCardActions"
506
+ }), { disableSpacing: r = !1, className: i, ...a } = n, o = {
507
+ ...n,
508
+ disableSpacing: r
509
+ }, s = ((e) => {
510
+ let { classes: t, disableSpacing: n } = e;
511
+ return at({ root: ["root", !n && "spacing"] }, tr, t);
512
+ })(o);
513
+ return (0, Q.jsx)(nr, {
514
+ className: V(s.root, i),
515
+ ownerState: o,
516
+ ref: t,
517
+ ...a
518
+ });
519
+ }), ir = typeof ut({}) == "function", ar = (e, t) => ({
520
+ WebkitFontSmoothing: "antialiased",
521
+ MozOsxFontSmoothing: "grayscale",
522
+ boxSizing: "border-box",
523
+ WebkitTextSizeAdjust: "100%",
524
+ ...t && !e.vars && { colorScheme: e.palette.mode }
525
+ }), or = (e) => ({
526
+ color: (e.vars || e).palette.text.primary,
527
+ ...e.typography.body1,
528
+ backgroundColor: (e.vars || e).palette.background.default,
529
+ "@media print": { backgroundColor: (e.vars || e).palette.common.white }
530
+ }), sr = (e, t = !1) => {
531
+ let n = {};
532
+ t && e.colorSchemes && typeof e.getColorSchemeSelector == "function" && Object.entries(e.colorSchemes).forEach(([t, r]) => {
533
+ let i = e.getColorSchemeSelector(t);
534
+ i.startsWith("@") ? n[i] = { ":root": { colorScheme: r.palette?.mode } } : n[i.replace(/\s*&/, "")] = { colorScheme: r.palette?.mode };
535
+ });
536
+ let r = {
537
+ html: ar(e, t),
538
+ "*, *::before, *::after": { boxSizing: "inherit" },
539
+ "strong, b": { fontWeight: e.typography.fontWeightBold },
540
+ body: {
541
+ margin: 0,
542
+ ...or(e),
543
+ "&::backdrop": { backgroundColor: (e.vars || e).palette.background.default }
544
+ },
545
+ ...n
546
+ }, i = e.components?.MuiCssBaseline?.styleOverrides;
547
+ return i && (r = [r, i]), r;
548
+ }, cr = "mui-ecs", lr = ut(ir ? ({ theme: e, enableColorScheme: t }) => sr(e, t) : ({ theme: e }) => ((e) => {
549
+ let t = sr(e, !1), n = Array.isArray(t) ? t[0] : t;
550
+ return !e.vars && n && (n.html[`:root:has(${cr})`] = { colorScheme: e.palette.mode }), e.colorSchemes && Object.entries(e.colorSchemes).forEach(([t, r]) => {
551
+ let i = e.getColorSchemeSelector(t);
552
+ i.startsWith("@") ? n[i] = { [`:root:not(:has(.${cr}))`]: { colorScheme: r.palette?.mode } } : n[i.replace(/\s*&/, "")] = { [`&:not(:has(.${cr}))`]: { colorScheme: r.palette?.mode } };
553
+ }), t;
554
+ })(e));
555
+ function ur(e) {
556
+ let { children: t, enableColorScheme: n = !1 } = U({
557
+ props: e,
558
+ name: "MuiCssBaseline"
559
+ });
560
+ return (0, Q.jsxs)(Z.Fragment, { children: [
561
+ ir && (0, Q.jsx)(lr, { enableColorScheme: n }),
562
+ !ir && !n && (0, Q.jsx)("span", {
563
+ className: cr,
564
+ style: { display: "none" }
565
+ }),
566
+ t
567
+ ] });
568
+ }
569
+ var dr = e(n(), 1), fr = (0, Z.memo)((e) => {
570
+ let { variant: t = "format", children: n, sx: r, ...i } = e;
571
+ return (0, Q.jsx)(B, {
572
+ className: `sxl-cf-rule-section sxl-cf-rule-section-${t}`,
573
+ sx: {
574
+ display: "flex",
575
+ flexDirection: "column",
576
+ gap: 1,
577
+ p: 2,
578
+ border: 1,
579
+ borderColor: "divider",
580
+ borderRadius: 1,
581
+ ...t === "config" ? { backgroundColor: "action.hover" } : null,
582
+ ...r
583
+ },
584
+ ...i,
585
+ children: n
586
+ });
587
+ });
588
+ fr.displayName = "RuleSection";
589
+ var pr = new ce("transparent"), mr = {
590
+ lightRedFillDarkRedText: u("conditionalFormat.preset.lightRedFillDarkRedText"),
591
+ yellowFillDarkYellowText: u("conditionalFormat.preset.yellowFillDarkYellowText"),
592
+ greenFillDarkGreenText: u("conditionalFormat.preset.greenFillDarkGreenText"),
593
+ lightRedFill: u("conditionalFormat.preset.lightRedFill"),
594
+ redText: u("conditionalFormat.preset.redText"),
595
+ redBorder: u("conditionalFormat.preset.redBorder")
596
+ }, hr = (e) => e ? typeof e == "string" ? e : e.type === se.Type.None ? null : e.color ?? e.foreground ?? null : null, gr = (e, t) => e === "auto" ? null : rn(e, t), _r = (0, Z.memo)((e) => {
597
+ let { format: t, onFormatChange: n, readOnly: r, ...i } = e, a = k(), { workbook: o, schemeLookup: s, themeKey: c, darkMode: l, propsColorPanel: d } = Xt(), f = t?.font ?? null, p = (f?.weight ?? 400) >= 600, h = f?.style === P.Style.Italic, g = !!f?.underline && f.underline !== P.UnderlineStyle.None, _ = !!f?.strike, v = (e) => {
598
+ let r = { ...f };
599
+ for (let [t, n] of Object.entries(e)) n === void 0 ? delete r[t] : r[t] = n;
600
+ let i = { ...t };
601
+ Object.keys(r).length === 0 ? delete i.font : i.font = r, n(Object.keys(i).length === 0 ? null : i);
602
+ }, y = (0, Z.useMemo)(() => o?.getStyles().getNormal().getFont().getColor(), [o, c]), b = (0, Z.useMemo)(() => gr(f?.color, o), [
603
+ f?.color,
604
+ o,
605
+ c
606
+ ]), x = (0, Z.useMemo)(() => gr(hr(t?.fill), o), [
607
+ t?.fill,
608
+ o,
609
+ c
610
+ ]), S = {
611
+ padding: "4px",
612
+ border: "none",
613
+ borderRadius: 1
614
+ };
615
+ return (0, Q.jsxs)(fr, {
616
+ ...i,
617
+ children: [(0, Q.jsxs)(B, {
618
+ sx: {
619
+ display: "flex",
620
+ alignItems: "flex-start",
621
+ gap: 1
622
+ },
623
+ children: [(0, Q.jsx)(B, {
624
+ sx: {
625
+ flex: "1 1 auto",
626
+ minWidth: 0,
627
+ display: "flex",
628
+ gap: .5,
629
+ flexWrap: "wrap"
630
+ },
631
+ children: Be.map((e, t) => {
632
+ let i = gr(hr(e.style.fill), o), s = gr(e.style.font?.color, o), c = e.style.borders ? gr(Object.values(e.style.borders)[0]?.color, o) : null;
633
+ return (0, Q.jsx)(J, {
634
+ sheet: !0,
635
+ title: a(mr[e.key] ?? e.key),
636
+ disabled: r,
637
+ onClick: () => n(structuredClone(e.style)),
638
+ sx: {
639
+ backgroundColor: i?.toCSS("adaptive") ?? void 0,
640
+ color: s?.toCSS("adaptive") ?? void 0,
641
+ outline: c ? `1px solid ${c.toCSS("adaptive")}` : void 0,
642
+ outlineOffset: "-3px"
643
+ },
644
+ children: "Aa"
645
+ }, t);
646
+ })
647
+ }), (0, Q.jsx)(J, {
648
+ title: a("conditionalFormat.clearStyle"),
649
+ disabled: r || !t,
650
+ onClick: () => n(null),
651
+ sx: {
652
+ color: "text.secondary",
653
+ "&:disabled": { opacity: .4 }
654
+ },
655
+ children: (0, Q.jsx)(m, {
656
+ iconKey: "ClearFormats",
657
+ size: 16
658
+ })
659
+ })]
660
+ }), (0, Q.jsxs)(B, {
661
+ sx: {
662
+ display: "flex",
663
+ alignItems: "center",
664
+ gap: .25
665
+ },
666
+ children: [
667
+ (0, Q.jsx)(Y, {
668
+ value: "bold",
669
+ size: "small",
670
+ sx: S,
671
+ selected: p,
672
+ disabled: r,
673
+ onChange: () => v({ weight: p ? void 0 : 700 }),
674
+ children: (0, Q.jsx)(m, { iconKey: "TextBold" })
675
+ }),
676
+ (0, Q.jsx)(Y, {
677
+ value: "italic",
678
+ size: "small",
679
+ sx: S,
680
+ selected: h,
681
+ disabled: r,
682
+ onChange: () => v({ style: h ? void 0 : P.Style.Italic }),
683
+ children: (0, Q.jsx)(m, { iconKey: "TextItalic" })
684
+ }),
685
+ (0, Q.jsx)(Y, {
686
+ value: "underline",
687
+ size: "small",
688
+ sx: S,
689
+ selected: g,
690
+ disabled: r,
691
+ onChange: () => v({ underline: g ? void 0 : P.UnderlineStyle.Single }),
692
+ children: (0, Q.jsx)(m, { iconKey: "TextUnderline" })
693
+ }),
694
+ (0, Q.jsx)(Y, {
695
+ value: "strike",
696
+ size: "small",
697
+ sx: S,
698
+ selected: _,
699
+ disabled: r,
700
+ onChange: () => v({ strike: !_ || void 0 }),
701
+ children: (0, Q.jsx)(m, { iconKey: "TextStrike" })
702
+ }),
703
+ o && (0, Q.jsx)(Mt, {
704
+ tooltip: a("conditionalFormat.border"),
705
+ selectedBorder: t?.borders,
706
+ createBorder: (e) => o.getStyles().getNormal().createStyle({ borders: e }).getBorders(),
707
+ schemeLookup: s,
708
+ autoColor: y,
709
+ darkMode: l,
710
+ disabled: r,
711
+ onSelectBorder: (e) => ((e) => {
712
+ let r = { ...t };
713
+ e && Object.keys(e).length !== 0 ? r.borders = e : delete r.borders, n(Object.keys(r).length === 0 ? null : r);
714
+ })(e)
715
+ }),
716
+ (0, Q.jsx)(En, {
717
+ icon: "fill.colored",
718
+ tooltip: a("conditionalFormat.fillColor"),
719
+ selectedColor: x,
720
+ disabled: r,
721
+ onSelectColor: (e) => ((e) => {
722
+ let r = { ...t };
723
+ e ? r.fill = {
724
+ type: se.Type.Solid,
725
+ color: e.toString()
726
+ } : delete r.fill, n(Object.keys(r).length === 0 ? null : r);
727
+ })(e),
728
+ darkMode: l,
729
+ propsPanel: {
730
+ disableAlpha: !0,
731
+ autoColor: pr,
732
+ autoColorLabelKey: u("color.noFill"),
733
+ autoColorPosition: Tn.End,
734
+ ...d
735
+ }
736
+ }),
737
+ (0, Q.jsx)(En, {
738
+ icon: "text.colored",
739
+ tooltip: a("conditionalFormat.fontColor"),
740
+ selectedColor: b,
741
+ disabled: r,
742
+ onSelectColor: (e) => v({ color: e ? e.toString() : void 0 }),
743
+ darkMode: l,
744
+ propsPanel: {
745
+ disableAlpha: !0,
746
+ autoColor: y,
747
+ ...d
748
+ }
749
+ })
750
+ ]
751
+ })]
752
+ });
753
+ });
754
+ _r.displayName = "ConditionalFormatStylePicker";
755
+ var vr = {
756
+ [L.ColorStopType.AutoMin]: u("conditionalFormat.stopType.autoMin"),
757
+ [L.ColorStopType.AutoMax]: u("conditionalFormat.stopType.autoMax"),
758
+ [L.ColorStopType.Min]: u("conditionalFormat.stopType.min"),
759
+ [L.ColorStopType.Max]: u("conditionalFormat.stopType.max"),
760
+ [L.ColorStopType.Num]: u("conditionalFormat.stopType.num"),
761
+ [L.ColorStopType.Percent]: u("conditionalFormat.stopType.percent"),
762
+ [L.ColorStopType.Percentile]: u("conditionalFormat.stopType.percentile"),
763
+ [L.ColorStopType.Formula]: u("conditionalFormat.stopType.formula")
764
+ }, yr = /* @__PURE__ */ new Set([
765
+ L.ColorStopType.AutoMin,
766
+ L.ColorStopType.AutoMax,
767
+ L.ColorStopType.Min,
768
+ L.ColorStopType.Max
769
+ ]), br = (0, Z.memo)((e) => {
770
+ let { label: t, stop: n, onStopChange: r, allowedTypes: i, showColor: a = !1, leading: o, showExclusive: s = !1, readOnly: c, ...l } = e, u = k(), { darkMode: d, toColor: f, propsColorPanel: p } = Xt(), m = kt(), h = n.type ?? L.ColorStopType.Num, g = !yr.has(h), _ = c || !g, v = h === L.ColorStopType.Formula, y = n.value?.isIFormula ? n.value : null, b = n.color, x = a ? f(b) : null;
771
+ return (0, Q.jsxs)(B, {
772
+ sx: {
773
+ display: "flex",
774
+ alignItems: "center",
775
+ gap: .5
776
+ },
777
+ ...l,
778
+ children: [
779
+ t !== void 0 && (0, Q.jsx)(H, {
780
+ variant: "caption",
781
+ sx: {
782
+ color: "text.secondary",
783
+ flex: "0 0 62px",
784
+ minWidth: 0,
785
+ overflow: "hidden",
786
+ textOverflow: "ellipsis"
787
+ },
788
+ children: t
789
+ }),
790
+ o,
791
+ a && (0, Q.jsx)(En, {
792
+ tooltip: u("conditionalFormat.stopColor"),
793
+ selectedColor: x,
794
+ disabled: c,
795
+ onSelectColor: (e) => {
796
+ e && r({
797
+ ...n,
798
+ color: e.toString()
799
+ });
800
+ },
801
+ darkMode: d,
802
+ propsPanel: {
803
+ disableAlpha: !0,
804
+ ...p
805
+ }
806
+ }),
807
+ s && (0, Q.jsxs)(ft, {
808
+ size: "small",
809
+ value: n.exclusive ? "gt" : "gte",
810
+ disabled: c,
811
+ onChange: (e) => {
812
+ let t = { ...n };
813
+ e.target.value === "gt" ? t.exclusive = !0 : delete t.exclusive, r(t);
814
+ },
815
+ sx: {
816
+ flex: "0 0 auto",
817
+ backgroundColor: "background.paper"
818
+ },
819
+ children: [(0, Q.jsx)(X, {
820
+ value: "gte",
821
+ children: ">="
822
+ }), (0, Q.jsx)(X, {
823
+ value: "gt",
824
+ children: ">"
825
+ })]
826
+ }),
827
+ (0, Q.jsx)(ft, {
828
+ size: "small",
829
+ value: h,
830
+ disabled: c,
831
+ onChange: (e) => ((e) => {
832
+ let t = {
833
+ ...n,
834
+ type: e
835
+ };
836
+ if (yr.has(e)) delete t.value;
837
+ else if (t.value === void 0) t.value = e === L.ColorStopType.Formula ? "" : 0;
838
+ else if (e !== L.ColorStopType.Formula && typeof t.value != "number") {
839
+ let e = typeof t.value == "string" ? Number(t.value) : NaN;
840
+ t.value = Number.isFinite(e) ? e : 0;
841
+ }
842
+ r(t);
843
+ })(e.target.value),
844
+ sx: {
845
+ flex: "1 1 40%",
846
+ minWidth: 0,
847
+ backgroundColor: "background.paper"
848
+ },
849
+ children: i.map((e) => (0, Q.jsx)(X, {
850
+ value: e,
851
+ children: u(vr[e])
852
+ }, e))
853
+ }),
854
+ v ? (0, Q.jsx)(Dn, {
855
+ size: "small",
856
+ home: m.home,
857
+ value: y ? m.display(y) : `${n.value ?? ""}`,
858
+ onChangeText: (e) => {
859
+ r({
860
+ ...n,
861
+ value: e.trim().length > 0 ? m.compile(e) : e
862
+ });
863
+ },
864
+ placeholder: u("conditionalFormat.enterFormula"),
865
+ disabled: _,
866
+ equals: "bare",
867
+ pickAs: "absolute",
868
+ label: null,
869
+ showError: !1,
870
+ helperText: null,
871
+ sx: {
872
+ flex: "1 1 30%",
873
+ minWidth: 0,
874
+ "& .MuiInputBase-root": { backgroundColor: _ ? "action.disabledBackground" : "background.paper" }
875
+ }
876
+ }) : (0, Q.jsx)(cn, {
877
+ size: "small",
878
+ type: "number",
879
+ placeholder: g ? void 0 : u("conditionalFormat.stopFromData"),
880
+ value: g ? `${n.value ?? ""}` : "",
881
+ disabled: _,
882
+ onChange: (e) => {
883
+ let t = e.target.value;
884
+ r({
885
+ ...n,
886
+ value: t === "" ? 0 : Number(t)
887
+ });
888
+ },
889
+ sx: {
890
+ flex: "1 1 30%",
891
+ minWidth: 0,
892
+ cursor: _ ? "not-allowed" : void 0
893
+ },
894
+ slotProps: { input: { sx: {
895
+ backgroundColor: _ ? "action.disabledBackground" : "background.paper",
896
+ cursor: _ ? "not-allowed" : void 0
897
+ } } }
898
+ })
899
+ ]
900
+ });
901
+ });
902
+ br.displayName = "ScaleStopRow";
903
+ var xr = [
904
+ L.ColorStopType.Min,
905
+ L.ColorStopType.Max,
906
+ L.ColorStopType.Num,
907
+ L.ColorStopType.Percent,
908
+ L.ColorStopType.Percentile,
909
+ L.ColorStopType.Formula
910
+ ], Sr = (0, Z.memo)((e) => {
911
+ let { scale: t, onScaleChange: n, readOnly: r, ...i } = e, a = k(), { workbook: o, toColor: s } = Xt(), c = t.stops ?? [], l = c.length === 2 ? [u("conditionalFormat.stop.minimum"), u("conditionalFormat.stop.maximum")] : [
912
+ u("conditionalFormat.stop.minimum"),
913
+ u("conditionalFormat.stop.midpoint"),
914
+ u("conditionalFormat.stop.maximum")
915
+ ];
916
+ return (0, Q.jsxs)(B, {
917
+ sx: {
918
+ display: "flex",
919
+ flexDirection: "column",
920
+ gap: 1
921
+ },
922
+ ...i,
923
+ children: [(0, Q.jsx)(fr, { children: (0, Q.jsxs)(B, {
924
+ sx: {
925
+ display: "flex",
926
+ alignItems: "flex-start",
927
+ gap: 1
928
+ },
929
+ children: [(0, Q.jsx)(B, {
930
+ sx: {
931
+ flex: "1 1 auto",
932
+ minWidth: 0,
933
+ display: "flex",
934
+ gap: .5,
935
+ flexWrap: "wrap"
936
+ },
937
+ children: Ee.filter((e) => e.stops.length === (c.length === 2 ? 2 : 3)).map((e, t) => (0, Q.jsx)(J, {
938
+ sheet: !0,
939
+ disabled: r,
940
+ onClick: () => n(structuredClone(e)),
941
+ children: (0, Q.jsx)(_t, { rows: Ht(e.stops ?? [], Yt, o) })
942
+ }, t))
943
+ }), (0, Q.jsxs)(Vt, {
944
+ exclusive: !0,
945
+ size: "small",
946
+ value: c.length === 2 ? 2 : 3,
947
+ disabled: r,
948
+ onChange: (e, r) => {
949
+ r && ((e) => {
950
+ if (e === c.length || e !== 2 && e !== 3) return;
951
+ let r = c.slice();
952
+ if (e === 3) {
953
+ let e = "#FFEB84", t = s(c[0]?.color ?? e)?.toRGBA(), n = s(c[c.length - 1]?.color ?? e)?.toRGBA();
954
+ if (t && n) {
955
+ let r = (e) => Math.round(e).toString(16).padStart(2, "0").toUpperCase();
956
+ e = `#${r((t.red + n.red) / 2)}${r((t.green + n.green) / 2)}${r((t.blue + n.blue) / 2)}`;
957
+ }
958
+ r.splice(1, 0, {
959
+ type: L.ColorStopType.Percentile,
960
+ value: 50,
961
+ color: e
962
+ });
963
+ } else r.splice(1, r.length - 2);
964
+ n({
965
+ ...t,
966
+ stops: r
967
+ });
968
+ })(r);
969
+ },
970
+ sx: { flex: "0 0 auto" },
971
+ children: [(0, Q.jsx)(Y, {
972
+ value: 2,
973
+ sx: {
974
+ textTransform: "none",
975
+ pt: .25,
976
+ pb: .25
977
+ },
978
+ children: a("conditionalFormat.twoColor")
979
+ }), (0, Q.jsx)(Y, {
980
+ value: 3,
981
+ sx: {
982
+ textTransform: "none",
983
+ pt: .25,
984
+ pb: .25
985
+ },
986
+ children: a("conditionalFormat.threeColor")
987
+ })]
988
+ })]
989
+ }) }), (0, Q.jsx)(fr, {
990
+ variant: "config",
991
+ children: c.map((e, i) => (0, Q.jsx)(br, {
992
+ label: a(l[Math.min(i, l.length - 1)]),
993
+ stop: e,
994
+ allowedTypes: xr,
995
+ showColor: !0,
996
+ readOnly: r,
997
+ onStopChange: (e) => {
998
+ let r = c.slice();
999
+ r[i] = e, n({
1000
+ ...t,
1001
+ stops: r
1002
+ });
1003
+ }
1004
+ }, i))
1005
+ })]
1006
+ });
1007
+ });
1008
+ Sr.displayName = "ColorScaleRulePanel";
1009
+ var Cr = [
1010
+ L.ColorStopType.AutoMin,
1011
+ L.ColorStopType.Min,
1012
+ L.ColorStopType.Num,
1013
+ L.ColorStopType.Percent,
1014
+ L.ColorStopType.Percentile,
1015
+ L.ColorStopType.Formula
1016
+ ], wr = [
1017
+ L.ColorStopType.AutoMax,
1018
+ L.ColorStopType.Max,
1019
+ L.ColorStopType.Num,
1020
+ L.ColorStopType.Percent,
1021
+ L.ColorStopType.Percentile,
1022
+ L.ColorStopType.Formula
1023
+ ], Tr = "__auto__", Er = (0, Z.memo)((e) => {
1024
+ let { scale: t, onScaleChange: n, readOnly: r, ...i } = e, a = k(), { darkMode: o, toColor: s, propsColorPanel: c } = Xt(), l = t.stops ?? [], u = s(t.color), d = s(t.negativeFillColor), f = s(t.borderColor), p = s(t.negativeBorderColor), h = t.gradient ?? !1, g = (e) => {
1025
+ let r = { ...t };
1026
+ for (let [t, n] of Object.entries(e)) n === void 0 ? delete r[t] : r[t] = n;
1027
+ n(r);
1028
+ }, _ = { backgroundColor: "background.paper" };
1029
+ return (0, Q.jsxs)(B, {
1030
+ sx: {
1031
+ display: "flex",
1032
+ flexDirection: "column",
1033
+ gap: 1
1034
+ },
1035
+ ...i,
1036
+ children: [(0, Q.jsxs)(fr, { children: [
1037
+ (0, Q.jsxs)(B, {
1038
+ sx: {
1039
+ display: "flex",
1040
+ alignItems: "flex-start",
1041
+ gap: 1
1042
+ },
1043
+ children: [(0, Q.jsx)(B, {
1044
+ sx: {
1045
+ flex: "1 1 auto",
1046
+ minWidth: 0,
1047
+ display: "flex",
1048
+ gap: .5,
1049
+ flexWrap: "wrap"
1050
+ },
1051
+ children: z.filter((e) => (e.gradient ?? !1) === h).map((e, t) => (0, Q.jsx)(J, {
1052
+ sheet: !0,
1053
+ disabled: r,
1054
+ onClick: () => g({
1055
+ color: e.color,
1056
+ gradient: e.gradient,
1057
+ borderColor: e.borderColor
1058
+ }),
1059
+ children: (0, Q.jsx)(_t, { rows: Lt(e, s(e.color)?.toCSS("adaptive") ?? "var(--sxl-color-primary, rgb(33, 115, 70))") })
1060
+ }, t))
1061
+ }), (0, Q.jsxs)(Vt, {
1062
+ exclusive: !0,
1063
+ size: "small",
1064
+ value: h,
1065
+ disabled: r,
1066
+ onChange: (e, t) => {
1067
+ t !== null && g({ gradient: !!t || void 0 });
1068
+ },
1069
+ sx: { flex: "0 0 auto" },
1070
+ children: [(0, Q.jsx)(Y, {
1071
+ value: !1,
1072
+ sx: {
1073
+ textTransform: "none",
1074
+ pt: .25,
1075
+ pb: .25
1076
+ },
1077
+ children: a("conditionalFormat.solidFill")
1078
+ }), (0, Q.jsx)(Y, {
1079
+ value: !0,
1080
+ sx: {
1081
+ textTransform: "none",
1082
+ pt: .25,
1083
+ pb: .25
1084
+ },
1085
+ children: a("conditionalFormat.gradientFill")
1086
+ })]
1087
+ })]
1088
+ }),
1089
+ (0, Q.jsx)(sn, {
1090
+ control: (0, Q.jsx)(on, {
1091
+ size: "small",
1092
+ checked: !1 === t.showValue,
1093
+ disabled: r,
1094
+ onChange: (e) => g({ showValue: !e.target.checked && void 0 })
1095
+ }),
1096
+ label: (0, Q.jsx)(H, {
1097
+ variant: "body2",
1098
+ children: a("conditionalFormat.showBarsOnly")
1099
+ })
1100
+ }),
1101
+ (0, Q.jsxs)(B, {
1102
+ sx: {
1103
+ display: "flex",
1104
+ alignItems: "center",
1105
+ gap: .5
1106
+ },
1107
+ children: [
1108
+ (0, Q.jsx)(H, {
1109
+ variant: "caption",
1110
+ sx: {
1111
+ color: "text.secondary",
1112
+ flex: "0 0 62px"
1113
+ },
1114
+ children: a("conditionalFormat.bar")
1115
+ }),
1116
+ (0, Q.jsx)(En, {
1117
+ icon: "fill.colored",
1118
+ tooltip: a("conditionalFormat.barColor"),
1119
+ selectedColor: u,
1120
+ disabled: r,
1121
+ onSelectColor: (e) => g({ color: e ? e.toString() : void 0 }),
1122
+ darkMode: o,
1123
+ propsPanel: {
1124
+ disableAlpha: !0,
1125
+ ...c
1126
+ }
1127
+ }),
1128
+ (0, Q.jsx)(En, {
1129
+ icon: "stroke.colored",
1130
+ tooltip: a("conditionalFormat.barBorderColor"),
1131
+ selectedColor: f,
1132
+ disabled: r,
1133
+ onSelectColor: (e) => g({ borderColor: e ? e.toString() : void 0 }),
1134
+ darkMode: o,
1135
+ propsPanel: {
1136
+ disableAlpha: !0,
1137
+ ...c
1138
+ }
1139
+ })
1140
+ ]
1141
+ }),
1142
+ (0, Q.jsxs)(B, {
1143
+ sx: {
1144
+ display: "flex",
1145
+ alignItems: "center",
1146
+ gap: .5
1147
+ },
1148
+ children: [
1149
+ (0, Q.jsx)(H, {
1150
+ variant: "caption",
1151
+ sx: {
1152
+ color: "text.secondary",
1153
+ flex: "0 0 62px"
1154
+ },
1155
+ children: a("conditionalFormat.negative")
1156
+ }),
1157
+ (0, Q.jsx)(En, {
1158
+ icon: "fill.colored",
1159
+ tooltip: a("conditionalFormat.negativeColor"),
1160
+ selectedColor: d ?? u,
1161
+ disabled: r,
1162
+ onSelectColor: (e) => g({ negativeFillColor: e ? e.toString() : void 0 }),
1163
+ darkMode: o,
1164
+ propsPanel: {
1165
+ disableAlpha: !0,
1166
+ ...c
1167
+ }
1168
+ }),
1169
+ (0, Q.jsx)(En, {
1170
+ icon: "stroke.colored",
1171
+ tooltip: a("conditionalFormat.negativeBorderColor"),
1172
+ selectedColor: p ?? f,
1173
+ disabled: r,
1174
+ onSelectColor: (e) => g({ negativeBorderColor: e ? e.toString() : void 0 }),
1175
+ darkMode: o,
1176
+ propsPanel: {
1177
+ disableAlpha: !0,
1178
+ ...c
1179
+ }
1180
+ }),
1181
+ (0, Q.jsx)(J, {
1182
+ title: a("conditionalFormat.sameAsPositive"),
1183
+ disabled: r || !t.negativeFillColor && !t.negativeBorderColor,
1184
+ onClick: () => g({
1185
+ negativeFillColor: void 0,
1186
+ negativeBorderColor: void 0
1187
+ }),
1188
+ sx: {
1189
+ color: "text.secondary",
1190
+ "&:disabled": { opacity: .4 }
1191
+ },
1192
+ children: (0, Q.jsx)(m, {
1193
+ iconKey: "ClearFormats",
1194
+ size: 16
1195
+ })
1196
+ })
1197
+ ]
1198
+ }),
1199
+ (0, Q.jsxs)(B, {
1200
+ sx: {
1201
+ display: "flex",
1202
+ gap: 1,
1203
+ mt: .5
1204
+ },
1205
+ children: [(0, Q.jsxs)(pt, {
1206
+ size: "small",
1207
+ sx: {
1208
+ flex: 1,
1209
+ minWidth: 0
1210
+ },
1211
+ children: [(0, Q.jsx)(dt, { children: a("conditionalFormat.axis") }), (0, Q.jsxs)(ft, {
1212
+ label: a("conditionalFormat.axis"),
1213
+ value: t.axisPosition ?? Tr,
1214
+ disabled: r,
1215
+ sx: _,
1216
+ onChange: (e) => {
1217
+ let t = e.target.value;
1218
+ g({ axisPosition: t === Tr ? void 0 : t });
1219
+ },
1220
+ children: [
1221
+ (0, Q.jsx)(X, {
1222
+ value: Tr,
1223
+ children: a("conditionalFormat.automatic")
1224
+ }),
1225
+ (0, Q.jsx)(X, {
1226
+ value: "middle",
1227
+ children: a("conditionalFormat.axisMiddle")
1228
+ }),
1229
+ (0, Q.jsx)(X, {
1230
+ value: "none",
1231
+ children: a("conditionalFormat.axisNone")
1232
+ })
1233
+ ]
1234
+ })]
1235
+ }), (0, Q.jsxs)(pt, {
1236
+ size: "small",
1237
+ sx: {
1238
+ flex: 1,
1239
+ minWidth: 0
1240
+ },
1241
+ children: [(0, Q.jsx)(dt, { children: a("conditionalFormat.direction") }), (0, Q.jsxs)(ft, {
1242
+ label: a("conditionalFormat.direction"),
1243
+ value: t.direction ?? Tr,
1244
+ disabled: r,
1245
+ sx: _,
1246
+ onChange: (e) => {
1247
+ let t = e.target.value;
1248
+ g({ direction: t === Tr ? void 0 : t });
1249
+ },
1250
+ children: [
1251
+ (0, Q.jsx)(X, {
1252
+ value: Tr,
1253
+ children: a("conditionalFormat.automatic")
1254
+ }),
1255
+ (0, Q.jsx)(X, {
1256
+ value: "leftToRight",
1257
+ children: a("conditionalFormat.leftToRight")
1258
+ }),
1259
+ (0, Q.jsx)(X, {
1260
+ value: "rightToLeft",
1261
+ children: a("conditionalFormat.rightToLeft")
1262
+ })
1263
+ ]
1264
+ })]
1265
+ })]
1266
+ })
1267
+ ] }), (0, Q.jsxs)(fr, {
1268
+ variant: "config",
1269
+ children: [(0, Q.jsx)(br, {
1270
+ label: a("conditionalFormat.stop.minimum"),
1271
+ stop: l[0] ?? { type: L.ColorStopType.AutoMin },
1272
+ allowedTypes: Cr,
1273
+ readOnly: r,
1274
+ onStopChange: (e) => {
1275
+ let t = l.slice();
1276
+ t[0] = e, g({ stops: t });
1277
+ }
1278
+ }), (0, Q.jsx)(br, {
1279
+ label: a("conditionalFormat.stop.maximum"),
1280
+ stop: l[1] ?? { type: L.ColorStopType.AutoMax },
1281
+ allowedTypes: wr,
1282
+ readOnly: r,
1283
+ onStopChange: (e) => {
1284
+ let t = l.slice();
1285
+ for (; t.length < 2;) t.push({ type: L.ColorStopType.AutoMax });
1286
+ t[1] = e, g({ stops: t });
1287
+ }
1288
+ })]
1289
+ })]
1290
+ });
1291
+ });
1292
+ Er.displayName = "DataBarRulePanel";
1293
+ var Dr = u("conditionalFormat.noCellIcon"), Or = u("conditionalFormat.cellIcon"), kr = {
1294
+ borderColor: "primary.main",
1295
+ boxShadow: (e) => `inset 0 0 0 1px ${e.palette.primary.main}`
1296
+ }, Ar = {
1297
+ width: "28px",
1298
+ height: "26px"
1299
+ }, jr = (0, Z.memo)((e) => {
1300
+ let { icon: t, onPick: n } = e, r = k();
1301
+ return (0, Q.jsxs)(B, {
1302
+ sx: {
1303
+ display: "flex",
1304
+ flexDirection: "column",
1305
+ gap: "4px",
1306
+ padding: "6px 8px"
1307
+ },
1308
+ children: [(0, Q.jsx)(J, {
1309
+ sheet: !0,
1310
+ title: r(Dr),
1311
+ "aria-pressed": t === null,
1312
+ sx: {
1313
+ ...Ar,
1314
+ ...t === null ? kr : null
1315
+ },
1316
+ onClick: () => {
1317
+ n({ ...ue });
1318
+ },
1319
+ children: (0, Q.jsx)(Ve, {
1320
+ icons: [null],
1321
+ size: 16
1322
+ })
1323
+ }), (0, Q.jsx)(B, {
1324
+ sx: {
1325
+ display: "grid",
1326
+ gridTemplateColumns: "repeat(8, auto)",
1327
+ justifyContent: "start",
1328
+ gap: "3px"
1329
+ },
1330
+ children: Pe.map((e) => {
1331
+ let i = ((e, t) => !!e && e.iconKey === t.iconKey && e.color === t.color)(t, e.spec);
1332
+ return (0, Q.jsx)(J, {
1333
+ sheet: !0,
1334
+ title: Nt(r, e.spec),
1335
+ "aria-pressed": i,
1336
+ sx: {
1337
+ ...Ar,
1338
+ ...i ? kr : null
1339
+ },
1340
+ onClick: () => {
1341
+ n({
1342
+ set: e.set,
1343
+ id: e.id
1344
+ });
1345
+ },
1346
+ children: (0, Q.jsx)(Ve, {
1347
+ icons: [e.spec],
1348
+ size: 16
1349
+ })
1350
+ }, `${e.set}:${e.id}`);
1351
+ })
1352
+ })]
1353
+ });
1354
+ });
1355
+ jr.displayName = "IconCatalogPanel";
1356
+ var Mr = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
1357
+ let { icon: n, onPick: r, tooltip: i, ...a } = e, o = k(), s = (0, Z.useCallback)((e) => {
1358
+ let { closeFloat: t } = e, i = (0, Q.jsx)(jr, {
1359
+ icon: n,
1360
+ onPick: (e) => {
1361
+ t?.(), r(e);
1362
+ }
1363
+ });
1364
+ return xn({
1365
+ ...e,
1366
+ children: i
1367
+ });
1368
+ }, [n, r]);
1369
+ return (0, Q.jsx)(dn, {
1370
+ ref: t,
1371
+ createPopupPanel: s,
1372
+ tooltip: i ?? o(Or),
1373
+ icon: (0, Q.jsx)(Ve, {
1374
+ icons: [n],
1375
+ size: 16
1376
+ }),
1377
+ outlined: !0,
1378
+ ...a
1379
+ });
1380
+ }));
1381
+ Mr.displayName = "IconPickerPopupButton";
1382
+ var Nr = [
1383
+ L.ColorStopType.Percent,
1384
+ L.ColorStopType.Num,
1385
+ L.ColorStopType.Percentile,
1386
+ L.ColorStopType.Formula
1387
+ ], Pr = (0, Z.memo)((e) => {
1388
+ let { scale: t, onScaleChange: n, readOnly: r, ...i } = e, a = k(), s = t.iconSet ?? le.IconSet.TrafficLights3, c = de(s).length === 0, l = t.stops ?? [], u = l.length, d = ke(t), f = (e) => {
1389
+ let r = { ...t };
1390
+ for (let [t, n] of Object.entries(e)) n === void 0 ? delete r[t] : r[t] = n;
1391
+ n(r);
1392
+ }, p = (0, Z.useCallback)((e) => {
1393
+ let { closeFloat: t } = e, n = (0, Q.jsx)(bt, {
1394
+ groups: Qt,
1395
+ disabled: r,
1396
+ onPick: (e) => {
1397
+ t?.(), e.type === L.ScaleType.IconSet && e.iconSet && ((e) => {
1398
+ if (e === s) return;
1399
+ let t = Le(e), n = l;
1400
+ t !== l.length && (n = Me(t)), f({
1401
+ iconSet: e,
1402
+ stops: n,
1403
+ icon: void 0
1404
+ });
1405
+ })(e.iconSet);
1406
+ }
1407
+ });
1408
+ return xn({
1409
+ ...e,
1410
+ children: n
1411
+ });
1412
+ }, [r, t]), m = o.camelToPrettyCase(s);
1413
+ return (0, Q.jsxs)(B, {
1414
+ sx: {
1415
+ display: "flex",
1416
+ flexDirection: "column",
1417
+ gap: 1
1418
+ },
1419
+ ...i,
1420
+ children: [(0, Q.jsxs)(fr, { children: [
1421
+ (0, Q.jsx)(B, {
1422
+ sx: {
1423
+ display: "flex",
1424
+ alignItems: "center",
1425
+ gap: 1
1426
+ },
1427
+ children: (0, Q.jsx)(dn, {
1428
+ outlined: !0,
1429
+ disabled: r,
1430
+ label: m,
1431
+ tooltip: m,
1432
+ icon: (0, Q.jsx)(B, {
1433
+ sx: {
1434
+ width: "82px",
1435
+ display: "flex",
1436
+ justifyContent: "center"
1437
+ },
1438
+ children: c ? (0, Q.jsx)(H, {
1439
+ variant: "caption",
1440
+ noWrap: !0,
1441
+ children: m
1442
+ }) : (0, Q.jsx)(Ve, {
1443
+ icons: de(s),
1444
+ order: "descending",
1445
+ size: 14,
1446
+ gap: 3
1447
+ })
1448
+ }),
1449
+ createPopupPanel: p
1450
+ })
1451
+ }),
1452
+ c && (0, Q.jsx)(H, {
1453
+ variant: "caption",
1454
+ sx: { color: "text.secondary" },
1455
+ children: a("conditionalFormat.adoptedIconSet")
1456
+ }),
1457
+ (0, Q.jsxs)(B, {
1458
+ sx: {
1459
+ display: "flex",
1460
+ gap: 1
1461
+ },
1462
+ children: [(0, Q.jsx)(sn, {
1463
+ control: (0, Q.jsx)(on, {
1464
+ size: "small",
1465
+ checked: !1 === t.showValue,
1466
+ disabled: r,
1467
+ onChange: (e) => f({ showValue: !e.target.checked && void 0 })
1468
+ }),
1469
+ label: (0, Q.jsx)(H, {
1470
+ variant: "body2",
1471
+ children: a("conditionalFormat.showIconsOnly")
1472
+ })
1473
+ }), (0, Q.jsx)(sn, {
1474
+ control: (0, Q.jsx)(on, {
1475
+ size: "small",
1476
+ checked: t.reverse ?? !1,
1477
+ disabled: r,
1478
+ onChange: (e) => f({ reverse: !!e.target.checked || void 0 })
1479
+ }),
1480
+ label: (0, Q.jsx)(H, {
1481
+ variant: "body2",
1482
+ children: a("conditionalFormat.reverseIcons")
1483
+ })
1484
+ })]
1485
+ })
1486
+ ] }), (0, Q.jsx)(fr, {
1487
+ variant: "config",
1488
+ children: l.map((e, i) => {
1489
+ let a = t.reverse ? u - 1 - i : i;
1490
+ return (0, Q.jsx)(br, {
1491
+ stop: e,
1492
+ allowedTypes: Nr,
1493
+ showExclusive: !0,
1494
+ readOnly: r || i === 0,
1495
+ leading: (0, Q.jsx)(Mr, {
1496
+ icon: d[i] ?? null,
1497
+ disabled: r || c,
1498
+ onPick: (e) => n(fe(t, a, e))
1499
+ }),
1500
+ onStopChange: (e) => {
1501
+ let t = l.slice();
1502
+ t[i] = e, f({ stops: t });
1503
+ }
1504
+ }, i);
1505
+ })
1506
+ })]
1507
+ });
1508
+ });
1509
+ Pr.displayName = "IconSetRulePanel";
1510
+ var Fr = (e, t, n) => rn(e, t)?.toCSS("adaptive") ?? n, Ir = (e, t, n) => {
1511
+ if (!e) return n;
1512
+ if (typeof e == "string") return Fr(e, t, n);
1513
+ if (e.type === se.Type.None) return n;
1514
+ let r = e, i = e;
1515
+ return Fr(i.foreground ?? r.color ?? i.background, t, n);
1516
+ }, Lr = (0, Z.memo)((e) => {
1517
+ let { conditionalFormat: t, size: n = 28, ...r } = e, { workbook: i, themeKey: a } = Xt();
1518
+ N(t, "onAnyChange");
1519
+ let o = t.getScale(), s = t.getStyle(), c = (0, Z.useMemo)(() => {
1520
+ try {
1521
+ return i?.getStyles().getNormal().getFont().toCSS("adaptive") ?? {};
1522
+ } catch {
1523
+ return {};
1524
+ }
1525
+ }, [i, a]), l = (0, Z.useMemo)(() => {
1526
+ if (o?.type === L.ScaleType.ColorScale) return (0, Q.jsx)(_t, { rows: Ht(o.stops ?? [], Yt, i) });
1527
+ if (o?.type === L.ScaleType.DataBar) return (0, Q.jsx)(_t, { rows: Lt(o, Fr(o.color, i, an), o.borderColor ? Fr(o.borderColor, i, an) : void 0) });
1528
+ if (o?.type === L.ScaleType.IconSet) return (0, Q.jsx)(B, {
1529
+ sx: {
1530
+ display: "flex",
1531
+ alignItems: "center",
1532
+ justifyContent: "center",
1533
+ width: "100%",
1534
+ height: "100%",
1535
+ px: .5
1536
+ },
1537
+ children: (0, Q.jsx)(Ve, {
1538
+ icons: ke(o),
1539
+ order: "descending",
1540
+ size: 14,
1541
+ gap: 3
1542
+ })
1543
+ });
1544
+ let e = s?.font, t = e?.underline && e.underline !== P.UnderlineStyle.None;
1545
+ return (0, Q.jsx)(B, {
1546
+ sx: {
1547
+ width: "100%",
1548
+ height: "100%",
1549
+ display: "flex",
1550
+ alignItems: "center",
1551
+ justifyContent: "center",
1552
+ ...c,
1553
+ backgroundColor: Ir(s?.fill, i, "transparent"),
1554
+ ...e?.color && e.color !== "auto" ? { color: Fr(e.color, i, qt) } : null,
1555
+ ...e?.weight ? { fontWeight: e.weight } : null,
1556
+ ...e?.style ? { fontStyle: e.style } : null,
1557
+ textDecoration: [t ? "underline" : "", e?.strike ? "line-through" : ""].join(" ").trim() || "none",
1558
+ fontSize: `${Math.round(.5 * n)}px`,
1559
+ lineHeight: 1,
1560
+ outline: s?.borders ? `1px solid ${Fr(Object.values(s.borders)[0]?.color, i, Bt)}` : void 0,
1561
+ outlineOffset: "-3px"
1562
+ },
1563
+ children: "Aa"
1564
+ });
1565
+ }, [
1566
+ o,
1567
+ s,
1568
+ n,
1569
+ c,
1570
+ i,
1571
+ a
1572
+ ]);
1573
+ return (0, Q.jsx)(J, {
1574
+ sheet: !0,
1575
+ className: "sxl-cf-rule-preview",
1576
+ sx: {
1577
+ width: "auto",
1578
+ minWidth: 1.7 * n + "px",
1579
+ height: `${n}px`
1580
+ },
1581
+ ...r,
1582
+ children: l
1583
+ });
1584
+ });
1585
+ Lr.displayName = "RulePreview";
1586
+ var Rr = (e, t) => {
1587
+ let n = e.getCondition()?.toString();
1588
+ if (n) return n;
1589
+ let r = e.getScale();
1590
+ return r ? o.camelToPrettyCase(r.type) : t("conditionalFormat.noCondition");
1591
+ }, zr = {
1592
+ classic: u("conditionalFormat.tab.classic"),
1593
+ [L.ScaleType.ColorScale]: u("conditionalFormat.tab.colorScale"),
1594
+ [L.ScaleType.DataBar]: u("conditionalFormat.tab.dataBars"),
1595
+ [L.ScaleType.IconSet]: u("conditionalFormat.tab.iconSets")
1596
+ }, Br = (0, Z.memo)((e) => {
1597
+ let { conditionalFormat: t } = e, n = k();
1598
+ N(t, "onAnyChange");
1599
+ let r = t.getScale(), i = t.getCondition(), a = t.getStyle(), o = t.isProtected(), s = r?.type ?? "classic", c = (0, Z.useRef)({ scales: {} }), l = (e) => {
1600
+ t.update({ scale: e });
1601
+ }, u = (0, Q.jsxs)(Qe, {
1602
+ tabIndex: 0,
1603
+ className: Zt["editor-panel"],
1604
+ sx: {
1605
+ gap: (e) => e.spacing(1),
1606
+ paddingTop: (e) => e.spacing(1.25),
1607
+ paddingBottom: (e) => e.spacing(2),
1608
+ paddingLeft: (e) => e.spacing(1.5),
1609
+ paddingRight: (e) => e.spacing(1.5),
1610
+ border: (e) => `1px solid ${e.palette.divider}`,
1611
+ borderRadius: (e) => e.spacing(1.25),
1612
+ overflow: "auto"
1613
+ },
1614
+ children: [
1615
+ (0, Q.jsxs)(B, {
1616
+ sx: {
1617
+ display: "flex",
1618
+ flexDirection: "column",
1619
+ gap: (e) => e.spacing(1.75),
1620
+ margin: (e) => e.spacing(1.25),
1621
+ marginBottom: 0
1622
+ },
1623
+ children: [(0, Q.jsxs)(B, {
1624
+ sx: {
1625
+ display: "flex",
1626
+ alignItems: "center",
1627
+ gap: (e) => e.spacing(1.5)
1628
+ },
1629
+ children: [(0, Q.jsx)(Lr, {
1630
+ conditionalFormat: t,
1631
+ size: 48
1632
+ }), (0, Q.jsx)(H, {
1633
+ variant: "body2",
1634
+ sx: {
1635
+ minWidth: 0,
1636
+ wordBreak: "break-word"
1637
+ },
1638
+ children: Rr(t, n)
1639
+ })]
1640
+ }), (0, Q.jsx)(Gt, {
1641
+ item: t,
1642
+ label: n("conditionalFormat.applyTo")
1643
+ })]
1644
+ }),
1645
+ (0, Q.jsx)(St, {
1646
+ value: s,
1647
+ onChange: (e, n) => {
1648
+ o || ((e) => {
1649
+ if (e !== s) {
1650
+ if (s === "classic" ? (c.current.condition = i?.toJSON() ?? null, c.current.style = a) : r && (c.current.scales[r.type] = r), e === "classic") t.update({
1651
+ condition: c.current.condition ?? {
1652
+ operator: F.BuiltInOperatorNames.Between,
1653
+ param: null
1654
+ },
1655
+ style: c.current.style ?? null,
1656
+ scale: null
1657
+ });
1658
+ else {
1659
+ let n = c.current.scales[e] ?? (e === L.ScaleType.ColorScale ? ve() : e === L.ScaleType.DataBar ? we() : Ie());
1660
+ t.update({
1661
+ scale: n,
1662
+ condition: null,
1663
+ style: null
1664
+ });
1665
+ }
1666
+ }
1667
+ })(n);
1668
+ },
1669
+ variant: "fullWidth",
1670
+ sx: {
1671
+ minHeight: "36px",
1672
+ borderBottom: 1,
1673
+ borderColor: "divider",
1674
+ "& .MuiTab-root": {
1675
+ minHeight: "36px",
1676
+ textTransform: "none",
1677
+ pt: .5,
1678
+ pb: .5,
1679
+ px: .5,
1680
+ minWidth: 0
1681
+ }
1682
+ },
1683
+ children: Object.keys(zr).map((e) => (0, Q.jsx)(Et, {
1684
+ value: e,
1685
+ label: n(zr[e])
1686
+ }, e))
1687
+ }),
1688
+ s === "classic" && (0, Q.jsxs)(Q.Fragment, { children: [(0, Q.jsx)(_r, {
1689
+ format: a,
1690
+ readOnly: o,
1691
+ onFormatChange: (e) => t.update({ style: e })
1692
+ }), (0, Q.jsx)(wt, {
1693
+ sx: {
1694
+ ...yt,
1695
+ p: 2,
1696
+ pb: 1
1697
+ },
1698
+ selectorTitle: n("conditionalFormat.highlight"),
1699
+ condition: i,
1700
+ ranges: t.getRanges(),
1701
+ readOnly: o,
1702
+ onConditionChange: (e) => t.setCondition(e)
1703
+ })] }),
1704
+ r?.type === L.ScaleType.ColorScale && (0, Q.jsx)(Sr, {
1705
+ scale: r,
1706
+ onScaleChange: l,
1707
+ readOnly: o
1708
+ }),
1709
+ r?.type === L.ScaleType.DataBar && (0, Q.jsx)(Er, {
1710
+ scale: r,
1711
+ onScaleChange: l,
1712
+ readOnly: o
1713
+ }),
1714
+ r?.type === L.ScaleType.IconSet && (0, Q.jsx)(Pr, {
1715
+ scale: r,
1716
+ onScaleChange: l,
1717
+ readOnly: o
1718
+ }),
1719
+ s === "classic" && (0, Q.jsx)(B, {
1720
+ sx: {
1721
+ pl: 2,
1722
+ pr: 2,
1723
+ border: 1,
1724
+ borderColor: "divider",
1725
+ borderRadius: 1
1726
+ },
1727
+ children: (0, Q.jsx)(sn, {
1728
+ control: (0, Q.jsx)(on, {
1729
+ checked: t.isStopIfTrue(),
1730
+ disabled: o,
1731
+ onChange: (e) => t.setStopIfTrue(e.target.checked)
1732
+ }),
1733
+ label: n("conditionalFormat.stopIfTrue")
1734
+ })
1735
+ })
1736
+ ]
1737
+ });
1738
+ return (0, Q.jsx)(en.Provider, {
1739
+ value: t,
1740
+ children: u
1741
+ });
1742
+ });
1743
+ Br.displayName = "ConditionalFormatEditorPanel";
1744
+ var Vr = (0, Z.memo)(({ item: e }) => {
1745
+ let t = k();
1746
+ return N(e, "onAnyChange"), !e.isStopIfTrue() || e.getScale() ? null : (0, Q.jsx)(B, {
1747
+ sx: {
1748
+ display: "inline-flex",
1749
+ alignItems: "center",
1750
+ alignSelf: "flex-start",
1751
+ px: .75,
1752
+ py: .25,
1753
+ border: 1,
1754
+ borderColor: "divider",
1755
+ borderRadius: 1,
1756
+ color: "text.secondary"
1757
+ },
1758
+ children: (0, Q.jsx)(H, {
1759
+ variant: "caption",
1760
+ children: t("conditionalFormat.stopIfTrue")
1761
+ })
1762
+ });
1763
+ });
1764
+ Vr.displayName = "StopIfTrueBadge";
1765
+ var Hr = (0, Z.memo)(({ item: e }) => {
1766
+ let t = k();
1767
+ return (0, Q.jsx)(Gt, {
1768
+ item: e,
1769
+ label: t("conditionalFormat.applyTo"),
1770
+ helperText: null
1771
+ });
1772
+ });
1773
+ Hr.displayName = "ConditionalFormatCardRanges";
1774
+ var Ur = {
1775
+ key: "conditional-format",
1776
+ messageKeys: {
1777
+ none: u("conditionalFormat.none"),
1778
+ addPrompt: u("conditionalFormat.addPrompt"),
1779
+ heading: u("conditionalFormat.heading"),
1780
+ insert: u("conditionalFormat.insert"),
1781
+ new: u("conditionalFormat.new"),
1782
+ moveUp: u("conditionalFormat.moveUp"),
1783
+ moveDown: u("conditionalFormat.moveDown"),
1784
+ edit: u("conditionalFormat.edit"),
1785
+ duplicate: u("conditionalFormat.duplicate"),
1786
+ delete: u("conditionalFormat.delete"),
1787
+ cancel: u("conditionalFormat.cancel"),
1788
+ save: u("conditionalFormat.save")
1789
+ },
1790
+ getCollection: (e) => e.getConditionalFormats(),
1791
+ changeEvents: ["onConditionalFormatsChange"],
1792
+ isReadOnly: (e) => !e.getProtection().isFormatCellsAllowed(),
1793
+ applyUpdate: (e, t) => {
1794
+ e.update(t);
1795
+ },
1796
+ validate: (e) => e.getCondition()?.validate() ?? null,
1797
+ applySeed: (e, t) => {
1798
+ e.update({
1799
+ condition: t.condition ?? null,
1800
+ style: t.style ?? null,
1801
+ scale: t.scale ?? null,
1802
+ stopIfTrue: t.stopIfTrue ?? !1
1803
+ });
1804
+ },
1805
+ getCardTitle: Rr,
1806
+ CardMedia: ({ item: e }) => (0, Q.jsx)(Lr, {
1807
+ conditionalFormat: e,
1808
+ size: 32
1809
+ }),
1810
+ CardSubtitle: Hr,
1811
+ CardBody: Vr,
1812
+ EditorBody: ({ item: e }) => (0, Q.jsx)(Br, { conditionalFormat: e })
1813
+ }, Wr = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
1814
+ let { workbook: n, args: r, ...i } = e;
1815
+ return (0, Q.jsx)($t, {
1816
+ ref: t,
1817
+ workbook: n,
1818
+ descriptor: Ur,
1819
+ args: r,
1820
+ dragReorder: !0,
1821
+ ...i
1822
+ });
1823
+ }));
1824
+ Wr.displayName = "ConditionalFormatDetailsPanel";
1825
+ var Gr = ["lines"];
1826
+ function Kr(e) {
1827
+ var t, n, r = "";
1828
+ if (typeof e == "string" || typeof e == "number") r += e;
1829
+ else if (typeof e == "object") {
1830
+ if (Array.isArray(e)) for (t = 0; t < e.length; t++) e[t] && (n = Kr(e[t])) && (r && (r += " "), r += n);
1831
+ else for (t in e) e[t] && (r && (r += " "), r += t);
1832
+ }
1833
+ return r;
1834
+ }
1835
+ function qr() {
1836
+ for (var e, t, n = 0, r = ""; n < arguments.length;) (e = arguments[n++]) && (t = Kr(e)) && (r && (r += " "), r += t);
1837
+ return r;
1838
+ }
1839
+ var Jr = { data: "" }, Yr = /(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g, Xr = /\/\*[^]*?\*\/| +/g, Zr = /\n+/g, Qr = (e, t) => {
1840
+ let n = "", r = "", i = "";
1841
+ for (let a in e) {
1842
+ let o = e[a];
1843
+ a[0] == "@" ? a[1] == "i" ? n = a + " " + o + ";" : r += a[1] == "f" ? Qr(o, a) : a + "{" + Qr(o, a[1] == "k" ? "" : t) + "}" : typeof o == "object" ? r += Qr(o, t ? t.replace(/([^,])+/g, (e) => a.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g, (t) => /&/.test(t) ? t.replace(/&/g, e) : e ? e + " " + t : t)) : a) : o != null && (a = a[1] == "-" ? a : a.replace(/[A-Z]/g, "-$&").toLowerCase(), i += Qr.p ? Qr.p(a, o) : a + ":" + o + ";");
1844
+ }
1845
+ return n + (t && i ? t + "{" + i + "}" : i) + r;
1846
+ }, $r = {}, ei = (e) => {
1847
+ if (typeof e == "object") {
1848
+ let t = "";
1849
+ for (let n in e) t += n + ei(e[n]);
1850
+ return t;
1851
+ }
1852
+ return e;
1853
+ };
1854
+ function ti(e) {
1855
+ let t = this || {}, n = e.call ? e(t.p) : e;
1856
+ return ((e, t, n, r, i) => {
1857
+ let a = ei(e), o = $r[a] || ($r[a] = ((e) => {
1858
+ let t = 0, n = 11;
1859
+ for (; t < e.length;) n = 101 * n + e.charCodeAt(t++) >>> 0;
1860
+ return "go" + n;
1861
+ })(a));
1862
+ if (!$r[o]) {
1863
+ let t = a === e ? ((e) => {
1864
+ let t, n, r = [{}];
1865
+ for (; t = Yr.exec(e.replace(Xr, ""));) t[4] ? r.shift() : t[3] ? (n = t[3].replace(Zr, " ").trim(), r.unshift(r[0][n] = r[0][n] || {})) : r[0][t[1]] = t[2].replace(Zr, " ").trim();
1866
+ return r[0];
1867
+ })(e) : e;
1868
+ $r[o] = Qr(i ? { ["@keyframes " + o]: t } : t, n ? "" : "." + o);
1869
+ }
1870
+ let s = n && $r.g;
1871
+ return n && ($r.g = $r[o]), ((e, t, n, r) => {
1872
+ r ? t.data = t.data.replace(r, e) : t.data.indexOf(e) === -1 && (t.data = n ? e + t.data : t.data + e);
1873
+ })($r[o], t, r, s), o;
1874
+ })(n.unshift ? n.raw ? ((e, t, n) => e.reduce((e, r, i) => {
1875
+ let a = t[i];
1876
+ if (a && a.call) {
1877
+ let e = a(n), t = e && e.props && e.props.className || /^go/.test(e) && e;
1878
+ a = t ? "." + t : e && typeof e == "object" ? e.props ? "" : Qr(e, "") : !1 === e ? "" : e;
1879
+ }
1880
+ return e + r + (a ?? "");
1881
+ }, ""))(n, [].slice.call(arguments, 1), t.p) : n.reduce((e, n) => Object.assign(e, n && n.call ? n(t.p) : n), {}) : n, ((e) => {
1882
+ if (typeof window == "object") {
1883
+ let t = (e ? e.querySelector("#_goober") : window._goober) || Object.assign(document.createElement("style"), {
1884
+ innerHTML: " ",
1885
+ id: "_goober"
1886
+ });
1887
+ return t.nonce = window.__nonce__, t.parentNode || (e || document.head).appendChild(t), t.firstChild;
1888
+ }
1889
+ return e || Jr;
1890
+ })(t.target), t.g, t.o, t.k);
1891
+ }
1892
+ function ni(e, t) {
1893
+ for (var n = 0; n < t.length; n++) {
1894
+ var r = t[n];
1895
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(e, r.key, r);
1896
+ }
1897
+ }
1898
+ function ri(e, t, n) {
1899
+ return t && ni(e.prototype, t), n && ni(e, n), e;
1900
+ }
1901
+ function $() {
1902
+ return $ = Object.assign || function(e) {
1903
+ for (var t = 1; t < arguments.length; t++) {
1904
+ var n = arguments[t];
1905
+ for (var r in n) Object.prototype.hasOwnProperty.call(n, r) && (e[r] = n[r]);
1906
+ }
1907
+ return e;
1908
+ }, $.apply(this, arguments);
1909
+ }
1910
+ function ii(e, t) {
1911
+ e.prototype = Object.create(t.prototype), e.prototype.constructor = e, e.__proto__ = t;
1912
+ }
1913
+ function ai(e, t) {
1914
+ if (e == null) return {};
1915
+ for (var n, r = {}, i = Object.keys(e), a = 0; a < i.length; a++) n = i[a], t.indexOf(n) >= 0 || (r[n] = e[n]);
1916
+ return r;
1917
+ }
1918
+ function oi(e) {
1919
+ if (e === void 0) throw ReferenceError("this hasn't been initialised - super() hasn't been called");
1920
+ return e;
1921
+ }
1922
+ ti.bind({ g: 1 }), ti.bind({ k: 1 });
1923
+ var si = function() {
1924
+ return "";
1925
+ }, ci = Z.createContext({
1926
+ enqueueSnackbar: si,
1927
+ closeSnackbar: si
1928
+ }), li = "@media (max-width:599.95px)", ui = "@media (min-width:600px)", di = function(e) {
1929
+ return e.charAt(0).toUpperCase() + e.slice(1);
1930
+ }, fi = function(e) {
1931
+ return "" + di(e.vertical) + di(e.horizontal);
1932
+ }, pi = function(e) {
1933
+ return !!e || e === 0;
1934
+ }, mi = "unmounted", hi = "exited", gi = "entering", _i = "entered", vi = "exiting", yi = function(e) {
1935
+ function t(t) {
1936
+ var n, r = e.call(this, t) || this, i = t.appear;
1937
+ return r.appearStatus = null, t.in ? i ? (n = hi, r.appearStatus = gi) : n = _i : n = t.unmountOnExit || t.mountOnEnter ? mi : hi, r.state = { status: n }, r.nextCallback = null, r;
1938
+ }
1939
+ ii(t, e), t.getDerivedStateFromProps = function(e, t) {
1940
+ return e.in && t.status === mi ? { status: hi } : null;
1941
+ };
1942
+ var n = t.prototype;
1943
+ return n.componentDidMount = function() {
1944
+ this.updateStatus(!0, this.appearStatus);
1945
+ }, n.componentDidUpdate = function(e) {
1946
+ var t = null;
1947
+ if (e !== this.props) {
1948
+ var n = this.state.status;
1949
+ this.props.in ? n !== gi && n !== _i && (t = gi) : n !== gi && n !== _i || (t = vi);
1950
+ }
1951
+ this.updateStatus(!1, t);
1952
+ }, n.componentWillUnmount = function() {
1953
+ this.cancelNextCallback();
1954
+ }, n.getTimeouts = function() {
1955
+ var e = this.props.timeout, t = e, n = e;
1956
+ return e != null && typeof e != "number" && typeof e != "string" && (n = e.exit, t = e.enter), {
1957
+ exit: n,
1958
+ enter: t
1959
+ };
1960
+ }, n.updateStatus = function(e, t) {
1961
+ e === void 0 && (e = !1), t === null ? this.props.unmountOnExit && this.state.status === hi && this.setState({ status: mi }) : (this.cancelNextCallback(), t === gi ? this.performEnter(e) : this.performExit());
1962
+ }, n.performEnter = function(e) {
1963
+ var t = this, n = this.props.enter, r = e, i = this.getTimeouts();
1964
+ e || n ? (this.props.onEnter && this.props.onEnter(this.node, r), this.safeSetState({ status: gi }, function() {
1965
+ t.props.onEntering && t.props.onEntering(t.node, r), t.onTransitionEnd(i.enter, function() {
1966
+ t.safeSetState({ status: _i }, function() {
1967
+ t.props.onEntered && t.props.onEntered(t.node, r);
1968
+ });
1969
+ });
1970
+ })) : this.safeSetState({ status: _i }, function() {
1971
+ t.props.onEntered && t.props.onEntered(t.node, r);
1972
+ });
1973
+ }, n.performExit = function() {
1974
+ var e = this, t = this.props.exit, n = this.getTimeouts();
1975
+ t ? (this.props.onExit && this.props.onExit(this.node), this.safeSetState({ status: vi }, function() {
1976
+ e.props.onExiting && e.props.onExiting(e.node), e.onTransitionEnd(n.exit, function() {
1977
+ e.safeSetState({ status: hi }, function() {
1978
+ e.props.onExited && e.props.onExited(e.node);
1979
+ });
1980
+ });
1981
+ })) : this.safeSetState({ status: hi }, function() {
1982
+ e.props.onExited && e.props.onExited(e.node);
1983
+ });
1984
+ }, n.cancelNextCallback = function() {
1985
+ this.nextCallback !== null && this.nextCallback.cancel && (this.nextCallback.cancel(), this.nextCallback = null);
1986
+ }, n.safeSetState = function(e, t) {
1987
+ t = this.setNextCallback(t), this.setState(e, t);
1988
+ }, n.setNextCallback = function(e) {
1989
+ var t = this, n = !0;
1990
+ return this.nextCallback = function() {
1991
+ n && (n = !1, t.nextCallback = null, e());
1992
+ }, this.nextCallback.cancel = function() {
1993
+ n = !1;
1994
+ }, this.nextCallback;
1995
+ }, n.onTransitionEnd = function(e, t) {
1996
+ this.setNextCallback(t);
1997
+ var n = e == null && !this.props.addEndListener;
1998
+ this.node && !n ? (this.props.addEndListener && this.props.addEndListener(this.node, this.nextCallback), e != null && setTimeout(this.nextCallback, e)) : setTimeout(this.nextCallback, 0);
1999
+ }, n.render = function() {
2000
+ var e = this.state.status;
2001
+ if (e === mi) return null;
2002
+ var t = this.props;
2003
+ return (0, t.children)(e, ai(t, [
2004
+ "children",
2005
+ "in",
2006
+ "mountOnEnter",
2007
+ "unmountOnExit",
2008
+ "appear",
2009
+ "enter",
2010
+ "exit",
2011
+ "timeout",
2012
+ "addEndListener",
2013
+ "onEnter",
2014
+ "onEntering",
2015
+ "onEntered",
2016
+ "onExit",
2017
+ "onExiting",
2018
+ "onExited",
2019
+ "nodeRef"
2020
+ ]));
2021
+ }, ri(t, [{
2022
+ key: "node",
2023
+ get: function() {
2024
+ var e = this.props.nodeRef?.current;
2025
+ if (!e) throw Error("notistack - Custom snackbar is not refForwarding");
2026
+ return e;
2027
+ }
2028
+ }]), t;
2029
+ }(Z.Component);
2030
+ function bi() {}
2031
+ function xi(e, t) {
2032
+ typeof e == "function" ? e(t) : e && (e.current = t);
2033
+ }
2034
+ function Si(e, t) {
2035
+ return (0, Z.useMemo)(function() {
2036
+ return e == null && t == null ? null : function(n) {
2037
+ xi(e, n), xi(t, n);
2038
+ };
2039
+ }, [e, t]);
2040
+ }
2041
+ function Ci(e) {
2042
+ var t = e.timeout, n = e.style, r = n === void 0 ? {} : n, i = e.mode;
2043
+ return {
2044
+ duration: typeof t == "object" ? t[i] || 0 : t,
2045
+ easing: r.transitionTimingFunction,
2046
+ delay: r.transitionDelay
2047
+ };
2048
+ }
2049
+ yi.defaultProps = {
2050
+ in: !1,
2051
+ mountOnEnter: !1,
2052
+ unmountOnExit: !1,
2053
+ appear: !1,
2054
+ enter: !0,
2055
+ exit: !0,
2056
+ onEnter: bi,
2057
+ onEntering: bi,
2058
+ onEntered: bi,
2059
+ onExit: bi,
2060
+ onExiting: bi,
2061
+ onExited: bi
2062
+ };
2063
+ var wi = function(e) {
2064
+ e.scrollTop = e.scrollTop;
2065
+ }, Ti = function(e) {
2066
+ return Math.round(e) + "ms";
2067
+ };
2068
+ function Ei(e, t) {
2069
+ e === void 0 && (e = ["all"]);
2070
+ var n = t || {}, r = n.duration, i = r === void 0 ? 300 : r, a = n.easing, o = a === void 0 ? "cubic-bezier(0.4, 0, 0.2, 1)" : a, s = n.delay, c = s === void 0 ? 0 : s;
2071
+ return (Array.isArray(e) ? e : [e]).map(function(e) {
2072
+ var t = typeof i == "string" ? i : Ti(i), n = typeof c == "string" ? c : Ti(c);
2073
+ return e + " " + t + " " + o + " " + n;
2074
+ }).join(",");
2075
+ }
2076
+ function Di(e) {
2077
+ return function(e) {
2078
+ return e && e.ownerDocument || document;
2079
+ }(e).defaultView || window;
2080
+ }
2081
+ function Oi(e, t) {
2082
+ if (t) {
2083
+ var n = function(e, t) {
2084
+ var n, r = t.getBoundingClientRect(), i = Di(t);
2085
+ if (t.fakeTransform) n = t.fakeTransform;
2086
+ else {
2087
+ var a = i.getComputedStyle(t);
2088
+ n = a.getPropertyValue("-webkit-transform") || a.getPropertyValue("transform");
2089
+ }
2090
+ var o = 0, s = 0;
2091
+ if (n && n !== "none" && typeof n == "string") {
2092
+ var c = n.split("(")[1].split(")")[0].split(",");
2093
+ o = parseInt(c[4], 10), s = parseInt(c[5], 10);
2094
+ }
2095
+ switch (e) {
2096
+ case "left": return "translateX(" + (i.innerWidth + o - r.left) + "px)";
2097
+ case "right": return "translateX(-" + (r.left + r.width - o) + "px)";
2098
+ case "up": return "translateY(" + (i.innerHeight + s - r.top) + "px)";
2099
+ default: return "translateY(-" + (r.top + r.height - s) + "px)";
2100
+ }
2101
+ }(e, t);
2102
+ n && (t.style.webkitTransform = n, t.style.transform = n);
2103
+ }
2104
+ }
2105
+ var ki = (0, Z.forwardRef)(function(e, t) {
2106
+ var n = e.children, r = e.direction, i = r === void 0 ? "down" : r, a = e.in, o = e.style, s = e.timeout, c = s === void 0 ? 0 : s, l = e.onEnter, u = e.onEntered, d = e.onExit, f = e.onExited, p = ai(e, [
2107
+ "children",
2108
+ "direction",
2109
+ "in",
2110
+ "style",
2111
+ "timeout",
2112
+ "onEnter",
2113
+ "onEntered",
2114
+ "onExit",
2115
+ "onExited"
2116
+ ]), m = (0, Z.useRef)(null), h = Si(Si(n.ref, m), t), g = (0, Z.useCallback)(function() {
2117
+ m.current && Oi(i, m.current);
2118
+ }, [i]);
2119
+ return (0, Z.useEffect)(function() {
2120
+ if (!a && i !== "down" && i !== "right") {
2121
+ var e = function(e, t) {
2122
+ var n;
2123
+ function r() {
2124
+ for (var r = this, i = arguments.length, a = Array(i), o = 0; o < i; o++) a[o] = arguments[o];
2125
+ clearTimeout(n), n = setTimeout(function() {
2126
+ e.apply(r, a);
2127
+ }, t);
2128
+ }
2129
+ return t === void 0 && (t = 166), r.clear = function() {
2130
+ clearTimeout(n);
2131
+ }, r;
2132
+ }(function() {
2133
+ m.current && Oi(i, m.current);
2134
+ }), t = Di(m.current);
2135
+ return t.addEventListener("resize", e), function() {
2136
+ e.clear(), t.removeEventListener("resize", e);
2137
+ };
2138
+ }
2139
+ }, [i, a]), (0, Z.useEffect)(function() {
2140
+ a || g();
2141
+ }, [a, g]), (0, Z.createElement)(yi, Object.assign({
2142
+ appear: !0,
2143
+ nodeRef: m,
2144
+ onEnter: function(e, t) {
2145
+ Oi(i, e), wi(e), l && l(e, t);
2146
+ },
2147
+ onEntered: u,
2148
+ onEntering: function(e) {
2149
+ var t = Ci({
2150
+ timeout: c,
2151
+ mode: "enter",
2152
+ style: $({}, o, { transitionTimingFunction: o?.transitionTimingFunction || "cubic-bezier(0.0, 0, 0.2, 1)" })
2153
+ });
2154
+ e.style.webkitTransition = Ei("-webkit-transform", t), e.style.transition = Ei("transform", t), e.style.webkitTransform = "none", e.style.transform = "none";
2155
+ },
2156
+ onExit: function(e) {
2157
+ var t = Ci({
2158
+ timeout: c,
2159
+ mode: "exit",
2160
+ style: $({}, o, { transitionTimingFunction: o?.transitionTimingFunction || "cubic-bezier(0.4, 0, 0.6, 1)" })
2161
+ });
2162
+ e.style.webkitTransition = Ei("-webkit-transform", t), e.style.transition = Ei("transform", t), Oi(i, e), d && d(e);
2163
+ },
2164
+ onExited: function(e) {
2165
+ e.style.webkitTransition = "", e.style.transition = "", f && f(e);
2166
+ },
2167
+ in: a,
2168
+ timeout: c
2169
+ }, p), function(e, t) {
2170
+ return (0, Z.cloneElement)(n, $({
2171
+ ref: h,
2172
+ style: $({ visibility: e !== "exited" || a ? void 0 : "hidden" }, o, {}, n.props.style)
2173
+ }, t));
2174
+ });
2175
+ });
2176
+ ki.displayName = "Slide";
2177
+ var Ai = function(e) {
2178
+ return Z.createElement("svg", Object.assign({
2179
+ viewBox: "0 0 24 24",
2180
+ focusable: "false",
2181
+ style: {
2182
+ fontSize: 20,
2183
+ marginInlineEnd: 8,
2184
+ userSelect: "none",
2185
+ width: "1em",
2186
+ height: "1em",
2187
+ display: "inline-block",
2188
+ fill: "currentColor",
2189
+ flexShrink: 0
2190
+ }
2191
+ }, e));
2192
+ }, ji = {
2193
+ maxSnack: 3,
2194
+ persist: !1,
2195
+ hideIconVariant: !1,
2196
+ disableWindowBlurListener: !1,
2197
+ variant: "default",
2198
+ autoHideDuration: 5e3,
2199
+ iconVariant: {
2200
+ default: void 0,
2201
+ success: Z.createElement(function() {
2202
+ return Z.createElement(Ai, null, Z.createElement("path", { d: "M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M10 17L5 12L6.41\n 10.59L10 14.17L17.59 6.58L19 8L10 17Z" }));
2203
+ }, null),
2204
+ warning: Z.createElement(function() {
2205
+ return Z.createElement(Ai, null, Z.createElement("path", { d: "M13,14H11V10H13M13,18H11V16H13M1,21H23L12,2L1,21Z" }));
2206
+ }, null),
2207
+ error: Z.createElement(function() {
2208
+ return Z.createElement(Ai, null, Z.createElement("path", { d: "M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,\n 6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,\n 13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z" }));
2209
+ }, null),
2210
+ info: Z.createElement(function() {
2211
+ return Z.createElement(Ai, null, Z.createElement("path", { d: "M13,9H11V7H13M13,17H11V11H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,\n 0 22,12A10,10 0 0,0 12,2Z" }));
2212
+ }, null)
2213
+ },
2214
+ anchorOrigin: {
2215
+ vertical: "bottom",
2216
+ horizontal: "left"
2217
+ },
2218
+ TransitionComponent: ki,
2219
+ transitionDuration: {
2220
+ enter: 225,
2221
+ exit: 195
2222
+ }
2223
+ };
2224
+ function Mi(e) {
2225
+ return Object.entries(e).reduce(function(e, t) {
2226
+ var n, r = t[0], i = t[1];
2227
+ return $({}, e, ((n = {})[r] = ti(i), n));
2228
+ }, {});
2229
+ }
2230
+ var Ni = "notistack-CollapseWrapper", Pi = function(e) {
2231
+ return "notistack-MuiContent-" + e;
2232
+ }, Fi = Mi({
2233
+ root: { height: 0 },
2234
+ entered: { height: "auto" }
2235
+ }), Ii = "0px", Li = (0, Z.forwardRef)(function(e, t) {
2236
+ var n = e.children, r = e.in, i = e.onExited, a = (0, Z.useRef)(null), o = (0, Z.useRef)(null), s = Si(t, o), c = function() {
2237
+ return a.current ? a.current.clientHeight : 0;
2238
+ };
2239
+ return (0, Z.createElement)(yi, {
2240
+ in: r,
2241
+ unmountOnExit: !0,
2242
+ onEnter: function(e) {
2243
+ e.style.height = Ii;
2244
+ },
2245
+ onEntered: function(e) {
2246
+ e.style.height = "auto";
2247
+ },
2248
+ onEntering: function(e) {
2249
+ var t = c(), n = Ci({
2250
+ timeout: 175,
2251
+ mode: "enter"
2252
+ }), r = n.duration, i = n.easing;
2253
+ e.style.transitionDuration = typeof r == "string" ? r : r + "ms", e.style.height = t + "px", e.style.transitionTimingFunction = i || "";
2254
+ },
2255
+ onExit: function(e) {
2256
+ e.style.height = c() + "px";
2257
+ },
2258
+ onExited: i,
2259
+ onExiting: function(e) {
2260
+ wi(e);
2261
+ var t = Ci({
2262
+ timeout: 175,
2263
+ mode: "exit"
2264
+ }), n = t.duration, r = t.easing;
2265
+ e.style.transitionDuration = typeof n == "string" ? n : n + "ms", e.style.height = Ii, e.style.transitionTimingFunction = r || "";
2266
+ },
2267
+ nodeRef: o,
2268
+ timeout: 175
2269
+ }, function(e, t) {
2270
+ return (0, Z.createElement)("div", Object.assign({
2271
+ ref: s,
2272
+ className: qr(Fi.root, e === "entered" && Fi.entered),
2273
+ style: $({
2274
+ pointerEvents: "all",
2275
+ overflow: "hidden",
2276
+ minHeight: Ii,
2277
+ transition: Ei("height")
2278
+ }, e === "entered" && { overflow: "visible" }, {}, e === "exited" && !r && { visibility: "hidden" })
2279
+ }, t), (0, Z.createElement)("div", {
2280
+ ref: a,
2281
+ className: Ni,
2282
+ style: {
2283
+ display: "flex",
2284
+ width: "100%"
2285
+ }
2286
+ }, n));
2287
+ });
2288
+ });
2289
+ Li.displayName = "Collapse";
2290
+ var Ri = {
2291
+ right: "left",
2292
+ left: "right",
2293
+ bottom: "up",
2294
+ top: "down"
2295
+ }, zi = function(e) {
2296
+ return "anchorOrigin" + fi(e);
2297
+ }, Bi = function() {};
2298
+ function Vi(e, t) {
2299
+ return e.reduce(function(e, n) {
2300
+ return n == null ? e : function() {
2301
+ var r = [...arguments], i = [].concat(r);
2302
+ t && i.indexOf(t) === -1 && i.push(t), e.apply(this, i), n.apply(this, i);
2303
+ };
2304
+ }, Bi);
2305
+ }
2306
+ var Hi, Ui = typeof window < "u" ? Z.useLayoutEffect : Z.useEffect;
2307
+ function Wi(e) {
2308
+ var t = (0, Z.useRef)(e);
2309
+ return Ui(function() {
2310
+ t.current = e;
2311
+ }), (0, Z.useCallback)(function() {
2312
+ return t.current.apply(void 0, arguments);
2313
+ }, []);
2314
+ }
2315
+ var Gi = (0, Z.forwardRef)(function(e, t) {
2316
+ var n = e.children, r = e.className, i = e.autoHideDuration, a = e.disableWindowBlurListener, o = a !== void 0 && a, s = e.onClose, c = e.id, l = e.open, u = e.SnackbarProps, d = u === void 0 ? {} : u, f = (0, Z.useRef)(), p = Wi(function() {
2317
+ s && s.apply(void 0, arguments);
2318
+ }), m = Wi(function(e) {
2319
+ s && e != null && (f.current && clearTimeout(f.current), f.current = setTimeout(function() {
2320
+ p(null, "timeout", c);
2321
+ }, e));
2322
+ });
2323
+ (0, Z.useEffect)(function() {
2324
+ return l && m(i), function() {
2325
+ f.current && clearTimeout(f.current);
2326
+ };
2327
+ }, [
2328
+ l,
2329
+ i,
2330
+ m
2331
+ ]);
2332
+ var h = function() {
2333
+ f.current && clearTimeout(f.current);
2334
+ }, g = (0, Z.useCallback)(function() {
2335
+ i != null && m(.5 * i);
2336
+ }, [i, m]);
2337
+ return (0, Z.useEffect)(function() {
2338
+ if (!o && l) return window.addEventListener("focus", g), window.addEventListener("blur", h), function() {
2339
+ window.removeEventListener("focus", g), window.removeEventListener("blur", h);
2340
+ };
2341
+ }, [
2342
+ o,
2343
+ g,
2344
+ l
2345
+ ]), (0, Z.createElement)("div", Object.assign({ ref: t }, d, {
2346
+ className: qr("notistack-Snackbar", r),
2347
+ onMouseEnter: function(e) {
2348
+ d.onMouseEnter && d.onMouseEnter(e), h();
2349
+ },
2350
+ onMouseLeave: function(e) {
2351
+ d.onMouseLeave && d.onMouseLeave(e), g();
2352
+ }
2353
+ }), n);
2354
+ });
2355
+ Gi.displayName = "Snackbar";
2356
+ var Ki = Mi({ root: (Hi = {
2357
+ display: "flex",
2358
+ flexWrap: "wrap",
2359
+ flexGrow: 1
2360
+ }, Hi[ui] = {
2361
+ flexGrow: "initial",
2362
+ minWidth: "288px"
2363
+ }, Hi) }), qi = (0, Z.forwardRef)(function(e, t) {
2364
+ var n = e.className, r = ai(e, ["className"]);
2365
+ return Z.createElement("div", Object.assign({
2366
+ ref: t,
2367
+ className: qr(Ki.root, n)
2368
+ }, r));
2369
+ });
2370
+ qi.displayName = "SnackbarContent";
2371
+ var Ji, Yi, Xi, Zi, Qi, $i = Mi({
2372
+ root: {
2373
+ backgroundColor: "#313131",
2374
+ fontSize: "0.875rem",
2375
+ lineHeight: 1.43,
2376
+ letterSpacing: "0.01071em",
2377
+ color: "#fff",
2378
+ alignItems: "center",
2379
+ padding: "6px 16px",
2380
+ borderRadius: "4px",
2381
+ boxShadow: "0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12)"
2382
+ },
2383
+ lessPadding: { paddingLeft: "20px" },
2384
+ default: { backgroundColor: "#313131" },
2385
+ success: { backgroundColor: "#43a047" },
2386
+ error: { backgroundColor: "#d32f2f" },
2387
+ warning: { backgroundColor: "#ff9800" },
2388
+ info: { backgroundColor: "#2196f3" },
2389
+ message: {
2390
+ display: "flex",
2391
+ alignItems: "center",
2392
+ padding: "8px 0"
2393
+ },
2394
+ action: {
2395
+ display: "flex",
2396
+ alignItems: "center",
2397
+ marginLeft: "auto",
2398
+ paddingLeft: "16px",
2399
+ marginRight: "-8px"
2400
+ }
2401
+ }), ea = "notistack-snackbar", ta = (0, Z.forwardRef)(function(e, t) {
2402
+ var n = e.id, r = e.message, i = e.action, a = e.iconVariant, o = e.variant, s = e.hideIconVariant, c = e.style, l = e.className, u = a[o], d = i;
2403
+ return typeof d == "function" && (d = d(n)), Z.createElement(qi, {
2404
+ ref: t,
2405
+ role: "alert",
2406
+ "aria-describedby": ea,
2407
+ style: c,
2408
+ className: qr("notistack-MuiContent", Pi(o), $i.root, $i[o], l, !s && u && $i.lessPadding)
2409
+ }, Z.createElement("div", {
2410
+ id: ea,
2411
+ className: $i.message
2412
+ }, s ? null : u, r), d && Z.createElement("div", { className: $i.action }, d));
2413
+ });
2414
+ ta.displayName = "MaterialDesignContent";
2415
+ var na = (0, Z.memo)(ta), ra = Mi({ wrappedRoot: {
2416
+ width: "100%",
2417
+ position: "relative",
2418
+ transform: "translateX(0)",
2419
+ top: 0,
2420
+ right: 0,
2421
+ bottom: 0,
2422
+ left: 0,
2423
+ minWidth: "288px"
2424
+ } }), ia = function(e) {
2425
+ var t = (0, Z.useRef)(), n = (0, Z.useState)(!0), r = n[0], i = n[1], a = Vi([e.snack.onClose, e.onClose]), o = (0, Z.useCallback)(function() {
2426
+ t.current = setTimeout(function() {
2427
+ i(function(e) {
2428
+ return !e;
2429
+ });
2430
+ }, 125);
2431
+ }, []);
2432
+ (0, Z.useEffect)(function() {
2433
+ return function() {
2434
+ t.current && clearTimeout(t.current);
2435
+ };
2436
+ }, []);
2437
+ var s, c = e.snack, l = e.classes, u = e.Component, d = u === void 0 ? na : u, f = (0, Z.useMemo)(function() {
2438
+ return function(e) {
2439
+ e === void 0 && (e = {});
2440
+ var t = {
2441
+ containerRoot: !0,
2442
+ containerAnchorOriginTopCenter: !0,
2443
+ containerAnchorOriginBottomCenter: !0,
2444
+ containerAnchorOriginTopRight: !0,
2445
+ containerAnchorOriginBottomRight: !0,
2446
+ containerAnchorOriginTopLeft: !0,
2447
+ containerAnchorOriginBottomLeft: !0
2448
+ };
2449
+ return Object.keys(e).filter(function(e) {
2450
+ return !t[e];
2451
+ }).reduce(function(t, n) {
2452
+ var r;
2453
+ return $({}, t, ((r = {})[n] = e[n], r));
2454
+ }, {});
2455
+ }(l);
2456
+ }, [l]), p = c.open, m = c.SnackbarProps, h = c.TransitionComponent, g = c.TransitionProps, _ = c.transitionDuration, v = c.disableWindowBlurListener, y = c.content, b = ai(c, [
2457
+ "open",
2458
+ "SnackbarProps",
2459
+ "TransitionComponent",
2460
+ "TransitionProps",
2461
+ "transitionDuration",
2462
+ "disableWindowBlurListener",
2463
+ "content",
2464
+ "entered",
2465
+ "requestClose",
2466
+ "onEnter",
2467
+ "onEntered",
2468
+ "onExit",
2469
+ "onExited"
2470
+ ]), x = $({
2471
+ direction: (s = b.anchorOrigin, s.horizontal === "center" ? Ri[s.vertical] : Ri[s.horizontal]),
2472
+ timeout: _
2473
+ }, g), S = y;
2474
+ typeof S == "function" && (S = S(b.id, b.message));
2475
+ var C = [
2476
+ "onEnter",
2477
+ "onEntered",
2478
+ "onExit",
2479
+ "onExited"
2480
+ ].reduce(function(t, n) {
2481
+ var r;
2482
+ return $({}, t, ((r = {})[n] = Vi([e.snack[n], e[n]], b.id), r));
2483
+ }, {});
2484
+ return Z.createElement(Li, {
2485
+ in: r,
2486
+ onExited: C.onExited
2487
+ }, Z.createElement(Gi, {
2488
+ open: p,
2489
+ id: b.id,
2490
+ disableWindowBlurListener: v,
2491
+ autoHideDuration: b.autoHideDuration,
2492
+ className: qr(ra.wrappedRoot, f.root, f[zi(b.anchorOrigin)]),
2493
+ SnackbarProps: m,
2494
+ onClose: a
2495
+ }, Z.createElement(h, Object.assign({}, x, {
2496
+ appear: !0,
2497
+ in: p,
2498
+ onExit: C.onExit,
2499
+ onExited: o,
2500
+ onEnter: C.onEnter,
2501
+ onEntered: Vi([C.onEntered, function() {
2502
+ e.snack.requestClose && a(null, "instructed", e.snack.id);
2503
+ }], b.id)
2504
+ }), S || Z.createElement(d, Object.assign({}, b)))));
2505
+ }, aa = 20, oa = 6, sa = 2, ca = "." + Ni, la = Mi({
2506
+ root: (Ji = {
2507
+ boxSizing: "border-box",
2508
+ display: "flex",
2509
+ maxHeight: "100%",
2510
+ position: "fixed",
2511
+ zIndex: 1400,
2512
+ height: "auto",
2513
+ width: "auto",
2514
+ transition: Ei([
2515
+ "top",
2516
+ "right",
2517
+ "bottom",
2518
+ "left",
2519
+ "max-width"
2520
+ ], {
2521
+ duration: 300,
2522
+ easing: "ease"
2523
+ }),
2524
+ pointerEvents: "none"
2525
+ }, Ji[ca] = {
2526
+ padding: oa + "px 0px",
2527
+ transition: "padding 300ms ease 0ms"
2528
+ }, Ji.maxWidth = "calc(100% - " + 2 * aa + "px)", Ji[li] = {
2529
+ width: "100%",
2530
+ maxWidth: "calc(100% - 32px)"
2531
+ }, Ji),
2532
+ rootDense: (Yi = {}, Yi[ca] = { padding: sa + "px 0px" }, Yi),
2533
+ top: {
2534
+ top: aa - oa + "px",
2535
+ flexDirection: "column"
2536
+ },
2537
+ bottom: {
2538
+ bottom: aa - oa + "px",
2539
+ flexDirection: "column-reverse"
2540
+ },
2541
+ left: (Xi = { left: aa + "px" }, Xi[ui] = { alignItems: "flex-start" }, Xi[li] = { left: "16px" }, Xi),
2542
+ right: (Zi = { right: aa + "px" }, Zi[ui] = { alignItems: "flex-end" }, Zi[li] = { right: "16px" }, Zi),
2543
+ center: (Qi = {
2544
+ left: "50%",
2545
+ transform: "translateX(-50%)"
2546
+ }, Qi[ui] = { alignItems: "center" }, Qi)
2547
+ }), ua = (0, Z.memo)(function(e) {
2548
+ var t = e.classes, n = t === void 0 ? {} : t, r = e.anchorOrigin, i = e.dense, a = e.children, o = qr("notistack-SnackbarContainer", la[r.vertical], la[r.horizontal], la.root, n.containerRoot, n["containerAnchorOrigin" + fi(r)], i && la.rootDense);
2549
+ return Z.createElement("div", { className: o }, a);
2550
+ }), da = function(e) {
2551
+ return !(typeof e == "string" || (0, Z.isValidElement)(e));
2552
+ }, fa = function(e) {
2553
+ function t(t) {
2554
+ var n = e.call(this, t) || this;
2555
+ return n.enqueueSnackbar = function(e, t) {
2556
+ if (t === void 0 && (t = {}), e == null) throw Error("enqueueSnackbar called with invalid argument");
2557
+ var r = da(e) ? e : t, i = da(e) ? e.message : e, a = r.key, o = r.preventDuplicate, s = ai(r, ["key", "preventDuplicate"]), c = pi(a), l = c ? a : (/* @__PURE__ */ new Date()).getTime() + Math.random(), u = function(e, t) {
2558
+ return function(n, r) {
2559
+ return r === void 0 && (r = !1), r ? $({}, ji[n], {}, t[n], {}, e[n]) : n === "autoHideDuration" ? (i = e.autoHideDuration, a = t.autoHideDuration, (o = function(e) {
2560
+ return typeof e == "number" || e === null;
2561
+ })(i) ? i : o(a) ? a : ji.autoHideDuration) : n === "transitionDuration" ? function(e, t) {
2562
+ var n = function(e, t) {
2563
+ return t.some(function(t) {
2564
+ return typeof e === t;
2565
+ });
2566
+ };
2567
+ return n(e, ["string", "number"]) ? e : n(e, ["object"]) ? $({}, ji.transitionDuration, {}, n(t, ["object"]) && t, {}, e) : n(t, ["string", "number"]) ? t : n(t, ["object"]) ? $({}, ji.transitionDuration, {}, t) : ji.transitionDuration;
2568
+ }(e.transitionDuration, t.transitionDuration) : e[n] || t[n] || ji[n];
2569
+ var i, a, o;
2570
+ };
2571
+ }(s, n.props), d = $({ id: l }, s, {
2572
+ message: i,
2573
+ open: !0,
2574
+ entered: !1,
2575
+ requestClose: !1,
2576
+ persist: u("persist"),
2577
+ action: u("action"),
2578
+ content: u("content"),
2579
+ variant: u("variant"),
2580
+ anchorOrigin: u("anchorOrigin"),
2581
+ disableWindowBlurListener: u("disableWindowBlurListener"),
2582
+ autoHideDuration: u("autoHideDuration"),
2583
+ hideIconVariant: u("hideIconVariant"),
2584
+ TransitionComponent: u("TransitionComponent"),
2585
+ transitionDuration: u("transitionDuration"),
2586
+ TransitionProps: u("TransitionProps", !0),
2587
+ iconVariant: u("iconVariant", !0),
2588
+ style: u("style", !0),
2589
+ SnackbarProps: u("SnackbarProps", !0),
2590
+ className: qr(n.props.className, s.className)
2591
+ });
2592
+ return d.persist && (d.autoHideDuration = void 0), n.setState(function(e) {
2593
+ if (o === void 0 && n.props.preventDuplicate || o) {
2594
+ var t = function(e) {
2595
+ return c ? e.id === l : e.message === i;
2596
+ }, r = e.queue.findIndex(t) > -1, a = e.snacks.findIndex(t) > -1;
2597
+ if (r || a) return e;
2598
+ }
2599
+ return n.handleDisplaySnack($({}, e, { queue: [].concat(e.queue, [d]) }));
2600
+ }), l;
2601
+ }, n.handleDisplaySnack = function(e) {
2602
+ return e.snacks.length >= n.maxSnack ? n.handleDismissOldest(e) : n.processQueue(e);
2603
+ }, n.processQueue = function(e) {
2604
+ var t = e.queue, n = e.snacks;
2605
+ return t.length > 0 ? $({}, e, {
2606
+ snacks: [].concat(n, [t[0]]),
2607
+ queue: t.slice(1, t.length)
2608
+ }) : e;
2609
+ }, n.handleDismissOldest = function(e) {
2610
+ if (e.snacks.some(function(e) {
2611
+ return !e.open || e.requestClose;
2612
+ })) return e;
2613
+ var t = !1, r = !1;
2614
+ e.snacks.reduce(function(e, t) {
2615
+ return e + (t.open && t.persist ? 1 : 0);
2616
+ }, 0) === n.maxSnack && (r = !0);
2617
+ var i = e.snacks.map(function(e) {
2618
+ return t || e.persist && !r ? $({}, e) : (t = !0, e.entered ? (e.onClose && e.onClose(null, "maxsnack", e.id), n.props.onClose && n.props.onClose(null, "maxsnack", e.id), $({}, e, { open: !1 })) : $({}, e, { requestClose: !0 }));
2619
+ });
2620
+ return $({}, e, { snacks: i });
2621
+ }, n.handleEnteredSnack = function(e, t, r) {
2622
+ if (!pi(r)) throw Error("handleEnteredSnack Cannot be called with undefined key");
2623
+ n.setState(function(e) {
2624
+ return { snacks: e.snacks.map(function(e) {
2625
+ return e.id === r ? $({}, e, { entered: !0 }) : $({}, e);
2626
+ }) };
2627
+ });
2628
+ }, n.handleCloseSnack = function(e, t, r) {
2629
+ n.props.onClose && n.props.onClose(e, t, r);
2630
+ var i = r === void 0;
2631
+ n.setState(function(e) {
2632
+ var t = e.snacks, n = e.queue;
2633
+ return {
2634
+ snacks: t.map(function(e) {
2635
+ return i || e.id === r ? e.entered ? $({}, e, { open: !1 }) : $({}, e, { requestClose: !0 }) : $({}, e);
2636
+ }),
2637
+ queue: n.filter(function(e) {
2638
+ return e.id !== r;
2639
+ })
2640
+ };
2641
+ });
2642
+ }, n.closeSnackbar = function(e) {
2643
+ var t = n.state.snacks.find(function(t) {
2644
+ return t.id === e;
2645
+ });
2646
+ pi(e) && t && t.onClose && t.onClose(null, "instructed", e), n.handleCloseSnack(null, "instructed", e);
2647
+ }, n.handleExitedSnack = function(e, t) {
2648
+ if (!pi(t)) throw Error("handleExitedSnack Cannot be called with undefined key");
2649
+ n.setState(function(e) {
2650
+ var r = n.processQueue($({}, e, { snacks: e.snacks.filter(function(e) {
2651
+ return e.id !== t;
2652
+ }) }));
2653
+ return r.queue.length === 0 ? r : n.handleDismissOldest(r);
2654
+ });
2655
+ }, n.enqueueSnackbar, n.closeSnackbar, n.state = {
2656
+ snacks: [],
2657
+ queue: [],
2658
+ contextValue: {
2659
+ enqueueSnackbar: n.enqueueSnackbar.bind(oi(n)),
2660
+ closeSnackbar: n.closeSnackbar.bind(oi(n))
2661
+ }
2662
+ }, n;
2663
+ }
2664
+ return ii(t, e), t.prototype.render = function() {
2665
+ var e = this, t = this.state.contextValue, n = this.props, r = n.domRoot, i = n.children, a = n.dense, o = a !== void 0 && a, s = n.Components, c = s === void 0 ? {} : s, l = n.classes, u = this.state.snacks.reduce(function(e, t) {
2666
+ var n, r = fi(t.anchorOrigin), i = e[r] || [];
2667
+ return $({}, e, ((n = {})[r] = [].concat(i, [t]), n));
2668
+ }, {}), d = Object.keys(u).map(function(t) {
2669
+ var n = u[t], r = n[0];
2670
+ return Z.createElement(ua, {
2671
+ key: t,
2672
+ dense: o,
2673
+ anchorOrigin: r.anchorOrigin,
2674
+ classes: l
2675
+ }, n.map(function(t) {
2676
+ return Z.createElement(ia, {
2677
+ key: t.id,
2678
+ snack: t,
2679
+ classes: l,
2680
+ Component: c[t.variant],
2681
+ onClose: e.handleCloseSnack,
2682
+ onEnter: e.props.onEnter,
2683
+ onExit: e.props.onExit,
2684
+ onExited: Vi([e.handleExitedSnack, e.props.onExited], t.id),
2685
+ onEntered: Vi([e.handleEnteredSnack, e.props.onEntered], t.id)
2686
+ });
2687
+ }));
2688
+ });
2689
+ return Z.createElement(ci.Provider, { value: t }, i, r ? (0, dr.createPortal)(d, r) : d);
2690
+ }, ri(t, [{
2691
+ key: "maxSnack",
2692
+ get: function() {
2693
+ return this.props.maxSnack || ji.maxSnack;
2694
+ }
2695
+ }]), t;
2696
+ }(Z.Component), pa = function() {
2697
+ return (0, Z.useContext)(ci);
2698
+ }, ma = {
2699
+ card: "_card_h0jnt_7",
2700
+ actionRoot: "_actionRoot_h0jnt_11",
2701
+ icons: "_icons_h0jnt_16",
2702
+ expand: "_expand_h0jnt_22",
2703
+ expandOpen: "_expandOpen_h0jnt_29",
2704
+ stackTraceContainer: "_stackTraceContainer_h0jnt_33",
2705
+ paper: "_paper_h0jnt_37",
2706
+ checkIcon: "_checkIcon_h0jnt_42",
2707
+ button: "_button_h0jnt_47"
2708
+ }, ha = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
2709
+ let { id: n, message: r, iconVariant: a, error: o, hideIconVariant: s, ...c } = e, l = k(), { closeSnackbar: u } = pa(), [d, p] = (0, Z.useState)(!1), h = o ? i.collectErrorChain(o, !0)?.[0]?.error : void 0, g = h && !(h instanceof f), _ = (0, Z.useCallback)(() => {
2710
+ p((e) => !e);
2711
+ }, []), v = (0, Z.useCallback)(() => {
2712
+ u(n);
2713
+ }, [n, u]), y = h?.message;
2714
+ return !y && (0, Z.isValidElement)(r) && (y = r), y || typeof r != "string" || (y = r), y ||= `Unknown Error: ${r}`, (0, Q.jsx)(qi, {
2715
+ ref: t,
2716
+ className: M(ma.root, "error-snackbar"),
2717
+ children: (0, Q.jsxs)(er, {
2718
+ className: ma.card,
2719
+ style: {
2720
+ backgroundColor: "var(--sxl-color-error)",
2721
+ color: "var(--sxl-color-error-content)",
2722
+ border: "1px solid var(--sxl-color-error)"
2723
+ },
2724
+ children: [(0, Q.jsxs)(rr, {
2725
+ className: ma.actionRoot,
2726
+ children: [
2727
+ s ? null : a?.error,
2728
+ (0, Q.jsx)(H, {
2729
+ variant: "body2",
2730
+ component: "div",
2731
+ className: ma.typography,
2732
+ children: y
2733
+ }),
2734
+ (0, Q.jsx)("div", { style: { flex: "1 1 auto" } }),
2735
+ (0, Q.jsxs)("div", {
2736
+ className: ma.icons,
2737
+ children: [g ? (0, Q.jsx)($e, {
2738
+ "aria-label": l("toast.showMore"),
2739
+ size: "small",
2740
+ className: M(ma.expand, { [ma.expandOpen]: d }),
2741
+ onClick: _,
2742
+ children: (0, Q.jsx)(m, { iconKey: "ExpandMore" })
2743
+ }) : null, (0, Q.jsx)($e, {
2744
+ size: "small",
2745
+ className: ma.expand,
2746
+ onClick: v,
2747
+ children: (0, Q.jsx)(m, {
2748
+ iconKey: "Close",
2749
+ style: { transform: "scale(0.8)" }
2750
+ })
2751
+ })]
2752
+ })
2753
+ ]
2754
+ }), g ? (0, Q.jsx)(wn, {
2755
+ in: d,
2756
+ timeout: "auto",
2757
+ children: (0, Q.jsx)("div", {
2758
+ className: ma.stackTraceContainer,
2759
+ style: {
2760
+ backgroundColor: "color-mix(in srgb, var(--sxl-color-error) 90%, var(--sxl-color-base-100))",
2761
+ borderTop: "1px solid var(--sxl-color-error)"
2762
+ },
2763
+ children: (0, Q.jsx)(fn, {
2764
+ error: o,
2765
+ hideLineNumbers: !0
2766
+ })
2767
+ })
2768
+ }) : null]
2769
+ })
2770
+ });
2771
+ }));
2772
+ ha.displayName = "ToastError";
2773
+ var ga = (0, Q.jsx)(() => {
2774
+ let e = k();
2775
+ return (0, Q.jsx)(ot, {
2776
+ label: "SheetXL",
2777
+ description: e("logo.description"),
2778
+ children: (0, Q.jsx)(B, {
2779
+ component: "a",
2780
+ href: "https://www.sheetxl.com",
2781
+ target: "_blank",
2782
+ rel: "noopener noreferrer",
2783
+ sx: {
2784
+ display: "inline-flex",
2785
+ width: "24px",
2786
+ height: "24px",
2787
+ marginBottom: "4px",
2788
+ marginLeft: "6px",
2789
+ cursor: "pointer"
2790
+ },
2791
+ children: (0, Q.jsx)(pe, { style: {
2792
+ width: "24px",
2793
+ height: "24px"
2794
+ } })
2795
+ })
2796
+ });
2797
+ }, {}), _a = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
2798
+ let { workbook: n, className: r, logo: i = ga, mainElement: a, startElement: o, endElement: s, ...c } = e, [l, { width: u }] = j(), d = u < 530, f = (0, Z.useRef)(null), p = Ct([
2799
+ f,
2800
+ l,
2801
+ t
2802
+ ]);
2803
+ return (0, Q.jsx)(B, {
2804
+ ...c,
2805
+ ref: p,
2806
+ className: r,
2807
+ children: zt({
2808
+ isCompact: d,
2809
+ wrapperSelect: (e) => (0, Q.jsxs)(B, {
2810
+ sx: {
2811
+ display: "grid",
2812
+ gridTemplateColumns: "1fr auto 1fr",
2813
+ flex: "1",
2814
+ alignItems: "stretch",
2815
+ gap: (e) => e.spacing(1),
2816
+ paddingLeft: (e) => e.spacing(1),
2817
+ paddingRight: (e) => e.spacing(1)
2818
+ },
2819
+ children: [
2820
+ (0, Q.jsxs)(B, {
2821
+ sx: {
2822
+ display: "flex",
2823
+ flexDirection: "row",
2824
+ alignItems: "center",
2825
+ justifyContent: "start",
2826
+ gap: (e) => e.spacing(.5)
2827
+ },
2828
+ children: [i, (0, Q.jsxs)(B, {
2829
+ sx: {
2830
+ display: "flex",
2831
+ flexDirection: "row",
2832
+ alignItems: "center",
2833
+ gap: (e) => e.spacing(.25)
2834
+ },
2835
+ children: [o, e]
2836
+ })]
2837
+ }),
2838
+ (0, Q.jsx)(B, {
2839
+ sx: {
2840
+ display: "flex",
2841
+ flexDirection: "row",
2842
+ minWidth: 0,
2843
+ overflow: "hidden",
2844
+ alignItems: "center",
2845
+ justifyContent: "center"
2846
+ },
2847
+ children: a
2848
+ }),
2849
+ (0, Q.jsx)(B, {
2850
+ sx: {
2851
+ display: "flex",
2852
+ alignItems: "center",
2853
+ justifyContent: "end"
2854
+ },
2855
+ children: s
2856
+ })
2857
+ ]
2858
+ })
2859
+ })
2860
+ });
2861
+ }));
2862
+ _a.displayName = "StudioToolbar";
2863
+ var va = (e, t) => {
2864
+ let n = new URL(window.location.pathname, window.location.origin);
2865
+ e && n.searchParams.set("source", e), e && t && n.searchParams.set("title", t), window.open(n.toString(), "sheetxl-" + o.uuidV4(), "popup=true");
2866
+ }, ya = bn(p("studio:shortcutKeysDialog", () => import("./CRAzVh3CaAa16avf.mjs")).load);
2867
+ Jt(), Kt();
2868
+ var ba = /* @__PURE__ */ new Set(["ui"]), xa = (e) => {
2869
+ let t = (e) => {
2870
+ if (typeof e != "function") return e;
2871
+ try {
2872
+ return e();
2873
+ } catch {
2874
+ return;
2875
+ }
2876
+ }, n = (e, n) => {
2877
+ let r = t(e);
2878
+ return typeof r == "string" ? s(r, n, a.getActive()) : void 0;
2879
+ }, r = [];
2880
+ for (let i of e.names()) if (!ba.has(i)) for (let a of e.keys(i)) {
2881
+ let o = e.resolveDefinition(i, a);
2882
+ r.push({
2883
+ groupKey: i,
2884
+ command: {
2885
+ getLabel: () => n(o?.label, o?.params) ?? a,
2886
+ getIcon: () => t(o?.icon),
2887
+ getDescription: () => n(o?.description, o?.params) ?? "",
2888
+ getShortcut: () => t(o?.shortcut) ?? null,
2889
+ getScope: () => i,
2890
+ getScopeLabel: () => x.DefaultCommandCatalogService.getScopeLabel(i)
2891
+ }
2892
+ });
2893
+ }
2894
+ return { getAllCommands: () => r };
2895
+ }, Sa = (e) => {
2896
+ let { children: t, workbook: n, setWorkbook: r, workbookTitle: i, isDirty: o, refSave: s, fullscreenTarget: l } = e, f = x.useCommandScope(), p = _(), { showModal: m } = Cn(), h = k(), v = (0, Z.useRef)(o);
2897
+ v.current = o;
2898
+ let y = D(() => {
2899
+ let e = f?.getRoot().getRegistry();
2900
+ if (!e) return;
2901
+ let t = m(ya, {
2902
+ title: h("dialog.shortcutKeys.title"),
2903
+ commands: xa(e),
2904
+ onDone: () => t.hide(),
2905
+ onLoadError: (e) => {
2906
+ t.destroy(), p.showError(e);
2907
+ }
2908
+ });
2909
+ }, [f, m]);
2910
+ (0, Z.useEffect)(() => {
2911
+ if (!f) return;
2912
+ let e = f.getRoot().contribution();
2913
+ return function(e, t) {
2914
+ let n = () => t.showShortcuts();
2915
+ e.updateCommand("showKeyboardShortcuts", { callback: n }), e.updateCommand("help", { callback: n });
2916
+ for (let [t, n] of Object.entries({
2917
+ gotoUrlGithub: "https://github.com/sheetxl/sheetxl",
2918
+ gotoUrlDiscord: "https://discord.gg/NTKdwUgK9p",
2919
+ gotoUrlDocumentation: "https://www.sheetxl.com/docs",
2920
+ gotoUrlIssue: "https://github.com/sheetxl/sheetxl/issues"
2921
+ })) e.updateCommand(t, { callback: () => {
2922
+ window?.open(n);
2923
+ } });
2924
+ }(e, { showShortcuts: y }), () => e.remove();
2925
+ }, [f, y]);
2926
+ let b = gt("(prefers-color-scheme: dark)"), { themeMode: ee } = ie(), [w, te] = g(Re.Mode, Te[Re.Mode]), [T, E] = g(Re.DarkGrid, Te[Re.DarkGrid]), [O, A] = g(Re.DarkImages, Te[Re.DarkImages]);
2927
+ (0, Z.useEffect)(() => {
2928
+ if (!f) return;
2929
+ let e = f.getRoot().contribution();
2930
+ return function(e, t) {
2931
+ e.updateCommand("themeMode", {
2932
+ state: t.mode ?? null,
2933
+ params: { dark: t.isDark },
2934
+ icon: t.isDark ? "DarkMode" : "LightMode",
2935
+ callback: () => t.setMode(t.isDark ? "light" : "dark")
2936
+ }), e.updateCommand("defaultThemeMode", {
2937
+ state: !t.mode,
2938
+ icon: t.systemDefaultDark ? "SystemDefaultDarkMode" : "SystemDefaultLightMode",
2939
+ callback: () => t.setMode(null)
2940
+ }), e.updateCommand("enableDarkGrid", {
2941
+ state: t.enableDarkGrid,
2942
+ callback: () => t.setEnableDarkGrid((e) => !e)
2943
+ }), e.updateCommand("enableDarkImages", {
2944
+ state: t.enableDarkImages,
2945
+ callback: () => t.setEnableDarkImages((e) => !e)
2946
+ });
2947
+ }(e, {
2948
+ mode: w,
2949
+ setMode: te,
2950
+ isDark: w === "dark" || !w && ee === "dark",
2951
+ systemDefaultDark: b,
2952
+ enableDarkGrid: T,
2953
+ setEnableDarkGrid: E,
2954
+ enableDarkImages: O,
2955
+ setEnableDarkImages: A
2956
+ }), () => e.remove();
2957
+ }, [
2958
+ f,
2959
+ w,
2960
+ ee,
2961
+ b,
2962
+ T,
2963
+ O,
2964
+ te,
2965
+ E,
2966
+ A
2967
+ ]);
2968
+ let [j, ne] = g(S.Active, null), [ae, M] = (0, Z.useState)(() => a.getActive());
2969
+ (0, Z.useEffect)(() => a.addChangeListener(M), []), (0, Z.useEffect)(() => {
2970
+ j && j !== a.getActive() && a.setActive(j);
2971
+ }, [j]), (0, Z.useEffect)(() => {
2972
+ if (!f) return;
2973
+ let e = f.getRoot().contribution();
2974
+ return function(e, t) {
2975
+ e.updateCommand("language", {
2976
+ state: t.active,
2977
+ callback: (e) => {
2978
+ e && t.setActive(e);
2979
+ }
2980
+ });
2981
+ }(e, {
2982
+ active: ae,
2983
+ setActive: (e) => {
2984
+ ne(e);
2985
+ }
2986
+ }), () => e.remove();
2987
+ }, [
2988
+ f,
2989
+ ae,
2990
+ ne
2991
+ ]);
2992
+ let N = (0, Z.useMemo)(() => ({ current: l ?? null }), [l]), { isFullscreenAvailable: oe, isFullscreenEnabled: se, toggleFullscreen: ce } = re({ target: N });
2993
+ (0, Z.useEffect)(() => {
2994
+ if (!f) return;
2995
+ let e = f.getRoot().contribution();
2996
+ return function(e, t) {
2997
+ e.updateCommand("fullScreenToggle", {
2998
+ state: t.isFullscreenEnabled,
2999
+ disabledReasons: t.isFullscreenAvailable ? [] : [u("reason.fullscreenUnavailable")],
3000
+ icon: t.isFullscreenEnabled ? "FullScreenOff" : "FullScreen",
3001
+ callback: () => {
3002
+ t.toggleFullscreen();
3003
+ }
3004
+ });
3005
+ }(e, {
3006
+ isFullscreenAvailable: oe,
3007
+ isFullscreenEnabled: se,
3008
+ toggleFullscreen: ce
3009
+ }), () => e.remove();
3010
+ }, [
3011
+ f,
3012
+ oe,
3013
+ se,
3014
+ ce
3015
+ ]);
3016
+ let le = ye(!0);
3017
+ return (0, Z.useEffect)(() => {
3018
+ if (!f) return;
3019
+ let e = f.getRoot().contribution();
3020
+ return function(e) {
3021
+ e.updateCommand("protectWorkbook", {
3022
+ tags: ["noTransaction", "noRepeat"],
3023
+ callback: () => {
3024
+ ((e, t) => {
3025
+ le.activate(e, t);
3026
+ })("manageProtection", { args: { tab: "workbook" } });
3027
+ }
3028
+ });
3029
+ }(e), () => e.remove();
3030
+ }, [f, le]), (0, Z.useEffect)(() => {
3031
+ if (!f || !n) return;
3032
+ let e = f.getRoot().contribution(), t = function(e, t) {
3033
+ let { workbook: n, setWorkbook: r, workbookTitle: i = "export", isDirty: a, notifier: o, refSave: s } = t, l = !1, f = async (e = null, t = null, n = null) => {
3034
+ let r, i = [], a = {
3035
+ source: e && typeof e != "string" ? e : null,
3036
+ typedCreateWorkbookOptions: t ?? void 0,
3037
+ onPassword: async ({ origin: e, validate: t }) => {
3038
+ let n = await o.showInput({
3039
+ title: d("dialog.password.title"),
3040
+ description: d("dialog.password.open.description", { name: e.getName() ?? "" }),
3041
+ inputType: "password",
3042
+ options: [{
3043
+ id: "Open",
3044
+ label: () => d("dialog.open")
3045
+ }, "Cancel"],
3046
+ defaultOption: "Open",
3047
+ onValidateInput: async (e, n) => n === void 0 ? { valid: !0 } : e ? await t(e) ? { valid: !0 } : {
3048
+ valid: !1,
3049
+ message: d("dialog.password.open.retry")
3050
+ } : {
3051
+ valid: !1,
3052
+ message: d("dialog.password.open.required")
3053
+ }
3054
+ });
3055
+ return n?.option === "Open" ? n.input ?? null : null;
3056
+ },
3057
+ progress: { onWarning: (e) => {
3058
+ i.push(e);
3059
+ } }
3060
+ };
3061
+ n && (a.progress.onStart = n);
3062
+ let s = -5;
3063
+ return R.read({
3064
+ ...a,
3065
+ progress: {
3066
+ async onStart(e, t) {
3067
+ await a?.progress?.onStart?.(e, t), r = await o?.showBusy?.(d("workbook.opening", { name: e?.getName() ?? "" })), t && r?.setProgress?.(0, t);
3068
+ },
3069
+ onProgress(e, t) {
3070
+ if (!t) return;
3071
+ let n = Math.min(100, Math.round(e / t * 100));
3072
+ if (n >= 100) {
3073
+ if (s === 100) return;
3074
+ s = 100, r?.setProgress?.(e, t);
3075
+ } else n - s < 5 || (s = n, r?.setProgress?.(e, t));
3076
+ },
3077
+ onComplete() {
3078
+ r?.(), i.length > 0 && (o.showMessage(d("workbook.importWarnings")), console.warn("Import warnings:\n" + i.join("\n")));
3079
+ },
3080
+ onWarning(e, t) {
3081
+ a?.progress?.onWarning?.(e, t);
3082
+ }
3083
+ }
3084
+ });
3085
+ }, p = async (e, t, n = !1, r) => {
3086
+ let a, s, c = {
3087
+ format: t?.key,
3088
+ progress: {
3089
+ async onStart(e) {
3090
+ a = await o?.showBusy?.(d("workbook.saving", { name: e?.getName() ?? "" }));
3091
+ },
3092
+ onComplete() {
3093
+ a?.();
3094
+ }
3095
+ },
3096
+ onWarnings: r ?? (async ({ warnings: e, origin: t, canCancel: n }) => {
3097
+ a?.(), console.warn(`Not written to '${t.getName()}':\n${e.map((e) => ` ${e.message}`).join("\n")}`);
3098
+ let r = d("dialog.writeWarnings.title"), i = t.getFormat(), s = (i ? (await R.getWriteFormats({ search: i }))[0] : void 0)?.description ?? i ?? "", c = d("dialog.writeWarnings.keep");
3099
+ return n ? await o.showOptions({
3100
+ title: r,
3101
+ type: C.Warning,
3102
+ description: `${d("dialog.writeWarnings.confirm", { format: s })}\n\n${c}`,
3103
+ options: [{
3104
+ id: "Save",
3105
+ label: () => d("dialog.save")
3106
+ }, "Cancel"],
3107
+ defaultOption: "Cancel"
3108
+ }) === "Save" && (a = await o?.showBusy?.(d("workbook.saving", { name: t?.getName() ?? "" })), !0) : (o.showOptions({
3109
+ title: r,
3110
+ type: C.Warning,
3111
+ description: `${d("dialog.writeWarnings.saved", { format: s })}\n\n${c}`,
3112
+ options: ["Ok"]
3113
+ }), !0);
3114
+ })
3115
+ };
3116
+ if (n) {
3117
+ let n = e.getOrigin(), r = t?.exts?.[0] ?? (n.getExtension() || "sxl"), a = `${i || n.getName() || d("workbook.defaultName")}.${r}`;
3118
+ s = await R.writeAs(e, a, {
3119
+ ...c,
3120
+ prompt: !0
3121
+ });
3122
+ } else s = await R.write(e, void 0, c);
3123
+ return s;
3124
+ }, m = null;
3125
+ return e.updateCommand("newWorkbook", { callback: async (e) => {
3126
+ let t = R.canRead() && !a();
3127
+ e?.source ? t && m ? await m({
3128
+ url: e.source,
3129
+ title: e.title
3130
+ }) : va(e.source, e.title) : t ? r({}) : va();
3131
+ } }), e.updateCommand("closeWorkbook", { callback: async () => {
3132
+ a() && await o.showOptions({
3133
+ title: d("dialog.confirm.title"),
3134
+ description: d("dialog.unsavedChanges"),
3135
+ options: [{
3136
+ id: "Close",
3137
+ label: () => d("dialog.close")
3138
+ }, "Cancel"],
3139
+ defaultOption: "Cancel"
3140
+ }) !== "Close" || window.close();
3141
+ } }), (async () => {
3142
+ let t = await R.getWriteFormats();
3143
+ if (l) return;
3144
+ let i = R.canWrite(), h = R.canRead();
3145
+ if (i) {
3146
+ let r = (e) => {
3147
+ let r = e ? t.find((t) => t.key === e) : void 0;
3148
+ p(n, r, !0).catch((e) => o.showError(e));
3149
+ };
3150
+ e.updateCommand("saveWorkbook", { callback: () => {
3151
+ p(n, void 0, !1).catch((e) => o.showError(e));
3152
+ } }), s && (s.current = (e) => p(n, void 0, !1, e?.onWarnings)), e.updateCommand("saveWorkbookAs", { callback: (e) => {
3153
+ r(e);
3154
+ } });
3155
+ for (let n of t) {
3156
+ let t = n.key;
3157
+ e.updateCommand(`saveWorkbookAs${t}`, {
3158
+ label: () => d("command.saveAsFormat.label", { format: n.description }),
3159
+ groupLabels: {
3160
+ workbook: () => d("command.saveAsFormat.workbook", { format: n.description }),
3161
+ saveWorkbookOptions: () => d("command.saveAsFormat.compact", { format: n.description })
3162
+ },
3163
+ tags: n.tags,
3164
+ description: () => d("command.saveAsFormat", { format: n.description }),
3165
+ icon: t === "CSV" ? "FileDownloadAsCSV" : t === "Excel" ? "FileDownloadAsExcel" : "FileDownloadAsSheet",
3166
+ callback: () => {
3167
+ r(t);
3168
+ }
3169
+ });
3170
+ }
3171
+ }
3172
+ let g = async (e = null) => {
3173
+ let t = { csv: {
3174
+ date1904: n.getRuntime().isDate1904(),
3175
+ ...n.options
3176
+ } };
3177
+ try {
3178
+ let r = "", i = await f(e, t, async (e) => {
3179
+ r = e?.getName() ?? "";
3180
+ });
3181
+ if (!i) return;
3182
+ let a = i.getSheets().getItems();
3183
+ await n.doBatch(async () => {
3184
+ for (let e = 0; e < a.length; e++) {
3185
+ let t = a[e], i = a.length === 1 ? r : t.getName(), o = n.findValidSheetName(i);
3186
+ await n.getSheets().add({
3187
+ name: o,
3188
+ autoSelect: e === a.length - 1
3189
+ }).getEntireRange().copyFrom(t.getEntireRange());
3190
+ }
3191
+ }, u("op.importData")), i.close();
3192
+ } catch (e) {
3193
+ o.showError(e);
3194
+ }
3195
+ };
3196
+ if (e.updateCommand("insertDataFromFile", {
3197
+ tags: ["noTransaction", "noRepeat"],
3198
+ callback: async (e = null) => {
3199
+ let t = e;
3200
+ if (t || R.canRead() || (t = await (async () => {
3201
+ let e = await R.getReadFormats(), t = [...new Set(e.flatMap((e) => e.exts))].map((e) => `.${e}`);
3202
+ return c.openFileDialog(t.length ? t.join(",") : "*.*");
3203
+ })(), t)) return g(t);
3204
+ }
3205
+ }), e.updateCommand("insertDataFromURL", {
3206
+ tags: ["noTransaction", "noRepeat"],
3207
+ callback: async (e) => {
3208
+ if (!e) {
3209
+ let t = await o.showInput({
3210
+ title: d("dialog.importFromWeb.title"),
3211
+ description: d("dialog.importFromWeb.description"),
3212
+ inputLabel: d("dialog.webAddress.inputLabel"),
3213
+ initialValue: "https://www.sheetxl.com/docs/examples/financial-calculators.xlsx",
3214
+ propsInput: { style: { minWidth: "440px" } },
3215
+ options: [{
3216
+ id: "Import",
3217
+ label: () => d("dialog.import")
3218
+ }]
3219
+ });
3220
+ if (t.option !== "Import") return;
3221
+ e = t.input;
3222
+ }
3223
+ if (e) try {
3224
+ let t = await fetch(e);
3225
+ if (!t.ok) throw Error(`Could not fetch '${e}' (${t.status} ${t.statusText}).`);
3226
+ let n = await t.blob(), r = decodeURIComponent(e.split("/").pop()?.split("?")[0] || "") || "import.xlsx";
3227
+ await g(new File([n], r, { type: n.type }));
3228
+ } catch (e) {
3229
+ o.showError(e);
3230
+ }
3231
+ }
3232
+ }), h) {
3233
+ let t = async () => !a() || await o.showOptions({
3234
+ title: d("dialog.confirm.title"),
3235
+ description: d("dialog.unsavedChanges"),
3236
+ options: [{
3237
+ id: "Open",
3238
+ label: () => d("dialog.open")
3239
+ }, "Cancel"],
3240
+ defaultOption: "Cancel"
3241
+ }) === "Open", i = async (e = null) => {
3242
+ let t = { csv: {
3243
+ date1904: n.getRuntime().isDate1904(),
3244
+ ...n.options
3245
+ } };
3246
+ try {
3247
+ let n = await f(e, t);
3248
+ if (!n) return;
3249
+ r(n);
3250
+ } catch (e) {
3251
+ o.showError(e);
3252
+ }
3253
+ };
3254
+ e.updateCommand("openWorkbook", { callback: async (e = null) => {
3255
+ await t() && await i(e);
3256
+ } }), m = async (e) => {
3257
+ let n = typeof e == "string" ? e : e?.url, r = typeof e == "string" ? void 0 : e?.title;
3258
+ if (!n) {
3259
+ let e = await o.showInput({
3260
+ title: d("dialog.openFromWeb.title"),
3261
+ description: d("dialog.openFromWeb.description"),
3262
+ inputLabel: d("dialog.webAddress.inputLabel"),
3263
+ initialValue: "https://www.sheetxl.com/docs/examples/financial-calculators.xlsx",
3264
+ propsInput: { style: { minWidth: "440px" } },
3265
+ options: [{
3266
+ id: "Open",
3267
+ label: () => d("dialog.open")
3268
+ }]
3269
+ });
3270
+ if (e.option !== "Open") return;
3271
+ n = e.input;
3272
+ }
3273
+ if (n && await t()) try {
3274
+ let e = await fetch(n);
3275
+ if (!e.ok) throw Error(`Could not fetch '${n}' (${e.status} ${e.statusText}).`);
3276
+ let t = await e.blob(), a = decodeURIComponent(n.split("/").pop()?.split("?")[0] || "") || "workbook.xlsx", o = a.match(/\.[^/.]+$/)?.[0] ?? "", s = r ? `${r}${o}` : a;
3277
+ await i(new File([t], s, { type: t.type }));
3278
+ } catch (e) {
3279
+ o.showError(e);
3280
+ }
3281
+ }, e.updateCommand("openWorkbookFromUrl", { callback: m });
3282
+ }
3283
+ })(), () => {
3284
+ l = !0, s && (s.current = null);
3285
+ };
3286
+ }(e, {
3287
+ workbook: n,
3288
+ setWorkbook: r,
3289
+ workbookTitle: i ?? void 0,
3290
+ isDirty: () => v.current?.() ?? !1,
3291
+ notifier: p,
3292
+ refSave: s
3293
+ });
3294
+ return () => {
3295
+ t(), e.remove();
3296
+ };
3297
+ }, [
3298
+ f,
3299
+ n,
3300
+ r,
3301
+ i,
3302
+ p,
3303
+ s
3304
+ ]), t;
3305
+ };
3306
+ Sa.displayName = "StudioCommandProvider";
3307
+ var Ca = ({ renderWorkbook: e }) => {
3308
+ let t = x.useCommandResolver(), n = (0, Z.useRef)(null), r = k(), [i, a] = (0, Z.useState)(null), o = (0, Z.useCallback)((e) => {
3309
+ let n = e.dataTransfer;
3310
+ if (t && n) {
3311
+ if (e.type === "dragenter" || e.type === "dragover") {
3312
+ let e = n.types, t = n.items, r = !1;
3313
+ for (let e = 0; e < t.length; e++) if (t[e].type.startsWith("image/")) {
3314
+ r = !0;
3315
+ break;
3316
+ }
3317
+ r ? a("insertImage") : e.includes("Files") && t.length > 0 ? a("open") : (n.effectAllowed = "none", n.dropEffect = "none");
3318
+ } else if (e.type === "dragleave") {
3319
+ let t = e.relatedTarget;
3320
+ t && e.currentTarget.contains(t) || a(null);
3321
+ }
3322
+ e.preventDefault();
3323
+ }
3324
+ }, [t]), s = D((e) => {
3325
+ e.preventDefault();
3326
+ let r = i;
3327
+ if (a(null), r && t && (e.stopPropagation(), e.dataTransfer.files && e.dataTransfer.files.length > 0)) {
3328
+ let r = e.dataTransfer.files[0];
3329
+ if (!r) return;
3330
+ if (r?.type?.startsWith("image/")) {
3331
+ let i = n.current?.getSheetElement()?.getGridSurface().getPaneFromClient(e.clientX, e.clientY);
3332
+ if (!i) return;
3333
+ let a = i.getPanePointFromPointer(e.clientX, e.clientY);
3334
+ if (!a) return;
3335
+ let o = i.toAbsoluteBounds({
3336
+ x: a.x ?? 0,
3337
+ y: a.y ?? 0,
3338
+ width: 0,
3339
+ height: 0
3340
+ });
3341
+ t.execute("insertImageFromFile", {
3342
+ file: r,
3343
+ options: { bounds: {
3344
+ x: o.x,
3345
+ y: o.y
3346
+ } }
3347
+ });
3348
+ } else {
3349
+ if (!R.canRead()) return;
3350
+ let n = e.dataTransfer.items?.[0], i = typeof window < "u" && window.isSecureContext ? n?.getAsFileSystemHandle?.() : void 0;
3351
+ i ? i.then((e) => t.execute("openWorkbook", e?.kind === "file" ? e : r)).catch(() => t.execute("openWorkbook", r)) : t.execute("openWorkbook", r);
3352
+ }
3353
+ }
3354
+ }, [t, i]), c = (0, Z.useMemo)(() => {
3355
+ if (!i) return null;
3356
+ let e = i === "insertImage";
3357
+ return (0, Q.jsx)(B, {
3358
+ className: "drop-overlay",
3359
+ sx: {
3360
+ position: "absolute",
3361
+ inset: 0,
3362
+ zIndex: 1,
3363
+ boxSizing: "border-box",
3364
+ pointerEvents: "none",
3365
+ display: "flex",
3366
+ justifyContent: "center",
3367
+ alignItems: "center",
3368
+ backgroundColor: (e) => Ke(e.palette.primary.main, .46),
3369
+ outline: (e) => `2px dashed ${e.palette.primary.main}`,
3370
+ outlineOffset: "-6px",
3371
+ borderRadius: 2
3372
+ },
3373
+ children: (0, Q.jsxs)(Qe, {
3374
+ elevation: 6,
3375
+ sx: {
3376
+ display: "flex",
3377
+ alignItems: "center",
3378
+ gap: 1.5,
3379
+ px: 3,
3380
+ py: 2,
3381
+ borderRadius: 2,
3382
+ color: "text.primary",
3383
+ "& .drop-overlay-icon": { color: "primary.main" }
3384
+ },
3385
+ children: [(0, Q.jsx)(m, {
3386
+ iconKey: e ? "InsertImage" : "FileOpen",
3387
+ className: "drop-overlay-icon",
3388
+ size: 32
3389
+ }), (0, Q.jsx)(H, {
3390
+ variant: "h6",
3391
+ component: "span",
3392
+ children: r(e ? "drop.insertImage" : "drop.open")
3393
+ })]
3394
+ })
3395
+ });
3396
+ }, [i, r]);
3397
+ return (0, Q.jsxs)(Q.Fragment, { children: [e({
3398
+ ref: n,
3399
+ onDragStart: (e) => {
3400
+ if (e.target.src) {
3401
+ let t = new Image();
3402
+ t.src = e.target.src, e.dataTransfer.setDragImage(t, 1, 1);
3403
+ }
3404
+ },
3405
+ onDragEnter: o,
3406
+ onDragLeave: o,
3407
+ onDragOver: o,
3408
+ onDrop: s
3409
+ }), c] });
3410
+ }, wa = (0, Z.memo)((e) => {
3411
+ let { workbook: t, setWorkbook: n, refDocumentTitle: r, titleWorkbook: i, setWorkbookTitle: a, isDirty: o, initialCommandAnchor: s, renderWorkbook: c, refSave: l, host: u } = e;
3412
+ return (0, Q.jsx)(je, {
3413
+ initialAnchor: s,
3414
+ children: (0, Q.jsx)(Sa, {
3415
+ workbook: t,
3416
+ setWorkbook: n,
3417
+ workbookTitle: i,
3418
+ isDirty: o,
3419
+ refSave: l,
3420
+ fullscreenTarget: u,
3421
+ children: (0, Q.jsx)(Ca, { renderWorkbook: c })
3422
+ })
3423
+ });
3424
+ });
3425
+ wa.displayName = "CommandsWrapper";
3426
+ var Ta = {
3427
+ sort: p("studio:sortDialog", () => import("./DTn9oYyiIYgyijAk.mjs")).load,
3428
+ hyperlink: p("studio:hyperlinkDialog", () => import("./BeMLfv6hWo15VCIL.mjs")).load,
3429
+ find: p("studio:findReplaceWindow", () => import("./CaS8_J5HfBRk5_Nw.mjs")).load,
3430
+ tableNew: p("studio:tableNewDialog", () => import("./CCd192S7yVpc6iOe.mjs")).load,
3431
+ namedDetails: p("studio:namedReferenceDialog", () => import("./f1OJemsiZnbwnds-.mjs")).load,
3432
+ insertFunction: p("studio:insertFunctionDialog", () => import("./CqoHxlGpZ3yzPj5V.mjs")).load,
3433
+ resizeHeader: p("studio:resizeHeaderDialog", () => import("./DxwprgjYhcmfDbXH.mjs")).load,
3434
+ outlineSettings: p("studio:outlineSettingsDialog", () => import("./CvWGtHslTdesJik-.mjs")).load,
3435
+ fillSeries: p("studio:fillSeriesDialog", () => import("./CxCipDFamYSOctBo.mjs")).load,
3436
+ workbookStatistics: p("studio:workbookStatisticsDialog", () => import("./ByqhqEMBLrnkaPKE.mjs")).load,
3437
+ password: p("studio:passwordDialog", () => import("./index.mjs").then((e) => e.t).then((e) => e.t)).load
3438
+ }, Ea = ["find"], Da = (0, Z.memo)((e) => {
3439
+ let { children: t } = e, n = pa(), r = n ? n.enqueueSnackbar : () => {}, i = n ? n.closeSnackbar : () => {}, a = (0, Z.useRef)(/* @__PURE__ */ new Set()), s = (0, Z.useRef)(null), c = (0, Z.useRef)(null), [u, d] = (0, Z.useState)({
3440
+ label: null,
3441
+ progress: null
3442
+ }), f = k(), p = o.EmptyObject, h = vn(p), g = mn(p), _ = _n(p), y = (0, Z.useRef)(!1);
3443
+ (0, Z.useEffect)(() => {
3444
+ if (y.current) return;
3445
+ y.current = !0;
3446
+ let e = window, t = e.requestIdleCallback ?? ((e) => setTimeout(e, 500)), n = e.cancelIdleCallback ?? clearTimeout, r = t(() => {
3447
+ for (let e of Ea) h(e, Ta[e], { prewarm: !0 }).catch(() => {});
3448
+ });
3449
+ return () => n(r);
3450
+ }, []);
3451
+ let b = (0, Z.useRef)(/* @__PURE__ */ new Set()), x = (0, Z.useMemo)(() => {
3452
+ let e = (e, t) => {
3453
+ if (t?.onceKey) {
3454
+ if (b.current.has(t.onceKey)) return;
3455
+ let e = new Set(b.current);
3456
+ e.add(t.onceKey), b.current = e;
3457
+ }
3458
+ let n = {
3459
+ variant: t?.type ?? C.Info,
3460
+ anchorOrigin: {
3461
+ vertical: "top",
3462
+ horizontal: "center"
3463
+ },
3464
+ preventDuplicate: t?.preventDuplicate,
3465
+ persist: t?.persist ?? t?.type === C.Error,
3466
+ action: (e) => (0, Q.jsx)($e, {
3467
+ onClick: () => i(e),
3468
+ children: (0, Q.jsx)(m, { iconKey: "Cancel" })
3469
+ })
3470
+ };
3471
+ t?.enqueueProps && Object.assign(n, t.enqueueProps), e || console.log("message is 'null'", t), r(e ?? "Alert", n);
3472
+ }, t = {
3473
+ showMessage: e,
3474
+ showBusy: (e, t) => {
3475
+ let n = Symbol("busy");
3476
+ a.current.add(n), c.current = e, e != null && typeof e != "string" && d((t) => t.label === e ? t : {
3477
+ ...t,
3478
+ label: e
3479
+ });
3480
+ let r = te(() => {
3481
+ a.current.delete(n) && (a.current.size > 0 || (hn(s.current), c.current = null, d((e) => e.label === null && e.progress === null ? e : {
3482
+ label: null,
3483
+ progress: null
3484
+ })));
3485
+ }, (e, t) => {
3486
+ let n = t && t > 0 && e != null ? Math.max(0, Math.min(1, e / t)) : null;
3487
+ d((e) => e.progress === n ? e : {
3488
+ ...e,
3489
+ progress: n
3490
+ });
3491
+ }, (e) => {
3492
+ c.current = e, typeof e == "string" ? gn(s.current, e) : d((t) => ({
3493
+ ...t,
3494
+ label: e
3495
+ }));
3496
+ }), i = gn(s.current, typeof e == "string" ? e : void 0);
3497
+ return i ? i.then(() => r) : r;
3498
+ },
3499
+ showWindow: (e, t) => {
3500
+ let n = t;
3501
+ return t = {
3502
+ ...t,
3503
+ onKeyDown: (e) => {
3504
+ e.isDefaultPrevented() || e.isPropagationStopped() || n?.onKeyDown?.(e);
3505
+ }
3506
+ }, h(e, Ta[e], t);
3507
+ },
3508
+ showOptions: g,
3509
+ showInput: _,
3510
+ showError: (t) => {
3511
+ let n, r = C.Error, i = f("error.unknown");
3512
+ typeof t == "string" ? i = t : t instanceof Error && (n = t, t.message && (i = f(t.message))), t instanceof l && (r = C.Info), e(i, {
3513
+ type: r,
3514
+ enqueueProps: { error: n }
3515
+ });
3516
+ }
3517
+ }, n = new v();
3518
+ return n.setOverrides(t), n;
3519
+ }, [f]), S = (0, Z.useMemo)(() => (0, Q.jsx)(yn, {
3520
+ ref: s,
3521
+ autoStart: !1,
3522
+ icon: (0, Q.jsx)(pn, { sx: {
3523
+ transform: "scale(0.7)",
3524
+ marginLeft: "-6px"
3525
+ } }),
3526
+ panel: !0,
3527
+ label: u.label ?? (typeof c.current == "string" ? c.current : void 0),
3528
+ progress: u.progress,
3529
+ sx: {
3530
+ position: "absolute",
3531
+ left: "0",
3532
+ top: "0",
3533
+ width: "100%",
3534
+ height: "100%",
3535
+ zIndex: "9999",
3536
+ pointerEvents: "none"
3537
+ }
3538
+ }), [u.label, u.progress]);
3539
+ return (0, Q.jsxs)(O, {
3540
+ notifier: x,
3541
+ children: [S, t]
3542
+ });
3543
+ });
3544
+ Da.displayName = "StudioNotifierProvider";
3545
+ var Oa = "var(--sxl-color-input-border, light-dark(rgba(0, 0, 0, 0.2), rgba(255, 255, 255, 0.2)))", ka = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
3546
+ let { children: n, title: r, taskPanes: i, onSelect: a, selected: o, registry: s = _e, style: c, iconsOnly: l, side: u = "right", className: d, ...f } = e, p = u !== "right", h = y(), g = (0, Z.useMemo)(() => i.map((t) => {
3547
+ let n = s.getRegisteredTaskPane(t);
3548
+ if (!n) return null;
3549
+ let r = n.getIcon?.();
3550
+ typeof r == "string" && (r = (0, Q.jsx)(m, { iconKey: r }));
3551
+ let i = t === o, a = r ? (0, Q.jsx)(B, {
3552
+ sx: {
3553
+ display: "inline-block",
3554
+ transform: p ? "rotate(-90deg)" : "rotate(90deg)",
3555
+ transformOrigin: "center",
3556
+ color: (e) => e.palette.text.secondary
3557
+ },
3558
+ children: r
3559
+ }) : null, c = !r || !l && i, u = (0, Q.jsx)(B, {
3560
+ sx: {
3561
+ display: "grid",
3562
+ gridTemplateColumns: c ? "1fr" : "0fr",
3563
+ opacity: +!!c,
3564
+ transition: (e) => e.transitions.create(["grid-template-columns", "opacity"], { duration: e.transitions.duration.short })
3565
+ },
3566
+ children: (0, Q.jsx)(B, {
3567
+ sx: {
3568
+ overflow: "hidden",
3569
+ minWidth: 0,
3570
+ minHeight: 0
3571
+ },
3572
+ children: (0, Q.jsx)(H, {
3573
+ component: "div",
3574
+ sx: {
3575
+ textTransform: "none",
3576
+ whiteSpace: "nowrap",
3577
+ transform: p ? "rotate(180deg)" : void 0,
3578
+ padding: "4px 0px",
3579
+ color: (e) => i ? e.palette.primary.main : e.palette.text.secondary
3580
+ },
3581
+ children: n.getTitle()
3582
+ })
3583
+ })
3584
+ });
3585
+ return (0, Q.jsx)(Et, {
3586
+ value: t,
3587
+ label: (0, Q.jsx)(rt, {
3588
+ disableInteractive: !0,
3589
+ title: n.getTitle() ?? "",
3590
+ placement: "left-start",
3591
+ children: (0, Q.jsxs)(B, {
3592
+ sx: {
3593
+ padding: "0px 0px",
3594
+ writingMode: p ? "vertical-lr" : "vertical-rl",
3595
+ textOrientation: "mixed",
3596
+ display: "flex",
3597
+ alignItems: "center",
3598
+ justifyContent: "space-between",
3599
+ minWidth: "0px",
3600
+ color: (e) => e.palette.text.secondary
3601
+ },
3602
+ children: [p ? u : a, p ? a : u]
3603
+ })
3604
+ }),
3605
+ sx: {
3606
+ padding: "4px 4px",
3607
+ minWidth: "0px",
3608
+ minHeight: "0px",
3609
+ borderRadius: "4px"
3610
+ },
3611
+ className: M("taskpane-strip-item", { "Mui-selected": i }),
3612
+ onClick: () => e.onSelect(t)
3613
+ }, t);
3614
+ }), [
3615
+ i,
3616
+ o,
3617
+ a,
3618
+ s,
3619
+ p,
3620
+ l,
3621
+ h
3622
+ ]), _ = E(t, () => ({ isTaskPaneStrip: () => !0 }), []), v = (0, Z.useMemo)(() => M("taskpane-strip", d), [d]);
3623
+ return (0, Q.jsx)(B, {
3624
+ ref: _,
3625
+ className: v,
3626
+ sx: {
3627
+ paddingLeft: p ? void 0 : "2px",
3628
+ paddingRight: p ? "2px" : void 0,
3629
+ paddingTop: "4px",
3630
+ ...c
3631
+ },
3632
+ ...f,
3633
+ children: (0, Q.jsx)(St, {
3634
+ orientation: "vertical",
3635
+ variant: "scrollable",
3636
+ value: o,
3637
+ onChange: (e, t) => {
3638
+ a(t);
3639
+ },
3640
+ slotProps: {
3641
+ list: { sx: { gap: "2px" } },
3642
+ indicator: { sx: {
3643
+ left: p ? void 0 : "0px",
3644
+ right: p ? void 0 : "unset",
3645
+ bottom: p ? "0px" : void 0
3646
+ } }
3647
+ },
3648
+ children: g
3649
+ })
3650
+ });
3651
+ })), Aa = (e) => {
3652
+ let { title: t, icon: n, onClose: r, readOnly: i, focused: a, ...o } = e, s = (0, Z.useRef)(null), c = k();
3653
+ return (0, Q.jsx)(it, {
3654
+ className: M({ "Mui-selected": a }),
3655
+ sx: {
3656
+ display: "flex",
3657
+ flex: "1 1 %0",
3658
+ color: (e) => e.palette.text.secondary,
3659
+ boxSizing: "border-box",
3660
+ padding: "0 0",
3661
+ transitionProperty: "opacity",
3662
+ transitionDuration: (e) => `${e.transitions.duration.shortest}ms`,
3663
+ opacity: .7,
3664
+ "&.Mui-selected": {
3665
+ opacity: 1,
3666
+ transitionDuration: (e) => e.transitions.duration.shortest / 2 + "ms"
3667
+ },
3668
+ backgroundColor: (e) => Ke(e.palette.action.hover, .03),
3669
+ borderBottom: `solid ${Oa} 1px`
3670
+ },
3671
+ ...o,
3672
+ children: (0, Q.jsxs)(B, {
3673
+ sx: {
3674
+ display: "flex",
3675
+ flex: "1 1 10%",
3676
+ flexDirection: "row",
3677
+ alignItems: "center",
3678
+ marginTop: (e) => e.spacing(.25),
3679
+ marginBottom: (e) => e.spacing(.25),
3680
+ marginLeft: (e) => e.spacing(1),
3681
+ marginRight: (e) => e.spacing(1)
3682
+ },
3683
+ children: [(0, Q.jsx)(B, {
3684
+ sx: {
3685
+ flex: "1 1 100%",
3686
+ paddingLeft: (e) => e.spacing(1)
3687
+ },
3688
+ children: t
3689
+ }), (0, Q.jsx)(ot, {
3690
+ label: c("taskPane.close"),
3691
+ children: (0, Q.jsx)($e, {
3692
+ "aria-label": "close",
3693
+ sx: { color: (e) => e.palette.text.icon ?? e.palette.action.active },
3694
+ touchRippleRef: s,
3695
+ onPointerDown: (e) => {
3696
+ s.current?.start(e, { center: !1 }), e.stopPropagation(), e.preventDefault();
3697
+ },
3698
+ onPointerUp: () => {
3699
+ r();
3700
+ },
3701
+ children: (0, Q.jsx)(m, { iconKey: "Close" })
3702
+ })
3703
+ })]
3704
+ })
3705
+ });
3706
+ }, ja = (0, Z.forwardRef)((e, t) => {
3707
+ let { model: n, side: r, ...i } = e, a = Ye(), o = `solid ${Oa} 1px`, s = `${a.shape.borderRadius ?? 4}px`, c = `${a.spacing?.(.5) ?? 4}px`;
3708
+ return (0, Q.jsx)(me, {
3709
+ model: n,
3710
+ ref: t,
3711
+ propsFrame: { style: {
3712
+ border: o,
3713
+ borderRadius: s,
3714
+ marginBottom: c
3715
+ } },
3716
+ alwaysShowStrip: !0,
3717
+ componentTitle: Aa,
3718
+ componentStrip: ka,
3719
+ side: r,
3720
+ ...e,
3721
+ onOpen: () => {
3722
+ e?.onOpen?.();
3723
+ },
3724
+ onClose: () => {
3725
+ e?.onClose?.();
3726
+ },
3727
+ ...i
3728
+ });
3729
+ }), Ma = {}, Na = {
3730
+ flex: "1 1 100%",
3731
+ display: "flex",
3732
+ boxSizing: "border-box"
3733
+ }, Pa = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
3734
+ let n, r, { mainElement: i, sidebarElement: a, position: o, persistKey: s, onPositionChange: c, className: l, style: u, taskSide: d = "right", ...f } = e, [p, m] = g(s ?? null, Ma), h = Ye(), [_, { width: v }] = j(), y = v > 530 || v === 0, b = (0, Z.useRef)(null), x = null, S = 4, C = 13;
3735
+ y ? x = "m 3.6261898,11.36243 c 0,0.88365 -0.71627,1.59991 -1.59991,1.59991 -0.8836498,0 -1.60004965,-0.71626 -1.60004965,-1.59991 0,-0.88365 0.71639985,-1.6000508 1.60004965,-1.6000508 0.88364,0 1.59991,0.7164008 1.59991,1.6000508 m 0,-4.881294 c 0,0.88364 -0.71627,1.60004 -1.59991,1.60004 -0.8836498,0 -1.60004965,-0.7164 -1.60004965,-1.60004 0,-0.88365 0.71639985,-1.60005 1.60004965,-1.60005 0.88364,0 1.59991,0.7164 1.59991,1.60005 m 0,-4.881226 c 0,0.88365 -0.71627,1.60005 -1.59991,1.60005 C 1.14263,3.19996 0.42623015,2.48356 0.42623015,1.59991 0.42623015,0.71626 1.14263,0 2.0262798,0 c 0.88364,0 1.59991,0.71626 1.59991,1.59991" : (x = "M 1.59991,3.62619 C 0.71626,3.62619 0,2.90992 0,2.02628 0,1.1426301 0.71626,0.42623015 1.59991,0.42623015 c 0.88365,0 1.6000508,0.71639995 1.6000508,1.60004985 0,0.88364 -0.7164008,1.59991 -1.6000508,1.59991 m 4.881294,0 c -0.88364,0 -1.60004,-0.71627 -1.60004,-1.59991 0,-0.8836499 0.7164,-1.60004985 1.60004,-1.60004985 0.88365,0 1.60005,0.71639995 1.60005,1.60004985 0,0.88364 -0.7164,1.59991 -1.60005,1.59991 m 4.881226,0 c -0.88365,0 -1.60005,-0.71627 -1.60005,-1.59991 0,-0.8836499 0.7164,-1.60004985 1.60005,-1.60004985 0.88365,0 1.59991,0.71639995 1.59991,1.60004985 0,0.88364 -0.71626,1.59991 -1.59991,1.59991", S = 13, C = 4);
3736
+ let w, te = i, T = a, E = d !== "right", D = y ? "row" : "column", O = E && T ? "before" : "after", k = `${D}:${O}`, A = s ? p[k] : void 0, ne = A == null ? ((e, t) => {
3737
+ if (e == null) return "40%";
3738
+ if (typeof e == "number" || typeof e == "string") return e;
3739
+ let n = e[t];
3740
+ return n == null ? "40%" : `${n}%`;
3741
+ })(o, k) : `${A}%`, re = s || c ? (e) => {
3742
+ s && m((t) => ({
3743
+ ...t,
3744
+ [k]: e.percent
3745
+ })), c?.(e, {
3746
+ orientation: D,
3747
+ side: O,
3748
+ key: k
3749
+ });
3750
+ } : void 0;
3751
+ E && T ? (te = a, T = i, r = { style: {
3752
+ flexDirection: "column",
3753
+ boxSizing: "border-box",
3754
+ paddingRight: "2px"
3755
+ } }, n = {}, w = {
3756
+ fixedPane: "before",
3757
+ position: ne,
3758
+ minBefore: y ? "280px" : "120px",
3759
+ splitDirection: y ? "row" : "column"
3760
+ }) : (n = { style: {
3761
+ flexDirection: "column",
3762
+ marginRight: a ? void 0 : "6px"
3763
+ } }, r = { style: {
3764
+ marginLeft: y ? "0px" : "4px",
3765
+ marginRight: y ? "8px" : "4px"
3766
+ } }, w = {
3767
+ fixedPane: "after",
3768
+ position: ne,
3769
+ minAfter: y ? "280px" : "120px",
3770
+ splitDirection: y ? "row" : "column"
3771
+ });
3772
+ let ie = Ct([
3773
+ b,
3774
+ _,
3775
+ t
3776
+ ]);
3777
+ return (0, Q.jsx)(ee, {
3778
+ ref: ie,
3779
+ className: l,
3780
+ style: u ? {
3781
+ ...Na,
3782
+ ...u
3783
+ } : Na,
3784
+ ...f,
3785
+ ...w,
3786
+ onPositionChange: re,
3787
+ propsResizer: {
3788
+ className: M("styled-resizer", "_styled-resizer_fdl5y_3"),
3789
+ style: {
3790
+ minWidth: y ? "7px" : void 0,
3791
+ minHeight: y ? void 0 : "6px",
3792
+ maskImage: `url("data:image/svg+xml,%3Csvg width='${S}' height='${C}' viewBox='0 0 ${S} ${C}' version='1.1' fill='${h.palette.text.icon ?? h.palette.action.active}' xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg'%3E%3Cpath d='${x}' /%3E%3C/svg%3E%0A")`,
3793
+ maskRepeat: "no-repeat",
3794
+ maskPosition: E ? y ? "center center" : "bottom center" : y ? "left center" : "top center"
3795
+ }
3796
+ },
3797
+ elementBefore: te,
3798
+ propsPaneBefore: n,
3799
+ elementAfter: T,
3800
+ propsPaneAfter: r
3801
+ });
3802
+ }));
3803
+ Pa.displayName = "StudioSplitPane";
3804
+ var Fa = () => (0, Q.jsx)("div", { style: {
3805
+ flex: "none",
3806
+ height: 0,
3807
+ borderTop: "solid var(--sxl-color-base-border, light-dark(rgba(0, 0, 0, 0.26), rgba(255, 255, 255, 0.3))) 1px"
3808
+ } }), Ia = (e, t) => {
3809
+ let n = (e) => (0, Q.jsx)(Z.Fragment, { children: t[e] }, e);
3810
+ if (e === "bottom") {
3811
+ let e = t.statusBar && t.formulaBar ? (0, Q.jsx)(Fa, {}, "divider") : null;
3812
+ return [
3813
+ n("toolbar"),
3814
+ n("main"),
3815
+ n("statusBar"),
3816
+ e,
3817
+ n("formulaBar")
3818
+ ];
3819
+ }
3820
+ return [
3821
+ n("toolbar"),
3822
+ n("formulaBar"),
3823
+ n("main"),
3824
+ n("statusBar")
3825
+ ];
3826
+ }, La = F.BuiltInSelectorNames, Ra = {
3827
+ [La.Whole]: "FormulaMathTrig",
3828
+ [La.Number]: "IncreaseDecimal",
3829
+ [La.Date]: "FormulaDateTime",
3830
+ [La.DateTime]: "FormulaDateTime",
3831
+ [La.Time]: "FormulaDateTime",
3832
+ [La.TextLength]: "FormulaText"
3833
+ }, za = (e) => {
3834
+ let t = e.getCondition();
3835
+ if (!t) return "DataValidation";
3836
+ let n = t.toJSON();
3837
+ return n.operator === F.BuiltInOperatorNames.Expression ? "FormulaCustom" : n.selector || n.operator !== F.BuiltInOperatorNames.InSet ? typeof n.selector == "string" && Ra[n.selector] || "DataValidation" : "Menu";
3838
+ }, Ba = (0, Z.memo)(({ dataValidation: e, size: t = 28 }) => (N(e, "onAnyChange"), (0, Q.jsx)(J, {
3839
+ className: "sxl-dv-icon",
3840
+ sx: {
3841
+ width: "auto",
3842
+ minWidth: 1.7 * t + "px",
3843
+ height: `${t}px`
3844
+ },
3845
+ children: (0, Q.jsx)(m, {
3846
+ iconKey: za(e),
3847
+ size: Math.round(.6 * t),
3848
+ ariaHidden: !0
3849
+ })
3850
+ })));
3851
+ Ba.displayName = "DataValidationIcon";
3852
+ var Va = (e, t) => {
3853
+ let n = e.getCondition();
3854
+ if (!n) return t("dataValidation.anyValue");
3855
+ let r = n.toJSON();
3856
+ if (r.operator === F.BuiltInOperatorNames.Expression && typeof r.param == "string") return t("dataValidation.titleCustom", { formula: r.param });
3857
+ if (!r.selector && r.operator === F.BuiltInOperatorNames.InSet) {
3858
+ let e = r.param, n = e?.source;
3859
+ if (typeof n == "string" && n.length > 0) return t("dataValidation.titleListFrom", { source: n });
3860
+ let i = (e?.items ?? []).map((e) => String(e ?? "")).concat((e?.additions ?? []).map((e) => e.trimStart()));
3861
+ return t("dataValidation.titleList", {
3862
+ items: i.slice(0, 3).join(", "),
3863
+ more: Math.max(0, i.length - 3)
3864
+ });
3865
+ }
3866
+ return n.toString();
3867
+ }, Ha = {
3868
+ [I.AlertStyle.Stop]: "ValidationStop",
3869
+ [I.AlertStyle.Warning]: "ValidationWarning",
3870
+ [I.AlertStyle.Information]: "ValidationInformation"
3871
+ }, Ua = "none", Wa = {
3872
+ width: 18,
3873
+ height: 18,
3874
+ flex: "0 0 auto"
3875
+ }, Ga = {
3876
+ [I.AlertStyle.Stop]: u("dataValidation.alertStop"),
3877
+ [I.AlertStyle.Warning]: u("dataValidation.alertWarning"),
3878
+ [I.AlertStyle.Information]: u("dataValidation.alertInformation")
3879
+ }, Ka = (0, Z.memo)((e) => {
3880
+ let { dataValidation: t } = e, n = k();
3881
+ N(t, "onAnyChange");
3882
+ let r = t.isProtected(), i = t.getRenderHints().includes("list"), [a, o] = (0, Z.useState)("rule"), s = (0, Q.jsxs)(Qe, {
3883
+ tabIndex: 0,
3884
+ className: Zt["editor-panel"],
3885
+ sx: {
3886
+ gap: (e) => e.spacing(1),
3887
+ paddingTop: (e) => e.spacing(1.25),
3888
+ paddingBottom: (e) => e.spacing(2),
3889
+ paddingLeft: (e) => e.spacing(1.5),
3890
+ paddingRight: (e) => e.spacing(1.5),
3891
+ border: (e) => `1px solid ${e.palette.divider}`,
3892
+ borderRadius: (e) => e.spacing(1.25),
3893
+ overflow: "auto"
3894
+ },
3895
+ children: [
3896
+ (0, Q.jsxs)(B, {
3897
+ sx: {
3898
+ display: "flex",
3899
+ flexDirection: "column",
3900
+ gap: (e) => e.spacing(1.75),
3901
+ margin: (e) => e.spacing(1.25),
3902
+ marginBottom: 0
3903
+ },
3904
+ children: [(0, Q.jsxs)(B, {
3905
+ sx: {
3906
+ display: "flex",
3907
+ alignItems: "center",
3908
+ gap: (e) => e.spacing(1.5)
3909
+ },
3910
+ children: [(0, Q.jsx)(Ba, {
3911
+ dataValidation: t,
3912
+ size: 48
3913
+ }), (0, Q.jsx)(H, {
3914
+ variant: "body2",
3915
+ sx: {
3916
+ minWidth: 0,
3917
+ wordBreak: "break-word"
3918
+ },
3919
+ children: Va(t, n)
3920
+ })]
3921
+ }), (0, Q.jsx)(Gt, {
3922
+ item: t,
3923
+ label: n("dataValidation.applyTo")
3924
+ })]
3925
+ }),
3926
+ (0, Q.jsxs)(St, {
3927
+ value: a,
3928
+ onChange: (e, t) => o(t),
3929
+ sx: {
3930
+ minHeight: "36px",
3931
+ borderBottom: 1,
3932
+ borderColor: "divider",
3933
+ "& .MuiTab-root": {
3934
+ minHeight: "36px",
3935
+ textTransform: "none",
3936
+ pt: .5,
3937
+ pb: .5,
3938
+ px: 1.5,
3939
+ minWidth: 0
3940
+ }
3941
+ },
3942
+ children: [(0, Q.jsx)(Et, {
3943
+ value: "rule",
3944
+ label: n("dataValidation.tabRule")
3945
+ }), (0, Q.jsx)(Et, {
3946
+ value: "prompt",
3947
+ label: n("dataValidation.prompt")
3948
+ })]
3949
+ }),
3950
+ a === "prompt" ? (0, Q.jsxs)(B, {
3951
+ sx: {
3952
+ display: "flex",
3953
+ flexDirection: "column",
3954
+ gap: 2
3955
+ },
3956
+ children: [
3957
+ (0, Q.jsx)(sn, {
3958
+ control: (0, Q.jsx)(on, {
3959
+ checked: t.isShowPromptMessage(),
3960
+ disabled: r,
3961
+ onChange: (e) => t.setShowPromptMessage(e.target.checked)
3962
+ }),
3963
+ label: n("dataValidation.showPrompt"),
3964
+ sx: {
3965
+ ml: 0,
3966
+ pl: .5
3967
+ }
3968
+ }),
3969
+ (0, Q.jsx)(cn, {
3970
+ size: "small",
3971
+ label: n("dataValidation.title"),
3972
+ value: t.getPromptTitle(),
3973
+ onChange: (e) => t.setPromptTitle(e.target.value),
3974
+ disabled: r,
3975
+ fullWidth: !0,
3976
+ slotProps: { htmlInput: { maxLength: 32 } },
3977
+ sx: { backgroundColor: "background.paper" }
3978
+ }),
3979
+ (0, Q.jsx)(cn, {
3980
+ size: "small",
3981
+ label: n("dataValidation.message"),
3982
+ value: t.getPromptMessage(),
3983
+ onChange: (e) => t.setPromptMessage(e.target.value),
3984
+ disabled: r,
3985
+ multiline: !0,
3986
+ rows: 2,
3987
+ fullWidth: !0,
3988
+ slotProps: { htmlInput: { maxLength: 254 } },
3989
+ sx: { backgroundColor: "background.paper" }
3990
+ })
3991
+ ]
3992
+ }) : (0, Q.jsxs)(Q.Fragment, { children: [(0, Q.jsx)(wt, {
3993
+ sx: {
3994
+ ...yt,
3995
+ p: 2,
3996
+ pb: 0
3997
+ },
3998
+ selectorTitle: n("dataValidation.allow"),
3999
+ condition: t.getCondition(),
4000
+ ranges: t.getRanges(),
4001
+ readOnly: r,
4002
+ onConditionChange: (e) => {
4003
+ let n = !t.getCondition() && e ? {
4004
+ ...e,
4005
+ includeBlanks: !0
4006
+ } : e;
4007
+ t.setCondition(n);
4008
+ },
4009
+ qualifiers: i ? (0, Q.jsx)(sn, {
4010
+ control: (0, Q.jsx)(on, {
4011
+ size: "small",
4012
+ checked: !t.isHideDropdown(),
4013
+ disabled: r,
4014
+ onChange: (e) => t.setHideDropdown(!e.target.checked)
4015
+ }),
4016
+ label: n("dataValidation.inCellDropdown")
4017
+ }) : null
4018
+ }), (0, Q.jsxs)(B, {
4019
+ sx: {
4020
+ display: "flex",
4021
+ flexDirection: "column",
4022
+ gap: 2,
4023
+ p: 2,
4024
+ border: 1,
4025
+ borderColor: "divider",
4026
+ borderRadius: 1
4027
+ },
4028
+ children: [(0, Q.jsxs)(pt, {
4029
+ fullWidth: !0,
4030
+ size: "small",
4031
+ disabled: r,
4032
+ sx: { backgroundColor: "background.paper" },
4033
+ children: [(0, Q.jsx)(dt, { children: n("dataValidation.onInvalid") }), (0, Q.jsxs)(ft, {
4034
+ className: "on-invalid",
4035
+ value: t.isShowAlertMessage() ? t.getAlertStyle() : Ua,
4036
+ label: n("dataValidation.onInvalid"),
4037
+ onChange: (e) => {
4038
+ let n = e.target.value;
4039
+ n === Ua ? t.setShowAlertMessage(!1) : (t.setAlertStyle(n), t.setShowAlertMessage(!0));
4040
+ },
4041
+ renderValue: (e) => (0, Q.jsxs)(B, {
4042
+ sx: {
4043
+ display: "flex",
4044
+ alignItems: "center",
4045
+ gap: 1
4046
+ },
4047
+ children: [e === Ua ? (0, Q.jsx)(B, { sx: Wa }) : (0, Q.jsx)(m, {
4048
+ iconKey: Ha[e],
4049
+ size: 18,
4050
+ ariaHidden: !0
4051
+ }), n(e === Ua ? "dataValidation.alertNone" : Ga[e])]
4052
+ }),
4053
+ children: [Object.keys(Ha).map((e) => (0, Q.jsxs)(X, {
4054
+ value: e,
4055
+ sx: { gap: 1 },
4056
+ children: [(0, Q.jsx)(m, {
4057
+ iconKey: Ha[e],
4058
+ size: 18,
4059
+ ariaHidden: !0
4060
+ }), n(Ga[e])]
4061
+ }, e)), (0, Q.jsxs)(X, {
4062
+ value: Ua,
4063
+ sx: { gap: 1 },
4064
+ children: [(0, Q.jsx)(B, { sx: Wa }), n("dataValidation.alertNone")]
4065
+ }, Ua)]
4066
+ })]
4067
+ }), t.isShowAlertMessage() ? (0, Q.jsxs)(Q.Fragment, { children: [(0, Q.jsx)(cn, {
4068
+ size: "small",
4069
+ label: n("dataValidation.title"),
4070
+ value: t.getAlertTitle(),
4071
+ onChange: (e) => t.setAlertTitle(e.target.value),
4072
+ disabled: r,
4073
+ fullWidth: !0,
4074
+ slotProps: { htmlInput: { maxLength: 32 } },
4075
+ sx: { backgroundColor: "background.paper" }
4076
+ }), (0, Q.jsx)(cn, {
4077
+ size: "small",
4078
+ label: n("dataValidation.message"),
4079
+ value: t.getAlertMessage(),
4080
+ onChange: (e) => t.setAlertMessage(e.target.value),
4081
+ disabled: r,
4082
+ multiline: !0,
4083
+ rows: 2,
4084
+ fullWidth: !0,
4085
+ slotProps: { htmlInput: { maxLength: 225 } },
4086
+ sx: { backgroundColor: "background.paper" }
4087
+ })] }) : null]
4088
+ })] })
4089
+ ]
4090
+ });
4091
+ return (0, Q.jsx)(en.Provider, {
4092
+ value: t,
4093
+ children: s
4094
+ });
4095
+ });
4096
+ Ka.displayName = "DataValidationEditorPanel";
4097
+ var qa = ({ icon: e, title: t, children: n }) => (0, Q.jsxs)(B, {
4098
+ className: "validation-badge",
4099
+ title: t,
4100
+ "aria-label": t,
4101
+ sx: {
4102
+ display: "inline-flex",
4103
+ alignItems: "center",
4104
+ gap: .5,
4105
+ px: .75,
4106
+ py: .25,
4107
+ border: 1,
4108
+ borderColor: "divider",
4109
+ borderRadius: 1,
4110
+ color: "text.secondary"
4111
+ },
4112
+ children: [(0, Q.jsx)(m, {
4113
+ iconKey: e,
4114
+ size: 14,
4115
+ ariaHidden: !0
4116
+ }), n ? (0, Q.jsx)(H, {
4117
+ variant: "caption",
4118
+ children: n
4119
+ }) : null]
4120
+ }), Ja = {
4121
+ [I.AlertStyle.Stop]: "dataValidation.alertStop",
4122
+ [I.AlertStyle.Warning]: "dataValidation.alertWarning",
4123
+ [I.AlertStyle.Information]: "dataValidation.alertInformation"
4124
+ }, Ya = (0, Z.memo)(({ item: e }) => {
4125
+ let t = k();
4126
+ N(e, "onAnyChange");
4127
+ let n = [];
4128
+ if (e.isShowPromptMessage() && n.push((0, Q.jsx)(qa, {
4129
+ icon: "NoteInsert",
4130
+ title: t("dataValidation.prompt"),
4131
+ children: e.getPromptTitle() || null
4132
+ }, "prompt")), e.getCondition() && e.isShowAlertMessage()) {
4133
+ let r = e.getAlertStyle();
4134
+ n.push((0, Q.jsx)(qa, {
4135
+ icon: Ha[r],
4136
+ title: `${t("dataValidation.alert")}: ${t(Ja[r])}`
4137
+ }, "alert"));
4138
+ }
4139
+ return !e.isHideDropdown() && e.getRenderHints().includes("list") && n.push((0, Q.jsx)(qa, {
4140
+ icon: "ArrowDownOutline",
4141
+ title: t("dataValidation.inCellDropdown")
4142
+ }, "dropdown")), n.length === 0 ? null : (0, Q.jsx)(B, {
4143
+ sx: {
4144
+ display: "flex",
4145
+ flexWrap: "wrap",
4146
+ gap: .5
4147
+ },
4148
+ children: n
4149
+ });
4150
+ });
4151
+ Ya.displayName = "DataValidationCardBody";
4152
+ var Xa = (0, Z.memo)(({ item: e }) => {
4153
+ let t = k();
4154
+ return (0, Q.jsx)(Gt, {
4155
+ item: e,
4156
+ label: t("dataValidation.applyTo"),
4157
+ helperText: null
4158
+ });
4159
+ });
4160
+ Xa.displayName = "DataValidationCardRanges";
4161
+ var Za = {
4162
+ key: "data-validation",
4163
+ messageKeys: {
4164
+ none: u("dataValidation.none"),
4165
+ addPrompt: u("dataValidation.addPrompt"),
4166
+ heading: u("dataValidation.heading"),
4167
+ insert: u("dataValidation.insert"),
4168
+ new: u("dataValidation.new"),
4169
+ moveUp: u("dataValidation.moveUp"),
4170
+ moveDown: u("dataValidation.moveDown"),
4171
+ edit: u("dataValidation.edit"),
4172
+ duplicate: u("dataValidation.duplicate"),
4173
+ delete: u("dataValidation.delete"),
4174
+ cancel: u("dataValidation.cancel"),
4175
+ save: u("dataValidation.save")
4176
+ },
4177
+ getCollection: (e) => e.getDataValidations(),
4178
+ changeEvents: ["onDataValidationsChange"],
4179
+ isReadOnly: (e) => e.getProtection().isLocked() || e.getProtection().isReadOnly(),
4180
+ applyUpdate: (e, t) => {
4181
+ e.update(t);
4182
+ },
4183
+ validate: (e) => e.getCondition()?.validate() ?? null,
4184
+ applyNewDefaults: (e) => {
4185
+ e.update({
4186
+ alertStyle: I.AlertStyle.Stop,
4187
+ showAlertMessage: !0
4188
+ });
4189
+ },
4190
+ applySeed: (e, t) => {
4191
+ e.update(t);
4192
+ },
4193
+ getCardTitle: Va,
4194
+ CardMedia: ({ item: e }) => (0, Q.jsx)(Ba, {
4195
+ dataValidation: e,
4196
+ size: 32
4197
+ }),
4198
+ CardSubtitle: Xa,
4199
+ CardBody: Ya,
4200
+ EditorBody: ({ item: e }) => (0, Q.jsx)(Ka, { dataValidation: e })
4201
+ }, Qa = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
4202
+ let { workbook: n, args: r, ...i } = e;
4203
+ return (0, Q.jsx)($t, {
4204
+ ref: t,
4205
+ workbook: n,
4206
+ descriptor: Za,
4207
+ args: r,
4208
+ dragReorder: !0,
4209
+ ...i
4210
+ });
4211
+ }));
4212
+ Qa.displayName = "DataValidationDetailsPanel", Ft(), Ae("shape", {
4213
+ key: "changeShapeGallery",
4214
+ render: (e) => (0, Q.jsx)(Ut, {
4215
+ ...e,
4216
+ commandKey: "changeShape",
4217
+ excludeCategories: Gr
4218
+ })
4219
+ }, {
4220
+ order: -1,
4221
+ divider: "after"
4222
+ }), oe("shape", () => import("./CnWNviK4qlX2GVl6.mjs").then((e) => e.ShapeFormatPanel)), Ae("picture", {
4223
+ key: "changePictureOptions",
4224
+ defaultKey: "changePictureFromFile",
4225
+ members: ["changePictureFromFile", "changePictureFromURL"]
4226
+ }, {
4227
+ order: -1,
4228
+ divider: "after"
4229
+ }), Rt(), h.register("plugin-table", { icons: {} }), _e.registerTaskPane({
4230
+ key: "dataValidationDetails",
4231
+ getTitle: () => "Data Validation",
4232
+ getIcon: () => "DataValidation",
4233
+ component: (e) => {
4234
+ let { model: t, entryKey: n, frame: r, args: i, ref: a, ...o } = e;
4235
+ return (0, Q.jsx)(Qa, {
4236
+ ref: a,
4237
+ workbook: t,
4238
+ args: i,
4239
+ ...o
4240
+ });
4241
+ }
4242
+ }, !0), _e.registerTaskPane({
4243
+ key: "conditionalFormatDetails",
4244
+ getTitle: () => "Conditional Formatting",
4245
+ getIcon: () => "FormatPaint",
4246
+ component: (e) => {
4247
+ let { model: t, entryKey: n, frame: r, args: i, ref: a, ...o } = e;
4248
+ return (0, Q.jsx)(Wr, {
4249
+ ref: a,
4250
+ workbook: t,
4251
+ args: i,
4252
+ ...o
4253
+ });
4254
+ }
4255
+ }, !0), Wt(), Tt(), q(), It(), mt(), At();
4256
+ var $a = () => {
4257
+ let e, t, n = new Promise((n, r) => {
4258
+ e = n, t = r;
4259
+ }), r = {
4260
+ promise: n,
4261
+ settled: !1,
4262
+ resolve: (t) => {
4263
+ r.settled = !0, e(t);
4264
+ },
4265
+ reject: (e) => {
4266
+ r.settled = !0, t(e);
4267
+ }
4268
+ };
4269
+ return n.catch(() => {}), r;
4270
+ }, eo = (e, t) => {
4271
+ if (!e) return {};
4272
+ let { colorSchemes: n, ...r } = e, i = n?.[t ? "dark" : "light"];
4273
+ return i && typeof i == "object" ? o.deepMerge(r, i) : r;
4274
+ }, to = (0, Z.memo)((0, Z.forwardRef)((e, t) => {
4275
+ let { host: n, scopeClass: r, square: i, elevation: s, variant: c, onWorkbookLoad: l, prefetch: u, onDocumentError: d, renderDocumentError: f = Dt, propsDocumentError: p, propsTaskPaneArea: _, renderTaskPaneArea: v = no, taskPaneSide: y = "right", onKeyDown: C, workbook: ee, onWorkbookChange: te, logo: O, topLeft: k, topRight: j, muiTheme: re, tokens: M, cssBaseline: oe, autoFocus: se = !1, title: ce, onDirtyChange: le, propsDocumentTitle: P, renderDocumentLoading: F = tn, propsDocumentLoading: I, propsWorkbook: L, showFormulaBar: ue, propsFormulaBar: de, renderFormulaBar: fe, formulaBarPlacement: pe, manageVisualViewport: me = !0, editable: _e, showStatusBar: ve, propsStatusBar: ye, renderStatusBar: we, propsToolbar: Ee, renderToolbar: ke } = e, z = (0, Z.useRef)(null), Ae = (0, Z.useRef)(null), je = (0, Z.useRef)(null), Me = D(() => {
4276
+ je.current?.getNamedCollectionEditorElement?.()?.focus?.();
4277
+ }, []), Pe = ((e, t = typeof window > "u" ? "mouse" : ae.detectIt().primaryInput) => e === "top" || e === "bottom" ? e : t === "touch" ? "bottom" : "top")(pe), Ie = Pe === "bottom" && me, Le = T(Ie), Be = Le ? Math.max(0, Math.round(window.innerHeight - Le.height)) : 0, Ve = Le ? Math.round(Le.offsetTop) : 0, He = Le?.height;
4278
+ (0, Z.useEffect)(() => {
4279
+ Ie && He !== void 0 && (window.scrollX === 0 && window.scrollY === 0 || window.scrollTo(0, 0));
4280
+ }, [Ie, He]);
4281
+ let Ue = D(d ?? (() => {}), [d]), We = D(le ?? (() => {}), [le]), Ge = P?.placeHolder, [Ke] = g(Re.Mode, Te[Re.Mode]), { themeMode: qe } = ie({ mode: Ke ?? void 0 }), [Je] = g(S.Active, null), Ye = (0, Z.useRef)(Je);
4282
+ Ye.current = Je;
4283
+ let Xe = w(), V = (0, Z.useMemo)(() => ({
4284
+ light: tt(!1, o.deepMerge(eo(re, !1), jt(Xe?.light))),
4285
+ dark: tt(!0, o.deepMerge(eo(re, !0), jt(Xe?.dark)))
4286
+ }), [
4287
+ re,
4288
+ Xe?.light,
4289
+ Xe?.dark
4290
+ ]), Ze = qe === "dark", $e = (0, Z.useMemo)(() => ht(V.light, V.dark, `.${r}`, M), [
4291
+ V,
4292
+ r,
4293
+ M
4294
+ ]), nt = (0, Z.useMemo)(() => Se("sxl-defaults", `.${r}`), [r]), rt = he(), [it, at] = (0, Z.useState)(() => ee ?? null);
4295
+ (0, Z.useEffect)(() => {
4296
+ at(ee ?? null);
4297
+ }, [ee]);
4298
+ let [ot, H] = (0, Z.useState)(0), st = (0, Z.useRef)(null);
4299
+ st.current ||= $a();
4300
+ let U = Fe(it, {
4301
+ io: R,
4302
+ defaultTheme: rt.getDefaultTheme(),
4303
+ reloadKey: ot
4304
+ }), W = U.status === "loaded" ? U.workbook : null, G = (0, Z.useMemo)(() => U.status === "error" ? {
4305
+ status: "error",
4306
+ error: U.error
4307
+ } : U.status === "loaded" ? {
4308
+ status: "loaded",
4309
+ workbook: U.workbook
4310
+ } : { status: "loading" }, [U]);
4311
+ (0, Z.useEffect)(() => {
4312
+ st.current.settled && (st.current = $a());
4313
+ }, [it, ot]), (0, Z.useEffect)(() => {
4314
+ G.status === "loaded" ? st.current.resolve(G.workbook) : G.status === "error" && (Ue?.(G.error), st.current.reject(G.error));
4315
+ }, [G]);
4316
+ let [K, ct] = (0, Z.useState)(null);
4317
+ W && !K && ct(W);
4318
+ let lt = W && K && W !== K ? W : null, ut = (0, Z.useRef)(lt);
4319
+ ut.current = lt;
4320
+ let dt = (0, Z.useRef)(K);
4321
+ dt.current = K;
4322
+ let ft = (0, Z.useRef)([]), pt = (0, Z.useCallback)((e) => {
4323
+ let t = dt.current;
4324
+ t && ft.current.push(t), at(e);
4325
+ }, []);
4326
+ (0, Z.useEffect)(() => {
4327
+ let e = ft.current;
4328
+ if (e.length !== 0) {
4329
+ ft.current = e.filter((e) => e === K);
4330
+ for (let t = 0; t < e.length; t++) {
4331
+ let n = e[t];
4332
+ if (n !== K) try {
4333
+ n.close();
4334
+ } catch (e) {
4335
+ console.warn("Unable to close the replaced workbook", e);
4336
+ }
4337
+ }
4338
+ }
4339
+ }, [K]);
4340
+ let mt = _e ? null : K, gt = Ce(), _t = (0, Z.useMemo)(() => mt ? ze(mt.getSelectedSheet(), { referenceMode: gt }) : null, [mt, gt]), q = _e ?? _t, J = (0, Z.useRef)(q);
4341
+ J.current = q, (0, Z.useEffect)(() => {
4342
+ if (!q) return;
4343
+ let e = q.getSession();
4344
+ return q.subscribe(() => {
4345
+ let t = e;
4346
+ e = q.getSession(), t && !e && t.getActiveEditorId() === "formula-bar" && je.current?.contains?.(document.activeElement) && z.current?.focus();
4347
+ });
4348
+ }, [q]);
4349
+ let yt = Oe(K), { isDirty: bt, saveState: Y } = De(K, R), St = Ne(K), Ct = (0, Z.useRef)(Y), wt = (0, Z.useRef)(null);
4350
+ Ct.current = Y;
4351
+ let Tt = (0, Z.useCallback)(() => Ct.current?.isDirty() ?? !1, []), Et = (0, Z.useRef)(G);
4352
+ Et.current = G;
4353
+ let [kt, At] = (0, Z.useState)(null), Mt = ce ?? P?.title, [Nt, Ft] = (0, Z.useState)(null);
4354
+ (0, Z.useEffect)(() => {
4355
+ Ft(null);
4356
+ }, [K]);
4357
+ let It = Mt ?? Nt ?? yt ?? "";
4358
+ (0, Z.useEffect)(() => {
4359
+ We?.(bt);
4360
+ }, [bt]);
4361
+ let Lt = D(te ?? (() => {}), [te]);
4362
+ (0, Z.useEffect)(() => {
4363
+ Lt?.(W);
4364
+ }, [W]);
4365
+ let Rt = (0, Z.useRef)(W);
4366
+ Rt.current = W, N(K, "onViewChange");
4367
+ let zt = (0, Z.useMemo)(() => (0, Q.jsx)(ln, {
4368
+ groupKey: "helpOptions",
4369
+ disableHover: !0,
4370
+ sx: { padding: "0" },
4371
+ propsButton: { sx: { maxHeight: "22px" } }
4372
+ }), []), [Bt, Vt] = (0, Z.useState)(null), Ht = (0, Z.useCallback)((e) => {
4373
+ Vt(e);
4374
+ }, []);
4375
+ (0, Z.useEffect)(() => {
4376
+ h.prefetch().catch((e) => {
4377
+ console.warn("Icons could not be loaded:", e);
4378
+ });
4379
+ }, []);
4380
+ let Ut = (0, Z.useRef)(null);
4381
+ Ut.current ||= $a();
4382
+ let Wt = (0, Z.useRef)(null), Gt = (0, Z.useCallback)(() => Wt.current?.getSheetElement()?.getGridSurface()?.getPane()?.getElement() ?? Ut.current.promise, []), Kt = D(async (e) => {
4383
+ let t = Ye.current;
4384
+ t && t !== a.getActive() && await a.setActive(t), await x.DefaultCommandCatalogService.prefetch(t ?? void 0), At(e), Wt.current = e.source, Ut.current.settled || Ut.current.resolve(e.source.getSheetElement()?.getGridSurface()?.getPane()?.getElement() ?? null), l?.(e);
4385
+ }, []), qt = (0, Z.useRef)(null), Jt = (0, Z.useCallback)((e) => {
4386
+ let t = null, n = {
4387
+ readOnly: !0,
4388
+ ...P
4389
+ };
4390
+ return P?.hidden || (t = (0, Q.jsx)(vt, {
4391
+ ...n,
4392
+ style: {
4393
+ maxWidth: "100%",
4394
+ ...P?.style
4395
+ },
4396
+ workbook: e.workbook ?? z.current,
4397
+ ref: qt,
4398
+ title: It,
4399
+ modified: bt,
4400
+ encrypted: St,
4401
+ placeHolder: Ge,
4402
+ onTitleChange: (e) => {
4403
+ Ft(e), P?.onTitleChange?.(e);
4404
+ }
4405
+ })), (0, Q.jsx)(_a, {
4406
+ ...e,
4407
+ logo: O,
4408
+ mainElement: t,
4409
+ startElement: k,
4410
+ endElement: j
4411
+ });
4412
+ }, [
4413
+ O,
4414
+ It,
4415
+ bt,
4416
+ St,
4417
+ P,
4418
+ k,
4419
+ j
4420
+ ]);
4421
+ (0, Z.useEffect)(() => {
4422
+ let e = z.current;
4423
+ if (!e) return;
4424
+ let t = (t) => {
4425
+ (t.ctrlKey || t.metaKey || ne.getWheelOwner(t, e) !== "native") && t.preventDefault();
4426
+ };
4427
+ return e.addEventListener("wheel", t, { passive: !1 }), () => {
4428
+ e.removeEventListener("wheel", t);
4429
+ };
4430
+ }, [kt]);
4431
+ let [Yt, Xt] = (0, Z.useState)(null);
4432
+ (0, Z.useEffect)(() => {
4433
+ Xt(kt?.source?.getCommandScope?.() ?? null);
4434
+ }, [kt]);
4435
+ let Zt = (0, Z.useMemo)(() => ({
4436
+ "& .SnackbarContainer-root": { position: "absolute !important" },
4437
+ "& .notistack-SnackbarContainer > div": { maxWidth: "min(100%, 720px)" },
4438
+ "& .notistack-Snackbar": { minWidth: "unset" },
4439
+ "& .notistack-Snackbar > .error-snackbar .MuiTypography-root": { color: (e) => e.palette.getContrastText(e.palette.error.main) },
4440
+ "& .notistack-Snackbar > .error-snackbar .MuiCardActions-root": { color: (e) => e.palette.getContrastText(e.palette.error.main) },
4441
+ "& .notistack-Snackbar > .error-snackbar .MuiButtonBase-root": { color: (e) => e.palette.getContrastText(e.palette.error.main) },
4442
+ "& .notistack-MuiContent *": { fontFamily: (e) => e.typography.fontFamily },
4443
+ "& #notistack-snackbar": {
4444
+ maxWidth: "560px",
4445
+ whiteSpace: "pre-wrap"
4446
+ },
4447
+ "*": { userSelect: "none" }
4448
+ }), []), [Qt, $t] = (0, Z.useState)(null), [, en] = g(null, !1);
4449
+ (0, Z.useEffect)(() => {
4450
+ en(Qt != null);
4451
+ }, [Qt, en]);
4452
+ let rn = (0, Z.useCallback)((e) => v({
4453
+ model: K,
4454
+ side: y,
4455
+ ...e,
4456
+ ..._
4457
+ }), [
4458
+ K,
4459
+ y,
4460
+ _
4461
+ ]), an = (0, Z.useRef)(n);
4462
+ an.current = n, E(t, () => ({
4463
+ isStudioElement: () => !0,
4464
+ save: (e) => {
4465
+ let t = wt.current;
4466
+ return t ? t(e) : Promise.reject(Error("The studio cannot save: no workbook, or the backing store cannot write."));
4467
+ },
4468
+ getWorkbookElement: () => z.current,
4469
+ getWorkbook: () => Rt.current ?? null,
4470
+ isDirty: () => Ct.current?.isDirty() ?? !1,
4471
+ getEditable: () => J.current,
4472
+ getFormulaBarElement: () => je.current ?? null,
4473
+ focus: () => z.current?.focus(),
4474
+ whenReady: () => (st.current ||= $a(), st.current.promise),
4475
+ getWorkbookState: () => Et.current,
4476
+ retry: () => H((e) => e + 1)
4477
+ }), [], n);
4478
+ let on = (0, Z.useRef)(!1), sn = D((e, t) => {
4479
+ t === ut.current && requestAnimationFrame(() => requestAnimationFrame(() => {
4480
+ t === ut.current && (on.current = an.current?.contains(document.activeElement) ?? !0, ct(t), Kt(e));
4481
+ }));
4482
+ }, []);
4483
+ (0, Z.useEffect)(() => {
4484
+ on.current && (on.current = !1, z.current?.focus());
4485
+ }, [K]);
4486
+ let cn = (0, Z.useCallback)(() => (0, Q.jsx)(Q.Fragment, {}), []), dn = (0, Z.useCallback)((e) => {
4487
+ let { ref: t, ...n } = e, r = Ze ? V.dark : V.light, a = G.status === "error" ? f({
4488
+ ...p,
4489
+ style: {
4490
+ width: "100%",
4491
+ height: "100%",
4492
+ ...p?.style
4493
+ },
4494
+ error: G.error
4495
+ }) : null;
4496
+ if (a && !K) return (0, Q.jsx)(Qe, {
4497
+ style: {
4498
+ width: "100%",
4499
+ height: "100%",
4500
+ position: "absolute",
4501
+ display: "flex",
4502
+ alignItems: "stretch",
4503
+ justifyContent: "stretch"
4504
+ },
4505
+ children: a
4506
+ });
4507
+ let o = null;
4508
+ if (K) {
4509
+ let e = K, i = e.getView(), a = ue ?? i?.isShowFormulaBar(), s = ve ?? i?.isShowStatusBar(), c = kt?.source ?? z.current, l = (ke ?? Jt)({
4510
+ workbook: c,
4511
+ ...Ee
4512
+ }), d = Pe === "bottom", f = a ? (fe ?? Pt)({
4513
+ ref: je,
4514
+ style: {
4515
+ marginTop: r.spacing(d ? .5 : .25),
4516
+ marginLeft: r.spacing(1),
4517
+ marginRight: r.spacing(1),
4518
+ marginBottom: r.spacing(d ? .5 : .75)
4519
+ },
4520
+ workbook: e,
4521
+ editable: q ?? void 0,
4522
+ placement: Pe,
4523
+ ...de,
4524
+ propsNamedCollectionEditor: {
4525
+ restoreFocus: (e) => c?.focus(e),
4526
+ ...de?.propsNamedCollectionEditor
4527
+ }
4528
+ }) : null, p = s ? (we ?? nn)({
4529
+ childrenEnd: zt,
4530
+ ...ye
4531
+ }) : null, m = (e, r) => (0, Q.jsx)(xt, {
4532
+ ...L,
4533
+ tabIndex: 0,
4534
+ autoFocus: !r && se,
4535
+ workbook: e,
4536
+ editable: r ? void 0 : q ?? void 0,
4537
+ focusNameBox: r ? void 0 : Me,
4538
+ prefetch: !r && u,
4539
+ ref: r ? Ae : Ot([t, z]),
4540
+ onWorkbookLoad: r ? (t) => sn(t, e) : Kt,
4541
+ onKeyDown: (e) => {
4542
+ C?.(e);
4543
+ },
4544
+ propsWorkbookLoading: I,
4545
+ renderWorkbookLoading: cn,
4546
+ style: r ? {
4547
+ ...L?.style,
4548
+ position: "absolute",
4549
+ inset: 0,
4550
+ visibility: "hidden"
4551
+ } : {
4552
+ flex: "1 1 100%",
4553
+ minHeight: 0,
4554
+ ...L?.style
4555
+ },
4556
+ onContextMenu: (e) => e.preventDefault(),
4557
+ ...r ? null : n
4558
+ }, e.getId());
4559
+ o = (0, Q.jsx)("div", {
4560
+ style: {
4561
+ display: "flex",
4562
+ flexDirection: "column",
4563
+ flex: "1 1 100%",
4564
+ minWidth: 0,
4565
+ minHeight: 0,
4566
+ ...xe({
4567
+ window: r.palette.background.default,
4568
+ windowText: r.palette.text.primary
4569
+ })
4570
+ },
4571
+ children: Ia(Pe, {
4572
+ toolbar: l,
4573
+ formulaBar: f,
4574
+ statusBar: p,
4575
+ main: (0, Q.jsx)(Pa, {
4576
+ taskSide: y,
4577
+ persistKey: "taskPanePosition",
4578
+ sidebarElement: Qt ? (0, Q.jsx)(x.CommandScopeProvider, {
4579
+ scope: Yt,
4580
+ children: Qt
4581
+ }) : void 0,
4582
+ mainElement: (0, Q.jsxs)("div", {
4583
+ style: {
4584
+ position: "relative",
4585
+ display: "flex",
4586
+ flexDirection: "column",
4587
+ flex: "1 1 100%",
4588
+ minWidth: 0,
4589
+ minHeight: 0
4590
+ },
4591
+ children: [[m(K, !1), lt ? m(lt, !0) : null], (0, Q.jsx)(B, {
4592
+ ref: Ht,
4593
+ sx: {
4594
+ position: "absolute",
4595
+ top: "10%",
4596
+ left: 0,
4597
+ right: 0,
4598
+ bottom: 0,
4599
+ pointerEvents: "none",
4600
+ "& > :first-of-type": { position: "relative" }
4601
+ }
4602
+ })]
4603
+ })
4604
+ })
4605
+ })
4606
+ });
4607
+ }
4608
+ let l = kt ? null : F({ ...I });
4609
+ return (0, Q.jsxs)(Qe, {
4610
+ sx: Zt,
4611
+ style: {
4612
+ width: "100%",
4613
+ height: Be ? `calc(100% - ${Be}px)` : "100%",
4614
+ transform: Ve ? `translateY(${Ve}px)` : void 0,
4615
+ overscrollBehavior: Ie ? "none" : void 0,
4616
+ position: "absolute",
4617
+ display: "flex",
4618
+ alignItems: "stretch",
4619
+ justifyContent: "stretch",
4620
+ backgroundColor: "var(--sxl-color-base-200)"
4621
+ },
4622
+ className: "eager-studio",
4623
+ square: i,
4624
+ elevation: s,
4625
+ variant: c,
4626
+ children: [
4627
+ o,
4628
+ a ? (0, Q.jsx)(Qe, {
4629
+ style: {
4630
+ position: "absolute",
4631
+ inset: 0,
4632
+ display: "flex",
4633
+ alignItems: "stretch",
4634
+ justifyContent: "stretch"
4635
+ },
4636
+ children: a
4637
+ }) : null,
4638
+ l ? (0, Q.jsx)("div", {
4639
+ style: {
4640
+ position: "absolute",
4641
+ inset: 0,
4642
+ display: "flex",
4643
+ alignItems: "center",
4644
+ justifyContent: "center",
4645
+ background: `var(--sxl-color-base-100, ${Ze ? "#121212" : "#fff"})`
4646
+ },
4647
+ children: l
4648
+ }) : null
4649
+ ]
4650
+ });
4651
+ }, [
4652
+ G,
4653
+ K,
4654
+ lt,
4655
+ kt,
4656
+ It,
4657
+ F,
4658
+ I,
4659
+ cn,
4660
+ L,
4661
+ i,
4662
+ s,
4663
+ c,
4664
+ zt,
4665
+ f,
4666
+ p,
4667
+ Jt,
4668
+ Zt,
4669
+ Qt,
4670
+ y,
4671
+ Yt,
4672
+ ue,
4673
+ de,
4674
+ fe,
4675
+ Pe,
4676
+ q,
4677
+ ve,
4678
+ ye,
4679
+ we,
4680
+ Ee,
4681
+ ke,
4682
+ Ie,
4683
+ Be,
4684
+ Ve,
4685
+ V,
4686
+ Ze
4687
+ ]), fn = (0, Q.jsx)(fa, {
4688
+ maxSnack: 3,
4689
+ domRoot: Bt ?? void 0,
4690
+ anchorOrigin: {
4691
+ vertical: "bottom",
4692
+ horizontal: "right"
4693
+ },
4694
+ autoHideDuration: 3500,
4695
+ onClose: (e, t, n) => {
4696
+ z.current?.focus();
4697
+ },
4698
+ Components: { error: ha },
4699
+ iconVariant: {
4700
+ success: (0, Q.jsx)(et, {
4701
+ style: { marginRight: "8px" },
4702
+ children: (0, Q.jsx)("path", { d: "M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z" })
4703
+ }),
4704
+ error: (0, Q.jsx)(m, {
4705
+ iconKey: "ErrorAlert",
4706
+ style: { marginRight: "8px" }
4707
+ })
4708
+ },
4709
+ children: (0, Q.jsx)(be, {
4710
+ workbook: K,
4711
+ children: (0, Q.jsx)(ge, {
4712
+ renderArea: rn,
4713
+ onUpdateArea: (e) => {
4714
+ $t(e);
4715
+ },
4716
+ children: (0, Q.jsx)(Sn, { children: (0, Q.jsx)(Da, { children: (0, Q.jsx)(A, { children: (0, Q.jsx)(b, { children: (0, Q.jsx)(wa, {
4717
+ workbook: K,
4718
+ initialCommandAnchor: Gt,
4719
+ renderWorkbook: dn,
4720
+ setWorkbook: pt,
4721
+ titleWorkbook: It,
4722
+ setWorkbookTitle: Ft,
4723
+ refDocumentTitle: qt,
4724
+ isDirty: Tt,
4725
+ refSave: wt,
4726
+ host: n
4727
+ }) }) }) }) })
4728
+ })
4729
+ })
4730
+ });
4731
+ return fn = (0, Q.jsxs)(Zn, {
4732
+ theme: Ze ? V.dark : V.light,
4733
+ children: [
4734
+ oe ? (0, Q.jsx)(ur, {}) : null,
4735
+ (0, Q.jsx)("style", { children: $e }),
4736
+ (0, Q.jsx)("style", { children: nt }),
4737
+ (0, Q.jsx)(un, {
4738
+ themeScopeClass: r,
4739
+ themeSurface: "app",
4740
+ themeMode: qe,
4741
+ children: fn
4742
+ })
4743
+ ]
4744
+ }), fn;
4745
+ }));
4746
+ to.displayName = "EagerStudio";
4747
+ var no = (e) => (0, Q.jsx)(ja, { ...e });
4748
+ export { to as EagerStudio, to as default };