@rpcbase/ui 0.287.0 → 0.289.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (738) hide show
  1. package/dist/assets/sha256.worker-DNtOSCbM.js.map +1 -0
  2. package/dist/components/FilesUploadField/index.d.ts.map +1 -1
  3. package/dist/index.js +12 -12
  4. package/dist/index10.js.map +1 -1
  5. package/dist/index100.js.map +1 -1
  6. package/dist/index101.js.map +1 -1
  7. package/dist/index102.js.map +1 -1
  8. package/dist/index103.js.map +1 -1
  9. package/dist/index104.js.map +1 -1
  10. package/dist/index105.js.map +1 -1
  11. package/dist/index106.js.map +1 -1
  12. package/dist/index107.js.map +1 -1
  13. package/dist/index108.js.map +1 -1
  14. package/dist/index109.js.map +1 -1
  15. package/dist/index11.js +96 -17
  16. package/dist/index11.js.map +1 -1
  17. package/dist/index110.js.map +1 -1
  18. package/dist/index111.js.map +1 -1
  19. package/dist/index112.js.map +1 -1
  20. package/dist/index113.js.map +1 -1
  21. package/dist/index114.js.map +1 -1
  22. package/dist/index115.js.map +1 -1
  23. package/dist/index116.js.map +1 -1
  24. package/dist/index117.js.map +1 -1
  25. package/dist/index118.js.map +1 -1
  26. package/dist/index119.js.map +1 -1
  27. package/dist/index12.js.map +1 -1
  28. package/dist/index120.js.map +1 -1
  29. package/dist/index121.js.map +1 -1
  30. package/dist/index122.js.map +1 -1
  31. package/dist/index123.js +1 -1
  32. package/dist/index123.js.map +1 -1
  33. package/dist/index124.js.map +1 -1
  34. package/dist/index125.js.map +1 -1
  35. package/dist/index126.js.map +1 -1
  36. package/dist/index127.js.map +1 -1
  37. package/dist/index128.js.map +1 -1
  38. package/dist/index129.js.map +1 -1
  39. package/dist/index13.js.map +1 -1
  40. package/dist/index130.js.map +1 -1
  41. package/dist/index131.js.map +1 -1
  42. package/dist/index132.js.map +1 -1
  43. package/dist/index133.js.map +1 -1
  44. package/dist/index134.js.map +1 -1
  45. package/dist/index135.js.map +1 -1
  46. package/dist/index136.js.map +1 -1
  47. package/dist/index137.js.map +1 -1
  48. package/dist/index138.js.map +1 -1
  49. package/dist/index139.js.map +1 -1
  50. package/dist/index14.js.map +1 -1
  51. package/dist/index140.js.map +1 -1
  52. package/dist/index141.js.map +1 -1
  53. package/dist/index142.js.map +1 -1
  54. package/dist/index143.js.map +1 -1
  55. package/dist/index144.js.map +1 -1
  56. package/dist/index145.js.map +1 -1
  57. package/dist/index146.js.map +1 -1
  58. package/dist/index147.js.map +1 -1
  59. package/dist/index148.js.map +1 -1
  60. package/dist/index149.js.map +1 -1
  61. package/dist/index15.js.map +1 -1
  62. package/dist/index150.js.map +1 -1
  63. package/dist/index151.js.map +1 -1
  64. package/dist/index152.js.map +1 -1
  65. package/dist/index153.js.map +1 -1
  66. package/dist/index154.js +4 -4
  67. package/dist/index154.js.map +1 -1
  68. package/dist/index155.js.map +1 -1
  69. package/dist/index156.js.map +1 -1
  70. package/dist/index157.js.map +1 -1
  71. package/dist/index158.js.map +1 -1
  72. package/dist/index159.js.map +1 -1
  73. package/dist/index16.js.map +1 -1
  74. package/dist/index160.js.map +1 -1
  75. package/dist/index161.js.map +1 -1
  76. package/dist/index162.js.map +1 -1
  77. package/dist/index163.js.map +1 -1
  78. package/dist/index164.js.map +1 -1
  79. package/dist/index165.js.map +1 -1
  80. package/dist/index166.js.map +1 -1
  81. package/dist/index167.js.map +1 -1
  82. package/dist/index168.js.map +1 -1
  83. package/dist/index169.js.map +1 -1
  84. package/dist/index17.js.map +1 -1
  85. package/dist/index170.js +18 -12
  86. package/dist/index170.js.map +1 -1
  87. package/dist/index171.js.map +1 -1
  88. package/dist/index172.js.map +1 -1
  89. package/dist/index173.js.map +1 -1
  90. package/dist/index174.js.map +1 -1
  91. package/dist/index175.js.map +1 -1
  92. package/dist/index176.js.map +1 -1
  93. package/dist/index177.js.map +1 -1
  94. package/dist/index178.js.map +1 -1
  95. package/dist/index179.js.map +1 -1
  96. package/dist/index18.js.map +1 -1
  97. package/dist/index180.js.map +1 -1
  98. package/dist/index181.js +1 -1
  99. package/dist/index181.js.map +1 -1
  100. package/dist/index182.js +3 -3
  101. package/dist/index182.js.map +1 -1
  102. package/dist/index183.js.map +1 -1
  103. package/dist/index184.js.map +1 -1
  104. package/dist/index185.js.map +1 -1
  105. package/dist/index186.js.map +1 -1
  106. package/dist/index187.js.map +1 -1
  107. package/dist/index188.js.map +1 -1
  108. package/dist/index189.js.map +1 -1
  109. package/dist/index19.js.map +1 -1
  110. package/dist/index190.js +9 -7
  111. package/dist/index190.js.map +1 -1
  112. package/dist/index191.js +4 -4
  113. package/dist/index191.js.map +1 -1
  114. package/dist/index192.js +4 -15
  115. package/dist/index192.js.map +1 -1
  116. package/dist/index193.js +13 -3
  117. package/dist/index193.js.map +1 -1
  118. package/dist/index194.js +2 -2
  119. package/dist/index194.js.map +1 -1
  120. package/dist/index195.js +4 -85
  121. package/dist/index195.js.map +1 -1
  122. package/dist/index196.js +79 -54
  123. package/dist/index196.js.map +1 -1
  124. package/dist/index197.js +68 -7
  125. package/dist/index197.js.map +1 -1
  126. package/dist/index198.js +3 -23
  127. package/dist/index198.js.map +1 -1
  128. package/dist/index199.js +6 -28
  129. package/dist/index199.js.map +1 -1
  130. package/dist/index20.js.map +1 -1
  131. package/dist/index200.js +4 -97
  132. package/dist/index200.js.map +1 -1
  133. package/dist/index201.js +3 -4
  134. package/dist/index201.js.map +1 -1
  135. package/dist/index202.js +23 -24
  136. package/dist/index202.js.map +1 -1
  137. package/dist/index203.js +28 -10
  138. package/dist/index203.js.map +1 -1
  139. package/dist/index204.js +97 -4
  140. package/dist/index204.js.map +1 -1
  141. package/dist/index205.js +4 -12
  142. package/dist/index205.js.map +1 -1
  143. package/dist/index206.js +22 -19
  144. package/dist/index206.js.map +1 -1
  145. package/dist/index207.js +4 -6
  146. package/dist/index207.js.map +1 -1
  147. package/dist/index208.js +4 -15
  148. package/dist/index208.js.map +1 -1
  149. package/dist/index209.js +10 -102
  150. package/dist/index209.js.map +1 -1
  151. package/dist/index210.js +21 -3
  152. package/dist/index210.js.map +1 -1
  153. package/dist/index211.js +5 -23
  154. package/dist/index211.js.map +1 -1
  155. package/dist/index212.js +15 -28
  156. package/dist/index212.js.map +1 -1
  157. package/dist/index213.js +101 -17
  158. package/dist/index213.js.map +1 -1
  159. package/dist/index214.js +3 -7
  160. package/dist/index214.js.map +1 -1
  161. package/dist/index215.js +24 -15
  162. package/dist/index215.js.map +1 -1
  163. package/dist/index216.js +27 -7
  164. package/dist/index216.js.map +1 -1
  165. package/dist/index217.js +17 -24
  166. package/dist/index217.js.map +1 -1
  167. package/dist/index218.js +6 -22
  168. package/dist/index218.js.map +1 -1
  169. package/dist/index219.js +15 -6
  170. package/dist/index219.js.map +1 -1
  171. package/dist/index220.js +8 -5
  172. package/dist/index220.js.map +1 -1
  173. package/dist/index221.js +27 -4
  174. package/dist/index221.js.map +1 -1
  175. package/dist/index222.js +23 -4
  176. package/dist/index222.js.map +1 -1
  177. package/dist/index223.js +6 -24
  178. package/dist/index223.js.map +1 -1
  179. package/dist/index224.js +5 -3
  180. package/dist/index224.js.map +1 -1
  181. package/dist/index225.js +4 -24
  182. package/dist/index225.js.map +1 -1
  183. package/dist/index226.js +4 -23
  184. package/dist/index226.js.map +1 -1
  185. package/dist/index227.js +23 -6
  186. package/dist/index227.js.map +1 -1
  187. package/dist/index228.js +22 -8
  188. package/dist/index228.js.map +1 -1
  189. package/dist/index229.js +3 -19
  190. package/dist/index229.js.map +1 -1
  191. package/dist/index23.js.map +1 -1
  192. package/dist/index230.js +22 -50
  193. package/dist/index230.js.map +1 -1
  194. package/dist/index231.js +7 -20
  195. package/dist/index231.js.map +1 -1
  196. package/dist/index232.js +9 -27
  197. package/dist/index232.js.map +1 -1
  198. package/dist/index233.js +17 -97
  199. package/dist/index233.js.map +1 -1
  200. package/dist/index234.js +50 -33
  201. package/dist/index234.js.map +1 -1
  202. package/dist/index235.js +20 -119
  203. package/dist/index235.js.map +1 -1
  204. package/dist/index236.js +28 -13
  205. package/dist/index236.js.map +1 -1
  206. package/dist/index237.js +98 -4
  207. package/dist/index237.js.map +1 -1
  208. package/dist/index238.js +33 -15
  209. package/dist/index238.js.map +1 -1
  210. package/dist/index239.js +116 -62
  211. package/dist/index239.js.map +1 -1
  212. package/dist/index24.js.map +1 -1
  213. package/dist/index240.js +13 -10
  214. package/dist/index240.js.map +1 -1
  215. package/dist/index241.js +4 -109
  216. package/dist/index241.js.map +1 -1
  217. package/dist/index242.js +14 -14
  218. package/dist/index242.js.map +1 -1
  219. package/dist/index243.js +64 -12
  220. package/dist/index243.js.map +1 -1
  221. package/dist/index244.js +10 -5
  222. package/dist/index244.js.map +1 -1
  223. package/dist/index245.js +104 -318
  224. package/dist/index245.js.map +1 -1
  225. package/dist/index246.js +14 -66
  226. package/dist/index246.js.map +1 -1
  227. package/dist/index247.js +12 -232
  228. package/dist/index247.js.map +1 -1
  229. package/dist/index248.js +4 -270
  230. package/dist/index248.js.map +1 -1
  231. package/dist/index249.js +313 -309
  232. package/dist/index249.js.map +1 -1
  233. package/dist/index25.js.map +1 -1
  234. package/dist/index250.js +60 -171
  235. package/dist/index250.js.map +1 -1
  236. package/dist/index251.js +252 -8
  237. package/dist/index251.js.map +1 -1
  238. package/dist/index252.js +268 -41
  239. package/dist/index252.js.map +1 -1
  240. package/dist/index253.js +316 -47
  241. package/dist/index253.js.map +1 -1
  242. package/dist/index254.js +179 -9
  243. package/dist/index254.js.map +1 -1
  244. package/dist/index255.js +6 -50
  245. package/dist/index255.js.map +1 -1
  246. package/dist/index256.js +41 -51
  247. package/dist/index256.js.map +1 -1
  248. package/dist/index257.js +50 -7
  249. package/dist/index257.js.map +1 -1
  250. package/dist/index258.js +9 -10
  251. package/dist/index258.js.map +1 -1
  252. package/dist/index259.js +51 -61
  253. package/dist/index259.js.map +1 -1
  254. package/dist/index26.js.map +1 -1
  255. package/dist/index260.js +53 -42
  256. package/dist/index260.js.map +1 -1
  257. package/dist/index261.js +9 -97
  258. package/dist/index261.js.map +1 -1
  259. package/dist/index262.js +31 -47
  260. package/dist/index262.js.map +1 -1
  261. package/dist/index263.js +61 -36
  262. package/dist/index263.js.map +1 -1
  263. package/dist/index264.js +43 -47
  264. package/dist/index264.js.map +1 -1
  265. package/dist/index265.js +92 -46
  266. package/dist/index265.js.map +1 -1
  267. package/dist/index266.js +48 -20
  268. package/dist/index266.js.map +1 -1
  269. package/dist/index267.js +33 -176
  270. package/dist/index267.js.map +1 -1
  271. package/dist/index268.js +49 -48
  272. package/dist/index268.js.map +1 -1
  273. package/dist/index269.js +68 -15
  274. package/dist/index269.js.map +1 -1
  275. package/dist/index27.js.map +1 -1
  276. package/dist/index270.js +20 -65
  277. package/dist/index270.js.map +1 -1
  278. package/dist/index271.js +202 -9
  279. package/dist/index271.js.map +1 -1
  280. package/dist/index272.js +48 -40
  281. package/dist/index272.js.map +1 -1
  282. package/dist/index273.js +60 -91
  283. package/dist/index273.js.map +1 -1
  284. package/dist/index274.js +9 -278
  285. package/dist/index274.js.map +1 -1
  286. package/dist/index275.js +38 -55
  287. package/dist/index275.js.map +1 -1
  288. package/dist/index276.js +91 -10
  289. package/dist/index276.js.map +1 -1
  290. package/dist/index277.js +278 -12
  291. package/dist/index277.js.map +1 -1
  292. package/dist/index278.js +58 -11
  293. package/dist/index278.js.map +1 -1
  294. package/dist/index279.js +11 -64
  295. package/dist/index279.js.map +1 -1
  296. package/dist/index28.js +5 -5
  297. package/dist/index28.js.map +1 -1
  298. package/dist/index280.js +12 -6
  299. package/dist/index280.js.map +1 -1
  300. package/dist/index281.js +3 -25
  301. package/dist/index281.js.map +1 -1
  302. package/dist/index282.js +3 -25
  303. package/dist/index282.js.map +1 -1
  304. package/dist/index283.js +12 -126
  305. package/dist/index283.js.map +1 -1
  306. package/dist/index284.js +63 -51
  307. package/dist/index284.js.map +1 -1
  308. package/dist/index285.js +5 -60
  309. package/dist/index285.js.map +1 -1
  310. package/dist/index286.js +24 -48
  311. package/dist/index286.js.map +1 -1
  312. package/dist/index287.js +24 -6
  313. package/dist/index287.js.map +1 -1
  314. package/dist/index288.js +125 -14
  315. package/dist/index288.js.map +1 -1
  316. package/dist/index289.js +51 -16
  317. package/dist/index289.js.map +1 -1
  318. package/dist/index29.js +5 -7
  319. package/dist/index29.js.map +1 -1
  320. package/dist/index290.js +56 -11
  321. package/dist/index290.js.map +1 -1
  322. package/dist/index291.js +47 -24
  323. package/dist/index291.js.map +1 -1
  324. package/dist/index292.js +7 -51
  325. package/dist/index292.js.map +1 -1
  326. package/dist/index293.js +15 -6
  327. package/dist/index293.js.map +1 -1
  328. package/dist/index294.js +18 -148
  329. package/dist/index294.js.map +1 -1
  330. package/dist/index295.js +12 -59
  331. package/dist/index295.js.map +1 -1
  332. package/dist/index296.js +25 -120
  333. package/dist/index296.js.map +1 -1
  334. package/dist/index297.js +54 -15
  335. package/dist/index297.js.map +1 -1
  336. package/dist/index298.js +5 -866
  337. package/dist/index298.js.map +1 -1
  338. package/dist/index299.js +148 -28
  339. package/dist/index299.js.map +1 -1
  340. package/dist/index3.js.map +1 -1
  341. package/dist/index30.js +6 -8
  342. package/dist/index30.js.map +1 -1
  343. package/dist/index300.js +55 -512
  344. package/dist/index300.js.map +1 -1
  345. package/dist/index301.js +111 -794
  346. package/dist/index301.js.map +1 -1
  347. package/dist/index302.js +14 -7436
  348. package/dist/index302.js.map +1 -1
  349. package/dist/index303.js +862 -6
  350. package/dist/index303.js.map +1 -1
  351. package/dist/index304.js +28 -12
  352. package/dist/index304.js.map +1 -1
  353. package/dist/index305.js +515 -5
  354. package/dist/index305.js.map +1 -1
  355. package/dist/index306.js +803 -5
  356. package/dist/index306.js.map +1 -1
  357. package/dist/index307.js +7426 -468
  358. package/dist/index307.js.map +1 -1
  359. package/dist/index308.js +6 -37
  360. package/dist/index308.js.map +1 -1
  361. package/dist/index309.js +12 -19
  362. package/dist/index309.js.map +1 -1
  363. package/dist/index31.js +5 -11
  364. package/dist/index31.js.map +1 -1
  365. package/dist/index310.js +5 -30
  366. package/dist/index310.js.map +1 -1
  367. package/dist/index311.js +5 -4
  368. package/dist/index311.js.map +1 -1
  369. package/dist/index312.js +461 -51
  370. package/dist/index312.js.map +1 -1
  371. package/dist/index313.js +36 -10
  372. package/dist/index313.js.map +1 -1
  373. package/dist/index314.js +19 -5
  374. package/dist/index314.js.map +1 -1
  375. package/dist/index315.js +29 -8
  376. package/dist/index315.js.map +1 -1
  377. package/dist/index316.js +4 -12
  378. package/dist/index316.js.map +1 -1
  379. package/dist/index317.js +60 -3
  380. package/dist/index317.js.map +1 -1
  381. package/dist/index318.js +10 -15
  382. package/dist/index318.js.map +1 -1
  383. package/dist/index319.js +5 -25
  384. package/dist/index319.js.map +1 -1
  385. package/dist/index32.js +5 -5
  386. package/dist/index32.js.map +1 -1
  387. package/dist/index320.js +9 -41
  388. package/dist/index320.js.map +1 -1
  389. package/dist/index321.js +11 -4
  390. package/dist/index321.js.map +1 -1
  391. package/dist/index322.js +3 -26
  392. package/dist/index322.js.map +1 -1
  393. package/dist/index323.js +15 -18
  394. package/dist/index323.js.map +1 -1
  395. package/dist/index324.js +22 -31
  396. package/dist/index324.js.map +1 -1
  397. package/dist/index325.js +41 -5
  398. package/dist/index325.js.map +1 -1
  399. package/dist/index326.js +4 -8
  400. package/dist/index326.js.map +1 -1
  401. package/dist/index327.js +25 -8
  402. package/dist/index327.js.map +1 -1
  403. package/dist/index328.js +19 -9
  404. package/dist/index328.js.map +1 -1
  405. package/dist/index329.js +34 -10
  406. package/dist/index329.js.map +1 -1
  407. package/dist/index33.js +9 -6
  408. package/dist/index33.js.map +1 -1
  409. package/dist/index330.js +5 -7
  410. package/dist/index330.js.map +1 -1
  411. package/dist/index331.js +9 -75
  412. package/dist/index331.js.map +1 -1
  413. package/dist/index332.js +8 -162
  414. package/dist/index332.js.map +1 -1
  415. package/dist/index333.js +9 -114
  416. package/dist/index333.js.map +1 -1
  417. package/dist/index334.js +10 -14
  418. package/dist/index334.js.map +1 -1
  419. package/dist/index335.js +7 -80
  420. package/dist/index335.js.map +1 -1
  421. package/dist/index336.js +68 -39
  422. package/dist/index336.js.map +1 -1
  423. package/dist/index337.js +160 -11
  424. package/dist/index337.js.map +1 -1
  425. package/dist/index338.js +113 -15
  426. package/dist/index338.js.map +1 -1
  427. package/dist/index339.js +13 -100
  428. package/dist/index339.js.map +1 -1
  429. package/dist/index34.js +6 -6
  430. package/dist/index34.js.map +1 -1
  431. package/dist/index340.js +73 -49
  432. package/dist/index340.js.map +1 -1
  433. package/dist/index341.js +34 -96
  434. package/dist/index341.js.map +1 -1
  435. package/dist/index342.js +12 -70
  436. package/dist/index342.js.map +1 -1
  437. package/dist/index343.js +14 -111
  438. package/dist/index343.js.map +1 -1
  439. package/dist/index344.js +94 -48
  440. package/dist/index344.js.map +1 -1
  441. package/dist/index345.js +50 -37
  442. package/dist/index345.js.map +1 -1
  443. package/dist/index346.js +89 -125
  444. package/dist/index346.js.map +1 -1
  445. package/dist/index347.js +52 -123
  446. package/dist/index347.js.map +1 -1
  447. package/dist/index348.js +54 -197
  448. package/dist/index348.js.map +1 -1
  449. package/dist/index349.js +44 -229
  450. package/dist/index349.js.map +1 -1
  451. package/dist/index35.js +9 -9
  452. package/dist/index35.js.map +1 -1
  453. package/dist/index350.js +42 -308
  454. package/dist/index350.js.map +1 -1
  455. package/dist/index351.js +144 -5
  456. package/dist/index351.js.map +1 -1
  457. package/dist/index352.js +142 -6
  458. package/dist/index352.js.map +1 -1
  459. package/dist/index353.js +257 -7
  460. package/dist/index353.js.map +1 -1
  461. package/dist/index354.js +241 -6
  462. package/dist/index354.js.map +1 -1
  463. package/dist/index355.js +309 -6
  464. package/dist/index355.js.map +1 -1
  465. package/dist/index356.js +5 -21
  466. package/dist/index356.js.map +1 -1
  467. package/dist/index357.js +6 -10
  468. package/dist/index357.js.map +1 -1
  469. package/dist/index358.js +7 -128
  470. package/dist/index358.js.map +1 -1
  471. package/dist/index359.js +6 -42
  472. package/dist/index359.js.map +1 -1
  473. package/dist/index36.js +12 -7
  474. package/dist/index36.js.map +1 -1
  475. package/dist/index360.js +6 -68
  476. package/dist/index360.js.map +1 -1
  477. package/dist/index361.js +20 -116
  478. package/dist/index361.js.map +1 -1
  479. package/dist/index362.js +10 -490
  480. package/dist/index362.js.map +1 -1
  481. package/dist/index363.js +128 -7
  482. package/dist/index363.js.map +1 -1
  483. package/dist/index364.js +42 -13
  484. package/dist/index364.js.map +1 -1
  485. package/dist/index365.js +67 -3
  486. package/dist/index365.js.map +1 -1
  487. package/dist/index366.js +115 -45
  488. package/dist/index366.js.map +1 -1
  489. package/dist/index367.js +490 -11
  490. package/dist/index367.js.map +1 -1
  491. package/dist/index368.js +8 -26
  492. package/dist/index368.js.map +1 -1
  493. package/dist/index369.js +12 -41
  494. package/dist/index369.js.map +1 -1
  495. package/dist/index37.js +13 -5
  496. package/dist/index37.js.map +1 -1
  497. package/dist/index370.js +4 -36
  498. package/dist/index370.js.map +1 -1
  499. package/dist/index371.js +45 -15
  500. package/dist/index371.js.map +1 -1
  501. package/dist/index372.js +24 -41
  502. package/dist/index372.js.map +1 -1
  503. package/dist/index373.js +3 -12
  504. package/dist/index373.js.map +1 -1
  505. package/dist/index374.js +27 -11
  506. package/dist/index374.js.map +1 -1
  507. package/dist/index375.js +40 -50
  508. package/dist/index375.js.map +1 -1
  509. package/dist/index376.js +37 -40
  510. package/dist/index376.js.map +1 -1
  511. package/dist/index377.js +12 -10
  512. package/dist/index377.js.map +1 -1
  513. package/dist/index378.js +40 -4
  514. package/dist/index378.js.map +1 -1
  515. package/dist/index379.js +7 -4
  516. package/dist/index379.js.map +1 -1
  517. package/dist/index38.js +5 -5
  518. package/dist/index38.js.map +1 -1
  519. package/dist/index380.js +29 -8
  520. package/dist/index380.js.map +1 -1
  521. package/dist/index381.js +9 -303
  522. package/dist/index381.js.map +1 -1
  523. package/dist/index382.js +57 -4
  524. package/dist/index382.js.map +1 -1
  525. package/dist/index383.js +40 -22
  526. package/dist/index383.js.map +1 -1
  527. package/dist/index384.js +15 -105
  528. package/dist/index384.js.map +1 -1
  529. package/dist/index385.js +5 -22
  530. package/dist/index385.js.map +1 -1
  531. package/dist/index386.js +10 -22
  532. package/dist/index386.js.map +1 -1
  533. package/dist/index387.js +289 -16
  534. package/dist/index387.js.map +1 -1
  535. package/dist/index388.js +4 -12
  536. package/dist/index388.js.map +1 -1
  537. package/dist/index389.js +20 -112
  538. package/dist/index389.js.map +1 -1
  539. package/dist/index39.js +6 -10
  540. package/dist/index39.js.map +1 -1
  541. package/dist/index390.js +3 -9
  542. package/dist/index390.js.map +1 -1
  543. package/dist/index391.js +104 -27
  544. package/dist/index391.js.map +1 -1
  545. package/dist/index392.js +20 -9
  546. package/dist/index392.js.map +1 -1
  547. package/dist/index393.js +20 -6
  548. package/dist/index393.js.map +1 -1
  549. package/dist/index394.js +14 -253
  550. package/dist/index394.js.map +1 -1
  551. package/dist/index395.js +12 -10
  552. package/dist/index395.js.map +1 -1
  553. package/dist/index396.js +117 -11
  554. package/dist/index396.js.map +1 -1
  555. package/dist/index397.js +8 -6
  556. package/dist/index397.js.map +1 -1
  557. package/dist/index398.js +32 -22
  558. package/dist/index398.js.map +1 -1
  559. package/dist/index399.js +9 -23
  560. package/dist/index399.js.map +1 -1
  561. package/dist/index4.js.map +1 -1
  562. package/dist/index40.js +8 -11
  563. package/dist/index40.js.map +1 -1
  564. package/dist/index400.js +6 -105
  565. package/dist/index400.js.map +1 -1
  566. package/dist/index401.js +3 -15
  567. package/dist/index401.js.map +1 -1
  568. package/dist/index402.js +251 -10
  569. package/dist/index402.js.map +1 -1
  570. package/dist/index403.js +9 -7
  571. package/dist/index403.js.map +1 -1
  572. package/dist/index404.js +11 -239
  573. package/dist/index404.js.map +1 -1
  574. package/dist/index405.js +7 -28
  575. package/dist/index405.js.map +1 -1
  576. package/dist/index406.js +21 -37
  577. package/dist/index406.js.map +1 -1
  578. package/dist/index407.js +21 -10
  579. package/dist/index407.js.map +1 -1
  580. package/dist/index408.js +97 -117
  581. package/dist/index408.js.map +1 -1
  582. package/dist/index409.js +15 -40
  583. package/dist/index409.js.map +1 -1
  584. package/dist/index41.js +6 -7
  585. package/dist/index41.js.map +1 -1
  586. package/dist/index410.js +11 -25
  587. package/dist/index410.js.map +1 -1
  588. package/dist/index411.js +7 -9
  589. package/dist/index411.js.map +1 -1
  590. package/dist/index412.js +3 -24
  591. package/dist/index412.js.map +1 -1
  592. package/dist/index413.js +226 -15
  593. package/dist/index413.js.map +1 -1
  594. package/dist/index414.js +24 -11
  595. package/dist/index414.js.map +1 -1
  596. package/dist/index415.js +38 -4
  597. package/dist/index415.js.map +1 -1
  598. package/dist/index416.js +11 -324
  599. package/dist/index416.js.map +1 -1
  600. package/dist/index417.js +119 -62
  601. package/dist/index417.js.map +1 -1
  602. package/dist/index418.js +42 -4
  603. package/dist/index418.js.map +1 -1
  604. package/dist/index419.js +25 -28
  605. package/dist/index419.js.map +1 -1
  606. package/dist/index42.js +6 -4
  607. package/dist/index42.js.map +1 -1
  608. package/dist/index420.js +11 -470
  609. package/dist/index420.js.map +1 -1
  610. package/dist/index421.js +23 -268
  611. package/dist/index421.js.map +1 -1
  612. package/dist/index422.js +24 -0
  613. package/dist/index422.js.map +1 -0
  614. package/dist/index423.js +17 -0
  615. package/dist/index423.js.map +1 -0
  616. package/dist/index424.js +8 -0
  617. package/dist/index424.js.map +1 -0
  618. package/dist/index425.js +328 -0
  619. package/dist/index425.js.map +1 -0
  620. package/dist/index426.js +66 -0
  621. package/dist/index426.js.map +1 -0
  622. package/dist/index427.js +7 -0
  623. package/dist/index427.js.map +1 -0
  624. package/dist/index428.js +31 -0
  625. package/dist/index428.js.map +1 -0
  626. package/dist/index429.js +474 -0
  627. package/dist/index429.js.map +1 -0
  628. package/dist/index43.js +68 -7
  629. package/dist/index43.js.map +1 -1
  630. package/dist/index430.js +272 -0
  631. package/dist/index430.js.map +1 -0
  632. package/dist/index44.js +7 -6
  633. package/dist/index44.js.map +1 -1
  634. package/dist/index45.js +31 -7
  635. package/dist/index45.js.map +1 -1
  636. package/dist/index46.js +10 -10
  637. package/dist/index46.js.map +1 -1
  638. package/dist/index47.js +15 -13
  639. package/dist/index47.js.map +1 -1
  640. package/dist/index48.js +201 -7
  641. package/dist/index48.js.map +1 -1
  642. package/dist/index49.js +20 -6
  643. package/dist/index49.js.map +1 -1
  644. package/dist/index5.js.map +1 -1
  645. package/dist/index50.js +16 -6
  646. package/dist/index50.js.map +1 -1
  647. package/dist/index51.js +123 -14
  648. package/dist/index51.js.map +1 -1
  649. package/dist/index52.js +19 -8
  650. package/dist/index52.js.map +1 -1
  651. package/dist/index53.js +5 -7
  652. package/dist/index53.js.map +1 -1
  653. package/dist/index54.js +9 -68
  654. package/dist/index54.js.map +1 -1
  655. package/dist/index55.js +7 -7
  656. package/dist/index55.js.map +1 -1
  657. package/dist/index56.js +9 -31
  658. package/dist/index56.js.map +1 -1
  659. package/dist/index57.js +13 -10
  660. package/dist/index57.js.map +1 -1
  661. package/dist/index58.js +8 -15
  662. package/dist/index58.js.map +1 -1
  663. package/dist/index59.js +10 -201
  664. package/dist/index59.js.map +1 -1
  665. package/dist/index6.js.map +1 -1
  666. package/dist/index60.js +13 -20
  667. package/dist/index60.js.map +1 -1
  668. package/dist/index61.js +9 -16
  669. package/dist/index61.js.map +1 -1
  670. package/dist/index62.js +10 -123
  671. package/dist/index62.js.map +1 -1
  672. package/dist/index63.js +5 -19
  673. package/dist/index63.js.map +1 -1
  674. package/dist/index64.js +42 -9
  675. package/dist/index64.js.map +1 -1
  676. package/dist/index65.js +387 -9
  677. package/dist/index65.js.map +1 -1
  678. package/dist/index66.js +37 -14
  679. package/dist/index66.js.map +1 -1
  680. package/dist/index67.js +21 -9
  681. package/dist/index67.js.map +1 -1
  682. package/dist/index68.js +4 -9
  683. package/dist/index68.js.map +1 -1
  684. package/dist/index69.js +6 -4
  685. package/dist/index69.js.map +1 -1
  686. package/dist/index7.js +3 -3
  687. package/dist/index7.js.map +1 -1
  688. package/dist/index70.js +57 -41
  689. package/dist/index70.js.map +1 -1
  690. package/dist/index71.js +5 -387
  691. package/dist/index71.js.map +1 -1
  692. package/dist/index72.js +6 -37
  693. package/dist/index72.js.map +1 -1
  694. package/dist/index73.js +5 -21
  695. package/dist/index73.js.map +1 -1
  696. package/dist/index74.js +4 -56
  697. package/dist/index74.js.map +1 -1
  698. package/dist/index75.js +7 -7
  699. package/dist/index75.js.map +1 -1
  700. package/dist/index76.js +6 -5
  701. package/dist/index76.js.map +1 -1
  702. package/dist/index77.js +6 -5
  703. package/dist/index77.js.map +1 -1
  704. package/dist/index78.js +11 -5
  705. package/dist/index78.js.map +1 -1
  706. package/dist/index79.js +11 -5
  707. package/dist/index79.js.map +1 -1
  708. package/dist/index8.js.map +1 -1
  709. package/dist/index80.js +7 -6
  710. package/dist/index80.js.map +1 -1
  711. package/dist/index81.js +10 -6
  712. package/dist/index81.js.map +1 -1
  713. package/dist/index82.js +5 -8
  714. package/dist/index82.js.map +1 -1
  715. package/dist/index83.js +6 -7
  716. package/dist/index83.js.map +1 -1
  717. package/dist/index84.js.map +1 -1
  718. package/dist/index85.js.map +1 -1
  719. package/dist/index86.js.map +1 -1
  720. package/dist/index87.js +2 -2
  721. package/dist/index87.js.map +1 -1
  722. package/dist/index88.js +31 -31
  723. package/dist/index88.js.map +1 -1
  724. package/dist/index89.js +1 -1
  725. package/dist/index89.js.map +1 -1
  726. package/dist/index9.js.map +1 -1
  727. package/dist/index90.js.map +1 -1
  728. package/dist/index91.js.map +1 -1
  729. package/dist/index92.js.map +1 -1
  730. package/dist/index93.js.map +1 -1
  731. package/dist/index94.js.map +1 -1
  732. package/dist/index95.js.map +1 -1
  733. package/dist/index96.js.map +1 -1
  734. package/dist/index97.js.map +1 -1
  735. package/dist/index98.js.map +1 -1
  736. package/dist/index99.js.map +1 -1
  737. package/package.json +13 -13
  738. package/dist/assets/sha256.worker-BEf4_Y9w.js.map +0 -1
package/dist/index251.js CHANGED
@@ -1,11 +1,255 @@
1
- import { __commonJSMin as e } from "./index2.js";
2
- import * as t from "react";
3
- //#region builtin:esm-external-require-react
4
- var n = /* @__PURE__ */ e(((e, n) => {
5
- n.exports = { ...t };
6
- }));
1
+ "use client";
2
+ import { getComputedStyle as e, getParentNode as t, isElement as n, isHTMLElement as r, isLastTraversableNode as i, isShadowRoot as ee } from "./index204.js";
3
+ import { useStableCallback as a } from "./index206.js";
4
+ import { ownerDocument as o } from "./index211.js";
5
+ import { escapeKey as s, outsidePress as te, triggerPress as c } from "./index214.js";
6
+ import { createChangeEventDetails as l } from "./index215.js";
7
+ import { Timeout as u, useTimeout as d } from "./index221.js";
8
+ import { webkit as f } from "./index224.js";
9
+ import { isReactEvent as p, isVirtualClick as ne } from "./index227.js";
10
+ import { contains as m, getTarget as h } from "./index228.js";
11
+ import { isEventTargetWithin as g, isRootElement as re } from "./index230.js";
12
+ import { addEventListener as _ } from "./index231.js";
13
+ import { mergeCleanups as v } from "./index232.js";
14
+ import { getNodeChildren as ie } from "./index240.js";
15
+ import { createAttribute as ae } from "./index241.js";
16
+ import { useFloatingTree as y } from "./index247.js";
17
+ import * as b from "react";
18
+ //#region ../../node_modules/@base-ui/react/floating-ui-react/hooks/useDismiss.mjs
19
+ function x() {
20
+ return !1;
21
+ }
22
+ function S(e) {
23
+ return {
24
+ escapeKey: typeof e == "boolean" ? e : e?.escapeKey ?? !1,
25
+ outsidePress: typeof e == "boolean" ? e : e?.outsidePress ?? !0
26
+ };
27
+ }
28
+ function C(C, w = {}) {
29
+ let { enabled: T = !0, escapeKey: E = !0, outsidePress: D = !0, outsidePressEvent: oe = "sloppy", referencePress: O = x, bubbles: se, externalTree: k } = w, A = "rootStore" in C ? C.rootStore : C, j = A.useState("open"), ce = A.useState("floatingElement"), { dataRef: M, events: N } = A.context, P = y(k), le = a(typeof D == "function" ? D : () => !1), F = typeof D == "function" ? le : D, ue = F !== !1, de = a(() => oe), { escapeKey: I, outsidePress: fe } = S(se), L = b.useRef(!1), R = b.useRef(!1), z = b.useRef(!1), B = b.useRef(!1), V = b.useRef(!1), H = b.useRef(""), U = b.useRef(null), W = d(), G = d(), K = a(() => {
30
+ G.clear(), M.current.insideReactTree = !1;
31
+ }), q = a((e) => {
32
+ let t = M.current.floatingContext?.nodeId;
33
+ return (P ? ie(P.nodesRef.current, t) : []).some((t) => t.context?.open && !t.context.dataRef.current[e]);
34
+ }), J = a((e) => g(e, A.select("floatingElement")) || g(e, A.select("domReferenceElement"))), Y = a((e) => {
35
+ O() && A.setOpen(!1, l(c, e.nativeEvent));
36
+ }), X = a((e) => {
37
+ if (!j || !T || !E || e.key !== "Escape" || V.current || !I && q("__escapeKeyBubbles")) return;
38
+ let t = p(e) ? e.nativeEvent : e, n = l(s, t);
39
+ A.setOpen(!1, n), n.isCanceled || e.preventDefault(), !I && !n.isPropagationAllowed && e.stopPropagation();
40
+ }), Z = a(() => {
41
+ M.current.insideReactTree = !0, G.start(0, K);
42
+ }), Q = a((e) => {
43
+ if (!j || !T || e.button !== 0) return;
44
+ let t = h(e.nativeEvent);
45
+ m(A.select("floatingElement"), t) && (L.current || (L.current = !0, R.current = !1));
46
+ }), $ = a((e) => {
47
+ j && T && (e.defaultPrevented || e.nativeEvent.defaultPrevented) && L.current && (R.current = !0);
48
+ });
49
+ b.useEffect(() => {
50
+ function e(e) {
51
+ e.open || (B.current = !1);
52
+ }
53
+ return N.on("openchange", e), () => {
54
+ N.off("openchange", e);
55
+ };
56
+ }, [N]), b.useEffect(() => {
57
+ if (!j || !T) return j || (B.current = !1), K;
58
+ M.current.__escapeKeyBubbles = I, M.current.__outsidePressBubbles = fe;
59
+ let a = new u(), s = new u(), c = o(ce);
60
+ function d() {
61
+ a.clear(), V.current = !0;
62
+ }
63
+ function p() {
64
+ a.start(f ? 5 : 0, () => {
65
+ V.current = !1;
66
+ });
67
+ }
68
+ function y() {
69
+ z.current = !0, s.start(0, () => {
70
+ z.current = !1;
71
+ });
72
+ }
73
+ function b() {
74
+ L.current = !1, R.current = !1;
75
+ }
76
+ function x() {
77
+ let e = H.current, t = e === "pen" || !e ? "mouse" : e, n = de(), r = typeof n == "function" ? n() : n;
78
+ return typeof r == "string" ? r : r[t];
79
+ }
80
+ function S(e) {
81
+ let t = x();
82
+ return t === "intentional" && e.type !== "click" || t === "sloppy" && e.type === "click";
83
+ }
84
+ function C(e) {
85
+ let t = M.current.floatingContext?.nodeId, n = P && ie(P.nodesRef.current, t).some((t) => g(e, t.context?.elements.floating));
86
+ return J(e) || n;
87
+ }
88
+ function w(a) {
89
+ if (S(a)) {
90
+ a.type !== "click" && !J(a) && (s.clear(), z.current = !1), K();
91
+ return;
92
+ }
93
+ if (M.current.insideReactTree) {
94
+ K();
95
+ return;
96
+ }
97
+ let c = h(a), u = `[${ae("inert")}]`, d = n(c) ? c.getRootNode() : null, f = Array.from((ee(d) ? d : o(A.select("floatingElement"))).querySelectorAll(u)), p = A.context.triggerElements;
98
+ if (c && (p.hasElement(c) || p.hasMatchingElement((e) => m(e, c)))) return;
99
+ let g = n(c) ? c : null;
100
+ for (; g && !i(g);) {
101
+ let e = t(g);
102
+ if (i(e) || !n(e)) break;
103
+ g = e;
104
+ }
105
+ if (!(f.length && n(c) && !re(c) && !m(c, A.select("floatingElement")) && f.every((e) => !m(g, e)))) {
106
+ if (r(c) && !("touches" in a)) {
107
+ let t = i(c), n = e(c), r = /auto|scroll/, ee = t || r.test(n.overflowX), o = t || r.test(n.overflowY), s = ee && c.clientWidth > 0 && c.scrollWidth > c.clientWidth, te = o && c.clientHeight > 0 && c.scrollHeight > c.clientHeight, l = n.direction === "rtl", u = te && (l ? a.offsetX <= c.offsetWidth - c.clientWidth : a.offsetX > c.clientWidth), d = s && a.offsetY > c.clientHeight;
108
+ if (u || d) return;
109
+ }
110
+ if (!C(a)) {
111
+ if (x() === "intentional") {
112
+ if (a.detail !== 0 && !ne(a) && !B.current) return;
113
+ if (z.current) {
114
+ s.clear(), z.current = !1;
115
+ return;
116
+ }
117
+ }
118
+ (typeof F != "function" || F(a)) && (q("__outsidePressBubbles") || (A.setOpen(!1, l(te, a)), K()));
119
+ }
120
+ }
121
+ }
122
+ function D(e) {
123
+ x() === "sloppy" && e.pointerType !== "touch" && A.select("open") && T && !J(e) && w(e);
124
+ }
125
+ function oe(e) {
126
+ if (x() !== "sloppy" || !A.select("open") || !T || J(e)) return;
127
+ let t = e.touches[0];
128
+ t && (U.current = {
129
+ startTime: Date.now(),
130
+ startX: t.clientX,
131
+ startY: t.clientY,
132
+ dismissOnTouchEnd: !1,
133
+ dismissOnMouseDown: !0
134
+ }, W.start(1e3, () => {
135
+ U.current && (U.current.dismissOnTouchEnd = !1, U.current.dismissOnMouseDown = !1);
136
+ }));
137
+ }
138
+ function O(e, t) {
139
+ let n = h(e);
140
+ if (!n) return;
141
+ let r = _(n, e.type, () => {
142
+ t(e), r();
143
+ });
144
+ }
145
+ function se(e) {
146
+ H.current = "touch", O(e, oe);
147
+ }
148
+ function k(e) {
149
+ W.clear(), e.type === "pointerdown" && (e.button === 0 && (B.current = !0), H.current = e.pointerType), (e.type !== "mousedown" || !U.current || U.current.dismissOnMouseDown) && O(e, (e) => {
150
+ e.type === "pointerdown" ? D(e) : w(e);
151
+ });
152
+ }
153
+ function N(e) {
154
+ if (e.type === "pointercancel" && (B.current = !1), !L.current) return;
155
+ let t = R.current;
156
+ if (b(), x() === "intentional") {
157
+ if (e.type === "pointercancel") {
158
+ t && y();
159
+ return;
160
+ }
161
+ if (!C(e)) {
162
+ if (t) {
163
+ y();
164
+ return;
165
+ }
166
+ (typeof F != "function" || F(e)) && (s.clear(), z.current = !0, K());
167
+ }
168
+ }
169
+ }
170
+ function le(e) {
171
+ if (x() !== "sloppy" || !U.current || J(e)) return;
172
+ let t = e.touches[0];
173
+ if (!t) return;
174
+ let n = Math.abs(t.clientX - U.current.startX), r = Math.abs(t.clientY - U.current.startY), i = Math.sqrt(n * n + r * r);
175
+ i > 5 && (U.current.dismissOnTouchEnd = !0), i > 10 && (w(e), W.clear(), U.current = null);
176
+ }
177
+ function G(e) {
178
+ O(e, le);
179
+ }
180
+ function Y(e) {
181
+ x() === "sloppy" && U.current && !J(e) && (U.current.dismissOnTouchEnd && w(e), W.clear(), U.current = null);
182
+ }
183
+ function Z(e) {
184
+ O(e, Y);
185
+ }
186
+ let Q = v(E && v(_(c, "keydown", X), _(c, "compositionstart", d), _(c, "compositionend", p)), ue && v(_(c, "click", k, !0), _(c, "pointerdown", k, !0), _(c, "pointerup", N, !0), _(c, "pointercancel", N, !0), _(c, "mousedown", k, !0), _(c, "mouseup", N, !0), _(c, "touchstart", se, {
187
+ capture: !0,
188
+ passive: !0
189
+ }), _(c, "touchmove", G, {
190
+ capture: !0,
191
+ passive: !0
192
+ }), _(c, "touchend", Z, {
193
+ capture: !0,
194
+ passive: !0
195
+ })));
196
+ return () => {
197
+ Q(), a.clear(), s.clear(), b(), z.current = !1, K();
198
+ };
199
+ }, [
200
+ M,
201
+ ce,
202
+ E,
203
+ ue,
204
+ F,
205
+ j,
206
+ T,
207
+ I,
208
+ fe,
209
+ X,
210
+ K,
211
+ de,
212
+ q,
213
+ J,
214
+ P,
215
+ A,
216
+ W
217
+ ]);
218
+ let pe = b.useMemo(() => ({
219
+ onKeyDown: X,
220
+ onPointerDown: Y,
221
+ onClick: Y
222
+ }), [X, Y]), me = b.useMemo(() => ({
223
+ onKeyDown: X,
224
+ onPointerDown: $,
225
+ onMouseDown: $,
226
+ onClickCapture: Z,
227
+ onMouseDownCapture(e) {
228
+ Z(), Q(e);
229
+ },
230
+ onPointerDownCapture(e) {
231
+ Z(), Q(e);
232
+ },
233
+ onMouseUpCapture: Z,
234
+ onTouchEndCapture: Z,
235
+ onTouchMoveCapture: Z
236
+ }), [
237
+ X,
238
+ Z,
239
+ Q,
240
+ $
241
+ ]);
242
+ return b.useMemo(() => T ? {
243
+ reference: pe,
244
+ floating: me,
245
+ trigger: pe
246
+ } : {}, [
247
+ T,
248
+ pe,
249
+ me
250
+ ]);
251
+ }
7
252
  //#endregion
8
- export default n();
9
- export { n as require_builtin_esm_external_require_react };
253
+ export { S as normalizeProp, C as useDismiss };
10
254
 
11
255
  //# sourceMappingURL=index251.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index251.js","names":[],"sources":["../builtin:esm-external-require-react"],"sourcesContent":["import * as m from 'react';module.exports = { ...m };"],"mappings":";;;;CAA2B,EAAO,UAAU,EAAE,GAAG,EAAE"}
1
+ {"version":3,"file":"index251.js","names":["outsidePress","React","REASONS.triggerPress","escapeKey","REASONS.escapeKey","platform.engine.webkit","REASONS.outsidePress","React$1","alwaysFalse","normalizeProp","normalizable","useDismiss","escapeKey$1","outsidePressProp","props","store","context","open","floatingElement","tree","useFloatingTree","externalTree","outsidePressFn","useStableCallback","outsidePress$1","outsidePressEnabled","getOutsidePressEventProp","outsidePressEvent","escapeKeyBubbles","outsidePressBubbles","bubbles","pressStartedInsideRef","pressStartPreventedRef","suppressNextOutsideClickRef","sawPressWhileOpenRef","isComposingRef","currentPointerTypeRef","touchStateRef","cancelDismissOnEndTimeout","useTimeout","clearInsideReactTreeTimeout","clearInsideReactTree","hasBlockingChild","nodeId","dataRef","getNodeChildren","child","bubbleKey","isEventWithinOwnElements","isEventTargetWithin","event","closeOnReferencePress","referencePress","createChangeEventDetails","triggerPress","closeOnEscapeKeyDown","enabled","native","isReactEvent","eventDetails","escapeKey","markInsideReactTree","markPressStartedInsideReactTree","target","getTarget","contains","markInsidePressStartPrevented","handleOpenChange","details","events","compositionTimeout","Timeout","preventedPressSuppressionTimeout","doc","ownerDocument","handleCompositionStart","handleCompositionEnd","webkit","suppressImmediateOutsideClickAfterPreventedStart","resetPressStartState","getOutsidePressEvent","type","computedType","outsidePressEventValue","resolved","shouldIgnoreEvent","computedOutsidePressEvent","isEventWithinFloatingTree","targetIsInsideChildren","node","closeOnPressOutside","inertSelector","createAttribute","targetRoot","isElement","markers","isShadowRoot","triggers","trigger","targetRootAncestor","isLastTraversableNode","nextParent","getParentNode","isRootElement","marker","isHTMLElement","lastTraversableNode","style","getComputedStyle","scrollRe","isScrollableX","isScrollableY","canScrollX","canScrollY","isRTL","pressedVerticalScrollbar","pressedHorizontalScrollbar","isVirtualClick","outsidePress","handlePointerDown","handleTouchStart","touch","addTargetEventListenerOnce","unsubscribe","addEventListener","listener","handleTouchStartCapture","closeOnPressOutsideCapture","targetEvent","handlePressEndCapture","pressStartedInsideDefaultPrevented","handleTouchMove","deltaX","deltaY","distance","handleTouchMoveCapture","handleTouchEnd","handleTouchEndCapture","mergeCleanups","reference","floating"],"sources":["../../../node_modules/@base-ui/react/floating-ui-react/hooks/useDismiss.mjs"],"sourcesContent":["'use client';\n\n/* eslint-disable no-underscore-dangle */\nimport * as React from 'react';\nimport { addEventListener } from '@base-ui/utils/addEventListener';\nimport { mergeCleanups } from '@base-ui/utils/mergeCleanups';\nimport { ownerDocument } from '@base-ui/utils/owner';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { Timeout, useTimeout } from '@base-ui/utils/useTimeout';\nimport { getComputedStyle, getParentNode, isElement, isHTMLElement, isLastTraversableNode, isShadowRoot } from '@floating-ui/utils/dom';\nimport { platform } from '@base-ui/utils/platform';\nimport { useFloatingTree } from \"../components/FloatingTree.mjs\";\nimport { createChangeEventDetails } from \"../../internals/createBaseUIEventDetails.mjs\";\nimport { REASONS } from \"../../internals/reasons.mjs\";\nimport { createAttribute } from \"../utils/createAttribute.mjs\";\nimport { contains, getTarget, isEventTargetWithin, isRootElement } from \"../utils/element.mjs\";\nimport { isReactEvent, isVirtualClick } from \"../utils/event.mjs\";\nimport { getNodeChildren } from \"../utils/nodes.mjs\";\nfunction alwaysFalse() {\n return false;\n}\nexport function normalizeProp(normalizable) {\n return {\n escapeKey: typeof normalizable === 'boolean' ? normalizable : normalizable?.escapeKey ?? false,\n outsidePress: typeof normalizable === 'boolean' ? normalizable : normalizable?.outsidePress ?? true\n };\n}\n/**\n * Closes the floating element when a dismissal is requested — by default, when\n * the user presses the `escape` key or outside of the floating element.\n * @see https://floating-ui.com/docs/useDismiss\n */\nexport function useDismiss(context, props = {}) {\n const {\n enabled = true,\n escapeKey = true,\n outsidePress: outsidePressProp = true,\n outsidePressEvent = 'sloppy',\n referencePress = alwaysFalse,\n bubbles,\n externalTree\n } = props;\n const store = 'rootStore' in context ? context.rootStore : context;\n const open = store.useState('open');\n const floatingElement = store.useState('floatingElement');\n const {\n dataRef,\n events\n } = store.context;\n const tree = useFloatingTree(externalTree);\n const outsidePressFn = useStableCallback(typeof outsidePressProp === 'function' ? outsidePressProp : () => false);\n const outsidePress = typeof outsidePressProp === 'function' ? outsidePressFn : outsidePressProp;\n const outsidePressEnabled = outsidePress !== false;\n const getOutsidePressEventProp = useStableCallback(() => outsidePressEvent);\n const {\n escapeKey: escapeKeyBubbles,\n outsidePress: outsidePressBubbles\n } = normalizeProp(bubbles);\n const pressStartedInsideRef = React.useRef(false);\n const pressStartPreventedRef = React.useRef(false);\n // Ignore only the very next outside click after dragging from inside to outside.\n const suppressNextOutsideClickRef = React.useRef(false);\n // A click whose press began before the floating element opened is the tail of that\n // gesture (e.g. the drag-release that opened it), not a new outside press.\n const sawPressWhileOpenRef = React.useRef(false);\n const isComposingRef = React.useRef(false);\n const currentPointerTypeRef = React.useRef('');\n const touchStateRef = React.useRef(null);\n const cancelDismissOnEndTimeout = useTimeout();\n const clearInsideReactTreeTimeout = useTimeout();\n const clearInsideReactTree = useStableCallback(() => {\n clearInsideReactTreeTimeout.clear();\n dataRef.current.insideReactTree = false;\n });\n const hasBlockingChild = useStableCallback(bubbleKey => {\n const nodeId = dataRef.current.floatingContext?.nodeId;\n const children = tree ? getNodeChildren(tree.nodesRef.current, nodeId) : [];\n return children.some(child => child.context?.open && !child.context.dataRef.current[bubbleKey]);\n });\n const isEventWithinOwnElements = useStableCallback(event => {\n return isEventTargetWithin(event, store.select('floatingElement')) || isEventTargetWithin(event, store.select('domReferenceElement'));\n });\n const closeOnReferencePress = useStableCallback(event => {\n if (!referencePress()) {\n return;\n }\n store.setOpen(false, createChangeEventDetails(REASONS.triggerPress, event.nativeEvent));\n });\n const closeOnEscapeKeyDown = useStableCallback(event => {\n if (!open || !enabled || !escapeKey || event.key !== 'Escape') {\n return;\n }\n\n // Wait until IME is settled. Pressing `Escape` while composing should\n // close the compose menu, but not the floating element.\n if (isComposingRef.current) {\n return;\n }\n if (!escapeKeyBubbles && hasBlockingChild('__escapeKeyBubbles')) {\n return;\n }\n const native = isReactEvent(event) ? event.nativeEvent : event;\n const eventDetails = createChangeEventDetails(REASONS.escapeKey, native);\n store.setOpen(false, eventDetails);\n if (!eventDetails.isCanceled) {\n event.preventDefault();\n }\n if (!escapeKeyBubbles && !eventDetails.isPropagationAllowed) {\n event.stopPropagation();\n }\n });\n const markInsideReactTree = useStableCallback(() => {\n dataRef.current.insideReactTree = true;\n clearInsideReactTreeTimeout.start(0, clearInsideReactTree);\n });\n const markPressStartedInsideReactTree = useStableCallback(event => {\n if (!open || !enabled || event.button !== 0) {\n return;\n }\n const target = getTarget(event.nativeEvent);\n\n // Only treat presses that start within the floating DOM subtree as inside.\n // This avoids suppressing parent dismissal when interacting with nested portals.\n if (!contains(store.select('floatingElement'), target)) {\n return;\n }\n if (!pressStartedInsideRef.current) {\n pressStartedInsideRef.current = true;\n pressStartPreventedRef.current = false;\n }\n });\n const markInsidePressStartPrevented = useStableCallback(event => {\n if (!open || !enabled) {\n return;\n }\n if (!(event.defaultPrevented || event.nativeEvent.defaultPrevented)) {\n return;\n }\n if (pressStartedInsideRef.current) {\n pressStartPreventedRef.current = true;\n }\n });\n\n // A same-batch close+reopen never renders `open === false`, so only `openchange` can\n // observe that session boundary. The effect below covers controlled flips.\n React.useEffect(() => {\n function handleOpenChange(details) {\n // Only the closing half ends the session: `setOpen(true)` on an already-open\n // element (hovering an inactive trigger) must not drop a press mid-gesture.\n if (!details.open) {\n sawPressWhileOpenRef.current = false;\n }\n }\n events.on('openchange', handleOpenChange);\n return () => {\n events.off('openchange', handleOpenChange);\n };\n }, [events]);\n React.useEffect(() => {\n if (!open || !enabled) {\n // Reset in the effect body, not the cleanup, which also runs when a dependency\n // changes mid-gesture.\n if (!open) {\n sawPressWhileOpenRef.current = false;\n }\n return clearInsideReactTree;\n }\n dataRef.current.__escapeKeyBubbles = escapeKeyBubbles;\n dataRef.current.__outsidePressBubbles = outsidePressBubbles;\n const compositionTimeout = new Timeout();\n const preventedPressSuppressionTimeout = new Timeout();\n const doc = ownerDocument(floatingElement);\n function handleCompositionStart() {\n compositionTimeout.clear();\n isComposingRef.current = true;\n }\n function handleCompositionEnd() {\n // Safari fires `compositionend` before `keydown`, so we need to wait\n // until the next tick to set `isComposing` to `false`.\n // https://bugs.webkit.org/show_bug.cgi?id=165004\n compositionTimeout.start(\n // 0ms or 1ms don't work in Safari. 5ms appears to consistently work.\n // Only apply to WebKit for the test to remain 0ms.\n platform.engine.webkit ? 5 : 0, () => {\n isComposingRef.current = false;\n });\n }\n function suppressImmediateOutsideClickAfterPreventedStart() {\n suppressNextOutsideClickRef.current = true;\n // Firefox can emit the synthetic outside click in a later task after\n // pointer lock exit, so microtask clearing is too early here.\n preventedPressSuppressionTimeout.start(0, () => {\n suppressNextOutsideClickRef.current = false;\n });\n }\n function resetPressStartState() {\n pressStartedInsideRef.current = false;\n pressStartPreventedRef.current = false;\n }\n function getOutsidePressEvent() {\n const type = currentPointerTypeRef.current;\n const computedType = type === 'pen' || !type ? 'mouse' : type;\n const outsidePressEventValue = getOutsidePressEventProp();\n const resolved = typeof outsidePressEventValue === 'function' ? outsidePressEventValue() : outsidePressEventValue;\n if (typeof resolved === 'string') {\n return resolved;\n }\n return resolved[computedType];\n }\n function shouldIgnoreEvent(event) {\n const computedOutsidePressEvent = getOutsidePressEvent();\n return computedOutsidePressEvent === 'intentional' && event.type !== 'click' || computedOutsidePressEvent === 'sloppy' && event.type === 'click';\n }\n function isEventWithinFloatingTree(event) {\n const nodeId = dataRef.current.floatingContext?.nodeId;\n const targetIsInsideChildren = tree && getNodeChildren(tree.nodesRef.current, nodeId).some(node => isEventTargetWithin(event, node.context?.elements.floating));\n return isEventWithinOwnElements(event) || targetIsInsideChildren;\n }\n function closeOnPressOutside(event) {\n if (shouldIgnoreEvent(event)) {\n // A new press began outside the floating element and its trigger. Clear any\n // leftover drag-out suppression so this press's eventual click can dismiss.\n if (event.type !== 'click' && !isEventWithinOwnElements(event)) {\n preventedPressSuppressionTimeout.clear();\n suppressNextOutsideClickRef.current = false;\n }\n clearInsideReactTree();\n return;\n }\n if (dataRef.current.insideReactTree) {\n clearInsideReactTree();\n return;\n }\n const target = getTarget(event);\n const inertSelector = `[${createAttribute('inert')}]`;\n const targetRoot = isElement(target) ? target.getRootNode() : null;\n const markers = Array.from((isShadowRoot(targetRoot) ? targetRoot : ownerDocument(store.select('floatingElement'))).querySelectorAll(inertSelector));\n const triggers = store.context.triggerElements;\n\n // If another trigger is clicked, don't close the floating element.\n if (target && (triggers.hasElement(target) || triggers.hasMatchingElement(trigger => contains(trigger, target)))) {\n return;\n }\n let targetRootAncestor = isElement(target) ? target : null;\n while (targetRootAncestor && !isLastTraversableNode(targetRootAncestor)) {\n const nextParent = getParentNode(targetRootAncestor);\n if (isLastTraversableNode(nextParent) || !isElement(nextParent)) {\n break;\n }\n targetRootAncestor = nextParent;\n }\n\n // Check if the click occurred on a third-party element injected after the\n // floating element rendered.\n if (markers.length && isElement(target) && !isRootElement(target) &&\n // Clicked on a direct ancestor (e.g. FloatingOverlay).\n !contains(target, store.select('floatingElement')) &&\n // If the target root element contains none of the markers, then the\n // element was injected after the floating element rendered.\n markers.every(marker => !contains(targetRootAncestor, marker))) {\n return;\n }\n\n // Check if the click occurred on the scrollbar\n // Skip for touch events: scrollbars don't receive touch events on most platforms\n if (isHTMLElement(target) && !('touches' in event)) {\n const lastTraversableNode = isLastTraversableNode(target);\n const style = getComputedStyle(target);\n const scrollRe = /auto|scroll/;\n const isScrollableX = lastTraversableNode || scrollRe.test(style.overflowX);\n const isScrollableY = lastTraversableNode || scrollRe.test(style.overflowY);\n const canScrollX = isScrollableX && target.clientWidth > 0 && target.scrollWidth > target.clientWidth;\n const canScrollY = isScrollableY && target.clientHeight > 0 && target.scrollHeight > target.clientHeight;\n const isRTL = style.direction === 'rtl';\n\n // Check click position relative to scrollbar.\n // In some browsers it is possible to change the <body> (or window)\n // scrollbar to the left side, but is very rare and is difficult to\n // check for. Plus, for modal dialogs with backdrops, it is more\n // important that the backdrop is checked but not so much the window.\n const pressedVerticalScrollbar = canScrollY && (isRTL ? event.offsetX <= target.offsetWidth - target.clientWidth : event.offsetX > target.clientWidth);\n const pressedHorizontalScrollbar = canScrollX && event.offsetY > target.clientHeight;\n if (pressedVerticalScrollbar || pressedHorizontalScrollbar) {\n return;\n }\n }\n if (isEventWithinFloatingTree(event)) {\n return;\n }\n\n // Only `click` events reach this point in intentional mode.\n if (getOutsidePressEvent() === 'intentional') {\n // Press-less clicks (keyboard, assistive technology, `element.click()`) report no\n // click count; `isVirtualClick` also catches the ones that do.\n if (event.detail !== 0 && !isVirtualClick(event) && !sawPressWhileOpenRef.current) {\n return;\n }\n\n // A press that starts inside and ends outside gets one suppressed\n // outside click. Run this after inside-target checks so inside clicks\n // don't consume the one-shot suppression.\n if (suppressNextOutsideClickRef.current) {\n preventedPressSuppressionTimeout.clear();\n suppressNextOutsideClickRef.current = false;\n return;\n }\n }\n if (typeof outsidePress === 'function' && !outsidePress(event)) {\n return;\n }\n if (hasBlockingChild('__outsidePressBubbles')) {\n return;\n }\n store.setOpen(false, createChangeEventDetails(REASONS.outsidePress, event));\n clearInsideReactTree();\n }\n function handlePointerDown(event) {\n if (getOutsidePressEvent() !== 'sloppy' || event.pointerType === 'touch' || !store.select('open') || !enabled || isEventWithinOwnElements(event)) {\n return;\n }\n closeOnPressOutside(event);\n }\n function handleTouchStart(event) {\n if (getOutsidePressEvent() !== 'sloppy' || !store.select('open') || !enabled || isEventWithinOwnElements(event)) {\n return;\n }\n const touch = event.touches[0];\n if (touch) {\n touchStateRef.current = {\n startTime: Date.now(),\n startX: touch.clientX,\n startY: touch.clientY,\n dismissOnTouchEnd: false,\n dismissOnMouseDown: true\n };\n cancelDismissOnEndTimeout.start(1000, () => {\n if (touchStateRef.current) {\n touchStateRef.current.dismissOnTouchEnd = false;\n touchStateRef.current.dismissOnMouseDown = false;\n }\n });\n }\n }\n function addTargetEventListenerOnce(event, listener) {\n const target = getTarget(event);\n if (!target) {\n return;\n }\n const unsubscribe = addEventListener(target, event.type, () => {\n listener(event);\n unsubscribe();\n });\n }\n function handleTouchStartCapture(event) {\n currentPointerTypeRef.current = 'touch';\n addTargetEventListenerOnce(event, handleTouchStart);\n }\n function closeOnPressOutsideCapture(event) {\n cancelDismissOnEndTimeout.clear();\n\n // Only `pointerdown` marks a press; `mousedown` is its compatibility event, and\n // counting it would misattribute a gesture that started before open.\n if (event.type === 'pointerdown') {\n // Only a primary press can produce a `click`.\n if (event.button === 0) {\n sawPressWhileOpenRef.current = true;\n }\n currentPointerTypeRef.current = event.pointerType;\n }\n if (event.type === 'mousedown' && touchStateRef.current && !touchStateRef.current.dismissOnMouseDown) {\n return;\n }\n addTargetEventListenerOnce(event, targetEvent => {\n if (targetEvent.type === 'pointerdown') {\n handlePointerDown(targetEvent);\n } else {\n closeOnPressOutside(targetEvent);\n }\n });\n }\n function handlePressEndCapture(event) {\n // A cancelled gesture produces no click. Not cleared on `pointerup`: the click\n // fires after it and must still find the press.\n if (event.type === 'pointercancel') {\n sawPressWhileOpenRef.current = false;\n }\n if (!pressStartedInsideRef.current) {\n return;\n }\n const pressStartedInsideDefaultPrevented = pressStartPreventedRef.current;\n resetPressStartState();\n if (getOutsidePressEvent() !== 'intentional') {\n return;\n }\n if (event.type === 'pointercancel') {\n if (pressStartedInsideDefaultPrevented) {\n suppressImmediateOutsideClickAfterPreventedStart();\n }\n return;\n }\n if (isEventWithinFloatingTree(event)) {\n return;\n }\n\n // If pointerdown was prevented, no click may be generated for that\n // interaction. However, Firefox may still emit an immediate click after\n // pointerup (e.g. NumberField scrub with pointer lock), so suppress for\n // one tick to absorb that synthetic click only.\n if (pressStartedInsideDefaultPrevented) {\n suppressImmediateOutsideClickAfterPreventedStart();\n return;\n }\n\n // Avoid suppressing when outsidePress explicitly ignores this target.\n if (typeof outsidePress === 'function' && !outsidePress(event)) {\n return;\n }\n preventedPressSuppressionTimeout.clear();\n suppressNextOutsideClickRef.current = true;\n clearInsideReactTree();\n }\n function handleTouchMove(event) {\n if (getOutsidePressEvent() !== 'sloppy' || !touchStateRef.current || isEventWithinOwnElements(event)) {\n return;\n }\n const touch = event.touches[0];\n if (!touch) {\n return;\n }\n const deltaX = Math.abs(touch.clientX - touchStateRef.current.startX);\n const deltaY = Math.abs(touch.clientY - touchStateRef.current.startY);\n const distance = Math.sqrt(deltaX * deltaX + deltaY * deltaY);\n if (distance > 5) {\n touchStateRef.current.dismissOnTouchEnd = true;\n }\n if (distance > 10) {\n closeOnPressOutside(event);\n cancelDismissOnEndTimeout.clear();\n touchStateRef.current = null;\n }\n }\n function handleTouchMoveCapture(event) {\n addTargetEventListenerOnce(event, handleTouchMove);\n }\n function handleTouchEnd(event) {\n if (getOutsidePressEvent() !== 'sloppy' || !touchStateRef.current || isEventWithinOwnElements(event)) {\n return;\n }\n if (touchStateRef.current.dismissOnTouchEnd) {\n closeOnPressOutside(event);\n }\n cancelDismissOnEndTimeout.clear();\n touchStateRef.current = null;\n }\n function handleTouchEndCapture(event) {\n addTargetEventListenerOnce(event, handleTouchEnd);\n }\n const unsubscribe = mergeCleanups(escapeKey && mergeCleanups(addEventListener(doc, 'keydown', closeOnEscapeKeyDown), addEventListener(doc, 'compositionstart', handleCompositionStart), addEventListener(doc, 'compositionend', handleCompositionEnd)), outsidePressEnabled && mergeCleanups(addEventListener(doc, 'click', closeOnPressOutsideCapture, true), addEventListener(doc, 'pointerdown', closeOnPressOutsideCapture, true), addEventListener(doc, 'pointerup', handlePressEndCapture, true), addEventListener(doc, 'pointercancel', handlePressEndCapture, true), addEventListener(doc, 'mousedown', closeOnPressOutsideCapture, true), addEventListener(doc, 'mouseup', handlePressEndCapture, true), addEventListener(doc, 'touchstart', handleTouchStartCapture, {\n capture: true,\n passive: true\n }), addEventListener(doc, 'touchmove', handleTouchMoveCapture, {\n capture: true,\n passive: true\n }), addEventListener(doc, 'touchend', handleTouchEndCapture, {\n capture: true,\n passive: true\n })));\n return () => {\n unsubscribe();\n compositionTimeout.clear();\n preventedPressSuppressionTimeout.clear();\n resetPressStartState();\n suppressNextOutsideClickRef.current = false;\n clearInsideReactTree();\n };\n }, [dataRef, floatingElement, escapeKey, outsidePressEnabled, outsidePress, open, enabled, escapeKeyBubbles, outsidePressBubbles, closeOnEscapeKeyDown, clearInsideReactTree, getOutsidePressEventProp, hasBlockingChild, isEventWithinOwnElements, tree, store, cancelDismissOnEndTimeout]);\n const reference = React.useMemo(() => ({\n onKeyDown: closeOnEscapeKeyDown,\n onPointerDown: closeOnReferencePress,\n onClick: closeOnReferencePress\n }), [closeOnEscapeKeyDown, closeOnReferencePress]);\n const floating = React.useMemo(() => ({\n onKeyDown: closeOnEscapeKeyDown,\n // `onMouseDown` may be blocked if `event.preventDefault()` is called in\n // `onPointerDown`, such as with <NumberField.ScrubArea>.\n // See https://github.com/mui/base-ui/pull/3379\n onPointerDown: markInsidePressStartPrevented,\n onMouseDown: markInsidePressStartPrevented,\n onClickCapture: markInsideReactTree,\n onMouseDownCapture(event) {\n markInsideReactTree();\n markPressStartedInsideReactTree(event);\n },\n onPointerDownCapture(event) {\n markInsideReactTree();\n markPressStartedInsideReactTree(event);\n },\n onMouseUpCapture: markInsideReactTree,\n onTouchEndCapture: markInsideReactTree,\n onTouchMoveCapture: markInsideReactTree\n }), [closeOnEscapeKeyDown, markInsideReactTree, markPressStartedInsideReactTree, markInsidePressStartPrevented]);\n return React.useMemo(() => enabled ? {\n reference,\n floating,\n trigger: reference\n } : {}, [enabled, reference, floating]);\n}"],"ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;AAkBA,SAASQ,IAAc;CACrB,OAAO;AACT;AACA,SAAgBC,EAAc,GAA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
@@ -1,47 +1,274 @@
1
- import { __commonJSMin as e } from "./index2.js";
2
- import { require_builtin_esm_external_require_react as t } from "./index251.js";
3
- //#region ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js
4
- var n = /* @__PURE__ */ e(((e) => {
5
- var n = t();
6
- function r(e, t) {
7
- return e === t && (e !== 0 || 1 / e == 1 / t) || e !== e && t !== t;
1
+ import { clamp as e, evaluate as t, getAlignment as n, getAlignmentAxis as r, getAlignmentSides as i, getAxisLength as a, getExpandedPlacements as o, getOppositeAxis as s, getOppositeAxisPlacements as c, getOppositePlacement as l, getPaddingObject as u, getSide as d, getSideAxis as f, max as p, min as m, rectToClientRect as h } from "./index237.js";
2
+ //#region ../../node_modules/@floating-ui/core/dist/floating-ui.core.mjs
3
+ function g(e, t, i) {
4
+ let { reference: o, floating: s } = e, c = f(t), l = r(t), u = a(l), p = d(t), m = c === "y", h = o.x + o.width / 2 - s.width / 2, g = o.y + o.height / 2 - s.height / 2, _ = o[u] / 2 - s[u] / 2, v;
5
+ switch (p) {
6
+ case "top":
7
+ v = {
8
+ x: h,
9
+ y: o.y - s.height
10
+ };
11
+ break;
12
+ case "bottom":
13
+ v = {
14
+ x: h,
15
+ y: o.y + o.height
16
+ };
17
+ break;
18
+ case "right":
19
+ v = {
20
+ x: o.x + o.width,
21
+ y: g
22
+ };
23
+ break;
24
+ case "left":
25
+ v = {
26
+ x: o.x - s.width,
27
+ y: g
28
+ };
29
+ break;
30
+ default: v = {
31
+ x: o.x,
32
+ y: o.y
33
+ };
8
34
  }
9
- var i = typeof Object.is == "function" ? Object.is : r, a = n.useState, o = n.useEffect, s = n.useLayoutEffect, c = n.useDebugValue;
10
- function l(e, t) {
11
- var n = t(), r = a({ inst: {
12
- value: n,
13
- getSnapshot: t
14
- } }), i = r[0].inst, l = r[1];
15
- return s(function() {
16
- i.value = n, i.getSnapshot = t, u(i) && l({ inst: i });
17
- }, [
18
- e,
19
- n,
20
- t
21
- ]), o(function() {
22
- return u(i) && l({ inst: i }), e(function() {
23
- u(i) && l({ inst: i });
24
- });
25
- }, [e]), c(n), n;
35
+ let y = n(t);
36
+ return y && (v[l] += _ * (y === "end" ? 1 : -1) * (i && m ? -1 : 1)), v;
37
+ }
38
+ async function _(e, n) {
39
+ n === void 0 && (n = {});
40
+ let { x: r, y: i, platform: a, rects: o, elements: s, strategy: c } = e, { boundary: l = "clippingAncestors", rootBoundary: d = "viewport", elementContext: f = "floating", altBoundary: p = !1, padding: m = 0 } = t(n, e), g = u(m), _ = s[p ? f === "floating" ? "reference" : "floating" : f], v = h(await a.getClippingRect({
41
+ element: await (a.isElement == null ? void 0 : a.isElement(_)) ?? !0 ? _ : _.contextElement || await (a.getDocumentElement == null ? void 0 : a.getDocumentElement(s.floating)),
42
+ boundary: l,
43
+ rootBoundary: d,
44
+ strategy: c
45
+ })), y = f === "floating" ? {
46
+ x: r,
47
+ y: i,
48
+ width: o.floating.width,
49
+ height: o.floating.height
50
+ } : o.reference, b = await (a.getOffsetParent == null ? void 0 : a.getOffsetParent(s.floating)), x = await (a.isElement == null ? void 0 : a.isElement(b)) && await (a.getScale == null ? void 0 : a.getScale(b)) || {
51
+ x: 1,
52
+ y: 1
53
+ }, S = h(a.convertOffsetParentRelativeRectToViewportRelativeRect ? await a.convertOffsetParentRelativeRectToViewportRelativeRect({
54
+ elements: s,
55
+ rect: y,
56
+ offsetParent: b,
57
+ strategy: c
58
+ }) : y);
59
+ return {
60
+ top: (v.top - S.top + g.top) / x.y,
61
+ bottom: (S.bottom - v.bottom + g.bottom) / x.y,
62
+ left: (v.left - S.left + g.left) / x.x,
63
+ right: (S.right - v.right + g.right) / x.x
64
+ };
65
+ }
66
+ var v = 50, y = async (e, t, n) => {
67
+ let { placement: r = "bottom", strategy: i = "absolute", middleware: a = [], platform: o } = n, s = o.detectOverflow ? o : {
68
+ ...o,
69
+ detectOverflow: _
70
+ }, c = await (o.isRTL == null ? void 0 : o.isRTL(t)), l = await o.getElementRects({
71
+ reference: e,
72
+ floating: t,
73
+ strategy: i
74
+ }), { x: u, y: d } = g(l, r, c), f = r, p = 0, m = {};
75
+ for (let n = 0; n < a.length; n++) {
76
+ let h = a[n];
77
+ if (!h) continue;
78
+ let { name: _, fn: y } = h, { x: b, y: x, data: S, reset: C } = await y({
79
+ x: u,
80
+ y: d,
81
+ initialPlacement: r,
82
+ placement: f,
83
+ strategy: i,
84
+ middlewareData: m,
85
+ rects: l,
86
+ platform: s,
87
+ elements: {
88
+ reference: e,
89
+ floating: t
90
+ }
91
+ });
92
+ u = b ?? u, d = x ?? d, m[_] = {
93
+ ...m[_],
94
+ ...S
95
+ }, C && p < v && (p++, typeof C == "object" && (C.placement && (f = C.placement), C.rects && (l = C.rects === !0 ? await o.getElementRects({
96
+ reference: e,
97
+ floating: t,
98
+ strategy: i
99
+ }) : C.rects), {x: u, y: d} = g(l, f, c)), n = -1);
26
100
  }
27
- function u(e) {
28
- var t = e.getSnapshot;
29
- e = e.value;
30
- try {
31
- var n = t();
32
- return !i(e, n);
33
- } catch {
34
- return !0;
101
+ return {
102
+ x: u,
103
+ y: d,
104
+ placement: f,
105
+ strategy: i,
106
+ middlewareData: m
107
+ };
108
+ }, b = function(e) {
109
+ return e === void 0 && (e = {}), {
110
+ name: "flip",
111
+ options: e,
112
+ async fn(n) {
113
+ var r;
114
+ let { placement: a, middlewareData: s, rects: u, initialPlacement: p, platform: m, elements: h } = n, { mainAxis: g = !0, crossAxis: _ = !0, fallbackPlacements: v, fallbackStrategy: y = "bestFit", fallbackAxisSideDirection: b = "none", flipAlignment: x = !0, ...S } = t(e, n);
115
+ if ((r = s.arrow) != null && r.alignmentOffset) return {};
116
+ let C = d(a), w = f(p), T = d(p) === p, E = await (m.isRTL == null ? void 0 : m.isRTL(h.floating)), D = v || (T || !x ? [l(p)] : o(p)), O = b !== "none";
117
+ !v && O && D.push(...c(p, x, b, E));
118
+ let k = [p, ...D], A = await m.detectOverflow(n, S), j = [], M = s.flip?.overflows || [];
119
+ if (g && j.push(A[C]), _) {
120
+ let e = i(a, u, E);
121
+ j.push(A[e[0]], A[e[1]]);
122
+ }
123
+ if (M = [...M, {
124
+ placement: a,
125
+ overflows: j
126
+ }], !j.every((e) => e <= 0)) {
127
+ let e = (s.flip?.index || 0) + 1, t = k[e];
128
+ if (t && (_ !== "alignment" || w === f(t) || M.every((e) => f(e.placement) !== w || e.overflows[0] > 0))) return {
129
+ data: {
130
+ index: e,
131
+ overflows: M
132
+ },
133
+ reset: { placement: t }
134
+ };
135
+ let n = M.filter((e) => e.overflows[0] <= 0).sort((e, t) => e.overflows[1] - t.overflows[1])[0]?.placement;
136
+ if (!n) switch (y) {
137
+ case "bestFit": {
138
+ let e = M.filter((e) => {
139
+ if (O) {
140
+ let t = f(e.placement);
141
+ return t === w || t === "y";
142
+ }
143
+ return !0;
144
+ }).map((e) => [e.placement, e.overflows.filter((e) => e > 0).reduce((e, t) => e + t, 0)]).sort((e, t) => e[1] - t[1])[0]?.[0];
145
+ e && (n = e);
146
+ break;
147
+ }
148
+ case "initialPlacement": n = p;
149
+ }
150
+ if (a !== n) return { reset: { placement: n } };
151
+ }
152
+ return {};
35
153
  }
36
- }
37
- function d(e, t) {
38
- return t();
39
- }
40
- var f = typeof window > "u" || window.document === void 0 || window.document.createElement === void 0 ? d : l;
41
- e.useSyncExternalStore = n.useSyncExternalStore === void 0 ? f : n.useSyncExternalStore;
42
- }));
154
+ };
155
+ }, x = /*#__PURE__*/ new Set(["left", "top"]);
156
+ async function S(e, r) {
157
+ let { placement: i, platform: a, elements: o } = e, s = await (a.isRTL == null ? void 0 : a.isRTL(o.floating)), c = d(i), l = n(i), u = f(i) === "y", p = x.has(c) ? -1 : 1, m = s && u ? -1 : 1, h = t(r, e), { mainAxis: g, crossAxis: _, alignmentAxis: v } = typeof h == "number" ? {
158
+ mainAxis: h,
159
+ crossAxis: 0,
160
+ alignmentAxis: null
161
+ } : {
162
+ mainAxis: h.mainAxis || 0,
163
+ crossAxis: h.crossAxis || 0,
164
+ alignmentAxis: h.alignmentAxis
165
+ };
166
+ return l && typeof v == "number" && (_ = l === "end" ? v * -1 : v), u ? {
167
+ x: _ * m,
168
+ y: g * p
169
+ } : {
170
+ x: g * p,
171
+ y: _ * m
172
+ };
173
+ }
174
+ var C = function(e) {
175
+ return e === void 0 && (e = 0), {
176
+ name: "offset",
177
+ options: e,
178
+ async fn(t) {
179
+ var n;
180
+ let { x: r, y: i, placement: a, middlewareData: o } = t, s = await S(t, e);
181
+ return a === o.offset?.placement && (n = o.arrow) != null && n.alignmentOffset ? {} : {
182
+ x: r + s.x,
183
+ y: i + s.y,
184
+ data: {
185
+ ...s,
186
+ placement: a
187
+ }
188
+ };
189
+ }
190
+ };
191
+ }, w = function(n) {
192
+ return n === void 0 && (n = {}), {
193
+ name: "shift",
194
+ options: n,
195
+ async fn(r) {
196
+ let { x: i, y: a, placement: o, platform: c } = r, { mainAxis: l = !0, crossAxis: u = !1, limiter: d = { fn: (e) => {
197
+ let { x: t, y: n } = e;
198
+ return {
199
+ x: t,
200
+ y: n
201
+ };
202
+ } }, ...p } = t(n, r), m = {
203
+ x: i,
204
+ y: a
205
+ }, h = await c.detectOverflow(r, p), g = f(o), _ = s(g), v = m[_], y = m[g], b = (t, n) => e(n + h[t === "y" ? "top" : "left"], n, n - h[t === "y" ? "bottom" : "right"]);
206
+ l && (v = b(_, v)), u && (y = b(g, y));
207
+ let x = d.fn({
208
+ ...r,
209
+ [_]: v,
210
+ [g]: y
211
+ });
212
+ return {
213
+ ...x,
214
+ data: {
215
+ x: x.x - i,
216
+ y: x.y - a,
217
+ enabled: {
218
+ [_]: l,
219
+ [g]: u
220
+ }
221
+ }
222
+ };
223
+ }
224
+ };
225
+ }, T = function(e) {
226
+ return e === void 0 && (e = {}), {
227
+ options: e,
228
+ fn(n) {
229
+ let { x: r, y: i, placement: a, rects: o, middlewareData: c } = n, { offset: l = 0, mainAxis: u = !0, crossAxis: p = !0 } = t(e, n), m = {
230
+ x: r,
231
+ y: i
232
+ }, h = f(a), g = s(h), _ = m[g], v = m[h], y = t(l, n), b = typeof y == "number" ? {
233
+ mainAxis: y,
234
+ crossAxis: 0
235
+ } : {
236
+ mainAxis: y.mainAxis ?? 0,
237
+ crossAxis: y.crossAxis ?? 0
238
+ };
239
+ if (u) {
240
+ let e = g === "y" ? "height" : "width", t = o.reference[g] - o.floating[e] + b.mainAxis, n = o.reference[g] + o.reference[e] - b.mainAxis;
241
+ _ < t ? _ = t : _ > n && (_ = n);
242
+ }
243
+ if (p) {
244
+ let e = g === "y" ? "width" : "height", t = x.has(d(a)), n = o.reference[h] - o.floating[e] + (t && c.offset?.[h] || 0) + (t ? 0 : b.crossAxis), r = o.reference[h] + o.reference[e] + (t ? 0 : c.offset?.[h] || 0) - (t ? b.crossAxis : 0);
245
+ v < n ? v = n : v > r && (v = r);
246
+ }
247
+ return {
248
+ [g]: _,
249
+ [h]: v
250
+ };
251
+ }
252
+ };
253
+ }, E = function(e) {
254
+ return e === void 0 && (e = {}), {
255
+ name: "size",
256
+ options: e,
257
+ async fn(r) {
258
+ let { placement: i, rects: a, platform: o, elements: s } = r, { apply: c = () => {}, ...l } = t(e, r), u = await o.detectOverflow(r, l), h = d(i), g = n(i), _ = f(i) === "y", { width: v, height: y } = a.floating, b, x;
259
+ h === "top" || h === "bottom" ? (b = h, x = g === (await (o.isRTL == null ? void 0 : o.isRTL(s.floating)) ? "start" : "end") ? "left" : "right") : (x = h, b = g === "end" ? "top" : "bottom");
260
+ let S = y - u.top - u.bottom, C = v - u.left - u.right, w = m(y - u[b], S), T = m(v - u[x], C), E = r.middlewareData.shift, D = !E, O = w, k = T;
261
+ E != null && E.enabled.x && (k = C), E != null && E.enabled.y && (O = S), D && !g && (_ ? k = v - 2 * p(u.left, u.right) : O = y - 2 * p(u.top, u.bottom)), await c({
262
+ ...r,
263
+ availableWidth: k,
264
+ availableHeight: O
265
+ });
266
+ let A = await o.getDimensions(s.floating);
267
+ return v !== A.width || y !== A.height ? { reset: { rects: !0 } } : {};
268
+ }
269
+ };
270
+ };
43
271
  //#endregion
44
- export default n();
45
- export { n as require_use_sync_external_store_shim_production };
272
+ export { y as computePosition, _ as detectOverflow, b as flip, T as limitShift, C as offset, h as rectToClientRect, w as shift, E as size };
46
273
 
47
274
  //# sourceMappingURL=index252.js.map