@blockend/widget 1.0.31 → 1.0.32

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 (162) hide show
  1. package/dist/AllRoutes-CPwuTwqd.js +2209 -0
  2. package/dist/Box-CIChapvH.js +55 -0
  3. package/dist/EstGas-CEFILtyf.js +12867 -0
  4. package/dist/Grow-DJZj9zjv.js +1656 -0
  5. package/dist/InputComp-DqF1JGIu.js +106 -0
  6. package/dist/LoadRoute-r3sHTYXM.js +126 -0
  7. package/dist/QuotesProgress-BXVLxZ8U.js +28 -0
  8. package/dist/SwapAsset-07WvVwl-.js +64 -0
  9. package/dist/Tooltip-CNAsCF8n.js +572 -0
  10. package/dist/TxnButton-D2TTkFYA.js +207 -0
  11. package/dist/WidgetForm.module-QHJ0-m5f.js +9 -0
  12. package/dist/{add-B8AfyNIx.js → add-t2GqC9VA.js} +3 -3
  13. package/dist/{all-wallets-BaLLU39i.js → all-wallets-DFyf0q31.js} +3 -3
  14. package/dist/{app-store-DNpoABj1.js → app-store-aAahwmBP.js} +3 -3
  15. package/dist/{apple-DzzHtaL4.js → apple-DeRgpwlc.js} +3 -3
  16. package/dist/{arrow-bottom-D2c13c51.js → arrow-bottom-DdEOkaAj.js} +3 -3
  17. package/dist/{arrow-bottom-circle-ls9OCLx1.js → arrow-bottom-circle-BWwREWcv.js} +3 -3
  18. package/dist/{arrow-left-BI3rQkNI.js → arrow-left-CulyLmoH.js} +3 -3
  19. package/dist/{arrow-right-rnMzhVod.js → arrow-right-Dwr7TISn.js} +3 -3
  20. package/dist/{arrow-top-CfA6PVMz.js → arrow-top-pL4rM_y8.js} +3 -3
  21. package/dist/{bank-CmpAmHgg.js → bank-CPuyK_08.js} +3 -3
  22. package/dist/basic-CVc9xEvb.js +5783 -0
  23. package/dist/{browser-mEcjgS1H.js → browser-Cbq2Zbp4.js} +3 -3
  24. package/dist/{card-DkgIWcMc.js → card-B_hUtPWK.js} +3 -3
  25. package/dist/ccip-BLVGcR4A.js +228 -0
  26. package/dist/{checkmark-B_A013n2.js → checkmark-WEqTsFAc.js} +3 -3
  27. package/dist/{checkmark-bold-DestuG2T.js → checkmark-bold-Du_ZvhqM.js} +3 -3
  28. package/dist/{chevron-bottom-Di3S86dj.js → chevron-bottom-C-s-lv4L.js} +3 -3
  29. package/dist/{chevron-left-A9Wj-3tj.js → chevron-left-C7NcRElx.js} +3 -3
  30. package/dist/{chevron-right-UFxJogOZ.js → chevron-right-CSzmAmdn.js} +3 -3
  31. package/dist/{chevron-top-BbZs3eaC.js → chevron-top-Dd99Wfel.js} +3 -3
  32. package/dist/{chrome-store-B4F6hJmy.js → chrome-store-C4p77Of0.js} +3 -3
  33. package/dist/{clock-BbAQ09uV.js → clock-Cib24qjH.js} +3 -3
  34. package/dist/clockIcon-C2W5xvyt.js +76 -0
  35. package/dist/{close-CY3oZP_D.js → close-BXjEkTvS.js} +3 -3
  36. package/dist/{coinPlaceholder-DpfsobZT.js → coinPlaceholder-BFNC7cQN.js} +3 -3
  37. package/dist/{compass-CHS7RZFk.js → compass-CXPX5Ycp.js} +3 -3
  38. package/dist/{copy-CEd4nGhs.js → copy-BEawMbmF.js} +3 -3
  39. package/dist/core-Bez9Ow7F.js +14967 -0
  40. package/dist/cursor-Cxq4Q9jk.js +7 -0
  41. package/dist/{cursor-transparent-Tm6k6Ws4.js → cursor-transparent-ZjJ0P2vr.js} +3 -3
  42. package/dist/{desktop-CrSyXZkL.js → desktop-BhZVovAp.js} +3 -3
  43. package/dist/{disconnect-BooT10E1.js → disconnect-AC-bffZO.js} +3 -3
  44. package/dist/{discord-B982Qaml.js → discord-dT97h-CC.js} +3 -3
  45. package/dist/down-DP56YSKp.js +606 -0
  46. package/dist/{etherscan-CFL0IcNl.js → etherscan-rYFRhRTM.js} +3 -3
  47. package/dist/ethertousd-CC_ezooz.js +6 -0
  48. package/dist/{exclamation-triangle-BBeGXYgt.js → exclamation-triangle-C-pCuC08.js} +3 -3
  49. package/dist/{extension-C5WqJw73.js → extension-BnqauLSn.js} +3 -3
  50. package/dist/{external-link-CcSxVDcd.js → external-link-M9D6e_F3.js} +3 -3
  51. package/dist/{facebook-DF0v9ED8.js → facebook-DHezcoD-.js} +3 -3
  52. package/dist/{farcaster-Boq7M4VK.js → farcaster-D0Ky-Imv.js} +3 -3
  53. package/dist/{filters-DfeymbPx.js → filters-B02NYLWq.js} +3 -3
  54. package/dist/getChainIds-CJd2TZYT.js +1888 -0
  55. package/dist/getCosmosAddress-DTZfw04G.js +9565 -0
  56. package/dist/{github-DQ8FV4bD.js → github-BzQkIMuE.js} +3 -3
  57. package/dist/{google-Dm8FDDZR.js → google-BpwCJ4Fs.js} +3 -3
  58. package/dist/hamburger-BzqwkUjE.js +3915 -0
  59. package/dist/{help-circle-CbgiAebR.js → help-circle-C0nOySHC.js} +3 -3
  60. package/dist/{id-CzqxUksI.js → id-DFP_kFd4.js} +3 -3
  61. package/dist/{image-CsCGTIN-.js → image-QiYOAGjM.js} +3 -3
  62. package/dist/index-CDq3vNnP.js +22 -0
  63. package/dist/index-CLzkn733.js +28223 -0
  64. package/dist/index-CjtwASJt.js +252 -0
  65. package/dist/index-CrC4B7xn.js +331 -0
  66. package/dist/index-D5hLIe-N.js +9 -0
  67. package/dist/index-DDk00SOL.js +159 -0
  68. package/dist/index-DTish3yr.js +1014 -0
  69. package/dist/index-DW3W7zaF.js +473 -0
  70. package/dist/index-DXdD3L9f.js +1460 -0
  71. package/dist/index-DaJ1272l.js +18613 -0
  72. package/dist/index-DxPp2gBS.js +992 -0
  73. package/dist/index-Dy_n2MPD.js +3010 -0
  74. package/dist/index-oc8HPfOF.js +13583 -0
  75. package/dist/index.es-Bsr7zP98.js +366 -0
  76. package/dist/index.es-C-j-Ghef.js +11678 -0
  77. package/dist/index.es.js +4 -4
  78. package/dist/{info-fKCfLW0k.js → info-BTLQJ-wd.js} +3 -3
  79. package/dist/{info-circle-Bt350Yzj.js → info-circle-Dla9169_.js} +3 -3
  80. package/dist/{lightbulb-BL9YBxiA.js → lightbulb-PN8DA_Wh.js} +3 -3
  81. package/dist/{mail-_g6CHQeQ.js → mail-BGYZut_4.js} +3 -3
  82. package/dist/{mobile-B-EQ4IcH.js → mobile-BM760ZzX.js} +3 -3
  83. package/dist/{more-C3rpOdUy.js → more-rHGnl2ck.js} +3 -3
  84. package/dist/{network-placeholder-D9Ak7Xj_.js → network-placeholder-CyQl-3_2.js} +3 -3
  85. package/dist/{nftPlaceholder-CIIm2V_o.js → nftPlaceholder-nuUJ8nKY.js} +3 -3
  86. package/dist/{off-DZjgI0eE.js → off-GYlwYDrT.js} +3 -3
  87. package/dist/{play-store-DvRnagoF.js → play-store-Ck01Ez1F.js} +3 -3
  88. package/dist/{plus-C2jN2huZ.js → plus-CQfXWgLw.js} +3 -3
  89. package/dist/{qr-code-B64HnZgi.js → qr-code-CyLVwLY7.js} +3 -3
  90. package/dist/{recycle-horizontal-CovcJGa_.js → recycle-horizontal-DvnWPcEQ.js} +3 -3
  91. package/dist/{refresh-J1Vw6QMA.js → refresh-BOxj8b2n.js} +3 -3
  92. package/dist/{reown-logo-BsXoZ3KT.js → reown-logo-D1iprOTg.js} +3 -3
  93. package/dist/{search-BC86wYXR.js → search-DrPaZPnc.js} +3 -3
  94. package/dist/secp256k1-DgmH1qVg.js +1251 -0
  95. package/dist/{send-BPA1bK5G.js → send-ybBREe4b.js} +3 -3
  96. package/dist/shareicon-D3Qj5j1T.js +262 -0
  97. package/dist/{sortDown-cDA6MpOw.js → sortDown-CjBaDQTU.js} +13 -13
  98. package/dist/{swapHorizontal-47_8ePle.js → swapHorizontal-BddjZdXK.js} +3 -3
  99. package/dist/{swapHorizontalBold-CJ7TzeQP.js → swapHorizontalBold-B6AWjPZ9.js} +3 -3
  100. package/dist/{swapHorizontalMedium-CTACgUR9.js → swapHorizontalMedium-CNacWoBn.js} +3 -3
  101. package/dist/{swapHorizontalRoundedBold-Ht3_LABp.js → swapHorizontalRoundedBold-B8VcPnqt.js} +3 -3
  102. package/dist/{swapVertical-DlS0V6DD.js → swapVertical-zY2BbSyQ.js} +3 -3
  103. package/dist/{telegram-UZ00kvIE.js → telegram-DS4l-8Oc.js} +3 -3
  104. package/dist/{three-dots-D9zVXr1j.js → three-dots-RctNqamK.js} +3 -3
  105. package/dist/truncate-D9t92mVX.js +7 -0
  106. package/dist/{twitch-CP6rpz4m.js → twitch-CJ0llIIH.js} +3 -3
  107. package/dist/{twitterIcon-Cm3I3FRU.js → twitterIcon-pgvN9-bP.js} +3 -3
  108. package/dist/unsupportedProp-BJVuEW_b.js +10 -0
  109. package/dist/useRegisterError-C_YLA1dw.js +9857 -0
  110. package/dist/validError-CDlJpg_f.js +6 -0
  111. package/dist/{verify-DuUE85WT.js → verify-BeZLo1Fq.js} +3 -3
  112. package/dist/{verify-filled-CfgydKPa.js → verify-filled-meyb7E16.js} +3 -3
  113. package/dist/w3m-modal-C-Jp9NVv.js +1471 -0
  114. package/dist/{wallet-BC2LSDlF.js → wallet-CFcOgSsz.js} +3 -3
  115. package/dist/{wallet-placeholder-DugEJ7xM.js → wallet-placeholder-CeUMILZq.js} +3 -3
  116. package/dist/{walletconnect-wayCaYfk.js → walletconnect-D6LB1PyC.js} +7 -9
  117. package/dist/{warning-circle-Cy9YuvwU.js → warning-circle-BRtzofvT.js} +3 -3
  118. package/dist/{x-jggPFiy-.js → x-DKQAOOh3.js} +3 -3
  119. package/package.json +1 -1
  120. package/dist/AllRoutes-Bdi5ZW8W.js +0 -2604
  121. package/dist/Box-e4gA-y_H.js +0 -60
  122. package/dist/EstGas-C5ihS0Mw.js +0 -17108
  123. package/dist/Grow-B4K-I-E-.js +0 -2212
  124. package/dist/InputComp-C_UUZxNU.js +0 -114
  125. package/dist/LoadRoute-CnDhVKdh.js +0 -142
  126. package/dist/QuotesProgress-DxgPgPJE.js +0 -29
  127. package/dist/SwapAsset-CmmuxeQF.js +0 -65
  128. package/dist/Tooltip-D8YjOOKU.js +0 -718
  129. package/dist/TxnButton-CF-TLZrD.js +0 -302
  130. package/dist/WidgetForm.module-DhUUlwZP.js +0 -13
  131. package/dist/basic-Cx2xxgd9.js +0 -7109
  132. package/dist/ccip-BKpquA5i.js +0 -250
  133. package/dist/clockIcon-jSNFFrLy.js +0 -76
  134. package/dist/core-C-gr9X18.js +0 -17217
  135. package/dist/cursor-BTtIlTHP.js +0 -7
  136. package/dist/down-DDk8OoJG.js +0 -809
  137. package/dist/ethertousd-BOknTgU4.js +0 -7
  138. package/dist/getChainIds-6iugk2h0.js +0 -2431
  139. package/dist/getCosmosAddress-BgD5iV6f.js +0 -13998
  140. package/dist/hamburger-BYe_G11E.js +0 -4562
  141. package/dist/index-BAmjBHYR.js +0 -1087
  142. package/dist/index-BxHeZ9IF.js +0 -543
  143. package/dist/index-C7cb2O7r.js +0 -16078
  144. package/dist/index-CF9p4S_X.js +0 -11
  145. package/dist/index-C_vo1L7p.js +0 -24384
  146. package/dist/index-Ch7w83dW.js +0 -4217
  147. package/dist/index-Crhenmgw.js +0 -188
  148. package/dist/index-Cz5Dosd2.js +0 -412
  149. package/dist/index-D5OnT-__.js +0 -35858
  150. package/dist/index-DArR1lwi.js +0 -1759
  151. package/dist/index-hEJSpZe-.js +0 -308
  152. package/dist/index-m2O0cbD8.js +0 -1883
  153. package/dist/index-sLx4Edw4.js +0 -22
  154. package/dist/index.es-DIbGJsfa.js +0 -475
  155. package/dist/index.es-t6sHlseh.js +0 -12916
  156. package/dist/secp256k1-BkBK0mD5.js +0 -1681
  157. package/dist/shareicon-C88Wx-AM.js +0 -314
  158. package/dist/truncate-DSxFWEga.js +0 -7
  159. package/dist/unsupportedProp-DkeDzLfM.js +0 -14
  160. package/dist/useRegisterError-W_UfecIN.js +0 -19288
  161. package/dist/validError-rariWQ7G.js +0 -14
  162. package/dist/w3m-modal-Bl-DPlah.js +0 -1721
@@ -0,0 +1,366 @@
1
+ import { M as z } from "./useRegisterError-C_YLA1dw.js";
2
+ import G, { useEffect as C, useState as J, useRef as j } from "react";
3
+ function E(t, e) {
4
+ (e == null || e > t.length) && (e = t.length);
5
+ for (var r = 0, n = Array(e); r < e; r++) n[r] = t[r];
6
+ return n;
7
+ }
8
+ function Q(t) {
9
+ if (Array.isArray(t)) return t;
10
+ }
11
+ function Z(t, e, r) {
12
+ return (e = oe(e)) in t ? Object.defineProperty(t, e, {
13
+ value: r,
14
+ enumerable: !0,
15
+ configurable: !0,
16
+ writable: !0
17
+ }) : t[e] = r, t;
18
+ }
19
+ function ee(t, e) {
20
+ var r = t == null ? null : typeof Symbol < "u" && t[Symbol.iterator] || t["@@iterator"];
21
+ if (r != null) {
22
+ var n, c, f, i, b = [], d = !0, A = !1;
23
+ try {
24
+ if (f = (r = r.call(t)).next, e !== 0) for (; !(d = (n = f.call(r)).done) && (b.push(n.value), b.length !== e); d = !0) ;
25
+ } catch (g) {
26
+ A = !0, c = g;
27
+ } finally {
28
+ try {
29
+ if (!d && r.return != null && (i = r.return(), Object(i) !== i)) return;
30
+ } finally {
31
+ if (A) throw c;
32
+ }
33
+ }
34
+ return b;
35
+ }
36
+ }
37
+ function te() {
38
+ throw new TypeError(`Invalid attempt to destructure non-iterable instance.
39
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
40
+ }
41
+ function x(t, e) {
42
+ var r = Object.keys(t);
43
+ if (Object.getOwnPropertySymbols) {
44
+ var n = Object.getOwnPropertySymbols(t);
45
+ e && (n = n.filter(function(c) {
46
+ return Object.getOwnPropertyDescriptor(t, c).enumerable;
47
+ })), r.push.apply(r, n);
48
+ }
49
+ return r;
50
+ }
51
+ function I(t) {
52
+ for (var e = 1; e < arguments.length; e++) {
53
+ var r = arguments[e] != null ? arguments[e] : {};
54
+ e % 2 ? x(Object(r), !0).forEach(function(n) {
55
+ Z(t, n, r[n]);
56
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : x(Object(r)).forEach(function(n) {
57
+ Object.defineProperty(t, n, Object.getOwnPropertyDescriptor(r, n));
58
+ });
59
+ }
60
+ return t;
61
+ }
62
+ function M(t, e) {
63
+ if (t == null) return {};
64
+ var r, n, c = ne(t, e);
65
+ if (Object.getOwnPropertySymbols) {
66
+ var f = Object.getOwnPropertySymbols(t);
67
+ for (n = 0; n < f.length; n++) r = f[n], e.includes(r) || {}.propertyIsEnumerable.call(t, r) && (c[r] = t[r]);
68
+ }
69
+ return c;
70
+ }
71
+ function ne(t, e) {
72
+ if (t == null) return {};
73
+ var r = {};
74
+ for (var n in t) if ({}.hasOwnProperty.call(t, n)) {
75
+ if (e.includes(n)) continue;
76
+ r[n] = t[n];
77
+ }
78
+ return r;
79
+ }
80
+ function re(t, e) {
81
+ return Q(t) || ee(t, e) || ie(t, e) || te();
82
+ }
83
+ function ae(t, e) {
84
+ if (typeof t != "object" || !t) return t;
85
+ var r = t[Symbol.toPrimitive];
86
+ if (r !== void 0) {
87
+ var n = r.call(t, e);
88
+ if (typeof n != "object") return n;
89
+ throw new TypeError("@@toPrimitive must return a primitive value.");
90
+ }
91
+ return (e === "string" ? String : Number)(t);
92
+ }
93
+ function oe(t) {
94
+ var e = ae(t, "string");
95
+ return typeof e == "symbol" ? e : e + "";
96
+ }
97
+ function ie(t, e) {
98
+ if (t) {
99
+ if (typeof t == "string") return E(t, e);
100
+ var r = {}.toString.call(t).slice(8, -1);
101
+ return r === "Object" && t.constructor && (r = t.constructor.name), r === "Map" || r === "Set" ? Array.from(t) : r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r) ? E(t, e) : void 0;
102
+ }
103
+ }
104
+ var ue = ["animationData", "loop", "autoplay", "initialSegment", "onComplete", "onLoopComplete", "onEnterFrame", "onSegmentStart", "onConfigReady", "onDataReady", "onDataFailed", "onLoadedImages", "onDOMLoaded", "onDestroy", "lottieRef", "renderer", "name", "assetsPath", "rendererSettings"], le = function(e, r) {
105
+ var n = e.animationData, c = e.loop, f = e.autoplay, i = e.initialSegment, b = e.onComplete, d = e.onLoopComplete, A = e.onEnterFrame, g = e.onSegmentStart, L = e.onConfigReady, _ = e.onDataReady, h = e.onDataFailed, u = e.onLoadedImages, w = e.onDOMLoaded, S = e.onDestroy;
106
+ e.lottieRef, e.renderer, e.name, e.assetsPath, e.rendererSettings;
107
+ var p = M(e, ue), D = J(!1), l = re(D, 2), O = l[0], R = l[1], o = j(), v = j(null), H = function() {
108
+ var a;
109
+ (a = o.current) === null || a === void 0 || a.play();
110
+ }, F = function() {
111
+ var a;
112
+ (a = o.current) === null || a === void 0 || a.stop();
113
+ }, V = function() {
114
+ var a;
115
+ (a = o.current) === null || a === void 0 || a.pause();
116
+ }, N = function(a) {
117
+ var s;
118
+ (s = o.current) === null || s === void 0 || s.setSpeed(a);
119
+ }, $ = function(a, s) {
120
+ var m;
121
+ (m = o.current) === null || m === void 0 || m.goToAndPlay(a, s);
122
+ }, k = function(a, s) {
123
+ var m;
124
+ (m = o.current) === null || m === void 0 || m.goToAndStop(a, s);
125
+ }, B = function(a) {
126
+ var s;
127
+ (s = o.current) === null || s === void 0 || s.setDirection(a);
128
+ }, W = function(a, s) {
129
+ var m;
130
+ (m = o.current) === null || m === void 0 || m.playSegments(a, s);
131
+ }, K = function(a) {
132
+ var s;
133
+ (s = o.current) === null || s === void 0 || s.setSubframe(a);
134
+ }, U = function(a) {
135
+ var s;
136
+ return (s = o.current) === null || s === void 0 ? void 0 : s.getDuration(a);
137
+ }, X = function() {
138
+ var a;
139
+ (a = o.current) === null || a === void 0 || a.destroy(), o.current = void 0;
140
+ }, Y = function() {
141
+ var a = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, s;
142
+ if (v.current) {
143
+ (s = o.current) === null || s === void 0 || s.destroy();
144
+ var m = I(I(I({}, e), a), {}, {
145
+ container: v.current
146
+ });
147
+ return o.current = z.loadAnimation(m), R(!!o.current), function() {
148
+ var P;
149
+ (P = o.current) === null || P === void 0 || P.destroy(), o.current = void 0;
150
+ };
151
+ }
152
+ };
153
+ C(function() {
154
+ var y = Y();
155
+ return function() {
156
+ return y == null ? void 0 : y();
157
+ };
158
+ }, [n, c]), C(function() {
159
+ o.current && (o.current.autoplay = !!f);
160
+ }, [f]), C(function() {
161
+ if (o.current) {
162
+ if (!i) {
163
+ o.current.resetSegments(!0);
164
+ return;
165
+ }
166
+ !Array.isArray(i) || !i.length || ((o.current.currentRawFrame < i[0] || o.current.currentRawFrame > i[1]) && (o.current.currentRawFrame = i[0]), o.current.setSegment(i[0], i[1]));
167
+ }
168
+ }, [i]), C(function() {
169
+ var y = [{
170
+ name: "complete",
171
+ handler: b
172
+ }, {
173
+ name: "loopComplete",
174
+ handler: d
175
+ }, {
176
+ name: "enterFrame",
177
+ handler: A
178
+ }, {
179
+ name: "segmentStart",
180
+ handler: g
181
+ }, {
182
+ name: "config_ready",
183
+ handler: L
184
+ }, {
185
+ name: "data_ready",
186
+ handler: _
187
+ }, {
188
+ name: "data_failed",
189
+ handler: h
190
+ }, {
191
+ name: "loaded_images",
192
+ handler: u
193
+ }, {
194
+ name: "DOMLoaded",
195
+ handler: w
196
+ }, {
197
+ name: "destroy",
198
+ handler: S
199
+ }], a = y.filter(function(m) {
200
+ return m.handler != null;
201
+ });
202
+ if (a.length) {
203
+ var s = a.map(
204
+ /**
205
+ * Handle the process of adding an event listener
206
+ * @param {Listener} listener
207
+ * @return {Function} Function that deregister the listener
208
+ */
209
+ function(m) {
210
+ var P;
211
+ return (P = o.current) === null || P === void 0 || P.addEventListener(m.name, m.handler), function() {
212
+ var T;
213
+ (T = o.current) === null || T === void 0 || T.removeEventListener(m.name, m.handler);
214
+ };
215
+ }
216
+ );
217
+ return function() {
218
+ s.forEach(function(m) {
219
+ return m();
220
+ });
221
+ };
222
+ }
223
+ }, [b, d, A, g, L, _, h, u, w, S]);
224
+ var q = /* @__PURE__ */ G.createElement("div", I({
225
+ style: r,
226
+ ref: v
227
+ }, p));
228
+ return {
229
+ View: q,
230
+ play: H,
231
+ stop: F,
232
+ pause: V,
233
+ setSpeed: N,
234
+ goToAndStop: k,
235
+ goToAndPlay: $,
236
+ setDirection: B,
237
+ playSegments: W,
238
+ setSubframe: K,
239
+ getDuration: U,
240
+ destroy: X,
241
+ animationContainerRef: v,
242
+ animationLoaded: O,
243
+ animationItem: o.current
244
+ };
245
+ };
246
+ function se(t) {
247
+ var e = t.getBoundingClientRect(), r = e.top, n = e.height, c = window.innerHeight - r, f = window.innerHeight + n;
248
+ return c / f;
249
+ }
250
+ function de(t, e, r) {
251
+ var n = t.getBoundingClientRect(), c = n.top, f = n.left, i = n.width, b = n.height, d = (e - f) / i, A = (r - c) / b;
252
+ return {
253
+ x: d,
254
+ y: A
255
+ };
256
+ }
257
+ var ce = function(e) {
258
+ var r = e.wrapperRef, n = e.animationItem, c = e.mode, f = e.actions;
259
+ C(function() {
260
+ var i = r.current;
261
+ if (!(!i || !n || !f.length)) {
262
+ n.stop();
263
+ var b = function() {
264
+ var g = null, L = function() {
265
+ var h = se(i), u = f.find(function(S) {
266
+ var p = S.visibility;
267
+ return p && h >= p[0] && h <= p[1];
268
+ });
269
+ if (u) {
270
+ if (u.type === "seek" && u.visibility && u.frames.length === 2) {
271
+ var w = u.frames[0] + Math.ceil((h - u.visibility[0]) / (u.visibility[1] - u.visibility[0]) * u.frames[1]);
272
+ n.goToAndStop(w - n.firstFrame - 1, !0);
273
+ }
274
+ u.type === "loop" && (g === null || g !== u.frames || n.isPaused) && (n.playSegments(u.frames, !0), g = u.frames), u.type === "play" && n.isPaused && (n.resetSegments(!0), n.play()), u.type === "stop" && n.goToAndStop(u.frames[0] - n.firstFrame - 1, !0);
275
+ }
276
+ };
277
+ return document.addEventListener("scroll", L), function() {
278
+ document.removeEventListener("scroll", L);
279
+ };
280
+ }, d = function() {
281
+ var g = function(u, w) {
282
+ var S = u, p = w;
283
+ if (S !== -1 && p !== -1) {
284
+ var D = de(i, S, p);
285
+ S = D.x, p = D.y;
286
+ }
287
+ var l = f.find(function(o) {
288
+ var v = o.position;
289
+ return v && Array.isArray(v.x) && Array.isArray(v.y) ? S >= v.x[0] && S <= v.x[1] && p >= v.y[0] && p <= v.y[1] : v && !Number.isNaN(v.x) && !Number.isNaN(v.y) ? S === v.x && p === v.y : !1;
290
+ });
291
+ if (l) {
292
+ if (l.type === "seek" && l.position && Array.isArray(l.position.x) && Array.isArray(l.position.y) && l.frames.length === 2) {
293
+ var O = (S - l.position.x[0]) / (l.position.x[1] - l.position.x[0]), R = (p - l.position.y[0]) / (l.position.y[1] - l.position.y[0]);
294
+ n.playSegments(l.frames, !0), n.goToAndStop(Math.ceil((O + R) / 2 * (l.frames[1] - l.frames[0])), !0);
295
+ }
296
+ l.type === "loop" && n.playSegments(l.frames, !0), l.type === "play" && (n.isPaused && n.resetSegments(!1), n.playSegments(l.frames)), l.type === "stop" && n.goToAndStop(l.frames[0], !0);
297
+ }
298
+ }, L = function(u) {
299
+ g(u.clientX, u.clientY);
300
+ }, _ = function() {
301
+ g(-1, -1);
302
+ };
303
+ return i.addEventListener("mousemove", L), i.addEventListener("mouseout", _), function() {
304
+ i.removeEventListener("mousemove", L), i.removeEventListener("mouseout", _);
305
+ };
306
+ };
307
+ switch (c) {
308
+ case "scroll":
309
+ return b();
310
+ case "cursor":
311
+ return d();
312
+ }
313
+ }
314
+ }, [c, n]);
315
+ }, me = function(e) {
316
+ var r = e.actions, n = e.mode, c = e.lottieObj, f = c.animationItem, i = c.View, b = c.animationContainerRef;
317
+ return ce({
318
+ actions: r,
319
+ animationItem: f,
320
+ mode: n,
321
+ wrapperRef: b
322
+ }), i;
323
+ }, fe = ["style", "interactivity"], ge = function(e) {
324
+ var r, n, c, f = e.style, i = e.interactivity, b = M(e, fe), d = le(b, f), A = d.View, g = d.play, L = d.stop, _ = d.pause, h = d.setSpeed, u = d.goToAndStop, w = d.goToAndPlay, S = d.setDirection, p = d.playSegments, D = d.setSubframe, l = d.getDuration, O = d.destroy, R = d.animationContainerRef, o = d.animationLoaded, v = d.animationItem;
325
+ return C(function() {
326
+ e.lottieRef && (e.lottieRef.current = {
327
+ play: g,
328
+ stop: L,
329
+ pause: _,
330
+ setSpeed: h,
331
+ goToAndPlay: w,
332
+ goToAndStop: u,
333
+ setDirection: S,
334
+ playSegments: p,
335
+ setSubframe: D,
336
+ getDuration: l,
337
+ destroy: O,
338
+ animationContainerRef: R,
339
+ animationLoaded: o,
340
+ animationItem: v
341
+ });
342
+ }, [(r = e.lottieRef) === null || r === void 0 ? void 0 : r.current]), me({
343
+ lottieObj: {
344
+ View: A,
345
+ play: g,
346
+ stop: L,
347
+ pause: _,
348
+ setSpeed: h,
349
+ goToAndStop: u,
350
+ goToAndPlay: w,
351
+ setDirection: S,
352
+ playSegments: p,
353
+ setSubframe: D,
354
+ getDuration: l,
355
+ destroy: O,
356
+ animationContainerRef: R,
357
+ animationLoaded: o,
358
+ animationItem: v
359
+ },
360
+ actions: (n = i == null ? void 0 : i.actions) !== null && n !== void 0 ? n : [],
361
+ mode: (c = i == null ? void 0 : i.mode) !== null && c !== void 0 ? c : "scroll"
362
+ });
363
+ };
364
+ export {
365
+ ge as L
366
+ };