hardhat-airsign 0.1.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.
- package/LICENSE +21 -0
- package/README.md +239 -0
- package/app-dist/assets/Arc-VDBY7LNS-BChRXCXW.js +2 -0
- package/app-dist/assets/Arc-VDBY7LNS-BChRXCXW.js.map +1 -0
- package/app-dist/assets/Brave-BRAKJXDS-mq-Xo37j.js +2 -0
- package/app-dist/assets/Brave-BRAKJXDS-mq-Xo37j.js.map +1 -0
- package/app-dist/assets/Browser-76IHF3Y2-BMhRaC5Z.js +2 -0
- package/app-dist/assets/Browser-76IHF3Y2-BMhRaC5Z.js.map +1 -0
- package/app-dist/assets/Chrome-65Q5P54Y-DR9MQEVr.js +2 -0
- package/app-dist/assets/Chrome-65Q5P54Y-DR9MQEVr.js.map +1 -0
- package/app-dist/assets/Edge-XSPUTORV-DEoZslQE.js +2 -0
- package/app-dist/assets/Edge-XSPUTORV-DEoZslQE.js.map +1 -0
- package/app-dist/assets/Firefox-AAHGJQIP-Bp_Hm04m.js +2 -0
- package/app-dist/assets/Firefox-AAHGJQIP-Bp_Hm04m.js.map +1 -0
- package/app-dist/assets/Linux-OO4TNCLJ-B0aw93n9.js +2 -0
- package/app-dist/assets/Linux-OO4TNCLJ-B0aw93n9.js.map +1 -0
- package/app-dist/assets/Macos-MW4AE7LN-Vvm8Drw3.js +2 -0
- package/app-dist/assets/Macos-MW4AE7LN-Vvm8Drw3.js.map +1 -0
- package/app-dist/assets/Opera-KQZLSACL-Cwv5MDFy.js +2 -0
- package/app-dist/assets/Opera-KQZLSACL-Cwv5MDFy.js.map +1 -0
- package/app-dist/assets/Safari-ZPL37GXR-C4Ggg6rz.js +2 -0
- package/app-dist/assets/Safari-ZPL37GXR-C4Ggg6rz.js.map +1 -0
- package/app-dist/assets/Windows-PPTHQER6-BlyV2p7Y.js +2 -0
- package/app-dist/assets/Windows-PPTHQER6-BlyV2p7Y.js.map +1 -0
- package/app-dist/assets/add--InA7epz.js +16 -0
- package/app-dist/assets/add--InA7epz.js.map +1 -0
- package/app-dist/assets/add-0SGyxYcB.js +16 -0
- package/app-dist/assets/add-0SGyxYcB.js.map +0 -0
- package/app-dist/assets/add-DnWcHPES.js +16 -0
- package/app-dist/assets/add-DnWcHPES.js.map +1 -0
- package/app-dist/assets/all-wallets-DOaftD3q.js +7 -0
- package/app-dist/assets/all-wallets-DOaftD3q.js.map +1 -0
- package/app-dist/assets/all-wallets-I5CHqbVa.js +7 -0
- package/app-dist/assets/all-wallets-I5CHqbVa.js.map +1 -0
- package/app-dist/assets/all-wallets-nk-TNPoK.js +7 -0
- package/app-dist/assets/all-wallets-nk-TNPoK.js.map +0 -0
- package/app-dist/assets/apechain-SX5YFU6N-q5qBv-mp.js +2 -0
- package/app-dist/assets/apechain-SX5YFU6N-q5qBv-mp.js.map +1 -0
- package/app-dist/assets/app-store-BI7dtYVv.js +18 -0
- package/app-dist/assets/app-store-BI7dtYVv.js.map +1 -0
- package/app-dist/assets/app-store-D-r9UZaj.js +18 -0
- package/app-dist/assets/app-store-D-r9UZaj.js.map +1 -0
- package/app-dist/assets/app-store-DEIpbdyI.js +18 -0
- package/app-dist/assets/app-store-DEIpbdyI.js.map +0 -0
- package/app-dist/assets/apple-C8TKxHY0.js +19 -0
- package/app-dist/assets/apple-C8TKxHY0.js.map +1 -0
- package/app-dist/assets/apple-CNmISHhG.js +19 -0
- package/app-dist/assets/apple-CNmISHhG.js.map +1 -0
- package/app-dist/assets/apple-tsKJeNpP.js +19 -0
- package/app-dist/assets/apple-tsKJeNpP.js.map +0 -0
- package/app-dist/assets/ar_AR-44JUQ6EW-BMX-am0v.js +1488 -0
- package/app-dist/assets/ar_AR-44JUQ6EW-BMX-am0v.js.map +1 -0
- package/app-dist/assets/arbitrum-WURIBY6W-CqVkHBr5.js +2 -0
- package/app-dist/assets/arbitrum-WURIBY6W-CqVkHBr5.js.map +1 -0
- package/app-dist/assets/arrow-bottom-DigzIzmG.js +9 -0
- package/app-dist/assets/arrow-bottom-DigzIzmG.js.map +1 -0
- package/app-dist/assets/arrow-bottom-Y229K4sk.js +9 -0
- package/app-dist/assets/arrow-bottom-Y229K4sk.js.map +1 -0
- package/app-dist/assets/arrow-bottom-circle-4IW6POXa.js +12 -0
- package/app-dist/assets/arrow-bottom-circle-4IW6POXa.js.map +0 -0
- package/app-dist/assets/arrow-bottom-circle-CbMasYEI.js +12 -0
- package/app-dist/assets/arrow-bottom-circle-CbMasYEI.js.map +1 -0
- package/app-dist/assets/arrow-bottom-circle-Ds_LJfyU.js +12 -0
- package/app-dist/assets/arrow-bottom-circle-Ds_LJfyU.js.map +1 -0
- package/app-dist/assets/arrow-bottom-oNe1x2mS.js +9 -0
- package/app-dist/assets/arrow-bottom-oNe1x2mS.js.map +0 -0
- package/app-dist/assets/arrow-left-BODjw1GB.js +9 -0
- package/app-dist/assets/arrow-left-BODjw1GB.js.map +1 -0
- package/app-dist/assets/arrow-left-CW9JCHZ3.js +9 -0
- package/app-dist/assets/arrow-left-CW9JCHZ3.js.map +0 -0
- package/app-dist/assets/arrow-left-Dg1BVZAC.js +9 -0
- package/app-dist/assets/arrow-left-Dg1BVZAC.js.map +1 -0
- package/app-dist/assets/arrow-right-5W6Bl9Bj.js +9 -0
- package/app-dist/assets/arrow-right-5W6Bl9Bj.js.map +1 -0
- package/app-dist/assets/arrow-right-C82ug51v.js +9 -0
- package/app-dist/assets/arrow-right-C82ug51v.js.map +0 -0
- package/app-dist/assets/arrow-right-dmJyFJTB.js +9 -0
- package/app-dist/assets/arrow-right-dmJyFJTB.js.map +1 -0
- package/app-dist/assets/arrow-top-BC20uJLe.js +9 -0
- package/app-dist/assets/arrow-top-BC20uJLe.js.map +1 -0
- package/app-dist/assets/arrow-top-DanTkraS.js +9 -0
- package/app-dist/assets/arrow-top-DanTkraS.js.map +1 -0
- package/app-dist/assets/arrow-top-Imr-OtMk.js +9 -0
- package/app-dist/assets/arrow-top-Imr-OtMk.js.map +0 -0
- package/app-dist/assets/assets-Q6ZU7ZJ5-P8HioiAD.js +2 -0
- package/app-dist/assets/assets-Q6ZU7ZJ5-P8HioiAD.js.map +1 -0
- package/app-dist/assets/avalanche-KOMJD3XY-Dsn_JPR4.js +2 -0
- package/app-dist/assets/avalanche-KOMJD3XY-Dsn_JPR4.js.map +1 -0
- package/app-dist/assets/bank-ButTTnRs.js +15 -0
- package/app-dist/assets/bank-ButTTnRs.js.map +0 -0
- package/app-dist/assets/bank-Co9iaTPZ.js +15 -0
- package/app-dist/assets/bank-Co9iaTPZ.js.map +1 -0
- package/app-dist/assets/bank-DrHFkCz9.js +15 -0
- package/app-dist/assets/bank-DrHFkCz9.js.map +1 -0
- package/app-dist/assets/base-OAXLRA4F-CoYTVIiL.js +2 -0
- package/app-dist/assets/base-OAXLRA4F-CoYTVIiL.js.map +1 -0
- package/app-dist/assets/baseAccount-44UITRK7-CsjdbWCf.js +2 -0
- package/app-dist/assets/baseAccount-44UITRK7-CsjdbWCf.js.map +1 -0
- package/app-dist/assets/basic-BOJWVLk7.js +2129 -0
- package/app-dist/assets/basic-BOJWVLk7.js.map +1 -0
- package/app-dist/assets/basic-D3kLhhPb.js +2129 -0
- package/app-dist/assets/basic-D3kLhhPb.js.map +0 -0
- package/app-dist/assets/basic-DayfWMvc.js +2129 -0
- package/app-dist/assets/basic-DayfWMvc.js.map +1 -0
- package/app-dist/assets/berachain-NJECWIVC-DumxnFvf.js +2 -0
- package/app-dist/assets/berachain-NJECWIVC-DumxnFvf.js.map +1 -0
- package/app-dist/assets/blast-V555OVXZ-BbhJh1tj.js +2 -0
- package/app-dist/assets/blast-V555OVXZ-BbhJh1tj.js.map +1 -0
- package/app-dist/assets/browser-BIa8JuXN.js +15 -0
- package/app-dist/assets/browser-BIa8JuXN.js.map +1 -0
- package/app-dist/assets/browser-D3UhxMVn.js +15 -0
- package/app-dist/assets/browser-D3UhxMVn.js.map +0 -0
- package/app-dist/assets/browser-D3u19hzr.js +15 -0
- package/app-dist/assets/browser-D3u19hzr.js.map +1 -0
- package/app-dist/assets/bsc-N647EYR2-B2nLKXWV.js +2 -0
- package/app-dist/assets/bsc-N647EYR2-B2nLKXWV.js.map +1 -0
- package/app-dist/assets/card-CTTiKL-L.js +15 -0
- package/app-dist/assets/card-CTTiKL-L.js.map +1 -0
- package/app-dist/assets/card-DOjxiga1.js +15 -0
- package/app-dist/assets/card-DOjxiga1.js.map +1 -0
- package/app-dist/assets/card-DaF-cVjH.js +15 -0
- package/app-dist/assets/card-DaF-cVjH.js.map +0 -0
- package/app-dist/assets/ccip-BuEOOHoL.js +2 -0
- package/app-dist/assets/ccip-BuEOOHoL.js.map +1 -0
- package/app-dist/assets/ccip-CJMOhB7g.js +0 -0
- package/app-dist/assets/ccip-CJMOhB7g.js.map +0 -0
- package/app-dist/assets/ccip-WYMNLYQt.js +2 -0
- package/app-dist/assets/ccip-WYMNLYQt.js.map +1 -0
- package/app-dist/assets/celo-GEP4TUHG-CenIBYLU.js +2 -0
- package/app-dist/assets/celo-GEP4TUHG-CenIBYLU.js.map +1 -0
- package/app-dist/assets/checkmark-B6P7irtS.js +12 -0
- package/app-dist/assets/checkmark-B6P7irtS.js.map +1 -0
- package/app-dist/assets/checkmark-OSwxF5tq.js +12 -0
- package/app-dist/assets/checkmark-OSwxF5tq.js.map +1 -0
- package/app-dist/assets/checkmark-bold-CRUf3cWH.js +9 -0
- package/app-dist/assets/checkmark-bold-CRUf3cWH.js.map +1 -0
- package/app-dist/assets/checkmark-bold-D9gp5-An.js +9 -0
- package/app-dist/assets/checkmark-bold-D9gp5-An.js.map +1 -0
- package/app-dist/assets/checkmark-bold-DU3gdt2a.js +9 -0
- package/app-dist/assets/checkmark-bold-DU3gdt2a.js.map +0 -0
- package/app-dist/assets/checkmark-rdFIfftt.js +12 -0
- package/app-dist/assets/checkmark-rdFIfftt.js.map +0 -0
- package/app-dist/assets/chevron-bottom-BTlNRA6K.js +9 -0
- package/app-dist/assets/chevron-bottom-BTlNRA6K.js.map +0 -0
- package/app-dist/assets/chevron-bottom-CFeQ71Pr.js +9 -0
- package/app-dist/assets/chevron-bottom-CFeQ71Pr.js.map +1 -0
- package/app-dist/assets/chevron-bottom-CON_Yq4L.js +9 -0
- package/app-dist/assets/chevron-bottom-CON_Yq4L.js.map +1 -0
- package/app-dist/assets/chevron-left-B6NbMRK7.js +9 -0
- package/app-dist/assets/chevron-left-B6NbMRK7.js.map +1 -0
- package/app-dist/assets/chevron-left-BbGh1GnY.js +9 -0
- package/app-dist/assets/chevron-left-BbGh1GnY.js.map +0 -0
- package/app-dist/assets/chevron-left-P4zxdUtN.js +9 -0
- package/app-dist/assets/chevron-left-P4zxdUtN.js.map +1 -0
- package/app-dist/assets/chevron-right-BPMsRgVg.js +9 -0
- package/app-dist/assets/chevron-right-BPMsRgVg.js.map +0 -0
- package/app-dist/assets/chevron-right-Cus2a-0w.js +9 -0
- package/app-dist/assets/chevron-right-Cus2a-0w.js.map +1 -0
- package/app-dist/assets/chevron-right-i3QUb2xq.js +9 -0
- package/app-dist/assets/chevron-right-i3QUb2xq.js.map +1 -0
- package/app-dist/assets/chevron-top-Be8bXxJF.js +9 -0
- package/app-dist/assets/chevron-top-Be8bXxJF.js.map +1 -0
- package/app-dist/assets/chevron-top-GbLiblg7.js +9 -0
- package/app-dist/assets/chevron-top-GbLiblg7.js.map +1 -0
- package/app-dist/assets/chevron-top-ja4eZLum.js +9 -0
- package/app-dist/assets/chevron-top-ja4eZLum.js.map +0 -0
- package/app-dist/assets/chrome-store-BAP-tG78.js +62 -0
- package/app-dist/assets/chrome-store-BAP-tG78.js.map +0 -0
- package/app-dist/assets/chrome-store-Dcbk9Hyg.js +62 -0
- package/app-dist/assets/chrome-store-Dcbk9Hyg.js.map +1 -0
- package/app-dist/assets/chrome-store-Df1HyrXG.js +62 -0
- package/app-dist/assets/chrome-store-Df1HyrXG.js.map +1 -0
- package/app-dist/assets/clock-1ETgyOC2.js +9 -0
- package/app-dist/assets/clock-1ETgyOC2.js.map +0 -0
- package/app-dist/assets/clock-BmiJckGp.js +9 -0
- package/app-dist/assets/clock-BmiJckGp.js.map +1 -0
- package/app-dist/assets/clock-K1b_guWl.js +9 -0
- package/app-dist/assets/clock-K1b_guWl.js.map +1 -0
- package/app-dist/assets/close-BIxvox0S.js +9 -0
- package/app-dist/assets/close-BIxvox0S.js.map +0 -0
- package/app-dist/assets/close-BeoJC3Uv.js +9 -0
- package/app-dist/assets/close-BeoJC3Uv.js.map +1 -0
- package/app-dist/assets/close-DpAyMC6Y.js +9 -0
- package/app-dist/assets/close-DpAyMC6Y.js.map +1 -0
- package/app-dist/assets/coinPlaceholder-7j0sMili.js +9 -0
- package/app-dist/assets/coinPlaceholder-7j0sMili.js.map +1 -0
- package/app-dist/assets/coinPlaceholder-DgRNfUoS.js +9 -0
- package/app-dist/assets/coinPlaceholder-DgRNfUoS.js.map +0 -0
- package/app-dist/assets/coinPlaceholder-okFRLG_E.js +9 -0
- package/app-dist/assets/coinPlaceholder-okFRLG_E.js.map +1 -0
- package/app-dist/assets/compass-CswIWfIU.js +9 -0
- package/app-dist/assets/compass-CswIWfIU.js.map +1 -0
- package/app-dist/assets/compass-D2UP2WYp.js +9 -0
- package/app-dist/assets/compass-D2UP2WYp.js.map +1 -0
- package/app-dist/assets/compass-DegPL0E7.js +9 -0
- package/app-dist/assets/compass-DegPL0E7.js.map +0 -0
- package/app-dist/assets/connect-UA7M4XW6-IY3X6Bmr.js +2 -0
- package/app-dist/assets/connect-UA7M4XW6-IY3X6Bmr.js.map +1 -0
- package/app-dist/assets/copy-BUQNBQKO.js +16 -0
- package/app-dist/assets/copy-BUQNBQKO.js.map +1 -0
- package/app-dist/assets/copy-CH08PmRP.js +16 -0
- package/app-dist/assets/copy-CH08PmRP.js.map +1 -0
- package/app-dist/assets/copy-DDSY1US-.js +16 -0
- package/app-dist/assets/copy-DDSY1US-.js.map +0 -0
- package/app-dist/assets/core-934haPKz.js +909 -0
- package/app-dist/assets/core-934haPKz.js.map +1 -0
- package/app-dist/assets/core-CnB1gfzN.js +909 -0
- package/app-dist/assets/core-CnB1gfzN.js.map +0 -0
- package/app-dist/assets/core-D0TC3Irc.js +909 -0
- package/app-dist/assets/core-D0TC3Irc.js.map +1 -0
- package/app-dist/assets/create-FASO7PVG-D_rvSpre.js +2 -0
- package/app-dist/assets/create-FASO7PVG-D_rvSpre.js.map +1 -0
- package/app-dist/assets/cronos-HJPAQTAE-BEOvlOC4.js +2 -0
- package/app-dist/assets/cronos-HJPAQTAE-BEOvlOC4.js.map +1 -0
- package/app-dist/assets/cursor-BC4aSsg6.js +4 -0
- package/app-dist/assets/cursor-BC4aSsg6.js.map +0 -0
- package/app-dist/assets/cursor-BbkSQ8O8.js +4 -0
- package/app-dist/assets/cursor-BbkSQ8O8.js.map +1 -0
- package/app-dist/assets/cursor-EZA60-dh.js +4 -0
- package/app-dist/assets/cursor-EZA60-dh.js.map +1 -0
- package/app-dist/assets/cursor-transparent-BYLTaIJ6.js +13 -0
- package/app-dist/assets/cursor-transparent-BYLTaIJ6.js.map +1 -0
- package/app-dist/assets/cursor-transparent-DfXiz1dJ.js +13 -0
- package/app-dist/assets/cursor-transparent-DfXiz1dJ.js.map +1 -0
- package/app-dist/assets/cursor-transparent-DgQzgZ6k.js +13 -0
- package/app-dist/assets/cursor-transparent-DgQzgZ6k.js.map +0 -0
- package/app-dist/assets/de_DE-PYAO5YD6-BWlqPWgO.js +1488 -0
- package/app-dist/assets/de_DE-PYAO5YD6-BWlqPWgO.js.map +1 -0
- package/app-dist/assets/degen-FQQ4XGHB-CeHTs88l.js +2 -0
- package/app-dist/assets/degen-FQQ4XGHB-CeHTs88l.js.map +1 -0
- package/app-dist/assets/desktop-B0oUxvE2.js +10 -0
- package/app-dist/assets/desktop-B0oUxvE2.js.map +0 -0
- package/app-dist/assets/desktop-BXTprGjq.js +10 -0
- package/app-dist/assets/desktop-BXTprGjq.js.map +1 -0
- package/app-dist/assets/desktop-CfOv1C53.js +10 -0
- package/app-dist/assets/desktop-CfOv1C53.js.map +1 -0
- package/app-dist/assets/disconnect-28QqKBLG.js +9 -0
- package/app-dist/assets/disconnect-28QqKBLG.js.map +1 -0
- package/app-dist/assets/disconnect-CLpknshm.js +9 -0
- package/app-dist/assets/disconnect-CLpknshm.js.map +1 -0
- package/app-dist/assets/disconnect-_WlV_ypl.js +9 -0
- package/app-dist/assets/disconnect-_WlV_ypl.js.map +0 -0
- package/app-dist/assets/discord-CM01WZ7v.js +18 -0
- package/app-dist/assets/discord-CM01WZ7v.js.map +1 -0
- package/app-dist/assets/discord-DA_9T3af.js +18 -0
- package/app-dist/assets/discord-DA_9T3af.js.map +1 -0
- package/app-dist/assets/discord-DLSaUvT5.js +18 -0
- package/app-dist/assets/discord-DLSaUvT5.js.map +0 -0
- package/app-dist/assets/es_419-HRGOJ6VT-D-qzxUM-.js +1488 -0
- package/app-dist/assets/es_419-HRGOJ6VT-D-qzxUM-.js.map +1 -0
- package/app-dist/assets/ethereum-RGGVA4PY-SWGOlkuk.js +2 -0
- package/app-dist/assets/ethereum-RGGVA4PY-SWGOlkuk.js.map +1 -0
- package/app-dist/assets/etherscan-CJQ-3naZ.js +7 -0
- package/app-dist/assets/etherscan-CJQ-3naZ.js.map +1 -0
- package/app-dist/assets/etherscan-DKAtH0_w.js +7 -0
- package/app-dist/assets/etherscan-DKAtH0_w.js.map +1 -0
- package/app-dist/assets/etherscan-DdyO6DfW.js +7 -0
- package/app-dist/assets/etherscan-DdyO6DfW.js.map +0 -0
- package/app-dist/assets/events-C-nGMAUz.js +2 -0
- package/app-dist/assets/events-C-nGMAUz.js.map +1 -0
- package/app-dist/assets/events-DGXtGlqW.js +2 -0
- package/app-dist/assets/events-DGXtGlqW.js.map +0 -0
- package/app-dist/assets/events-V5iwB1aA.js +2 -0
- package/app-dist/assets/events-V5iwB1aA.js.map +1 -0
- package/app-dist/assets/exclamation-triangle-BpkRYFbz.js +5 -0
- package/app-dist/assets/exclamation-triangle-BpkRYFbz.js.map +1 -0
- package/app-dist/assets/exclamation-triangle-CUEbLIXX.js +5 -0
- package/app-dist/assets/exclamation-triangle-CUEbLIXX.js.map +0 -0
- package/app-dist/assets/exclamation-triangle-W3jsBnbs.js +5 -0
- package/app-dist/assets/exclamation-triangle-W3jsBnbs.js.map +1 -0
- package/app-dist/assets/extension-Bw6aI6CD.js +9 -0
- package/app-dist/assets/extension-Bw6aI6CD.js.map +1 -0
- package/app-dist/assets/extension-CBEZDBRi.js +9 -0
- package/app-dist/assets/extension-CBEZDBRi.js.map +0 -0
- package/app-dist/assets/extension-CrdF9uQv.js +9 -0
- package/app-dist/assets/extension-CrdF9uQv.js.map +1 -0
- package/app-dist/assets/external-link-3xiNxHuX.js +9 -0
- package/app-dist/assets/external-link-3xiNxHuX.js.map +1 -0
- package/app-dist/assets/external-link-BHInMwbS.js +9 -0
- package/app-dist/assets/external-link-BHInMwbS.js.map +1 -0
- package/app-dist/assets/external-link-NI08Iugo.js +9 -0
- package/app-dist/assets/external-link-NI08Iugo.js.map +0 -0
- package/app-dist/assets/facebook-B-BDj4Mx.js +27 -0
- package/app-dist/assets/facebook-B-BDj4Mx.js.map +1 -0
- package/app-dist/assets/facebook-D4To_IcG.js +27 -0
- package/app-dist/assets/facebook-D4To_IcG.js.map +0 -0
- package/app-dist/assets/facebook-DJ4p_RSy.js +27 -0
- package/app-dist/assets/facebook-DJ4p_RSy.js.map +1 -0
- package/app-dist/assets/farcaster-BKjN0wJM.js +13 -0
- package/app-dist/assets/farcaster-BKjN0wJM.js.map +1 -0
- package/app-dist/assets/farcaster-BTHbqyy5.js +13 -0
- package/app-dist/assets/farcaster-BTHbqyy5.js.map +1 -0
- package/app-dist/assets/farcaster-BU0IdcaC.js +13 -0
- package/app-dist/assets/farcaster-BU0IdcaC.js.map +0 -0
- package/app-dist/assets/filters-BjdDmCeO.js +9 -0
- package/app-dist/assets/filters-BjdDmCeO.js.map +0 -0
- package/app-dist/assets/filters-CeIbsl7p.js +9 -0
- package/app-dist/assets/filters-CeIbsl7p.js.map +1 -0
- package/app-dist/assets/filters-CeqsW5y_.js +9 -0
- package/app-dist/assets/filters-CeqsW5y_.js.map +1 -0
- package/app-dist/assets/flow-5FQJFCTK-CUie2reO.js +2 -0
- package/app-dist/assets/flow-5FQJFCTK-CUie2reO.js.map +1 -0
- package/app-dist/assets/fr_FR-IGGVC6RM-D8LpUM75.js +1488 -0
- package/app-dist/assets/fr_FR-IGGVC6RM-D8LpUM75.js.map +1 -0
- package/app-dist/assets/github-COBzxMpo.js +19 -0
- package/app-dist/assets/github-COBzxMpo.js.map +1 -0
- package/app-dist/assets/github-UoB8TY06.js +19 -0
- package/app-dist/assets/github-UoB8TY06.js.map +1 -0
- package/app-dist/assets/github-tfIdZEgg.js +19 -0
- package/app-dist/assets/github-tfIdZEgg.js.map +0 -0
- package/app-dist/assets/gnosis-37ZC4RBL-B137OtHZ.js +2 -0
- package/app-dist/assets/gnosis-37ZC4RBL-B137OtHZ.js.map +1 -0
- package/app-dist/assets/google-BMBqSrtr.js +19 -0
- package/app-dist/assets/google-BMBqSrtr.js.map +1 -0
- package/app-dist/assets/google-C33fwdPQ.js +19 -0
- package/app-dist/assets/google-C33fwdPQ.js.map +0 -0
- package/app-dist/assets/google-DWOXMwCZ.js +19 -0
- package/app-dist/assets/google-DWOXMwCZ.js.map +1 -0
- package/app-dist/assets/gravity-J5YQHTYH-Bj6B0uod.js +2 -0
- package/app-dist/assets/gravity-J5YQHTYH-Bj6B0uod.js.map +1 -0
- package/app-dist/assets/hardhat-TX56IT5N-CV1FY-wE.js +2 -0
- package/app-dist/assets/hardhat-TX56IT5N-CV1FY-wE.js.map +1 -0
- package/app-dist/assets/help-circle-CfNkpcpo.js +13 -0
- package/app-dist/assets/help-circle-CfNkpcpo.js.map +1 -0
- package/app-dist/assets/help-circle-DnnfIW69.js +13 -0
- package/app-dist/assets/help-circle-DnnfIW69.js.map +0 -0
- package/app-dist/assets/help-circle-nnSYZQHe.js +13 -0
- package/app-dist/assets/help-circle-nnSYZQHe.js.map +1 -0
- package/app-dist/assets/hi_IN-XSKAA3MF-C3QUpWyP.js +1488 -0
- package/app-dist/assets/hi_IN-XSKAA3MF-C3QUpWyP.js.map +1 -0
- package/app-dist/assets/hyperevm-VKPAA4SA-CHwraEsx.js +2 -0
- package/app-dist/assets/hyperevm-VKPAA4SA-CHwraEsx.js.map +1 -0
- package/app-dist/assets/id-BA1gQKAW.js +13 -0
- package/app-dist/assets/id-BA1gQKAW.js.map +1 -0
- package/app-dist/assets/id-ConjL7B0.js +13 -0
- package/app-dist/assets/id-ConjL7B0.js.map +1 -0
- package/app-dist/assets/id-LTSS8c5a.js +13 -0
- package/app-dist/assets/id-LTSS8c5a.js.map +0 -0
- package/app-dist/assets/id_ID-KUOB4UAL-K9y-nRWm.js +1488 -0
- package/app-dist/assets/id_ID-KUOB4UAL-K9y-nRWm.js.map +1 -0
- package/app-dist/assets/image-1X1N9pEo.js +5 -0
- package/app-dist/assets/image-1X1N9pEo.js.map +0 -0
- package/app-dist/assets/image-CnzWE8sT.js +5 -0
- package/app-dist/assets/image-CnzWE8sT.js.map +1 -0
- package/app-dist/assets/image-D8EBgbEy.js +5 -0
- package/app-dist/assets/image-D8EBgbEy.js.map +1 -0
- package/app-dist/assets/index-Acaa9INf.css +1 -0
- package/app-dist/assets/index-B36ryxz7.css +1 -0
- package/app-dist/assets/index-BD8n2rGx.js +2 -0
- package/app-dist/assets/index-BD8n2rGx.js.map +1 -0
- package/app-dist/assets/index-BG2lKNFT.js +396 -0
- package/app-dist/assets/index-BG2lKNFT.js.map +1 -0
- package/app-dist/assets/index-BJqyj4ib.js +2 -0
- package/app-dist/assets/index-BJqyj4ib.js.map +1 -0
- package/app-dist/assets/index-BNkizogK.js +2 -0
- package/app-dist/assets/index-BNkizogK.js.map +1 -0
- package/app-dist/assets/index-BV7ZaCR1.js +2 -0
- package/app-dist/assets/index-BV7ZaCR1.js.map +0 -0
- package/app-dist/assets/index-BfMkm3WT.js +396 -0
- package/app-dist/assets/index-BfMkm3WT.js.map +1 -0
- package/app-dist/assets/index-Bu_XtD5E.css +1 -0
- package/app-dist/assets/index-Bw0DyTKl.js +1753 -0
- package/app-dist/assets/index-Bw0DyTKl.js.map +1 -0
- package/app-dist/assets/index-Bx9SdYRI.js +396 -0
- package/app-dist/assets/index-Bx9SdYRI.js.map +0 -0
- package/app-dist/assets/index-Cf9eUEVe.js +2 -0
- package/app-dist/assets/index-Cf9eUEVe.js.map +1 -0
- package/app-dist/assets/index-Cu9oSBA4.js +2 -0
- package/app-dist/assets/index-Cu9oSBA4.js.map +0 -0
- package/app-dist/assets/index-DMFcetuY.js +17 -0
- package/app-dist/assets/index-DMFcetuY.js.map +0 -0
- package/app-dist/assets/index-bl8KCnX7.js +1610 -0
- package/app-dist/assets/index-bl8KCnX7.js.map +0 -0
- package/app-dist/assets/index-gh3LLqN4.js +17 -0
- package/app-dist/assets/index-gh3LLqN4.js.map +1 -0
- package/app-dist/assets/index-m8qSBWEb.js +1753 -0
- package/app-dist/assets/index-m8qSBWEb.js.map +1 -0
- package/app-dist/assets/index-nibyPLVP.js +2 -0
- package/app-dist/assets/index-nibyPLVP.js.map +1 -0
- package/app-dist/assets/index-zDP7hiYr.js +17 -0
- package/app-dist/assets/index-zDP7hiYr.js.map +1 -0
- package/app-dist/assets/index.es-BcffXcp9.js +27 -0
- package/app-dist/assets/index.es-BcffXcp9.js.map +0 -0
- package/app-dist/assets/index.es-Ch6fFmdq.js +27 -0
- package/app-dist/assets/index.es-Ch6fFmdq.js.map +1 -0
- package/app-dist/assets/index.es-DE_zEOto.js +27 -0
- package/app-dist/assets/index.es-DE_zEOto.js.map +1 -0
- package/app-dist/assets/info-BY-gCRMd.js +4 -0
- package/app-dist/assets/info-BY-gCRMd.js.map +1 -0
- package/app-dist/assets/info-D7gXoZPi.js +4 -0
- package/app-dist/assets/info-D7gXoZPi.js.map +0 -0
- package/app-dist/assets/info-DfhESGyw.js +4 -0
- package/app-dist/assets/info-DfhESGyw.js.map +1 -0
- package/app-dist/assets/info-circle--klNFwmq.js +13 -0
- package/app-dist/assets/info-circle--klNFwmq.js.map +1 -0
- package/app-dist/assets/info-circle-C59FTc51.js +13 -0
- package/app-dist/assets/info-circle-C59FTc51.js.map +0 -0
- package/app-dist/assets/info-circle-DrnnGW73.js +13 -0
- package/app-dist/assets/info-circle-DrnnGW73.js.map +1 -0
- package/app-dist/assets/ink-FZMYZWHG-62p-5IK5.js +2 -0
- package/app-dist/assets/ink-FZMYZWHG-62p-5IK5.js.map +1 -0
- package/app-dist/assets/ja_JP-4WRQ63RX-Ct5pF4ug.js +1488 -0
- package/app-dist/assets/ja_JP-4WRQ63RX-Ct5pF4ug.js.map +1 -0
- package/app-dist/assets/kaia-65D2U3PU-JmuLQ4gC.js +2 -0
- package/app-dist/assets/kaia-65D2U3PU-JmuLQ4gC.js.map +1 -0
- package/app-dist/assets/ko_KR-I2K7AIEP-B5gw8Mwb.js +1488 -0
- package/app-dist/assets/ko_KR-I2K7AIEP-B5gw8Mwb.js.map +1 -0
- package/app-dist/assets/lightbulb-BTEvb2k7.js +4 -0
- package/app-dist/assets/lightbulb-BTEvb2k7.js.map +0 -0
- package/app-dist/assets/lightbulb-Bi58NOv6.js +4 -0
- package/app-dist/assets/lightbulb-Bi58NOv6.js.map +1 -0
- package/app-dist/assets/lightbulb-BnYQt3eU.js +4 -0
- package/app-dist/assets/lightbulb-BnYQt3eU.js.map +1 -0
- package/app-dist/assets/linea-QRMVQ5DY-DuI3vv0d.js +2 -0
- package/app-dist/assets/linea-QRMVQ5DY-DuI3vv0d.js.map +1 -0
- package/app-dist/assets/login-UP3DZBGS-Db_wM5oQ.js +2 -0
- package/app-dist/assets/login-UP3DZBGS-Db_wM5oQ.js.map +1 -0
- package/app-dist/assets/mail-BCS3Hmz0.js +9 -0
- package/app-dist/assets/mail-BCS3Hmz0.js.map +0 -0
- package/app-dist/assets/mail-NVYe_3V7.js +9 -0
- package/app-dist/assets/mail-NVYe_3V7.js.map +1 -0
- package/app-dist/assets/mail-Xf-Dw9Jy.js +9 -0
- package/app-dist/assets/mail-Xf-Dw9Jy.js.map +1 -0
- package/app-dist/assets/manta-SI27YFEJ-CpVOKa06.js +2 -0
- package/app-dist/assets/manta-SI27YFEJ-CpVOKa06.js.map +1 -0
- package/app-dist/assets/mantle-CKIUT334-DR2WgqzU.js +2 -0
- package/app-dist/assets/mantle-CKIUT334-DR2WgqzU.js.map +1 -0
- package/app-dist/assets/metaMaskWallet-SITXT2FV-BlemcphV.js +2 -0
- package/app-dist/assets/metaMaskWallet-SITXT2FV-BlemcphV.js.map +1 -0
- package/app-dist/assets/metamask-sdk-Bswiy7kc.js +543 -0
- package/app-dist/assets/metamask-sdk-Bswiy7kc.js.map +0 -0
- package/app-dist/assets/metamask-sdk-Dd2lmGg5.js +543 -0
- package/app-dist/assets/metamask-sdk-Dd2lmGg5.js.map +1 -0
- package/app-dist/assets/metamask-sdk-Dk18cS5U.js +543 -0
- package/app-dist/assets/metamask-sdk-Dk18cS5U.js.map +1 -0
- package/app-dist/assets/mobile-BhvN5ELh.js +10 -0
- package/app-dist/assets/mobile-BhvN5ELh.js.map +1 -0
- package/app-dist/assets/mobile-Dnnfz06O.js +10 -0
- package/app-dist/assets/mobile-Dnnfz06O.js.map +1 -0
- package/app-dist/assets/mobile-bk-rEeQm.js +10 -0
- package/app-dist/assets/mobile-bk-rEeQm.js.map +0 -0
- package/app-dist/assets/monad-4KWC6TSS-DVXSkpiz.js +2 -0
- package/app-dist/assets/monad-4KWC6TSS-DVXSkpiz.js.map +1 -0
- package/app-dist/assets/more-BZC9ufLh.js +12 -0
- package/app-dist/assets/more-BZC9ufLh.js.map +0 -0
- package/app-dist/assets/more-DAN1-99P.js +12 -0
- package/app-dist/assets/more-DAN1-99P.js.map +1 -0
- package/app-dist/assets/more-DPY5dZh3.js +12 -0
- package/app-dist/assets/more-DPY5dZh3.js.map +1 -0
- package/app-dist/assets/ms_MY-6VZW6Q3Z-BtFD07hR.js +1488 -0
- package/app-dist/assets/ms_MY-6VZW6Q3Z-BtFD07hR.js.map +1 -0
- package/app-dist/assets/network-placeholder-BZBthQUA.js +15 -0
- package/app-dist/assets/network-placeholder-BZBthQUA.js.map +1 -0
- package/app-dist/assets/network-placeholder-DBaBbSPm.js +15 -0
- package/app-dist/assets/network-placeholder-DBaBbSPm.js.map +1 -0
- package/app-dist/assets/network-placeholder-fSD0Hnoz.js +15 -0
- package/app-dist/assets/network-placeholder-fSD0Hnoz.js.map +0 -0
- package/app-dist/assets/nftPlaceholder-Cn-ju_m0.js +9 -0
- package/app-dist/assets/nftPlaceholder-Cn-ju_m0.js.map +1 -0
- package/app-dist/assets/nftPlaceholder-Cuf1LJxh.js +9 -0
- package/app-dist/assets/nftPlaceholder-Cuf1LJxh.js.map +1 -0
- package/app-dist/assets/nftPlaceholder-Df0vgj0s.js +9 -0
- package/app-dist/assets/nftPlaceholder-Df0vgj0s.js.map +0 -0
- package/app-dist/assets/off-BA0GdN0u.js +9 -0
- package/app-dist/assets/off-BA0GdN0u.js.map +1 -0
- package/app-dist/assets/off-BmvDze4S.js +9 -0
- package/app-dist/assets/off-BmvDze4S.js.map +0 -0
- package/app-dist/assets/off-CWKjhP29.js +9 -0
- package/app-dist/assets/off-CWKjhP29.js.map +1 -0
- package/app-dist/assets/optimism-HAF2GUT7-ec6Nqxs9.js +2 -0
- package/app-dist/assets/optimism-HAF2GUT7-ec6Nqxs9.js.map +1 -0
- package/app-dist/assets/play-store-1KSI-YkA.js +0 -0
- package/app-dist/assets/play-store-1KSI-YkA.js.map +0 -0
- package/app-dist/assets/play-store-7Uft13-I.js +33 -0
- package/app-dist/assets/play-store-7Uft13-I.js.map +1 -0
- package/app-dist/assets/play-store-CMt_52bt.js +33 -0
- package/app-dist/assets/play-store-CMt_52bt.js.map +1 -0
- package/app-dist/assets/plus-DA9slqh_.js +14 -0
- package/app-dist/assets/plus-DA9slqh_.js.map +1 -0
- package/app-dist/assets/plus-DeArAyIN.js +14 -0
- package/app-dist/assets/plus-DeArAyIN.js.map +1 -0
- package/app-dist/assets/plus-ttkAaJbX.js +14 -0
- package/app-dist/assets/plus-ttkAaJbX.js.map +0 -0
- package/app-dist/assets/polygon-WW6ZI7PM-DXlmm4L1.js +2 -0
- package/app-dist/assets/polygon-WW6ZI7PM-DXlmm4L1.js.map +1 -0
- package/app-dist/assets/pt_BR-N3XOZ4SV-CvVpfsHb.js +1488 -0
- package/app-dist/assets/pt_BR-N3XOZ4SV-CvVpfsHb.js.map +1 -0
- package/app-dist/assets/qr-code-B6Nxd7r0.js +7 -0
- package/app-dist/assets/qr-code-B6Nxd7r0.js.map +1 -0
- package/app-dist/assets/qr-code-Bq5zVwzG.js +7 -0
- package/app-dist/assets/qr-code-Bq5zVwzG.js.map +0 -0
- package/app-dist/assets/qr-code-ChHwFaPr.js +7 -0
- package/app-dist/assets/qr-code-ChHwFaPr.js.map +1 -0
- package/app-dist/assets/rainbowWallet-O26YNBMX-DUhYus-9.js +2 -0
- package/app-dist/assets/rainbowWallet-O26YNBMX-DUhYus-9.js.map +1 -0
- package/app-dist/assets/recycle-horizontal-BBt9gto7.js +10 -0
- package/app-dist/assets/recycle-horizontal-BBt9gto7.js.map +1 -0
- package/app-dist/assets/recycle-horizontal-BaNxuTZz.js +10 -0
- package/app-dist/assets/recycle-horizontal-BaNxuTZz.js.map +0 -0
- package/app-dist/assets/recycle-horizontal-BeOWfmaR.js +10 -0
- package/app-dist/assets/recycle-horizontal-BeOWfmaR.js.map +1 -0
- package/app-dist/assets/refresh-CeUMiLYY.js +9 -0
- package/app-dist/assets/refresh-CeUMiLYY.js.map +0 -0
- package/app-dist/assets/refresh-DXqLx3hf.js +9 -0
- package/app-dist/assets/refresh-DXqLx3hf.js.map +1 -0
- package/app-dist/assets/refresh-S4T5V5GX-CwqIaaxK.js +2 -0
- package/app-dist/assets/refresh-S4T5V5GX-CwqIaaxK.js.map +1 -0
- package/app-dist/assets/refresh-r_CwnI6n.js +9 -0
- package/app-dist/assets/refresh-r_CwnI6n.js.map +1 -0
- package/app-dist/assets/reown-logo-Cl87QtVl.js +13 -0
- package/app-dist/assets/reown-logo-Cl87QtVl.js.map +1 -0
- package/app-dist/assets/reown-logo-CtELU8EI.js +0 -0
- package/app-dist/assets/reown-logo-CtELU8EI.js.map +0 -0
- package/app-dist/assets/reown-logo-EAOTbnwj.js +13 -0
- package/app-dist/assets/reown-logo-EAOTbnwj.js.map +1 -0
- package/app-dist/assets/ronin-EMCPYXZT-N-QBHZdV.js +2 -0
- package/app-dist/assets/ronin-EMCPYXZT-N-QBHZdV.js.map +1 -0
- package/app-dist/assets/ru_RU-IITAPRET-DOj6Jzj7.js +1488 -0
- package/app-dist/assets/ru_RU-IITAPRET-DOj6Jzj7.js.map +1 -0
- package/app-dist/assets/safeWallet-5MNKTR5Z-D-5imDLD.js +2 -0
- package/app-dist/assets/safeWallet-5MNKTR5Z-D-5imDLD.js.map +1 -0
- package/app-dist/assets/sanko-RHQYXGM5-OX010CbN.js +2 -0
- package/app-dist/assets/sanko-RHQYXGM5-OX010CbN.js.map +1 -0
- package/app-dist/assets/scan-4UYSQ56Q-CjMz6-XC.js +2 -0
- package/app-dist/assets/scan-4UYSQ56Q-CjMz6-XC.js.map +1 -0
- package/app-dist/assets/scroll-5OBGQVOV-DJFECiai.js +2 -0
- package/app-dist/assets/scroll-5OBGQVOV-DJFECiai.js.map +1 -0
- package/app-dist/assets/search-BIpf7E5h.js +9 -0
- package/app-dist/assets/search-BIpf7E5h.js.map +1 -0
- package/app-dist/assets/search-C0MSODDG.js +9 -0
- package/app-dist/assets/search-C0MSODDG.js.map +1 -0
- package/app-dist/assets/search-CZEQdX_m.js +9 -0
- package/app-dist/assets/search-CZEQdX_m.js.map +0 -0
- package/app-dist/assets/secp256k1-6vcaH-hZ.js +2 -0
- package/app-dist/assets/secp256k1-6vcaH-hZ.js.map +0 -0
- package/app-dist/assets/secp256k1-BTIn5g_i.js +2 -0
- package/app-dist/assets/secp256k1-BTIn5g_i.js.map +1 -0
- package/app-dist/assets/secp256k1-Dw2ShtHs.js +2 -0
- package/app-dist/assets/secp256k1-Dw2ShtHs.js.map +0 -0
- package/app-dist/assets/secp256k1-UGVTesID.js +2 -0
- package/app-dist/assets/secp256k1-UGVTesID.js.map +1 -0
- package/app-dist/assets/secp256k1-WgYt5tWe.js +2 -0
- package/app-dist/assets/secp256k1-WgYt5tWe.js.map +1 -0
- package/app-dist/assets/secp256k1-ZdcG5_q9.js +2 -0
- package/app-dist/assets/secp256k1-ZdcG5_q9.js.map +1 -0
- package/app-dist/assets/send-B1YPNG_e.js +16 -0
- package/app-dist/assets/send-B1YPNG_e.js.map +1 -0
- package/app-dist/assets/send-DIxJoab7.js +16 -0
- package/app-dist/assets/send-DIxJoab7.js.map +0 -0
- package/app-dist/assets/send-DwEqE_Iw.js +16 -0
- package/app-dist/assets/send-DwEqE_Iw.js.map +1 -0
- package/app-dist/assets/sign-A7IJEUT5-CGsRnPrd.js +2 -0
- package/app-dist/assets/sign-A7IJEUT5-CGsRnPrd.js.map +1 -0
- package/app-dist/assets/superposition-HG6MMR2Y-bRkgatRO.js +2 -0
- package/app-dist/assets/superposition-HG6MMR2Y-bRkgatRO.js.map +1 -0
- package/app-dist/assets/swapHorizontal-BF8vSwPR.js +9 -0
- package/app-dist/assets/swapHorizontal-BF8vSwPR.js.map +0 -0
- package/app-dist/assets/swapHorizontal-BVZ3G47g.js +9 -0
- package/app-dist/assets/swapHorizontal-BVZ3G47g.js.map +1 -0
- package/app-dist/assets/swapHorizontal-D3IG_uQT.js +9 -0
- package/app-dist/assets/swapHorizontal-D3IG_uQT.js.map +1 -0
- package/app-dist/assets/swapHorizontalBold-Bs2d-WYn.js +9 -0
- package/app-dist/assets/swapHorizontalBold-Bs2d-WYn.js.map +1 -0
- package/app-dist/assets/swapHorizontalBold-CF13elKE.js +9 -0
- package/app-dist/assets/swapHorizontalBold-CF13elKE.js.map +0 -0
- package/app-dist/assets/swapHorizontalBold-CV00HZay.js +9 -0
- package/app-dist/assets/swapHorizontalBold-CV00HZay.js.map +1 -0
- package/app-dist/assets/swapHorizontalMedium-DmC2VRKQ.js +17 -0
- package/app-dist/assets/swapHorizontalMedium-DmC2VRKQ.js.map +1 -0
- package/app-dist/assets/swapHorizontalMedium-DmsZRV8w.js +17 -0
- package/app-dist/assets/swapHorizontalMedium-DmsZRV8w.js.map +1 -0
- package/app-dist/assets/swapHorizontalMedium-siVNmc-5.js +17 -0
- package/app-dist/assets/swapHorizontalMedium-siVNmc-5.js.map +0 -0
- package/app-dist/assets/swapHorizontalRoundedBold-BSycj5mH.js +9 -0
- package/app-dist/assets/swapHorizontalRoundedBold-BSycj5mH.js.map +1 -0
- package/app-dist/assets/swapHorizontalRoundedBold-DCruWIeG.js +9 -0
- package/app-dist/assets/swapHorizontalRoundedBold-DCruWIeG.js.map +1 -0
- package/app-dist/assets/swapHorizontalRoundedBold-FPj1enHe.js +9 -0
- package/app-dist/assets/swapHorizontalRoundedBold-FPj1enHe.js.map +0 -0
- package/app-dist/assets/swapVertical-BBlDJ0wU.js +9 -0
- package/app-dist/assets/swapVertical-BBlDJ0wU.js.map +1 -0
- package/app-dist/assets/swapVertical-BdixiATC.js +9 -0
- package/app-dist/assets/swapVertical-BdixiATC.js.map +1 -0
- package/app-dist/assets/swapVertical-CsNeXIDf.js +9 -0
- package/app-dist/assets/swapVertical-CsNeXIDf.js.map +0 -0
- package/app-dist/assets/telegram-CZTfaW5R.js +17 -0
- package/app-dist/assets/telegram-CZTfaW5R.js.map +0 -0
- package/app-dist/assets/telegram-CfQNs_qk.js +17 -0
- package/app-dist/assets/telegram-CfQNs_qk.js.map +1 -0
- package/app-dist/assets/telegram-DyKP2tSP.js +17 -0
- package/app-dist/assets/telegram-DyKP2tSP.js.map +1 -0
- package/app-dist/assets/th_TH-3ZQCKCQE-BcHUN2Q4.js +1488 -0
- package/app-dist/assets/th_TH-3ZQCKCQE-BcHUN2Q4.js.map +1 -0
- package/app-dist/assets/three-dots-D7hZJWqD.js +6 -0
- package/app-dist/assets/three-dots-D7hZJWqD.js.map +0 -0
- package/app-dist/assets/three-dots-DKxr-fZm.js +6 -0
- package/app-dist/assets/three-dots-DKxr-fZm.js.map +1 -0
- package/app-dist/assets/three-dots-ZNXQKqRA.js +6 -0
- package/app-dist/assets/three-dots-ZNXQKqRA.js.map +1 -0
- package/app-dist/assets/tr_TR-QUPUGMUF-CwpF6ZFn.js +1488 -0
- package/app-dist/assets/tr_TR-QUPUGMUF-CwpF6ZFn.js.map +1 -0
- package/app-dist/assets/twitch-BkfjQBCS.js +19 -0
- package/app-dist/assets/twitch-BkfjQBCS.js.map +1 -0
- package/app-dist/assets/twitch-Bt6sNQO2.js +19 -0
- package/app-dist/assets/twitch-Bt6sNQO2.js.map +0 -0
- package/app-dist/assets/twitch-BvUrl1UX.js +19 -0
- package/app-dist/assets/twitch-BvUrl1UX.js.map +1 -0
- package/app-dist/assets/twitterIcon-BJgZokLW.js +7 -0
- package/app-dist/assets/twitterIcon-BJgZokLW.js.map +1 -0
- package/app-dist/assets/twitterIcon-BY7OY2GX.js +7 -0
- package/app-dist/assets/twitterIcon-BY7OY2GX.js.map +1 -0
- package/app-dist/assets/twitterIcon-Dvu-dDEg.js +7 -0
- package/app-dist/assets/twitterIcon-Dvu-dDEg.js.map +0 -0
- package/app-dist/assets/uk_UA-SSN6SV5E-IlYYyRC6.js +1488 -0
- package/app-dist/assets/uk_UA-SSN6SV5E-IlYYyRC6.js.map +1 -0
- package/app-dist/assets/unichain-C5BWO2ZY-BfguYsnu.js +2 -0
- package/app-dist/assets/unichain-C5BWO2ZY-BfguYsnu.js.map +1 -0
- package/app-dist/assets/verify-6ofWwX2p.js +9 -0
- package/app-dist/assets/verify-6ofWwX2p.js.map +1 -0
- package/app-dist/assets/verify-BmdjVjoU.js +9 -0
- package/app-dist/assets/verify-BmdjVjoU.js.map +1 -0
- package/app-dist/assets/verify-Dqd-Oj6j.js +9 -0
- package/app-dist/assets/verify-Dqd-Oj6j.js.map +0 -0
- package/app-dist/assets/verify-filled-Bd7cBcl6.js +9 -0
- package/app-dist/assets/verify-filled-Bd7cBcl6.js.map +1 -0
- package/app-dist/assets/verify-filled-CGEF4WVN.js +9 -0
- package/app-dist/assets/verify-filled-CGEF4WVN.js.map +0 -0
- package/app-dist/assets/verify-filled-Cf-TeM4T.js +9 -0
- package/app-dist/assets/verify-filled-Cf-TeM4T.js.map +1 -0
- package/app-dist/assets/vi_VN-7BUVRNYY-CZ9S75qZ.js +1488 -0
- package/app-dist/assets/vi_VN-7BUVRNYY-CZ9S75qZ.js.map +1 -0
- package/app-dist/assets/w3m-modal-CWyXHUW5.js +643 -0
- package/app-dist/assets/w3m-modal-CWyXHUW5.js.map +1 -0
- package/app-dist/assets/w3m-modal-CnoO8YJf.js +0 -0
- package/app-dist/assets/w3m-modal-CnoO8YJf.js.map +0 -0
- package/app-dist/assets/w3m-modal-xrIPs4AE.js +643 -0
- package/app-dist/assets/w3m-modal-xrIPs4AE.js.map +1 -0
- package/app-dist/assets/wallet-B9tNiUsz.js +9 -0
- package/app-dist/assets/wallet-B9tNiUsz.js.map +0 -0
- package/app-dist/assets/wallet-BZ4F_yJB.js +9 -0
- package/app-dist/assets/wallet-BZ4F_yJB.js.map +1 -0
- package/app-dist/assets/wallet-Dwi1CFfY.js +9 -0
- package/app-dist/assets/wallet-Dwi1CFfY.js.map +1 -0
- package/app-dist/assets/wallet-placeholder-9FExN6iz.js +15 -0
- package/app-dist/assets/wallet-placeholder-9FExN6iz.js.map +1 -0
- package/app-dist/assets/wallet-placeholder-DTYChZmr.js +15 -0
- package/app-dist/assets/wallet-placeholder-DTYChZmr.js.map +0 -0
- package/app-dist/assets/wallet-placeholder-DpYL6Gkg.js +15 -0
- package/app-dist/assets/wallet-placeholder-DpYL6Gkg.js.map +1 -0
- package/app-dist/assets/walletConnectWallet-YHWKVTDY-D3lyiczV.js +2 -0
- package/app-dist/assets/walletConnectWallet-YHWKVTDY-D3lyiczV.js.map +1 -0
- package/app-dist/assets/walletconnect-D7I3rksa.js +31 -0
- package/app-dist/assets/walletconnect-D7I3rksa.js.map +0 -0
- package/app-dist/assets/walletconnect-DAi4FVBA.js +31 -0
- package/app-dist/assets/walletconnect-DAi4FVBA.js.map +1 -0
- package/app-dist/assets/walletconnect-DJRTAE4R.js +31 -0
- package/app-dist/assets/walletconnect-DJRTAE4R.js.map +1 -0
- package/app-dist/assets/warning-circle-hyMAaK3d.js +13 -0
- package/app-dist/assets/warning-circle-hyMAaK3d.js.map +1 -0
- package/app-dist/assets/warning-circle-ygtzYLqr.js +13 -0
- package/app-dist/assets/warning-circle-ygtzYLqr.js.map +0 -0
- package/app-dist/assets/warning-circle-z9wNayCA.js +13 -0
- package/app-dist/assets/warning-circle-z9wNayCA.js.map +1 -0
- package/app-dist/assets/x-DsvNj0kT.js +13 -0
- package/app-dist/assets/x-DsvNj0kT.js.map +1 -0
- package/app-dist/assets/x-H7B0_YQh.js +13 -0
- package/app-dist/assets/x-H7B0_YQh.js.map +1 -0
- package/app-dist/assets/x-jMygn2bJ.js +13 -0
- package/app-dist/assets/x-jMygn2bJ.js.map +0 -0
- package/app-dist/assets/xdc-KJ3TDBYO-DNV6zchh.js +2 -0
- package/app-dist/assets/xdc-KJ3TDBYO-DNV6zchh.js.map +1 -0
- package/app-dist/assets/zetachain-TLDS5IPW-Udhyw16T.js +2 -0
- package/app-dist/assets/zetachain-TLDS5IPW-Udhyw16T.js.map +1 -0
- package/app-dist/assets/zh_CN-HJBN674C-Baf0GEeT.js +1488 -0
- package/app-dist/assets/zh_CN-HJBN674C-Baf0GEeT.js.map +1 -0
- package/app-dist/assets/zh_HK-JW3WLRKE-VztJKXL5.js +1488 -0
- package/app-dist/assets/zh_HK-JW3WLRKE-VztJKXL5.js.map +1 -0
- package/app-dist/assets/zh_TW-VNNRNXY7-aWfg7Qp4.js +1488 -0
- package/app-dist/assets/zh_TW-VNNRNXY7-aWfg7Qp4.js.map +1 -0
- package/app-dist/assets/zksync-DH7HK5U4-Dt4usFw6.js +2 -0
- package/app-dist/assets/zksync-DH7HK5U4-Dt4usFw6.js.map +1 -0
- package/app-dist/assets/zora-FYL5H3IO-iB4wygST.js +2 -0
- package/app-dist/assets/zora-FYL5H3IO-iB4wygST.js.map +1 -0
- package/app-dist/index.html +14 -0
- package/dist/RemoteSigner.d.ts +27 -0
- package/dist/RemoteSigner.d.ts.map +1 -0
- package/dist/RemoteSigner.js +108 -0
- package/dist/RemoteSigner.js.map +1 -0
- package/dist/SigningClient.d.ts +36 -0
- package/dist/SigningClient.d.ts.map +1 -0
- package/dist/SigningClient.js +132 -0
- package/dist/SigningClient.js.map +1 -0
- package/dist/SigningServer.d.ts +70 -0
- package/dist/SigningServer.d.ts.map +1 -0
- package/dist/SigningServer.js +584 -0
- package/dist/SigningServer.js.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +122 -0
- package/dist/index.js.map +1 -0
- package/dist/tasks/start.d.ts +2 -0
- package/dist/tasks/start.d.ts.map +1 -0
- package/dist/tasks/start.js +378 -0
- package/dist/tasks/start.js.map +1 -0
- package/dist/tasks/status.d.ts +2 -0
- package/dist/tasks/status.d.ts.map +1 -0
- package/dist/tasks/status.js +108 -0
- package/dist/tasks/status.js.map +1 -0
- package/dist/tasks/stop.d.ts +2 -0
- package/dist/tasks/stop.d.ts.map +1 -0
- package/dist/tasks/stop.js +92 -0
- package/dist/tasks/stop.js.map +1 -0
- package/dist/types.d.ts +154 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +3 -0
- package/dist/types.js.map +1 -0
- package/package.json +71 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-gh3LLqN4.js","sources":["../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/utils/abi/encodePacked.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/utils/nonceManager.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/constants/bytes.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/utils/signature/serializeErc6492Signature.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/clients/createPublicClient.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/utils/signature/parseSignature.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/chains/definitions/zora.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/zustand/esm/middleware.mjs","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/zustand/esm/vanilla.mjs","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/constants.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/store/store.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/telemetry-content.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/initCCA.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/constants.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/error/constants.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/error/utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/error/errors.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/assertPresence.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/checkCrossOriginOpenerPolicy.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/validatePreferences.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/logEvent.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/events/communicator.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/events/dialog.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/ui/assets/fontFaceCSS.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/ui/assets/injectFontStyle.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/preact/dist/preact.module.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/clsx/dist/clsx.m.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/username/getDisplayableUsername.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/ui/assets/colors.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/ui/assets/BaseLogo.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/preact/hooks/dist/hooks.module.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/ui/Dialog/Dialog-css.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/ui/Dialog/Dialog.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/ui/Dialog/index.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/web.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/communicator/Communicator.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/error/serialize.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/provider/interface.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/events/provider.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/type/index.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/type/util.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/events/scw-signer.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/core/telemetry/events/scw-sub-account.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/constants/abis.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/constants/address.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/userOperation/getInitCode.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/userOperation/toPackedUserOperation.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/userOperation/getUserOperationTypedData.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/userOperation/getUserOperationHash.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/accounts/toSmartAccount.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/errors/bundler.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/errors/userOperation.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/errors/getBundlerError.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/errors/getUserOperationError.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/formatters/userOperationGas.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/formatters/userOperationRequest.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/paymaster/getPaymasterData.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/paymaster/getPaymasterStubData.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/bundler/prepareUserOperation.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/bundler/estimateUserOperationGas.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/bundler/getSupportedEntryPoints.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/formatters/userOperation.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/bundler/getUserOperation.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/utils/formatters/userOperationReceipt.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/bundler/getUserOperationReceipt.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/bundler/sendUserOperation.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/actions/bundler/waitForUserOperationReceipt.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/clients/decorators/bundler.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/viem/_esm/account-abstraction/clients/createBundlerClient.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/store/chain-clients/store.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/store/chain-clients/utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/store/correlation-ids/store.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/assertSubAccount.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/cipher.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/provider.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/version.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/internal/errors.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Errors.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/node_modules/@noble/hashes/esm/utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/node_modules/@noble/hashes/esm/_md.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/node_modules/@noble/hashes/esm/sha2.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/node_modules/@noble/hashes/esm/sha256.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/node_modules/@noble/hashes/esm/crypto.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/node_modules/@noble/hashes/esm/utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/esm/utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Json.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/internal/bytes.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/internal/hex.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Hex.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Bytes.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Hash.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/PublicKey.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Solidity.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/node_modules/@noble/hashes/esm/_md.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/node_modules/@noble/hashes/esm/_u64.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/node_modules/@noble/hashes/esm/sha2.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/node_modules/@noble/hashes/esm/hmac.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/esm/abstract/modular.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/esm/abstract/curve.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/esm/abstract/weierstrass.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/esm/_shortw_utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Signature.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/Base64.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/esm/nist.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/@noble/curves/esm/p256.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/WebAuthnP256.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/node_modules/ox/_esm/core/WebCryptoP256.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/kms/crypto-key/storage.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/kms/crypto-key/index.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/SCWKeyManager.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/get.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/util/encoding.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/createSmartAccount.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/createSubAccountSigner.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/findOwnerIndex.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/presentAddOwnerDialog.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/handleAddSubAccountOwner.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/routeThroughGlobalAccount.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/utils/handleInsufficientBalance.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/sign/base-account/Signer.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/interface/builder/core/BaseAccountProvider.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/interface/builder/core/getInjectedProvider.js","../../../sessions/lucid-charming-johnson/mnt/pda/hardhat-airsign/node_modules/@base-org/account/dist/interface/builder/core/createBaseAccountSDK.js"],"sourcesContent":["import { AbiEncodingLengthMismatchError, BytesSizeMismatchError, UnsupportedPackedAbiType, } from '../../errors/abi.js';\nimport { InvalidAddressError, } from '../../errors/address.js';\nimport { isAddress } from '../address/isAddress.js';\nimport { concatHex } from '../data/concat.js';\nimport { pad } from '../data/pad.js';\nimport { boolToHex, numberToHex, stringToHex, } from '../encoding/toHex.js';\nimport { arrayRegex, bytesRegex, integerRegex } from '../regex.js';\nexport function encodePacked(types, values) {\n if (types.length !== values.length)\n throw new AbiEncodingLengthMismatchError({\n expectedLength: types.length,\n givenLength: values.length,\n });\n const data = [];\n for (let i = 0; i < types.length; i++) {\n const type = types[i];\n const value = values[i];\n data.push(encode(type, value));\n }\n return concatHex(data);\n}\nfunction encode(type, value, isArray = false) {\n if (type === 'address') {\n const address = value;\n if (!isAddress(address))\n throw new InvalidAddressError({ address });\n return pad(address.toLowerCase(), {\n size: isArray ? 32 : null,\n });\n }\n if (type === 'string')\n return stringToHex(value);\n if (type === 'bytes')\n return value;\n if (type === 'bool')\n return pad(boolToHex(value), { size: isArray ? 32 : 1 });\n const intMatch = type.match(integerRegex);\n if (intMatch) {\n const [_type, baseType, bits = '256'] = intMatch;\n const size = Number.parseInt(bits, 10) / 8;\n return numberToHex(value, {\n size: isArray ? 32 : size,\n signed: baseType === 'int',\n });\n }\n const bytesMatch = type.match(bytesRegex);\n if (bytesMatch) {\n const [_type, size] = bytesMatch;\n if (Number.parseInt(size, 10) !== (value.length - 2) / 2)\n throw new BytesSizeMismatchError({\n expectedSize: Number.parseInt(size, 10),\n givenSize: (value.length - 2) / 2,\n });\n return pad(value, { dir: 'right', size: isArray ? 32 : null });\n }\n const arrayMatch = type.match(arrayRegex);\n if (arrayMatch && Array.isArray(value)) {\n const [_type, childType] = arrayMatch;\n const data = [];\n for (let i = 0; i < value.length; i++) {\n data.push(encode(childType, value[i], true));\n }\n if (data.length === 0)\n return '0x';\n return concatHex(data);\n }\n throw new UnsupportedPackedAbiType(type);\n}\n//# sourceMappingURL=encodePacked.js.map","import { getTransactionCount } from '../actions/public/getTransactionCount.js';\nimport { LruMap } from './lru.js';\n/**\n * Creates a nonce manager for auto-incrementing transaction nonces.\n *\n * - Docs: https://viem.sh/docs/accounts/createNonceManager\n *\n * @example\n * ```ts\n * const nonceManager = createNonceManager({\n * source: jsonRpc(),\n * })\n * ```\n */\nexport function createNonceManager(parameters) {\n const { source } = parameters;\n const deltaMap = new Map();\n const nonceMap = new LruMap(8192);\n const promiseMap = new Map();\n const getKey = ({ address, chainId }) => `${address}.${chainId}`;\n return {\n async consume({ address, chainId, client }) {\n const key = getKey({ address, chainId });\n const promise = this.get({ address, chainId, client });\n this.increment({ address, chainId });\n const nonce = await promise;\n await source.set({ address, chainId }, nonce);\n nonceMap.set(key, nonce);\n return nonce;\n },\n async increment({ address, chainId }) {\n const key = getKey({ address, chainId });\n const delta = deltaMap.get(key) ?? 0;\n deltaMap.set(key, delta + 1);\n },\n async get({ address, chainId, client }) {\n const key = getKey({ address, chainId });\n let promise = promiseMap.get(key);\n if (!promise) {\n promise = (async () => {\n try {\n const nonce = await source.get({ address, chainId, client });\n const previousNonce = nonceMap.get(key) ?? 0;\n if (previousNonce > 0 && nonce <= previousNonce)\n return previousNonce + 1;\n nonceMap.delete(key);\n return nonce;\n }\n finally {\n this.reset({ address, chainId });\n }\n })();\n promiseMap.set(key, promise);\n }\n const delta = deltaMap.get(key) ?? 0;\n return delta + (await promise);\n },\n reset({ address, chainId }) {\n const key = getKey({ address, chainId });\n deltaMap.delete(key);\n promiseMap.delete(key);\n },\n };\n}\n/** JSON-RPC source for a nonce manager. */\nexport function jsonRpc() {\n return {\n async get(parameters) {\n const { address, client } = parameters;\n return getTransactionCount(client, {\n address,\n blockTag: 'pending',\n });\n },\n set() { },\n };\n}\n////////////////////////////////////////////////////////////////////////////////////////////\n// Default\n/** Default Nonce Manager with a JSON-RPC source. */\nexport const nonceManager = /*#__PURE__*/ createNonceManager({\n source: jsonRpc(),\n});\n//# sourceMappingURL=nonceManager.js.map","export const erc6492MagicBytes = '0x6492649264926492649264926492649264926492649264926492649264926492';\nexport const zeroHash = '0x0000000000000000000000000000000000000000000000000000000000000000';\n//# sourceMappingURL=bytes.js.map","import { erc6492MagicBytes } from '../../constants/bytes.js';\nimport { encodeAbiParameters } from '../abi/encodeAbiParameters.js';\nimport { concatHex } from '../data/concat.js';\nimport { hexToBytes } from '../encoding/toBytes.js';\n/**\n * @description Serializes a ERC-6492 flavoured signature into hex format.\n *\n * @param signature ERC-6492 signature in object format.\n * @returns ERC-6492 signature in hex format.\n *\n * @example\n * serializeSignature({ address: '0x...', data: '0x...', signature: '0x...' })\n * // '0x000000000000000000000000cafebabecafebabecafebabecafebabecafebabe000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000004deadbeef000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041a461f509887bd19e312c0c58467ce8ff8e300d3c1a90b608a760c5b80318eaf15fe57c96f9175d6cd4daad4663763baa7e78836e067d0163e9a2ccf2ff753f5b1b000000000000000000000000000000000000000000000000000000000000006492649264926492649264926492649264926492649264926492649264926492'\n */\nexport function serializeErc6492Signature(parameters) {\n const { address, data, signature, to = 'hex' } = parameters;\n const signature_ = concatHex([\n encodeAbiParameters([{ type: 'address' }, { type: 'bytes' }, { type: 'bytes' }], [address, data, signature]),\n erc6492MagicBytes,\n ]);\n if (to === 'hex')\n return signature_;\n return hexToBytes(signature_);\n}\n//# sourceMappingURL=serializeErc6492Signature.js.map","import { createClient, } from './createClient.js';\nimport { publicActions } from './decorators/public.js';\n/**\n * Creates a Public Client with a given [Transport](https://viem.sh/docs/clients/intro) configured for a [Chain](https://viem.sh/docs/clients/chains).\n *\n * - Docs: https://viem.sh/docs/clients/public\n *\n * A Public Client is an interface to \"public\" [JSON-RPC API](https://ethereum.org/en/developers/docs/apis/json-rpc/) methods such as retrieving block numbers, transactions, reading from smart contracts, etc through [Public Actions](/docs/actions/public/introduction).\n *\n * @param config - {@link PublicClientConfig}\n * @returns A Public Client. {@link PublicClient}\n *\n * @example\n * import { createPublicClient, http } from 'viem'\n * import { mainnet } from 'viem/chains'\n *\n * const client = createPublicClient({\n * chain: mainnet,\n * transport: http(),\n * })\n */\nexport function createPublicClient(parameters) {\n const { key = 'public', name = 'Public Client' } = parameters;\n const client = createClient({\n ...parameters,\n key,\n name,\n type: 'publicClient',\n });\n return client.extend(publicActions);\n}\n//# sourceMappingURL=createPublicClient.js.map","import { secp256k1 } from '@noble/curves/secp256k1';\nimport { numberToHex, } from '../../utils/encoding/toHex.js';\n/**\n * @description Parses a hex formatted signature into a structured signature.\n *\n * @param signatureHex Signature in hex format.\n * @returns The structured signature.\n *\n * @example\n * parseSignature('0x6e100a352ec6ad1b70802290e18aeed190704973570f3b8ed42cb9808e2ea6bf4a90a229a244495b41890987806fcbd2d5d23fc0dbe5f5256c2613c039d76db81c')\n * // { r: '0x...', s: '0x...', v: 28n }\n */\nexport function parseSignature(signatureHex) {\n const { r, s } = secp256k1.Signature.fromCompact(signatureHex.slice(2, 130));\n const yParityOrV = Number(`0x${signatureHex.slice(130)}`);\n const [v, yParity] = (() => {\n if (yParityOrV === 0 || yParityOrV === 1)\n return [undefined, yParityOrV];\n if (yParityOrV === 27)\n return [BigInt(yParityOrV), 0];\n if (yParityOrV === 28)\n return [BigInt(yParityOrV), 1];\n throw new Error('Invalid yParityOrV value');\n })();\n if (typeof v !== 'undefined')\n return {\n r: numberToHex(r, { size: 32 }),\n s: numberToHex(s, { size: 32 }),\n v,\n yParity,\n };\n return {\n r: numberToHex(r, { size: 32 }),\n s: numberToHex(s, { size: 32 }),\n yParity,\n };\n}\n//# sourceMappingURL=parseSignature.js.map","import { chainConfig } from '../../op-stack/chainConfig.js';\nimport { defineChain } from '../../utils/chain/defineChain.js';\nconst sourceId = 1; // mainnet\nexport const zora = /*#__PURE__*/ defineChain({\n ...chainConfig,\n id: 7777777,\n name: 'Zora',\n nativeCurrency: {\n decimals: 18,\n name: 'Ether',\n symbol: 'ETH',\n },\n rpcUrls: {\n default: {\n http: ['https://rpc.zora.energy'],\n webSocket: ['wss://rpc.zora.energy'],\n },\n },\n blockExplorers: {\n default: {\n name: 'Explorer',\n url: 'https://explorer.zora.energy',\n apiUrl: 'https://explorer.zora.energy/api',\n },\n },\n contracts: {\n ...chainConfig.contracts,\n disputeGameFactory: {\n [sourceId]: {\n address: '0xB0F15106fa1e473Ddb39790f197275BC979Aa37e',\n },\n },\n l2OutputOracle: {\n [sourceId]: {\n address: '0x9E6204F750cD866b299594e2aC9eA824E2e5f95c',\n },\n },\n multicall3: {\n address: '0xcA11bde05977b3631167028862bE2a173976CA11',\n blockCreated: 5882,\n },\n portal: {\n [sourceId]: {\n address: '0x1a0ad011913A150f69f6A19DF447A0CfD9551054',\n },\n },\n l1StandardBridge: {\n [sourceId]: {\n address: '0x3e2Ea9B92B7E48A52296fD261dc26fd995284631',\n },\n },\n },\n sourceId,\n});\n//# sourceMappingURL=zora.js.map","const reduxImpl = (reducer, initial) => (set, _get, api) => {\n api.dispatch = (action) => {\n set((state) => reducer(state, action), false, action);\n return action;\n };\n api.dispatchFromDevtools = true;\n return { dispatch: (...a) => api.dispatch(...a), ...initial };\n};\nconst redux = reduxImpl;\n\nconst trackedConnections = /* @__PURE__ */ new Map();\nconst getTrackedConnectionState = (name) => {\n const api = trackedConnections.get(name);\n if (!api) return {};\n return Object.fromEntries(\n Object.entries(api.stores).map(([key, api2]) => [key, api2.getState()])\n );\n};\nconst extractConnectionInformation = (store, extensionConnector, options) => {\n if (store === undefined) {\n return {\n type: \"untracked\",\n connection: extensionConnector.connect(options)\n };\n }\n const existingConnection = trackedConnections.get(options.name);\n if (existingConnection) {\n return { type: \"tracked\", store, ...existingConnection };\n }\n const newConnection = {\n connection: extensionConnector.connect(options),\n stores: {}\n };\n trackedConnections.set(options.name, newConnection);\n return { type: \"tracked\", store, ...newConnection };\n};\nconst devtoolsImpl = (fn, devtoolsOptions = {}) => (set, get, api) => {\n const { enabled, anonymousActionType, store, ...options } = devtoolsOptions;\n let extensionConnector;\n try {\n extensionConnector = (enabled != null ? enabled : (import.meta.env ? import.meta.env.MODE : void 0) !== \"production\") && window.__REDUX_DEVTOOLS_EXTENSION__;\n } catch (e) {\n }\n if (!extensionConnector) {\n return fn(set, get, api);\n }\n const { connection, ...connectionInformation } = extractConnectionInformation(store, extensionConnector, options);\n let isRecording = true;\n api.setState = (state, replace, nameOrAction) => {\n const r = set(state, replace);\n if (!isRecording) return r;\n const action = nameOrAction === undefined ? { type: anonymousActionType || \"anonymous\" } : typeof nameOrAction === \"string\" ? { type: nameOrAction } : nameOrAction;\n if (store === undefined) {\n connection == null ? undefined : connection.send(action, get());\n return r;\n }\n connection == null ? undefined : connection.send(\n {\n ...action,\n type: `${store}/${action.type}`\n },\n {\n ...getTrackedConnectionState(options.name),\n [store]: api.getState()\n }\n );\n return r;\n };\n const setStateFromDevtools = (...a) => {\n const originalIsRecording = isRecording;\n isRecording = false;\n set(...a);\n isRecording = originalIsRecording;\n };\n const initialState = fn(api.setState, get, api);\n if (connectionInformation.type === \"untracked\") {\n connection == null ? undefined : connection.init(initialState);\n } else {\n connectionInformation.stores[connectionInformation.store] = api;\n connection == null ? undefined : connection.init(\n Object.fromEntries(\n Object.entries(connectionInformation.stores).map(([key, store2]) => [\n key,\n key === connectionInformation.store ? initialState : store2.getState()\n ])\n )\n );\n }\n if (api.dispatchFromDevtools && typeof api.dispatch === \"function\") {\n let didWarnAboutReservedActionType = false;\n const originalDispatch = api.dispatch;\n api.dispatch = (...a) => {\n if ((import.meta.env ? import.meta.env.MODE : undefined) !== \"production\" && a[0].type === \"__setState\" && !didWarnAboutReservedActionType) {\n console.warn(\n '[zustand devtools middleware] \"__setState\" action type is reserved to set state from the devtools. Avoid using it.'\n );\n didWarnAboutReservedActionType = true;\n }\n originalDispatch(...a);\n };\n }\n connection.subscribe((message) => {\n var _a;\n switch (message.type) {\n case \"ACTION\":\n if (typeof message.payload !== \"string\") {\n console.error(\n \"[zustand devtools middleware] Unsupported action format\"\n );\n return;\n }\n return parseJsonThen(\n message.payload,\n (action) => {\n if (action.type === \"__setState\") {\n if (store === undefined) {\n setStateFromDevtools(action.state);\n return;\n }\n if (Object.keys(action.state).length !== 1) {\n console.error(\n `\n [zustand devtools middleware] Unsupported __setState action format.\n When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(),\n and value of this only key should be a state object. Example: { \"type\": \"__setState\", \"state\": { \"abc123Store\": { \"foo\": \"bar\" } } }\n `\n );\n }\n const stateFromDevtools = action.state[store];\n if (stateFromDevtools === undefined || stateFromDevtools === null) {\n return;\n }\n if (JSON.stringify(api.getState()) !== JSON.stringify(stateFromDevtools)) {\n setStateFromDevtools(stateFromDevtools);\n }\n return;\n }\n if (!api.dispatchFromDevtools) return;\n if (typeof api.dispatch !== \"function\") return;\n api.dispatch(action);\n }\n );\n case \"DISPATCH\":\n switch (message.payload.type) {\n case \"RESET\":\n setStateFromDevtools(initialState);\n if (store === undefined) {\n return connection == null ? undefined : connection.init(api.getState());\n }\n return connection == null ? undefined : connection.init(getTrackedConnectionState(options.name));\n case \"COMMIT\":\n if (store === undefined) {\n connection == null ? undefined : connection.init(api.getState());\n return;\n }\n return connection == null ? undefined : connection.init(getTrackedConnectionState(options.name));\n case \"ROLLBACK\":\n return parseJsonThen(message.state, (state) => {\n if (store === undefined) {\n setStateFromDevtools(state);\n connection == null ? undefined : connection.init(api.getState());\n return;\n }\n setStateFromDevtools(state[store]);\n connection == null ? undefined : connection.init(getTrackedConnectionState(options.name));\n });\n case \"JUMP_TO_STATE\":\n case \"JUMP_TO_ACTION\":\n return parseJsonThen(message.state, (state) => {\n if (store === undefined) {\n setStateFromDevtools(state);\n return;\n }\n if (JSON.stringify(api.getState()) !== JSON.stringify(state[store])) {\n setStateFromDevtools(state[store]);\n }\n });\n case \"IMPORT_STATE\": {\n const { nextLiftedState } = message.payload;\n const lastComputedState = (_a = nextLiftedState.computedStates.slice(-1)[0]) == null ? undefined : _a.state;\n if (!lastComputedState) return;\n if (store === undefined) {\n setStateFromDevtools(lastComputedState);\n } else {\n setStateFromDevtools(lastComputedState[store]);\n }\n connection == null ? undefined : connection.send(\n null,\n // FIXME no-any\n nextLiftedState\n );\n return;\n }\n case \"PAUSE_RECORDING\":\n return isRecording = !isRecording;\n }\n return;\n }\n });\n return initialState;\n};\nconst devtools = devtoolsImpl;\nconst parseJsonThen = (stringified, f) => {\n let parsed;\n try {\n parsed = JSON.parse(stringified);\n } catch (e) {\n console.error(\n \"[zustand devtools middleware] Could not parse the received json\",\n e\n );\n }\n if (parsed !== undefined) f(parsed);\n};\n\nconst subscribeWithSelectorImpl = (fn) => (set, get, api) => {\n const origSubscribe = api.subscribe;\n api.subscribe = (selector, optListener, options) => {\n let listener = selector;\n if (optListener) {\n const equalityFn = (options == null ? undefined : options.equalityFn) || Object.is;\n let currentSlice = selector(api.getState());\n listener = (state) => {\n const nextSlice = selector(state);\n if (!equalityFn(currentSlice, nextSlice)) {\n const previousSlice = currentSlice;\n optListener(currentSlice = nextSlice, previousSlice);\n }\n };\n if (options == null ? undefined : options.fireImmediately) {\n optListener(currentSlice, currentSlice);\n }\n }\n return origSubscribe(listener);\n };\n const initialState = fn(set, get, api);\n return initialState;\n};\nconst subscribeWithSelector = subscribeWithSelectorImpl;\n\nconst combine = (initialState, create) => (...a) => Object.assign({}, initialState, create(...a));\n\nfunction createJSONStorage(getStorage, options) {\n let storage;\n try {\n storage = getStorage();\n } catch (e) {\n return;\n }\n const persistStorage = {\n getItem: (name) => {\n var _a;\n const parse = (str2) => {\n if (str2 === null) {\n return null;\n }\n return JSON.parse(str2, options == null ? undefined : options.reviver);\n };\n const str = (_a = storage.getItem(name)) != null ? _a : null;\n if (str instanceof Promise) {\n return str.then(parse);\n }\n return parse(str);\n },\n setItem: (name, newValue) => storage.setItem(\n name,\n JSON.stringify(newValue, options == null ? undefined : options.replacer)\n ),\n removeItem: (name) => storage.removeItem(name)\n };\n return persistStorage;\n}\nconst toThenable = (fn) => (input) => {\n try {\n const result = fn(input);\n if (result instanceof Promise) {\n return result;\n }\n return {\n then(onFulfilled) {\n return toThenable(onFulfilled)(result);\n },\n catch(_onRejected) {\n return this;\n }\n };\n } catch (e) {\n return {\n then(_onFulfilled) {\n return this;\n },\n catch(onRejected) {\n return toThenable(onRejected)(e);\n }\n };\n }\n};\nconst persistImpl = (config, baseOptions) => (set, get, api) => {\n let options = {\n storage: createJSONStorage(() => localStorage),\n partialize: (state) => state,\n version: 0,\n merge: (persistedState, currentState) => ({\n ...currentState,\n ...persistedState\n }),\n ...baseOptions\n };\n let hasHydrated = false;\n const hydrationListeners = /* @__PURE__ */ new Set();\n const finishHydrationListeners = /* @__PURE__ */ new Set();\n let storage = options.storage;\n if (!storage) {\n return config(\n (...args) => {\n console.warn(\n `[zustand persist middleware] Unable to update item '${options.name}', the given storage is currently unavailable.`\n );\n set(...args);\n },\n get,\n api\n );\n }\n const setItem = () => {\n const state = options.partialize({ ...get() });\n return storage.setItem(options.name, {\n state,\n version: options.version\n });\n };\n const savedSetState = api.setState;\n api.setState = (state, replace) => {\n savedSetState(state, replace);\n void setItem();\n };\n const configResult = config(\n (...args) => {\n set(...args);\n void setItem();\n },\n get,\n api\n );\n api.getInitialState = () => configResult;\n let stateFromStorage;\n const hydrate = () => {\n var _a, _b;\n if (!storage) return;\n hasHydrated = false;\n hydrationListeners.forEach((cb) => {\n var _a2;\n return cb((_a2 = get()) != null ? _a2 : configResult);\n });\n const postRehydrationCallback = ((_b = options.onRehydrateStorage) == null ? undefined : _b.call(options, (_a = get()) != null ? _a : configResult)) || undefined;\n return toThenable(storage.getItem.bind(storage))(options.name).then((deserializedStorageValue) => {\n if (deserializedStorageValue) {\n if (typeof deserializedStorageValue.version === \"number\" && deserializedStorageValue.version !== options.version) {\n if (options.migrate) {\n const migration = options.migrate(\n deserializedStorageValue.state,\n deserializedStorageValue.version\n );\n if (migration instanceof Promise) {\n return migration.then((result) => [true, result]);\n }\n return [true, migration];\n }\n console.error(\n `State loaded from storage couldn't be migrated since no migrate function was provided`\n );\n } else {\n return [false, deserializedStorageValue.state];\n }\n }\n return [false, undefined];\n }).then((migrationResult) => {\n var _a2;\n const [migrated, migratedState] = migrationResult;\n stateFromStorage = options.merge(\n migratedState,\n (_a2 = get()) != null ? _a2 : configResult\n );\n set(stateFromStorage, true);\n if (migrated) {\n return setItem();\n }\n }).then(() => {\n postRehydrationCallback == null ? undefined : postRehydrationCallback(stateFromStorage, undefined);\n stateFromStorage = get();\n hasHydrated = true;\n finishHydrationListeners.forEach((cb) => cb(stateFromStorage));\n }).catch((e) => {\n postRehydrationCallback == null ? undefined : postRehydrationCallback(undefined, e);\n });\n };\n api.persist = {\n setOptions: (newOptions) => {\n options = {\n ...options,\n ...newOptions\n };\n if (newOptions.storage) {\n storage = newOptions.storage;\n }\n },\n clearStorage: () => {\n storage == null ? undefined : storage.removeItem(options.name);\n },\n getOptions: () => options,\n rehydrate: () => hydrate(),\n hasHydrated: () => hasHydrated,\n onHydrate: (cb) => {\n hydrationListeners.add(cb);\n return () => {\n hydrationListeners.delete(cb);\n };\n },\n onFinishHydration: (cb) => {\n finishHydrationListeners.add(cb);\n return () => {\n finishHydrationListeners.delete(cb);\n };\n }\n };\n if (!options.skipHydration) {\n hydrate();\n }\n return stateFromStorage || configResult;\n};\nconst persist = persistImpl;\n\nexport { combine, createJSONStorage, devtools, persist, redux, subscribeWithSelector };\n","const createStoreImpl = (createState) => {\n let state;\n const listeners = /* @__PURE__ */ new Set();\n const setState = (partial, replace) => {\n const nextState = typeof partial === \"function\" ? partial(state) : partial;\n if (!Object.is(nextState, state)) {\n const previousState = state;\n state = (replace != null ? replace : typeof nextState !== \"object\" || nextState === null) ? nextState : Object.assign({}, state, nextState);\n listeners.forEach((listener) => listener(state, previousState));\n }\n };\n const getState = () => state;\n const getInitialState = () => initialState;\n const subscribe = (listener) => {\n listeners.add(listener);\n return () => listeners.delete(listener);\n };\n const api = { setState, getState, getInitialState, subscribe };\n const initialState = state = createState(setState, getState, api);\n return api;\n};\nconst createStore = (createState) => createState ? createStoreImpl(createState) : createStoreImpl;\n\nexport { createStore };\n","import pkg from '../../package.json' with { type: 'json' };\nexport const CB_KEYS_URL = 'https://keys.coinbase.com/connect';\nexport const CB_WALLET_RPC_URL = 'https://rpc.wallet.coinbase.com';\nexport const PACKAGE_NAME = pkg.name;\nexport const PACKAGE_VERSION = pkg.version;\n//# sourceMappingURL=constants.js.map","import { PACKAGE_VERSION } from '../core/constants.js';\nimport { createJSONStorage, persist } from 'zustand/middleware';\nimport { createStore } from 'zustand/vanilla';\nconst createChainSlice = () => {\n return {\n chains: [],\n };\n};\nconst createKeysSlice = () => {\n return {\n keys: {},\n };\n};\nconst createAccountSlice = () => {\n return {\n account: {},\n };\n};\nconst createSubAccountSlice = () => {\n return {\n subAccount: undefined,\n };\n};\nconst createSubAccountConfigSlice = () => {\n return {\n subAccountConfig: {},\n };\n};\nconst createSpendPermissionsSlice = () => {\n return {\n spendPermissions: [],\n };\n};\nconst createConfigSlice = () => {\n return {\n config: {\n version: PACKAGE_VERSION,\n },\n };\n};\nexport const sdkstore = createStore(persist((...args) => ({\n ...createChainSlice(...args),\n ...createKeysSlice(...args),\n ...createAccountSlice(...args),\n ...createSubAccountSlice(...args),\n ...createSpendPermissionsSlice(...args),\n ...createConfigSlice(...args),\n ...createSubAccountConfigSlice(...args),\n}), {\n name: 'base-acc-sdk.store',\n storage: createJSONStorage(() => localStorage),\n partialize: (state) => {\n // Explicitly select only the data properties we want to persist\n // (not the methods)\n return {\n chains: state.chains,\n keys: state.keys,\n account: state.account,\n subAccount: state.subAccount,\n spendPermissions: state.spendPermissions,\n config: state.config,\n };\n },\n}));\n// Non-persisted subaccount configuration\nexport const subAccountsConfig = {\n get: () => sdkstore.getState().subAccountConfig,\n set: (subAccountConfig) => {\n sdkstore.setState((state) => ({\n subAccountConfig: { ...state.subAccountConfig, ...subAccountConfig },\n }));\n },\n clear: () => {\n sdkstore.setState({\n subAccountConfig: {},\n });\n },\n};\nexport const subAccounts = {\n get: () => sdkstore.getState().subAccount,\n set: (subAccount) => {\n sdkstore.setState((state) => ({\n subAccount: state.subAccount\n ? { ...state.subAccount, ...subAccount }\n : { address: subAccount.address, ...subAccount },\n }));\n },\n clear: () => {\n sdkstore.setState({\n subAccount: undefined,\n });\n },\n};\nexport const spendPermissions = {\n get: () => sdkstore.getState().spendPermissions,\n set: (spendPermissions) => {\n sdkstore.setState({ spendPermissions });\n },\n clear: () => {\n sdkstore.setState({\n spendPermissions: [],\n });\n },\n};\nexport const account = {\n get: () => sdkstore.getState().account,\n set: (account) => {\n sdkstore.setState((state) => ({\n account: { ...state.account, ...account },\n }));\n },\n clear: () => {\n sdkstore.setState({\n account: {},\n });\n },\n};\nexport const chains = {\n get: () => sdkstore.getState().chains,\n set: (chains) => {\n sdkstore.setState({ chains });\n },\n clear: () => {\n sdkstore.setState({\n chains: [],\n });\n },\n};\nexport const keys = {\n get: (key) => sdkstore.getState().keys[key],\n set: (key, value) => {\n sdkstore.setState((state) => ({ keys: { ...state.keys, [key]: value } }));\n },\n clear: () => {\n sdkstore.setState({\n keys: {},\n });\n },\n};\nexport const config = {\n get: () => sdkstore.getState().config,\n set: (config) => {\n sdkstore.setState((state) => ({ config: { ...state.config, ...config } }));\n },\n};\nconst actions = {\n subAccounts,\n subAccountsConfig,\n spendPermissions,\n account,\n chains,\n keys,\n config,\n};\nexport const store = {\n ...sdkstore,\n ...actions,\n};\n//# sourceMappingURL=store.js.map","// This file is auto-generated by compile-assets.cjs\n// Do not edit manually - changes will be overwritten\nexport const TELEMETRY_SCRIPT_CONTENT = `!function(e,t){\"object\"==typeof exports&&\"object\"==typeof module?module.exports=t():\"function\"==typeof define&&define.amd?define([],t):\"object\"==typeof exports?exports.ClientAnalytics=t():e.ClientAnalytics=t()}(this,(function(){return(()=>{var e={792:e=>{var t={utf8:{stringToBytes:function(e){return t.bin.stringToBytes(unescape(encodeURIComponent(e)))},bytesToString:function(e){return decodeURIComponent(escape(t.bin.bytesToString(e)))}},bin:{stringToBytes:function(e){for(var t=[],n=0;n<e.length;n++)t.push(255&e.charCodeAt(n));return t},bytesToString:function(e){for(var t=[],n=0;n<e.length;n++)t.push(String.fromCharCode(e[n]));return t.join(\"\")}}};e.exports=t},562:e=>{var t,n;t=\"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\",n={rotl:function(e,t){return e<<t|e>>>32-t},rotr:function(e,t){return e<<32-t|e>>>t},endian:function(e){if(e.constructor==Number)return 16711935&n.rotl(e,8)|4278255360&n.rotl(e,24);for(var t=0;t<e.length;t++)e[t]=n.endian(e[t]);return e},randomBytes:function(e){for(var t=[];e>0;e--)t.push(Math.floor(256*Math.random()));return t},bytesToWords:function(e){for(var t=[],n=0,r=0;n<e.length;n++,r+=8)t[r>>>5]|=e[n]<<24-r%32;return t},wordsToBytes:function(e){for(var t=[],n=0;n<32*e.length;n+=8)t.push(e[n>>>5]>>>24-n%32&255);return t},bytesToHex:function(e){for(var t=[],n=0;n<e.length;n++)t.push((e[n]>>>4).toString(16)),t.push((15&e[n]).toString(16));return t.join(\"\")},hexToBytes:function(e){for(var t=[],n=0;n<e.length;n+=2)t.push(parseInt(e.substr(n,2),16));return t},bytesToBase64:function(e){for(var n=[],r=0;r<e.length;r+=3)for(var i=e[r]<<16|e[r+1]<<8|e[r+2],a=0;a<4;a++)8*r+6*a<=8*e.length?n.push(t.charAt(i>>>6*(3-a)&63)):n.push(\"=\");return n.join(\"\")},base64ToBytes:function(e){e=e.replace(/[^A-Z0-9+\\\\/]/gi,\"\");for(var n=[],r=0,i=0;r<e.length;i=++r%4)0!=i&&n.push((t.indexOf(e.charAt(r-1))&Math.pow(2,-2*i+8)-1)<<2*i|t.indexOf(e.charAt(r))>>>6-2*i);return n}},e.exports=n},335:e=>{function t(e){return!!e.constructor&&\"function\"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}e.exports=function(e){return null!=e&&(t(e)||function(e){return\"function\"==typeof e.readFloatLE&&\"function\"==typeof e.slice&&t(e.slice(0,0))}(e)||!!e._isBuffer)}},762:(e,t,n)=>{var r,i,a,o,s;r=n(562),i=n(792).utf8,a=n(335),o=n(792).bin,(s=function(e,t){e.constructor==String?e=t&&\"binary\"===t.encoding?o.stringToBytes(e):i.stringToBytes(e):a(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var n=r.bytesToWords(e),c=8*e.length,u=1732584193,l=-271733879,d=-1732584194,p=271733878,m=0;m<n.length;m++)n[m]=16711935&(n[m]<<8|n[m]>>>24)|4278255360&(n[m]<<24|n[m]>>>8);n[c>>>5]|=128<<c%32,n[14+(c+64>>>9<<4)]=c;var f=s._ff,v=s._gg,g=s._hh,b=s._ii;for(m=0;m<n.length;m+=16){var h=u,w=l,y=d,T=p;u=f(u,l,d,p,n[m+0],7,-680876936),p=f(p,u,l,d,n[m+1],12,-389564586),d=f(d,p,u,l,n[m+2],17,606105819),l=f(l,d,p,u,n[m+3],22,-1044525330),u=f(u,l,d,p,n[m+4],7,-176418897),p=f(p,u,l,d,n[m+5],12,1200080426),d=f(d,p,u,l,n[m+6],17,-1473231341),l=f(l,d,p,u,n[m+7],22,-45705983),u=f(u,l,d,p,n[m+8],7,1770035416),p=f(p,u,l,d,n[m+9],12,-1958414417),d=f(d,p,u,l,n[m+10],17,-42063),l=f(l,d,p,u,n[m+11],22,-1990404162),u=f(u,l,d,p,n[m+12],7,1804603682),p=f(p,u,l,d,n[m+13],12,-40341101),d=f(d,p,u,l,n[m+14],17,-1502002290),u=v(u,l=f(l,d,p,u,n[m+15],22,1236535329),d,p,n[m+1],5,-165796510),p=v(p,u,l,d,n[m+6],9,-1069501632),d=v(d,p,u,l,n[m+11],14,643717713),l=v(l,d,p,u,n[m+0],20,-373897302),u=v(u,l,d,p,n[m+5],5,-701558691),p=v(p,u,l,d,n[m+10],9,38016083),d=v(d,p,u,l,n[m+15],14,-660478335),l=v(l,d,p,u,n[m+4],20,-405537848),u=v(u,l,d,p,n[m+9],5,568446438),p=v(p,u,l,d,n[m+14],9,-1019803690),d=v(d,p,u,l,n[m+3],14,-187363961),l=v(l,d,p,u,n[m+8],20,1163531501),u=v(u,l,d,p,n[m+13],5,-1444681467),p=v(p,u,l,d,n[m+2],9,-51403784),d=v(d,p,u,l,n[m+7],14,1735328473),u=g(u,l=v(l,d,p,u,n[m+12],20,-1926607734),d,p,n[m+5],4,-378558),p=g(p,u,l,d,n[m+8],11,-2022574463),d=g(d,p,u,l,n[m+11],16,1839030562),l=g(l,d,p,u,n[m+14],23,-35309556),u=g(u,l,d,p,n[m+1],4,-1530992060),p=g(p,u,l,d,n[m+4],11,1272893353),d=g(d,p,u,l,n[m+7],16,-155497632),l=g(l,d,p,u,n[m+10],23,-1094730640),u=g(u,l,d,p,n[m+13],4,681279174),p=g(p,u,l,d,n[m+0],11,-358537222),d=g(d,p,u,l,n[m+3],16,-722521979),l=g(l,d,p,u,n[m+6],23,76029189),u=g(u,l,d,p,n[m+9],4,-640364487),p=g(p,u,l,d,n[m+12],11,-421815835),d=g(d,p,u,l,n[m+15],16,530742520),u=b(u,l=g(l,d,p,u,n[m+2],23,-995338651),d,p,n[m+0],6,-198630844),p=b(p,u,l,d,n[m+7],10,1126891415),d=b(d,p,u,l,n[m+14],15,-1416354905),l=b(l,d,p,u,n[m+5],21,-57434055),u=b(u,l,d,p,n[m+12],6,1700485571),p=b(p,u,l,d,n[m+3],10,-1894986606),d=b(d,p,u,l,n[m+10],15,-1051523),l=b(l,d,p,u,n[m+1],21,-2054922799),u=b(u,l,d,p,n[m+8],6,1873313359),p=b(p,u,l,d,n[m+15],10,-30611744),d=b(d,p,u,l,n[m+6],15,-1560198380),l=b(l,d,p,u,n[m+13],21,1309151649),u=b(u,l,d,p,n[m+4],6,-145523070),p=b(p,u,l,d,n[m+11],10,-1120210379),d=b(d,p,u,l,n[m+2],15,718787259),l=b(l,d,p,u,n[m+9],21,-343485551),u=u+h>>>0,l=l+w>>>0,d=d+y>>>0,p=p+T>>>0}return r.endian([u,l,d,p])})._ff=function(e,t,n,r,i,a,o){var s=e+(t&n|~t&r)+(i>>>0)+o;return(s<<a|s>>>32-a)+t},s._gg=function(e,t,n,r,i,a,o){var s=e+(t&r|n&~r)+(i>>>0)+o;return(s<<a|s>>>32-a)+t},s._hh=function(e,t,n,r,i,a,o){var s=e+(t^n^r)+(i>>>0)+o;return(s<<a|s>>>32-a)+t},s._ii=function(e,t,n,r,i,a,o){var s=e+(n^(t|~r))+(i>>>0)+o;return(s<<a|s>>>32-a)+t},s._blocksize=16,s._digestsize=16,e.exports=function(e,t){if(null==e)throw new Error(\"Illegal argument \"+e);var n=r.wordsToBytes(s(e,t));return t&&t.asBytes?n:t&&t.asString?o.bytesToString(n):r.bytesToHex(n)}},2:(e,t,n)=>{\"use strict\";n.r(t),n.d(t,{Perfume:()=>ze,incrementUjNavigation:()=>Le,markStep:()=>Re,markStepOnce:()=>qe});var r,i,a={isResourceTiming:!1,isElementTiming:!1,maxTime:3e4,reportOptions:{},enableNavigationTracking:!0},o=window,s=o.console,c=o.navigator,u=o.performance,l=function(){return c.deviceMemory},d=function(){return c.hardwareConcurrency},p=\"mark.\",m=function(){return u&&!!u.getEntriesByType&&!!u.now&&!!u.mark},f=\"4g\",v=!1,g={},b={value:0},h={value:{beacon:0,css:0,fetch:0,img:0,other:0,script:0,total:0,xmlhttprequest:0}},w={value:0},y={value:0},T={},k={isHidden:!1,didChange:!1},_=function(){k.isHidden=!1,document.hidden&&(k.isHidden=document.hidden,k.didChange=!0)},S=function(e,t){try{var n=new PerformanceObserver((function(e){t(e.getEntries())}));return n.observe({type:e,buffered:!0}),n}catch(e){s.warn(\"Perfume.js:\",e)}return null},E=function(){return!!(d()&&d()<=4)||!!(l()&&l()<=4)},x=function(e,t){switch(e){case\"slow-2g\":case\"2g\":case\"3g\":return!0;default:return E()||t}},O=function(e){return parseFloat(e.toFixed(4))},j=function(e){return\"number\"!=typeof e?null:O(e/Math.pow(1024,2))},N=function(e,t,n,r,i){var s,u=function(){a.analyticsTracker&&(k.isHidden&&![\"CLS\",\"INP\"].includes(e)||a.analyticsTracker({attribution:r,metricName:e,data:t,navigatorInformation:c?{deviceMemory:l()||0,hardwareConcurrency:d()||0,serviceWorkerStatus:\"serviceWorker\"in c?c.serviceWorker.controller?\"controlled\":\"supported\":\"unsupported\",isLowEndDevice:E(),isLowEndExperience:x(f,v)}:{},rating:n,navigationType:i}))};[\"CLS\",\"INP\"].includes(e)?u():(s=u,\"requestIdleCallback\"in o?o.requestIdleCallback(s,{timeout:3e3}):s())},I=function(e){e.forEach((function(e){if(!(\"self\"!==e.name||e.startTime<b.value)){var t=e.duration-50;t>0&&(w.value+=t,y.value+=t)}}))};!function(e){e.instant=\"instant\",e.quick=\"quick\",e.moderate=\"moderate\",e.slow=\"slow\",e.unavoidable=\"unavoidable\"}(r||(r={}));var P,M,B,C,D,A=((i={})[r.instant]={vitalsThresholds:[100,200],maxOutlierThreshold:1e4},i[r.quick]={vitalsThresholds:[200,500],maxOutlierThreshold:1e4},i[r.moderate]={vitalsThresholds:[500,1e3],maxOutlierThreshold:1e4},i[r.slow]={vitalsThresholds:[1e3,2e3],maxOutlierThreshold:1e4},i[r.unavoidable]={vitalsThresholds:[2e3,5e3],maxOutlierThreshold:2e4},i),L={RT:[100,200],TBT:[200,600],NTBT:[200,600]},U=function(e,t){return L[e]?t<=L[e][0]?\"good\":t<=L[e][1]?\"needsImprovement\":\"poor\":null},R=function(e,t,n){Object.keys(t).forEach((function(e){\"number\"==typeof t[e]&&(t[e]=O(t[e]))})),N(e,t,null,n||{})},q=function(e){var t=e.attribution,n=e.name,r=e.rating,i=e.value,o=e.navigationType;\"FCP\"===n&&(b.value=i),[\"FCP\",\"LCP\"].includes(n)&&!T[0]&&(T[0]=S(\"longtask\",I)),\"FID\"===n&&setTimeout((function(){k.didChange||(q({attribution:t,name:\"TBT\",rating:U(\"TBT\",w.value),value:w.value,navigationType:o}),R(\"dataConsumption\",h.value))}),1e4);var s=O(i);s<=a.maxTime&&s>=0&&N(n,s,r,t,o)},F=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType(\"navigation\")[0]},z=function(e){if(\"loading\"===document.readyState)return\"loading\";var t=F();if(t){if(e<t.domInteractive)return\"loading\";if(0===t.domContentLoadedEventStart||e<t.domContentLoadedEventStart)return\"dom-interactive\";if(0===t.domComplete||e<t.domComplete)return\"dom-content-loaded\"}return\"complete\"},K=function(e){var t=e.nodeName;return 1===e.nodeType?t.toLowerCase():t.toUpperCase().replace(/^#/,\"\")},$=function(e,t){var n=\"\";try{for(;e&&9!==e.nodeType;){var r=e,i=r.id?\"#\"+r.id:K(r)+(r.className&&r.className.length?\".\"+r.className.replace(/\\\\s+/g,\".\"):\"\");if(n.length+i.length>(t||100)-1)return n||i;if(n=n?i+\">\"+n:i,r.id)break;e=r.parentNode}}catch(e){}return n},Q=-1,W=function(){return Q},H=function(e){addEventListener(\"pageshow\",(function(t){t.persisted&&(Q=t.timeStamp,e(t))}),!0)},V=function(){var e=F();return e&&e.activationStart||0},J=function(e,t){var n=F(),r=\"navigate\";return W()>=0?r=\"back-forward-cache\":n&&(r=document.prerendering||V()>0?\"prerender\":document.wasDiscarded?\"restore\":n.type.replace(/_/g,\"-\")),{name:e,value:void 0===t?-1:t,rating:\"good\",delta:0,entries:[],id:\"v3-\".concat(Date.now(),\"-\").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},X=function(e,t,n){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){t(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch(e){}},G=function(e,t){var n=function n(r){\"pagehide\"!==r.type&&\"hidden\"!==document.visibilityState||(e(r),t&&(removeEventListener(\"visibilitychange\",n,!0),removeEventListener(\"pagehide\",n,!0)))};addEventListener(\"visibilitychange\",n,!0),addEventListener(\"pagehide\",n,!0)},Z=function(e,t,n,r){var i,a;return function(o){t.value>=0&&(o||r)&&((a=t.value-(i||0))||void 0===i)&&(i=t.value,t.delta=a,t.rating=function(e,t){return e>t[1]?\"poor\":e>t[0]?\"needs-improvement\":\"good\"}(t.value,n),e(t))}},Y=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},ee=function(e){document.prerendering?addEventListener(\"prerenderingchange\",(function(){return e()}),!0):e()},te=-1,ne=function(){return\"hidden\"!==document.visibilityState||document.prerendering?1/0:0},re=function(e){\"hidden\"===document.visibilityState&&te>-1&&(te=\"visibilitychange\"===e.type?e.timeStamp:0,ae())},ie=function(){addEventListener(\"visibilitychange\",re,!0),addEventListener(\"prerenderingchange\",re,!0)},ae=function(){removeEventListener(\"visibilitychange\",re,!0),removeEventListener(\"prerenderingchange\",re,!0)},oe=function(){return te<0&&(te=ne(),ie(),H((function(){setTimeout((function(){te=ne(),ie()}),0)}))),{get firstHiddenTime(){return te}}},se=function(e,t){t=t||{},ee((function(){var n,r=[1800,3e3],i=oe(),a=J(\"FCP\"),o=X(\"paint\",(function(e){e.forEach((function(e){\"first-contentful-paint\"===e.name&&(o.disconnect(),e.startTime<i.firstHiddenTime&&(a.value=Math.max(e.startTime-V(),0),a.entries.push(e),n(!0)))}))}));o&&(n=Z(e,a,r,t.reportAllChanges),H((function(i){a=J(\"FCP\"),n=Z(e,a,r,t.reportAllChanges),Y((function(){a.value=performance.now()-i.timeStamp,n(!0)}))})))}))},ce={passive:!0,capture:!0},ue=new Date,le=function(e,t){P||(P=t,M=e,B=new Date,me(removeEventListener),de())},de=function(){if(M>=0&&M<B-ue){var e={entryType:\"first-input\",name:P.type,target:P.target,cancelable:P.cancelable,startTime:P.timeStamp,processingStart:P.timeStamp+M};C.forEach((function(t){t(e)})),C=[]}},pe=function(e){if(e.cancelable){var t=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;\"pointerdown\"==e.type?function(e,t){var n=function(){le(e,t),i()},r=function(){i()},i=function(){removeEventListener(\"pointerup\",n,ce),removeEventListener(\"pointercancel\",r,ce)};addEventListener(\"pointerup\",n,ce),addEventListener(\"pointercancel\",r,ce)}(t,e):le(t,e)}},me=function(e){[\"mousedown\",\"keydown\",\"touchstart\",\"pointerdown\"].forEach((function(t){return e(t,pe,ce)}))},fe=0,ve=1/0,ge=0,be=function(e){e.forEach((function(e){e.interactionId&&(ve=Math.min(ve,e.interactionId),ge=Math.max(ge,e.interactionId),fe=ge?(ge-ve)/7+1:0)}))},he=function(){return D?fe:performance.interactionCount||0},we=0,ye=function(){return he()-we},Te=[],ke={},_e=function(e){var t=Te[Te.length-1],n=ke[e.interactionId];if(n||Te.length<10||e.duration>t.latency){if(n)n.entries.push(e),n.latency=Math.max(n.latency,e.duration);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};ke[r.id]=r,Te.push(r)}Te.sort((function(e,t){return t.latency-e.latency})),Te.splice(10).forEach((function(e){delete ke[e.id]}))}},Se={},Ee=function e(t){document.prerendering?ee((function(){return e(t)})):\"complete\"!==document.readyState?addEventListener(\"load\",(function(){return e(t)}),!0):setTimeout(t,0)},xe=function(e,t){t=t||{};var n=[800,1800],r=J(\"TTFB\"),i=Z(e,r,n,t.reportAllChanges);Ee((function(){var a=F();if(a){var o=a.responseStart;if(o<=0||o>performance.now())return;r.value=Math.max(o-V(),0),r.entries=[a],i(!0),H((function(){r=J(\"TTFB\",0),(i=Z(e,r,n,t.reportAllChanges))(!0)}))}}))},Oe=function(e){e.forEach((function(e){e.identifier&&q({attribution:{identifier:e.identifier},name:\"ET\",rating:null,value:e.startTime})}))},je=function(e){e.forEach((function(e){if(a.isResourceTiming&&R(\"resourceTiming\",e),e.decodedBodySize&&e.initiatorType){var t=e.decodedBodySize/1e3;h.value[e.initiatorType]+=t,h.value.total+=t}}))},Ne=function(){!function(e,t){xe((function(e){!function(e){if(e.entries.length){var t=e.entries[0],n=t.activationStart||0,r=Math.max(t.domainLookupStart-n,0),i=Math.max(t.connectStart-n,0),a=Math.max(t.requestStart-n,0);e.attribution={waitingTime:r,dnsTime:i-r,connectionTime:a-i,requestTime:e.value-a,navigationEntry:t}}else e.attribution={waitingTime:0,dnsTime:0,connectionTime:0,requestTime:0}}(e),function(e){e.value>0&&q(e)}(e)}),t)}(0,a.reportOptions.ttfb),function(e,t){!function(e,t){t=t||{},ee((function(){var e,n=[.1,.25],r=J(\"CLS\"),i=-1,a=0,o=[],s=function(e){i>-1&&function(e){!function(e){if(e.entries.length){var t=e.entries.reduce((function(e,t){return e&&e.value>t.value?e:t}));if(t&&t.sources&&t.sources.length){var n=(r=t.sources).find((function(e){return e.node&&1===e.node.nodeType}))||r[0];if(n)return void(e.attribution={largestShiftTarget:$(n.node),largestShiftTime:t.startTime,largestShiftValue:t.value,largestShiftSource:n,largestShiftEntry:t,loadState:z(t.startTime)})}}var r;e.attribution={}}(e),function(e){q(e)}(e)}(e)},c=function(t){t.forEach((function(t){if(!t.hadRecentInput){var n=o[0],i=o[o.length-1];a&&t.startTime-i.startTime<1e3&&t.startTime-n.startTime<5e3?(a+=t.value,o.push(t)):(a=t.value,o=[t]),a>r.value&&(r.value=a,r.entries=o,e())}}))},u=X(\"layout-shift\",c);u&&(e=Z(s,r,n,t.reportAllChanges),se((function(t){i=t.value,r.value<0&&(r.value=0,e())})),G((function(){c(u.takeRecords()),e(!0)})),H((function(){a=0,i=-1,r=J(\"CLS\",0),e=Z(s,r,n,t.reportAllChanges),Y((function(){return e()}))})))}))}(0,t)}(0,a.reportOptions.cls),function(e,t){se((function(e){!function(e){if(e.entries.length){var t=F(),n=e.entries[e.entries.length-1];if(t){var r=t.activationStart||0,i=Math.max(0,t.responseStart-r);return void(e.attribution={timeToFirstByte:i,firstByteToFCP:e.value-i,loadState:z(e.entries[0].startTime),navigationEntry:t,fcpEntry:n})}}e.attribution={timeToFirstByte:0,firstByteToFCP:e.value,loadState:z(W())}}(e),function(e){q(e)}(e)}),t)}(0,a.reportOptions.fcp),function(e,t){!function(e,t){t=t||{},ee((function(){var n,r=[100,300],i=oe(),a=J(\"FID\"),o=function(e){e.startTime<i.firstHiddenTime&&(a.value=e.processingStart-e.startTime,a.entries.push(e),n(!0))},s=function(e){e.forEach(o)},c=X(\"first-input\",s);n=Z(e,a,r,t.reportAllChanges),c&&G((function(){s(c.takeRecords()),c.disconnect()}),!0),c&&H((function(){var i;a=J(\"FID\"),n=Z(e,a,r,t.reportAllChanges),C=[],M=-1,P=null,me(addEventListener),i=o,C.push(i),de()}))}))}((function(e){!function(e){var t=e.entries[0];e.attribution={eventTarget:$(t.target),eventType:t.name,eventTime:t.startTime,eventEntry:t,loadState:z(t.startTime)}}(e),function(e){q(e)}(e)}),t)}(0,a.reportOptions.fid),function(e,t){!function(e,t){t=t||{},ee((function(){var n,r=[2500,4e3],i=oe(),a=J(\"LCP\"),o=function(e){var t=e[e.length-1];if(t){var r=Math.max(t.startTime-V(),0);r<i.firstHiddenTime&&(a.value=r,a.entries=[t],n())}},s=X(\"largest-contentful-paint\",o);if(s){n=Z(e,a,r,t.reportAllChanges);var c=function(){Se[a.id]||(o(s.takeRecords()),s.disconnect(),Se[a.id]=!0,n(!0))};[\"keydown\",\"click\"].forEach((function(e){addEventListener(e,c,{once:!0,capture:!0})})),G(c,!0),H((function(i){a=J(\"LCP\"),n=Z(e,a,r,t.reportAllChanges),Y((function(){a.value=performance.now()-i.timeStamp,Se[a.id]=!0,n(!0)}))}))}}))}((function(e){!function(e){if(e.entries.length){var t=F();if(t){var n=t.activationStart||0,r=e.entries[e.entries.length-1],i=r.url&&performance.getEntriesByType(\"resource\").filter((function(e){return e.name===r.url}))[0],a=Math.max(0,t.responseStart-n),o=Math.max(a,i?(i.requestStart||i.startTime)-n:0),s=Math.max(o,i?i.responseEnd-n:0),c=Math.max(s,r?r.startTime-n:0),u={element:$(r.element),timeToFirstByte:a,resourceLoadDelay:o-a,resourceLoadTime:s-o,elementRenderDelay:c-s,navigationEntry:t,lcpEntry:r};return r.url&&(u.url=r.url),i&&(u.lcpResourceEntry=i),void(e.attribution=u)}}e.attribution={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadTime:0,elementRenderDelay:e.value}}(e),function(e){q(e)}(e)}),t)}(0,a.reportOptions.lcp),function(e,t){!function(e,t){t=t||{},ee((function(){var n=[200,500];\"interactionCount\"in performance||D||(D=X(\"event\",be,{type:\"event\",buffered:!0,durationThreshold:0}));var r,i=J(\"INP\"),a=function(e){e.forEach((function(e){e.interactionId&&_e(e),\"first-input\"===e.entryType&&!Te.some((function(t){return t.entries.some((function(t){return e.duration===t.duration&&e.startTime===t.startTime}))}))&&_e(e)}));var t,n=(t=Math.min(Te.length-1,Math.floor(ye()/50)),Te[t]);n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())},o=X(\"event\",a,{durationThreshold:t.durationThreshold||40});r=Z(e,i,n,t.reportAllChanges),o&&(o.observe({type:\"first-input\",buffered:!0}),G((function(){a(o.takeRecords()),i.value<0&&ye()>0&&(i.value=0,i.entries=[]),r(!0)})),H((function(){Te=[],we=he(),i=J(\"INP\"),r=Z(e,i,n,t.reportAllChanges)})))}))}((function(t){!function(e){if(e.entries.length){var t=e.entries.sort((function(e,t){return t.duration-e.duration||t.processingEnd-t.processingStart-(e.processingEnd-e.processingStart)}))[0];e.attribution={eventTarget:$(t.target),eventType:t.name,eventTime:t.startTime,eventEntry:t,loadState:z(t.startTime)}}else e.attribution={}}(t),e(t)}),t)}((function(e){return q(e)}),a.reportOptions.inp),a.isResourceTiming&&S(\"resource\",je),a.isElementTiming&&S(\"element\",Oe)},Ie=function(e){var t=\"usageDetails\"in e?e.usageDetails:{};R(\"storageEstimate\",{quota:j(e.quota),usage:j(e.usage),caches:j(t.caches),indexedDB:j(t.indexedDB),serviceWorker:j(t.serviceWorkerRegistrations)})},Pe={finalMarkToStepsMap:{},startMarkToStepsMap:{},active:{},navigationSteps:{}},Me=function(e){delete Pe.active[e]},Be=function(){return Pe.navigationSteps},Ce=function(e){var t;return null!==(t=Be()[e])&&void 0!==t?t:{}},De=function(e,t,n){var r=\"step.\"+e,i=u.getEntriesByName(p+t).length>0;if(u.getEntriesByName(p+n).length>0&&a.steps){var o=A[a.steps[e].threshold],s=o.maxOutlierThreshold,c=o.vitalsThresholds;if(i){var l=u.measure(r,p+t,p+n),d=l.duration;if(d<=s){var m=function(e,t){return e<=t[0]?\"good\":e<=t[1]?\"needsImprovement\":\"poor\"}(d,c);d>=0&&(N(\"userJourneyStep\",d,m,{stepName:e},void 0),u.measure(\"step.\".concat(e,\"_vitals_\").concat(m),{start:l.startTime+l.duration,end:l.startTime+l.duration,detail:{type:\"stepVital\",duration:d}}))}}}},Ae=function(){var e=Be(),t=Pe.startMarkToStepsMap,n=Object.keys(e).length;if(0===n)return{};var r={},i=n-1,a=Ce(i);if(Object.keys(a).forEach((function(e){var n,i=null!==(n=t[e])&&void 0!==n?n:[];Object.keys(i).forEach((function(e){r[e]=!0}))})),n>1){var o=Ce(i-1);Object.keys(o).forEach((function(e){var n,i=null!==(n=t[e])&&void 0!==n?n:[];Object.keys(i).forEach((function(e){r[e]=!0}))}))}return r},Le=function(){var e,t=Object.keys(Pe.navigationSteps).length;Pe.navigationSteps[t]={};var n=Ae();null===(e=a.onMarkStep)||void 0===e||e.call(a,\"\",Object.keys(n))},Ue=function(e){var t,n,r,i,o,s,c;if(Pe.finalMarkToStepsMap[e]){!function(e){var t=Pe.navigationSteps,n=Pe.finalMarkToStepsMap,r=Object.keys(t).length;if(0!==r){var i=r-1,a=Ce(i);if(a&&n[e]){var o=n[e];o&&Object.keys(o).forEach((function(e){if(a[e]){var n=Ce(i)||{};n[e]=!1,t[i]=n}if(r>1){var o=i-1,s=Ce(o);s[e]&&(s[e]=!1,t[o]=s)}}))}}}(e);var u=Pe.finalMarkToStepsMap[e];Object.keys(u).forEach((function(t){var n=u[t];n.forEach(Me),Promise.all(n.map((function(n){return function(e,t,n,r){return new(n||(n=Promise))((function(e,t){function i(e){try{o(r.next(e))}catch(e){t(e)}}function a(e){try{o(r.throw(e))}catch(e){t(e)}}function o(t){var r;t.done?e(t.value):(r=t.value,r instanceof n?r:new n((function(e){e(r)}))).then(i,a)}o((r=r.apply(undefined,[])).next())}))}(0,0,void 0,(function(){return function(e,t){var n,r,i,a,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return a={next:s(0),throw:s(1),return:s(2)},\"function\"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(a){return function(s){return function(a){if(n)throw new TypeError(\"Generator is already executing.\");for(;o;)try{if(n=1,r&&(i=2&a[0]?r.return:a[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,a[1])).done)return i;switch(r=0,i&&(a=[2&a[0],i.value]),a[0]){case 0:case 1:i=a;break;case 4:return o.label++,{value:a[1],done:!1};case 5:o.label++,r=a[1],a=[0];continue;case 7:a=o.ops.pop(),o.trys.pop();continue;default:if(!((i=(i=o.trys).length>0&&i[i.length-1])||6!==a[0]&&2!==a[0])){o=0;continue}if(3===a[0]&&(!i||a[1]>i[0]&&a[1]<i[3])){o.label=a[1];break}if(6===a[0]&&o.label<i[1]){o.label=i[1],i=a;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(a);break}i[2]&&o.ops.pop(),o.trys.pop();continue}a=t.call(e,o)}catch(e){a=[6,e],r=0}finally{n=i=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,s])}}}(this,(function(r){switch(r.label){case 0:return[4,De(n,t,e)];case 1:return r.sent(),[2]}}))}))}))).catch((function(){}))}))}else r=e,i=Pe.navigationSteps,o=Object.keys(i).length,(c=Ce(s=(o>0?o:1)-1)||[])[r]=!0,i[s]=c,function(e){var t,n=null!==(t=Pe.startMarkToStepsMap[e])&&void 0!==t?t:[];Object.keys(n).forEach((function(e){Pe.active[e]||(Pe.active[e]=!0)}))}(e);if(a.enableNavigationTracking){var l=Ae();null===(t=a.onMarkStep)||void 0===t||t.call(a,e,Object.keys(l))}else null===(n=a.onMarkStep)||void 0===n||n.call(a,e,Object.keys(Pe.active))},Re=function(e){u.mark(p+e),Ue(e)},qe=function(e){0===u.getEntriesByName(p+e).length&&(u.mark(p+e),Ue(e))},Fe=0,ze=function(){function e(e){if(void 0===e&&(e={}),this.v=\"9.0.0-rc.3\",a.analyticsTracker=e.analyticsTracker,a.isResourceTiming=!!e.resourceTiming,a.isElementTiming=!!e.elementTiming,a.maxTime=e.maxMeasureTime||a.maxTime,a.reportOptions=e.reportOptions||a.reportOptions,a.steps=e.steps,a.onMarkStep=e.onMarkStep,a.enableNavigationTracking=e.enableNavigationTracking,m()){\"PerformanceObserver\"in o&&Ne(),void 0!==document.hidden&&document.addEventListener(\"visibilitychange\",_);var t=function(){if(!m())return{};var e=u.getEntriesByType(\"navigation\")[0];if(!e)return{};var t=e.responseStart,n=e.responseEnd;return{fetchTime:n-e.fetchStart,workerTime:e.workerStart>0?n-e.workerStart:0,totalTime:n-e.requestStart,downloadTime:n-t,timeToFirstByte:t-e.requestStart,headerSize:e.transferSize-e.encodedBodySize||0,dnsLookupTime:e.domainLookupEnd-e.domainLookupStart,redirectTime:e.redirectEnd-e.redirectStart}}();R(\"navigationTiming\",t),t.redirectTime&&q({attribution:{},name:\"RT\",rating:U(\"RT\",t.redirectTime),value:t.redirectTime}),R(\"networkInformation\",function(){if(\"connection\"in c){var e=c.connection;return\"object\"!=typeof e?{}:(f=e.effectiveType,v=!!e.saveData,{downlink:e.downlink,effectiveType:e.effectiveType,rtt:e.rtt,saveData:!!e.saveData})}return{}}()),c&&c.storage&&\"function\"==typeof c.storage.estimate&&c.storage.estimate().then(Ie),a.steps&&a.steps&&(Pe.startMarkToStepsMap={},Pe.finalMarkToStepsMap={},Pe.active={},Pe.navigationSteps={},Object.entries(a.steps).forEach((function(e){var t,n,r=e[0],i=e[1].marks,a=i[0],o=i[1],s=null!==(n=Pe.startMarkToStepsMap[a])&&void 0!==n?n:{};if(s[r]=!0,Pe.startMarkToStepsMap[a]=s,Pe.finalMarkToStepsMap[o]){var c=Pe.finalMarkToStepsMap[o][a]||[];c.push(r),Pe.finalMarkToStepsMap[o][a]=c}else Pe.finalMarkToStepsMap[o]=((t={})[a]=[r],t)})))}}return e.prototype.start=function(e){m()&&!g[e]&&(g[e]=!0,u.mark(\"mark_\".concat(e,\"_start\")))},e.prototype.end=function(e,t,n){if(void 0===t&&(t={}),void 0===n&&(n=!0),m()&&g[e]){u.mark(\"mark_\".concat(e,\"_end\")),delete g[e];var r=function(e){u.measure(e,\"mark_\".concat(e,\"_start\"),\"mark_\".concat(e,\"_end\"));var t=u.getEntriesByName(e).pop();return t&&\"measure\"===t.entryType?t.duration:-1}(e);n&&R(e,O(r),t)}},e.prototype.endPaint=function(e,t){var n=this;setTimeout((function(){n.end(e,t)}))},e.prototype.clear=function(e){delete g[e],u.clearMarks&&(u.clearMarks(\"mark_\".concat(e,\"_start\")),u.clearMarks(\"mark_\".concat(e,\"_end\")))},e.prototype.markNTBT=function(){var e=this;this.start(\"ntbt\"),y.value=0,clearTimeout(Fe),Fe=setTimeout((function(){e.end(\"ntbt\",{},!1),q({attribution:{},name:\"NTBT\",rating:U(\"NTBT\",y.value),value:y.value}),y.value=0}),2e3)},e}()},426:(e,t)=>{\"use strict\";Symbol.for(\"react.element\"),Symbol.for(\"react.portal\"),Symbol.for(\"react.fragment\"),Symbol.for(\"react.strict_mode\"),Symbol.for(\"react.profiler\"),Symbol.for(\"react.provider\"),Symbol.for(\"react.context\"),Symbol.for(\"react.forward_ref\"),Symbol.for(\"react.suspense\"),Symbol.for(\"react.memo\"),Symbol.for(\"react.lazy\"),Symbol.iterator;var n={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},r=Object.assign,i={};function a(e,t,r){this.props=e,this.context=t,this.refs=i,this.updater=r||n}function o(){}function s(e,t,r){this.props=e,this.context=t,this.refs=i,this.updater=r||n}a.prototype.isReactComponent={},a.prototype.setState=function(e,t){if(\"object\"!=typeof e&&\"function\"!=typeof e&&null!=e)throw Error(\"setState(...): takes an object of state variables to update or a function which returns an object of state variables.\");this.updater.enqueueSetState(this,e,t,\"setState\")},a.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,\"forceUpdate\")},o.prototype=a.prototype;var c=s.prototype=new o;c.constructor=s,r(c,a.prototype),c.isPureReactComponent=!0;Array.isArray,Object.prototype.hasOwnProperty;var u={current:null};t.useCallback=function(e,t){return u.current.useCallback(e,t)},t.useEffect=function(e,t){return u.current.useEffect(e,t)},t.useRef=function(e){return u.current.useRef(e)}},784:(e,t,n)=>{\"use strict\";e.exports=n(426)},353:function(e,t,n){var r;!function(i,a){\"use strict\";var o=\"function\",s=\"undefined\",c=\"object\",u=\"string\",l=\"major\",d=\"model\",p=\"name\",m=\"type\",f=\"vendor\",v=\"version\",g=\"architecture\",b=\"console\",h=\"mobile\",w=\"tablet\",y=\"smarttv\",T=\"wearable\",k=\"embedded\",_=\"Amazon\",S=\"Apple\",E=\"ASUS\",x=\"BlackBerry\",O=\"Browser\",j=\"Chrome\",N=\"Firefox\",I=\"Google\",P=\"Huawei\",M=\"LG\",B=\"Microsoft\",C=\"Motorola\",D=\"Opera\",A=\"Samsung\",L=\"Sharp\",U=\"Sony\",R=\"Xiaomi\",q=\"Zebra\",F=\"Facebook\",z=\"Chromium OS\",K=\"Mac OS\",$=function(e){for(var t={},n=0;n<e.length;n++)t[e[n].toUpperCase()]=e[n];return t},Q=function(e,t){return typeof e===u&&-1!==W(t).indexOf(W(e))},W=function(e){return e.toLowerCase()},H=function(e,t){if(typeof e===u)return e=e.replace(/^\\\\s\\\\s*/,\"\"),typeof t===s?e:e.substring(0,350)},V=function(e,t){for(var n,r,i,s,u,l,d=0;d<t.length&&!u;){var p=t[d],m=t[d+1];for(n=r=0;n<p.length&&!u&&p[n];)if(u=p[n++].exec(e))for(i=0;i<m.length;i++)l=u[++r],typeof(s=m[i])===c&&s.length>0?2===s.length?typeof s[1]==o?this[s[0]]=s[1].call(this,l):this[s[0]]=s[1]:3===s.length?typeof s[1]!==o||s[1].exec&&s[1].test?this[s[0]]=l?l.replace(s[1],s[2]):a:this[s[0]]=l?s[1].call(this,l,s[2]):a:4===s.length&&(this[s[0]]=l?s[3].call(this,l.replace(s[1],s[2])):a):this[s]=l||a;d+=2}},J=function(e,t){for(var n in t)if(typeof t[n]===c&&t[n].length>0){for(var r=0;r<t[n].length;r++)if(Q(t[n][r],e))return\"?\"===n?a:n}else if(Q(t[n],e))return\"?\"===n?a:n;return e},X={ME:\"4.90\",\"NT 3.11\":\"NT3.51\",\"NT 4.0\":\"NT4.0\",2e3:\"NT 5.0\",XP:[\"NT 5.1\",\"NT 5.2\"],Vista:\"NT 6.0\",7:\"NT 6.1\",8:\"NT 6.2\",8.1:\"NT 6.3\",10:[\"NT 6.4\",\"NT 10.0\"],RT:\"ARM\"},G={browser:[[/\\\\b(?:crmo|crios)\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"Chrome\"]],[/edg(?:e|ios|a)?\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"Edge\"]],[/(opera mini)\\\\/([-\\\\w\\\\.]+)/i,/(opera [mobiletab]{3,6})\\\\b.+version\\\\/([-\\\\w\\\\.]+)/i,/(opera)(?:.+version\\\\/|[\\\\/ ]+)([\\\\w\\\\.]+)/i],[p,v],[/opios[\\\\/ ]+([\\\\w\\\\.]+)/i],[v,[p,D+\" Mini\"]],[/\\\\bopr\\\\/([\\\\w\\\\.]+)/i],[v,[p,D]],[/(kindle)\\\\/([\\\\w\\\\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\\\\/ ]?([\\\\w\\\\.]*)/i,/(avant |iemobile|slim)(?:browser)?[\\\\/ ]?([\\\\w\\\\.]*)/i,/(ba?idubrowser)[\\\\/ ]?([\\\\w\\\\.]+)/i,/(?:ms|\\\\()(ie) ([\\\\w\\\\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\\\\/([-\\\\w\\\\.]+)/i,/(heytap|ovi)browser\\\\/([\\\\d\\\\.]+)/i,/(weibo)__([\\\\d\\\\.]+)/i],[p,v],[/(?:\\\\buc? ?browser|(?:juc.+)ucweb)[\\\\/ ]?([\\\\w\\\\.]+)/i],[v,[p,\"UC\"+O]],[/microm.+\\\\bqbcore\\\\/([\\\\w\\\\.]+)/i,/\\\\bqbcore\\\\/([\\\\w\\\\.]+).+microm/i],[v,[p,\"WeChat(Win) Desktop\"]],[/micromessenger\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"WeChat\"]],[/konqueror\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"Konqueror\"]],[/trident.+rv[: ]([\\\\w\\\\.]{1,9})\\\\b.+like gecko/i],[v,[p,\"IE\"]],[/ya(?:search)?browser\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"Yandex\"]],[/(avast|avg)\\\\/([\\\\w\\\\.]+)/i],[[p,/(.+)/,\"$1 Secure \"+O],v],[/\\\\bfocus\\\\/([\\\\w\\\\.]+)/i],[v,[p,N+\" Focus\"]],[/\\\\bopt\\\\/([\\\\w\\\\.]+)/i],[v,[p,D+\" Touch\"]],[/coc_coc\\\\w+\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"Coc Coc\"]],[/dolfin\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"Dolphin\"]],[/coast\\\\/([\\\\w\\\\.]+)/i],[v,[p,D+\" Coast\"]],[/miuibrowser\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"MIUI \"+O]],[/fxios\\\\/([-\\\\w\\\\.]+)/i],[v,[p,N]],[/\\\\bqihu|(qi?ho?o?|360)browser/i],[[p,\"360 \"+O]],[/(oculus|samsung|sailfish|huawei)browser\\\\/([\\\\w\\\\.]+)/i],[[p,/(.+)/,\"$1 \"+O],v],[/(comodo_dragon)\\\\/([\\\\w\\\\.]+)/i],[[p,/_/g,\" \"],v],[/(electron)\\\\/([\\\\w\\\\.]+) safari/i,/(tesla)(?: qtcarbrowser|\\\\/(20\\\\d\\\\d\\\\.[-\\\\w\\\\.]+))/i,/m?(qqbrowser|baiduboxapp|2345Explorer)[\\\\/ ]?([\\\\w\\\\.]+)/i],[p,v],[/(metasr)[\\\\/ ]?([\\\\w\\\\.]+)/i,/(lbbrowser)/i,/\\\\[(linkedin)app\\\\]/i],[p],[/((?:fban\\\\/fbios|fb_iab\\\\/fb4a)(?!.+fbav)|;fbav\\\\/([\\\\w\\\\.]+);)/i],[[p,F],v],[/(kakao(?:talk|story))[\\\\/ ]([\\\\w\\\\.]+)/i,/(naver)\\\\(.*?(\\\\d+\\\\.[\\\\w\\\\.]+).*\\\\)/i,/safari (line)\\\\/([\\\\w\\\\.]+)/i,/\\\\b(line)\\\\/([\\\\w\\\\.]+)\\\\/iab/i,/(chromium|instagram)[\\\\/ ]([-\\\\w\\\\.]+)/i],[p,v],[/\\\\bgsa\\\\/([\\\\w\\\\.]+) .*safari\\\\//i],[v,[p,\"GSA\"]],[/musical_ly(?:.+app_?version\\\\/|_)([\\\\w\\\\.]+)/i],[v,[p,\"TikTok\"]],[/headlesschrome(?:\\\\/([\\\\w\\\\.]+)| )/i],[v,[p,j+\" Headless\"]],[/ wv\\\\).+(chrome)\\\\/([\\\\w\\\\.]+)/i],[[p,j+\" WebView\"],v],[/droid.+ version\\\\/([\\\\w\\\\.]+)\\\\b.+(?:mobile safari|safari)/i],[v,[p,\"Android \"+O]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\\\\/v?([\\\\w\\\\.]+)/i],[p,v],[/version\\\\/([\\\\w\\\\.\\\\,]+) .*mobile\\\\/\\\\w+ (safari)/i],[v,[p,\"Mobile Safari\"]],[/version\\\\/([\\\\w(\\\\.|\\\\,)]+) .*(mobile ?safari|safari)/i],[v,p],[/webkit.+?(mobile ?safari|safari)(\\\\/[\\\\w\\\\.]+)/i],[p,[v,J,{\"1.0\":\"/8\",1.2:\"/1\",1.3:\"/3\",\"2.0\":\"/412\",\"2.0.2\":\"/416\",\"2.0.3\":\"/417\",\"2.0.4\":\"/419\",\"?\":\"/\"}]],[/(webkit|khtml)\\\\/([\\\\w\\\\.]+)/i],[p,v],[/(navigator|netscape\\\\d?)\\\\/([-\\\\w\\\\.]+)/i],[[p,\"Netscape\"],v],[/mobile vr; rv:([\\\\w\\\\.]+)\\\\).+firefox/i],[v,[p,N+\" Reality\"]],[/ekiohf.+(flow)\\\\/([\\\\w\\\\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\\\\/ ]?([\\\\w\\\\.\\\\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\\\\/([-\\\\w\\\\.]+)$/i,/(firefox)\\\\/([\\\\w\\\\.]+)/i,/(mozilla)\\\\/([\\\\w\\\\.]+) .+rv\\\\:.+gecko\\\\/\\\\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\\\\. ]?browser)[-\\\\/ ]?v?([\\\\w\\\\.]+)/i,/(links) \\\\(([\\\\w\\\\.]+)/i,/panasonic;(viera)/i],[p,v],[/(cobalt)\\\\/([\\\\w\\\\.]+)/i],[p,[v,/master.|lts./,\"\"]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\\\\)]/i],[[g,\"amd64\"]],[/(ia32(?=;))/i],[[g,W]],[/((?:i[346]|x)86)[;\\\\)]/i],[[g,\"ia32\"]],[/\\\\b(aarch64|arm(v?8e?l?|_?64))\\\\b/i],[[g,\"arm64\"]],[/\\\\b(arm(?:v[67])?ht?n?[fl]p?)\\\\b/i],[[g,\"armhf\"]],[/windows (ce|mobile); ppc;/i],[[g,\"arm\"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\\\\))/i],[[g,/ower/,\"\",W]],[/(sun4\\\\w)[;\\\\)]/i],[[g,\"sparc\"]],[/((?:avr32|ia64(?=;))|68k(?=\\\\))|\\\\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\\\\b|pa-risc)/i],[[g,W]]],device:[[/\\\\b(sch-i[89]0\\\\d|shw-m380s|sm-[ptx]\\\\w{2,4}|gt-[pn]\\\\d{2,4}|sgh-t8[56]9|nexus 10)/i],[d,[f,A],[m,w]],[/\\\\b((?:s[cgp]h|gt|sm)-\\\\w+|sc[g-]?[\\\\d]+a?|galaxy nexus)/i,/samsung[- ]([-\\\\w]+)/i,/sec-(sgh\\\\w+)/i],[d,[f,A],[m,h]],[/(?:\\\\/|\\\\()(ip(?:hone|od)[\\\\w, ]*)(?:\\\\/|;)/i],[d,[f,S],[m,h]],[/\\\\((ipad);[-\\\\w\\\\),; ]+apple/i,/applecoremedia\\\\/[\\\\w\\\\.]+ \\\\((ipad)/i,/\\\\b(ipad)\\\\d\\\\d?,\\\\d\\\\d?[;\\\\]].+ios/i],[d,[f,S],[m,w]],[/(macintosh);/i],[d,[f,S]],[/\\\\b(sh-?[altvz]?\\\\d\\\\d[a-ekm]?)/i],[d,[f,L],[m,h]],[/\\\\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\\\\d{2})\\\\b(?!.+d\\\\/s)/i],[d,[f,P],[m,w]],[/(?:huawei|honor)([-\\\\w ]+)[;\\\\)]/i,/\\\\b(nexus 6p|\\\\w{2,4}e?-[atu]?[ln][\\\\dx][012359c][adn]?)\\\\b(?!.+d\\\\/s)/i],[d,[f,P],[m,h]],[/\\\\b(poco[\\\\w ]+)(?: bui|\\\\))/i,/\\\\b; (\\\\w+) build\\\\/hm\\\\1/i,/\\\\b(hm[-_ ]?note?[_ ]?(?:\\\\d\\\\w)?) bui/i,/\\\\b(redmi[\\\\-_ ]?(?:note|k)?[\\\\w_ ]+)(?: bui|\\\\))/i,/\\\\b(mi[-_ ]?(?:a\\\\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\\\\d?\\\\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\\\\))/i],[[d,/_/g,\" \"],[f,R],[m,h]],[/\\\\b(mi[-_ ]?(?:pad)(?:[\\\\w_ ]+))(?: bui|\\\\))/i],[[d,/_/g,\" \"],[f,R],[m,w]],[/; (\\\\w+) bui.+ oppo/i,/\\\\b(cph[12]\\\\d{3}|p(?:af|c[al]|d\\\\w|e[ar])[mt]\\\\d0|x9007|a101op)\\\\b/i],[d,[f,\"OPPO\"],[m,h]],[/vivo (\\\\w+)(?: bui|\\\\))/i,/\\\\b(v[12]\\\\d{3}\\\\w?[at])(?: bui|;)/i],[d,[f,\"Vivo\"],[m,h]],[/\\\\b(rmx[12]\\\\d{3})(?: bui|;|\\\\))/i],[d,[f,\"Realme\"],[m,h]],[/\\\\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\\\\b[\\\\w ]+build\\\\//i,/\\\\bmot(?:orola)?[- ](\\\\w*)/i,/((?:moto[\\\\w\\\\(\\\\) ]+|xt\\\\d{3,4}|nexus 6)(?= bui|\\\\)))/i],[d,[f,C],[m,h]],[/\\\\b(mz60\\\\d|xoom[2 ]{0,2}) build\\\\//i],[d,[f,C],[m,w]],[/((?=lg)?[vl]k\\\\-?\\\\d{3}) bui| 3\\\\.[-\\\\w; ]{10}lg?-([06cv9]{3,4})/i],[d,[f,M],[m,w]],[/(lm(?:-?f100[nv]?|-[\\\\w\\\\.]+)(?= bui|\\\\))|nexus [45])/i,/\\\\blg[-e;\\\\/ ]+((?!browser|netcast|android tv)\\\\w+)/i,/\\\\blg-?([\\\\d\\\\w]+) bui/i],[d,[f,M],[m,h]],[/(ideatab[-\\\\w ]+)/i,/lenovo ?(s[56]000[-\\\\w]+|tab(?:[\\\\w ]+)|yt[-\\\\d\\\\w]{6}|tb[-\\\\d\\\\w]{6})/i],[d,[f,\"Lenovo\"],[m,w]],[/(?:maemo|nokia).*(n900|lumia \\\\d+)/i,/nokia[-_ ]?([-\\\\w\\\\.]*)/i],[[d,/_/g,\" \"],[f,\"Nokia\"],[m,h]],[/(pixel c)\\\\b/i],[d,[f,I],[m,w]],[/droid.+; (pixel[\\\\daxl ]{0,6})(?: bui|\\\\))/i],[d,[f,I],[m,h]],[/droid.+ (a?\\\\d[0-2]{2}so|[c-g]\\\\d{4}|so[-gl]\\\\w+|xq-a\\\\w[4-7][12])(?= bui|\\\\).+chrome\\\\/(?![1-6]{0,1}\\\\d\\\\.))/i],[d,[f,U],[m,h]],[/sony tablet [ps]/i,/\\\\b(?:sony)?sgp\\\\w+(?: bui|\\\\))/i],[[d,\"Xperia Tablet\"],[f,U],[m,w]],[/ (kb2005|in20[12]5|be20[12][59])\\\\b/i,/(?:one)?(?:plus)? (a\\\\d0\\\\d\\\\d)(?: b|\\\\))/i],[d,[f,\"OnePlus\"],[m,h]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\\\\))/i,/(kf[a-z]+)( bui|\\\\)).+silk\\\\//i],[d,[f,_],[m,w]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\\\\)).+silk\\\\//i],[[d,/(.+)/g,\"Fire Phone $1\"],[f,_],[m,h]],[/(playbook);[-\\\\w\\\\),; ]+(rim)/i],[d,f,[m,w]],[/\\\\b((?:bb[a-f]|st[hv])100-\\\\d)/i,/\\\\(bb10; (\\\\w+)/i],[d,[f,x],[m,h]],[/(?:\\\\b|asus_)(transfo[prime ]{4,10} \\\\w+|eeepc|slider \\\\w+|nexus 7|padfone|p00[cj])/i],[d,[f,E],[m,w]],[/ (z[bes]6[027][012][km][ls]|zenfone \\\\d\\\\w?)\\\\b/i],[d,[f,E],[m,h]],[/(nexus 9)/i],[d,[f,\"HTC\"],[m,w]],[/(htc)[-;_ ]{1,2}([\\\\w ]+(?=\\\\)| bui)|\\\\w+)/i,/(zte)[- ]([\\\\w ]+?)(?: bui|\\\\/|\\\\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\\\\.))|sony(?!-bra))[-_ ]?([-\\\\w]*)/i],[f,[d,/_/g,\" \"],[m,h]],[/droid.+; ([ab][1-7]-?[0178a]\\\\d\\\\d?)/i],[d,[f,\"Acer\"],[m,w]],[/droid.+; (m[1-5] note) bui/i,/\\\\bmz-([-\\\\w]{2,})/i],[d,[f,\"Meizu\"],[m,h]],[/(blackberry|benq|palm(?=\\\\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron)[-_ ]?([-\\\\w]*)/i,/(hp) ([\\\\w ]+\\\\w)/i,/(asus)-?(\\\\w+)/i,/(microsoft); (lumia[\\\\w ]+)/i,/(lenovo)[-_ ]?([-\\\\w]+)/i,/(jolla)/i,/(oppo) ?([\\\\w ]+) bui/i],[f,d,[m,h]],[/(kobo)\\\\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\\\\/([\\\\w\\\\.]+)/i,/(nook)[\\\\w ]+build\\\\/(\\\\w+)/i,/(dell) (strea[kpr\\\\d ]*[\\\\dko])/i,/(le[- ]+pan)[- ]+(\\\\w{1,9}) bui/i,/(trinity)[- ]*(t\\\\d{3}) bui/i,/(gigaset)[- ]+(q\\\\w{1,9}) bui/i,/(vodafone) ([\\\\w ]+)(?:\\\\)| bui)/i],[f,d,[m,w]],[/(surface duo)/i],[d,[f,B],[m,w]],[/droid [\\\\d\\\\.]+; (fp\\\\du?)(?: b|\\\\))/i],[d,[f,\"Fairphone\"],[m,h]],[/(u304aa)/i],[d,[f,\"AT&T\"],[m,h]],[/\\\\bsie-(\\\\w*)/i],[d,[f,\"Siemens\"],[m,h]],[/\\\\b(rct\\\\w+) b/i],[d,[f,\"RCA\"],[m,w]],[/\\\\b(venue[\\\\d ]{2,7}) b/i],[d,[f,\"Dell\"],[m,w]],[/\\\\b(q(?:mv|ta)\\\\w+) b/i],[d,[f,\"Verizon\"],[m,w]],[/\\\\b(?:barnes[& ]+noble |bn[rt])([\\\\w\\\\+ ]*) b/i],[d,[f,\"Barnes & Noble\"],[m,w]],[/\\\\b(tm\\\\d{3}\\\\w+) b/i],[d,[f,\"NuVision\"],[m,w]],[/\\\\b(k88) b/i],[d,[f,\"ZTE\"],[m,w]],[/\\\\b(nx\\\\d{3}j) b/i],[d,[f,\"ZTE\"],[m,h]],[/\\\\b(gen\\\\d{3}) b.+49h/i],[d,[f,\"Swiss\"],[m,h]],[/\\\\b(zur\\\\d{3}) b/i],[d,[f,\"Swiss\"],[m,w]],[/\\\\b((zeki)?tb.*\\\\b) b/i],[d,[f,\"Zeki\"],[m,w]],[/\\\\b([yr]\\\\d{2}) b/i,/\\\\b(dragon[- ]+touch |dt)(\\\\w{5}) b/i],[[f,\"Dragon Touch\"],d,[m,w]],[/\\\\b(ns-?\\\\w{0,9}) b/i],[d,[f,\"Insignia\"],[m,w]],[/\\\\b((nxa|next)-?\\\\w{0,9}) b/i],[d,[f,\"NextBook\"],[m,w]],[/\\\\b(xtreme\\\\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[f,\"Voice\"],d,[m,h]],[/\\\\b(lvtel\\\\-)?(v1[12]) b/i],[[f,\"LvTel\"],d,[m,h]],[/\\\\b(ph-1) /i],[d,[f,\"Essential\"],[m,h]],[/\\\\b(v(100md|700na|7011|917g).*\\\\b) b/i],[d,[f,\"Envizen\"],[m,w]],[/\\\\b(trio[-\\\\w\\\\. ]+) b/i],[d,[f,\"MachSpeed\"],[m,w]],[/\\\\btu_(1491) b/i],[d,[f,\"Rotor\"],[m,w]],[/(shield[\\\\w ]+) b/i],[d,[f,\"Nvidia\"],[m,w]],[/(sprint) (\\\\w+)/i],[f,d,[m,h]],[/(kin\\\\.[onetw]{3})/i],[[d,/\\\\./g,\" \"],[f,B],[m,h]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\\\\)/i],[d,[f,q],[m,w]],[/droid.+; (ec30|ps20|tc[2-8]\\\\d[kx])\\\\)/i],[d,[f,q],[m,h]],[/smart-tv.+(samsung)/i],[f,[m,y]],[/hbbtv.+maple;(\\\\d+)/i],[[d,/^/,\"SmartTV\"],[f,A],[m,y]],[/(nux; netcast.+smarttv|lg (netcast\\\\.tv-201\\\\d|android tv))/i],[[f,M],[m,y]],[/(apple) ?tv/i],[f,[d,S+\" TV\"],[m,y]],[/crkey/i],[[d,j+\"cast\"],[f,I],[m,y]],[/droid.+aft(\\\\w)( bui|\\\\))/i],[d,[f,_],[m,y]],[/\\\\(dtv[\\\\);].+(aquos)/i,/(aquos-tv[\\\\w ]+)\\\\)/i],[d,[f,L],[m,y]],[/(bravia[\\\\w ]+)( bui|\\\\))/i],[d,[f,U],[m,y]],[/(mitv-\\\\w{5}) bui/i],[d,[f,R],[m,y]],[/Hbbtv.*(technisat) (.*);/i],[f,d,[m,y]],[/\\\\b(roku)[\\\\dx]*[\\\\)\\\\/]((?:dvp-)?[\\\\d\\\\.]*)/i,/hbbtv\\\\/\\\\d+\\\\.\\\\d+\\\\.\\\\d+ +\\\\([\\\\w\\\\+ ]*; *([\\\\w\\\\d][^;]*);([^;]*)/i],[[f,H],[d,H],[m,y]],[/\\\\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\\\\b/i],[[m,y]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[f,d,[m,b]],[/droid.+; (shield) bui/i],[d,[f,\"Nvidia\"],[m,b]],[/(playstation [345portablevi]+)/i],[d,[f,U],[m,b]],[/\\\\b(xbox(?: one)?(?!; xbox))[\\\\); ]/i],[d,[f,B],[m,b]],[/((pebble))app/i],[f,d,[m,T]],[/(watch)(?: ?os[,\\\\/]|\\\\d,\\\\d\\\\/)[\\\\d\\\\.]+/i],[d,[f,S],[m,T]],[/droid.+; (glass) \\\\d/i],[d,[f,I],[m,T]],[/droid.+; (wt63?0{2,3})\\\\)/i],[d,[f,q],[m,T]],[/(quest( 2| pro)?)/i],[d,[f,F],[m,T]],[/(tesla)(?: qtcarbrowser|\\\\/[-\\\\w\\\\.]+)/i],[f,[m,k]],[/(aeobc)\\\\b/i],[d,[f,_],[m,k]],[/droid .+?; ([^;]+?)(?: bui|\\\\) applew).+? mobile safari/i],[d,[m,h]],[/droid .+?; ([^;]+?)(?: bui|\\\\) applew).+?(?! mobile) safari/i],[d,[m,w]],[/\\\\b((tablet|tab)[;\\\\/]|focus\\\\/\\\\d(?!.+mobile))/i],[[m,w]],[/(phone|mobile(?:[;\\\\/]| [ \\\\w\\\\/\\\\.]*safari)|pda(?=.+windows ce))/i],[[m,h]],[/(android[-\\\\w\\\\. ]{0,9});.+buil/i],[d,[f,\"Generic\"]]],engine:[[/windows.+ edge\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"EdgeHTML\"]],[/webkit\\\\/537\\\\.36.+chrome\\\\/(?!27)([\\\\w\\\\.]+)/i],[v,[p,\"Blink\"]],[/(presto)\\\\/([\\\\w\\\\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\\\\/([\\\\w\\\\.]+)/i,/ekioh(flow)\\\\/([\\\\w\\\\.]+)/i,/(khtml|tasman|links)[\\\\/ ]\\\\(?([\\\\w\\\\.]+)/i,/(icab)[\\\\/ ]([23]\\\\.[\\\\d\\\\.]+)/i,/\\\\b(libweb)/i],[p,v],[/rv\\\\:([\\\\w\\\\.]{1,9})\\\\b.+(gecko)/i],[v,p]],os:[[/microsoft (windows) (vista|xp)/i],[p,v],[/(windows) nt 6\\\\.2; (arm)/i,/(windows (?:phone(?: os)?|mobile))[\\\\/ ]?([\\\\d\\\\.\\\\w ]*)/i,/(windows)[\\\\/ ]?([ntce\\\\d\\\\. ]+\\\\w)(?!.+xbox)/i],[p,[v,J,X]],[/(win(?=3|9|n)|win 9x )([nt\\\\d\\\\.]+)/i],[[p,\"Windows\"],[v,J,X]],[/ip[honead]{2,4}\\\\b(?:.*os ([\\\\w]+) like mac|; opera)/i,/ios;fbsv\\\\/([\\\\d\\\\.]+)/i,/cfnetwork\\\\/.+darwin/i],[[v,/_/g,\".\"],[p,\"iOS\"]],[/(mac os x) ?([\\\\w\\\\. ]*)/i,/(macintosh|mac_powerpc\\\\b)(?!.+haiku)/i],[[p,K],[v,/_/g,\".\"]],[/droid ([\\\\w\\\\.]+)\\\\b.+(android[- ]x86|harmonyos)/i],[v,p],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\\\\/ ]?([\\\\w\\\\.]*)/i,/(blackberry)\\\\w*\\\\/([\\\\w\\\\.]*)/i,/(tizen|kaios)[\\\\/ ]([\\\\w\\\\.]+)/i,/\\\\((series40);/i],[p,v],[/\\\\(bb(10);/i],[v,[p,x]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\\\\/ ]?([\\\\w\\\\.]*)/i],[v,[p,\"Symbian\"]],[/mozilla\\\\/[\\\\d\\\\.]+ \\\\((?:mobile|tablet|tv|mobile; [\\\\w ]+); rv:.+ gecko\\\\/([\\\\w\\\\.]+)/i],[v,[p,N+\" OS\"]],[/web0s;.+rt(tv)/i,/\\\\b(?:hp)?wos(?:browser)?\\\\/([\\\\w\\\\.]+)/i],[v,[p,\"webOS\"]],[/watch(?: ?os[,\\\\/]|\\\\d,\\\\d\\\\/)([\\\\d\\\\.]+)/i],[v,[p,\"watchOS\"]],[/crkey\\\\/([\\\\d\\\\.]+)/i],[v,[p,j+\"cast\"]],[/(cros) [\\\\w]+(?:\\\\)| ([\\\\w\\\\.]+)\\\\b)/i],[[p,z],v],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\\\\/(\\\\d+\\\\.[\\\\w\\\\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\\\\);]+)/i,/\\\\b(joli|palm)\\\\b ?(?:os)?\\\\/?([\\\\w\\\\.]*)/i,/(mint)[\\\\/\\\\(\\\\) ]?(\\\\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\\\\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\\\\/ ]?(?!chrom|package)([-\\\\w\\\\.]*)/i,/(hurd|linux) ?([\\\\w\\\\.]*)/i,/(gnu) ?([\\\\w\\\\.]*)/i,/\\\\b([-frentopcghs]{0,5}bsd|dragonfly)[\\\\/ ]?(?!amd|[ix346]{1,2}86)([\\\\w\\\\.]*)/i,/(haiku) (\\\\w+)/i],[p,v],[/(sunos) ?([\\\\w\\\\.\\\\d]*)/i],[[p,\"Solaris\"],v],[/((?:open)?solaris)[-\\\\/ ]?([\\\\w\\\\.]*)/i,/(aix) ((\\\\d)(?=\\\\.|\\\\)| )[\\\\w\\\\.])*/i,/\\\\b(beos|os\\\\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\\\\w\\\\.]*)/i],[p,v]]},Z=function(e,t){if(typeof e===c&&(t=e,e=a),!(this instanceof Z))return new Z(e,t).getResult();var n=typeof i!==s&&i.navigator?i.navigator:a,r=e||(n&&n.userAgent?n.userAgent:\"\"),b=n&&n.userAgentData?n.userAgentData:a,y=t?function(e,t){var n={};for(var r in e)t[r]&&t[r].length%2==0?n[r]=t[r].concat(e[r]):n[r]=e[r];return n}(G,t):G,T=n&&n.userAgent==r;return this.getBrowser=function(){var e,t={};return t[p]=a,t[v]=a,V.call(t,r,y.browser),t[l]=typeof(e=t[v])===u?e.replace(/[^\\\\d\\\\.]/g,\"\").split(\".\")[0]:a,T&&n&&n.brave&&typeof n.brave.isBrave==o&&(t[p]=\"Brave\"),t},this.getCPU=function(){var e={};return e[g]=a,V.call(e,r,y.cpu),e},this.getDevice=function(){var e={};return e[f]=a,e[d]=a,e[m]=a,V.call(e,r,y.device),T&&!e[m]&&b&&b.mobile&&(e[m]=h),T&&\"Macintosh\"==e[d]&&n&&typeof n.standalone!==s&&n.maxTouchPoints&&n.maxTouchPoints>2&&(e[d]=\"iPad\",e[m]=w),e},this.getEngine=function(){var e={};return e[p]=a,e[v]=a,V.call(e,r,y.engine),e},this.getOS=function(){var e={};return e[p]=a,e[v]=a,V.call(e,r,y.os),T&&!e[p]&&b&&\"Unknown\"!=b.platform&&(e[p]=b.platform.replace(/chrome os/i,z).replace(/macos/i,K)),e},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return r},this.setUA=function(e){return r=typeof e===u&&e.length>350?H(e,350):e,this},this.setUA(r),this};Z.VERSION=\"1.0.35\",Z.BROWSER=$([p,v,l]),Z.CPU=$([g]),Z.DEVICE=$([d,f,m,b,h,y,w,T,k]),Z.ENGINE=Z.OS=$([p,v]),typeof t!==s?(e.exports&&(t=e.exports=Z),t.UAParser=Z):n.amdO?(r=function(){return Z}.call(t,n,t,e))===a||(e.exports=r):typeof i!==s&&(i.UAParser=Z);var Y=typeof i!==s&&(i.jQuery||i.Zepto);if(Y&&!Y.ua){var ee=new Z;Y.ua=ee.getResult(),Y.ua.get=function(){return ee.getUA()},Y.ua.set=function(e){ee.setUA(e);var t=ee.getResult();for(var n in t)Y.ua[n]=t[n]}}}(\"object\"==typeof window?window:this)}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var a=t[r]={exports:{}};return e[r].call(a.exports,a,a.exports,n),a.exports}n.amdO={},n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{\"undefined\"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:\"Module\"}),Object.defineProperty(e,\"__esModule\",{value:!0})};var r={};return(()=>{\"use strict\";n.r(r),n.d(r,{ActionType:()=>f,AmplitudePlatformName:()=>g,AnalyticsEventImportance:()=>l,AnalyticsQueries:()=>e,AuthStatus:()=>b,ComponentType:()=>m,IThresholdTier:()=>Jt,MetricType:()=>d,PlatformName:()=>v,SessionActions:()=>h,SessionAutomatedEvents:()=>w,SessionRank:()=>y,SubjectType:()=>p,UserTypeCommerce:()=>c,UserTypeInsto:()=>i,UserTypeRetail:()=>t,UserTypeRetailBusinessBanking:()=>s,UserTypeRetailEmployeeInternal:()=>a,UserTypeRetailEmployeePersonal:()=>o,UserTypeWallet:()=>u,automatedEvents:()=>xn,automatedMappingConfig:()=>In,clearMarkEntry:()=>Vn,clearPerformanceMarkEntries:()=>Xn,config:()=>A,createEventConfig:()=>On,createNewSpan:()=>Ln,createNewTrace:()=>Un,device:()=>W,endPerfMark:()=>Jn,exposeExperiment:()=>wn,flushQueue:()=>or,generateUUID:()=>V,getAnalyticsHeaders:()=>sr,getReferrerData:()=>le,getTracingHeaders:()=>An,getTracingId:()=>Dn,getUrlHostname:()=>pe,getUrlParams:()=>me,getUrlPathname:()=>fe,getUserContext:()=>ar,identify:()=>Tn,identifyFlow:()=>xe,identity:()=>H,identityFlow:()=>Se,incrementUjNavigation:()=>an,init:()=>yn,initNextJsTrackPageview:()=>_n,initTrackPageview:()=>kn,isEventKeyFormatValid:()=>we,isSessionEnded:()=>pt,location:()=>re,logEvent:()=>$t,logMetric:()=>Ht,logPageView:()=>on,logTrace:()=>Rn,markNTBT:()=>tn,markStep:()=>nn,markStepOnce:()=>rn,onVisibilityChange:()=>ln,optIn:()=>En,optOut:()=>Sn,perfMark:()=>Wn,persistentData:()=>oe,postMessage:()=>K,recordSessionDuration:()=>pn,removeFromIdentifyFlow:()=>Ee,savePersistentData:()=>st,sendScheduledEvents:()=>Bt,setBreadcrumbs:()=>ie,setConfig:()=>U,setLocation:()=>ae,setPagePath:()=>ve,setPageview:()=>Kt,setPersistentData:()=>se,setSessionStart:()=>dt,setTime:()=>Ue,startPerfMark:()=>Hn,timeStone:()=>Le,useEventLogger:()=>Yn,useLogEventOnMount:()=>tr,usePerformanceMarks:()=>rr});let e=function(e){return e.fbclid=\"fbclid\",e.gclid=\"gclid\",e.msclkid=\"msclkid\",e.ptclid=\"ptclid\",e.ttclid=\"ttclid\",e.utm_source=\"utm_source\",e.utm_medium=\"utm_medium\",e.utm_campaign=\"utm_campaign\",e.utm_term=\"utm_term\",e.utm_content=\"utm_content\",e}({});const t=0,i=1,a=2,o=3,s=4,c=5,u=6;let l=function(e){return e.low=\"low\",e.high=\"high\",e}({}),d=function(e){return e.count=\"count\",e.rate=\"rate\",e.gauge=\"gauge\",e.distribution=\"distribution\",e.histogram=\"histogram\",e}({}),p=function(e){return e.commerce_merchant=\"commerce_merchant\",e.device=\"device\",e.edp_fingerprint_id=\"edp_fingerprint_id\",e.nft_user=\"nft_user\",e.user=\"user\",e.wallet_user=\"wallet_user\",e.uuid=\"user_uuid\",e}({}),m=function(e){return e.unknown=\"unknown\",e.banner=\"banner\",e.button=\"button\",e.card=\"card\",e.chart=\"chart\",e.content_script=\"content_script\",e.dropdown=\"dropdown\",e.link=\"link\",e.page=\"page\",e.modal=\"modal\",e.table=\"table\",e.search_bar=\"search_bar\",e.service_worker=\"service_worker\",e.text=\"text\",e.text_input=\"text_input\",e.tray=\"tray\",e.checkbox=\"checkbox\",e.icon=\"icon\",e}({}),f=function(e){return e.unknown=\"unknown\",e.blur=\"blur\",e.click=\"click\",e.change=\"change\",e.dismiss=\"dismiss\",e.focus=\"focus\",e.hover=\"hover\",e.select=\"select\",e.measurement=\"measurement\",e.move=\"move\",e.process=\"process\",e.render=\"render\",e.scroll=\"scroll\",e.view=\"view\",e.search=\"search\",e.keyPress=\"keyPress\",e}({}),v=function(e){return e.unknown=\"unknown\",e.web=\"web\",e.android=\"android\",e.ios=\"ios\",e.mobile_web=\"mobile_web\",e.tablet_web=\"tablet_web\",e.server=\"server\",e.windows=\"windows\",e.macos=\"macos\",e.extension=\"extension\",e}({}),g=function(e){return e.web=\"Web\",e.ios=\"iOS\",e.android=\"Android\",e}({}),b=function(e){return e[e.notLoggedIn=0]=\"notLoggedIn\",e[e.loggedIn=1]=\"loggedIn\",e}({}),h=function(e){return e.ac=\"ac\",e.af=\"af\",e.ah=\"ah\",e.al=\"al\",e.am=\"am\",e.ar=\"ar\",e.as=\"as\",e}({}),w=function(e){return e.pv=\"pv\",e}({}),y=function(e){return e.xs=\"xs\",e.s=\"s\",e.m=\"m\",e.l=\"l\",e.xl=\"xl\",e.xxl=\"xxl\",e}({});const T=\"https://analytics-service-dev.cbhq.net\",k=3e5,_=5e3,S=\"analytics-db\",E=\"experiment-exposure-db\",x=\"Analytics SDK:\",O=Object.values(e),j=\"pageview\",N=\"session_duration\",I={navigationTiming:{eventName:\"perf_navigation_timing\"},redirectTime:{eventName:\"perf_redirect_time\"},RT:{eventName:\"perf_redirect_time\"},TTFB:{eventName:\"perf_time_to_first_byte\"},networkInformation:{eventName:\"perf_network_information\"},storageEstimate:{eventName:\"perf_storage_estimate\"},FCP:{eventName:\"perf_first_contentful_paint\"},FID:{eventName:\"perf_first_input_delay\"},LCP:{eventName:\"perf_largest_contentful_paint\"},CLS:{eventName:\"perf_cumulative_layout_shift\"},TBT:{eventName:\"perf_total_blocking_time\"},NTBT:{eventName:\"perf_navigation_total_blocking_time\"},INP:{eventName:\"perf_interact_to_next_paint\"},ET:{eventName:\"perf_element_timing\"},userJourneyStep:{eventName:\"perf_user_journey_step\"}},P=\"1\",M=\"web\";function B(){return B=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},B.apply(this,arguments)}const C=/^(https?:\\\\/\\\\/)/;function D(e){return{eventsEndpoint:e+\"/amp\",metricsEndPoint:e+\"/metrics\",exposureEndpoint:e+\"/track-exposures\",tracesEndpoint:e+\"/traces\"}}const A=B({authCookie:\"logged_in\",amplitudeApiKey:\"\",batchEventsPeriod:_,batchEventsThreshold:30,batchMetricsPeriod:_,batchMetricsThreshold:30,batchTracesPeriod:_,batchTracesThreshold:30,headers:{},interactionManager:null,isAlwaysAuthed:!1,isProd:!1,isInternalApplication:!1,onError:(e,t)=>{console.error(x,e,t)},platform:v.unknown,projectName:\"\",ricTimeoutScheduleEvent:1e3,ricTimeoutSetDevice:500,showDebugLogging:!1,trackUserId:!1,version:null,apiEndpoint:T},D(T),{steps:{}}),L=[].reduce(((e,t)=>n=>e(t(n))),(e=>{if(!e.isProd)return e.isInternalApplication?(e.apiEndpoint=\"https://analytics-service-internal-dev.cbhq.net\",B({},e,D(e.apiEndpoint))):e;const t=(e=>e.apiEndpoint?C.test(e.apiEndpoint)?e.apiEndpoint:\\`https://\\${e.apiEndpoint}\\`:e.isInternalApplication?\"https://analytics-service-internal.cbhq.net\":\"https://as.coinbase.com\")(e);return B({},e,{apiEndpoint:t},D(t))})),U=e=>{const{batchEventsThreshold:t,batchMetricsThreshold:n,batchTracesThreshold:r}=e,i=[t,n,r];for(const e of i)if((e||0)>30){console.warn(\"You are setting the threshhold for the batch limit to be greater than 30. This may cause request overload.\");break}Object.assign(A,L(e))},R=[v.web,v.mobile_web,v.tablet_web];function q(){return\"android\"===A.platform}function F(){return\"ios\"===A.platform}function z(){return R.includes(A.platform)}function K(e){if(z()&&navigator&&\"serviceWorker\"in navigator&&navigator.serviceWorker.controller)try{navigator.serviceWorker.controller.postMessage(e)}catch(e){e instanceof Error&&A.onError(e)}}var $=n(353),Q=n.n($);const W={amplitudeOSName:null,amplitudeOSVersion:null,amplitudeDeviceModel:null,amplitudePlatform:null,browserName:null,browserMajor:null,osName:null,userAgent:null,width:null,height:null},H={countryCode:null,deviceId:null,device_os:null,isOptOut:!1,languageCode:null,locale:null,jwt:null,session_lcc_id:null,userAgent:null,userId:null},V=e=>e?(e^16*Math.random()>>e/4).toString(16):\"10000000-1000-4000-8000-100000000000\".replace(/[018]/g,V),J=()=>A.isAlwaysAuthed||!!H.userId,X=()=>{const e={};return H.countryCode&&(e.country_code=H.countryCode),e},G=()=>{const{platform:e}=A;if(e===v.web)switch(!0){case window.matchMedia(\"(max-width: 560px)\").matches:return v.mobile_web;case window.matchMedia(\"(max-width: 1024px, min-width: 561px)\").matches:return v.tablet_web}return e},Z=()=>{var e,t,n,r,i;z()?(\"requestIdleCallback\"in window?window.requestIdleCallback(ne,{timeout:A.ricTimeoutSetDevice}):ne(),W.amplitudePlatform=g.web,W.userAgent=(null==(e=window)||null==(e=e.navigator)?void 0:e.userAgent)||null,ee({height:null!=(t=null==(n=window)?void 0:n.innerHeight)?t:null,width:null!=(r=null==(i=window)?void 0:i.innerWidth)?r:null})):F()?(W.amplitudePlatform=g.ios,W.userAgent=H.userAgent,W.userAgent&&ne()):q()&&(W.userAgent=H.userAgent,W.amplitudePlatform=g.android,W.userAgent&&ne())},Y=e=>{Object.assign(H,e),z()&&K({identity:{isAuthed:!!H.userId,locale:H.locale||null}})},ee=e=>{W.height=e.height,W.width=e.width},te=()=>{U({platform:G()}),z()&&K({config:{platform:A.platform}})},ne=()=>{var e;performance.mark&&performance.mark(\"ua_parser_start\");const t=new(Q())(null!=(e=W.userAgent)?e:\"\").getResult();W.browserName=t.browser.name||null,W.browserMajor=t.browser.major||null,W.osName=t.os.name||null,W.amplitudeOSName=W.browserName,W.amplitudeOSVersion=W.browserMajor,W.amplitudeDeviceModel=W.osName,K({device:{browserName:W.browserName,osName:W.osName}}),performance.mark&&(performance.mark(\"ua_parser_end\"),performance.measure(\"ua_parser\",\"ua_parser_start\",\"ua_parser_end\"))},re={breadcrumbs:[],initialUAAData:{},pageKey:\"\",pageKeyRegex:{},pagePath:\"\",prevPageKey:\"\",prevPagePath:\"\"};function ie(e){Object.assign(re,{breadcrumbs:e})}function ae(e){Object.assign(re,e)}const oe={eventId:0,sequenceNumber:0,sessionId:0,lastEventTime:0,sessionStart:0,sessionUUID:null,userId:null,ac:0,af:0,ah:0,al:0,am:0,ar:0,as:0,pv:0};function se(e){Object.assign(oe,e)}function ce(){var e,t;return null!=(e=null==(t=document)?void 0:t.referrer)?e:\"\"}function ue(){return ue=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ue.apply(this,arguments)}const le=()=>{const e=ce();if(!e)return{};const t=new URL(e);return t.hostname===pe()?{}:{referrer:e,referring_domain:t.hostname}},de=()=>{const e=new URLSearchParams(me()),t={};return O.forEach((n=>{e.has(n)&&(t[n]=(e.get(n)||\"\").toLowerCase())})),t},pe=()=>{var e;return(null==(e=window)||null==(e=e.location)?void 0:e.hostname)||\"\"},me=()=>{var e;return(null==(e=window)||null==(e=e.location)?void 0:e.search)||\"\"},fe=()=>{var e;return(null==(e=window)||null==(e=e.location)?void 0:e.pathname)||\"\"},ve=()=>{const e=A.overrideWindowLocation?re.pagePath:fe()+me();e&&e!==re.pagePath&&(e!==re.pagePath&&ge(),re.pagePath=e,re.pageKeyRegex&&Object.keys(re.pageKeyRegex).some((e=>{if(re.pageKeyRegex[e].test(re.pagePath))return re.pageKey=e,!0})))},ge=()=>{if(z()){const e=ce();if(!re.prevPagePath&&e){const t=new URL(e);if(t.hostname===pe())return void(re.prevPagePath=t.pathname)}}re.prevPagePath=re.pagePath,re.prevPageKey=re.pageKey},be=e=>{z()&&Object.assign(e,z()?(Object.keys(re.initialUAAData).length>0||(new URLSearchParams(me()),re.initialUAAData=ue({},(()=>{const e={};return O.forEach((t=>{oe[t]&&(e[t]=oe[t])})),e})(),de(),le())),re.initialUAAData):re.initialUAAData)},he=/^[a-zd]+(_[a-zd]+)*$/;function we(e){return he.test(e)}function ye(){return ye=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ye.apply(this,arguments)}const Te=[\"action\",\"component_type\",\"component_name\",\"context\",\"logging_id\"],ke=[\"num_non_hardware_accounts\",\"ujs\"],_e=\"ujs_\",Se={};function Ee(e){e.forEach((e=>{ke.includes(e)&&delete Se[e]}))}function xe(e){var t;const n=Object.entries(e).reduce(((e,t)=>{const[n,r]=t;return!Te.includes(n)&&ke.includes(n)?we(n)?ye({},e,{[n]:r}):(A.onError(new Error(\"IdentityFlow property names must have snake case format\"),{[n]:r}),e):e}),{});null!=(t=n.ujs)&&t.length&&(n.ujs=n.ujs.map((e=>\\`\\${_e}\\${e}\\`))),Object.assign(Se,n)}function Oe(){return A.platform!==v.unknown||(A.onError(new Error(\"SDK platform not initialized\")),!1)}const je={eventsQueue:[],eventsScheduled:!1,metricsQueue:[],metricsScheduled:!1,tracesQueue:[],tracesScheduled:!1};function Ne(e){Object.assign(je,e)}const Ie={ac:0,af:0,ah:0,al:0,am:0,ar:0,as:0,pv:0,sqs:0},Pe={ac:20,af:5,ah:1,al:1,am:0,ar:10,as:20},Me={pv:25},Be={xs:0,s:1,m:1,l:2,xl:2,xxl:2},Ce=e=>e<15?y.xs:e<60?y.s:e<240?y.m:e<960?y.l:e<3840?y.xl:y.xxl,De=e=>{Object.assign(Ie,e)};function Ae(){return(new Date).getTime()}const Le={timeStart:Ae(),timeOnPagePath:0,timeOnPageKey:0,prevTimeOnPagePath:0,prevTimeOnPageKey:0,sessionDuration:0,sessionEnd:0,sessionStart:0,prevSessionDuration:0};function Ue(e){Object.assign(Le,e)}const Re=(e,t)=>t.some((t=>e instanceof t));let qe,Fe;const ze=new WeakMap,Ke=new WeakMap,$e=new WeakMap,Qe=new WeakMap,We=new WeakMap;let He={get(e,t,n){if(e instanceof IDBTransaction){if(\"done\"===t)return Ke.get(e);if(\"objectStoreNames\"===t)return e.objectStoreNames||$e.get(e);if(\"store\"===t)return n.objectStoreNames[1]?void 0:n.objectStore(n.objectStoreNames[0])}return Je(e[t])},set:(e,t,n)=>(e[t]=n,!0),has:(e,t)=>e instanceof IDBTransaction&&(\"done\"===t||\"store\"===t)||t in e};function Ve(e){return\"function\"==typeof e?(t=e)!==IDBDatabase.prototype.transaction||\"objectStoreNames\"in IDBTransaction.prototype?(Fe||(Fe=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])).includes(t)?function(...e){return t.apply(Xe(this),e),Je(ze.get(this))}:function(...e){return Je(t.apply(Xe(this),e))}:function(e,...n){const r=t.call(Xe(this),e,...n);return $e.set(r,e.sort?e.sort():[e]),Je(r)}:(e instanceof IDBTransaction&&function(e){if(Ke.has(e))return;const t=new Promise(((t,n)=>{const r=()=>{e.removeEventListener(\"complete\",i),e.removeEventListener(\"error\",a),e.removeEventListener(\"abort\",a)},i=()=>{t(),r()},a=()=>{n(e.error||new DOMException(\"AbortError\",\"AbortError\")),r()};e.addEventListener(\"complete\",i),e.addEventListener(\"error\",a),e.addEventListener(\"abort\",a)}));Ke.set(e,t)}(e),Re(e,qe||(qe=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction]))?new Proxy(e,He):e);var t}function Je(e){if(e instanceof IDBRequest)return function(e){const t=new Promise(((t,n)=>{const r=()=>{e.removeEventListener(\"success\",i),e.removeEventListener(\"error\",a)},i=()=>{t(Je(e.result)),r()},a=()=>{n(e.error),r()};e.addEventListener(\"success\",i),e.addEventListener(\"error\",a)}));return t.then((t=>{t instanceof IDBCursor&&ze.set(t,e)})).catch((()=>{})),We.set(t,e),t}(e);if(Qe.has(e))return Qe.get(e);const t=Ve(e);return t!==e&&(Qe.set(e,t),We.set(t,e)),t}const Xe=e=>We.get(e),Ge=[\"get\",\"getKey\",\"getAll\",\"getAllKeys\",\"count\"],Ze=[\"put\",\"add\",\"delete\",\"clear\"],Ye=new Map;function et(e,t){if(!(e instanceof IDBDatabase)||t in e||\"string\"!=typeof t)return;if(Ye.get(t))return Ye.get(t);const n=t.replace(/FromIndex$/,\"\"),r=t!==n,i=Ze.includes(n);if(!(n in(r?IDBIndex:IDBObjectStore).prototype)||!i&&!Ge.includes(n))return;const a=async function(e,...t){const a=this.transaction(e,i?\"readwrite\":\"readonly\");let o=a.store;return r&&(o=o.index(t.shift())),(await Promise.all([o[n](...t),i&&a.done]))[0]};return Ye.set(t,a),a}var tt;tt=He,He={...tt,get:(e,t,n)=>et(e,t)||tt.get(e,t,n),has:(e,t)=>!!et(e,t)||tt.has(e,t)};const nt={isReady:!1,idbKeyval:null};function rt(e){Object.assign(nt,e)}const it={},at=async e=>{if(!nt.idbKeyval)return Promise.resolve(null);try{return await nt.idbKeyval.get(e)}catch(e){return A.onError(new Error(\"IndexedDB:Get:InternalError\")),Promise.resolve(null)}},ot=async(e,t)=>{if(nt.idbKeyval)try{await nt.idbKeyval.set(e,t)}catch(e){A.onError(new Error(\"IndexedDB:Set:InternalError\"))}},st=()=>{\"server\"!==A.platform&&(se({sessionStart:Le.sessionStart,ac:Ie.ac,af:Ie.af,ah:Ie.ah,al:Ie.al,am:Ie.am,ar:Ie.ar,as:Ie.as,pv:Ie.pv}),H.userId&&se({userId:H.userId}),ot(S,oe))},ct=\"rgb(5,177,105)\",ut=e=>{const{metricName:t,data:n}=e,r=e.importance||l.low;if(!A.showDebugLogging||!console)return;const i=\\`%c \\${x}\\`,a=\\`color:\\${ct};font-size:11px;\\`,o=\\`Importance: \\${r}\\`;console.group(i,a,t,o),n.forEach((e=>{e.event_type?console.log(e.event_type,e):console.log(e)})),console.groupEnd()},lt=e=>{const{metricName:t,data:n}=e,r=e.importance||l.low;if(!A.showDebugLogging||!console)return;const i=\\`color:\\${ct};font-size:11px;\\`,a=\\`%c \\${x}\\`,o=\\`Importance: \\${r}\\`;console.log(a,i,t,n,o)},dt=()=>{const e=Ae();oe.sessionId&&oe.lastEventTime&&oe.sessionUUID&&!pt(e)||(oe.sessionId=e,oe.sessionUUID=V(),Ue({sessionStart:e}),lt({metricName:\"Started new session:\",data:{persistentData:oe,timeStone:Le}})),oe.lastEventTime=e},pt=e=>e-oe.lastEventTime>18e5;function mt(){return mt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},mt.apply(this,arguments)}const ft=e=>{var t;(e=>{switch(e.action){case f.click:Ie.ac+=1;break;case f.focus:Ie.af+=1;break;case f.hover:Ie.ah+=1;break;case f.move:Ie.am+=1;break;case f.scroll:Ie.al+=1;break;case f.search:Ie.ar+=1;break;case f.select:Ie.as+=1}})(t=e),t.event_type!==j?t.event_type===N&&((e=>{if(!e.session_rank)return;const t=e.session_rank;Object.values(h).forEach((e=>{Ie.sqs+=Ie[e]*Pe[e]})),Object.values(w).forEach((e=>{Ie.sqs+=Ie[e]*Me[e]})),Ie.sqs*=Be[t]})(t),Object.assign(t,Ie),De({ac:0,af:0,ah:0,al:0,am:0,ar:0,as:0,pv:0,sqs:0})):Ie.pv+=1;const n=e.event_type;delete e.event_type;const r=e.deviceId?e.deviceId:null,i=e.timestamp;return delete e.timestamp,se({eventId:oe.eventId+1}),se({sequenceNumber:oe.sequenceNumber+1}),dt(),st(),{device_id:H.deviceId||r||null,user_id:H.userId,timestamp:i,event_id:oe.eventId,session_id:oe.sessionId||-1,event_type:n,version_name:A.version||null,platform:W.amplitudePlatform,os_name:W.amplitudeOSName,os_version:W.amplitudeOSVersion,device_model:W.amplitudeDeviceModel,language:H.languageCode,event_properties:mt({},e,{session_uuid:oe.sessionUUID,height:W.height,width:W.width}),user_properties:X(),uuid:V(),library:{name:\"@cbhq/client-analytics\",version:\"10.6.0\"},sequence_number:oe.sequenceNumber,user_agent:W.userAgent||H.userAgent}},vt=e=>e.map((e=>ft(e)));function gt(){return gt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},gt.apply(this,arguments)}const bt=e=>e.map((e=>(e=>{const t=e.tags||{},n=gt({authed:J()?\"true\":\"false\",platform:A.platform},t,{project_name:A.projectName,version_name:A.version||null});return{metric_name:e.metricName,page_path:e.pagePath||null,value:e.value,tags:n,type:e.metricType}})(e))),ht=e=>0!==je.metricsQueue.length&&(je.metricsQueue.length>=A.batchMetricsThreshold||(je.metricsScheduled||(je.metricsScheduled=!0,setTimeout((()=>{je.metricsScheduled=!1,e(bt(je.metricsQueue)),je.metricsQueue=[]}),A.batchMetricsPeriod)),!1)),wt=e=>0!==je.tracesQueue.length&&(je.tracesQueue.length>=A.batchTracesThreshold||(je.tracesScheduled||(je.tracesScheduled=!0,setTimeout((()=>{je.tracesScheduled=!1,e(je.tracesQueue),je.tracesQueue=[]}),A.batchTracesPeriod)),!1)),yt=e=>{var t;z()&&null!=(t=window)&&t.requestIdleCallback?window.requestIdleCallback(e,{timeout:A.ricTimeoutScheduleEvent}):(q()||F())&&A.interactionManager?A.interactionManager.runAfterInteractions(e):e()};function Tt(){return Tt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Tt.apply(this,arguments)}const kt=\"application/x-www-form-urlencoded; charset=UTF-8\",_t=e=>{const{data:t,importance:n,isJSON:r,onError:i,url:a}=e,o=r?\"application/json\":kt,s=n||l.low,c=r?JSON.stringify(t):new URLSearchParams(t).toString();function u(){const e=new XMLHttpRequest;e.open(\"POST\",a,!0),Object.keys(A.headers||{}).forEach((t=>{e.setRequestHeader(t,A.headers[t])})),e.setRequestHeader(\"Content-Type\",kt),H.jwt&&e.setRequestHeader(\"authorization\",\\`Bearer \\${H.jwt}\\`),e.send(c)}if(!z()||r||!(\"sendBeacon\"in navigator)||s!==l.low||A.headers&&0!==Object.keys(A.headers).length)if(z()&&!r)u();else{const e=Tt({},A.headers,{\"Content-Type\":o});H.jwt&&(e.Authorization=\\`Bearer \\${H.jwt}\\`),fetch(a,{method:\"POST\",mode:\"no-cors\",headers:e,body:c}).catch((e=>{i(e,{context:\"AnalyticsSDKApiError\"})}))}else{const e=new Blob([c],{type:kt});try{navigator.sendBeacon.bind(navigator)(a,e)||u()}catch(e){console.error(e),u()}}};var St=n(762),Et=n.n(St);const xt=(e,t,n)=>{const r=e||\"\";return Et()(\"2\"+r+t+n)};function Ot(){return Ot=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ot.apply(this,arguments)}class jt extends Error{constructor(e){super(e),this.name=\"CircularJsonReference\",this.message=e,\"function\"==typeof Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error(e).stack}}class Nt extends jt{constructor(...e){super(...e),this.name=\"DomReferenceInAnalyticsEvent\"}}function It(){return It=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},It.apply(this,arguments)}const Pt=(e,t=l.low)=>{var n;e&&je.eventsQueue.push(e),nt.isReady&&(!A.trackUserId||H.userId?(t===l.high||(n=Mt,0!==je.eventsQueue.length&&(je.eventsQueue.length>=A.batchEventsThreshold||(je.eventsScheduled||(je.eventsScheduled=!0,setTimeout((()=>{je.eventsScheduled=!1,n(vt(je.eventsQueue)),je.eventsQueue=[]}),A.batchEventsPeriod)),0))))&&Bt():je.eventsQueue.length>10&&(A.trackUserId=!1,A.onError(new Error(\"userId not set in Logged-in\"))))},Mt=(e,t=l.low)=>{if(H.isOptOut||0===e.length)return;let n;try{n=JSON.stringify(e)}catch(t){const r=e.map((e=>e.event_type)).join(\", \"),[i,a]=(e=>{try{const n=[];for(const r of e){const e=Ot({},r);r.event_properties&&(e.event_properties=Ot({},e.event_properties,{currentTarget:null,target:null,relatedTarget:null,_dispatchInstances:null,_targetInst:null,view:(t=r.event_properties.view,[\"string\",\"number\",\"boolean\"].includes(typeof t)?r.event_properties.view:null)})),n.push(e)}return[!0,JSON.stringify(n)]}catch(e){return[!1,\"\"]}var t})(e);if(!i)return void A.onError(new jt(t instanceof Error?t.message:\"unknown\"),{listEventType:r});n=a,A.onError(new Nt(\"Found DOM element reference\"),{listEventType:r,stringifiedEventData:n})}const r=Ae().toString(),i=It({},{e:n,v:\"2\",upload_time:r},{client:A.amplitudeApiKey,checksum:xt(A.amplitudeApiKey,n,r)});_t({url:A.eventsEndpoint,data:i,importance:t,onError:A.onError}),ut({metricName:\"Batch Events\",data:e,importance:t})},Bt=()=>{Mt(vt(je.eventsQueue)),Ne({eventsQueue:[]})};function Ct(){return Ct=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ct.apply(this,arguments)}const Dt=Object.values(f),At=Object.values(m),Lt=e=>Dt.includes(e)?e:f.unknown,Ut=e=>At.includes(e)?e:m.unknown,Rt=(e,t,n)=>{const r={auth:J()?b.loggedIn:b.notLoggedIn,action:Lt(e),component_type:Ut(t),logging_id:n,platform:A.platform,project_name:A.projectName};return\"number\"==typeof H.userTypeEnum&&(r.user_type_enum=H.userTypeEnum),r},qt=e=>{const t=Ae();if(!e)return A.onError(new Error(\"missing logData\")),Ct({},Rt(f.unknown,m.unknown),{locale:H.locale,session_lcc_id:H.session_lcc_id,timestamp:t,time_start:Le.timeStart});const n=Ct({},e,Rt(e.action,e.componentType,e.loggingId),{locale:H.locale,session_lcc_id:H.session_lcc_id,timestamp:t,time_start:Le.timeStart});return delete n.componentType,delete n.loggingId,n},Ft={blacklistRegex:[],isEnabled:!1};function zt(){return{page_key:re.pageKey,page_path:re.pagePath,prev_page_key:re.prevPageKey,prev_page_path:re.prevPagePath}}function Kt(e){Object.assign(Ft,e)}function $t(e,t,n=l.low){if(H.isOptOut)return;if(!Oe())return;const r=qt(t);!function(e){Ft.isEnabled&&(ve(),Object.assign(e,zt()))}(r),be(r),function(e){Object.keys(Se).length>0&&Object.assign(e,Se)}(r),r.has_double_fired=!1,r.event_type=e,n===l.high?Pt(r,n):yt((()=>{Pt(r)}))}function Qt(e,t=!1){t?_t({url:A.metricsEndPoint,data:{metrics:e},isJSON:!0,onError:A.onError}):yt((()=>{_t({url:A.metricsEndPoint,data:{metrics:e},isJSON:!0,onError:A.onError})})),ut({metricName:\"Batch Metrics\",data:e})}function Wt(){return Wt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Wt.apply(this,arguments)}function Ht(e){if(!Oe())return;v.server!==A.platform&&!e.pagePath&&re.pagePath&&(e.pagePath=re.pagePath);const t=Object.keys(Se).length?Wt({},e.tags,Se):e.tags;t&&Object.assign(e,{tags:t}),je.metricsQueue.push(e),ht(Qt)&&(Qt(bt(je.metricsQueue)),je.metricsQueue=[])}function Vt(){return Vt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vt.apply(this,arguments)}let Jt=function(e){return e.instant=\"instant\",e.quick=\"quick\",e.moderate=\"moderate\",e.slow=\"slow\",e.unavoidable=\"unavoidable\",e}({});function Xt(e){return e.toLowerCase()}let Gt={};const Zt=(e,t)=>{null!=A&&A.onMarkStep&&A.onMarkStep(e,t),xe({ujs:t})};let Yt;const en={Perfume:()=>{},markStep:e=>{},markStepOnce:e=>{},incrementUjNavigation:()=>{}},tn=()=>{z()&&Yt&&Yt.markNTBT&&Yt.markNTBT()},nn=e=>{z()&&Yt&&en.markStep&&en.markStep(e)},rn=e=>{z()&&Yt&&en.markStepOnce&&en.markStepOnce(e)},an=()=>{z()&&Yt&&en.incrementUjNavigation&&en.incrementUjNavigation()};function on(e={callMarkNTBT:!0}){\"unknown\"!==A.platform&&(Ft.blacklistRegex.some((e=>e.test(fe())))||($t(j,{action:f.render,componentType:m.page}),e.callMarkNTBT&&tn()))}let sn=!1,cn=!1;const un=e=>{sn=!e.persisted},ln=(e,t=\"hidden\",n=!1)=>{cn||(addEventListener(\"pagehide\",un),addEventListener(\"beforeunload\",(()=>{})),cn=!0),addEventListener(\"visibilitychange\",(({timeStamp:n})=>{document.visibilityState===t&&e({timeStamp:n,isUnloading:sn})}),{capture:!0,once:n})},dn=36e3;function pn(){const e=pt(Ae());if(e&&(O.forEach((e=>{oe[e]&&delete oe[e]})),st()),!oe.lastEventTime||!Le.sessionStart||!e)return;const t=Math.round((oe.lastEventTime-Le.sessionStart)/1e3);if(t<1||t>dn)return;const n=Ce(t);$t(N,{action:f.measurement,componentType:m.page,session_duration:t,session_end:oe.lastEventTime,session_start:Le.sessionStart,session_rank:n})}function mn(){return mn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},mn.apply(this,arguments)}const fn=[],vn=[],gn=()=>{const e=fn.shift();e&&e()},bn=()=>{const e=vn.shift();e&&e()};let hn={};function wn(e){const t=function(e){return{test_name:e.testName,group_name:e.group,subject_id:e.subjectId,exposed_at:Ae(),subject_type:e.subjectType,platform:A.platform}}(e);hn[e.testName]=hn[e.testName]||0,hn[e.testName]+k>Ae()?lt({metricName:\\`Event: exposeExperiment \\${e.testName} not sent\\`,data:t}):(hn[e.testName]=Ae(),ot(E,hn),lt({metricName:\\`Event: exposeExperiment \\${e.testName} sent\\`,data:t}),_t({url:A.exposureEndpoint,data:[t],onError:(t,n)=>{hn[e.testName]=0,ot(E,hn),A.onError(t,n)},isJSON:!0,importance:l.high}))}const yn=e=>{var t,r,i;U(e),z()&&(H.languageCode=(null==(t=navigator)?void 0:t.languages[0])||(null==(r=navigator)?void 0:r.language)||\"\"),te(),(()=>{var e;if(z()&&null!=(e=window)&&e.indexedDB){const e=function(e,t,{blocked:n,upgrade:r,blocking:i,terminated:a}={}){const o=indexedDB.open(e,t),s=Je(o);return r&&o.addEventListener(\"upgradeneeded\",(e=>{r(Je(o.result),e.oldVersion,e.newVersion,Je(o.transaction),e)})),n&&o.addEventListener(\"blocked\",(e=>n(e.oldVersion,e.newVersion,e))),s.then((e=>{a&&e.addEventListener(\"close\",(()=>a())),i&&e.addEventListener(\"versionchange\",(e=>i(e.oldVersion,e.newVersion,e)))})).catch((()=>{})),s}(\"keyval-store\",1,{upgrade(e){e.createObjectStore(\"keyval\")}});rt({idbKeyval:{get:async t=>(await e).get(\"keyval\",t),set:async(t,n)=>(await e).put(\"keyval\",n,t),delete:async t=>(await e).delete(\"keyval\",t),keys:async()=>(await e).getAllKeys(\"keyval\")}})}else rt({idbKeyval:{get:async e=>new Promise((t=>{t(it[e])})),set:async(e,t)=>new Promise((n=>{it[e]=t,n(e)})),delete:async e=>new Promise((()=>{delete it[e]})),keys:async()=>new Promise((e=>{e(Object.keys(it))}))}})})(),lt({metricName:\"Initialized Analytics:\",data:{deviceId:H.deviceId}}),fn.push((()=>{Pt()})),(async()=>{const e=await at(S);rt({isReady:!0}),gn(),e&&(bn(),se({eventId:e.eventId||oe.eventId,sequenceNumber:e.sequenceNumber||oe.sequenceNumber,sessionId:e.sessionId||oe.sessionId,lastEventTime:e.lastEventTime||oe.lastEventTime,sessionUUID:e.sessionUUID||oe.sessionUUID}),function(e){se(mn({},function(e){const t={};return O.forEach((n=>{e[n]&&(t[n]=e[n])})),t}(e),de()))}(e),Ue({sessionStart:e.sessionStart||oe.sessionStart}),De({ac:e.ac||Ie.ac,af:e.af||Ie.af,ah:e.ah||Ie.ah,al:e.al||Ie.al,am:e.am||Ie.am,ar:e.ar||Ie.ar,as:e.as||Ie.as,pv:e.pv||Ie.pv}),A.trackUserId&&Y({userId:e.userId||H.userId}),pn(),lt({metricName:\"Initialized Analytics IndexedDB:\",data:e}))})(),async function(){at(E).then((e=>{hn=null!=e?e:{}})).catch((e=>{e instanceof Error&&A.onError(e)}))}(),Z(),z()&&(ln((()=>{se({lastEventTime:Ae()}),st(),Bt()}),\"hidden\"),ln((()=>{pn()}),\"visible\")),z()&&(i=()=>{var e,t,n,r;te(),ee({width:null!=(e=null==(t=window)?void 0:t.innerWidth)?e:null,height:null!=(n=null==(r=window)?void 0:r.innerHeight)?n:null})},addEventListener(\"resize\",(()=>{requestAnimationFrame((()=>{i()}))}))),(()=>{if(z())try{const e=n(2);en.markStep=e.markStep,en.markStepOnce=e.markStepOnce,en.incrementUjNavigation=e.incrementUjNavigation,Yt=new e.Perfume({analyticsTracker:e=>{const{data:t,attribution:n,metricName:r,navigatorInformation:i,rating:a}=e,o=I[r],s=(null==n?void 0:n.category)||null;if(!o&&!s)return;const c=(null==i?void 0:i.deviceMemory)||0,u=(null==i?void 0:i.hardwareConcurrency)||0,l=(null==i?void 0:i.isLowEndDevice)||!1,p=(null==i?void 0:i.isLowEndExperience)||!1,v=(null==i?void 0:i.serviceWorkerStatus)||\"unsupported\",g=Vt({deviceMemory:c,hardwareConcurrency:u,isLowEndDevice:l,isLowEndExperience:p,serviceWorkerStatus:v},Gt),b={is_low_end_device:l,is_low_end_experience:p,page_key:re.pageKey||\"\",save_data:t.saveData||!1,service_worker:v,is_perf_metric:!0};if(\"navigationTiming\"===r)t&&\"number\"==typeof t.redirectTime&&Ht({metricName:I.redirectTime.eventName,metricType:d.histogram,tags:b,value:t.redirectTime||0});else if(\"TTFB\"===r)$t(o.eventName,Vt({action:f.measurement,componentType:m.page,duration:t||null,vitalsScore:a||null},g)),Ht({metricName:I.TTFB.eventName,metricType:d.histogram,tags:Vt({},b),value:t}),a&&Ht({metricName:\\`perf_web_vitals_ttfb_\\${a}\\`,metricType:d.count,tags:b,value:1});else if(\"networkInformation\"===r)null!=t&&t.effectiveType&&(Gt=t,$t(o.eventName,{action:f.measurement,componentType:m.page,networkInformationDownlink:t.downlink,networkInformationEffectiveType:t.effectiveType,networkInformationRtt:t.rtt,networkInformationSaveData:t.saveData,navigatorDeviceMemory:c,navigatorHardwareConcurrency:u}));else if(\"storageEstimate\"===r)$t(o.eventName,Vt({action:f.measurement,componentType:m.page},t,g)),Ht({metricName:\"perf_storage_estimate_caches\",metricType:d.histogram,tags:b,value:t.caches}),Ht({metricName:\"perf_storage_estimate_indexed_db\",metricType:d.histogram,tags:b,value:t.indexedDB});else if(\"CLS\"===r)$t(o.eventName,Vt({action:f.measurement,componentType:m.page,score:100*t||null,vitalsScore:a||null},g)),a&&Ht({metricName:\\`perf_web_vitals_cls_\\${a}\\`,metricType:d.count,tags:b,value:1});else if(\"FID\"===r){const e=(null==n?void 0:n.performanceEntry)||null,r=parseInt((null==e?void 0:e.processingStart)||\"\");$t(o.eventName,Vt({action:f.measurement,componentType:m.page,duration:t||null,processingStart:null!=e&&e.processingStart?r:null,startTime:null!=e&&e.startTime?parseInt(e.startTime):null,vitalsScore:a||null},g)),a&&Ht({metricName:\\`perf_web_vitals_fidVitals_\\${a}\\`,metricType:d.count,tags:b,value:1})}else\"userJourneyStep\"===r?($t(\"perf_user_journey_step\",Vt({action:f.measurement,componentType:m.page,duration:t||null,rating:null!=a?a:null,step_name:(null==n?void 0:n.stepName)||\"\"},g)),Ht({metricName:\\`user_journey_step.\\${A.projectName}.\\${A.platform}.\\${(null==n?void 0:n.stepName)||\"\"}_vitals_\\${a}\\`,metricType:d.count,tags:b,value:1}),Ht({metricName:\\`user_journey_step.\\${A.projectName}.\\${A.platform}.\\${(null==n?void 0:n.stepName)||\"\"}\\`,metricType:d.distribution,tags:b,value:t||null})):I[r]&&t&&($t(o.eventName,Vt({action:f.measurement,componentType:m.page,duration:t||null,vitalsScore:a||null},g)),a&&(Ht({metricName:\\`perf_web_vitals_\\${Xt(r)}_\\${a}\\`,metricType:d.count,tags:b,value:1}),\"LCP\"===r&&Ht({metricName:\\`perf_web_vitals_\\${Xt(r)}\\`,metricType:d.distribution,tags:b,value:t})))},maxMeasureTime:3e4,steps:A.steps,onMarkStep:Zt})}catch(e){e instanceof Error&&A.onError(e)}})()},Tn=e=>{Y(e),e.userAgent&&Z(),lt({metricName:\"Identify:\",data:{countryCode:H.countryCode,deviceId:H.deviceId,userId:H.userId}})},kn=({blacklistRegex:e,pageKeyRegex:t,browserHistory:n})=>{Kt({blacklistRegex:e||[],isEnabled:!0}),ae({pageKeyRegex:t}),on({callMarkNTBT:!1}),n.listen((()=>{on()}))},_n=({blacklistRegex:e,pageKeyRegex:t,nextJsRouter:n})=>{Kt({blacklistRegex:e||[],isEnabled:!0}),ae({pageKeyRegex:t}),on({callMarkNTBT:!1}),n.events.on(\"routeChangeComplete\",(()=>{on()}))},Sn=()=>{Y({isOptOut:!0}),ot(S,{})},En=()=>{Y({isOptOut:!1})},xn={Button:{label:\"cb_button\",uuid:\"e921a074-40e6-4371-8700-134d5cd633e6\",componentType:m.button}};function On(e,t,n){return{componentName:e,actions:t,data:n}}function jn(){return jn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jn.apply(this,arguments)}function Nn(e,t,n){const{componentName:r,data:i}=n;$t(e.label,jn({componentType:e.componentType,action:t,loggingId:e.uuid,component_name:r},i))}const In={actionMapping:{onPress:f.click,onHover:f.hover},handlers:{Button:{[f.click]:e=>Nn(xn.Button,f.click,e),[f.hover]:e=>Nn(xn.Button,f.hover,e)}}};function Pn(e,t=!1){t?_t({url:A.tracesEndpoint,data:{traces:e},isJSON:!0,onError:A.onError}):yt((()=>{_t({url:A.tracesEndpoint,data:{traces:e},isJSON:!0,onError:A.onError})})),ut({metricName:\"Batch Traces\",data:e})}function Mn(){return Mn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Mn.apply(this,arguments)}const Bn=1e6;function Cn(e){return e*Bn}function Dn(e=function(){var e;return null==(e=window)?void 0:e.crypto}()){const t=new Uint32Array(2);return null==e||e.getRandomValues(t),((BigInt(t[0])<<BigInt(32))+BigInt(t[1])).toString()}function An(e,t){return{\"x-datadog-origin\":\"rum\",\"x-datadog-parent-id\":t,\"x-datadog-sampling-priority\":\"1\",\"x-datadog-trace-id\":e}}function Ln(e){var t;const{name:n,traceId:r,spanId:i,start:a,duration:o,resource:s,meta:c}=e;return{duration:o?Cn(o):0,name:n,resource:s,service:A.projectName,span_id:null!=i?i:Dn(),start:a?Cn(a):0,trace_id:null!=r?r:Dn(),parent_id:P,type:M,meta:Mn({platform:A.platform},re.pageKey?{page_key:re.pageKey}:{},null!=(t=Se.ujs)&&t.length?{last_ujs:Se.ujs[Se.ujs.length-1]}:{},null!=c?c:{})}}function Un(e){return[Ln(e)]}function Rn(e,t){Oe()&&function(e){return e.length>0}(e)&&(t&&function(e,t){e.forEach((e=>function(e,t){const n=Mn({},e.meta,t.meta),r={start:t.start?Cn(t.start):e.start,duration:t.duration?Cn(t.duration):e.duration};Object.assign(e,t,Mn({meta:n},r))}(e,t)))}(e,t),je.tracesQueue.push(e),wt(Pn)&&(Pn(je.tracesQueue),je.tracesQueue=[]))}function qn(e){var t=function(e,t){if(\"object\"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,\"string\");if(\"object\"!=typeof r)return r;throw new TypeError(\"@@toPrimitive must return a primitive value.\")}return String(e)}(e);return\"symbol\"==typeof t?t:String(t)}function Fn(){return Fn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Fn.apply(this,arguments)}function zn(){return void 0!==typeof window&&\"performance\"in window&&\"mark\"in performance&&\"getEntriesByName\"in performance}function Kn(e,t){return\\`perf_\\${e}\\${null!=t&&t.label?\\`_\\${t.label}\\`:\"\"}\\`}function $n(e,t,n){return\\`\\${Kn(e,n)}__\\${t}\\`}let Qn={};function Wn(e,t,n){if(!zn())return;const r=$n(e,t,n);if(performance.mark(r),\"end\"===t){const t=Kn(e,n);!function(e,t,n){try{performance.measure(e,t,n)}catch(e){A.onError(e)}}(t,$n(e,\"start\",n),r);const i=performance.getEntriesByName(t).pop();i&&Ht(Fn({metricName:e,metricType:d.distribution,value:i.duration},null!=n&&n.tags?{tags:n.tags}:{}))}}function Hn(e,t){if(!zn())return;const n=$n(e,\"start\",t);Qn[n]||(Wn(e,\"start\",t),Qn[n]=!0)}function Vn(e,t){const n=$n(e,\"start\",t),r=function(e,t){if(null==e)return{};var n,r,i={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(Qn,[n].map(qn));Qn=r}function Jn(e,t){if(!zn())return;const n=$n(e,\"start\",t);Qn[n]&&(Wn(e,\"end\",t),Vn(e,t))}function Xn(){zn()&&(performance.clearMarks(),Qn={})}var Gn=n(784);function Zn(){return Zn=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zn.apply(this,arguments)}function Yn(e,t,n=l.low){const r=(0,Gn.useRef)(t);return(0,Gn.useEffect)((()=>{r.current=t}),[t]),(0,Gn.useCallback)((t=>{$t(e,Zn({},r.current,t),n)}),[e,n])}function er(){return er=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},er.apply(this,arguments)}function tr(e,t,n=l.low){(0,Gn.useEffect)((()=>{const r=er({},t,{action:f.render});$t(e,r,n)}),[])}function nr(){return nr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},nr.apply(this,arguments)}const rr=function(e,t){return{markStartPerf:(0,Gn.useCallback)((()=>Hn(e,t)),[e,t]),markEndPerf:(0,Gn.useCallback)((n=>Jn(e,nr({},t,n))),[e,t])}};function ir(){return ir=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ir.apply(this,arguments)}function ar(){return Object.entries(ir({},Se,zt(),{sessionUUID:oe.sessionUUID,userId:oe.userId})).reduce(((e,t)=>{return null!=(n=t[1])&&\"\"!==n?ir({},e,{[t[0]]:t[1]}):e;var n}),{})}async function or(){return new Promise((e=>{Mt(vt(je.eventsQueue)),Qt(bt(je.metricsQueue),!0),Pn(je.tracesQueue,!0),Ne({eventsQueue:[],metricsQueue:[],tracesQueue:[]}),e()}))}function sr(){return{\"X-CB-Device-ID\":H.deviceId||\"unknown\",\"X-CB-Is-Logged-In\":H.userId?\"true\":\"false\",\"X-CB-Pagekey\":re.pageKey||\"unknown\",\"X-CB-UJS\":(e=Se.ujs,void 0===e||0===e.length?\"\":e.join(\",\")),\"X-CB-Platform\":A.platform||\"unknown\",\"X-CB-Project-Name\":A.projectName||\"unknown\",\"X-CB-Session-UUID\":oe.sessionUUID||\"unknown\",\"X-CB-Version-Name\":A.version?String(A.version):\"unknown\"};var e}})(),r})()}));`;\n//# sourceMappingURL=telemetry-content.js.map","import { store } from '../../store/store.js';\nimport { TELEMETRY_SCRIPT_CONTENT } from './telemetry-content.js';\nexport const loadTelemetryScript = () => {\n return new Promise((resolve, reject) => {\n if (typeof window === 'undefined') {\n reject(new Error('Telemetry is not supported in non-browser environments'));\n return;\n }\n if (window.ClientAnalytics) {\n return resolve();\n }\n try {\n const script = document.createElement('script');\n script.textContent = TELEMETRY_SCRIPT_CONTENT;\n script.type = 'text/javascript';\n document.head.appendChild(script);\n initCCA();\n document.head.removeChild(script);\n resolve();\n }\n catch {\n console.error('Failed to execute inlined telemetry script');\n reject();\n }\n });\n};\nconst initCCA = () => {\n if (typeof window !== 'undefined') {\n const deviceId = store.config.get().deviceId ?? crypto?.randomUUID() ?? '';\n if (window.ClientAnalytics) {\n const { init, identify, PlatformName } = window.ClientAnalytics;\n init({\n isProd: true,\n amplitudeApiKey: 'c66737ad47ec354ced777935b0af822e',\n platform: PlatformName.web,\n projectName: 'base_account_sdk',\n showDebugLogging: false,\n version: '1.0.0',\n apiEndpoint: 'https://cca-lite.coinbase.com',\n });\n identify({ deviceId });\n store.config.set({ deviceId });\n }\n }\n};\n//# sourceMappingURL=initCCA.js.map","/**********************************************************************\n * Constants\n **********************************************************************/\nexport const factoryAddress = '0xba5ed110efdba3d005bfc882d75358acbbb85842';\nexport const spendPermissionManagerAddress = '0xf85210B21cC50302F477BA56686d2019dC9b67Ad';\nexport const abi = [\n { inputs: [], stateMutability: 'nonpayable', type: 'constructor' },\n {\n inputs: [{ name: 'owner', type: 'bytes' }],\n name: 'AlreadyOwner',\n type: 'error',\n },\n { inputs: [], name: 'Initialized', type: 'error' },\n {\n inputs: [{ name: 'owner', type: 'bytes' }],\n name: 'InvalidEthereumAddressOwner',\n type: 'error',\n },\n {\n inputs: [{ name: 'key', type: 'uint256' }],\n name: 'InvalidNonceKey',\n type: 'error',\n },\n {\n inputs: [{ name: 'owner', type: 'bytes' }],\n name: 'InvalidOwnerBytesLength',\n type: 'error',\n },\n { inputs: [], name: 'LastOwner', type: 'error' },\n {\n inputs: [{ name: 'index', type: 'uint256' }],\n name: 'NoOwnerAtIndex',\n type: 'error',\n },\n {\n inputs: [{ name: 'ownersRemaining', type: 'uint256' }],\n name: 'NotLastOwner',\n type: 'error',\n },\n {\n inputs: [{ name: 'selector', type: 'bytes4' }],\n name: 'SelectorNotAllowed',\n type: 'error',\n },\n { inputs: [], name: 'Unauthorized', type: 'error' },\n { inputs: [], name: 'UnauthorizedCallContext', type: 'error' },\n { inputs: [], name: 'UpgradeFailed', type: 'error' },\n {\n inputs: [\n { name: 'index', type: 'uint256' },\n { name: 'expectedOwner', type: 'bytes' },\n { name: 'actualOwner', type: 'bytes' },\n ],\n name: 'WrongOwnerAtIndex',\n type: 'error',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'index',\n type: 'uint256',\n },\n { indexed: false, name: 'owner', type: 'bytes' },\n ],\n name: 'AddOwner',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'index',\n type: 'uint256',\n },\n { indexed: false, name: 'owner', type: 'bytes' },\n ],\n name: 'RemoveOwner',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'implementation',\n type: 'address',\n },\n ],\n name: 'Upgraded',\n type: 'event',\n },\n { stateMutability: 'payable', type: 'fallback' },\n {\n inputs: [],\n name: 'REPLAYABLE_NONCE_KEY',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'owner', type: 'address' }],\n name: 'addOwnerAddress',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { name: 'x', type: 'bytes32' },\n { name: 'y', type: 'bytes32' },\n ],\n name: 'addOwnerPublicKey',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ name: 'functionSelector', type: 'bytes4' }],\n name: 'canSkipChainIdValidation',\n outputs: [{ name: '', type: 'bool' }],\n stateMutability: 'pure',\n type: 'function',\n },\n {\n inputs: [],\n name: 'domainSeparator',\n outputs: [{ name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'eip712Domain',\n outputs: [\n { name: 'fields', type: 'bytes1' },\n { name: 'name', type: 'string' },\n { name: 'version', type: 'string' },\n { name: 'chainId', type: 'uint256' },\n { name: 'verifyingContract', type: 'address' },\n { name: 'salt', type: 'bytes32' },\n { name: 'extensions', type: 'uint256[]' },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'entryPoint',\n outputs: [{ name: '', type: 'address' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'target', type: 'address' },\n { name: 'value', type: 'uint256' },\n { name: 'data', type: 'bytes' },\n ],\n name: 'execute',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'target', type: 'address' },\n { name: 'value', type: 'uint256' },\n { name: 'data', type: 'bytes' },\n ],\n name: 'calls',\n type: 'tuple[]',\n },\n ],\n name: 'executeBatch',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ name: 'calls', type: 'bytes[]' }],\n name: 'executeWithoutChainIdValidation',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n { name: 'callGasLimit', type: 'uint256' },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'maxFeePerGas', type: 'uint256' },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'userOp',\n type: 'tuple',\n },\n ],\n name: 'getUserOpHashWithoutChainId',\n outputs: [{ name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'implementation',\n outputs: [{ name: '$', type: 'address' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'owners', type: 'bytes[]' }],\n name: 'initialize',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'address' }],\n name: 'isOwnerAddress',\n outputs: [{ name: '', type: 'bool' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'bytes' }],\n name: 'isOwnerBytes',\n outputs: [{ name: '', type: 'bool' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'x', type: 'bytes32' },\n { name: 'y', type: 'bytes32' },\n ],\n name: 'isOwnerPublicKey',\n outputs: [{ name: '', type: 'bool' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'hash', type: 'bytes32' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'isValidSignature',\n outputs: [{ name: 'result', type: 'bytes4' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'nextOwnerIndex',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'index', type: 'uint256' }],\n name: 'ownerAtIndex',\n outputs: [{ name: '', type: 'bytes' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'ownerCount',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'proxiableUUID',\n outputs: [{ name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'index', type: 'uint256' },\n { name: 'owner', type: 'bytes' },\n ],\n name: 'removeLastOwner',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { name: 'index', type: 'uint256' },\n { name: 'owner', type: 'bytes' },\n ],\n name: 'removeOwnerAtIndex',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [],\n name: 'removedOwnersCount',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'hash', type: 'bytes32' }],\n name: 'replaySafeHash',\n outputs: [{ name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'newImplementation', type: 'address' },\n { name: 'data', type: 'bytes' },\n ],\n name: 'upgradeToAndCall',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n { name: 'callGasLimit', type: 'uint256' },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'maxFeePerGas', type: 'uint256' },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'userOp',\n type: 'tuple',\n },\n { name: 'userOpHash', type: 'bytes32' },\n { name: 'missingAccountFunds', type: 'uint256' },\n ],\n name: 'validateUserOp',\n outputs: [{ name: 'validationData', type: 'uint256' }],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n { stateMutability: 'payable', type: 'receive' },\n];\nexport const factoryAbi = [\n {\n inputs: [{ name: 'implementation_', type: 'address' }],\n stateMutability: 'payable',\n type: 'constructor',\n },\n { inputs: [], name: 'OwnerRequired', type: 'error' },\n {\n inputs: [\n { name: 'owners', type: 'bytes[]' },\n { name: 'nonce', type: 'uint256' },\n ],\n name: 'createAccount',\n outputs: [\n {\n name: 'account',\n type: 'address',\n },\n ],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [\n { name: 'owners', type: 'bytes[]' },\n { name: 'nonce', type: 'uint256' },\n ],\n name: 'getAddress',\n outputs: [{ name: '', type: 'address' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'implementation',\n outputs: [{ name: '', type: 'address' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'initCodeHash',\n outputs: [{ name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n];\nexport const spendPermissionManagerAbi = [\n {\n type: 'constructor',\n inputs: [\n {\n name: 'publicERC6492Validator',\n type: 'address',\n internalType: 'contract PublicERC6492Validator',\n },\n { name: 'magicSpend', type: 'address', internalType: 'address' },\n ],\n stateMutability: 'nonpayable',\n },\n { type: 'receive', stateMutability: 'payable' },\n {\n type: 'function',\n name: 'MAGIC_SPEND',\n inputs: [],\n outputs: [{ name: '', type: 'address', internalType: 'address' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'NATIVE_TOKEN',\n inputs: [],\n outputs: [{ name: '', type: 'address', internalType: 'address' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'PERMISSION_DETAILS_TYPEHASH',\n inputs: [],\n outputs: [{ name: '', type: 'bytes32', internalType: 'bytes32' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'PUBLIC_ERC6492_VALIDATOR',\n inputs: [],\n outputs: [\n {\n name: '',\n type: 'address',\n internalType: 'contract PublicERC6492Validator',\n },\n ],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'SPEND_PERMISSION_BATCH_TYPEHASH',\n inputs: [],\n outputs: [{ name: '', type: 'bytes32', internalType: 'bytes32' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'SPEND_PERMISSION_TYPEHASH',\n inputs: [],\n outputs: [{ name: '', type: 'bytes32', internalType: 'bytes32' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'approve',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [{ name: '', type: 'bool', internalType: 'bool' }],\n stateMutability: 'nonpayable',\n },\n {\n type: 'function',\n name: 'approveBatchWithSignature',\n inputs: [\n {\n name: 'spendPermissionBatch',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermissionBatch',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n {\n name: 'permissions',\n type: 'tuple[]',\n internalType: 'struct SpendPermissionManager.PermissionDetails[]',\n components: [\n {\n name: 'spender',\n type: 'address',\n internalType: 'address',\n },\n {\n name: 'token',\n type: 'address',\n internalType: 'address',\n },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n {\n name: 'salt',\n type: 'uint256',\n internalType: 'uint256',\n },\n {\n name: 'extraData',\n type: 'bytes',\n internalType: 'bytes',\n },\n ],\n },\n ],\n },\n { name: 'signature', type: 'bytes', internalType: 'bytes' },\n ],\n outputs: [{ name: '', type: 'bool', internalType: 'bool' }],\n stateMutability: 'nonpayable',\n },\n {\n type: 'function',\n name: 'approveWithRevoke',\n inputs: [\n {\n name: 'permissionToApprove',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n {\n name: 'permissionToRevoke',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n {\n name: 'expectedLastUpdatedPeriod',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.PeriodSpend',\n components: [\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'spend', type: 'uint160', internalType: 'uint160' },\n ],\n },\n ],\n outputs: [{ name: '', type: 'bool', internalType: 'bool' }],\n stateMutability: 'nonpayable',\n },\n {\n type: 'function',\n name: 'approveWithSignature',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n { name: 'signature', type: 'bytes', internalType: 'bytes' },\n ],\n outputs: [{ name: '', type: 'bool', internalType: 'bool' }],\n stateMutability: 'nonpayable',\n },\n {\n type: 'function',\n name: 'eip712Domain',\n inputs: [],\n outputs: [\n { name: 'fields', type: 'bytes1', internalType: 'bytes1' },\n { name: 'name', type: 'string', internalType: 'string' },\n { name: 'version', type: 'string', internalType: 'string' },\n { name: 'chainId', type: 'uint256', internalType: 'uint256' },\n {\n name: 'verifyingContract',\n type: 'address',\n internalType: 'address',\n },\n { name: 'salt', type: 'bytes32', internalType: 'bytes32' },\n {\n name: 'extensions',\n type: 'uint256[]',\n internalType: 'uint256[]',\n },\n ],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'getBatchHash',\n inputs: [\n {\n name: 'spendPermissionBatch',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermissionBatch',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n {\n name: 'permissions',\n type: 'tuple[]',\n internalType: 'struct SpendPermissionManager.PermissionDetails[]',\n components: [\n {\n name: 'spender',\n type: 'address',\n internalType: 'address',\n },\n {\n name: 'token',\n type: 'address',\n internalType: 'address',\n },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n {\n name: 'salt',\n type: 'uint256',\n internalType: 'uint256',\n },\n {\n name: 'extraData',\n type: 'bytes',\n internalType: 'bytes',\n },\n ],\n },\n ],\n },\n ],\n outputs: [{ name: '', type: 'bytes32', internalType: 'bytes32' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'getCurrentPeriod',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [\n {\n name: '',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.PeriodSpend',\n components: [\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'spend', type: 'uint160', internalType: 'uint160' },\n ],\n },\n ],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'getHash',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [{ name: '', type: 'bytes32', internalType: 'bytes32' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'getLastUpdatedPeriod',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [\n {\n name: '',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.PeriodSpend',\n components: [\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'spend', type: 'uint160', internalType: 'uint160' },\n ],\n },\n ],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'isApproved',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [{ name: '', type: 'bool', internalType: 'bool' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'isRevoked',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [{ name: '', type: 'bool', internalType: 'bool' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'isValid',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [{ name: '', type: 'bool', internalType: 'bool' }],\n stateMutability: 'view',\n },\n {\n type: 'function',\n name: 'revoke',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [],\n stateMutability: 'nonpayable',\n },\n {\n type: 'function',\n name: 'revokeAsSpender',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n outputs: [],\n stateMutability: 'nonpayable',\n },\n {\n type: 'function',\n name: 'spend',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n { name: 'value', type: 'uint160', internalType: 'uint160' },\n ],\n outputs: [],\n stateMutability: 'nonpayable',\n },\n {\n type: 'function',\n name: 'spendWithWithdraw',\n inputs: [\n {\n name: 'spendPermission',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n { name: 'value', type: 'uint160', internalType: 'uint160' },\n {\n name: 'withdrawRequest',\n type: 'tuple',\n internalType: 'struct MagicSpend.WithdrawRequest',\n components: [\n { name: 'signature', type: 'bytes', internalType: 'bytes' },\n { name: 'asset', type: 'address', internalType: 'address' },\n { name: 'amount', type: 'uint256', internalType: 'uint256' },\n { name: 'nonce', type: 'uint256', internalType: 'uint256' },\n { name: 'expiry', type: 'uint48', internalType: 'uint48' },\n ],\n },\n ],\n outputs: [],\n stateMutability: 'nonpayable',\n },\n {\n type: 'event',\n name: 'SpendPermissionApproved',\n inputs: [\n {\n name: 'hash',\n type: 'bytes32',\n indexed: true,\n internalType: 'bytes32',\n },\n {\n name: 'spendPermission',\n type: 'tuple',\n indexed: false,\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n anonymous: false,\n },\n {\n type: 'event',\n name: 'SpendPermissionRevoked',\n inputs: [\n {\n name: 'hash',\n type: 'bytes32',\n indexed: true,\n internalType: 'bytes32',\n },\n {\n name: 'spendPermission',\n type: 'tuple',\n indexed: false,\n internalType: 'struct SpendPermissionManager.SpendPermission',\n components: [\n { name: 'account', type: 'address', internalType: 'address' },\n { name: 'spender', type: 'address', internalType: 'address' },\n { name: 'token', type: 'address', internalType: 'address' },\n {\n name: 'allowance',\n type: 'uint160',\n internalType: 'uint160',\n },\n { name: 'period', type: 'uint48', internalType: 'uint48' },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'salt', type: 'uint256', internalType: 'uint256' },\n { name: 'extraData', type: 'bytes', internalType: 'bytes' },\n ],\n },\n ],\n anonymous: false,\n },\n {\n type: 'event',\n name: 'SpendPermissionUsed',\n inputs: [\n {\n name: 'hash',\n type: 'bytes32',\n indexed: true,\n internalType: 'bytes32',\n },\n {\n name: 'account',\n type: 'address',\n indexed: true,\n internalType: 'address',\n },\n {\n name: 'spender',\n type: 'address',\n indexed: true,\n internalType: 'address',\n },\n {\n name: 'token',\n type: 'address',\n indexed: false,\n internalType: 'address',\n },\n {\n name: 'periodSpend',\n type: 'tuple',\n indexed: false,\n internalType: 'struct SpendPermissionManager.PeriodSpend',\n components: [\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'spend', type: 'uint160', internalType: 'uint160' },\n ],\n },\n ],\n anonymous: false,\n },\n {\n type: 'error',\n name: 'AfterSpendPermissionEnd',\n inputs: [\n {\n name: 'currentTimestamp',\n type: 'uint48',\n internalType: 'uint48',\n },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n ],\n },\n {\n type: 'error',\n name: 'BeforeSpendPermissionStart',\n inputs: [\n {\n name: 'currentTimestamp',\n type: 'uint48',\n internalType: 'uint48',\n },\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n ],\n },\n {\n type: 'error',\n name: 'ERC721TokenNotSupported',\n inputs: [{ name: 'token', type: 'address', internalType: 'address' }],\n },\n { type: 'error', name: 'EmptySpendPermissionBatch', inputs: [] },\n {\n type: 'error',\n name: 'ExceededSpendPermission',\n inputs: [\n { name: 'value', type: 'uint256', internalType: 'uint256' },\n { name: 'allowance', type: 'uint256', internalType: 'uint256' },\n ],\n },\n {\n type: 'error',\n name: 'InvalidLastUpdatedPeriod',\n inputs: [\n {\n name: 'actualLastUpdatedPeriod',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.PeriodSpend',\n components: [\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'spend', type: 'uint160', internalType: 'uint160' },\n ],\n },\n {\n name: 'expectedLastUpdatedPeriod',\n type: 'tuple',\n internalType: 'struct SpendPermissionManager.PeriodSpend',\n components: [\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n { name: 'spend', type: 'uint160', internalType: 'uint160' },\n ],\n },\n ],\n },\n {\n type: 'error',\n name: 'InvalidSender',\n inputs: [\n { name: 'sender', type: 'address', internalType: 'address' },\n { name: 'expected', type: 'address', internalType: 'address' },\n ],\n },\n { type: 'error', name: 'InvalidSignature', inputs: [] },\n {\n type: 'error',\n name: 'InvalidStartEnd',\n inputs: [\n { name: 'start', type: 'uint48', internalType: 'uint48' },\n { name: 'end', type: 'uint48', internalType: 'uint48' },\n ],\n },\n {\n type: 'error',\n name: 'InvalidWithdrawRequestNonce',\n inputs: [\n {\n name: 'noncePostfix',\n type: 'uint128',\n internalType: 'uint128',\n },\n {\n name: 'permissionHashPostfix',\n type: 'uint128',\n internalType: 'uint128',\n },\n ],\n },\n {\n type: 'error',\n name: 'MismatchedAccounts',\n inputs: [\n {\n name: 'firstAccount',\n type: 'address',\n internalType: 'address',\n },\n {\n name: 'secondAccount',\n type: 'address',\n internalType: 'address',\n },\n ],\n },\n {\n type: 'error',\n name: 'SafeERC20FailedOperation',\n inputs: [{ name: 'token', type: 'address', internalType: 'address' }],\n },\n {\n type: 'error',\n name: 'SpendTokenWithdrawAssetMismatch',\n inputs: [\n { name: 'spendToken', type: 'address', internalType: 'address' },\n {\n name: 'withdrawAsset',\n type: 'address',\n internalType: 'address',\n },\n ],\n },\n {\n type: 'error',\n name: 'SpendValueOverflow',\n inputs: [{ name: 'value', type: 'uint256', internalType: 'uint256' }],\n },\n {\n type: 'error',\n name: 'SpendValueWithdrawAmountMismatch',\n inputs: [\n { name: 'spendValue', type: 'uint256', internalType: 'uint256' },\n {\n name: 'withdrawAmount',\n type: 'uint256',\n internalType: 'uint256',\n },\n ],\n },\n { type: 'error', name: 'UnauthorizedSpendPermission', inputs: [] },\n {\n type: 'error',\n name: 'UnexpectedReceiveAmount',\n inputs: [\n { name: 'received', type: 'uint256', internalType: 'uint256' },\n { name: 'expected', type: 'uint256', internalType: 'uint256' },\n ],\n },\n { type: 'error', name: 'ZeroAllowance', inputs: [] },\n { type: 'error', name: 'ZeroPeriod', inputs: [] },\n { type: 'error', name: 'ZeroSpender', inputs: [] },\n { type: 'error', name: 'ZeroToken', inputs: [] },\n { type: 'error', name: 'ZeroValue', inputs: [] },\n];\n//# sourceMappingURL=constants.js.map","export const standardErrorCodes = {\n rpc: {\n invalidInput: -32000,\n resourceNotFound: -32001,\n resourceUnavailable: -32002,\n transactionRejected: -32003,\n methodNotSupported: -32004,\n limitExceeded: -32005,\n parse: -32700,\n invalidRequest: -32600,\n methodNotFound: -32601,\n invalidParams: -32602,\n internal: -32603,\n },\n provider: {\n userRejectedRequest: 4001,\n unauthorized: 4100,\n unsupportedMethod: 4200,\n disconnected: 4900,\n chainDisconnected: 4901,\n unsupportedChain: 4902,\n },\n};\nexport const errorValues = {\n '-32700': {\n standard: 'JSON RPC 2.0',\n message: 'Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text.',\n },\n '-32600': {\n standard: 'JSON RPC 2.0',\n message: 'The JSON sent is not a valid Request object.',\n },\n '-32601': {\n standard: 'JSON RPC 2.0',\n message: 'The method does not exist / is not available.',\n },\n '-32602': {\n standard: 'JSON RPC 2.0',\n message: 'Invalid method parameter(s).',\n },\n '-32603': {\n standard: 'JSON RPC 2.0',\n message: 'Internal JSON-RPC error.',\n },\n '-32000': {\n standard: 'EIP-1474',\n message: 'Invalid input.',\n },\n '-32001': {\n standard: 'EIP-1474',\n message: 'Resource not found.',\n },\n '-32002': {\n standard: 'EIP-1474',\n message: 'Resource unavailable.',\n },\n '-32003': {\n standard: 'EIP-1474',\n message: 'Transaction rejected.',\n },\n '-32004': {\n standard: 'EIP-1474',\n message: 'Method not supported.',\n },\n '-32005': {\n standard: 'EIP-1474',\n message: 'Request limit exceeded.',\n },\n '4001': {\n standard: 'EIP-1193',\n message: 'User rejected the request.',\n },\n '4100': {\n standard: 'EIP-1193',\n message: 'The requested account and/or method has not been authorized by the user.',\n },\n '4200': {\n standard: 'EIP-1193',\n message: 'The requested method is not supported by this Ethereum provider.',\n },\n '4900': {\n standard: 'EIP-1193',\n message: 'The provider is disconnected from all chains.',\n },\n '4901': {\n standard: 'EIP-1193',\n message: 'The provider is disconnected from the specified chain.',\n },\n '4902': {\n standard: 'EIP-3085',\n message: 'Unrecognized chain ID.',\n },\n};\n//# sourceMappingURL=constants.js.map","import { errorValues, standardErrorCodes } from './constants.js';\nconst FALLBACK_MESSAGE = 'Unspecified error message.';\nexport const JSON_RPC_SERVER_ERROR_MESSAGE = 'Unspecified server error.';\n/**\n * Gets the message for a given code, or a fallback message if the code has\n * no corresponding message.\n */\nexport function getMessageFromCode(code, fallbackMessage = FALLBACK_MESSAGE) {\n if (code && Number.isInteger(code)) {\n const codeString = code.toString();\n if (hasKey(errorValues, codeString)) {\n return errorValues[codeString].message;\n }\n if (isJsonRpcServerError(code)) {\n return JSON_RPC_SERVER_ERROR_MESSAGE;\n }\n }\n return fallbackMessage;\n}\n/**\n * Returns whether the given code is valid.\n * A code is only valid if it has a message.\n */\nexport function isValidCode(code) {\n if (!Number.isInteger(code)) {\n return false;\n }\n const codeString = code.toString();\n if (errorValues[codeString]) {\n return true;\n }\n if (isJsonRpcServerError(code)) {\n return true;\n }\n return false;\n}\n/**\n * Returns the error code from an error object.\n */\nexport function getErrorCode(error) {\n if (typeof error === 'number') {\n return error;\n }\n if (isErrorWithCode(error)) {\n return error.code ?? error.errorCode;\n }\n return undefined;\n}\nfunction isErrorWithCode(error) {\n return (typeof error === 'object' &&\n error !== null &&\n (typeof error.code === 'number' ||\n typeof error.errorCode === 'number'));\n}\nexport function serialize(error, { shouldIncludeStack = false } = {}) {\n const serialized = {};\n if (error &&\n typeof error === 'object' &&\n !Array.isArray(error) &&\n hasKey(error, 'code') &&\n isValidCode(error.code)) {\n const _error = error;\n serialized.code = _error.code;\n if (_error.message && typeof _error.message === 'string') {\n serialized.message = _error.message;\n if (hasKey(_error, 'data')) {\n serialized.data = _error.data;\n }\n }\n else {\n serialized.message = getMessageFromCode(serialized.code);\n serialized.data = { originalError: assignOriginalError(error) };\n }\n }\n else {\n serialized.code = standardErrorCodes.rpc.internal;\n serialized.message = hasStringProperty(error, 'message') ? error.message : FALLBACK_MESSAGE;\n serialized.data = { originalError: assignOriginalError(error) };\n }\n if (shouldIncludeStack) {\n serialized.stack = hasStringProperty(error, 'stack') ? error.stack : undefined;\n }\n return serialized;\n}\n// Internal\nfunction isJsonRpcServerError(code) {\n return code >= -32099 && code <= -32000;\n}\nfunction assignOriginalError(error) {\n if (error && typeof error === 'object' && !Array.isArray(error)) {\n return Object.assign({}, error);\n }\n return error;\n}\nfunction hasKey(obj, key) {\n return Object.prototype.hasOwnProperty.call(obj, key);\n}\nfunction hasStringProperty(obj, prop) {\n return (typeof obj === 'object' && obj !== null && prop in obj && typeof obj[prop] === 'string');\n}\n//# sourceMappingURL=utils.js.map","import { standardErrorCodes } from './constants.js';\nimport { getMessageFromCode } from './utils.js';\nexport const standardErrors = {\n rpc: {\n parse: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.parse, arg),\n invalidRequest: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.invalidRequest, arg),\n invalidParams: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.invalidParams, arg),\n methodNotFound: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.methodNotFound, arg),\n internal: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.internal, arg),\n server: (opts) => {\n if (!opts || typeof opts !== 'object' || Array.isArray(opts)) {\n throw new Error('Ethereum RPC Server errors must provide single object argument.');\n }\n const { code } = opts;\n if (!Number.isInteger(code) || code > -32005 || code < -32099) {\n throw new Error('\"code\" must be an integer such that: -32099 <= code <= -32005');\n }\n return getEthJsonRpcError(code, opts);\n },\n invalidInput: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.invalidInput, arg),\n resourceNotFound: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.resourceNotFound, arg),\n resourceUnavailable: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.resourceUnavailable, arg),\n transactionRejected: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.transactionRejected, arg),\n methodNotSupported: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.methodNotSupported, arg),\n limitExceeded: (arg) => getEthJsonRpcError(standardErrorCodes.rpc.limitExceeded, arg),\n },\n provider: {\n userRejectedRequest: (arg) => {\n return getEthProviderError(standardErrorCodes.provider.userRejectedRequest, arg);\n },\n unauthorized: (arg) => {\n return getEthProviderError(standardErrorCodes.provider.unauthorized, arg);\n },\n unsupportedMethod: (arg) => {\n return getEthProviderError(standardErrorCodes.provider.unsupportedMethod, arg);\n },\n disconnected: (arg) => {\n return getEthProviderError(standardErrorCodes.provider.disconnected, arg);\n },\n chainDisconnected: (arg) => {\n return getEthProviderError(standardErrorCodes.provider.chainDisconnected, arg);\n },\n unsupportedChain: (arg) => {\n return getEthProviderError(standardErrorCodes.provider.unsupportedChain, arg);\n },\n custom: (opts) => {\n if (!opts || typeof opts !== 'object' || Array.isArray(opts)) {\n throw new Error('Ethereum Provider custom errors must provide single object argument.');\n }\n const { code, message, data } = opts;\n if (!message || typeof message !== 'string') {\n throw new Error('\"message\" must be a nonempty string');\n }\n return new EthereumProviderError(code, message, data);\n },\n },\n};\n// Internal\nfunction getEthJsonRpcError(code, arg) {\n const [message, data] = parseOpts(arg);\n return new EthereumRpcError(code, message || getMessageFromCode(code), data);\n}\nfunction getEthProviderError(code, arg) {\n const [message, data] = parseOpts(arg);\n return new EthereumProviderError(code, message || getMessageFromCode(code), data);\n}\nfunction parseOpts(arg) {\n if (arg) {\n if (typeof arg === 'string') {\n return [arg];\n }\n if (typeof arg === 'object' && !Array.isArray(arg)) {\n const { message, data } = arg;\n if (message && typeof message !== 'string') {\n throw new Error('Must specify string message.');\n }\n return [message || undefined, data];\n }\n }\n return [];\n}\nclass EthereumRpcError extends Error {\n code;\n data;\n constructor(code, message, data) {\n if (!Number.isInteger(code)) {\n throw new Error('\"code\" must be an integer.');\n }\n if (!message || typeof message !== 'string') {\n throw new Error('\"message\" must be a nonempty string.');\n }\n super(message);\n this.code = code;\n if (data !== undefined) {\n this.data = data;\n }\n }\n}\nclass EthereumProviderError extends EthereumRpcError {\n /**\n * Create an Ethereum Provider JSON-RPC error.\n * `code` must be an integer in the 1000 <= 4999 range.\n */\n constructor(code, message, data) {\n if (!isValidEthProviderCode(code)) {\n throw new Error('\"code\" must be an integer such that: 1000 <= code <= 4999');\n }\n super(code, message, data);\n }\n}\nclass ActionableInsufficientBalanceError extends EthereumRpcError {\n}\nfunction isValidEthProviderCode(code) {\n return Number.isInteger(code) && code >= 1000 && code <= 4999;\n}\nexport function isActionableHttpRequestError(errorObject) {\n return (typeof errorObject === 'object' &&\n errorObject !== null &&\n 'code' in errorObject &&\n 'data' in errorObject &&\n errorObject.code === -32090 &&\n typeof errorObject.data === 'object' &&\n errorObject.data !== null &&\n 'type' in errorObject.data &&\n errorObject.data.type === 'INSUFFICIENT_FUNDS');\n}\nexport function isViemError(error) {\n // Check if object and has code, message, and details\n return typeof error === 'object' && error !== null && 'details' in error;\n}\nexport function viemHttpErrorToProviderError(error) {\n try {\n const details = JSON.parse(error.details);\n return new EthereumRpcError(details.code, details.message, details.data);\n }\n catch (_) {\n return null;\n }\n}\n//# sourceMappingURL=errors.js.map","import { standardErrors } from '../core/error/errors.js';\nexport function assertPresence(value, error, message) {\n if (value === null || value === undefined) {\n throw (error ??\n standardErrors.rpc.invalidParams({\n message: message ?? 'value must be present',\n data: value,\n }));\n }\n}\nexport function assertArrayPresence(value, message) {\n if (!Array.isArray(value)) {\n throw standardErrors.rpc.invalidParams({\n message: message ?? 'value must be an array',\n data: value,\n });\n }\n}\n//# sourceMappingURL=assertPresence.js.map","const COOP_ERROR_MESSAGE = `Base Account SDK requires the Cross-Origin-Opener-Policy header to not be set to 'same-origin'. This is to ensure that the SDK can communicate with the Base Account app.\n\nPlease see https://docs.base.org/smart-wallet/quickstart#cross-origin-opener-policy for more information.`;\n/**\n * Creates a checker for the Cross-Origin-Opener-Policy (COOP).\n *\n * @returns An object with methods to get and check the Cross-Origin-Opener-Policy.\n *\n * @method getCrossOriginOpenerPolicy\n * Retrieves current Cross-Origin-Opener-Policy.\n * @throws Will throw an error if the policy has not been checked yet.\n *\n * @method checkCrossOriginOpenerPolicy\n * Checks the Cross-Origin-Opener-Policy of the current environment.\n * If in a non-browser environment, sets the policy to 'non-browser-env'.\n * If in a browser environment, fetches the policy from the current origin.\n * Logs an error if the policy is 'same-origin'.\n */\nconst createCoopChecker = () => {\n let crossOriginOpenerPolicy;\n return {\n getCrossOriginOpenerPolicy: () => {\n if (crossOriginOpenerPolicy === undefined) {\n return 'undefined';\n }\n return crossOriginOpenerPolicy;\n },\n checkCrossOriginOpenerPolicy: async () => {\n if (typeof window === 'undefined') {\n // Non-browser environment\n crossOriginOpenerPolicy = 'non-browser-env';\n return;\n }\n try {\n const url = `${window.location.origin}${window.location.pathname}`;\n const response = await fetch(url, {\n method: 'HEAD',\n });\n if (!response.ok) {\n throw new Error(`HTTP error! status: ${response.status}`);\n }\n const result = response.headers.get('Cross-Origin-Opener-Policy');\n crossOriginOpenerPolicy = result ?? 'null';\n if (crossOriginOpenerPolicy === 'same-origin') {\n console.error(COOP_ERROR_MESSAGE);\n }\n }\n catch (error) {\n console.error('Error checking Cross-Origin-Opener-Policy:', error.message);\n crossOriginOpenerPolicy = 'error';\n }\n },\n };\n};\nexport const { checkCrossOriginOpenerPolicy, getCrossOriginOpenerPolicy } = createCoopChecker();\n//# sourceMappingURL=checkCrossOriginOpenerPolicy.js.map","/**\n * Validates user supplied preferences. Throws if keys are not valid.\n * @param preference\n */\nexport function validatePreferences(preference) {\n if (!preference) {\n return;\n }\n if (preference.attribution) {\n if (preference.attribution.auto !== undefined &&\n preference.attribution.dataSuffix !== undefined) {\n throw new Error(`Attribution cannot contain both auto and dataSuffix properties`);\n }\n }\n if (preference.telemetry) {\n if (typeof preference.telemetry !== 'boolean') {\n throw new Error(`Telemetry must be a boolean`);\n }\n }\n}\n/**\n * Validates user supplied toSubAccountSigner function. Throws if keys are not valid.\n * @param toAccount\n */\nexport function validateSubAccount(toAccount) {\n if (typeof toAccount !== 'function') {\n throw new Error(`toAccount is not a function`);\n }\n}\n//# sourceMappingURL=validatePreferences.js.map","import { PACKAGE_NAME, PACKAGE_VERSION } from '../constants.js';\nimport { store } from '../../store/store.js';\nvar ComponentType;\n(function (ComponentType) {\n ComponentType[\"unknown\"] = \"unknown\";\n ComponentType[\"banner\"] = \"banner\";\n ComponentType[\"button\"] = \"button\";\n ComponentType[\"card\"] = \"card\";\n ComponentType[\"chart\"] = \"chart\";\n ComponentType[\"content_script\"] = \"content_script\";\n ComponentType[\"dropdown\"] = \"dropdown\";\n ComponentType[\"link\"] = \"link\";\n ComponentType[\"page\"] = \"page\";\n ComponentType[\"modal\"] = \"modal\";\n ComponentType[\"table\"] = \"table\";\n ComponentType[\"search_bar\"] = \"search_bar\";\n ComponentType[\"service_worker\"] = \"service_worker\";\n ComponentType[\"text\"] = \"text\";\n ComponentType[\"text_input\"] = \"text_input\";\n ComponentType[\"tray\"] = \"tray\";\n ComponentType[\"checkbox\"] = \"checkbox\";\n ComponentType[\"icon\"] = \"icon\";\n})(ComponentType || (ComponentType = {}));\nvar ActionType;\n(function (ActionType) {\n ActionType[\"unknown\"] = \"unknown\";\n ActionType[\"blur\"] = \"blur\";\n ActionType[\"click\"] = \"click\";\n ActionType[\"change\"] = \"change\";\n ActionType[\"dismiss\"] = \"dismiss\";\n ActionType[\"focus\"] = \"focus\";\n ActionType[\"hover\"] = \"hover\";\n ActionType[\"select\"] = \"select\";\n ActionType[\"measurement\"] = \"measurement\";\n ActionType[\"move\"] = \"move\";\n ActionType[\"process\"] = \"process\";\n ActionType[\"render\"] = \"render\";\n ActionType[\"scroll\"] = \"scroll\";\n ActionType[\"view\"] = \"view\";\n ActionType[\"search\"] = \"search\";\n ActionType[\"keyPress\"] = \"keyPress\";\n ActionType[\"error\"] = \"error\";\n})(ActionType || (ActionType = {}));\nvar AnalyticsEventImportance;\n(function (AnalyticsEventImportance) {\n AnalyticsEventImportance[\"low\"] = \"low\";\n AnalyticsEventImportance[\"high\"] = \"high\";\n})(AnalyticsEventImportance || (AnalyticsEventImportance = {}));\nexport function logEvent(name, event, importance) {\n // ClientAnalytics only works in the browser environment\n if (typeof window !== 'undefined' && window.ClientAnalytics) {\n window.ClientAnalytics?.logEvent(name, {\n ...event,\n sdkVersion: PACKAGE_VERSION,\n sdkName: PACKAGE_NAME,\n appName: store.config.get().metadata?.appName ?? '',\n appOrigin: window.location.origin,\n }, importance);\n }\n}\nexport function identify(event) {\n if (window.ClientAnalytics) {\n window.ClientAnalytics?.identify(event);\n }\n}\nexport { ActionType, AnalyticsEventImportance, ComponentType };\n//# sourceMappingURL=logEvent.js.map","import { ActionType, AnalyticsEventImportance, ComponentType, logEvent } from '../logEvent.js';\nexport const logPopupSetupStarted = () => {\n logEvent('communicator.popup_setup.started', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n }, AnalyticsEventImportance.high);\n};\nexport const logPopupSetupCompleted = () => {\n logEvent('communicator.popup_setup.completed', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n }, AnalyticsEventImportance.high);\n};\nexport const logPopupUnloadReceived = () => {\n logEvent('communicator.popup_unload.received', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n }, AnalyticsEventImportance.high);\n};\n//# sourceMappingURL=communicator.js.map","import { ActionType, AnalyticsEventImportance, ComponentType, logEvent } from '../logEvent.js';\nexport const logDialogShown = ({ dialogContext }) => {\n logEvent(`dialog.${dialogContext}.shown`, {\n action: ActionType.render,\n componentType: ComponentType.modal,\n dialogContext,\n }, AnalyticsEventImportance.high);\n};\nexport const logDialogDismissed = ({ dialogContext }) => {\n logEvent(`dialog.${dialogContext}.dismissed`, {\n action: ActionType.dismiss,\n componentType: ComponentType.modal,\n dialogContext,\n }, AnalyticsEventImportance.high);\n};\nexport const logDialogActionClicked = ({ dialogContext, dialogAction, }) => {\n logEvent(`dialog.${dialogContext}.action_clicked`, {\n action: ActionType.click,\n componentType: ComponentType.button,\n dialogContext,\n dialogAction,\n }, AnalyticsEventImportance.high);\n};\n//# sourceMappingURL=dialog.js.map","export const FONT_FACE_CSS = `\n@font-face {\n font-family: \"BaseSans-Regular\";\n src: url(\"data:font/woff2;charset=utf-8;base64,d09GMgABAAAAAJigAA8AAAACCywAAJg8AAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAP0ZGVE0cGoIuG4L7BhzCdAZgAJIGEQgKg+k0gv4NC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5iIbyL6xxlDU1z1Ondoq5WK/TiBmGFViZDOT9TXHjq9J/1n/df9F/2X2XX2eLqMYT6Bda7m7tPU7tesjePu86yzG/3v77fxWK6k+sviyhq2vJhA9bGk3/X5eN/AAAA\")\n format(\"woff2\");\n font-weight: normal;\n font-style: normal;\n font-display: swap;\n}\n`;\n//# sourceMappingURL=fontFaceCSS.js.map","import { FONT_FACE_CSS } from './fontFaceCSS.js';\nconst FONT_NAME = 'BaseSans-Regular';\nexport function injectFontStyle() {\n const existing = document.head.querySelector(`style[base-sdk-font=\"${FONT_NAME}\"]`);\n if (existing)\n return;\n const style = document.createElement('style');\n style.setAttribute('base-sdk-font', FONT_NAME);\n style.textContent = FONT_FACE_CSS;\n document.head.appendChild(style);\n}\n//# sourceMappingURL=injectFontStyle.js.map","var n,l,u,t,i,o,r,f,e,c,s,a,h={},v=[],p=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,y=Array.isArray;function d(n,l){for(var u in l)n[u]=l[u];return n}function w(n){n&&n.parentNode&&n.parentNode.removeChild(n)}function _(l,u,t){var i,o,r,f={};for(r in u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),\"function\"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return g(l,f,i,o,null)}function g(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++u:r,__i:-1,__u:0};return null==r&&null!=l.vnode&&l.vnode(f),f}function m(){return{current:null}}function b(n){return n.children}function k(n,l){this.props=n,this.context=l}function x(n,l){if(null==l)return n.__?x(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return\"function\"==typeof n.type?x(n):null}function C(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return C(n)}}function M(n){(!n.__d&&(n.__d=!0)&&i.push(n)&&!P.__r++||o!==l.debounceRendering)&&((o=l.debounceRendering)||r)(P)}function P(){var n,u,t,o,r,e,c,s;for(i.sort(f);n=i.shift();)n.__d&&(u=i.length,o=void 0,e=(r=(t=n).__v).__e,c=[],s=[],t.__P&&((o=d({},r)).__v=r.__v+1,l.vnode&&l.vnode(o),O(t.__P,o,r,t.__n,t.__P.namespaceURI,32&r.__u?[e]:null,c,null==e?x(r):e,!!(32&r.__u),s),o.__v=r.__v,o.__.__k[o.__i]=o,j(c,o,s),o.__e!=e&&C(o)),i.length>u&&i.sort(f));P.__r=0}function S(n,l,u,t,i,o,r,f,e,c,s){var a,p,y,d,w,_=t&&t.__k||v,g=l.length;for(u.__d=e,$(u,l,_),e=u.__d,a=0;a<g;a++)null!=(y=u.__k[a])&&(p=-1===y.__i?h:_[y.__i]||h,y.__i=a,O(n,y,p,i,o,r,f,e,c,s),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&N(p.ref,null,y),s.push(y.ref,y.__c||d,y)),null==w&&null!=d&&(w=d),65536&y.__u||p.__k===y.__k?e=I(y,e,n):\"function\"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=w}function $(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)null!=(i=l[t])&&\"boolean\"!=typeof i&&\"function\"!=typeof i?(r=t+a,(i=n.__k[t]=\"string\"==typeof i||\"number\"==typeof i||\"bigint\"==typeof i||i.constructor==String?g(null,i,null,null,null):y(i)?g(b,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?g(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i).__=n,i.__b=n.__b+1,o=null,-1!==(f=i.__i=L(i,u,r,s))&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,\"function\"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f==r-1?a--:f==r+1?a++:(f>r?a--:a++,i.__u|=65536))):i=n.__k[t]=null;if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=x(o)),V(o,o))}function I(n,l,u){var t,i;if(\"function\"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=I(t[i],l,u));return l}n.__e!=l&&(l&&n.type&&!u.contains(l)&&(l=x(n)),u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling}while(null!=l&&8===l.nodeType);return l}function H(n,l){return l=l||[],null==n||\"boolean\"==typeof n||(y(n)?n.some(function(n){H(n,l)}):l.push(n)),l}function L(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++}}return-1}function T(n,l,u){\"-\"===l[0]?n.setProperty(l,null==u?\"\":u):n[l]=null==u?\"\":\"number\"!=typeof u||p.test(l)?u:u+\"px\"}function A(n,l,u,t,i){var o;n:if(\"style\"===l)if(\"string\"==typeof u)n.style.cssText=u;else{if(\"string\"==typeof t&&(n.style.cssText=t=\"\"),t)for(l in t)u&&l in u||T(n.style,l,\"\");if(u)for(l in u)t&&u[l]===t[l]||T(n.style,l,u[l])}else if(\"o\"===l[0]&&\"n\"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,\"$1\")),l=l.toLowerCase()in n||\"onFocusOut\"===l||\"onFocusIn\"===l?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=e,n.addEventListener(l,o?s:c,o)):n.removeEventListener(l,o?s:c,o);else{if(\"http://www.w3.org/2000/svg\"==i)l=l.replace(/xlink(H|:h)/,\"h\").replace(/sName$/,\"s\");else if(\"width\"!=l&&\"height\"!=l&&\"href\"!=l&&\"list\"!=l&&\"form\"!=l&&\"tabIndex\"!=l&&\"download\"!=l&&\"rowSpan\"!=l&&\"colSpan\"!=l&&\"role\"!=l&&\"popover\"!=l&&l in n)try{n[l]=null==u?\"\":u;break n}catch(n){}\"function\"==typeof u||(null==u||!1===u&&\"-\"!==l[4]?n.removeAttribute(l):n.setAttribute(l,\"popover\"==l&&1==u?\"\":u))}}function F(n){return function(u){if(this.l){var t=this.l[u.type+n];if(null==u.t)u.t=e++;else if(u.t<t.u)return;return t(l.event?l.event(u):u)}}}function O(n,u,t,i,o,r,f,e,c,s){var a,h,v,p,w,_,g,m,x,C,M,P,$,I,H,L,T=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l.__b)&&a(u);n:if(\"function\"==typeof T)try{if(m=u.props,x=\"prototype\"in T&&T.prototype.render,C=(a=T.contextType)&&i[a.__c],M=a?C?C.props.value:a.__:i,t.__c?g=(h=u.__c=t.__c).__=h.__E:(x?u.__c=h=new T(m,M):(u.__c=h=new k(m,M),h.constructor=T,h.render=q),C&&C.sub(h),h.props=m,h.state||(h.state={}),h.context=M,h.__n=i,v=h.__d=!0,h.__h=[],h._sb=[]),x&&null==h.__s&&(h.__s=h.state),x&&null!=T.getDerivedStateFromProps&&(h.__s==h.state&&(h.__s=d({},h.__s)),d(h.__s,T.getDerivedStateFromProps(m,h.__s))),p=h.props,w=h.state,h.__v=u,v)x&&null==T.getDerivedStateFromProps&&null!=h.componentWillMount&&h.componentWillMount(),x&&null!=h.componentDidMount&&h.__h.push(h.componentDidMount);else{if(x&&null==T.getDerivedStateFromProps&&m!==p&&null!=h.componentWillReceiveProps&&h.componentWillReceiveProps(m,M),!h.__e&&(null!=h.shouldComponentUpdate&&!1===h.shouldComponentUpdate(m,h.__s,M)||u.__v===t.__v)){for(u.__v!==t.__v&&(h.props=m,h.state=h.__s,h.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.some(function(n){n&&(n.__=u)}),P=0;P<h._sb.length;P++)h.__h.push(h._sb[P]);h._sb=[],h.__h.length&&f.push(h);break n}null!=h.componentWillUpdate&&h.componentWillUpdate(m,h.__s,M),x&&null!=h.componentDidUpdate&&h.__h.push(function(){h.componentDidUpdate(p,w,_)})}if(h.context=M,h.props=m,h.__P=n,h.__e=!1,$=l.__r,I=0,x){for(h.state=h.__s,h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),H=0;H<h._sb.length;H++)h.__h.push(h._sb[H]);h._sb=[]}else do{h.__d=!1,$&&$(u),a=h.render(h.props,h.state,h.context),h.state=h.__s}while(h.__d&&++I<25);h.state=h.__s,null!=h.getChildContext&&(i=d(d({},i),h.getChildContext())),x&&!v&&null!=h.getSnapshotBeforeUpdate&&(_=h.getSnapshotBeforeUpdate(p,w)),S(n,y(L=null!=a&&a.type===b&&null==a.key?a.props.children:a)?L:[L],u,t,i,o,r,f,e,c,s),h.base=u.__e,u.__u&=-161,h.__h.length&&f.push(h),g&&(h.__E=h.__=null)}catch(n){if(u.__v=null,c||null!=r){for(u.__u|=c?160:32;e&&8===e.nodeType&&e.nextSibling;)e=e.nextSibling;r[r.indexOf(e)]=null,u.__e=e}else u.__e=t.__e,u.__k=t.__k;l.__e(n,u,t)}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z(t.__e,u,t,i,o,r,f,c,s);(a=l.diffed)&&a(u)}function j(n,u,t){u.__d=void 0;for(var i=0;i<t.length;i++)N(t[i],t[++i],t[++i]);l.__c&&l.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u)})}catch(n){l.__e(n,u.__v)}})}function z(u,t,i,o,r,f,e,c,s){var a,v,p,d,_,g,m,b=i.props,k=t.props,C=t.type;if(\"svg\"===C?r=\"http://www.w3.org/2000/svg\":\"math\"===C?r=\"http://www.w3.org/1998/Math/MathML\":r||(r=\"http://www.w3.org/1999/xhtml\"),null!=f)for(a=0;a<f.length;a++)if((_=f[a])&&\"setAttribute\"in _==!!C&&(C?_.localName===C:3===_.nodeType)){u=_,f[a]=null;break}if(null==u){if(null===C)return document.createTextNode(k);u=document.createElementNS(r,C,k.is&&k),c&&(l.__m&&l.__m(t,f),c=!1),f=null}if(null===C)b===k||c&&u.data===k||(u.data=k);else{if(f=f&&n.call(u.childNodes),b=i.props||h,!c&&null!=f)for(b={},a=0;a<u.attributes.length;a++)b[(_=u.attributes[a]).name]=_.value;for(a in b)if(_=b[a],\"children\"==a);else if(\"dangerouslySetInnerHTML\"==a)p=_;else if(!(a in k)){if(\"value\"==a&&\"defaultValue\"in k||\"checked\"==a&&\"defaultChecked\"in k)continue;A(u,a,null,_,r)}for(a in k)_=k[a],\"children\"==a?d=_:\"dangerouslySetInnerHTML\"==a?v=_:\"value\"==a?g=_:\"checked\"==a?m=_:c&&\"function\"!=typeof _||b[a]===_||A(u,a,_,b[a],r);if(v)c||p&&(v.__html===p.__html||v.__html===u.innerHTML)||(u.innerHTML=v.__html),t.__k=[];else if(p&&(u.innerHTML=\"\"),S(u,y(d)?d:[d],t,i,o,\"foreignObject\"===C?\"http://www.w3.org/1999/xhtml\":r,f,e,f?f[0]:i.__k&&x(i,0),c,s),null!=f)for(a=f.length;a--;)w(f[a]);c||(a=\"value\",\"progress\"===C&&null==g?u.removeAttribute(\"value\"):void 0!==g&&(g!==u[a]||\"progress\"===C&&!g||\"option\"===C&&g!==b[a])&&A(u,a,g,b[a],r),a=\"checked\",void 0!==m&&m!==u[a]&&A(u,a,m,b[a],r))}return u}function N(n,u,t){try{if(\"function\"==typeof n){var i=\"function\"==typeof n.__u;i&&n.__u(),i&&null==u||(n.__u=n(u))}else n.current=u}catch(n){l.__e(n,t)}}function V(n,u,t){var i,o;if(l.unmount&&l.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||N(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount()}catch(n){l.__e(n,u)}i.base=i.__P=null}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&V(i[o],u,t||\"function\"!=typeof n.type);t||w(n.__e),n.__c=n.__=n.__e=n.__d=void 0}function q(n,l,u){return this.constructor(n,u)}function B(u,t,i){var o,r,f,e;l.__&&l.__(u,t),r=(o=\"function\"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],O(t,u=(!o&&i||t).__k=_(b,null,[u]),r||h,h,t.namespaceURI,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),j(f,u,e)}function D(n,l){B(n,l,D)}function E(l,u,t){var i,o,r,f,e=d({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)\"key\"==r?i=u[r]:\"ref\"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),g(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l=\"__cC\"+a++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.componentWillUnmount=function(){u=null},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,M(n)})},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u&&u.splice(u.indexOf(n),1),l&&l.call(n)}}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=v.slice,l={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l}throw n}},u=0,t=function(n){return null!=n&&null==n.constructor},k.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),\"function\"==typeof n&&(n=n(d({},u),this.props)),n&&d(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),M(this))},k.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),M(this))},k.prototype.render=b,i=[],r=\"function\"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,f=function(n,l){return n.__v.__b-l.__v.__b},P.__r=0,e=0,c=F(!1),s=F(!0),a=0;export{k as Component,b as Fragment,E as cloneElement,G as createContext,_ as createElement,m as createRef,_ as h,D as hydrate,t as isValidElement,l as options,B as render,H as toChildArray};\n//# sourceMappingURL=preact.module.js.map\n","import{options as r,Fragment as e}from\"preact\";export{Fragment}from\"preact\";var t=/[\"&<]/;function n(r){if(0===r.length||!1===t.test(r))return r;for(var e=0,n=0,o=\"\",f=\"\";n<r.length;n++){switch(r.charCodeAt(n)){case 34:f=\""\";break;case 38:f=\"&\";break;case 60:f=\"<\";break;default:continue}n!==e&&(o+=r.slice(e,n)),o+=f,e=n+1}return n!==e&&(o+=r.slice(e,n)),o}var o=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,f=0,i=Array.isArray;function u(e,t,n,o,i,u){t||(t={});var a,c,l=t;\"ref\"in t&&(a=t.ref,delete t.ref);var p={type:e,props:l,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--f,__i:-1,__u:0,__source:i,__self:u};if(\"function\"==typeof e&&(a=e.defaultProps))for(c in a)void 0===l[c]&&(l[c]=a[c]);return r.vnode&&r.vnode(p),p}function a(r){var t=u(e,{tpl:r,exprs:[].slice.call(arguments,1)});return t.key=t.__v,t}var c={},l=/[A-Z]/g;function p(e,t){if(r.attr){var f=r.attr(e,t);if(\"string\"==typeof f)return f}if(\"ref\"===e||\"key\"===e)return\"\";if(\"style\"===e&&\"object\"==typeof t){var i=\"\";for(var u in t){var a=t[u];if(null!=a&&\"\"!==a){var p=\"-\"==u[0]?u:c[u]||(c[u]=u.replace(l,\"-$&\").toLowerCase()),_=\";\";\"number\"!=typeof a||p.startsWith(\"--\")||o.test(p)||(_=\"px;\"),i=i+p+\":\"+a+_}}return e+'=\"'+i+'\"'}return null==t||!1===t||\"function\"==typeof t||\"object\"==typeof t?\"\":!0===t?e:e+'=\"'+n(t)+'\"'}function _(r){if(null==r||\"boolean\"==typeof r||\"function\"==typeof r)return null;if(\"object\"==typeof r){if(void 0===r.constructor)return r;if(i(r)){for(var e=0;e<r.length;e++)r[e]=_(r[e]);return r}}return n(\"\"+r)}export{u as jsx,p as jsxAttr,u as jsxDEV,_ as jsxEscape,a as jsxTemplate,u as jsxs};\n//# sourceMappingURL=jsxRuntime.module.js.map\n","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f);else for(t in e)e[t]&&(n&&(n+=\" \"),n+=t);return n}export function clsx(){for(var e,t,f=0,n=\"\";f<arguments.length;)(e=arguments[f++])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","export async function getDisplayableUsername(address) {\n return truncateAddress(address);\n}\nfunction truncateAddress(address, length = 4) {\n return `${address.slice(0, 2 + length)}...${address.slice(-length)}`;\n}\n//# sourceMappingURL=getDisplayableUsername.js.map","export const WHITE = '#FFF';\nexport const BLACK = '#000';\nexport const BRAND_BLUE = '#0000FF';\nexport const LIGHT_MODE_BOARDER = '#1E2025';\nexport const DARK_MODE_BOARDER = '#282B31';\n// Button hover and active colors\nexport const BUTTON_HOVER_LIGHT_SOLID = '#2A2A2A';\nexport const BUTTON_HOVER_DARK_SOLID = '#F5F5F5';\nexport const BUTTON_HOVER_LIGHT_TRANSPARENT = 'rgba(0, 0, 0, 0.02)';\nexport const BUTTON_HOVER_DARK_TRANSPARENT = 'rgba(255, 255, 255, 0.05)';\nexport const BUTTON_ACTIVE_LIGHT_SOLID = '#3A3A3A';\nexport const BUTTON_ACTIVE_DARK_SOLID = '#EEEEEE';\nexport const BUTTON_ACTIVE_LIGHT_TRANSPARENT = 'rgba(0, 0, 0, 0.04)';\nexport const BUTTON_ACTIVE_DARK_TRANSPARENT = 'rgba(255, 255, 255, 0.08)';\nexport const BUTTON_HOVER_BORDER_LIGHT = '#1A1A1A';\nexport const BUTTON_HOVER_BORDER_DARK = '#FFFFFF';\nexport const BUTTON_ACTIVE_BORDER_LIGHT = '#2A2A2A';\nexport const BUTTON_ACTIVE_BORDER_DARK = '#FFFFFF';\n//# sourceMappingURL=colors.js.map","import { jsx as _jsx } from \"preact/jsx-runtime\";\nimport { BRAND_BLUE, WHITE } from './colors.js';\nexport const BaseLogo = ({ fill }) => {\n const fillColor = fill === 'blue' ? BRAND_BLUE : WHITE;\n return (_jsx(\"svg\", { width: \"16\", height: \"16\", viewBox: \"0 0 16 16\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", children: _jsx(\"path\", { d: \"M0 2.014C0 1.58105 0 1.36457 0.0815779 1.19805C0.159686 1.03861 0.288611 0.909686 0.448049 0.831578C0.61457 0.75 0.831047 0.75 1.264 0.75H14.736C15.169 0.75 15.3854 0.75 15.552 0.831578C15.7114 0.909686 15.8403 1.03861 15.9184 1.19805C16 1.36457 16 1.58105 16 2.014V15.486C16 15.919 16 16.1354 15.9184 16.302C15.8403 16.4614 15.7114 16.5903 15.552 16.6684C15.3854 16.75 15.169 16.75 14.736 16.75H1.264C0.831047 16.75 0.61457 16.75 0.448049 16.6684C0.288611 16.5903 0.159686 16.4614 0.0815779 16.302C0 16.1354 0 15.919 0 15.486V2.014Z\", fill: fillColor }) }));\n};\n//# sourceMappingURL=BaseLogo.js.map","import{options as n}from\"preact\";var t,r,u,i,o=0,f=[],c=n,e=c.__b,a=c.__r,v=c.diffed,l=c.__c,m=c.unmount,s=c.__;function d(n,t){c.__h&&c.__h(r,n,o||t),o=0;var u=r.__H||(r.__H={__:[],__h:[]});return n>=u.__.length&&u.__.push({}),u.__[n]}function h(n){return o=1,p(D,n)}function p(n,u,i){var o=d(t++,2);if(o.t=n,!o.__c&&(o.__=[i?i(u):D(void 0,u),function(n){var t=o.__N?o.__N[0]:o.__[0],r=o.t(t,n);t!==r&&(o.__N=[r,o.__[1]],o.__c.setState({}))}],o.__c=r,!r.u)){var f=function(n,t,r){if(!o.__c.__H)return!0;var u=o.__c.__H.__.filter(function(n){return!!n.__c});if(u.every(function(n){return!n.__N}))return!c||c.call(this,n,t,r);var i=!1;return u.forEach(function(n){if(n.__N){var t=n.__[0];n.__=n.__N,n.__N=void 0,t!==n.__[0]&&(i=!0)}}),!(!i&&o.__c.props===n)&&(!c||c.call(this,n,t,r))};r.u=!0;var c=r.shouldComponentUpdate,e=r.componentWillUpdate;r.componentWillUpdate=function(n,t,r){if(this.__e){var u=c;c=void 0,f(n,t,r),c=u}e&&e.call(this,n,t,r)},r.shouldComponentUpdate=f}return o.__N||o.__}function y(n,u){var i=d(t++,3);!c.__s&&C(i.__H,u)&&(i.__=n,i.i=u,r.__H.__h.push(i))}function _(n,u){var i=d(t++,4);!c.__s&&C(i.__H,u)&&(i.__=n,i.i=u,r.__h.push(i))}function A(n){return o=5,T(function(){return{current:n}},[])}function F(n,t,r){o=6,_(function(){return\"function\"==typeof n?(n(t()),function(){return n(null)}):n?(n.current=t(),function(){return n.current=null}):void 0},null==r?r:r.concat(n))}function T(n,r){var u=d(t++,7);return C(u.__H,r)&&(u.__=n(),u.__H=r,u.__h=n),u.__}function q(n,t){return o=8,T(function(){return n},t)}function x(n){var u=r.context[n.__c],i=d(t++,9);return i.c=n,u?(null==i.__&&(i.__=!0,u.sub(r)),u.props.value):n.__}function P(n,t){c.useDebugValue&&c.useDebugValue(t?t(n):n)}function b(n){var u=d(t++,10),i=h();return u.__=n,r.componentDidCatch||(r.componentDidCatch=function(n,t){u.__&&u.__(n,t),i[1](n)}),[i[0],function(){i[1](void 0)}]}function g(){var n=d(t++,11);if(!n.__){for(var u=r.__v;null!==u&&!u.__m&&null!==u.__;)u=u.__;var i=u.__m||(u.__m=[0,0]);n.__=\"P\"+i[0]+\"-\"+i[1]++}return n.__}function j(){for(var n;n=f.shift();)if(n.__P&&n.__H)try{n.__H.__h.forEach(z),n.__H.__h.forEach(B),n.__H.__h=[]}catch(t){n.__H.__h=[],c.__e(t,n.__v)}}c.__b=function(n){r=null,e&&e(n)},c.__=function(n,t){n&&t.__k&&t.__k.__m&&(n.__m=t.__k.__m),s&&s(n,t)},c.__r=function(n){a&&a(n),t=0;var i=(r=n.__c).__H;i&&(u===r?(i.__h=[],r.__h=[],i.__.forEach(function(n){n.__N&&(n.__=n.__N),n.i=n.__N=void 0})):(i.__h.forEach(z),i.__h.forEach(B),i.__h=[],t=0)),u=r},c.diffed=function(n){v&&v(n);var t=n.__c;t&&t.__H&&(t.__H.__h.length&&(1!==f.push(t)&&i===c.requestAnimationFrame||((i=c.requestAnimationFrame)||w)(j)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.i=void 0})),u=r=null},c.__c=function(n,t){t.some(function(n){try{n.__h.forEach(z),n.__h=n.__h.filter(function(n){return!n.__||B(n)})}catch(r){t.some(function(n){n.__h&&(n.__h=[])}),t=[],c.__e(r,n.__v)}}),l&&l(n,t)},c.unmount=function(n){m&&m(n);var t,r=n.__c;r&&r.__H&&(r.__H.__.forEach(function(n){try{z(n)}catch(n){t=n}}),r.__H=void 0,t&&c.__e(t,r.__v))};var k=\"function\"==typeof requestAnimationFrame;function w(n){var t,r=function(){clearTimeout(u),k&&cancelAnimationFrame(t),setTimeout(n)},u=setTimeout(r,100);k&&(t=requestAnimationFrame(r))}function z(n){var t=r,u=n.__c;\"function\"==typeof u&&(n.__c=void 0,u()),r=t}function B(n){var t=r;n.__c=n.__(),r=t}function C(n,t){return!n||n.length!==t.length||t.some(function(t,r){return t!==n[r]})}function D(n,t){return\"function\"==typeof t?t(n):t}export{q as useCallback,x as useContext,P as useDebugValue,y as useEffect,b as useErrorBoundary,g as useId,F as useImperativeHandle,_ as useLayoutEffect,T as useMemo,p as useReducer,A as useRef,h as useState};\n//# sourceMappingURL=hooks.module.js.map\n","export default (() => `.-base-acc-sdk-css-reset{-webkit-font-smoothing:antialiased;pointer-events:auto !important}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-container{position:fixed;top:0;left:0;width:100%;height:100%;z-index:2147483647}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-container *{user-select:none;box-sizing:border-box}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-backdrop{position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.5);display:flex;align-items:center;justify-content:center;padding:20px}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-backdrop{align-items:flex-end;justify-content:stretch;padding:0}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog{position:relative;z-index:2147483648}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog{width:100%}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance{background:#fff;border-radius:12px;box-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 10px 10px -5px rgba(0,0,0,.04);width:380px;max-height:90vh;overflow:hidden;transform:scale(0.95);opacity:0;transition:all .2s ease-in-out}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance{touch-action:pan-y;user-select:none}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-hidden{transform:scale(0.9);opacity:0}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-hidden{transform:translateY(100%)}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance:not(.-base-acc-sdk-dialog-instance-hidden){transform:scale(1);opacity:1}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance:not(.-base-acc-sdk-dialog-instance-hidden){transform:translateY(0)}}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance{width:100%;max-width:100%;border-radius:20px 20px 0 0;box-shadow:0 -10px 25px rgba(0,0,0,.15);max-height:80vh;transform:translateY(0)}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-hidden{transform:translateY(100%);opacity:1}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance:not(.-base-acc-sdk-dialog-instance-hidden){transform:translateY(0);opacity:1}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header{display:flex;align-items:center;justify-content:space-between;padding:16px 20px 0 20px}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header{padding:16px 20px 12px 20px}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header-icon-and-title{display:flex;align-items:center;gap:8px}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header-icon-and-title-title{font-family:\"BaseSans-Regular\",sans-serif;font-size:14px;font-weight:400;color:#5b616e}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header-cblogo{width:32px;height:32px}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header-close{display:flex;align-items:center;justify-content:center;width:32px;height:32px;cursor:pointer;border-radius:6px;transition:background-color .2s}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header-close:hover{background-color:#f5f7f8}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header-close-icon{width:14px;height:14px}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-header-close-icon{display:none}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-content{padding:20px 20px 16px 20px;font-family:\"BaseSans-Regular\",sans-serif}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-content{padding:8px 20px 12px 20px}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-content-title{font-size:20px;font-weight:600;line-height:28px;color:#0a0b0d;margin-bottom:10px}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-content-message{font-size:16px;font-weight:400;line-height:24px;color:#5b616e;margin-bottom:0}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-actions{display:flex;padding:16px 20px 20px 20px;flex-direction:column}@media(max-width: 600px)and (orientation: portrait){.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-actions{padding:16px 20px calc(20px + env(safe-area-inset-bottom)) 20px;gap:6px}}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button{font-family:\"BaseSans-Regular\",sans-serif;font-size:16px;font-weight:500;line-height:24px;border:none;border-radius:12px;padding:16px 24px;cursor:pointer;transition:all .2s ease-in-out;width:100%;margin:4px 0}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button:disabled{opacity:.5;cursor:not-allowed}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button-primary{background-color:#0a0b0d;color:#fff}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button-primary:hover:not(:disabled){background-color:#1c1e20}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button-primary:active:not(:disabled){background-color:#2a2d31}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button-secondary{background-color:#eef0f3;color:#0a0b0d}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button-secondary:hover:not(:disabled){background-color:#e1e4e8}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-instance-button-secondary:active:not(:disabled){background-color:#d4d8dd}.-base-acc-sdk-css-reset .-base-acc-sdk-dialog-handle-bar{position:absolute;top:-16px;left:50%;transform:translateX(-50%);width:64px;height:4px;background-color:#d1d5db;border-radius:2px;opacity:0;animation:handleBarFadeIn .2s ease-in-out .2s forwards}@keyframes handleBarFadeIn{from{opacity:0}to{opacity:1}}`)();\n//# sourceMappingURL=Dialog-css.js.map","import { createElement as _createElement } from \"preact\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"preact/jsx-runtime\";\n// Copyright (c) 2018-2025 Coinbase, Inc. <https://www.coinbase.com/>\nimport { clsx } from 'clsx';\nimport { render } from 'preact';\nimport { getDisplayableUsername } from '../../core/username/getDisplayableUsername.js';\nimport { store } from '../../store/store.js';\nimport { BaseLogo } from '../assets/BaseLogo.js';\nimport { useEffect, useMemo, useState } from 'preact/hooks';\nimport css from './Dialog-css.js';\nconst closeIcon = `data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTQiIGhlaWdodD0iMTQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEzIDFMMSAxM20wLTEyTDEzIDEzIiBzdHJva2U9IiM5Q0EzQUYiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+PC9zdmc+`;\n// Helper function to detect phone portrait mode\nfunction isPhonePortrait() {\n return window.innerWidth <= 600 && window.innerHeight > window.innerWidth;\n}\n// Handle bar component for mobile bottom sheet\nconst DialogHandleBar = () => {\n const [showHandleBar, setShowHandleBar] = useState(false);\n useEffect(() => {\n // Only show handle bar on phone portrait mode\n const checkOrientation = () => {\n setShowHandleBar(isPhonePortrait());\n };\n // Initial check\n checkOrientation();\n // Listen for orientation/resize changes\n window.addEventListener('resize', checkOrientation);\n window.addEventListener('orientationchange', checkOrientation);\n return () => {\n window.removeEventListener('resize', checkOrientation);\n window.removeEventListener('orientationchange', checkOrientation);\n };\n }, []);\n if (!showHandleBar) {\n return null;\n }\n return _jsx(\"div\", { class: \"-base-acc-sdk-dialog-handle-bar\" });\n};\nexport class Dialog {\n items = new Map();\n nextItemKey = 0;\n root = null;\n constructor() { }\n attach(el) {\n this.root = document.createElement('div');\n this.root.className = '-base-acc-sdk-dialog-root';\n el.appendChild(this.root);\n this.render();\n }\n presentItem(itemProps) {\n const key = this.nextItemKey++;\n this.items.set(key, itemProps);\n this.render();\n }\n clear() {\n this.items.clear();\n if (this.root) {\n render(null, this.root);\n }\n }\n render() {\n if (this.root) {\n render(_jsx(\"div\", { children: _jsx(DialogContainer, { children: Array.from(this.items.entries()).map(([key, itemProps]) => (_createElement(DialogInstance, { ...itemProps, key: key, handleClose: () => {\n this.clear();\n itemProps.onClose?.();\n } }))) }) }), this.root);\n }\n }\n}\nexport const DialogContainer = (props) => {\n const [dragY, setDragY] = useState(0);\n const [isDragging, setIsDragging] = useState(false);\n const [startY, setStartY] = useState(0);\n // Touch event handlers for drag-to-dismiss (entire dialog area)\n const handleTouchStart = (e) => {\n // Only enable drag on mobile portrait mode\n if (!isPhonePortrait())\n return;\n const touch = e.touches[0];\n setStartY(touch.clientY);\n setIsDragging(true);\n };\n const handleTouchMove = (e) => {\n if (!isDragging)\n return;\n const touch = e.touches[0];\n const deltaY = touch.clientY - startY;\n // Only allow dragging down (positive deltaY)\n if (deltaY > 0) {\n setDragY(deltaY);\n e.preventDefault(); // Prevent scrolling\n }\n };\n const handleTouchEnd = () => {\n if (!isDragging)\n return;\n setIsDragging(false);\n // Dismiss if dragged down more than 100px\n if (dragY > 100) {\n // Find the dialog instance and trigger its close handler\n const closeButton = document.querySelector('.-base-acc-sdk-dialog-instance-header-close');\n if (closeButton) {\n closeButton.click();\n }\n }\n else {\n // Animate back to original position\n setDragY(0);\n }\n };\n return (_jsxs(\"div\", { class: clsx('-base-acc-sdk-dialog-container'), children: [_jsx(\"style\", { children: css }), _jsx(\"div\", { class: \"-base-acc-sdk-dialog-backdrop\", onTouchStart: handleTouchStart, onTouchMove: handleTouchMove, onTouchEnd: handleTouchEnd, children: _jsxs(\"div\", { class: \"-base-acc-sdk-dialog\", style: {\n transform: `translateY(${dragY}px)`,\n transition: isDragging ? 'none' : 'transform 0.2s ease-out',\n }, children: [_jsx(DialogHandleBar, {}), props.children] }) })] }));\n};\nexport const DialogInstance = ({ title, message, actionItems, handleClose, }) => {\n const [hidden, setHidden] = useState(true);\n const [isLoadingUsername, setIsLoadingUsername] = useState(true);\n const [username, setUsername] = useState(null);\n useEffect(() => {\n const timer = window.setTimeout(() => {\n setHidden(false);\n }, 1);\n return () => {\n window.clearTimeout(timer);\n };\n }, []);\n useEffect(() => {\n const fetchEnsName = async () => {\n const address = store.account.get().accounts?.[0];\n if (address) {\n const username = await getDisplayableUsername(address);\n setUsername(username);\n }\n setIsLoadingUsername(false);\n };\n fetchEnsName();\n }, []);\n const headerTitle = useMemo(() => {\n return username ? `Signed in as ${username}` : 'Base Account';\n }, [username]);\n const shouldShowHeaderTitle = !isLoadingUsername;\n return (_jsxs(\"div\", { class: clsx('-base-acc-sdk-dialog-instance', hidden && '-base-acc-sdk-dialog-instance-hidden'), children: [_jsxs(\"div\", { class: \"-base-acc-sdk-dialog-instance-header\", children: [_jsxs(\"div\", { class: \"-base-acc-sdk-dialog-instance-header-icon-and-title\", children: [_jsx(BaseLogo, { fill: \"blue\" }), shouldShowHeaderTitle && (_jsx(\"div\", { class: \"-base-acc-sdk-dialog-instance-header-icon-and-title-title\", children: headerTitle }))] }), _jsx(\"div\", { class: \"-base-acc-sdk-dialog-instance-header-close\", onClick: handleClose, children: _jsx(\"img\", { src: closeIcon, class: \"-base-acc-sdk-dialog-instance-header-close-icon\" }) })] }), _jsxs(\"div\", { class: \"-base-acc-sdk-dialog-instance-content\", children: [_jsx(\"div\", { class: \"-base-acc-sdk-dialog-instance-content-title\", children: title }), _jsx(\"div\", { class: \"-base-acc-sdk-dialog-instance-content-message\", children: message })] }), actionItems && actionItems.length > 0 && (_jsx(\"div\", { class: \"-base-acc-sdk-dialog-instance-actions\", children: actionItems.map((action, i) => (_jsx(\"button\", { class: clsx('-base-acc-sdk-dialog-instance-button', action.variant === 'primary' && '-base-acc-sdk-dialog-instance-button-primary', action.variant === 'secondary' && '-base-acc-sdk-dialog-instance-button-secondary'), onClick: action.onClick, children: action.text }, i))) }))] }));\n};\n//# sourceMappingURL=Dialog.js.map","import { injectFontStyle } from '../assets/injectFontStyle.js';\nimport { Dialog } from './Dialog.js';\nlet dialog = null;\nexport function initDialog() {\n if (!dialog) {\n const root = document.createElement('div');\n root.className = '-base-acc-sdk-css-reset';\n document.body.appendChild(root);\n dialog = new Dialog();\n dialog.attach(root);\n }\n injectFontStyle();\n return dialog;\n}\n//# sourceMappingURL=index.js.map","import { PACKAGE_NAME, PACKAGE_VERSION } from '../core/constants.js';\nimport { standardErrors } from '../core/error/errors.js';\nimport { logDialogActionClicked, logDialogShown } from '../core/telemetry/events/dialog.js';\nimport { store } from '../store/store.js';\nimport { initDialog } from '../ui/Dialog/index.js';\nimport { getCrossOriginOpenerPolicy } from './checkCrossOriginOpenerPolicy.js';\nconst POPUP_WIDTH = 420;\nconst POPUP_HEIGHT = 700;\nconst POPUP_BLOCKED_TITLE = '{app} wants to continue in Base Account';\nconst POPUP_BLOCKED_MESSAGE = 'This action requires your permission to open a new window.';\nexport function openPopup(url) {\n const left = (window.innerWidth - POPUP_WIDTH) / 2 + window.screenX;\n const top = (window.innerHeight - POPUP_HEIGHT) / 2 + window.screenY;\n appendAppInfoQueryParams(url);\n function tryOpenPopup() {\n const popupId = `wallet_${crypto.randomUUID()}`;\n const popup = window.open(url, popupId, `width=${POPUP_WIDTH}, height=${POPUP_HEIGHT}, left=${left}, top=${top}`);\n popup?.focus();\n if (!popup) {\n return null;\n }\n return popup;\n }\n const popup = tryOpenPopup();\n // If the popup was blocked, show a snackbar with a retry button\n if (!popup) {\n return openPopupWithDialog(tryOpenPopup);\n }\n return Promise.resolve(popup);\n}\nexport function closePopup(popup) {\n if (popup && !popup.closed) {\n popup.close();\n }\n}\nfunction appendAppInfoQueryParams(url) {\n const params = {\n sdkName: PACKAGE_NAME,\n sdkVersion: PACKAGE_VERSION,\n origin: window.location.origin,\n coop: getCrossOriginOpenerPolicy(),\n };\n for (const [key, value] of Object.entries(params)) {\n if (!url.searchParams.has(key)) {\n url.searchParams.append(key, value.toString());\n }\n }\n}\nfunction openPopupWithDialog(tryOpenPopup) {\n const dappName = store.config.get().metadata?.appName ?? 'App';\n const dialog = initDialog();\n return new Promise((resolve, reject) => {\n logDialogShown({ dialogContext: 'popup_blocked' });\n dialog.presentItem({\n title: POPUP_BLOCKED_TITLE.replace('{app}', dappName),\n message: POPUP_BLOCKED_MESSAGE,\n onClose: () => {\n logDialogActionClicked({\n dialogContext: 'popup_blocked',\n dialogAction: 'cancel',\n });\n reject(standardErrors.rpc.internal('Popup window was blocked'));\n },\n actionItems: [\n {\n text: 'Try again',\n variant: 'primary',\n onClick: () => {\n logDialogActionClicked({\n dialogContext: 'popup_blocked',\n dialogAction: 'confirm',\n });\n const popup = tryOpenPopup();\n if (popup) {\n resolve(popup);\n }\n else {\n reject(standardErrors.rpc.internal('Popup window was blocked'));\n }\n dialog.clear();\n },\n },\n {\n text: 'Cancel',\n variant: 'secondary',\n onClick: () => {\n logDialogActionClicked({\n dialogContext: 'popup_blocked',\n dialogAction: 'cancel',\n });\n reject(standardErrors.rpc.internal('Popup window was blocked'));\n dialog.clear();\n },\n },\n ],\n });\n });\n}\n//# sourceMappingURL=web.js.map","import { CB_KEYS_URL, PACKAGE_NAME, PACKAGE_VERSION } from '../constants.js';\nimport { standardErrors } from '../error/errors.js';\nimport { logPopupSetupCompleted, logPopupSetupStarted, logPopupUnloadReceived, } from '../telemetry/events/communicator.js';\nimport { closePopup, openPopup } from '../../util/web.js';\n/**\n * Communicates with a popup window for specific Base Account environment\n * to send and receive messages.\n *\n * This class is responsible for opening a popup window, posting messages to it,\n * and listening for responses.\n *\n * It also handles cleanup of event listeners and the popup window itself when necessary.\n */\nexport class Communicator {\n metadata;\n preference;\n url;\n popup = null;\n listeners = new Map();\n constructor({ url = CB_KEYS_URL, metadata, preference }) {\n this.url = new URL(url);\n this.metadata = metadata;\n this.preference = preference;\n }\n /**\n * Posts a message to the popup window\n */\n postMessage = async (message) => {\n const popup = await this.waitForPopupLoaded();\n popup.postMessage(message, this.url.origin);\n };\n /**\n * Posts a request to the popup window and waits for a response\n */\n postRequestAndWaitForResponse = async (request) => {\n const responsePromise = this.onMessage(({ requestId }) => requestId === request.id);\n this.postMessage(request);\n return await responsePromise;\n };\n /**\n * Listens for messages from the popup window that match a given predicate.\n */\n onMessage = async (predicate) => {\n return new Promise((resolve, reject) => {\n const listener = (event) => {\n if (event.origin !== this.url.origin)\n return; // origin validation\n const message = event.data;\n if (predicate(message)) {\n resolve(message);\n window.removeEventListener('message', listener);\n this.listeners.delete(listener);\n }\n };\n window.addEventListener('message', listener);\n this.listeners.set(listener, { reject });\n });\n };\n /**\n * Closes the popup, rejects all requests and clears the listeners\n */\n disconnect = () => {\n // Note: keys popup handles closing itself. this is a fallback.\n closePopup(this.popup);\n this.popup = null;\n this.listeners.forEach(({ reject }, listener) => {\n reject(standardErrors.provider.userRejectedRequest('Request rejected'));\n window.removeEventListener('message', listener);\n });\n this.listeners.clear();\n };\n /**\n * Waits for the popup window to fully load and then sends a version message.\n */\n waitForPopupLoaded = async () => {\n if (this.popup && !this.popup.closed) {\n // In case the user un-focused the popup between requests, focus it again\n this.popup.focus();\n return this.popup;\n }\n logPopupSetupStarted();\n this.popup = await openPopup(this.url);\n this.onMessage(({ event }) => event === 'PopupUnload')\n .then(() => {\n this.disconnect();\n logPopupUnloadReceived();\n })\n .catch(() => { });\n return this.onMessage(({ event }) => event === 'PopupLoaded')\n .then((message) => {\n this.postMessage({\n requestId: message.id,\n data: {\n version: PACKAGE_VERSION,\n sdkName: PACKAGE_NAME,\n metadata: this.metadata,\n preference: this.preference,\n location: window.location.toString(),\n },\n });\n })\n .then(() => {\n if (!this.popup)\n throw standardErrors.rpc.internal();\n logPopupSetupCompleted();\n return this.popup;\n });\n };\n}\n//# sourceMappingURL=Communicator.js.map","import { PACKAGE_VERSION } from '../constants.js';\nimport { standardErrorCodes } from './constants.js';\nimport { serialize } from './utils.js';\n/**\n * Serializes an error to a format that is compatible with the Ethereum JSON RPC error format.\n * See https://docs.cloud.coinbase.com/wallet-sdk/docs/errors\n * for more information.\n */\nexport function serializeError(error) {\n const serialized = serialize(getErrorObject(error), {\n shouldIncludeStack: true,\n });\n const docUrl = new URL('https://docs.cloud.coinbase.com/wallet-sdk/docs/errors');\n docUrl.searchParams.set('version', PACKAGE_VERSION);\n docUrl.searchParams.set('code', serialized.code.toString());\n docUrl.searchParams.set('message', serialized.message);\n return {\n ...serialized,\n docUrl: docUrl.href,\n };\n}\nfunction isErrorResponse(response) {\n return response.errorMessage !== undefined;\n}\n/**\n * Converts an error to a serializable object.\n */\nfunction getErrorObject(error) {\n if (typeof error === 'string') {\n return {\n message: error,\n code: standardErrorCodes.rpc.internal,\n };\n }\n if (isErrorResponse(error)) {\n const message = error.errorMessage;\n const code = error.errorCode ??\n (message.match(/(denied|rejected)/i)\n ? standardErrorCodes.provider.userRejectedRequest\n : undefined);\n return {\n ...error,\n message,\n code,\n data: { method: error.method },\n };\n }\n return error;\n}\n//# sourceMappingURL=serialize.js.map","import { EventEmitter } from 'eventemitter3';\nexport class ProviderEventEmitter extends EventEmitter {\n}\n//# sourceMappingURL=interface.js.map","import { ActionType, AnalyticsEventImportance, ComponentType, logEvent } from '../logEvent.js';\nexport const logRequestStarted = ({ method, correlationId, }) => {\n logEvent('provider.request.started', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n signerType: 'base-account',\n correlationId,\n }, AnalyticsEventImportance.high);\n};\nexport const logRequestError = ({ method, correlationId, errorMessage, }) => {\n logEvent('provider.request.error', {\n action: ActionType.error,\n componentType: ComponentType.unknown,\n method,\n signerType: 'base-account',\n correlationId,\n errorMessage,\n }, AnalyticsEventImportance.high);\n};\nexport const logRequestResponded = ({ method, correlationId, }) => {\n logEvent('provider.request.responded', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n signerType: 'base-account',\n correlationId,\n }, AnalyticsEventImportance.high);\n};\n//# sourceMappingURL=provider.js.map","// biome-ignore lint/suspicious/noExplicitAny: this is used in a catch block\nexport const parseErrorMessageFromAny = (errorOrAny) => {\n return 'message' in errorOrAny && typeof errorOrAny.message === 'string'\n ? errorOrAny.message\n : '';\n};\n//# sourceMappingURL=utils.js.map","export function OpaqueType() {\n return (value) => value;\n}\nexport const HexString = OpaqueType();\nexport const BigIntString = OpaqueType();\nexport function IntNumber(num) {\n return Math.floor(num);\n}\nexport const RegExpString = OpaqueType();\n//# sourceMappingURL=index.js.map","// Copyright (c) 2018-2023 Coinbase, Inc. <https://www.coinbase.com/>\nimport { standardErrors } from '../error/errors.js';\nimport { BigIntString, HexString, IntNumber, RegExpString } from './index.js';\nconst INT_STRING_REGEX = /^[0-9]*$/;\nconst HEXADECIMAL_STRING_REGEX = /^[a-f0-9]*$/;\n/**\n * @param length number of bytes\n */\nexport function randomBytesHex(length) {\n return uint8ArrayToHex(crypto.getRandomValues(new Uint8Array(length)));\n}\nexport function uint8ArrayToHex(value) {\n return [...value].map((b) => b.toString(16).padStart(2, '0')).join('');\n}\nexport function hexStringToUint8Array(hexString) {\n return new Uint8Array(hexString.match(/.{1,2}/g).map((byte) => Number.parseInt(byte, 16)));\n}\nexport function hexStringFromBuffer(buf, includePrefix = false) {\n const hex = buf.toString('hex');\n return HexString(includePrefix ? `0x${hex}` : hex);\n}\nexport function encodeToHexString(str) {\n return hexStringFromBuffer(ensureBuffer(str), true);\n}\nexport function bigIntStringFromBigInt(bi) {\n return BigIntString(bi.toString(10));\n}\nexport function intNumberFromHexString(hex) {\n return IntNumber(Number(BigInt(ensureEvenLengthHexString(hex, true))));\n}\nexport function hexStringFromNumber(num) {\n return HexString(`0x${BigInt(num).toString(16)}`);\n}\nexport function has0xPrefix(str) {\n return str.startsWith('0x') || str.startsWith('0X');\n}\nexport function strip0x(hex) {\n if (has0xPrefix(hex)) {\n return hex.slice(2);\n }\n return hex;\n}\nexport function prepend0x(hex) {\n if (has0xPrefix(hex)) {\n return `0x${hex.slice(2)}`;\n }\n return `0x${hex}`;\n}\nexport function isHexString(hex) {\n if (typeof hex !== 'string') {\n return false;\n }\n const s = strip0x(hex).toLowerCase();\n return HEXADECIMAL_STRING_REGEX.test(s);\n}\nexport function ensureHexString(hex, includePrefix = false) {\n if (typeof hex === 'string') {\n const s = strip0x(hex).toLowerCase();\n if (HEXADECIMAL_STRING_REGEX.test(s)) {\n return HexString(includePrefix ? `0x${s}` : s);\n }\n }\n throw standardErrors.rpc.invalidParams(`\"${String(hex)}\" is not a hexadecimal string`);\n}\nexport function ensureEvenLengthHexString(hex, includePrefix = false) {\n let h = ensureHexString(hex, false);\n if (h.length % 2 === 1) {\n h = HexString(`0${h}`);\n }\n return includePrefix ? HexString(`0x${h}`) : h;\n}\nexport function ensureAddressString(str) {\n if (typeof str === 'string') {\n const s = strip0x(str).toLowerCase();\n if (isHexString(s) && s.length === 40) {\n return prepend0x(s);\n }\n }\n throw standardErrors.rpc.invalidParams(`Invalid Ethereum address: ${String(str)}`);\n}\nexport function ensureBuffer(str) {\n if (Buffer.isBuffer(str)) {\n return str;\n }\n if (typeof str === 'string') {\n if (isHexString(str)) {\n const s = ensureEvenLengthHexString(str, false);\n return Buffer.from(s, 'hex');\n }\n return Buffer.from(str, 'utf8');\n }\n throw standardErrors.rpc.invalidParams(`Not binary data: ${String(str)}`);\n}\nexport function ensureIntNumber(num) {\n if (typeof num === 'number' && Number.isInteger(num)) {\n return IntNumber(num);\n }\n if (typeof num === 'string') {\n if (INT_STRING_REGEX.test(num)) {\n return IntNumber(Number(num));\n }\n if (isHexString(num)) {\n return IntNumber(Number(BigInt(ensureEvenLengthHexString(num, true))));\n }\n }\n throw standardErrors.rpc.invalidParams(`Not an integer: ${String(num)}`);\n}\nexport function ensureRegExpString(regExp) {\n if (regExp instanceof RegExp) {\n return RegExpString(regExp.toString());\n }\n throw standardErrors.rpc.invalidParams(`Not a RegExp: ${String(regExp)}`);\n}\nexport function ensureBigInt(val) {\n if (val !== null && (typeof val === 'bigint' || isBigNumber(val))) {\n // biome-ignore lint/suspicious/noExplicitAny: force cast to any to avoid type error\n return BigInt(val.toString(10));\n }\n if (typeof val === 'number') {\n return BigInt(ensureIntNumber(val));\n }\n if (typeof val === 'string') {\n if (INT_STRING_REGEX.test(val)) {\n return BigInt(val);\n }\n if (isHexString(val)) {\n return BigInt(ensureEvenLengthHexString(val, true));\n }\n }\n throw standardErrors.rpc.invalidParams(`Not an integer: ${String(val)}`);\n}\nexport function ensureParsedJSONObject(val) {\n if (typeof val === 'string') {\n return JSON.parse(val);\n }\n if (typeof val === 'object') {\n return val;\n }\n throw standardErrors.rpc.invalidParams(`Not a JSON string or an object: ${String(val)}`);\n}\nexport function isBigNumber(val) {\n // biome-ignore lint/suspicious/noExplicitAny: force cast to any to avoid type error\n if (val == null || typeof val.constructor !== 'function') {\n return false;\n }\n // biome-ignore lint/suspicious/noExplicitAny: force cast to any to avoid type error\n const { constructor: constructor_ } = val;\n return typeof constructor_.config === 'function' && typeof constructor_.EUCLID === 'number';\n}\nexport function range(start, stop) {\n return Array.from({ length: stop - start }, (_, i) => start + i);\n}\nexport function areAddressArraysEqual(arr1, arr2) {\n return arr1.length === arr2.length && arr1.every((value, index) => value === arr2[index]);\n}\n//# sourceMappingURL=util.js.map","import { store } from '../../../store/store.js';\nimport { ActionType, AnalyticsEventImportance, ComponentType, logEvent } from '../logEvent.js';\nexport const logHandshakeStarted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_signer.handshake.started', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logHandshakeError = ({ method, correlationId, errorMessage, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_signer.handshake.error', {\n action: ActionType.error,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n errorMessage,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logHandshakeCompleted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_signer.handshake.completed', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logRequestStarted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_signer.request.started', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logRequestError = ({ method, correlationId, errorMessage, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_signer.request.error', {\n action: ActionType.error,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n errorMessage,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logRequestCompleted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_signer.request.completed', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\n//# sourceMappingURL=scw-signer.js.map","import { store } from '../../../store/store.js';\nimport { ActionType, AnalyticsEventImportance, ComponentType, logEvent } from '../logEvent.js';\nexport const logSubAccountRequestStarted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.request.started', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logSubAccountRequestCompleted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.request.completed', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logSubAccountRequestError = ({ method, correlationId, errorMessage, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.request.error', {\n action: ActionType.error,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n errorMessage,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logAddOwnerStarted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.add_owner.started', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logAddOwnerCompleted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.add_owner.completed', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logAddOwnerError = ({ method, correlationId, errorMessage, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.add_owner.error', {\n action: ActionType.error,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n errorMessage,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logInsufficientBalanceErrorHandlingStarted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.insufficient_balance.error_handling.started', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logInsufficientBalanceErrorHandlingCompleted = ({ method, correlationId, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.insufficient_balance.error_handling.completed', {\n action: ActionType.unknown,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\nexport const logInsufficientBalanceErrorHandlingError = ({ method, correlationId, errorMessage, }) => {\n const config = store.subAccountsConfig.get();\n logEvent('scw_sub_account.insufficient_balance.error_handling.error', {\n action: ActionType.error,\n componentType: ComponentType.unknown,\n method,\n correlationId,\n errorMessage,\n subAccountCreation: config?.creation,\n subAccountDefaultAccount: config?.defaultAccount,\n subAccountFunding: config?.funding,\n }, AnalyticsEventImportance.high);\n};\n//# sourceMappingURL=scw-sub-account.js.map","export const entryPoint06Abi = [\n {\n inputs: [\n { name: 'preOpGas', type: 'uint256' },\n { name: 'paid', type: 'uint256' },\n { name: 'validAfter', type: 'uint48' },\n { name: 'validUntil', type: 'uint48' },\n { name: 'targetSuccess', type: 'bool' },\n { name: 'targetResult', type: 'bytes' },\n ],\n name: 'ExecutionResult',\n type: 'error',\n },\n {\n inputs: [\n { name: 'opIndex', type: 'uint256' },\n { name: 'reason', type: 'string' },\n ],\n name: 'FailedOp',\n type: 'error',\n },\n {\n inputs: [{ name: 'sender', type: 'address' }],\n name: 'SenderAddressResult',\n type: 'error',\n },\n {\n inputs: [{ name: 'aggregator', type: 'address' }],\n name: 'SignatureValidationFailed',\n type: 'error',\n },\n {\n inputs: [\n {\n components: [\n { name: 'preOpGas', type: 'uint256' },\n { name: 'prefund', type: 'uint256' },\n { name: 'sigFailed', type: 'bool' },\n { name: 'validAfter', type: 'uint48' },\n { name: 'validUntil', type: 'uint48' },\n { name: 'paymasterContext', type: 'bytes' },\n ],\n name: 'returnInfo',\n type: 'tuple',\n },\n {\n components: [\n { name: 'stake', type: 'uint256' },\n { name: 'unstakeDelaySec', type: 'uint256' },\n ],\n name: 'senderInfo',\n type: 'tuple',\n },\n {\n components: [\n { name: 'stake', type: 'uint256' },\n { name: 'unstakeDelaySec', type: 'uint256' },\n ],\n name: 'factoryInfo',\n type: 'tuple',\n },\n {\n components: [\n { name: 'stake', type: 'uint256' },\n { name: 'unstakeDelaySec', type: 'uint256' },\n ],\n name: 'paymasterInfo',\n type: 'tuple',\n },\n ],\n name: 'ValidationResult',\n type: 'error',\n },\n {\n inputs: [\n {\n components: [\n { name: 'preOpGas', type: 'uint256' },\n { name: 'prefund', type: 'uint256' },\n { name: 'sigFailed', type: 'bool' },\n { name: 'validAfter', type: 'uint48' },\n { name: 'validUntil', type: 'uint48' },\n { name: 'paymasterContext', type: 'bytes' },\n ],\n name: 'returnInfo',\n type: 'tuple',\n },\n {\n components: [\n { name: 'stake', type: 'uint256' },\n { name: 'unstakeDelaySec', type: 'uint256' },\n ],\n name: 'senderInfo',\n type: 'tuple',\n },\n {\n components: [\n { name: 'stake', type: 'uint256' },\n { name: 'unstakeDelaySec', type: 'uint256' },\n ],\n name: 'factoryInfo',\n type: 'tuple',\n },\n {\n components: [\n { name: 'stake', type: 'uint256' },\n { name: 'unstakeDelaySec', type: 'uint256' },\n ],\n name: 'paymasterInfo',\n type: 'tuple',\n },\n {\n components: [\n { name: 'aggregator', type: 'address' },\n {\n components: [\n { name: 'stake', type: 'uint256' },\n {\n name: 'unstakeDelaySec',\n type: 'uint256',\n },\n ],\n name: 'stakeInfo',\n type: 'tuple',\n },\n ],\n name: 'aggregatorInfo',\n type: 'tuple',\n },\n ],\n name: 'ValidationResultWithAggregation',\n type: 'error',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n name: 'factory',\n type: 'address',\n },\n {\n indexed: false,\n name: 'paymaster',\n type: 'address',\n },\n ],\n name: 'AccountDeployed',\n type: 'event',\n },\n { anonymous: false, inputs: [], name: 'BeforeExecution', type: 'event' },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'totalDeposit',\n type: 'uint256',\n },\n ],\n name: 'Deposited',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'aggregator',\n type: 'address',\n },\n ],\n name: 'SignatureAggregatorChanged',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'totalStaked',\n type: 'uint256',\n },\n {\n indexed: false,\n name: 'unstakeDelaySec',\n type: 'uint256',\n },\n ],\n name: 'StakeLocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'withdrawTime',\n type: 'uint256',\n },\n ],\n name: 'StakeUnlocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'StakeWithdrawn',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: true,\n name: 'paymaster',\n type: 'address',\n },\n {\n indexed: false,\n name: 'nonce',\n type: 'uint256',\n },\n { indexed: false, name: 'success', type: 'bool' },\n {\n indexed: false,\n name: 'actualGasCost',\n type: 'uint256',\n },\n {\n indexed: false,\n name: 'actualGasUsed',\n type: 'uint256',\n },\n ],\n name: 'UserOperationEvent',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n name: 'nonce',\n type: 'uint256',\n },\n {\n indexed: false,\n name: 'revertReason',\n type: 'bytes',\n },\n ],\n name: 'UserOperationRevertReason',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'Withdrawn',\n type: 'event',\n },\n {\n inputs: [],\n name: 'SIG_VALIDATION_FAILED',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'initCode', type: 'bytes' },\n { name: 'sender', type: 'address' },\n { name: 'paymasterAndData', type: 'bytes' },\n ],\n name: '_validateSenderAndPaymaster',\n outputs: [],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'unstakeDelaySec', type: 'uint32' }],\n name: 'addStake',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'address' }],\n name: 'balanceOf',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'address' }],\n name: 'depositTo',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ name: '', type: 'address' }],\n name: 'deposits',\n outputs: [\n { name: 'deposit', type: 'uint112' },\n { name: 'staked', type: 'bool' },\n { name: 'stake', type: 'uint112' },\n { name: 'unstakeDelaySec', type: 'uint32' },\n { name: 'withdrawTime', type: 'uint48' },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'address' }],\n name: 'getDepositInfo',\n outputs: [\n {\n components: [\n { name: 'deposit', type: 'uint112' },\n { name: 'staked', type: 'bool' },\n { name: 'stake', type: 'uint112' },\n { name: 'unstakeDelaySec', type: 'uint32' },\n { name: 'withdrawTime', type: 'uint48' },\n ],\n name: 'info',\n type: 'tuple',\n },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'sender', type: 'address' },\n { name: 'key', type: 'uint192' },\n ],\n name: 'getNonce',\n outputs: [{ name: 'nonce', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'initCode', type: 'bytes' }],\n name: 'getSenderAddress',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n { name: 'callGasLimit', type: 'uint256' },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'maxFeePerGas', type: 'uint256' },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'userOp',\n type: 'tuple',\n },\n ],\n name: 'getUserOpHash',\n outputs: [{ name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n {\n name: 'callGasLimit',\n type: 'uint256',\n },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n {\n name: 'maxFeePerGas',\n type: 'uint256',\n },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n {\n name: 'paymasterAndData',\n type: 'bytes',\n },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'userOps',\n type: 'tuple[]',\n },\n {\n name: 'aggregator',\n type: 'address',\n },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'opsPerAggregator',\n type: 'tuple[]',\n },\n { name: 'beneficiary', type: 'address' },\n ],\n name: 'handleAggregatedOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n { name: 'callGasLimit', type: 'uint256' },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'maxFeePerGas', type: 'uint256' },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'ops',\n type: 'tuple[]',\n },\n { name: 'beneficiary', type: 'address' },\n ],\n name: 'handleOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ name: 'key', type: 'uint192' }],\n name: 'incrementNonce',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { name: 'callData', type: 'bytes' },\n {\n components: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n {\n name: 'callGasLimit',\n type: 'uint256',\n },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'paymaster', type: 'address' },\n {\n name: 'maxFeePerGas',\n type: 'uint256',\n },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n ],\n name: 'mUserOp',\n type: 'tuple',\n },\n { name: 'userOpHash', type: 'bytes32' },\n { name: 'prefund', type: 'uint256' },\n { name: 'contextOffset', type: 'uint256' },\n { name: 'preOpGas', type: 'uint256' },\n ],\n name: 'opInfo',\n type: 'tuple',\n },\n { name: 'context', type: 'bytes' },\n ],\n name: 'innerHandleOp',\n outputs: [{ name: 'actualGasCost', type: 'uint256' }],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { name: '', type: 'address' },\n { name: '', type: 'uint192' },\n ],\n name: 'nonceSequenceNumber',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n { name: 'callGasLimit', type: 'uint256' },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'maxFeePerGas', type: 'uint256' },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'op',\n type: 'tuple',\n },\n { name: 'target', type: 'address' },\n { name: 'targetCallData', type: 'bytes' },\n ],\n name: 'simulateHandleOp',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n { name: 'callGasLimit', type: 'uint256' },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'maxFeePerGas', type: 'uint256' },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'userOp',\n type: 'tuple',\n },\n ],\n name: 'simulateValidation',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [],\n name: 'unlockStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n name: 'withdrawAddress',\n type: 'address',\n },\n ],\n name: 'withdrawStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n name: 'withdrawAddress',\n type: 'address',\n },\n { name: 'withdrawAmount', type: 'uint256' },\n ],\n name: 'withdrawTo',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n { stateMutability: 'payable', type: 'receive' },\n];\nexport const entryPoint07Abi = [\n {\n inputs: [\n { name: 'success', type: 'bool' },\n { name: 'ret', type: 'bytes' },\n ],\n name: 'DelegateAndRevert',\n type: 'error',\n },\n {\n inputs: [\n { name: 'opIndex', type: 'uint256' },\n { name: 'reason', type: 'string' },\n ],\n name: 'FailedOp',\n type: 'error',\n },\n {\n inputs: [\n { name: 'opIndex', type: 'uint256' },\n { name: 'reason', type: 'string' },\n { name: 'inner', type: 'bytes' },\n ],\n name: 'FailedOpWithRevert',\n type: 'error',\n },\n {\n inputs: [{ name: 'returnData', type: 'bytes' }],\n name: 'PostOpReverted',\n type: 'error',\n },\n { inputs: [], name: 'ReentrancyGuardReentrantCall', type: 'error' },\n {\n inputs: [{ name: 'sender', type: 'address' }],\n name: 'SenderAddressResult',\n type: 'error',\n },\n {\n inputs: [{ name: 'aggregator', type: 'address' }],\n name: 'SignatureValidationFailed',\n type: 'error',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n name: 'factory',\n type: 'address',\n },\n {\n indexed: false,\n name: 'paymaster',\n type: 'address',\n },\n ],\n name: 'AccountDeployed',\n type: 'event',\n },\n { anonymous: false, inputs: [], name: 'BeforeExecution', type: 'event' },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'totalDeposit',\n type: 'uint256',\n },\n ],\n name: 'Deposited',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n name: 'nonce',\n type: 'uint256',\n },\n {\n indexed: false,\n name: 'revertReason',\n type: 'bytes',\n },\n ],\n name: 'PostOpRevertReason',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'aggregator',\n type: 'address',\n },\n ],\n name: 'SignatureAggregatorChanged',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'totalStaked',\n type: 'uint256',\n },\n {\n indexed: false,\n name: 'unstakeDelaySec',\n type: 'uint256',\n },\n ],\n name: 'StakeLocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'withdrawTime',\n type: 'uint256',\n },\n ],\n name: 'StakeUnlocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'StakeWithdrawn',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: true,\n name: 'paymaster',\n type: 'address',\n },\n {\n indexed: false,\n name: 'nonce',\n type: 'uint256',\n },\n { indexed: false, name: 'success', type: 'bool' },\n {\n indexed: false,\n name: 'actualGasCost',\n type: 'uint256',\n },\n {\n indexed: false,\n name: 'actualGasUsed',\n type: 'uint256',\n },\n ],\n name: 'UserOperationEvent',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n name: 'nonce',\n type: 'uint256',\n },\n ],\n name: 'UserOperationPrefundTooLow',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n name: 'nonce',\n type: 'uint256',\n },\n {\n indexed: false,\n name: 'revertReason',\n type: 'bytes',\n },\n ],\n name: 'UserOperationRevertReason',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'Withdrawn',\n type: 'event',\n },\n {\n inputs: [{ name: 'unstakeDelaySec', type: 'uint32' }],\n name: 'addStake',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'address' }],\n name: 'balanceOf',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'target', type: 'address' },\n { name: 'data', type: 'bytes' },\n ],\n name: 'delegateAndRevert',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'address' }],\n name: 'depositTo',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ name: '', type: 'address' }],\n name: 'deposits',\n outputs: [\n { name: 'deposit', type: 'uint256' },\n { name: 'staked', type: 'bool' },\n { name: 'stake', type: 'uint112' },\n { name: 'unstakeDelaySec', type: 'uint32' },\n { name: 'withdrawTime', type: 'uint48' },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'account', type: 'address' }],\n name: 'getDepositInfo',\n outputs: [\n {\n components: [\n { name: 'deposit', type: 'uint256' },\n { name: 'staked', type: 'bool' },\n { name: 'stake', type: 'uint112' },\n { name: 'unstakeDelaySec', type: 'uint32' },\n { name: 'withdrawTime', type: 'uint48' },\n ],\n name: 'info',\n type: 'tuple',\n },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { name: 'sender', type: 'address' },\n { name: 'key', type: 'uint192' },\n ],\n name: 'getNonce',\n outputs: [{ name: 'nonce', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'initCode', type: 'bytes' }],\n name: 'getSenderAddress',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n {\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'gasFees', type: 'bytes32' },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'userOp',\n type: 'tuple',\n },\n ],\n name: 'getUserOpHash',\n outputs: [{ name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n {\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'gasFees', type: 'bytes32' },\n {\n name: 'paymasterAndData',\n type: 'bytes',\n },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'userOps',\n type: 'tuple[]',\n },\n {\n name: 'aggregator',\n type: 'address',\n },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'opsPerAggregator',\n type: 'tuple[]',\n },\n { name: 'beneficiary', type: 'address' },\n ],\n name: 'handleAggregatedOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n { name: 'initCode', type: 'bytes' },\n { name: 'callData', type: 'bytes' },\n {\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'gasFees', type: 'bytes32' },\n { name: 'paymasterAndData', type: 'bytes' },\n { name: 'signature', type: 'bytes' },\n ],\n name: 'ops',\n type: 'tuple[]',\n },\n { name: 'beneficiary', type: 'address' },\n ],\n name: 'handleOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ name: 'key', type: 'uint192' }],\n name: 'incrementNonce',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { name: 'callData', type: 'bytes' },\n {\n components: [\n {\n components: [\n { name: 'sender', type: 'address' },\n { name: 'nonce', type: 'uint256' },\n {\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'callGasLimit',\n type: 'uint256',\n },\n {\n name: 'paymasterVerificationGasLimit',\n type: 'uint256',\n },\n {\n name: 'paymasterPostOpGasLimit',\n type: 'uint256',\n },\n {\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { name: 'paymaster', type: 'address' },\n {\n name: 'maxFeePerGas',\n type: 'uint256',\n },\n {\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n ],\n name: 'mUserOp',\n type: 'tuple',\n },\n { name: 'userOpHash', type: 'bytes32' },\n { name: 'prefund', type: 'uint256' },\n { name: 'contextOffset', type: 'uint256' },\n { name: 'preOpGas', type: 'uint256' },\n ],\n name: 'opInfo',\n type: 'tuple',\n },\n { name: 'context', type: 'bytes' },\n ],\n name: 'innerHandleOp',\n outputs: [{ name: 'actualGasCost', type: 'uint256' }],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { name: '', type: 'address' },\n { name: '', type: 'uint192' },\n ],\n name: 'nonceSequenceNumber',\n outputs: [{ name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ name: 'interfaceId', type: 'bytes4' }],\n name: 'supportsInterface',\n outputs: [{ name: '', type: 'bool' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'unlockStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n name: 'withdrawAddress',\n type: 'address',\n },\n ],\n name: 'withdrawStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n name: 'withdrawAddress',\n type: 'address',\n },\n { name: 'withdrawAmount', type: 'uint256' },\n ],\n name: 'withdrawTo',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n { stateMutability: 'payable', type: 'receive' },\n];\nexport const entryPoint08Abi = [\n { inputs: [], stateMutability: 'nonpayable', type: 'constructor' },\n {\n inputs: [\n { internalType: 'bool', name: 'success', type: 'bool' },\n { internalType: 'bytes', name: 'ret', type: 'bytes' },\n ],\n name: 'DelegateAndRevert',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'opIndex', type: 'uint256' },\n { internalType: 'string', name: 'reason', type: 'string' },\n ],\n name: 'FailedOp',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'opIndex', type: 'uint256' },\n { internalType: 'string', name: 'reason', type: 'string' },\n { internalType: 'bytes', name: 'inner', type: 'bytes' },\n ],\n name: 'FailedOpWithRevert',\n type: 'error',\n },\n { inputs: [], name: 'InvalidShortString', type: 'error' },\n {\n inputs: [{ internalType: 'bytes', name: 'returnData', type: 'bytes' }],\n name: 'PostOpReverted',\n type: 'error',\n },\n { inputs: [], name: 'ReentrancyGuardReentrantCall', type: 'error' },\n {\n inputs: [{ internalType: 'address', name: 'sender', type: 'address' }],\n name: 'SenderAddressResult',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'address', name: 'aggregator', type: 'address' }],\n name: 'SignatureValidationFailed',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'string', name: 'str', type: 'string' }],\n name: 'StringTooLong',\n type: 'error',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'factory',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'paymaster',\n type: 'address',\n },\n ],\n name: 'AccountDeployed',\n type: 'event',\n },\n { anonymous: false, inputs: [], name: 'BeforeExecution', type: 'event' },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'totalDeposit',\n type: 'uint256',\n },\n ],\n name: 'Deposited',\n type: 'event',\n },\n { anonymous: false, inputs: [], name: 'EIP712DomainChanged', type: 'event' },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'bytes',\n name: 'revertReason',\n type: 'bytes',\n },\n ],\n name: 'PostOpRevertReason',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'aggregator',\n type: 'address',\n },\n ],\n name: 'SignatureAggregatorChanged',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'totalStaked',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'unstakeDelaySec',\n type: 'uint256',\n },\n ],\n name: 'StakeLocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'withdrawTime',\n type: 'uint256',\n },\n ],\n name: 'StakeUnlocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'StakeWithdrawn',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'paymaster',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n { indexed: false, internalType: 'bool', name: 'success', type: 'bool' },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'actualGasCost',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'actualGasUsed',\n type: 'uint256',\n },\n ],\n name: 'UserOperationEvent',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n ],\n name: 'UserOperationPrefundTooLow',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'bytes',\n name: 'revertReason',\n type: 'bytes',\n },\n ],\n name: 'UserOperationRevertReason',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'Withdrawn',\n type: 'event',\n },\n {\n inputs: [\n { internalType: 'uint32', name: 'unstakeDelaySec', type: 'uint32' },\n ],\n name: 'addStake',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'address', name: 'account', type: 'address' }],\n name: 'balanceOf',\n outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'address', name: 'target', type: 'address' },\n { internalType: 'bytes', name: 'data', type: 'bytes' },\n ],\n name: 'delegateAndRevert',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'address', name: 'account', type: 'address' }],\n name: 'depositTo',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [],\n name: 'eip712Domain',\n outputs: [\n { internalType: 'bytes1', name: 'fields', type: 'bytes1' },\n { internalType: 'string', name: 'name', type: 'string' },\n { internalType: 'string', name: 'version', type: 'string' },\n { internalType: 'uint256', name: 'chainId', type: 'uint256' },\n { internalType: 'address', name: 'verifyingContract', type: 'address' },\n { internalType: 'bytes32', name: 'salt', type: 'bytes32' },\n { internalType: 'uint256[]', name: 'extensions', type: 'uint256[]' },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'address', name: 'account', type: 'address' }],\n name: 'getDepositInfo',\n outputs: [\n {\n components: [\n { internalType: 'uint256', name: 'deposit', type: 'uint256' },\n { internalType: 'bool', name: 'staked', type: 'bool' },\n { internalType: 'uint112', name: 'stake', type: 'uint112' },\n { internalType: 'uint32', name: 'unstakeDelaySec', type: 'uint32' },\n { internalType: 'uint48', name: 'withdrawTime', type: 'uint48' },\n ],\n internalType: 'struct IStakeManager.DepositInfo',\n name: 'info',\n type: 'tuple',\n },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'getDomainSeparatorV4',\n outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint192', name: 'key', type: 'uint192' },\n ],\n name: 'getNonce',\n outputs: [{ internalType: 'uint256', name: 'nonce', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'getPackedUserOpTypeHash',\n outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],\n stateMutability: 'pure',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'bytes', name: 'initCode', type: 'bytes' }],\n name: 'getSenderAddress',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n { internalType: 'bytes', name: 'initCode', type: 'bytes' },\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n internalType: 'bytes32',\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'bytes32', name: 'gasFees', type: 'bytes32' },\n { internalType: 'bytes', name: 'paymasterAndData', type: 'bytes' },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct PackedUserOperation',\n name: 'userOp',\n type: 'tuple',\n },\n ],\n name: 'getUserOpHash',\n outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n { internalType: 'bytes', name: 'initCode', type: 'bytes' },\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n internalType: 'bytes32',\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'bytes32', name: 'gasFees', type: 'bytes32' },\n {\n internalType: 'bytes',\n name: 'paymasterAndData',\n type: 'bytes',\n },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct PackedUserOperation[]',\n name: 'userOps',\n type: 'tuple[]',\n },\n {\n internalType: 'contract IAggregator',\n name: 'aggregator',\n type: 'address',\n },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct IEntryPoint.UserOpsPerAggregator[]',\n name: 'opsPerAggregator',\n type: 'tuple[]',\n },\n { internalType: 'address payable', name: 'beneficiary', type: 'address' },\n ],\n name: 'handleAggregatedOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n { internalType: 'bytes', name: 'initCode', type: 'bytes' },\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n internalType: 'bytes32',\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'bytes32', name: 'gasFees', type: 'bytes32' },\n { internalType: 'bytes', name: 'paymasterAndData', type: 'bytes' },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct PackedUserOperation[]',\n name: 'ops',\n type: 'tuple[]',\n },\n { internalType: 'address payable', name: 'beneficiary', type: 'address' },\n ],\n name: 'handleOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'uint192', name: 'key', type: 'uint192' }],\n name: 'incrementNonce',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n components: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n {\n internalType: 'uint256',\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'callGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'paymasterVerificationGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'paymasterPostOpGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'address', name: 'paymaster', type: 'address' },\n {\n internalType: 'uint256',\n name: 'maxFeePerGas',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n ],\n internalType: 'struct EntryPoint.MemoryUserOp',\n name: 'mUserOp',\n type: 'tuple',\n },\n { internalType: 'bytes32', name: 'userOpHash', type: 'bytes32' },\n { internalType: 'uint256', name: 'prefund', type: 'uint256' },\n { internalType: 'uint256', name: 'contextOffset', type: 'uint256' },\n { internalType: 'uint256', name: 'preOpGas', type: 'uint256' },\n ],\n internalType: 'struct EntryPoint.UserOpInfo',\n name: 'opInfo',\n type: 'tuple',\n },\n { internalType: 'bytes', name: 'context', type: 'bytes' },\n ],\n name: 'innerHandleOp',\n outputs: [\n { internalType: 'uint256', name: 'actualGasCost', type: 'uint256' },\n ],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'address', name: '', type: 'address' },\n { internalType: 'uint192', name: '', type: 'uint192' },\n ],\n name: 'nonceSequenceNumber',\n outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'senderCreator',\n outputs: [\n { internalType: 'contract ISenderCreator', name: '', type: 'address' },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'bytes4', name: 'interfaceId', type: 'bytes4' }],\n name: 'supportsInterface',\n outputs: [{ internalType: 'bool', name: '', type: 'bool' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'unlockStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n internalType: 'address payable',\n name: 'withdrawAddress',\n type: 'address',\n },\n ],\n name: 'withdrawStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n internalType: 'address payable',\n name: 'withdrawAddress',\n type: 'address',\n },\n { internalType: 'uint256', name: 'withdrawAmount', type: 'uint256' },\n ],\n name: 'withdrawTo',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n { stateMutability: 'payable', type: 'receive' },\n];\nexport const entryPoint09Abi = [\n { inputs: [], stateMutability: 'nonpayable', type: 'constructor' },\n {\n inputs: [\n { internalType: 'bool', name: 'success', type: 'bool' },\n { internalType: 'bytes', name: 'ret', type: 'bytes' },\n ],\n name: 'DelegateAndRevert',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'address', name: 'account', type: 'address' },\n { internalType: 'address', name: 'withdrawAddress', type: 'address' },\n { internalType: 'uint256', name: 'amount', type: 'uint256' },\n { internalType: 'bytes', name: 'revertReason', type: 'bytes' },\n ],\n name: 'DepositWithdrawalFailed',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'address', name: 'sender', type: 'address' }],\n name: 'Eip7702SenderNotDelegate',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'address', name: 'sender', type: 'address' }],\n name: 'Eip7702SenderWithoutCode',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'opIndex', type: 'uint256' },\n { internalType: 'string', name: 'reason', type: 'string' },\n ],\n name: 'FailedOp',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'opIndex', type: 'uint256' },\n { internalType: 'string', name: 'reason', type: 'string' },\n { internalType: 'bytes', name: 'inner', type: 'bytes' },\n ],\n name: 'FailedOpWithRevert',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'address', name: 'beneficiary', type: 'address' },\n { internalType: 'uint256', name: 'amount', type: 'uint256' },\n { internalType: 'bytes', name: 'revertData', type: 'bytes' },\n ],\n name: 'FailedSendToBeneficiary',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'currentDeposit', type: 'uint256' },\n { internalType: 'uint256', name: 'withdrawAmount', type: 'uint256' },\n ],\n name: 'InsufficientDeposit',\n type: 'error',\n },\n { inputs: [], name: 'InternalFunction', type: 'error' },\n {\n inputs: [{ internalType: 'address', name: 'beneficiary', type: 'address' }],\n name: 'InvalidBeneficiary',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'address', name: 'paymaster', type: 'address' }],\n name: 'InvalidPaymaster',\n type: 'error',\n },\n {\n inputs: [\n {\n internalType: 'uint256',\n name: 'paymasterAndDataLength',\n type: 'uint256',\n },\n ],\n name: 'InvalidPaymasterData',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'dataLength', type: 'uint256' },\n { internalType: 'uint256', name: 'pmSignatureLength', type: 'uint256' },\n ],\n name: 'InvalidPaymasterSignatureLength',\n type: 'error',\n },\n { inputs: [], name: 'InvalidShortString', type: 'error' },\n {\n inputs: [\n { internalType: 'uint256', name: 'msgValue', type: 'uint256' },\n { internalType: 'uint256', name: 'currentStake', type: 'uint256' },\n ],\n name: 'InvalidStake',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'newUnstakeDelaySec', type: 'uint256' },\n {\n internalType: 'uint256',\n name: 'currentUnstakeDelaySec',\n type: 'uint256',\n },\n ],\n name: 'InvalidUnstakeDelay',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'currentStake', type: 'uint256' },\n { internalType: 'uint256', name: 'unstakeDelaySec', type: 'uint256' },\n { internalType: 'bool', name: 'staked', type: 'bool' },\n ],\n name: 'NotStaked',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'bytes', name: 'returnData', type: 'bytes' }],\n name: 'PostOpReverted',\n type: 'error',\n },\n { inputs: [], name: 'Reentrancy', type: 'error' },\n {\n inputs: [{ internalType: 'address', name: 'sender', type: 'address' }],\n name: 'SenderAddressResult',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'address', name: 'aggregator', type: 'address' }],\n name: 'SignatureValidationFailed',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'withdrawTime', type: 'uint256' },\n { internalType: 'uint256', name: 'blockTimestamp', type: 'uint256' },\n ],\n name: 'StakeNotUnlocked',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'address', name: 'account', type: 'address' },\n { internalType: 'address', name: 'withdrawAddress', type: 'address' },\n { internalType: 'uint256', name: 'amount', type: 'uint256' },\n { internalType: 'bytes', name: 'revertReason', type: 'bytes' },\n ],\n name: 'StakeWithdrawalFailed',\n type: 'error',\n },\n {\n inputs: [{ internalType: 'string', name: 'str', type: 'string' }],\n name: 'StringTooLong',\n type: 'error',\n },\n {\n inputs: [\n { internalType: 'uint256', name: 'withdrawTime', type: 'uint256' },\n { internalType: 'uint256', name: 'blockTimestamp', type: 'uint256' },\n ],\n name: 'WithdrawalNotDue',\n type: 'error',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'factory',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'paymaster',\n type: 'address',\n },\n ],\n name: 'AccountDeployed',\n type: 'event',\n },\n { anonymous: false, inputs: [], name: 'BeforeExecution', type: 'event' },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'totalDeposit',\n type: 'uint256',\n },\n ],\n name: 'Deposited',\n type: 'event',\n },\n { anonymous: false, inputs: [], name: 'EIP712DomainChanged', type: 'event' },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'delegate',\n type: 'address',\n },\n ],\n name: 'EIP7702AccountInitialized',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'unusedFactory',\n type: 'address',\n },\n ],\n name: 'IgnoredInitCode',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'bytes',\n name: 'revertReason',\n type: 'bytes',\n },\n ],\n name: 'PostOpRevertReason',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'aggregator',\n type: 'address',\n },\n ],\n name: 'SignatureAggregatorChanged',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'totalStaked',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'unstakeDelaySec',\n type: 'uint256',\n },\n ],\n name: 'StakeLocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'withdrawTime',\n type: 'uint256',\n },\n ],\n name: 'StakeUnlocked',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'StakeWithdrawn',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'paymaster',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n { indexed: false, internalType: 'bool', name: 'success', type: 'bool' },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'actualGasCost',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'actualGasUsed',\n type: 'uint256',\n },\n ],\n name: 'UserOperationEvent',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n ],\n name: 'UserOperationPrefundTooLow',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'bytes32',\n name: 'userOpHash',\n type: 'bytes32',\n },\n {\n indexed: true,\n internalType: 'address',\n name: 'sender',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'nonce',\n type: 'uint256',\n },\n {\n indexed: false,\n internalType: 'bytes',\n name: 'revertReason',\n type: 'bytes',\n },\n ],\n name: 'UserOperationRevertReason',\n type: 'event',\n },\n {\n anonymous: false,\n inputs: [\n {\n indexed: true,\n internalType: 'address',\n name: 'account',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'address',\n name: 'withdrawAddress',\n type: 'address',\n },\n {\n indexed: false,\n internalType: 'uint256',\n name: 'amount',\n type: 'uint256',\n },\n ],\n name: 'Withdrawn',\n type: 'event',\n },\n {\n inputs: [\n { internalType: 'uint32', name: 'unstakeDelaySec', type: 'uint32' },\n ],\n name: 'addStake',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'address', name: 'account', type: 'address' }],\n name: 'balanceOf',\n outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'address', name: 'target', type: 'address' },\n { internalType: 'bytes', name: 'data', type: 'bytes' },\n ],\n name: 'delegateAndRevert',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'address', name: 'account', type: 'address' }],\n name: 'depositTo',\n outputs: [],\n stateMutability: 'payable',\n type: 'function',\n },\n {\n inputs: [],\n name: 'eip712Domain',\n outputs: [\n { internalType: 'bytes1', name: 'fields', type: 'bytes1' },\n { internalType: 'string', name: 'name', type: 'string' },\n { internalType: 'string', name: 'version', type: 'string' },\n { internalType: 'uint256', name: 'chainId', type: 'uint256' },\n { internalType: 'address', name: 'verifyingContract', type: 'address' },\n { internalType: 'bytes32', name: 'salt', type: 'bytes32' },\n { internalType: 'uint256[]', name: 'extensions', type: 'uint256[]' },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'getCurrentUserOpHash',\n outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'address', name: 'account', type: 'address' }],\n name: 'getDepositInfo',\n outputs: [\n {\n components: [\n { internalType: 'uint256', name: 'deposit', type: 'uint256' },\n { internalType: 'bool', name: 'staked', type: 'bool' },\n { internalType: 'uint112', name: 'stake', type: 'uint112' },\n { internalType: 'uint32', name: 'unstakeDelaySec', type: 'uint32' },\n { internalType: 'uint48', name: 'withdrawTime', type: 'uint48' },\n ],\n internalType: 'struct IStakeManager.DepositInfo',\n name: 'info',\n type: 'tuple',\n },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'getDomainSeparatorV4',\n outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint192', name: 'key', type: 'uint192' },\n ],\n name: 'getNonce',\n outputs: [{ internalType: 'uint256', name: 'nonce', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'getPackedUserOpTypeHash',\n outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],\n stateMutability: 'pure',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'bytes', name: 'initCode', type: 'bytes' }],\n name: 'getSenderAddress',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n { internalType: 'bytes', name: 'initCode', type: 'bytes' },\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n internalType: 'bytes32',\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'bytes32', name: 'gasFees', type: 'bytes32' },\n { internalType: 'bytes', name: 'paymasterAndData', type: 'bytes' },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct PackedUserOperation',\n name: 'userOp',\n type: 'tuple',\n },\n ],\n name: 'getUserOpHash',\n outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n { internalType: 'bytes', name: 'initCode', type: 'bytes' },\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n internalType: 'bytes32',\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'bytes32', name: 'gasFees', type: 'bytes32' },\n {\n internalType: 'bytes',\n name: 'paymasterAndData',\n type: 'bytes',\n },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct PackedUserOperation[]',\n name: 'userOps',\n type: 'tuple[]',\n },\n {\n internalType: 'contract IAggregator',\n name: 'aggregator',\n type: 'address',\n },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct IEntryPoint.UserOpsPerAggregator[]',\n name: 'opsPerAggregator',\n type: 'tuple[]',\n },\n { internalType: 'address payable', name: 'beneficiary', type: 'address' },\n ],\n name: 'handleAggregatedOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n { internalType: 'bytes', name: 'initCode', type: 'bytes' },\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n internalType: 'bytes32',\n name: 'accountGasLimits',\n type: 'bytes32',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'bytes32', name: 'gasFees', type: 'bytes32' },\n { internalType: 'bytes', name: 'paymasterAndData', type: 'bytes' },\n { internalType: 'bytes', name: 'signature', type: 'bytes' },\n ],\n internalType: 'struct PackedUserOperation[]',\n name: 'ops',\n type: 'tuple[]',\n },\n { internalType: 'address payable', name: 'beneficiary', type: 'address' },\n ],\n name: 'handleOps',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'uint192', name: 'key', type: 'uint192' }],\n name: 'incrementNonce',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'bytes', name: 'callData', type: 'bytes' },\n {\n components: [\n {\n components: [\n { internalType: 'address', name: 'sender', type: 'address' },\n { internalType: 'uint256', name: 'nonce', type: 'uint256' },\n {\n internalType: 'uint256',\n name: 'verificationGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'callGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'paymasterVerificationGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'paymasterPostOpGasLimit',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'preVerificationGas',\n type: 'uint256',\n },\n { internalType: 'address', name: 'paymaster', type: 'address' },\n {\n internalType: 'uint256',\n name: 'maxFeePerGas',\n type: 'uint256',\n },\n {\n internalType: 'uint256',\n name: 'maxPriorityFeePerGas',\n type: 'uint256',\n },\n ],\n internalType: 'struct EntryPoint.MemoryUserOp',\n name: 'mUserOp',\n type: 'tuple',\n },\n { internalType: 'bytes32', name: 'userOpHash', type: 'bytes32' },\n { internalType: 'uint256', name: 'prefund', type: 'uint256' },\n { internalType: 'uint256', name: 'contextOffset', type: 'uint256' },\n { internalType: 'uint256', name: 'preOpGas', type: 'uint256' },\n ],\n internalType: 'struct EntryPoint.UserOpInfo',\n name: 'opInfo',\n type: 'tuple',\n },\n { internalType: 'bytes', name: 'context', type: 'bytes' },\n ],\n name: 'innerHandleOp',\n outputs: [\n { internalType: 'uint256', name: 'actualGasCost', type: 'uint256' },\n ],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n { internalType: 'address', name: '', type: 'address' },\n { internalType: 'uint192', name: '', type: 'uint192' },\n ],\n name: 'nonceSequenceNumber',\n outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'senderCreator',\n outputs: [\n { internalType: 'contract ISenderCreator', name: '', type: 'address' },\n ],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [{ internalType: 'bytes4', name: 'interfaceId', type: 'bytes4' }],\n name: 'supportsInterface',\n outputs: [{ internalType: 'bool', name: '', type: 'bool' }],\n stateMutability: 'view',\n type: 'function',\n },\n {\n inputs: [],\n name: 'unlockStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n internalType: 'address payable',\n name: 'withdrawAddress',\n type: 'address',\n },\n ],\n name: 'withdrawStake',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n {\n inputs: [\n {\n internalType: 'address payable',\n name: 'withdrawAddress',\n type: 'address',\n },\n { internalType: 'uint256', name: 'withdrawAmount', type: 'uint256' },\n ],\n name: 'withdrawTo',\n outputs: [],\n stateMutability: 'nonpayable',\n type: 'function',\n },\n { stateMutability: 'payable', type: 'receive' },\n];\n//# sourceMappingURL=abis.js.map","export const entryPoint06Address = '0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789';\nexport const entryPoint07Address = '0x0000000071727De22E5E9d8BAf0edAc6f37da032';\nexport const entryPoint08Address = '0x4337084D9E255Ff0702461CF8895CE9E3b5Ff108';\nexport const entryPoint09Address = '0x433709009B8330FDa32311DF1C2AFA402eD8D009';\n//# sourceMappingURL=address.js.map","import { concat } from '../../../utils/data/concat.js';\nexport function getInitCode(userOperation, options = {}) {\n const { forHash } = options;\n const { authorization, factory, factoryData } = userOperation;\n if (forHash &&\n (factory === '0x7702' ||\n factory === '0x7702000000000000000000000000000000000000')) {\n if (!authorization)\n return '0x7702000000000000000000000000000000000000';\n return concat([authorization.address, factoryData ?? '0x']);\n }\n if (!factory)\n return '0x';\n return concat([factory, factoryData ?? '0x']);\n}\n//# sourceMappingURL=getInitCode.js.map","import { concat } from '../../../utils/data/concat.js';\nimport { pad } from '../../../utils/data/pad.js';\nimport { size } from '../../../utils/data/size.js';\nimport { numberToHex } from '../../../utils/index.js';\nimport { getInitCode } from './getInitCode.js';\n/** Magic suffix for paymaster signature encoding (keccak256(\"PaymasterSignature\")[:8]) */\nconst paymasterSignatureMagic = '0x22e325a297439656';\nexport function toPackedUserOperation(userOperation, options = {}) {\n const { callGasLimit, callData, maxPriorityFeePerGas, maxFeePerGas, paymaster, paymasterData, paymasterPostOpGasLimit, paymasterSignature, paymasterVerificationGasLimit, sender, signature = '0x', verificationGasLimit, } = userOperation;\n const accountGasLimits = concat([\n pad(numberToHex(verificationGasLimit || 0n), { size: 16 }),\n pad(numberToHex(callGasLimit || 0n), { size: 16 }),\n ]);\n const initCode = getInitCode(userOperation, options);\n const gasFees = concat([\n pad(numberToHex(maxPriorityFeePerGas || 0n), { size: 16 }),\n pad(numberToHex(maxFeePerGas || 0n), { size: 16 }),\n ]);\n const nonce = userOperation.nonce ?? 0n;\n // For v0.9, paymasterSignature can be provided separately and appended after paymasterData.\n // The encoding uses a magic suffix and length prefix as per ERC-4337 spec:\n // - forHash: just append the magic (signature is not part of hash)\n // - !forHash: append signature + length (2 bytes) + magic\n const paymasterAndData = paymaster\n ? concat([\n paymaster,\n pad(numberToHex(paymasterVerificationGasLimit || 0n), {\n size: 16,\n }),\n pad(numberToHex(paymasterPostOpGasLimit || 0n), {\n size: 16,\n }),\n paymasterData || '0x',\n ...(paymasterSignature\n ? options.forHash\n ? [paymasterSignatureMagic]\n : [\n paymasterSignature,\n pad(numberToHex(size(paymasterSignature)), { size: 2 }),\n paymasterSignatureMagic,\n ]\n : []),\n ])\n : '0x';\n const preVerificationGas = userOperation.preVerificationGas ?? 0n;\n return {\n accountGasLimits,\n callData,\n initCode,\n gasFees,\n nonce,\n paymasterAndData,\n preVerificationGas,\n sender,\n signature,\n };\n}\n//# sourceMappingURL=toPackedUserOperation.js.map","import { toPackedUserOperation } from './toPackedUserOperation.js';\nconst types = {\n PackedUserOperation: [\n { type: 'address', name: 'sender' },\n { type: 'uint256', name: 'nonce' },\n { type: 'bytes', name: 'initCode' },\n { type: 'bytes', name: 'callData' },\n { type: 'bytes32', name: 'accountGasLimits' },\n { type: 'uint256', name: 'preVerificationGas' },\n { type: 'bytes32', name: 'gasFees' },\n { type: 'bytes', name: 'paymasterAndData' },\n ],\n};\nexport function getUserOperationTypedData(parameters) {\n const { chainId, entryPointAddress, userOperation } = parameters;\n const packedUserOp = toPackedUserOperation(userOperation, { forHash: true });\n return {\n types,\n primaryType: 'PackedUserOperation',\n domain: {\n name: 'ERC4337',\n version: '1',\n chainId,\n verifyingContract: entryPointAddress,\n },\n message: packedUserOp,\n };\n}\n//# sourceMappingURL=getUserOperationTypedData.js.map","import { encodeAbiParameters } from '../../../utils/abi/encodeAbiParameters.js';\nimport { keccak256 } from '../../../utils/hash/keccak256.js';\nimport { hashTypedData } from '../../../utils/signature/hashTypedData.js';\nimport { getInitCode } from './getInitCode.js';\nimport { getUserOperationTypedData } from './getUserOperationTypedData.js';\nimport { toPackedUserOperation } from './toPackedUserOperation.js';\nexport function getUserOperationHash(parameters) {\n const { chainId, entryPointAddress, entryPointVersion } = parameters;\n const userOperation = parameters.userOperation;\n const { authorization, callData = '0x', callGasLimit, maxFeePerGas, maxPriorityFeePerGas, nonce, paymasterAndData = '0x', preVerificationGas, sender, verificationGasLimit, } = userOperation;\n if (entryPointVersion === '0.8' || entryPointVersion === '0.9')\n return hashTypedData(getUserOperationTypedData({\n chainId,\n entryPointAddress,\n userOperation,\n }));\n const packedUserOp = (() => {\n if (entryPointVersion === '0.6') {\n const factory = userOperation.initCode?.slice(0, 42);\n const factoryData = userOperation.initCode?.slice(42);\n const initCode = getInitCode({\n authorization,\n factory,\n factoryData,\n }, { forHash: true });\n return encodeAbiParameters([\n { type: 'address' },\n { type: 'uint256' },\n { type: 'bytes32' },\n { type: 'bytes32' },\n { type: 'uint256' },\n { type: 'uint256' },\n { type: 'uint256' },\n { type: 'uint256' },\n { type: 'uint256' },\n { type: 'bytes32' },\n ], [\n sender,\n nonce,\n keccak256(initCode),\n keccak256(callData),\n callGasLimit,\n verificationGasLimit,\n preVerificationGas,\n maxFeePerGas,\n maxPriorityFeePerGas,\n keccak256(paymasterAndData),\n ]);\n }\n if (entryPointVersion === '0.7') {\n const packedUserOp = toPackedUserOperation(userOperation, {\n forHash: true,\n });\n return encodeAbiParameters([\n { type: 'address' },\n { type: 'uint256' },\n { type: 'bytes32' },\n { type: 'bytes32' },\n { type: 'bytes32' },\n { type: 'uint256' },\n { type: 'bytes32' },\n { type: 'bytes32' },\n ], [\n packedUserOp.sender,\n packedUserOp.nonce,\n keccak256(packedUserOp.initCode),\n keccak256(packedUserOp.callData),\n packedUserOp.accountGasLimits,\n packedUserOp.preVerificationGas,\n packedUserOp.gasFees,\n keccak256(packedUserOp.paymasterAndData),\n ]);\n }\n throw new Error(`entryPointVersion \"${entryPointVersion}\" not supported.`);\n })();\n return keccak256(encodeAbiParameters([{ type: 'bytes32' }, { type: 'address' }, { type: 'uint256' }], [keccak256(packedUserOp), entryPointAddress, BigInt(chainId)]));\n}\n//# sourceMappingURL=getUserOperationHash.js.map","import { parseAbi } from 'abitype';\nimport { getCode } from '../../actions/public/getCode.js';\nimport { readContract } from '../../actions/public/readContract.js';\nimport { getAction } from '../../utils/getAction.js';\nimport { createNonceManager } from '../../utils/nonceManager.js';\nimport { serializeErc6492Signature } from '../../utils/signature/serializeErc6492Signature.js';\n/**\n * @description Creates a Smart Account with a provided account implementation.\n *\n * @param parameters - {@link ToSmartAccountParameters}\n * @returns A Smart Account. {@link ToSmartAccountReturnType}\n */\nexport async function toSmartAccount(implementation) {\n const { extend, nonceKeyManager = createNonceManager({\n source: {\n get() {\n return Date.now();\n },\n set() { },\n },\n }), ...rest } = implementation;\n let deployed = false;\n const address = await implementation.getAddress();\n return {\n ...extend,\n ...rest,\n address,\n async getFactoryArgs() {\n if ('isDeployed' in this && (await this.isDeployed()))\n return { factory: undefined, factoryData: undefined };\n return implementation.getFactoryArgs();\n },\n async getNonce(parameters) {\n const key = parameters?.key ??\n BigInt(await nonceKeyManager.consume({\n address,\n chainId: implementation.client.chain.id,\n client: implementation.client,\n }));\n if (implementation.getNonce)\n return await implementation.getNonce({ ...parameters, key });\n const nonce = await readContract(implementation.client, {\n abi: parseAbi([\n 'function getNonce(address, uint192) pure returns (uint256)',\n ]),\n address: implementation.entryPoint.address,\n functionName: 'getNonce',\n args: [address, key],\n });\n return nonce;\n },\n async isDeployed() {\n if (deployed)\n return true;\n const code = await getAction(implementation.client, getCode, 'getCode')({\n address,\n });\n deployed = Boolean(code);\n return deployed;\n },\n ...(implementation.sign\n ? {\n async sign(parameters) {\n const [{ factory, factoryData }, signature] = await Promise.all([\n this.getFactoryArgs(),\n implementation.sign(parameters),\n ]);\n if (factory && factoryData)\n return serializeErc6492Signature({\n address: factory,\n data: factoryData,\n signature,\n });\n return signature;\n },\n }\n : {}),\n async signMessage(parameters) {\n const [{ factory, factoryData }, signature] = await Promise.all([\n this.getFactoryArgs(),\n implementation.signMessage(parameters),\n ]);\n if (factory && factoryData && factory !== '0x7702')\n return serializeErc6492Signature({\n address: factory,\n data: factoryData,\n signature,\n });\n return signature;\n },\n async signTypedData(parameters) {\n const [{ factory, factoryData }, signature] = await Promise.all([\n this.getFactoryArgs(),\n implementation.signTypedData(parameters),\n ]);\n if (factory && factoryData && factory !== '0x7702')\n return serializeErc6492Signature({\n address: factory,\n data: factoryData,\n signature,\n });\n return signature;\n },\n type: 'smart',\n };\n}\n//# sourceMappingURL=toSmartAccount.js.map","import { BaseError } from '../../errors/base.js';\nexport class AccountNotDeployedError extends BaseError {\n constructor({ cause, }) {\n super('Smart Account is not deployed.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- No `factory`/`factoryData` or `initCode` properties are provided for Smart Account deployment.',\n '- An incorrect `sender` address is provided.',\n ],\n name: 'AccountNotDeployedError',\n });\n }\n}\nObject.defineProperty(AccountNotDeployedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa20/\n});\nexport class ExecutionRevertedError extends BaseError {\n constructor({ cause, data, message, } = {}) {\n const reason = message\n ?.replace('execution reverted: ', '')\n ?.replace('execution reverted', '');\n super(`Execution reverted ${reason ? `with reason: ${reason}` : 'for an unknown reason'}.`, {\n cause,\n name: 'ExecutionRevertedError',\n });\n Object.defineProperty(this, \"data\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: void 0\n });\n this.data = data;\n }\n}\nObject.defineProperty(ExecutionRevertedError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32521\n});\nObject.defineProperty(ExecutionRevertedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /execution reverted/\n});\nexport class FailedToSendToBeneficiaryError extends BaseError {\n constructor({ cause, }) {\n super('Failed to send funds to beneficiary.', {\n cause,\n name: 'FailedToSendToBeneficiaryError',\n });\n }\n}\nObject.defineProperty(FailedToSendToBeneficiaryError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa91/\n});\nexport class GasValuesOverflowError extends BaseError {\n constructor({ cause, }) {\n super('Gas value overflowed.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- one of the gas values exceeded 2**120 (uint120)',\n ].filter(Boolean),\n name: 'GasValuesOverflowError',\n });\n }\n}\nObject.defineProperty(GasValuesOverflowError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa94/\n});\nexport class HandleOpsOutOfGasError extends BaseError {\n constructor({ cause, }) {\n super('The `handleOps` function was called by the Bundler with a gas limit too low.', {\n cause,\n name: 'HandleOpsOutOfGasError',\n });\n }\n}\nObject.defineProperty(HandleOpsOutOfGasError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa95/\n});\nexport class InitCodeFailedError extends BaseError {\n constructor({ cause, factory, factoryData, initCode, }) {\n super('Failed to simulate deployment for Smart Account.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- Invalid `factory`/`factoryData` or `initCode` properties are present',\n '- Smart Account deployment execution ran out of gas (low `verificationGasLimit` value)',\n '- Smart Account deployment execution reverted with an error\\n',\n factory && `factory: ${factory}`,\n factoryData && `factoryData: ${factoryData}`,\n initCode && `initCode: ${initCode}`,\n ].filter(Boolean),\n name: 'InitCodeFailedError',\n });\n }\n}\nObject.defineProperty(InitCodeFailedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa13/\n});\nexport class InitCodeMustCreateSenderError extends BaseError {\n constructor({ cause, factory, factoryData, initCode, }) {\n super('Smart Account initialization implementation did not create an account.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- `factory`/`factoryData` or `initCode` properties are invalid',\n '- Smart Account initialization implementation is incorrect\\n',\n factory && `factory: ${factory}`,\n factoryData && `factoryData: ${factoryData}`,\n initCode && `initCode: ${initCode}`,\n ].filter(Boolean),\n name: 'InitCodeMustCreateSenderError',\n });\n }\n}\nObject.defineProperty(InitCodeMustCreateSenderError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa15/\n});\nexport class InitCodeMustReturnSenderError extends BaseError {\n constructor({ cause, factory, factoryData, initCode, sender, }) {\n super('Smart Account initialization implementation does not return the expected sender.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n 'Smart Account initialization implementation does not return a sender address\\n',\n factory && `factory: ${factory}`,\n factoryData && `factoryData: ${factoryData}`,\n initCode && `initCode: ${initCode}`,\n sender && `sender: ${sender}`,\n ].filter(Boolean),\n name: 'InitCodeMustReturnSenderError',\n });\n }\n}\nObject.defineProperty(InitCodeMustReturnSenderError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa14/\n});\nexport class InsufficientPrefundError extends BaseError {\n constructor({ cause, }) {\n super('Smart Account does not have sufficient funds to execute the User Operation.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the Smart Account does not have sufficient funds to cover the required prefund, or',\n '- a Paymaster was not provided',\n ].filter(Boolean),\n name: 'InsufficientPrefundError',\n });\n }\n}\nObject.defineProperty(InsufficientPrefundError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa21/\n});\nexport class InternalCallOnlyError extends BaseError {\n constructor({ cause, }) {\n super('Bundler attempted to call an invalid function on the EntryPoint.', {\n cause,\n name: 'InternalCallOnlyError',\n });\n }\n}\nObject.defineProperty(InternalCallOnlyError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa92/\n});\nexport class InvalidAggregatorError extends BaseError {\n constructor({ cause, }) {\n super('Bundler used an invalid aggregator for handling aggregated User Operations.', {\n cause,\n name: 'InvalidAggregatorError',\n });\n }\n}\nObject.defineProperty(InvalidAggregatorError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa96/\n});\nexport class InvalidAccountNonceError extends BaseError {\n constructor({ cause, nonce, }) {\n super('Invalid Smart Account nonce used for User Operation.', {\n cause,\n metaMessages: [nonce && `nonce: ${nonce}`].filter(Boolean),\n name: 'InvalidAccountNonceError',\n });\n }\n}\nObject.defineProperty(InvalidAccountNonceError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa25/\n});\nexport class InvalidBeneficiaryError extends BaseError {\n constructor({ cause, }) {\n super('Bundler has not set a beneficiary address.', {\n cause,\n name: 'InvalidBeneficiaryError',\n });\n }\n}\nObject.defineProperty(InvalidBeneficiaryError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa90/\n});\nexport class InvalidFieldsError extends BaseError {\n constructor({ cause, }) {\n super('Invalid fields set on User Operation.', {\n cause,\n name: 'InvalidFieldsError',\n });\n }\n}\nObject.defineProperty(InvalidFieldsError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32602\n});\nexport class InvalidPaymasterAndDataError extends BaseError {\n constructor({ cause, paymasterAndData, }) {\n super('Paymaster properties provided are invalid.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the `paymasterAndData` property is of an incorrect length\\n',\n paymasterAndData && `paymasterAndData: ${paymasterAndData}`,\n ].filter(Boolean),\n name: 'InvalidPaymasterAndDataError',\n });\n }\n}\nObject.defineProperty(InvalidPaymasterAndDataError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa93/\n});\nexport class PaymasterDepositTooLowError extends BaseError {\n constructor({ cause, }) {\n super('Paymaster deposit for the User Operation is too low.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the Paymaster has deposited less than the expected amount via the `deposit` function',\n ].filter(Boolean),\n name: 'PaymasterDepositTooLowError',\n });\n }\n}\nObject.defineProperty(PaymasterDepositTooLowError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32508\n});\nObject.defineProperty(PaymasterDepositTooLowError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa31/\n});\nexport class PaymasterFunctionRevertedError extends BaseError {\n constructor({ cause, }) {\n super('The `validatePaymasterUserOp` function on the Paymaster reverted.', {\n cause,\n name: 'PaymasterFunctionRevertedError',\n });\n }\n}\nObject.defineProperty(PaymasterFunctionRevertedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa33/\n});\nexport class PaymasterNotDeployedError extends BaseError {\n constructor({ cause, }) {\n super('The Paymaster contract has not been deployed.', {\n cause,\n name: 'PaymasterNotDeployedError',\n });\n }\n}\nObject.defineProperty(PaymasterNotDeployedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa30/\n});\nexport class PaymasterRateLimitError extends BaseError {\n constructor({ cause }) {\n super('UserOperation rejected because paymaster (or signature aggregator) is throttled/banned.', {\n cause,\n name: 'PaymasterRateLimitError',\n });\n }\n}\nObject.defineProperty(PaymasterRateLimitError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32504\n});\nexport class PaymasterStakeTooLowError extends BaseError {\n constructor({ cause }) {\n super('UserOperation rejected because paymaster (or signature aggregator) stake or unstake-delay is too low.', {\n cause,\n name: 'PaymasterStakeTooLowError',\n });\n }\n}\nObject.defineProperty(PaymasterStakeTooLowError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32505\n});\nexport class PaymasterPostOpFunctionRevertedError extends BaseError {\n constructor({ cause, }) {\n super('Paymaster `postOp` function reverted.', {\n cause,\n name: 'PaymasterPostOpFunctionRevertedError',\n });\n }\n}\nObject.defineProperty(PaymasterPostOpFunctionRevertedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa50/\n});\nexport class SenderAlreadyConstructedError extends BaseError {\n constructor({ cause, factory, factoryData, initCode, }) {\n super('Smart Account has already been deployed.', {\n cause,\n metaMessages: [\n 'Remove the following properties and try again:',\n factory && '`factory`',\n factoryData && '`factoryData`',\n initCode && '`initCode`',\n ].filter(Boolean),\n name: 'SenderAlreadyConstructedError',\n });\n }\n}\nObject.defineProperty(SenderAlreadyConstructedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa10/\n});\nexport class SignatureCheckFailedError extends BaseError {\n constructor({ cause }) {\n super('UserOperation rejected because account signature check failed (or paymaster signature, if the paymaster uses its data as signature).', {\n cause,\n name: 'SignatureCheckFailedError',\n });\n }\n}\nObject.defineProperty(SignatureCheckFailedError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32507\n});\nexport class SmartAccountFunctionRevertedError extends BaseError {\n constructor({ cause, }) {\n super('The `validateUserOp` function on the Smart Account reverted.', {\n cause,\n name: 'SmartAccountFunctionRevertedError',\n });\n }\n}\nObject.defineProperty(SmartAccountFunctionRevertedError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa23/\n});\nexport class UnsupportedSignatureAggregatorError extends BaseError {\n constructor({ cause }) {\n super('UserOperation rejected because account specified unsupported signature aggregator.', {\n cause,\n name: 'UnsupportedSignatureAggregatorError',\n });\n }\n}\nObject.defineProperty(UnsupportedSignatureAggregatorError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32506\n});\nexport class UserOperationExpiredError extends BaseError {\n constructor({ cause, }) {\n super('User Operation expired.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the `validAfter` or `validUntil` values returned from `validateUserOp` on the Smart Account are not satisfied',\n ].filter(Boolean),\n name: 'UserOperationExpiredError',\n });\n }\n}\nObject.defineProperty(UserOperationExpiredError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa22/\n});\nexport class UserOperationPaymasterExpiredError extends BaseError {\n constructor({ cause, }) {\n super('Paymaster for User Operation expired.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the `validAfter` or `validUntil` values returned from `validatePaymasterUserOp` on the Paymaster are not satisfied',\n ].filter(Boolean),\n name: 'UserOperationPaymasterExpiredError',\n });\n }\n}\nObject.defineProperty(UserOperationPaymasterExpiredError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa32/\n});\nexport class UserOperationSignatureError extends BaseError {\n constructor({ cause, }) {\n super('Signature provided for the User Operation is invalid.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the `signature` for the User Operation is incorrectly computed, and unable to be verified by the Smart Account',\n ].filter(Boolean),\n name: 'UserOperationSignatureError',\n });\n }\n}\nObject.defineProperty(UserOperationSignatureError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa24/\n});\nexport class UserOperationPaymasterSignatureError extends BaseError {\n constructor({ cause, }) {\n super('Signature provided for the User Operation is invalid.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the `signature` for the User Operation is incorrectly computed, and unable to be verified by the Paymaster',\n ].filter(Boolean),\n name: 'UserOperationPaymasterSignatureError',\n });\n }\n}\nObject.defineProperty(UserOperationPaymasterSignatureError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa34/\n});\nexport class UserOperationRejectedByEntryPointError extends BaseError {\n constructor({ cause }) {\n super(\"User Operation rejected by EntryPoint's `simulateValidation` during account creation or validation.\", {\n cause,\n name: 'UserOperationRejectedByEntryPointError',\n });\n }\n}\nObject.defineProperty(UserOperationRejectedByEntryPointError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32500\n});\nexport class UserOperationRejectedByPaymasterError extends BaseError {\n constructor({ cause }) {\n super(\"User Operation rejected by Paymaster's `validatePaymasterUserOp`.\", {\n cause,\n name: 'UserOperationRejectedByPaymasterError',\n });\n }\n}\nObject.defineProperty(UserOperationRejectedByPaymasterError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32501\n});\nexport class UserOperationRejectedByOpCodeError extends BaseError {\n constructor({ cause }) {\n super('User Operation rejected with op code validation error.', {\n cause,\n name: 'UserOperationRejectedByOpCodeError',\n });\n }\n}\nObject.defineProperty(UserOperationRejectedByOpCodeError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32502\n});\nexport class UserOperationOutOfTimeRangeError extends BaseError {\n constructor({ cause }) {\n super('UserOperation out of time-range: either wallet or paymaster returned a time-range, and it is already expired (or will expire soon).', {\n cause,\n name: 'UserOperationOutOfTimeRangeError',\n });\n }\n}\nObject.defineProperty(UserOperationOutOfTimeRangeError, \"code\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: -32503\n});\nexport class UnknownBundlerError extends BaseError {\n constructor({ cause }) {\n super(`An error occurred while executing user operation: ${cause?.shortMessage}`, {\n cause,\n name: 'UnknownBundlerError',\n });\n }\n}\nexport class VerificationGasLimitExceededError extends BaseError {\n constructor({ cause, }) {\n super('User Operation verification gas limit exceeded.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the gas used for verification exceeded the `verificationGasLimit`',\n ].filter(Boolean),\n name: 'VerificationGasLimitExceededError',\n });\n }\n}\nObject.defineProperty(VerificationGasLimitExceededError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa40/\n});\nexport class VerificationGasLimitTooLowError extends BaseError {\n constructor({ cause, }) {\n super('User Operation verification gas limit is too low.', {\n cause,\n metaMessages: [\n 'This could arise when:',\n '- the `verificationGasLimit` is too low to verify the User Operation',\n ].filter(Boolean),\n name: 'VerificationGasLimitTooLowError',\n });\n }\n}\nObject.defineProperty(VerificationGasLimitTooLowError, \"message\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: /aa41/\n});\n//# sourceMappingURL=bundler.js.map","import { BaseError } from '../../errors/base.js';\nimport { prettyPrint } from '../../errors/transaction.js';\nimport { formatGwei } from '../../utils/index.js';\nexport class UserOperationExecutionError extends BaseError {\n constructor(cause, { callData, callGasLimit, docsPath, factory, factoryData, initCode, maxFeePerGas, maxPriorityFeePerGas, nonce, paymaster, paymasterAndData, paymasterData, paymasterPostOpGasLimit, paymasterVerificationGasLimit, preVerificationGas, sender, signature, verificationGasLimit, }) {\n const prettyArgs = prettyPrint({\n callData,\n callGasLimit,\n factory,\n factoryData,\n initCode,\n maxFeePerGas: typeof maxFeePerGas !== 'undefined' &&\n `${formatGwei(maxFeePerGas)} gwei`,\n maxPriorityFeePerGas: typeof maxPriorityFeePerGas !== 'undefined' &&\n `${formatGwei(maxPriorityFeePerGas)} gwei`,\n nonce,\n paymaster,\n paymasterAndData,\n paymasterData,\n paymasterPostOpGasLimit,\n paymasterVerificationGasLimit,\n preVerificationGas,\n sender,\n signature,\n verificationGasLimit,\n });\n super(cause.shortMessage, {\n cause,\n docsPath,\n metaMessages: [\n ...(cause.metaMessages ? [...cause.metaMessages, ' '] : []),\n 'Request Arguments:',\n prettyArgs,\n ].filter(Boolean),\n name: 'UserOperationExecutionError',\n });\n Object.defineProperty(this, \"cause\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: void 0\n });\n this.cause = cause;\n }\n}\nexport class UserOperationReceiptNotFoundError extends BaseError {\n constructor({ hash }) {\n super(`User Operation receipt with hash \"${hash}\" could not be found. The User Operation may not have been processed yet.`, { name: 'UserOperationReceiptNotFoundError' });\n }\n}\nexport class UserOperationNotFoundError extends BaseError {\n constructor({ hash }) {\n super(`User Operation with hash \"${hash}\" could not be found.`, {\n name: 'UserOperationNotFoundError',\n });\n }\n}\nexport class WaitForUserOperationReceiptTimeoutError extends BaseError {\n constructor({ hash }) {\n super(`Timed out while waiting for User Operation with hash \"${hash}\" to be confirmed.`, { name: 'WaitForUserOperationReceiptTimeoutError' });\n }\n}\n//# sourceMappingURL=userOperation.js.map","import { AccountNotDeployedError, ExecutionRevertedError, FailedToSendToBeneficiaryError, GasValuesOverflowError, HandleOpsOutOfGasError, InitCodeFailedError, InitCodeMustCreateSenderError, InitCodeMustReturnSenderError, InsufficientPrefundError, InternalCallOnlyError, InvalidAccountNonceError, InvalidAggregatorError, InvalidBeneficiaryError, InvalidFieldsError, InvalidPaymasterAndDataError, PaymasterDepositTooLowError, PaymasterFunctionRevertedError, PaymasterNotDeployedError, PaymasterPostOpFunctionRevertedError, PaymasterRateLimitError, PaymasterStakeTooLowError, SenderAlreadyConstructedError, SignatureCheckFailedError, SmartAccountFunctionRevertedError, UnknownBundlerError, UnsupportedSignatureAggregatorError, UserOperationExpiredError, UserOperationOutOfTimeRangeError, UserOperationPaymasterExpiredError, UserOperationPaymasterSignatureError, UserOperationRejectedByEntryPointError, UserOperationRejectedByOpCodeError, UserOperationRejectedByPaymasterError, UserOperationSignatureError, VerificationGasLimitExceededError, VerificationGasLimitTooLowError, } from '../../errors/bundler.js';\nconst bundlerErrors = [\n ExecutionRevertedError,\n InvalidFieldsError,\n PaymasterDepositTooLowError,\n PaymasterRateLimitError,\n PaymasterStakeTooLowError,\n SignatureCheckFailedError,\n UnsupportedSignatureAggregatorError,\n UserOperationOutOfTimeRangeError,\n UserOperationRejectedByEntryPointError,\n UserOperationRejectedByPaymasterError,\n UserOperationRejectedByOpCodeError,\n];\nexport function getBundlerError(err, args) {\n const message = (err.details || '').toLowerCase();\n if (AccountNotDeployedError.message.test(message))\n return new AccountNotDeployedError({\n cause: err,\n });\n if (FailedToSendToBeneficiaryError.message.test(message))\n return new FailedToSendToBeneficiaryError({\n cause: err,\n });\n if (GasValuesOverflowError.message.test(message))\n return new GasValuesOverflowError({\n cause: err,\n });\n if (HandleOpsOutOfGasError.message.test(message))\n return new HandleOpsOutOfGasError({\n cause: err,\n });\n if (InitCodeFailedError.message.test(message))\n return new InitCodeFailedError({\n cause: err,\n factory: args.factory,\n factoryData: args.factoryData,\n initCode: args.initCode,\n });\n if (InitCodeMustCreateSenderError.message.test(message))\n return new InitCodeMustCreateSenderError({\n cause: err,\n factory: args.factory,\n factoryData: args.factoryData,\n initCode: args.initCode,\n });\n if (InitCodeMustReturnSenderError.message.test(message))\n return new InitCodeMustReturnSenderError({\n cause: err,\n factory: args.factory,\n factoryData: args.factoryData,\n initCode: args.initCode,\n sender: args.sender,\n });\n if (InsufficientPrefundError.message.test(message))\n return new InsufficientPrefundError({\n cause: err,\n });\n if (InternalCallOnlyError.message.test(message))\n return new InternalCallOnlyError({\n cause: err,\n });\n if (InvalidAccountNonceError.message.test(message))\n return new InvalidAccountNonceError({\n cause: err,\n nonce: args.nonce,\n });\n if (InvalidAggregatorError.message.test(message))\n return new InvalidAggregatorError({\n cause: err,\n });\n if (InvalidBeneficiaryError.message.test(message))\n return new InvalidBeneficiaryError({\n cause: err,\n });\n if (InvalidPaymasterAndDataError.message.test(message))\n return new InvalidPaymasterAndDataError({\n cause: err,\n });\n if (PaymasterDepositTooLowError.message.test(message))\n return new PaymasterDepositTooLowError({\n cause: err,\n });\n if (PaymasterFunctionRevertedError.message.test(message))\n return new PaymasterFunctionRevertedError({\n cause: err,\n });\n if (PaymasterNotDeployedError.message.test(message))\n return new PaymasterNotDeployedError({\n cause: err,\n });\n if (PaymasterPostOpFunctionRevertedError.message.test(message))\n return new PaymasterPostOpFunctionRevertedError({\n cause: err,\n });\n if (SmartAccountFunctionRevertedError.message.test(message))\n return new SmartAccountFunctionRevertedError({\n cause: err,\n });\n if (SenderAlreadyConstructedError.message.test(message))\n return new SenderAlreadyConstructedError({\n cause: err,\n factory: args.factory,\n factoryData: args.factoryData,\n initCode: args.initCode,\n });\n if (UserOperationExpiredError.message.test(message))\n return new UserOperationExpiredError({\n cause: err,\n });\n if (UserOperationPaymasterExpiredError.message.test(message))\n return new UserOperationPaymasterExpiredError({\n cause: err,\n });\n if (UserOperationPaymasterSignatureError.message.test(message))\n return new UserOperationPaymasterSignatureError({\n cause: err,\n });\n if (UserOperationSignatureError.message.test(message))\n return new UserOperationSignatureError({\n cause: err,\n });\n if (VerificationGasLimitExceededError.message.test(message))\n return new VerificationGasLimitExceededError({\n cause: err,\n });\n if (VerificationGasLimitTooLowError.message.test(message))\n return new VerificationGasLimitTooLowError({\n cause: err,\n });\n const error = err.walk((e) => bundlerErrors.some((error) => error.code === e.code));\n if (error) {\n if (error.code === ExecutionRevertedError.code)\n return new ExecutionRevertedError({\n cause: err,\n data: error.data,\n message: error.details,\n });\n if (error.code === InvalidFieldsError.code)\n return new InvalidFieldsError({\n cause: err,\n });\n if (error.code === PaymasterDepositTooLowError.code)\n return new PaymasterDepositTooLowError({\n cause: err,\n });\n if (error.code === PaymasterRateLimitError.code)\n return new PaymasterRateLimitError({\n cause: err,\n });\n if (error.code === PaymasterStakeTooLowError.code)\n return new PaymasterStakeTooLowError({\n cause: err,\n });\n if (error.code === SignatureCheckFailedError.code)\n return new SignatureCheckFailedError({\n cause: err,\n });\n if (error.code === UnsupportedSignatureAggregatorError.code)\n return new UnsupportedSignatureAggregatorError({\n cause: err,\n });\n if (error.code === UserOperationOutOfTimeRangeError.code)\n return new UserOperationOutOfTimeRangeError({\n cause: err,\n });\n if (error.code === UserOperationRejectedByEntryPointError.code)\n return new UserOperationRejectedByEntryPointError({\n cause: err,\n });\n if (error.code === UserOperationRejectedByPaymasterError.code)\n return new UserOperationRejectedByPaymasterError({\n cause: err,\n });\n if (error.code === UserOperationRejectedByOpCodeError.code)\n return new UserOperationRejectedByOpCodeError({\n cause: err,\n });\n }\n return new UnknownBundlerError({\n cause: err,\n });\n}\n//# sourceMappingURL=getBundlerError.js.map","import { BaseError } from '../../../errors/base.js';\nimport { ContractFunctionExecutionError, ContractFunctionRevertedError, ContractFunctionZeroDataError, } from '../../../errors/contract.js';\nimport { decodeErrorResult } from '../../../utils/abi/decodeErrorResult.js';\nimport { ExecutionRevertedError } from '../../errors/bundler.js';\nimport { UserOperationExecutionError, } from '../../errors/userOperation.js';\nimport { getBundlerError, } from './getBundlerError.js';\nexport function getUserOperationError(err, { calls, docsPath, ...args }) {\n const cause = (() => {\n const cause = getBundlerError(err, args);\n if (calls && cause instanceof ExecutionRevertedError) {\n const revertData = getRevertData(cause);\n const contractCalls = calls?.filter((call) => call.abi);\n if (revertData && contractCalls.length > 0)\n return getContractError({ calls: contractCalls, revertData });\n }\n return cause;\n })();\n return new UserOperationExecutionError(cause, {\n docsPath,\n ...args,\n });\n}\n/////////////////////////////////////////////////////////////////////////////////\nfunction getRevertData(error) {\n let revertData;\n error.walk((e) => {\n const error = e;\n if (typeof error.data === 'string' ||\n typeof error.data?.revertData === 'string' ||\n (!(error instanceof BaseError) && typeof error.message === 'string')) {\n const match = (error.data?.revertData ||\n error.data ||\n error.message).match?.(/(0x[A-Za-z0-9]*)/);\n if (match) {\n revertData = match[1];\n return true;\n }\n }\n return false;\n });\n return revertData;\n}\nfunction getContractError(parameters) {\n const { calls, revertData } = parameters;\n const { abi, functionName, args, to } = (() => {\n const contractCalls = calls?.filter((call) => Boolean(call.abi));\n if (contractCalls.length === 1)\n return contractCalls[0];\n const compatContractCalls = contractCalls.filter((call) => {\n try {\n return Boolean(decodeErrorResult({\n abi: call.abi,\n data: revertData,\n }));\n }\n catch {\n return false;\n }\n });\n if (compatContractCalls.length === 1)\n return compatContractCalls[0];\n return {\n abi: [],\n functionName: contractCalls.reduce((acc, call) => `${acc ? `${acc} | ` : ''}${call.functionName}`, ''),\n args: undefined,\n to: undefined,\n };\n })();\n const cause = (() => {\n if (revertData === '0x')\n return new ContractFunctionZeroDataError({ functionName });\n return new ContractFunctionRevertedError({\n abi,\n data: revertData,\n functionName,\n });\n })();\n return new ContractFunctionExecutionError(cause, {\n abi,\n args,\n contractAddress: to,\n functionName,\n });\n}\n//# sourceMappingURL=getUserOperationError.js.map","export function formatUserOperationGas(parameters) {\n const gas = {};\n if (parameters.callGasLimit)\n gas.callGasLimit = BigInt(parameters.callGasLimit);\n if (parameters.preVerificationGas)\n gas.preVerificationGas = BigInt(parameters.preVerificationGas);\n if (parameters.verificationGasLimit)\n gas.verificationGasLimit = BigInt(parameters.verificationGasLimit);\n if (parameters.paymasterPostOpGasLimit)\n gas.paymasterPostOpGasLimit = BigInt(parameters.paymasterPostOpGasLimit);\n if (parameters.paymasterVerificationGasLimit)\n gas.paymasterVerificationGasLimit = BigInt(parameters.paymasterVerificationGasLimit);\n return gas;\n}\n//# sourceMappingURL=userOperationGas.js.map","import { numberToHex } from '../../../utils/encoding/toHex.js';\nimport { pad } from '../../../utils/index.js';\nexport function formatUserOperationRequest(request) {\n const rpcRequest = {};\n if (typeof request.callData !== 'undefined')\n rpcRequest.callData = request.callData;\n if (typeof request.callGasLimit !== 'undefined')\n rpcRequest.callGasLimit = numberToHex(request.callGasLimit);\n if (typeof request.factory !== 'undefined')\n rpcRequest.factory = request.factory;\n if (typeof request.factoryData !== 'undefined')\n rpcRequest.factoryData = request.factoryData;\n if (typeof request.initCode !== 'undefined')\n rpcRequest.initCode = request.initCode;\n if (typeof request.maxFeePerGas !== 'undefined')\n rpcRequest.maxFeePerGas = numberToHex(request.maxFeePerGas);\n if (typeof request.maxPriorityFeePerGas !== 'undefined')\n rpcRequest.maxPriorityFeePerGas = numberToHex(request.maxPriorityFeePerGas);\n if (typeof request.nonce !== 'undefined')\n rpcRequest.nonce = numberToHex(request.nonce);\n if (typeof request.paymaster !== 'undefined')\n rpcRequest.paymaster = request.paymaster;\n if (typeof request.paymasterAndData !== 'undefined')\n rpcRequest.paymasterAndData = request.paymasterAndData || '0x';\n if (typeof request.paymasterData !== 'undefined')\n rpcRequest.paymasterData = request.paymasterData;\n if (typeof request.paymasterPostOpGasLimit !== 'undefined')\n rpcRequest.paymasterPostOpGasLimit = numberToHex(request.paymasterPostOpGasLimit);\n if (typeof request.paymasterSignature !== 'undefined')\n rpcRequest.paymasterSignature = request.paymasterSignature;\n if (typeof request.paymasterVerificationGasLimit !== 'undefined')\n rpcRequest.paymasterVerificationGasLimit = numberToHex(request.paymasterVerificationGasLimit);\n if (typeof request.preVerificationGas !== 'undefined')\n rpcRequest.preVerificationGas = numberToHex(request.preVerificationGas);\n if (typeof request.sender !== 'undefined')\n rpcRequest.sender = request.sender;\n if (typeof request.signature !== 'undefined')\n rpcRequest.signature = request.signature;\n if (typeof request.verificationGasLimit !== 'undefined')\n rpcRequest.verificationGasLimit = numberToHex(request.verificationGasLimit);\n if (typeof request.authorization !== 'undefined')\n rpcRequest.eip7702Auth = formatAuthorization(request.authorization);\n return rpcRequest;\n}\nfunction formatAuthorization(authorization) {\n return {\n address: authorization.address,\n chainId: numberToHex(authorization.chainId),\n nonce: numberToHex(authorization.nonce),\n r: authorization.r\n ? numberToHex(BigInt(authorization.r), { size: 32 })\n : pad('0x', { size: 32 }),\n s: authorization.s\n ? numberToHex(BigInt(authorization.s), { size: 32 })\n : pad('0x', { size: 32 }),\n yParity: authorization.yParity\n ? numberToHex(authorization.yParity, { size: 1 })\n : pad('0x', { size: 32 }),\n };\n}\n//# sourceMappingURL=userOperationRequest.js.map","import { hexToBigInt } from '../../../utils/encoding/fromHex.js';\nimport { numberToHex } from '../../../utils/encoding/toHex.js';\nimport { formatUserOperationRequest, } from '../../utils/formatters/userOperationRequest.js';\n/**\n * Retrieves paymaster-related User Operation properties to be used for sending the User Operation.\n *\n * - Docs: https://viem.sh/account-abstraction/actions/paymaster/getPaymasterData\n *\n * @param client - Client to use\n * @param parameters - {@link GetPaymasterDataParameters}\n * @returns Paymaster-related User Operation properties. {@link GetPaymasterDataReturnType}\n *\n * @example\n * import { http } from 'viem'\n * import { createPaymasterClient, getPaymasterData } from 'viem/account-abstraction'\n *\n * const paymasterClient = createPaymasterClient({\n * transport: http('https://...'),\n * })\n *\n * const userOperation = { ... }\n *\n * const values = await getPaymasterData(paymasterClient, {\n * chainId: 1,\n * entryPointAddress: '0x...',\n * ...userOperation,\n * })\n */\nexport async function getPaymasterData(client, parameters) {\n const { chainId, entryPointAddress, context, ...userOperation } = parameters;\n const request = formatUserOperationRequest(userOperation);\n const { paymasterPostOpGasLimit, paymasterVerificationGasLimit, ...rest } = await client.request({\n method: 'pm_getPaymasterData',\n params: [\n {\n ...request,\n callGasLimit: request.callGasLimit ?? '0x0',\n verificationGasLimit: request.verificationGasLimit ?? '0x0',\n preVerificationGas: request.preVerificationGas ?? '0x0',\n },\n entryPointAddress,\n numberToHex(chainId),\n context,\n ],\n });\n return {\n ...rest,\n ...(paymasterPostOpGasLimit && {\n paymasterPostOpGasLimit: hexToBigInt(paymasterPostOpGasLimit),\n }),\n ...(paymasterVerificationGasLimit && {\n paymasterVerificationGasLimit: hexToBigInt(paymasterVerificationGasLimit),\n }),\n };\n}\n//# sourceMappingURL=getPaymasterData.js.map","import { hexToBigInt } from '../../../utils/encoding/fromHex.js';\nimport { numberToHex } from '../../../utils/encoding/toHex.js';\nimport { formatUserOperationRequest, } from '../../utils/formatters/userOperationRequest.js';\n/**\n * Retrieves paymaster-related User Operation properties to be used for gas estimation.\n *\n * - Docs: https://viem.sh/account-abstraction/actions/paymaster/getPaymasterStubData\n *\n * @param client - Client to use\n * @param parameters - {@link GetPaymasterStubDataParameters}\n * @returns Paymaster-related User Operation properties. {@link GetPaymasterStubDataReturnType}\n *\n * @example\n * import { http } from 'viem'\n * import { createPaymasterClient, getPaymasterStubData } from 'viem/account-abstraction'\n *\n * const paymasterClient = createPaymasterClient({\n * transport: http('https://...'),\n * })\n *\n * const userOperation = { ... }\n *\n * const values = await getPaymasterStubData(paymasterClient, {\n * chainId: 1,\n * entryPointAddress: '0x...',\n * ...userOperation,\n * })\n */\nexport async function getPaymasterStubData(client, parameters) {\n const { chainId, entryPointAddress, context, ...userOperation } = parameters;\n const request = formatUserOperationRequest(userOperation);\n const { paymasterPostOpGasLimit, paymasterVerificationGasLimit, ...rest } = await client.request({\n method: 'pm_getPaymasterStubData',\n params: [\n {\n ...request,\n callGasLimit: request.callGasLimit ?? '0x0',\n verificationGasLimit: request.verificationGasLimit ?? '0x0',\n preVerificationGas: request.preVerificationGas ?? '0x0',\n },\n entryPointAddress,\n numberToHex(chainId),\n context,\n ],\n });\n return {\n ...rest,\n ...(paymasterPostOpGasLimit && {\n paymasterPostOpGasLimit: hexToBigInt(paymasterPostOpGasLimit),\n }),\n ...(paymasterVerificationGasLimit && {\n paymasterVerificationGasLimit: hexToBigInt(paymasterVerificationGasLimit),\n }),\n };\n}\n//# sourceMappingURL=getPaymasterStubData.js.map","import { parseAccount, } from '../../../accounts/utils/parseAccount.js';\nimport { prepareAuthorization } from '../../../actions/index.js';\nimport { estimateFeesPerGas, } from '../../../actions/public/estimateFeesPerGas.js';\nimport { getChainId as getChainId_ } from '../../../actions/public/getChainId.js';\nimport { AccountNotFoundError } from '../../../errors/account.js';\nimport { encodeFunctionData, } from '../../../utils/abi/encodeFunctionData.js';\nimport { concat } from '../../../utils/data/concat.js';\nimport { getAction } from '../../../utils/getAction.js';\nimport { getPaymasterData as getPaymasterData_, } from '../paymaster/getPaymasterData.js';\nimport { getPaymasterStubData as getPaymasterStubData_, } from '../paymaster/getPaymasterStubData.js';\nimport { estimateUserOperationGas, } from './estimateUserOperationGas.js';\nconst defaultParameters = [\n 'factory',\n 'fees',\n 'gas',\n 'paymaster',\n 'nonce',\n 'signature',\n 'authorization',\n];\n/**\n * Prepares a User Operation and fills in missing properties.\n *\n * - Docs: https://viem.sh/actions/bundler/prepareUserOperation\n *\n * @param args - {@link PrepareUserOperationParameters}\n * @returns The User Operation. {@link PrepareUserOperationReturnType}\n *\n * @example\n * import { createBundlerClient, http } from 'viem'\n * import { toSmartAccount } from 'viem/accounts'\n * import { mainnet } from 'viem/chains'\n * import { prepareUserOperation } from 'viem/actions'\n *\n * const account = await toSmartAccount({ ... })\n *\n * const client = createBundlerClient({\n * chain: mainnet,\n * transport: http(),\n * })\n *\n * const request = await prepareUserOperation(client, {\n * account,\n * calls: [{ to: '0x...', value: parseEther('1') }],\n * })\n */\nexport async function prepareUserOperation(client, parameters_) {\n const parameters = parameters_;\n const { account: account_ = client.account, dataSuffix = typeof client.dataSuffix === 'string'\n ? client.dataSuffix\n : client.dataSuffix?.value, parameters: properties = defaultParameters, stateOverride, } = parameters;\n ////////////////////////////////////////////////////////////////////////////////\n // Assert that an Account is defined.\n ////////////////////////////////////////////////////////////////////////////////\n if (!account_)\n throw new AccountNotFoundError();\n const account = parseAccount(account_);\n ////////////////////////////////////////////////////////////////////////////////\n // Declare typed Bundler Client.\n ////////////////////////////////////////////////////////////////////////////////\n const bundlerClient = client;\n ////////////////////////////////////////////////////////////////////////////////\n // Declare Paymaster properties.\n ////////////////////////////////////////////////////////////////////////////////\n const paymaster = parameters.paymaster ?? bundlerClient?.paymaster;\n const paymasterAddress = typeof paymaster === 'string' ? paymaster : undefined;\n const { getPaymasterStubData, getPaymasterData } = (() => {\n // If `paymaster: true`, we will assume the Bundler Client supports Paymaster Actions.\n if (paymaster === true)\n return {\n getPaymasterStubData: (parameters) => getAction(bundlerClient, getPaymasterStubData_, 'getPaymasterStubData')(parameters),\n getPaymasterData: (parameters) => getAction(bundlerClient, getPaymasterData_, 'getPaymasterData')(parameters),\n };\n // If Actions are passed to `paymaster` (via Paymaster Client or directly), we will use them.\n if (typeof paymaster === 'object') {\n const { getPaymasterStubData, getPaymasterData } = paymaster;\n return {\n getPaymasterStubData: (getPaymasterData && getPaymasterStubData\n ? getPaymasterStubData\n : getPaymasterData),\n getPaymasterData: getPaymasterData && getPaymasterStubData\n ? getPaymasterData\n : undefined,\n };\n }\n // No Paymaster functions.\n return {\n getPaymasterStubData: undefined,\n getPaymasterData: undefined,\n };\n })();\n const paymasterContext = parameters.paymasterContext\n ? parameters.paymasterContext\n : bundlerClient?.paymasterContext;\n ////////////////////////////////////////////////////////////////////////////////\n // Set up the User Operation request.\n ////////////////////////////////////////////////////////////////////////////////\n let request = {\n ...parameters,\n paymaster: paymasterAddress,\n sender: account.address,\n };\n ////////////////////////////////////////////////////////////////////////////////\n // Concurrently prepare properties required to fill the User Operation.\n ////////////////////////////////////////////////////////////////////////////////\n const [callData, factory, fees, nonce, authorization] = await Promise.all([\n (async () => {\n if (parameters.calls)\n return account.encodeCalls(parameters.calls.map((call_) => {\n const call = call_;\n if (call.abi)\n return {\n data: encodeFunctionData(call),\n to: call.to,\n value: call.value,\n };\n return call;\n }));\n return parameters.callData;\n })(),\n (async () => {\n if (!properties.includes('factory'))\n return undefined;\n if (parameters.initCode)\n return { initCode: parameters.initCode };\n if (parameters.factory && parameters.factoryData) {\n return {\n factory: parameters.factory,\n factoryData: parameters.factoryData,\n };\n }\n const { factory, factoryData } = await account.getFactoryArgs();\n if (account.entryPoint.version === '0.6')\n return {\n initCode: factory && factoryData ? concat([factory, factoryData]) : undefined,\n };\n return {\n factory,\n factoryData,\n };\n })(),\n (async () => {\n if (!properties.includes('fees'))\n return undefined;\n // If we have sufficient properties for fees, return them.\n if (typeof parameters.maxFeePerGas === 'bigint' &&\n typeof parameters.maxPriorityFeePerGas === 'bigint')\n return request;\n // If the Bundler Client has a `estimateFeesPerGas` hook, run it.\n if (bundlerClient?.userOperation?.estimateFeesPerGas) {\n const fees = await bundlerClient.userOperation.estimateFeesPerGas({\n account,\n bundlerClient,\n userOperation: request,\n });\n return {\n ...request,\n ...fees,\n };\n }\n // Otherwise, we will need to estimate the fees to fill the fee properties.\n try {\n const client_ = bundlerClient.client ?? client;\n const fees = await getAction(client_, estimateFeesPerGas, 'estimateFeesPerGas')({\n chain: client_.chain,\n type: 'eip1559',\n });\n return {\n maxFeePerGas: typeof parameters.maxFeePerGas === 'bigint'\n ? parameters.maxFeePerGas\n : BigInt(\n // Bundlers unfortunately have strict rules on fee prechecks – we will need to set a generous buffer.\n 2n * fees.maxFeePerGas),\n maxPriorityFeePerGas: typeof parameters.maxPriorityFeePerGas === 'bigint'\n ? parameters.maxPriorityFeePerGas\n : BigInt(\n // Bundlers unfortunately have strict rules on fee prechecks – we will need to set a generous buffer.\n 2n * fees.maxPriorityFeePerGas),\n };\n }\n catch {\n return undefined;\n }\n })(),\n (async () => {\n if (!properties.includes('nonce'))\n return undefined;\n if (typeof parameters.nonce === 'bigint')\n return parameters.nonce;\n return account.getNonce();\n })(),\n (async () => {\n if (!properties.includes('authorization'))\n return undefined;\n if (typeof parameters.authorization === 'object')\n return parameters.authorization;\n if (account.authorization && !(await account.isDeployed())) {\n const authorization = await prepareAuthorization(account.client, account.authorization);\n return {\n ...authorization,\n r: '0xfffffffffffffffffffffffffffffff000000000000000000000000000000000',\n s: '0x7aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa',\n yParity: 1,\n };\n }\n return undefined;\n })(),\n ]);\n ////////////////////////////////////////////////////////////////////////////////\n // Fill User Operation with the prepared properties from above.\n ////////////////////////////////////////////////////////////////////////////////\n if (typeof callData !== 'undefined')\n request.callData = dataSuffix ? concat([callData, dataSuffix]) : callData;\n if (typeof factory !== 'undefined')\n request = { ...request, ...factory };\n if (typeof fees !== 'undefined')\n request = { ...request, ...fees };\n if (typeof nonce !== 'undefined')\n request.nonce = nonce;\n if (typeof authorization !== 'undefined')\n request.authorization = authorization;\n ////////////////////////////////////////////////////////////////////////////////\n // Fill User Operation with the `signature` property.\n ////////////////////////////////////////////////////////////////////////////////\n if (properties.includes('signature')) {\n if (typeof parameters.signature !== 'undefined')\n request.signature = parameters.signature;\n else\n request.signature = await account.getStubSignature(request);\n }\n ////////////////////////////////////////////////////////////////////////////////\n // `initCode` is required to be filled with EntryPoint 0.6.\n ////////////////////////////////////////////////////////////////////////////////\n // If no `initCode` is provided, we use an empty bytes string.\n if (account.entryPoint.version === '0.6' && !request.initCode)\n request.initCode = '0x';\n ////////////////////////////////////////////////////////////////////////////////\n // Fill User Operation with paymaster-related properties for **gas estimation**.\n ////////////////////////////////////////////////////////////////////////////////\n let chainId;\n async function getChainId() {\n if (chainId)\n return chainId;\n if (client.chain)\n return client.chain.id;\n const chainId_ = await getAction(client, getChainId_, 'getChainId')({});\n chainId = chainId_;\n return chainId;\n }\n // If the User Operation is intended to be sponsored, we will need to fill the paymaster-related\n // User Operation properties required to estimate the User Operation gas.\n let isPaymasterPopulated = false;\n if (properties.includes('paymaster') &&\n getPaymasterStubData &&\n !paymasterAddress &&\n !parameters.paymasterAndData) {\n const { isFinal = false, sponsor: _, ...paymasterArgs } = await getPaymasterStubData({\n chainId: await getChainId(),\n entryPointAddress: account.entryPoint.address,\n context: paymasterContext,\n ...request,\n });\n isPaymasterPopulated = isFinal;\n request = {\n ...request,\n ...paymasterArgs,\n };\n }\n ////////////////////////////////////////////////////////////////////////////////\n // `paymasterAndData` is required to be filled with EntryPoint 0.6.\n ////////////////////////////////////////////////////////////////////////////////\n // If no `paymasterAndData` is provided, we use an empty bytes string.\n if (account.entryPoint.version === '0.6' && !request.paymasterAndData)\n request.paymasterAndData = '0x';\n ////////////////////////////////////////////////////////////////////////////////\n // Fill User Operation with gas-related properties.\n ////////////////////////////////////////////////////////////////////////////////\n if (properties.includes('gas')) {\n // If the Account has opinionated gas estimation logic, run the `estimateGas` hook and\n // fill the request with the prepared gas properties.\n if (account.userOperation?.estimateGas) {\n const gas = await account.userOperation.estimateGas(request);\n request = {\n ...request,\n ...gas,\n };\n }\n // If not all the gas properties are already populated, we will need to estimate the gas\n // to fill the gas properties.\n if (typeof request.callGasLimit === 'undefined' ||\n typeof request.preVerificationGas === 'undefined' ||\n typeof request.verificationGasLimit === 'undefined' ||\n (request.paymaster &&\n typeof request.paymasterPostOpGasLimit === 'undefined') ||\n (request.paymaster &&\n typeof request.paymasterVerificationGasLimit === 'undefined')) {\n const gas = await getAction(bundlerClient, estimateUserOperationGas, 'estimateUserOperationGas')({\n account,\n // Some Bundlers fail if nullish gas values are provided for gas estimation :') –\n // so we will need to set a default zeroish value.\n callGasLimit: 0n,\n preVerificationGas: 0n,\n verificationGasLimit: 0n,\n stateOverride,\n ...(request.paymaster\n ? {\n paymasterPostOpGasLimit: 0n,\n paymasterVerificationGasLimit: 0n,\n }\n : {}),\n ...request,\n });\n request = {\n ...request,\n callGasLimit: request.callGasLimit ?? gas.callGasLimit,\n preVerificationGas: request.preVerificationGas ?? gas.preVerificationGas,\n verificationGasLimit: request.verificationGasLimit ?? gas.verificationGasLimit,\n paymasterPostOpGasLimit: request.paymasterPostOpGasLimit ?? gas.paymasterPostOpGasLimit,\n paymasterVerificationGasLimit: request.paymasterVerificationGasLimit ??\n gas.paymasterVerificationGasLimit,\n };\n }\n }\n ////////////////////////////////////////////////////////////////////////////////\n // Fill User Operation with paymaster-related properties for **sending** the User Operation.\n ////////////////////////////////////////////////////////////////////////////////\n // If the User Operation is intended to be sponsored, we will need to fill the paymaster-related\n // User Operation properties required to send the User Operation.\n if (properties.includes('paymaster') &&\n getPaymasterData &&\n !paymasterAddress &&\n !parameters.paymasterAndData &&\n !isPaymasterPopulated) {\n // Retrieve paymaster-related User Operation properties to be used for **sending** the User Operation.\n const paymaster = await getPaymasterData({\n chainId: await getChainId(),\n entryPointAddress: account.entryPoint.address,\n context: paymasterContext,\n ...request,\n });\n request = {\n ...request,\n ...paymaster,\n };\n }\n ////////////////////////////////////////////////////////////////////////////////\n // Remove redundant properties that do not conform to the User Operation schema.\n ////////////////////////////////////////////////////////////////////////////////\n delete request.calls;\n delete request.parameters;\n delete request.paymasterContext;\n if (typeof request.paymaster !== 'string')\n delete request.paymaster;\n ////////////////////////////////////////////////////////////////////////////////\n return request;\n}\n//# sourceMappingURL=prepareUserOperation.js.map","import { parseAccount, } from '../../../accounts/utils/parseAccount.js';\nimport { AccountNotFoundError } from '../../../errors/account.js';\nimport { getAction } from '../../../utils/getAction.js';\nimport { serializeStateOverride } from '../../../utils/stateOverride.js';\nimport { getUserOperationError } from '../../utils/errors/getUserOperationError.js';\nimport { formatUserOperationGas, } from '../../utils/formatters/userOperationGas.js';\nimport { formatUserOperationRequest, } from '../../utils/formatters/userOperationRequest.js';\nimport { prepareUserOperation, } from './prepareUserOperation.js';\n/**\n * Returns an estimate of gas values necessary to execute the User Operation.\n *\n * - Docs: https://viem.sh/actions/bundler/estimateUserOperationGas\n *\n * @param client - Client to use\n * @param parameters - {@link EstimateUserOperationGasParameters}\n * @returns The gas estimate (in wei). {@link EstimateUserOperationGasReturnType}\n *\n * @example\n * import { createBundlerClient, http, parseEther } from 'viem'\n * import { toSmartAccount } from 'viem/accounts'\n * import { mainnet } from 'viem/chains'\n * import { estimateUserOperationGas } from 'viem/actions'\n *\n * const account = await toSmartAccount({ ... })\n *\n * const bundlerClient = createBundlerClient({\n * chain: mainnet,\n * transport: http(),\n * })\n *\n * const values = await estimateUserOperationGas(bundlerClient, {\n * account,\n * calls: [{ to: '0x...', value: parseEther('1') }],\n * })\n */\nexport async function estimateUserOperationGas(client, parameters) {\n const { account: account_ = client.account, entryPointAddress, stateOverride, } = parameters;\n if (!account_ && !parameters.sender)\n throw new AccountNotFoundError();\n const account = account_ ? parseAccount(account_) : undefined;\n const rpcStateOverride = serializeStateOverride(stateOverride);\n const request = account\n ? await getAction(client, prepareUserOperation, 'prepareUserOperation')({\n ...parameters,\n parameters: [\n 'authorization',\n 'factory',\n 'nonce',\n 'paymaster',\n 'signature',\n ],\n })\n : parameters;\n try {\n const params = [\n formatUserOperationRequest(request),\n (entryPointAddress ?? account?.entryPoint?.address),\n ];\n const result = await client.request({\n method: 'eth_estimateUserOperationGas',\n params: rpcStateOverride ? [...params, rpcStateOverride] : [...params],\n });\n return formatUserOperationGas(result);\n }\n catch (error) {\n const calls = parameters.calls;\n throw getUserOperationError(error, {\n ...request,\n ...(calls ? { calls } : {}),\n });\n }\n}\n//# sourceMappingURL=estimateUserOperationGas.js.map","/**\n * Returns the EntryPoints that the bundler supports.\n *\n * - Docs: https://viem.sh/actions/bundler/getSupportedEntryPoints\n *\n * @param client - Client to use\n * @param parameters - {@link GetSupportedEntryPointsParameters}\n * @returns Supported Entry Points. {@link GetSupportedEntryPointsReturnType}\n *\n * @example\n * import { createBundlerClient, http, parseEther } from 'viem'\n * import { mainnet } from 'viem/chains'\n * import { getSupportedEntryPoints } from 'viem/actions'\n *\n * const bundlerClient = createBundlerClient({\n * chain: mainnet,\n * transport: http(),\n * })\n *\n * const addresses = await getSupportedEntryPoints(bundlerClient)\n */\nexport function getSupportedEntryPoints(client) {\n return client.request({ method: 'eth_supportedEntryPoints' });\n}\n//# sourceMappingURL=getSupportedEntryPoints.js.map","export function formatUserOperation(parameters) {\n const userOperation = { ...parameters };\n if (parameters.callGasLimit)\n userOperation.callGasLimit = BigInt(parameters.callGasLimit);\n if (parameters.maxFeePerGas)\n userOperation.maxFeePerGas = BigInt(parameters.maxFeePerGas);\n if (parameters.maxPriorityFeePerGas)\n userOperation.maxPriorityFeePerGas = BigInt(parameters.maxPriorityFeePerGas);\n if (parameters.nonce)\n userOperation.nonce = BigInt(parameters.nonce);\n if (parameters.paymasterPostOpGasLimit)\n userOperation.paymasterPostOpGasLimit = BigInt(parameters.paymasterPostOpGasLimit);\n if (parameters.paymasterVerificationGasLimit)\n userOperation.paymasterVerificationGasLimit = BigInt(parameters.paymasterVerificationGasLimit);\n if (parameters.preVerificationGas)\n userOperation.preVerificationGas = BigInt(parameters.preVerificationGas);\n if (parameters.verificationGasLimit)\n userOperation.verificationGasLimit = BigInt(parameters.verificationGasLimit);\n return userOperation;\n}\n//# sourceMappingURL=userOperation.js.map","import { UserOperationNotFoundError, } from '../../errors/userOperation.js';\nimport { formatUserOperation } from '../../utils/formatters/userOperation.js';\n/**\n * Retrieves information about a User Operation given a hash.\n *\n * - Docs: https://viem.sh/account-abstraction/actions/bundler/getUserOperation\n *\n * @param client - Client to use\n * @param parameters - {@link GetUserOperationParameters}\n * @returns The receipt. {@link GetUserOperationReturnType}\n *\n * @example\n * import { createBundlerClient, http } from 'viem'\n * import { mainnet } from 'viem/chains'\n * import { getUserOperation } from 'viem/actions\n *\n * const client = createBundlerClient({\n * chain: mainnet,\n * transport: http(),\n * })\n *\n * const receipt = await getUserOperation(client, {\n * hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d',\n * })\n */\nexport async function getUserOperation(client, { hash }) {\n const result = await client.request({\n method: 'eth_getUserOperationByHash',\n params: [hash],\n }, { dedupe: true });\n if (!result)\n throw new UserOperationNotFoundError({ hash });\n const { blockHash, blockNumber, entryPoint, transactionHash, userOperation } = result;\n return {\n blockHash,\n blockNumber: BigInt(blockNumber),\n entryPoint,\n transactionHash,\n userOperation: formatUserOperation(userOperation),\n };\n}\n//# sourceMappingURL=getUserOperation.js.map","import { formatLog } from '../../../utils/formatters/log.js';\nimport { formatTransactionReceipt } from '../../../utils/formatters/transactionReceipt.js';\nexport function formatUserOperationReceipt(parameters) {\n const receipt = { ...parameters };\n if (parameters.actualGasCost)\n receipt.actualGasCost = BigInt(parameters.actualGasCost);\n if (parameters.actualGasUsed)\n receipt.actualGasUsed = BigInt(parameters.actualGasUsed);\n if (parameters.logs)\n receipt.logs = parameters.logs.map((log) => formatLog(log));\n if (parameters.receipt)\n receipt.receipt = formatTransactionReceipt(receipt.receipt);\n return receipt;\n}\n//# sourceMappingURL=userOperationReceipt.js.map","import { UserOperationReceiptNotFoundError, } from '../../errors/userOperation.js';\nimport { formatUserOperationReceipt } from '../../utils/formatters/userOperationReceipt.js';\n/**\n * Returns the User Operation Receipt given a User Operation hash.\n *\n * - Docs: https://viem.sh/docs/actions/bundler/getUserOperationReceipt\n *\n * @param client - Client to use\n * @param parameters - {@link GetUserOperationReceiptParameters}\n * @returns The receipt. {@link GetUserOperationReceiptReturnType}\n *\n * @example\n * import { createBundlerClient, http } from 'viem'\n * import { mainnet } from 'viem/chains'\n * import { getUserOperationReceipt } from 'viem/actions\n *\n * const client = createBundlerClient({\n * chain: mainnet,\n * transport: http(),\n * })\n *\n * const receipt = await getUserOperationReceipt(client, {\n * hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d',\n * })\n */\nexport async function getUserOperationReceipt(client, { hash }) {\n const receipt = await client.request({\n method: 'eth_getUserOperationReceipt',\n params: [hash],\n }, { dedupe: true });\n if (!receipt)\n throw new UserOperationReceiptNotFoundError({ hash });\n return formatUserOperationReceipt(receipt);\n}\n//# sourceMappingURL=getUserOperationReceipt.js.map","import { parseAccount } from '../../../accounts/utils/parseAccount.js';\nimport { AccountNotFoundError } from '../../../errors/account.js';\nimport { getAction } from '../../../utils/getAction.js';\nimport { getUserOperationError } from '../../utils/errors/getUserOperationError.js';\nimport { formatUserOperationRequest, } from '../../utils/formatters/userOperationRequest.js';\nimport { prepareUserOperation, } from './prepareUserOperation.js';\n/**\n * Broadcasts a User Operation to the Bundler.\n *\n * - Docs: https://viem.sh/actions/bundler/sendUserOperation\n *\n * @param client - Client to use\n * @param parameters - {@link SendUserOperationParameters}\n * @returns The User Operation hash. {@link SendUserOperationReturnType}\n *\n * @example\n * import { createBundlerClient, http, parseEther } from 'viem'\n * import { mainnet } from 'viem/chains'\n * import { toSmartAccount } from 'viem/accounts'\n * import { sendUserOperation } from 'viem/actions'\n *\n * const account = await toSmartAccount({ ... })\n *\n * const bundlerClient = createBundlerClient({\n * chain: mainnet,\n * transport: http(),\n * })\n *\n * const values = await sendUserOperation(bundlerClient, {\n * account,\n * calls: [{ to: '0x...', value: parseEther('1') }],\n * })\n */\nexport async function sendUserOperation(client, parameters) {\n const { account: account_ = client.account, entryPointAddress } = parameters;\n if (!account_ && !parameters.sender)\n throw new AccountNotFoundError();\n const account = account_ ? parseAccount(account_) : undefined;\n const request = account\n ? await getAction(client, prepareUserOperation, 'prepareUserOperation')(parameters)\n : parameters;\n const signature = (parameters.signature ||\n (await account?.signUserOperation?.(request)));\n const rpcParameters = formatUserOperationRequest({\n ...request,\n signature,\n });\n try {\n return await client.request({\n method: 'eth_sendUserOperation',\n params: [\n rpcParameters,\n (entryPointAddress ?? account?.entryPoint?.address),\n ],\n }, { retryCount: 0 });\n }\n catch (error) {\n const calls = parameters.calls;\n throw getUserOperationError(error, {\n ...request,\n ...(calls ? { calls } : {}),\n signature,\n });\n }\n}\n//# sourceMappingURL=sendUserOperation.js.map","import { getAction } from '../../../utils/getAction.js';\nimport { observe } from '../../../utils/observe.js';\nimport { poll } from '../../../utils/poll.js';\nimport { stringify } from '../../../utils/stringify.js';\nimport { WaitForUserOperationReceiptTimeoutError, } from '../../errors/userOperation.js';\nimport { getUserOperationReceipt, } from './getUserOperationReceipt.js';\n/**\n * Waits for the User Operation to be included on a [Block](https://viem.sh/docs/glossary/terms#block) (one confirmation), and then returns the User Operation receipt.\n *\n * - Docs: https://viem.sh/docs/actions/bundler/waitForUserOperationReceipt\n *\n * @param client - Client to use\n * @param parameters - {@link WaitForUserOperationReceiptParameters}\n * @returns The receipt. {@link WaitForUserOperationReceiptReturnType}\n *\n * @example\n * import { createBundlerClient, http } from 'viem'\n * import { mainnet } from 'viem/chains'\n * import { waitForUserOperationReceipt } from 'viem/actions'\n *\n * const client = createBundlerClient({\n * chain: mainnet,\n * transport: http(),\n * })\n *\n * const receipt = await waitForUserOperationReceipt(client, {\n * hash: '0x4ca7ee652d57678f26e887c149ab0735f41de37bcad58c9f6d3ed5824f15b74d',\n * })\n */\nexport function waitForUserOperationReceipt(client, parameters) {\n const { hash, pollingInterval = client.pollingInterval, retryCount, timeout = 120_000, } = parameters;\n let count = 0;\n const observerId = stringify([\n 'waitForUserOperationReceipt',\n client.uid,\n hash,\n ]);\n return new Promise((resolve, reject) => {\n const unobserve = observe(observerId, { resolve, reject }, (emit) => {\n const done = (fn) => {\n unpoll();\n fn();\n unobserve();\n };\n const timeoutId = timeout\n ? setTimeout(() => done(() => emit.reject(new WaitForUserOperationReceiptTimeoutError({ hash }))), timeout)\n : undefined;\n const unpoll = poll(async () => {\n if (retryCount && count >= retryCount) {\n clearTimeout(timeoutId);\n done(() => emit.reject(new WaitForUserOperationReceiptTimeoutError({ hash })));\n }\n try {\n const receipt = await getAction(client, getUserOperationReceipt, 'getUserOperationReceipt')({ hash });\n clearTimeout(timeoutId);\n done(() => emit.resolve(receipt));\n }\n catch (err) {\n const error = err;\n if (error.name !== 'UserOperationReceiptNotFoundError') {\n clearTimeout(timeoutId);\n done(() => emit.reject(error));\n }\n }\n count++;\n }, {\n emitOnBegin: true,\n interval: pollingInterval,\n });\n return unpoll;\n });\n });\n}\n//# sourceMappingURL=waitForUserOperationReceipt.js.map","import { getChainId, } from '../../../actions/public/getChainId.js';\nimport { estimateUserOperationGas, } from '../../actions/bundler/estimateUserOperationGas.js';\nimport { getSupportedEntryPoints, } from '../../actions/bundler/getSupportedEntryPoints.js';\nimport { getUserOperation, } from '../../actions/bundler/getUserOperation.js';\nimport { getUserOperationReceipt, } from '../../actions/bundler/getUserOperationReceipt.js';\nimport { prepareUserOperation, } from '../../actions/bundler/prepareUserOperation.js';\nimport { sendUserOperation, } from '../../actions/bundler/sendUserOperation.js';\nimport { waitForUserOperationReceipt, } from '../../actions/bundler/waitForUserOperationReceipt.js';\nexport function bundlerActions(client) {\n return {\n estimateUserOperationGas: (parameters) => estimateUserOperationGas(client, parameters),\n getChainId: () => getChainId(client),\n getSupportedEntryPoints: () => getSupportedEntryPoints(client),\n getUserOperation: (parameters) => getUserOperation(client, parameters),\n getUserOperationReceipt: (parameters) => getUserOperationReceipt(client, parameters),\n prepareUserOperation: (parameters) => prepareUserOperation(client, parameters),\n sendUserOperation: (parameters) => sendUserOperation(client, parameters),\n waitForUserOperationReceipt: (parameters) => waitForUserOperationReceipt(client, parameters),\n };\n}\n//# sourceMappingURL=bundler.js.map","import { createClient, } from '../../clients/createClient.js';\nimport { bundlerActions } from './decorators/bundler.js';\nexport function createBundlerClient(parameters) {\n const { client: client_, dataSuffix, key = 'bundler', name = 'Bundler Client', paymaster, paymasterContext, transport, userOperation, } = parameters;\n const client = Object.assign(createClient({\n ...parameters,\n chain: parameters.chain ?? client_?.chain,\n key,\n name,\n transport,\n type: 'bundlerClient',\n }), {\n client: client_,\n dataSuffix: dataSuffix ?? client_?.dataSuffix,\n paymaster,\n paymasterContext,\n userOperation,\n });\n return client.extend(bundlerActions);\n}\n//# sourceMappingURL=createBundlerClient.js.map","import { createStore } from 'zustand/vanilla';\nexport const ChainClients = createStore(() => ({}));\n//# sourceMappingURL=store.js.map","import { createPublicClient, defineChain, http } from 'viem';\nimport { createBundlerClient } from 'viem/account-abstraction';\nimport { arbitrum, avalanche, base, baseSepolia, bsc, mainnet, optimism, optimismSepolia, polygon, sepolia, zora, } from 'viem/chains';\nimport { ChainClients } from './store.js';\nexport const SUPPORTED_MAINNET_CHAINS = [\n base,\n avalanche,\n arbitrum,\n polygon,\n mainnet,\n bsc,\n zora,\n optimism,\n];\nexport const SUPPORTED_TESTNET_CHAINS = [\n baseSepolia,\n sepolia,\n optimismSepolia,\n];\nconst SUPPORTED_CHAINS_BY_ID = [\n ...SUPPORTED_MAINNET_CHAINS,\n ...SUPPORTED_TESTNET_CHAINS,\n].reduce((acc, chain) => {\n acc.set(chain.id, chain);\n return acc;\n}, new Map());\n// Get fallback chain data from supported chain list\nfunction getSupportedChainById(chainId) {\n return SUPPORTED_CHAINS_BY_ID.get(chainId);\n}\n// Get fallback RPC URL from viem's chain definitions\nfunction getFallbackRpcUrl(chainId) {\n const viemChain = getSupportedChainById(chainId);\n if (viemChain?.rpcUrls?.default?.http?.[0]) {\n return viemChain.rpcUrls.default.http[0];\n }\n return undefined;\n}\nfunction defineChainConfig(chainId, rpcUrl, options) {\n const viemChain = options?.viemChain;\n const nativeCurrency = options?.nativeCurrency;\n const name = nativeCurrency?.name ?? viemChain?.name ?? '';\n const symbol = nativeCurrency?.symbol ?? viemChain?.nativeCurrency?.symbol ?? '';\n const decimals = nativeCurrency?.decimal ?? viemChain?.nativeCurrency?.decimals ?? 18;\n return defineChain({\n id: chainId,\n name,\n nativeCurrency: {\n name,\n symbol,\n decimals,\n },\n rpcUrls: {\n default: {\n http: [rpcUrl],\n },\n },\n });\n}\nexport function createClients(chains) {\n chains.forEach((c) => {\n // Use fallback RPC URL from viem if wallet hasn't provided one\n let rpcUrl = c.rpcUrl;\n if (!rpcUrl) {\n rpcUrl = getFallbackRpcUrl(c.id);\n }\n // Skip if still no RPC URL available\n if (!rpcUrl) {\n return;\n }\n const viemChain = getSupportedChainById(c.id);\n const clients = createClientPair({\n chainId: c.id,\n rpcUrl,\n nativeCurrency: c.nativeCurrency,\n viemChain,\n });\n storeClientPair(c.id, clients);\n });\n}\nfunction createClientPair(options) {\n const { chainId, rpcUrl, nativeCurrency, viemChain } = options;\n const chain = defineChainConfig(chainId, rpcUrl, {\n viemChain,\n nativeCurrency,\n });\n const client = createPublicClient({\n chain,\n transport: http(rpcUrl),\n });\n const bundlerClient = createBundlerClient({\n client,\n transport: http(rpcUrl),\n });\n return { client, bundlerClient };\n}\nfunction createFallbackClientPair(chainId) {\n const rpcUrl = getFallbackRpcUrl(chainId);\n const viemChain = getSupportedChainById(chainId);\n if (!rpcUrl) {\n return undefined;\n }\n return createClientPair({\n chainId,\n rpcUrl,\n viemChain,\n });\n}\nfunction storeClientPair(chainId, pair) {\n ChainClients.setState((state) => ({\n ...state,\n [chainId]: {\n client: pair.client,\n bundlerClient: pair.bundlerClient,\n },\n }));\n}\nexport function getClient(chainId) {\n // First check if client exists in storage\n const storedClient = ChainClients.getState()[chainId]?.client;\n if (storedClient) {\n return storedClient;\n }\n // If not in storage, try to create a fallback client\n const fallbackPair = createFallbackClientPair(chainId);\n // If we successfully created fallback clients, store them for future use\n if (fallbackPair) {\n storeClientPair(chainId, fallbackPair);\n return fallbackPair.client;\n }\n return undefined;\n}\nexport function getBundlerClient(chainId) {\n // First check if bundler client exists in storage\n const storedBundlerClient = ChainClients.getState()[chainId]?.bundlerClient;\n if (storedBundlerClient) {\n return storedBundlerClient;\n }\n // If not in storage, try to create a fallback bundler client\n const fallbackPair = createFallbackClientPair(chainId);\n // If we successfully created fallback clients, store them for future use\n if (fallbackPair) {\n storeClientPair(chainId, fallbackPair);\n return fallbackPair.bundlerClient;\n }\n return undefined;\n}\n//# sourceMappingURL=utils.js.map","import { createStore } from 'zustand/vanilla';\nconst correlationIdsStore = createStore(() => ({\n correlationIds: new Map(),\n}));\nexport const correlationIds = {\n get: (key) => {\n const correlationId = correlationIdsStore.getState().correlationIds.get(key);\n return correlationId;\n },\n set: (key, correlationId) => {\n correlationIdsStore.setState((state) => {\n const newMap = new Map(state.correlationIds);\n newMap.set(key, correlationId);\n return { correlationIds: newMap };\n });\n },\n delete: (key) => {\n correlationIdsStore.setState((state) => {\n const newMap = new Map(state.correlationIds);\n newMap.delete(key);\n return { correlationIds: newMap };\n });\n },\n clear: () => {\n correlationIdsStore.setState({\n correlationIds: new Map(),\n });\n },\n};\n//# sourceMappingURL=store.js.map","import { isAddress, isHex } from 'viem';\nimport { standardErrors } from '../core/error/errors.js';\nexport function assertSubAccount(info) {\n if (typeof info !== 'object' || info === null) {\n throw standardErrors.rpc.internal('sub account info is not an object');\n }\n if (!('address' in info)) {\n throw standardErrors.rpc.internal('sub account is invalid');\n }\n if ('address' in info && typeof info.address === 'string' && !isAddress(info.address)) {\n throw standardErrors.rpc.internal('sub account address is invalid');\n }\n if ('factory' in info && typeof info.factory === 'string' && !isAddress(info.factory)) {\n throw standardErrors.rpc.internal('sub account factory address is invalid');\n }\n if ('factoryData' in info && typeof info.factoryData === 'string' && !isHex(info.factoryData)) {\n throw standardErrors.rpc.internal('sub account factory data is invalid');\n }\n}\n//# sourceMappingURL=assertSubAccount.js.map","import { hexStringToUint8Array, uint8ArrayToHex } from '../core/type/util.js';\nexport async function generateKeyPair() {\n return crypto.subtle.generateKey({\n name: 'ECDH',\n namedCurve: 'P-256',\n }, true, ['deriveKey']);\n}\nexport async function deriveSharedSecret(ownPrivateKey, peerPublicKey) {\n return crypto.subtle.deriveKey({\n name: 'ECDH',\n public: peerPublicKey,\n }, ownPrivateKey, {\n name: 'AES-GCM',\n length: 256,\n }, false, ['encrypt', 'decrypt']);\n}\nexport async function encrypt(sharedSecret, plainText) {\n const iv = crypto.getRandomValues(new Uint8Array(12));\n const cipherText = await crypto.subtle.encrypt({\n name: 'AES-GCM',\n iv,\n }, sharedSecret, new TextEncoder().encode(plainText));\n return { iv, cipherText };\n}\nexport async function decrypt(sharedSecret, { iv, cipherText }) {\n const plainText = await crypto.subtle.decrypt({\n name: 'AES-GCM',\n iv,\n }, sharedSecret, cipherText);\n return new TextDecoder().decode(plainText);\n}\nfunction getFormat(keyType) {\n switch (keyType) {\n case 'public':\n return 'spki';\n case 'private':\n return 'pkcs8';\n }\n}\nexport async function exportKeyToHexString(type, key) {\n const format = getFormat(type);\n const exported = await crypto.subtle.exportKey(format, key);\n return uint8ArrayToHex(new Uint8Array(exported));\n}\nexport async function importKeyFromHexString(type, hexString) {\n const format = getFormat(type);\n const arrayBuffer = hexStringToUint8Array(hexString).buffer;\n return await crypto.subtle.importKey(format, new Uint8Array(arrayBuffer), {\n name: 'ECDH',\n namedCurve: 'P-256',\n }, true, type === 'private' ? ['deriveKey'] : []);\n}\nexport async function encryptContent(content, sharedSecret) {\n const serialized = JSON.stringify(content, (_, value) => {\n if (!(value instanceof Error))\n return value;\n const error = value;\n return {\n ...(error.code ? { code: error.code } : {}),\n message: error.message,\n };\n });\n return encrypt(sharedSecret, serialized);\n}\nexport async function decryptContent(encryptedData, sharedSecret) {\n return JSON.parse(await decrypt(sharedSecret, encryptedData));\n}\n//# sourceMappingURL=cipher.js.map","import { PACKAGE_NAME, PACKAGE_VERSION } from '../core/constants.js';\nimport { standardErrors } from '../core/error/errors.js';\nexport async function fetchRPCRequest(request, rpcUrl) {\n const requestBody = {\n ...request,\n jsonrpc: '2.0',\n id: crypto.randomUUID(),\n };\n const res = await fetch(rpcUrl, {\n method: 'POST',\n body: JSON.stringify(requestBody),\n mode: 'cors',\n headers: {\n 'Content-Type': 'application/json',\n 'X-Cbw-Sdk-Version': PACKAGE_VERSION,\n 'X-Cbw-Sdk-Platform': PACKAGE_NAME,\n },\n });\n const { result, error } = await res.json();\n if (error)\n throw error;\n return result;\n}\n/**\n * Validates the arguments for an invalid request and returns an error if any validation fails.\n * Valid request args are defined here: https://eips.ethereum.org/EIPS/eip-1193#request\n * @param args The request arguments to validate.\n * @returns An error object if the arguments are invalid, otherwise undefined.\n */\nexport function checkErrorForInvalidRequestArgs(args) {\n if (!args || typeof args !== 'object' || Array.isArray(args)) {\n throw standardErrors.rpc.invalidParams({\n message: 'Expected a single, non-array, object argument.',\n data: args,\n });\n }\n const { method, params } = args;\n if (typeof method !== 'string' || method.length === 0) {\n throw standardErrors.rpc.invalidParams({\n message: \"'args.method' must be a non-empty string.\",\n data: args,\n });\n }\n if (params !== undefined &&\n !Array.isArray(params) &&\n (typeof params !== 'object' || params === null)) {\n throw standardErrors.rpc.invalidParams({\n message: \"'args.params' must be an object or array if provided.\",\n data: args,\n });\n }\n switch (method) {\n case 'eth_sign':\n case 'eth_signTypedData_v2':\n case 'eth_subscribe':\n case 'eth_unsubscribe':\n throw standardErrors.provider.unsupportedMethod();\n }\n}\n//# sourceMappingURL=provider.js.map","/** @internal */\nexport const version = '0.1.1';\n//# sourceMappingURL=version.js.map","import { version } from '../version.js';\n/** @internal */\nexport function getUrl(url) {\n return url;\n}\n/** @internal */\nexport function getVersion() {\n return version;\n}\n/** @internal */\nexport function prettyPrint(args) {\n if (!args)\n return '';\n const entries = Object.entries(args)\n .map(([key, value]) => {\n if (value === undefined || value === false)\n return null;\n return [key, value];\n })\n .filter(Boolean);\n const maxLength = entries.reduce((acc, [key]) => Math.max(acc, key.length), 0);\n return entries\n .map(([key, value]) => ` ${`${key}:`.padEnd(maxLength + 1)} ${value}`)\n .join('\\n');\n}\n//# sourceMappingURL=errors.js.map","import { getVersion } from './internal/errors.js';\n/**\n * Base error class inherited by all errors thrown by ox.\n *\n * @example\n * ```ts\n * import { Errors } from 'ox'\n * throw new Errors.BaseError('An error occurred')\n * ```\n */\nexport class BaseError extends Error {\n constructor(shortMessage, options = {}) {\n const details = (() => {\n if (options.cause instanceof BaseError) {\n if (options.cause.details)\n return options.cause.details;\n if (options.cause.shortMessage)\n return options.cause.shortMessage;\n }\n if (options.cause?.message)\n return options.cause.message;\n return options.details;\n })();\n const docsPath = (() => {\n if (options.cause instanceof BaseError)\n return options.cause.docsPath || options.docsPath;\n return options.docsPath;\n })();\n const docsBaseUrl = 'https://oxlib.sh';\n const docs = `${docsBaseUrl}${docsPath ?? ''}`;\n const message = [\n shortMessage || 'An error occurred.',\n ...(options.metaMessages ? ['', ...options.metaMessages] : []),\n ...(details || docsPath\n ? [\n '',\n details ? `Details: ${details}` : undefined,\n docsPath ? `See: ${docs}` : undefined,\n ]\n : []),\n ]\n .filter((x) => typeof x === 'string')\n .join('\\n');\n super(message, options.cause ? { cause: options.cause } : undefined);\n Object.defineProperty(this, \"details\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: void 0\n });\n Object.defineProperty(this, \"docs\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: void 0\n });\n Object.defineProperty(this, \"docsPath\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: void 0\n });\n Object.defineProperty(this, \"shortMessage\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: void 0\n });\n Object.defineProperty(this, \"cause\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: void 0\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'BaseError'\n });\n Object.defineProperty(this, \"version\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: `ox@${getVersion()}`\n });\n this.cause = options.cause;\n this.details = details;\n this.docs = docs;\n this.docsPath = docsPath;\n this.shortMessage = shortMessage;\n }\n walk(fn) {\n return walk(this, fn);\n }\n}\n/** @internal */\nfunction walk(err, fn) {\n if (fn?.(err))\n return err;\n if (err && typeof err === 'object' && 'cause' in err && err.cause)\n return walk(err.cause, fn);\n return fn ? null : err;\n}\n//# sourceMappingURL=Errors.js.map","/**\n * Utilities for hex, bytes, CSPRNG.\n * @module\n */\n/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */\n// We use WebCrypto aka globalThis.crypto, which exists in browsers and node.js 16+.\n// node.js versions earlier than v19 don't declare it in global scope.\n// For node.js, package.json#exports field mapping rewrites import\n// from `crypto` to `cryptoNode`, which imports native module.\n// Makes the utils un-importable in browsers without a bundler.\n// Once node.js 18 is deprecated (2025-04-30), we can just drop the import.\nimport { crypto } from '@noble/hashes/crypto';\n/** Checks if something is Uint8Array. Be careful: nodejs Buffer will return true. */\nexport function isBytes(a) {\n return a instanceof Uint8Array || (ArrayBuffer.isView(a) && a.constructor.name === 'Uint8Array');\n}\n/** Asserts something is positive integer. */\nexport function anumber(n) {\n if (!Number.isSafeInteger(n) || n < 0)\n throw new Error('positive integer expected, got ' + n);\n}\n/** Asserts something is Uint8Array. */\nexport function abytes(b, ...lengths) {\n if (!isBytes(b))\n throw new Error('Uint8Array expected');\n if (lengths.length > 0 && !lengths.includes(b.length))\n throw new Error('Uint8Array expected of length ' + lengths + ', got length=' + b.length);\n}\n/** Asserts something is hash */\nexport function ahash(h) {\n if (typeof h !== 'function' || typeof h.create !== 'function')\n throw new Error('Hash should be wrapped by utils.createHasher');\n anumber(h.outputLen);\n anumber(h.blockLen);\n}\n/** Asserts a hash instance has not been destroyed / finished */\nexport function aexists(instance, checkFinished = true) {\n if (instance.destroyed)\n throw new Error('Hash instance has been destroyed');\n if (checkFinished && instance.finished)\n throw new Error('Hash#digest() has already been called');\n}\n/** Asserts output is properly-sized byte array */\nexport function aoutput(out, instance) {\n abytes(out);\n const min = instance.outputLen;\n if (out.length < min) {\n throw new Error('digestInto() expects output buffer of length at least ' + min);\n }\n}\n/** Cast u8 / u16 / u32 to u8. */\nexport function u8(arr) {\n return new Uint8Array(arr.buffer, arr.byteOffset, arr.byteLength);\n}\n/** Cast u8 / u16 / u32 to u32. */\nexport function u32(arr) {\n return new Uint32Array(arr.buffer, arr.byteOffset, Math.floor(arr.byteLength / 4));\n}\n/** Zeroize a byte array. Warning: JS provides no guarantees. */\nexport function clean(...arrays) {\n for (let i = 0; i < arrays.length; i++) {\n arrays[i].fill(0);\n }\n}\n/** Create DataView of an array for easy byte-level manipulation. */\nexport function createView(arr) {\n return new DataView(arr.buffer, arr.byteOffset, arr.byteLength);\n}\n/** The rotate right (circular right shift) operation for uint32 */\nexport function rotr(word, shift) {\n return (word << (32 - shift)) | (word >>> shift);\n}\n/** The rotate left (circular left shift) operation for uint32 */\nexport function rotl(word, shift) {\n return (word << shift) | ((word >>> (32 - shift)) >>> 0);\n}\n/** Is current platform little-endian? Most are. Big-Endian platform: IBM */\nexport const isLE = /* @__PURE__ */ (() => new Uint8Array(new Uint32Array([0x11223344]).buffer)[0] === 0x44)();\n/** The byte swap operation for uint32 */\nexport function byteSwap(word) {\n return (((word << 24) & 0xff000000) |\n ((word << 8) & 0xff0000) |\n ((word >>> 8) & 0xff00) |\n ((word >>> 24) & 0xff));\n}\n/** Conditionally byte swap if on a big-endian platform */\nexport const swap8IfBE = isLE\n ? (n) => n\n : (n) => byteSwap(n);\n/** @deprecated */\nexport const byteSwapIfBE = swap8IfBE;\n/** In place byte swap for Uint32Array */\nexport function byteSwap32(arr) {\n for (let i = 0; i < arr.length; i++) {\n arr[i] = byteSwap(arr[i]);\n }\n return arr;\n}\nexport const swap32IfBE = isLE\n ? (u) => u\n : byteSwap32;\n// Built-in hex conversion https://caniuse.com/mdn-javascript_builtins_uint8array_fromhex\nconst hasHexBuiltin = /* @__PURE__ */ (() => \n// @ts-ignore\ntypeof Uint8Array.from([]).toHex === 'function' && typeof Uint8Array.fromHex === 'function')();\n// Array where index 0xf0 (240) is mapped to string 'f0'\nconst hexes = /* @__PURE__ */ Array.from({ length: 256 }, (_, i) => i.toString(16).padStart(2, '0'));\n/**\n * Convert byte array to hex string. Uses built-in function, when available.\n * @example bytesToHex(Uint8Array.from([0xca, 0xfe, 0x01, 0x23])) // 'cafe0123'\n */\nexport function bytesToHex(bytes) {\n abytes(bytes);\n // @ts-ignore\n if (hasHexBuiltin)\n return bytes.toHex();\n // pre-caching improves the speed 6x\n let hex = '';\n for (let i = 0; i < bytes.length; i++) {\n hex += hexes[bytes[i]];\n }\n return hex;\n}\n// We use optimized technique to convert hex string to byte array\nconst asciis = { _0: 48, _9: 57, A: 65, F: 70, a: 97, f: 102 };\nfunction asciiToBase16(ch) {\n if (ch >= asciis._0 && ch <= asciis._9)\n return ch - asciis._0; // '2' => 50-48\n if (ch >= asciis.A && ch <= asciis.F)\n return ch - (asciis.A - 10); // 'B' => 66-(65-10)\n if (ch >= asciis.a && ch <= asciis.f)\n return ch - (asciis.a - 10); // 'b' => 98-(97-10)\n return;\n}\n/**\n * Convert hex string to byte array. Uses built-in function, when available.\n * @example hexToBytes('cafe0123') // Uint8Array.from([0xca, 0xfe, 0x01, 0x23])\n */\nexport function hexToBytes(hex) {\n if (typeof hex !== 'string')\n throw new Error('hex string expected, got ' + typeof hex);\n // @ts-ignore\n if (hasHexBuiltin)\n return Uint8Array.fromHex(hex);\n const hl = hex.length;\n const al = hl / 2;\n if (hl % 2)\n throw new Error('hex string expected, got unpadded hex of length ' + hl);\n const array = new Uint8Array(al);\n for (let ai = 0, hi = 0; ai < al; ai++, hi += 2) {\n const n1 = asciiToBase16(hex.charCodeAt(hi));\n const n2 = asciiToBase16(hex.charCodeAt(hi + 1));\n if (n1 === undefined || n2 === undefined) {\n const char = hex[hi] + hex[hi + 1];\n throw new Error('hex string expected, got non-hex character \"' + char + '\" at index ' + hi);\n }\n array[ai] = n1 * 16 + n2; // multiply first octet, e.g. 'a3' => 10*16+3 => 160 + 3 => 163\n }\n return array;\n}\n/**\n * There is no setImmediate in browser and setTimeout is slow.\n * Call of async fn will return Promise, which will be fullfiled only on\n * next scheduler queue processing step and this is exactly what we need.\n */\nexport const nextTick = async () => { };\n/** Returns control to thread each 'tick' ms to avoid blocking. */\nexport async function asyncLoop(iters, tick, cb) {\n let ts = Date.now();\n for (let i = 0; i < iters; i++) {\n cb(i);\n // Date.now() is not monotonic, so in case if clock goes backwards we return return control too\n const diff = Date.now() - ts;\n if (diff >= 0 && diff < tick)\n continue;\n await nextTick();\n ts += diff;\n }\n}\n/**\n * Converts string to bytes using UTF8 encoding.\n * @example utf8ToBytes('abc') // Uint8Array.from([97, 98, 99])\n */\nexport function utf8ToBytes(str) {\n if (typeof str !== 'string')\n throw new Error('string expected');\n return new Uint8Array(new TextEncoder().encode(str)); // https://bugzil.la/1681809\n}\n/**\n * Converts bytes to string using UTF8 encoding.\n * @example bytesToUtf8(Uint8Array.from([97, 98, 99])) // 'abc'\n */\nexport function bytesToUtf8(bytes) {\n return new TextDecoder().decode(bytes);\n}\n/**\n * Normalizes (non-hex) string or Uint8Array to Uint8Array.\n * Warning: when Uint8Array is passed, it would NOT get copied.\n * Keep in mind for future mutable operations.\n */\nexport function toBytes(data) {\n if (typeof data === 'string')\n data = utf8ToBytes(data);\n abytes(data);\n return data;\n}\n/**\n * Helper for KDFs: consumes uint8array or string.\n * When string is passed, does utf8 decoding, using TextDecoder.\n */\nexport function kdfInputToBytes(data) {\n if (typeof data === 'string')\n data = utf8ToBytes(data);\n abytes(data);\n return data;\n}\n/** Copies several Uint8Arrays into one. */\nexport function concatBytes(...arrays) {\n let sum = 0;\n for (let i = 0; i < arrays.length; i++) {\n const a = arrays[i];\n abytes(a);\n sum += a.length;\n }\n const res = new Uint8Array(sum);\n for (let i = 0, pad = 0; i < arrays.length; i++) {\n const a = arrays[i];\n res.set(a, pad);\n pad += a.length;\n }\n return res;\n}\nexport function checkOpts(defaults, opts) {\n if (opts !== undefined && {}.toString.call(opts) !== '[object Object]')\n throw new Error('options should be object or undefined');\n const merged = Object.assign(defaults, opts);\n return merged;\n}\n/** For runtime check if class implements interface */\nexport class Hash {\n}\n/** Wraps hash function, creating an interface on top of it */\nexport function createHasher(hashCons) {\n const hashC = (msg) => hashCons().update(toBytes(msg)).digest();\n const tmp = hashCons();\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = () => hashCons();\n return hashC;\n}\nexport function createOptHasher(hashCons) {\n const hashC = (msg, opts) => hashCons(opts).update(toBytes(msg)).digest();\n const tmp = hashCons({});\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = (opts) => hashCons(opts);\n return hashC;\n}\nexport function createXOFer(hashCons) {\n const hashC = (msg, opts) => hashCons(opts).update(toBytes(msg)).digest();\n const tmp = hashCons({});\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = (opts) => hashCons(opts);\n return hashC;\n}\nexport const wrapConstructor = createHasher;\nexport const wrapConstructorWithOpts = createOptHasher;\nexport const wrapXOFConstructorWithOpts = createXOFer;\n/** Cryptographically secure PRNG. Uses internal OS-level `crypto.getRandomValues`. */\nexport function randomBytes(bytesLength = 32) {\n if (crypto && typeof crypto.getRandomValues === 'function') {\n return crypto.getRandomValues(new Uint8Array(bytesLength));\n }\n // Legacy Node.js compatibility\n if (crypto && typeof crypto.randomBytes === 'function') {\n return Uint8Array.from(crypto.randomBytes(bytesLength));\n }\n throw new Error('crypto.getRandomValues must be defined');\n}\n//# sourceMappingURL=utils.js.map","/**\n * Internal Merkle-Damgard hash utils.\n * @module\n */\nimport { Hash, abytes, aexists, aoutput, clean, createView, toBytes } from \"./utils.js\";\n/** Polyfill for Safari 14. https://caniuse.com/mdn-javascript_builtins_dataview_setbiguint64 */\nexport function setBigUint64(view, byteOffset, value, isLE) {\n if (typeof view.setBigUint64 === 'function')\n return view.setBigUint64(byteOffset, value, isLE);\n const _32n = BigInt(32);\n const _u32_max = BigInt(0xffffffff);\n const wh = Number((value >> _32n) & _u32_max);\n const wl = Number(value & _u32_max);\n const h = isLE ? 4 : 0;\n const l = isLE ? 0 : 4;\n view.setUint32(byteOffset + h, wh, isLE);\n view.setUint32(byteOffset + l, wl, isLE);\n}\n/** Choice: a ? b : c */\nexport function Chi(a, b, c) {\n return (a & b) ^ (~a & c);\n}\n/** Majority function, true if any two inputs is true. */\nexport function Maj(a, b, c) {\n return (a & b) ^ (a & c) ^ (b & c);\n}\n/**\n * Merkle-Damgard hash construction base class.\n * Could be used to create MD5, RIPEMD, SHA1, SHA2.\n */\nexport class HashMD extends Hash {\n constructor(blockLen, outputLen, padOffset, isLE) {\n super();\n this.finished = false;\n this.length = 0;\n this.pos = 0;\n this.destroyed = false;\n this.blockLen = blockLen;\n this.outputLen = outputLen;\n this.padOffset = padOffset;\n this.isLE = isLE;\n this.buffer = new Uint8Array(blockLen);\n this.view = createView(this.buffer);\n }\n update(data) {\n aexists(this);\n data = toBytes(data);\n abytes(data);\n const { view, buffer, blockLen } = this;\n const len = data.length;\n for (let pos = 0; pos < len;) {\n const take = Math.min(blockLen - this.pos, len - pos);\n // Fast path: we have at least one block in input, cast it to view and process\n if (take === blockLen) {\n const dataView = createView(data);\n for (; blockLen <= len - pos; pos += blockLen)\n this.process(dataView, pos);\n continue;\n }\n buffer.set(data.subarray(pos, pos + take), this.pos);\n this.pos += take;\n pos += take;\n if (this.pos === blockLen) {\n this.process(view, 0);\n this.pos = 0;\n }\n }\n this.length += data.length;\n this.roundClean();\n return this;\n }\n digestInto(out) {\n aexists(this);\n aoutput(out, this);\n this.finished = true;\n // Padding\n // We can avoid allocation of buffer for padding completely if it\n // was previously not allocated here. But it won't change performance.\n const { buffer, view, blockLen, isLE } = this;\n let { pos } = this;\n // append the bit '1' to the message\n buffer[pos++] = 0b10000000;\n clean(this.buffer.subarray(pos));\n // we have less than padOffset left in buffer, so we cannot put length in\n // current block, need process it and pad again\n if (this.padOffset > blockLen - pos) {\n this.process(view, 0);\n pos = 0;\n }\n // Pad until full block byte with zeros\n for (let i = pos; i < blockLen; i++)\n buffer[i] = 0;\n // Note: sha512 requires length to be 128bit integer, but length in JS will overflow before that\n // You need to write around 2 exabytes (u64_max / 8 / (1024**6)) for this to happen.\n // So we just write lowest 64 bits of that value.\n setBigUint64(view, blockLen - 8, BigInt(this.length * 8), isLE);\n this.process(view, 0);\n const oview = createView(out);\n const len = this.outputLen;\n // NOTE: we do division by 4 later, which should be fused in single op with modulo by JIT\n if (len % 4)\n throw new Error('_sha2: outputLen should be aligned to 32bit');\n const outLen = len / 4;\n const state = this.get();\n if (outLen > state.length)\n throw new Error('_sha2: outputLen bigger than state');\n for (let i = 0; i < outLen; i++)\n oview.setUint32(4 * i, state[i], isLE);\n }\n digest() {\n const { buffer, outputLen } = this;\n this.digestInto(buffer);\n const res = buffer.slice(0, outputLen);\n this.destroy();\n return res;\n }\n _cloneInto(to) {\n to || (to = new this.constructor());\n to.set(...this.get());\n const { blockLen, buffer, length, finished, destroyed, pos } = this;\n to.destroyed = destroyed;\n to.finished = finished;\n to.length = length;\n to.pos = pos;\n if (length % blockLen)\n to.buffer.set(buffer);\n return to;\n }\n clone() {\n return this._cloneInto();\n }\n}\n/**\n * Initial SHA-2 state: fractional parts of square roots of first 16 primes 2..53.\n * Check out `test/misc/sha2-gen-iv.js` for recomputation guide.\n */\n/** Initial SHA256 state. Bits 0..32 of frac part of sqrt of primes 2..19 */\nexport const SHA256_IV = /* @__PURE__ */ Uint32Array.from([\n 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19,\n]);\n/** Initial SHA224 state. Bits 32..64 of frac part of sqrt of primes 23..53 */\nexport const SHA224_IV = /* @__PURE__ */ Uint32Array.from([\n 0xc1059ed8, 0x367cd507, 0x3070dd17, 0xf70e5939, 0xffc00b31, 0x68581511, 0x64f98fa7, 0xbefa4fa4,\n]);\n/** Initial SHA384 state. Bits 0..64 of frac part of sqrt of primes 23..53 */\nexport const SHA384_IV = /* @__PURE__ */ Uint32Array.from([\n 0xcbbb9d5d, 0xc1059ed8, 0x629a292a, 0x367cd507, 0x9159015a, 0x3070dd17, 0x152fecd8, 0xf70e5939,\n 0x67332667, 0xffc00b31, 0x8eb44a87, 0x68581511, 0xdb0c2e0d, 0x64f98fa7, 0x47b5481d, 0xbefa4fa4,\n]);\n/** Initial SHA512 state. Bits 0..64 of frac part of sqrt of primes 2..19 */\nexport const SHA512_IV = /* @__PURE__ */ Uint32Array.from([\n 0x6a09e667, 0xf3bcc908, 0xbb67ae85, 0x84caa73b, 0x3c6ef372, 0xfe94f82b, 0xa54ff53a, 0x5f1d36f1,\n 0x510e527f, 0xade682d1, 0x9b05688c, 0x2b3e6c1f, 0x1f83d9ab, 0xfb41bd6b, 0x5be0cd19, 0x137e2179,\n]);\n//# sourceMappingURL=_md.js.map","/**\n * SHA2 hash function. A.k.a. sha256, sha384, sha512, sha512_224, sha512_256.\n * SHA256 is the fastest hash implementable in JS, even faster than Blake3.\n * Check out [RFC 4634](https://datatracker.ietf.org/doc/html/rfc4634) and\n * [FIPS 180-4](https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.180-4.pdf).\n * @module\n */\nimport { Chi, HashMD, Maj, SHA224_IV, SHA256_IV, SHA384_IV, SHA512_IV } from \"./_md.js\";\nimport * as u64 from \"./_u64.js\";\nimport { clean, createHasher, rotr } from \"./utils.js\";\n/**\n * Round constants:\n * First 32 bits of fractional parts of the cube roots of the first 64 primes 2..311)\n */\n// prettier-ignore\nconst SHA256_K = /* @__PURE__ */ Uint32Array.from([\n 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5,\n 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174,\n 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da,\n 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967,\n 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85,\n 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070,\n 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3,\n 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2\n]);\n/** Reusable temporary buffer. \"W\" comes straight from spec. */\nconst SHA256_W = /* @__PURE__ */ new Uint32Array(64);\nexport class SHA256 extends HashMD {\n constructor(outputLen = 32) {\n super(64, outputLen, 8, false);\n // We cannot use array here since array allows indexing by variable\n // which means optimizer/compiler cannot use registers.\n this.A = SHA256_IV[0] | 0;\n this.B = SHA256_IV[1] | 0;\n this.C = SHA256_IV[2] | 0;\n this.D = SHA256_IV[3] | 0;\n this.E = SHA256_IV[4] | 0;\n this.F = SHA256_IV[5] | 0;\n this.G = SHA256_IV[6] | 0;\n this.H = SHA256_IV[7] | 0;\n }\n get() {\n const { A, B, C, D, E, F, G, H } = this;\n return [A, B, C, D, E, F, G, H];\n }\n // prettier-ignore\n set(A, B, C, D, E, F, G, H) {\n this.A = A | 0;\n this.B = B | 0;\n this.C = C | 0;\n this.D = D | 0;\n this.E = E | 0;\n this.F = F | 0;\n this.G = G | 0;\n this.H = H | 0;\n }\n process(view, offset) {\n // Extend the first 16 words into the remaining 48 words w[16..63] of the message schedule array\n for (let i = 0; i < 16; i++, offset += 4)\n SHA256_W[i] = view.getUint32(offset, false);\n for (let i = 16; i < 64; i++) {\n const W15 = SHA256_W[i - 15];\n const W2 = SHA256_W[i - 2];\n const s0 = rotr(W15, 7) ^ rotr(W15, 18) ^ (W15 >>> 3);\n const s1 = rotr(W2, 17) ^ rotr(W2, 19) ^ (W2 >>> 10);\n SHA256_W[i] = (s1 + SHA256_W[i - 7] + s0 + SHA256_W[i - 16]) | 0;\n }\n // Compression function main loop, 64 rounds\n let { A, B, C, D, E, F, G, H } = this;\n for (let i = 0; i < 64; i++) {\n const sigma1 = rotr(E, 6) ^ rotr(E, 11) ^ rotr(E, 25);\n const T1 = (H + sigma1 + Chi(E, F, G) + SHA256_K[i] + SHA256_W[i]) | 0;\n const sigma0 = rotr(A, 2) ^ rotr(A, 13) ^ rotr(A, 22);\n const T2 = (sigma0 + Maj(A, B, C)) | 0;\n H = G;\n G = F;\n F = E;\n E = (D + T1) | 0;\n D = C;\n C = B;\n B = A;\n A = (T1 + T2) | 0;\n }\n // Add the compressed chunk to the current hash value\n A = (A + this.A) | 0;\n B = (B + this.B) | 0;\n C = (C + this.C) | 0;\n D = (D + this.D) | 0;\n E = (E + this.E) | 0;\n F = (F + this.F) | 0;\n G = (G + this.G) | 0;\n H = (H + this.H) | 0;\n this.set(A, B, C, D, E, F, G, H);\n }\n roundClean() {\n clean(SHA256_W);\n }\n destroy() {\n this.set(0, 0, 0, 0, 0, 0, 0, 0);\n clean(this.buffer);\n }\n}\nexport class SHA224 extends SHA256 {\n constructor() {\n super(28);\n this.A = SHA224_IV[0] | 0;\n this.B = SHA224_IV[1] | 0;\n this.C = SHA224_IV[2] | 0;\n this.D = SHA224_IV[3] | 0;\n this.E = SHA224_IV[4] | 0;\n this.F = SHA224_IV[5] | 0;\n this.G = SHA224_IV[6] | 0;\n this.H = SHA224_IV[7] | 0;\n }\n}\n// SHA2-512 is slower than sha256 in js because u64 operations are slow.\n// Round contants\n// First 32 bits of the fractional parts of the cube roots of the first 80 primes 2..409\n// prettier-ignore\nconst K512 = /* @__PURE__ */ (() => u64.split([\n '0x428a2f98d728ae22', '0x7137449123ef65cd', '0xb5c0fbcfec4d3b2f', '0xe9b5dba58189dbbc',\n '0x3956c25bf348b538', '0x59f111f1b605d019', '0x923f82a4af194f9b', '0xab1c5ed5da6d8118',\n '0xd807aa98a3030242', '0x12835b0145706fbe', '0x243185be4ee4b28c', '0x550c7dc3d5ffb4e2',\n '0x72be5d74f27b896f', '0x80deb1fe3b1696b1', '0x9bdc06a725c71235', '0xc19bf174cf692694',\n '0xe49b69c19ef14ad2', '0xefbe4786384f25e3', '0x0fc19dc68b8cd5b5', '0x240ca1cc77ac9c65',\n '0x2de92c6f592b0275', '0x4a7484aa6ea6e483', '0x5cb0a9dcbd41fbd4', '0x76f988da831153b5',\n '0x983e5152ee66dfab', '0xa831c66d2db43210', '0xb00327c898fb213f', '0xbf597fc7beef0ee4',\n '0xc6e00bf33da88fc2', '0xd5a79147930aa725', '0x06ca6351e003826f', '0x142929670a0e6e70',\n '0x27b70a8546d22ffc', '0x2e1b21385c26c926', '0x4d2c6dfc5ac42aed', '0x53380d139d95b3df',\n '0x650a73548baf63de', '0x766a0abb3c77b2a8', '0x81c2c92e47edaee6', '0x92722c851482353b',\n '0xa2bfe8a14cf10364', '0xa81a664bbc423001', '0xc24b8b70d0f89791', '0xc76c51a30654be30',\n '0xd192e819d6ef5218', '0xd69906245565a910', '0xf40e35855771202a', '0x106aa07032bbd1b8',\n '0x19a4c116b8d2d0c8', '0x1e376c085141ab53', '0x2748774cdf8eeb99', '0x34b0bcb5e19b48a8',\n '0x391c0cb3c5c95a63', '0x4ed8aa4ae3418acb', '0x5b9cca4f7763e373', '0x682e6ff3d6b2b8a3',\n '0x748f82ee5defb2fc', '0x78a5636f43172f60', '0x84c87814a1f0ab72', '0x8cc702081a6439ec',\n '0x90befffa23631e28', '0xa4506cebde82bde9', '0xbef9a3f7b2c67915', '0xc67178f2e372532b',\n '0xca273eceea26619c', '0xd186b8c721c0c207', '0xeada7dd6cde0eb1e', '0xf57d4f7fee6ed178',\n '0x06f067aa72176fba', '0x0a637dc5a2c898a6', '0x113f9804bef90dae', '0x1b710b35131c471b',\n '0x28db77f523047d84', '0x32caab7b40c72493', '0x3c9ebe0a15c9bebc', '0x431d67c49c100d4c',\n '0x4cc5d4becb3e42b6', '0x597f299cfc657e2a', '0x5fcb6fab3ad6faec', '0x6c44198c4a475817'\n].map(n => BigInt(n))))();\nconst SHA512_Kh = /* @__PURE__ */ (() => K512[0])();\nconst SHA512_Kl = /* @__PURE__ */ (() => K512[1])();\n// Reusable temporary buffers\nconst SHA512_W_H = /* @__PURE__ */ new Uint32Array(80);\nconst SHA512_W_L = /* @__PURE__ */ new Uint32Array(80);\nexport class SHA512 extends HashMD {\n constructor(outputLen = 64) {\n super(128, outputLen, 16, false);\n // We cannot use array here since array allows indexing by variable\n // which means optimizer/compiler cannot use registers.\n // h -- high 32 bits, l -- low 32 bits\n this.Ah = SHA512_IV[0] | 0;\n this.Al = SHA512_IV[1] | 0;\n this.Bh = SHA512_IV[2] | 0;\n this.Bl = SHA512_IV[3] | 0;\n this.Ch = SHA512_IV[4] | 0;\n this.Cl = SHA512_IV[5] | 0;\n this.Dh = SHA512_IV[6] | 0;\n this.Dl = SHA512_IV[7] | 0;\n this.Eh = SHA512_IV[8] | 0;\n this.El = SHA512_IV[9] | 0;\n this.Fh = SHA512_IV[10] | 0;\n this.Fl = SHA512_IV[11] | 0;\n this.Gh = SHA512_IV[12] | 0;\n this.Gl = SHA512_IV[13] | 0;\n this.Hh = SHA512_IV[14] | 0;\n this.Hl = SHA512_IV[15] | 0;\n }\n // prettier-ignore\n get() {\n const { Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl } = this;\n return [Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl];\n }\n // prettier-ignore\n set(Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl) {\n this.Ah = Ah | 0;\n this.Al = Al | 0;\n this.Bh = Bh | 0;\n this.Bl = Bl | 0;\n this.Ch = Ch | 0;\n this.Cl = Cl | 0;\n this.Dh = Dh | 0;\n this.Dl = Dl | 0;\n this.Eh = Eh | 0;\n this.El = El | 0;\n this.Fh = Fh | 0;\n this.Fl = Fl | 0;\n this.Gh = Gh | 0;\n this.Gl = Gl | 0;\n this.Hh = Hh | 0;\n this.Hl = Hl | 0;\n }\n process(view, offset) {\n // Extend the first 16 words into the remaining 64 words w[16..79] of the message schedule array\n for (let i = 0; i < 16; i++, offset += 4) {\n SHA512_W_H[i] = view.getUint32(offset);\n SHA512_W_L[i] = view.getUint32((offset += 4));\n }\n for (let i = 16; i < 80; i++) {\n // s0 := (w[i-15] rightrotate 1) xor (w[i-15] rightrotate 8) xor (w[i-15] rightshift 7)\n const W15h = SHA512_W_H[i - 15] | 0;\n const W15l = SHA512_W_L[i - 15] | 0;\n const s0h = u64.rotrSH(W15h, W15l, 1) ^ u64.rotrSH(W15h, W15l, 8) ^ u64.shrSH(W15h, W15l, 7);\n const s0l = u64.rotrSL(W15h, W15l, 1) ^ u64.rotrSL(W15h, W15l, 8) ^ u64.shrSL(W15h, W15l, 7);\n // s1 := (w[i-2] rightrotate 19) xor (w[i-2] rightrotate 61) xor (w[i-2] rightshift 6)\n const W2h = SHA512_W_H[i - 2] | 0;\n const W2l = SHA512_W_L[i - 2] | 0;\n const s1h = u64.rotrSH(W2h, W2l, 19) ^ u64.rotrBH(W2h, W2l, 61) ^ u64.shrSH(W2h, W2l, 6);\n const s1l = u64.rotrSL(W2h, W2l, 19) ^ u64.rotrBL(W2h, W2l, 61) ^ u64.shrSL(W2h, W2l, 6);\n // SHA256_W[i] = s0 + s1 + SHA256_W[i - 7] + SHA256_W[i - 16];\n const SUMl = u64.add4L(s0l, s1l, SHA512_W_L[i - 7], SHA512_W_L[i - 16]);\n const SUMh = u64.add4H(SUMl, s0h, s1h, SHA512_W_H[i - 7], SHA512_W_H[i - 16]);\n SHA512_W_H[i] = SUMh | 0;\n SHA512_W_L[i] = SUMl | 0;\n }\n let { Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl } = this;\n // Compression function main loop, 80 rounds\n for (let i = 0; i < 80; i++) {\n // S1 := (e rightrotate 14) xor (e rightrotate 18) xor (e rightrotate 41)\n const sigma1h = u64.rotrSH(Eh, El, 14) ^ u64.rotrSH(Eh, El, 18) ^ u64.rotrBH(Eh, El, 41);\n const sigma1l = u64.rotrSL(Eh, El, 14) ^ u64.rotrSL(Eh, El, 18) ^ u64.rotrBL(Eh, El, 41);\n //const T1 = (H + sigma1 + Chi(E, F, G) + SHA256_K[i] + SHA256_W[i]) | 0;\n const CHIh = (Eh & Fh) ^ (~Eh & Gh);\n const CHIl = (El & Fl) ^ (~El & Gl);\n // T1 = H + sigma1 + Chi(E, F, G) + SHA512_K[i] + SHA512_W[i]\n // prettier-ignore\n const T1ll = u64.add5L(Hl, sigma1l, CHIl, SHA512_Kl[i], SHA512_W_L[i]);\n const T1h = u64.add5H(T1ll, Hh, sigma1h, CHIh, SHA512_Kh[i], SHA512_W_H[i]);\n const T1l = T1ll | 0;\n // S0 := (a rightrotate 28) xor (a rightrotate 34) xor (a rightrotate 39)\n const sigma0h = u64.rotrSH(Ah, Al, 28) ^ u64.rotrBH(Ah, Al, 34) ^ u64.rotrBH(Ah, Al, 39);\n const sigma0l = u64.rotrSL(Ah, Al, 28) ^ u64.rotrBL(Ah, Al, 34) ^ u64.rotrBL(Ah, Al, 39);\n const MAJh = (Ah & Bh) ^ (Ah & Ch) ^ (Bh & Ch);\n const MAJl = (Al & Bl) ^ (Al & Cl) ^ (Bl & Cl);\n Hh = Gh | 0;\n Hl = Gl | 0;\n Gh = Fh | 0;\n Gl = Fl | 0;\n Fh = Eh | 0;\n Fl = El | 0;\n ({ h: Eh, l: El } = u64.add(Dh | 0, Dl | 0, T1h | 0, T1l | 0));\n Dh = Ch | 0;\n Dl = Cl | 0;\n Ch = Bh | 0;\n Cl = Bl | 0;\n Bh = Ah | 0;\n Bl = Al | 0;\n const All = u64.add3L(T1l, sigma0l, MAJl);\n Ah = u64.add3H(All, T1h, sigma0h, MAJh);\n Al = All | 0;\n }\n // Add the compressed chunk to the current hash value\n ({ h: Ah, l: Al } = u64.add(this.Ah | 0, this.Al | 0, Ah | 0, Al | 0));\n ({ h: Bh, l: Bl } = u64.add(this.Bh | 0, this.Bl | 0, Bh | 0, Bl | 0));\n ({ h: Ch, l: Cl } = u64.add(this.Ch | 0, this.Cl | 0, Ch | 0, Cl | 0));\n ({ h: Dh, l: Dl } = u64.add(this.Dh | 0, this.Dl | 0, Dh | 0, Dl | 0));\n ({ h: Eh, l: El } = u64.add(this.Eh | 0, this.El | 0, Eh | 0, El | 0));\n ({ h: Fh, l: Fl } = u64.add(this.Fh | 0, this.Fl | 0, Fh | 0, Fl | 0));\n ({ h: Gh, l: Gl } = u64.add(this.Gh | 0, this.Gl | 0, Gh | 0, Gl | 0));\n ({ h: Hh, l: Hl } = u64.add(this.Hh | 0, this.Hl | 0, Hh | 0, Hl | 0));\n this.set(Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl);\n }\n roundClean() {\n clean(SHA512_W_H, SHA512_W_L);\n }\n destroy() {\n clean(this.buffer);\n this.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);\n }\n}\nexport class SHA384 extends SHA512 {\n constructor() {\n super(48);\n this.Ah = SHA384_IV[0] | 0;\n this.Al = SHA384_IV[1] | 0;\n this.Bh = SHA384_IV[2] | 0;\n this.Bl = SHA384_IV[3] | 0;\n this.Ch = SHA384_IV[4] | 0;\n this.Cl = SHA384_IV[5] | 0;\n this.Dh = SHA384_IV[6] | 0;\n this.Dl = SHA384_IV[7] | 0;\n this.Eh = SHA384_IV[8] | 0;\n this.El = SHA384_IV[9] | 0;\n this.Fh = SHA384_IV[10] | 0;\n this.Fl = SHA384_IV[11] | 0;\n this.Gh = SHA384_IV[12] | 0;\n this.Gl = SHA384_IV[13] | 0;\n this.Hh = SHA384_IV[14] | 0;\n this.Hl = SHA384_IV[15] | 0;\n }\n}\n/**\n * Truncated SHA512/256 and SHA512/224.\n * SHA512_IV is XORed with 0xa5a5a5a5a5a5a5a5, then used as \"intermediary\" IV of SHA512/t.\n * Then t hashes string to produce result IV.\n * See `test/misc/sha2-gen-iv.js`.\n */\n/** SHA512/224 IV */\nconst T224_IV = /* @__PURE__ */ Uint32Array.from([\n 0x8c3d37c8, 0x19544da2, 0x73e19966, 0x89dcd4d6, 0x1dfab7ae, 0x32ff9c82, 0x679dd514, 0x582f9fcf,\n 0x0f6d2b69, 0x7bd44da8, 0x77e36f73, 0x04c48942, 0x3f9d85a8, 0x6a1d36c8, 0x1112e6ad, 0x91d692a1,\n]);\n/** SHA512/256 IV */\nconst T256_IV = /* @__PURE__ */ Uint32Array.from([\n 0x22312194, 0xfc2bf72c, 0x9f555fa3, 0xc84c64c2, 0x2393b86b, 0x6f53b151, 0x96387719, 0x5940eabd,\n 0x96283ee2, 0xa88effe3, 0xbe5e1e25, 0x53863992, 0x2b0199fc, 0x2c85b8aa, 0x0eb72ddc, 0x81c52ca2,\n]);\nexport class SHA512_224 extends SHA512 {\n constructor() {\n super(28);\n this.Ah = T224_IV[0] | 0;\n this.Al = T224_IV[1] | 0;\n this.Bh = T224_IV[2] | 0;\n this.Bl = T224_IV[3] | 0;\n this.Ch = T224_IV[4] | 0;\n this.Cl = T224_IV[5] | 0;\n this.Dh = T224_IV[6] | 0;\n this.Dl = T224_IV[7] | 0;\n this.Eh = T224_IV[8] | 0;\n this.El = T224_IV[9] | 0;\n this.Fh = T224_IV[10] | 0;\n this.Fl = T224_IV[11] | 0;\n this.Gh = T224_IV[12] | 0;\n this.Gl = T224_IV[13] | 0;\n this.Hh = T224_IV[14] | 0;\n this.Hl = T224_IV[15] | 0;\n }\n}\nexport class SHA512_256 extends SHA512 {\n constructor() {\n super(32);\n this.Ah = T256_IV[0] | 0;\n this.Al = T256_IV[1] | 0;\n this.Bh = T256_IV[2] | 0;\n this.Bl = T256_IV[3] | 0;\n this.Ch = T256_IV[4] | 0;\n this.Cl = T256_IV[5] | 0;\n this.Dh = T256_IV[6] | 0;\n this.Dl = T256_IV[7] | 0;\n this.Eh = T256_IV[8] | 0;\n this.El = T256_IV[9] | 0;\n this.Fh = T256_IV[10] | 0;\n this.Fl = T256_IV[11] | 0;\n this.Gh = T256_IV[12] | 0;\n this.Gl = T256_IV[13] | 0;\n this.Hh = T256_IV[14] | 0;\n this.Hl = T256_IV[15] | 0;\n }\n}\n/**\n * SHA2-256 hash function from RFC 4634.\n *\n * It is the fastest JS hash, even faster than Blake3.\n * To break sha256 using birthday attack, attackers need to try 2^128 hashes.\n * BTC network is doing 2^70 hashes/sec (2^95 hashes/year) as per 2025.\n */\nexport const sha256 = /* @__PURE__ */ createHasher(() => new SHA256());\n/** SHA2-224 hash function from RFC 4634 */\nexport const sha224 = /* @__PURE__ */ createHasher(() => new SHA224());\n/** SHA2-512 hash function from RFC 4634. */\nexport const sha512 = /* @__PURE__ */ createHasher(() => new SHA512());\n/** SHA2-384 hash function from RFC 4634. */\nexport const sha384 = /* @__PURE__ */ createHasher(() => new SHA384());\n/**\n * SHA2-512/256 \"truncated\" hash function, with improved resistance to length extension attacks.\n * See the paper on [truncated SHA512](https://eprint.iacr.org/2010/548.pdf).\n */\nexport const sha512_256 = /* @__PURE__ */ createHasher(() => new SHA512_256());\n/**\n * SHA2-512/224 \"truncated\" hash function, with improved resistance to length extension attacks.\n * See the paper on [truncated SHA512](https://eprint.iacr.org/2010/548.pdf).\n */\nexport const sha512_224 = /* @__PURE__ */ createHasher(() => new SHA512_224());\n//# sourceMappingURL=sha2.js.map","/**\n * SHA2-256 a.k.a. sha256. In JS, it is the fastest hash, even faster than Blake3.\n *\n * To break sha256 using birthday attack, attackers need to try 2^128 hashes.\n * BTC network is doing 2^70 hashes/sec (2^95 hashes/year) as per 2025.\n *\n * Check out [FIPS 180-4](https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.180-4.pdf).\n * @module\n * @deprecated\n */\nimport { SHA224 as SHA224n, sha224 as sha224n, SHA256 as SHA256n, sha256 as sha256n, } from \"./sha2.js\";\n/** @deprecated Use import from `noble/hashes/sha2` module */\nexport const SHA256 = SHA256n;\n/** @deprecated Use import from `noble/hashes/sha2` module */\nexport const sha256 = sha256n;\n/** @deprecated Use import from `noble/hashes/sha2` module */\nexport const SHA224 = SHA224n;\n/** @deprecated Use import from `noble/hashes/sha2` module */\nexport const sha224 = sha224n;\n//# sourceMappingURL=sha256.js.map","export const crypto = typeof globalThis === 'object' && 'crypto' in globalThis ? globalThis.crypto : undefined;\n//# sourceMappingURL=crypto.js.map","/**\n * Utilities for hex, bytes, CSPRNG.\n * @module\n */\n/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */\n// We use WebCrypto aka globalThis.crypto, which exists in browsers and node.js 16+.\n// node.js versions earlier than v19 don't declare it in global scope.\n// For node.js, package.json#exports field mapping rewrites import\n// from `crypto` to `cryptoNode`, which imports native module.\n// Makes the utils un-importable in browsers without a bundler.\n// Once node.js 18 is deprecated (2025-04-30), we can just drop the import.\nimport { crypto } from '@noble/hashes/crypto';\n/** Checks if something is Uint8Array. Be careful: nodejs Buffer will return true. */\nexport function isBytes(a) {\n return a instanceof Uint8Array || (ArrayBuffer.isView(a) && a.constructor.name === 'Uint8Array');\n}\n/** Asserts something is positive integer. */\nexport function anumber(n) {\n if (!Number.isSafeInteger(n) || n < 0)\n throw new Error('positive integer expected, got ' + n);\n}\n/** Asserts something is Uint8Array. */\nexport function abytes(b, ...lengths) {\n if (!isBytes(b))\n throw new Error('Uint8Array expected');\n if (lengths.length > 0 && !lengths.includes(b.length))\n throw new Error('Uint8Array expected of length ' + lengths + ', got length=' + b.length);\n}\n/** Asserts something is hash */\nexport function ahash(h) {\n if (typeof h !== 'function' || typeof h.create !== 'function')\n throw new Error('Hash should be wrapped by utils.createHasher');\n anumber(h.outputLen);\n anumber(h.blockLen);\n}\n/** Asserts a hash instance has not been destroyed / finished */\nexport function aexists(instance, checkFinished = true) {\n if (instance.destroyed)\n throw new Error('Hash instance has been destroyed');\n if (checkFinished && instance.finished)\n throw new Error('Hash#digest() has already been called');\n}\n/** Asserts output is properly-sized byte array */\nexport function aoutput(out, instance) {\n abytes(out);\n const min = instance.outputLen;\n if (out.length < min) {\n throw new Error('digestInto() expects output buffer of length at least ' + min);\n }\n}\n/** Cast u8 / u16 / u32 to u8. */\nexport function u8(arr) {\n return new Uint8Array(arr.buffer, arr.byteOffset, arr.byteLength);\n}\n/** Cast u8 / u16 / u32 to u32. */\nexport function u32(arr) {\n return new Uint32Array(arr.buffer, arr.byteOffset, Math.floor(arr.byteLength / 4));\n}\n/** Zeroize a byte array. Warning: JS provides no guarantees. */\nexport function clean(...arrays) {\n for (let i = 0; i < arrays.length; i++) {\n arrays[i].fill(0);\n }\n}\n/** Create DataView of an array for easy byte-level manipulation. */\nexport function createView(arr) {\n return new DataView(arr.buffer, arr.byteOffset, arr.byteLength);\n}\n/** The rotate right (circular right shift) operation for uint32 */\nexport function rotr(word, shift) {\n return (word << (32 - shift)) | (word >>> shift);\n}\n/** The rotate left (circular left shift) operation for uint32 */\nexport function rotl(word, shift) {\n return (word << shift) | ((word >>> (32 - shift)) >>> 0);\n}\n/** Is current platform little-endian? Most are. Big-Endian platform: IBM */\nexport const isLE = /* @__PURE__ */ (() => new Uint8Array(new Uint32Array([0x11223344]).buffer)[0] === 0x44)();\n/** The byte swap operation for uint32 */\nexport function byteSwap(word) {\n return (((word << 24) & 0xff000000) |\n ((word << 8) & 0xff0000) |\n ((word >>> 8) & 0xff00) |\n ((word >>> 24) & 0xff));\n}\n/** Conditionally byte swap if on a big-endian platform */\nexport const swap8IfBE = isLE\n ? (n) => n\n : (n) => byteSwap(n);\n/** @deprecated */\nexport const byteSwapIfBE = swap8IfBE;\n/** In place byte swap for Uint32Array */\nexport function byteSwap32(arr) {\n for (let i = 0; i < arr.length; i++) {\n arr[i] = byteSwap(arr[i]);\n }\n return arr;\n}\nexport const swap32IfBE = isLE\n ? (u) => u\n : byteSwap32;\n// Built-in hex conversion https://caniuse.com/mdn-javascript_builtins_uint8array_fromhex\nconst hasHexBuiltin = /* @__PURE__ */ (() => \n// @ts-ignore\ntypeof Uint8Array.from([]).toHex === 'function' && typeof Uint8Array.fromHex === 'function')();\n// Array where index 0xf0 (240) is mapped to string 'f0'\nconst hexes = /* @__PURE__ */ Array.from({ length: 256 }, (_, i) => i.toString(16).padStart(2, '0'));\n/**\n * Convert byte array to hex string. Uses built-in function, when available.\n * @example bytesToHex(Uint8Array.from([0xca, 0xfe, 0x01, 0x23])) // 'cafe0123'\n */\nexport function bytesToHex(bytes) {\n abytes(bytes);\n // @ts-ignore\n if (hasHexBuiltin)\n return bytes.toHex();\n // pre-caching improves the speed 6x\n let hex = '';\n for (let i = 0; i < bytes.length; i++) {\n hex += hexes[bytes[i]];\n }\n return hex;\n}\n// We use optimized technique to convert hex string to byte array\nconst asciis = { _0: 48, _9: 57, A: 65, F: 70, a: 97, f: 102 };\nfunction asciiToBase16(ch) {\n if (ch >= asciis._0 && ch <= asciis._9)\n return ch - asciis._0; // '2' => 50-48\n if (ch >= asciis.A && ch <= asciis.F)\n return ch - (asciis.A - 10); // 'B' => 66-(65-10)\n if (ch >= asciis.a && ch <= asciis.f)\n return ch - (asciis.a - 10); // 'b' => 98-(97-10)\n return;\n}\n/**\n * Convert hex string to byte array. Uses built-in function, when available.\n * @example hexToBytes('cafe0123') // Uint8Array.from([0xca, 0xfe, 0x01, 0x23])\n */\nexport function hexToBytes(hex) {\n if (typeof hex !== 'string')\n throw new Error('hex string expected, got ' + typeof hex);\n // @ts-ignore\n if (hasHexBuiltin)\n return Uint8Array.fromHex(hex);\n const hl = hex.length;\n const al = hl / 2;\n if (hl % 2)\n throw new Error('hex string expected, got unpadded hex of length ' + hl);\n const array = new Uint8Array(al);\n for (let ai = 0, hi = 0; ai < al; ai++, hi += 2) {\n const n1 = asciiToBase16(hex.charCodeAt(hi));\n const n2 = asciiToBase16(hex.charCodeAt(hi + 1));\n if (n1 === undefined || n2 === undefined) {\n const char = hex[hi] + hex[hi + 1];\n throw new Error('hex string expected, got non-hex character \"' + char + '\" at index ' + hi);\n }\n array[ai] = n1 * 16 + n2; // multiply first octet, e.g. 'a3' => 10*16+3 => 160 + 3 => 163\n }\n return array;\n}\n/**\n * There is no setImmediate in browser and setTimeout is slow.\n * Call of async fn will return Promise, which will be fullfiled only on\n * next scheduler queue processing step and this is exactly what we need.\n */\nexport const nextTick = async () => { };\n/** Returns control to thread each 'tick' ms to avoid blocking. */\nexport async function asyncLoop(iters, tick, cb) {\n let ts = Date.now();\n for (let i = 0; i < iters; i++) {\n cb(i);\n // Date.now() is not monotonic, so in case if clock goes backwards we return return control too\n const diff = Date.now() - ts;\n if (diff >= 0 && diff < tick)\n continue;\n await nextTick();\n ts += diff;\n }\n}\n/**\n * Converts string to bytes using UTF8 encoding.\n * @example utf8ToBytes('abc') // Uint8Array.from([97, 98, 99])\n */\nexport function utf8ToBytes(str) {\n if (typeof str !== 'string')\n throw new Error('string expected');\n return new Uint8Array(new TextEncoder().encode(str)); // https://bugzil.la/1681809\n}\n/**\n * Converts bytes to string using UTF8 encoding.\n * @example bytesToUtf8(Uint8Array.from([97, 98, 99])) // 'abc'\n */\nexport function bytesToUtf8(bytes) {\n return new TextDecoder().decode(bytes);\n}\n/**\n * Normalizes (non-hex) string or Uint8Array to Uint8Array.\n * Warning: when Uint8Array is passed, it would NOT get copied.\n * Keep in mind for future mutable operations.\n */\nexport function toBytes(data) {\n if (typeof data === 'string')\n data = utf8ToBytes(data);\n abytes(data);\n return data;\n}\n/**\n * Helper for KDFs: consumes uint8array or string.\n * When string is passed, does utf8 decoding, using TextDecoder.\n */\nexport function kdfInputToBytes(data) {\n if (typeof data === 'string')\n data = utf8ToBytes(data);\n abytes(data);\n return data;\n}\n/** Copies several Uint8Arrays into one. */\nexport function concatBytes(...arrays) {\n let sum = 0;\n for (let i = 0; i < arrays.length; i++) {\n const a = arrays[i];\n abytes(a);\n sum += a.length;\n }\n const res = new Uint8Array(sum);\n for (let i = 0, pad = 0; i < arrays.length; i++) {\n const a = arrays[i];\n res.set(a, pad);\n pad += a.length;\n }\n return res;\n}\nexport function checkOpts(defaults, opts) {\n if (opts !== undefined && {}.toString.call(opts) !== '[object Object]')\n throw new Error('options should be object or undefined');\n const merged = Object.assign(defaults, opts);\n return merged;\n}\n/** For runtime check if class implements interface */\nexport class Hash {\n}\n/** Wraps hash function, creating an interface on top of it */\nexport function createHasher(hashCons) {\n const hashC = (msg) => hashCons().update(toBytes(msg)).digest();\n const tmp = hashCons();\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = () => hashCons();\n return hashC;\n}\nexport function createOptHasher(hashCons) {\n const hashC = (msg, opts) => hashCons(opts).update(toBytes(msg)).digest();\n const tmp = hashCons({});\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = (opts) => hashCons(opts);\n return hashC;\n}\nexport function createXOFer(hashCons) {\n const hashC = (msg, opts) => hashCons(opts).update(toBytes(msg)).digest();\n const tmp = hashCons({});\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = (opts) => hashCons(opts);\n return hashC;\n}\nexport const wrapConstructor = createHasher;\nexport const wrapConstructorWithOpts = createOptHasher;\nexport const wrapXOFConstructorWithOpts = createXOFer;\n/** Cryptographically secure PRNG. Uses internal OS-level `crypto.getRandomValues`. */\nexport function randomBytes(bytesLength = 32) {\n if (crypto && typeof crypto.getRandomValues === 'function') {\n return crypto.getRandomValues(new Uint8Array(bytesLength));\n }\n // Legacy Node.js compatibility\n if (crypto && typeof crypto.randomBytes === 'function') {\n return Uint8Array.from(crypto.randomBytes(bytesLength));\n }\n throw new Error('crypto.getRandomValues must be defined');\n}\n//# sourceMappingURL=utils.js.map","/**\n * Hex, bytes and number utilities.\n * @module\n */\n/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */\nimport { abytes as abytes_, bytesToHex as bytesToHex_, concatBytes as concatBytes_, hexToBytes as hexToBytes_, isBytes as isBytes_, } from '@noble/hashes/utils.js';\nexport { abytes, anumber, bytesToHex, bytesToUtf8, concatBytes, hexToBytes, isBytes, randomBytes, utf8ToBytes, } from '@noble/hashes/utils.js';\nconst _0n = /* @__PURE__ */ BigInt(0);\nconst _1n = /* @__PURE__ */ BigInt(1);\nexport function abool(title, value) {\n if (typeof value !== 'boolean')\n throw new Error(title + ' boolean expected, got ' + value);\n}\n// tmp name until v2\nexport function _abool2(value, title = '') {\n if (typeof value !== 'boolean') {\n const prefix = title && `\"${title}\"`;\n throw new Error(prefix + 'expected boolean, got type=' + typeof value);\n }\n return value;\n}\n// tmp name until v2\n/** Asserts something is Uint8Array. */\nexport function _abytes2(value, length, title = '') {\n const bytes = isBytes_(value);\n const len = value?.length;\n const needsLen = length !== undefined;\n if (!bytes || (needsLen && len !== length)) {\n const prefix = title && `\"${title}\" `;\n const ofLen = needsLen ? ` of length ${length}` : '';\n const got = bytes ? `length=${len}` : `type=${typeof value}`;\n throw new Error(prefix + 'expected Uint8Array' + ofLen + ', got ' + got);\n }\n return value;\n}\n// Used in weierstrass, der\nexport function numberToHexUnpadded(num) {\n const hex = num.toString(16);\n return hex.length & 1 ? '0' + hex : hex;\n}\nexport function hexToNumber(hex) {\n if (typeof hex !== 'string')\n throw new Error('hex string expected, got ' + typeof hex);\n return hex === '' ? _0n : BigInt('0x' + hex); // Big Endian\n}\n// BE: Big Endian, LE: Little Endian\nexport function bytesToNumberBE(bytes) {\n return hexToNumber(bytesToHex_(bytes));\n}\nexport function bytesToNumberLE(bytes) {\n abytes_(bytes);\n return hexToNumber(bytesToHex_(Uint8Array.from(bytes).reverse()));\n}\nexport function numberToBytesBE(n, len) {\n return hexToBytes_(n.toString(16).padStart(len * 2, '0'));\n}\nexport function numberToBytesLE(n, len) {\n return numberToBytesBE(n, len).reverse();\n}\n// Unpadded, rarely used\nexport function numberToVarBytesBE(n) {\n return hexToBytes_(numberToHexUnpadded(n));\n}\n/**\n * Takes hex string or Uint8Array, converts to Uint8Array.\n * Validates output length.\n * Will throw error for other types.\n * @param title descriptive title for an error e.g. 'secret key'\n * @param hex hex string or Uint8Array\n * @param expectedLength optional, will compare to result array's length\n * @returns\n */\nexport function ensureBytes(title, hex, expectedLength) {\n let res;\n if (typeof hex === 'string') {\n try {\n res = hexToBytes_(hex);\n }\n catch (e) {\n throw new Error(title + ' must be hex string or Uint8Array, cause: ' + e);\n }\n }\n else if (isBytes_(hex)) {\n // Uint8Array.from() instead of hash.slice() because node.js Buffer\n // is instance of Uint8Array, and its slice() creates **mutable** copy\n res = Uint8Array.from(hex);\n }\n else {\n throw new Error(title + ' must be hex string or Uint8Array');\n }\n const len = res.length;\n if (typeof expectedLength === 'number' && len !== expectedLength)\n throw new Error(title + ' of length ' + expectedLength + ' expected, got ' + len);\n return res;\n}\n// Compares 2 u8a-s in kinda constant time\nexport function equalBytes(a, b) {\n if (a.length !== b.length)\n return false;\n let diff = 0;\n for (let i = 0; i < a.length; i++)\n diff |= a[i] ^ b[i];\n return diff === 0;\n}\n/**\n * Copies Uint8Array. We can't use u8a.slice(), because u8a can be Buffer,\n * and Buffer#slice creates mutable copy. Never use Buffers!\n */\nexport function copyBytes(bytes) {\n return Uint8Array.from(bytes);\n}\n/**\n * Decodes 7-bit ASCII string to Uint8Array, throws on non-ascii symbols\n * Should be safe to use for things expected to be ASCII.\n * Returns exact same result as utf8ToBytes for ASCII or throws.\n */\nexport function asciiToBytes(ascii) {\n return Uint8Array.from(ascii, (c, i) => {\n const charCode = c.charCodeAt(0);\n if (c.length !== 1 || charCode > 127) {\n throw new Error(`string contains non-ASCII character \"${ascii[i]}\" with code ${charCode} at position ${i}`);\n }\n return charCode;\n });\n}\n/**\n * @example utf8ToBytes('abc') // new Uint8Array([97, 98, 99])\n */\n// export const utf8ToBytes: typeof utf8ToBytes_ = utf8ToBytes_;\n/**\n * Converts bytes to string using UTF8 encoding.\n * @example bytesToUtf8(Uint8Array.from([97, 98, 99])) // 'abc'\n */\n// export const bytesToUtf8: typeof bytesToUtf8_ = bytesToUtf8_;\n// Is positive bigint\nconst isPosBig = (n) => typeof n === 'bigint' && _0n <= n;\nexport function inRange(n, min, max) {\n return isPosBig(n) && isPosBig(min) && isPosBig(max) && min <= n && n < max;\n}\n/**\n * Asserts min <= n < max. NOTE: It's < max and not <= max.\n * @example\n * aInRange('x', x, 1n, 256n); // would assume x is in (1n..255n)\n */\nexport function aInRange(title, n, min, max) {\n // Why min <= n < max and not a (min < n < max) OR b (min <= n <= max)?\n // consider P=256n, min=0n, max=P\n // - a for min=0 would require -1: `inRange('x', x, -1n, P)`\n // - b would commonly require subtraction: `inRange('x', x, 0n, P - 1n)`\n // - our way is the cleanest: `inRange('x', x, 0n, P)\n if (!inRange(n, min, max))\n throw new Error('expected valid ' + title + ': ' + min + ' <= n < ' + max + ', got ' + n);\n}\n// Bit operations\n/**\n * Calculates amount of bits in a bigint.\n * Same as `n.toString(2).length`\n * TODO: merge with nLength in modular\n */\nexport function bitLen(n) {\n let len;\n for (len = 0; n > _0n; n >>= _1n, len += 1)\n ;\n return len;\n}\n/**\n * Gets single bit at position.\n * NOTE: first bit position is 0 (same as arrays)\n * Same as `!!+Array.from(n.toString(2)).reverse()[pos]`\n */\nexport function bitGet(n, pos) {\n return (n >> BigInt(pos)) & _1n;\n}\n/**\n * Sets single bit at position.\n */\nexport function bitSet(n, pos, value) {\n return n | ((value ? _1n : _0n) << BigInt(pos));\n}\n/**\n * Calculate mask for N bits. Not using ** operator with bigints because of old engines.\n * Same as BigInt(`0b${Array(i).fill('1').join('')}`)\n */\nexport const bitMask = (n) => (_1n << BigInt(n)) - _1n;\n/**\n * Minimal HMAC-DRBG from NIST 800-90 for RFC6979 sigs.\n * @returns function that will call DRBG until 2nd arg returns something meaningful\n * @example\n * const drbg = createHmacDRBG<Key>(32, 32, hmac);\n * drbg(seed, bytesToKey); // bytesToKey must return Key or undefined\n */\nexport function createHmacDrbg(hashLen, qByteLen, hmacFn) {\n if (typeof hashLen !== 'number' || hashLen < 2)\n throw new Error('hashLen must be a number');\n if (typeof qByteLen !== 'number' || qByteLen < 2)\n throw new Error('qByteLen must be a number');\n if (typeof hmacFn !== 'function')\n throw new Error('hmacFn must be a function');\n // Step B, Step C: set hashLen to 8*ceil(hlen/8)\n const u8n = (len) => new Uint8Array(len); // creates Uint8Array\n const u8of = (byte) => Uint8Array.of(byte); // another shortcut\n let v = u8n(hashLen); // Minimal non-full-spec HMAC-DRBG from NIST 800-90 for RFC6979 sigs.\n let k = u8n(hashLen); // Steps B and C of RFC6979 3.2: set hashLen, in our case always same\n let i = 0; // Iterations counter, will throw when over 1000\n const reset = () => {\n v.fill(1);\n k.fill(0);\n i = 0;\n };\n const h = (...b) => hmacFn(k, v, ...b); // hmac(k)(v, ...values)\n const reseed = (seed = u8n(0)) => {\n // HMAC-DRBG reseed() function. Steps D-G\n k = h(u8of(0x00), seed); // k = hmac(k || v || 0x00 || seed)\n v = h(); // v = hmac(k || v)\n if (seed.length === 0)\n return;\n k = h(u8of(0x01), seed); // k = hmac(k || v || 0x01 || seed)\n v = h(); // v = hmac(k || v)\n };\n const gen = () => {\n // HMAC-DRBG generate() function\n if (i++ >= 1000)\n throw new Error('drbg: tried 1000 values');\n let len = 0;\n const out = [];\n while (len < qByteLen) {\n v = h();\n const sl = v.slice();\n out.push(sl);\n len += v.length;\n }\n return concatBytes_(...out);\n };\n const genUntil = (seed, pred) => {\n reset();\n reseed(seed); // Steps D-G\n let res = undefined; // Step H: grind until k is in [1..n-1]\n while (!(res = pred(gen())))\n reseed();\n reset();\n return res;\n };\n return genUntil;\n}\n// Validating curves and fields\nconst validatorFns = {\n bigint: (val) => typeof val === 'bigint',\n function: (val) => typeof val === 'function',\n boolean: (val) => typeof val === 'boolean',\n string: (val) => typeof val === 'string',\n stringOrUint8Array: (val) => typeof val === 'string' || isBytes_(val),\n isSafeInteger: (val) => Number.isSafeInteger(val),\n array: (val) => Array.isArray(val),\n field: (val, object) => object.Fp.isValid(val),\n hash: (val) => typeof val === 'function' && Number.isSafeInteger(val.outputLen),\n};\n// type Record<K extends string | number | symbol, T> = { [P in K]: T; }\nexport function validateObject(object, validators, optValidators = {}) {\n const checkField = (fieldName, type, isOptional) => {\n const checkVal = validatorFns[type];\n if (typeof checkVal !== 'function')\n throw new Error('invalid validator function');\n const val = object[fieldName];\n if (isOptional && val === undefined)\n return;\n if (!checkVal(val, object)) {\n throw new Error('param ' + String(fieldName) + ' is invalid. Expected ' + type + ', got ' + val);\n }\n };\n for (const [fieldName, type] of Object.entries(validators))\n checkField(fieldName, type, false);\n for (const [fieldName, type] of Object.entries(optValidators))\n checkField(fieldName, type, true);\n return object;\n}\n// validate type tests\n// const o: { a: number; b: number; c: number } = { a: 1, b: 5, c: 6 };\n// const z0 = validateObject(o, { a: 'isSafeInteger' }, { c: 'bigint' }); // Ok!\n// // Should fail type-check\n// const z1 = validateObject(o, { a: 'tmp' }, { c: 'zz' });\n// const z2 = validateObject(o, { a: 'isSafeInteger' }, { c: 'zz' });\n// const z3 = validateObject(o, { test: 'boolean', z: 'bug' });\n// const z4 = validateObject(o, { a: 'boolean', z: 'bug' });\nexport function isHash(val) {\n return typeof val === 'function' && Number.isSafeInteger(val.outputLen);\n}\nexport function _validateObject(object, fields, optFields = {}) {\n if (!object || typeof object !== 'object')\n throw new Error('expected valid options object');\n function checkField(fieldName, expectedType, isOpt) {\n const val = object[fieldName];\n if (isOpt && val === undefined)\n return;\n const current = typeof val;\n if (current !== expectedType || val === null)\n throw new Error(`param \"${fieldName}\" is invalid: expected ${expectedType}, got ${current}`);\n }\n Object.entries(fields).forEach(([k, v]) => checkField(k, v, false));\n Object.entries(optFields).forEach(([k, v]) => checkField(k, v, true));\n}\n/**\n * throws not implemented error\n */\nexport const notImplemented = () => {\n throw new Error('not implemented');\n};\n/**\n * Memoizes (caches) computation result.\n * Uses WeakMap: the value is going auto-cleaned by GC after last reference is removed.\n */\nexport function memoized(fn) {\n const map = new WeakMap();\n return (arg, ...args) => {\n const val = map.get(arg);\n if (val !== undefined)\n return val;\n const computed = fn(arg, ...args);\n map.set(arg, computed);\n return computed;\n };\n}\n//# sourceMappingURL=utils.js.map","const bigIntSuffix = '#__bigint';\n/**\n * Parses a JSON string, with support for `bigint`.\n *\n * @example\n * ```ts twoslash\n * import { Json } from 'ox'\n *\n * const json = Json.parse('{\"foo\":\"bar\",\"baz\":\"69420694206942069420694206942069420694206942069420#__bigint\"}')\n * // @log: {\n * // @log: foo: 'bar',\n * // @log: baz: 69420694206942069420694206942069420694206942069420n\n * // @log: }\n * ```\n *\n * @param string - The value to parse.\n * @param reviver - A function that transforms the results.\n * @returns The parsed value.\n */\nexport function parse(string, reviver) {\n return JSON.parse(string, (key, value_) => {\n const value = value_;\n if (typeof value === 'string' && value.endsWith(bigIntSuffix))\n return BigInt(value.slice(0, -bigIntSuffix.length));\n return typeof reviver === 'function' ? reviver(key, value) : value;\n });\n}\n/**\n * Stringifies a value to its JSON representation, with support for `bigint`.\n *\n * @example\n * ```ts twoslash\n * import { Json } from 'ox'\n *\n * const json = Json.stringify({\n * foo: 'bar',\n * baz: 69420694206942069420694206942069420694206942069420n,\n * })\n * // @log: '{\"foo\":\"bar\",\"baz\":\"69420694206942069420694206942069420694206942069420#__bigint\"}'\n * ```\n *\n * @param value - The value to stringify.\n * @param replacer - A function that transforms the results. It is passed the key and value of the property, and must return the value to be used in the JSON string. If this function returns `undefined`, the property is not included in the resulting JSON string.\n * @param space - A string or number that determines the indentation of the JSON string. If it is a number, it indicates the number of spaces to use as indentation; if it is a string (e.g. `'\\t'`), it uses the string as the indentation character.\n * @returns The JSON string.\n */\nexport function stringify(value, replacer, space) {\n return JSON.stringify(value, (key, value) => {\n if (typeof replacer === 'function')\n return replacer(key, value);\n if (typeof value === 'bigint')\n return value.toString() + bigIntSuffix;\n return value;\n }, space);\n}\n//# sourceMappingURL=Json.js.map","import * as Bytes from '../Bytes.js';\n/** @internal */\nexport function assertSize(bytes, size_) {\n if (Bytes.size(bytes) > size_)\n throw new Bytes.SizeOverflowError({\n givenSize: Bytes.size(bytes),\n maxSize: size_,\n });\n}\n/** @internal */\nexport function assertStartOffset(value, start) {\n if (typeof start === 'number' && start > 0 && start > Bytes.size(value) - 1)\n throw new Bytes.SliceOffsetOutOfBoundsError({\n offset: start,\n position: 'start',\n size: Bytes.size(value),\n });\n}\n/** @internal */\nexport function assertEndOffset(value, start, end) {\n if (typeof start === 'number' &&\n typeof end === 'number' &&\n Bytes.size(value) !== end - start) {\n throw new Bytes.SliceOffsetOutOfBoundsError({\n offset: end,\n position: 'end',\n size: Bytes.size(value),\n });\n }\n}\n/** @internal */\nexport const charCodeMap = {\n zero: 48,\n nine: 57,\n A: 65,\n F: 70,\n a: 97,\n f: 102,\n};\n/** @internal */\nexport function charCodeToBase16(char) {\n if (char >= charCodeMap.zero && char <= charCodeMap.nine)\n return char - charCodeMap.zero;\n if (char >= charCodeMap.A && char <= charCodeMap.F)\n return char - (charCodeMap.A - 10);\n if (char >= charCodeMap.a && char <= charCodeMap.f)\n return char - (charCodeMap.a - 10);\n return undefined;\n}\n/** @internal */\nexport function pad(bytes, options = {}) {\n const { dir, size = 32 } = options;\n if (size === 0)\n return bytes;\n if (bytes.length > size)\n throw new Bytes.SizeExceedsPaddingSizeError({\n size: bytes.length,\n targetSize: size,\n type: 'Bytes',\n });\n const paddedBytes = new Uint8Array(size);\n for (let i = 0; i < size; i++) {\n const padEnd = dir === 'right';\n paddedBytes[padEnd ? i : size - i - 1] =\n bytes[padEnd ? i : bytes.length - i - 1];\n }\n return paddedBytes;\n}\n/** @internal */\nexport function trim(value, options = {}) {\n const { dir = 'left' } = options;\n let data = value;\n let sliceLength = 0;\n for (let i = 0; i < data.length - 1; i++) {\n if (data[dir === 'left' ? i : data.length - i - 1].toString() === '0')\n sliceLength++;\n else\n break;\n }\n data =\n dir === 'left'\n ? data.slice(sliceLength)\n : data.slice(0, data.length - sliceLength);\n return data;\n}\n//# sourceMappingURL=bytes.js.map","import * as Hex from '../Hex.js';\n/** @internal */\nexport function assertSize(hex, size_) {\n if (Hex.size(hex) > size_)\n throw new Hex.SizeOverflowError({\n givenSize: Hex.size(hex),\n maxSize: size_,\n });\n}\n/** @internal */\nexport function assertStartOffset(value, start) {\n if (typeof start === 'number' && start > 0 && start > Hex.size(value) - 1)\n throw new Hex.SliceOffsetOutOfBoundsError({\n offset: start,\n position: 'start',\n size: Hex.size(value),\n });\n}\n/** @internal */\nexport function assertEndOffset(value, start, end) {\n if (typeof start === 'number' &&\n typeof end === 'number' &&\n Hex.size(value) !== end - start) {\n throw new Hex.SliceOffsetOutOfBoundsError({\n offset: end,\n position: 'end',\n size: Hex.size(value),\n });\n }\n}\n/** @internal */\nexport function pad(hex_, options = {}) {\n const { dir, size = 32 } = options;\n if (size === 0)\n return hex_;\n const hex = hex_.replace('0x', '');\n if (hex.length > size * 2)\n throw new Hex.SizeExceedsPaddingSizeError({\n size: Math.ceil(hex.length / 2),\n targetSize: size,\n type: 'Hex',\n });\n return `0x${hex[dir === 'right' ? 'padEnd' : 'padStart'](size * 2, '0')}`;\n}\n/** @internal */\nexport function trim(value, options = {}) {\n const { dir = 'left' } = options;\n let data = value.replace('0x', '');\n let sliceLength = 0;\n for (let i = 0; i < data.length - 1; i++) {\n if (data[dir === 'left' ? i : data.length - i - 1].toString() === '0')\n sliceLength++;\n else\n break;\n }\n data =\n dir === 'left'\n ? data.slice(sliceLength)\n : data.slice(0, data.length - sliceLength);\n if (data === '0')\n return '0x';\n if (dir === 'right' && data.length % 2 === 1)\n return `0x${data}0`;\n return `0x${data}`;\n}\n//# sourceMappingURL=hex.js.map","import { equalBytes } from '@noble/curves/abstract/utils';\nimport * as Bytes from './Bytes.js';\nimport * as Errors from './Errors.js';\nimport * as Json from './Json.js';\nimport * as internal_bytes from './internal/bytes.js';\nimport * as internal from './internal/hex.js';\nconst encoder = /*#__PURE__*/ new TextEncoder();\nconst hexes = /*#__PURE__*/ Array.from({ length: 256 }, (_v, i) => i.toString(16).padStart(2, '0'));\n/**\n * Asserts if the given value is {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.assert('abc')\n * // @error: InvalidHexValueTypeError:\n * // @error: Value `\"abc\"` of type `string` is an invalid hex type.\n * // @error: Hex types must be represented as `\"0x\\${string}\"`.\n * ```\n *\n * @param value - The value to assert.\n * @param options - Options.\n */\nexport function assert(value, options = {}) {\n const { strict = false } = options;\n if (!value)\n throw new InvalidHexTypeError(value);\n if (typeof value !== 'string')\n throw new InvalidHexTypeError(value);\n if (strict) {\n if (!/^0x[0-9a-fA-F]*$/.test(value))\n throw new InvalidHexValueError(value);\n }\n if (!value.startsWith('0x'))\n throw new InvalidHexValueError(value);\n}\n/**\n * Concatenates two or more {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.concat('0x123', '0x456')\n * // @log: '0x123456'\n * ```\n *\n * @param values - The {@link ox#Hex.Hex} values to concatenate.\n * @returns The concatenated {@link ox#Hex.Hex} value.\n */\nexport function concat(...values) {\n return `0x${values.reduce((acc, x) => acc + x.replace('0x', ''), '')}`;\n}\n/**\n * Instantiates a {@link ox#Hex.Hex} value from a hex string or {@link ox#Bytes.Bytes} value.\n *\n * :::tip\n *\n * To instantiate from a **Boolean**, **String**, or **Number**, use one of the following:\n *\n * - `Hex.fromBoolean`\n *\n * - `Hex.fromString`\n *\n * - `Hex.fromNumber`\n *\n * :::\n *\n * @example\n * ```ts twoslash\n * import { Bytes, Hex } from 'ox'\n *\n * Hex.from('0x48656c6c6f20576f726c6421')\n * // @log: '0x48656c6c6f20576f726c6421'\n *\n * Hex.from(Bytes.from([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33]))\n * // @log: '0x48656c6c6f20576f726c6421'\n * ```\n *\n * @param value - The {@link ox#Bytes.Bytes} value to encode.\n * @returns The encoded {@link ox#Hex.Hex} value.\n */\nexport function from(value) {\n if (value instanceof Uint8Array)\n return fromBytes(value);\n if (Array.isArray(value))\n return fromBytes(new Uint8Array(value));\n return value;\n}\n/**\n * Encodes a boolean into a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.fromBoolean(true)\n * // @log: '0x1'\n *\n * Hex.fromBoolean(false)\n * // @log: '0x0'\n *\n * Hex.fromBoolean(true, { size: 32 })\n * // @log: '0x0000000000000000000000000000000000000000000000000000000000000001'\n * ```\n *\n * @param value - The boolean value to encode.\n * @param options - Options.\n * @returns The encoded {@link ox#Hex.Hex} value.\n */\nexport function fromBoolean(value, options = {}) {\n const hex = `0x${Number(value)}`;\n if (typeof options.size === 'number') {\n internal.assertSize(hex, options.size);\n return padLeft(hex, options.size);\n }\n return hex;\n}\n/**\n * Encodes a {@link ox#Bytes.Bytes} value into a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { Bytes, Hex } from 'ox'\n *\n * Hex.fromBytes(Bytes.from([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33]))\n * // @log: '0x48656c6c6f20576f726c6421'\n * ```\n *\n * @param value - The {@link ox#Bytes.Bytes} value to encode.\n * @param options - Options.\n * @returns The encoded {@link ox#Hex.Hex} value.\n */\nexport function fromBytes(value, options = {}) {\n let string = '';\n for (let i = 0; i < value.length; i++)\n string += hexes[value[i]];\n const hex = `0x${string}`;\n if (typeof options.size === 'number') {\n internal.assertSize(hex, options.size);\n return padRight(hex, options.size);\n }\n return hex;\n}\n/**\n * Encodes a number or bigint into a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.fromNumber(420)\n * // @log: '0x1a4'\n *\n * Hex.fromNumber(420, { size: 32 })\n * // @log: '0x00000000000000000000000000000000000000000000000000000000000001a4'\n * ```\n *\n * @param value - The number or bigint value to encode.\n * @param options - Options.\n * @returns The encoded {@link ox#Hex.Hex} value.\n */\nexport function fromNumber(value, options = {}) {\n const { signed, size } = options;\n const value_ = BigInt(value);\n let maxValue;\n if (size) {\n if (signed)\n maxValue = (1n << (BigInt(size) * 8n - 1n)) - 1n;\n else\n maxValue = 2n ** (BigInt(size) * 8n) - 1n;\n }\n else if (typeof value === 'number') {\n maxValue = BigInt(Number.MAX_SAFE_INTEGER);\n }\n const minValue = typeof maxValue === 'bigint' && signed ? -maxValue - 1n : 0;\n if ((maxValue && value_ > maxValue) || value_ < minValue) {\n const suffix = typeof value === 'bigint' ? 'n' : '';\n throw new IntegerOutOfRangeError({\n max: maxValue ? `${maxValue}${suffix}` : undefined,\n min: `${minValue}${suffix}`,\n signed,\n size,\n value: `${value}${suffix}`,\n });\n }\n const stringValue = (signed && value_ < 0 ? (1n << BigInt(size * 8)) + BigInt(value_) : value_).toString(16);\n const hex = `0x${stringValue}`;\n if (size)\n return padLeft(hex, size);\n return hex;\n}\n/**\n * Encodes a string into a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n * Hex.fromString('Hello World!')\n * // '0x48656c6c6f20576f726c6421'\n *\n * Hex.fromString('Hello World!', { size: 32 })\n * // '0x48656c6c6f20576f726c64210000000000000000000000000000000000000000'\n * ```\n *\n * @param value - The string value to encode.\n * @param options - Options.\n * @returns The encoded {@link ox#Hex.Hex} value.\n */\nexport function fromString(value, options = {}) {\n return fromBytes(encoder.encode(value), options);\n}\n/**\n * Checks if two {@link ox#Hex.Hex} values are equal.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.isEqual('0xdeadbeef', '0xdeadbeef')\n * // @log: true\n *\n * Hex.isEqual('0xda', '0xba')\n * // @log: false\n * ```\n *\n * @param hexA - The first {@link ox#Hex.Hex} value.\n * @param hexB - The second {@link ox#Hex.Hex} value.\n * @returns `true` if the two {@link ox#Hex.Hex} values are equal, `false` otherwise.\n */\nexport function isEqual(hexA, hexB) {\n return equalBytes(Bytes.fromHex(hexA), Bytes.fromHex(hexB));\n}\n/**\n * Pads a {@link ox#Hex.Hex} value to the left with zero bytes until it reaches the given `size` (default: 32 bytes).\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.padLeft('0x1234', 4)\n * // @log: '0x00001234'\n * ```\n *\n * @param value - The {@link ox#Hex.Hex} value to pad.\n * @param size - The size (in bytes) of the output hex value.\n * @returns The padded {@link ox#Hex.Hex} value.\n */\nexport function padLeft(value, size) {\n return internal.pad(value, { dir: 'left', size });\n}\n/**\n * Pads a {@link ox#Hex.Hex} value to the right with zero bytes until it reaches the given `size` (default: 32 bytes).\n *\n * @example\n * ```ts\n * import { Hex } from 'ox'\n *\n * Hex.padRight('0x1234', 4)\n * // @log: '0x12340000'\n * ```\n *\n * @param value - The {@link ox#Hex.Hex} value to pad.\n * @param size - The size (in bytes) of the output hex value.\n * @returns The padded {@link ox#Hex.Hex} value.\n */\nexport function padRight(value, size) {\n return internal.pad(value, { dir: 'right', size });\n}\n/**\n * Generates a random {@link ox#Hex.Hex} value of the specified length.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * const hex = Hex.random(32)\n * // @log: '0x...'\n * ```\n *\n * @returns Random {@link ox#Hex.Hex} value.\n */\nexport function random(length) {\n return fromBytes(Bytes.random(length));\n}\n/**\n * Returns a section of a {@link ox#Bytes.Bytes} value given a start/end bytes offset.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.slice('0x0123456789', 1, 4)\n * // @log: '0x234567'\n * ```\n *\n * @param value - The {@link ox#Hex.Hex} value to slice.\n * @param start - The start offset (in bytes).\n * @param end - The end offset (in bytes).\n * @param options - Options.\n * @returns The sliced {@link ox#Hex.Hex} value.\n */\nexport function slice(value, start, end, options = {}) {\n const { strict } = options;\n internal.assertStartOffset(value, start);\n const value_ = `0x${value\n .replace('0x', '')\n .slice((start ?? 0) * 2, (end ?? value.length) * 2)}`;\n if (strict)\n internal.assertEndOffset(value_, start, end);\n return value_;\n}\n/**\n * Retrieves the size of a {@link ox#Hex.Hex} value (in bytes).\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.size('0xdeadbeef')\n * // @log: 4\n * ```\n *\n * @param value - The {@link ox#Hex.Hex} value to get the size of.\n * @returns The size of the {@link ox#Hex.Hex} value (in bytes).\n */\nexport function size(value) {\n return Math.ceil((value.length - 2) / 2);\n}\n/**\n * Trims leading zeros from a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.trimLeft('0x00000000deadbeef')\n * // @log: '0xdeadbeef'\n * ```\n *\n * @param value - The {@link ox#Hex.Hex} value to trim.\n * @returns The trimmed {@link ox#Hex.Hex} value.\n */\nexport function trimLeft(value) {\n return internal.trim(value, { dir: 'left' });\n}\n/**\n * Trims trailing zeros from a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.trimRight('0xdeadbeef00000000')\n * // @log: '0xdeadbeef'\n * ```\n *\n * @param value - The {@link ox#Hex.Hex} value to trim.\n * @returns The trimmed {@link ox#Hex.Hex} value.\n */\nexport function trimRight(value) {\n return internal.trim(value, { dir: 'right' });\n}\n/**\n * Decodes a {@link ox#Hex.Hex} value into a BigInt.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.toBigInt('0x1a4')\n * // @log: 420n\n *\n * Hex.toBigInt('0x00000000000000000000000000000000000000000000000000000000000001a4', { size: 32 })\n * // @log: 420n\n * ```\n *\n * @param hex - The {@link ox#Hex.Hex} value to decode.\n * @param options - Options.\n * @returns The decoded BigInt.\n */\nexport function toBigInt(hex, options = {}) {\n const { signed } = options;\n if (options.size)\n internal.assertSize(hex, options.size);\n const value = BigInt(hex);\n if (!signed)\n return value;\n const size = (hex.length - 2) / 2;\n const max_unsigned = (1n << (BigInt(size) * 8n)) - 1n;\n const max_signed = max_unsigned >> 1n;\n if (value <= max_signed)\n return value;\n return value - max_unsigned - 1n;\n}\n/**\n * Decodes a {@link ox#Hex.Hex} value into a boolean.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.toBoolean('0x01')\n * // @log: true\n *\n * Hex.toBoolean('0x0000000000000000000000000000000000000000000000000000000000000001', { size: 32 })\n * // @log: true\n * ```\n *\n * @param hex - The {@link ox#Hex.Hex} value to decode.\n * @param options - Options.\n * @returns The decoded boolean.\n */\nexport function toBoolean(hex, options = {}) {\n if (options.size)\n internal.assertSize(hex, options.size);\n const hex_ = trimLeft(hex);\n if (hex_ === '0x')\n return false;\n if (hex_ === '0x1')\n return true;\n throw new InvalidHexBooleanError(hex);\n}\n/**\n * Decodes a {@link ox#Hex.Hex} value into a {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * const data = Hex.toBytes('0x48656c6c6f20776f726c6421')\n * // @log: Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33])\n * ```\n *\n * @param hex - The {@link ox#Hex.Hex} value to decode.\n * @param options - Options.\n * @returns The decoded {@link ox#Bytes.Bytes}.\n */\nexport function toBytes(hex, options = {}) {\n return Bytes.fromHex(hex, options);\n}\n/**\n * Decodes a {@link ox#Hex.Hex} value into a number.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.toNumber('0x1a4')\n * // @log: 420\n *\n * Hex.toNumber('0x00000000000000000000000000000000000000000000000000000000000001a4', { size: 32 })\n * // @log: 420\n * ```\n *\n * @param hex - The {@link ox#Hex.Hex} value to decode.\n * @param options - Options.\n * @returns The decoded number.\n */\nexport function toNumber(hex, options = {}) {\n const { signed, size } = options;\n if (!signed && !size)\n return Number(hex);\n return Number(toBigInt(hex, options));\n}\n/**\n * Decodes a {@link ox#Hex.Hex} value into a string.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.toString('0x48656c6c6f20576f726c6421')\n * // @log: 'Hello world!'\n *\n * Hex.toString('0x48656c6c6f20576f726c64210000000000000000000000000000000000000000', {\n * size: 32,\n * })\n * // @log: 'Hello world'\n * ```\n *\n * @param hex - The {@link ox#Hex.Hex} value to decode.\n * @param options - Options.\n * @returns The decoded string.\n */\nexport function toString(hex, options = {}) {\n const { size } = options;\n let bytes = Bytes.fromHex(hex);\n if (size) {\n internal_bytes.assertSize(bytes, size);\n bytes = Bytes.trimRight(bytes);\n }\n return new TextDecoder().decode(bytes);\n}\n/**\n * Checks if the given value is {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes, Hex } from 'ox'\n *\n * Hex.validate('0xdeadbeef')\n * // @log: true\n *\n * Hex.validate(Bytes.from([1, 2, 3]))\n * // @log: false\n * ```\n *\n * @param value - The value to check.\n * @param options - Options.\n * @returns `true` if the value is a {@link ox#Hex.Hex}, `false` otherwise.\n */\nexport function validate(value, options = {}) {\n const { strict = false } = options;\n try {\n assert(value, { strict });\n return true;\n }\n catch {\n return false;\n }\n}\n/**\n * Thrown when the provided integer is out of range, and cannot be represented as a hex value.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.fromNumber(420182738912731283712937129)\n * // @error: Hex.IntegerOutOfRangeError: Number \\`4.2018273891273126e+26\\` is not in safe unsigned integer range (`0` to `9007199254740991`)\n * ```\n */\nexport class IntegerOutOfRangeError extends Errors.BaseError {\n constructor({ max, min, signed, size, value, }) {\n super(`Number \\`${value}\\` is not in safe${size ? ` ${size * 8}-bit` : ''}${signed ? ' signed' : ' unsigned'} integer range ${max ? `(\\`${min}\\` to \\`${max}\\`)` : `(above \\`${min}\\`)`}`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.IntegerOutOfRangeError'\n });\n }\n}\n/**\n * Thrown when the provided hex value cannot be represented as a boolean.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.toBoolean('0xa')\n * // @error: Hex.InvalidHexBooleanError: Hex value `\"0xa\"` is not a valid boolean.\n * // @error: The hex value must be `\"0x0\"` (false) or `\"0x1\"` (true).\n * ```\n */\nexport class InvalidHexBooleanError extends Errors.BaseError {\n constructor(hex) {\n super(`Hex value \\`\"${hex}\"\\` is not a valid boolean.`, {\n metaMessages: [\n 'The hex value must be `\"0x0\"` (false) or `\"0x1\"` (true).',\n ],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.InvalidHexBooleanError'\n });\n }\n}\n/**\n * Thrown when the provided value is not a valid hex type.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.assert(1)\n * // @error: Hex.InvalidHexTypeError: Value `1` of type `number` is an invalid hex type.\n * ```\n */\nexport class InvalidHexTypeError extends Errors.BaseError {\n constructor(value) {\n super(`Value \\`${typeof value === 'object' ? Json.stringify(value) : value}\\` of type \\`${typeof value}\\` is an invalid hex type.`, {\n metaMessages: ['Hex types must be represented as `\"0x${string}\"`.'],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.InvalidHexTypeError'\n });\n }\n}\n/**\n * Thrown when the provided hex value is invalid.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.assert('0x0123456789abcdefg')\n * // @error: Hex.InvalidHexValueError: Value `0x0123456789abcdefg` is an invalid hex value.\n * // @error: Hex values must start with `\"0x\"` and contain only hexadecimal characters (0-9, a-f, A-F).\n * ```\n */\nexport class InvalidHexValueError extends Errors.BaseError {\n constructor(value) {\n super(`Value \\`${value}\\` is an invalid hex value.`, {\n metaMessages: [\n 'Hex values must start with `\"0x\"` and contain only hexadecimal characters (0-9, a-f, A-F).',\n ],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.InvalidHexValueError'\n });\n }\n}\n/**\n * Thrown when the provided hex value is an odd length.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.fromHex('0xabcde')\n * // @error: Hex.InvalidLengthError: Hex value `\"0xabcde\"` is an odd length (5 nibbles).\n * ```\n */\nexport class InvalidLengthError extends Errors.BaseError {\n constructor(value) {\n super(`Hex value \\`\"${value}\"\\` is an odd length (${value.length - 2} nibbles).`, {\n metaMessages: ['It must be an even length.'],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.InvalidLengthError'\n });\n }\n}\n/**\n * Thrown when the size of the value exceeds the expected max size.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.fromString('Hello World!', { size: 8 })\n * // @error: Hex.SizeOverflowError: Size cannot exceed `8` bytes. Given size: `12` bytes.\n * ```\n */\nexport class SizeOverflowError extends Errors.BaseError {\n constructor({ givenSize, maxSize }) {\n super(`Size cannot exceed \\`${maxSize}\\` bytes. Given size: \\`${givenSize}\\` bytes.`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.SizeOverflowError'\n });\n }\n}\n/**\n * Thrown when the slice offset exceeds the bounds of the value.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.slice('0x0123456789', 6)\n * // @error: Hex.SliceOffsetOutOfBoundsError: Slice starting at offset `6` is out-of-bounds (size: `5`).\n * ```\n */\nexport class SliceOffsetOutOfBoundsError extends Errors.BaseError {\n constructor({ offset, position, size, }) {\n super(`Slice ${position === 'start' ? 'starting' : 'ending'} at offset \\`${offset}\\` is out-of-bounds (size: \\`${size}\\`).`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.SliceOffsetOutOfBoundsError'\n });\n }\n}\n/**\n * Thrown when the size of the value exceeds the pad size.\n *\n * @example\n * ```ts twoslash\n * import { Hex } from 'ox'\n *\n * Hex.padLeft('0x1a4e12a45a21323123aaa87a897a897a898a6567a578a867a98778a667a85a875a87a6a787a65a675a6a9', 32)\n * // @error: Hex.SizeExceedsPaddingSizeError: Hex size (`43`) exceeds padding size (`32`).\n * ```\n */\nexport class SizeExceedsPaddingSizeError extends Errors.BaseError {\n constructor({ size, targetSize, type, }) {\n super(`${type.charAt(0).toUpperCase()}${type\n .slice(1)\n .toLowerCase()} size (\\`${size}\\`) exceeds padding size (\\`${targetSize}\\`).`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Hex.SizeExceedsPaddingSizeError'\n });\n }\n}\n//# sourceMappingURL=Hex.js.map","import { equalBytes } from '@noble/curves/abstract/utils';\nimport * as Errors from './Errors.js';\nimport * as Hex from './Hex.js';\nimport * as Json from './Json.js';\nimport * as internal from './internal/bytes.js';\nimport * as internal_hex from './internal/hex.js';\nconst decoder = /*#__PURE__*/ new TextDecoder();\nconst encoder = /*#__PURE__*/ new TextEncoder();\n/**\n * Asserts if the given value is {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.assert('abc')\n * // @error: Bytes.InvalidBytesTypeError:\n * // @error: Value `\"abc\"` of type `string` is an invalid Bytes value.\n * // @error: Bytes values must be of type `Uint8Array`.\n * ```\n *\n * @param value - Value to assert.\n */\nexport function assert(value) {\n if (value instanceof Uint8Array)\n return;\n if (!value)\n throw new InvalidBytesTypeError(value);\n if (typeof value !== 'object')\n throw new InvalidBytesTypeError(value);\n if (!('BYTES_PER_ELEMENT' in value))\n throw new InvalidBytesTypeError(value);\n if (value.BYTES_PER_ELEMENT !== 1 || value.constructor.name !== 'Uint8Array')\n throw new InvalidBytesTypeError(value);\n}\n/**\n * Concatenates two or more {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const bytes = Bytes.concat(\n * Bytes.from([1]),\n * Bytes.from([69]),\n * Bytes.from([420, 69]),\n * )\n * // @log: Uint8Array [ 1, 69, 420, 69 ]\n * ```\n *\n * @param values - Values to concatenate.\n * @returns Concatenated {@link ox#Bytes.Bytes}.\n */\nexport function concat(...values) {\n let length = 0;\n for (const arr of values) {\n length += arr.length;\n }\n const result = new Uint8Array(length);\n for (let i = 0, index = 0; i < values.length; i++) {\n const arr = values[i];\n result.set(arr, index);\n index += arr.length;\n }\n return result;\n}\n/**\n * Instantiates a {@link ox#Bytes.Bytes} value from a `Uint8Array`, a hex string, or an array of unsigned 8-bit integers.\n *\n * :::tip\n *\n * To instantiate from a **Boolean**, **String**, or **Number**, use one of the following:\n *\n * - `Bytes.fromBoolean`\n *\n * - `Bytes.fromString`\n *\n * - `Bytes.fromNumber`\n *\n * :::\n *\n * @example\n * ```ts twoslash\n * // @noErrors\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.from([255, 124, 5, 4])\n * // @log: Uint8Array([255, 124, 5, 4])\n *\n * const data = Bytes.from('0xdeadbeef')\n * // @log: Uint8Array([222, 173, 190, 239])\n * ```\n *\n * @param value - Value to convert.\n * @returns A {@link ox#Bytes.Bytes} instance.\n */\nexport function from(value) {\n if (value instanceof Uint8Array)\n return value;\n if (typeof value === 'string')\n return fromHex(value);\n return fromArray(value);\n}\n/**\n * Converts an array of unsigned 8-bit integers into {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromArray([255, 124, 5, 4])\n * // @log: Uint8Array([255, 124, 5, 4])\n * ```\n *\n * @param value - Value to convert.\n * @returns A {@link ox#Bytes.Bytes} instance.\n */\nexport function fromArray(value) {\n return value instanceof Uint8Array ? value : new Uint8Array(value);\n}\n/**\n * Encodes a boolean value into {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromBoolean(true)\n * // @log: Uint8Array([1])\n * ```\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromBoolean(true, { size: 32 })\n * // @log: Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1])\n * ```\n *\n * @param value - Boolean value to encode.\n * @param options - Encoding options.\n * @returns Encoded {@link ox#Bytes.Bytes}.\n */\nexport function fromBoolean(value, options = {}) {\n const { size } = options;\n const bytes = new Uint8Array(1);\n bytes[0] = Number(value);\n if (typeof size === 'number') {\n internal.assertSize(bytes, size);\n return padLeft(bytes, size);\n }\n return bytes;\n}\n/**\n * Encodes a {@link ox#Hex.Hex} value into {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromHex('0x48656c6c6f20776f726c6421')\n * // @log: Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33])\n * ```\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromHex('0x48656c6c6f20776f726c6421', { size: 32 })\n * // @log: Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0])\n * ```\n *\n * @param value - {@link ox#Hex.Hex} value to encode.\n * @param options - Encoding options.\n * @returns Encoded {@link ox#Bytes.Bytes}.\n */\nexport function fromHex(value, options = {}) {\n const { size } = options;\n let hex = value;\n if (size) {\n internal_hex.assertSize(value, size);\n hex = Hex.padRight(value, size);\n }\n let hexString = hex.slice(2);\n if (hexString.length % 2)\n hexString = `0${hexString}`;\n const length = hexString.length / 2;\n const bytes = new Uint8Array(length);\n for (let index = 0, j = 0; index < length; index++) {\n const nibbleLeft = internal.charCodeToBase16(hexString.charCodeAt(j++));\n const nibbleRight = internal.charCodeToBase16(hexString.charCodeAt(j++));\n if (nibbleLeft === undefined || nibbleRight === undefined) {\n throw new Errors.BaseError(`Invalid byte sequence (\"${hexString[j - 2]}${hexString[j - 1]}\" in \"${hexString}\").`);\n }\n bytes[index] = nibbleLeft * 16 + nibbleRight;\n }\n return bytes;\n}\n/**\n * Encodes a number value into {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromNumber(420)\n * // @log: Uint8Array([1, 164])\n * ```\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromNumber(420, { size: 4 })\n * // @log: Uint8Array([0, 0, 1, 164])\n * ```\n *\n * @param value - Number value to encode.\n * @param options - Encoding options.\n * @returns Encoded {@link ox#Bytes.Bytes}.\n */\nexport function fromNumber(value, options) {\n const hex = Hex.fromNumber(value, options);\n return fromHex(hex);\n}\n/**\n * Encodes a string into {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromString('Hello world!')\n * // @log: Uint8Array([72, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100, 33])\n * ```\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.fromString('Hello world!', { size: 32 })\n * // @log: Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0])\n * ```\n *\n * @param value - String to encode.\n * @param options - Encoding options.\n * @returns Encoded {@link ox#Bytes.Bytes}.\n */\nexport function fromString(value, options = {}) {\n const { size } = options;\n const bytes = encoder.encode(value);\n if (typeof size === 'number') {\n internal.assertSize(bytes, size);\n return padRight(bytes, size);\n }\n return bytes;\n}\n/**\n * Checks if two {@link ox#Bytes.Bytes} values are equal.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.isEqual(Bytes.from([1]), Bytes.from([1]))\n * // @log: true\n *\n * Bytes.isEqual(Bytes.from([1]), Bytes.from([2]))\n * // @log: false\n * ```\n *\n * @param bytesA - First {@link ox#Bytes.Bytes} value.\n * @param bytesB - Second {@link ox#Bytes.Bytes} value.\n * @returns `true` if the two values are equal, otherwise `false`.\n */\nexport function isEqual(bytesA, bytesB) {\n return equalBytes(bytesA, bytesB);\n}\n/**\n * Pads a {@link ox#Bytes.Bytes} value to the left with zero bytes until it reaches the given `size` (default: 32 bytes).\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.padLeft(Bytes.from([1]), 4)\n * // @log: Uint8Array([0, 0, 0, 1])\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} value to pad.\n * @param size - Size to pad the {@link ox#Bytes.Bytes} value to.\n * @returns Padded {@link ox#Bytes.Bytes} value.\n */\nexport function padLeft(value, size) {\n return internal.pad(value, { dir: 'left', size });\n}\n/**\n * Pads a {@link ox#Bytes.Bytes} value to the right with zero bytes until it reaches the given `size` (default: 32 bytes).\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.padRight(Bytes.from([1]), 4)\n * // @log: Uint8Array([1, 0, 0, 0])\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} value to pad.\n * @param size - Size to pad the {@link ox#Bytes.Bytes} value to.\n * @returns Padded {@link ox#Bytes.Bytes} value.\n */\nexport function padRight(value, size) {\n return internal.pad(value, { dir: 'right', size });\n}\n/**\n * Generates random {@link ox#Bytes.Bytes} of the specified length.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const bytes = Bytes.random(32)\n * // @log: Uint8Array([... x32])\n * ```\n *\n * @param length - Length of the random {@link ox#Bytes.Bytes} to generate.\n * @returns Random {@link ox#Bytes.Bytes} of the specified length.\n */\nexport function random(length) {\n return crypto.getRandomValues(new Uint8Array(length));\n}\n/**\n * Retrieves the size of a {@link ox#Bytes.Bytes} value.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.size(Bytes.from([1, 2, 3, 4]))\n * // @log: 4\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} value.\n * @returns Size of the {@link ox#Bytes.Bytes} value.\n */\nexport function size(value) {\n return value.length;\n}\n/**\n * Returns a section of a {@link ox#Bytes.Bytes} value given a start/end bytes offset.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.slice(\n * Bytes.from([1, 2, 3, 4, 5, 6, 7, 8, 9]),\n * 1,\n * 4,\n * )\n * // @log: Uint8Array([2, 3, 4])\n * ```\n *\n * @param value - The {@link ox#Bytes.Bytes} value.\n * @param start - Start offset.\n * @param end - End offset.\n * @param options - Slice options.\n * @returns Sliced {@link ox#Bytes.Bytes} value.\n */\nexport function slice(value, start, end, options = {}) {\n const { strict } = options;\n internal.assertStartOffset(value, start);\n const value_ = value.slice(start, end);\n if (strict)\n internal.assertEndOffset(value_, start, end);\n return value_;\n}\n/**\n * Decodes a {@link ox#Bytes.Bytes} into a bigint.\n *\n * @example\n * ```ts\n * import { Bytes } from 'ox'\n *\n * Bytes.toBigInt(Bytes.from([1, 164]))\n * // @log: 420n\n * ```\n *\n * @param bytes - The {@link ox#Bytes.Bytes} to decode.\n * @param options - Decoding options.\n * @returns Decoded bigint.\n */\nexport function toBigInt(bytes, options = {}) {\n const { size } = options;\n if (typeof size !== 'undefined')\n internal.assertSize(bytes, size);\n const hex = Hex.fromBytes(bytes, options);\n return Hex.toBigInt(hex, options);\n}\n/**\n * Decodes a {@link ox#Bytes.Bytes} into a boolean.\n *\n * @example\n * ```ts\n * import { Bytes } from 'ox'\n *\n * Bytes.toBoolean(Bytes.from([1]))\n * // @log: true\n * ```\n *\n * @param bytes - The {@link ox#Bytes.Bytes} to decode.\n * @param options - Decoding options.\n * @returns Decoded boolean.\n */\nexport function toBoolean(bytes, options = {}) {\n const { size } = options;\n let bytes_ = bytes;\n if (typeof size !== 'undefined') {\n internal.assertSize(bytes_, size);\n bytes_ = trimLeft(bytes_);\n }\n if (bytes_.length > 1 || bytes_[0] > 1)\n throw new InvalidBytesBooleanError(bytes_);\n return Boolean(bytes_[0]);\n}\n/**\n * Encodes a {@link ox#Bytes.Bytes} value into a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.toHex(Bytes.from([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33]))\n * // '0x48656c6c6f20576f726c6421'\n * ```\n *\n * @param value - The {@link ox#Bytes.Bytes} to decode.\n * @param options - Options.\n * @returns Decoded {@link ox#Hex.Hex} value.\n */\nexport function toHex(value, options = {}) {\n return Hex.fromBytes(value, options);\n}\n/**\n * Decodes a {@link ox#Bytes.Bytes} into a number.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.toNumber(Bytes.from([1, 164]))\n * // @log: 420\n * ```\n */\nexport function toNumber(bytes, options = {}) {\n const { size } = options;\n if (typeof size !== 'undefined')\n internal.assertSize(bytes, size);\n const hex = Hex.fromBytes(bytes, options);\n return Hex.toNumber(hex, options);\n}\n/**\n * Decodes a {@link ox#Bytes.Bytes} into a string.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * const data = Bytes.toString(Bytes.from([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33]))\n * // @log: 'Hello world'\n * ```\n *\n * @param bytes - The {@link ox#Bytes.Bytes} to decode.\n * @param options - Options.\n * @returns Decoded string.\n */\nexport function toString(bytes, options = {}) {\n const { size } = options;\n let bytes_ = bytes;\n if (typeof size !== 'undefined') {\n internal.assertSize(bytes_, size);\n bytes_ = trimRight(bytes_);\n }\n return decoder.decode(bytes_);\n}\n/**\n * Trims leading zeros from a {@link ox#Bytes.Bytes} value.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.trimLeft(Bytes.from([0, 0, 0, 0, 1, 2, 3]))\n * // @log: Uint8Array([1, 2, 3])\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} value.\n * @returns Trimmed {@link ox#Bytes.Bytes} value.\n */\nexport function trimLeft(value) {\n return internal.trim(value, { dir: 'left' });\n}\n/**\n * Trims trailing zeros from a {@link ox#Bytes.Bytes} value.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.trimRight(Bytes.from([1, 2, 3, 0, 0, 0, 0]))\n * // @log: Uint8Array([1, 2, 3])\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} value.\n * @returns Trimmed {@link ox#Bytes.Bytes} value.\n */\nexport function trimRight(value) {\n return internal.trim(value, { dir: 'right' });\n}\n/**\n * Checks if the given value is {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.validate('0x')\n * // @log: false\n *\n * Bytes.validate(Bytes.from([1, 2, 3]))\n * // @log: true\n * ```\n *\n * @param value - Value to check.\n * @returns `true` if the value is {@link ox#Bytes.Bytes}, otherwise `false`.\n */\nexport function validate(value) {\n try {\n assert(value);\n return true;\n }\n catch {\n return false;\n }\n}\n/**\n * Thrown when the bytes value cannot be represented as a boolean.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.toBoolean(Bytes.from([5]))\n * // @error: Bytes.InvalidBytesBooleanError: Bytes value `[5]` is not a valid boolean.\n * // @error: The bytes array must contain a single byte of either a `0` or `1` value.\n * ```\n */\nexport class InvalidBytesBooleanError extends Errors.BaseError {\n constructor(bytes) {\n super(`Bytes value \\`${bytes}\\` is not a valid boolean.`, {\n metaMessages: [\n 'The bytes array must contain a single byte of either a `0` or `1` value.',\n ],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Bytes.InvalidBytesBooleanError'\n });\n }\n}\n/**\n * Thrown when a value cannot be converted to bytes.\n *\n * @example\n * ```ts twoslash\n * // @noErrors\n * import { Bytes } from 'ox'\n *\n * Bytes.from('foo')\n * // @error: Bytes.InvalidBytesTypeError: Value `foo` of type `string` is an invalid Bytes value.\n * ```\n */\nexport class InvalidBytesTypeError extends Errors.BaseError {\n constructor(value) {\n super(`Value \\`${typeof value === 'object' ? Json.stringify(value) : value}\\` of type \\`${typeof value}\\` is an invalid Bytes value.`, {\n metaMessages: ['Bytes values must be of type `Bytes`.'],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Bytes.InvalidBytesTypeError'\n });\n }\n}\n/**\n * Thrown when a size exceeds the maximum allowed size.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.fromString('Hello World!', { size: 8 })\n * // @error: Bytes.SizeOverflowError: Size cannot exceed `8` bytes. Given size: `12` bytes.\n * ```\n */\nexport class SizeOverflowError extends Errors.BaseError {\n constructor({ givenSize, maxSize }) {\n super(`Size cannot exceed \\`${maxSize}\\` bytes. Given size: \\`${givenSize}\\` bytes.`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Bytes.SizeOverflowError'\n });\n }\n}\n/**\n * Thrown when a slice offset is out-of-bounds.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.slice(Bytes.from([1, 2, 3]), 4)\n * // @error: Bytes.SliceOffsetOutOfBoundsError: Slice starting at offset `4` is out-of-bounds (size: `3`).\n * ```\n */\nexport class SliceOffsetOutOfBoundsError extends Errors.BaseError {\n constructor({ offset, position, size, }) {\n super(`Slice ${position === 'start' ? 'starting' : 'ending'} at offset \\`${offset}\\` is out-of-bounds (size: \\`${size}\\`).`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Bytes.SliceOffsetOutOfBoundsError'\n });\n }\n}\n/**\n * Thrown when a the padding size exceeds the maximum allowed size.\n *\n * @example\n * ```ts twoslash\n * import { Bytes } from 'ox'\n *\n * Bytes.padLeft(Bytes.fromString('Hello World!'), 8)\n * // @error: [Bytes.SizeExceedsPaddingSizeError: Bytes size (`12`) exceeds padding size (`8`).\n * ```\n */\nexport class SizeExceedsPaddingSizeError extends Errors.BaseError {\n constructor({ size, targetSize, type, }) {\n super(`${type.charAt(0).toUpperCase()}${type\n .slice(1)\n .toLowerCase()} size (\\`${size}\\`) exceeds padding size (\\`${targetSize}\\`).`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Bytes.SizeExceedsPaddingSizeError'\n });\n }\n}\n//# sourceMappingURL=Bytes.js.map","import { ripemd160 as noble_ripemd160 } from '@noble/hashes/ripemd160';\nimport { keccak_256 as noble_keccak256 } from '@noble/hashes/sha3';\nimport { sha256 as noble_sha256 } from '@noble/hashes/sha256';\nimport * as Bytes from './Bytes.js';\nimport * as Hex from './Hex.js';\n/**\n * Calculates the [Keccak256](https://en.wikipedia.org/wiki/SHA-3) hash of a {@link ox#Bytes.Bytes} or {@link ox#Hex.Hex} value.\n *\n * This function is a re-export of `keccak_256` from [`@noble/hashes`](https://github.com/paulmillr/noble-hashes), an audited & minimal JS hashing library.\n *\n * @example\n * ```ts twoslash\n * import { Hash } from 'ox'\n *\n * Hash.keccak256('0xdeadbeef')\n * // @log: '0xd4fd4e189132273036449fc9e11198c739161b4c0116a9a2dccdfa1c492006f1'\n * ```\n *\n * @example\n * ### Calculate Hash of a String\n *\n * ```ts twoslash\n * import { Hash, Hex } from 'ox'\n *\n * Hash.keccak256(Hex.fromString('hello world'))\n * // @log: '0x3ea2f1d0abf3fc66cf29eebb70cbd4e7fe762ef8a09bcc06c8edf641230afec0'\n * ```\n *\n * @example\n * ### Configure Return Type\n *\n * ```ts twoslash\n * import { Hash } from 'ox'\n *\n * Hash.keccak256('0xdeadbeef', { as: 'Bytes' })\n * // @log: Uint8Array [...]\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} or {@link ox#Hex.Hex} value.\n * @param options - Options.\n * @returns Keccak256 hash.\n */\nexport function keccak256(value, options = {}) {\n const { as = typeof value === 'string' ? 'Hex' : 'Bytes' } = options;\n const bytes = noble_keccak256(Bytes.from(value));\n if (as === 'Bytes')\n return bytes;\n return Hex.fromBytes(bytes);\n}\n/**\n * Calculates the [Ripemd160](https://en.wikipedia.org/wiki/RIPEMD) hash of a {@link ox#Bytes.Bytes} or {@link ox#Hex.Hex} value.\n *\n * This function is a re-export of `ripemd160` from [`@noble/hashes`](https://github.com/paulmillr/noble-hashes), an audited & minimal JS hashing library.\n *\n * @example\n * ```ts twoslash\n * import { Hash } from 'ox'\n *\n * Hash.ripemd160('0xdeadbeef')\n * // '0x226821c2f5423e11fe9af68bd285c249db2e4b5a'\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} or {@link ox#Hex.Hex} value.\n * @param options - Options.\n * @returns Ripemd160 hash.\n */\nexport function ripemd160(value, options = {}) {\n const { as = typeof value === 'string' ? 'Hex' : 'Bytes' } = options;\n const bytes = noble_ripemd160(Bytes.from(value));\n if (as === 'Bytes')\n return bytes;\n return Hex.fromBytes(bytes);\n}\n/**\n * Calculates the [Sha256](https://en.wikipedia.org/wiki/SHA-256) hash of a {@link ox#Bytes.Bytes} or {@link ox#Hex.Hex} value.\n *\n * This function is a re-export of `sha256` from [`@noble/hashes`](https://github.com/paulmillr/noble-hashes), an audited & minimal JS hashing library.\n *\n * @example\n * ```ts twoslash\n * import { Hash } from 'ox'\n *\n * Hash.sha256('0xdeadbeef')\n * // '0x5f78c33274e43fa9de5659265c1d917e25c03722dcb0b8d27db8d5feaa813953'\n * ```\n *\n * @param value - {@link ox#Bytes.Bytes} or {@link ox#Hex.Hex} value.\n * @param options - Options.\n * @returns Sha256 hash.\n */\nexport function sha256(value, options = {}) {\n const { as = typeof value === 'string' ? 'Hex' : 'Bytes' } = options;\n const bytes = noble_sha256(Bytes.from(value));\n if (as === 'Bytes')\n return bytes;\n return Hex.fromBytes(bytes);\n}\n/**\n * Checks if a string is a valid hash value.\n *\n * @example\n * ```ts twoslash\n * import { Hash } from 'ox'\n *\n * Hash.validate('0x')\n * // @log: false\n *\n * Hash.validate('0x3ea2f1d0abf3fc66cf29eebb70cbd4e7fe762ef8a09bcc06c8edf641230afec0')\n * // @log: true\n * ```\n *\n * @param value - Value to check.\n * @returns Whether the value is a valid hash.\n */\nexport function validate(value) {\n return Hex.validate(value) && Hex.size(value) === 32;\n}\n//# sourceMappingURL=Hash.js.map","import * as Bytes from './Bytes.js';\nimport * as Errors from './Errors.js';\nimport * as Hex from './Hex.js';\nimport * as Json from './Json.js';\n/**\n * Asserts that a {@link ox#PublicKey.PublicKey} is valid.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * PublicKey.assert({\n * prefix: 4,\n * y: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * })\n * // @error: PublicKey.InvalidError: Value \\`{\"y\":\"1\"}\\` is not a valid public key.\n * // @error: Public key must contain:\n * // @error: - an `x` and `prefix` value (compressed)\n * // @error: - an `x`, `y`, and `prefix` value (uncompressed)\n * ```\n *\n * @param publicKey - The public key object to assert.\n */\nexport function assert(publicKey, options = {}) {\n const { compressed } = options;\n const { prefix, x, y } = publicKey;\n // Uncompressed\n if (compressed === false ||\n (typeof x === 'bigint' && typeof y === 'bigint')) {\n if (prefix !== 4)\n throw new InvalidPrefixError({\n prefix,\n cause: new InvalidUncompressedPrefixError(),\n });\n return;\n }\n // Compressed\n if (compressed === true ||\n (typeof x === 'bigint' && typeof y === 'undefined')) {\n if (prefix !== 3 && prefix !== 2)\n throw new InvalidPrefixError({\n prefix,\n cause: new InvalidCompressedPrefixError(),\n });\n return;\n }\n // Unknown/invalid\n throw new InvalidError({ publicKey });\n}\n/**\n * Compresses a {@link ox#PublicKey.PublicKey}.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.from({\n * prefix: 4,\n * x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * })\n *\n * const compressed = PublicKey.compress(publicKey) // [!code focus]\n * // @log: {\n * // @log: prefix: 3,\n * // @log: x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * // @log: }\n * ```\n *\n * @param publicKey - The public key to compress.\n * @returns The compressed public key.\n */\nexport function compress(publicKey) {\n const { x, y } = publicKey;\n return {\n prefix: y % 2n === 0n ? 2 : 3,\n x,\n };\n}\n/**\n * Instantiates a typed {@link ox#PublicKey.PublicKey} object from a {@link ox#PublicKey.PublicKey}, {@link ox#Bytes.Bytes}, or {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.from({\n * prefix: 4,\n * x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * })\n * // @log: {\n * // @log: prefix: 4,\n * // @log: x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * // @log: y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * // @log: }\n * ```\n *\n * @example\n * ### From Serialized\n *\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.from('0x048318535b54105d4a7aae60c08fc45f9687181b4fdfc625bd1a753fa7397fed753547f11ca8696646f2f3acb08e31016afac23e630c5d11f59f61fef57b0d2aa5')\n * // @log: {\n * // @log: prefix: 4,\n * // @log: x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * // @log: y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * // @log: }\n * ```\n *\n * @param value - The public key value to instantiate.\n * @returns The instantiated {@link ox#PublicKey.PublicKey}.\n */\nexport function from(value) {\n const publicKey = (() => {\n if (Hex.validate(value))\n return fromHex(value);\n if (Bytes.validate(value))\n return fromBytes(value);\n const { prefix, x, y } = value;\n if (typeof x === 'bigint' && typeof y === 'bigint')\n return { prefix: prefix ?? 0x04, x, y };\n return { prefix, x };\n })();\n assert(publicKey);\n return publicKey;\n}\n/**\n * Deserializes a {@link ox#PublicKey.PublicKey} from a {@link ox#Bytes.Bytes} value.\n *\n * @example\n * ```ts twoslash\n * // @noErrors\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.fromBytes(new Uint8Array([128, 3, 131, ...]))\n * // @log: {\n * // @log: prefix: 4,\n * // @log: x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * // @log: y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * // @log: }\n * ```\n *\n * @param publicKey - The serialized public key.\n * @returns The deserialized public key.\n */\nexport function fromBytes(publicKey) {\n return fromHex(Hex.fromBytes(publicKey));\n}\n/**\n * Deserializes a {@link ox#PublicKey.PublicKey} from a {@link ox#Hex.Hex} value.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.fromHex('0x8318535b54105d4a7aae60c08fc45f9687181b4fdfc625bd1a753fa7397fed753547f11ca8696646f2f3acb08e31016afac23e630c5d11f59f61fef57b0d2aa5')\n * // @log: {\n * // @log: prefix: 4,\n * // @log: x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * // @log: y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * // @log: }\n * ```\n *\n * @example\n * ### Deserializing a Compressed Public Key\n *\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.fromHex('0x038318535b54105d4a7aae60c08fc45f9687181b4fdfc625bd1a753fa7397fed75')\n * // @log: {\n * // @log: prefix: 3,\n * // @log: x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * // @log: }\n * ```\n *\n * @param publicKey - The serialized public key.\n * @returns The deserialized public key.\n */\nexport function fromHex(publicKey) {\n if (publicKey.length !== 132 &&\n publicKey.length !== 130 &&\n publicKey.length !== 68)\n throw new InvalidSerializedSizeError({ publicKey });\n if (publicKey.length === 130) {\n const x = BigInt(Hex.slice(publicKey, 0, 32));\n const y = BigInt(Hex.slice(publicKey, 32, 64));\n return {\n prefix: 4,\n x,\n y,\n };\n }\n if (publicKey.length === 132) {\n const prefix = Number(Hex.slice(publicKey, 0, 1));\n const x = BigInt(Hex.slice(publicKey, 1, 33));\n const y = BigInt(Hex.slice(publicKey, 33, 65));\n return {\n prefix,\n x,\n y,\n };\n }\n const prefix = Number(Hex.slice(publicKey, 0, 1));\n const x = BigInt(Hex.slice(publicKey, 1, 33));\n return {\n prefix,\n x,\n };\n}\n/**\n * Serializes a {@link ox#PublicKey.PublicKey} to {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.from({\n * prefix: 4,\n * x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * })\n *\n * const bytes = PublicKey.toBytes(publicKey) // [!code focus]\n * // @log: Uint8Array [128, 3, 131, ...]\n * ```\n *\n * @param publicKey - The public key to serialize.\n * @returns The serialized public key.\n */\nexport function toBytes(publicKey, options = {}) {\n return Bytes.fromHex(toHex(publicKey, options));\n}\n/**\n * Serializes a {@link ox#PublicKey.PublicKey} to {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const publicKey = PublicKey.from({\n * prefix: 4,\n * x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * })\n *\n * const hex = PublicKey.toHex(publicKey) // [!code focus]\n * // @log: '0x048318535b54105d4a7aae60c08fc45f9687181b4fdfc625bd1a753fa7397fed753547f11ca8696646f2f3acb08e31016afac23e630c5d11f59f61fef57b0d2aa5'\n * ```\n *\n * @param publicKey - The public key to serialize.\n * @returns The serialized public key.\n */\nexport function toHex(publicKey, options = {}) {\n assert(publicKey);\n const { prefix, x, y } = publicKey;\n const { includePrefix = true } = options;\n const publicKey_ = Hex.concat(includePrefix ? Hex.fromNumber(prefix, { size: 1 }) : '0x', Hex.fromNumber(x, { size: 32 }), \n // If the public key is not compressed, add the y coordinate.\n typeof y === 'bigint' ? Hex.fromNumber(y, { size: 32 }) : '0x');\n return publicKey_;\n}\n/**\n * Validates a {@link ox#PublicKey.PublicKey}. Returns `true` if valid, `false` otherwise.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * const valid = PublicKey.validate({\n * prefix: 4,\n * y: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * })\n * // @log: false\n * ```\n *\n * @param publicKey - The public key object to assert.\n */\nexport function validate(publicKey, options = {}) {\n try {\n assert(publicKey, options);\n return true;\n }\n catch (error) {\n return false;\n }\n}\n/**\n * Thrown when a public key is invalid.\n *\n * @example\n * ```ts twoslash\n * import { PublicKey } from 'ox'\n *\n * PublicKey.assert({ y: 1n })\n * // @error: PublicKey.InvalidError: Value `{\"y\":1n}` is not a valid public key.\n * // @error: Public key must contain:\n * // @error: - an `x` and `prefix` value (compressed)\n * // @error: - an `x`, `y`, and `prefix` value (uncompressed)\n * ```\n */\nexport class InvalidError extends Errors.BaseError {\n constructor({ publicKey }) {\n super(`Value \\`${Json.stringify(publicKey)}\\` is not a valid public key.`, {\n metaMessages: [\n 'Public key must contain:',\n '- an `x` and `prefix` value (compressed)',\n '- an `x`, `y`, and `prefix` value (uncompressed)',\n ],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'PublicKey.InvalidError'\n });\n }\n}\n/** Thrown when a public key has an invalid prefix. */\nexport class InvalidPrefixError extends Errors.BaseError {\n constructor({ prefix, cause }) {\n super(`Prefix \"${prefix}\" is invalid.`, {\n cause,\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'PublicKey.InvalidPrefixError'\n });\n }\n}\n/** Thrown when the public key has an invalid prefix for a compressed public key. */\nexport class InvalidCompressedPrefixError extends Errors.BaseError {\n constructor() {\n super('Prefix must be 2 or 3 for compressed public keys.');\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'PublicKey.InvalidCompressedPrefixError'\n });\n }\n}\n/** Thrown when the public key has an invalid prefix for an uncompressed public key. */\nexport class InvalidUncompressedPrefixError extends Errors.BaseError {\n constructor() {\n super('Prefix must be 4 for uncompressed public keys.');\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'PublicKey.InvalidUncompressedPrefixError'\n });\n }\n}\n/** Thrown when the public key has an invalid serialized size. */\nexport class InvalidSerializedSizeError extends Errors.BaseError {\n constructor({ publicKey }) {\n super(`Value \\`${publicKey}\\` is an invalid public key size.`, {\n metaMessages: [\n 'Expected: 33 bytes (compressed + prefix), 64 bytes (uncompressed) or 65 bytes (uncompressed + prefix).',\n `Received ${Hex.size(Hex.from(publicKey))} bytes.`,\n ],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'PublicKey.InvalidSerializedSizeError'\n });\n }\n}\n//# sourceMappingURL=PublicKey.js.map","export const arrayRegex = /^(.*)\\[([0-9]*)\\]$/;\n// `bytes<M>`: binary type of `M` bytes, `0 < M <= 32`\n// https://regexr.com/6va55\nexport const bytesRegex = /^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/;\n// `(u)int<M>`: (un)signed integer type of `M` bits, `0 < M <= 256`, `M % 8 == 0`\n// https://regexr.com/6v8hp\nexport const integerRegex = /^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;\nexport const maxInt8 = 2n ** (8n - 1n) - 1n;\nexport const maxInt16 = 2n ** (16n - 1n) - 1n;\nexport const maxInt24 = 2n ** (24n - 1n) - 1n;\nexport const maxInt32 = 2n ** (32n - 1n) - 1n;\nexport const maxInt40 = 2n ** (40n - 1n) - 1n;\nexport const maxInt48 = 2n ** (48n - 1n) - 1n;\nexport const maxInt56 = 2n ** (56n - 1n) - 1n;\nexport const maxInt64 = 2n ** (64n - 1n) - 1n;\nexport const maxInt72 = 2n ** (72n - 1n) - 1n;\nexport const maxInt80 = 2n ** (80n - 1n) - 1n;\nexport const maxInt88 = 2n ** (88n - 1n) - 1n;\nexport const maxInt96 = 2n ** (96n - 1n) - 1n;\nexport const maxInt104 = 2n ** (104n - 1n) - 1n;\nexport const maxInt112 = 2n ** (112n - 1n) - 1n;\nexport const maxInt120 = 2n ** (120n - 1n) - 1n;\nexport const maxInt128 = 2n ** (128n - 1n) - 1n;\nexport const maxInt136 = 2n ** (136n - 1n) - 1n;\nexport const maxInt144 = 2n ** (144n - 1n) - 1n;\nexport const maxInt152 = 2n ** (152n - 1n) - 1n;\nexport const maxInt160 = 2n ** (160n - 1n) - 1n;\nexport const maxInt168 = 2n ** (168n - 1n) - 1n;\nexport const maxInt176 = 2n ** (176n - 1n) - 1n;\nexport const maxInt184 = 2n ** (184n - 1n) - 1n;\nexport const maxInt192 = 2n ** (192n - 1n) - 1n;\nexport const maxInt200 = 2n ** (200n - 1n) - 1n;\nexport const maxInt208 = 2n ** (208n - 1n) - 1n;\nexport const maxInt216 = 2n ** (216n - 1n) - 1n;\nexport const maxInt224 = 2n ** (224n - 1n) - 1n;\nexport const maxInt232 = 2n ** (232n - 1n) - 1n;\nexport const maxInt240 = 2n ** (240n - 1n) - 1n;\nexport const maxInt248 = 2n ** (248n - 1n) - 1n;\nexport const maxInt256 = 2n ** (256n - 1n) - 1n;\nexport const minInt8 = -(2n ** (8n - 1n));\nexport const minInt16 = -(2n ** (16n - 1n));\nexport const minInt24 = -(2n ** (24n - 1n));\nexport const minInt32 = -(2n ** (32n - 1n));\nexport const minInt40 = -(2n ** (40n - 1n));\nexport const minInt48 = -(2n ** (48n - 1n));\nexport const minInt56 = -(2n ** (56n - 1n));\nexport const minInt64 = -(2n ** (64n - 1n));\nexport const minInt72 = -(2n ** (72n - 1n));\nexport const minInt80 = -(2n ** (80n - 1n));\nexport const minInt88 = -(2n ** (88n - 1n));\nexport const minInt96 = -(2n ** (96n - 1n));\nexport const minInt104 = -(2n ** (104n - 1n));\nexport const minInt112 = -(2n ** (112n - 1n));\nexport const minInt120 = -(2n ** (120n - 1n));\nexport const minInt128 = -(2n ** (128n - 1n));\nexport const minInt136 = -(2n ** (136n - 1n));\nexport const minInt144 = -(2n ** (144n - 1n));\nexport const minInt152 = -(2n ** (152n - 1n));\nexport const minInt160 = -(2n ** (160n - 1n));\nexport const minInt168 = -(2n ** (168n - 1n));\nexport const minInt176 = -(2n ** (176n - 1n));\nexport const minInt184 = -(2n ** (184n - 1n));\nexport const minInt192 = -(2n ** (192n - 1n));\nexport const minInt200 = -(2n ** (200n - 1n));\nexport const minInt208 = -(2n ** (208n - 1n));\nexport const minInt216 = -(2n ** (216n - 1n));\nexport const minInt224 = -(2n ** (224n - 1n));\nexport const minInt232 = -(2n ** (232n - 1n));\nexport const minInt240 = -(2n ** (240n - 1n));\nexport const minInt248 = -(2n ** (248n - 1n));\nexport const minInt256 = -(2n ** (256n - 1n));\nexport const maxUint8 = 2n ** 8n - 1n;\nexport const maxUint16 = 2n ** 16n - 1n;\nexport const maxUint24 = 2n ** 24n - 1n;\nexport const maxUint32 = 2n ** 32n - 1n;\nexport const maxUint40 = 2n ** 40n - 1n;\nexport const maxUint48 = 2n ** 48n - 1n;\nexport const maxUint56 = 2n ** 56n - 1n;\nexport const maxUint64 = 2n ** 64n - 1n;\nexport const maxUint72 = 2n ** 72n - 1n;\nexport const maxUint80 = 2n ** 80n - 1n;\nexport const maxUint88 = 2n ** 88n - 1n;\nexport const maxUint96 = 2n ** 96n - 1n;\nexport const maxUint104 = 2n ** 104n - 1n;\nexport const maxUint112 = 2n ** 112n - 1n;\nexport const maxUint120 = 2n ** 120n - 1n;\nexport const maxUint128 = 2n ** 128n - 1n;\nexport const maxUint136 = 2n ** 136n - 1n;\nexport const maxUint144 = 2n ** 144n - 1n;\nexport const maxUint152 = 2n ** 152n - 1n;\nexport const maxUint160 = 2n ** 160n - 1n;\nexport const maxUint168 = 2n ** 168n - 1n;\nexport const maxUint176 = 2n ** 176n - 1n;\nexport const maxUint184 = 2n ** 184n - 1n;\nexport const maxUint192 = 2n ** 192n - 1n;\nexport const maxUint200 = 2n ** 200n - 1n;\nexport const maxUint208 = 2n ** 208n - 1n;\nexport const maxUint216 = 2n ** 216n - 1n;\nexport const maxUint224 = 2n ** 224n - 1n;\nexport const maxUint232 = 2n ** 232n - 1n;\nexport const maxUint240 = 2n ** 240n - 1n;\nexport const maxUint248 = 2n ** 248n - 1n;\nexport const maxUint256 = 2n ** 256n - 1n;\n//# sourceMappingURL=Solidity.js.map","/**\n * Internal Merkle-Damgard hash utils.\n * @module\n */\nimport { Hash, abytes, aexists, aoutput, clean, createView, toBytes } from \"./utils.js\";\n/** Polyfill for Safari 14. https://caniuse.com/mdn-javascript_builtins_dataview_setbiguint64 */\nexport function setBigUint64(view, byteOffset, value, isLE) {\n if (typeof view.setBigUint64 === 'function')\n return view.setBigUint64(byteOffset, value, isLE);\n const _32n = BigInt(32);\n const _u32_max = BigInt(0xffffffff);\n const wh = Number((value >> _32n) & _u32_max);\n const wl = Number(value & _u32_max);\n const h = isLE ? 4 : 0;\n const l = isLE ? 0 : 4;\n view.setUint32(byteOffset + h, wh, isLE);\n view.setUint32(byteOffset + l, wl, isLE);\n}\n/** Choice: a ? b : c */\nexport function Chi(a, b, c) {\n return (a & b) ^ (~a & c);\n}\n/** Majority function, true if any two inputs is true. */\nexport function Maj(a, b, c) {\n return (a & b) ^ (a & c) ^ (b & c);\n}\n/**\n * Merkle-Damgard hash construction base class.\n * Could be used to create MD5, RIPEMD, SHA1, SHA2.\n */\nexport class HashMD extends Hash {\n constructor(blockLen, outputLen, padOffset, isLE) {\n super();\n this.finished = false;\n this.length = 0;\n this.pos = 0;\n this.destroyed = false;\n this.blockLen = blockLen;\n this.outputLen = outputLen;\n this.padOffset = padOffset;\n this.isLE = isLE;\n this.buffer = new Uint8Array(blockLen);\n this.view = createView(this.buffer);\n }\n update(data) {\n aexists(this);\n data = toBytes(data);\n abytes(data);\n const { view, buffer, blockLen } = this;\n const len = data.length;\n for (let pos = 0; pos < len;) {\n const take = Math.min(blockLen - this.pos, len - pos);\n // Fast path: we have at least one block in input, cast it to view and process\n if (take === blockLen) {\n const dataView = createView(data);\n for (; blockLen <= len - pos; pos += blockLen)\n this.process(dataView, pos);\n continue;\n }\n buffer.set(data.subarray(pos, pos + take), this.pos);\n this.pos += take;\n pos += take;\n if (this.pos === blockLen) {\n this.process(view, 0);\n this.pos = 0;\n }\n }\n this.length += data.length;\n this.roundClean();\n return this;\n }\n digestInto(out) {\n aexists(this);\n aoutput(out, this);\n this.finished = true;\n // Padding\n // We can avoid allocation of buffer for padding completely if it\n // was previously not allocated here. But it won't change performance.\n const { buffer, view, blockLen, isLE } = this;\n let { pos } = this;\n // append the bit '1' to the message\n buffer[pos++] = 0b10000000;\n clean(this.buffer.subarray(pos));\n // we have less than padOffset left in buffer, so we cannot put length in\n // current block, need process it and pad again\n if (this.padOffset > blockLen - pos) {\n this.process(view, 0);\n pos = 0;\n }\n // Pad until full block byte with zeros\n for (let i = pos; i < blockLen; i++)\n buffer[i] = 0;\n // Note: sha512 requires length to be 128bit integer, but length in JS will overflow before that\n // You need to write around 2 exabytes (u64_max / 8 / (1024**6)) for this to happen.\n // So we just write lowest 64 bits of that value.\n setBigUint64(view, blockLen - 8, BigInt(this.length * 8), isLE);\n this.process(view, 0);\n const oview = createView(out);\n const len = this.outputLen;\n // NOTE: we do division by 4 later, which should be fused in single op with modulo by JIT\n if (len % 4)\n throw new Error('_sha2: outputLen should be aligned to 32bit');\n const outLen = len / 4;\n const state = this.get();\n if (outLen > state.length)\n throw new Error('_sha2: outputLen bigger than state');\n for (let i = 0; i < outLen; i++)\n oview.setUint32(4 * i, state[i], isLE);\n }\n digest() {\n const { buffer, outputLen } = this;\n this.digestInto(buffer);\n const res = buffer.slice(0, outputLen);\n this.destroy();\n return res;\n }\n _cloneInto(to) {\n to || (to = new this.constructor());\n to.set(...this.get());\n const { blockLen, buffer, length, finished, destroyed, pos } = this;\n to.destroyed = destroyed;\n to.finished = finished;\n to.length = length;\n to.pos = pos;\n if (length % blockLen)\n to.buffer.set(buffer);\n return to;\n }\n clone() {\n return this._cloneInto();\n }\n}\n/**\n * Initial SHA-2 state: fractional parts of square roots of first 16 primes 2..53.\n * Check out `test/misc/sha2-gen-iv.js` for recomputation guide.\n */\n/** Initial SHA256 state. Bits 0..32 of frac part of sqrt of primes 2..19 */\nexport const SHA256_IV = /* @__PURE__ */ Uint32Array.from([\n 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19,\n]);\n/** Initial SHA224 state. Bits 32..64 of frac part of sqrt of primes 23..53 */\nexport const SHA224_IV = /* @__PURE__ */ Uint32Array.from([\n 0xc1059ed8, 0x367cd507, 0x3070dd17, 0xf70e5939, 0xffc00b31, 0x68581511, 0x64f98fa7, 0xbefa4fa4,\n]);\n/** Initial SHA384 state. Bits 0..64 of frac part of sqrt of primes 23..53 */\nexport const SHA384_IV = /* @__PURE__ */ Uint32Array.from([\n 0xcbbb9d5d, 0xc1059ed8, 0x629a292a, 0x367cd507, 0x9159015a, 0x3070dd17, 0x152fecd8, 0xf70e5939,\n 0x67332667, 0xffc00b31, 0x8eb44a87, 0x68581511, 0xdb0c2e0d, 0x64f98fa7, 0x47b5481d, 0xbefa4fa4,\n]);\n/** Initial SHA512 state. Bits 0..64 of frac part of sqrt of primes 2..19 */\nexport const SHA512_IV = /* @__PURE__ */ Uint32Array.from([\n 0x6a09e667, 0xf3bcc908, 0xbb67ae85, 0x84caa73b, 0x3c6ef372, 0xfe94f82b, 0xa54ff53a, 0x5f1d36f1,\n 0x510e527f, 0xade682d1, 0x9b05688c, 0x2b3e6c1f, 0x1f83d9ab, 0xfb41bd6b, 0x5be0cd19, 0x137e2179,\n]);\n//# sourceMappingURL=_md.js.map","/**\n * Internal helpers for u64. BigUint64Array is too slow as per 2025, so we implement it using Uint32Array.\n * @todo re-check https://issues.chromium.org/issues/42212588\n * @module\n */\nconst U32_MASK64 = /* @__PURE__ */ BigInt(2 ** 32 - 1);\nconst _32n = /* @__PURE__ */ BigInt(32);\nfunction fromBig(n, le = false) {\n if (le)\n return { h: Number(n & U32_MASK64), l: Number((n >> _32n) & U32_MASK64) };\n return { h: Number((n >> _32n) & U32_MASK64) | 0, l: Number(n & U32_MASK64) | 0 };\n}\nfunction split(lst, le = false) {\n const len = lst.length;\n let Ah = new Uint32Array(len);\n let Al = new Uint32Array(len);\n for (let i = 0; i < len; i++) {\n const { h, l } = fromBig(lst[i], le);\n [Ah[i], Al[i]] = [h, l];\n }\n return [Ah, Al];\n}\nconst toBig = (h, l) => (BigInt(h >>> 0) << _32n) | BigInt(l >>> 0);\n// for Shift in [0, 32)\nconst shrSH = (h, _l, s) => h >>> s;\nconst shrSL = (h, l, s) => (h << (32 - s)) | (l >>> s);\n// Right rotate for Shift in [1, 32)\nconst rotrSH = (h, l, s) => (h >>> s) | (l << (32 - s));\nconst rotrSL = (h, l, s) => (h << (32 - s)) | (l >>> s);\n// Right rotate for Shift in (32, 64), NOTE: 32 is special case.\nconst rotrBH = (h, l, s) => (h << (64 - s)) | (l >>> (s - 32));\nconst rotrBL = (h, l, s) => (h >>> (s - 32)) | (l << (64 - s));\n// Right rotate for shift===32 (just swaps l&h)\nconst rotr32H = (_h, l) => l;\nconst rotr32L = (h, _l) => h;\n// Left rotate for Shift in [1, 32)\nconst rotlSH = (h, l, s) => (h << s) | (l >>> (32 - s));\nconst rotlSL = (h, l, s) => (l << s) | (h >>> (32 - s));\n// Left rotate for Shift in (32, 64), NOTE: 32 is special case.\nconst rotlBH = (h, l, s) => (l << (s - 32)) | (h >>> (64 - s));\nconst rotlBL = (h, l, s) => (h << (s - 32)) | (l >>> (64 - s));\n// JS uses 32-bit signed integers for bitwise operations which means we cannot\n// simple take carry out of low bit sum by shift, we need to use division.\nfunction add(Ah, Al, Bh, Bl) {\n const l = (Al >>> 0) + (Bl >>> 0);\n return { h: (Ah + Bh + ((l / 2 ** 32) | 0)) | 0, l: l | 0 };\n}\n// Addition with more than 2 elements\nconst add3L = (Al, Bl, Cl) => (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0);\nconst add3H = (low, Ah, Bh, Ch) => (Ah + Bh + Ch + ((low / 2 ** 32) | 0)) | 0;\nconst add4L = (Al, Bl, Cl, Dl) => (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0) + (Dl >>> 0);\nconst add4H = (low, Ah, Bh, Ch, Dh) => (Ah + Bh + Ch + Dh + ((low / 2 ** 32) | 0)) | 0;\nconst add5L = (Al, Bl, Cl, Dl, El) => (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0) + (Dl >>> 0) + (El >>> 0);\nconst add5H = (low, Ah, Bh, Ch, Dh, Eh) => (Ah + Bh + Ch + Dh + Eh + ((low / 2 ** 32) | 0)) | 0;\n// prettier-ignore\nexport { add, add3H, add3L, add4H, add4L, add5H, add5L, fromBig, rotlBH, rotlBL, rotlSH, rotlSL, rotr32H, rotr32L, rotrBH, rotrBL, rotrSH, rotrSL, shrSH, shrSL, split, toBig };\n// prettier-ignore\nconst u64 = {\n fromBig, split, toBig,\n shrSH, shrSL,\n rotrSH, rotrSL, rotrBH, rotrBL,\n rotr32H, rotr32L,\n rotlSH, rotlSL, rotlBH, rotlBL,\n add, add3L, add3H, add4L, add4H, add5H, add5L,\n};\nexport default u64;\n//# sourceMappingURL=_u64.js.map","/**\n * SHA2 hash function. A.k.a. sha256, sha384, sha512, sha512_224, sha512_256.\n * SHA256 is the fastest hash implementable in JS, even faster than Blake3.\n * Check out [RFC 4634](https://datatracker.ietf.org/doc/html/rfc4634) and\n * [FIPS 180-4](https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.180-4.pdf).\n * @module\n */\nimport { Chi, HashMD, Maj, SHA224_IV, SHA256_IV, SHA384_IV, SHA512_IV } from \"./_md.js\";\nimport * as u64 from \"./_u64.js\";\nimport { clean, createHasher, rotr } from \"./utils.js\";\n/**\n * Round constants:\n * First 32 bits of fractional parts of the cube roots of the first 64 primes 2..311)\n */\n// prettier-ignore\nconst SHA256_K = /* @__PURE__ */ Uint32Array.from([\n 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5,\n 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174,\n 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da,\n 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967,\n 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85,\n 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070,\n 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3,\n 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2\n]);\n/** Reusable temporary buffer. \"W\" comes straight from spec. */\nconst SHA256_W = /* @__PURE__ */ new Uint32Array(64);\nexport class SHA256 extends HashMD {\n constructor(outputLen = 32) {\n super(64, outputLen, 8, false);\n // We cannot use array here since array allows indexing by variable\n // which means optimizer/compiler cannot use registers.\n this.A = SHA256_IV[0] | 0;\n this.B = SHA256_IV[1] | 0;\n this.C = SHA256_IV[2] | 0;\n this.D = SHA256_IV[3] | 0;\n this.E = SHA256_IV[4] | 0;\n this.F = SHA256_IV[5] | 0;\n this.G = SHA256_IV[6] | 0;\n this.H = SHA256_IV[7] | 0;\n }\n get() {\n const { A, B, C, D, E, F, G, H } = this;\n return [A, B, C, D, E, F, G, H];\n }\n // prettier-ignore\n set(A, B, C, D, E, F, G, H) {\n this.A = A | 0;\n this.B = B | 0;\n this.C = C | 0;\n this.D = D | 0;\n this.E = E | 0;\n this.F = F | 0;\n this.G = G | 0;\n this.H = H | 0;\n }\n process(view, offset) {\n // Extend the first 16 words into the remaining 48 words w[16..63] of the message schedule array\n for (let i = 0; i < 16; i++, offset += 4)\n SHA256_W[i] = view.getUint32(offset, false);\n for (let i = 16; i < 64; i++) {\n const W15 = SHA256_W[i - 15];\n const W2 = SHA256_W[i - 2];\n const s0 = rotr(W15, 7) ^ rotr(W15, 18) ^ (W15 >>> 3);\n const s1 = rotr(W2, 17) ^ rotr(W2, 19) ^ (W2 >>> 10);\n SHA256_W[i] = (s1 + SHA256_W[i - 7] + s0 + SHA256_W[i - 16]) | 0;\n }\n // Compression function main loop, 64 rounds\n let { A, B, C, D, E, F, G, H } = this;\n for (let i = 0; i < 64; i++) {\n const sigma1 = rotr(E, 6) ^ rotr(E, 11) ^ rotr(E, 25);\n const T1 = (H + sigma1 + Chi(E, F, G) + SHA256_K[i] + SHA256_W[i]) | 0;\n const sigma0 = rotr(A, 2) ^ rotr(A, 13) ^ rotr(A, 22);\n const T2 = (sigma0 + Maj(A, B, C)) | 0;\n H = G;\n G = F;\n F = E;\n E = (D + T1) | 0;\n D = C;\n C = B;\n B = A;\n A = (T1 + T2) | 0;\n }\n // Add the compressed chunk to the current hash value\n A = (A + this.A) | 0;\n B = (B + this.B) | 0;\n C = (C + this.C) | 0;\n D = (D + this.D) | 0;\n E = (E + this.E) | 0;\n F = (F + this.F) | 0;\n G = (G + this.G) | 0;\n H = (H + this.H) | 0;\n this.set(A, B, C, D, E, F, G, H);\n }\n roundClean() {\n clean(SHA256_W);\n }\n destroy() {\n this.set(0, 0, 0, 0, 0, 0, 0, 0);\n clean(this.buffer);\n }\n}\nexport class SHA224 extends SHA256 {\n constructor() {\n super(28);\n this.A = SHA224_IV[0] | 0;\n this.B = SHA224_IV[1] | 0;\n this.C = SHA224_IV[2] | 0;\n this.D = SHA224_IV[3] | 0;\n this.E = SHA224_IV[4] | 0;\n this.F = SHA224_IV[5] | 0;\n this.G = SHA224_IV[6] | 0;\n this.H = SHA224_IV[7] | 0;\n }\n}\n// SHA2-512 is slower than sha256 in js because u64 operations are slow.\n// Round contants\n// First 32 bits of the fractional parts of the cube roots of the first 80 primes 2..409\n// prettier-ignore\nconst K512 = /* @__PURE__ */ (() => u64.split([\n '0x428a2f98d728ae22', '0x7137449123ef65cd', '0xb5c0fbcfec4d3b2f', '0xe9b5dba58189dbbc',\n '0x3956c25bf348b538', '0x59f111f1b605d019', '0x923f82a4af194f9b', '0xab1c5ed5da6d8118',\n '0xd807aa98a3030242', '0x12835b0145706fbe', '0x243185be4ee4b28c', '0x550c7dc3d5ffb4e2',\n '0x72be5d74f27b896f', '0x80deb1fe3b1696b1', '0x9bdc06a725c71235', '0xc19bf174cf692694',\n '0xe49b69c19ef14ad2', '0xefbe4786384f25e3', '0x0fc19dc68b8cd5b5', '0x240ca1cc77ac9c65',\n '0x2de92c6f592b0275', '0x4a7484aa6ea6e483', '0x5cb0a9dcbd41fbd4', '0x76f988da831153b5',\n '0x983e5152ee66dfab', '0xa831c66d2db43210', '0xb00327c898fb213f', '0xbf597fc7beef0ee4',\n '0xc6e00bf33da88fc2', '0xd5a79147930aa725', '0x06ca6351e003826f', '0x142929670a0e6e70',\n '0x27b70a8546d22ffc', '0x2e1b21385c26c926', '0x4d2c6dfc5ac42aed', '0x53380d139d95b3df',\n '0x650a73548baf63de', '0x766a0abb3c77b2a8', '0x81c2c92e47edaee6', '0x92722c851482353b',\n '0xa2bfe8a14cf10364', '0xa81a664bbc423001', '0xc24b8b70d0f89791', '0xc76c51a30654be30',\n '0xd192e819d6ef5218', '0xd69906245565a910', '0xf40e35855771202a', '0x106aa07032bbd1b8',\n '0x19a4c116b8d2d0c8', '0x1e376c085141ab53', '0x2748774cdf8eeb99', '0x34b0bcb5e19b48a8',\n '0x391c0cb3c5c95a63', '0x4ed8aa4ae3418acb', '0x5b9cca4f7763e373', '0x682e6ff3d6b2b8a3',\n '0x748f82ee5defb2fc', '0x78a5636f43172f60', '0x84c87814a1f0ab72', '0x8cc702081a6439ec',\n '0x90befffa23631e28', '0xa4506cebde82bde9', '0xbef9a3f7b2c67915', '0xc67178f2e372532b',\n '0xca273eceea26619c', '0xd186b8c721c0c207', '0xeada7dd6cde0eb1e', '0xf57d4f7fee6ed178',\n '0x06f067aa72176fba', '0x0a637dc5a2c898a6', '0x113f9804bef90dae', '0x1b710b35131c471b',\n '0x28db77f523047d84', '0x32caab7b40c72493', '0x3c9ebe0a15c9bebc', '0x431d67c49c100d4c',\n '0x4cc5d4becb3e42b6', '0x597f299cfc657e2a', '0x5fcb6fab3ad6faec', '0x6c44198c4a475817'\n].map(n => BigInt(n))))();\nconst SHA512_Kh = /* @__PURE__ */ (() => K512[0])();\nconst SHA512_Kl = /* @__PURE__ */ (() => K512[1])();\n// Reusable temporary buffers\nconst SHA512_W_H = /* @__PURE__ */ new Uint32Array(80);\nconst SHA512_W_L = /* @__PURE__ */ new Uint32Array(80);\nexport class SHA512 extends HashMD {\n constructor(outputLen = 64) {\n super(128, outputLen, 16, false);\n // We cannot use array here since array allows indexing by variable\n // which means optimizer/compiler cannot use registers.\n // h -- high 32 bits, l -- low 32 bits\n this.Ah = SHA512_IV[0] | 0;\n this.Al = SHA512_IV[1] | 0;\n this.Bh = SHA512_IV[2] | 0;\n this.Bl = SHA512_IV[3] | 0;\n this.Ch = SHA512_IV[4] | 0;\n this.Cl = SHA512_IV[5] | 0;\n this.Dh = SHA512_IV[6] | 0;\n this.Dl = SHA512_IV[7] | 0;\n this.Eh = SHA512_IV[8] | 0;\n this.El = SHA512_IV[9] | 0;\n this.Fh = SHA512_IV[10] | 0;\n this.Fl = SHA512_IV[11] | 0;\n this.Gh = SHA512_IV[12] | 0;\n this.Gl = SHA512_IV[13] | 0;\n this.Hh = SHA512_IV[14] | 0;\n this.Hl = SHA512_IV[15] | 0;\n }\n // prettier-ignore\n get() {\n const { Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl } = this;\n return [Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl];\n }\n // prettier-ignore\n set(Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl) {\n this.Ah = Ah | 0;\n this.Al = Al | 0;\n this.Bh = Bh | 0;\n this.Bl = Bl | 0;\n this.Ch = Ch | 0;\n this.Cl = Cl | 0;\n this.Dh = Dh | 0;\n this.Dl = Dl | 0;\n this.Eh = Eh | 0;\n this.El = El | 0;\n this.Fh = Fh | 0;\n this.Fl = Fl | 0;\n this.Gh = Gh | 0;\n this.Gl = Gl | 0;\n this.Hh = Hh | 0;\n this.Hl = Hl | 0;\n }\n process(view, offset) {\n // Extend the first 16 words into the remaining 64 words w[16..79] of the message schedule array\n for (let i = 0; i < 16; i++, offset += 4) {\n SHA512_W_H[i] = view.getUint32(offset);\n SHA512_W_L[i] = view.getUint32((offset += 4));\n }\n for (let i = 16; i < 80; i++) {\n // s0 := (w[i-15] rightrotate 1) xor (w[i-15] rightrotate 8) xor (w[i-15] rightshift 7)\n const W15h = SHA512_W_H[i - 15] | 0;\n const W15l = SHA512_W_L[i - 15] | 0;\n const s0h = u64.rotrSH(W15h, W15l, 1) ^ u64.rotrSH(W15h, W15l, 8) ^ u64.shrSH(W15h, W15l, 7);\n const s0l = u64.rotrSL(W15h, W15l, 1) ^ u64.rotrSL(W15h, W15l, 8) ^ u64.shrSL(W15h, W15l, 7);\n // s1 := (w[i-2] rightrotate 19) xor (w[i-2] rightrotate 61) xor (w[i-2] rightshift 6)\n const W2h = SHA512_W_H[i - 2] | 0;\n const W2l = SHA512_W_L[i - 2] | 0;\n const s1h = u64.rotrSH(W2h, W2l, 19) ^ u64.rotrBH(W2h, W2l, 61) ^ u64.shrSH(W2h, W2l, 6);\n const s1l = u64.rotrSL(W2h, W2l, 19) ^ u64.rotrBL(W2h, W2l, 61) ^ u64.shrSL(W2h, W2l, 6);\n // SHA256_W[i] = s0 + s1 + SHA256_W[i - 7] + SHA256_W[i - 16];\n const SUMl = u64.add4L(s0l, s1l, SHA512_W_L[i - 7], SHA512_W_L[i - 16]);\n const SUMh = u64.add4H(SUMl, s0h, s1h, SHA512_W_H[i - 7], SHA512_W_H[i - 16]);\n SHA512_W_H[i] = SUMh | 0;\n SHA512_W_L[i] = SUMl | 0;\n }\n let { Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl } = this;\n // Compression function main loop, 80 rounds\n for (let i = 0; i < 80; i++) {\n // S1 := (e rightrotate 14) xor (e rightrotate 18) xor (e rightrotate 41)\n const sigma1h = u64.rotrSH(Eh, El, 14) ^ u64.rotrSH(Eh, El, 18) ^ u64.rotrBH(Eh, El, 41);\n const sigma1l = u64.rotrSL(Eh, El, 14) ^ u64.rotrSL(Eh, El, 18) ^ u64.rotrBL(Eh, El, 41);\n //const T1 = (H + sigma1 + Chi(E, F, G) + SHA256_K[i] + SHA256_W[i]) | 0;\n const CHIh = (Eh & Fh) ^ (~Eh & Gh);\n const CHIl = (El & Fl) ^ (~El & Gl);\n // T1 = H + sigma1 + Chi(E, F, G) + SHA512_K[i] + SHA512_W[i]\n // prettier-ignore\n const T1ll = u64.add5L(Hl, sigma1l, CHIl, SHA512_Kl[i], SHA512_W_L[i]);\n const T1h = u64.add5H(T1ll, Hh, sigma1h, CHIh, SHA512_Kh[i], SHA512_W_H[i]);\n const T1l = T1ll | 0;\n // S0 := (a rightrotate 28) xor (a rightrotate 34) xor (a rightrotate 39)\n const sigma0h = u64.rotrSH(Ah, Al, 28) ^ u64.rotrBH(Ah, Al, 34) ^ u64.rotrBH(Ah, Al, 39);\n const sigma0l = u64.rotrSL(Ah, Al, 28) ^ u64.rotrBL(Ah, Al, 34) ^ u64.rotrBL(Ah, Al, 39);\n const MAJh = (Ah & Bh) ^ (Ah & Ch) ^ (Bh & Ch);\n const MAJl = (Al & Bl) ^ (Al & Cl) ^ (Bl & Cl);\n Hh = Gh | 0;\n Hl = Gl | 0;\n Gh = Fh | 0;\n Gl = Fl | 0;\n Fh = Eh | 0;\n Fl = El | 0;\n ({ h: Eh, l: El } = u64.add(Dh | 0, Dl | 0, T1h | 0, T1l | 0));\n Dh = Ch | 0;\n Dl = Cl | 0;\n Ch = Bh | 0;\n Cl = Bl | 0;\n Bh = Ah | 0;\n Bl = Al | 0;\n const All = u64.add3L(T1l, sigma0l, MAJl);\n Ah = u64.add3H(All, T1h, sigma0h, MAJh);\n Al = All | 0;\n }\n // Add the compressed chunk to the current hash value\n ({ h: Ah, l: Al } = u64.add(this.Ah | 0, this.Al | 0, Ah | 0, Al | 0));\n ({ h: Bh, l: Bl } = u64.add(this.Bh | 0, this.Bl | 0, Bh | 0, Bl | 0));\n ({ h: Ch, l: Cl } = u64.add(this.Ch | 0, this.Cl | 0, Ch | 0, Cl | 0));\n ({ h: Dh, l: Dl } = u64.add(this.Dh | 0, this.Dl | 0, Dh | 0, Dl | 0));\n ({ h: Eh, l: El } = u64.add(this.Eh | 0, this.El | 0, Eh | 0, El | 0));\n ({ h: Fh, l: Fl } = u64.add(this.Fh | 0, this.Fl | 0, Fh | 0, Fl | 0));\n ({ h: Gh, l: Gl } = u64.add(this.Gh | 0, this.Gl | 0, Gh | 0, Gl | 0));\n ({ h: Hh, l: Hl } = u64.add(this.Hh | 0, this.Hl | 0, Hh | 0, Hl | 0));\n this.set(Ah, Al, Bh, Bl, Ch, Cl, Dh, Dl, Eh, El, Fh, Fl, Gh, Gl, Hh, Hl);\n }\n roundClean() {\n clean(SHA512_W_H, SHA512_W_L);\n }\n destroy() {\n clean(this.buffer);\n this.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);\n }\n}\nexport class SHA384 extends SHA512 {\n constructor() {\n super(48);\n this.Ah = SHA384_IV[0] | 0;\n this.Al = SHA384_IV[1] | 0;\n this.Bh = SHA384_IV[2] | 0;\n this.Bl = SHA384_IV[3] | 0;\n this.Ch = SHA384_IV[4] | 0;\n this.Cl = SHA384_IV[5] | 0;\n this.Dh = SHA384_IV[6] | 0;\n this.Dl = SHA384_IV[7] | 0;\n this.Eh = SHA384_IV[8] | 0;\n this.El = SHA384_IV[9] | 0;\n this.Fh = SHA384_IV[10] | 0;\n this.Fl = SHA384_IV[11] | 0;\n this.Gh = SHA384_IV[12] | 0;\n this.Gl = SHA384_IV[13] | 0;\n this.Hh = SHA384_IV[14] | 0;\n this.Hl = SHA384_IV[15] | 0;\n }\n}\n/**\n * Truncated SHA512/256 and SHA512/224.\n * SHA512_IV is XORed with 0xa5a5a5a5a5a5a5a5, then used as \"intermediary\" IV of SHA512/t.\n * Then t hashes string to produce result IV.\n * See `test/misc/sha2-gen-iv.js`.\n */\n/** SHA512/224 IV */\nconst T224_IV = /* @__PURE__ */ Uint32Array.from([\n 0x8c3d37c8, 0x19544da2, 0x73e19966, 0x89dcd4d6, 0x1dfab7ae, 0x32ff9c82, 0x679dd514, 0x582f9fcf,\n 0x0f6d2b69, 0x7bd44da8, 0x77e36f73, 0x04c48942, 0x3f9d85a8, 0x6a1d36c8, 0x1112e6ad, 0x91d692a1,\n]);\n/** SHA512/256 IV */\nconst T256_IV = /* @__PURE__ */ Uint32Array.from([\n 0x22312194, 0xfc2bf72c, 0x9f555fa3, 0xc84c64c2, 0x2393b86b, 0x6f53b151, 0x96387719, 0x5940eabd,\n 0x96283ee2, 0xa88effe3, 0xbe5e1e25, 0x53863992, 0x2b0199fc, 0x2c85b8aa, 0x0eb72ddc, 0x81c52ca2,\n]);\nexport class SHA512_224 extends SHA512 {\n constructor() {\n super(28);\n this.Ah = T224_IV[0] | 0;\n this.Al = T224_IV[1] | 0;\n this.Bh = T224_IV[2] | 0;\n this.Bl = T224_IV[3] | 0;\n this.Ch = T224_IV[4] | 0;\n this.Cl = T224_IV[5] | 0;\n this.Dh = T224_IV[6] | 0;\n this.Dl = T224_IV[7] | 0;\n this.Eh = T224_IV[8] | 0;\n this.El = T224_IV[9] | 0;\n this.Fh = T224_IV[10] | 0;\n this.Fl = T224_IV[11] | 0;\n this.Gh = T224_IV[12] | 0;\n this.Gl = T224_IV[13] | 0;\n this.Hh = T224_IV[14] | 0;\n this.Hl = T224_IV[15] | 0;\n }\n}\nexport class SHA512_256 extends SHA512 {\n constructor() {\n super(32);\n this.Ah = T256_IV[0] | 0;\n this.Al = T256_IV[1] | 0;\n this.Bh = T256_IV[2] | 0;\n this.Bl = T256_IV[3] | 0;\n this.Ch = T256_IV[4] | 0;\n this.Cl = T256_IV[5] | 0;\n this.Dh = T256_IV[6] | 0;\n this.Dl = T256_IV[7] | 0;\n this.Eh = T256_IV[8] | 0;\n this.El = T256_IV[9] | 0;\n this.Fh = T256_IV[10] | 0;\n this.Fl = T256_IV[11] | 0;\n this.Gh = T256_IV[12] | 0;\n this.Gl = T256_IV[13] | 0;\n this.Hh = T256_IV[14] | 0;\n this.Hl = T256_IV[15] | 0;\n }\n}\n/**\n * SHA2-256 hash function from RFC 4634.\n *\n * It is the fastest JS hash, even faster than Blake3.\n * To break sha256 using birthday attack, attackers need to try 2^128 hashes.\n * BTC network is doing 2^70 hashes/sec (2^95 hashes/year) as per 2025.\n */\nexport const sha256 = /* @__PURE__ */ createHasher(() => new SHA256());\n/** SHA2-224 hash function from RFC 4634 */\nexport const sha224 = /* @__PURE__ */ createHasher(() => new SHA224());\n/** SHA2-512 hash function from RFC 4634. */\nexport const sha512 = /* @__PURE__ */ createHasher(() => new SHA512());\n/** SHA2-384 hash function from RFC 4634. */\nexport const sha384 = /* @__PURE__ */ createHasher(() => new SHA384());\n/**\n * SHA2-512/256 \"truncated\" hash function, with improved resistance to length extension attacks.\n * See the paper on [truncated SHA512](https://eprint.iacr.org/2010/548.pdf).\n */\nexport const sha512_256 = /* @__PURE__ */ createHasher(() => new SHA512_256());\n/**\n * SHA2-512/224 \"truncated\" hash function, with improved resistance to length extension attacks.\n * See the paper on [truncated SHA512](https://eprint.iacr.org/2010/548.pdf).\n */\nexport const sha512_224 = /* @__PURE__ */ createHasher(() => new SHA512_224());\n//# sourceMappingURL=sha2.js.map","/**\n * HMAC: RFC2104 message authentication code.\n * @module\n */\nimport { abytes, aexists, ahash, clean, Hash, toBytes } from \"./utils.js\";\nexport class HMAC extends Hash {\n constructor(hash, _key) {\n super();\n this.finished = false;\n this.destroyed = false;\n ahash(hash);\n const key = toBytes(_key);\n this.iHash = hash.create();\n if (typeof this.iHash.update !== 'function')\n throw new Error('Expected instance of class which extends utils.Hash');\n this.blockLen = this.iHash.blockLen;\n this.outputLen = this.iHash.outputLen;\n const blockLen = this.blockLen;\n const pad = new Uint8Array(blockLen);\n // blockLen can be bigger than outputLen\n pad.set(key.length > blockLen ? hash.create().update(key).digest() : key);\n for (let i = 0; i < pad.length; i++)\n pad[i] ^= 0x36;\n this.iHash.update(pad);\n // By doing update (processing of first block) of outer hash here we can re-use it between multiple calls via clone\n this.oHash = hash.create();\n // Undo internal XOR && apply outer XOR\n for (let i = 0; i < pad.length; i++)\n pad[i] ^= 0x36 ^ 0x5c;\n this.oHash.update(pad);\n clean(pad);\n }\n update(buf) {\n aexists(this);\n this.iHash.update(buf);\n return this;\n }\n digestInto(out) {\n aexists(this);\n abytes(out, this.outputLen);\n this.finished = true;\n this.iHash.digestInto(out);\n this.oHash.update(out);\n this.oHash.digestInto(out);\n this.destroy();\n }\n digest() {\n const out = new Uint8Array(this.oHash.outputLen);\n this.digestInto(out);\n return out;\n }\n _cloneInto(to) {\n // Create new instance without calling constructor since key already in state and we don't know it.\n to || (to = Object.create(Object.getPrototypeOf(this), {}));\n const { oHash, iHash, finished, destroyed, blockLen, outputLen } = this;\n to = to;\n to.finished = finished;\n to.destroyed = destroyed;\n to.blockLen = blockLen;\n to.outputLen = outputLen;\n to.oHash = oHash._cloneInto(to.oHash);\n to.iHash = iHash._cloneInto(to.iHash);\n return to;\n }\n clone() {\n return this._cloneInto();\n }\n destroy() {\n this.destroyed = true;\n this.oHash.destroy();\n this.iHash.destroy();\n }\n}\n/**\n * HMAC: RFC2104 message authentication code.\n * @param hash - function that would be used e.g. sha256\n * @param key - message key\n * @param message - message data\n * @example\n * import { hmac } from '@noble/hashes/hmac';\n * import { sha256 } from '@noble/hashes/sha2';\n * const mac1 = hmac(sha256, 'key', 'message');\n */\nexport const hmac = (hash, key, message) => new HMAC(hash, key).update(message).digest();\nhmac.create = (hash, key) => new HMAC(hash, key);\n//# sourceMappingURL=hmac.js.map","/**\n * Utils for modular division and fields.\n * Field over 11 is a finite (Galois) field is integer number operations `mod 11`.\n * There is no division: it is replaced by modular multiplicative inverse.\n * @module\n */\n/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */\nimport { _validateObject, anumber, bitMask, bytesToNumberBE, bytesToNumberLE, ensureBytes, numberToBytesBE, numberToBytesLE, } from \"../utils.js\";\n// prettier-ignore\nconst _0n = BigInt(0), _1n = BigInt(1), _2n = /* @__PURE__ */ BigInt(2), _3n = /* @__PURE__ */ BigInt(3);\n// prettier-ignore\nconst _4n = /* @__PURE__ */ BigInt(4), _5n = /* @__PURE__ */ BigInt(5), _7n = /* @__PURE__ */ BigInt(7);\n// prettier-ignore\nconst _8n = /* @__PURE__ */ BigInt(8), _9n = /* @__PURE__ */ BigInt(9), _16n = /* @__PURE__ */ BigInt(16);\n// Calculates a modulo b\nexport function mod(a, b) {\n const result = a % b;\n return result >= _0n ? result : b + result;\n}\n/**\n * Efficiently raise num to power and do modular division.\n * Unsafe in some contexts: uses ladder, so can expose bigint bits.\n * @example\n * pow(2n, 6n, 11n) // 64n % 11n == 9n\n */\nexport function pow(num, power, modulo) {\n return FpPow(Field(modulo), num, power);\n}\n/** Does `x^(2^power)` mod p. `pow2(30, 4)` == `30^(2^4)` */\nexport function pow2(x, power, modulo) {\n let res = x;\n while (power-- > _0n) {\n res *= res;\n res %= modulo;\n }\n return res;\n}\n/**\n * Inverses number over modulo.\n * Implemented using [Euclidean GCD](https://brilliant.org/wiki/extended-euclidean-algorithm/).\n */\nexport function invert(number, modulo) {\n if (number === _0n)\n throw new Error('invert: expected non-zero number');\n if (modulo <= _0n)\n throw new Error('invert: expected positive modulus, got ' + modulo);\n // Fermat's little theorem \"CT-like\" version inv(n) = n^(m-2) mod m is 30x slower.\n let a = mod(number, modulo);\n let b = modulo;\n // prettier-ignore\n let x = _0n, y = _1n, u = _1n, v = _0n;\n while (a !== _0n) {\n // JIT applies optimization if those two lines follow each other\n const q = b / a;\n const r = b % a;\n const m = x - u * q;\n const n = y - v * q;\n // prettier-ignore\n b = a, a = r, x = u, y = v, u = m, v = n;\n }\n const gcd = b;\n if (gcd !== _1n)\n throw new Error('invert: does not exist');\n return mod(x, modulo);\n}\nfunction assertIsSquare(Fp, root, n) {\n if (!Fp.eql(Fp.sqr(root), n))\n throw new Error('Cannot find square root');\n}\n// Not all roots are possible! Example which will throw:\n// const NUM =\n// n = 72057594037927816n;\n// Fp = Field(BigInt('0x1a0111ea397fe69a4b1ba7b6434bacd764774b84f38512bf6730d2a0f6b0f6241eabfffeb153ffffb9feffffffffaaab'));\nfunction sqrt3mod4(Fp, n) {\n const p1div4 = (Fp.ORDER + _1n) / _4n;\n const root = Fp.pow(n, p1div4);\n assertIsSquare(Fp, root, n);\n return root;\n}\nfunction sqrt5mod8(Fp, n) {\n const p5div8 = (Fp.ORDER - _5n) / _8n;\n const n2 = Fp.mul(n, _2n);\n const v = Fp.pow(n2, p5div8);\n const nv = Fp.mul(n, v);\n const i = Fp.mul(Fp.mul(nv, _2n), v);\n const root = Fp.mul(nv, Fp.sub(i, Fp.ONE));\n assertIsSquare(Fp, root, n);\n return root;\n}\n// Based on RFC9380, Kong algorithm\n// prettier-ignore\nfunction sqrt9mod16(P) {\n const Fp_ = Field(P);\n const tn = tonelliShanks(P);\n const c1 = tn(Fp_, Fp_.neg(Fp_.ONE)); // 1. c1 = sqrt(-1) in F, i.e., (c1^2) == -1 in F\n const c2 = tn(Fp_, c1); // 2. c2 = sqrt(c1) in F, i.e., (c2^2) == c1 in F\n const c3 = tn(Fp_, Fp_.neg(c1)); // 3. c3 = sqrt(-c1) in F, i.e., (c3^2) == -c1 in F\n const c4 = (P + _7n) / _16n; // 4. c4 = (q + 7) / 16 # Integer arithmetic\n return (Fp, n) => {\n let tv1 = Fp.pow(n, c4); // 1. tv1 = x^c4\n let tv2 = Fp.mul(tv1, c1); // 2. tv2 = c1 * tv1\n const tv3 = Fp.mul(tv1, c2); // 3. tv3 = c2 * tv1\n const tv4 = Fp.mul(tv1, c3); // 4. tv4 = c3 * tv1\n const e1 = Fp.eql(Fp.sqr(tv2), n); // 5. e1 = (tv2^2) == x\n const e2 = Fp.eql(Fp.sqr(tv3), n); // 6. e2 = (tv3^2) == x\n tv1 = Fp.cmov(tv1, tv2, e1); // 7. tv1 = CMOV(tv1, tv2, e1) # Select tv2 if (tv2^2) == x\n tv2 = Fp.cmov(tv4, tv3, e2); // 8. tv2 = CMOV(tv4, tv3, e2) # Select tv3 if (tv3^2) == x\n const e3 = Fp.eql(Fp.sqr(tv2), n); // 9. e3 = (tv2^2) == x\n const root = Fp.cmov(tv1, tv2, e3); // 10. z = CMOV(tv1, tv2, e3) # Select sqrt from tv1 & tv2\n assertIsSquare(Fp, root, n);\n return root;\n };\n}\n/**\n * Tonelli-Shanks square root search algorithm.\n * 1. https://eprint.iacr.org/2012/685.pdf (page 12)\n * 2. Square Roots from 1; 24, 51, 10 to Dan Shanks\n * @param P field order\n * @returns function that takes field Fp (created from P) and number n\n */\nexport function tonelliShanks(P) {\n // Initialization (precomputation).\n // Caching initialization could boost perf by 7%.\n if (P < _3n)\n throw new Error('sqrt is not defined for small field');\n // Factor P - 1 = Q * 2^S, where Q is odd\n let Q = P - _1n;\n let S = 0;\n while (Q % _2n === _0n) {\n Q /= _2n;\n S++;\n }\n // Find the first quadratic non-residue Z >= 2\n let Z = _2n;\n const _Fp = Field(P);\n while (FpLegendre(_Fp, Z) === 1) {\n // Basic primality test for P. After x iterations, chance of\n // not finding quadratic non-residue is 2^x, so 2^1000.\n if (Z++ > 1000)\n throw new Error('Cannot find square root: probably non-prime P');\n }\n // Fast-path; usually done before Z, but we do \"primality test\".\n if (S === 1)\n return sqrt3mod4;\n // Slow-path\n // TODO: test on Fp2 and others\n let cc = _Fp.pow(Z, Q); // c = z^Q\n const Q1div2 = (Q + _1n) / _2n;\n return function tonelliSlow(Fp, n) {\n if (Fp.is0(n))\n return n;\n // Check if n is a quadratic residue using Legendre symbol\n if (FpLegendre(Fp, n) !== 1)\n throw new Error('Cannot find square root');\n // Initialize variables for the main loop\n let M = S;\n let c = Fp.mul(Fp.ONE, cc); // c = z^Q, move cc from field _Fp into field Fp\n let t = Fp.pow(n, Q); // t = n^Q, first guess at the fudge factor\n let R = Fp.pow(n, Q1div2); // R = n^((Q+1)/2), first guess at the square root\n // Main loop\n // while t != 1\n while (!Fp.eql(t, Fp.ONE)) {\n if (Fp.is0(t))\n return Fp.ZERO; // if t=0 return R=0\n let i = 1;\n // Find the smallest i >= 1 such that t^(2^i) ≡ 1 (mod P)\n let t_tmp = Fp.sqr(t); // t^(2^1)\n while (!Fp.eql(t_tmp, Fp.ONE)) {\n i++;\n t_tmp = Fp.sqr(t_tmp); // t^(2^2)...\n if (i === M)\n throw new Error('Cannot find square root');\n }\n // Calculate the exponent for b: 2^(M - i - 1)\n const exponent = _1n << BigInt(M - i - 1); // bigint is important\n const b = Fp.pow(c, exponent); // b = 2^(M - i - 1)\n // Update variables\n M = i;\n c = Fp.sqr(b); // c = b^2\n t = Fp.mul(t, c); // t = (t * b^2)\n R = Fp.mul(R, b); // R = R*b\n }\n return R;\n };\n}\n/**\n * Square root for a finite field. Will try optimized versions first:\n *\n * 1. P ≡ 3 (mod 4)\n * 2. P ≡ 5 (mod 8)\n * 3. P ≡ 9 (mod 16)\n * 4. Tonelli-Shanks algorithm\n *\n * Different algorithms can give different roots, it is up to user to decide which one they want.\n * For example there is FpSqrtOdd/FpSqrtEven to choice root based on oddness (used for hash-to-curve).\n */\nexport function FpSqrt(P) {\n // P ≡ 3 (mod 4) => √n = n^((P+1)/4)\n if (P % _4n === _3n)\n return sqrt3mod4;\n // P ≡ 5 (mod 8) => Atkin algorithm, page 10 of https://eprint.iacr.org/2012/685.pdf\n if (P % _8n === _5n)\n return sqrt5mod8;\n // P ≡ 9 (mod 16) => Kong algorithm, page 11 of https://eprint.iacr.org/2012/685.pdf (algorithm 4)\n if (P % _16n === _9n)\n return sqrt9mod16(P);\n // Tonelli-Shanks algorithm\n return tonelliShanks(P);\n}\n// Little-endian check for first LE bit (last BE bit);\nexport const isNegativeLE = (num, modulo) => (mod(num, modulo) & _1n) === _1n;\n// prettier-ignore\nconst FIELD_FIELDS = [\n 'create', 'isValid', 'is0', 'neg', 'inv', 'sqrt', 'sqr',\n 'eql', 'add', 'sub', 'mul', 'pow', 'div',\n 'addN', 'subN', 'mulN', 'sqrN'\n];\nexport function validateField(field) {\n const initial = {\n ORDER: 'bigint',\n MASK: 'bigint',\n BYTES: 'number',\n BITS: 'number',\n };\n const opts = FIELD_FIELDS.reduce((map, val) => {\n map[val] = 'function';\n return map;\n }, initial);\n _validateObject(field, opts);\n // const max = 16384;\n // if (field.BYTES < 1 || field.BYTES > max) throw new Error('invalid field');\n // if (field.BITS < 1 || field.BITS > 8 * max) throw new Error('invalid field');\n return field;\n}\n// Generic field functions\n/**\n * Same as `pow` but for Fp: non-constant-time.\n * Unsafe in some contexts: uses ladder, so can expose bigint bits.\n */\nexport function FpPow(Fp, num, power) {\n if (power < _0n)\n throw new Error('invalid exponent, negatives unsupported');\n if (power === _0n)\n return Fp.ONE;\n if (power === _1n)\n return num;\n let p = Fp.ONE;\n let d = num;\n while (power > _0n) {\n if (power & _1n)\n p = Fp.mul(p, d);\n d = Fp.sqr(d);\n power >>= _1n;\n }\n return p;\n}\n/**\n * Efficiently invert an array of Field elements.\n * Exception-free. Will return `undefined` for 0 elements.\n * @param passZero map 0 to 0 (instead of undefined)\n */\nexport function FpInvertBatch(Fp, nums, passZero = false) {\n const inverted = new Array(nums.length).fill(passZero ? Fp.ZERO : undefined);\n // Walk from first to last, multiply them by each other MOD p\n const multipliedAcc = nums.reduce((acc, num, i) => {\n if (Fp.is0(num))\n return acc;\n inverted[i] = acc;\n return Fp.mul(acc, num);\n }, Fp.ONE);\n // Invert last element\n const invertedAcc = Fp.inv(multipliedAcc);\n // Walk from last to first, multiply them by inverted each other MOD p\n nums.reduceRight((acc, num, i) => {\n if (Fp.is0(num))\n return acc;\n inverted[i] = Fp.mul(acc, inverted[i]);\n return Fp.mul(acc, num);\n }, invertedAcc);\n return inverted;\n}\n// TODO: remove\nexport function FpDiv(Fp, lhs, rhs) {\n return Fp.mul(lhs, typeof rhs === 'bigint' ? invert(rhs, Fp.ORDER) : Fp.inv(rhs));\n}\n/**\n * Legendre symbol.\n * Legendre constant is used to calculate Legendre symbol (a | p)\n * which denotes the value of a^((p-1)/2) (mod p).\n *\n * * (a | p) ≡ 1 if a is a square (mod p), quadratic residue\n * * (a | p) ≡ -1 if a is not a square (mod p), quadratic non residue\n * * (a | p) ≡ 0 if a ≡ 0 (mod p)\n */\nexport function FpLegendre(Fp, n) {\n // We can use 3rd argument as optional cache of this value\n // but seems unneeded for now. The operation is very fast.\n const p1mod2 = (Fp.ORDER - _1n) / _2n;\n const powered = Fp.pow(n, p1mod2);\n const yes = Fp.eql(powered, Fp.ONE);\n const zero = Fp.eql(powered, Fp.ZERO);\n const no = Fp.eql(powered, Fp.neg(Fp.ONE));\n if (!yes && !zero && !no)\n throw new Error('invalid Legendre symbol result');\n return yes ? 1 : zero ? 0 : -1;\n}\n// This function returns True whenever the value x is a square in the field F.\nexport function FpIsSquare(Fp, n) {\n const l = FpLegendre(Fp, n);\n return l === 1;\n}\n// CURVE.n lengths\nexport function nLength(n, nBitLength) {\n // Bit size, byte size of CURVE.n\n if (nBitLength !== undefined)\n anumber(nBitLength);\n const _nBitLength = nBitLength !== undefined ? nBitLength : n.toString(2).length;\n const nByteLength = Math.ceil(_nBitLength / 8);\n return { nBitLength: _nBitLength, nByteLength };\n}\n/**\n * Creates a finite field. Major performance optimizations:\n * * 1. Denormalized operations like mulN instead of mul.\n * * 2. Identical object shape: never add or remove keys.\n * * 3. `Object.freeze`.\n * Fragile: always run a benchmark on a change.\n * Security note: operations don't check 'isValid' for all elements for performance reasons,\n * it is caller responsibility to check this.\n * This is low-level code, please make sure you know what you're doing.\n *\n * Note about field properties:\n * * CHARACTERISTIC p = prime number, number of elements in main subgroup.\n * * ORDER q = similar to cofactor in curves, may be composite `q = p^m`.\n *\n * @param ORDER field order, probably prime, or could be composite\n * @param bitLen how many bits the field consumes\n * @param isLE (default: false) if encoding / decoding should be in little-endian\n * @param redef optional faster redefinitions of sqrt and other methods\n */\nexport function Field(ORDER, bitLenOrOpts, // TODO: use opts only in v2?\nisLE = false, opts = {}) {\n if (ORDER <= _0n)\n throw new Error('invalid field: expected ORDER > 0, got ' + ORDER);\n let _nbitLength = undefined;\n let _sqrt = undefined;\n let modFromBytes = false;\n let allowedLengths = undefined;\n if (typeof bitLenOrOpts === 'object' && bitLenOrOpts != null) {\n if (opts.sqrt || isLE)\n throw new Error('cannot specify opts in two arguments');\n const _opts = bitLenOrOpts;\n if (_opts.BITS)\n _nbitLength = _opts.BITS;\n if (_opts.sqrt)\n _sqrt = _opts.sqrt;\n if (typeof _opts.isLE === 'boolean')\n isLE = _opts.isLE;\n if (typeof _opts.modFromBytes === 'boolean')\n modFromBytes = _opts.modFromBytes;\n allowedLengths = _opts.allowedLengths;\n }\n else {\n if (typeof bitLenOrOpts === 'number')\n _nbitLength = bitLenOrOpts;\n if (opts.sqrt)\n _sqrt = opts.sqrt;\n }\n const { nBitLength: BITS, nByteLength: BYTES } = nLength(ORDER, _nbitLength);\n if (BYTES > 2048)\n throw new Error('invalid field: expected ORDER of <= 2048 bytes');\n let sqrtP; // cached sqrtP\n const f = Object.freeze({\n ORDER,\n isLE,\n BITS,\n BYTES,\n MASK: bitMask(BITS),\n ZERO: _0n,\n ONE: _1n,\n allowedLengths: allowedLengths,\n create: (num) => mod(num, ORDER),\n isValid: (num) => {\n if (typeof num !== 'bigint')\n throw new Error('invalid field element: expected bigint, got ' + typeof num);\n return _0n <= num && num < ORDER; // 0 is valid element, but it's not invertible\n },\n is0: (num) => num === _0n,\n // is valid and invertible\n isValidNot0: (num) => !f.is0(num) && f.isValid(num),\n isOdd: (num) => (num & _1n) === _1n,\n neg: (num) => mod(-num, ORDER),\n eql: (lhs, rhs) => lhs === rhs,\n sqr: (num) => mod(num * num, ORDER),\n add: (lhs, rhs) => mod(lhs + rhs, ORDER),\n sub: (lhs, rhs) => mod(lhs - rhs, ORDER),\n mul: (lhs, rhs) => mod(lhs * rhs, ORDER),\n pow: (num, power) => FpPow(f, num, power),\n div: (lhs, rhs) => mod(lhs * invert(rhs, ORDER), ORDER),\n // Same as above, but doesn't normalize\n sqrN: (num) => num * num,\n addN: (lhs, rhs) => lhs + rhs,\n subN: (lhs, rhs) => lhs - rhs,\n mulN: (lhs, rhs) => lhs * rhs,\n inv: (num) => invert(num, ORDER),\n sqrt: _sqrt ||\n ((n) => {\n if (!sqrtP)\n sqrtP = FpSqrt(ORDER);\n return sqrtP(f, n);\n }),\n toBytes: (num) => (isLE ? numberToBytesLE(num, BYTES) : numberToBytesBE(num, BYTES)),\n fromBytes: (bytes, skipValidation = true) => {\n if (allowedLengths) {\n if (!allowedLengths.includes(bytes.length) || bytes.length > BYTES) {\n throw new Error('Field.fromBytes: expected ' + allowedLengths + ' bytes, got ' + bytes.length);\n }\n const padded = new Uint8Array(BYTES);\n // isLE add 0 to right, !isLE to the left.\n padded.set(bytes, isLE ? 0 : padded.length - bytes.length);\n bytes = padded;\n }\n if (bytes.length !== BYTES)\n throw new Error('Field.fromBytes: expected ' + BYTES + ' bytes, got ' + bytes.length);\n let scalar = isLE ? bytesToNumberLE(bytes) : bytesToNumberBE(bytes);\n if (modFromBytes)\n scalar = mod(scalar, ORDER);\n if (!skipValidation)\n if (!f.isValid(scalar))\n throw new Error('invalid field element: outside of range 0..ORDER');\n // NOTE: we don't validate scalar here, please use isValid. This done such way because some\n // protocol may allow non-reduced scalar that reduced later or changed some other way.\n return scalar;\n },\n // TODO: we don't need it here, move out to separate fn\n invertBatch: (lst) => FpInvertBatch(f, lst),\n // We can't move this out because Fp6, Fp12 implement it\n // and it's unclear what to return in there.\n cmov: (a, b, c) => (c ? b : a),\n });\n return Object.freeze(f);\n}\n// Generic random scalar, we can do same for other fields if via Fp2.mul(Fp2.ONE, Fp2.random)?\n// This allows unsafe methods like ignore bias or zero. These unsafe, but often used in different protocols (if deterministic RNG).\n// which mean we cannot force this via opts.\n// Not sure what to do with randomBytes, we can accept it inside opts if wanted.\n// Probably need to export getMinHashLength somewhere?\n// random(bytes?: Uint8Array, unsafeAllowZero = false, unsafeAllowBias = false) {\n// const LEN = !unsafeAllowBias ? getMinHashLength(ORDER) : BYTES;\n// if (bytes === undefined) bytes = randomBytes(LEN); // _opts.randomBytes?\n// const num = isLE ? bytesToNumberLE(bytes) : bytesToNumberBE(bytes);\n// // `mod(x, 11)` can sometimes produce 0. `mod(x, 10) + 1` is the same, but no 0\n// const reduced = unsafeAllowZero ? mod(num, ORDER) : mod(num, ORDER - _1n) + _1n;\n// return reduced;\n// },\nexport function FpSqrtOdd(Fp, elm) {\n if (!Fp.isOdd)\n throw new Error(\"Field doesn't have isOdd\");\n const root = Fp.sqrt(elm);\n return Fp.isOdd(root) ? root : Fp.neg(root);\n}\nexport function FpSqrtEven(Fp, elm) {\n if (!Fp.isOdd)\n throw new Error(\"Field doesn't have isOdd\");\n const root = Fp.sqrt(elm);\n return Fp.isOdd(root) ? Fp.neg(root) : root;\n}\n/**\n * \"Constant-time\" private key generation utility.\n * Same as mapKeyToField, but accepts less bytes (40 instead of 48 for 32-byte field).\n * Which makes it slightly more biased, less secure.\n * @deprecated use `mapKeyToField` instead\n */\nexport function hashToPrivateScalar(hash, groupOrder, isLE = false) {\n hash = ensureBytes('privateHash', hash);\n const hashLen = hash.length;\n const minLen = nLength(groupOrder).nByteLength + 8;\n if (minLen < 24 || hashLen < minLen || hashLen > 1024)\n throw new Error('hashToPrivateScalar: expected ' + minLen + '-1024 bytes of input, got ' + hashLen);\n const num = isLE ? bytesToNumberLE(hash) : bytesToNumberBE(hash);\n return mod(num, groupOrder - _1n) + _1n;\n}\n/**\n * Returns total number of bytes consumed by the field element.\n * For example, 32 bytes for usual 256-bit weierstrass curve.\n * @param fieldOrder number of field elements, usually CURVE.n\n * @returns byte length of field\n */\nexport function getFieldBytesLength(fieldOrder) {\n if (typeof fieldOrder !== 'bigint')\n throw new Error('field order must be bigint');\n const bitLength = fieldOrder.toString(2).length;\n return Math.ceil(bitLength / 8);\n}\n/**\n * Returns minimal amount of bytes that can be safely reduced\n * by field order.\n * Should be 2^-128 for 128-bit curve such as P256.\n * @param fieldOrder number of field elements, usually CURVE.n\n * @returns byte length of target hash\n */\nexport function getMinHashLength(fieldOrder) {\n const length = getFieldBytesLength(fieldOrder);\n return length + Math.ceil(length / 2);\n}\n/**\n * \"Constant-time\" private key generation utility.\n * Can take (n + n/2) or more bytes of uniform input e.g. from CSPRNG or KDF\n * and convert them into private scalar, with the modulo bias being negligible.\n * Needs at least 48 bytes of input for 32-byte private key.\n * https://research.kudelskisecurity.com/2020/07/28/the-definitive-guide-to-modulo-bias-and-how-to-avoid-it/\n * FIPS 186-5, A.2 https://csrc.nist.gov/publications/detail/fips/186/5/final\n * RFC 9380, https://www.rfc-editor.org/rfc/rfc9380#section-5\n * @param hash hash output from SHA3 or a similar function\n * @param groupOrder size of subgroup - (e.g. secp256k1.CURVE.n)\n * @param isLE interpret hash bytes as LE num\n * @returns valid private scalar\n */\nexport function mapHashToField(key, fieldOrder, isLE = false) {\n const len = key.length;\n const fieldLen = getFieldBytesLength(fieldOrder);\n const minLen = getMinHashLength(fieldOrder);\n // No small numbers: need to understand bias story. No huge numbers: easier to detect JS timings.\n if (len < 16 || len < minLen || len > 1024)\n throw new Error('expected ' + minLen + '-1024 bytes of input, got ' + len);\n const num = isLE ? bytesToNumberLE(key) : bytesToNumberBE(key);\n // `mod(x, 11)` can sometimes produce 0. `mod(x, 10) + 1` is the same, but no 0\n const reduced = mod(num, fieldOrder - _1n) + _1n;\n return isLE ? numberToBytesLE(reduced, fieldLen) : numberToBytesBE(reduced, fieldLen);\n}\n//# sourceMappingURL=modular.js.map","/**\n * Methods for elliptic curve multiplication by scalars.\n * Contains wNAF, pippenger.\n * @module\n */\n/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */\nimport { bitLen, bitMask, validateObject } from \"../utils.js\";\nimport { Field, FpInvertBatch, nLength, validateField } from \"./modular.js\";\nconst _0n = BigInt(0);\nconst _1n = BigInt(1);\nexport function negateCt(condition, item) {\n const neg = item.negate();\n return condition ? neg : item;\n}\n/**\n * Takes a bunch of Projective Points but executes only one\n * inversion on all of them. Inversion is very slow operation,\n * so this improves performance massively.\n * Optimization: converts a list of projective points to a list of identical points with Z=1.\n */\nexport function normalizeZ(c, points) {\n const invertedZs = FpInvertBatch(c.Fp, points.map((p) => p.Z));\n return points.map((p, i) => c.fromAffine(p.toAffine(invertedZs[i])));\n}\nfunction validateW(W, bits) {\n if (!Number.isSafeInteger(W) || W <= 0 || W > bits)\n throw new Error('invalid window size, expected [1..' + bits + '], got W=' + W);\n}\nfunction calcWOpts(W, scalarBits) {\n validateW(W, scalarBits);\n const windows = Math.ceil(scalarBits / W) + 1; // W=8 33. Not 32, because we skip zero\n const windowSize = 2 ** (W - 1); // W=8 128. Not 256, because we skip zero\n const maxNumber = 2 ** W; // W=8 256\n const mask = bitMask(W); // W=8 255 == mask 0b11111111\n const shiftBy = BigInt(W); // W=8 8\n return { windows, windowSize, mask, maxNumber, shiftBy };\n}\nfunction calcOffsets(n, window, wOpts) {\n const { windowSize, mask, maxNumber, shiftBy } = wOpts;\n let wbits = Number(n & mask); // extract W bits.\n let nextN = n >> shiftBy; // shift number by W bits.\n // What actually happens here:\n // const highestBit = Number(mask ^ (mask >> 1n));\n // let wbits2 = wbits - 1; // skip zero\n // if (wbits2 & highestBit) { wbits2 ^= Number(mask); // (~);\n // split if bits > max: +224 => 256-32\n if (wbits > windowSize) {\n // we skip zero, which means instead of `>= size-1`, we do `> size`\n wbits -= maxNumber; // -32, can be maxNumber - wbits, but then we need to set isNeg here.\n nextN += _1n; // +256 (carry)\n }\n const offsetStart = window * windowSize;\n const offset = offsetStart + Math.abs(wbits) - 1; // -1 because we skip zero\n const isZero = wbits === 0; // is current window slice a 0?\n const isNeg = wbits < 0; // is current window slice negative?\n const isNegF = window % 2 !== 0; // fake random statement for noise\n const offsetF = offsetStart; // fake offset for noise\n return { nextN, offset, isZero, isNeg, isNegF, offsetF };\n}\nfunction validateMSMPoints(points, c) {\n if (!Array.isArray(points))\n throw new Error('array expected');\n points.forEach((p, i) => {\n if (!(p instanceof c))\n throw new Error('invalid point at index ' + i);\n });\n}\nfunction validateMSMScalars(scalars, field) {\n if (!Array.isArray(scalars))\n throw new Error('array of scalars expected');\n scalars.forEach((s, i) => {\n if (!field.isValid(s))\n throw new Error('invalid scalar at index ' + i);\n });\n}\n// Since points in different groups cannot be equal (different object constructor),\n// we can have single place to store precomputes.\n// Allows to make points frozen / immutable.\nconst pointPrecomputes = new WeakMap();\nconst pointWindowSizes = new WeakMap();\nfunction getW(P) {\n // To disable precomputes:\n // return 1;\n return pointWindowSizes.get(P) || 1;\n}\nfunction assert0(n) {\n if (n !== _0n)\n throw new Error('invalid wNAF');\n}\n/**\n * Elliptic curve multiplication of Point by scalar. Fragile.\n * Table generation takes **30MB of ram and 10ms on high-end CPU**,\n * but may take much longer on slow devices. Actual generation will happen on\n * first call of `multiply()`. By default, `BASE` point is precomputed.\n *\n * Scalars should always be less than curve order: this should be checked inside of a curve itself.\n * Creates precomputation tables for fast multiplication:\n * - private scalar is split by fixed size windows of W bits\n * - every window point is collected from window's table & added to accumulator\n * - since windows are different, same point inside tables won't be accessed more than once per calc\n * - each multiplication is 'Math.ceil(CURVE_ORDER / 𝑊) + 1' point additions (fixed for any scalar)\n * - +1 window is neccessary for wNAF\n * - wNAF reduces table size: 2x less memory + 2x faster generation, but 10% slower multiplication\n *\n * @todo Research returning 2d JS array of windows, instead of a single window.\n * This would allow windows to be in different memory locations\n */\nexport class wNAF {\n // Parametrized with a given Point class (not individual point)\n constructor(Point, bits) {\n this.BASE = Point.BASE;\n this.ZERO = Point.ZERO;\n this.Fn = Point.Fn;\n this.bits = bits;\n }\n // non-const time multiplication ladder\n _unsafeLadder(elm, n, p = this.ZERO) {\n let d = elm;\n while (n > _0n) {\n if (n & _1n)\n p = p.add(d);\n d = d.double();\n n >>= _1n;\n }\n return p;\n }\n /**\n * Creates a wNAF precomputation window. Used for caching.\n * Default window size is set by `utils.precompute()` and is equal to 8.\n * Number of precomputed points depends on the curve size:\n * 2^(𝑊−1) * (Math.ceil(𝑛 / 𝑊) + 1), where:\n * - 𝑊 is the window size\n * - 𝑛 is the bitlength of the curve order.\n * For a 256-bit curve and window size 8, the number of precomputed points is 128 * 33 = 4224.\n * @param point Point instance\n * @param W window size\n * @returns precomputed point tables flattened to a single array\n */\n precomputeWindow(point, W) {\n const { windows, windowSize } = calcWOpts(W, this.bits);\n const points = [];\n let p = point;\n let base = p;\n for (let window = 0; window < windows; window++) {\n base = p;\n points.push(base);\n // i=1, bc we skip 0\n for (let i = 1; i < windowSize; i++) {\n base = base.add(p);\n points.push(base);\n }\n p = base.double();\n }\n return points;\n }\n /**\n * Implements ec multiplication using precomputed tables and w-ary non-adjacent form.\n * More compact implementation:\n * https://github.com/paulmillr/noble-secp256k1/blob/47cb1669b6e506ad66b35fe7d76132ae97465da2/index.ts#L502-L541\n * @returns real and fake (for const-time) points\n */\n wNAF(W, precomputes, n) {\n // Scalar should be smaller than field order\n if (!this.Fn.isValid(n))\n throw new Error('invalid scalar');\n // Accumulators\n let p = this.ZERO;\n let f = this.BASE;\n // This code was first written with assumption that 'f' and 'p' will never be infinity point:\n // since each addition is multiplied by 2 ** W, it cannot cancel each other. However,\n // there is negate now: it is possible that negated element from low value\n // would be the same as high element, which will create carry into next window.\n // It's not obvious how this can fail, but still worth investigating later.\n const wo = calcWOpts(W, this.bits);\n for (let window = 0; window < wo.windows; window++) {\n // (n === _0n) is handled and not early-exited. isEven and offsetF are used for noise\n const { nextN, offset, isZero, isNeg, isNegF, offsetF } = calcOffsets(n, window, wo);\n n = nextN;\n if (isZero) {\n // bits are 0: add garbage to fake point\n // Important part for const-time getPublicKey: add random \"noise\" point to f.\n f = f.add(negateCt(isNegF, precomputes[offsetF]));\n }\n else {\n // bits are 1: add to result point\n p = p.add(negateCt(isNeg, precomputes[offset]));\n }\n }\n assert0(n);\n // Return both real and fake points: JIT won't eliminate f.\n // At this point there is a way to F be infinity-point even if p is not,\n // which makes it less const-time: around 1 bigint multiply.\n return { p, f };\n }\n /**\n * Implements ec unsafe (non const-time) multiplication using precomputed tables and w-ary non-adjacent form.\n * @param acc accumulator point to add result of multiplication\n * @returns point\n */\n wNAFUnsafe(W, precomputes, n, acc = this.ZERO) {\n const wo = calcWOpts(W, this.bits);\n for (let window = 0; window < wo.windows; window++) {\n if (n === _0n)\n break; // Early-exit, skip 0 value\n const { nextN, offset, isZero, isNeg } = calcOffsets(n, window, wo);\n n = nextN;\n if (isZero) {\n // Window bits are 0: skip processing.\n // Move to next window.\n continue;\n }\n else {\n const item = precomputes[offset];\n acc = acc.add(isNeg ? item.negate() : item); // Re-using acc allows to save adds in MSM\n }\n }\n assert0(n);\n return acc;\n }\n getPrecomputes(W, point, transform) {\n // Calculate precomputes on a first run, reuse them after\n let comp = pointPrecomputes.get(point);\n if (!comp) {\n comp = this.precomputeWindow(point, W);\n if (W !== 1) {\n // Doing transform outside of if brings 15% perf hit\n if (typeof transform === 'function')\n comp = transform(comp);\n pointPrecomputes.set(point, comp);\n }\n }\n return comp;\n }\n cached(point, scalar, transform) {\n const W = getW(point);\n return this.wNAF(W, this.getPrecomputes(W, point, transform), scalar);\n }\n unsafe(point, scalar, transform, prev) {\n const W = getW(point);\n if (W === 1)\n return this._unsafeLadder(point, scalar, prev); // For W=1 ladder is ~x2 faster\n return this.wNAFUnsafe(W, this.getPrecomputes(W, point, transform), scalar, prev);\n }\n // We calculate precomputes for elliptic curve point multiplication\n // using windowed method. This specifies window size and\n // stores precomputed values. Usually only base point would be precomputed.\n createCache(P, W) {\n validateW(W, this.bits);\n pointWindowSizes.set(P, W);\n pointPrecomputes.delete(P);\n }\n hasCache(elm) {\n return getW(elm) !== 1;\n }\n}\n/**\n * Endomorphism-specific multiplication for Koblitz curves.\n * Cost: 128 dbl, 0-256 adds.\n */\nexport function mulEndoUnsafe(Point, point, k1, k2) {\n let acc = point;\n let p1 = Point.ZERO;\n let p2 = Point.ZERO;\n while (k1 > _0n || k2 > _0n) {\n if (k1 & _1n)\n p1 = p1.add(acc);\n if (k2 & _1n)\n p2 = p2.add(acc);\n acc = acc.double();\n k1 >>= _1n;\n k2 >>= _1n;\n }\n return { p1, p2 };\n}\n/**\n * Pippenger algorithm for multi-scalar multiplication (MSM, Pa + Qb + Rc + ...).\n * 30x faster vs naive addition on L=4096, 10x faster than precomputes.\n * For N=254bit, L=1, it does: 1024 ADD + 254 DBL. For L=5: 1536 ADD + 254 DBL.\n * Algorithmically constant-time (for same L), even when 1 point + scalar, or when scalar = 0.\n * @param c Curve Point constructor\n * @param fieldN field over CURVE.N - important that it's not over CURVE.P\n * @param points array of L curve points\n * @param scalars array of L scalars (aka secret keys / bigints)\n */\nexport function pippenger(c, fieldN, points, scalars) {\n // If we split scalars by some window (let's say 8 bits), every chunk will only\n // take 256 buckets even if there are 4096 scalars, also re-uses double.\n // TODO:\n // - https://eprint.iacr.org/2024/750.pdf\n // - https://tches.iacr.org/index.php/TCHES/article/view/10287\n // 0 is accepted in scalars\n validateMSMPoints(points, c);\n validateMSMScalars(scalars, fieldN);\n const plength = points.length;\n const slength = scalars.length;\n if (plength !== slength)\n throw new Error('arrays of points and scalars must have equal length');\n // if (plength === 0) throw new Error('array must be of length >= 2');\n const zero = c.ZERO;\n const wbits = bitLen(BigInt(plength));\n let windowSize = 1; // bits\n if (wbits > 12)\n windowSize = wbits - 3;\n else if (wbits > 4)\n windowSize = wbits - 2;\n else if (wbits > 0)\n windowSize = 2;\n const MASK = bitMask(windowSize);\n const buckets = new Array(Number(MASK) + 1).fill(zero); // +1 for zero array\n const lastBits = Math.floor((fieldN.BITS - 1) / windowSize) * windowSize;\n let sum = zero;\n for (let i = lastBits; i >= 0; i -= windowSize) {\n buckets.fill(zero);\n for (let j = 0; j < slength; j++) {\n const scalar = scalars[j];\n const wbits = Number((scalar >> BigInt(i)) & MASK);\n buckets[wbits] = buckets[wbits].add(points[j]);\n }\n let resI = zero; // not using this will do small speed-up, but will lose ct\n // Skip first bucket, because it is zero\n for (let j = buckets.length - 1, sumI = zero; j > 0; j--) {\n sumI = sumI.add(buckets[j]);\n resI = resI.add(sumI);\n }\n sum = sum.add(resI);\n if (i !== 0)\n for (let j = 0; j < windowSize; j++)\n sum = sum.double();\n }\n return sum;\n}\n/**\n * Precomputed multi-scalar multiplication (MSM, Pa + Qb + Rc + ...).\n * @param c Curve Point constructor\n * @param fieldN field over CURVE.N - important that it's not over CURVE.P\n * @param points array of L curve points\n * @returns function which multiplies points with scaars\n */\nexport function precomputeMSMUnsafe(c, fieldN, points, windowSize) {\n /**\n * Performance Analysis of Window-based Precomputation\n *\n * Base Case (256-bit scalar, 8-bit window):\n * - Standard precomputation requires:\n * - 31 additions per scalar × 256 scalars = 7,936 ops\n * - Plus 255 summary additions = 8,191 total ops\n * Note: Summary additions can be optimized via accumulator\n *\n * Chunked Precomputation Analysis:\n * - Using 32 chunks requires:\n * - 255 additions per chunk\n * - 256 doublings\n * - Total: (255 × 32) + 256 = 8,416 ops\n *\n * Memory Usage Comparison:\n * Window Size | Standard Points | Chunked Points\n * ------------|-----------------|---------------\n * 4-bit | 520 | 15\n * 8-bit | 4,224 | 255\n * 10-bit | 13,824 | 1,023\n * 16-bit | 557,056 | 65,535\n *\n * Key Advantages:\n * 1. Enables larger window sizes due to reduced memory overhead\n * 2. More efficient for smaller scalar counts:\n * - 16 chunks: (16 × 255) + 256 = 4,336 ops\n * - ~2x faster than standard 8,191 ops\n *\n * Limitations:\n * - Not suitable for plain precomputes (requires 256 constant doublings)\n * - Performance degrades with larger scalar counts:\n * - Optimal for ~256 scalars\n * - Less efficient for 4096+ scalars (Pippenger preferred)\n */\n validateW(windowSize, fieldN.BITS);\n validateMSMPoints(points, c);\n const zero = c.ZERO;\n const tableSize = 2 ** windowSize - 1; // table size (without zero)\n const chunks = Math.ceil(fieldN.BITS / windowSize); // chunks of item\n const MASK = bitMask(windowSize);\n const tables = points.map((p) => {\n const res = [];\n for (let i = 0, acc = p; i < tableSize; i++) {\n res.push(acc);\n acc = acc.add(p);\n }\n return res;\n });\n return (scalars) => {\n validateMSMScalars(scalars, fieldN);\n if (scalars.length > points.length)\n throw new Error('array of scalars must be smaller than array of points');\n let res = zero;\n for (let i = 0; i < chunks; i++) {\n // No need to double if accumulator is still zero.\n if (res !== zero)\n for (let j = 0; j < windowSize; j++)\n res = res.double();\n const shiftBy = BigInt(chunks * windowSize - (i + 1) * windowSize);\n for (let j = 0; j < scalars.length; j++) {\n const n = scalars[j];\n const curr = Number((n >> shiftBy) & MASK);\n if (!curr)\n continue; // skip zero scalars chunks\n res = res.add(tables[j][curr - 1]);\n }\n }\n return res;\n };\n}\n// TODO: remove\n/** @deprecated */\nexport function validateBasic(curve) {\n validateField(curve.Fp);\n validateObject(curve, {\n n: 'bigint',\n h: 'bigint',\n Gx: 'field',\n Gy: 'field',\n }, {\n nBitLength: 'isSafeInteger',\n nByteLength: 'isSafeInteger',\n });\n // Set defaults\n return Object.freeze({\n ...nLength(curve.n, curve.nBitLength),\n ...curve,\n ...{ p: curve.Fp.ORDER },\n });\n}\nfunction createField(order, field, isLE) {\n if (field) {\n if (field.ORDER !== order)\n throw new Error('Field.ORDER must match order: Fp == p, Fn == n');\n validateField(field);\n return field;\n }\n else {\n return Field(order, { isLE });\n }\n}\n/** Validates CURVE opts and creates fields */\nexport function _createCurveFields(type, CURVE, curveOpts = {}, FpFnLE) {\n if (FpFnLE === undefined)\n FpFnLE = type === 'edwards';\n if (!CURVE || typeof CURVE !== 'object')\n throw new Error(`expected valid ${type} CURVE object`);\n for (const p of ['p', 'n', 'h']) {\n const val = CURVE[p];\n if (!(typeof val === 'bigint' && val > _0n))\n throw new Error(`CURVE.${p} must be positive bigint`);\n }\n const Fp = createField(CURVE.p, curveOpts.Fp, FpFnLE);\n const Fn = createField(CURVE.n, curveOpts.Fn, FpFnLE);\n const _b = type === 'weierstrass' ? 'b' : 'd';\n const params = ['Gx', 'Gy', 'a', _b];\n for (const p of params) {\n // @ts-ignore\n if (!Fp.isValid(CURVE[p]))\n throw new Error(`CURVE.${p} must be valid field element of CURVE.Fp`);\n }\n CURVE = Object.freeze(Object.assign({}, CURVE));\n return { CURVE, Fp, Fn };\n}\n//# sourceMappingURL=curve.js.map","/**\n * Short Weierstrass curve methods. The formula is: y² = x³ + ax + b.\n *\n * ### Design rationale for types\n *\n * * Interaction between classes from different curves should fail:\n * `k256.Point.BASE.add(p256.Point.BASE)`\n * * For this purpose we want to use `instanceof` operator, which is fast and works during runtime\n * * Different calls of `curve()` would return different classes -\n * `curve(params) !== curve(params)`: if somebody decided to monkey-patch their curve,\n * it won't affect others\n *\n * TypeScript can't infer types for classes created inside a function. Classes is one instance\n * of nominative types in TypeScript and interfaces only check for shape, so it's hard to create\n * unique type for every function call.\n *\n * We can use generic types via some param, like curve opts, but that would:\n * 1. Enable interaction between `curve(params)` and `curve(params)` (curves of same params)\n * which is hard to debug.\n * 2. Params can be generic and we can't enforce them to be constant value:\n * if somebody creates curve from non-constant params,\n * it would be allowed to interact with other curves with non-constant params\n *\n * @todo https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-7.html#unique-symbol\n * @module\n */\n/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */\nimport { hmac as nobleHmac } from '@noble/hashes/hmac.js';\nimport { ahash } from '@noble/hashes/utils';\nimport { _validateObject, _abool2 as abool, _abytes2 as abytes, aInRange, bitLen, bitMask, bytesToHex, bytesToNumberBE, concatBytes, createHmacDrbg, ensureBytes, hexToBytes, inRange, isBytes, memoized, numberToHexUnpadded, randomBytes as randomBytesWeb, } from \"../utils.js\";\nimport { _createCurveFields, mulEndoUnsafe, negateCt, normalizeZ, pippenger, wNAF, } from \"./curve.js\";\nimport { Field, FpInvertBatch, getMinHashLength, mapHashToField, nLength, validateField, } from \"./modular.js\";\n// We construct basis in such way that den is always positive and equals n, but num sign depends on basis (not on secret value)\nconst divNearest = (num, den) => (num + (num >= 0 ? den : -den) / _2n) / den;\n/**\n * Splits scalar for GLV endomorphism.\n */\nexport function _splitEndoScalar(k, basis, n) {\n // Split scalar into two such that part is ~half bits: `abs(part) < sqrt(N)`\n // Since part can be negative, we need to do this on point.\n // TODO: verifyScalar function which consumes lambda\n const [[a1, b1], [a2, b2]] = basis;\n const c1 = divNearest(b2 * k, n);\n const c2 = divNearest(-b1 * k, n);\n // |k1|/|k2| is < sqrt(N), but can be negative.\n // If we do `k1 mod N`, we'll get big scalar (`> sqrt(N)`): so, we do cheaper negation instead.\n let k1 = k - c1 * a1 - c2 * a2;\n let k2 = -c1 * b1 - c2 * b2;\n const k1neg = k1 < _0n;\n const k2neg = k2 < _0n;\n if (k1neg)\n k1 = -k1;\n if (k2neg)\n k2 = -k2;\n // Double check that resulting scalar less than half bits of N: otherwise wNAF will fail.\n // This should only happen on wrong basises. Also, math inside is too complex and I don't trust it.\n const MAX_NUM = bitMask(Math.ceil(bitLen(n) / 2)) + _1n; // Half bits of N\n if (k1 < _0n || k1 >= MAX_NUM || k2 < _0n || k2 >= MAX_NUM) {\n throw new Error('splitScalar (endomorphism): failed, k=' + k);\n }\n return { k1neg, k1, k2neg, k2 };\n}\nfunction validateSigFormat(format) {\n if (!['compact', 'recovered', 'der'].includes(format))\n throw new Error('Signature format must be \"compact\", \"recovered\", or \"der\"');\n return format;\n}\nfunction validateSigOpts(opts, def) {\n const optsn = {};\n for (let optName of Object.keys(def)) {\n // @ts-ignore\n optsn[optName] = opts[optName] === undefined ? def[optName] : opts[optName];\n }\n abool(optsn.lowS, 'lowS');\n abool(optsn.prehash, 'prehash');\n if (optsn.format !== undefined)\n validateSigFormat(optsn.format);\n return optsn;\n}\nexport class DERErr extends Error {\n constructor(m = '') {\n super(m);\n }\n}\n/**\n * ASN.1 DER encoding utilities. ASN is very complex & fragile. Format:\n *\n * [0x30 (SEQUENCE), bytelength, 0x02 (INTEGER), intLength, R, 0x02 (INTEGER), intLength, S]\n *\n * Docs: https://letsencrypt.org/docs/a-warm-welcome-to-asn1-and-der/, https://luca.ntop.org/Teaching/Appunti/asn1.html\n */\nexport const DER = {\n // asn.1 DER encoding utils\n Err: DERErr,\n // Basic building block is TLV (Tag-Length-Value)\n _tlv: {\n encode: (tag, data) => {\n const { Err: E } = DER;\n if (tag < 0 || tag > 256)\n throw new E('tlv.encode: wrong tag');\n if (data.length & 1)\n throw new E('tlv.encode: unpadded data');\n const dataLen = data.length / 2;\n const len = numberToHexUnpadded(dataLen);\n if ((len.length / 2) & 128)\n throw new E('tlv.encode: long form length too big');\n // length of length with long form flag\n const lenLen = dataLen > 127 ? numberToHexUnpadded((len.length / 2) | 128) : '';\n const t = numberToHexUnpadded(tag);\n return t + lenLen + len + data;\n },\n // v - value, l - left bytes (unparsed)\n decode(tag, data) {\n const { Err: E } = DER;\n let pos = 0;\n if (tag < 0 || tag > 256)\n throw new E('tlv.encode: wrong tag');\n if (data.length < 2 || data[pos++] !== tag)\n throw new E('tlv.decode: wrong tlv');\n const first = data[pos++];\n const isLong = !!(first & 128); // First bit of first length byte is flag for short/long form\n let length = 0;\n if (!isLong)\n length = first;\n else {\n // Long form: [longFlag(1bit), lengthLength(7bit), length (BE)]\n const lenLen = first & 127;\n if (!lenLen)\n throw new E('tlv.decode(long): indefinite length not supported');\n if (lenLen > 4)\n throw new E('tlv.decode(long): byte length is too big'); // this will overflow u32 in js\n const lengthBytes = data.subarray(pos, pos + lenLen);\n if (lengthBytes.length !== lenLen)\n throw new E('tlv.decode: length bytes not complete');\n if (lengthBytes[0] === 0)\n throw new E('tlv.decode(long): zero leftmost byte');\n for (const b of lengthBytes)\n length = (length << 8) | b;\n pos += lenLen;\n if (length < 128)\n throw new E('tlv.decode(long): not minimal encoding');\n }\n const v = data.subarray(pos, pos + length);\n if (v.length !== length)\n throw new E('tlv.decode: wrong value length');\n return { v, l: data.subarray(pos + length) };\n },\n },\n // https://crypto.stackexchange.com/a/57734 Leftmost bit of first byte is 'negative' flag,\n // since we always use positive integers here. It must always be empty:\n // - add zero byte if exists\n // - if next byte doesn't have a flag, leading zero is not allowed (minimal encoding)\n _int: {\n encode(num) {\n const { Err: E } = DER;\n if (num < _0n)\n throw new E('integer: negative integers are not allowed');\n let hex = numberToHexUnpadded(num);\n // Pad with zero byte if negative flag is present\n if (Number.parseInt(hex[0], 16) & 0b1000)\n hex = '00' + hex;\n if (hex.length & 1)\n throw new E('unexpected DER parsing assertion: unpadded hex');\n return hex;\n },\n decode(data) {\n const { Err: E } = DER;\n if (data[0] & 128)\n throw new E('invalid signature integer: negative');\n if (data[0] === 0x00 && !(data[1] & 128))\n throw new E('invalid signature integer: unnecessary leading zero');\n return bytesToNumberBE(data);\n },\n },\n toSig(hex) {\n // parse DER signature\n const { Err: E, _int: int, _tlv: tlv } = DER;\n const data = ensureBytes('signature', hex);\n const { v: seqBytes, l: seqLeftBytes } = tlv.decode(0x30, data);\n if (seqLeftBytes.length)\n throw new E('invalid signature: left bytes after parsing');\n const { v: rBytes, l: rLeftBytes } = tlv.decode(0x02, seqBytes);\n const { v: sBytes, l: sLeftBytes } = tlv.decode(0x02, rLeftBytes);\n if (sLeftBytes.length)\n throw new E('invalid signature: left bytes after parsing');\n return { r: int.decode(rBytes), s: int.decode(sBytes) };\n },\n hexFromSig(sig) {\n const { _tlv: tlv, _int: int } = DER;\n const rs = tlv.encode(0x02, int.encode(sig.r));\n const ss = tlv.encode(0x02, int.encode(sig.s));\n const seq = rs + ss;\n return tlv.encode(0x30, seq);\n },\n};\n// Be friendly to bad ECMAScript parsers by not using bigint literals\n// prettier-ignore\nconst _0n = BigInt(0), _1n = BigInt(1), _2n = BigInt(2), _3n = BigInt(3), _4n = BigInt(4);\nexport function _normFnElement(Fn, key) {\n const { BYTES: expected } = Fn;\n let num;\n if (typeof key === 'bigint') {\n num = key;\n }\n else {\n let bytes = ensureBytes('private key', key);\n try {\n num = Fn.fromBytes(bytes);\n }\n catch (error) {\n throw new Error(`invalid private key: expected ui8a of size ${expected}, got ${typeof key}`);\n }\n }\n if (!Fn.isValidNot0(num))\n throw new Error('invalid private key: out of range [1..N-1]');\n return num;\n}\n/**\n * Creates weierstrass Point constructor, based on specified curve options.\n *\n * @example\n```js\nconst opts = {\n p: BigInt('0xffffffff00000001000000000000000000000000ffffffffffffffffffffffff'),\n n: BigInt('0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551'),\n h: BigInt(1),\n a: BigInt('0xffffffff00000001000000000000000000000000fffffffffffffffffffffffc'),\n b: BigInt('0x5ac635d8aa3a93e7b3ebbd55769886bc651d06b0cc53b0f63bce3c3e27d2604b'),\n Gx: BigInt('0x6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296'),\n Gy: BigInt('0x4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5'),\n};\nconst p256_Point = weierstrass(opts);\n```\n */\nexport function weierstrassN(params, extraOpts = {}) {\n const validated = _createCurveFields('weierstrass', params, extraOpts);\n const { Fp, Fn } = validated;\n let CURVE = validated.CURVE;\n const { h: cofactor, n: CURVE_ORDER } = CURVE;\n _validateObject(extraOpts, {}, {\n allowInfinityPoint: 'boolean',\n clearCofactor: 'function',\n isTorsionFree: 'function',\n fromBytes: 'function',\n toBytes: 'function',\n endo: 'object',\n wrapPrivateKey: 'boolean',\n });\n const { endo } = extraOpts;\n if (endo) {\n // validateObject(endo, { beta: 'bigint', splitScalar: 'function' });\n if (!Fp.is0(CURVE.a) || typeof endo.beta !== 'bigint' || !Array.isArray(endo.basises)) {\n throw new Error('invalid endo: expected \"beta\": bigint and \"basises\": array');\n }\n }\n const lengths = getWLengths(Fp, Fn);\n function assertCompressionIsSupported() {\n if (!Fp.isOdd)\n throw new Error('compression is not supported: Field does not have .isOdd()');\n }\n // Implements IEEE P1363 point encoding\n function pointToBytes(_c, point, isCompressed) {\n const { x, y } = point.toAffine();\n const bx = Fp.toBytes(x);\n abool(isCompressed, 'isCompressed');\n if (isCompressed) {\n assertCompressionIsSupported();\n const hasEvenY = !Fp.isOdd(y);\n return concatBytes(pprefix(hasEvenY), bx);\n }\n else {\n return concatBytes(Uint8Array.of(0x04), bx, Fp.toBytes(y));\n }\n }\n function pointFromBytes(bytes) {\n abytes(bytes, undefined, 'Point');\n const { publicKey: comp, publicKeyUncompressed: uncomp } = lengths; // e.g. for 32-byte: 33, 65\n const length = bytes.length;\n const head = bytes[0];\n const tail = bytes.subarray(1);\n // No actual validation is done here: use .assertValidity()\n if (length === comp && (head === 0x02 || head === 0x03)) {\n const x = Fp.fromBytes(tail);\n if (!Fp.isValid(x))\n throw new Error('bad point: is not on curve, wrong x');\n const y2 = weierstrassEquation(x); // y² = x³ + ax + b\n let y;\n try {\n y = Fp.sqrt(y2); // y = y² ^ (p+1)/4\n }\n catch (sqrtError) {\n const err = sqrtError instanceof Error ? ': ' + sqrtError.message : '';\n throw new Error('bad point: is not on curve, sqrt error' + err);\n }\n assertCompressionIsSupported();\n const isYOdd = Fp.isOdd(y); // (y & _1n) === _1n;\n const isHeadOdd = (head & 1) === 1; // ECDSA-specific\n if (isHeadOdd !== isYOdd)\n y = Fp.neg(y);\n return { x, y };\n }\n else if (length === uncomp && head === 0x04) {\n // TODO: more checks\n const L = Fp.BYTES;\n const x = Fp.fromBytes(tail.subarray(0, L));\n const y = Fp.fromBytes(tail.subarray(L, L * 2));\n if (!isValidXY(x, y))\n throw new Error('bad point: is not on curve');\n return { x, y };\n }\n else {\n throw new Error(`bad point: got length ${length}, expected compressed=${comp} or uncompressed=${uncomp}`);\n }\n }\n const encodePoint = extraOpts.toBytes || pointToBytes;\n const decodePoint = extraOpts.fromBytes || pointFromBytes;\n function weierstrassEquation(x) {\n const x2 = Fp.sqr(x); // x * x\n const x3 = Fp.mul(x2, x); // x² * x\n return Fp.add(Fp.add(x3, Fp.mul(x, CURVE.a)), CURVE.b); // x³ + a * x + b\n }\n // TODO: move top-level\n /** Checks whether equation holds for given x, y: y² == x³ + ax + b */\n function isValidXY(x, y) {\n const left = Fp.sqr(y); // y²\n const right = weierstrassEquation(x); // x³ + ax + b\n return Fp.eql(left, right);\n }\n // Validate whether the passed curve params are valid.\n // Test 1: equation y² = x³ + ax + b should work for generator point.\n if (!isValidXY(CURVE.Gx, CURVE.Gy))\n throw new Error('bad curve params: generator point');\n // Test 2: discriminant Δ part should be non-zero: 4a³ + 27b² != 0.\n // Guarantees curve is genus-1, smooth (non-singular).\n const _4a3 = Fp.mul(Fp.pow(CURVE.a, _3n), _4n);\n const _27b2 = Fp.mul(Fp.sqr(CURVE.b), BigInt(27));\n if (Fp.is0(Fp.add(_4a3, _27b2)))\n throw new Error('bad curve params: a or b');\n /** Asserts coordinate is valid: 0 <= n < Fp.ORDER. */\n function acoord(title, n, banZero = false) {\n if (!Fp.isValid(n) || (banZero && Fp.is0(n)))\n throw new Error(`bad point coordinate ${title}`);\n return n;\n }\n function aprjpoint(other) {\n if (!(other instanceof Point))\n throw new Error('ProjectivePoint expected');\n }\n function splitEndoScalarN(k) {\n if (!endo || !endo.basises)\n throw new Error('no endo');\n return _splitEndoScalar(k, endo.basises, Fn.ORDER);\n }\n // Memoized toAffine / validity check. They are heavy. Points are immutable.\n // Converts Projective point to affine (x, y) coordinates.\n // Can accept precomputed Z^-1 - for example, from invertBatch.\n // (X, Y, Z) ∋ (x=X/Z, y=Y/Z)\n const toAffineMemo = memoized((p, iz) => {\n const { X, Y, Z } = p;\n // Fast-path for normalized points\n if (Fp.eql(Z, Fp.ONE))\n return { x: X, y: Y };\n const is0 = p.is0();\n // If invZ was 0, we return zero point. However we still want to execute\n // all operations, so we replace invZ with a random number, 1.\n if (iz == null)\n iz = is0 ? Fp.ONE : Fp.inv(Z);\n const x = Fp.mul(X, iz);\n const y = Fp.mul(Y, iz);\n const zz = Fp.mul(Z, iz);\n if (is0)\n return { x: Fp.ZERO, y: Fp.ZERO };\n if (!Fp.eql(zz, Fp.ONE))\n throw new Error('invZ was invalid');\n return { x, y };\n });\n // NOTE: on exception this will crash 'cached' and no value will be set.\n // Otherwise true will be return\n const assertValidMemo = memoized((p) => {\n if (p.is0()) {\n // (0, 1, 0) aka ZERO is invalid in most contexts.\n // In BLS, ZERO can be serialized, so we allow it.\n // (0, 0, 0) is invalid representation of ZERO.\n if (extraOpts.allowInfinityPoint && !Fp.is0(p.Y))\n return;\n throw new Error('bad point: ZERO');\n }\n // Some 3rd-party test vectors require different wording between here & `fromCompressedHex`\n const { x, y } = p.toAffine();\n if (!Fp.isValid(x) || !Fp.isValid(y))\n throw new Error('bad point: x or y not field elements');\n if (!isValidXY(x, y))\n throw new Error('bad point: equation left != right');\n if (!p.isTorsionFree())\n throw new Error('bad point: not in prime-order subgroup');\n return true;\n });\n function finishEndo(endoBeta, k1p, k2p, k1neg, k2neg) {\n k2p = new Point(Fp.mul(k2p.X, endoBeta), k2p.Y, k2p.Z);\n k1p = negateCt(k1neg, k1p);\n k2p = negateCt(k2neg, k2p);\n return k1p.add(k2p);\n }\n /**\n * Projective Point works in 3d / projective (homogeneous) coordinates:(X, Y, Z) ∋ (x=X/Z, y=Y/Z).\n * Default Point works in 2d / affine coordinates: (x, y).\n * We're doing calculations in projective, because its operations don't require costly inversion.\n */\n class Point {\n /** Does NOT validate if the point is valid. Use `.assertValidity()`. */\n constructor(X, Y, Z) {\n this.X = acoord('x', X);\n this.Y = acoord('y', Y, true);\n this.Z = acoord('z', Z);\n Object.freeze(this);\n }\n static CURVE() {\n return CURVE;\n }\n /** Does NOT validate if the point is valid. Use `.assertValidity()`. */\n static fromAffine(p) {\n const { x, y } = p || {};\n if (!p || !Fp.isValid(x) || !Fp.isValid(y))\n throw new Error('invalid affine point');\n if (p instanceof Point)\n throw new Error('projective point not allowed');\n // (0, 0) would've produced (0, 0, 1) - instead, we need (0, 1, 0)\n if (Fp.is0(x) && Fp.is0(y))\n return Point.ZERO;\n return new Point(x, y, Fp.ONE);\n }\n static fromBytes(bytes) {\n const P = Point.fromAffine(decodePoint(abytes(bytes, undefined, 'point')));\n P.assertValidity();\n return P;\n }\n static fromHex(hex) {\n return Point.fromBytes(ensureBytes('pointHex', hex));\n }\n get x() {\n return this.toAffine().x;\n }\n get y() {\n return this.toAffine().y;\n }\n /**\n *\n * @param windowSize\n * @param isLazy true will defer table computation until the first multiplication\n * @returns\n */\n precompute(windowSize = 8, isLazy = true) {\n wnaf.createCache(this, windowSize);\n if (!isLazy)\n this.multiply(_3n); // random number\n return this;\n }\n // TODO: return `this`\n /** A point on curve is valid if it conforms to equation. */\n assertValidity() {\n assertValidMemo(this);\n }\n hasEvenY() {\n const { y } = this.toAffine();\n if (!Fp.isOdd)\n throw new Error(\"Field doesn't support isOdd\");\n return !Fp.isOdd(y);\n }\n /** Compare one point to another. */\n equals(other) {\n aprjpoint(other);\n const { X: X1, Y: Y1, Z: Z1 } = this;\n const { X: X2, Y: Y2, Z: Z2 } = other;\n const U1 = Fp.eql(Fp.mul(X1, Z2), Fp.mul(X2, Z1));\n const U2 = Fp.eql(Fp.mul(Y1, Z2), Fp.mul(Y2, Z1));\n return U1 && U2;\n }\n /** Flips point to one corresponding to (x, -y) in Affine coordinates. */\n negate() {\n return new Point(this.X, Fp.neg(this.Y), this.Z);\n }\n // Renes-Costello-Batina exception-free doubling formula.\n // There is 30% faster Jacobian formula, but it is not complete.\n // https://eprint.iacr.org/2015/1060, algorithm 3\n // Cost: 8M + 3S + 3*a + 2*b3 + 15add.\n double() {\n const { a, b } = CURVE;\n const b3 = Fp.mul(b, _3n);\n const { X: X1, Y: Y1, Z: Z1 } = this;\n let X3 = Fp.ZERO, Y3 = Fp.ZERO, Z3 = Fp.ZERO; // prettier-ignore\n let t0 = Fp.mul(X1, X1); // step 1\n let t1 = Fp.mul(Y1, Y1);\n let t2 = Fp.mul(Z1, Z1);\n let t3 = Fp.mul(X1, Y1);\n t3 = Fp.add(t3, t3); // step 5\n Z3 = Fp.mul(X1, Z1);\n Z3 = Fp.add(Z3, Z3);\n X3 = Fp.mul(a, Z3);\n Y3 = Fp.mul(b3, t2);\n Y3 = Fp.add(X3, Y3); // step 10\n X3 = Fp.sub(t1, Y3);\n Y3 = Fp.add(t1, Y3);\n Y3 = Fp.mul(X3, Y3);\n X3 = Fp.mul(t3, X3);\n Z3 = Fp.mul(b3, Z3); // step 15\n t2 = Fp.mul(a, t2);\n t3 = Fp.sub(t0, t2);\n t3 = Fp.mul(a, t3);\n t3 = Fp.add(t3, Z3);\n Z3 = Fp.add(t0, t0); // step 20\n t0 = Fp.add(Z3, t0);\n t0 = Fp.add(t0, t2);\n t0 = Fp.mul(t0, t3);\n Y3 = Fp.add(Y3, t0);\n t2 = Fp.mul(Y1, Z1); // step 25\n t2 = Fp.add(t2, t2);\n t0 = Fp.mul(t2, t3);\n X3 = Fp.sub(X3, t0);\n Z3 = Fp.mul(t2, t1);\n Z3 = Fp.add(Z3, Z3); // step 30\n Z3 = Fp.add(Z3, Z3);\n return new Point(X3, Y3, Z3);\n }\n // Renes-Costello-Batina exception-free addition formula.\n // There is 30% faster Jacobian formula, but it is not complete.\n // https://eprint.iacr.org/2015/1060, algorithm 1\n // Cost: 12M + 0S + 3*a + 3*b3 + 23add.\n add(other) {\n aprjpoint(other);\n const { X: X1, Y: Y1, Z: Z1 } = this;\n const { X: X2, Y: Y2, Z: Z2 } = other;\n let X3 = Fp.ZERO, Y3 = Fp.ZERO, Z3 = Fp.ZERO; // prettier-ignore\n const a = CURVE.a;\n const b3 = Fp.mul(CURVE.b, _3n);\n let t0 = Fp.mul(X1, X2); // step 1\n let t1 = Fp.mul(Y1, Y2);\n let t2 = Fp.mul(Z1, Z2);\n let t3 = Fp.add(X1, Y1);\n let t4 = Fp.add(X2, Y2); // step 5\n t3 = Fp.mul(t3, t4);\n t4 = Fp.add(t0, t1);\n t3 = Fp.sub(t3, t4);\n t4 = Fp.add(X1, Z1);\n let t5 = Fp.add(X2, Z2); // step 10\n t4 = Fp.mul(t4, t5);\n t5 = Fp.add(t0, t2);\n t4 = Fp.sub(t4, t5);\n t5 = Fp.add(Y1, Z1);\n X3 = Fp.add(Y2, Z2); // step 15\n t5 = Fp.mul(t5, X3);\n X3 = Fp.add(t1, t2);\n t5 = Fp.sub(t5, X3);\n Z3 = Fp.mul(a, t4);\n X3 = Fp.mul(b3, t2); // step 20\n Z3 = Fp.add(X3, Z3);\n X3 = Fp.sub(t1, Z3);\n Z3 = Fp.add(t1, Z3);\n Y3 = Fp.mul(X3, Z3);\n t1 = Fp.add(t0, t0); // step 25\n t1 = Fp.add(t1, t0);\n t2 = Fp.mul(a, t2);\n t4 = Fp.mul(b3, t4);\n t1 = Fp.add(t1, t2);\n t2 = Fp.sub(t0, t2); // step 30\n t2 = Fp.mul(a, t2);\n t4 = Fp.add(t4, t2);\n t0 = Fp.mul(t1, t4);\n Y3 = Fp.add(Y3, t0);\n t0 = Fp.mul(t5, t4); // step 35\n X3 = Fp.mul(t3, X3);\n X3 = Fp.sub(X3, t0);\n t0 = Fp.mul(t3, t1);\n Z3 = Fp.mul(t5, Z3);\n Z3 = Fp.add(Z3, t0); // step 40\n return new Point(X3, Y3, Z3);\n }\n subtract(other) {\n return this.add(other.negate());\n }\n is0() {\n return this.equals(Point.ZERO);\n }\n /**\n * Constant time multiplication.\n * Uses wNAF method. Windowed method may be 10% faster,\n * but takes 2x longer to generate and consumes 2x memory.\n * Uses precomputes when available.\n * Uses endomorphism for Koblitz curves.\n * @param scalar by which the point would be multiplied\n * @returns New point\n */\n multiply(scalar) {\n const { endo } = extraOpts;\n if (!Fn.isValidNot0(scalar))\n throw new Error('invalid scalar: out of range'); // 0 is invalid\n let point, fake; // Fake point is used to const-time mult\n const mul = (n) => wnaf.cached(this, n, (p) => normalizeZ(Point, p));\n /** See docs for {@link EndomorphismOpts} */\n if (endo) {\n const { k1neg, k1, k2neg, k2 } = splitEndoScalarN(scalar);\n const { p: k1p, f: k1f } = mul(k1);\n const { p: k2p, f: k2f } = mul(k2);\n fake = k1f.add(k2f);\n point = finishEndo(endo.beta, k1p, k2p, k1neg, k2neg);\n }\n else {\n const { p, f } = mul(scalar);\n point = p;\n fake = f;\n }\n // Normalize `z` for both points, but return only real one\n return normalizeZ(Point, [point, fake])[0];\n }\n /**\n * Non-constant-time multiplication. Uses double-and-add algorithm.\n * It's faster, but should only be used when you don't care about\n * an exposed secret key e.g. sig verification, which works over *public* keys.\n */\n multiplyUnsafe(sc) {\n const { endo } = extraOpts;\n const p = this;\n if (!Fn.isValid(sc))\n throw new Error('invalid scalar: out of range'); // 0 is valid\n if (sc === _0n || p.is0())\n return Point.ZERO;\n if (sc === _1n)\n return p; // fast-path\n if (wnaf.hasCache(this))\n return this.multiply(sc);\n if (endo) {\n const { k1neg, k1, k2neg, k2 } = splitEndoScalarN(sc);\n const { p1, p2 } = mulEndoUnsafe(Point, p, k1, k2); // 30% faster vs wnaf.unsafe\n return finishEndo(endo.beta, p1, p2, k1neg, k2neg);\n }\n else {\n return wnaf.unsafe(p, sc);\n }\n }\n multiplyAndAddUnsafe(Q, a, b) {\n const sum = this.multiplyUnsafe(a).add(Q.multiplyUnsafe(b));\n return sum.is0() ? undefined : sum;\n }\n /**\n * Converts Projective point to affine (x, y) coordinates.\n * @param invertedZ Z^-1 (inverted zero) - optional, precomputation is useful for invertBatch\n */\n toAffine(invertedZ) {\n return toAffineMemo(this, invertedZ);\n }\n /**\n * Checks whether Point is free of torsion elements (is in prime subgroup).\n * Always torsion-free for cofactor=1 curves.\n */\n isTorsionFree() {\n const { isTorsionFree } = extraOpts;\n if (cofactor === _1n)\n return true;\n if (isTorsionFree)\n return isTorsionFree(Point, this);\n return wnaf.unsafe(this, CURVE_ORDER).is0();\n }\n clearCofactor() {\n const { clearCofactor } = extraOpts;\n if (cofactor === _1n)\n return this; // Fast-path\n if (clearCofactor)\n return clearCofactor(Point, this);\n return this.multiplyUnsafe(cofactor);\n }\n isSmallOrder() {\n // can we use this.clearCofactor()?\n return this.multiplyUnsafe(cofactor).is0();\n }\n toBytes(isCompressed = true) {\n abool(isCompressed, 'isCompressed');\n this.assertValidity();\n return encodePoint(Point, this, isCompressed);\n }\n toHex(isCompressed = true) {\n return bytesToHex(this.toBytes(isCompressed));\n }\n toString() {\n return `<Point ${this.is0() ? 'ZERO' : this.toHex()}>`;\n }\n // TODO: remove\n get px() {\n return this.X;\n }\n get py() {\n return this.X;\n }\n get pz() {\n return this.Z;\n }\n toRawBytes(isCompressed = true) {\n return this.toBytes(isCompressed);\n }\n _setWindowSize(windowSize) {\n this.precompute(windowSize);\n }\n static normalizeZ(points) {\n return normalizeZ(Point, points);\n }\n static msm(points, scalars) {\n return pippenger(Point, Fn, points, scalars);\n }\n static fromPrivateKey(privateKey) {\n return Point.BASE.multiply(_normFnElement(Fn, privateKey));\n }\n }\n // base / generator point\n Point.BASE = new Point(CURVE.Gx, CURVE.Gy, Fp.ONE);\n // zero / infinity / identity point\n Point.ZERO = new Point(Fp.ZERO, Fp.ONE, Fp.ZERO); // 0, 1, 0\n // math field\n Point.Fp = Fp;\n // scalar field\n Point.Fn = Fn;\n const bits = Fn.BITS;\n const wnaf = new wNAF(Point, extraOpts.endo ? Math.ceil(bits / 2) : bits);\n Point.BASE.precompute(8); // Enable precomputes. Slows down first publicKey computation by 20ms.\n return Point;\n}\n// Points start with byte 0x02 when y is even; otherwise 0x03\nfunction pprefix(hasEvenY) {\n return Uint8Array.of(hasEvenY ? 0x02 : 0x03);\n}\n/**\n * Implementation of the Shallue and van de Woestijne method for any weierstrass curve.\n * TODO: check if there is a way to merge this with uvRatio in Edwards; move to modular.\n * b = True and y = sqrt(u / v) if (u / v) is square in F, and\n * b = False and y = sqrt(Z * (u / v)) otherwise.\n * @param Fp\n * @param Z\n * @returns\n */\nexport function SWUFpSqrtRatio(Fp, Z) {\n // Generic implementation\n const q = Fp.ORDER;\n let l = _0n;\n for (let o = q - _1n; o % _2n === _0n; o /= _2n)\n l += _1n;\n const c1 = l; // 1. c1, the largest integer such that 2^c1 divides q - 1.\n // We need 2n ** c1 and 2n ** (c1-1). We can't use **; but we can use <<.\n // 2n ** c1 == 2n << (c1-1)\n const _2n_pow_c1_1 = _2n << (c1 - _1n - _1n);\n const _2n_pow_c1 = _2n_pow_c1_1 * _2n;\n const c2 = (q - _1n) / _2n_pow_c1; // 2. c2 = (q - 1) / (2^c1) # Integer arithmetic\n const c3 = (c2 - _1n) / _2n; // 3. c3 = (c2 - 1) / 2 # Integer arithmetic\n const c4 = _2n_pow_c1 - _1n; // 4. c4 = 2^c1 - 1 # Integer arithmetic\n const c5 = _2n_pow_c1_1; // 5. c5 = 2^(c1 - 1) # Integer arithmetic\n const c6 = Fp.pow(Z, c2); // 6. c6 = Z^c2\n const c7 = Fp.pow(Z, (c2 + _1n) / _2n); // 7. c7 = Z^((c2 + 1) / 2)\n let sqrtRatio = (u, v) => {\n let tv1 = c6; // 1. tv1 = c6\n let tv2 = Fp.pow(v, c4); // 2. tv2 = v^c4\n let tv3 = Fp.sqr(tv2); // 3. tv3 = tv2^2\n tv3 = Fp.mul(tv3, v); // 4. tv3 = tv3 * v\n let tv5 = Fp.mul(u, tv3); // 5. tv5 = u * tv3\n tv5 = Fp.pow(tv5, c3); // 6. tv5 = tv5^c3\n tv5 = Fp.mul(tv5, tv2); // 7. tv5 = tv5 * tv2\n tv2 = Fp.mul(tv5, v); // 8. tv2 = tv5 * v\n tv3 = Fp.mul(tv5, u); // 9. tv3 = tv5 * u\n let tv4 = Fp.mul(tv3, tv2); // 10. tv4 = tv3 * tv2\n tv5 = Fp.pow(tv4, c5); // 11. tv5 = tv4^c5\n let isQR = Fp.eql(tv5, Fp.ONE); // 12. isQR = tv5 == 1\n tv2 = Fp.mul(tv3, c7); // 13. tv2 = tv3 * c7\n tv5 = Fp.mul(tv4, tv1); // 14. tv5 = tv4 * tv1\n tv3 = Fp.cmov(tv2, tv3, isQR); // 15. tv3 = CMOV(tv2, tv3, isQR)\n tv4 = Fp.cmov(tv5, tv4, isQR); // 16. tv4 = CMOV(tv5, tv4, isQR)\n // 17. for i in (c1, c1 - 1, ..., 2):\n for (let i = c1; i > _1n; i--) {\n let tv5 = i - _2n; // 18. tv5 = i - 2\n tv5 = _2n << (tv5 - _1n); // 19. tv5 = 2^tv5\n let tvv5 = Fp.pow(tv4, tv5); // 20. tv5 = tv4^tv5\n const e1 = Fp.eql(tvv5, Fp.ONE); // 21. e1 = tv5 == 1\n tv2 = Fp.mul(tv3, tv1); // 22. tv2 = tv3 * tv1\n tv1 = Fp.mul(tv1, tv1); // 23. tv1 = tv1 * tv1\n tvv5 = Fp.mul(tv4, tv1); // 24. tv5 = tv4 * tv1\n tv3 = Fp.cmov(tv2, tv3, e1); // 25. tv3 = CMOV(tv2, tv3, e1)\n tv4 = Fp.cmov(tvv5, tv4, e1); // 26. tv4 = CMOV(tv5, tv4, e1)\n }\n return { isValid: isQR, value: tv3 };\n };\n if (Fp.ORDER % _4n === _3n) {\n // sqrt_ratio_3mod4(u, v)\n const c1 = (Fp.ORDER - _3n) / _4n; // 1. c1 = (q - 3) / 4 # Integer arithmetic\n const c2 = Fp.sqrt(Fp.neg(Z)); // 2. c2 = sqrt(-Z)\n sqrtRatio = (u, v) => {\n let tv1 = Fp.sqr(v); // 1. tv1 = v^2\n const tv2 = Fp.mul(u, v); // 2. tv2 = u * v\n tv1 = Fp.mul(tv1, tv2); // 3. tv1 = tv1 * tv2\n let y1 = Fp.pow(tv1, c1); // 4. y1 = tv1^c1\n y1 = Fp.mul(y1, tv2); // 5. y1 = y1 * tv2\n const y2 = Fp.mul(y1, c2); // 6. y2 = y1 * c2\n const tv3 = Fp.mul(Fp.sqr(y1), v); // 7. tv3 = y1^2; 8. tv3 = tv3 * v\n const isQR = Fp.eql(tv3, u); // 9. isQR = tv3 == u\n let y = Fp.cmov(y2, y1, isQR); // 10. y = CMOV(y2, y1, isQR)\n return { isValid: isQR, value: y }; // 11. return (isQR, y) isQR ? y : y*c2\n };\n }\n // No curves uses that\n // if (Fp.ORDER % _8n === _5n) // sqrt_ratio_5mod8\n return sqrtRatio;\n}\n/**\n * Simplified Shallue-van de Woestijne-Ulas Method\n * https://www.rfc-editor.org/rfc/rfc9380#section-6.6.2\n */\nexport function mapToCurveSimpleSWU(Fp, opts) {\n validateField(Fp);\n const { A, B, Z } = opts;\n if (!Fp.isValid(A) || !Fp.isValid(B) || !Fp.isValid(Z))\n throw new Error('mapToCurveSimpleSWU: invalid opts');\n const sqrtRatio = SWUFpSqrtRatio(Fp, Z);\n if (!Fp.isOdd)\n throw new Error('Field does not have .isOdd()');\n // Input: u, an element of F.\n // Output: (x, y), a point on E.\n return (u) => {\n // prettier-ignore\n let tv1, tv2, tv3, tv4, tv5, tv6, x, y;\n tv1 = Fp.sqr(u); // 1. tv1 = u^2\n tv1 = Fp.mul(tv1, Z); // 2. tv1 = Z * tv1\n tv2 = Fp.sqr(tv1); // 3. tv2 = tv1^2\n tv2 = Fp.add(tv2, tv1); // 4. tv2 = tv2 + tv1\n tv3 = Fp.add(tv2, Fp.ONE); // 5. tv3 = tv2 + 1\n tv3 = Fp.mul(tv3, B); // 6. tv3 = B * tv3\n tv4 = Fp.cmov(Z, Fp.neg(tv2), !Fp.eql(tv2, Fp.ZERO)); // 7. tv4 = CMOV(Z, -tv2, tv2 != 0)\n tv4 = Fp.mul(tv4, A); // 8. tv4 = A * tv4\n tv2 = Fp.sqr(tv3); // 9. tv2 = tv3^2\n tv6 = Fp.sqr(tv4); // 10. tv6 = tv4^2\n tv5 = Fp.mul(tv6, A); // 11. tv5 = A * tv6\n tv2 = Fp.add(tv2, tv5); // 12. tv2 = tv2 + tv5\n tv2 = Fp.mul(tv2, tv3); // 13. tv2 = tv2 * tv3\n tv6 = Fp.mul(tv6, tv4); // 14. tv6 = tv6 * tv4\n tv5 = Fp.mul(tv6, B); // 15. tv5 = B * tv6\n tv2 = Fp.add(tv2, tv5); // 16. tv2 = tv2 + tv5\n x = Fp.mul(tv1, tv3); // 17. x = tv1 * tv3\n const { isValid, value } = sqrtRatio(tv2, tv6); // 18. (is_gx1_square, y1) = sqrt_ratio(tv2, tv6)\n y = Fp.mul(tv1, u); // 19. y = tv1 * u -> Z * u^3 * y1\n y = Fp.mul(y, value); // 20. y = y * y1\n x = Fp.cmov(x, tv3, isValid); // 21. x = CMOV(x, tv3, is_gx1_square)\n y = Fp.cmov(y, value, isValid); // 22. y = CMOV(y, y1, is_gx1_square)\n const e1 = Fp.isOdd(u) === Fp.isOdd(y); // 23. e1 = sgn0(u) == sgn0(y)\n y = Fp.cmov(Fp.neg(y), y, e1); // 24. y = CMOV(-y, y, e1)\n const tv4_inv = FpInvertBatch(Fp, [tv4], true)[0];\n x = Fp.mul(x, tv4_inv); // 25. x = x / tv4\n return { x, y };\n };\n}\nfunction getWLengths(Fp, Fn) {\n return {\n secretKey: Fn.BYTES,\n publicKey: 1 + Fp.BYTES,\n publicKeyUncompressed: 1 + 2 * Fp.BYTES,\n publicKeyHasPrefix: true,\n signature: 2 * Fn.BYTES,\n };\n}\n/**\n * Sometimes users only need getPublicKey, getSharedSecret, and secret key handling.\n * This helper ensures no signature functionality is present. Less code, smaller bundle size.\n */\nexport function ecdh(Point, ecdhOpts = {}) {\n const { Fn } = Point;\n const randomBytes_ = ecdhOpts.randomBytes || randomBytesWeb;\n const lengths = Object.assign(getWLengths(Point.Fp, Fn), { seed: getMinHashLength(Fn.ORDER) });\n function isValidSecretKey(secretKey) {\n try {\n return !!_normFnElement(Fn, secretKey);\n }\n catch (error) {\n return false;\n }\n }\n function isValidPublicKey(publicKey, isCompressed) {\n const { publicKey: comp, publicKeyUncompressed } = lengths;\n try {\n const l = publicKey.length;\n if (isCompressed === true && l !== comp)\n return false;\n if (isCompressed === false && l !== publicKeyUncompressed)\n return false;\n return !!Point.fromBytes(publicKey);\n }\n catch (error) {\n return false;\n }\n }\n /**\n * Produces cryptographically secure secret key from random of size\n * (groupLen + ceil(groupLen / 2)) with modulo bias being negligible.\n */\n function randomSecretKey(seed = randomBytes_(lengths.seed)) {\n return mapHashToField(abytes(seed, lengths.seed, 'seed'), Fn.ORDER);\n }\n /**\n * Computes public key for a secret key. Checks for validity of the secret key.\n * @param isCompressed whether to return compact (default), or full key\n * @returns Public key, full when isCompressed=false; short when isCompressed=true\n */\n function getPublicKey(secretKey, isCompressed = true) {\n return Point.BASE.multiply(_normFnElement(Fn, secretKey)).toBytes(isCompressed);\n }\n function keygen(seed) {\n const secretKey = randomSecretKey(seed);\n return { secretKey, publicKey: getPublicKey(secretKey) };\n }\n /**\n * Quick and dirty check for item being public key. Does not validate hex, or being on-curve.\n */\n function isProbPub(item) {\n if (typeof item === 'bigint')\n return false;\n if (item instanceof Point)\n return true;\n const { secretKey, publicKey, publicKeyUncompressed } = lengths;\n if (Fn.allowedLengths || secretKey === publicKey)\n return undefined;\n const l = ensureBytes('key', item).length;\n return l === publicKey || l === publicKeyUncompressed;\n }\n /**\n * ECDH (Elliptic Curve Diffie Hellman).\n * Computes shared public key from secret key A and public key B.\n * Checks: 1) secret key validity 2) shared key is on-curve.\n * Does NOT hash the result.\n * @param isCompressed whether to return compact (default), or full key\n * @returns shared public key\n */\n function getSharedSecret(secretKeyA, publicKeyB, isCompressed = true) {\n if (isProbPub(secretKeyA) === true)\n throw new Error('first arg must be private key');\n if (isProbPub(publicKeyB) === false)\n throw new Error('second arg must be public key');\n const s = _normFnElement(Fn, secretKeyA);\n const b = Point.fromHex(publicKeyB); // checks for being on-curve\n return b.multiply(s).toBytes(isCompressed);\n }\n const utils = {\n isValidSecretKey,\n isValidPublicKey,\n randomSecretKey,\n // TODO: remove\n isValidPrivateKey: isValidSecretKey,\n randomPrivateKey: randomSecretKey,\n normPrivateKeyToScalar: (key) => _normFnElement(Fn, key),\n precompute(windowSize = 8, point = Point.BASE) {\n return point.precompute(windowSize, false);\n },\n };\n return Object.freeze({ getPublicKey, getSharedSecret, keygen, Point, utils, lengths });\n}\n/**\n * Creates ECDSA signing interface for given elliptic curve `Point` and `hash` function.\n * We need `hash` for 2 features:\n * 1. Message prehash-ing. NOT used if `sign` / `verify` are called with `prehash: false`\n * 2. k generation in `sign`, using HMAC-drbg(hash)\n *\n * ECDSAOpts are only rarely needed.\n *\n * @example\n * ```js\n * const p256_Point = weierstrass(...);\n * const p256_sha256 = ecdsa(p256_Point, sha256);\n * const p256_sha224 = ecdsa(p256_Point, sha224);\n * const p256_sha224_r = ecdsa(p256_Point, sha224, { randomBytes: (length) => { ... } });\n * ```\n */\nexport function ecdsa(Point, hash, ecdsaOpts = {}) {\n ahash(hash);\n _validateObject(ecdsaOpts, {}, {\n hmac: 'function',\n lowS: 'boolean',\n randomBytes: 'function',\n bits2int: 'function',\n bits2int_modN: 'function',\n });\n const randomBytes = ecdsaOpts.randomBytes || randomBytesWeb;\n const hmac = ecdsaOpts.hmac ||\n ((key, ...msgs) => nobleHmac(hash, key, concatBytes(...msgs)));\n const { Fp, Fn } = Point;\n const { ORDER: CURVE_ORDER, BITS: fnBits } = Fn;\n const { keygen, getPublicKey, getSharedSecret, utils, lengths } = ecdh(Point, ecdsaOpts);\n const defaultSigOpts = {\n prehash: false,\n lowS: typeof ecdsaOpts.lowS === 'boolean' ? ecdsaOpts.lowS : false,\n format: undefined, //'compact' as ECDSASigFormat,\n extraEntropy: false,\n };\n const defaultSigOpts_format = 'compact';\n function isBiggerThanHalfOrder(number) {\n const HALF = CURVE_ORDER >> _1n;\n return number > HALF;\n }\n function validateRS(title, num) {\n if (!Fn.isValidNot0(num))\n throw new Error(`invalid signature ${title}: out of range 1..Point.Fn.ORDER`);\n return num;\n }\n function validateSigLength(bytes, format) {\n validateSigFormat(format);\n const size = lengths.signature;\n const sizer = format === 'compact' ? size : format === 'recovered' ? size + 1 : undefined;\n return abytes(bytes, sizer, `${format} signature`);\n }\n /**\n * ECDSA signature with its (r, s) properties. Supports compact, recovered & DER representations.\n */\n class Signature {\n constructor(r, s, recovery) {\n this.r = validateRS('r', r); // r in [1..N-1];\n this.s = validateRS('s', s); // s in [1..N-1];\n if (recovery != null)\n this.recovery = recovery;\n Object.freeze(this);\n }\n static fromBytes(bytes, format = defaultSigOpts_format) {\n validateSigLength(bytes, format);\n let recid;\n if (format === 'der') {\n const { r, s } = DER.toSig(abytes(bytes));\n return new Signature(r, s);\n }\n if (format === 'recovered') {\n recid = bytes[0];\n format = 'compact';\n bytes = bytes.subarray(1);\n }\n const L = Fn.BYTES;\n const r = bytes.subarray(0, L);\n const s = bytes.subarray(L, L * 2);\n return new Signature(Fn.fromBytes(r), Fn.fromBytes(s), recid);\n }\n static fromHex(hex, format) {\n return this.fromBytes(hexToBytes(hex), format);\n }\n addRecoveryBit(recovery) {\n return new Signature(this.r, this.s, recovery);\n }\n recoverPublicKey(messageHash) {\n const FIELD_ORDER = Fp.ORDER;\n const { r, s, recovery: rec } = this;\n if (rec == null || ![0, 1, 2, 3].includes(rec))\n throw new Error('recovery id invalid');\n // ECDSA recovery is hard for cofactor > 1 curves.\n // In sign, `r = q.x mod n`, and here we recover q.x from r.\n // While recovering q.x >= n, we need to add r+n for cofactor=1 curves.\n // However, for cofactor>1, r+n may not get q.x:\n // r+n*i would need to be done instead where i is unknown.\n // To easily get i, we either need to:\n // a. increase amount of valid recid values (4, 5...); OR\n // b. prohibit non-prime-order signatures (recid > 1).\n const hasCofactor = CURVE_ORDER * _2n < FIELD_ORDER;\n if (hasCofactor && rec > 1)\n throw new Error('recovery id is ambiguous for h>1 curve');\n const radj = rec === 2 || rec === 3 ? r + CURVE_ORDER : r;\n if (!Fp.isValid(radj))\n throw new Error('recovery id 2 or 3 invalid');\n const x = Fp.toBytes(radj);\n const R = Point.fromBytes(concatBytes(pprefix((rec & 1) === 0), x));\n const ir = Fn.inv(radj); // r^-1\n const h = bits2int_modN(ensureBytes('msgHash', messageHash)); // Truncate hash\n const u1 = Fn.create(-h * ir); // -hr^-1\n const u2 = Fn.create(s * ir); // sr^-1\n // (sr^-1)R-(hr^-1)G = -(hr^-1)G + (sr^-1). unsafe is fine: there is no private data.\n const Q = Point.BASE.multiplyUnsafe(u1).add(R.multiplyUnsafe(u2));\n if (Q.is0())\n throw new Error('point at infinify');\n Q.assertValidity();\n return Q;\n }\n // Signatures should be low-s, to prevent malleability.\n hasHighS() {\n return isBiggerThanHalfOrder(this.s);\n }\n toBytes(format = defaultSigOpts_format) {\n validateSigFormat(format);\n if (format === 'der')\n return hexToBytes(DER.hexFromSig(this));\n const r = Fn.toBytes(this.r);\n const s = Fn.toBytes(this.s);\n if (format === 'recovered') {\n if (this.recovery == null)\n throw new Error('recovery bit must be present');\n return concatBytes(Uint8Array.of(this.recovery), r, s);\n }\n return concatBytes(r, s);\n }\n toHex(format) {\n return bytesToHex(this.toBytes(format));\n }\n // TODO: remove\n assertValidity() { }\n static fromCompact(hex) {\n return Signature.fromBytes(ensureBytes('sig', hex), 'compact');\n }\n static fromDER(hex) {\n return Signature.fromBytes(ensureBytes('sig', hex), 'der');\n }\n normalizeS() {\n return this.hasHighS() ? new Signature(this.r, Fn.neg(this.s), this.recovery) : this;\n }\n toDERRawBytes() {\n return this.toBytes('der');\n }\n toDERHex() {\n return bytesToHex(this.toBytes('der'));\n }\n toCompactRawBytes() {\n return this.toBytes('compact');\n }\n toCompactHex() {\n return bytesToHex(this.toBytes('compact'));\n }\n }\n // RFC6979: ensure ECDSA msg is X bytes and < N. RFC suggests optional truncating via bits2octets.\n // FIPS 186-4 4.6 suggests the leftmost min(nBitLen, outLen) bits, which matches bits2int.\n // bits2int can produce res>N, we can do mod(res, N) since the bitLen is the same.\n // int2octets can't be used; pads small msgs with 0: unacceptatble for trunc as per RFC vectors\n const bits2int = ecdsaOpts.bits2int ||\n function bits2int_def(bytes) {\n // Our custom check \"just in case\", for protection against DoS\n if (bytes.length > 8192)\n throw new Error('input is too large');\n // For curves with nBitLength % 8 !== 0: bits2octets(bits2octets(m)) !== bits2octets(m)\n // for some cases, since bytes.length * 8 is not actual bitLength.\n const num = bytesToNumberBE(bytes); // check for == u8 done here\n const delta = bytes.length * 8 - fnBits; // truncate to nBitLength leftmost bits\n return delta > 0 ? num >> BigInt(delta) : num;\n };\n const bits2int_modN = ecdsaOpts.bits2int_modN ||\n function bits2int_modN_def(bytes) {\n return Fn.create(bits2int(bytes)); // can't use bytesToNumberBE here\n };\n // Pads output with zero as per spec\n const ORDER_MASK = bitMask(fnBits);\n /** Converts to bytes. Checks if num in `[0..ORDER_MASK-1]` e.g.: `[0..2^256-1]`. */\n function int2octets(num) {\n // IMPORTANT: the check ensures working for case `Fn.BYTES != Fn.BITS * 8`\n aInRange('num < 2^' + fnBits, num, _0n, ORDER_MASK);\n return Fn.toBytes(num);\n }\n function validateMsgAndHash(message, prehash) {\n abytes(message, undefined, 'message');\n return prehash ? abytes(hash(message), undefined, 'prehashed message') : message;\n }\n /**\n * Steps A, D of RFC6979 3.2.\n * Creates RFC6979 seed; converts msg/privKey to numbers.\n * Used only in sign, not in verify.\n *\n * Warning: we cannot assume here that message has same amount of bytes as curve order,\n * this will be invalid at least for P521. Also it can be bigger for P224 + SHA256.\n */\n function prepSig(message, privateKey, opts) {\n if (['recovered', 'canonical'].some((k) => k in opts))\n throw new Error('sign() legacy options not supported');\n const { lowS, prehash, extraEntropy } = validateSigOpts(opts, defaultSigOpts);\n message = validateMsgAndHash(message, prehash); // RFC6979 3.2 A: h1 = H(m)\n // We can't later call bits2octets, since nested bits2int is broken for curves\n // with fnBits % 8 !== 0. Because of that, we unwrap it here as int2octets call.\n // const bits2octets = (bits) => int2octets(bits2int_modN(bits))\n const h1int = bits2int_modN(message);\n const d = _normFnElement(Fn, privateKey); // validate secret key, convert to bigint\n const seedArgs = [int2octets(d), int2octets(h1int)];\n // extraEntropy. RFC6979 3.6: additional k' (optional).\n if (extraEntropy != null && extraEntropy !== false) {\n // K = HMAC_K(V || 0x00 || int2octets(x) || bits2octets(h1) || k')\n // gen random bytes OR pass as-is\n const e = extraEntropy === true ? randomBytes(lengths.secretKey) : extraEntropy;\n seedArgs.push(ensureBytes('extraEntropy', e)); // check for being bytes\n }\n const seed = concatBytes(...seedArgs); // Step D of RFC6979 3.2\n const m = h1int; // NOTE: no need to call bits2int second time here, it is inside truncateHash!\n // Converts signature params into point w r/s, checks result for validity.\n // To transform k => Signature:\n // q = k⋅G\n // r = q.x mod n\n // s = k^-1(m + rd) mod n\n // Can use scalar blinding b^-1(bm + bdr) where b ∈ [1,q−1] according to\n // https://tches.iacr.org/index.php/TCHES/article/view/7337/6509. We've decided against it:\n // a) dependency on CSPRNG b) 15% slowdown c) doesn't really help since bigints are not CT\n function k2sig(kBytes) {\n // RFC 6979 Section 3.2, step 3: k = bits2int(T)\n // Important: all mod() calls here must be done over N\n const k = bits2int(kBytes); // mod n, not mod p\n if (!Fn.isValidNot0(k))\n return; // Valid scalars (including k) must be in 1..N-1\n const ik = Fn.inv(k); // k^-1 mod n\n const q = Point.BASE.multiply(k).toAffine(); // q = k⋅G\n const r = Fn.create(q.x); // r = q.x mod n\n if (r === _0n)\n return;\n const s = Fn.create(ik * Fn.create(m + r * d)); // Not using blinding here, see comment above\n if (s === _0n)\n return;\n let recovery = (q.x === r ? 0 : 2) | Number(q.y & _1n); // recovery bit (2 or 3, when q.x > n)\n let normS = s;\n if (lowS && isBiggerThanHalfOrder(s)) {\n normS = Fn.neg(s); // if lowS was passed, ensure s is always\n recovery ^= 1; // // in the bottom half of N\n }\n return new Signature(r, normS, recovery); // use normS, not s\n }\n return { seed, k2sig };\n }\n /**\n * Signs message hash with a secret key.\n *\n * ```\n * sign(m, d) where\n * k = rfc6979_hmac_drbg(m, d)\n * (x, y) = G × k\n * r = x mod n\n * s = (m + dr) / k mod n\n * ```\n */\n function sign(message, secretKey, opts = {}) {\n message = ensureBytes('message', message);\n const { seed, k2sig } = prepSig(message, secretKey, opts); // Steps A, D of RFC6979 3.2.\n const drbg = createHmacDrbg(hash.outputLen, Fn.BYTES, hmac);\n const sig = drbg(seed, k2sig); // Steps B, C, D, E, F, G\n return sig;\n }\n function tryParsingSig(sg) {\n // Try to deduce format\n let sig = undefined;\n const isHex = typeof sg === 'string' || isBytes(sg);\n const isObj = !isHex &&\n sg !== null &&\n typeof sg === 'object' &&\n typeof sg.r === 'bigint' &&\n typeof sg.s === 'bigint';\n if (!isHex && !isObj)\n throw new Error('invalid signature, expected Uint8Array, hex string or Signature instance');\n if (isObj) {\n sig = new Signature(sg.r, sg.s);\n }\n else if (isHex) {\n try {\n sig = Signature.fromBytes(ensureBytes('sig', sg), 'der');\n }\n catch (derError) {\n if (!(derError instanceof DER.Err))\n throw derError;\n }\n if (!sig) {\n try {\n sig = Signature.fromBytes(ensureBytes('sig', sg), 'compact');\n }\n catch (error) {\n return false;\n }\n }\n }\n if (!sig)\n return false;\n return sig;\n }\n /**\n * Verifies a signature against message and public key.\n * Rejects lowS signatures by default: see {@link ECDSAVerifyOpts}.\n * Implements section 4.1.4 from https://www.secg.org/sec1-v2.pdf:\n *\n * ```\n * verify(r, s, h, P) where\n * u1 = hs^-1 mod n\n * u2 = rs^-1 mod n\n * R = u1⋅G + u2⋅P\n * mod(R.x, n) == r\n * ```\n */\n function verify(signature, message, publicKey, opts = {}) {\n const { lowS, prehash, format } = validateSigOpts(opts, defaultSigOpts);\n publicKey = ensureBytes('publicKey', publicKey);\n message = validateMsgAndHash(ensureBytes('message', message), prehash);\n if ('strict' in opts)\n throw new Error('options.strict was renamed to lowS');\n const sig = format === undefined\n ? tryParsingSig(signature)\n : Signature.fromBytes(ensureBytes('sig', signature), format);\n if (sig === false)\n return false;\n try {\n const P = Point.fromBytes(publicKey);\n if (lowS && sig.hasHighS())\n return false;\n const { r, s } = sig;\n const h = bits2int_modN(message); // mod n, not mod p\n const is = Fn.inv(s); // s^-1 mod n\n const u1 = Fn.create(h * is); // u1 = hs^-1 mod n\n const u2 = Fn.create(r * is); // u2 = rs^-1 mod n\n const R = Point.BASE.multiplyUnsafe(u1).add(P.multiplyUnsafe(u2)); // u1⋅G + u2⋅P\n if (R.is0())\n return false;\n const v = Fn.create(R.x); // v = r.x mod n\n return v === r;\n }\n catch (e) {\n return false;\n }\n }\n function recoverPublicKey(signature, message, opts = {}) {\n const { prehash } = validateSigOpts(opts, defaultSigOpts);\n message = validateMsgAndHash(message, prehash);\n return Signature.fromBytes(signature, 'recovered').recoverPublicKey(message).toBytes();\n }\n return Object.freeze({\n keygen,\n getPublicKey,\n getSharedSecret,\n utils,\n lengths,\n Point,\n sign,\n verify,\n recoverPublicKey,\n Signature,\n hash,\n });\n}\n/** @deprecated use `weierstrass` in newer releases */\nexport function weierstrassPoints(c) {\n const { CURVE, curveOpts } = _weierstrass_legacy_opts_to_new(c);\n const Point = weierstrassN(CURVE, curveOpts);\n return _weierstrass_new_output_to_legacy(c, Point);\n}\nfunction _weierstrass_legacy_opts_to_new(c) {\n const CURVE = {\n a: c.a,\n b: c.b,\n p: c.Fp.ORDER,\n n: c.n,\n h: c.h,\n Gx: c.Gx,\n Gy: c.Gy,\n };\n const Fp = c.Fp;\n let allowedLengths = c.allowedPrivateKeyLengths\n ? Array.from(new Set(c.allowedPrivateKeyLengths.map((l) => Math.ceil(l / 2))))\n : undefined;\n const Fn = Field(CURVE.n, {\n BITS: c.nBitLength,\n allowedLengths: allowedLengths,\n modFromBytes: c.wrapPrivateKey,\n });\n const curveOpts = {\n Fp,\n Fn,\n allowInfinityPoint: c.allowInfinityPoint,\n endo: c.endo,\n isTorsionFree: c.isTorsionFree,\n clearCofactor: c.clearCofactor,\n fromBytes: c.fromBytes,\n toBytes: c.toBytes,\n };\n return { CURVE, curveOpts };\n}\nfunction _ecdsa_legacy_opts_to_new(c) {\n const { CURVE, curveOpts } = _weierstrass_legacy_opts_to_new(c);\n const ecdsaOpts = {\n hmac: c.hmac,\n randomBytes: c.randomBytes,\n lowS: c.lowS,\n bits2int: c.bits2int,\n bits2int_modN: c.bits2int_modN,\n };\n return { CURVE, curveOpts, hash: c.hash, ecdsaOpts };\n}\nexport function _legacyHelperEquat(Fp, a, b) {\n /**\n * y² = x³ + ax + b: Short weierstrass curve formula. Takes x, returns y².\n * @returns y²\n */\n function weierstrassEquation(x) {\n const x2 = Fp.sqr(x); // x * x\n const x3 = Fp.mul(x2, x); // x² * x\n return Fp.add(Fp.add(x3, Fp.mul(x, a)), b); // x³ + a * x + b\n }\n return weierstrassEquation;\n}\nfunction _weierstrass_new_output_to_legacy(c, Point) {\n const { Fp, Fn } = Point;\n function isWithinCurveOrder(num) {\n return inRange(num, _1n, Fn.ORDER);\n }\n const weierstrassEquation = _legacyHelperEquat(Fp, c.a, c.b);\n return Object.assign({}, {\n CURVE: c,\n Point: Point,\n ProjectivePoint: Point,\n normPrivateKeyToScalar: (key) => _normFnElement(Fn, key),\n weierstrassEquation,\n isWithinCurveOrder,\n });\n}\nfunction _ecdsa_new_output_to_legacy(c, _ecdsa) {\n const Point = _ecdsa.Point;\n return Object.assign({}, _ecdsa, {\n ProjectivePoint: Point,\n CURVE: Object.assign({}, c, nLength(Point.Fn.ORDER, Point.Fn.BITS)),\n });\n}\n// _ecdsa_legacy\nexport function weierstrass(c) {\n const { CURVE, curveOpts, hash, ecdsaOpts } = _ecdsa_legacy_opts_to_new(c);\n const Point = weierstrassN(CURVE, curveOpts);\n const signs = ecdsa(Point, hash, ecdsaOpts);\n return _ecdsa_new_output_to_legacy(c, signs);\n}\n//# sourceMappingURL=weierstrass.js.map","/**\n * Utilities for short weierstrass curves, combined with noble-hashes.\n * @module\n */\n/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */\nimport { weierstrass } from \"./abstract/weierstrass.js\";\n/** connects noble-curves to noble-hashes */\nexport function getHash(hash) {\n return { hash };\n}\n/** @deprecated use new `weierstrass()` and `ecdsa()` methods */\nexport function createCurve(curveDef, defHash) {\n const create = (hash) => weierstrass({ ...curveDef, hash: hash });\n return { ...create(defHash), create };\n}\n//# sourceMappingURL=_shortw_utils.js.map","import { secp256k1 } from '@noble/curves/secp256k1';\nimport * as Bytes from './Bytes.js';\nimport * as Errors from './Errors.js';\nimport * as Hex from './Hex.js';\nimport * as Json from './Json.js';\nimport * as Solidity from './Solidity.js';\n/**\n * Asserts that a Signature is valid.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * Signature.assert({\n * r: -49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * yParity: 1,\n * })\n * // @error: InvalidSignatureRError:\n * // @error: Value `-549...n` is an invalid r value.\n * // @error: r must be a positive integer less than 2^256.\n * ```\n *\n * @param signature - The signature object to assert.\n */\nexport function assert(signature, options = {}) {\n const { recovered } = options;\n if (typeof signature.r === 'undefined')\n throw new MissingPropertiesError({ signature });\n if (typeof signature.s === 'undefined')\n throw new MissingPropertiesError({ signature });\n if (recovered && typeof signature.yParity === 'undefined')\n throw new MissingPropertiesError({ signature });\n if (signature.r < 0n || signature.r > Solidity.maxUint256)\n throw new InvalidRError({ value: signature.r });\n if (signature.s < 0n || signature.s > Solidity.maxUint256)\n throw new InvalidSError({ value: signature.s });\n if (typeof signature.yParity === 'number' &&\n signature.yParity !== 0 &&\n signature.yParity !== 1)\n throw new InvalidYParityError({ value: signature.yParity });\n}\n/**\n * Deserializes a {@link ox#Bytes.Bytes} signature into a structured {@link ox#Signature.Signature}.\n *\n * @example\n * ```ts twoslash\n * // @noErrors\n * import { Signature } from 'ox'\n *\n * Signature.fromBytes(new Uint8Array([128, 3, 131, ...]))\n * // @log: { r: 5231...n, s: 3522...n, yParity: 0 }\n * ```\n *\n * @param signature - The serialized signature.\n * @returns The deserialized {@link ox#Signature.Signature}.\n */\nexport function fromBytes(signature) {\n return fromHex(Hex.fromBytes(signature));\n}\n/**\n * Deserializes a {@link ox#Hex.Hex} signature into a structured {@link ox#Signature.Signature}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * Signature.fromHex('0x6e100a352ec6ad1b70802290e18aeed190704973570f3b8ed42cb9808e2ea6bf4a90a229a244495b41890987806fcbd2d5d23fc0dbe5f5256c2613c039d76db81c')\n * // @log: { r: 5231...n, s: 3522...n, yParity: 0 }\n * ```\n *\n * @param serialized - The serialized signature.\n * @returns The deserialized {@link ox#Signature.Signature}.\n */\nexport function fromHex(signature) {\n if (signature.length !== 130 && signature.length !== 132)\n throw new InvalidSerializedSizeError({ signature });\n const r = BigInt(Hex.slice(signature, 0, 32));\n const s = BigInt(Hex.slice(signature, 32, 64));\n const yParity = (() => {\n const yParity = Number(`0x${signature.slice(130)}`);\n if (Number.isNaN(yParity))\n return undefined;\n try {\n return vToYParity(yParity);\n }\n catch {\n throw new InvalidYParityError({ value: yParity });\n }\n })();\n if (typeof yParity === 'undefined')\n return {\n r,\n s,\n };\n return {\n r,\n s,\n yParity,\n };\n}\n/**\n * Extracts a {@link ox#Signature.Signature} from an arbitrary object that may include signature properties.\n *\n * @example\n * ```ts twoslash\n * // @noErrors\n * import { Signature } from 'ox'\n *\n * Signature.extract({\n * baz: 'barry',\n * foo: 'bar',\n * r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * yParity: 1,\n * zebra: 'stripes',\n * })\n * // @log: {\n * // @log: r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * // @log: s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * // @log: yParity: 1\n * // @log: }\n * ```\n *\n * @param value - The arbitrary object to extract the signature from.\n * @returns The extracted {@link ox#Signature.Signature}.\n */\nexport function extract(value) {\n if (typeof value.r === 'undefined')\n return undefined;\n if (typeof value.s === 'undefined')\n return undefined;\n return from(value);\n}\n/**\n * Instantiates a typed {@link ox#Signature.Signature} object from a {@link ox#Signature.Signature}, {@link ox#Signature.Legacy}, {@link ox#Bytes.Bytes}, or {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * Signature.from({\n * r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * yParity: 1,\n * })\n * // @log: {\n * // @log: r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * // @log: s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * // @log: yParity: 1\n * // @log: }\n * ```\n *\n * @example\n * ### From Serialized\n *\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * Signature.from('0x6e100a352ec6ad1b70802290e18aeed190704973570f3b8ed42cb9808e2ea6bf4a90a229a244495b41890987806fcbd2d5d23fc0dbe5f5256c2613c039d76db801')\n * // @log: {\n * // @log: r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * // @log: s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * // @log: yParity: 1,\n * // @log: }\n * ```\n *\n * @example\n * ### From Legacy\n *\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * Signature.from({\n * r: 47323457007453657207889730243826965761922296599680473886588287015755652701072n,\n * s: 57228803202727131502949358313456071280488184270258293674242124340113824882788n,\n * v: 27,\n * })\n * // @log: {\n * // @log: r: 47323457007453657207889730243826965761922296599680473886588287015755652701072n,\n * // @log: s: 57228803202727131502949358313456071280488184270258293674242124340113824882788n,\n * // @log: yParity: 0\n * // @log: }\n * ```\n *\n * @param signature - The signature value to instantiate.\n * @returns The instantiated {@link ox#Signature.Signature}.\n */\nexport function from(signature) {\n const signature_ = (() => {\n if (typeof signature === 'string')\n return fromHex(signature);\n if (signature instanceof Uint8Array)\n return fromBytes(signature);\n if (typeof signature.r === 'string')\n return fromRpc(signature);\n if (signature.v)\n return fromLegacy(signature);\n return {\n r: signature.r,\n s: signature.s,\n ...(typeof signature.yParity !== 'undefined'\n ? { yParity: signature.yParity }\n : {}),\n };\n })();\n assert(signature_);\n return signature_;\n}\n/**\n * Converts a DER-encoded signature to a {@link ox#Signature.Signature}.\n *\n * @example\n * ```ts twoslash\n * // @noErrors\n * import { Signature } from 'ox'\n *\n * const signature = Signature.fromDerBytes(new Uint8Array([132, 51, 23, ...]))\n * // @log: {\n * // @log: r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * // @log: s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * // @log: }\n * ```\n *\n * @param signature - The DER-encoded signature to convert.\n * @returns The {@link ox#Signature.Signature}.\n */\nexport function fromDerBytes(signature) {\n return fromDerHex(Hex.fromBytes(signature));\n}\n/**\n * Converts a DER-encoded signature to a {@link ox#Signature.Signature}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.fromDerHex('0x304402206e100a352ec6ad1b70802290e18aeed190704973570f3b8ed42cb9808e2ea6bf02204a90a229a244495b41890987806fcbd2d5d23fc0dbe5f5256c2613c039d76db8')\n * // @log: {\n * // @log: r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * // @log: s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * // @log: }\n * ```\n *\n * @param signature - The DER-encoded signature to convert.\n * @returns The {@link ox#Signature.Signature}.\n */\nexport function fromDerHex(signature) {\n const { r, s } = secp256k1.Signature.fromDER(Hex.from(signature).slice(2));\n return { r, s };\n}\n/**\n * Converts a {@link ox#Signature.Legacy} into a {@link ox#Signature.Signature}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const legacy = Signature.fromLegacy({ r: 1n, s: 2n, v: 28 })\n * // @log: { r: 1n, s: 2n, yParity: 1 }\n * ```\n *\n * @param signature - The {@link ox#Signature.Legacy} to convert.\n * @returns The converted {@link ox#Signature.Signature}.\n */\nexport function fromLegacy(signature) {\n return {\n r: signature.r,\n s: signature.s,\n yParity: vToYParity(signature.v),\n };\n}\n/**\n * Converts a {@link ox#Signature.Rpc} into a {@link ox#Signature.Signature}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.fromRpc({\n * r: '0x635dc2033e60185bb36709c29c75d64ea51dfbd91c32ef4be198e4ceb169fb4d',\n * s: '0x50c2667ac4c771072746acfdcf1f1483336dcca8bd2df47cd83175dbe60f0540',\n * yParity: '0x0',\n * })\n * ```\n *\n * @param signature - The {@link ox#Signature.Rpc} to convert.\n * @returns The converted {@link ox#Signature.Signature}.\n */\nexport function fromRpc(signature) {\n const yParity = (() => {\n const v = signature.v ? Number(signature.v) : undefined;\n let yParity = signature.yParity ? Number(signature.yParity) : undefined;\n if (typeof v === 'number' && typeof yParity !== 'number')\n yParity = vToYParity(v);\n if (typeof yParity !== 'number')\n throw new InvalidYParityError({ value: signature.yParity });\n return yParity;\n })();\n return {\n r: BigInt(signature.r),\n s: BigInt(signature.s),\n yParity,\n };\n}\n/**\n * Converts a {@link ox#Signature.Tuple} to a {@link ox#Signature.Signature}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.fromTuple(['0x01', '0x7b', '0x1c8'])\n * // @log: {\n * // @log: r: 123n,\n * // @log: s: 456n,\n * // @log: yParity: 1,\n * // @log: }\n * ```\n *\n * @param tuple - The {@link ox#Signature.Tuple} to convert.\n * @returns The {@link ox#Signature.Signature}.\n */\nexport function fromTuple(tuple) {\n const [yParity, r, s] = tuple;\n return from({\n r: r === '0x' ? 0n : BigInt(r),\n s: s === '0x' ? 0n : BigInt(s),\n yParity: yParity === '0x' ? 0 : Number(yParity),\n });\n}\n/**\n * Serializes a {@link ox#Signature.Signature} to {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.toBytes({\n * r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * yParity: 1\n * })\n * // @log: Uint8Array [102, 16, 10, ...]\n * ```\n *\n * @param signature - The signature to serialize.\n * @returns The serialized signature.\n */\nexport function toBytes(signature) {\n return Bytes.fromHex(toHex(signature));\n}\n/**\n * Serializes a {@link ox#Signature.Signature} to {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.toHex({\n * r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * yParity: 1\n * })\n * // @log: '0x6e100a352ec6ad1b70802290e18aeed190704973570f3b8ed42cb9808e2ea6bf4a90a229a244495b41890987806fcbd2d5d23fc0dbe5f5256c2613c039d76db81c'\n * ```\n *\n * @param signature - The signature to serialize.\n * @returns The serialized signature.\n */\nexport function toHex(signature) {\n assert(signature);\n const r = signature.r;\n const s = signature.s;\n const signature_ = Hex.concat(Hex.fromNumber(r, { size: 32 }), Hex.fromNumber(s, { size: 32 }), \n // If the signature is recovered, add the recovery byte to the signature.\n typeof signature.yParity === 'number'\n ? Hex.fromNumber(yParityToV(signature.yParity), { size: 1 })\n : '0x');\n return signature_;\n}\n/**\n * Converts a {@link ox#Signature.Signature} to DER-encoded format.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.from({\n * r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * })\n *\n * const signature_der = Signature.toDerBytes(signature)\n * // @log: Uint8Array [132, 51, 23, ...]\n * ```\n *\n * @param signature - The signature to convert.\n * @returns The DER-encoded signature.\n */\nexport function toDerBytes(signature) {\n const sig = new secp256k1.Signature(signature.r, signature.s);\n return sig.toDERRawBytes();\n}\n/**\n * Converts a {@link ox#Signature.Signature} to DER-encoded format.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.from({\n * r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * })\n *\n * const signature_der = Signature.toDerHex(signature)\n * // @log: '0x304402206e100a352ec6ad1b70802290e18aeed190704973570f3b8ed42cb9808e2ea6bf02204a90a229a244495b41890987806fcbd2d5d23fc0dbe5f5256c2613c039d76db8'\n * ```\n *\n * @param signature - The signature to convert.\n * @returns The DER-encoded signature.\n */\nexport function toDerHex(signature) {\n const sig = new secp256k1.Signature(signature.r, signature.s);\n return `0x${sig.toDERHex()}`;\n}\n/**\n * Converts a {@link ox#Signature.Signature} into a {@link ox#Signature.Legacy}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const legacy = Signature.toLegacy({ r: 1n, s: 2n, yParity: 1 })\n * // @log: { r: 1n, s: 2n, v: 28 }\n * ```\n *\n * @param signature - The {@link ox#Signature.Signature} to convert.\n * @returns The converted {@link ox#Signature.Legacy}.\n */\nexport function toLegacy(signature) {\n return {\n r: signature.r,\n s: signature.s,\n v: yParityToV(signature.yParity),\n };\n}\n/**\n * Converts a {@link ox#Signature.Signature} into a {@link ox#Signature.Rpc}.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signature = Signature.toRpc({\n * r: 49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * yParity: 1\n * })\n * ```\n *\n * @param signature - The {@link ox#Signature.Signature} to convert.\n * @returns The converted {@link ox#Signature.Rpc}.\n */\nexport function toRpc(signature) {\n const { r, s, yParity } = signature;\n return {\n r: Hex.fromNumber(r, { size: 32 }),\n s: Hex.fromNumber(s, { size: 32 }),\n yParity: yParity === 0 ? '0x0' : '0x1',\n };\n}\n/**\n * Converts a {@link ox#Signature.Signature} to a serialized {@link ox#Signature.Tuple} to be used for signatures in Transaction Envelopes, EIP-7702 Authorization Lists, etc.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const signatureTuple = Signature.toTuple({\n * r: 123n,\n * s: 456n,\n * yParity: 1,\n * })\n * // @log: [yParity: '0x01', r: '0x7b', s: '0x1c8']\n * ```\n *\n * @param signature - The {@link ox#Signature.Signature} to convert.\n * @returns The {@link ox#Signature.Tuple}.\n */\nexport function toTuple(signature) {\n const { r, s, yParity } = signature;\n return [\n yParity ? '0x01' : '0x',\n r === 0n ? '0x' : Hex.trimLeft(Hex.fromNumber(r)),\n s === 0n ? '0x' : Hex.trimLeft(Hex.fromNumber(s)),\n ];\n}\n/**\n * Validates a Signature. Returns `true` if the signature is valid, `false` otherwise.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const valid = Signature.validate({\n * r: -49782753348462494199823712700004552394425719014458918871452329774910450607807n,\n * s: 33726695977844476214676913201140481102225469284307016937915595756355928419768n,\n * yParity: 1,\n * })\n * // @log: false\n * ```\n *\n * @param signature - The signature object to assert.\n */\nexport function validate(signature, options = {}) {\n try {\n assert(signature, options);\n return true;\n }\n catch {\n return false;\n }\n}\n/**\n * Converts a ECDSA `v` value to a `yParity` value.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const yParity = Signature.vToYParity(28)\n * // @log: 1\n * ```\n *\n * @param v - The ECDSA `v` value to convert.\n * @returns The `yParity` value.\n */\nexport function vToYParity(v) {\n if (v === 0 || v === 27)\n return 0;\n if (v === 1 || v === 28)\n return 1;\n if (v >= 35)\n return v % 2 === 0 ? 1 : 0;\n throw new InvalidVError({ value: v });\n}\n/**\n * Converts a ECDSA `v` value to a `yParity` value.\n *\n * @example\n * ```ts twoslash\n * import { Signature } from 'ox'\n *\n * const v = Signature.yParityToV(1)\n * // @log: 28\n * ```\n *\n * @param yParity - The ECDSA `yParity` value to convert.\n * @returns The `v` value.\n */\nexport function yParityToV(yParity) {\n if (yParity === 0)\n return 27;\n if (yParity === 1)\n return 28;\n throw new InvalidYParityError({ value: yParity });\n}\n/** Thrown when the serialized signature is of an invalid size. */\nexport class InvalidSerializedSizeError extends Errors.BaseError {\n constructor({ signature }) {\n super(`Value \\`${signature}\\` is an invalid signature size.`, {\n metaMessages: [\n 'Expected: 64 bytes or 65 bytes.',\n `Received ${Hex.size(Hex.from(signature))} bytes.`,\n ],\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Signature.InvalidSerializedSizeError'\n });\n }\n}\n/** Thrown when the signature is missing either an `r`, `s`, or `yParity` property. */\nexport class MissingPropertiesError extends Errors.BaseError {\n constructor({ signature }) {\n super(`Signature \\`${Json.stringify(signature)}\\` is missing either an \\`r\\`, \\`s\\`, or \\`yParity\\` property.`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Signature.MissingPropertiesError'\n });\n }\n}\n/** Thrown when the signature has an invalid `r` value. */\nexport class InvalidRError extends Errors.BaseError {\n constructor({ value }) {\n super(`Value \\`${value}\\` is an invalid r value. r must be a positive integer less than 2^256.`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Signature.InvalidRError'\n });\n }\n}\n/** Thrown when the signature has an invalid `s` value. */\nexport class InvalidSError extends Errors.BaseError {\n constructor({ value }) {\n super(`Value \\`${value}\\` is an invalid s value. s must be a positive integer less than 2^256.`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Signature.InvalidSError'\n });\n }\n}\n/** Thrown when the signature has an invalid `yParity` value. */\nexport class InvalidYParityError extends Errors.BaseError {\n constructor({ value }) {\n super(`Value \\`${value}\\` is an invalid y-parity value. Y-parity must be 0 or 1.`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Signature.InvalidYParityError'\n });\n }\n}\n/** Thrown when the signature has an invalid `v` value. */\nexport class InvalidVError extends Errors.BaseError {\n constructor({ value }) {\n super(`Value \\`${value}\\` is an invalid v value. v must be 27, 28 or >=35.`);\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'Signature.InvalidVError'\n });\n }\n}\n//# sourceMappingURL=Signature.js.map","import * as Bytes from './Bytes.js';\nimport * as Hex from './Hex.js';\nconst encoder = /*#__PURE__*/ new TextEncoder();\nconst decoder = /*#__PURE__*/ new TextDecoder();\nconst integerToCharacter = /*#__PURE__*/ Object.fromEntries(Array.from('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/').map((a, i) => [i, a.charCodeAt(0)]));\nconst characterToInteger = /*#__PURE__*/ {\n ...Object.fromEntries(Array.from('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/').map((a, i) => [a.charCodeAt(0), i])),\n ['='.charCodeAt(0)]: 0,\n ['-'.charCodeAt(0)]: 62,\n ['_'.charCodeAt(0)]: 63,\n};\n/**\n * Encodes a {@link ox#Bytes.Bytes} to a Base64-encoded string (with optional padding and/or URL-safe characters).\n *\n * @example\n * ```ts twoslash\n * import { Base64, Bytes } from 'ox'\n *\n * const value = Base64.fromBytes(Bytes.fromString('hello world'))\n * // @log: 'aGVsbG8gd29ybGQ='\n * ```\n *\n * @example\n * ### No Padding\n *\n * Turn off [padding of encoded data](https://datatracker.ietf.org/doc/html/rfc4648#section-3.2) with the `pad` option:\n *\n * ```ts twoslash\n * import { Base64, Bytes } from 'ox'\n *\n * const value = Base64.fromBytes(Bytes.fromString('hello world'), { pad: false })\n * // @log: 'aGVsbG8gd29ybGQ'\n * ```\n *\n * ### URL-safe Encoding\n *\n * Turn on [URL-safe encoding](https://datatracker.ietf.org/doc/html/rfc4648#section-5) (Base64 URL) with the `url` option:\n *\n * ```ts twoslash\n * import { Base64, Bytes } from 'ox'\n *\n * const value = Base64.fromBytes(Bytes.fromString('hello wod'), { url: true })\n * // @log: 'aGVsbG8gd29_77-9ZA=='\n * ```\n *\n * @param value - The byte array to encode.\n * @param options - Encoding options.\n * @returns The Base64 encoded string.\n */\nexport function fromBytes(value, options = {}) {\n const { pad = true, url = false } = options;\n const encoded = new Uint8Array(Math.ceil(value.length / 3) * 4);\n for (let i = 0, j = 0; j < value.length; i += 4, j += 3) {\n const y = (value[j] << 16) + (value[j + 1] << 8) + (value[j + 2] | 0);\n encoded[i] = integerToCharacter[y >> 18];\n encoded[i + 1] = integerToCharacter[(y >> 12) & 0x3f];\n encoded[i + 2] = integerToCharacter[(y >> 6) & 0x3f];\n encoded[i + 3] = integerToCharacter[y & 0x3f];\n }\n const k = value.length % 3;\n const end = Math.floor(value.length / 3) * 4 + (k && k + 1);\n let base64 = decoder.decode(new Uint8Array(encoded.buffer, 0, end));\n if (pad && k === 1)\n base64 += '==';\n if (pad && k === 2)\n base64 += '=';\n if (url)\n base64 = base64.replaceAll('+', '-').replaceAll('/', '_');\n return base64;\n}\n/**\n * Encodes a {@link ox#Hex.Hex} to a Base64-encoded string (with optional padding and/or URL-safe characters).\n *\n * @example\n * ```ts twoslash\n * import { Base64, Hex } from 'ox'\n *\n * const value = Base64.fromHex(Hex.fromString('hello world'))\n * // @log: 'aGVsbG8gd29ybGQ='\n * ```\n *\n * @example\n * ### No Padding\n *\n * Turn off [padding of encoded data](https://datatracker.ietf.org/doc/html/rfc4648#section-3.2) with the `pad` option:\n *\n * ```ts twoslash\n * import { Base64, Hex } from 'ox'\n *\n * const value = Base64.fromHex(Hex.fromString('hello world'), { pad: false })\n * // @log: 'aGVsbG8gd29ybGQ'\n * ```\n *\n * ### URL-safe Encoding\n *\n * Turn on [URL-safe encoding](https://datatracker.ietf.org/doc/html/rfc4648#section-5) (Base64 URL) with the `url` option:\n *\n * ```ts twoslash\n * import { Base64, Hex } from 'ox'\n *\n * const value = Base64.fromHex(Hex.fromString('hello wod'), { url: true })\n * // @log: 'aGVsbG8gd29_77-9ZA=='\n * ```\n *\n * @param value - The hex value to encode.\n * @param options - Encoding options.\n * @returns The Base64 encoded string.\n */\nexport function fromHex(value, options = {}) {\n return fromBytes(Bytes.fromHex(value), options);\n}\n/**\n * Encodes a string to a Base64-encoded string (with optional padding and/or URL-safe characters).\n *\n * @example\n * ```ts twoslash\n * import { Base64 } from 'ox'\n *\n * const value = Base64.fromString('hello world')\n * // @log: 'aGVsbG8gd29ybGQ='\n * ```\n *\n * @example\n * ### No Padding\n *\n * Turn off [padding of encoded data](https://datatracker.ietf.org/doc/html/rfc4648#section-3.2) with the `pad` option:\n *\n * ```ts twoslash\n * import { Base64 } from 'ox'\n *\n * const value = Base64.fromString('hello world', { pad: false })\n * // @log: 'aGVsbG8gd29ybGQ'\n * ```\n *\n * ### URL-safe Encoding\n *\n * Turn on [URL-safe encoding](https://datatracker.ietf.org/doc/html/rfc4648#section-5) (Base64 URL) with the `url` option:\n *\n * ```ts twoslash\n * import { Base64 } from 'ox'\n *\n * const value = Base64.fromString('hello wod', { url: true })\n * // @log: 'aGVsbG8gd29_77-9ZA=='\n * ```\n *\n * @param value - The string to encode.\n * @param options - Encoding options.\n * @returns The Base64 encoded string.\n */\nexport function fromString(value, options = {}) {\n return fromBytes(Bytes.fromString(value), options);\n}\n/**\n * Decodes a Base64-encoded string (with optional padding and/or URL-safe characters) to {@link ox#Bytes.Bytes}.\n *\n * @example\n * ```ts twoslash\n * import { Base64, Bytes } from 'ox'\n *\n * const value = Base64.toBytes('aGVsbG8gd29ybGQ=')\n * // @log: Uint8Array([104, 101, 108, 108, 111, 32, 119, 111, 114, 108, 100])\n * ```\n *\n * @param value - The string, hex value, or byte array to encode.\n * @returns The Base64 decoded {@link ox#Bytes.Bytes}.\n */\nexport function toBytes(value) {\n const base64 = value.replace(/=+$/, '');\n const size = base64.length;\n const decoded = new Uint8Array(size + 3);\n encoder.encodeInto(base64 + '===', decoded);\n for (let i = 0, j = 0; i < base64.length; i += 4, j += 3) {\n const x = (characterToInteger[decoded[i]] << 18) +\n (characterToInteger[decoded[i + 1]] << 12) +\n (characterToInteger[decoded[i + 2]] << 6) +\n characterToInteger[decoded[i + 3]];\n decoded[j] = x >> 16;\n decoded[j + 1] = (x >> 8) & 0xff;\n decoded[j + 2] = x & 0xff;\n }\n const decodedSize = (size >> 2) * 3 + (size % 4 && (size % 4) - 1);\n return new Uint8Array(decoded.buffer, 0, decodedSize);\n}\n/**\n * Decodes a Base64-encoded string (with optional padding and/or URL-safe characters) to {@link ox#Hex.Hex}.\n *\n * @example\n * ```ts twoslash\n * import { Base64, Hex } from 'ox'\n *\n * const value = Base64.toHex('aGVsbG8gd29ybGQ=')\n * // @log: 0x68656c6c6f20776f726c64\n * ```\n *\n * @param value - The string, hex value, or byte array to encode.\n * @returns The Base64 decoded {@link ox#Hex.Hex}.\n */\nexport function toHex(value) {\n return Hex.fromBytes(toBytes(value));\n}\n/**\n * Decodes a Base64-encoded string (with optional padding and/or URL-safe characters) to a string.\n *\n * @example\n * ```ts twoslash\n * import { Base64 } from 'ox'\n *\n * const value = Base64.toString('aGVsbG8gd29ybGQ=')\n * // @log: 'hello world'\n * ```\n *\n * @param value - The string, hex value, or byte array to encode.\n * @returns The Base64 decoded string.\n */\nexport function toString(value) {\n return Bytes.toString(toBytes(value));\n}\n//# sourceMappingURL=Base64.js.map","/**\n * Internal module for NIST P256, P384, P521 curves.\n * Do not use for now.\n * @module\n */\n/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */\nimport { sha256, sha384, sha512 } from '@noble/hashes/sha2.js';\nimport { createCurve } from \"./_shortw_utils.js\";\nimport { createHasher } from \"./abstract/hash-to-curve.js\";\nimport { Field } from \"./abstract/modular.js\";\nimport { mapToCurveSimpleSWU, } from \"./abstract/weierstrass.js\";\n// p = 2n**224n * (2n**32n-1n) + 2n**192n + 2n**96n - 1n\n// a = Fp256.create(BigInt('-3'));\nconst p256_CURVE = {\n p: BigInt('0xffffffff00000001000000000000000000000000ffffffffffffffffffffffff'),\n n: BigInt('0xffffffff00000000ffffffffffffffffbce6faada7179e84f3b9cac2fc632551'),\n h: BigInt(1),\n a: BigInt('0xffffffff00000001000000000000000000000000fffffffffffffffffffffffc'),\n b: BigInt('0x5ac635d8aa3a93e7b3ebbd55769886bc651d06b0cc53b0f63bce3c3e27d2604b'),\n Gx: BigInt('0x6b17d1f2e12c4247f8bce6e563a440f277037d812deb33a0f4a13945d898c296'),\n Gy: BigInt('0x4fe342e2fe1a7f9b8ee7eb4a7c0f9e162bce33576b315ececbb6406837bf51f5'),\n};\n// p = 2n**384n - 2n**128n - 2n**96n + 2n**32n - 1n\nconst p384_CURVE = {\n p: BigInt('0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000ffffffff'),\n n: BigInt('0xffffffffffffffffffffffffffffffffffffffffffffffffc7634d81f4372ddf581a0db248b0a77aecec196accc52973'),\n h: BigInt(1),\n a: BigInt('0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeffffffff0000000000000000fffffffc'),\n b: BigInt('0xb3312fa7e23ee7e4988e056be3f82d19181d9c6efe8141120314088f5013875ac656398d8a2ed19d2a85c8edd3ec2aef'),\n Gx: BigInt('0xaa87ca22be8b05378eb1c71ef320ad746e1d3b628ba79b9859f741e082542a385502f25dbf55296c3a545e3872760ab7'),\n Gy: BigInt('0x3617de4a96262c6f5d9e98bf9292dc29f8f41dbd289a147ce9da3113b5f0b8c00a60b1ce1d7e819d7a431d7c90ea0e5f'),\n};\n// p = 2n**521n - 1n\nconst p521_CURVE = {\n p: BigInt('0x1ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff'),\n n: BigInt('0x01fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa51868783bf2f966b7fcc0148f709a5d03bb5c9b8899c47aebb6fb71e91386409'),\n h: BigInt(1),\n a: BigInt('0x1fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc'),\n b: BigInt('0x0051953eb9618e1c9a1f929a21a0b68540eea2da725b99b315f3b8b489918ef109e156193951ec7e937b1652c0bd3bb1bf073573df883d2c34f1ef451fd46b503f00'),\n Gx: BigInt('0x00c6858e06b70404e9cd9e3ecb662395b4429c648139053fb521f828af606b4d3dbaa14b5e77efe75928fe1dc127a2ffa8de3348b3c1856a429bf97e7e31c2e5bd66'),\n Gy: BigInt('0x011839296a789a3bc0045c8a5fb42c7d1bd998f54449579b446817afbd17273e662c97ee72995ef42640c550b9013fad0761353c7086a272c24088be94769fd16650'),\n};\nconst Fp256 = Field(p256_CURVE.p);\nconst Fp384 = Field(p384_CURVE.p);\nconst Fp521 = Field(p521_CURVE.p);\nfunction createSWU(Point, opts) {\n const map = mapToCurveSimpleSWU(Point.Fp, opts);\n return (scalars) => map(scalars[0]);\n}\n/** NIST P256 (aka secp256r1, prime256v1) curve, ECDSA and ECDH methods. */\nexport const p256 = createCurve({ ...p256_CURVE, Fp: Fp256, lowS: false }, sha256);\n/** Hashing / encoding to p256 points / field. RFC 9380 methods. */\nexport const p256_hasher = /* @__PURE__ */ (() => {\n return createHasher(p256.Point, createSWU(p256.Point, {\n A: p256_CURVE.a,\n B: p256_CURVE.b,\n Z: p256.Point.Fp.create(BigInt('-10')),\n }), {\n DST: 'P256_XMD:SHA-256_SSWU_RO_',\n encodeDST: 'P256_XMD:SHA-256_SSWU_NU_',\n p: p256_CURVE.p,\n m: 1,\n k: 128,\n expand: 'xmd',\n hash: sha256,\n });\n})();\n// export const p256_oprf: OPRF = createORPF({\n// name: 'P256-SHA256',\n// Point: p256.Point,\n// hash: sha256,\n// hashToGroup: p256_hasher.hashToCurve,\n// hashToScalar: p256_hasher.hashToScalar,\n// });\n/** NIST P384 (aka secp384r1) curve, ECDSA and ECDH methods. */\nexport const p384 = createCurve({ ...p384_CURVE, Fp: Fp384, lowS: false }, sha384);\n/** Hashing / encoding to p384 points / field. RFC 9380 methods. */\nexport const p384_hasher = /* @__PURE__ */ (() => {\n return createHasher(p384.Point, createSWU(p384.Point, {\n A: p384_CURVE.a,\n B: p384_CURVE.b,\n Z: p384.Point.Fp.create(BigInt('-12')),\n }), {\n DST: 'P384_XMD:SHA-384_SSWU_RO_',\n encodeDST: 'P384_XMD:SHA-384_SSWU_NU_',\n p: p384_CURVE.p,\n m: 1,\n k: 192,\n expand: 'xmd',\n hash: sha384,\n });\n})();\n// export const p384_oprf: OPRF = createORPF({\n// name: 'P384-SHA384',\n// Point: p384.Point,\n// hash: sha384,\n// hashToGroup: p384_hasher.hashToCurve,\n// hashToScalar: p384_hasher.hashToScalar,\n// });\n// const Fn521 = Field(p521_CURVE.n, { allowedScalarLengths: [65, 66] });\n/** NIST P521 (aka secp521r1) curve, ECDSA and ECDH methods. */\nexport const p521 = createCurve({ ...p521_CURVE, Fp: Fp521, lowS: false, allowedPrivateKeyLengths: [130, 131, 132] }, sha512);\n/** @deprecated use `p256` for consistency with `p256_hasher` */\nexport const secp256r1 = p256;\n/** @deprecated use `p384` for consistency with `p384_hasher` */\nexport const secp384r1 = p384;\n/** @deprecated use `p521` for consistency with `p521_hasher` */\nexport const secp521r1 = p521;\n/** Hashing / encoding to p521 points / field. RFC 9380 methods. */\nexport const p521_hasher = /* @__PURE__ */ (() => {\n return createHasher(p521.Point, createSWU(p521.Point, {\n A: p521_CURVE.a,\n B: p521_CURVE.b,\n Z: p521.Point.Fp.create(BigInt('-4')),\n }), {\n DST: 'P521_XMD:SHA-512_SSWU_RO_',\n encodeDST: 'P521_XMD:SHA-512_SSWU_NU_',\n p: p521_CURVE.p,\n m: 1,\n k: 256,\n expand: 'xmd',\n hash: sha512,\n });\n})();\n// export const p521_oprf: OPRF = createORPF({\n// name: 'P521-SHA512',\n// Point: p521.Point,\n// hash: sha512,\n// hashToGroup: p521_hasher.hashToCurve,\n// hashToScalar: p521_hasher.hashToScalar, // produces L=98 just like in RFC\n// });\n//# sourceMappingURL=nist.js.map","/**\n * NIST secp256r1 aka p256.\n * @module\n */\n/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */\nimport {} from \"./abstract/hash-to-curve.js\";\nimport { p256_hasher, p256 as p256n } from \"./nist.js\";\n/** @deprecated use `import { p256 } from '@noble/curves/nist.js';` */\nexport const p256 = p256n;\n/** @deprecated use `import { p256 } from '@noble/curves/nist.js';` */\nexport const secp256r1 = p256n;\n/** @deprecated use `import { p256_hasher } from '@noble/curves/nist.js';` */\nexport const hashToCurve = /* @__PURE__ */ (() => p256_hasher.hashToCurve)();\n/** @deprecated use `import { p256_hasher } from '@noble/curves/nist.js';` */\nexport const encodeToCurve = /* @__PURE__ */ (() => p256_hasher.encodeToCurve)();\n//# sourceMappingURL=p256.js.map","import * as Base64 from './Base64.js';\nimport * as Bytes from './Bytes.js';\nimport * as Errors from './Errors.js';\nimport * as Hash from './Hash.js';\nimport * as Hex from './Hex.js';\nimport * as P256 from './P256.js';\nimport * as internal from './internal/webauthn.js';\nexport const createChallenge = Uint8Array.from([\n 105, 171, 180, 181, 160, 222, 75, 198, 42, 42, 32, 31, 141, 37, 186, 233,\n]);\n/**\n * Creates a new WebAuthn P256 Credential, which can be stored and later used for signing.\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256 } from 'ox'\n *\n * const credential = await WebAuthnP256.createCredential({ name: 'Example' }) // [!code focus]\n * // @log: {\n * // @log: id: 'oZ48...',\n * // @log: publicKey: { x: 51421...5123n, y: 12345...6789n },\n * // @log: raw: PublicKeyCredential {},\n * // @log: }\n *\n * const { metadata, signature } = await WebAuthnP256.sign({\n * credentialId: credential.id,\n * challenge: '0xdeadbeef',\n * })\n * ```\n *\n * @param options - Credential creation options.\n * @returns A WebAuthn P256 credential.\n */\nexport async function createCredential(options) {\n const { createFn = window.navigator.credentials.create.bind(window.navigator.credentials), ...rest } = options;\n const creationOptions = getCredentialCreationOptions(rest);\n try {\n const credential = (await createFn(creationOptions));\n if (!credential)\n throw new CredentialCreationFailedError();\n const response = credential.response;\n const publicKey = await internal.parseCredentialPublicKey(response);\n return {\n id: credential.id,\n publicKey,\n raw: credential,\n };\n }\n catch (error) {\n throw new CredentialCreationFailedError({\n cause: error,\n });\n }\n}\n/**\n * Gets the authenticator data which contains information about the\n * processing of an authenticator request (ie. from `WebAuthnP256.sign`).\n *\n * :::warning\n *\n * This function is mainly for testing purposes or for manually constructing\n * autenticator data. In most cases you will not need this function.\n * `authenticatorData` is typically returned as part of the\n * {@link ox#WebAuthnP256.(sign:function)} response (ie. an authenticator response).\n *\n * :::\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256 } from 'ox'\n *\n * const authenticatorData = WebAuthnP256.getAuthenticatorData({\n * rpId: 'example.com',\n * signCount: 420,\n * })\n * // @log: \"0xa379a6f6eeafb9a55e378c118034e2751e682fab9f2d30ab13d2125586ce194705000001a4\"\n * ```\n *\n * @param options - Options to construct the authenticator data.\n * @returns The authenticator data.\n */\nexport function getAuthenticatorData(options = {}) {\n const { flag = 5, rpId = window.location.hostname, signCount = 0 } = options;\n const rpIdHash = Hash.sha256(Hex.fromString(rpId));\n const flag_bytes = Hex.fromNumber(flag, { size: 1 });\n const signCount_bytes = Hex.fromNumber(signCount, { size: 4 });\n return Hex.concat(rpIdHash, flag_bytes, signCount_bytes);\n}\n/**\n * Constructs the Client Data in stringified JSON format which represents client data that\n * was passed to `credentials.get()` in {@link ox#WebAuthnP256.(sign:function)}.\n *\n * :::warning\n *\n * This function is mainly for testing purposes or for manually constructing\n * client data. In most cases you will not need this function.\n * `clientDataJSON` is typically returned as part of the\n * {@link ox#WebAuthnP256.(sign:function)} response (ie. an authenticator response).\n *\n * :::\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256 } from 'ox'\n *\n * const clientDataJSON = WebAuthnP256.getClientDataJSON({\n * challenge: '0xdeadbeef',\n * origin: 'https://example.com',\n * })\n * // @log: \"{\"type\":\"webauthn.get\",\"challenge\":\"3q2-7w\",\"origin\":\"https://example.com\",\"crossOrigin\":false}\"\n * ```\n *\n * @param options - Options to construct the client data.\n * @returns The client data.\n */\nexport function getClientDataJSON(options) {\n const { challenge, crossOrigin = false, extraClientData, origin = window.location.origin, } = options;\n return JSON.stringify({\n type: 'webauthn.get',\n challenge: Base64.fromHex(challenge, { url: true, pad: false }),\n origin,\n crossOrigin,\n ...extraClientData,\n });\n}\n/**\n * Returns the creation options for a P256 WebAuthn Credential to be used with\n * the Web Authentication API.\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256 } from 'ox'\n *\n * const options = WebAuthnP256.getCredentialCreationOptions({ name: 'Example' })\n *\n * const credential = await window.navigator.credentials.create(options)\n * ```\n *\n * @param options - Options.\n * @returns The credential creation options.\n */\nexport function getCredentialCreationOptions(options) {\n const { attestation = 'none', authenticatorSelection = {\n residentKey: 'preferred',\n requireResidentKey: false,\n userVerification: 'required',\n }, challenge = createChallenge, excludeCredentialIds, name: name_, rp = {\n id: window.location.hostname,\n name: window.document.title,\n }, user, extensions, } = options;\n const name = (user?.name ?? name_);\n return {\n publicKey: {\n attestation,\n authenticatorSelection,\n challenge,\n ...(excludeCredentialIds\n ? {\n excludeCredentials: excludeCredentialIds?.map((id) => ({\n id: Base64.toBytes(id),\n type: 'public-key',\n })),\n }\n : {}),\n pubKeyCredParams: [\n {\n type: 'public-key',\n alg: -7, // p256\n },\n ],\n rp,\n user: {\n id: user?.id ?? Hash.keccak256(Bytes.fromString(name), { as: 'Bytes' }),\n name,\n displayName: user?.displayName ?? name,\n },\n extensions,\n },\n };\n}\n/**\n * Returns the request options to sign a challenge with the Web Authentication API.\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256 } from 'ox'\n *\n * const options = WebAuthnP256.getCredentialRequestOptions({\n * challenge: '0xdeadbeef',\n * })\n *\n * const credential = await window.navigator.credentials.get(options)\n * ```\n *\n * @param options - Options.\n * @returns The credential request options.\n */\nexport function getCredentialRequestOptions(options) {\n const { credentialId, challenge, rpId = window.location.hostname, userVerification = 'required', } = options;\n return {\n publicKey: {\n ...(credentialId\n ? {\n allowCredentials: [\n {\n id: Base64.toBytes(credentialId),\n type: 'public-key',\n },\n ],\n }\n : {}),\n challenge: Bytes.fromHex(challenge),\n rpId,\n userVerification,\n },\n };\n}\n/**\n * Constructs the final digest that was signed and computed by the authenticator. This payload includes\n * the cryptographic `challenge`, as well as authenticator metadata (`authenticatorData` + `clientDataJSON`).\n * This value can be also used with raw P256 verification (such as {@link ox#P256.(verify:function)} or\n * {@link ox#WebCryptoP256.(verify:function)}).\n *\n * :::warning\n *\n * This function is mainly for testing purposes or for manually constructing\n * signing payloads. In most cases you will not need this function and\n * instead use {@link ox#WebAuthnP256.(sign:function)}.\n *\n * :::\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256, WebCryptoP256 } from 'ox'\n *\n * const { metadata, payload } = WebAuthnP256.getSignPayload({ // [!code focus]\n * challenge: '0xdeadbeef', // [!code focus]\n * }) // [!code focus]\n * // @log: {\n * // @log: metadata: {\n * // @log: authenticatorData: \"0x49960de5880e8c687434170f6476605b8fe4aeb9a28632c7995cf3ba831d97630500000000\",\n * // @log: challengeIndex: 23,\n * // @log: clientDataJSON: \"{\"type\":\"webauthn.get\",\"challenge\":\"9jEFijuhEWrM4SOW-tChJbUEHEP44VcjcJ-Bqo1fTM8\",\"origin\":\"http://localhost:5173\",\"crossOrigin\":false}\",\n * // @log: typeIndex: 1,\n * // @log: userVerificationRequired: true,\n * // @log: },\n * // @log: payload: \"0x49960de5880e8c687434170f6476605b8fe4aeb9a28632c7995cf3ba831d9763050000000045086dcb06a5f234db625bcdc94e657f86b76b6fd3eb9c30543eabc1e577a4b0\",\n * // @log: }\n *\n * const { publicKey, privateKey } = await WebCryptoP256.createKeyPair()\n *\n * const signature = await WebCryptoP256.sign({\n * payload,\n * privateKey,\n * })\n * ```\n *\n * @param options - Options to construct the signing payload.\n * @returns The signing payload.\n */\nexport function getSignPayload(options) {\n const { challenge, crossOrigin, extraClientData, flag, origin, rpId, signCount, userVerification = 'required', } = options;\n const authenticatorData = getAuthenticatorData({\n flag,\n rpId,\n signCount,\n });\n const clientDataJSON = getClientDataJSON({\n challenge,\n crossOrigin,\n extraClientData,\n origin,\n });\n const clientDataJSONHash = Hash.sha256(Hex.fromString(clientDataJSON));\n const challengeIndex = clientDataJSON.indexOf('\"challenge\"');\n const typeIndex = clientDataJSON.indexOf('\"type\"');\n const metadata = {\n authenticatorData,\n clientDataJSON,\n challengeIndex,\n typeIndex,\n userVerificationRequired: userVerification === 'required',\n };\n const payload = Hex.concat(authenticatorData, clientDataJSONHash);\n return { metadata, payload };\n}\n/**\n * Signs a challenge using a stored WebAuthn P256 Credential. If no Credential is provided,\n * a prompt will be displayed for the user to select an existing Credential\n * that was previously registered.\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256 } from 'ox'\n *\n * const credential = await WebAuthnP256.createCredential({\n * name: 'Example',\n * })\n *\n * const { metadata, signature } = await WebAuthnP256.sign({ // [!code focus]\n * credentialId: credential.id, // [!code focus]\n * challenge: '0xdeadbeef', // [!code focus]\n * }) // [!code focus]\n * // @log: {\n * // @log: metadata: {\n * // @log: authenticatorData: '0x49960de5880e8c687434170f6476605b8fe4aeb9a28632c7995cf3ba831d97630500000000',\n * // @log: clientDataJSON: '{\"type\":\"webauthn.get\",\"challenge\":\"9jEFijuhEWrM4SOW-tChJbUEHEP44VcjcJ-Bqo1fTM8\",\"origin\":\"http://localhost:5173\",\"crossOrigin\":false}',\n * // @log: challengeIndex: 23,\n * // @log: typeIndex: 1,\n * // @log: userVerificationRequired: true,\n * // @log: },\n * // @log: signature: { r: 51231...4215n, s: 12345...6789n },\n * // @log: }\n * ```\n *\n * @param options - Options.\n * @returns The signature.\n */\nexport async function sign(options) {\n const { getFn = window.navigator.credentials.get.bind(window.navigator.credentials), ...rest } = options;\n const requestOptions = getCredentialRequestOptions(rest);\n try {\n const credential = (await getFn(requestOptions));\n if (!credential)\n throw new CredentialRequestFailedError();\n const response = credential.response;\n const clientDataJSON = String.fromCharCode(...new Uint8Array(response.clientDataJSON));\n const challengeIndex = clientDataJSON.indexOf('\"challenge\"');\n const typeIndex = clientDataJSON.indexOf('\"type\"');\n const signature = internal.parseAsn1Signature(new Uint8Array(response.signature));\n return {\n metadata: {\n authenticatorData: Hex.fromBytes(new Uint8Array(response.authenticatorData)),\n clientDataJSON,\n challengeIndex,\n typeIndex,\n userVerificationRequired: requestOptions.publicKey.userVerification === 'required',\n },\n signature,\n raw: credential,\n };\n }\n catch (error) {\n throw new CredentialRequestFailedError({\n cause: error,\n });\n }\n}\n/**\n * Verifies a signature using the Credential's public key and the challenge which was signed.\n *\n * @example\n * ```ts twoslash\n * import { WebAuthnP256 } from 'ox'\n *\n * const credential = await WebAuthnP256.createCredential({\n * name: 'Example',\n * })\n *\n * const { metadata, signature } = await WebAuthnP256.sign({\n * credentialId: credential.id,\n * challenge: '0xdeadbeef',\n * })\n *\n * const result = await WebAuthnP256.verify({ // [!code focus]\n * metadata, // [!code focus]\n * challenge: '0xdeadbeef', // [!code focus]\n * publicKey: credential.publicKey, // [!code focus]\n * signature, // [!code focus]\n * }) // [!code focus]\n * // @log: true\n * ```\n *\n * @param options - Options.\n * @returns Whether the signature is valid.\n */\nexport function verify(options) {\n const { challenge, hash = true, metadata, publicKey, signature } = options;\n const { authenticatorData, challengeIndex, clientDataJSON, typeIndex, userVerificationRequired, } = metadata;\n const authenticatorDataBytes = Bytes.fromHex(authenticatorData);\n // Check length of `authenticatorData`.\n if (authenticatorDataBytes.length < 37)\n return false;\n const flag = authenticatorDataBytes[32];\n // Verify that the UP bit of the flags in authData is set.\n if ((flag & 0x01) !== 0x01)\n return false;\n // If user verification was determined to be required, verify that\n // the UV bit of the flags in authData is set. Otherwise, ignore the\n // value of the UV flag.\n if (userVerificationRequired && (flag & 0x04) !== 0x04)\n return false;\n // If the BE bit of the flags in authData is not set, verify that\n // the BS bit is not set.\n if ((flag & 0x08) !== 0x08 && (flag & 0x10) === 0x10)\n return false;\n // Check that response is for an authentication assertion\n const type = '\"type\":\"webauthn.get\"';\n if (type !== clientDataJSON.slice(Number(typeIndex), type.length + 1))\n return false;\n // Check that hash is in the clientDataJSON.\n const match = clientDataJSON\n .slice(Number(challengeIndex))\n .match(/^\"challenge\":\"(.*?)\"/);\n if (!match)\n return false;\n // Validate the challenge in the clientDataJSON.\n const [_, challenge_extracted] = match;\n if (Hex.fromBytes(Base64.toBytes(challenge_extracted)) !== challenge)\n return false;\n const clientDataJSONHash = Hash.sha256(Bytes.fromString(clientDataJSON), {\n as: 'Bytes',\n });\n const payload = Bytes.concat(authenticatorDataBytes, clientDataJSONHash);\n return P256.verify({\n hash,\n payload,\n publicKey,\n signature,\n });\n}\n/** Thrown when a WebAuthn P256 credential creation fails. */\nexport class CredentialCreationFailedError extends Errors.BaseError {\n constructor({ cause } = {}) {\n super('Failed to create credential.', {\n cause,\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'WebAuthnP256.CredentialCreationFailedError'\n });\n }\n}\n/** Thrown when a WebAuthn P256 credential request fails. */\nexport class CredentialRequestFailedError extends Errors.BaseError {\n constructor({ cause } = {}) {\n super('Failed to request credential.', {\n cause,\n });\n Object.defineProperty(this, \"name\", {\n enumerable: true,\n configurable: true,\n writable: true,\n value: 'WebAuthnP256.CredentialRequestFailedError'\n });\n }\n}\n//# sourceMappingURL=WebAuthnP256.js.map","import { p256 } from '@noble/curves/p256';\nimport * as Bytes from './Bytes.js';\nimport * as PublicKey from './PublicKey.js';\n/**\n * Generates an ECDSA P256 key pair that includes:\n *\n * - a `privateKey` of type [`CryptoKey`](https://developer.mozilla.org/en-US/docs/Web/API/CryptoKey)\n *\n * - a `publicKey` of type {@link ox#Hex.Hex} or {@link ox#Bytes.Bytes}\n *\n * @example\n * ```ts twoslash\n * import { WebCryptoP256 } from 'ox'\n *\n * const { publicKey, privateKey } = await WebCryptoP256.createKeyPair()\n * // @log: {\n * // @log: privateKey: CryptoKey {},\n * // @log: publicKey: {\n * // @log: x: 59295962801117472859457908919941473389380284132224861839820747729565200149877n,\n * // @log: y: 24099691209996290925259367678540227198235484593389470330605641003500238088869n,\n * // @log: prefix: 4,\n * // @log: },\n * // @log: }\n * ```\n *\n * @param options - Options for creating the key pair.\n * @returns The key pair.\n */\nexport async function createKeyPair(options = {}) {\n const { extractable = false } = options;\n const keypair = await globalThis.crypto.subtle.generateKey({\n name: 'ECDSA',\n namedCurve: 'P-256',\n }, extractable, ['sign', 'verify']);\n const publicKey_raw = await globalThis.crypto.subtle.exportKey('raw', keypair.publicKey);\n const publicKey = PublicKey.from(new Uint8Array(publicKey_raw));\n return {\n privateKey: keypair.privateKey,\n publicKey,\n };\n}\n/**\n * Signs a payload with the provided `CryptoKey` private key and returns a P256 signature.\n *\n * @example\n * ```ts twoslash\n * import { WebCryptoP256 } from 'ox'\n *\n * const { privateKey } = await WebCryptoP256.createKeyPair()\n *\n * const signature = await WebCryptoP256.sign({ // [!code focus]\n * payload: '0xdeadbeef', // [!code focus]\n * privateKey, // [!code focus]\n * }) // [!code focus]\n * // @log: {\n * // @log: r: 151231...4423n,\n * // @log: s: 516123...5512n,\n * // @log: }\n * ```\n *\n * @param options - Options for signing the payload.\n * @returns The P256 ECDSA {@link ox#Signature.Signature}.\n */\nexport async function sign(options) {\n const { payload, privateKey } = options;\n const signature = await globalThis.crypto.subtle.sign({\n name: 'ECDSA',\n hash: 'SHA-256',\n }, privateKey, Bytes.from(payload));\n const signature_bytes = Bytes.fromArray(new Uint8Array(signature));\n const r = Bytes.toBigInt(Bytes.slice(signature_bytes, 0, 32));\n let s = Bytes.toBigInt(Bytes.slice(signature_bytes, 32, 64));\n if (s > p256.CURVE.n / 2n)\n s = p256.CURVE.n - s;\n return { r, s };\n}\n/**\n * Verifies a payload was signed by the provided public key.\n *\n * @example\n *\n * ```ts twoslash\n * import { WebCryptoP256 } from 'ox'\n *\n * const { privateKey, publicKey } = await WebCryptoP256.createKeyPair()\n * const signature = await WebCryptoP256.sign({ payload: '0xdeadbeef', privateKey })\n *\n * const verified = await WebCryptoP256.verify({ // [!code focus]\n * payload: '0xdeadbeef', // [!code focus]\n * publicKey, // [!code focus]\n * signature, // [!code focus]\n * }) // [!code focus]\n * // @log: true\n * ```\n *\n * @param options - The verification options.\n * @returns Whether the payload was signed by the provided public key.\n */\nexport async function verify(options) {\n const { payload, signature } = options;\n const publicKey = await globalThis.crypto.subtle.importKey('raw', PublicKey.toBytes(options.publicKey), { name: 'ECDSA', namedCurve: 'P-256' }, true, ['verify']);\n return await globalThis.crypto.subtle.verify({\n name: 'ECDSA',\n hash: 'SHA-256',\n }, publicKey, Bytes.concat(Bytes.fromNumber(signature.r), Bytes.fromNumber(signature.s)), Bytes.from(payload));\n}\n//# sourceMappingURL=WebCryptoP256.js.map","import { createStore, del, get, set } from 'idb-keyval';\nexport function createStorage(scope, name) {\n const store = typeof indexedDB !== 'undefined' ? createStore(scope, name) : undefined;\n return {\n getItem: async (key) => {\n const value = await get(key, store);\n if (!value) {\n return null;\n }\n return value;\n },\n removeItem: async (key) => {\n return del(key, store);\n },\n setItem: async (key, value) => {\n return set(key, value, store);\n },\n };\n}\n//# sourceMappingURL=storage.js.map","import { Hex, PublicKey, Signature, WebAuthnP256, WebCryptoP256 } from 'ox';\nimport { hashMessage, hashTypedData } from 'viem';\nimport { createStorage } from './storage.js';\n// *****************************************************************\n// Constants\n// *****************************************************************\nexport const STORAGE_SCOPE = 'base-acc-sdk';\nexport const STORAGE_NAME = 'keys';\nexport const ACTIVE_ID_KEY = 'activeId';\n// *****************************************************************\n// Storage\n// *****************************************************************\nexport const storage = createStorage(STORAGE_SCOPE, STORAGE_NAME);\n// *****************************************************************\n// Functions\n// *****************************************************************\nexport async function generateKeyPair() {\n const keypair = await WebCryptoP256.createKeyPair({ extractable: false });\n const publicKey = Hex.slice(PublicKey.toHex(keypair.publicKey), 1);\n await storage.setItem(publicKey, keypair);\n await storage.setItem(ACTIVE_ID_KEY, publicKey);\n return keypair;\n}\nexport async function getKeypair() {\n const id = await storage.getItem(ACTIVE_ID_KEY);\n if (!id) {\n return null;\n }\n const keypair = await storage.getItem(id);\n if (!keypair) {\n return null;\n }\n return keypair;\n}\nasync function getOrCreateKeypair() {\n const keypair = await getKeypair();\n if (!keypair) {\n const kp = await generateKeyPair();\n const pubKey = Hex.slice(PublicKey.toHex(kp.publicKey), 1);\n await storage.setItem(pubKey, kp);\n await storage.setItem(ACTIVE_ID_KEY, pubKey);\n return kp;\n }\n return keypair;\n}\nasync function getAccount() {\n const keypair = await getOrCreateKeypair();\n /**\n * public key / address\n */\n const publicKey = Hex.slice(PublicKey.toHex(keypair.publicKey), 1);\n const sign = async (payload) => {\n const { payload: message, metadata } = WebAuthnP256.getSignPayload({\n challenge: payload,\n origin: 'https://keys.coinbase.com',\n userVerification: 'preferred',\n });\n const signature = await WebCryptoP256.sign({\n payload: message,\n privateKey: keypair.privateKey,\n });\n return {\n signature: Signature.toHex(signature),\n raw: {}, // type changed in viem\n webauthn: metadata,\n };\n };\n return {\n id: publicKey,\n publicKey,\n async sign({ hash }) {\n return sign(hash);\n },\n async signMessage({ message }) {\n return sign(hashMessage(message));\n },\n async signTypedData(parameters) {\n return sign(hashTypedData(parameters));\n },\n type: 'webAuthn',\n };\n}\nexport async function getCryptoKeyAccount() {\n const account = await getAccount();\n return {\n account,\n };\n}\nexport async function removeCryptoKey() {\n const keypair = await getKeypair();\n if (!keypair) {\n return;\n }\n await storage.removeItem(Hex.slice(PublicKey.toHex(keypair.publicKey), 1));\n await storage.removeItem(ACTIVE_ID_KEY);\n}\n//# sourceMappingURL=index.js.map","import { store } from '../../store/store.js';\nimport { deriveSharedSecret, exportKeyToHexString, generateKeyPair, importKeyFromHexString, } from '../../util/cipher.js';\nconst OWN_PRIVATE_KEY = {\n storageKey: 'ownPrivateKey',\n keyType: 'private',\n};\nconst OWN_PUBLIC_KEY = {\n storageKey: 'ownPublicKey',\n keyType: 'public',\n};\nconst PEER_PUBLIC_KEY = {\n storageKey: 'peerPublicKey',\n keyType: 'public',\n};\nexport class SCWKeyManager {\n ownPrivateKey = null;\n ownPublicKey = null;\n peerPublicKey = null;\n sharedSecret = null;\n async getOwnPublicKey() {\n await this.loadKeysIfNeeded();\n return this.ownPublicKey;\n }\n // returns null if the shared secret is not yet derived\n async getSharedSecret() {\n await this.loadKeysIfNeeded();\n return this.sharedSecret;\n }\n async setPeerPublicKey(key) {\n this.sharedSecret = null;\n this.peerPublicKey = key;\n await this.storeKey(PEER_PUBLIC_KEY, key);\n await this.loadKeysIfNeeded();\n }\n async clear() {\n this.ownPrivateKey = null;\n this.ownPublicKey = null;\n this.peerPublicKey = null;\n this.sharedSecret = null;\n store.keys.clear();\n }\n async generateKeyPair() {\n const newKeyPair = await generateKeyPair();\n this.ownPrivateKey = newKeyPair.privateKey;\n this.ownPublicKey = newKeyPair.publicKey;\n await this.storeKey(OWN_PRIVATE_KEY, newKeyPair.privateKey);\n await this.storeKey(OWN_PUBLIC_KEY, newKeyPair.publicKey);\n }\n async loadKeysIfNeeded() {\n if (this.ownPrivateKey === null) {\n this.ownPrivateKey = await this.loadKey(OWN_PRIVATE_KEY);\n }\n if (this.ownPublicKey === null) {\n this.ownPublicKey = await this.loadKey(OWN_PUBLIC_KEY);\n }\n if (this.ownPrivateKey === null || this.ownPublicKey === null) {\n await this.generateKeyPair();\n }\n if (this.peerPublicKey === null) {\n this.peerPublicKey = await this.loadKey(PEER_PUBLIC_KEY);\n }\n if (this.sharedSecret === null) {\n if (this.ownPrivateKey === null || this.peerPublicKey === null)\n return;\n this.sharedSecret = await deriveSharedSecret(this.ownPrivateKey, this.peerPublicKey);\n }\n }\n // storage methods\n async loadKey(item) {\n const key = store.keys.get(item.storageKey);\n if (!key)\n return null;\n return importKeyFromHexString(item.keyType, key);\n }\n async storeKey(item, key) {\n const hexString = await exportKeyToHexString(item.keyType, key);\n store.keys.set(item.storageKey, hexString);\n }\n}\n//# sourceMappingURL=SCWKeyManager.js.map","export function get(obj, path) {\n if (typeof obj !== 'object' || obj === null)\n return undefined;\n return path\n .split(/[.[\\]]+/)\n .filter(Boolean)\n .reduce((value, key) => {\n if (typeof value === 'object' && value !== null) {\n return value[key];\n }\n return undefined;\n }, obj);\n}\n//# sourceMappingURL=get.js.map","import { hexToBigInt, isAddress } from 'viem';\nimport { keccak256, numberToHex, slice, toHex } from 'viem';\nimport { standardErrors } from '../../core/error/errors.js';\nimport { logDialogActionClicked, logDialogDismissed, logDialogShown, } from '../../core/telemetry/events/dialog.js';\nimport { config, store } from '../../store/store.js';\nimport { initDialog } from '../../ui/Dialog/index.js';\nimport { get } from '../../util/get.js';\nimport { waitForCallsStatus } from 'viem/actions';\nimport { getCryptoKeyAccount } from '../../kms/crypto-key/index.js';\nimport { spendPermissionManagerAddress } from './utils/constants.js';\n// ***************************************************************\n// Utility\n// ***************************************************************\nexport function getSenderFromRequest(request) {\n if (!Array.isArray(request.params)) {\n return null;\n }\n switch (request.method) {\n case 'personal_sign':\n return request.params[1];\n case 'eth_signTypedData_v4':\n return request.params[0];\n case 'eth_signTransaction':\n case 'eth_sendTransaction':\n case 'wallet_sendCalls':\n return request.params[0]?.from;\n default:\n return null;\n }\n}\nexport function addSenderToRequest(request, sender) {\n if (!Array.isArray(request.params)) {\n throw standardErrors.rpc.invalidParams();\n }\n const params = [...request.params];\n switch (request.method) {\n case 'eth_signTransaction':\n case 'eth_sendTransaction':\n case 'wallet_sendCalls':\n params[0].from = sender;\n break;\n case 'eth_signTypedData_v4':\n params[0] = sender;\n break;\n case 'personal_sign':\n params[1] = sender;\n break;\n default:\n break;\n }\n return { ...request, params };\n}\nexport function assertParamsChainId(params) {\n if (!params || !Array.isArray(params) || !params[0]?.chainId) {\n throw standardErrors.rpc.invalidParams();\n }\n if (typeof params[0].chainId !== 'string' && typeof params[0].chainId !== 'number') {\n throw standardErrors.rpc.invalidParams();\n }\n}\nexport function assertGetCapabilitiesParams(params) {\n if (!params || !Array.isArray(params) || (params.length !== 1 && params.length !== 2)) {\n throw standardErrors.rpc.invalidParams();\n }\n if (typeof params[0] !== 'string' || !isAddress(params[0])) {\n throw standardErrors.rpc.invalidParams();\n }\n if (params.length === 2) {\n if (!Array.isArray(params[1])) {\n throw standardErrors.rpc.invalidParams();\n }\n for (const param of params[1]) {\n if (typeof param !== 'string' || !param.startsWith('0x')) {\n throw standardErrors.rpc.invalidParams();\n }\n }\n }\n}\nexport function injectRequestCapabilities(request, capabilities) {\n // Modify request to include auto sub account capabilities\n const modifiedRequest = { ...request };\n if (capabilities && request.method.startsWith('wallet_')) {\n let requestCapabilities = get(modifiedRequest, 'params.0.capabilities');\n if (typeof requestCapabilities === 'undefined') {\n requestCapabilities = {};\n }\n if (typeof requestCapabilities !== 'object') {\n throw standardErrors.rpc.invalidParams();\n }\n // Merge capabilities: injected capabilities first, then request capabilities\n // This ensures that if the request doesn't have a capability (e.g., addSubAccount),\n // it gets injected. If the request already has it, the request's version takes precedence.\n requestCapabilities = {\n ...capabilities,\n ...requestCapabilities,\n };\n if (modifiedRequest.params && Array.isArray(modifiedRequest.params)) {\n modifiedRequest.params[0] = {\n ...modifiedRequest.params[0],\n capabilities: requestCapabilities,\n };\n }\n }\n return modifiedRequest;\n}\n/**\n * Initializes the `subAccountConfig` store with the owner account function and capabilities\n * @returns void\n */\nexport async function initSubAccountConfig() {\n const config = store.subAccountsConfig.get() ?? {};\n const capabilities = {};\n if (config.creation === 'on-connect') {\n // Get the owner account\n const { account: owner } = config.toOwnerAccount\n ? await config.toOwnerAccount()\n : await getCryptoKeyAccount();\n if (!owner) {\n throw standardErrors.provider.unauthorized('No owner account found');\n }\n capabilities.addSubAccount = {\n account: {\n type: 'create',\n keys: [\n {\n type: owner.address ? 'address' : 'webauthn-p256',\n publicKey: owner.address || owner.publicKey,\n },\n ],\n },\n };\n }\n // Merge capabilities with existing config (don't overwrite the other properties!)\n store.subAccountsConfig.set({\n ...config,\n capabilities,\n });\n}\nexport function assertFetchPermissionsRequest(request) {\n if (request.method === 'coinbase_fetchPermissions' && request.params === undefined) {\n return;\n }\n if (request.method === 'coinbase_fetchPermissions' &&\n Array.isArray(request.params) &&\n request.params.length === 1 &&\n typeof request.params[0] === 'object') {\n if (typeof request.params[0].account !== 'string' ||\n !request.params[0].chainId.startsWith('0x')) {\n throw standardErrors.rpc.invalidParams('FetchPermissions - Invalid params: params[0].account must be a hex string');\n }\n if (typeof request.params[0].chainId !== 'string' ||\n !request.params[0].chainId.startsWith('0x')) {\n throw standardErrors.rpc.invalidParams('FetchPermissions - Invalid params: params[0].chainId must be a hex string');\n }\n if (typeof request.params[0].spender !== 'string' ||\n !request.params[0].spender.startsWith('0x')) {\n throw standardErrors.rpc.invalidParams('FetchPermissions - Invalid params: params[0].spender must be a hex string');\n }\n return;\n }\n throw standardErrors.rpc.invalidParams();\n}\nexport function fillMissingParamsForFetchPermissions(request) {\n if (request.params !== undefined) {\n return request;\n }\n // this is based on the assumption that the first account is the active account\n // it could change in the context of multi-(universal)-account\n const accountFromStore = store.getState().account.accounts?.[0];\n const chainId = store.getState().account.chain?.id;\n const subAccountFromStore = store.getState().subAccount?.address;\n if (!accountFromStore || !subAccountFromStore || !chainId) {\n throw standardErrors.rpc.invalidParams('FetchPermissions - one or more of account, sub account, or chain id is missing, connect to sub account via wallet_connect first');\n }\n return {\n method: 'coinbase_fetchPermissions',\n params: [\n {\n account: accountFromStore,\n chainId: numberToHex(chainId),\n spender: subAccountFromStore,\n },\n ],\n };\n}\nexport function createSpendPermissionMessage({ spendPermission, chainId, }) {\n return {\n domain: {\n name: 'Spend Permission Manager',\n version: '1',\n chainId: chainId,\n verifyingContract: spendPermissionManagerAddress,\n },\n types: {\n SpendPermission: [\n { name: 'account', type: 'address' },\n { name: 'spender', type: 'address' },\n { name: 'token', type: 'address' },\n { name: 'allowance', type: 'uint160' },\n { name: 'period', type: 'uint48' },\n { name: 'start', type: 'uint48' },\n { name: 'end', type: 'uint48' },\n { name: 'salt', type: 'uint256' },\n { name: 'extraData', type: 'bytes' },\n ],\n },\n primaryType: 'SpendPermission',\n message: {\n account: spendPermission.account,\n spender: spendPermission.spender,\n token: spendPermission.token,\n allowance: spendPermission.allowance,\n period: spendPermission.period,\n start: spendPermission.start,\n end: spendPermission.end,\n salt: spendPermission.salt,\n extraData: spendPermission.extraData,\n },\n };\n}\nexport function createSpendPermissionBatchMessage({ spendPermissionBatch, chainId, }) {\n return {\n domain: {\n name: 'Spend Permission Manager',\n version: '1',\n chainId,\n verifyingContract: spendPermissionManagerAddress,\n },\n types: {\n SpendPermissionBatch: [\n { name: 'account', type: 'address' },\n { name: 'period', type: 'uint48' },\n { name: 'start', type: 'uint48' },\n { name: 'end', type: 'uint48' },\n { name: 'permissions', type: 'PermissionDetails[]' },\n ],\n PermissionDetails: [\n { name: 'spender', type: 'address' },\n { name: 'token', type: 'address' },\n { name: 'allowance', type: 'uint160' },\n { name: 'salt', type: 'uint256' },\n { name: 'extraData', type: 'bytes' },\n ],\n },\n primaryType: 'SpendPermissionBatch',\n message: {\n account: spendPermissionBatch.account,\n period: spendPermissionBatch.period,\n start: spendPermissionBatch.start,\n end: spendPermissionBatch.end,\n permissions: spendPermissionBatch.permissions.map((p) => ({\n spender: p.spender,\n token: p.token,\n allowance: p.allowance,\n salt: p.salt,\n extraData: p.extraData,\n })),\n },\n };\n}\nexport async function waitForCallsTransactionHash({ client, id, }) {\n const result = await waitForCallsStatus(client, {\n id,\n });\n if (result.status === 'success') {\n return result.receipts?.[0].transactionHash;\n }\n throw standardErrors.rpc.internal('failed to send transaction');\n}\nexport function createWalletSendCallsRequest({ calls, from, chainId, capabilities, }) {\n const paymasterUrls = config.get().paymasterUrls;\n let request = {\n method: 'wallet_sendCalls',\n params: [\n {\n version: '1.0',\n calls,\n chainId: numberToHex(chainId),\n from,\n atomicRequired: true,\n capabilities,\n },\n ],\n };\n if (paymasterUrls?.[chainId]) {\n request = injectRequestCapabilities(request, {\n paymasterService: { url: paymasterUrls?.[chainId] },\n });\n }\n return request;\n}\nexport async function presentSubAccountFundingDialog() {\n const dialog = initDialog();\n const userChoice = await new Promise((resolve, reject) => {\n logDialogShown({ dialogContext: 'sub_account_insufficient_balance' });\n dialog.presentItem({\n title: 'Insufficient spend permission',\n message: \"Your spend permission's remaining balance cannot cover this transaction. Please use your primary account to complete this transaction.\",\n onClose: () => {\n logDialogDismissed({ dialogContext: 'sub_account_insufficient_balance' });\n dialog.clear();\n reject(new Error('User cancelled funding'));\n },\n actionItems: [\n {\n text: 'Use primary account',\n variant: 'primary',\n onClick: () => {\n logDialogActionClicked({\n dialogContext: 'sub_account_insufficient_balance',\n dialogAction: 'continue_in_popup',\n });\n dialog.clear();\n resolve('continue_popup');\n },\n },\n {\n text: 'Cancel',\n variant: 'secondary',\n onClick: () => {\n logDialogActionClicked({\n dialogContext: 'sub_account_insufficient_balance',\n dialogAction: 'cancel',\n });\n dialog.clear();\n reject(new Error('User cancelled funding'));\n },\n },\n ],\n });\n });\n return userChoice;\n}\nexport function parseFundingOptions({ errorData, sourceAddress, }) {\n const spendPermissionRequests = [];\n for (const [token, { amount, sources }] of Object.entries(errorData?.required ?? {})) {\n const sourcesWithSufficientBalance = sources.filter((source) => {\n return (hexToBigInt(source.balance) >= hexToBigInt(amount) &&\n source.address.toLowerCase() === sourceAddress?.toLowerCase());\n });\n if (sourcesWithSufficientBalance.length === 0) {\n throw new Error('Source address has insufficient balance for a token');\n }\n spendPermissionRequests.push({\n token: token,\n requiredAmount: hexToBigInt(amount),\n });\n }\n return spendPermissionRequests;\n}\nexport function isSendCallsParams(params) {\n return (typeof params === 'object' &&\n params !== null &&\n Array.isArray(params) &&\n params.length > 0 &&\n typeof params[0] === 'object' &&\n params[0] !== null &&\n 'calls' in params[0]);\n}\nexport function isEthSendTransactionParams(params) {\n return (Array.isArray(params) &&\n params.length === 1 &&\n typeof params[0] === 'object' &&\n params[0] !== null &&\n 'to' in params[0]);\n}\nexport function compute16ByteHash(input) {\n return slice(keccak256(toHex(input)), 0, 16);\n}\nexport function makeDataSuffix({ attribution, dappOrigin, }) {\n if (!attribution) {\n return;\n }\n if ('auto' in attribution && attribution.auto && dappOrigin) {\n return compute16ByteHash(dappOrigin);\n }\n if ('dataSuffix' in attribution) {\n return attribution.dataSuffix;\n }\n return;\n}\n/**\n * Checks if a specific capability is present in a request's params\n * @param request The request object to check\n * @param capabilityName The name of the capability to check for\n * @returns boolean indicating if the capability is present\n */\nexport function requestHasCapability(request, capabilityName) {\n if (!Array.isArray(request?.params))\n return false;\n const capabilities = request.params[0]?.capabilities;\n if (!capabilities || typeof capabilities !== 'object')\n return false;\n return capabilityName in capabilities;\n}\n/**\n * Prepends an item to an array without duplicates\n * @param array The array to prepend to\n * @param item The item to prepend\n * @returns The array with the item prepended\n */\nexport function prependWithoutDuplicates(array, item) {\n const filtered = array.filter((i) => i !== item);\n return [item, ...filtered];\n}\n/**\n * Appends an item to an array without duplicates\n * @param array The array to append to\n * @param item The item to append\n * @returns The array with the item appended\n */\nexport function appendWithoutDuplicates(array, item) {\n const filtered = array.filter((i) => i !== item);\n return [...filtered, item];\n}\nexport async function getCachedWalletConnectResponse() {\n const spendPermissions = store.spendPermissions.get();\n const subAccount = store.subAccounts.get();\n const accounts = store.account.get().accounts;\n if (!accounts) {\n return null;\n }\n const walletConnectAccounts = accounts?.map((account) => ({\n address: account,\n capabilities: {\n subAccounts: subAccount ? [subAccount] : undefined,\n spendPermissions: spendPermissions.length > 0 ? { permissions: spendPermissions } : undefined,\n },\n }));\n return {\n accounts: walletConnectAccounts,\n };\n}\n//# sourceMappingURL=utils.js.map","import { Signature } from 'ox';\nimport { hexToBytes, numberToHex, stringToBytes, trim } from 'viem';\nexport function base64ToBase64Url(base64) {\n return base64.replaceAll('+', '-').replaceAll('/', '_').replace(/=+$/, '');\n}\nexport function arrayBufferToBase64Url(buffer) {\n // First convert to regular base64\n const base64String = btoa(String.fromCharCode(...new Uint8Array(buffer)));\n // Then convert to base64url\n return base64ToBase64Url(base64String);\n}\nexport function convertCredentialToJSON({ webauthn, signature, id, }) {\n const signatureRaw = Signature.fromHex(signature);\n return {\n id,\n rawId: arrayBufferToBase64Url(stringToBytes(id)),\n response: {\n authenticatorData: arrayBufferToBase64Url(hexToBytes(webauthn.authenticatorData)),\n clientDataJSON: arrayBufferToBase64Url(stringToBytes(webauthn.clientDataJSON)),\n signature: arrayBufferToBase64Url(asn1EncodeSignature(signatureRaw.r, signatureRaw.s)),\n },\n type: JSON.parse(webauthn.clientDataJSON).type,\n };\n}\nexport function asn1EncodeSignature(r, s) {\n // Convert r and s to byte arrays and remove any leading zeros\n const rBytes = hexToBytes(trim(numberToHex(r)));\n const sBytes = hexToBytes(trim(numberToHex(s)));\n // Calculate lengths\n const rLength = rBytes.length;\n const sLength = sBytes.length;\n const totalLength = rLength + sLength + 4; // 4 additional bytes for type and length fields\n // Create the signature buffer\n const signature = new Uint8Array(totalLength + 2); // +2 for sequence header\n // Sequence header\n signature[0] = 0x30; // ASN.1 sequence tag\n signature[1] = totalLength;\n // Encode r value\n signature[2] = 0x02; // ASN.1 integer tag\n signature[3] = rLength;\n signature.set(rBytes, 4);\n // Encode s value\n signature[rLength + 4] = 0x02; // ASN.1 integer tag\n signature[rLength + 5] = sLength;\n signature.set(sBytes, rLength + 6);\n return signature;\n}\n//# sourceMappingURL=encoding.js.map","import * as Signature from 'ox/Signature';\nimport { BaseError, decodeFunctionData, encodeAbiParameters, encodeFunctionData, encodePacked, hashMessage, hashTypedData, parseSignature, size, stringToHex, } from 'viem';\nimport { entryPoint06Abi, entryPoint06Address, getUserOperationHash, toSmartAccount, } from 'viem/account-abstraction';\nimport { abi, factoryAbi, factoryAddress } from './constants.js';\n/**\n * @description Create a Coinbase Smart Account.\n *\n * @param parameters - {@link CreateSmartAccountParameters}\n * @returns Coinbase Smart Account. {@link CreateSmartAccountReturnType}\n *\n * @example\n *\n * const account = createSmartAccount({\n * client,\n * owner: privateKeyToAccount('0x...'),\n * ownerIndex: 0,\n * address: '0x...',\n * factoryData: '0x...',\n * })\n */\nexport async function createSmartAccount(parameters) {\n const { owner, ownerIndex, address, client, factoryData } = parameters;\n const entryPoint = {\n abi: entryPoint06Abi,\n address: entryPoint06Address,\n version: '0.6',\n };\n const factory = {\n abi: factoryAbi,\n address: factoryAddress,\n };\n return toSmartAccount({\n client,\n entryPoint,\n extend: { abi, factory },\n async decodeCalls(data) {\n const result = decodeFunctionData({\n abi,\n data,\n });\n if (result.functionName === 'execute')\n return [{ to: result.args[0], value: result.args[1], data: result.args[2] }];\n if (result.functionName === 'executeBatch')\n return result.args[0].map((arg) => ({\n to: arg.target,\n value: arg.value,\n data: arg.data,\n }));\n throw new BaseError(`unable to decode calls for \"${result.functionName}\"`);\n },\n async encodeCalls(calls) {\n if (calls.length === 1) {\n return encodeFunctionData({\n abi,\n functionName: 'execute',\n args: [calls[0].to, calls[0].value ?? BigInt(0), calls[0].data ?? '0x'],\n });\n }\n return encodeFunctionData({\n abi,\n functionName: 'executeBatch',\n args: [\n calls.map((call) => ({\n data: call.data ?? '0x',\n target: call.to,\n value: call.value ?? BigInt(0),\n })),\n ],\n });\n },\n async getAddress() {\n return address;\n },\n async getFactoryArgs() {\n if (factoryData)\n return { factory: factory.address, factoryData };\n // TODO: support creating factory data\n return { factory: factory.address, factoryData };\n },\n async getStubSignature() {\n if (owner.type === 'webAuthn')\n return '0x0000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000170000000000000000000000000000000000000000000000000000000000000001949fc7c88032b9fcb5f6efc7a7b8c63668eae9871b765e23123bb473ff57aa831a7c0d9276168ebcc29f2875a0239cffdf2a9cd1c2007c5c77c071db9264df1d000000000000000000000000000000000000000000000000000000000000002549960de5880e8c687434170f6476605b8fe4aeb9a28632c7995cf3ba831d97630500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008a7b2274797065223a22776562617574686e2e676574222c226368616c6c656e6765223a2273496a396e6164474850596759334b7156384f7a4a666c726275504b474f716d59576f4d57516869467773222c226f726967696e223a2268747470733a2f2f7369676e2e636f696e626173652e636f6d222c2263726f73734f726967696e223a66616c73657d00000000000000000000000000000000000000000000';\n return wrapSignature({\n ownerIndex,\n signature: '0xfffffffffffffffffffffffffffffff0000000000000000000000000000000007aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa1c',\n });\n },\n async sign(parameters) {\n const address = await this.getAddress();\n const hash = toReplaySafeHash({\n address,\n chainId: client.chain.id,\n hash: parameters.hash,\n });\n const signature = await sign({ hash, owner });\n return wrapSignature({\n ownerIndex,\n signature,\n });\n },\n async signMessage(parameters) {\n const { message } = parameters;\n const address = await this.getAddress();\n const hash = toReplaySafeHash({\n address,\n chainId: client.chain.id,\n hash: hashMessage(message),\n });\n const signature = await sign({ hash, owner });\n return wrapSignature({\n ownerIndex,\n signature,\n });\n },\n async signTypedData(parameters) {\n const { domain, types, primaryType, message } = parameters;\n const address = await this.getAddress();\n const hash = toReplaySafeHash({\n address,\n chainId: client.chain.id,\n hash: hashTypedData({\n domain,\n message,\n primaryType,\n types,\n }),\n });\n const signature = await sign({ hash, owner });\n return wrapSignature({\n ownerIndex,\n signature,\n });\n },\n async signUserOperation(parameters) {\n const { chainId = client.chain.id, ...userOperation } = parameters;\n const address = await this.getAddress();\n const hash = getUserOperationHash({\n chainId,\n entryPointAddress: entryPoint.address,\n entryPointVersion: entryPoint.version,\n userOperation: {\n ...userOperation,\n sender: address,\n },\n });\n const signature = await sign({ hash, owner });\n return wrapSignature({\n ownerIndex,\n signature,\n });\n },\n userOperation: {\n async estimateGas(userOperation) {\n if (owner.type !== 'webAuthn')\n return;\n // Accounts with WebAuthn owner require a minimum verification gas limit of 800,000.\n return {\n verificationGasLimit: BigInt(Math.max(Number(userOperation.verificationGasLimit ?? BigInt(0)), 800_000)),\n };\n },\n },\n });\n}\n/////////////////////////////////////////////////////////////////////////////////////////////\n// Utilities\n/////////////////////////////////////////////////////////////////////////////////////////////\n/** @internal */\nexport async function sign({ hash, owner, }) {\n // WebAuthn Account (Passkey)\n if (owner.type === 'webAuthn') {\n const { signature, webauthn } = await owner.sign({\n hash,\n });\n return toWebAuthnSignature({ signature, webauthn });\n }\n if (owner.sign)\n return owner.sign({ hash });\n throw new BaseError('`owner` does not support raw sign.');\n}\n/** @internal */\nexport function toReplaySafeHash({ address, chainId, hash, }) {\n return hashTypedData({\n domain: {\n chainId,\n name: 'Coinbase Smart Wallet',\n verifyingContract: address,\n version: '1',\n },\n types: {\n CoinbaseSmartWalletMessage: [\n {\n name: 'hash',\n type: 'bytes32',\n },\n ],\n },\n primaryType: 'CoinbaseSmartWalletMessage',\n message: {\n hash,\n },\n });\n}\n/** @internal */\nexport function toWebAuthnSignature({ webauthn, signature, }) {\n const { r, s } = Signature.fromHex(signature);\n return encodeAbiParameters([\n {\n components: [\n {\n name: 'authenticatorData',\n type: 'bytes',\n },\n { name: 'clientDataJSON', type: 'bytes' },\n { name: 'challengeIndex', type: 'uint256' },\n { name: 'typeIndex', type: 'uint256' },\n {\n name: 'r',\n type: 'uint256',\n },\n {\n name: 's',\n type: 'uint256',\n },\n ],\n type: 'tuple',\n },\n ], [\n {\n authenticatorData: webauthn.authenticatorData,\n clientDataJSON: stringToHex(webauthn.clientDataJSON),\n challengeIndex: BigInt(webauthn.challengeIndex),\n typeIndex: BigInt(webauthn.typeIndex),\n r,\n s,\n },\n ]);\n}\n/** @internal */\nexport function wrapSignature(parameters) {\n const { ownerIndex = 0 } = parameters;\n const signatureData = (() => {\n if (size(parameters.signature) !== 65)\n return parameters.signature;\n const signature = parseSignature(parameters.signature);\n return encodePacked(['bytes32', 'bytes32', 'uint8'], [signature.r, signature.s, signature.yParity === 0 ? 27 : 28]);\n })();\n return encodeAbiParameters([\n {\n components: [\n {\n name: 'ownerIndex',\n type: 'uint8',\n },\n {\n name: 'signatureData',\n type: 'bytes',\n },\n ],\n type: 'tuple',\n },\n ], [\n {\n ownerIndex,\n signatureData,\n },\n ]);\n}\n//# sourceMappingURL=createSmartAccount.js.map","import { isViemError, standardErrors, viemHttpErrorToProviderError } from '../../../core/error/errors.js';\nimport { ensureHexString } from '../../../core/type/util.js';\nimport { assertArrayPresence, assertPresence } from '../../../util/assertPresence.js';\nimport { convertCredentialToJSON } from '../../../util/encoding.js';\nimport { get } from '../../../util/get.js';\nimport { hexToString, isHex, numberToHex, } from 'viem';\nimport { createWalletSendCallsRequest, injectRequestCapabilities, waitForCallsTransactionHash, } from '../utils.js';\nimport { createSmartAccount } from './createSmartAccount.js';\nexport async function createSubAccountSigner({ address, client, factory, factoryData, owner, ownerIndex, parentAddress, attribution, }) {\n const subAccount = {\n address,\n factory,\n factoryData,\n };\n const chainId = client.chain?.id;\n if (!chainId) {\n throw standardErrors.rpc.internal('chainId not found');\n }\n const account = await createSmartAccount({\n owner,\n ownerIndex: ownerIndex ?? 1,\n address,\n client,\n factoryData,\n });\n const request = async (args) => {\n try {\n switch (args.method) {\n case 'wallet_addSubAccount':\n return subAccount;\n case 'eth_accounts':\n return [subAccount.address];\n case 'eth_coinbase':\n return subAccount.address;\n case 'net_version':\n return chainId.toString();\n case 'eth_chainId':\n return numberToHex(chainId);\n case 'eth_sendTransaction': {\n assertArrayPresence(args.params);\n const rawParams = args.params[0];\n assertPresence(rawParams.to, standardErrors.rpc.invalidParams('to is required'));\n const params = {\n to: rawParams.to,\n data: ensureHexString(rawParams.data ?? '0x', true),\n value: ensureHexString(rawParams.value ?? '0x', true),\n from: rawParams.from ?? subAccount.address,\n };\n // Transform into wallet_sendCalls request\n const sendCallsRequest = createWalletSendCallsRequest({\n calls: [params],\n chainId,\n from: params.from,\n });\n const response = (await request(sendCallsRequest));\n return waitForCallsTransactionHash({\n client,\n id: response,\n });\n }\n case 'wallet_sendCalls': {\n assertArrayPresence(args.params);\n // Get the client for the chain\n const chainId = get(args.params[0], 'chainId');\n if (!chainId) {\n throw standardErrors.rpc.invalidParams('chainId is required');\n }\n if (!isHex(chainId)) {\n throw standardErrors.rpc.invalidParams('chainId must be a hex encoded integer');\n }\n if (!args.params[0]) {\n throw standardErrors.rpc.invalidParams('params are required');\n }\n if (!('calls' in args.params[0])) {\n throw standardErrors.rpc.invalidParams('calls are required');\n }\n let prepareCallsRequest = {\n method: 'wallet_prepareCalls',\n params: [\n {\n version: '1.0',\n calls: args.params[0].calls,\n chainId: chainId,\n from: subAccount.address,\n capabilities: 'capabilities' in args.params[0]\n ? args.params[0].capabilities\n : {},\n },\n ],\n };\n if (parentAddress) {\n prepareCallsRequest = injectRequestCapabilities(prepareCallsRequest, {\n funding: [\n {\n type: 'spendPermission',\n data: {\n autoApply: true,\n sources: [parentAddress],\n preference: 'PREFER_DIRECT_BALANCE',\n },\n },\n ],\n });\n }\n let prepareCallsResponse = (await request(prepareCallsRequest));\n const signResponse = await owner.sign?.({\n // Hash returned from wallet_prepareCalls is double hex encoded\n hash: hexToString(prepareCallsResponse.signatureRequest.hash),\n });\n let signatureData;\n if (!signResponse) {\n throw standardErrors.rpc.internal('signature not found');\n }\n if (isHex(signResponse)) {\n signatureData = {\n type: 'secp256k1',\n data: {\n address: owner.address,\n signature: signResponse,\n },\n };\n }\n else {\n signatureData = {\n type: 'webauthn',\n data: {\n signature: JSON.stringify(convertCredentialToJSON({\n id: owner.id ?? '1',\n ...signResponse,\n })),\n publicKey: owner.publicKey,\n },\n };\n }\n const sendPreparedCallsResponse = (await request({\n method: 'wallet_sendPreparedCalls',\n params: [\n {\n version: '1.0',\n type: prepareCallsResponse.type,\n data: prepareCallsResponse.userOp,\n chainId: prepareCallsResponse.chainId,\n signature: signatureData,\n },\n ],\n }));\n return sendPreparedCallsResponse[0];\n }\n case 'wallet_sendPreparedCalls': {\n assertArrayPresence(args.params);\n // Get the client for the chain\n const chainId = get(args.params[0], 'chainId');\n if (!chainId) {\n throw standardErrors.rpc.invalidParams('chainId is required');\n }\n if (!isHex(chainId)) {\n throw standardErrors.rpc.invalidParams('chainId must be a hex encoded integer');\n }\n const sendPreparedCallsResponse = await client.request({\n method: 'wallet_sendPreparedCalls',\n params: args.params,\n });\n return sendPreparedCallsResponse;\n }\n case 'wallet_prepareCalls': {\n assertArrayPresence(args.params);\n // Get the client for the chain\n const chainId = get(args.params[0], 'chainId');\n if (!chainId) {\n throw standardErrors.rpc.invalidParams('chainId is required');\n }\n if (!isHex(chainId)) {\n throw standardErrors.rpc.invalidParams('chainId must be a hex encoded integer');\n }\n if (!args.params[0]) {\n throw standardErrors.rpc.invalidParams('params are required');\n }\n if (!get(args.params[0], 'calls')) {\n throw standardErrors.rpc.invalidParams('calls are required');\n }\n const prepareCallsParams = args.params[0];\n if (attribution &&\n prepareCallsParams.capabilities &&\n !('attribution' in prepareCallsParams.capabilities)) {\n prepareCallsParams.capabilities.attribution = attribution;\n }\n const prepareCallsResponse = await client.request({\n method: 'wallet_prepareCalls',\n params: [{ ...args.params[0], chainId: chainId }],\n });\n return prepareCallsResponse;\n }\n case 'personal_sign': {\n assertArrayPresence(args.params);\n // Param is expected to be a hex encoded string\n if (!isHex(args.params[0])) {\n throw standardErrors.rpc.invalidParams('message must be a hex encoded string');\n }\n // signMessage expects the unencoded message\n const message = hexToString(args.params[0]);\n return account.signMessage({ message });\n }\n case 'eth_signTypedData_v4': {\n assertArrayPresence(args.params);\n const typedData = typeof args.params[1] === 'string' ? JSON.parse(args.params[1]) : args.params[1];\n return account.signTypedData(typedData);\n }\n case 'eth_signTypedData_v1':\n case 'eth_signTypedData_v3':\n case 'wallet_addEthereumChain':\n case 'wallet_switchEthereumChain':\n default:\n throw standardErrors.rpc.methodNotSupported();\n }\n }\n catch (error) {\n // Convert error to RPC error if possible\n if (isViemError(error)) {\n const newError = viemHttpErrorToProviderError(error);\n if (newError) {\n throw newError;\n }\n }\n throw error;\n }\n };\n return { request };\n}\n//# sourceMappingURL=createSubAccountSigner.js.map","import { standardErrors } from '../../../core/error/errors.js';\nimport { decodeFunctionData, isAddress, pad } from 'viem';\nimport { getCode, readContract } from 'viem/actions';\nimport { abi, factoryAbi } from './constants.js';\nexport async function findOwnerIndex({ address, client, publicKey, factory, factoryData, }) {\n const code = await getCode(client, {\n address,\n });\n // Check index of owner in the factoryData\n // Note: importing an undeployed contract might need to be handled differently\n // The implemention will likely require the signer to tell us the index\n if (!code && factory && factoryData) {\n const initData = decodeFunctionData({\n abi: factoryAbi,\n data: factoryData,\n });\n if (initData.functionName !== 'createAccount') {\n throw standardErrors.rpc.internal('unknown factory function');\n }\n const [owners] = initData.args;\n return owners.findIndex((owner) => {\n return owner.toLowerCase() === formatPublicKey(publicKey).toLowerCase();\n });\n }\n const ownerCount = await readContract(client, {\n address,\n abi,\n functionName: 'ownerCount',\n });\n // Iterate from highest index down and return early when found\n for (let i = Number(ownerCount) - 1; i >= 0; i--) {\n const owner = await readContract(client, {\n address,\n abi,\n functionName: 'ownerAtIndex',\n args: [BigInt(i)],\n });\n const formatted = formatPublicKey(publicKey);\n if (owner.toLowerCase() === formatted.toLowerCase()) {\n return i;\n }\n }\n return -1;\n}\n/**\n * Formats 20 byte addresses to 32 byte public keys. Contract uses 32 byte keys for owners.\n * @param publicKey - The public key to format\n * @returns The formatted public key\n */\nexport function formatPublicKey(publicKey) {\n if (isAddress(publicKey)) {\n return pad(publicKey);\n }\n return publicKey;\n}\n//# sourceMappingURL=findOwnerIndex.js.map","import { logDialogActionClicked, logDialogDismissed, logDialogShown, } from '../../../core/telemetry/events/dialog.js';\nimport { store } from '../../../store/store.js';\nimport { initDialog } from '../../../ui/Dialog/index.js';\nexport async function presentAddOwnerDialog() {\n const appName = store.config.get().metadata?.appName ?? 'App';\n const dialog = initDialog();\n return new Promise((resolve) => {\n logDialogShown({ dialogContext: 'sub_account_add_owner' });\n dialog.presentItem({\n title: `Re-authorize ${appName}`,\n message: `${appName} has lost access to your account. Please sign at the next step to re-authorize ${appName}`,\n onClose: () => {\n logDialogDismissed({ dialogContext: 'sub_account_add_owner' });\n resolve('cancel');\n },\n actionItems: [\n {\n text: 'Continue',\n variant: 'primary',\n onClick: () => {\n logDialogActionClicked({\n dialogContext: 'sub_account_add_owner',\n dialogAction: 'confirm',\n });\n dialog.clear();\n resolve('authenticate');\n },\n },\n {\n text: 'Not now',\n variant: 'secondary',\n onClick: () => {\n logDialogActionClicked({\n dialogContext: 'sub_account_add_owner',\n dialogAction: 'cancel',\n });\n dialog.clear();\n resolve('cancel');\n },\n },\n ],\n });\n });\n}\n//# sourceMappingURL=presentAddOwnerDialog.js.map","import { standardErrors } from '../../../core/error/errors.js';\nimport { getClient } from '../../../store/chain-clients/utils.js';\nimport { store } from '../../../store/store.js';\nimport { assertPresence } from '../../../util/assertPresence.js';\nimport { decodeAbiParameters, encodeFunctionData, numberToHex, toHex } from 'viem';\nimport { waitForCallsStatus } from 'viem/experimental';\nimport { abi } from './constants.js';\nimport { findOwnerIndex } from './findOwnerIndex.js';\nimport { presentAddOwnerDialog } from './presentAddOwnerDialog.js';\nexport async function handleAddSubAccountOwner({ ownerAccount, globalAccountRequest, chainId, }) {\n const account = store.account.get();\n const subAccount = store.subAccounts.get();\n const globalAccount = account.accounts?.find((account) => account.toLowerCase() !== subAccount?.address.toLowerCase());\n assertPresence(globalAccount, standardErrors.provider.unauthorized('no global account'));\n assertPresence(account.chain?.id, standardErrors.provider.unauthorized('no chain id'));\n assertPresence(subAccount?.address, standardErrors.provider.unauthorized('no sub account'));\n const calls = [];\n if (ownerAccount.type === 'local' && ownerAccount.address) {\n calls.push({\n to: subAccount.address,\n data: encodeFunctionData({\n abi,\n functionName: 'addOwnerAddress',\n args: [ownerAccount.address],\n }),\n value: toHex(0),\n });\n }\n if (ownerAccount.publicKey) {\n const [x, y] = decodeAbiParameters([{ type: 'bytes32' }, { type: 'bytes32' }], ownerAccount.publicKey);\n calls.push({\n to: subAccount.address,\n data: encodeFunctionData({\n abi,\n functionName: 'addOwnerPublicKey',\n args: [x, y],\n }),\n value: toHex(0),\n });\n }\n const request = {\n method: 'wallet_sendCalls',\n params: [\n {\n version: '1',\n calls,\n chainId: numberToHex(chainId),\n from: globalAccount,\n },\n ],\n };\n const selection = await presentAddOwnerDialog();\n if (selection === 'cancel') {\n throw standardErrors.provider.unauthorized('user cancelled');\n }\n const callsId = (await globalAccountRequest(request));\n const client = getClient(account.chain.id);\n assertPresence(client, standardErrors.rpc.internal(`client not found for chainId ${account.chain.id}`));\n const callsResult = await waitForCallsStatus(client, {\n id: callsId,\n });\n if (callsResult.status !== 'success') {\n throw standardErrors.rpc.internal('add owner call failed');\n }\n const ownerIndex = await findOwnerIndex({\n address: subAccount.address,\n publicKey: ownerAccount.type === 'local' && ownerAccount.address\n ? ownerAccount.address\n : ownerAccount.publicKey,\n client,\n });\n if (ownerIndex === -1) {\n throw standardErrors.rpc.internal('failed to find owner index');\n }\n return ownerIndex;\n}\n//# sourceMappingURL=handleAddSubAccountOwner.js.map","import { spendPermissions } from '../../../store/store.js';\nimport { encodeFunctionData, hexToBigInt, } from 'viem';\nimport { createWalletSendCallsRequest, injectRequestCapabilities, isEthSendTransactionParams, isSendCallsParams, waitForCallsTransactionHash, } from '../utils.js';\nimport { abi } from './constants.js';\n/**\n * This function is used to send a request to the global account.\n * It is used to execute a request that requires a spend permission through the global account.\n * @returns The result of the request.\n */\nexport async function routeThroughGlobalAccount({ request, globalAccountAddress, subAccountAddress, client, globalAccountRequest, chainId, prependCalls, }) {\n // Construct call to execute the original calls using executeBatch\n let originalSendCallsParams;\n if (request.method === 'wallet_sendCalls' && isSendCallsParams(request.params)) {\n originalSendCallsParams = request.params[0];\n }\n else if (request.method === 'eth_sendTransaction' &&\n isEthSendTransactionParams(request.params)) {\n const sendCallsRequest = createWalletSendCallsRequest({\n calls: [request.params[0]],\n chainId,\n from: request.params[0].from,\n });\n originalSendCallsParams = sendCallsRequest.params[0];\n }\n else {\n throw new Error(`Could not get original call from ${request.method} request`);\n }\n const subAccountCallData = encodeFunctionData({\n abi,\n functionName: 'executeBatch',\n args: [\n originalSendCallsParams.calls.map((call) => ({\n target: call.to,\n value: hexToBigInt(call.value ?? '0x0'),\n data: call.data ?? '0x',\n })),\n ],\n });\n // Send using wallet_sendCalls\n const calls = [\n ...(prependCalls ?? []),\n { data: subAccountCallData, to: subAccountAddress, value: '0x0' },\n ];\n const requestToParent = injectRequestCapabilities({\n method: 'wallet_sendCalls',\n params: [\n {\n ...originalSendCallsParams,\n calls,\n from: globalAccountAddress,\n version: '2.0.0',\n atomicRequired: true,\n },\n ],\n }, {\n spendPermissions: {\n request: {\n spender: subAccountAddress,\n },\n },\n });\n const result = (await globalAccountRequest(requestToParent));\n let callsId = result.id;\n // Cache returned spend permissions\n if (result.capabilities?.spendPermissions) {\n spendPermissions.set(result.capabilities.spendPermissions.permissions);\n }\n // Wait for transaction hash if sending a transaction\n if (request.method === 'eth_sendTransaction') {\n return waitForCallsTransactionHash({\n client,\n id: callsId,\n });\n }\n return result;\n}\n//# sourceMappingURL=routeThroughGlobalAccount.js.map","import { standardErrors } from '../../../core/error/errors.js';\nimport { assertPresence } from '../../../util/assertPresence.js';\nimport { presentSubAccountFundingDialog } from '../utils.js';\nimport { routeThroughGlobalAccount } from './routeThroughGlobalAccount.js';\nexport async function handleInsufficientBalanceError({ globalAccountAddress, subAccountAddress, client, request, globalAccountRequest, }) {\n const chainId = client.chain?.id;\n assertPresence(chainId, standardErrors.rpc.internal(`invalid chainId`));\n try {\n await presentSubAccountFundingDialog();\n }\n catch {\n throw standardErrors.provider.userRejectedRequest({\n message: 'User cancelled funding',\n });\n }\n const result = await routeThroughGlobalAccount({\n request,\n globalAccountAddress,\n subAccountAddress,\n client,\n globalAccountRequest,\n chainId,\n });\n return result;\n}\n//# sourceMappingURL=handleInsufficientBalance.js.map","import { CB_WALLET_RPC_URL } from '../../core/constants.js';\nimport { hexToNumber, isAddressEqual, numberToHex } from 'viem';\nimport { isActionableHttpRequestError, isViemError, standardErrors } from '../../core/error/errors.js';\nimport { logHandshakeCompleted, logHandshakeError, logHandshakeStarted, logRequestCompleted, logRequestError, logRequestStarted, } from '../../core/telemetry/events/scw-signer.js';\nimport { logAddOwnerCompleted, logAddOwnerError, logAddOwnerStarted, logInsufficientBalanceErrorHandlingCompleted, logInsufficientBalanceErrorHandlingError, logInsufficientBalanceErrorHandlingStarted, logSubAccountRequestCompleted, logSubAccountRequestError, logSubAccountRequestStarted, } from '../../core/telemetry/events/scw-sub-account.js';\nimport { parseErrorMessageFromAny } from '../../core/telemetry/utils.js';\nimport { ensureIntNumber, hexStringFromNumber } from '../../core/type/util.js';\nimport { createClients, getClient } from '../../store/chain-clients/utils.js';\nimport { correlationIds } from '../../store/correlation-ids/store.js';\nimport { spendPermissions, store } from '../../store/store.js';\nimport { assertArrayPresence, assertPresence } from '../../util/assertPresence.js';\nimport { assertSubAccount } from '../../util/assertSubAccount.js';\nimport { decryptContent, encryptContent, exportKeyToHexString, importKeyFromHexString, } from '../../util/cipher.js';\nimport { fetchRPCRequest } from '../../util/provider.js';\nimport { getCryptoKeyAccount } from '../../kms/crypto-key/index.js';\nimport { SCWKeyManager } from './SCWKeyManager.js';\nimport { addSenderToRequest, appendWithoutDuplicates, assertFetchPermissionsRequest, assertGetCapabilitiesParams, assertParamsChainId, fillMissingParamsForFetchPermissions, getSenderFromRequest, initSubAccountConfig, injectRequestCapabilities, makeDataSuffix, prependWithoutDuplicates, } from './utils.js';\nimport { createSubAccountSigner } from './utils/createSubAccountSigner.js';\nimport { findOwnerIndex } from './utils/findOwnerIndex.js';\nimport { handleAddSubAccountOwner } from './utils/handleAddSubAccountOwner.js';\nimport { handleInsufficientBalanceError } from './utils/handleInsufficientBalance.js';\nimport { routeThroughGlobalAccount } from './utils/routeThroughGlobalAccount.js';\nexport class Signer {\n communicator;\n keyManager;\n callback;\n accounts;\n chain;\n constructor(params) {\n this.communicator = params.communicator;\n this.callback = params.callback;\n this.keyManager = new SCWKeyManager();\n const { account, chains } = store.getState();\n this.accounts = account.accounts ?? [];\n this.chain = account.chain ?? {\n id: params.metadata.appChainIds?.[0] ?? 1,\n };\n // Initialize chain clients if chains are provided\n if (chains) {\n createClients(chains);\n }\n // Note: getClient will automatically create fallback clients when needed\n }\n get isConnected() {\n return this.accounts.length > 0;\n }\n async handshake(args) {\n const correlationId = correlationIds.get(args);\n logHandshakeStarted({ method: args.method, correlationId });\n try {\n // Open the popup before constructing the request message.\n // This is to ensure that the popup is not blocked by some browsers (i.e. Safari)\n await this.communicator.waitForPopupLoaded?.();\n const handshakeMessage = await this.createRequestMessage({\n handshake: {\n method: args.method,\n params: args.params ?? [],\n },\n }, correlationId);\n const response = await this.communicator.postRequestAndWaitForResponse(handshakeMessage);\n // store peer's public key\n if ('failure' in response.content) {\n throw response.content.failure;\n }\n const peerPublicKey = await importKeyFromHexString('public', response.sender);\n await this.keyManager.setPeerPublicKey(peerPublicKey);\n const decrypted = await this.decryptResponseMessage(response);\n this.handleResponse(args, decrypted);\n logHandshakeCompleted({ method: args.method, correlationId });\n }\n catch (error) {\n logHandshakeError({\n method: args.method,\n correlationId,\n errorMessage: parseErrorMessageFromAny(error),\n });\n throw error;\n }\n }\n async request(request) {\n const correlationId = correlationIds.get(request);\n logRequestStarted({ method: request.method, correlationId });\n try {\n const result = await this._request(request);\n logRequestCompleted({ method: request.method, correlationId });\n return result;\n }\n catch (error) {\n logRequestError({\n method: request.method,\n correlationId,\n errorMessage: parseErrorMessageFromAny(error),\n });\n throw error;\n }\n }\n async _request(request) {\n if (this.accounts.length === 0) {\n switch (request.method) {\n case 'wallet_switchEthereumChain': {\n assertParamsChainId(request.params);\n this.chain.id = Number(request.params[0].chainId);\n return;\n }\n case 'wallet_connect': {\n // Wait for the popup to be loaded before making async calls\n await this.communicator.waitForPopupLoaded?.();\n await initSubAccountConfig();\n const subAccountsConfig = store.subAccountsConfig.get();\n // Inject capabilities from config (e.g., addSubAccount when creation: 'on-connect')\n const modifiedRequest = injectRequestCapabilities(request, subAccountsConfig?.capabilities ?? {});\n return this.sendRequestToPopup(modifiedRequest);\n }\n case 'wallet_sendCalls':\n case 'wallet_sign': {\n return this.sendRequestToPopup(request);\n }\n default:\n throw standardErrors.provider.unauthorized();\n }\n }\n if (this.shouldRequestUseSubAccountSigner(request)) {\n const correlationId = correlationIds.get(request);\n logSubAccountRequestStarted({ method: request.method, correlationId });\n try {\n const result = await this.sendRequestToSubAccountSigner(request);\n logSubAccountRequestCompleted({ method: request.method, correlationId });\n return result;\n }\n catch (error) {\n logSubAccountRequestError({\n method: request.method,\n correlationId,\n errorMessage: parseErrorMessageFromAny(error),\n });\n throw error;\n }\n }\n switch (request.method) {\n case 'eth_requestAccounts':\n case 'eth_accounts': {\n const subAccount = store.subAccounts.get();\n const subAccountsConfig = store.subAccountsConfig.get();\n if (subAccount?.address) {\n // if defaultAccount is 'sub' and we have a sub account, we need to return it as the first account\n // otherwise, we just append it to the accounts array\n this.accounts =\n subAccountsConfig?.defaultAccount === 'sub'\n ? prependWithoutDuplicates(this.accounts, subAccount.address)\n : appendWithoutDuplicates(this.accounts, subAccount.address);\n }\n this.callback?.('connect', { chainId: numberToHex(this.chain.id) });\n return this.accounts;\n }\n case 'eth_coinbase':\n return this.accounts[0];\n case 'net_version':\n return this.chain.id;\n case 'eth_chainId':\n return numberToHex(this.chain.id);\n case 'wallet_getCapabilities':\n return this.handleGetCapabilitiesRequest(request);\n case 'wallet_switchEthereumChain':\n return this.handleSwitchChainRequest(request);\n case 'eth_ecRecover':\n case 'personal_sign':\n case 'wallet_sign':\n case 'personal_ecRecover':\n case 'eth_signTransaction':\n case 'eth_sendTransaction':\n case 'eth_signTypedData_v1':\n case 'eth_signTypedData_v3':\n case 'eth_signTypedData_v4':\n case 'eth_signTypedData':\n case 'wallet_addEthereumChain':\n case 'wallet_watchAsset':\n case 'wallet_sendCalls':\n case 'wallet_showCallsStatus':\n case 'wallet_grantPermissions':\n return this.sendRequestToPopup(request);\n case 'wallet_connect': {\n // Wait for the popup to be loaded before making async calls\n await this.communicator.waitForPopupLoaded?.();\n await initSubAccountConfig();\n const subAccountsConfig = store.subAccountsConfig.get();\n const modifiedRequest = injectRequestCapabilities(request, subAccountsConfig?.capabilities ?? {});\n const result = await this.sendRequestToPopup(modifiedRequest);\n this.callback?.('connect', { chainId: numberToHex(this.chain.id) });\n return result;\n }\n // Sub Account Support\n case 'wallet_getSubAccounts': {\n const subAccount = store.subAccounts.get();\n if (subAccount?.address) {\n return {\n subAccounts: [subAccount],\n };\n }\n if (!this.chain.rpcUrl) {\n throw standardErrors.rpc.internal('No RPC URL set for chain');\n }\n const response = (await fetchRPCRequest(request, this.chain.rpcUrl));\n assertArrayPresence(response.subAccounts, 'subAccounts');\n if (response.subAccounts.length > 0) {\n // cache the sub account\n assertSubAccount(response.subAccounts[0]);\n const subAccount = response.subAccounts[0];\n store.subAccounts.set({\n address: subAccount.address,\n factory: subAccount.factory,\n factoryData: subAccount.factoryData,\n });\n }\n return response;\n }\n case 'wallet_addSubAccount':\n return this.addSubAccount(request);\n case 'coinbase_fetchPermissions': {\n assertFetchPermissionsRequest(request);\n const completeRequest = fillMissingParamsForFetchPermissions(request);\n const permissions = (await fetchRPCRequest(completeRequest, CB_WALLET_RPC_URL));\n const requestedChainId = hexToNumber(completeRequest.params?.[0].chainId);\n store.spendPermissions.set(permissions.permissions.map((permission) => ({\n ...permission,\n chainId: requestedChainId,\n })));\n return permissions;\n }\n case 'coinbase_fetchPermission': {\n const fetchPermissionRequest = request;\n const response = (await fetchRPCRequest(fetchPermissionRequest, CB_WALLET_RPC_URL));\n // Store the single permission if it has a chainId\n if (response.permission && response.permission.chainId) {\n store.spendPermissions.set([response.permission]);\n }\n return response;\n }\n default:\n if (!this.chain.rpcUrl) {\n throw standardErrors.rpc.internal('No RPC URL set for chain');\n }\n return fetchRPCRequest(request, this.chain.rpcUrl);\n }\n }\n async sendRequestToPopup(request) {\n // Open the popup before constructing the request message.\n // This is to ensure that the popup is not blocked by some browsers (i.e. Safari)\n await this.communicator.waitForPopupLoaded?.();\n const response = await this.sendEncryptedRequest(request);\n const decrypted = await this.decryptResponseMessage(response);\n return this.handleResponse(request, decrypted);\n }\n async handleResponse(request, decrypted) {\n const result = decrypted.result;\n if ('error' in result)\n throw result.error;\n switch (request.method) {\n case 'eth_requestAccounts': {\n const accounts = result.value;\n this.accounts = accounts;\n store.account.set({\n accounts,\n chain: this.chain,\n });\n this.callback?.('accountsChanged', accounts);\n break;\n }\n case 'wallet_connect': {\n const response = result.value;\n const accounts = response.accounts.map((account) => account.address);\n this.accounts = accounts;\n store.account.set({\n accounts,\n });\n const account = response.accounts.at(0);\n const capabilities = account?.capabilities;\n if (capabilities?.subAccounts) {\n const capabilityResponse = capabilities?.subAccounts;\n assertArrayPresence(capabilityResponse, 'subAccounts');\n assertSubAccount(capabilityResponse[0]);\n store.subAccounts.set({\n address: capabilityResponse[0].address,\n factory: capabilityResponse[0].factory,\n factoryData: capabilityResponse[0].factoryData,\n });\n }\n const subAccount = store.subAccounts.get();\n const subAccountsConfig = store.subAccountsConfig.get();\n if (subAccount?.address) {\n // Sub account should be returned as the default account if defaultAccount is 'sub'\n this.accounts =\n subAccountsConfig?.defaultAccount === 'sub'\n ? prependWithoutDuplicates(this.accounts, subAccount.address)\n : appendWithoutDuplicates(this.accounts, subAccount.address);\n }\n const spendPermissions = response?.accounts?.[0].capabilities?.spendPermissions;\n if (spendPermissions && 'permissions' in spendPermissions) {\n store.spendPermissions.set(spendPermissions?.permissions);\n }\n this.callback?.('accountsChanged', this.accounts);\n break;\n }\n case 'wallet_addSubAccount': {\n assertSubAccount(result.value);\n const subAccount = result.value;\n store.subAccounts.set(subAccount);\n const subAccountsConfig = store.subAccountsConfig.get();\n this.accounts =\n subAccountsConfig?.defaultAccount === 'sub'\n ? prependWithoutDuplicates(this.accounts, subAccount.address)\n : appendWithoutDuplicates(this.accounts, subAccount.address);\n this.callback?.('accountsChanged', this.accounts);\n break;\n }\n default:\n break;\n }\n return result.value;\n }\n async cleanup() {\n const metadata = store.config.get().metadata;\n await this.keyManager.clear();\n // clear the store\n store.account.clear();\n store.subAccounts.clear();\n store.spendPermissions.clear();\n store.chains.clear();\n // reset the signer\n this.accounts = [];\n this.chain = {\n id: metadata?.appChainIds?.[0] ?? 1,\n };\n }\n /**\n * @returns `null` if the request was successful.\n * https://eips.ethereum.org/EIPS/eip-3326#wallet_switchethereumchain\n */\n async handleSwitchChainRequest(request) {\n assertParamsChainId(request.params);\n const chainId = ensureIntNumber(request.params[0].chainId);\n const localResult = this.updateChain(chainId);\n if (localResult)\n return null;\n const popupResult = await this.sendRequestToPopup(request);\n if (popupResult === null) {\n this.updateChain(chainId);\n }\n return popupResult;\n }\n async handleGetCapabilitiesRequest(request) {\n assertGetCapabilitiesParams(request.params);\n const requestedAccount = request.params[0];\n const filterChainIds = request.params[1]; // Optional second parameter\n if (!this.accounts.some((account) => isAddressEqual(account, requestedAccount))) {\n throw standardErrors.provider.unauthorized('no active account found when getting capabilities');\n }\n const capabilities = store.getState().account.capabilities;\n // Return empty object if capabilities is undefined\n if (!capabilities) {\n return {};\n }\n // If no filter is provided, return all capabilities\n if (!filterChainIds || filterChainIds.length === 0) {\n return capabilities;\n }\n // Convert filter chain IDs to numbers once for efficient lookup\n const filterChainNumbers = new Set(filterChainIds.map((chainId) => hexToNumber(chainId)));\n // Filter capabilities\n const filteredCapabilities = Object.fromEntries(Object.entries(capabilities).filter(([capabilityKey]) => {\n try {\n const capabilityChainNumber = hexToNumber(capabilityKey);\n return filterChainNumbers.has(capabilityChainNumber);\n }\n catch {\n // If capabilityKey is not a valid hex string, exclude it\n return false;\n }\n }));\n return filteredCapabilities;\n }\n async sendEncryptedRequest(request) {\n const sharedSecret = await this.keyManager.getSharedSecret();\n if (!sharedSecret) {\n throw standardErrors.provider.unauthorized('No shared secret found when encrypting request');\n }\n const encrypted = await encryptContent({\n action: request,\n chainId: this.chain.id,\n }, sharedSecret);\n const correlationId = correlationIds.get(request);\n const message = await this.createRequestMessage({ encrypted }, correlationId);\n return this.communicator.postRequestAndWaitForResponse(message);\n }\n async createRequestMessage(content, correlationId) {\n const publicKey = await exportKeyToHexString('public', await this.keyManager.getOwnPublicKey());\n return {\n id: crypto.randomUUID(),\n correlationId,\n sender: publicKey,\n content,\n timestamp: new Date(),\n };\n }\n async decryptResponseMessage(message) {\n const content = message.content;\n // throw protocol level error\n if ('failure' in content) {\n throw content.failure;\n }\n const sharedSecret = await this.keyManager.getSharedSecret();\n if (!sharedSecret) {\n throw standardErrors.provider.unauthorized('Invalid session: no shared secret found when decrypting response');\n }\n const response = await decryptContent(content.encrypted, sharedSecret);\n const availableChains = response.data?.chains;\n if (availableChains) {\n const nativeCurrencies = response.data?.nativeCurrencies;\n const chains = Object.entries(availableChains).map(([id, rpcUrl]) => {\n const nativeCurrency = nativeCurrencies?.[Number(id)];\n return {\n id: Number(id),\n rpcUrl,\n ...(nativeCurrency ? { nativeCurrency } : {}),\n };\n });\n store.chains.set(chains);\n this.updateChain(this.chain.id, chains);\n createClients(chains);\n }\n const walletCapabilities = response.data?.capabilities;\n if (walletCapabilities) {\n store.account.set({\n capabilities: walletCapabilities,\n });\n }\n return response;\n }\n updateChain(chainId, newAvailableChains) {\n const state = store.getState();\n const chains = newAvailableChains ?? state.chains;\n const chain = chains?.find((chain) => chain.id === chainId);\n if (!chain)\n return false;\n if (chain !== this.chain) {\n this.chain = chain;\n store.account.set({\n chain,\n });\n this.callback?.('chainChanged', hexStringFromNumber(chain.id));\n }\n return true;\n }\n async addSubAccount(request) {\n const state = store.getState();\n const subAccount = state.subAccount;\n const subAccountsConfig = store.subAccountsConfig.get();\n if (subAccount?.address) {\n this.accounts =\n subAccountsConfig?.defaultAccount === 'sub'\n ? prependWithoutDuplicates(this.accounts, subAccount.address)\n : appendWithoutDuplicates(this.accounts, subAccount.address);\n this.callback?.('accountsChanged', this.accounts);\n return subAccount;\n }\n // Wait for the popup to be loaded before sending the request\n await this.communicator.waitForPopupLoaded?.();\n if (Array.isArray(request.params) &&\n request.params.length > 0 &&\n request.params[0].account &&\n request.params[0].account.type === 'create') {\n let keys;\n if (request.params[0].account.keys && request.params[0].account.keys.length > 0) {\n keys = request.params[0].account.keys;\n }\n else {\n const config = store.subAccountsConfig.get() ?? {};\n const { account: ownerAccount } = config.toOwnerAccount\n ? await config.toOwnerAccount()\n : await getCryptoKeyAccount();\n if (!ownerAccount) {\n throw standardErrors.provider.unauthorized('could not get subaccount owner account when adding sub account');\n }\n keys = [\n {\n type: ownerAccount.address ? 'address' : 'webauthn-p256',\n publicKey: ownerAccount.address || ownerAccount.publicKey,\n },\n ];\n }\n request.params[0].account.keys = keys;\n }\n const response = await this.sendRequestToPopup(request);\n assertSubAccount(response);\n return response;\n }\n shouldRequestUseSubAccountSigner(request) {\n const sender = getSenderFromRequest(request);\n const subAccount = store.subAccounts.get();\n if (sender) {\n return sender.toLowerCase() === subAccount?.address.toLowerCase();\n }\n return false;\n }\n async sendRequestToSubAccountSigner(request) {\n const subAccount = store.subAccounts.get();\n const subAccountsConfig = store.subAccountsConfig.get();\n const config = store.config.get();\n assertPresence(subAccount?.address, standardErrors.provider.unauthorized('no active sub account when sending request to sub account signer'));\n // Get the owner account from the config\n const ownerAccount = subAccountsConfig?.toOwnerAccount\n ? await subAccountsConfig.toOwnerAccount()\n : await getCryptoKeyAccount();\n assertPresence(ownerAccount?.account, standardErrors.provider.unauthorized('no active sub account owner when sending request to sub account signer'));\n const sender = getSenderFromRequest(request);\n // if sender is undefined, we inject the active sub account\n // address into the params for the supported request methods\n if (sender === undefined) {\n request = addSenderToRequest(request, subAccount.address);\n }\n const globalAccountAddress = this.accounts.find((account) => account.toLowerCase() !== subAccount.address.toLowerCase());\n assertPresence(globalAccountAddress, standardErrors.provider.unauthorized('no global account found when sending request to sub account signer'));\n const dataSuffix = makeDataSuffix({\n attribution: config.preference?.attribution,\n dappOrigin: window.location.origin,\n });\n // Determine effective chainId - use request chainId for wallet_sendCalls, default otherwise\n const walletSendCallsChainId = request.method === 'wallet_sendCalls' &&\n request.params?.[0]?.chainId;\n const chainId = walletSendCallsChainId ? hexToNumber(walletSendCallsChainId) : this.chain.id;\n const client = getClient(chainId);\n assertPresence(client, standardErrors.rpc.internal(`client not found for chainId ${chainId} when sending request to sub account signer`));\n if (['eth_sendTransaction', 'wallet_sendCalls'].includes(request.method)) {\n // If we have never had a spend permission, we need to do this tx through the global account\n // Only perform this check if funding mode is 'spend-permissions'\n const subAccountsConfig = store.subAccountsConfig.get();\n if (subAccountsConfig?.funding === 'spend-permissions') {\n const storedSpendPermissions = spendPermissions.get();\n if (storedSpendPermissions.length === 0) {\n const result = await routeThroughGlobalAccount({\n request,\n globalAccountAddress,\n subAccountAddress: subAccount.address,\n client,\n globalAccountRequest: this.sendRequestToPopup.bind(this),\n chainId,\n });\n return result;\n }\n }\n }\n const publicKey = ownerAccount.account.type === 'local'\n ? ownerAccount.account.address\n : ownerAccount.account.publicKey;\n let ownerIndex = await findOwnerIndex({\n address: subAccount.address,\n factory: subAccount.factory,\n factoryData: subAccount.factoryData,\n publicKey,\n client,\n });\n if (ownerIndex === -1) {\n const correlationId = correlationIds.get(request);\n logAddOwnerStarted({ method: request.method, correlationId });\n try {\n ownerIndex = await handleAddSubAccountOwner({\n ownerAccount: ownerAccount.account,\n globalAccountRequest: this.sendRequestToPopup.bind(this),\n chainId: chainId,\n });\n logAddOwnerCompleted({ method: request.method, correlationId });\n }\n catch (error) {\n logAddOwnerError({\n method: request.method,\n correlationId,\n errorMessage: parseErrorMessageFromAny(error),\n });\n return standardErrors.provider.unauthorized('failed to add sub account owner when sending request to sub account signer');\n }\n }\n const { request: subAccountRequest } = await createSubAccountSigner({\n address: subAccount.address,\n owner: ownerAccount.account,\n client: client,\n factory: subAccount.factory,\n factoryData: subAccount.factoryData,\n parentAddress: globalAccountAddress,\n attribution: dataSuffix ? { suffix: dataSuffix } : undefined,\n ownerIndex,\n });\n try {\n const result = await subAccountRequest(request);\n return result;\n }\n catch (error) {\n // Skip insufficient balance error handling if funding mode is 'manual'\n const subAccountsConfig = store.subAccountsConfig.get();\n if (subAccountsConfig?.funding === 'manual') {\n throw error;\n }\n let errorObject;\n if (isViemError(error)) {\n errorObject = JSON.parse(error.details);\n }\n else if (isActionableHttpRequestError(error)) {\n errorObject = error;\n }\n else {\n throw error;\n }\n if (!(isActionableHttpRequestError(errorObject) && errorObject.data)) {\n throw error;\n }\n if (!errorObject.data) {\n throw error;\n }\n const correlationId = correlationIds.get(request);\n logInsufficientBalanceErrorHandlingStarted({ method: request.method, correlationId });\n try {\n const result = await handleInsufficientBalanceError({\n errorData: errorObject.data,\n globalAccountAddress,\n subAccountAddress: subAccount.address,\n client,\n request,\n globalAccountRequest: this.request.bind(this),\n });\n logInsufficientBalanceErrorHandlingCompleted({ method: request.method, correlationId });\n return result;\n }\n catch (handlingError) {\n console.error(handlingError);\n logInsufficientBalanceErrorHandlingError({\n method: request.method,\n correlationId,\n errorMessage: parseErrorMessageFromAny(handlingError),\n });\n throw error;\n }\n }\n }\n}\n//# sourceMappingURL=Signer.js.map","import { Communicator } from '../../../core/communicator/Communicator.js';\nimport { CB_WALLET_RPC_URL } from '../../../core/constants.js';\nimport { standardErrorCodes } from '../../../core/error/constants.js';\nimport { standardErrors } from '../../../core/error/errors.js';\nimport { serializeError } from '../../../core/error/serialize.js';\nimport { ProviderEventEmitter, } from '../../../core/provider/interface.js';\nimport { logRequestError, logRequestResponded, logRequestStarted, } from '../../../core/telemetry/events/provider.js';\nimport { parseErrorMessageFromAny } from '../../../core/telemetry/utils.js';\nimport { hexStringFromNumber } from '../../../core/type/util.js';\nimport { Signer } from '../../../sign/base-account/Signer.js';\nimport { initSubAccountConfig } from '../../../sign/base-account/utils.js';\nimport { correlationIds } from '../../../store/correlation-ids/store.js';\nimport { store } from '../../../store/store.js';\nimport { checkErrorForInvalidRequestArgs, fetchRPCRequest } from '../../../util/provider.js';\nexport class BaseAccountProvider extends ProviderEventEmitter {\n communicator;\n signer;\n constructor({ metadata, preference: { walletUrl, ...preference }, }) {\n super();\n this.communicator = new Communicator({\n url: walletUrl,\n metadata,\n preference,\n });\n this.signer = new Signer({\n metadata,\n communicator: this.communicator,\n callback: this.emit.bind(this),\n });\n }\n async request(args) {\n // correlation id across the entire request lifecycle\n const correlationId = crypto.randomUUID();\n correlationIds.set(args, correlationId);\n logRequestStarted({ method: args.method, correlationId });\n try {\n const result = await this._request(args);\n logRequestResponded({\n method: args.method,\n correlationId,\n });\n return result;\n }\n catch (error) {\n logRequestError({\n method: args.method,\n correlationId,\n errorMessage: parseErrorMessageFromAny(error),\n });\n throw error;\n }\n finally {\n correlationIds.delete(args);\n }\n }\n async _request(args) {\n try {\n checkErrorForInvalidRequestArgs(args);\n if (!this.signer.isConnected) {\n switch (args.method) {\n case 'eth_requestAccounts': {\n await this.signer.handshake({ method: 'handshake' });\n // We are translating eth_requestAccounts to wallet_connect always\n await initSubAccountConfig();\n await this.signer.request({\n method: 'wallet_connect',\n params: [\n {\n version: '1',\n capabilities: {\n ...(store.subAccountsConfig.get()?.capabilities ?? {}),\n },\n },\n ],\n });\n // wallet_connect will retrieve and save the account info in the store\n // continue to requesting it again at L130 for emitting the connect event +\n // returning the accounts\n break;\n }\n case 'wallet_connect': {\n await this.signer.handshake({ method: 'handshake' }); // exchange session keys\n const result = await this.signer.request(args); // send diffie-hellman encrypted request\n return result;\n }\n case 'wallet_switchEthereumChain': {\n // wallet_switchEthereumChain does not need to be sent to the popup\n // it is handled by the base account signer\n // so we just return the result\n const result = await this.signer.request(args);\n return result;\n }\n case 'wallet_sendCalls':\n case 'wallet_sign': {\n try {\n await this.signer.handshake({ method: 'handshake' }); // exchange session keys\n const result = await this.signer.request(args); // send diffie-hellman encrypted request\n return result;\n }\n finally {\n await this.signer.cleanup(); // clean up (rotate) the ephemeral session keys\n }\n }\n case 'wallet_getCallsStatus': {\n const result = await fetchRPCRequest(args, CB_WALLET_RPC_URL);\n return result;\n }\n case 'eth_accounts': {\n return [];\n }\n case 'net_version': {\n const result = 1; // default value\n return result;\n }\n case 'eth_chainId': {\n const result = hexStringFromNumber(1); // default value\n return result;\n }\n default: {\n throw standardErrors.provider.unauthorized(\"Must call 'eth_requestAccounts' before other methods\");\n }\n }\n }\n const result = await this.signer.request(args);\n return result;\n }\n catch (error) {\n const { code } = error;\n if (code === standardErrorCodes.provider.unauthorized) {\n await this.disconnect();\n }\n return Promise.reject(serializeError(error));\n }\n }\n async disconnect() {\n await this.signer.cleanup();\n correlationIds.clear();\n this.emit('disconnect', standardErrors.provider.disconnected('User initiated disconnection'));\n }\n isBaseAccount = true;\n}\n//# sourceMappingURL=BaseAccountProvider.js.map","const TBA_PROVIDER_IDENTIFIER = 'isCoinbaseBrowser';\nexport function getInjectedProvider() {\n const injectedProvider = window.top?.ethereum ?? window.ethereum;\n if (injectedProvider?.[TBA_PROVIDER_IDENTIFIER]) {\n return injectedProvider;\n }\n return null;\n}\n//# sourceMappingURL=getInjectedProvider.js.map","import { loadTelemetryScript } from '../../../core/telemetry/initCCA.js';\nimport { abi } from '../../../sign/base-account/utils/constants.js';\nimport { store } from '../../../store/store.js';\nimport { assertPresence } from '../../../util/assertPresence.js';\nimport { checkCrossOriginOpenerPolicy } from '../../../util/checkCrossOriginOpenerPolicy.js';\nimport { validatePreferences, validateSubAccount } from '../../../util/validatePreferences.js';\nimport { decodeAbiParameters, encodeFunctionData, toHex } from 'viem';\nimport { BaseAccountProvider } from './BaseAccountProvider.js';\nimport { getInjectedProvider } from './getInjectedProvider.js';\n/**\n * Create Base AccountSDK instance with EIP-1193 compliant provider\n * @param params - Options to create a base account SDK instance.\n * @returns An SDK object with a getProvider method that returns an EIP-1193 compliant provider.\n */\nexport function createBaseAccountSDK(params) {\n const options = {\n metadata: {\n appName: params.appName || 'App',\n appLogoUrl: params.appLogoUrl || '',\n appChainIds: params.appChainIds || [],\n },\n preference: params.preference ?? {},\n paymasterUrls: params.paymasterUrls,\n };\n // ====================================================================\n // If we have a toOwnerAccount function, set it in the non-persisted config\n // ====================================================================\n if (params.subAccounts?.toOwnerAccount) {\n validateSubAccount(params.subAccounts.toOwnerAccount);\n }\n store.subAccountsConfig.set({\n toOwnerAccount: params.subAccounts?.toOwnerAccount,\n creation: params.subAccounts?.creation ?? 'manual',\n defaultAccount: params.subAccounts?.defaultAccount ?? 'universal',\n funding: params.subAccounts?.funding ?? 'spend-permissions',\n });\n // ====================================================================\n // Set the options in the store and rehydrate the store from storage\n // ====================================================================\n store.config.set(options);\n void store.persist.rehydrate();\n // ====================================================================\n // Validation and telemetry\n // ====================================================================\n void checkCrossOriginOpenerPolicy();\n validatePreferences(options.preference);\n if (options.preference.telemetry !== false) {\n void loadTelemetryScript();\n }\n // ====================================================================\n // Return the provider\n // ====================================================================\n let provider = null;\n const sdk = {\n getProvider: () => {\n if (!provider) {\n provider = getInjectedProvider() ?? new BaseAccountProvider(options);\n }\n return provider;\n },\n subAccount: {\n async create(accountParam) {\n return (await sdk.getProvider()?.request({\n method: 'wallet_addSubAccount',\n params: [\n {\n version: '1',\n account: accountParam,\n },\n ],\n }));\n },\n async get() {\n const subAccount = store.subAccounts.get();\n if (subAccount?.address) {\n return subAccount;\n }\n const response = (await sdk.getProvider()?.request({\n method: 'wallet_connect',\n params: [\n {\n version: '1',\n capabilities: {},\n },\n ],\n }));\n const subAccounts = response.accounts[0].capabilities?.subAccounts;\n if (!Array.isArray(subAccounts)) {\n return null;\n }\n return subAccounts[0];\n },\n addOwner: async ({ address, publicKey, chainId, }) => {\n const subAccount = store.subAccounts.get();\n const account = store.account.get();\n assertPresence(account, new Error('account does not exist'));\n assertPresence(subAccount?.address, new Error('subaccount does not exist'));\n const calls = [];\n if (publicKey) {\n const [x, y] = decodeAbiParameters([{ type: 'bytes32' }, { type: 'bytes32' }], publicKey);\n calls.push({\n to: subAccount.address,\n data: encodeFunctionData({\n abi,\n functionName: 'addOwnerPublicKey',\n args: [x, y],\n }),\n value: toHex(0),\n });\n }\n if (address) {\n calls.push({\n to: subAccount.address,\n data: encodeFunctionData({\n abi,\n functionName: 'addOwnerAddress',\n args: [address],\n }),\n value: toHex(0),\n });\n }\n return (await sdk.getProvider()?.request({\n method: 'wallet_sendCalls',\n params: [\n {\n calls,\n chainId: toHex(chainId),\n from: account.accounts?.[0],\n version: '1',\n },\n ],\n }));\n },\n setToOwnerAccount(toSubAccountOwner) {\n validateSubAccount(toSubAccountOwner);\n store.subAccountsConfig.set({\n toOwnerAccount: toSubAccountOwner,\n });\n },\n },\n };\n return sdk;\n}\n//# sourceMappingURL=createBaseAccountSDK.js.map"],"names":["encodePacked","types","values","AbiEncodingLengthMismatchError","data","i","type","value","encode","concatHex","isArray","address","isAddress","InvalidAddressError","pad","stringToHex","boolToHex","intMatch","integerRegex","_type","baseType","bits","size","numberToHex","bytesMatch","bytesRegex","BytesSizeMismatchError","arrayMatch","arrayRegex","childType","UnsupportedPackedAbiType","createNonceManager","parameters","source","deltaMap","nonceMap","LruMap","promiseMap","getKey","chainId","client","key","promise","nonce","delta","previousNonce","erc6492MagicBytes","serializeErc6492Signature","signature","to","signature_","encodeAbiParameters","hexToBytes","createPublicClient","name","createClient","publicActions","parseSignature","signatureHex","r","s","secp256k1","yParityOrV","v","yParity","sourceId","zora","defineChain","chainConfig","createJSONStorage","getStorage","options","storage","_a","parse","str2","str","newValue","toThenable","fn","input","result","onFulfilled","_onRejected","e","_onFulfilled","onRejected","persistImpl","config","baseOptions","set","get","api","state","persistedState","currentState","hasHydrated","hydrationListeners","finishHydrationListeners","args","setItem","savedSetState","replace","configResult","stateFromStorage","hydrate","_b","cb","_a2","postRehydrationCallback","deserializedStorageValue","migration","migrationResult","migrated","migratedState","newOptions","persist","createStoreImpl","createState","listeners","setState","partial","nextState","previousState","listener","getState","initialState","createStore","CB_KEYS_URL","CB_WALLET_RPC_URL","PACKAGE_NAME","pkg","PACKAGE_VERSION","createChainSlice","createKeysSlice","createAccountSlice","createSubAccountSlice","createSubAccountConfigSlice","createSpendPermissionsSlice","createConfigSlice","sdkstore","subAccountsConfig","subAccountConfig","subAccounts","subAccount","spendPermissions","account","chains","keys","actions","store","TELEMETRY_SCRIPT_CONTENT","loadTelemetryScript","resolve","reject","script","initCCA","deviceId","init","identify","PlatformName","factoryAddress","abi","factoryAbi","standardErrorCodes","errorValues","FALLBACK_MESSAGE","JSON_RPC_SERVER_ERROR_MESSAGE","getMessageFromCode","code","fallbackMessage","codeString","hasKey","isJsonRpcServerError","isValidCode","serialize","error","shouldIncludeStack","serialized","_error","assignOriginalError","hasStringProperty","obj","prop","standardErrors","arg","getEthJsonRpcError","opts","getEthProviderError","message","EthereumProviderError","parseOpts","EthereumRpcError","__publicField","isValidEthProviderCode","isActionableHttpRequestError","errorObject","isViemError","viemHttpErrorToProviderError","details","assertPresence","assertArrayPresence","COOP_ERROR_MESSAGE","createCoopChecker","crossOriginOpenerPolicy","url","response","checkCrossOriginOpenerPolicy","getCrossOriginOpenerPolicy","validatePreferences","preference","validateSubAccount","toAccount","ComponentType","ActionType","AnalyticsEventImportance","logEvent","event","importance","logPopupSetupStarted","logPopupSetupCompleted","logPopupUnloadReceived","logDialogShown","dialogContext","logDialogDismissed","logDialogActionClicked","dialogAction","FONT_FACE_CSS","FONT_NAME","injectFontStyle","style","n","l","u","o","f","c","h","p","y","d","w","_","t","g","b","k","x","C","M","P","O","j","S","a","$","N","I","L","V","T","A","F","m","H","q","z","B","clsx","getDisplayableUsername","truncateAddress","length","WHITE","BRAND_BLUE","BaseLogo","fill","_jsx","D","css","closeIcon","isPhonePortrait","DialogHandleBar","showHandleBar","setShowHandleBar","useState","useEffect","checkOrientation","Dialog","el","itemProps","render","DialogContainer","_createElement","DialogInstance","props","dragY","setDragY","isDragging","setIsDragging","startY","setStartY","handleTouchStart","touch","handleTouchMove","deltaY","handleTouchEnd","closeButton","_jsxs","title","actionItems","handleClose","hidden","setHidden","isLoadingUsername","setIsLoadingUsername","username","setUsername","timer","headerTitle","useMemo","shouldShowHeaderTitle","action","dialog","initDialog","root","POPUP_WIDTH","POPUP_HEIGHT","POPUP_BLOCKED_TITLE","POPUP_BLOCKED_MESSAGE","openPopup","left","top","appendAppInfoQueryParams","tryOpenPopup","popupId","popup","openPopupWithDialog","closePopup","params","dappName","Communicator","metadata","request","responsePromise","requestId","predicate","serializeError","getErrorObject","docUrl","isErrorResponse","ProviderEventEmitter","EventEmitter","logRequestStarted","method","correlationId","logRequestError","errorMessage","logRequestResponded","parseErrorMessageFromAny","errorOrAny","OpaqueType","HexString","IntNumber","num","INT_STRING_REGEX","HEXADECIMAL_STRING_REGEX","uint8ArrayToHex","hexStringToUint8Array","hexString","byte","hexStringFromNumber","has0xPrefix","strip0x","hex","isHexString","ensureHexString","includePrefix","ensureEvenLengthHexString","ensureIntNumber","logHandshakeStarted","logHandshakeError","logHandshakeCompleted","logRequestCompleted","logSubAccountRequestStarted","logSubAccountRequestCompleted","logSubAccountRequestError","logAddOwnerStarted","logAddOwnerCompleted","logAddOwnerError","logInsufficientBalanceErrorHandlingStarted","logInsufficientBalanceErrorHandlingCompleted","logInsufficientBalanceErrorHandlingError","entryPoint06Abi","entryPoint06Address","getInitCode","userOperation","forHash","authorization","factory","factoryData","concat","paymasterSignatureMagic","toPackedUserOperation","callGasLimit","callData","maxPriorityFeePerGas","maxFeePerGas","paymaster","paymasterData","paymasterPostOpGasLimit","paymasterSignature","paymasterVerificationGasLimit","sender","verificationGasLimit","accountGasLimits","initCode","gasFees","paymasterAndData","preVerificationGas","getUserOperationTypedData","entryPointAddress","packedUserOp","getUserOperationHash","entryPointVersion","hashTypedData","keccak256","toSmartAccount","implementation","extend","nonceKeyManager","rest","deployed","readContract","parseAbi","getAction","getCode","AccountNotDeployedError","BaseError","cause","ExecutionRevertedError","reason","FailedToSendToBeneficiaryError","GasValuesOverflowError","HandleOpsOutOfGasError","InitCodeFailedError","InitCodeMustCreateSenderError","InitCodeMustReturnSenderError","InsufficientPrefundError","InternalCallOnlyError","InvalidAggregatorError","InvalidAccountNonceError","InvalidBeneficiaryError","InvalidFieldsError","InvalidPaymasterAndDataError","PaymasterDepositTooLowError","PaymasterFunctionRevertedError","PaymasterNotDeployedError","PaymasterRateLimitError","PaymasterStakeTooLowError","PaymasterPostOpFunctionRevertedError","SenderAlreadyConstructedError","SignatureCheckFailedError","SmartAccountFunctionRevertedError","UnsupportedSignatureAggregatorError","UserOperationExpiredError","UserOperationPaymasterExpiredError","UserOperationSignatureError","UserOperationPaymasterSignatureError","UserOperationRejectedByEntryPointError","UserOperationRejectedByPaymasterError","UserOperationRejectedByOpCodeError","UserOperationOutOfTimeRangeError","UnknownBundlerError","VerificationGasLimitExceededError","VerificationGasLimitTooLowError","UserOperationExecutionError","docsPath","prettyArgs","prettyPrint","formatGwei","UserOperationReceiptNotFoundError","hash","UserOperationNotFoundError","WaitForUserOperationReceiptTimeoutError","bundlerErrors","getBundlerError","err","getUserOperationError","calls","revertData","getRevertData","contractCalls","call","getContractError","match","_d","_c","functionName","compatContractCalls","decodeErrorResult","acc","ContractFunctionZeroDataError","ContractFunctionRevertedError","ContractFunctionExecutionError","formatUserOperationGas","gas","formatUserOperationRequest","rpcRequest","formatAuthorization","getPaymasterData","context","hexToBigInt","getPaymasterStubData","defaultParameters","prepareUserOperation","parameters_","account_","dataSuffix","properties","stateOverride","AccountNotFoundError","parseAccount","bundlerClient","paymasterAddress","getPaymasterStubData_","getPaymasterData_","paymasterContext","fees","call_","encodeFunctionData","client_","estimateFeesPerGas","prepareAuthorization","getChainId","getChainId_","isPaymasterPopulated","isFinal","paymasterArgs","estimateUserOperationGas","rpcStateOverride","serializeStateOverride","getSupportedEntryPoints","formatUserOperation","getUserOperation","blockHash","blockNumber","entryPoint","transactionHash","formatUserOperationReceipt","receipt","log","formatLog","formatTransactionReceipt","getUserOperationReceipt","sendUserOperation","rpcParameters","waitForUserOperationReceipt","pollingInterval","retryCount","timeout","count","observerId","stringify","unobserve","observe","emit","done","unpoll","timeoutId","poll","bundlerActions","createBundlerClient","transport","ChainClients","SUPPORTED_MAINNET_CHAINS","base","avalanche","arbitrum","polygon","mainnet","bsc","optimism","SUPPORTED_TESTNET_CHAINS","baseSepolia","sepolia","optimismSepolia","SUPPORTED_CHAINS_BY_ID","chain","getSupportedChainById","getFallbackRpcUrl","viemChain","defineChainConfig","rpcUrl","nativeCurrency","symbol","decimals","createClients","clients","createClientPair","storeClientPair","http","createFallbackClientPair","pair","getClient","storedClient","fallbackPair","correlationIdsStore","correlationIds","newMap","assertSubAccount","info","isHex","generateKeyPair","deriveSharedSecret","ownPrivateKey","peerPublicKey","encrypt","sharedSecret","plainText","iv","cipherText","decrypt","getFormat","keyType","exportKeyToHexString","format","exported","importKeyFromHexString","arrayBuffer","encryptContent","content","decryptContent","encryptedData","fetchRPCRequest","requestBody","res","checkErrorForInvalidRequestArgs","version","getVersion","shortMessage","docs","walk","isBytes","abytes","lengths","aexists","instance","checkFinished","aoutput","out","min","clean","arrays","createView","arr","rotr","word","shift","utf8ToBytes","toBytes","Hash$1","createHasher","hashCons","hashC","msg","tmp","setBigUint64","view","byteOffset","isLE","_32n","_u32_max","wh","wl","Chi","Maj","Hash","blockLen","outputLen","padOffset","buffer","len","pos","take","dataView","oview","outLen","finished","destroyed","SHA256_IV","SHA256_K","SHA256_W","HashMD","E","G","offset","W15","W2","s0","s1","sigma1","T1","T2","sha256","SHA256","sha256n","crypto","anumber","ahash","hasHexBuiltin","hexes","bytesToHex","bytes","asciis","asciiToBase16","ch","hl","al","array","ai","hi","n1","n2","char","concatBytes","sum","randomBytes","bytesLength","_0n","_1n","_abool2","prefix","_abytes2","isBytes_","needsLen","ofLen","got","numberToHexUnpadded","hexToNumber","bytesToNumberBE","bytesToHex_","bytesToNumberLE","abytes_","numberToBytesBE","hexToBytes_","numberToBytesLE","ensureBytes","expectedLength","isPosBig","inRange","max","aInRange","bitLen","bitMask","createHmacDrbg","hashLen","qByteLen","hmacFn","u8n","u8of","reset","reseed","seed","gen","sl","concatBytes_","pred","_validateObject","object","fields","optFields","checkField","fieldName","expectedType","isOpt","val","current","memoized","map","computed","bigIntSuffix","replacer","space","assertSize","size_","Bytes.size","Bytes.SizeOverflowError","assertStartOffset","start","Bytes.SliceOffsetOutOfBoundsError","assertEndOffset","end","charCodeMap","charCodeToBase16","Hex.size","Hex.SizeOverflowError","Hex.SliceOffsetOutOfBoundsError","hex_","dir","Hex.SizeExceedsPaddingSizeError","encoder","_v","assert","strict","InvalidHexTypeError","InvalidHexValueError","from","fromBytes","string","internal.assertSize","padRight","fromNumber","signed","value_","maxValue","minValue","suffix","IntegerOutOfRangeError","padLeft","fromString","internal.pad","slice","internal.assertStartOffset","internal.assertEndOffset","toBigInt","max_unsigned","max_signed","validate","Errors.BaseError","Json.stringify","givenSize","maxSize","position","SizeExceedsPaddingSizeError","targetSize","InvalidBytesTypeError","fromHex","fromArray","internal_hex.assertSize","Hex.padRight","index","nibbleLeft","internal.charCodeToBase16","nibbleRight","Hex.fromBytes","Hex.toBigInt","SizeOverflowError","SliceOffsetOutOfBoundsError","as","noble_sha256","Bytes.from","publicKey","compressed","InvalidPrefixError","InvalidUncompressedPrefixError","InvalidCompressedPrefixError","InvalidError","Hex.validate","Bytes.validate","InvalidSerializedSizeError","Hex.slice","toHex","Hex.concat","Hex.fromNumber","Hex.from","maxUint256","SHA384_IV","SHA512_IV","U32_MASK64","fromBig","le","split","lst","Ah","Al","shrSH","_l","shrSL","rotrSH","rotrSL","rotrBH","rotrBL","add","Bh","Bl","add3L","Cl","add3H","low","Ch","add4L","Dl","add4H","Dh","add5L","El","add5H","Eh","K512","u64.split","SHA512_Kh","SHA512_Kl","SHA512_W_H","SHA512_W_L","SHA512","Fh","Fl","Gh","Gl","Hh","Hl","W15h","W15l","s0h","u64.rotrSH","u64.shrSH","s0l","u64.rotrSL","u64.shrSL","W2h","W2l","s1h","u64.rotrBH","s1l","u64.rotrBL","SUMl","u64.add4L","SUMh","u64.add4H","sigma1h","sigma1l","CHIh","CHIl","T1ll","u64.add5L","T1h","u64.add5H","T1l","sigma0h","sigma0l","MAJh","MAJl","u64.add","All","u64.add3L","u64.add3H","SHA384","sha512","sha384","HMAC","_key","buf","oHash","iHash","hmac","_2n","_3n","_4n","_5n","_7n","_8n","_9n","_16n","mod","invert","number","modulo","assertIsSquare","Fp","sqrt3mod4","p1div4","sqrt5mod8","p5div8","nv","sqrt9mod16","Fp_","Field","tn","tonelliShanks","c1","c2","c3","c4","tv1","tv2","tv3","tv4","e1","e2","e3","Q","Z","_Fp","FpLegendre","cc","Q1div2","R","t_tmp","exponent","FpSqrt","FIELD_FIELDS","validateField","field","initial","FpPow","power","FpInvertBatch","nums","passZero","inverted","multipliedAcc","invertedAcc","p1mod2","powered","yes","zero","no","nLength","nBitLength","_nBitLength","nByteLength","ORDER","bitLenOrOpts","_nbitLength","_sqrt","modFromBytes","allowedLengths","_opts","BITS","BYTES","sqrtP","lhs","rhs","skipValidation","padded","scalar","getFieldBytesLength","fieldOrder","bitLength","getMinHashLength","mapHashToField","fieldLen","minLen","reduced","negateCt","condition","item","neg","normalizeZ","points","invertedZs","validateW","W","calcWOpts","scalarBits","windows","windowSize","maxNumber","mask","shiftBy","calcOffsets","window","wOpts","wbits","nextN","offsetStart","isZero","isNeg","isNegF","validateMSMPoints","validateMSMScalars","scalars","pointPrecomputes","pointWindowSizes","getW","assert0","wNAF","Point","elm","point","precomputes","wo","offsetF","transform","comp","prev","mulEndoUnsafe","k1","k2","p1","p2","pippenger","fieldN","plength","slength","MASK","buckets","lastBits","resI","sumI","createField","order","_createCurveFields","CURVE","curveOpts","FpFnLE","Fn","divNearest","den","_splitEndoScalar","basis","a1","b1","a2","b2","k1neg","k2neg","MAX_NUM","validateSigFormat","validateSigOpts","def","optsn","optName","abool","DERErr","DER","tag","dataLen","lenLen","first","isLong","lengthBytes","int","tlv","seqBytes","seqLeftBytes","rBytes","rLeftBytes","sBytes","sLeftBytes","sig","rs","ss","seq","_normFnElement","expected","weierstrassN","extraOpts","validated","cofactor","CURVE_ORDER","endo","getWLengths","assertCompressionIsSupported","pointToBytes","isCompressed","bx","hasEvenY","pprefix","pointFromBytes","uncomp","head","tail","y2","weierstrassEquation","sqrtError","isYOdd","isValidXY","encodePoint","decodePoint","x2","x3","right","_4a3","_27b2","acoord","banZero","aprjpoint","other","splitEndoScalarN","toAffineMemo","iz","X","Y","is0","zz","assertValidMemo","finishEndo","endoBeta","k1p","k2p","isLazy","wnaf","X1","Y1","Z1","X2","Y2","Z2","U1","U2","b3","X3","Y3","Z3","t0","t1","t2","t3","t4","t5","fake","mul","k1f","k2f","sc","invertedZ","isTorsionFree","clearCofactor","privateKey","ecdh","ecdhOpts","randomBytes_","randomBytesWeb","isValidSecretKey","secretKey","isValidPublicKey","publicKeyUncompressed","randomSecretKey","getPublicKey","keygen","isProbPub","getSharedSecret","secretKeyA","publicKeyB","ecdsa","ecdsaOpts","msgs","nobleHmac","fnBits","utils","defaultSigOpts","defaultSigOpts_format","isBiggerThanHalfOrder","HALF","validateRS","validateSigLength","sizer","Signature","recovery","recid","messageHash","FIELD_ORDER","rec","radj","ir","bits2int_modN","u1","u2","bits2int","ORDER_MASK","int2octets","validateMsgAndHash","prehash","prepSig","lowS","extraEntropy","h1int","seedArgs","k2sig","kBytes","ik","normS","sign","tryParsingSig","sg","isObj","derError","verify","is","recoverPublicKey","_weierstrass_legacy_opts_to_new","_ecdsa_legacy_opts_to_new","_ecdsa_new_output_to_legacy","_ecdsa","weierstrass","signs","createCurve","curveDef","defHash","create","recovered","MissingPropertiesError","Solidity.maxUint256","InvalidRError","InvalidSError","InvalidYParityError","vToYParity","yParityToV","InvalidVError","decoder","integerToCharacter","encoded","base64","Bytes.fromHex","p256_CURVE","p384_CURVE","p521_CURVE","Fp256","Fp384","Fp521","p256","p256n","getAuthenticatorData","flag","rpId","signCount","rpIdHash","Hash.sha256","Hex.fromString","flag_bytes","signCount_bytes","getClientDataJSON","challenge","crossOrigin","extraClientData","origin","Base64.fromHex","getSignPayload","userVerification","authenticatorData","clientDataJSON","clientDataJSONHash","challengeIndex","typeIndex","payload","createKeyPair","extractable","keypair","publicKey_raw","PublicKey.from","signature_bytes","Bytes.fromArray","Bytes.toBigInt","Bytes.slice","createStorage","scope","del","STORAGE_SCOPE","STORAGE_NAME","ACTIVE_ID_KEY","WebCryptoP256.createKeyPair","PublicKey.toHex","getKeypair","id","getOrCreateKeypair","kp","pubKey","getAccount","WebAuthnP256.getSignPayload","WebCryptoP256.sign","Signature.toHex","hashMessage","getCryptoKeyAccount","OWN_PRIVATE_KEY","OWN_PUBLIC_KEY","PEER_PUBLIC_KEY","SCWKeyManager","newKeyPair","path","getSenderFromRequest","addSenderToRequest","assertParamsChainId","assertGetCapabilitiesParams","param","injectRequestCapabilities","capabilities","modifiedRequest","requestCapabilities","initSubAccountConfig","owner","assertFetchPermissionsRequest","fillMissingParamsForFetchPermissions","accountFromStore","subAccountFromStore","waitForCallsTransactionHash","waitForCallsStatus","createWalletSendCallsRequest","paymasterUrls","presentSubAccountFundingDialog","isSendCallsParams","isEthSendTransactionParams","compute16ByteHash","makeDataSuffix","attribution","dappOrigin","prependWithoutDuplicates","filtered","appendWithoutDuplicates","base64ToBase64Url","arrayBufferToBase64Url","base64String","convertCredentialToJSON","webauthn","signatureRaw","Signature.fromHex","stringToBytes","asn1EncodeSignature","trim","rLength","sLength","totalLength","createSmartAccount","ownerIndex","decodeFunctionData","wrapSignature","toReplaySafeHash","domain","primaryType","toWebAuthnSignature","signatureData","createSubAccountSigner","parentAddress","rawParams","sendCallsRequest","prepareCallsRequest","prepareCallsResponse","signResponse","hexToString","prepareCallsParams","typedData","newError","findOwnerIndex","initData","owners","formatPublicKey","ownerCount","formatted","presentAddOwnerDialog","appName","handleAddSubAccountOwner","ownerAccount","globalAccountRequest","globalAccount","decodeAbiParameters","callsId","routeThroughGlobalAccount","globalAccountAddress","subAccountAddress","prependCalls","originalSendCallsParams","subAccountCallData","requestToParent","handleInsufficientBalanceError","Signer","handshakeMessage","decrypted","_e","_f","completeRequest","permissions","requestedChainId","_g","permission","accounts","capabilityResponse","popupResult","requestedAccount","filterChainIds","isAddressEqual","filterChainNumbers","capabilityKey","capabilityChainNumber","encrypted","availableChains","nativeCurrencies","walletCapabilities","newAvailableChains","walletSendCallsChainId","subAccountRequest","handlingError","BaseAccountProvider","walletUrl","TBA_PROVIDER_IDENTIFIER","getInjectedProvider","injectedProvider","createBaseAccountSDK","provider","sdk","accountParam","toSubAccountOwner"],"mappings":"o3BAOO,SAASA,GAAaC,EAAOC,EAAQ,CACxC,GAAID,EAAM,SAAWC,EAAO,OACxB,MAAM,IAAIC,GAA+B,CACrC,eAAgBF,EAAM,OACtB,YAAaC,EAAO,MAChC,CAAS,EACL,MAAME,EAAO,CAAA,EACb,QAASC,EAAI,EAAGA,EAAIJ,EAAM,OAAQI,IAAK,CACnC,MAAMC,EAAOL,EAAMI,CAAC,EACdE,EAAQL,EAAOG,CAAC,EACtBD,EAAK,KAAKI,GAAOF,EAAMC,CAAK,CAAC,CACjC,CACA,OAAOE,GAAUL,CAAI,CACzB,CACA,SAASI,GAAOF,EAAMC,EAAOG,EAAU,GAAO,CAC1C,GAAIJ,IAAS,UAAW,CACpB,MAAMK,EAAUJ,EAChB,GAAI,CAACK,GAAUD,CAAO,EAClB,MAAM,IAAIE,GAAoB,CAAE,QAAAF,EAAS,EAC7C,OAAOG,GAAIH,EAAQ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OAAO,EACtE,CACI,UAAW,GACX,OAAQ,CACJ,CACI,QAAS,GACT,KAAM,UACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,eACN,KAAM,SACtB,CACA,EACQ,KAAM,YACN,KAAM,OACd,EACI,CACI,UAAW,GACX,OAAQ,CACJ,CACI,QAAS,GACT,KAAM,aACN,KAAM,SACtB,CACA,EACQ,KAAM,6BACN,KAAM,OACd,EACI,CACI,UAAW,GACX,OAAQ,CACJ,CACI,QAAS,GACT,KAAM,UACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,cACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,kBACN,KAAM,SACtB,CACA,EACQ,KAAM,cACN,KAAM,OACd,EACI,CACI,UAAW,GACX,OAAQ,CACJ,CACI,QAAS,GACT,KAAM,UACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,eACN,KAAM,SACtB,CACA,EACQ,KAAM,gBACN,KAAM,OACd,EACI,CACI,UAAW,GACX,OAAQ,CACJ,CACI,QAAS,GACT,KAAM,UACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,kBACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,SACN,KAAM,SACtB,CACA,EACQ,KAAM,iBACN,KAAM,OACd,EACI,CACI,UAAW,GACX,OAAQ,CACJ,CACI,QAAS,GACT,KAAM,aACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,SACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,YACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,QACN,KAAM,SACtB,EACY,CAAE,QAAS,GAAO,KAAM,UAAW,KAAM,MAAM,EAC/C,CACI,QAAS,GACT,KAAM,gBACN,KAAM,SACtB,EACY,CACI,QAAS,GACT,KAAM,gBACN,KAAM,SACtB,CACA,EACQ,KAAM,qBACN,KAAM,OACd,EACI,CACI,UAAW,GACX,OAAQ,CACJ,CACI,QAAS,GACT,KAAM,aACN,K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AM,YAAY,IAAG,EAClCJ,EAAUI,EAAM,QAAQ,IAAG,EACjCkD,GAAetD,EAAS,IAAI,MAAM,wBAAwB,CAAC,EAC3DsD,GAAexD,GAAA,YAAAA,EAAY,QAAS,IAAI,MAAM,2BAA2B,CAAC,EAC1E,MAAMwV,EAAQ,CAAA,EACd,GAAI2W,EAAW,CACX,KAAM,CAAC5lB,EAAGR,CAAC,EAAIqrC,GAAoB,CAAC,CAAE,KAAM,SAAS,EAAI,CAAE,KAAM,SAAS,CAAE,EAAGjlB,CAAS,EACxF3W,EAAM,KAAK,CACP,GAAIxV,EAAW,QACf,KAAMiY,GAAmB,CACrB,IAAA/W,GACA,aAAc,oBACd,KAAM,CAACqF,EAAGR,CAAC,CACvC,CAAyB,EACD,MAAO8mB,GAAM,CAAC,CACtC,CAAqB,CACL,CACA,OAAIl1B,GACA6d,EAAM,KAAK,CACP,GAAIxV,EAAW,QACf,KAAMiY,GAAmB,CACrB,IAAA/W,GACA,aAAc,kBACd,KAAM,CAACvJ,CAAO,CAC1C,CAAyB,EACD,MAAOk1B,GAAM,CAAC,CACtC,CAAqB,EAEG,OAAMnvB,EAAAs2C,EAAI,YAAW,IAAf,YAAAt2C,EAAmB,QAAQ,CACrC,OAAQ,mBACR,OAAQ,CACJ,CACI,MAAA8X,EACA,QAASqX,GAAMtzB,CAAO,EACtB,MAAMkC,EAAAyE,EAAQ,WAAR,YAAAzE,EAAmB,GACzB,QAAS,GACrC,CACA,CACA,GACY,EACA,kBAAkBy4C,EAAmB,CACjC/vC,GAAmB+vC,CAAiB,EACpC5zC,EAAM,kBAAkB,IAAI,CACxB,eAAgB4zC,CACpC,CAAiB,CACL,CACZ,CACA,EACI,OAAOF,CACX","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125]}
|