@rpcbase/ui 0.243.0 → 0.245.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 (518) hide show
  1. package/dist/index10.js +2 -2
  2. package/dist/index106.js +1 -1
  3. package/dist/index11.js +2 -2
  4. package/dist/index12.js +3 -3
  5. package/dist/index13.js +2 -2
  6. package/dist/index14.js +2 -2
  7. package/dist/index149.js +14 -5
  8. package/dist/index149.js.map +1 -1
  9. package/dist/index15.js +2 -2
  10. package/dist/index150.js +63 -63
  11. package/dist/index150.js.map +1 -1
  12. package/dist/index151.js +38 -2
  13. package/dist/index151.js.map +1 -1
  14. package/dist/index152.js +13 -385
  15. package/dist/index152.js.map +1 -1
  16. package/dist/index153.js +23 -261
  17. package/dist/index153.js.map +1 -1
  18. package/dist/index154.js +109 -58
  19. package/dist/index154.js.map +1 -1
  20. package/dist/index155.js +13 -47
  21. package/dist/index155.js.map +1 -1
  22. package/dist/index156.js +4 -169
  23. package/dist/index156.js.map +1 -1
  24. package/dist/index157.js +4 -110
  25. package/dist/index157.js.map +1 -1
  26. package/dist/index158.js +5 -25
  27. package/dist/index158.js.map +1 -1
  28. package/dist/index159.js +12 -8
  29. package/dist/index159.js.map +1 -1
  30. package/dist/index16.js +8 -8
  31. package/dist/index160.js +19 -4
  32. package/dist/index160.js.map +1 -1
  33. package/dist/index161.js +11 -6
  34. package/dist/index161.js.map +1 -1
  35. package/dist/index162.js +176 -4
  36. package/dist/index162.js.map +1 -1
  37. package/dist/index163.js +268 -476
  38. package/dist/index163.js.map +1 -1
  39. package/dist/index164.js +4 -189
  40. package/dist/index164.js.map +1 -1
  41. package/dist/index165.js +28 -14
  42. package/dist/index165.js.map +1 -1
  43. package/dist/index166.js +124 -105
  44. package/dist/index166.js.map +1 -1
  45. package/dist/index167.js +63 -262
  46. package/dist/index167.js.map +1 -1
  47. package/dist/index168.js +8 -6
  48. package/dist/index168.js.map +1 -1
  49. package/dist/index169.js +15 -40
  50. package/dist/index169.js.map +1 -1
  51. package/dist/index17.js +1 -1
  52. package/dist/index170.js +30 -4
  53. package/dist/index170.js.map +1 -1
  54. package/dist/index171.js +69 -14
  55. package/dist/index171.js.map +1 -1
  56. package/dist/index172.js +5 -68
  57. package/dist/index172.js.map +1 -1
  58. package/dist/index173.js +66 -35
  59. package/dist/index173.js.map +1 -1
  60. package/dist/index174.js +2 -14
  61. package/dist/index174.js.map +1 -1
  62. package/dist/index175.js +384 -22
  63. package/dist/index175.js.map +1 -1
  64. package/dist/index176.js +258 -108
  65. package/dist/index176.js.map +1 -1
  66. package/dist/index177.js +61 -13
  67. package/dist/index177.js.map +1 -1
  68. package/dist/index178.js +46 -4
  69. package/dist/index178.js.map +1 -1
  70. package/dist/index179.js +170 -4
  71. package/dist/index179.js.map +1 -1
  72. package/dist/index18.js +7 -7
  73. package/dist/index180.js +110 -5
  74. package/dist/index180.js.map +1 -1
  75. package/dist/index181.js +24 -11
  76. package/dist/index181.js.map +1 -1
  77. package/dist/index182.js +8 -20
  78. package/dist/index182.js.map +1 -1
  79. package/dist/index183.js +5 -11
  80. package/dist/index183.js.map +1 -1
  81. package/dist/index184.js +5 -176
  82. package/dist/index184.js.map +1 -1
  83. package/dist/index185.js +4 -279
  84. package/dist/index185.js.map +1 -1
  85. package/dist/index186.js +487 -4
  86. package/dist/index186.js.map +1 -1
  87. package/dist/index187.js +189 -27
  88. package/dist/index187.js.map +1 -1
  89. package/dist/index188.js +13 -126
  90. package/dist/index188.js.map +1 -1
  91. package/dist/index189.js +107 -63
  92. package/dist/index189.js.map +1 -1
  93. package/dist/index19.js +16 -16
  94. package/dist/index190.js +262 -8
  95. package/dist/index190.js.map +1 -1
  96. package/dist/index191.js +7 -16
  97. package/dist/index191.js.map +1 -1
  98. package/dist/index192.js +39 -29
  99. package/dist/index192.js.map +1 -1
  100. package/dist/index193.js +4 -69
  101. package/dist/index193.js.map +1 -1
  102. package/dist/index21.js +1 -1
  103. package/dist/index22.js +2 -2
  104. package/dist/index23.js +1 -1
  105. package/dist/index24.js +1 -1
  106. package/dist/index246.js +1 -1
  107. package/dist/index25.js +1 -1
  108. package/dist/index252.js +1 -1
  109. package/dist/index254.js +58 -146
  110. package/dist/index254.js.map +1 -1
  111. package/dist/index255.js +8 -32
  112. package/dist/index255.js.map +1 -1
  113. package/dist/index256.js +11 -11
  114. package/dist/index256.js.map +1 -1
  115. package/dist/index257.js +7 -48
  116. package/dist/index257.js.map +1 -1
  117. package/dist/index258.js +5 -9
  118. package/dist/index258.js.map +1 -1
  119. package/dist/index259.js +13 -11
  120. package/dist/index259.js.map +1 -1
  121. package/dist/index260.js +3 -43
  122. package/dist/index260.js.map +1 -1
  123. package/dist/index261.js +3 -97
  124. package/dist/index261.js.map +1 -1
  125. package/dist/index262.js +87 -74
  126. package/dist/index262.js.map +1 -1
  127. package/dist/index263.js +16 -104
  128. package/dist/index263.js.map +1 -1
  129. package/dist/index264.js +27 -50
  130. package/dist/index264.js.map +1 -1
  131. package/dist/index265.js +51 -11
  132. package/dist/index265.js.map +1 -1
  133. package/dist/index266.js +5 -4
  134. package/dist/index266.js.map +1 -1
  135. package/dist/index267.js +5 -37
  136. package/dist/index267.js.map +1 -1
  137. package/dist/index268.js +61 -8
  138. package/dist/index268.js.map +1 -1
  139. package/dist/index269.js +61 -130
  140. package/dist/index269.js.map +1 -1
  141. package/dist/index270.js +133 -17
  142. package/dist/index270.js.map +1 -1
  143. package/dist/index271.js +7 -14
  144. package/dist/index271.js.map +1 -1
  145. package/dist/index272.js +5 -4
  146. package/dist/index272.js.map +1 -1
  147. package/dist/index273.js +4 -37
  148. package/dist/index273.js.map +1 -1
  149. package/dist/index274.js +11 -20
  150. package/dist/index274.js.map +1 -1
  151. package/dist/index275.js +21 -8
  152. package/dist/index275.js.map +1 -1
  153. package/dist/index276.js +16 -9
  154. package/dist/index276.js.map +1 -1
  155. package/dist/index277.js +11 -24
  156. package/dist/index277.js.map +1 -1
  157. package/dist/index278.js +8 -29
  158. package/dist/index278.js.map +1 -1
  159. package/dist/index279.js +142 -14
  160. package/dist/index279.js.map +1 -1
  161. package/dist/index28.js +1 -1
  162. package/dist/index280.js +79 -19
  163. package/dist/index280.js.map +1 -1
  164. package/dist/index281.js +60 -65
  165. package/dist/index281.js.map +1 -1
  166. package/dist/index282.js +15 -7
  167. package/dist/index282.js.map +1 -1
  168. package/dist/index283.js +20 -6
  169. package/dist/index283.js.map +1 -1
  170. package/dist/index284.js +6 -11
  171. package/dist/index284.js.map +1 -1
  172. package/dist/index285.js +11 -3
  173. package/dist/index285.js.map +1 -1
  174. package/dist/index286.js +3 -50
  175. package/dist/index286.js.map +1 -1
  176. package/dist/index287.js +51 -4
  177. package/dist/index287.js.map +1 -1
  178. package/dist/index288.js +12 -25
  179. package/dist/index288.js.map +1 -1
  180. package/dist/index289.js +19 -14
  181. package/dist/index289.js.map +1 -1
  182. package/dist/index29.js +3 -56
  183. package/dist/index29.js.map +1 -1
  184. package/dist/index290.js +53 -5
  185. package/dist/index290.js.map +1 -1
  186. package/dist/index291.js +20 -21
  187. package/dist/index291.js.map +1 -1
  188. package/dist/index292.js +41 -53
  189. package/dist/index292.js.map +1 -1
  190. package/dist/index293.js +38 -19
  191. package/dist/index293.js.map +1 -1
  192. package/dist/index294.js +46 -42
  193. package/dist/index294.js.map +1 -1
  194. package/dist/index295.js +19 -38
  195. package/dist/index295.js.map +1 -1
  196. package/dist/index296.js +71 -46
  197. package/dist/index296.js.map +1 -1
  198. package/dist/index297.js +17 -20
  199. package/dist/index297.js.map +1 -1
  200. package/dist/index298.js +3 -70
  201. package/dist/index298.js.map +1 -1
  202. package/dist/index299.js +12 -16
  203. package/dist/index299.js.map +1 -1
  204. package/dist/index3.js +2 -2
  205. package/dist/index30.js +242 -3
  206. package/dist/index30.js.map +1 -1
  207. package/dist/index300.js +18 -3
  208. package/dist/index300.js.map +1 -1
  209. package/dist/index301.js +36 -11
  210. package/dist/index301.js.map +1 -1
  211. package/dist/index302.js +238 -12
  212. package/dist/index302.js.map +1 -1
  213. package/dist/index303.js +249 -15
  214. package/dist/index303.js.map +1 -1
  215. package/dist/index304.js +67 -35
  216. package/dist/index304.js.map +1 -1
  217. package/dist/index305.js +77 -233
  218. package/dist/index305.js.map +1 -1
  219. package/dist/index306.js +3 -252
  220. package/dist/index306.js.map +1 -1
  221. package/dist/index307.js +29 -68
  222. package/dist/index307.js.map +1 -1
  223. package/dist/index308.js +16 -99
  224. package/dist/index308.js.map +1 -1
  225. package/dist/index309.js +33 -82
  226. package/dist/index309.js.map +1 -1
  227. package/dist/index31.js +21 -239
  228. package/dist/index31.js.map +1 -1
  229. package/dist/index310.js +17 -3
  230. package/dist/index310.js.map +1 -1
  231. package/dist/index311.js +3 -29
  232. package/dist/index311.js.map +1 -1
  233. package/dist/index312.js +26 -16
  234. package/dist/index312.js.map +1 -1
  235. package/dist/index313.js +28 -34
  236. package/dist/index313.js.map +1 -1
  237. package/dist/index314.js +4 -18
  238. package/dist/index314.js.map +1 -1
  239. package/dist/index315.js +78 -3
  240. package/dist/index315.js.map +1 -1
  241. package/dist/index316.js +269 -23
  242. package/dist/index316.js.map +1 -1
  243. package/dist/index317.js +10 -27
  244. package/dist/index317.js.map +1 -1
  245. package/dist/index318.js +11 -4
  246. package/dist/index318.js.map +1 -1
  247. package/dist/index319.js +24 -77
  248. package/dist/index319.js.map +1 -1
  249. package/dist/index32.js +4 -23
  250. package/dist/index32.js.map +1 -1
  251. package/dist/index320.js +15 -271
  252. package/dist/index320.js.map +1 -1
  253. package/dist/index321.js +125 -11
  254. package/dist/index321.js.map +1 -1
  255. package/dist/index322.js +5 -10
  256. package/dist/index322.js.map +1 -1
  257. package/dist/index323.js +64 -24
  258. package/dist/index323.js.map +1 -1
  259. package/dist/index324.js +14 -17
  260. package/dist/index324.js.map +1 -1
  261. package/dist/index325.js +7 -125
  262. package/dist/index325.js.map +1 -1
  263. package/dist/index326.js +5 -5
  264. package/dist/index326.js.map +1 -1
  265. package/dist/index327.js +3 -65
  266. package/dist/index327.js.map +1 -1
  267. package/dist/index328.js +10 -13
  268. package/dist/index328.js.map +1 -1
  269. package/dist/index329.js +7 -7
  270. package/dist/index329.js.map +1 -1
  271. package/dist/index33.js +6 -3
  272. package/dist/index33.js.map +1 -1
  273. package/dist/index330.js +399 -5
  274. package/dist/index330.js.map +1 -1
  275. package/dist/index331.js +5 -4
  276. package/dist/index331.js.map +1 -1
  277. package/dist/index332.js +52 -10
  278. package/dist/index332.js.map +1 -1
  279. package/dist/index333.js +10 -6
  280. package/dist/index333.js.map +1 -1
  281. package/dist/index334.js +22 -128
  282. package/dist/index334.js.map +1 -1
  283. package/dist/index335.js +11 -399
  284. package/dist/index335.js.map +1 -1
  285. package/dist/index336.js +155 -5
  286. package/dist/index336.js.map +1 -1
  287. package/dist/index337.js +31 -51
  288. package/dist/index337.js.map +1 -1
  289. package/dist/index338.js +11 -11
  290. package/dist/index338.js.map +1 -1
  291. package/dist/index339.js +45 -23
  292. package/dist/index339.js.map +1 -1
  293. package/dist/index34.js +38 -8
  294. package/dist/index34.js.map +1 -1
  295. package/dist/index340.js +9 -11
  296. package/dist/index340.js.map +1 -1
  297. package/dist/index341.js +11 -8
  298. package/dist/index341.js.map +1 -1
  299. package/dist/index342.js +43 -11
  300. package/dist/index342.js.map +1 -1
  301. package/dist/index343.js +96 -7
  302. package/dist/index343.js.map +1 -1
  303. package/dist/index344.js +84 -11
  304. package/dist/index344.js.map +1 -1
  305. package/dist/index345.js +105 -3
  306. package/dist/index345.js.map +1 -1
  307. package/dist/index346.js +52 -3
  308. package/dist/index346.js.map +1 -1
  309. package/dist/index347.js +10 -16
  310. package/dist/index347.js.map +1 -1
  311. package/dist/index348.js +4 -61
  312. package/dist/index348.js.map +1 -1
  313. package/dist/index349.js +34 -63
  314. package/dist/index349.js.map +1 -1
  315. package/dist/index35.js +74 -35
  316. package/dist/index35.js.map +1 -1
  317. package/dist/index350.js +8 -51
  318. package/dist/index350.js.map +1 -1
  319. package/dist/index351.js +135 -5
  320. package/dist/index351.js.map +1 -1
  321. package/dist/index352.js +17 -8
  322. package/dist/index352.js.map +1 -1
  323. package/dist/index353.js +16 -5
  324. package/dist/index353.js.map +1 -1
  325. package/dist/index354.js +3 -11
  326. package/dist/index354.js.map +1 -1
  327. package/dist/index355.js +34 -19
  328. package/dist/index355.js.map +1 -1
  329. package/dist/index356.js +20 -16
  330. package/dist/index356.js.map +1 -1
  331. package/dist/index357.js +10 -8
  332. package/dist/index357.js.map +1 -1
  333. package/dist/index358.js +8 -144
  334. package/dist/index358.js.map +1 -1
  335. package/dist/index359.js +22 -77
  336. package/dist/index359.js.map +1 -1
  337. package/dist/index36.js +20 -74
  338. package/dist/index36.js.map +1 -1
  339. package/dist/index360.js +28 -61
  340. package/dist/index360.js.map +1 -1
  341. package/dist/index361.js +17 -15
  342. package/dist/index361.js.map +1 -1
  343. package/dist/index363.js +5 -5
  344. package/dist/index365.js +8 -4
  345. package/dist/index365.js.map +1 -1
  346. package/dist/index366.js +27 -21
  347. package/dist/index366.js.map +1 -1
  348. package/dist/index367.js +138 -4
  349. package/dist/index367.js.map +1 -1
  350. package/dist/index368.js +11 -10
  351. package/dist/index368.js.map +1 -1
  352. package/dist/index369.js +46 -5
  353. package/dist/index369.js.map +1 -1
  354. package/dist/index37.js +33 -18
  355. package/dist/index37.js.map +1 -1
  356. package/dist/index370.js +4 -3
  357. package/dist/index370.js.map +1 -1
  358. package/dist/index371.js +20 -19
  359. package/dist/index371.js.map +1 -1
  360. package/dist/index372.js +75 -44
  361. package/dist/index372.js.map +1 -1
  362. package/dist/index373.js +11 -17
  363. package/dist/index373.js.map +1 -1
  364. package/dist/index374.js +4 -5
  365. package/dist/index374.js.map +1 -1
  366. package/dist/index375.js +70 -197
  367. package/dist/index375.js.map +1 -1
  368. package/dist/index376.js +197 -70
  369. package/dist/index376.js.map +1 -1
  370. package/dist/index377.js +66 -118
  371. package/dist/index377.js.map +1 -1
  372. package/dist/index378.js +35 -8
  373. package/dist/index378.js.map +1 -1
  374. package/dist/index379.js +7 -27
  375. package/dist/index379.js.map +1 -1
  376. package/dist/index38.js +26 -36
  377. package/dist/index38.js.map +1 -1
  378. package/dist/index380.js +14 -136
  379. package/dist/index380.js.map +1 -1
  380. package/dist/index381.js +121 -10
  381. package/dist/index381.js.map +1 -1
  382. package/dist/index382.js +4 -47
  383. package/dist/index382.js.map +1 -1
  384. package/dist/index383.js +11 -3
  385. package/dist/index383.js.map +1 -1
  386. package/dist/index384.js +5 -21
  387. package/dist/index384.js.map +1 -1
  388. package/dist/index385.js +3 -76
  389. package/dist/index385.js.map +1 -1
  390. package/dist/index386.js +21 -12
  391. package/dist/index386.js.map +1 -1
  392. package/dist/index387.js +45 -4
  393. package/dist/index387.js.map +1 -1
  394. package/dist/index388.js +16 -70
  395. package/dist/index388.js.map +1 -1
  396. package/dist/index389.js +5 -36
  397. package/dist/index389.js.map +1 -1
  398. package/dist/index39.js +21 -26
  399. package/dist/index39.js.map +1 -1
  400. package/dist/index390.js +5 -7
  401. package/dist/index390.js.map +1 -1
  402. package/dist/index391.js +20 -15
  403. package/dist/index391.js.map +1 -1
  404. package/dist/index399.js +2 -2
  405. package/dist/index4.js +2 -2
  406. package/dist/index40.js +56 -20
  407. package/dist/index40.js.map +1 -1
  408. package/dist/index409.js +3 -3
  409. package/dist/index409.js.map +1 -1
  410. package/dist/index41.js +51 -59
  411. package/dist/index41.js.map +1 -1
  412. package/dist/index410.js +15 -3
  413. package/dist/index410.js.map +1 -1
  414. package/dist/index411.js +488 -11
  415. package/dist/index411.js.map +1 -1
  416. package/dist/index412.js +3 -3
  417. package/dist/index412.js.map +1 -1
  418. package/dist/index413.js +3 -492
  419. package/dist/index413.js.map +1 -1
  420. package/dist/index414.js +5 -68
  421. package/dist/index414.js.map +1 -1
  422. package/dist/index415.js +55 -30
  423. package/dist/index415.js.map +1 -1
  424. package/dist/index416.js +68 -9
  425. package/dist/index416.js.map +1 -1
  426. package/dist/index417.js +26 -148
  427. package/dist/index417.js.map +1 -1
  428. package/dist/index418.js +9 -108
  429. package/dist/index418.js.map +1 -1
  430. package/dist/index419.js +153 -5
  431. package/dist/index419.js.map +1 -1
  432. package/dist/index42.js +21 -50
  433. package/dist/index42.js.map +1 -1
  434. package/dist/index420.js +106 -54
  435. package/dist/index420.js.map +1 -1
  436. package/dist/index421.js +32 -7
  437. package/dist/index421.js.map +1 -1
  438. package/dist/index422.js +8 -2
  439. package/dist/index422.js.map +1 -1
  440. package/dist/index423.js +2 -44
  441. package/dist/index423.js.map +1 -1
  442. package/dist/index424.js +40 -52
  443. package/dist/index424.js.map +1 -1
  444. package/dist/index425.js +55 -7
  445. package/dist/index425.js.map +1 -1
  446. package/dist/index426.js +8 -2
  447. package/dist/index426.js.map +1 -1
  448. package/dist/index427.js +2 -55
  449. package/dist/index427.js.map +1 -1
  450. package/dist/index428.js +52 -53
  451. package/dist/index428.js.map +1 -1
  452. package/dist/index429.js +55 -32
  453. package/dist/index429.js.map +1 -1
  454. package/dist/index43.js +127 -18
  455. package/dist/index43.js.map +1 -1
  456. package/dist/index44.js +39 -122
  457. package/dist/index44.js.map +1 -1
  458. package/dist/index45.js +85 -42
  459. package/dist/index45.js.map +1 -1
  460. package/dist/index46.js +123 -87
  461. package/dist/index46.js.map +1 -1
  462. package/dist/index47.js +5 -126
  463. package/dist/index47.js.map +1 -1
  464. package/dist/index48.js +332 -5
  465. package/dist/index48.js.map +1 -1
  466. package/dist/index49.js +246 -321
  467. package/dist/index49.js.map +1 -1
  468. package/dist/index5.js +2 -2
  469. package/dist/index50.js +23 -254
  470. package/dist/index50.js.map +1 -1
  471. package/dist/index51.js +129 -25
  472. package/dist/index51.js.map +1 -1
  473. package/dist/index52.js +24 -129
  474. package/dist/index52.js.map +1 -1
  475. package/dist/index53.js +19 -22
  476. package/dist/index53.js.map +1 -1
  477. package/dist/index54.js +134 -19
  478. package/dist/index54.js.map +1 -1
  479. package/dist/index55.js +30 -133
  480. package/dist/index55.js.map +1 -1
  481. package/dist/index56.js +24 -30
  482. package/dist/index56.js.map +1 -1
  483. package/dist/index57.js +38 -26
  484. package/dist/index57.js.map +1 -1
  485. package/dist/index58.js +19 -39
  486. package/dist/index58.js.map +1 -1
  487. package/dist/index59.js +133 -18
  488. package/dist/index59.js.map +1 -1
  489. package/dist/index6.js +4 -4
  490. package/dist/index60.js +49 -134
  491. package/dist/index60.js.map +1 -1
  492. package/dist/index61.js +25 -48
  493. package/dist/index61.js.map +1 -1
  494. package/dist/index62.js +57 -28
  495. package/dist/index62.js.map +1 -1
  496. package/dist/index63.js +56 -57
  497. package/dist/index63.js.map +1 -1
  498. package/dist/index64.js +5 -5
  499. package/dist/index64.js.map +1 -1
  500. package/dist/index66.js +22 -10
  501. package/dist/index66.js.map +1 -1
  502. package/dist/index67.js +232 -17
  503. package/dist/index67.js.map +1 -1
  504. package/dist/index68.js +5 -5
  505. package/dist/index68.js.map +1 -1
  506. package/dist/index7.js +11 -11
  507. package/dist/index70.js +10 -22
  508. package/dist/index70.js.map +1 -1
  509. package/dist/index71.js +17 -232
  510. package/dist/index71.js.map +1 -1
  511. package/dist/index76.js +1 -1
  512. package/dist/index77.js +2 -2
  513. package/dist/index77.js.map +1 -1
  514. package/dist/index78.js +2 -2
  515. package/dist/index78.js.map +1 -1
  516. package/dist/index8.js +2 -2
  517. package/dist/index9.js +1 -1
  518. package/package.json +1 -1
package/dist/index163.js CHANGED
@@ -1,491 +1,283 @@
1
- import h from "./index265.js";
2
- import l from "./index170.js";
3
- import v from "./index266.js";
4
- function o(n) {
5
- "@babel/helpers - typeof";
6
- return o = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
7
- return typeof t;
8
- } : function(t) {
9
- return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
10
- }, o(n);
1
+ import * as E from "react";
2
+ import { isHTMLElement as q, getNodeName as Se, getWindow as Be } from "./index270.js";
3
+ import { addEventListener as I } from "./index322.js";
4
+ import { mergeCleanups as ge } from "./index365.js";
5
+ import { useMergedRefs as Ee } from "./index254.js";
6
+ import { useValueAsRef as $ } from "./index288.js";
7
+ import { useStableCallback as oe } from "./index264.js";
8
+ import { useIsoLayoutEffect as W } from "./index273.js";
9
+ import { useTimeout as Fe } from "./index307.js";
10
+ import { useAnimationFrame as Ue } from "./index323.js";
11
+ import { ownerDocument as O } from "./index306.js";
12
+ import { FocusGuard as Te } from "./index366.js";
13
+ import { isTypeableCombobox as xe, getFloatingFocusElement as ye, isTypeableElement as $e } from "./index312.js";
14
+ import { isVirtualClick as ze, isVirtualPointerEvent as Je, stopEvent as Qe } from "./index334.js";
15
+ import { isOutsideEvent as Ie, getNextTabbable as Xe, getPreviousTabbable as Ye, tabbable as De, isTabbable as ie, focusable as Ze } from "./index367.js";
16
+ import { getNodeAncestors as ve, getNodeChildren as he } from "./index368.js";
17
+ import { isElementVisible as et } from "./index369.js";
18
+ import { createChangeEventDetails as tt } from "./index153.js";
19
+ import { createAttribute as Ae } from "./index370.js";
20
+ import { enqueueFocus as se } from "./index371.js";
21
+ import { markOthers as Ce } from "./index372.js";
22
+ import { usePortalContext as nt } from "./index166.js";
23
+ import { useFloatingTree as rt } from "./index373.js";
24
+ import { CLICK_TRIGGER_IDENTIFIER as ot } from "./index169.js";
25
+ import { resolveRef as w } from "./index374.js";
26
+ import { j as ue } from "./index28.js";
27
+ import { activeElement as N, contains as c, getTarget as z } from "./index313.js";
28
+ import { triggerHover as st, outsidePress as ut, focusOut as it } from "./index155.js";
29
+ import { webkit as ct } from "./index331.js";
30
+ function ft(n, D) {
31
+ const M = Be(z(n));
32
+ return n instanceof M.KeyboardEvent ? "keyboard" : n instanceof M.FocusEvent ? D || "keyboard" : "pointerType" in n ? n.pointerType || "keyboard" : "touches" in n ? "touch" : n instanceof M.MouseEvent ? D || (n.detail === 0 ? "keyboard" : "mouse") : "";
11
33
  }
12
- function u(n, t) {
13
- if (!(n instanceof t)) throw new TypeError("Cannot call a class as a function");
34
+ const ke = 20;
35
+ let S = [];
36
+ function ce() {
37
+ S = S.filter((n) => n.deref()?.isConnected);
14
38
  }
15
- function d(n, t) {
16
- for (var e = 0; e < t.length; e++) {
17
- var a = t[e];
18
- a.enumerable = a.enumerable || !1, a.configurable = !0, "value" in a && (a.writable = !0), Object.defineProperty(n, P(a.key), a);
19
- }
39
+ function Oe(n) {
40
+ ce(), n && Se(n) !== "body" && (S.push(new WeakRef(n)), S.length > ke && (S = S.slice(-ke)));
20
41
  }
21
- function s(n, t, e) {
22
- return t && d(n.prototype, t), Object.defineProperty(n, "prototype", { writable: !1 }), n;
42
+ function we() {
43
+ return ce(), S[S.length - 1]?.deref();
23
44
  }
24
- function P(n) {
25
- var t = C(n, "string");
26
- return o(t) == "symbol" ? t : t + "";
45
+ function at(n) {
46
+ return n ? ie(n) ? n : De(n)[0] || n : null;
27
47
  }
28
- function C(n, t) {
29
- if (o(n) != "object" || !n) return n;
30
- var e = n[Symbol.toPrimitive];
31
- if (e !== void 0) {
32
- var a = e.call(n, t);
33
- if (o(a) != "object") return a;
34
- throw new TypeError("@@toPrimitive must return a primitive value.");
35
- }
36
- return String(n);
48
+ function Ne(n) {
49
+ if (n.hasAttribute("tabindex") && !n.hasAttribute("data-tabindex") || !n.getAttribute("role")?.includes("dialog"))
50
+ return;
51
+ const M = Ze(n).filter((P) => {
52
+ const J = P.getAttribute("data-tabindex") || "";
53
+ return ie(P) || P.hasAttribute("data-tabindex") && !J.startsWith("-");
54
+ }), f = n.getAttribute("tabindex");
55
+ M.length === 0 ? f !== "0" && (n.setAttribute("tabindex", "0"), n.setAttribute("data-tabindex", "0")) : (f !== "-1" || n.hasAttribute("data-tabindex") && n.getAttribute("data-tabindex") !== "-1") && (n.setAttribute("tabindex", "-1"), n.setAttribute("data-tabindex", "-1"));
37
56
  }
38
- var p = "1.2.0", b = "1.7.35", g = " ext. ", F = /* @__PURE__ */ (function() {
39
- function n(t) {
40
- u(this, n), N(t), this.metadata = t, m.call(this, t);
41
- }
42
- return s(n, [{
43
- key: "getCountries",
44
- value: function() {
45
- return Object.keys(this.metadata.countries).filter(function(e) {
46
- return e !== "001";
57
+ function Lt(n) {
58
+ const {
59
+ context: D,
60
+ children: M,
61
+ disabled: f = !1,
62
+ initialFocus: P = !0,
63
+ returnFocus: J = !0,
64
+ restoreFocus: Q = !1,
65
+ modal: g = !0,
66
+ closeOnFocusOut: L = !0,
67
+ openInteractionType: Me = "",
68
+ nextFocusableElement: j,
69
+ previousFocusableElement: H,
70
+ beforeContentFocusGuardRef: Pe,
71
+ externalTree: Ge,
72
+ getInsideElements: Ve
73
+ } = n, v = "rootStore" in D ? D.rootStore : D, T = v.useState("open"), d = v.useState("domReferenceElement"), i = v.useState("floatingElement"), {
74
+ events: X,
75
+ dataRef: G
76
+ } = v.context, V = oe(() => G.current.floatingContext?.nodeId), qe = P === !1, h = xe(d) && qe, fe = $(P), Y = $(J), _ = $(Me), ae = $(T), x = rt(Ge), s = nt(), y = E.useRef(!1), K = E.useRef(!1), Z = E.useRef(!1), le = E.useRef(null), de = E.useRef(""), ee = E.useRef(""), te = E.useRef(null), ne = E.useRef(null), Le = Ee(te, Pe, s?.beforeInsideRef), je = Ee(ne, s?.afterInsideRef), me = Fe(), B = Fe(), be = Ue(), He = s != null, o = ye(i), C = oe((r = o) => r ? De(r) : []), k = oe(() => Ve?.().filter((r) => r != null) ?? []);
77
+ E.useEffect(() => {
78
+ if (f || !g)
79
+ return;
80
+ function r(b) {
81
+ b.key === "Tab" && c(o, N(O(o))) && C().length === 0 && !h && Qe(b);
82
+ }
83
+ const a = O(o);
84
+ return I(a, "keydown", r);
85
+ }, [f, o, g, h, C]), E.useEffect(() => {
86
+ if (f || !T)
87
+ return;
88
+ const r = O(o);
89
+ function a() {
90
+ Z.current = !1;
91
+ }
92
+ function b(A) {
93
+ const e = z(A), u = k(), t = c(i, e) || c(d, e) || c(s?.portalNode, e) || u.some((l) => l === e || c(l, e));
94
+ Z.current = !t, ee.current = A.pointerType || "keyboard", e?.closest(`[${ot}]`) && (K.current = !0, B.start(0, () => {
95
+ K.current = !1;
96
+ }));
97
+ }
98
+ function p() {
99
+ ee.current = "keyboard";
100
+ }
101
+ return ge(
102
+ I(r, "pointerdown", b, !0),
103
+ I(r, "pointerup", a, !0),
104
+ I(r, "pointercancel", a, !0),
105
+ I(r, "keydown", p, !0),
106
+ // Avoid a stale `true` leaking into the next open (e.g. keep-mounted popups)
107
+ // if the popup dismissed between pointerdown and pointerup.
108
+ a
109
+ );
110
+ }, [f, i, d, o, T, s, B, k]), E.useEffect(() => {
111
+ if (f || !L)
112
+ return;
113
+ const r = O(o);
114
+ function a() {
115
+ K.current = !0, B.start(0, () => {
116
+ K.current = !1;
47
117
  });
48
118
  }
49
- }, {
50
- key: "getCountryMetadata",
51
- value: function(e) {
52
- return this.metadata.countries[e];
53
- }
54
- }, {
55
- key: "nonGeographic",
56
- value: function() {
57
- if (!(this.v1 || this.v2 || this.v3))
58
- return this.metadata.nonGeographic || this.metadata.nonGeographical;
59
- }
60
- }, {
61
- key: "hasCountry",
62
- value: function(e) {
63
- return this.getCountryMetadata(e) !== void 0;
119
+ function b(u) {
120
+ const t = z(u);
121
+ ie(t) && (le.current = t);
122
+ }
123
+ function p(u) {
124
+ const t = u.relatedTarget, l = u.currentTarget, R = z(u);
125
+ g && t == null && R != null && c(i, R) && Oe(R), queueMicrotask(() => {
126
+ const F = V(), U = v.context.triggerElements, Ke = k(), We = t?.hasAttribute(Ae("focus-guard")) && [te.current, ne.current, s?.beforeInsideRef.current, s?.afterInsideRef.current, s?.beforeOutsideRef.current, s?.afterOutsideRef.current, w(H), w(j)].includes(t), _e = !(c(d, t) || c(i, t) || c(t, i) || c(s?.portalNode, t) || Ke.some((m) => m === t || c(m, t)) || t != null && U.hasElement(t) || U.hasMatchingElement((m) => c(m, t)) || We || x && (he(x.nodesRef.current, F).find((m) => c(m.context?.elements.floating, t) || c(m.context?.elements.domReference, t)) || ve(x.nodesRef.current, F).find((m) => [m.context?.elements.floating, ye(m.context?.elements.floating)].includes(t) || m.context?.elements.domReference === t)));
127
+ if (l === d && o && Ne(o), Q && l !== d && !et(R) && N(r) === r.body) {
128
+ if (q(o) && (o.focus(), Q === "popup")) {
129
+ be.request(() => {
130
+ o.focus();
131
+ });
132
+ return;
133
+ }
134
+ const m = C(), re = le.current, Re = (re && m.includes(re) ? re : null) || m[m.length - 1] || o;
135
+ q(Re) && Re.focus();
136
+ }
137
+ if (G.current.insideReactTree) {
138
+ G.current.insideReactTree = !1;
139
+ return;
140
+ }
141
+ (h || !g) && t && _e && !K.current && // Fix React 18 Strict Mode returnFocus due to double rendering.
142
+ // For an "untrapped" typeable combobox (input role=combobox with
143
+ // initialFocus=false), re-opening the popup and tabbing out should still close it even
144
+ // when the previously focused element (e.g. the next tabbable outside the popup) is
145
+ // focused again. Otherwise, the popup remains open on the second Tab sequence:
146
+ // click input -> Tab (closes) -> click input -> Tab.
147
+ // Allow closing when `isUntrappedTypeableCombobox` regardless of the previously focused element.
148
+ (h || t !== we()) && (y.current = !0, v.setOpen(!1, tt(it, u)));
149
+ });
64
150
  }
65
- }, {
66
- key: "hasCallingCode",
67
- value: function(e) {
68
- if (this.getCountryCodesForCallingCode(e))
69
- return !0;
70
- if (this.nonGeographic()) {
71
- if (this.nonGeographic()[e])
72
- return !0;
73
- } else {
74
- var a = this.countryCallingCodes()[e];
75
- if (a && a.length === 1 && a[0] === "001")
76
- return !0;
151
+ function A() {
152
+ Z.current || (G.current.insideReactTree = !0, me.start(0, () => {
153
+ G.current.insideReactTree = !1;
154
+ }));
155
+ }
156
+ const e = q(d) ? d : null;
157
+ if (!(!i && !e))
158
+ return ge(e && I(e, "focusout", p), e && I(e, "pointerdown", a), i && I(i, "focusin", b), i && I(i, "focusout", p), i && s && I(i, "focusout", A, !0));
159
+ }, [f, d, i, o, g, x, s, v, L, Q, C, h, V, G, me, B, be, j, H, k]), E.useEffect(() => {
160
+ if (f || !i || !T)
161
+ return;
162
+ const r = Array.from(s?.portalNode?.querySelectorAll(`[${Ae("portal")}]`) || []), b = (x ? ve(x.nodesRef.current, V()) : []).find((l) => xe(l.context?.elements.domReference || null))?.context?.elements.domReference, A = [...[i, ...r, te.current, ne.current, s?.beforeOutsideRef.current, s?.afterOutsideRef.current, ...k()], b, w(H), w(j), h ? d : null].filter((l) => l != null), e = Ce(A, {
163
+ ariaHidden: g || h,
164
+ mark: !1
165
+ }), u = [i, ...r].filter((l) => l != null), t = Ce(u);
166
+ return () => {
167
+ t(), e();
168
+ };
169
+ }, [T, f, d, i, g, s, h, x, V, j, H, k]), W(() => {
170
+ if (!T || f || !q(o))
171
+ return;
172
+ const r = O(o), a = N(r);
173
+ queueMicrotask(() => {
174
+ const b = fe.current, p = typeof b == "function" ? b(_.current || "") : b;
175
+ if (p === void 0 || p === !1 || c(o, a))
176
+ return;
177
+ let e = null;
178
+ const u = () => (e == null && (e = C(o)), e[0] || o);
179
+ let t;
180
+ p === !0 || p === null ? t = u() : t = w(p), t = t || u();
181
+ const l = c(o, N(r));
182
+ se(t, {
183
+ preventScroll: t === o,
184
+ shouldFocus() {
185
+ if (!ae.current)
186
+ return !1;
187
+ if (l)
188
+ return !0;
189
+ const R = N(r);
190
+ return !(R !== t && c(o, R));
191
+ }
192
+ });
193
+ });
194
+ }, [f, T, o, C, fe, _, ae]), W(() => {
195
+ if (f || !o)
196
+ return;
197
+ const r = O(o), a = N(r), b = _.current == null;
198
+ Oe(a);
199
+ function p(e) {
200
+ if (e.open || (de.current = ft(e.nativeEvent, ee.current)), e.reason === st && e.nativeEvent.type === "mouseleave" && (y.current = !0), e.reason === ut)
201
+ if (e.nested)
202
+ y.current = !1;
203
+ else if (ze(e.nativeEvent) || Je(e.nativeEvent))
204
+ y.current = !1;
205
+ else {
206
+ let u = !1;
207
+ O(o).createElement("div").focus({
208
+ get preventScroll() {
209
+ return u = !0, !1;
210
+ }
211
+ }), u ? y.current = !1 : y.current = !0;
212
+ }
213
+ }
214
+ X.on("openchange", p);
215
+ function A() {
216
+ const e = Y.current;
217
+ let u = typeof e == "function" ? e(de.current) : e;
218
+ if (u === void 0 || u === !1)
219
+ return null;
220
+ u === null && (u = !0);
221
+ const t = d?.isConnected ? d : null, l = a?.isConnected && Se(a) !== "body" ? a : null;
222
+ let R = b ? l || t : t || l;
223
+ return R || (R = we() || null), typeof u == "boolean" ? R : w(u) || R || null;
224
+ }
225
+ return () => {
226
+ X.off("openchange", p);
227
+ const e = N(r), u = k(), t = c(i, e) || u.some((F) => F === e || c(F, e)) || x && he(x.nodesRef.current, V(), !1).some((F) => c(F.context?.elements.floating, e)), l = Y.current, R = A();
228
+ queueMicrotask(() => {
229
+ const F = at(R), U = typeof l != "boolean";
230
+ l && !y.current && q(F) && // If the focus moved somewhere else after mount, avoid returning focus
231
+ // since it likely entered a different element which should be
232
+ // respected: https://github.com/floating-ui/floating-ui/issues/2607
233
+ (!(!U && F !== e && e !== r.body) || t) && F.focus({
234
+ preventScroll: !0
235
+ }), y.current = !1;
236
+ });
237
+ };
238
+ }, [f, i, o, Y, _, X, x, d, V, k]), W(() => {
239
+ if (!ct || T || !i)
240
+ return;
241
+ const r = N(O(i));
242
+ !q(r) || !$e(r) || c(i, r) && r.blur();
243
+ }, [T, i]), W(() => {
244
+ if (!(f || !s))
245
+ return s.setFocusManagerState({
246
+ modal: g,
247
+ closeOnFocusOut: L,
248
+ open: T,
249
+ onOpenChange: v.setOpen,
250
+ domReference: d
251
+ }), () => {
252
+ s.setFocusManagerState(null);
253
+ };
254
+ }, [f, s, g, T, v, L, d]), W(() => {
255
+ if (!(f || !o))
256
+ return Ne(o), () => {
257
+ queueMicrotask(ce);
258
+ };
259
+ }, [f, o]);
260
+ const pe = !f && (g ? !h : !0) && (He || g);
261
+ return /* @__PURE__ */ ue.jsxs(E.Fragment, {
262
+ children: [pe && /* @__PURE__ */ ue.jsx(Te, {
263
+ "data-type": "inside",
264
+ ref: Le,
265
+ onFocus: (r) => {
266
+ if (g) {
267
+ const a = C();
268
+ se(a[a.length - 1]);
269
+ } else s?.portalNode && (y.current = !1, Ie(r, s.portalNode) ? Xe(d)?.focus() : w(H ?? s.beforeOutsideRef)?.focus());
77
270
  }
78
- }
79
- }, {
80
- key: "isNonGeographicCallingCode",
81
- value: function(e) {
82
- return this.nonGeographic() ? !!this.nonGeographic()[e] : !this.getCountryCodesForCallingCode(e);
83
- }
84
- // Deprecated.
85
- }, {
86
- key: "country",
87
- value: function(e) {
88
- return this.selectNumberingPlan(e);
89
- }
90
- /**
91
- * Selects a telephone numbering plan based on either a country code or a calling code.
92
- * @param {string} argument — Country code or calling code.
93
- * @param {string} legacyArgumentCallingCode — Legacy argument: calling code, if the first argument is not passed.
94
- */
95
- }, {
96
- key: "selectNumberingPlan",
97
- value: function(e, a) {
98
- var i, r;
99
- if (e && (v(e) ? r = e : i = e), a && (r = a), i && i !== "001") {
100
- var f = this.getCountryMetadata(i);
101
- if (!f)
102
- throw new Error("Unknown country: ".concat(i));
103
- this.numberingPlan = new c(f, this);
104
- } else if (r) {
105
- if (!this.hasCallingCode(r))
106
- throw new Error("Unknown calling code: ".concat(r));
107
- this.numberingPlan = new c(this.getNumberingPlanMetadata(r), this);
108
- } else
109
- this.numberingPlan = void 0;
110
- return this;
111
- }
112
- }, {
113
- key: "getCountryCodesForCallingCode",
114
- value: function(e) {
115
- var a = this.countryCallingCodes()[e];
116
- if (a)
117
- return a.length === 1 && a[0].length === 3 ? void 0 : a;
118
- }
119
- }, {
120
- key: "getCountryCodeForCallingCode",
121
- value: function(e) {
122
- var a = this.getCountryCodesForCallingCode(e);
123
- if (a)
124
- return a[0];
125
- }
126
- }, {
127
- key: "getNumberingPlanMetadata",
128
- value: function(e) {
129
- var a = this.getCountryCodeForCallingCode(e);
130
- if (a)
131
- return this.getCountryMetadata(a);
132
- if (this.nonGeographic()) {
133
- var i = this.nonGeographic()[e];
134
- if (i)
135
- return i;
136
- } else {
137
- var r = this.countryCallingCodes()[e];
138
- if (r && r.length === 1 && r[0] === "001")
139
- return this.metadata.countries["001"];
271
+ }), M, pe && /* @__PURE__ */ ue.jsx(Te, {
272
+ "data-type": "inside",
273
+ ref: je,
274
+ onFocus: (r) => {
275
+ g ? se(C()[0]) : s?.portalNode && (L && (y.current = !0), Ie(r, s.portalNode) ? Ye(d)?.focus() : w(j ?? s.afterOutsideRef)?.focus());
140
276
  }
141
- }
142
- // Deprecated.
143
- }, {
144
- key: "countryCallingCode",
145
- value: function() {
146
- return this.numberingPlan.callingCode();
147
- }
148
- // Deprecated.
149
- }, {
150
- key: "IDDPrefix",
151
- value: function() {
152
- return this.numberingPlan.IDDPrefix();
153
- }
154
- // Deprecated.
155
- }, {
156
- key: "defaultIDDPrefix",
157
- value: function() {
158
- return this.numberingPlan.defaultIDDPrefix();
159
- }
160
- // Deprecated.
161
- }, {
162
- key: "nationalNumberPattern",
163
- value: function() {
164
- return this.numberingPlan.nationalNumberPattern();
165
- }
166
- // Deprecated.
167
- }, {
168
- key: "possibleLengths",
169
- value: function() {
170
- return this.numberingPlan.possibleLengths();
171
- }
172
- // Deprecated.
173
- }, {
174
- key: "formats",
175
- value: function() {
176
- return this.numberingPlan.formats();
177
- }
178
- // Deprecated.
179
- }, {
180
- key: "nationalPrefixForParsing",
181
- value: function() {
182
- return this.numberingPlan.nationalPrefixForParsing();
183
- }
184
- // Deprecated.
185
- }, {
186
- key: "nationalPrefixTransformRule",
187
- value: function() {
188
- return this.numberingPlan.nationalPrefixTransformRule();
189
- }
190
- // Deprecated.
191
- }, {
192
- key: "leadingDigits",
193
- value: function() {
194
- return this.numberingPlan.leadingDigits();
195
- }
196
- // Deprecated.
197
- }, {
198
- key: "hasTypes",
199
- value: function() {
200
- return this.numberingPlan.hasTypes();
201
- }
202
- // Deprecated.
203
- }, {
204
- key: "type",
205
- value: function(e) {
206
- return this.numberingPlan.type(e);
207
- }
208
- // Deprecated.
209
- }, {
210
- key: "ext",
211
- value: function() {
212
- return this.numberingPlan.ext();
213
- }
214
- }, {
215
- key: "countryCallingCodes",
216
- value: function() {
217
- return this.v1 ? this.metadata.country_phone_code_to_countries : this.metadata.country_calling_codes;
218
- }
219
- // Deprecated.
220
- }, {
221
- key: "chooseCountryByCountryCallingCode",
222
- value: function(e) {
223
- return this.selectNumberingPlan(e);
224
- }
225
- }, {
226
- key: "hasSelectedNumberingPlan",
227
- value: function() {
228
- return this.numberingPlan !== void 0;
229
- }
230
- }]);
231
- })(), c = /* @__PURE__ */ (function() {
232
- function n(t, e) {
233
- u(this, n), this.globalMetadataObject = e, this.metadata = t, m.call(this, e.metadata);
234
- }
235
- return s(n, [{
236
- key: "callingCode",
237
- value: function() {
238
- return this.metadata[0];
239
- }
240
- // When multiple countries share the same calling code,
241
- // all phone number formatting rules are included in the metadata
242
- // of the "default" country for that calling code.
243
- // Any other countries' metdata doesn't include any formatting rules.
244
- // Google developers said that such storage architecture was chosen for performance reasons.
245
- //
246
- // For example, for NANPA region ("North American Numbering Plan Administration",
247
- // which includes USA, Canada, Cayman Islands, Bahamas, etc) all formatting rules
248
- // are contained in the metadata of `US` country.
249
- //
250
- // This is not public API.
251
- //
252
- }, {
253
- key: "_getDefaultCountryMetadataForThisCallingCode",
254
- value: function() {
255
- return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode());
256
- }
257
- // Deprecated.
258
- }, {
259
- key: "getDefaultCountryMetadataForRegion",
260
- value: function() {
261
- return this._getDefaultCountryMetadataForThisCallingCode();
262
- }
263
- // Is always present.
264
- }, {
265
- key: "IDDPrefix",
266
- value: function() {
267
- if (!(this.v1 || this.v2))
268
- return this.metadata[1];
269
- }
270
- // Is only present when a country supports multiple IDD prefixes.
271
- }, {
272
- key: "defaultIDDPrefix",
273
- value: function() {
274
- if (!(this.v1 || this.v2))
275
- return this.metadata[12];
276
- }
277
- }, {
278
- key: "nationalNumberPattern",
279
- value: function() {
280
- return this.v1 || this.v2 ? this.metadata[1] : this.metadata[2];
281
- }
282
- // "possible length" data is always present in Google's metadata.
283
- }, {
284
- key: "possibleLengths",
285
- value: function() {
286
- if (!this.v1)
287
- return this.metadata[this.v2 ? 2 : 3];
288
- }
289
- }, {
290
- key: "_getFormats",
291
- value: function(e) {
292
- return e[this.v1 ? 2 : this.v2 ? 3 : 4];
293
- }
294
- // For countries of the same region (e.g. NANPA)
295
- // formats are all stored in the "main" country for that region.
296
- // E.g. "RU" and "KZ", "US" and "CA".
297
- }, {
298
- key: "formats",
299
- value: function() {
300
- var e = this, a = this._getFormats(this.metadata) || this._getFormats(this._getDefaultCountryMetadataForThisCallingCode()) || [];
301
- return a.map(function(i) {
302
- return new k(i, e);
303
- });
304
- }
305
- }, {
306
- key: "nationalPrefix",
307
- value: function() {
308
- return this.metadata[this.v1 ? 3 : this.v2 ? 4 : 5];
309
- }
310
- }, {
311
- key: "_getNationalPrefixFormattingRule",
312
- value: function(e) {
313
- return e[this.v1 ? 4 : this.v2 ? 5 : 6];
314
- }
315
- // For countries of the same region (e.g. NANPA)
316
- // national prefix formatting rule is stored in the "main" country for that region.
317
- // E.g. "RU" and "KZ", "US" and "CA".
318
- }, {
319
- key: "nationalPrefixFormattingRule",
320
- value: function() {
321
- return this._getNationalPrefixFormattingRule(this.metadata) || this._getNationalPrefixFormattingRule(this._getDefaultCountryMetadataForThisCallingCode());
322
- }
323
- }, {
324
- key: "_nationalPrefixForParsing",
325
- value: function() {
326
- return this.metadata[this.v1 ? 5 : this.v2 ? 6 : 7];
327
- }
328
- }, {
329
- key: "nationalPrefixForParsing",
330
- value: function() {
331
- return this._nationalPrefixForParsing() || this.nationalPrefix();
332
- }
333
- }, {
334
- key: "nationalPrefixTransformRule",
335
- value: function() {
336
- return this.metadata[this.v1 ? 6 : this.v2 ? 7 : 8];
337
- }
338
- }, {
339
- key: "_getNationalPrefixIsOptionalWhenFormatting",
340
- value: function() {
341
- return !!this.metadata[this.v1 ? 7 : this.v2 ? 8 : 9];
342
- }
343
- // For countries of the same region (e.g. NANPA)
344
- // "national prefix is optional when formatting" flag is
345
- // stored in the "main" country for that region.
346
- // E.g. "RU" and "KZ", "US" and "CA".
347
- }, {
348
- key: "nationalPrefixIsOptionalWhenFormattingInNationalFormat",
349
- value: function() {
350
- return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata) || this._getNationalPrefixIsOptionalWhenFormatting(this._getDefaultCountryMetadataForThisCallingCode());
351
- }
352
- }, {
353
- key: "leadingDigits",
354
- value: function() {
355
- return this.metadata[this.v1 ? 8 : this.v2 ? 9 : 10];
356
- }
357
- }, {
358
- key: "types",
359
- value: function() {
360
- return this.metadata[this.v1 ? 9 : this.v2 ? 10 : 11];
361
- }
362
- }, {
363
- key: "hasTypes",
364
- value: function() {
365
- return this.types() && this.types().length === 0 ? !1 : !!this.types();
366
- }
367
- }, {
368
- key: "type",
369
- value: function(e) {
370
- if (this.hasTypes() && y(this.types(), e))
371
- return new _(y(this.types(), e), this);
372
- }
373
- }, {
374
- key: "ext",
375
- value: function() {
376
- return this.v1 || this.v2 ? g : this.metadata[13] || g;
377
- }
378
- }]);
379
- })(), k = /* @__PURE__ */ (function() {
380
- function n(t, e) {
381
- u(this, n), this._format = t, this.metadata = e;
382
- }
383
- return s(n, [{
384
- key: "pattern",
385
- value: function() {
386
- return this._format[0];
387
- }
388
- }, {
389
- key: "format",
390
- value: function() {
391
- return this._format[1];
392
- }
393
- }, {
394
- key: "leadingDigitsPatterns",
395
- value: function() {
396
- return this._format[2] || [];
397
- }
398
- }, {
399
- key: "nationalPrefixFormattingRule",
400
- value: function() {
401
- return this._format[3] || this.metadata.nationalPrefixFormattingRule();
402
- }
403
- }, {
404
- key: "nationalPrefixIsOptionalWhenFormattingInNationalFormat",
405
- value: function() {
406
- return !!this._format[4] || this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat();
407
- }
408
- }, {
409
- key: "nationalPrefixIsMandatoryWhenFormattingInNationalFormat",
410
- value: function() {
411
- return this.usesNationalPrefix() && !this.nationalPrefixIsOptionalWhenFormattingInNationalFormat();
412
- }
413
- // Checks whether national prefix formatting rule contains national prefix.
414
- }, {
415
- key: "usesNationalPrefix",
416
- value: function() {
417
- return !!(this.nationalPrefixFormattingRule() && // Check that national prefix formatting rule is not a "dummy" one.
418
- !x.test(this.nationalPrefixFormattingRule()));
419
- }
420
- }, {
421
- key: "internationalFormat",
422
- value: function() {
423
- return this._format[5] || this.format();
424
- }
425
- }]);
426
- })(), x = /^\(?\$1\)?$/, _ = /* @__PURE__ */ (function() {
427
- function n(t, e) {
428
- u(this, n), this.type = t, this.metadata = e;
429
- }
430
- return s(n, [{
431
- key: "pattern",
432
- value: function() {
433
- return this.metadata.v1 ? this.type : this.type[0];
434
- }
435
- }, {
436
- key: "possibleLengths",
437
- value: function() {
438
- if (!this.metadata.v1)
439
- return this.type[1] || this.metadata.possibleLengths();
440
- }
441
- }]);
442
- })();
443
- function y(n, t) {
444
- switch (t) {
445
- case "FIXED_LINE":
446
- return n[0];
447
- case "MOBILE":
448
- return n[1];
449
- case "TOLL_FREE":
450
- return n[2];
451
- case "PREMIUM_RATE":
452
- return n[3];
453
- case "PERSONAL_NUMBER":
454
- return n[4];
455
- case "VOICEMAIL":
456
- return n[5];
457
- case "UAN":
458
- return n[6];
459
- case "PAGER":
460
- return n[7];
461
- case "VOIP":
462
- return n[8];
463
- case "SHARED_COST":
464
- return n[9];
465
- }
466
- }
467
- function N(n) {
468
- if (!n)
469
- throw new Error("[libphonenumber-js] `metadata` argument not passed. Check your arguments.");
470
- if (!l(n) || !l(n.countries))
471
- throw new Error("[libphonenumber-js] `metadata` argument was passed but it's not a valid metadata. Must be an object having `.countries` child object property. Got ".concat(l(n) ? "an object of shape: { " + Object.keys(n).join(", ") + " }" : "a " + I(n) + ": " + n, "."));
472
- }
473
- var I = function(t) {
474
- return o(t);
475
- };
476
- function M(n, t) {
477
- var e = new F(t);
478
- if (e.hasCountry(n))
479
- return e.selectNumberingPlan(n).countryCallingCode();
480
- throw new Error("Unknown country: ".concat(n));
481
- }
482
- function m(n) {
483
- var t = n.version;
484
- typeof t == "number" ? (this.v1 = t === 1, this.v2 = t === 2, this.v3 = t === 3, this.v4 = t === 4) : t ? h(t, p) === -1 ? this.v2 = !0 : h(t, b) === -1 ? this.v3 = !0 : this.v4 = !0 : this.v1 = !0;
277
+ })]
278
+ });
485
279
  }
486
280
  export {
487
- F as default,
488
- M as getCountryCallingCode,
489
- N as validateMetadata
281
+ Lt as FloatingFocusManager
490
282
  };
491
283
  //# sourceMappingURL=index163.js.map