PageSourceSearch

https://app.formo.so/_next/static/immutable/chunks/2ftw2c2myf_0v.js

js formo.so collected 2026-09-25 20:48:14 UTC 685,147 bytes, 34 lines download raw bytes

1;!function(){try { var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof global?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&((e._debugIds|| (e._debugIds={}))[n]="1ed872c6-958c-af54-16a6-8127c0d2b569")}catch(e){}}();
2(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,895104,342330,e=>{"use strict";let t;var r,n,i,a,o,s,c,u,l,d,f,p,h,m,b="".concat("https://events.formo.so","/v0/raw_events"),y={"Africa/Abidjan":"CI","Africa/Accra":"GH","Africa/Addis_Ababa":"ET","Africa/Algiers":"DZ","Africa/Asmara":"ER","Africa/Asmera":"ER","Africa/Bamako":"ML","Africa/Bangui":"CF","Africa/Banjul":"GM","Africa/Bissau":"GW","Africa/Blantyre":"MW","Africa/Brazzaville":"CG","Africa/Bujumbura":"BI","Africa/Cairo":"EG","Africa/Casablanca":"MA","Africa/Ceuta":"ES","Africa/Conakry":"GN","Africa/Dakar":"SN","Africa/Dar_es_Salaam":"TZ","Africa/Djibouti":"DJ","Africa/Douala":"CM","Africa/El_Aaiun":"EH","Africa/Freetown":"SL","Africa/Gaborone":"BW","Africa/Harare":"ZW","Africa/Johannesburg":"ZA","Africa/Juba":"SS","Africa/Kampala":"UG","Africa/Khartoum":"SD","Africa/Kigali":"RW","Africa/Kinshasa":"CD","Africa/Lagos":"NG","Africa/Libreville":"GA","Africa/Lome":"TG","Africa/Luanda":"AO","Africa/Lubumbashi":"CD","Africa/Lusaka":"ZM","Africa/Malabo":"GQ","Africa/Maputo":"MZ","Africa/Maseru":"LS","Africa/Mbabane":"SZ","Africa/Mogadishu":"SO","Africa/Monrovia":"LR","Africa/Nairobi":"KE","Africa/Ndjamena":"TD","Africa/Niamey":"NE","Africa/Nouakchott":"MR","Africa/Ouagadougou":"BF","Africa/Porto-Novo":"BJ","Africa/Sao_Tome":"ST","Africa/Timbuktu":"ML","Africa/Tripoli":"LY","Africa/Tunis":"TN","Africa/Windhoek":"NA","America/Adak":"US","America/Anchorage":"US","America/Anguilla":"AI","America/Antigua":"AG","America/Araguaina":"BR","America/Argentina/Buenos_Aires":"AR","America/Argentina/Catamarca":"AR","America/Argentina/ComodRivadavia":"AR","America/Argentina/Cordoba":"AR","America/Argentina/Jujuy":"AR","America/Argentina/La_Rioja":"AR","America/Argentina/Mendoza":"AR","America/Argentina/Rio_Gallegos":"AR","America/Argentina/Salta":"AR","America/Argentina/San_Juan":"AR","America/Argentina/San_Luis":"AR","America/Argentina/Tucuman":"AR","America/Argentina/Ushuaia":"AR","America/Aruba":"AW","America/Asuncion":"PY","America/Atikokan":"CA","America/Atka":"US","America/Bahia":"BR","America/Bahia_Banderas":"MX","America/Barbados":"BB","America/Belem":"BR","America/Belize":"BZ","America/Blanc-Sablon":"CA","America/Boa_Vista":"BR","America/Bogota":"CO","America/Boise":"US","America/Buenos_Aires":"AR","America/Cambridge_Bay":"CA","America/Campo_Grande":"BR","America/Cancun":"MX","America/Caracas":"VE","America/Catamarca":"AR","America/Cayenne":"GF","America/Cayman":"KY","America/Chicago":"US","America/Chihuahua":"MX","America/Ciudad_Juarez":"MX","America/Coral_Harbour":"CA","America/Cordoba":"AR","America/Costa_Rica":"CR","America/Creston":"CA","America/Cuiaba":"BR","America/Curacao":"CW","America/Danmarkshavn":"GL","America/Dawson":"CA","America/Dawson_Creek":"CA","America/Denver":"US","America/Detroit":"US","America/Dominica":"DM","America/Edmonton":"CA","America/Eirunepe":"BR","America/El_Salvador":"SV","America/Ensenada":"MX","America/Fort_Nelson":"CA","America/Fort_Wayne":"US","America/Fortaleza":"BR","America/Glace_Bay":"CA","America/Godthab":"GL","America/Goose_Bay":"CA","America/Grand_Turk":"TC","America/Grenada":"GD","America/Guadeloupe":"GP","America/Guatemala":"GT","America/Guayaquil":"EC","America/Guyana":"GY","America/Halifax":"CA","America/Havana":"CU","America/Hermosillo":"MX","America/Indiana/Indianapoli":"US","America/Indiana/Knox":"US","America/Indiana/Marengo":"US","America/Indiana/Petersburg":"US","America/Indiana/Tell_City":"US","America/Indiana/Vevay":"US","America/Indiana/Vincennes":"US","America/Indiana/Winamac":"US","America/Indianapoli":"US","America/Inuvik":"CA","America/Iqaluit":"CA","America/Jamaica":"JM","America/Jujuy":"AR","America/Juneau":"US","America/Kentucky/Louisville":"US","America/Kentucky/Monticello":"US","America/Knox_IN":"US","America/Kralendijk":"BQ","America/La_Paz":"BO","America/Lima":"PE","America/Los_Angeles":"US","America/Louisville":"US","America/Lower_Princes":"SX","America/Maceio":"BR","America/Managua":"NI","America/Manaus":"BR","America/Marigot":"MF","America/Martinique":"MQ","America/Matamoros":"MX","America/Mazatlan":"MX","America/Mendoza":"AR","America/Menominee":"US","America/Merida":"MX","America/Metlakatla":"US","America/Mexico_City":"MX","America/Miquelon":"PM","America/Moncton":"CA","America/Monterrey":"MX","America/Montevideo":"UY","America/Montreal":"CA","America/Montserrat":"MS","America/Nassau":"BS","America/Ne
2w_York":"US","America/Nipigon":"CA","America/Nome":"US","America/Noronha":"BR","America/North_Dakota/Beulah":"US","America/North_Dakota/Center":"US","America/North_Dakota/New_Salem":"US","America/Nuuk":"GL","America/Ojinaga":"MX","America/Panama":"PA","America/Pangnirtung":"CA","America/Paramaribo":"SR","America/Phoenix":"US","America/Port-au-Prince":"HT","America/Port_of_Spain":"TT","America/Porto_Acre":"BR","America/Porto_Velho":"BR","America/Puerto_Rico":"PR","America/Punta_Arenas":"CL","America/Rainy_River":"CA","America/Rankin_Inlet":"CA","America/Recife":"BR","America/Regina":"CA","America/Resolute":"CA","America/Rio_Branco":"BR","America/Rosario":"AR","America/Santa_Isabel":"MX","America/Santarem":"BR","America/Santiago":"CL","America/Santo_Domingo":"DO","America/Sao_Paulo":"BR","America/Scoresbysund":"GL","America/Shiprock":"US","America/Sitka":"US","America/St_Barthelemy":"BL","America/St_Johns":"CA","America/St_Kitts":"KN","America/St_Lucia":"LC","America/St_Thomas":"VI","America/St_Vincent":"VC","America/Swift_Current":"CA","America/Tegucigalpa":"HN","America/Thule":"GL","America/Thunder_Bay":"CA","America/Tijuana":"MX","America/Toronto":"CA","America/Tortola":"VG","America/Vancouver":"CA","America/Virgin":"VI","America/Whitehorse":"CA","America/Winnipeg":"CA","America/Yakutat":"US","America/Yellowknife":"CA","Antarctica/Casey":"AQ","Antarctica/Davis":"AQ","Antarctica/DumontDUrville":"AQ","Antarctica/Macquarie":"AU","Antarctica/Mawson":"AQ","Antarctica/McMurdo":"AQ","Antarctica/Palmer":"AQ","Antarctica/Rothera":"AQ","Antarctica/South_Pole":"AQ","Antarctica/Syowa":"AQ","Antarctica/Troll":"AQ","Antarctica/Vostok":"AQ","Arctic/Longyearbyen":"SJ","Asia/Aden":"YE","Asia/Almaty":"KZ","Asia/Amman":"JO","Asia/Anadyr":"RU","Asia/Aqtau":"KZ","Asia/Aqtobe":"KZ","Asia/Ashgabat":"TM","Asia/Ashkhabad":"TM","Asia/Atyrau":"KZ","Asia/Baghdad":"IQ","Asia/Bahrain":"BH","Asia/Baku":"AZ","Asia/Bangkok":"TH","Asia/Barnaul":"RU","Asia/Beirut":"LB","Asia/Bishkek":"KG","Asia/Brunei":"BN","Asia/Calcutta":"IN","Asia/Chita":"RU","Asia/Choibalsan":"MN","Asia/Chongqing":"CN","Asia/Chungking":"CN","Asia/Colombo":"LK","Asia/Dacca":"BD","Asia/Damascus":"SY","Asia/Dhaka":"BD","Asia/Dili":"TL","Asia/Dubai":"AE","Asia/Dushanbe":"TJ","Asia/Famagusta":"CY","Asia/Gaza":"PS","Asia/Harbin":"CN","Asia/Hebron":"PS","Asia/Ho_Chi_Minh":"VN","Asia/Hong_Kong":"HK","Asia/Hovd":"MN","Asia/Irkutsk":"RU","Asia/Istanbul":"TR","Asia/Jakarta":"ID","Asia/Jayapura":"ID","Asia/Jerusalem":"IL","Asia/Kabul":"AF","Asia/Kamchatka":"RU","Asia/Karachi":"PK","Asia/Kashgar":"CN","Asia/Kathmandu":"NP","Asia/Katmandu":"NP","Asia/Khandyga":"RU","Asia/Kolkata":"IN","Asia/Kostanay":"KZ","Asia/Krasnoyarsk":"RU","Asia/Kuala_Lumpur":"MY","Asia/Kuching":"MY","Asia/Kuwait":"KW","Asia/Macao":"MO","Asia/Macau":"MO","Asia/Magadan":"RU","Asia/Makassar":"ID","Asia/Manila":"PH","Asia/Muscat":"OM","Asia/Nicosia":"CY","Asia/Novokuznetsk":"RU","Asia/Novosibirsk":"RU","Asia/Omsk":"RU","Asia/Oral":"KZ","Asia/Phnom_Penh":"KH","Asia/Pontianak":"ID","Asia/Pyongyang":"KP","Asia/Qatar":"QA","Asia/Qostanay":"KZ","Asia/Qyzylorda":"KZ","Asia/Rangoon":"MM","Asia/Riyadh":"SA","Asia/Saigon":"VN","Asia/Sakhalin":"RU","Asia/Samarkand":"UZ","Asia/Seoul":"KR","Asia/Shanghai":"CN","Asia/Singapore":"SG","Asia/Srednekolymsk":"RU","Asia/Taipei":"TW","Asia/Tashkent":"UZ","Asia/Tbilisi":"GE","Asia/Tehran":"IR","Asia/Tel_Aviv":"IL","Asia/Thimbu":"BT","Asia/Thimphu":"BT","Asia/Tokyo":"JP","Asia/Tomsk":"RU","Asia/Ujung_Pandang":"ID","Asia/Ulaanbaatar":"MN","Asia/Ulan_Bator":"MN","Asia/Urumqi":"CN","Asia/Ust-Nera":"RU","Asia/Vientiane":"LA","Asia/Vladivostok":"RU","Asia/Yakutsk":"RU","Asia/Yangon":"MM","Asia/Yekaterinburg":"RU","Asia/Yerevan":"AM","Atlantic/Azores":"PT","Atlantic/Bermuda":"BM","Atlantic/Canary":"ES","Atlantic/Cape_Verde":"CV","Atlantic/Faeroe":"FO","Atlantic/Faroe":"FO","Atlantic/Jan_Mayen":"SJ","Atlantic/Madeira":"PT","Atlantic/Reykjavik":"IS","Atlantic/South_Georgia":"GS","Atlantic/St_Helena":"SH","Atlantic/Stanley":"FK","Australia/ACT":"AU","Australia/Adelaide":"AU","Australia/Brisbane":"AU","Australia/Broken_Hill":"AU","Australia/Canberra":"AU","Australia/Currie":"AU","Australia/Darwin":"AU","Australia/Eucla":"AU","Australia/Hobart":"AU","Australia/LHI":"AU","Australia/Lindeman":"AU","Australia/Lord_Howe":"AU","Australia/Melbourne":"AU","Australia/North":"AU","Australia/NSW":"AU","Australia/Perth":"AU","Australia/Queensland":"AU","Australia/South":"AU","Australia/Sydney":"AU","Australia/Tasmania":"AU","Australia/Victoria":"AU","Australia/West":"AU","Australia/Yancowinna":"AU","Brazil/Acre":"BR","Brazil/DeNoronha":"BR","Brazil/East":"BR","Brazil/West":"BR","Canada
2/Atlantic":"CA","Canada/Central":"CA","Canada/Eastern":"CA","Canada/Mountain":"CA","Canada/Newfoundland":"CA","Canada/Pacific":"CA","Canada/Saskatchewan":"CA","Canada/Yukon":"CA","Chile/Continental":"CL","Chile/EasterIsland":"CL",Cuba:"CU",Egypt:"EG",Eire:"IE","Europe/Amsterdam":"NL","Europe/Andorra":"AD","Europe/Astrakhan":"RU","Europe/Athens":"GR","Europe/Belfast":"GB","Europe/Belgrade":"RS","Europe/Berlin":"DE","Europe/Bratislava":"SK","Europe/Brussels":"BE","Europe/Bucharest":"RO","Europe/Budapest":"HU","Europe/Busingen":"DE","Europe/Chisinau":"MD","Europe/Copenhagen":"DK","Europe/Dublin":"IE","Europe/Gibraltar":"GI","Europe/Guernsey":"GG","Europe/Helsinki":"FI","Europe/Isle_of_Man":"IM","Europe/Istanbul":"TR","Europe/Jersey":"JE","Europe/Kaliningrad":"RU","Europe/Kiev":"UA","Europe/Kirov":"RU","Europe/Kyiv":"UA","Europe/Lisbon":"PT","Europe/Ljubljana":"SI","Europe/London":"GB","Europe/Luxembourg":"LU","Europe/Madrid":"ES","Europe/Malta":"MT","Europe/Mariehamn":"AX","Europe/Minsk":"BY","Europe/Monaco":"MC","Europe/Moscow":"RU","Europe/Nicosia":"CY","Europe/Oslo":"NO","Europe/Paris":"FR","Europe/Podgorica":"ME","Europe/Prague":"CZ","Europe/Riga":"LV","Europe/Rome":"IT","Europe/Samara":"RU","Europe/San_Marino":"SM","Europe/Sarajevo":"BA","Europe/Saratov":"RU","Europe/Simferopol":"RU","Europe/Skopje":"MK","Europe/Sofia":"BG","Europe/Stockholm":"SE","Europe/Tallinn":"EE","Europe/Tirane":"AL","Europe/Tiraspol":"MD","Europe/Ulyanovsk":"RU","Europe/Uzhgorod":"UA","Europe/Vaduz":"LI","Europe/Vatican":"VA","Europe/Vienna":"AT","Europe/Vilnius":"LT","Europe/Volgograd":"RU","Europe/Warsaw":"PL","Europe/Zagreb":"HR","Europe/Zaporozhye":"UA","Europe/Zurich":"CH",GB:"GB","GB-Eire":"GB",Hongkong:"HK",Iceland:"IS","Indian/Antananarivo":"MG","Indian/Chagos":"IO","Indian/Christmas":"CX","Indian/Cocos":"CC","Indian/Comoro":"KM","Indian/Kerguelen":"TF","Indian/Mahe":"SC","Indian/Maldives":"MV","Indian/Mauritius":"MU","Indian/Mayotte":"YT","Indian/Reunion":"RE",Iran:"IR",Israel:"IL",Jamaica:"JM",Japan:"JP",Kwajalein:"MH",Libya:"LY","Mexico/BajaNorte":"MX","Mexico/BajaSur":"MX","Mexico/General":"MX",Navajo:"US",NZ:"NZ","NZ-CHAT":"NZ","Pacific/Apia":"WS","Pacific/Auckland":"NZ","Pacific/Bougainville":"PG","Pacific/Chatham":"NZ","Pacific/Chuuk":"FM","Pacific/Easter":"CL","Pacific/Efate":"VU","Pacific/Enderbury":"KI","Pacific/Fakaofo":"TK","Pacific/Fiji":"FJ","Pacific/Funafuti":"TV","Pacific/Galapagos":"EC","Pacific/Gambier":"PF","Pacific/Guadalcanal":"SB","Pacific/Guam":"GU","Pacific/Honolulu":"US","Pacific/Johnston":"UM","Pacific/Kanton":"KI","Pacific/Kiritimati":"KI","Pacific/Kosrae":"FM","Pacific/Kwajalein":"MH","Pacific/Majuro":"MH","Pacific/Marquesas":"PF","Pacific/Midway":"UM","Pacific/Nauru":"NR","Pacific/Niue":"NU","Pacific/Norfolk":"NF","Pacific/Noumea":"NC","Pacific/Pago_Pago":"AS","Pacific/Palau":"PW","Pacific/Pitcairn":"PN","Pacific/Pohnpei":"FM","Pacific/Ponape":"FM","Pacific/Port_Moresby":"PG","Pacific/Rarotonga":"CK","Pacific/Saipan":"MP","Pacific/Samoa":"AS","Pacific/Tahiti":"PF","Pacific/Tarawa":"KI","Pacific/Tongatapu":"TO","Pacific/Truk":"FM","Pacific/Wake":"UM","Pacific/Wallis":"WF","Pacific/Yap":"FM",Poland:"PL",Portugal:"PT",PRC:"CN",ROC:"TW",ROK:"KR",Singapore:"SG",Turkey:"TR","US/Alaska":"US","US/Aleutian":"US","US/Arizona":"US","US/Central":"US","US/East-Indiana":"US","US/Eastern":"US","US/Hawaii":"US","US/Indiana-Starke":"US","US/Michigan":"US","US/Mountain":"US","US/Pacific":"US","US/Samoa":"AS","W-SU":"RU"};(u=r||(r={})).PAGE="page",u.IDENTIFY="identify",u.DETECT="detect",u.CONNECT="connect",u.DISCONNECT="disconnect",u.CHAIN="chain",u.SIGNATURE="signature",u.TRANSACTION="transaction",u.TRACK="track",(l=n||(n={})).WEB="web",l.MOBILE="mobile",l.SERVER="server",l.SOURCE="source";var g="traffic-source",v="user-id",w="active-wallet",E="anonymous-id",P="opt-out-tracking",x=["0x0000000000000000000000000000000000000000","0x000000000000000000000000000000000000dEaD"],A=function(e,t,r){if(r||2==arguments.length)for(var n,i=0,a=t.length;i<a;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))},I=["gclid","gad_source","fbclid","msclkid","twclid","li_fat_id","rdt_cid","ttclid"],T=["privy_oauth_code","privy_oauth_state","privy_oauth_provider"],S=["ref","referral","refcode","af","referrer"],C=new Set(A(A(A(["utm_source","utm_medium","utm_campaign","utm_term","utm_content"],S,!0),I,!0),["category","name","url","path","hash","query"],!1)),O="idempotency_key",j=function(e,t,r){if(r||2==arguments.length)for(var n,i=0,a=t.length;i<a;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))},k=function(){function e(e,t){void 0===e&&(e=!1),void 0===t&&(t=[]),this.enabled=e,this.enabledLevels=new Set(t)}return e.init=function(t){var r=e.getInstance();void 0!==t.enabled&&r.setEnabled(t.enabled),void 0!==t.enabledLevels&&r.setEnabledLevels(t.enabledLevels)},e.getInstance=function(t){var r,n;return e.instance||(e.instance=new e(null!=(r=null==t?void 0:t.enabled)&&r,null!=(n=null==t?void 0:t.enabledLevels)?n:[])),e.instance},e.prototype.setEnabled=function(e){this.enabled=e},e.prototype.isLoggingEnabled=function(){return this.enabled},e.prototype.setEnabledLevels=function(e){this.enabledLevels=new Set(e)},e.prototype.getEnabledLevels=function(){return Array.from(this.enabledLevels)},e.prototype.shouldLog=function(e){return!!this.enabled&&this.enabledLevels.has(e)},e.prototype.formatMessage=function(e){var t=new Date().toLocaleStr
2ing("en-US",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1});return"[Formo SDK][".concat(t,"] ").concat(e)},e.prototype.debug=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];this.shouldLog("debug")&&console.debug.apply(console,j([this.formatMessage(e)],t,!1))},e.prototype.info=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];this.shouldLog("info")&&console.info.apply(console,j([this.formatMessage(e)],t,!1))},e.prototype.warn=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];this.shouldLog("warn")&&console.warn.apply(console,j([this.formatMessage(e)],t,!1))},e.prototype.error=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];this.shouldLog("error")&&console.error.apply(console,j([this.formatMessage(e)],t,!1))},e.prototype.trace=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];this.shouldLog("trace")&&console.trace.apply(console,j([this.formatMessage(e)],t,!1))},e.prototype.log=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];this.info.apply(this,j([e],t,!1))},e}(),R=k.getInstance(),_="__json=",B=e.i(837474);"function"==typeof Uint8Array.from([]).toHex&&Uint8Array.fromHex;var M=e.i(944445);let F=M.abytes;function N(e){return t=>(F(t),e(t))}M.aexists,M.anumber,M.aoutput;let U=N(B.sha256);function H(e){var t=U((0,M.utf8ToBytes)(e));return(0,M.bytesToHex)(t).slice(0,8)}var z=function(){function e(e){this.writeKey=e}return e.prototype.getKey=function(e){return"".concat("formo","_").concat(H(this.writeKey),"_").concat(e)},e}(),L="__formo_domain_probe";function D(){if(void 0!==i)return i;var e=window.location.hostname;if("localhost"===e||/^\d+\.\d+\.\d+\.\d+$/.test(e))return i=null,null;var t=e.split(".");if(t.length<2)return i=null,null;for(var r=2;r<=t.length;r++){var n=t.slice(-r).join(".");if(function(e){var t="probe";document.cookie="".concat(L,"=").concat(t,"; domain=.").concat(e,"; path=/; max-age=10");var r=-1!==document.cookie.indexOf("".concat(L,"=").concat(t));return document.cookie="".concat(L,"=; domain=.").concat(e,"; path=/; max-age=0"),r}(n))return i=n,n}return i=null,null}var $=(d=function(e,t){return(d=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}d(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),q=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return $(t,e),t.prototype.isAvailable=function(){return"u">typeof document&&"string"==typeof document.cookie},t.prototype.set=function(e,t,r){var n=null==r?void 0:r.expires,i=null==r?void 0:r.maxAge,a=(null==r?void 0:r.path)||"/",o=(null==r?void 0:r.domain)||"",s=null==r?void 0:r.sameSite,c=(null==r?void 0:r.secure)||!1,u=encodeURIComponent(this.getKey(e));if(o)document.cookie="".concat(u,"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=").concat(a,";");else{var l=D();l&&(document.cookie="".concat(u,"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=").concat(a,"; domain=.").concat(l))}var d="".concat(u,"=").concat(encodeURIComponent(t));i?d+="; max-age="+i:n&&(d+="; expires="+n),a&&(d+="; path="+a),o&&(d+="; domain="+o),s&&(d+="; samesite="+s),c&&(d+="; secure"),document.cookie=d},t.prototype.get=function(e){var t=document.cookie.match(new RegExp("(?:^|; )".concat(encodeURIComponent(this.getKey(e)),"=([^;]*)")));return t?decodeURIComponent(t[1]):null},t.prototype.remove=function(e){var t=encodeURIComponent(this.getKey(e));document.cookie="".concat(t,"=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT");var r=D();r&&(document.cookie="".concat(t,"=; path=/; domain=.").concat(r,"; expires=Thu, 01 Jan 1970 00:00:00 GMT"))},t}(z),W=(f=function(e,t){return(f=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}f(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),G=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.memoryStorage={},t}return W(t,e),t.prototype.isAvailable=function(){return!0},t.prototype.set=function(e,t){this.memoryStorage[this.getKey(e)]=t},t.prototype.get=function(e){return this.memoryStorage[this.getKey(e)]||null},t.prototype.remove=function(e){delete this.memoryStorage[this.getKey(e)]},t}
2(z),K=(p=function(e,t){return(p=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}p(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),V=function(e){function t(t,r){var n=e.call(this,t)||this;return n.backend=r,n}return K(t,e),t.prototype.isAvailable=function(){try{var e="__storage_test__";return this.backend.setItem(e,"1"),this.backend.removeItem(e),!0}catch(e){return!1}},t.prototype.set=function(e,t){"boolean"==typeof t&&(t=!0===t?"true":"false"),"object"==typeof t&&(t=_+JSON.stringify(t)),this.backend.setItem(this.getKey(e),t)},t.prototype.get=function(e){var t=this.backend.getItem(this.getKey(e));if(!t||"string"!=typeof t||["null","undefined"].some(function(e){return e==t}))return null;if(t.startsWith(_))try{return JSON.parse(t.slice(_.length))}catch(e){return R.error("[FORMO_ERROR] ".concat(this.backend.constructor.name," failed to parse JSON"),e),null}return["true","false"].some(function(e){return e==t})?JSON.parse(t):t},t.prototype.remove=function(e){this.backend.removeItem(this.getKey(e))},t}(z),J=["cookieStorage","localStorage","sessionStorage","memoryStorage"],Z=function(){function e(e){this.writeKey=e,this.storages=new Map,this.resolvedTypes=new Map}return e.prototype.getStorage=function(e){if(!this.storages.has(e)){for(var t=this.createStorage(e),r=e;!t.isAvailable();){var n=J.indexOf(r);if(-1===n||n+1>=J.length){t=this.createStorage("memoryStorage");break}var i=r;r=J[n+1],R.warn("Storage ".concat(i," is not available, trying ").concat(r)),t=this.createStorage(r)}this.storages.set(e,t),this.resolvedTypes.set(e,r)}return this.storages.get(e)},e.prototype.getResolvedType=function(e){return this.getStorage(e),this.resolvedTypes.get(e)},e.prototype.createStorage=function(e){switch(e){case"cookieStorage":return new q(this.writeKey);case"localStorage":case"sessionStorage":return new V(this.writeKey,this.getWebStorage(e));default:return new G(this.writeKey)}},e.prototype.getWebStorage=function(e){try{var t="localStorage"===e?localStorage:sessionStorage;return null!=t?t:null}catch(e){return null}},e}(),Q=null;function Y(e){Q||(Q=new Z(e))}function X(e){if(!Q)throw Error("StorageManager not initialized. Call initStorageManager(writeKey) first.");return Q.getStorage(e)}var ee=function(){return X("cookieStorage")},et=function(){return X("localStorage")},er=function(){return X("sessionStorage")};function en(e){if(void 0===e&&(e=!0),!e)return"";var t=D();return t?".".concat(t):""}function ei(){var e;return{sameSite:"lax",secure:(null==(e=window.location)?void 0:e.protocol)==="https:"}}var ea=function(e,t,r){return Math.min(Math.max(e,r),t)},eo=function(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone||""}catch(e){return R.error("Error resolving timezone:",e),""}},es=e.i(626014);N(es.keccak_224);let ec=((t=N(es.keccak_256)).create=es.keccak_256.create,t);function eu(e){var t,r;return e instanceof Uint8Array||(null==(t=null==e?void 0:e.constructor)?void 0:t.name)==="Uint8Array"||(null==(r=null==e?void 0:e.constructor)?void 0:r.name)==="Buffer"}function el(e){for(var t="0x",r=0;r<e.length;r++){var n=e[r].toString(16);t+=1===n.length?"0".concat(n):n}return t}N(es.keccak_384),N(es.keccak_512);var ed=function(e,t){var r;return void 0===t&&(t=!0),("string"==typeof e||!!eu(e))&&(r=eu(e)?el(e):"string"!=typeof e||"string"==typeof e&&/^((-)?0x[0-9a-f]+|(0x))$/i.test(e)?e:e.toLowerCase().startsWith("0x")?e:"0x".concat(e),!!/^(0x)?[0-9a-f]{40}$/i.test(r)&&(!!(/^(0x|0X)?[0-9a-f]{40}$/.test(r)||/^(0x|0X)?[0-9A-F]{40}$/.test(r))||!t||ef(r)))},ef=function(e){if(!/^(0x)?[0-9a-f]{40}$/i.test(e))return!1;for(var t=e.slice(2),r=el(ec(ep((0,M.utf8ToBytes)(t.toLowerCase())))).slice(2),n=0;n<40;n+=1)if(parseInt(r[n],16)>7&&t[n].toUpperCase()!==t[n]||7>=parseInt(r[n],16)&&t[n].toLowerCase()!==t[n])return!1;return!0};function ep(e){var t;return e instanceof Uint8Array||(null==(t=null==e?void 0:e.constructor)?void 0:t.name)!=="Uint8Array"?e:Uint8Array.from(e)}var eh=new Set("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),em={SYSTEM_PROGRAM:"11111111111111111111111111111111",TOKEN_PROGRAM:"TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA",TOKEN_2022_PROGRAM:"TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb",ASSOCIATED_TOKEN_PROGRAM:"ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",RENT_SYSVAR:"SysvarRent111111111111111111111111111111111",CLOCK_SYSVAR:"SysvarC1ock11111111111111111111111111111111"};function eb(e){if("string"!=typeof e)return!1;var t=e.trim();if(t.length<32||t.length>44)return!1;for(var r=0;r<t.length;r++)if(!eh.has(t[r]))return!1;return!0}function ey(e){if(!e)return null;if("object"==typeof e&&"toBase58"in e)try{var t=e.toBase58();return eb(t)?t:null}catch(e){return null}if("string"==typeof e){var r=e.trim();return eb(r)?r:null}return null}function eg(e){var t,r=ey(e);return!!r&&!!((t=ey(r))&&Object.values(em).includes(t))}var ev={"mainnet-beta":900001,testnet:900002,devnet:900003,localnet:900004},ew={900001:"mainnet-beta",900002:"testnet",900003:"devnet",900004:"localnet"},eE=ev["mainnet-beta"];function eP(e){return null!=e&&Object.values(ev).includes(e)}function ex(e){return"sol.wallet.".concat(encodeURIComponent(e.toLowerCase().replace(/\s+/g,"")))}var eA=function(e){return"string"==typeof e&&""!==e.trim()&&ed(e.trim())?e.trim():null},eI=function(e){if(!e||"string"!=typeof e)return!1;var t=e.trim().toLowerCase();return!!t&&!!t.startsWith("0x")&&42===t.length&&x.some(function(e){return e.toLowerCase()===t})},eT=function(e){if(!ed(e,!1))throw Error("Invalid address "+e);var t=e.toLowerCase().replace(/^0x/i,""),r=el(ec(ep((0,M.utf8ToBytes)(t))));if(null==r||"0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470"===r)return"";for(var n="0x",i=r.replace(/^0x/i,""),a=0;a<t.length;a+=1)parseInt(i[a],16)>7?n+=t[a].toUpperCase():n+=t[a];return n},eS=function(e){var t=eA(e);return t?eT(t):void 0},eC=function(e,t){var r=Object.values(ev);if(null!=t&&r.includes(t))return ey(e)||void 0;if(null!=t)return eS(e);var n=eS(e);return n||eb(e)&&ey(e)||void 0},eO=function(e){return void 0===e};function ej(e,t){var r,n,i=null!=e?e:{},a=null!=t?t:{},o={};for(var s in i){Object.prototype.hasOwnProperty.call(i,s)&&(o[s]=Object.prototype.hasOwnProperty.call(a,s)?(r=i[s],n=a[s],ek(r)&&ek(n)?ej(r,n):n):i[s])}for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&(Object.prototype.hasOwnProperty.call(o,s)||(o[s]=a[s]));return o}function ek(e){return"[object Object]"===Object.prototype.toString.call(e)}var eR=function(){return(eR=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},e_=/^[A-Za-z0-9._-]{1,255}$/,eB=/^[A-Za-z0-9._-]{1,64}$/,eM=/[<>"'`\\\u0000-\u001f\u007f-\u009f\u200b-\u200f\u2028-\u202e\u2060\ufeff\ufffd]/,eF=/^\s*(javascript|data|vbscript):/i,eN=new Set(I),eU=function(e){for(var t=eR({},e),r=0,n=Object.keys(t);r<n.length;r++){var i=n[r],a=t[i];
2"string"==typeof a&&""!==a&&"referrer"!==i&&(eN.has(i)?t[i]=e_.test(a)?a:"":"ref"===i?t[i]=eB.test(a)?a:"":t[i]=!(a.length<=255)||eM.test(a)||eF.test(a)?"":a)}return t};function eH(e){return JSON.stringify(function e(t,r,n,i){var a=typeof t;if(null===t||"object"!==a&&"function"!==a&&"bigint"!==a)return t;if(!i){var o=t.toJSON;if("function"==typeof o)return e(Reflect.apply(o,t,[r]),r,n,!0)}if("bigint"==typeof t){if(i)throw TypeError("Do not know how to serialize a BigInt");return t}if("function"!=typeof t){if("u">typeof BigInt&&t instanceof BigInt){if(i)throw TypeError("Do not know how to serialize a BigInt");return BigInt.prototype.valueOf.call(t)}if(t instanceof Number)return Number.prototype.valueOf.call(t);if(t instanceof String)return String.prototype.valueOf.call(t);if(t instanceof Boolean)return Boolean.prototype.valueOf.call(t);if(n.has(t))throw TypeError("Converting circular structure to JSON");n.add(t);try{if(Array.isArray(t)){for(var s=[],c=t.length,u=0;u<c;u++)s.push(e(t[u],String(u),n,!1));return s}for(var l=Object.create(null),d=0,f=Object.keys(t).sort();d<f.length;d++){var p=f[d];l[p]=e(t[p],p,n,!1)}return l}finally{n.delete(t)}}}(e,"",new Set,!1))}function ez(e){var t=U((0,M.utf8ToBytes)(e));return(0,M.bytesToHex)(t)}function eL(){if("u">typeof crypto&&"function"==typeof crypto.randomUUID)return crypto.randomUUID();if("u">typeof crypto&&"function"==typeof crypto.getRandomValues){var e=new Uint8Array(16);crypto.getRandomValues(e),e[6]=15&e[6]|64,e[8]=63&e[8]|128;var t=Array.from(e).map(function(e){return e.toString(16).padStart(2,"0")}).join("");return"".concat(t.slice(0,8),"-").concat(t.slice(8,12),"-").concat(t.slice(12,16),"-").concat(t.slice(16,20),"-").concat(t.slice(20))}return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})}var eD=function(){return(eD=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},e$=function(e){try{var t=et().get(e);return"string"==typeof t&&t?t:void 0}catch(e){return}},eq=function(e,t){var r,n,i=ee().get(e),o=i&&"string"==typeof i?i:null!=(n=null!=(r=e$(e))?r:a)?n:eL(),s=en(t);if(ee().set(e,o,eD(eD({expires:new Date(Date.now()+31536e6).toUTCString(),path:"/"},ei()),s?{domain:s}:{})),s&&ee().get(e)!==o&&ee().set(e,o,eD({expires:new Date(Date.now()+31536e6).toUTCString(),path:"/"},ei())),ee().get(e)===o){if(a=void 0,Q&&"cookieStorage"===Q.getResolvedType("cookieStorage")&&e$(e))try{et().remove(e)}catch(e){}return o}try{et().set(e,o)}catch(e){}return a=o,o},eW=function(e){ee().remove(e);try{et().remove(e)}catch(e){}a=void 0},eG=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},eK=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},eV=null,eJ=null,eZ=Symbol(),eQ=function(){return(eQ=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},eY=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},eX=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},e0=function(e,t,r){if(r||2==arguments.length)for(var n,i=0,a=t.length;i<a;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))},e1=/^[A-Z]{2}$/,e6=function(){function e(e,t){void 0===t&&(t=function(){return!0});var r,n,i=this;this.canCreate=t,this.generation=0,this.extractUTMParameters=function(e){var t={utm_campaign:"",utm_content:"",utm_medium:"",utm_source:"",utm_term:""};
2try{new URL(e).searchParams.forEach(function(e,r){r.startsWith("utm_")&&(t[r]=e.trim())})}catch(e){}return t},this.extractClickIdParameters=function(e){for(var t={},r=0;r<I.length;r++){var n=I[r],i=e.searchParams.get(n);t[n]=i?i.trim():""}return t},this.extractReferralParameter=function(e){for(var t,r,n,a=(null==(t=i.options)?void 0:t.referral)&&null!=(r=i.options.referral.queryParams)?r:S,o=0;o<a.length;o++){var s=a[o],c=null==(n=e.searchParams.get(s))?void 0:n.trim();if(c)return c}if(i.compiledPathPattern){var u=e.pathname.match(i.compiledPathPattern);if(u&&u[1]){var l=u[1].trim();if(l)return l}}return""},this.getExternalReferrer=function(){var e,t=document.referrer;if(!t)return"";try{var r=null==(e=globalThis.location)?void 0:e.hostname;if(r&&new URL(t).hostname===r)return""}catch(e){}return i.redactUrl(t)},this.getTrafficSources=function(e){for(var t=new URL(e),r=eU(eQ(eQ(eQ({},i.extractUTMParameters(e)),i.extractClickIdParameters(t)),{ref:i.extractReferralParameter(t),referrer:i.getExternalReferrer()})),n=eU(i.redactStoredTrafficSources(er().get(g)||{})),a={},o=0;o<I.length;o++){var s=I[o];a[s]=r[s]||(null==n?void 0:n[s])||""}var c=eQ({ref:r.ref||(null==n?void 0:n.ref)||"",referrer:(null==n?void 0:n.referrer)||r.referrer||"",utm_campaign:r.utm_campaign||(null==n?void 0:n.utm_campaign)||"",utm_content:r.utm_content||(null==n?void 0:n.utm_content)||"",utm_medium:r.utm_medium||(null==n?void 0:n.utm_medium)||"",utm_source:r.utm_source||(null==n?void 0:n.utm_source)||"",utm_term:r.utm_term||(null==n?void 0:n.utm_term)||""},a),u=Object.keys(c).reduce(function(e,t){var r=c[t];return eO(r)||""===r||(e[t]=r),e},{});return Object.keys(u).length&&er().set(g,u),c},this.getPageProperties=function(e){var t=eQ({},e),r=null;try{r=new URL(globalThis.location.href),i.redactQueryParams(r),i.normalizeUrlPath(r)}catch(e){}eO(t.url)&&(t.url=r?r.href:globalThis.location.href),eO(t.path)&&(t.path=r?r.pathname:globalThis.location.pathname),eO(t.hash)&&(t.hash=globalThis.location.hash),eO(t.query)&&(t.query=r?r.search.slice(1):globalThis.location.search.slice(1));try{r&&r.searchParams.forEach(function(e,r){eO(t[r])&&!C.has(r)&&(t[r]=e)})}catch(e){R.error("Error parsing query parameters for page properties:",e)}return t},this.options=e;var a=null==e?void 0:e.tracking,o="object"==typeof a&&null!=(r=a.excludeQueryParams)?r:[];if(this.excludedQueryParams=new Set(e0(e0([],T,!0),o,!0).map(function(e){return e.toLowerCase()})),null==(n=null==e?void 0:e.referral)?void 0:n.pathPattern)try{this.compiledPathPattern=new RegExp(e.referral.pathPattern)}catch(t){R.warn("Invalid referral path pattern: ".concat(e.referral.pathPattern,". Error: ").concat(t))}}return e.prototype.validateEventAddress=function(e,t){return e&&eC(e,t)||null},e.prototype.getTimezone=function(){return eo()},e.prototype.getLocation=function(){try{var e=this.getTimezone();if(!e)return"";var t=y[e];return"string"==typeof t&&e1.test(t)?t:""}catch(e){return R.error("Error resolving location:",e),""}},e.prototype.getLanguage=function(){try{return(navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language)||"en"}catch(e){return R.error("Error resolving language:",e),"en"}},e.prototype.getLibraryVersion=function(){return"1.41.5"},e.prototype.isExcludedQueryParam=function(e){return this.excludedQueryParams.has(e.toLowerCase())},e.prototype.normalizeUrlPath=function(e){"/"!==e.pathname&&(e.pathname=e.pathname.replace(/\/+$/,""))},e.prototype.redactQueryParams=function(e){var t=this,r=new Set;e.searchParams.forEach(function(e,n){t.isExcludedQueryParam(n)&&r.add(n)}),r.forEach(function(t){return e.searchParams.delete(t)})},e.prototype.redactUrl=function(e){if(!e)return e;try{var t=new URL(e);return this.redactQueryParams(t),this.normalizeUrlPath(t),t.href}catch(t){return e}},e.prototype.redactStoredTrafficSources=function(e){for(var t={},r=0,n=Object.keys(e);r<n.length;r++){var i=n[r],a=e[i];"referrer"===i?t[i]=this.redactUrl(a||""):this.isExcludedQueryParam(i)?t[i]="":t[i]=a}return t},e.prototype.getScreen=function(){var e,t;try{return{screen_width:(null==(e=globalThis.screen)?void 0:e.width)||0,screen_height:(null==(t=globalThis.screen)?void 0:t.height)||0,screen_density:globalThis.devicePixelRatio||1,viewport_width:globalThis.innerWidth||0,viewport_height:globalThis.innerHeight||0}}catch(e){return R.error("Error resolving screen properties:",e),{screen_width:0,screen_height:0,screen_density:1,viewport_width:0,viewport_height:0}}},e.prototype.invalidate=function(){this.generation++},e.prototype.generateContext=function(e){return eY(this,void 0,void 0,function(){var t,r,n,i,a,o;return eX(this,function(s){switch(s.label){case 0:return[4,function(){return eJ?Promise.resolve(eJ):eV||(eV=eG(this,void 0,void 0,function(){var e;return eK(this,function(t){switch(t.label){case 0:return e=function(){try{return void 0!==globalThis.navigator?globalThis.navigator.userAgent:""}catch(e){return""}}(),[4,(function(){return eG(this,void 0,void 0,function(){var e,t,r,n;return eK(this,function(i){switch(i.label){case 0:if(!(e=void 0!==globalThis.navigator?globalThis.navigator:void 0))return[2,!1];i.label=1;case 1:if(i.trys.push([1,4,,5]),!(null==(r=e.brave)?void 0:r.isBrave))return[3,3];return[4,e.brave.isBrave().catch(function(){return!1})];case 2:if(i.sent())return[2,!0];i.label=3;case 3:return[3,5];case 4:return i.sent(),[3,5];case 5:try{if(null==(t=null==(n=e.userAgentData)?void 0:n.brands)?void 0:t.some(function(e){return/Brave/i.test(e.brand)}))return[2,!0]}catch(e){}try{if(/Brave/i.test(e.userAgent))return[2,!0]}catch(e){}return[2,!1]}})})})().catch(function(){return!1})];case 1:var r;return[2,eJ=t.sent()?"brave":(r=e,/Firefox\/\d+/i.test(r)?"firefox":/Edg\/\d+/i.test(r)?"edge":/OPR\/\d+/i.test(r)?"opera":/Safari\/\d+/i.test(r)&&!/Chrome\/\d+/i.test(r)?"safari":/Chrome\/\d+/i.test(r)?"chrome":"unknown")]}})}).finally(function(){eV=null}))}()];case 1:return t=s.sent(),r=this.getLanguage(),n=this.getTimezone(),i=this.getLocation(),a=this.getLibraryVersion(),o=this.redactUrl(globalThis.location.href),[2,ej(eQ(eQ(eQ({user_agent:globalThis.navigator.userAgent,locale:r,timezone:n,location:i},this.getTrafficSources(o)),{page_title:document.title,page_url:o,library_name:"Formo Web SDK",library_version:a,browser:t}
2),this.getScreen()),e||{})]}})})},e.prototype.getEnrichedEvent=function(e,t){return eY(this,void 0,void 0,function(){var r,n,i,a,o,s,c;return eX(this,function(u){switch(u.label){case 0:return r=this.generation,[4,this.generateContext(t)];case 1:var l,d;if(n=u.sent(),r!==this.generation||!this.canCreate())throw eZ;return(i={context:n,original_timestamp:new Date().toISOString(),user_id:e.user_id,type:e.type,channel:"web",version:"0"}).anonymous_id=eq(E,null==(s=this.options)?void 0:s.crossSubdomainCookies),a=null==(c=e.properties)?void 0:c.chainId,i.address=this.validateEventAddress(e.address,a),void 0===(o=ej(e,i)).event&&(o.event=null),void 0===o.properties&&(o.properties=null),[2,(void 0===l&&(l=[]),(d=function(e){return Array.isArray(e)?e.map(d):null!==e&&"object"==typeof e?Object.keys(e).reduce(function(t,r){return t[l.includes(r)?r:r.replace(/([a-z])([A-Z])/g,"$1_$2").replace(/[\s-]+/g,"_").toLowerCase()]=l.includes(r)?e[r]:d(e[r]),t},{}):e})(o))]}})})},e.prototype.generatePageEvent=function(e,t,r,n){return eY(this,void 0,void 0,function(){var i,a;return eX(this,function(o){return(i=eQ({},null!=r?r:{})).category=e,i.name=t,a={properties:i=this.getPageProperties(i),type:"page"},[2,this.getEnrichedEvent(a,n)]})})},e.prototype.generateDetectWalletEvent=function(e,t,r,n){return eY(this,void 0,void 0,function(){var i;return eX(this,function(a){return i={properties:eQ({providerName:e,rdns:t},r),type:"detect"},[2,this.getEnrichedEvent(i,n)]})})},e.prototype.generateIdentifyEvent=function(e,t,r,n,i,a){return eY(this,void 0,void 0,function(){var o;return eX(this,function(s){return o={properties:eQ(eQ(eQ({},void 0!==e&&{providerName:e}),void 0!==t&&{rdns:t}),i),user_id:n,address:r,type:"identify"},[2,this.getEnrichedEvent(o,a)]})})},e.prototype.generateConnectEvent=function(e,t,r,n){return eY(this,void 0,void 0,function(){var i;return eX(this,function(a){return i={properties:eQ({chainId:e},r),address:t,type:"connect"},[2,this.getEnrichedEvent(i,n)]})})},e.prototype.generateDisconnectEvent=function(e,t,r,n){return eY(this,void 0,void 0,function(){var i;return eX(this,function(a){return i={properties:eQ({chainId:e},r),address:t,type:"disconnect"},[2,this.getEnrichedEvent(i,n)]})})},e.prototype.generateChainChangedEvent=function(e,t,r,n){return eY(this,void 0,void 0,function(){var i;return eX(this,function(a){return i={properties:eQ({chainId:e},r),address:t,type:"chain"},[2,this.getEnrichedEvent(i,n)]})})},e.prototype.generateSignatureEvent=function(e,t,r,n,i,a){return eY(this,void 0,void 0,function(){var o;return eX(this,function(s){return o={properties:eQ({status:e,chainId:t,message:n},i),address:r,type:"signature"},[2,this.getEnrichedEvent(o,a)]})})},e.prototype.generateTransactionEvent=function(e,t,r,n,i,a,o,s,c,u,l){return eY(this,void 0,void 0,function(){var d;return eX(this,function(f){return d={properties:eQ(eQ(eQ(eQ(eQ(eQ(eQ({status:e,chainId:t},n&&{data:n}),i&&{to:i}),a&&{value:a}),o&&{transactionHash:o}),s&&{function_name:s}),c&&{function_args:c}),u),address:r,type:"transaction"},[2,this.getEnrichedEvent(d,l)]})})},e.prototype.generateTrackEvent=function(e,t,r){return eY(this,void 0,void 0,function(){var n;return eX(this,function(i){return n={properties:eQ(eQ(eQ(eQ({},t),(null==t?void 0:t.revenue)!==void 0&&{revenue:Number(t.revenue),currency:("string"==typeof(null==t?void 0:t.currency)?t.currency:"USD").toLowerCase()}),(null==t?void 0:t.points)!==void 0&&{points:Number(t.points)}),(null==t?void 0:t.volume)!==void 0&&{volume:Number(t.volume)}),event:e,type:"track"},[2,this.getEnrichedEvent(n,r)]})})},e.prototype.create=function(e,t,r){return eY(this,void 0,void 0,function(){var n,i,a,o;return eX(this,function(s){switch(s.label){case 0:switch(n={},e.type){case"page":return[3,1];case"detect":return[3,3];case"identify":return[3,5];case"chain":return[3,7];case"connect":return[3,9];case"disconnect":return[3,11];case"signature":return[3,13];case"transaction":return[3,15]}return[3,17];case 1:return[4,this.generatePageEvent(e.category,e.name,e.properties,e.context)];case 2:case 4:case 6:case 8:case 10:case 12:case 14:case 16:case 18:return n=s.sent(),[3,19];case 3:return[4,this.generateDetectWalletEvent(e.providerName,e.rdns,e.properties,e.context)];case 5:return[4,this.generateIdentifyEvent(e.providerName,e.rdns,e.address,e.userId,e.properties,e.context)];case 7:return[4,this.generateChainChangedEvent(e.chainId,e.address,e.properties,e.context)];case 9:return[4,this.generateConnectEvent(e.chainId,e.address,e.properties,e.context)];case 11:return[4,this.generateDisconnectEvent(e.chainId,e.address,e.properties,e.context)];case 13:return[4,this.generateSignatureEvent(e.status,e.chainId,e.address,e.message,e.properties,e.context)];case 15:return[4,this.generateTransactionEvent(e.status,e.chainId,e.address,e.data,e.to,e.value,e.transactionHash,e.function_name,e.function_args,e.properties,e.context)];case 17:return[4,this.generateTrackEvent(e.event,e.properties,e.context)];case 19:return(void 0===n.address||null===n.address)&&"identify"!==e.type&&(i="chainId"in e?e.chainId:void 0,n.address=this.validateEventAddress(t,i)),n.user_id="identify"===e.type?null!=(o=null!=(a=n.user_id
2)?a:r)?o:null:r||null,[2,n]}})})},e}(),e5={suppressed:"tracking is off for this visitor, environment, or chain",duplicate:"an identical event was already accepted",consent_withdrawn:"consent was withdrawn before delivery",closed:"the SDK was cleaned up before delivery",blocked:"the address is blocked",invalid_key:"the idempotency_key must be a non-empty string or a safe integer",invalid:"the call carried a missing or invalid address or chain"};function e2(e){return Object.assign(Error("Event not sent: ".concat(e5[e])),{code:e})}function e8(e,t,r){if(e)try{e(e2(r),t,[])}catch(e){}}var e3=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},e4=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)0>t.indexOf(n[i])&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r},e9=function(){function e(e,t,r){void 0===r&&(r=function(){return!0});var n=this;this.canAcceptEvent=r,this.generation=0,this.closed=!1,this.eventQueue=e,this.eventFactory=new e6(t,function(){return n.canAcceptEvent()})}return e.prototype.addEvent=function(e,t,r){var n,i,a,o;return n=this,i=void 0,a=void 0,o=function(){var n,i,a,o,s,c,u,l,d,f,p=this;return e3(this,function(h){switch(h.label){case 0:if(n=e.callback,a=(i=e4(e,["callback"])).idempotencyKey,o=e4(i,["idempotencyKey"]),s=this.generation,!(c=function(){return s===p.generation&&p.canAcceptEvent()})())return[2];u="track"===e.type?ez(null!=(f=eH({event:o,address:null!=t?t:null,userId:null!=r?r:null}))?f:""):void 0,h.label=1;case 1:return h.trys.push([1,3,,4]),[4,this.eventFactory.create(o,t,r)];case 2:return l=h.sent(),[3,4];case 3:if((d=h.sent())!==eZ)throw d;return[2,e8(n,o,this.closed?"closed":"consent_withdrawn")];case 4:if(!c())return[2,e8(n,o,this.closed?"closed":"consent_withdrawn")];if(l.address&&eI(l.address))return R.warn("Event blocked: Address ".concat(l.address," is in the blocked list and cannot emit events")),[2,e8(n,o,"blocked")];return this.eventQueue.enqueue(l,function(e,t,r){e?R.error("Error sending events:",e):R.info("Events sent successfully: ".concat(r.length," events")),null==n||n(e,t,r)},{dedupKey:u,idempotencyKey:a}),[2]}})},new(a||(a=Promise))(function(e,t){function r(e){try{c(o.next(e))}catch(e){t(e)}}function s(e){try{c(o.throw(e))}catch(e){t(e)}}function c(t){var n;t.done?e(t.value):((n=t.value)instanceof a?n:new a(function(e){e(n)})).then(r,s)}c((o=o.apply(n,i||[])).next())})},e.prototype.clear=function(){this.generation++,this.eventFactory.invalidate(),this.eventQueue.clear()},e.prototype.close=function(){this.closed=!0,this.generation++,this.eventFactory.invalidate(),this.eventQueue.close()},e}(),e7=Object.prototype.toString,te=function(e){var t=e7.call(e);return"[object Error]"===t||"[object DOMException]"===t},tt=new Set(["TypeError","TimeoutError","NetworkError"]),tr=new Set(["network error","Failed to fetch","NetworkError when attempting to fetch resource.","The Internet connection appears to be offline.","Load failed","Network request failed","fetch failed","terminated","The operation was aborted due to timeout"]),tn=function(e,t){var r=e;return(null==t?void 0:t.status)&&(r+=" ".concat(t.status)),("connect"===e||"disconnect"===e)&&(null==t?void 0:t.rdns)&&(r+=" (".concat(t.rdns,")")),r},ti=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},ta=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)0>t.indexOf(n[i])&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r};let to=function(e,t){var r,n,i,a;return r=this,n=void 0,i=void 0,a=function(){var r,n,i,a,o,s,c,u,l;return ti(this,function(d){switch(d.label){case 0:i=void 0===(n=(r=t||{}).retries)?0:n,a=r.retryDelay,o=r.retryOn,s=ta(r,["retries","retryDelay","retryOn"]),c=function(t){var r,n,c,u;return ti(this,function(l){switch(l.label){case 0:r=t===i,l.label=1;case 1:return l.trys.push([1,6,,10]),[4,globalThis.fetch(e,s)];case 2:if((n=l.sent()).ok||r)return[2,{value:n}];
2if((c=Error(n.statusText)).response=n,!(null==o?void 0:o(t,c,n)))return[3,5];if(!a)return[3,4];return[4,new Promise(function(e){return setTimeout(e,a(t))})];case 3:l.sent(),l.label=4;case 4:return[2,"continue"];case 5:return[2,{value:n}];case 6:if(u=l.sent(),r)throw u;if(!(null==o?void 0:o(t,u,null)))return[3,9];if(!a)return[3,8];return[4,new Promise(function(e){return setTimeout(e,a(t))})];case 7:l.sent(),l.label=8;case 8:return[2,"continue"];case 9:throw u;case 10:return[2]}})},u=0,d.label=1;case 1:if(!(u<=i))return[3,4];return[5,c(u)];case 2:if("object"==typeof(l=d.sent()))return[2,l.value];d.label=3;case 3:return u++,[3,1];case 4:throw Error("Unexpected: retry loop exited without returning or throwing")}})},new(i||(i=Promise))(function(e,t){function o(e){try{c(a.next(e))}catch(e){t(e)}}function s(e){try{c(a.throw(e))}catch(e){t(e)}}function c(t){var r;t.done?e(t.value):((r=t.value)instanceof i?r:new i(function(e){e(r)})).then(o,s)}c((a=a.apply(r,n||[])).next())})};var ts=function(){return(ts=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},tc=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},tu=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},tl=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)0>t.indexOf(n[i])&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r},td=function(){},tf=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];try{e.apply(void 0,t)}catch(e){}},tp=["page_title","screen_width","screen_height","screen_density","viewport_width","viewport_height"],th=function(){return"u">typeof performance&&"function"==typeof performance.now?performance.now():void 0},tm=function(){function e(e,t){var r=this;this.queue=[],this.queueByteSize=0,this.payloadHashes=new Map,this.acceptanceSeq=0,this.lastWall=Date.now(),this.wallElapsed=0,this.monotonicStart=th(),this.clearSeq=0,this.closed=!1,this.disposePageLeave=null,this.onPageLeave=function(e){var t=!1,r=!1,n=null;function i(){t||(t=!0,e(r),n=setTimeout(function(){n=null,t=!1},0))}var a=function(){r=!1,i()},o=function(){r=!0,i()},s=function(){t=!1},c=function(){r="hidden"!==document.visibilityState,i()},u=function(){r="hidden"!==document.visibilityState,"hidden"===document.visibilityState?i():t=!1},l=globalThis,d=document;return l.addEventListener("beforeunload",a),l.addEventListener("blur",o),l.addEventListener("focus",s),d.addEventListener("pagehide",c),d.addEventListener("visibilitychange",u),function(){n&&(clearTimeout(n),n=null),l.removeEventListener("beforeunload",a),l.removeEventListener("blur",o),l.removeEventListener("focus",s),d.removeEventListener("pagehide",c),d.removeEventListener("visibilitychange",u)}},t=t||{},this.queue=[],this.writeKey=e,this.apiHost=t.apiHost,this.canSend=t.canSe
2nd,this.retryCount=ea(t.retryCount||3,5,1),this.flushAt=ea(t.flushAt||20,20,1),this.maxQueueSize=ea(t.maxQueueSize||512e3,512e3,200),this.flushIntervalMs=ea(t.flushInterval||3e4,3e5,1e4),this.flushed=!1,this.errorHandler=t.errorHandler,this.pendingFlush=null,this.timer=null,this.disposePageLeave=this.onPageLeave(function(e){return tc(r,void 0,void 0,function(){return tu(this,function(t){switch(t.label){case 0:if(!1!==e)return[3,2];return[4,this.flush(void 0,!0)];case 1:t.sent(),t.label=2;case 2:return[2]}})})})}return e.prototype.generateMessageId=function(e,t){return tc(this,void 0,void 0,function(){var r,n;return tu(this,function(i){var a;return void 0!==t?[2,ez(JSON.stringify({type:e.type,event:null!=(n=e.event)?n:null,idempotencyKey:t}))]:"track"===e.type?[2,eL()]:(r=(a=new Date(e.original_timestamp)).getUTCFullYear()+"-"+("0"+(a.getUTCMonth()+1)).slice(-2)+"-"+("0"+a.getUTCDate()).slice(-2)+" "+("0"+a.getUTCHours()).slice(-2)+":"+("0"+a.getUTCMinutes()).slice(-2),[2,ez(JSON.stringify(ts(ts({},e),{original_timestamp:r})))])})})},e.prototype.generateDedupKey=function(e){return tc(this,void 0,void 0,function(){var t,r,n,i,a,o,s;return tu(this,function(c){if(e.original_timestamp,t=e.context,r=tl(e,["original_timestamp","context"]),n=t?ts({},t):t)for(i=0,a=tp;i<a.length;i++)o=a[i],delete n[o];return[2,ez(null!=(s=eH(ts(ts({},r),{context:n})))?s:"")]})})},e.prototype.clear=function(){this.clearSeq++,this.closed||(this.flushed=!1,this.pendingFlush=null,this.timer&&(clearTimeout(this.timer),this.timer=null),this.payloadHashes.clear()),this.dropBuffered(e2("consent_withdrawn"))},e.prototype.dropBuffered=function(e){var t=this.queue;this.queue=[],this.queueByteSize=0;for(var r=0;r<t.length;r++){var n=t[r],i=n.message;tf(n.callback,e,i,[])}},e.prototype.close=function(){!this.closed&&(this.timer&&(clearTimeout(this.timer),this.timer=null),this.queue.length&&this.flush(void 0,!0),this.closed=!0,this.dropBuffered(e2("closed")),this.flushed=!1,this.payloadHashes.clear(),this.disposePageLeave&&(tf(this.disposePageLeave),this.disposePageLeave=null))},Object.defineProperty(e.prototype,"isClosed",{get:function(){return this.closed},enumerable:!1,configurable:!0}),e.prototype.enqueue=function(e,t,r){return tc(this,void 0,void 0,function(){var n,i,a,o,s,c,u,l,d,f,p;return tu(this,function(h){switch(h.label){case 0:if(n=t||td,i=function(t){n!==td&&tf(n,e2(t),e,[])},this.closed)return[2,i("closed")];if(this.canSend&&!this.canSend())return this.clear(),[2,i("consent_withdrawn")];return a=this.clearSeq,[4,Promise.all([this.generateMessageId(e,null==r?void 0:r.idempotencyKey),this.generateDedupKey(e)])];case 1:if(s=(o=h.sent())[0],c=o[1],u=(null==r?void 0:r.idempotencyKey)?s:(null==r?void 0:r.dedupKey)||c,this.closed)return[2,i("closed")];if(this.canSend&&!this.canSend())return this.clear(),[2,i("consent_withdrawn")];if(this.clearSeq!==a)return[2,i("consent_withdrawn")];if(this.isDuplicate(u))return l=e.event?"".concat(e.type,' "').concat(e.event,'"'):e.type,R.warn("Duplicate ".concat(l," dropped: an identical event was accepted less than ").concat(Math.ceil(60)," seconds ago.")),[2,i("duplicate")];if((d={message:ts(ts({},e),{message_id:s}),callback:n,dedupKey:u,dedupToken:this.acceptanceSeq,byteSize:0}).byteSize=JSON.stringify({message:d.message}).length,this.queue.push(d),this.queueByteSize+=d.byteSize,R.log("Event enqueued: ".concat(tn(e.type,e.properties))),!this.flushed)return this.flushed=!0,this.flush(),[2];if(f=this.queue.length>=this.flushAt,p=this.queueByteSize>=this.maxQueueSize,f||p)return this.flush(),[2];return this.flushIntervalMs&&!this.timer&&(this.timer=setTimeout(this.flush.bind(this),this.flushIntervalMs)),[2]}})})},e.prototype.flush=function(e){return tc(this,arguments,void 0,function(e,t){var r,n,i,a,o,s,c,u,l,d=this;return void 0===t&&(t=!1),tu(this,function(f){switch(f.label){case 0:if(e=e||td,this.timer&&(clearTimeout(this.timer),this.timer=null),this.canSend&&!this.canSend())return this.clear(),tf(e),[2,Promise.resolve()];if(!this.queue.length)return tf(e),[2,Promise.resolve()];if(r=this.clearSeq,!this.pendingFlush||t)return[3,2];return[4,this.pendingFlush];case 1:if(f.sent(),this.closed||this.clearSeq!==r)return tf(e),[2,Promise.resolve()];if(this.canSend&&!this.canSend())return this.clear(),tf(e),[2,Promise.resolve()];if(!this.queue.length)return tf(e),[2,Promise.resolve()];f.label=2;case 2:for(n=this.queue.splice(0,t?this.queue.length:this.flushAt),i=0,a=n;i<a.length;i++)o=a[i],this.queueByteSize-=o.byteSize;return 0===this.queue.length&&(this.queueByteSize=0),s=new Date().toISOString(),c=n.map(function(e){return ts(ts({},e.message),{sent_at:s})}),u=this.splitIntoBatches(n,c),l=this.sendBatches(u,c,r).then(function(t){return t?(tf(e,t,c),"function"==typeof d.errorHandler&&tf(d.errorHandler,t)):tf(e,void 0,c),Promise.resolve(c)}).catch(function(t){tf(e,t,c),"function"==typeof d.errorHandler&&tf(d.errorHandler,t)}),[2,this.pendingFlush=l]}})})},e.byteLength=function(e){return new TextEncoder().encode(e).byteLength},e.prototype.splitIntoBatches=function(t,r){var n=JSON.stringify(r);if(65536>=e.byteLength(n))return[{data:r,items:t,keepalive:!0}];for(var i=[],a=[],o=[],s=2,c=0;c<r.length;c++){var u=r[c],l=e.byteLength(JSON.stringify(u)),d=s+ +(a.length>0)+l;d>65536?(a.length>0&&i.push({data:a,items:o,keepalive:!0}),l+2>65536?(i.push({data:[u],items:[t[c]],keepalive:!1}),a=[],o=[],s=2):(a=[u],o=[t[c]],s=2+l)):(a.push(u),o.push(t[c]),s=d)}return a.length>0&&i.push({data:a,items:o,keepalive:!0}),i},e.prototype.sendBatches=function(e,t,r){return tc(this,void 0,void 0,function(){var n,i,a,o,s=this;return tu(this,function(c){switch(c.label){case 0:i=function(i){var o,c,u,l,d,f,p;return tu(this,function(h){switch(h.label){case 0:if(o=e[i],a.canSend&&!a.canSend()||a.clearSeq!==r){for(c=e2("consent_withdrawn"),n=n||c,u=i;u<e.length;
2u++)a.releaseFingerprints(e[u].items),e[u].items.forEach(function(e){var r=e.message;return tf(e.callback,c,r,t)});return[2,"break"]}h.label=1;case 1:var m;return h.trys.push([1,3,,4]),l=JSON.stringify(o.data),[4,to("".concat(a.apiHost),{headers:(m=a.writeKey,{"Content-Type":"application/json",Authorization:"Bearer ".concat(m)}),method:"POST",body:l,keepalive:o.keepalive,retries:a.retryCount,retryDelay:function(e){return 1e3*Math.pow(2,e)},retryOn:function(e,t,r){return s.isErrorRetryable(t,r)}})];case 2:if(!(d=h.sent()).ok)throw(f=Error(d.statusText||"HTTP ".concat(d.status))).response=d,f;return o.items.forEach(function(e){var r=e.message;return tf(e.callback,void 0,r,t)}),[3,4];case 3:return p=h.sent(),n=n||p,a.releaseFingerprints(o.items),o.items.forEach(function(e){var r=e.message;return tf(e.callback,p,r,t)}),[3,4];case 4:return[2]}})},a=this,o=0,c.label=1;case 1:if(!(o<e.length))return[3,4];return[5,i(o)];case 2:if("break"===c.sent())return[3,4];c.label=3;case 3:return o++,[3,1];case 4:return[2,n]}})})},e.prototype.isErrorRetryable=function(e,t){if(e&&e&&te(e)&&tt.has(e.name)&&"string"==typeof e.message&&("Load failed"===e.message?void 0===e.stack:tr.has(e.message)))return!0;var r,n,i=null!=(r=null==t?void 0:t.status)?r:null==(n=null==e?void 0:e.response)?void 0:n.status;return!!i&&(!!(i>=500)&&!!(i<=599)||429===i)},e.prototype.isDuplicate=function(e){var t=this.elapsedNow();return this.pruneExpired(t),!!this.payloadHashes.has(e)||(this.payloadHashes.set(e,{expiresAt:t+6e4,token:++this.acceptanceSeq}),!1)},e.prototype.releaseFingerprints=function(e){for(var t=0;t<e.length;t++){var r=e[t],n=this.payloadHashes.get(r.dedupKey);n&&n.token===r.dedupToken&&this.payloadHashes.delete(r.dedupKey)}},e.prototype.elapsedNow=function(){var e=Date.now(),t=e-this.lastWall;this.lastWall=e,t>0&&(this.wallElapsed+=t);var r=th(),n=void 0!==r&&void 0!==this.monotonicStart?r-this.monotonicStart:0;return Math.max(this.wallElapsed,n)},e.prototype.pruneExpired=function(e){for(var t=this.payloadHashes.entries(),r=t.next();!r.done;r=t.next()){var n=r.value[0];if(r.value[1].expiresAt>e)break;this.payloadHashes.delete(n)}},e}();function tb(e,t){return"formo_".concat(H(e),"_").concat(t)}var ty=function(){return(ty=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},tg="wallet-detected",tv="wallet-identified",tw=function(){function e(){}return e.prototype.generateIdentificationKey=function(e,t,r,n){return this.buildIdentificationKey(e,t,r,n).key},e.prototype.buildIdentificationKey=function(e,t,r,n){var i=function(e){if(e){try{var t,r,n=function e(t,r){if((void 0===r&&(r=new Set),void 0!==t&&"function"!=typeof t)&&"symbol"!=typeof t){if(null===t)return"null";if("bigint"==typeof t)return"bigint:".concat(t.toString());if("number"==typeof t)return Number.isFinite(t)?JSON.stringify(t):"null";if("object"!=typeof t)return JSON.stringify(t);if(r.has(t))return'"[circular]"';r.add(t);try{var n=t.toJSON;if("function"==typeof n)return e(n.call(t),r);if(Array.isArray(t))return"[".concat(t.map(function(t){var n;return null!=(n=e(t,r))?n:"null"}).join(","),"]");for(var i=[],a=0,o=Object.keys(t).sort();a<o.length;a++){var s=o[a],c=e(t[s],r);void 0!==c&&i.push("".concat(JSON.stringify(s),":").concat(c))}return"{".concat(i.join(","),"}")}finally{r.delete(t)}}}(e);if(void 0===n||"{}"===n)return;r=n}catch(e){return null==(t=R.warn)||t.call(R,"Session: failed to fingerprint identify properties",e),"nohash"}for(var i=0x811c9dc5,a=0x1000193,o=0;o<r.length;o++){var s=r.charCodeAt(o);i^=s,i=Math.imul(i,0x1000193),a^=s+o,a=Math.imul(a,0x85ebca6b)}return"".concat((i>>>0).toString(36)).concat((a>>>0).toString(36))}}(n),a=[encodeURIComponent(e)];if(r||i){a.push(encodeURIComponent(t||"")),a.push(encodeURIComponent(r||""));var o=a.join(":");return i&&a.push(i),{key:a.join(":"),identityPrefix:o}}return t&&a.push(encodeURIComponent(t)),{key:a.join(":")}},e.prototype.isWalletDetected=function(e){var t;return((null==(t=ee().get(tg))?void 0:t.split(","))||[]).includes(e)},e.prototype.markWalletDetected=function(e){var t,r=(null==(t=ee().get(tg))?void 0:t.split(","))||[];r.includes(e)||(r.push(e),r.length>20&&r.splice(0,r.length-20),ee().set(tg,r.join(","),ty({expires:new Date(Date.now()+864e5).toUTCString(),path:"/"},ei())))},e.prototype.isWalletIdentified=function(e,t,r,n){var i=this.generateIdentificationKey(e,t,r,n),a=ee().get(tv),o=((null==a?void 0:a.split(","))||[]).includes(i);return R.debug("Session: Checking wallet identification",{identifiedKey:i,isIdentified:o,hasRdns:!!t}),o},e.prototype.markWalletIdentified=function(e,t,r,n){var i,a=this.buildIdentificationKey(e,t,r,n),o=a.key,s=a.identityPrefix,c=(null==(i=ee().get(tv))?void 0:i.split(","))||[];if(c.includes(o))R.info("Session: Wallet already marked as identified",{identifiedKey:o,existingWallets:c,hasRdns:!!t});else{s&&(c=c.filter(function(e){return e!==s&&!e.startsWith("".concat(s,":"))})),c.push(o);for(var u=c.join(",");c.length>1&&encodeURIComponent(u).length>3584;)c.shift(),u=c.join(",");ee().set(tv,u,ty({expires:new Date(Date.now()+864e5).toUTCString(),path:"/"},ei())),R.debug("Session: Marked wallet as identified",{identifiedKey:o,hasRdns:!!t})}},e}(),tE=function(){function e(e){this.deps=e}return e.prototype.trackingOptions=function(){var e=this.deps.options().tracking;return null===e||"object"!=typeof e||Array.isArray(e)?null:e},e.prototype.isTrackingSuppressed=function(){return this.deps.hasOptedOut()||this.isEnvironmentExcluded()},e.prototype.isEnvironmentExcluded=function(){return this.isTimezoneExcluded()||this.isHostExcluded()||this.isPathExcluded()},e.prototype.isHostExcluded=function(){var e=this.trackingOptions();if(!e)return!1;var t=e.excludeHosts;return(void 0===t?[]:t).includes(window.location.hostname)},e.prototype.isPathExcluded=function(){var e=this.trackingOptions();if(!e)return!1;var t=e.excludePaths;return(void 0===t?[]:t).includes(window.location.pathname)},e.prototype.isTimezoneExcluded=function(){var e=this.trackingOptions();if(!e)return!1;var t=e.excludeTimezones,r=void 0===t?[]:t;if(0===r.length)return!1;var n=eo();if(!n)return!1;var i=n.toLowerCase();return r.some(function(e){return"string"==typeof e&&e.toLowerCase()===i})},e.prototype.isPageExcluded=function(){return this.isHostExcluded()||this.isPathExcluded()},e.prototype.isPersistedIdentityPurgeRequired=function(){return this.deps.hasOptedOut()||this.isTimezoneExcluded()},e.prototype.isChainExcluded=function(e){var t=this.trackingOptions();if(!t)return!1;var r=t.excludeChains,n=void 0===r?[]:r;return 0!==n.length&&this.isChainRefused(n,e)},e.prototype.isChainRefused=function(e,t){var r,n=null!=(r=null==t?void 0:t.chainId)?r:this.deps.currentChainId();return 0===n||void 0!==n&&e.includes(n)},e.prototype.shouldTrack=function(e){if(this.deps.hasOptedOut())return!1;var t=this.deps.options().tracking;if("boolean"==typeof t)return t;var r=this.trackingOptions();if(r){if(this.isEnvironmentExcluded())return!1;var n=r.excludeChains,i=void 0===n?[]:n;return!(i.length>0&&this.isChainRefused(i,e))}return!(/^localhost$|^127(?:\.[0-9]+){0,2}\.[0-9]+$|^(?:0*:)*?:?0*1$/.test(window.location.hostname)||"file:"===window.location.protocol)},e.prototype.isAutocaptureEnabled=function(e){var t=this.deps.options().autocapture;return void 0===t||("boolean"==typeof t?t:null===t||"object"!=typeof t||!1!==t[e])},e}(),tP=function(){return(tP=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},tx=function(){function e(e){this.deps=e,this.state={evm:{},solana:{}},this.observationSeq=0,this.claimSeq=0,this.namespaceClaims={evm:0,solana:0},this.newestObservation={evm:0,solana:0},this.disconnectCount={evm:0,solana:0},this.resetCount=0}return Object.defineProperty(e.prototype,"activeNamespace",{get:function(){return this._activeNamespace}
2,enumerable:!1,configurable:!0}),e.prototype.namespaceOf=function(e){return eP(e)?"solana":"evm"},Object.defineProperty(e.prototype,"evmAddress",{get:function(){return this.state.evm.address},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"solanaAddress",{get:function(){return this.state.solana.address},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"evmChainId",{get:function(){return this.state.evm.chainId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"provider",{get:function(){return this.state.evm.provider},set:function(e){this.displaceProvider(this.state.evm.provider,e),this.state.evm.provider=e},enumerable:!1,configurable:!0}),e.prototype.observe=function(e){this.claimSeq++,this.namespaceClaims[e]++;var t=++this.observationSeq;return this.newestObservation[e]=t,{id:t,namespace:e}},e.prototype.beginDisconnect=function(e){this.disconnectCount[e]++},e.prototype.disconnectsSoFar=function(e){return this.disconnectCount[e]},e.prototype.snapshot=function(e){return this.newestObservation[e]},e.prototype.isUnchangedSince=function(e,t){return this.newestObservation[e]===t},e.prototype.currentObservation=function(e){return{id:this.newestObservation[e],namespace:e}},e.prototype.isCurrent=function(e){return this.newestObservation[e.namespace]===e.id},e.prototype.restore=function(e,t){var r=eC(t,e);if(!r)return void R.warn('restore: invalid address ("'.concat(t,'") for chain ').concat(e));var n=this.namespaceOf(e),i=this.state[n];if(this.deps.isTrackingSuppressed()){i.address===r&&i.chainId!==e&&(this.observe(n),i.chainId=e,this.syncDerived());return}i.address=r,i.chainId=e,this._activeNamespace||(this._activeNamespace=n),this.observe(n),this.syncDerived()},e.prototype.deferRestore=function(e){var t=this,r=this.namespaceOf(e),n=this.namespaceClaims[r],i=this.resetCount,a=this._activeNamespace===r,o=this.claimSeq;return function(e){if(t.namespaceClaims[r]!==n||i!==t.resetCount)return void R.debug("restore: skipped, the namespace changed hands or was reset meanwhile");var s=t.claimSeq===o;t.restore(e.chainId,e.address),a&&s&&t.state[r].address&&(t._activeNamespace=r,t.syncDerived())}},e.prototype.set=function(e,t){var r="string"==typeof e?e:this.namespaceOf(e),n=this.state[r];this.claimSeq++,this.namespaceClaims[r]++,"address"in t&&(n.address=t.address),"chainId"in t?n.chainId=t.chainId:"number"==typeof e&&(n.chainId=e),"evm"===r&&"provider"in t&&(this.displaceProvider(n.provider,t.provider),n.provider=t.provider),this._activeNamespace=r,this.syncDerived()},e.prototype.clear=function(e){"evm"===("string"==typeof e?e:this.namespaceOf(e))?(this.displaceProvider(this.state.evm.provider,void 0),this.state.evm={}):this.state.solana={},this.syncDerived()},e.prototype.reset=function(){this.resetCount++;var e=this.state.evm.provider;this.state={evm:{provider:e},solana:{}},this._activeNamespace=void 0,this.address=void 0,this.chainId=void 0},e.prototype.clearProvider=function(){this.provider=void 0},e.prototype.setActiveAddress=function(e){this.address=e,this.persist()},e.prototype.setActiveChainId=function(e){this.chainId=e,this.persist()},e.prototype.clearActiveChainId=function(){this.setActiveChainId(void 0)},e.prototype.syncWalletState=function(e){var t=e.chainId,r=e.address;if(this.observe(this.namespaceOf(t)),this.deps.isTrackingSuppressed()){if(!r)return void this.clearForChain(t);if(null==t)return;var n=this.namespaceOf(t),i=this.state[n].address,a=eC(r,t);return void(i&&a&&a!==i&&this.clear(t))}if(!r)return void this.clearForChain(t);if(null!=t){var o=eC(r,t);if(!o)return void R.warn('syncWalletState: invalid address ("'.concat(r,'") for chain ').concat(t));this.set(t,{address:o})}},e.prototype.backfill=function(e,t,r){if(r&&void 0!==t&&0!==t){var n=this.deps.providerChainId(r);void 0!==n&&n!==t&&(t=n)}if(!this.deps.isTrackingSuppressed()){var i=this.evmAddress;if(i){void 0===t||0===t&&this.evmChainId||i.toLowerCase()!==e.toLowerCase()||this.evmChainId===t||this.set("evm",{address:i,chainId:t});return}this.set("evm",{address:e,chainId:t})}},e.prototype.clearStaleEvmWalletOnSwitchWhileSuppressed=function(e){var t=this.state.evm.address,r=eS(e);t&&r&&r!==t&&this.clear("evm")},e.prototype.persist=function(){try{if(this.deps.isPersistedIdentityPurgeRequired())return void ee().remove(w);if(this.address){if(this.deps.isPageExcluded())return;var e=JSON.stringify(tP({address:this.address},void 0!==this.chainId&&{chainId:this.chainId})),t=en(this.deps.crossSubdomainCookies());ee().set(w,e,tP(tP({path:"/",expires:new Date(Date.now()+864e5).toUTCString()},ei()),t?{domain:t}:{}))}else ee().remove(w)}catch(e){R.warn("Failed to persist current wallet snapshot",e)}
2},e.prototype.load=function(){try{if(this.deps.isPersistedIdentityPurgeRequired())return void ee().remove(w);if(this.deps.isPageExcluded())return;var e=ee().get(w);if(!e)return;var t=JSON.parse(e);if(!(null==t?void 0:t.address))return;var r=t.chainId,n=null==r;if(!n&&("number"!=typeof r||!Number.isFinite(r)))return void ee().remove(w);var i=n?void 0:r,a=void 0===i?eS(t.address)?"evm":"solana":this.namespaceOf(i),o=eC(t.address,i);if(!o)return void ee().remove(w);var s=this.state[a];s.address=o,void 0!==i&&(s.chainId=i),this._activeNamespace=a,this.address=o,this.chainId=i}catch(e){R.warn("Failed to restore persisted wallet snapshot",e),ee().remove(w)}},e.prototype.clearForChain=function(e){null!=e?this.clear(e):(this.clear("evm"),this.clear("solana"))},e.prototype.displaceProvider=function(e,t){e&&e!==t&&this.deps.onProviderDisplaced(e)},e.prototype.syncDerived=function(){var e=this._activeNamespace;if(e){var t=this.state[e];if(t.address||t.chainId){this.address=t.address,this.chainId=t.chainId,this.persist();return}}var r="evm"===e?"solana":"evm",n=this.state[r];if(n.address||n.chainId){this.address=n.address,this.chainId=n.chainId,this._activeNamespace=r,this.persist();return}this.address=void 0,this.chainId=void 0,this.persist()},e}(),tA=function(){return(tA=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},tI="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzIiIGhlaWdodD0iMzIiIHZpZXdCb3g9IjAgMCAzMiAzMiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHJlY3Qgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIiBmaWxsPSIjRkZGIi8+CjxwYXRoIGQ9Ik0xNiA4TDggMjRoMTZMMTYgOHoiIGZpbGw9IiMzMzMiLz4KPC9zdmc+Cg==",tT=[{flag:"isMetaMask",name:"MetaMask",rdns:"io.metamask"},{flag:"isCoinbaseWallet",name:"Coinbase Wallet",rdns:"com.coinbase.wallet"},{flag:"isWalletConnect",name:"WalletConnect",rdns:"com.walletconnect"},{flag:"isTrust",name:"Trust Wallet",rdns:"com.trustwallet"},{flag:"isBraveWallet",name:"Brave Wallet",rdns:"com.brave.wallet"},{flag:"isPhantom",name:"Phantom",rdns:"app.phantom"}];function tS(e){for(var t="Injected Provider",r="io.injected.provider",n=0;n<tT.length;n++){var i=tT[n];if(e[i.flag]){t=i.name,r=i.rdns;break}}return{name:t,rdns:r,uuid:"injected-".concat(r.replace(/[^a-zA-Z0-9]/g,"-")),icon:tI}}function tC(e){for(var t=e,r=0;t&&r<5;r++){var n=t.code;if(4001===n||"number"==typeof n&&n>=5e3&&n<=5005||"UserRejectedRequestError"===t.name)return!0;t=t.cause}return!1}function tO(e){var t,r=e.session,n=null==(t=null==r?void 0:r.peer)?void 0:t.metadata;if(n&&"string"==typeof n.name&&0!==n.name.length)return tA({name:n.name},"string"==typeof n.url&&n.url.length>0?{url:n.url}:{})}function tj(e){return!!e&&"function"==typeof e.request&&"function"==typeof e.on&&"function"==typeof e.removeListener}var tk=Symbol("formoWrappedRequest"),tR=Symbol("formoWrappedRequestRef"),t_=Symbol("formoWrappedRequestOwner"),tB=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},tM=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},tF=function(e,t,r){if(r||2==arguments.length)for(var n,i=0,a=t.length;i<a;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))},tN=function(){function e(e){this.deps=e,this.details=[],this.tracked=new Set,this.seen=new Set,this.chainIds=new WeakMap,this.chainGenerations=new WeakMap,this.listeners=new Map,this.attributions=new WeakMap}return Object.defineProperty(e.prototype,"all",{get:function(){return this.details}
2,enumerable:!1,configurable:!0}),e.prototype.isTracked=function(e){return this.tracked.has(e)},e.prototype.markTracked=function(e){this.tracked.add(e)},e.prototype.forgetTracked=function(e){this.tracked.delete(e)},e.prototype.trackedProviders=function(){return Array.from(this.tracked)},e.prototype.isSeen=function(e){return this.seen.has(e)},Object.defineProperty(e.prototype,"injected",{get:function(){return this.injectedDetail},set:function(e){this.injectedDetail=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"counts",{get:function(){return{totalProviders:this.details.length,trackedProviders:this.tracked.size,seenProviders:this.seen.size}},enumerable:!1,configurable:!0}),e.prototype.add=function(e){var t=null==e?void 0:e.provider;return!(!t||this.details.some(function(e){return e.provider===t}))&&(this.details=tF(tF([],this.details,!0),[e],!1),this.seen.add(t),!0)},e.prototype.rememberAttribution=function(e,t){if(e){if(!t)return void this.attributions.delete(e);this.attributions.set(e,t)}},e.prototype.suppliedAttributionFor=function(e){var t=this.attributions.get(e);if(t)try{var r=t();return(null==r?void 0:r.name)?r:void 0}catch(e){return}},e.prototype.infoFor=function(e){var t,r,n=this.details.find(function(t){return t.provider===e}),i=n?void 0:this.suppliedAttributionFor(e),a=n?{name:n.info.name,rdns:n.info.rdns}:(r=tS(e),i?{name:i.name,rdns:null!=(t=i.rdns)?t:r.rdns}:{name:r.name,rdns:r.rdns});if("WalletConnect"===a.name||"Injected Provider"===a.name){var o=tO(e);if(null==o?void 0:o.name)return{name:o.name,rdns:"io.injected.provider"===a.rdns?"com.walletconnect":a.rdns}}return a},e.prototype.addListener=function(e,t,r){var n=this.listeners.get(e)||{};n[t]=r,this.listeners.set(e,n)},e.prototype.removeListeners=function(e){var t=this.listeners.get(e);if(t){for(var r={},n=0,i=Object.entries(t);n<i.length;n++){var a=i[n],o=a[0],s=a[1];try{e.removeListener(o,s)}catch(e){R.warn("Failed to remove listener for ".concat(String(o)),e),r[o]=s}}Object.keys(r).length>0?this.listeners.set(e,r):this.listeners.delete(e)}},e.prototype.attachedEvents=function(e){var t;return Object.keys(null!=(t=this.listeners.get(e))?t:{})},e.prototype.isWrapped=function(e,t){return!!(t&&"function"==typeof t&&t[tk]&&e[tR]===t)},e.prototype.chainIdOf=function(e){return this.chainIds.get(e)},e.prototype.bumpChainGeneration=function(e){var t,r=(null!=(t=this.chainGenerations.get(e))?t:0)+1;return this.chainGenerations.set(e,r),r},e.prototype.chainGeneration=function(e){var t;return null!=(t=this.chainGenerations.get(e))?t:0},e.prototype.rememberChain=function(e,t){e&&t&&(this.bumpChainGeneration(e),this.chainIds.set(e,t),this.deps.onChainObserved(e,t))},e.prototype.resolveChainId=function(e){if(e){var t=this.chainIds.get(e);if(t)return t;var r=this.deps.activeChainId();return e===this.deps.activeProvider()&&r?r:0}return this.deps.activeChainId()||0},e.prototype.addressOf=function(e){return tB(this,void 0,void 0,function(){var t,r,n,i;return tM(this,function(a){switch(a.label){case 0:if(t=this.deps.activeProvider(),r=e||t,(!e||e===t)&&(n=this.deps.knownEvmAddress()))return[2,n];if(!r)return R.info("The provider is not set"),[2,null];return[4,this.accountsOf(r)];case 1:if((i=a.sent())&&i.length>0)return[2,eS(i[0])||null];return[2,null]}})})},e.prototype.accountsOf=function(e){return tB(this,void 0,void 0,function(){var t,r,n;return tM(this,function(i){switch(i.label){case 0:t=e||this.deps.activeProvider(),i.label=1;case 1:return i.trys.push([1,3,,4]),[4,null==t?void 0:t.request({method:"eth_accounts"})];case 2:if(!(r=i.sent())||0===r.length)return[2,null];return[2,r.map(function(e){return eS(e)}).filter(function(e){return void 0!==e})];case 3:return 4001!==(null==(n=i.sent())?void 0:n.code)&&R.error("EvmProviderRegistry::accountsOf: eth_accounts threw an error",n),[2,null];case 4:return[2]}})})},e}(),tU=e.i(292210);function tH(e){return"string"!=typeof e?0:e.startsWith("0x")||e.startsWith("0X")?parseInt(e,16):parseInt(e,10)}var tz=function(){return(tz=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},tL=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},tD=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},t$=function(e,t,r){if(r||2==arguments.length)for(var n,i=0,a=t.length;i<a;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))};function tq(e){var t,r=e.accounts;if(Array.isArray(r)&&r.length>0&&r.every(function(e){return"string"==typeof e}))return r;var n=e.session,i=null==(t=null==n?void 0:n.namespaces)?void 0:t.eip155,a=e.chainId,o="number"==typeof a?a:"string"==typeof a?tH(a):void 0,s=o?"eip155:".concat(o,":"):void 0,c=[],u=[];
2if(Array.isArray(null==i?void 0:i.accounts))for(var l=0,d=i.accounts;l<d.length;l++){var f=d[l];if("string"==typeof f&&f.startsWith("eip155:")){var p=f.split(":")[2];if(p){var h=s&&f.startsWith(s)?c:u;h.includes(p)||h.push(p)}}}return t$(t$([],c,!0),u.filter(function(e){return!c.includes(e)}),!0)}var tW=function(){function e(e,t,r){this.wallet=e,this.registry=t,this.deps=r,this.externallyRegistered=new Set,this.pendingAdoptions=new Set,this.awaitingNewSession=new Set,this.retryInFlight=!1,this.retryRequested=!1,this._announcedConnect=new WeakMap,this.disposed=!1,this.sessionGenerations=new WeakMap}return e.prototype.dropRefusal=function(e){this.latestRefused===e&&(this.latestRefused=void 0)},e.prototype.markRegisteredAdoptionsPending=function(){var e=this;this.externallyRegistered.forEach(function(t){return e.pendingAdoptions.add(t)})},e.prototype.noteRefusalIfSuppressed=function(e){if(this.deps.isTrackingSuppressed()&&this.externallyRegistered.has(e)){this.pendingAdoptions.add(e);var t=!1;try{t=tq(e).length>0}catch(e){}t&&(this.latestRefused=e)}},e.prototype.settleAdoption=function(e){this.pendingAdoptions.delete(e),this.awaitingNewSession.delete(e),this.dropRefusal(e)},e.prototype.reopenAdoption=function(e){var t;this.externallyRegistered.has(e)&&(this.pendingAdoptions.add(e),this.awaitingNewSession.add(e),this.sessionGenerations.set(e,(null!=(t=this.sessionGenerations.get(e))?t:0)+1),this.dropRefusal(e))},e.prototype.cleanup=function(){var e,t;this.disposed=!0,this.pendingAdoptions.clear(),this.awaitingNewSession.clear(),this.latestRefused=void 0,this.retryRequested=!1;try{null==(e=this.unsubscribeDiscovery)||e.call(this),null==(t=this.discoveryStore)||t.destroy()}catch(e){R.warn("Failed to unsubscribe from provider discovery",e)}this.unsubscribeDiscovery=void 0,this.discoveryStore=void 0},e.prototype.sessionGeneration=function(e){var t;return null!=(t=this.sessionGenerations.get(e))?t:0},e.prototype.forgetAnnouncedConnect=function(e){this._announcedConnect.delete(e)},e.prototype.isProviderMismatch=function(e){return null!=this.wallet.provider&&this.wallet.provider!==e},e.prototype.trackEIP1193Provider=function(e){if(R.info("trackEIP1193Provider",e),this.deps.isWagmiMode())return void R.debug("trackEIP1193Provider: Skipping EIP-1193 provider tracking (Wagmi mode - using connector system instead)");try{if(!tj(e))return void R.warn("trackEIP1193Provider: Invalid provider - missing required methods");if(this.registry.isTracked(e))return void R.warn("trackEIP1193Provider: Provider already tracked");if(this.registerAccountsChangedListener(e),this.registerChainChangedListener(e),this.deps.isAutocaptureEnabled("connect")?this.registerConnectListener(e):this.registerConnectChainObserver(e),this.seedProviderChainFromState(e),!this.deps.registerRequestListeners(e))return void R.warn("TrackProvider: Could not wrap provider; leaving it untracked");this.registerDisconnectListener(e),this.registry.markTracked(e)}catch(e){R.error("Error tracking provider:",e)}},e.prototype.trackProviders=function(e){try{for(var t=0;t<e.length;t++){var r=e[t],n=null==r?void 0:r.provider;n&&!this.registry.isTracked(n)&&this.trackEIP1193Provider(n)}}catch(e){R.error("Failed to track EIP-6963 providers during initialization:",e)}},e.prototype.adoptExternalProvider=function(e){var t=e.provider;if(this.externallyRegistered.add(t),this.registry.add(e),this.trackProviders([e]),!this.registry.isTracked(t))return this.externallyRegistered.delete(t),this.untrackProvider(t),R.warn("adoptExternalProvider: provider could not be tracked"),!1;if(!this.deps.registerRequestListeners(t))return this.externallyRegistered.delete(t),this.untrackProvider(t),R.warn("adoptExternalProvider: request wrapper could not be ensured"),!1;this.detectWallets([tz(tz({},e),{info:tz(tz({},e.info),this.registry.infoFor(t))})]),this.pendingAdoptions.add(t);var r=tq(t);return r.length>0&&this.onAccountsChanged(t,r),!0},e.prototype.retryExternalAdoptions=function(){var e=this;if(this.externallyRegistered.forEach(function(t){var r=e.registry.infoFor(t);"com.walletconnect"===r.rdns&&e.detectWallets([{info:{name:r.name,rdns:r.rdns,uuid:"corrected-com-walletconnect",icon:tI},provider:t}])}),!(this.disposed||0===this.pendingAdoptions.size||this.deps.isTrackingSuppressed())){if(this.retryInFlight){this.retryRequested=!0;return}this.retryInFlight=!0,tL(e,void 0,void 0,function(){var e,t,r,n,i,a=this;return tD(this,function(o){switch(o.label){case 0:o.trys.push([0,,9,10]),o.label=1;case 1:this.retryRequested=!1,e=Array.from(new Set(t$(t$([],[this.wallet.provider,this.latestRefused].filter(function(e){return!!e&&a.pendingAdoptions.has(e)}),!0),Array.from(this.pendingAdoptions),!0))),t=0,r=e,o.label=2;case 2:if(!(t<r.length)||(n=r[t],this.disposed||this.deps.isTrackingSuppressed()))return[3,7];i=void 0;try{i=tq(n)}catch(e){return[3,6]}if(0===i.length||this.awaitingNewSession.has(n)||void 0!==this.wallet.provider&&this.wallet.provider!==n&&this.latestRefused!==n)return[3,6];o.label=3;case 3:return o.trys.push([3,5,,6]),[4,this.onAccountsChanged(n,i)];case 4:case 5:return o.sent(),[3,6];case 6:return t++,[3,2];case 7:if(this.retryRequested&&!this.disposed&&!this.deps.isTrackingSuppressed())return[3,1];o.label=8;case 8:return[3,10];case 9:return this.retryInFlight=!1,this.retryRequested=!1,[7];case 10:return[2]}})})}},e.prototype.registerAccountsChangedListener=function(e){var t=this;R.info("registerAccountsChangedListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.onAccountsChanged(e,r[0])};e.on("accountsChanged",r),this.registry.addListener(e,"accountsChanged",r)},e.prototype.onAccountsChanged=function(e,t){return tL(this,void 0,void 0,function(){var r;return tD(this,function(n){switch(n.label){case 0:if(this.disposed)return[2];return R.info("onAccountsChanged",t),r=t.length>0||this.wallet.provider===e?this.wallet.observe("evm"):this.wallet.currentObservation("evm"),[4,this._handleAccountsChanged(e,t,r)];case 1:return n.sent(),[2]}})})},e.prototype._handleAccountsChanged=function(e,t,r){return tL(this,void 0,void 0,function(){var n,i,a,o,s,c,u,l,d,f,p;return tD(this,function(h){switch(h.label){case 0:if(0!==t.length)return[3,9];if(this.reopenAdoption(e),this.wallet.provider!==e)return[3,7];if(R.info("OnAccountsChanged: Detecting disconnect, current state:",{evmAddress:this.wallet.evmAddress,evmChainId:this.wallet.evmChainId,providerMatch:this.wallet.provider===e}),this._announcedConnect.delete(e),!this.deps.isAutocaptureEnabled("disconnect"))return[3,5];h.label=1;case 1:return h.trys.push([1,3,,4]),[4,this.deps.disconnect({chainId:this.wallet.evmChainId,address:this.wallet.evmAddress})];case 2:if(h.sent(),this.disposed)return[2];return[3,4];case 3:return n=h.sent(),R.error("Failed to disconnect provider on accountsChanged",n),[3,4];case 4:return[3,6];case 5:R.debug("OnAccountsChanged: Disconnect event skipped (autocapture.disconnect: false)"),this.wallet.beginDisconnect("evm"),this.wallet.clear("evm"),h.label=6;case 6:return[3,8];case 7:R.info("OnAccountsChanged: Ignoring disconnect for non-active provider"),h.label=8;case 8:return[2];case 9:if(!(i=eS(t[0])))return R.warn("onAccountsChanged: Invalid address received",t[0]),[2];if(this.awaitingNewSession.delete(e),this.noteRefusalIfSuppressed(e),a=this.sessionGeneration(e),!(this.wallet.provider&&this.wallet.provider!==e))return[3,26];o=this.wallet.evmAddress,s=eS(i),R.info("OnAccountsChanged: Different provider attempting to connect",{activeProvider:this.registry.infoFor(this.wallet.provider).name,eventProvider:this.registry.infoFor(e).name,currentStoredAddress:o,newProviderAddress:s}),h.label=10;case 10:return h.trys.push([10,22,,26]),[4,this.registry.accountsOf(this.wallet.provider)];case 11:if(c=h.sent(),this.disposed)return[2];if(this.sessionGeneration(e)!==a||!this.wallet.isCurrent(r))return this.dropRefusal(e),[2];if(R.info("OnAccountsChanged: Checking current provider accounts",{activeProvider:this.registry.infoFor(this.wallet.provider).name,accountsLength:c?c.length:0,accounts:c}),!(c&&c.length>0))return[3,17];if(!(s&&o&&s!==o))return[3,15];if(R.info("OnAccountsChanged: Different address detected, switching providers despite current provider having accounts",{activeProvider:this.registry.infoFor(this.wallet.provider).name,eventProvider:this.registry.infoFor(e).name,currentAddress:o,newAddress:s,reason:"Address mismatch indicates wallet switch"}),!this.deps.isAutocaptureEnabled("disconnect"))return[3,13];return[4,this.deps.disconnect({chainId:this.wallet.evmChainId,address:this.wallet.evmAddress})];case 12:if(h.sent(),this.disposed)return[2];return[3,14];case 13:R.debug("OnAccountsChanged: Disconnect event skipped during provider switch (autocapture.disconnect: false)"),this.wallet.clear("evm"),h.label=14;case 14:if(!this.wallet.isCurrent(r))return this.dropRefusal(e),[2];return this.wallet.clearProvider(),[3,16];case 15:return this.deps.isTrackingSuppressed()||this.dropRefusal(e),R.info("OnAccountsChanged: Current provider still has accounts and same address, ignoring new provider",{activeProvider:this.registry.infoFor(this.wallet.provider).name,eventProvider:this.registry.infoFor(e).name,activeProviderAccountsCount:c.length,currentAddress:o,newAddress:s}),[2];case 16:return[3,21];case 17:if(R.info("OnAccountsChanged: Current provider has no accounts, switching to new provider",{oldProvider:this.registry.infoFor(this.wallet.provider).name,newProvider:this.registry.infoFor(e).name,reason:"Current provider has no accounts"}),!this.deps.isAutocaptureEnabled("disconnect"))return[3,19];return[4,this.deps.disconnect({chainId:this.wallet.evmChainId,address:this.wallet.evmAddress})];case 18:if(h.sent(),this.disposed)return[2];return[3,20];case 19:R.debug("OnAccountsChanged: Disconnect event skipped for old provider (autocapture.disconnect: false)"),this.wallet.clear("evm"),h.label=20;case 20:if(!this.wallet.isCurrent(r))return this.dropRefusal(e),[2];h.label=21;case 21:return[3,26];case 22:if(u=h.sent(),R.warn("OnAccountsChanged: Could not check current provider accounts, switching to new provider",{error:u instanceof Error?u.message:String(u),errorType:u instanceof Error?u.constructor.name:typeof u,oldProvider:this.wallet.provider?this.registry.infoFor(this.wallet.provider).name:"unknown",newProvider:this.registry.infoFor(e).name,reason:"Could not check current provider accounts"}),!this.deps.isAutocaptureEnabled("disconnect"))return[3,24];return[4,this.deps.disconnect({chainId:this.wallet.evmChainId,address:this.wallet.evmAddress})];case 23:if(h.sent(),this.disposed)return[2];return[3,25];case 24:R.debug("OnAccountsChanged: Disconnect event skipped for failed provider check (autocapture.disconnect: false)"),this.wallet.clear("evm"),h.label=25;case 25:if(!this.wallet.isCurrent(r))return this.dropRefusal(e),[2];return[3,26];case 26:if(this.wallet.provider||(this.wallet.provider=e),this.wallet.provider===e&&i===this.wallet.evmAddress)return this.settleAdoption(e),[2];return l=this.registry.resolveChainId(e),d=!this.wallet.evmAddress,this.deps.isTrackingSuppressed()?(this.wallet.clearStaleEvmWalletOnSwitchWhileSuppressed(i),this.noteRefusalIfSuppressed(e)):(this.wallet.set("evm",{address:i,chainId:l}),this.settleAdoption(e)),f=this.registry.infoFor(e),p=l||0,this.deps.isAutocaptureEnabled("connect")&&this.shouldReportConnect(e,i)?(R.info("OnAccountsChanged: Detected wallet connection, emitting connect event",{chainId:l,address:i,wasDisconnected:d,providerName:f.name,rdns:f.rdns,hasChainId:!!l}),0===p&&R.info("OnAccountsChanged: Using fallback chainId 0 for connect event"),this.markConnectReported(e,i,p),this.deps.connect({chainId:p,address:i},{providerName:f.name,rdns:f.rdns}).catch(function(e){R.error("Failed to track connect event during account change:",e)})):R.debug("OnAccountsChanged: Connect event skipped (autocapture.connect: false)",{chainId:l,address:i,providerName:f.name}),[2]}})})},e.prototype.registerChainChangedListener=function(e){var t=this;R.info("registerChainChangedListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return t.onChainChanged(e,r[0])};e.on("chainChanged",r),this.registry.addListener(e,"chainChanged",r)},e.prototype.onChainChanged=function(e,t){return tL(this,void 0,void 0,function(){var r,n;return tD(this,function(i){switch(i.label){case 0:if(this.disposed||(R.info("onChainChanged",t),r=tH(t),this.registry.rememberChain(e,r),!this.deps.isAutocaptureEnabled("chain")&&e!==this.wallet.provider))return[2];if(this.isProviderMismatch(e)){if("solana"===this.wallet.activeNamespace)return[2];this.handleProviderMismatch(e)}if(!this.wallet.evmAddress)return R.info("OnChainChanged: No current address, user appears disconnected"),[2,Promise.resolve()];this.wallet.provider||(this.wallet.provider=e),this.wallet.set("evm",{chainId:r}),this.deps.retryDetection(),i.label=1;case 1:if(i.trys.push([1,5,,6]),!this.deps.isAutocaptureEnabled("chain"))return[3,3];return[4,this.deps.chain({chainId:r,address:this.wallet.evmAddress})];case 2:return i.sent(),[3,4];case 3:R.debug("OnChainChanged: Chain event skipped (autocapture.chain: false)",{chainId:this.wallet.evmChainId,address:this.wallet.evmAddress}),i.label=4;case 4:return[3,6];case 5:return n=i.sent(),R.error("OnChainChanged: Failed to emit chain event:",n),[3,6];case 6:return[2]}})})},e.prototype.registerConnectChainObserver=function(e){var t=this,r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var i=r[0];t.disposed||"string"==typeof(null==i?void 0:i.chainId)&&(t.registry.rememberChain(e,tH(i.chainId)),t.awaitingNewSession.delete(e),t.noteRefusalIfSuppressed(e))};e.on("connect",r),this.registry.addListener(e,"connect",r)},e.prototype.shouldReportConnect=function(e,t){var r=this._announcedConnect.get(e);return!r||r.address.toLowerCase()!==t.toLowerCase()},e.prototype.markConnectReported=function(e,t,r){this.deps.willTrackEvent(r)&&this._announcedConnect.set(e,{address:t,chainId:r})},e.prototype.registerConnectListener=function(e){var t=this;R.info("registerConnectListener");var r=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var i=r[0];t.onConnected(e,i)};e.on("connect",r),this.registry.addListener(e,"connect",r)},e.prototype.registerDisconnectListener=function(e){var t=this;R.info("registerDisconnectListener");var r=function(r){return tL(t,void 0,void 0,function(){var t;return tD(this,function(r){switch(r.label){case 0:if(this.disposed||(this.reopenAdoption(e),this.wallet.provider!==e))return[2];if(this._announcedConnect.delete(e),R.info("OnDisconnect: Wallet disconnect event received, current state:",{currentAddress:this.wallet.evmAddress,currentChainId:this.wallet.evmChainId}),!this.deps.isAutocaptureEnabled("disconnect"))return[3,5];r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.deps.disconnect({chainId:this.wallet.evmChainId,address:this.wallet.evmAddress})];case 2:if(r.sent(),this.disposed)return[2];return[3,4];case 3:return t=r.sent(),R.error("Error during disconnect in disconnect listener",t),[3,4];case 4:return[3,6];case 5:R.debug("OnDisconnect: Disconnect event skipped (autocapture.disconnect: false)"),this.wallet.beginDisconnect("evm"),this.wallet.clear("evm"),r.label=6;case 6:return[2]}})})};e.on("disconnect",r),this.registry.addListener(e,"disconnect",r)},e.prototype.onConnected=function(e,t){return tL(this,void 0,void 0,function(){var r,n,i,a,o,s,c,u,l,d,f,p;return tD(this,function(h){switch(h.label){case 0:if(this.disposed)return[2];R.info("onConnected",t),this.awaitingNewSession.delete(e),this.noteRefusalIfSuppressed(e),r=this.wallet.disconnectsSoFar("evm"),n=this.wallet.currentObservation("evm"),h.label=1;case 1:if(h.trys.push([1,3,,4]),!(null==t?void 0:t.chainId)||"string"!=typeof t.chainId)return[2];return i=tH(t.chainId),this.registry.rememberChain(e,i),a=this.sessionGeneration(e),[4,this.registry.addressOf(e)];case 2:if(o=h.sent(),this.disposed)return[2];if(this.sessionGeneration(e)!==a)return this.dropRefusal(e),[2];if(this.wallet.disconnectsSoFar("evm")!==r)return R.info("onConnected: The wallet disconnected after this observation began; dropping it"),this.dropRefusal(e),[2];if(c=!!(s=this.wallet.evmAddress)&&!!o&&s.toLowerCase()!==o.toLowerCase(),e===this.wallet.provider&&!this.wallet.isCurrent(n)&&c)return R.info("onConnected: A newer signal from this provider has overtaken this connect 
2observation; dropping it"),this.dropRefusal(e),[2];return i&&o&&(u=!this.wallet.evmAddress,this.noteRefusalIfSuppressed(e),this.wallet.provider||(this.wallet.provider=e),(l=this.wallet.provider===e)&&(this.deps.isTrackingSuppressed()?(this.wallet.clearStaleEvmWalletOnSwitchWhileSuppressed(o),this.noteRefusalIfSuppressed(e)):(this.wallet.set("evm",{chainId:i,address:eS(o)||void 0}),this.settleAdoption(e))),l&&this.wallet.evmAddress&&this.shouldReportConnect(e,o)?(d=this.registry.infoFor(e),f=i||0,this.deps.isAutocaptureEnabled("connect")?(R.info("OnConnected: Detected wallet connection, emitting connect event",{chainId:i,wasDisconnected:u,providerName:d.name,rdns:d.rdns,hasChainId:!!i,isActiveProvider:l}),0===f&&R.info("OnConnected: Using fallback chainId 0 for connect event"),this.markConnectReported(e,o,f),this.deps.connect({chainId:f,address:o},{providerName:d.name,rdns:d.rdns}).catch(function(e){R.error("Failed to track connect event during provider connection:",e)})):R.debug("OnConnected: Connect event skipped (autocapture.connect: false)",{chainId:i,address:o,providerName:d.name})):o&&!l&&(d=this.registry.infoFor(e),R.debug("OnConnected: Skipping connect event for non-active provider",{chainId:i,providerName:d.name,rdns:d.rdns,isActiveProvider:l,activeProviderInfo:this.wallet.provider?this.registry.infoFor(this.wallet.provider):null}))),[3,4];case 3:return p=h.sent(),R.error("Error handling connect event",p),[3,4];case 4:return[2]}})})},e.prototype.tracksDiscovered=function(){return!this.deps.isWagmiMode()},e.prototype.getProviders=function(){return tL(this,void 0,void 0,function(){var e,t,r,n,i,a,o,s,c,u=this;return tD(this,function(l){if(e=(0,tU.createStore)(),this.discoveryStore=e,t=e.getProviders(),this.unsubscribeDiscovery=e.subscribe(function(e){t=e;for(var r=e.filter(function(e){var t=null==e?void 0:e.provider;return t&&!u.registry.isSeen(t)}),n=0;n<r.length;n++){var i=r[n];u.registry.add(i)}var a=e.filter(function(e){var t=null==e?void 0:e.provider;return!!t&&!u.registry.isTracked(t)}),o=u.tracksDiscovered()?a:r;u.tracksDiscovered()&&a.length>0&&u.trackProviders(a),o.length>0&&tL(u,void 0,void 0,function(){var e;return tD(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,this.detectWallets(o)];case 1:return t.sent(),[3,3];case 2:return e=t.sent(),R.error("Formo: Failed to detect wallets",e),[3,3];case 3:return[2]}})}),u.cleanupUnavailableProviders(e)}),0===t.length){if(r=window.ethereum){if(this.registry.injected&&this.registry.injected.provider===r)return this.tracksDiscovered()&&!this.registry.isTracked(r)&&this.trackEIP1193Provider(r),this.registry.add(this.registry.injected),[2,this.registry.all];this.tracksDiscovered()&&!this.registry.isTracked(r)&&this.trackEIP1193Provider(r),n=tS(r),i={provider:r,info:n},this.registry.injected=i,this.registry.add(i)}return[2,this.registry.all]}for(a=t.filter(function(e){var t=null==e?void 0:e.provider;return t&&!u.registry.isSeen(t)}),o=0,s=a;o<s.length;o++)c=s[o],this.registry.add(c);return[2,this.registry.all]})})},e.prototype.detectWallets=function(e){return tL(this,void 0,void 0,function(){var t,r,n,i;return tD(this,function(a){switch(a.label){case 0:a.trys.push([0,5,,6]),t=0,r=e,a.label=1;case 1:if(!(t<r.length))return[3,4];return n=r[t],[4,this.deps.detect({providerName:null==n?void 0:n.info.name,rdns:null==n?void 0:n.info.rdns})];case 2:a.sent(),a.label=3;case 3:return t++,[3,1];case 4:return[3,6];case 5:return i=a.sent(),R.error("Error detect all wallets:",i),[3,6];case 6:return[2]}})})},e.prototype.detectableProviders=function(){var e,t=new Set;null==(e=this.discoveryStore)||e.getProviders().forEach(function(e){return t.add(e.provider)});var r=window.ethereum;return r&&t.add(r),this.externallyRegistered.forEach(function(e){return t.add(e)}),this.registry.all.filter(function(e){return t.has(e.provider)})},e.prototype.seedProviderChainFromState=function(e){var t=e.chainId,r="string"==typeof t?tH(t):"number"==typeof t?t:void 0;this.registry.rememberChain(e,r)},e.prototype.untrackProvider=function(e){this.settleAdoption(e);try{this.registry.removeListeners(e),0===this.registry.attachedEvents(e).length&&this.registry.forgetTracked(e),this.wallet.provider===e&&this.wallet.clearProvider()}catch(e){R.warn("Failed to untrack provider",e)}},e.prototype.cleanupUnavailableProviders=function(e){for(var t=new Set(e.map(function(e){return e.provider}
2)),r=0,n=this.registry.trackedProviders();r<n.length;r++){var i=n[r];!this.externallyRegistered.has(i)&&(t.has(i)||(R.info("Cleaning up unavailable provider: ".concat(i.constructor.name)),this.untrackProvider(i)))}},e.prototype.handleProviderMismatch=function(e){this.wallet.provider?this.wallet.set("evm",{address:void 0,chainId:void 0,provider:e}):this.wallet.provider=e},e}();function tG(e){if("string"==typeof e&&e.length>0)return e;if(e&&"object"==typeof e){var t=e.id;if("string"==typeof t&&t.length>0)return t}}function tK(e){return"number"==typeof(null==e?void 0:e.statusCode)?e.statusCode:"number"==typeof(null==e?void 0:e.status)?e.status:void 0}function tV(e,t){var r=null==t?void 0:t.status;return void 0!==r?"0x0"===r||0===r||"reverted"===r?s.REVERTED:s.CONFIRMED:e>=600?void 0:e>=500?s.REVERTED:e>=400?s.REJECTED:s.CONFIRMED}function tJ(e,t,r){var n,i=Array.isArray(null==e?void 0:e.receipts)?e.receipts:[],a=null!=(n=tK(e))?n:0;return(null==e?void 0:e.atomic)===!0||(null==e?void 0:e.atomic)===void 0&&1===i.length&&r>1&&a<600?i[0]:i[t]}
2(h=o||(o={})).REQUESTED="requested",h.REJECTED="rejected",h.CONFIRMED="confirmed",(m=s||(s={})).STARTED="started",m.REJECTED="rejected",m.BROADCASTED="broadcasted",m.CONFIRMED="confirmed",m.REVERTED="reverted";var tZ=function(){return(tZ=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},tQ=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},tY=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},tX=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)0>t.indexOf(n[i])&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r},t0=function(e,t,r){if(r||2==arguments.length)for(var n,i=0,a=t.length;i<a;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))},t1=new WeakSet,t6=function(){function e(t,r,n){this.wallet=t,this.registry=r,this.deps=n,this.polls=new Set,this.disposed=!1,this.wrappedProviders=new Set,this.creationSeq=e.nextCreationSeq++}return e.prototype.cleanup=function(){var e=this;this.disposed=!0,this.polls.forEach(function(e){return clearTimeout(e)}),this.polls.clear(),this.wrappedProviders.forEach(function(t){var r=t[t_];if(Array.isArray(r)){var n=r.indexOf(e);-1!==n&&r.splice(n,1)}}),this.wrappedProviders.clear()},e.prototype.schedulePoll=function(e,t){var r=this;if(!this.disposed){var n=setTimeout(function(){r.polls.delete(n),e()},t);this.polls.add(n)}},e.prototype.insertBySeniority=function(e){var t=this,r=e.indexOf(this);-1!==r&&e.splice(r,1);var n=e.findIndex(function(e){return e.creationSeq>t.creationSeq});-1===n?e.push(this):e.splice(n,0,this)},e.prototype.registerRequestListeners=function(e){var t=this;if(R.info("registerRequestListeners"),!e)return R.error("Provider not found for request (signature, transaction) tracking"),!1;var r=e.request;if(this.registry.isWrapped(e,r)){var n=e[t_];return Array.isArray(n)?(this.insertBySeniority(n),this.wrappedProviders.add(e),R.info("Provider already wrapped; rebinding the wrapper to this instance."),!0):(R.warn("wrapped without owner list; cannot rebind"),!1)}var i=e.request.bind(e);try{var a=e[t_],n=Array.isArray(a)?a:[];this.insertBySeniority(n),Array.isArray(a)||(e[t_]=n),this.wrappedProviders.add(e)}catch(e){}return this.installWrappedRequest(e,function(r){return tQ(t,[r],void 0,function(t){var r,n,a=t.method,o=t.params;return tY(this,function(t){if(r=e[t_],t1.has(e))return[2,i({method:a,params:o})];n=Array.isArray(r)?t0([],r,!0).reverse().find(function(e){return!e.disposed}):void 0,t1.add(e);try{return[2,(null!=n?n:this).dispatchWrappedRequest({method:a,params:o},e,i)]}finally{t1.delete(e)}})})})},e.prototype.installWrappedRequest=function(e,t){t[tk]=!0;try{if(e[tR]=t,e.request=t,e.request!==t)return R.warn("request assignment swallowed; not wrapped"),!1;return!0}catch(e){return R.warn("Failed to wrap provider.request; skipping",e),!1}},e.prototype.dispatchWrappedRequest=function(e,t,r){return tQ(this,arguments,void 0,function(e,t,r){var n,i,a,c,u,l,d,f,p,h,m,b,y,g,v,w=this,E=e.method,P=e.params;return tY(this,function(e){switch(e.label){case 0:if("eth_chainId"===E)return n=this.registry.chainGeneration(t),[2,r({method:E,params:P}).then(function(e){return n===w.registry.chainGeneration(t)&&"string"==typeof e&&w.registry.rememberChain(t,tH(e)),e})];if(!(Array.isArray(P)&&["eth_signTypedData_v4","personal_sign"].includes(E)))return[3,4];if(!this.deps.isAutocaptureEnabled("signature"))return R.debug("Signature event skipped (autocapture.signature: false)",{method:E}
2),[2,r({method:E,params:P})];if(null==(y=(b=this.deps).shouldSkipRequestCapture)?void 0:y.call(b,E,P))return[2,r({method:E,params:P})];(i=r({method:E,params:P})).catch(function(){}),a=this.registry.resolveChainId(t),c=this.attributionFor(t),tQ(w,void 0,void 0,function(){var e;return tY(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,this.deps.signature(tZ({status:o.REQUESTED},this.buildSignatureEventPayload(E,P,void 0,a,t)),c)];case 1:return r.sent(),[3,3];case 2:return e=r.sent(),R.error("Formo: Failed to track signature request",e),[3,3];case 3:return[2]}})}),e.label=1;case 1:return e.trys.push([1,3,,4]),[4,i];case 2:return(u=e.sent())&&tQ(w,void 0,void 0,function(){var e;return tY(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,this.deps.signature(tZ({status:o.CONFIRMED},this.buildSignatureEventPayload(E,P,u,a,t)),c)];case 1:return r.sent(),[3,3];case 2:return e=r.sent(),R.error("Formo: Failed to track signature confirmation",e),[3,3];case 3:return[2]}})}),[2,u];case 3:throw tC(l=e.sent())&&tQ(w,void 0,void 0,function(){var e;return tY(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,this.deps.signature(tZ({status:o.REJECTED},this.buildSignatureEventPayload(E,P,void 0,a,t)),c)];case 1:return r.sent(),[3,3];case 2:return e=r.sent(),R.error("Formo: Failed to track signature rejection",e),[3,3];case 3:return[2]}})}),l;case 4:if("wallet_sendCalls"===E&&Array.isArray(P)&&P[0])return[2,this.trackBatchedCalls(t,r,P)];if(!(Array.isArray(P)&&"eth_sendTransaction"===E&&P[0]))return[3,8];if(!this.deps.isAutocaptureEnabled("transaction"))return R.debug("Transaction event skipped (autocapture.transaction: false)",{method:E}),[2,r({method:E,params:P})];if(null==(v=(g=this.deps).shouldSkipRequestCapture)?void 0:v.call(g,E,P))return[2,r({method:E,params:P})];(d=r({method:E,params:P})).catch(function(){}),f=this.registry.resolveChainId(t),p=this.attributionFor(t),tQ(w,void 0,void 0,function(){var e,r;return tY(this,function(n){switch(n.label){case 0:return n.trys.push([0,3,,4]),[4,this.buildTransactionEventPayload(P,t,f)];case 1:return e=n.sent(),[4,this.deps.transaction(tZ({status:s.STARTED},e),p)];case 2:return n.sent(),[3,4];case 3:return r=n.sent(),R.error("Formo: Failed to track transaction start",r),[3,4];case 4:return[2]}})}),e.label=5;case 5:return e.trys.push([5,7,,8]),[4,d];case 6:return h=e.sent(),tQ(w,void 0,void 0,function(){var e,r;return tY(this,function(n){switch(n.label){case 0:return n.trys.push([0,3,,4]),[4,this.buildTransactionEventPayload(P,t,f)];case 1:return e=n.sent(),[4,this.deps.transaction(tZ(tZ({status:s.BROADCASTED},e),{transactionHash:h}),p)];case 2:return n.sent(),this.pollTransactionReceipt(t,h,e,p),[3,4];case 3:return r=n.sent(),R.error("Formo: Failed to track transaction broadcast",r),[3,4];case 4:return[2]}})}),[2,h];case 7:throw tC(m=e.sent())&&tQ(w,void 0,void 0,function(){var e,r;return tY(this,function(n){switch(n.label){case 0:return n.trys.push([0,3,,4]),[4,this.buildTransactionEventPayload(P,t,f)];case 1:return e=n.sent(),[4,this.deps.transaction(tZ({status:s.REJECTED},e),p)];case 2:return n.sent(),[3,4];case 3:return r=n.sent(),R.error("Formo: Failed to track transaction rejection",r),[3,4];case 4:return[2]}})}),m;case 8:return[2,r({method:E,params:P})]}})})},e.prototype.attributionFor=function(e){var t=this.registry.infoFor(e);return{providerName:t.name,rdns:t.rdns}},e.prototype.buildSignatureEventPayload=function(e,t,r,n,i){var a,o="personal_sign"===e?t[1]:t[0],s=eS(o);if(!s)throw Error("Invalid address in signature payload: ".concat(o));var c=null!=(a=null!=n?n:this.wallet.evmChainId)?a:void 0;i&&i!==this.wallet.provider&&this.wallet.provider||this.wallet.backfill(s,c,i);var u={chainId:c,address:s};return"personal_sign"===e?tZ(tZ({},u),{message:function(e){var t="string"==typeof e&&e.startsWith("0x")?e.slice(2):e;if("string"!=typeof t||0===t.length)return"";for(var r=Math.floor(t.length/2),n=new Uint8Array(r),i=0;i<r;i++){var a=Number.parseInt(t.substring(2*i,2*i+2),16);if(Number.isNaN(a))return new TextDecoder().decode(n.subarray(0,i));n[i]=a}return new TextDecoder().decode(n)}(t[0])}):tZ(tZ({},u),{message:t[1]})},e.prototype.buildTransactionEventPayload=function(e,t,r){return tQ(this,void 0,void 0,function(){var n,i,a,o,s,c,u;return tY(this,function(l){if(i=(n=e[0]).data,a=n.from,o=n.to,s=n.value,!(c=eS(a)))throw Error("Invalid address in transaction payload: ".concat(a));return u=null!=r?r:this.registry.resolveChainId(t),t&&t!==this.wallet.provider&&this.wallet.provider||this.wallet.backfill(c,u,t),[2,{chainId:u,data:i,address:c,to:o,value:s}]})})},e.prototype.pollTransactionReceipt=function(e,t,r,n){return tQ(this,arguments,void 0,function(e,t,r,n,i,a){var o,c,u=this;return void 0===i&&(i=10),void 0===a&&(a=3e3),tY(this,function(l){return o=0,e&&(c=function(){return tQ(u,void 0,void 0,function(){var u,l;return tY(this,function(d){switch(d.label){case 0:if(this.disposed)return[2];d.label=1;case 1:return d.trys.push([1,3,,4]),[4,e.request({method:"eth_getTransactionReceipt",params:[t]})];case 2:if(u=d.sent()){if("0x1"===u.status||1===u.status)return this.deps.transaction(tZ(tZ({status:s.CONFIRMED},r),{transactionHash:t}),n).catch(function(e){return R.error("Formo: Failed to track transaction confirmation",e)}),[2];else if("0x0"===u.status||0===u.status)return this.deps.transaction(tZ(tZ({status:s.REVERTED},r),{transactionHash:t}),n).catch(function(e){return R.error("Formo: Failed to track transaction revert",e)}),[2]}return[3,4];case 3:return l=d.sent(),R.error("Error polling transaction receipt",l),[3,4];case 4:return++o<i&&this.schedulePoll(c,a),[2]}})})})(),[2]})})},e.prototype.trackBatchedCalls=function(e,t,r){return tQ(this,void 0,void 0,function(){var n,i,a,o,c,u,l,d,f,p,h,m,b,y,g,v,w,E,P,x,A,I;return tY(this,function(T){switch(T.label){case 0:if(!this.deps.isAutocaptureEnabled("transaction"))return R.debug("Transaction event skipped (autocapture.transaction: false)",{method:"wallet_sendCalls"}),[2,t({method:"wallet_sendCalls",params:r})];if(null==(A=(x=this.deps).shouldSkipRequestCapture)?void 0:A.call(x,"wallet_sendCalls",r))return[2,t({method:"wallet_sendCalls",params:r})];if((n=t({method:"wallet_sendCalls",params:r})).catch(function(){}),a=Array.isArray(null==(i=r[0])?void 0:i.calls)?i.calls:[],o=("string"==typeof(null==i?void 0:i.chainId)?tH(i.chainId):void 0)||this.registry.resolveChainId(e),
2!(c=eS(null!=(I=null==i?void 0:i.from)?I:"")))return R.warn("Formo: wallet_sendCalls has no valid `from`; not tracking",{from:null==i?void 0:i.from}),[2,n];if(0===a.length)return R.debug("Formo: wallet_sendCalls carried no calls"),[2,n];for(e&&e!==this.wallet.provider&&this.wallet.provider||this.wallet.backfill(c,o,e),u=this.attributionFor(e),l=a.map(function(e,t){return{chainId:o,address:c,to:null==e?void 0:e.to,value:null==e?void 0:e.value,data:null==e?void 0:e.data,properties:tZ({batch_size:a.length,batch_index:t},u)}}),d=0,f=l;d<f.length;d++)h=(p=f[d]).properties,m=tX(p,["properties"]),this.deps.transaction(tZ({status:s.STARTED},m),h).catch(function(e){return R.error("Formo: Failed to track batch call start",e)});T.label=1;case 1:return T.trys.push([1,3,,4]),[4,n];case 2:for(y=tG(b=T.sent()),g=0,v=l;g<v.length;g++)h=(p=v[g]).properties,m=tX(p,["properties"]),this.deps.transaction(tZ({status:s.BROADCASTED},m),tZ(tZ({},h),y?{batch_id:y}:{})).catch(function(e){return R.error("Formo: Failed to track batch call broadcast",e)});return y&&this.pollBatchStatus(e,y,l),[2,b];case 3:if(tC(w=T.sent()))for(E=0,P=l;E<P.length;E++)h=(p=P[E]).properties,m=tX(p,["properties"]),this.deps.transaction(tZ({status:s.REJECTED},m),h).catch(function(e){return R.error("Formo: Failed to track batch call rejection",e)});throw w;case 4:return[2]}})})},e.prototype.pollBatchStatus=function(e,t,r){return tQ(this,arguments,void 0,function(e,t,r,n,i){var a,o,s=this;return void 0===n&&(n=10),void 0===i&&(i=3e3),tY(this,function(c){return e&&(a=0,(o=function(){return tQ(s,void 0,void 0,function(){var s,c,u,l=this;return tY(this,function(d){switch(d.label){case 0:if(this.disposed)return[2];d.label=1;case 1:return d.trys.push([1,3,,4]),[4,e.request({method:"wallet_getCallsStatus",params:[t]})];case 2:if(void 0!==(c=tK(s=d.sent()))&&c>=200)return r.forEach(function(e,n){var i=tJ(s,n,r.length),a=tV(c,i);if(void 0!==a){var o=e.properties,u=tX(e,["properties"]);l.deps.transaction(tZ(tZ({status:a},u),(null==i?void 0:i.transactionHash)?{transactionHash:i.transactionHash}:{}),tZ(tZ({},o),{batch_id:t})).catch(function(e){return R.error("Formo: Failed to track batch call outcome",e)})}}),[2];return[3,4];case 3:return u=d.sent(),R.error("Error polling batch call status",u),[3,4];case 4:return++a<n&&this.schedulePoll(o,i),[2]}})})})()),[2]})})},e.nextCreationSeq=0,e}();function t5(){if(void 0!==c)return c;try{var t=e.r(996607);if(null==t?void 0:t.encodeFunctionData)return c={encodeFunctionData:t.encodeFunctionData,concatHex:t.concatHex}}catch(e){}return c=null,null}var t2=function(){return(t2=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},t8=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},t3=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},t4=new Set(["status","chainId","address","data","to","value","transactionHash","function_name","function_args","providerName","rdns"]),t9=new Set,t7=new WeakMap,re=function(e,t){return"".concat(e,":").concat(t.toLowerCase())},rt=new Map,rr=new Map,rn=new Map,ri=new WeakMap,ra=0,ro=function(e,t){var r=ri.get(t);return r||(r="cfg".concat(ra+=1),ri.set(t,r)),"".concat(e,":").concat(r)},rs=new WeakMap,rc=new WeakSet,ru=new WeakMap,rl=new Map,rd=new Map,rf=new Map;function rp(e,t){var r;return t&&(null==(r=t7.get(t))?void 0:r.has(e))?"exact":t9.has(e)?"recent":"none"}function rh(e,t){var r;t9.delete(e),t&&(null==(r=t7.get(t))||r.delete(e))}function rm(e,t){var r;if(t){var n=null!=(r=t7.get(t))?r:new Set;n.add(e),t7.set(t,n)}t9.add(e)}function rb(e){if("number"==typeof e)return Number.isFinite(e)?e:void 0;if("bigint"==typeof e)return Number(e);if("string"==typeof e&&""!==e.trim()){var t=(e.startsWith("0x"),Number(e));return Number.isFinite(t)?t:void 0}}function ry(e){if("string"==typeof e)return e;if(e&&"object"==typeof e){var t=e.address;if("string"==typeof t)return t}}function rg(e,t,r){if(void 0===t&&(t=1e3),void 0===r&&(r=500),e.size>t)for(var n=Array.from(e),i=0;i<r&&i<n.length;i++)e.delete(n[i])}var rv=function(){function e(e,t,r){this.unsubscribers=[],this.trackingState={isProcessing:!1},this.disposed=!1,this.reconciling=!1,this.transitionGeneration=0,this.missedDisconnect=!1,this.processedMutations=new Set,this.processedQueries=new Set,this.wrapEpochs=new WeakMap,this.wrapRetryCounts=new WeakMap,this.wrapRetryTimers=new Set,this.wrapSessionGeneration=0,this.formo=e,this.wagmiConfig=t,this.queryClient=r,R.info("WagmiEventHandler: Initializing Wagmi integration");var n,i,a=this.pruneMarkersForLostWallets(),o=this.formo.writeKey;if(rt.set(o,(null!=(s=rt.get(o))?s:0)+1),a){var s,c=rr.get(o);c&&(clearTimeout(c),rr.delete(o))}this.ownerKey=ro(this.formo.writeKey,t),rn.set(this.ownerKey,this),n=this.ownerKey,(i=rf.get(n))&&(clearTimeout(i),rf.delete(n)),this.setupConnectionListeners(),this.seedFromCurrentState(),this.queryClient?(this.setupMutationTracking(),this.setupQueryTracking()):R.warn("WagmiEventHandler: QueryClient not provided, signature and transaction events will not be tracked")}return e.prototype.pruneMarkersForLostWallets=function(){var e,t=this;try{e=this.getState()}catch(e){return!1}var r="".concat(this.formo.writeKey,":"),n=new Set;
2e.connections.forEach(function(e){e.accounts.forEach(function(e){return n.add(re(t.formo.writeKey,e))})});var i=!1;return t9.forEach(function(e){e.startsWith(r)&&(n.has(e)?i=!0:t9.delete(e))}),i},Object.defineProperty(e.prototype,"isEmittingOwner",{get:function(){if(!this.ownerKey)return!0;var e=rn.get(this.ownerKey);return e?e===this:(rn.set(this.ownerKey,this),!0)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"pendingTransactions",{get:function(){var e,t=null!=(e=this.ownerKey)?e:"",r=rl.get(t);return r||(r=new Map,rl.set(t,r)),r},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"pendingBatches",{get:function(){var e,t=null!=(e=this.ownerKey)?e:"",r=rd.get(t);return r||(r=new Map,rd.set(t,r)),r},enumerable:!1,configurable:!0}),e.prototype.setupConnectionListeners=function(){var e=this;R.info("WagmiEventHandler: Setting up connection listeners");var t=this.wagmiConfig.subscribe(function(e){return e.status},function(t,r){e.handleStatusChange(t,r)});this.unsubscribers.push(t);var r=this.wagmiConfig.subscribe(function(t){var r;return null!=(r=e.getActiveConnectionChainId(t))?r:t.chainId},function(t,r){e.handleChainChange(t,r)});this.unsubscribers.push(r);var n=this.wagmiConfig.subscribe(function(t){var r,n;return"".concat(null!=(r=t.current)?r:"","|").concat(null!=(n=e.getConnectedAddress(t))?n:"")},function(t,r){var n=t.split("|")[1],i=(null!=r?r:"|").split("|")[1];e.wrapActiveConnectorProvider(e.getState()),e.handleActiveAddressChange(n||void 0,i||void 0)});this.unsubscribers.push(n),R.info("WagmiEventHandler: Connection listeners set up successfully")},e.prototype.seedFromCurrentState=function(){var e,t;try{var r=this.getState();this.kickWalletConnectPeerLookup(r),this.wrapActiveConnectorProvider(r)}catch(e){}try{var n=this.getState();if("connected"!==n.status)return;var i=this.getConnectedAddress(n),a=null!=(e=this.getActiveConnectionChainId(n))?e:n.chainId;if(!i||void 0===a)return void R.debug("WagmiEventHandler: Connected at init but address or chainId is missing, nothing to seed",{address:i,chainId:a});if(R.info("WagmiEventHandler: Adopting connection that predates this handler",{address:i,chainId:a}),this.formo.syncWalletState({chainId:a,address:i}),(null==(t=this.formo.currentAddress)?void 0:t.toLowerCase())!==i.toLowerCase())return void R.debug("WagmiEventHandler: Central state declined the connection, not seeding",{address:i,chainId:a});if(this.trackingState.lastAddress=i,this.trackingState.lastChainId=a,this.trackingState.lastStatus=n.status,this.trackingState.lastConnectionId=n.current,!this.formo.isAutocaptureEnabled("connect")||!this.isEmittingOwner)return void R.debug("WagmiEventHandler: Connect autocapture disabled, adopted without emitting",{address:i,chainId:a});if(!this.formo.willTrackEvent(a))return void R.debug("WagmiEventHandler: Connect would not be tracked, adopted without emitting",{address:i,chainId:a});var o=re(this.formo.writeKey,i),s=n.current?n.connections.get(n.current):void 0;if("none"!==rp(o,s))return void R.debug("WagmiEventHandler: Wallet already adopted this page load, not re-emitting connect",{address:i});rm(o,s);var c=this.getConnectorName(n);Promise.resolve(this.formo.connect({chainId:a,address:i},t2({},c&&{providerName:c}))).catch(function(e){rh(o,s),R.error("WagmiEventHandler: Error emitting seeded connect event:",e)})}catch(e){R.error("WagmiEventHandler: Error seeding from current state:",e)}},e.prototype.restoreCentralStateFromTracking=function(){var e,t=this.trackingState,r=t.lastAddress,n=t.lastChainId;r&&void 0!==n&&((null==(e=this.formo.currentAddress)?void 0:e.toLowerCase())!==r.toLowerCase()||this.formo.currentChainId!==n)&&(R.info("WagmiEventHandler: Restoring central state a stale disconnect cleared",{address:r,chainId:n}),this.formo.syncWalletState({chainId:n,address:r}))},e.prototype.releaseTrackedWallet=function(){var e=this.trackingState.lastAddress;this.trackingState.lastAddress=void 0,this.trackingState.lastChainId=void 0,this.trackingState.lastConnectionId=void 0,e&&t9.delete(re(this.formo.writeKey,e))},e.prototype.retryAdoption=function(){this.disposed||(this.trackingState.lastAddress&&!this.tracksLiveWallet()&&(R.debug("WagmiEventHandler: Tracked wallet is no longer the live one, releasing before retry",{tracked:this.trackingState.lastAddress}),this.releaseTrackedWallet()),this.resyncCentralState(),this.trackingState.lastAddress&&this.isCurrentWalletAnnounced()||this.seedFromCurrentState())},e.prototype.tracksLiveWallet=function(){var e=this.trackingState.lastAddress;if(!e)return!1;try{var t=this.getState();if("connected"!==t.status)return!1;var r=this.getConnectedAddress(t);return!!r&&r.toLowerCase()===e.toLowerCase()}catch(e){return R.error("WagmiEventHandler: Error reading state to compare wallets:",e),!1}},e.prototype.resyncCentralState=function(){var e,t=this.trackingState,r=t.lastAddress,n=t.lastChainId;r&&void 0!==n&&((null==(e=this.formo.currentAddress)?void 0:e.toLowerCase())!==r.toLowerCase()||this.formo.currentChainId!==n)&&(R.info("WagmiEventHandler: Re-syncing central state for a tracked wallet",{address:r,chainId:n}),this.formo.syncWalletState({chainId:n,address:r}))},e.prototype.isCurrentWalletAnnounced=function(){var e,t=this.trackingState.lastAddress;if(!t)return!1;try{var r=this.getState();e=r.current?r.connections.get(r.current):void 0}catch(e){}return"none"!==rp(re(this.formo.writeKey,t),e)},e.prototype.handleStatusChange=function(e,t){return t8(this,void 0,void 0,function(){var r,n,i,a,o,s,c,u,l,d,f,p,h,m,b;return t3(this,function(y){switch(y.label){case 0:if(("disconnected"===e||"reconnecting"===e)&&(this.wrapSessionGeneration+=1,this.fallbackConnector=void 0,this.fallbackProvider=void 0),this.trackingState.isProcessing)return"disconnected"===e&&(this.missedDisconnect=!0),R.debug("WagmiEventHandler: Already processing status change, skipping"),[2];this.trackingState.isProcessing=!0;try{r=this.getState(),this.kickWalletConnectPeerLookup(r),this.wrapActiveConnectorProvider(r)}catch(e){}this.transitionGeneration+=1,y.label=1;case 1:if(y.trys.push([1,14,15,16]),n=this.getState(),i=this.getConnectedAddress(n),a=null!=(p=this.getActiveConnectionChainId(n))?p:n.chainId,R.info("WagmiEventHandler: Status changed",{status:e,prevStatus:t,address:i,chainId:a}),!("disconnected"===e&&this.trackingState.lastAddress))return[3,4];if(o=this.trackingState.lastAddress,s=this.trackingState.lastChainId,this.trackingState.lastConnectionId=void 0,this.trackingState.lastAddress=void 0,this.trackingState.lastChainId=void 0,this.pendingChainId=void 0,this.missedDisconnect=!1,t9.delete(re(this.formo.writeKey,o)),!(this.formo.isAutocaptureEnabled("disconnect")&&this.isEmittingOwner))return[3,3];return[4,this.formo.disconnect({chainId:s,address:o})];case 2:return y.sent(),[3,4];case 3:this.formo.syncWalletState({chainId:s}),y.label=4;case 4:if("connected"!==e||"connected"===t||!(i&&void 0!==a))return[3,13];if((null==(h=this.trackingState.lastAddress)?void 0:h.toLowerCase())!==i.toLowerCase())return[3,9];if(this.trackingState.lastChainId===a)return[3,7];if(this.pendingChainId!==a)return[3,6];return this.pendingChainId=void 0,R.info("WagmiEventHandler: Re-entry carries a chain the subscription dropped, emitting it",{address:i,from:this.trackingState.lastChainId,to:a}),[4,this.handleChainChange(a,this.trackingState.lastChainId)];case 5:return y.sent(),this.trackingState.lastStatus=e,[2];case 6:return R.info("WagmiEventHandler: Tracked wallet re-entered connected on a different chain",{address:i,from:this.trackingState.lastChainId,to:a}),this.formo.syncWalletState({chainId:a,address:i}),(null==(m=this.formo.currentAddress)?void 0:m.toLowerCase())===i.toLowerCase()?this.trackingState.lastChainId=a:(R.debug("WagmiEventHandler: Central state declined the re-entry chain, dropping the wallet",{address:i,chainId:a}),this.releaseTrackedWallet()),[3,8];case 7:R.debug("WagmiEventHandler: Ignoring re-entry to connected for an already tracked wallet",{address:i,chainId:a}),y.label=8;case 8:return this.trackingState.lastStatus=e,[2];case 9:if(this.formo.syncWalletState({chainId:a,address:i}),(null==(b=this.formo.currentAddress)?void 0:b.toLowerCase())!==i.toLowerCase())return R.debug("WagmiEventHandler: Central state declined the connection, not adopting",{address:i,chainId:a}),this.trackingState.lastStatus=e,[2];if(this.trackingState.lastAddress=i,this.trackingState.lastChainId=a,this.trackingState.lastConnectionId=n.current,!(this.formo.isAutocaptureEnabled("connect")&&this.isEmittingOwner&&this.formo.willTrackEvent(a)))return[3,13];if(c=re(this.formo.writeKey,i),u=n.current?n.connections.get(n.current):void 0,"none"!==rp(c,u))return R.debug("WagmiEventHandler: Connect already announced for this wallet, not emitting again",{address:i}),this.trackingState.lastStatus=e,[2];rm(c,u),l=this.getConnectorName(n),y.label=10;case 10:return y.trys.push([10,12,,13]),[4,this.formo.connect({chainId:a,address:i},t2({},l&&{providerName:l}))];case 11:return y.sent(),[3,13];case 12:throw d=y.sent(),rh(c,u),d;case 13:return this.trackingState.lastStatus=e,[3,16];case 14:return f=y.sent(),R.error("WagmiEventHandler: Error handling status change:",f),[3,16];case 15:return this.trackingState.isProcessing=!1,this.reconcileWithLiveState(),[7];case 16:return[2]}})})},e.prototype.reconcileWithLiveState=function(){var e,t=this;if(!this.disposed&&!this.trackingState.isProcessing&&!this.reconciling){try{e=this.getState()}
2catch(e){R.error("WagmiEventHandler: Error reading state to reconcile:",e);return}if("connected"===e.status||"disconnected"===e.status){var r="connected"===e.status?this.getConnectedAddress(e):void 0,n=this.trackingState.lastAddress;if(r||n){if(r&&n){if(r.toLowerCase()===n.toLowerCase()){if(this.missedDisconnect){this.missedDisconnect=!1,R.info("WagmiEventHandler: A disconnect/reconnect cycle completed while the lock was held",{address:r}),this.reconciling=!0;try{this.handleStatusChange("disconnected","connected").then(function(){return t.retryAdoption()})}finally{this.reconciling=!1}return}this.resyncCentralState();var i=this.pendingChainId;void 0!==i&&(this.pendingChainId=void 0,i!==this.trackingState.lastChainId&&(R.info("WagmiEventHandler: Replaying a chain change dropped while reconnecting",{address:r,from:this.trackingState.lastChainId,to:i}),this.handleChainChange(i,this.trackingState.lastChainId)));return}R.info("WagmiEventHandler: Wallet changed while the lock was held, re-adopting",{from:n,to:r}),this.reconciling=!0;try{this.releaseTrackedWallet(),this.seedFromCurrentState()}finally{this.reconciling=!1}return}this.reconciling=!0;try{r?(R.info("WagmiEventHandler: Reconnect landed while the lock was held, adopting it",{address:r}),this.retryAdoption()):(R.info("WagmiEventHandler: Disconnect landed while the lock was held, applying it",{address:n}),this.handleStatusChange("disconnected","connected"))}finally{this.reconciling=!1}}}}},e.prototype.handleActiveAddressChangeEntryKick=function(){try{this.kickWalletConnectPeerLookup(this.getState())}catch(e){}},e.prototype.handleActiveAddressChange=function(e,t){return t8(this,void 0,void 0,function(){var r,n,i,a,o,s,c,u,l,d,f,p,h,m,b,y,g,v,w,E,P,x;return t3(this,function(A){switch(A.label){case 0:if(this.handleActiveAddressChangeEntryKick(),"connected"!==(r=this.getState()).status||(i=!!(n=this.trackingState.lastConnectionId)&&!r.connections.has(n),a=void 0!==this.trackingState.lastConnectionId&&void 0!==r.current&&r.current!==this.trackingState.lastConnectionId,!i&&!a&&(!e||e===t||(null==(g=this.trackingState.lastAddress)?void 0:g.toLowerCase())===e.toLowerCase())))return[2];if(!(a&&!i&&e&&(null==(v=this.trackingState.lastAddress)?void 0:v.toLowerCase())===e.toLowerCase()))return[3,3];if(o=null!=(w=this.getActiveConnectionChainId(r))?w:r.chainId,R.info("WagmiEventHandler: Active connection changed for the same account",{address:e,from:this.trackingState.lastConnectionId,to:r.current}),this.trackingState.lastConnectionId=r.current,void 0===o||o===this.trackingState.lastChainId)return[3,2];return[4,this.applyChainForTrackedWallet(e,o)];case 1:A.sent(),A.label=2;case 2:return[2];case 3:if(!e||(s=++this.transitionGeneration,void 0===(c=null!=(E=this.getActiveConnectionChainId(r))?E:r.chainId)))return[2];if(!i)return[3,14];if(!(t&&this.isAddressConnected(r,t)))return[3,7];if(R.info("WagmiEventHandler: Tracked connector fell away, account still connected elsewhere",{address:t,connection:r.current}),this.trackingState.lastConnectionId=r.current,(null==(P=this.trackingState.lastAddress)?void 0:P.toLowerCase())!==e.toLowerCase())return[3,6];if(this.trackingState.lastChainId===c)return[3,5];return[4,this.applyChainForTrackedWallet(e,c)];case 4:A.sent(),A.label=5;case 5:return[2];case 6:return[3,14];case 7:if(!t)return[3,14];if(R.info("WagmiEventHandler: Tracked connector disconnected, wagmi fell back to another connection",{disconnected:t,fallback:e}),u=this.trackingState.lastChainId,this.releaseTrackedWallet(),!(this.formo.isAutocaptureEnabled("disconnect")&&this.isEmittingOwner))return[3,12];A.label=8;case 8:return A.trys.push([8,10,,11]),[4,this.formo.disconnect({chainId:u,address:t})];case 9:return A.sent(),[3,11];case 10:return l=A.sent(),R.error("WagmiEventHandler: Error tracking connector fallback disconnect:",l),[3,11];case 11:return[3,13];case 12:this.formo.syncWalletState({chainId:u}),A.label=13;case 13:d=void 0;try{d=this.getState()}catch(e){}if(f=!this.disposed&&(null==d?void 0:d.status)==="connected"&&d.current===r.current,s!==this.transitionGeneration||!f)return R.debug("WagmiEventHandler: A newer transition superseded this one, stopping",{address:e}),this.restoreCentralStateFromTracking(),[2];A.label=14;case 14:if(R.info("WagmiEventHandler: Active account switched",{from:t,to:e,chainId:c}),this.formo.syncWalletState({chainId:c,address:e}),(null==(x=this.formo.currentAddress)?void 0:x.toLowerCase())!==e.toLowerCase())return R.debug("WagmiEventHandler: Central state declined the switched account, not adopting",{address:e,chainId:c}),this.releaseTrackedWallet(),[2];if(this.trackingState.lastAddress=e,this.trackingState.lastChainId=c,this.trackingState.lastConnectionId=r.current,!(this.formo.isAutocaptureEnabled("connect")&&this.isEmittingOwner&&this.formo.willTrackEvent(c)))return[3,18];if(t&&!this.isAddressConnected(r,t)&&t9.delete(re(this.formo.writeKey,t)),p=re(this.formo.writeKey,e),h=r.current?r.connections.get(r.current):void 0,m="none"!==rp(p,h),rm(p,h),m)return R.debug("WagmiEventHandler: Fallback connection was already announced, not re-emitting connect",{address:e}),[2];A.label=15;case 15:return A.trys.push([15,17,,18]),b=this.getConnectorName(r),[4,this.formo.connect({chainId:c,address:e},t2({},b&&{providerName:b}))];
2case 16:return A.sent(),[3,18];case 17:return y=A.sent(),rh(p,h),R.error("WagmiEventHandler: Error tracking account switch:",y),[3,18];case 18:return[2]}})})},e.prototype.applyChainForTrackedWallet=function(e,t){return t8(this,void 0,void 0,function(){var r,n;return t3(this,function(i){switch(i.label){case 0:if(this.formo.syncWalletState({chainId:t,address:e}),(null==(n=this.formo.currentAddress)?void 0:n.toLowerCase())!==e.toLowerCase())return R.debug("WagmiEventHandler: Central state declined the new chain, dropping the wallet",{address:e,chainId:t}),this.releaseTrackedWallet(),[2];if(this.trackingState.lastChainId=t,!(this.formo.isAutocaptureEnabled("chain")&&this.isEmittingOwner))return[3,4];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this.formo.chain({chainId:t,address:e})];case 2:return i.sent(),[3,4];case 3:return r=i.sent(),R.error("WagmiEventHandler: Error tracking chain change:",r),[3,4];case 4:return[2]}})})},e.prototype.handleChainChange=function(e,t){return t8(this,void 0,void 0,function(){var r,n,i,a,o,s,c,u;return t3(this,function(l){switch(l.label){case 0:if(void 0!==this.fallbackProvider&&((r=this.getState()).current?null==(s=r.connections.get(r.current))?void 0:s.connector:void 0)===this.fallbackConnector)try{null==(u=(c=this.formo)._rememberWagmiProviderChain)||u.call(c,this.fallbackProvider,e)}catch(e){}if(e===t||void 0===e)return[2];if("connected"!==(n=this.getState()).status)return this.pendingChainId=e,[2];if(this.pendingChainId=void 0,!(i=this.getConnectedAddress(n)))return R.warn("WagmiEventHandler: Chain changed but no address found"),[2];if(void 0!==this.trackingState.lastConnectionId&&void 0!==n.current&&n.current!==this.trackingState.lastConnectionId)return R.debug("WagmiEventHandler: Chain change belongs to a connection not adopted yet, deferring",{chainId:e,from:this.trackingState.lastConnectionId,to:n.current}),[2];if(a=!!this.trackingState.lastAddress,o=this.isCurrentWalletAnnounced(),(!a||!o)&&(this.retryAdoption(),!o&&this.isCurrentWalletAnnounced()))return[2];return R.info("WagmiEventHandler: Chain changed",{chainId:e,prevChainId:t,address:i}),[4,this.applyChainForTrackedWallet(i,e)];case 1:return l.sent(),[2]}})})},e.prototype.setupMutationTracking=function(){var e=this;if(this.queryClient){R.info("WagmiEventHandler: Setting up mutation tracking");var t=this.queryClient.getMutationCache().subscribe(function(t){e.handleMutationEvent(t)});this.unsubscribers.push(t),R.info("WagmiEventHandler: Mutation tracking set up successfully")}},e.prototype.setupQueryTracking=function(){var e=this;if(this.queryClient){R.info("WagmiEventHandler: Setting up query tracking");var t=this.queryClient.getQueryCache().subscribe(function(t){e.handleQueryEvent(t)});this.unsubscribers.push(t),R.info("WagmiEventHandler: Query tracking set up successfully")}},e.prototype.handleQueryEvent=function(e){if("updated"===e.type&&this.isEmittingOwner){var t=e.query,r=t.queryKey;if(r&&0!==r.length){var n=r[0];if("waitForTransactionReceipt"===n||"callsStatus"===n){if("callsStatus"===n)return void this.handleCallsStatusQuery(t);var i=t.state,a=i.data,o=null==a?void 0:a.status,s="".concat(t.queryHash,":").concat(i.status,":").concat(o||"");if(this.processedQueries.has(s))return void R.debug("WagmiEventHandler: Skipping duplicate query event",{queryType:n,queryHash:t.queryHash,status:i.status,receiptStatus:o});this.processedQueries.add(s),R.debug("WagmiEventHandler: Query event",{queryType:n,queryHash:t.queryHash,status:i.status}),this.handleTransactionReceiptQuery(t),rg(this.processedQueries)}}}},e.prototype.settleFromCachedCallsStatus=function(e){var t,r,n;try{var i=null==(t=this.queryClient)?void 0:t.getQueryCache(),a=null==(r=null==i?void 0:i.getAll)?void 0:r.call(i);if(!Array.isArray(a))return;for(var o=0;o<a.length;o++){var s=a[o],c=null==s?void 0:s.queryKey;Array.isArray(c)&&"callsStatus"===c[0]&&(null==(n=c[1])?void 0:n.id)===e&&this.handleCallsStatusQuery(s)}}catch(e){R.debug("WagmiEventHandler: cached callsStatus scan failed",e)}},e.prototype.handleCallsStatusQuery=function(e){var t,r=this;if(this.formo.isAutocaptureEnabled("transaction")){var n=e.queryKey[1],i=null==n?void 0:n.id;if(i){var a=this.pendingBatches.get(i);if(!a)return void R.debug("WagmiEventHandler: unobserved batch",{batchId:i}
2);var o=e.state;if("success"===o.status&&o.data)try{var s=o.data,c=tK(s);if(void 0===c||c<200)return;R.debug("WagmiEventHandler: batch settled",{batchId:i,code:c});var u=a.chainIdWasExplicit?a.chainId:null!=(t=function(e){var t=null==e?void 0:e.chainId;if("number"==typeof t&&Number.isFinite(t)&&t>0)return t;if("string"==typeof t){var r=parseInt(t,16);if(Number.isFinite(r)&&r>0)return r}}(s))?t:a.chainId;a.calls.forEach(function(e,t){var n=tJ(s,t,a.calls.length),o=tV(c,n);void 0!==o&&r.formo.transaction(t2(t2(t2(t2({status:o,chainId:u||0,address:a.address},e.data&&{data:e.data}),e.to&&{to:e.to}),e.value&&{value:e.value}),(null==n?void 0:n.transactionHash)?{transactionHash:n.transactionHash}:{}),t2({batch_size:a.calls.length,batch_index:t,batch_id:i},a.providerName?{providerName:a.providerName}:{}))}),this.pendingBatches.delete(i)}catch(e){R.error("WagmiEventHandler: callsStatus error:",e)}}}},e.prototype.handleTransactionReceiptQuery=function(e){if(this.formo.isAutocaptureEnabled("transaction")){var t,r,n=e.state,i=e.queryKey;if("success"===n.status){var a=i[1],o=null==a?void 0:a.hash,c=null==a?void 0:a.chainId;if(!o)return void R.warn("WagmiEventHandler: Transaction receipt query but no hash found");var u=o.toLowerCase(),l=this.pendingTransactions.get(u);if(!l)return void R.debug("WagmiEventHandler: Receipt for unobserved tx hash; ignoring",{transactionHash:o});var d=l.address,f=l.chainIdWasExplicit?l.chainId:null!=(t=null!=c?c:l.chainId)?t:this.trackingState.lastChainId;if(!d)return void R.warn("WagmiEventHandler: Transaction receipt query but no address available");try{var p=n.data;if((null==p?void 0:p.status)!=="success"&&(null==p?void 0:p.status)!=="reverted")return void R.debug("WagmiEventHandler: Receipt without explicit success/reverted status; ignoring",{transactionHash:o,status:null==p?void 0:p.status});var h="reverted"===p.status?s.REVERTED:s.CONFIRMED;R.info("WagmiEventHandler: Tracking transaction confirmation",{status:h,transactionHash:o,address:d,chainId:f,blockNumber:null==(r=null==p?void 0:p.blockNumber)?void 0:r.toString()}),this.formo.transaction(t2(t2(t2(t2(t2({status:h,chainId:f||0,address:d,transactionHash:o},(null==l?void 0:l.data)&&{data:l.data}),(null==l?void 0:l.to)&&{to:l.to}),(null==l?void 0:l.value)&&{value:l.value}),(null==l?void 0:l.function_name)&&{function_name:l.function_name}),(null==l?void 0:l.function_args)&&{function_args:l.function_args}),t2(t2({},(null==l?void 0:l.providerName)?{providerName:l.providerName}:this.mutationAttribution()),null==l?void 0:l.safeFunctionArgs)),this.pendingTransactions.delete(u)}catch(e){R.error("WagmiEventHandler: Error handling transaction receipt query:",e)}}}},e.prototype.handleMutationEvent=function(e){if("updated"===e.type&&this.isEmittingOwner){var t=e.mutation,r=t.options.mutationKey;if(r&&0!==r.length){var n=r[0],i=t.state,a="".concat(t.mutationId,":").concat(i.status);if(this.processedMutations.has(a))return void R.debug("WagmiEventHandler: Skipping duplicate mutation event",{mutationType:n,mutationId:t.mutationId,status:i.status});this.processedMutations.add(a),R.debug("WagmiEventHandler: Mutation event",{mutationType:n,mutationId:t.mutationId,status:i.status}),("signMessage"===n||"signTypedData"===n)&&this.handleSignatureMutation(n,t),("sendTransaction"===n||"writeContract"===n)&&this.handleTransactionMutation(n,t),"sendCalls"===n&&this.handleSendCallsMutation(t),rg(this.processedMutations)}}},e.prototype.hasMatchingPendingMutation=function(e,t){var r,n,i,a,o,s;try{var c=null==(r=this.queryClient)?void 0:r.getMutationCache(),u=null==(n=null==c?void 0:c.getAll)?void 0:n.call(c);if(!Array.isArray(u))return!1;var l={personal_sign:["signMessage"],eth_signTypedData_v4:["signTypedData"],eth_sendTransaction:["sendTransaction","writeContract"],wallet_sendCalls:["sendCalls"]}[e];if(!l)return!1;for(var d=0;d<u.length;d++){var f=u[d];if((null==(i=null==f?void 0:f.state)?void 0:i.status)==="pending"){var p=null==(o=null==(a=null==f?void 0:f.options)?void 0:a.mutationKey)?void 0:o[0];if("string"==typeof p&&l.includes(p)){var h=null==(s=f.state)?void 0:s.variables;if("sendTransaction"===p&&h){var m=Array.isArray(t)?t[0]:void 0,b=h.to;
2if("string"==typeof(null==m?void 0:m.to)&&"string"==typeof b&&m.to.toLowerCase()!==b.toLowerCase())continue}return!0}}}return!1}catch(e){return!1}},e.prototype.mutationAttribution=function(){try{var e=this.getConnectorName(this.getState());return e?{providerName:e}:void 0}catch(e){return}},e.prototype.handleSignatureMutation=function(e,t){if(this.formo.isAutocaptureEnabled("signature")){var r=t.state,n=r.variables||{},i=null!=(l=null!=(u=null!=(c=rb(null==(s=n.domain)?void 0:s.chainId))?c:rb(n.chainId))?u:this.trackingState.lastChainId)?l:0,a=ry(n.account)||this.trackingState.lastAddress;if(!a)return void R.warn("WagmiEventHandler: Signature event but no address available");try{if("pending"===r.status)d=o.REQUESTED;else if("success"===r.status)d=o.CONFIRMED;else{if("error"!==r.status)return;d=o.REJECTED}var s,c,u,l,d,f=void 0;f="signMessage"===e?n.message||"":JSON.stringify(n.message||n.types||{}),R.info("WagmiEventHandler: Tracking signature event",{status:d,mutationType:e,address:a,chainId:i}),this.formo.signature({status:d,chainId:i,address:a,message:f},this.mutationAttribution())}catch(e){R.error("WagmiEventHandler: Error handling signature mutation:",e)}}},e.prototype.handleTransactionMutation=function(e,t){if(this.formo.isAutocaptureEnabled("transaction")){var r=t.state,n=r.variables||{},i=rb(n.chainId),a=null!=i?i:this.trackingState.lastChainId,o=ry(n.account)||n.from||this.trackingState.lastAddress;if(!o)return void R.warn("WagmiEventHandler: Transaction event but no address available");try{var c,u,l,d=void 0;if("pending"===r.status)l=s.STARTED;else if("success"===r.status)l=s.BROADCASTED,d=r.data;else{if("error"!==r.status)return;l=s.REJECTED}var f=void 0,p=void 0,h=void 0,m=void 0,b=null==(c=n.value)?void 0:c.toString();if("writeContract"===e){var y=n.abi,g=n.functionName,v=n.args,w=n.address,E=n.dataSuffix;if(p=w,h=g,y&&g){m=function(e,t,r){if(e&&t&&r&&Array.isArray(r))try{var n=e.find(function(e){return"function"===e.type&&e.name===t});if(!(null==n?void 0:n.inputs)||!Array.isArray(n.inputs))return;var i={};return n.inputs.forEach(function(e,t){if(t<r.length){var n=r[t];i[e.name||"arg".concat(t)]=function e(t){if("bigint"==typeof t)return t.toString();if(Array.isArray(t))return t.map(e);if(null!==t&&"object"==typeof t){for(var r={},n=0,i=Object.entries(t);n<i.length;n++){var a=i[n],o=a[0],s=a[1];r[o]=e(s)}return r}return t}(n)}}),i}catch(e){R.warn("WagmiEventHandler: Failed to extract function args",e);return}}(y,g,v);var P=function(e,t,r){try{var n=t5();if(!n)return void R.debug("WagmiEventHandler: viem not available, cannot encode function data");return n.encodeFunctionData({abi:e,functionName:t,args:r||[]})}catch(e){R.warn("WagmiEventHandler: Failed to encode function data",e);return}}(y,g,v);P&&(f=function(e,t){if(!t||"0x"===t)return e;var r=t5();if(null==r?void 0:r.concatHex)return r.concatHex([e,t]);var n=t.replace(/^0x/i,"");return"".concat(e).concat(n)}(P,E),R.debug("WagmiEventHandler: Encoded writeContract data",f.substring(0,10)))}}else f=n.data,p=n.to;R.info("WagmiEventHandler: Tracking transaction event",{status:l,mutationType:e,address:o,chainId:a,transactionHash:d,function_name:h});var x=function(e,t){if(e){for(var r={},n=0,i=Object.entries(e);n<i.length;n++){var a=i[n],o=a[0],s=a[1],c=o;if(t.has(o))do c="arg_".concat(c);while(c in e)if(r[c]=s,null!==s&&"object"==typeof s&&!Array.isArray(s))for(var u=function e(t,r){void 0===r&&(r="");for(var n={},i=0,a=Object.entries(t);i<a.length;i++){var o=a[i],s=o[0],c=o[1],u=r?"".concat(r,"_").concat(s):s;null===c||"object"!=typeof c||Array.isArray(c)?n[u]=c:Object.assign(n,e(c,u))}return n}(s,c),l=0,d=Object.entries(u);l<d.length;l++){var f=d[l],p=f[0],h=f[1];p in r?R.debug("WagmiEventHandler: Skipping flattened key collision",{flatKey:p,existingValue:r[p]}):r[p]=h}}return r}}(m,t4);if(l===s.BROADCASTED&&d){var A=d.toLowerCase(),I=t2(t2(t2(t2(t2(t2(t2(t2(t2({address:o},null!=(u=this.mutationAttribution())?u:{}),void 0!==a&&{chainId:a}),{chainIdWasExplicit:void 0!==i}),f&&{data:f}),p&&{to:p}),b&&{value:b}),h&&{function_name:h}),m&&{function_args:m}),x&&{safeFunctionArgs:x});if(this.pendingTransactions.set(A,I),R.debug("WagmiEventHandler: Stored pending transaction for confirmation",{transactionHash:A}),this.pendingTransactions.size>100)for(var T=Array.from(this.pendingTransactions.keys()),S=0;S<50&&S<T.length;S++)this.pendingTransactions.delete(T[S])}this.formo.transaction(t2(t2(t2(t2(t2(t2({status:l,chainId:a||0,address:o},f&&{data:f}),p&&{to:p}),b&&{value:b}),d&&{transactionHash:d}),h&&{function_name:h}),m&&{function_args:m}),t2(t2({},this.mutationAttribution()),x))}catch(e){R.error("WagmiEventHandler: Error handling transaction mutation:",e)}}},e.prototype.handleSendCallsMutation=function(e){var t=this;if(this.formo.isAutocaptureEnabled("transaction")){var r=e.state,n=r.variables||{},i=Array.isArray(n.calls)?n.calls:[];if(0!==i.length){var a=rb(n.chainId),o=null!=a?a:this.trackingState.lastChainId,c=ry(n.account)||this.trackingState.lastAddress;if(!c)return void R.warn("WagmiEventHandler: sendCalls without address");try{var u=i.map(function(e){return{to:null==e?void 0:e.to,value:(null==e?void 0:e.value)!==void 0?String(e.value):void 0,data:null==e?void 0:e.data}}),l=this.mutationAttribution(),d=function(e,r){u.forEach(function(n,i){t.formo.transaction(t2(t2(t2({status:e,chainId:o||0,address:c},n.data&&{data:n.data}),n.to&&{to:n.to}),n.value&&{value:n.value}),t2(t2({batch_size:u.length,batch_index:i},l),r))})};if("pending"===r.status)R.debug("WagmiEventHandler: sendCalls start",{calls:u.length}),d(s.STARTED);else if("success"===r.status){var f=tG(r.data);if(R.debug("WagmiEventHandler: sendCalls broadcast",{batchId:f}),d(s.BROADCASTED,f?{batch_id:f}:void 0),f){if(this.pendingBatches.set(f,t2(t2(t2({address:c},null!=l?l:{}),void 0!==o&&{chainId:o}),{chainIdWasExplicit:void 0!==a,calls:u})),this.pendingBatches.size>100)for(var p=Array.from(this.pendingBatches.keys()),h=0;h<50&&h<p.length;h++)this.pendingBatches.delete(p[h]);this.settleFromCachedCallsStatus(f)}}else"error"===r.status&&tC(r.error)&&(R.debug("WagmiEventHandler: sendCalls rejected"),d(s.REJECTED))}catch(e){R.error("WagmiEventHandler: sendCalls error:",e)}}}},e.prototype.getState=function(){return"function"==typeof this.wagmiConfig.getState?this.wagmiConfig.getState():this.wagmiConfig.state?this.wagmiConfig.state:(R.warn("WagmiEventHandler: Unable to get state from config, returning default state"),{status:"disconnected",connections:new Map,current:void 0,chainId:void 0})},e.prototype.getActiveConnectionChainId=function(e){var t;if(e.current)return null==(t=e.connections.get(e.current))?void 0:t.chainId},e.prototype.getConnectedAddress=function(e){if(e.current){var t=e.connections.get(e.current);if(t&&0!==t.accounts.length)return t.accounts[0]}},e.prototype.isAddressConnected=function(e,t){var r=t.toLowerCase(),n=!1;return e.connections.forEach(function(e){!n&&e.accounts.some(function(e){return e.toLowerCase()===r})&&(n=!0)}),n},e.prototype.attributionForConnector=function(e,t){var r=this.nameForConnector(e,t);if(r){var n=e.rdns,i="string"==typeof n&&n.length>0?n:Array.isArray(n)&&1===n.length&&"string"==typeof n[0]&&n[0].length>0?n[0]:void 0;return t2({name:r},i&&{rdns:i})}},e.prototype.boundConnectorAttribution=function(e){var t=this;return function(){if(!t.disposed)try{return t.attributionForConnector(e,t.getState())}catch(e){return}}},e.prototype.nameForConnector=function(e,t){var r,n=rs.get(e);if(n)return n;(t.current?null==(r=t.connections.get(t.current))?void 0:r.connector:void 0)===e&&this.kickWalletConnectPeerLookup(t);var i=e.name;return"string"==typeof i&&i.length>0?i:void 0},e.prototype.getConnectorName=function(e){if(e.current){var t=e.connections.get(e.current),r=null==t?void 0:t.connector;if(t&&r){var n=rs.get(r);return n||(this.kickWalletConnectPeerLookup(e),r.name)}}},e.prototype.wrapActiveConnectorProvider=function(e,t){var r,n,i,a,o=this;if(void 0===t&&(t=!1),(null==(n=null==(r=this.formo.options)?void 0:r.wagmi)?void 0:n.eip1193Fallback)===!0&&"connected"===e.status){var s=e.current?e.connections.get(e.current):void 0,c=null==s?void 0:s.connector;if(s&&"function"==typeof(null==c?void 0:c.getProvider)){var u=(null!=(i=this.wrapEpochs.get(c))?i:0)+1;this.wrapEpochs.set(c,u);var l=this.wrapSessionGeneration;t||this.wrapRetryCounts.delete(c);var d=function(){if(!o.disposed&&o.wrapEpochs.get(c)===u){var e,t=(null!=(e=o.wrapRetryCounts.get(c))?e:0)+1;if(o.wrapRetryCounts.set(c,t),!(t>3)){var r=setTimeout(function(){if(o.wrapRetryTimers.delete(r),!o.disposed){var e,t=o.getState();void 0!==t.current&&(null==(e=t.connections.get(t.current))?void 0:e.connector)===c&&o.wrapEpochs.get(c)===u&&o.wrapActiveConnectorProvider(t,!0)}},25*t);o.wrapRetryTimers.add(r)}}};try{a=c.getProvider()}catch(e){d();return}a.then(function(e){if(o.wrapEpochs.get(c)===u){var t,r,n,i,a=o.getState();if(!o.disposed&&o.wrapSessionGeneration===l&&"connected"===a.status&&void 0!==a.current&&(null==(t=a.connections.get(a.current))?void 0:t.connector)===c){var s=null!=(r=o.getActiveConnectionChainId(a))?r:a.chainId;
2if(!0!==(null==(i=(n=o.formo)._wrapWagmiProvider)?void 0:i.call(n,e,"number"==typeof s?s:void 0,o.boundConnectorAttribution(c))))return void d();o.wrapRetryCounts.delete(c),o.fallbackConnector=c,o.fallbackProvider=e}}}).catch(function(){d()})}}},e.prototype.kickWalletConnectPeerLookup=function(e){var t,r=e.current?e.connections.get(e.current):void 0,n=null==r?void 0:r.connector;if(!(!r||!n||"string"!=typeof n.name||!/walletconnect/i.test(n.name)||"function"!=typeof n.getProvider||rc.has(r))){rc.add(r),ru.get(n)!==r&&rs.delete(n),ru.set(n,r);var i=!1,a=setTimeout(function(){i||ru.get(n)!==r||rs.delete(n)},3e3);null==(t=a.unref)||t.call(a),n.getProvider().then(function(e){if(i=!0,clearTimeout(a),ru.get(n)===r){var t=tO(e);(null==t?void 0:t.name)?(rs.set(n,t.name),R.debug("WagmiEventHandler: WalletConnect peer resolved",{peer:t.name})):(rs.delete(n),rc.delete(r))}}).catch(function(){i=!0,clearTimeout(a),ru.get(n)===r&&rs.delete(n),rc.delete(r)})}},e.prototype.cleanup=function(){this.wrapRetryTimers.forEach(function(e){return clearTimeout(e)}),this.wrapRetryTimers.clear(),R.debug("WagmiEventHandler: Cleaning up subscriptions"),!this.disposed&&(this.disposed=!0,this.transitionGeneration+=1,this.ownerKey&&rn.get(this.ownerKey)===this&&rn.delete(this.ownerKey),function(e){var t,r,n=Math.max(0,(null!=(t=rt.get(e))?t:0)-1);rt.set(e,n);var i=0===n;if(n>0||rr.has(e))return i;var a=setTimeout(function(){rr.delete(e);var t="".concat(e,":");t9.forEach(function(e){e.startsWith(t)&&t9.delete(e)})},3e3);return null==(r=a.unref)||r.call(a),rr.set(e,a),i}(this.formo.writeKey)&&this.ownerKey&&function(e){if(!rf.has(e)){var t,r=setTimeout(function(){rf.delete(e),rl.delete(e),rd.delete(e)},3e3);null==(t=r.unref)||t.call(r),rf.set(e,r)}}(this.ownerKey));for(var e=0,t=this.unsubscribers;e<t.length;e++){var r=t[e];try{r()}catch(e){R.error("WagmiEventHandler: Error during cleanup:",e)}}this.unsubscribers=[],this.processedMutations.clear(),this.processedQueries.clear(),R.debug("WagmiEventHandler: Cleanup complete")},e}(),rw=function(){return(rw=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function rE(e,t,r){if(void 0===t&&(t=1e3),void 0===r&&(r=500),e.size>t)for(var n=Array.from(e),i=0;i<r&&i<n.length;i++)e.delete(n[i])}var rP=function(){function e(e,t,r){this.unsubscribers=[],this.lastWalletStatus="disconnected",this.restorable=!1,this.processedTransactions=new Set,this.startedTransactions=new Set,this.transactionSenders=new Map,this.formo=e,this.store=t,this.explicitCluster=!!(null==r?void 0:r.cluster),this.beforeWalletConnect=null==r?void 0:r.beforeWalletConnect,this.onClusterChange=null==r?void 0:r.onClusterChange,this.afterWalletDisconnect=null==r?void 0:r.afterWalletDisconnect,this.cluster=(null==r?void 0:r.cluster)||this.detectClusterFromStore(t)||"mainnet-beta",this.chainId=ev[this.cluster],R.info("SolanaStoreHandler: Initializing framework-kit store integration",{cluster:this.cluster,chainId:this.chainId}),this.setupWalletSubscription(),this.setupTransactionSubscription(),this.setupClusterSubscription(),this.checkInitialWalletState()}return e.prototype.setCluster=function(e){this.explicitCluster=!0;var t=this.cluster;this.cluster=e,this.chainId=ev[e],t!==e&&this.applyCluster()},e.prototype.applyCluster=function(){this.lastAddress&&(this.lastChainId=this.chainId,!this.restorable||(this.formo.restoreWalletState({address:this.lastAddress,chainId:this.chainId}),this.formo.isAutocaptureEnabled("chain")&&this.formo.chain({chainId:this.chainId,address:this.lastAddress}).catch(function(e){R.error("SolanaStoreHandler: Error emitting chain event",e)})))},e.prototype.getChainId=function(){return this.chainId},e.prototype.resolveCurrentChainId=function(){var e;if(!this.explicitCluster){var t=this.detectClusterFromStore(this.store);t&&t!==this.cluster&&(this.cluster=t,this.chainId=ev[t],null==(e=this.onClusterChange)||e.call(this,t))}return this.chainId},e.prototype.setupWalletSubscription=function(){var e=this,t=this.store.getState().wallet,r=this.store.subscribe(function(r){var n=r.wallet;if(n!==t){var i=t;t=n,e.handleWalletChange(n,i)}});this.unsubscribers.push(r),R.info("SolanaStoreHandler: Wallet subscription set up")},e.prototype.checkInitialWalletState=function(){var e,t,r,n=this.store.getState().wallet;if("connected"===n.status){var i=n.session.account.address;if(i&&!eg(i)){this.lastWalletStatus="connected",this.lastAddress=i,this.lastChainId=this.chainId,R.info("SolanaStoreHandler: Already connected on initialization",{address:i,chainId:this.chainId});var a=(null==(e=n.session.connector)?void 0:e.name)||n.connectorId,o=ex(a);(null==(r=null==(t=this.beforeWalletConnect)?void 0:t.call(this,{address:i,chainId:this.chainId,rdns:o}))||r)&&this.formo.isAutocaptureEnabled("connect")&&this.formo.connect({chainId:this.chainId,address:i},{providerName:a,rdns:o}).catch(function(e){R.error("SolanaStoreHandler: Error emitting initial connect",e)}),this.restorable=this.formo.solanaAddress===i}}this.lastWalletStatus=n.status},e.prototype.handleWalletChange=function(e,t){if("connected"===t.status&&"connected"!==e.status&&this.handleDisconnect(),"connected"===e.status&&"connected"!==t.status)this.handleConnect(e);else if("connected"===e.status&&"connected"===t.status){var r=e.session.account.address!==t.session.account.address,n=e.connectorId!==t.connectorId;(r||n)&&(this.handleDisconnect(),this.handleConnect(e))}this.lastWalletStatus=e.status},e.prototype.handleConnect=function(e){var t,r,n,i=e.session.account.address;if(!(!i||eg(i))){var a=this.resolveCurrentChainId();this.lastAddress=i,this.lastChainId=a,R.info("SolanaStoreHandler: Wallet connected",{address:i,chainId:a,connector:e.connectorId});var o=(null==(t=e.session.connector)?void 0:t.name)||e.connectorId,s=ex(o);(null==(n=null==(r=this.beforeWalletConnect)?void 0:r.call(this,{address:i,chainId:a,rdns:s}))||n)&&this.formo.isAutocaptureEnabled("connect")&&this.formo.connect({chainId:a,address:i},{providerName:o,rdns:s}).catch(function(e){R.error("SolanaStoreHandler: Error emitting connect",e)}),this.restorable=this.formo.solanaAddress===i}},e.prototype.restorableConnection=function(){var e;if(this.lastAddress&&this.restorable)return{address:this.lastAddress,chainId:null!=(e=this.lastChainId)?e:this.chainId}},e.prototype.onReset=function(){this.restorable=!1},e.prototype.handleDisconnect=function(){var e,t,r=this;if(this.lastAddress){R.info("SolanaStoreHandler: Wallet disconnected",{address:this.lastAddress,chainId:this.lastChainId});var n={address:this.lastAddress,chainId:null!=(e=this.lastChainId)?e:this.chainId},i=this.formo.deferWalletRestore(n.chainId);this.formo.isAutocaptureEnabled("disconnect")?this.formo.disconnect(n).then(function(){var e;return null==(e=r.afterWalletDisconnect)?void 0:e.call(r,n,i,!0)},function(e){var t;R.error("SolanaStoreHandler: Error emitting disconnect",e),null==(t=r.afterWalletDisconnect)||t.call(r,n,i,!1)}):null==(t=this.afterWalletDisconnect)||t.call(this,n,i,!1),this.lastAddress=void 0,this.lastChainId=void 0}},e.prototype.setupClusterSubscription=function(){var e=this,t=this.store.getState().cluster.endpoint,r=this.store.subscribe(function(r){var n=r.cluster.endpoint;n!==t&&(t=n,e.handleClusterChange(n))});this.unsubscribers.push(r),R.info("SolanaStoreHandler: Cluster subscription set up")},e.prototype.handleClusterChange=function(e){if(!this.explicitCluster){var t,r=this.detectClusterFromEndpoint(e);if(r){var n=this.cluster;r!==n&&(this.cluster=r,this.chainId=ev[r],R.info("SolanaStoreHandler: Cluster changed",{from:n,to:r,chainId:this.chainId}),null==(t=this.onClusterChange)||t.call(this,r),this.applyCluster())}}},e.prototype.setupTransactionSubscription=function(){var e=this,t=this.store.getState().transactions,r=this.store.subscribe(function(r){var n=r.transactions;if(n!==t){var i=t;t=n,e.handleTransactionChanges(n,i)}});this.unsubscribers.push(r),R.info("SolanaStoreHandler: Transaction subscription set up")},e.prototype.handleTransactionChanges=function(e,t){for(var r,n=0,i=Object.entries(e);n<i.length;
2n++){var a=i[n],o=a[0],s=a[1],c=t[o];if(!c||c.status!==s.status){var u=this.lastAddress||(null==(r=this.transactionSenders.get(o))?void 0:r.address);u&&this.handleTransactionStatusChange(o,s,c,u)}}},e.prototype.handleTransactionStatusChange=function(e,t,r,n){var i=this.chainId,a="".concat(e,":").concat(t.status);if(!this.processedTransactions.has(a)&&(this.processedTransactions.add(a),rE(this.processedTransactions),this.formo.isAutocaptureEnabled("transaction")))switch(t.status){case"sending":this.startedTransactions.has(e)||(this.startedTransactions.add(e),rE(this.startedTransactions),this.transactionSenders.set(e,{address:n,chainId:i}),this.formo.transaction({status:s.STARTED,chainId:i,address:n}).catch(function(e){R.error("SolanaStoreHandler: Error emitting transaction STARTED",e)}));break;case"waiting":var o=t.signature;if(o){this.transactionSenders.has(e)||this.transactionSenders.set(e,{address:n,chainId:i});var c=this.transactionSenders.get(e);this.formo.transaction({status:s.BROADCASTED,chainId:c.chainId,address:c.address,transactionHash:o}).catch(function(e){R.error("SolanaStoreHandler: Error emitting transaction BROADCASTED",e)})}break;case"confirmed":var c=this.transactionSenders.get(e),u=(null==c?void 0:c.address)||n,l=(null==c?void 0:c.chainId)||i,o=t.signature;R.info("SolanaStoreHandler: Transaction confirmed",{key:e,signature:o}),this.formo.transaction(rw({status:s.CONFIRMED,chainId:l,address:u},o&&{transactionHash:o})).catch(function(e){R.error("SolanaStoreHandler: Error emitting transaction CONFIRMED",e)}),this.transactionSenders.delete(e);break;case"failed":var c=this.transactionSenders.get(e),u=(null==c?void 0:c.address)||n,l=(null==c?void 0:c.chainId)||i,o=t.signature,d=null==r?void 0:r.status,f="waiting"===d?s.REVERTED:s.REJECTED;R.info("SolanaStoreHandler: Transaction failed",{key:e,signature:o,status:f,prevStatus:d}),this.formo.transaction(rw({status:f,chainId:l,address:u},o&&{transactionHash:o})).catch(function(e){R.error("SolanaStoreHandler: Error emitting transaction event",e)}),this.transactionSenders.delete(e)}},e.prototype.detectClusterFromStore=function(e){try{var t=e.getState().cluster.endpoint;return this.detectClusterFromEndpoint(t)}catch(e){return null}},e.prototype.detectClusterFromEndpoint=function(e){if(!e)return null;var t=e.toLowerCase();return t.includes("devnet")?"devnet":t.includes("testnet")?"testnet":t.includes("localhost")||t.includes("127.0.0.1")?"localnet":t.includes("mainnet")?"mainnet-beta":null},e.prototype.cleanup=function(){R.debug("SolanaStoreHandler: Cleaning up");for(var e=0,t=this.unsubscribers;e<t.length;e++){var r=t[e];try{r()}catch(e){R.error("SolanaStoreHandler: Error during cleanup",e)}}this.unsubscribers=[],this.processedTransactions.clear(),this.startedTransactions.clear(),this.transactionSenders.clear(),this.lastAddress=void 0,this.lastChainId=void 0,R.debug("SolanaStoreHandler: Cleanup complete")},e}(),rx="wallet-standard:register-wallet",rA={"solana:mainnet":"mainnet-beta","solana:devnet":"devnet","solana:testnet":"testnet","solana:localnet":"localnet"};function rI(e){return"string"==typeof e&&e.startsWith("solana:")}function rT(e){for(var t=0;t<e.length;t++){var r=e[t];if(r&&"object"==typeof r){if((!Array.isArray(r.chains)||r.chains.some(rI))&&eb(r.address)&&!eg(r.address))return r}}}var rS=function(){function e(e,t){var r=this;this.deps=e,this.wallets=new Map,this.connectSeq=0,this.restorableFrom=0,this.isCleanedUp=!1,this.cluster=null==t?void 0:t.cluster,this.api=Object.freeze({register:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r.register.apply(r,e)}}),this.listen()}return e.prototype.listen=function(){var e=this;if("function"==typeof window.addEventListener){var t=function(t){var r=t.detail;if("function"==typeof r)try{r(e.api)}catch(e){R.warn("SolanaWalletStandardRegistry: A wallet threw while registering",e)}};try{window.addEventListener(rx,t),this.removeWindowListener=function(){return window.removeEventListener(rx,t)}}catch(e){R.warn("SolanaWalletStandardRegistry: Could not listen for wallet registrations",e)}if("function"==typeof CustomEvent)try{window.dispatchEvent(new CustomEvent("wallet-standard:app-ready",{detail:this.api}))}catch(e){R.warn("SolanaWalletStandardRegistry: Could not announce app-ready",e)}}},e.prototype.register=function(){for(var e=this,t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var n=[];if(this.isCleanedUp)return function(){};for(var i=0;i<t.length;i++){var a=function(e){if(e&&"object"==typeof e){if("string"==typeof e.name&&e.name&&Array.isArray(e.chains)&&e.chains.some(rI)&&e.features&&"object"==typeof e.features&&Array.isArray(e.accounts))return e}}(t[i]);if(!(!a||this.wallets.has(a))){var o={wallet:a,name:a.name,rdns:ex(a.name),connectWasReported:!1,attributed:!1};this.wallets.set(a,o),n.push(o),this.track(o)}}return function(){for(var t=0;t<n.length;t++){var r=n[t];e.untrack(r)}}},e.prototype.track=function(e){var t=this;R.info("SolanaWalletStandardRegistry: Discovered wallet",{name:e.name,chains:e.wallet.chains});var r=rT(e.wallet.accounts);r&&this.deps.ownsWalletEvents()&&this.deps.syncWalletState({chainId:this.chainIdFor(e),address:r.address}),this.deps.detect({providerName:e.name,rdns:e.rdns}).catch(function(e){R.error("SolanaWalletStandardRegistry: Error emitting detect",e)}
2);var n=e.wallet.features["standard:events"];if(n&&"function"==typeof n.on)try{e.unsubscribe=n.on("change",function(r){return t.onChange(e,r)})}catch(t){R.warn("SolanaWalletStandardRegistry: Could not subscribe to ".concat(e.name," events"),t)}else R.info("SolanaWalletStandardRegistry: ".concat(e.name," has no standard:events feature; connections cannot be observed"));this.reconcile(e,e.wallet.accounts)},e.prototype.untrack=function(e){var t;try{null==(t=e.unsubscribe)||t.call(e)}catch(t){R.warn("SolanaWalletStandardRegistry: Could not unsubscribe from ".concat(e.name),t)}e.unsubscribe=void 0,this.wallets.delete(e.wallet)},e.prototype.onChange=function(e,t){if(!this.isCleanedUp){var r=Array.isArray(null==t?void 0:t.accounts)?t.accounts:e.wallet.accounts;this.reconcile(e,Array.isArray(r)?r:[])}},e.prototype.reconcile=function(e,t){var r=rT(t),n=e.connected;if((n||r)&&(!n||!r||n.address!==r.address)){if(!this.deps.ownsWalletEvents()){n&&e.connectWasReported&&this.reportDisconnect(e,n),e.connected=r?{address:r.address,chainId:this.chainIdFor(e)}:void 0,r&&(e.connectedSeq=++this.connectSeq),e.connectWasReported=!1,e.attributed=!1;return}n&&this.reportDisconnect(e,n),r&&this.reportConnect(e,r.address)}},e.prototype.reportConnect=function(e,t){var r=this.chainIdFor(e);e.connected={address:t,chainId:r},e.connectedSeq=++this.connectSeq,e.connectWasReported=!1,R.info("SolanaWalletStandardRegistry: Wallet connected",{name:e.name,address:t,chainId:r}),this.deps.syncWalletState({chainId:r,address:t}),e.attributed=this.deps.solanaAddress()===t,!this.deps.isAutocaptureEnabled("connect")||this.deps.willTrackEvent(r)&&(e.connectWasReported=!0,this.deps.connect({chainId:r,address:t},{providerName:e.name,rdns:e.rdns}).catch(function(e){R.error("SolanaWalletStandardRegistry: Error emitting connect",e)}))},e.prototype.reportDisconnect=function(e,t){var r=this;if(e.connected=void 0,e.connectWasReported=!1,e.attributed=!1,R.info("SolanaWalletStandardRegistry: Wallet disconnected",{name:e.name,address:t.address,chainId:t.chainId}),!this.deps.isAutocaptureEnabled("disconnect")){var n=this.deps.solanaAddress();if(n&&n!==t.address)return;this.deps.syncWalletState({chainId:t.chainId});var i=this.newestConnection();i&&this.deps.restoreWalletState(i);return}var a=this.deps.solanaAddress(),o=this.deps.deferWalletRestore(t.chainId);this.deps.disconnect(t).then(function(){if(!r.deps.solanaAddress()){var e,n=a&&a!==t.address?r.connectionOf(a):null!=(e=r.connectionOf(t.address))?e:r.newestConnection(t.address);n&&o(n)}}).catch(function(e){R.error("SolanaWalletStandardRegistry: Error emitting disconnect",e)})},e.prototype.chainIdFor=function(e){if(this.cluster)return ev[this.cluster];var t=e.wallet.chains;if(t.includes("solana:mainnet"))return eE;for(var r=0;r<t.length;r++){var n=rA[t[r]];if(n)return ev[n]}return eE},e.prototype.setCluster=function(e){if(this.cluster!==e){this.cluster=e;for(var t,r,n=ev[e],i=Array.from(this.wallets.values()),a=null!=(t=this.deps.solanaAddress())?t:this.deps.currentAddress(),o=null!=(r=this.trackedOn(a))?r:this.newestTracked(),s=0;s<i.length;s++){var c=i[s],u=c.connected;if(u&&u.chainId!==n)c.connected={address:u.address,chainId:n},this.deps.ownsWalletEvents()&&(c===o&&this.deps.restoreWalletState({chainId:n,address:u.address}),this.deps.isAutocaptureEnabled("chain")&&this.deps.chain({chainId:n,address:u.address}).catch(function(e){R.error("SolanaWalletStandardRegistry: Error emitting chain event",e)}))}}},Object.defineProperty(e.prototype,"walletNames",{get:function(){return Array.from(this.wallets.values()).map(function(e){return e.name})},enumerable:!1,configurable:!0}),e.prototype.newestConnection=function(e){var t;return null==(t=this.newestTracked(e))?void 0:t.connected},e.prototype.connectionOf=function(e){var t;return null==(t=this.trackedOn(e))?void 0:t.connected},e.prototype.newestTracked=function(e){var t,r=this;return this.wallets.forEach(function(n){var i,a,o;r.isRestorable(n)&&(null==(i=n.connected)?void 0:i.address)!==e&&(null!=(a=n.connectedSeq)?a:0)>(null!=(o=null==t?void 0:t.connectedSeq)?o:-1)&&(t=n)}),t},e.prototype.trackedOn=function(e){var t;if(e)for(var r=0,n=Array.from(this.wallets.values());r<n.length;r++){var i=n[r];if(this.isRestorable(i)&&(null==(t=i.connected)?void 0:t.address)===e)return i}},e.prototype.isRestorable=function(e){var t;return!!e.connected&&e.attributed&&(null!=(t=e.connectedSeq)?t:0)>=this.restorableFrom},e.prototype.onReset=function(){this.restorableFrom=this.connectSeq+1},e.prototype.reportedConnectionRdns=function(e){for(var t,r=0,n=Array.from(this.wallets.values());r<n.length;r++){var i=n[r];if(i.connectWasReported&&(null==(t=i.connected)?void 0:t.address)===e)return i.rdns}},e.prototype.takeReportedConnection=function(e,t){for(var r,n=0,i=Array.from(this.wallets.values());n<i.length;n++){var a=i[n];if(a.connectWasReported&&(null==(r=a.connected)?void 0:r.address)===e&&a.rdns===t)return a.connectWasReported=!1,a.connected}},e.prototype.cleanup=function(){var e;this.isCleanedUp=!0;try{null==(e=this.removeWindowListener)||e.call(this)}catch(e){R.warn("SolanaWalletStandardRegistry: Could not remove window listener",e)}this.removeWindowListener=void 0;for(var t=0,r=Array.from(this.wallets.values());t<r.length;t++){var n=r[t];this.untrack(n)}this.wallets.clear(),R.debug("SolanaWalletStandardRegistry: Cleanup complete")},e}(),rC=function(){function e(e,t,r){void 0===r&&(r=!0);var n=this;if(this.formo=e,this.enabled=r,this.storeOwnsWalletEvents=!1,r){this.cluster=null==t?void 0:t.cluster;var i=null==t?void 0:t.cluster;(null==t?void 0:t.store)&&(R.info("SolanaManager: Initializing store-based Solana tracking"),this.attachStore(t.store,i),i||(i=ew[this.storeHandler.getChainId()])),this.registry=new rS({isAutocaptureEnabled:function(e){return n.formo.isAutocaptureEnabled(e)},willTrackEvent:function(e){return n.formo.willTrackEvent(e)},detect:function(e){return n.formo.detect(e)},connect:function(e,t){return n.formo.connect(e,t)},disconnect:function(e){var t=n.formo.deferWalletRestore(e.chainId);return n.formo.disconnect(e).then(function(){var e,r=null==(e=n.storeHandler)?void 0:e.restorableConnection();r&&!n.formo.solanaAddress&&t(r)})},chain:function(e){return n.formo.chain(e)},syncWalletState:function(e){if(n.formo.syncWalletState(e),!e.address){var t,r=null==(t=n.storeHandler)?void 0:t.restorableConnection();r&&!n.formo.solanaAddress&&n.formo.restoreWalletState(r)}},restoreWalletState:function(e){return n.formo.restoreWalletState(e)},deferWalletRestore:function(e){return n.formo.deferWalletRestore(e)},currentAddress:function(){return n.formo.currentAddress},solanaAddress:function(){return n.formo.solanaAddress},ownsWalletEvents:function(){return!n.storeOwnsWalletEvents}},{cluster:i})}}return e.prototype.attachStore=function(e,t){var r,n=this;this.storeHandler=new rP(this.formo,e,{cluster:t,onClusterChange:function(e){var t;return null==(t=n.registry)?void 0:t.setCluster(e)},afterWalletDisconnect:function(e,t,r){var i,a=n.formo.solanaAddress;if(!a||!r&&a===e.address){a&&n.formo.syncWalletState({chainId:e.chainId});var o=null==(i=n.registry)?void 0:i.newestConnection(e.address);o&&(r?t(o):n.formo.restoreWalletState(o))}},beforeWalletConnect:function(e){if(n.formo.syncWalletState({address:e.address,chainId:e.chainId}),n.storeOwnsWalletEvents)return!0;var t,r,i=null==(t=n.registry)?void 0:t.takeReportedConnection(e.address,e.rdns);if(n.storeOwnsWalletEvents=!0,!i){var a=null==(r=n.registry)?void 0:r.reportedConnectionRdns(e.address);return a&&R.warn("SolanaManager: Store connector does not match the discovered wallet; the connection is reported twice",{storeRdns:e.rdns,walletRdns:a}),!0}return i.chainId!==e.chainId&&n.formo.isAutocaptureEnabled("chain")&&n.formo.chain(e).catch(function(e){R.error("SolanaManager: Error c
2orrecting cluster during store handoff",e)}),!1}});var i=ew[this.storeHandler.getChainId()];i&&(null==(r=this.registry)||r.setCluster(i))},e.prototype.setStore=function(e,t){var r;this.enabled?(null==(r=this.storeHandler)||r.cleanup(),this.storeHandler=void 0,this.storeOwnsWalletEvents=!1,(null==t?void 0:t.cluster)&&(this.cluster=t.cluster),this.attachStore(e,this.cluster)):R.warn("SolanaManager: Ignoring setStore. Solana tracking is off for this instance (solana: false, or the SDK was cleaned up)")},e.prototype.setCluster=function(e){var t,r;this.enabled&&(this.cluster=e,null==(t=this.storeHandler)||t.setCluster(e),null==(r=this.registry)||r.setCluster(e))},e.prototype.onReset=function(){var e,t;null==(e=this.registry)||e.onReset(),null==(t=this.storeHandler)||t.onReset()},Object.defineProperty(e.prototype,"discoveredWallets",{get:function(){var e,t;return null!=(t=null==(e=this.registry)?void 0:e.walletNames)?t:[]},enumerable:!1,configurable:!0}),e.prototype.cleanup=function(){var e,t;null==(e=this.storeHandler)||e.cleanup(),this.storeHandler=void 0,this.storeOwnsWalletEvents=!1,null==(t=this.registry)||t.cleanup(),this.registry=void 0},e}(),rO=function(){return(rO=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},rj=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},rk=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)0>t.indexOf(n[i])&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r},rR=function(e,t,r){if(r||2==arguments.length)for(var n,i=0,a=t.length;i<a;i++)!n&&i in t||(n||(n=Array.prototype.slice.call(t,0,i)),n[i]=t[i]);return e.concat(n||Array.prototype.slice.call(t))},r_=/^0x[0-9a-f]{40}$/i;function rB(e,t){return r_.test(e)&&r_.test(t)?e.toLowerCase()===t.toLowerCase():e===t}var rM=function(){return(rM=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},rF=function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t)})).then(o,s)}c((n=n.apply(e,t||[])).next())})},rN=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},rU=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)0>t.indexOf(n[i])&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r},rH=function(){function e(e,t){void 0===t&&(t={});var r,n,i,a=this;if(this.writeKey=e,this.options=t,this._announcedConnect=new WeakMap,this.isWagmiMo
2de=!1,this.isEvmDisabled=!1,this._currentUrl="",this._pageHooksDisposed=!1,this._pageGeneration=0,this.currentUserId="",this.isCleanedUp=!1,this.config={writeKey:e},this.options=t,this.isWagmiMode=!!t.wagmi,this.isEvmDisabled=!1===t.evm,this.crossSubdomainCookies=null==(r=t.crossSubdomainCookies)||r,t.crossSubdomainCookies=this.crossSubdomainCookies,this.session=new tw,this.currentUserId=ee().get(v)||void 0,this.identify=this.identify.bind(this),this.connect=this.connect.bind(this),this.disconnect=this.disconnect.bind(this),this.chain=this.chain.bind(this),this.signature=this.signature.bind(this),this.transaction=this.transaction.bind(this),this.detect=this.detect.bind(this),this.track=this.track.bind(this),this.registerProvider=this.registerProvider.bind(this),this.page=this.page.bind(this),this.reset=this.reset.bind(this),this.cleanup=this.cleanup.bind(this),this.optOutTracking=this.optOutTracking.bind(this),this.optInTracking=this.optInTracking.bind(this),this.hasOptedOutTracking=this.hasOptedOutTracking.bind(this),this.isAutocaptureEnabled=this.isAutocaptureEnabled.bind(this),this.syncPrivyActiveChain=this.syncPrivyActiveChain.bind(this),this.isTrackingSuppressed=this.isTrackingSuppressed.bind(this),this.getTrackedProvidersCount=this.getTrackedProvidersCount.bind(this),this.getProviderState=this.getProviderState.bind(this),this.syncWalletState=this.syncWalletState.bind(this),k.init({enabled:(null==(n=t.logger)?void 0:n.enabled)||!1,enabledLevels:(null==(i=t.logger)?void 0:i.levels)||[]}),this.evm=new tN({activeProvider:function(){return a.wallet.provider},activeChainId:function(){return a.wallet.evmChainId},knownEvmAddress:function(){return a.wallet.evmAddress},onChainObserved:function(e,t){e===a.wallet.provider&&"evm"===a.wallet.activeNamespace&&a.wallet.evmChainId!==t&&a.wallet.set("evm",{chainId:t})}}),this.wallet=new tx({isPersistedIdentityPurgeRequired:function(){return a.trackingPolicy.isPersistedIdentityPurgeRequired()},isPageExcluded:function(){return a.trackingPolicy.isPageExcluded()},isTrackingSuppressed:function(){return a.trackingPolicy.isTrackingSuppressed()},crossSubdomainCookies:function(){return a.crossSubdomainCookies},providerChainId:function(e){return a.evm.chainIdOf(e)},onProviderDisplaced:function(e){return a.evmEvents.forgetAnnouncedConnect(e)}}),this.evmRequests=new t6(this.wallet,this.evm,{isAutocaptureEnabled:function(e){return a.isAutocaptureEnabled(e)},signature:function(e,t){return a.signature(e,t)},transaction:function(e,t){return a.transaction(e,t)},shouldSkipRequestCapture:function(e,t){var r,n;return null!=(n=null==(r=a.wagmiHandler)?void 0:r.hasMatchingPendingMutation(e,t))&&n}}),this.evmEvents=new tW(this.wallet,this.evm,{isAutocaptureEnabled:function(e){return a.isAutocaptureEnabled(e)},isTrackingSuppressed:function(){return a.isTrackingSuppressed()},willTrackEvent:function(e){return a.willTrackEvent(e)},retryDetection:function(){return a.retryWalletDetection()},isWagmiMode:function(){return a.isWagmiMode},connect:function(e,t){return a.connect(e,t)},disconnect:function(e){return a.disconnect(e)},chain:function(e,t){return a.chain(e,t)},detect:function(e){return a.detect(e)},registerRequestListeners:function(e){return a.evmRequests.registerRequestListeners(e)}}),this.trackingPolicy=new tE({options:function(){return a.options},hasOptedOut:function(){return a.hasOptedOutTracking()},currentChainId:function(){return a.currentChainId}}),this.eventManager=new e9(new tm(this.config.writeKey,{apiHost:t.apiHost||b,flushAt:t.flushAt,retryCount:t.retryCount,maxQueueSize:t.maxQueueSize,flushInterval:t.flushInterval,errorHandler:t.errorHandler,canSend:function(){return!a.hasOptedOutTracking()}}),t,function(){return!a.hasOptedOutTracking()}),this.hasOptedOutTracking()&&R.info("User has previously opted out of tracking"),this.isEvmDisabled)R.info("FormoAnalytics: EVM provider tracking disabled");else if(this.isWagmiMode&&t.wagmi)R.info("FormoAnalytics: Initializing in Wagmi mode"),this.wagmiHandler=new rv(this,t.wagmi.config,t.wagmi.queryClient);else{var o=void 0,s=t.provider;s?o=s:window.ethereum&&(o=window.ethereum),o&&this.evmEvents.trackEIP1193Provider(o)}this.wallet.load(),!1!==t.solana&&(this.solanaManager=new rC(this,"object"==typeof t.solana?t.solana:void 0)),this._currentUrl=window.location.href,this.trackPageHit(),this.trackPageHits()}return Object.defineProperty(e.prototype,"_provider",{get:function(){return this.wallet.provider},set:function(e){this.wallet.provider=e}
2,enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"_evmAddress",{get:function(){return this.wallet.evmAddress},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"_evmChainId",{get:function(){return this.wallet.evmChainId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentAddress",{get:function(){return this.wallet.address},set:function(e){this.wallet.setActiveAddress(e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentChainId",{get:function(){return this.wallet.chainId},set:function(e){this.wallet.setActiveChainId(e)},enumerable:!1,configurable:!0}),e.init=function(t,r){return rF(this,void 0,void 0,function(){var n,i,a;return rN(this,function(o){switch(o.label){case 0:if(Y(t),!(n=new e(t,r)).isEvmDisabled)return[3,1];return R.info("FormoAnalytics: Skipping provider detection (EVM disabled)"),[3,5];case 1:return o.trys.push([1,4,,5]),[4,n.evmEvents.getProviders()];case 2:return i=o.sent(),[4,n.evmEvents.detectWallets(i)];case 3:return o.sent(),n.isWagmiMode||n.evmEvents.trackProviders(i),[3,5];case 4:return a=o.sent(),R.warn("FormoAnalytics: Provider discovery failed",a),[3,5];case 5:return[2,n]}})})},e.prototype.page=function(e,t,r,n,i){return rF(this,void 0,void 0,function(){return rN(this,function(a){switch(a.label){case 0:return[4,this.trackPageHit(e,t,r,n,i)];case 1:return a.sent(),[2]}})})},e.prototype.reset=function(){var e;this.currentUserId=void 0,this.wallet.reset(),null==(e=this.solanaManager)||e.onReset(),ee().remove(v),ee().remove(tv),ee().remove(w)},Object.defineProperty(e.prototype,"disposed",{get:function(){return this.isCleanedUp},enumerable:!1,configurable:!0}),e.prototype.cleanup=function(){if(this.isCleanedUp=!0,R.debug("FormoAnalytics: Cleaning up resources"),this.eventManager.close(),this.evmRequests.cleanup(),this.evmEvents.cleanup(),this.wagmiHandler&&(this.wagmiHandler.cleanup(),this.wagmiHandler=void 0),this.solanaManager&&(this.solanaManager.cleanup(),this.solanaManager=void 0),!this.isWagmiMode)for(var e=0,t=this.evm.trackedProviders();e<t.length;e++){var r=t[e];this.evmEvents.untrackProvider(r)}this._pageHooksDisposed=!0,this._onPopStateListener&&(window.removeEventListener("popstate",this._onPopStateListener),this._onPopStateListener=void 0),this._onLocationChangeListener&&(window.removeEventListener("locationchange",this._onLocationChangeListener),this._onLocationChangeListener=void 0),R.debug("FormoAnalytics: Cleanup complete")},e.prototype.connect=function(e,t,n,i){return rF(this,arguments,void 0,function(e,t,n,i){var a,o=e.chainId,s=e.address;return rN(this,function(e){switch(e.label){case 0:if(null==o)return R.warn("Connect: Chain ID cannot be null or undefined"),[2,e8(i,{chainId:o,address:s},"invalid")];if(!s)return R.warn("Connect: Address cannot be empty"),[2,e8(i,{chainId:o,address:s},"invalid")];if(!(a=eC(s,o)))return R.warn('Connect: Invalid address provided ("'.concat(s,'"). Please provide a valid EVM or Solana address.')),[2,e8(i,{chainId:o,address:s},"invalid")];if(this.isTrackingSuppressed())return R.info("connect() skipped: tracking is suppressed for this visitor or environment"),e8(i,{chainId:o,address:s},"suppressed"),[2];return this.wallet.observe(this.wallet.namespaceOf(o)),this.setChainState(o,{address:a}),[4,this.trackEvent(r.CONNECT,{chainId:o,address:a},t,n,i)];case 1:return e.sent(),[2]}})})},e.prototype.disconnect=function(e,t,n,i){return rF(this,void 0,void 0,function(){var a,o,s,c,u,l;return rN(this,function(d){switch(d.label){case 0:return a=(null==e?void 0:e.chainId)||this.currentChainId,o=(null==e?void 0:e.address)||this.currentAddress,s=!eP(a)&&this._provider?this.getProviderInfo(this._provider):null,R.info("Disconnect: Emitting disconnect event with:",{chainId:a,address:o,providerName:null==s?void 0:s.name,rdns:null==s?void 0:s.rdns}),c=rM(rM({},s&&{providerName:s.name,rdns:s.rdns}),t),u=this.wallet.namespaceOf(a),this.wallet.beginDisconnect(u),l=this.wallet.snapshot(u),[4,this.trackEvent(r.DISCONNECT,rM(rM({},a&&{chainId:a}),o&&{address:o}),c,n,i)];case 1:if(d.sent(),!this.wallet.isUnchangedSince(u,l))return R.info("Disconnect: A new session claimed this namespace while the event was in flight; leaving its state intact"),[2];return this.clearChainState(a),R.info("Wallet disconnected: Cleared currentAddress, currentChainId, and provider"),[2]}})})},e.prototype.setChainState=function(e,t){this.wallet.set(e,t)},e.prototype.clearChainState=function(e){this.wallet.clear(e)},e.prototype.syncWalletState=function(e){this.wallet.syncWalletState(e),this.retryWalletDetection()},e.prototype.restoreWalletState=function(e){this.wallet.restore(e.chainId,e.address),this.retryWalletDetection()},e.prototype.deferWalletRestore=function(e){var t=this,r=this.wallet.deferRestore(e);return function(e){r(e),t.retryWalletDetection()}},Object.defineProperty(e.prototype,"solanaAddress",{get:function(){return this.wallet.solanaAddress}
2,enumerable:!1,configurable:!0}),e.prototype.retryWalletDetection=function(){this.isCleanedUp||this.evmEvents.detectWallets(this.evmEvents.detectableProviders())},e.prototype.clearActiveProvider=function(){this.wallet.clearProvider()},e.prototype.backfillActiveWallet=function(e,t,r){this.wallet.backfill(e,t,r)},e.prototype.clearStaleEvmWalletOnSwitchWhileSuppressed=function(e){this.wallet.clearStaleEvmWalletOnSwitchWhileSuppressed(e)},e.prototype.addProviderListener=function(e,t,r){this.evm.addListener(e,t,r)},e.prototype.removeProviderListeners=function(e){this.evm.removeListeners(e)},e.prototype.getProviderInfo=function(e){return this.evm.infoFor(e)},e.prototype.isProviderAlreadyWrapped=function(e,t){return this.evm.isWrapped(e,t)},e.prototype.resolveChainIdForProvider=function(e){return this.evm.resolveChainId(e)},e.prototype.rememberProviderChain=function(e,t){this.evm.rememberChain(e,t)},e.prototype.getAddress=function(e){return rF(this,void 0,void 0,function(){return rN(this,function(t){return[2,this.evm.addressOf(e)]})})},e.prototype.getAccounts=function(e){return rF(this,void 0,void 0,function(){return rN(this,function(t){return[2,this.evm.accountsOf(e)]})})},e.prototype.chain=function(e,t,n,i){return rF(this,arguments,void 0,function(e,t,n,i){var a=e.chainId,o=e.address;return rN(this,function(e){switch(e.label){case 0:if(!a||0===Number(a))return R.warn("FormoAnalytics::chain: chainId cannot be empty or 0"),[2,e8(i,{chainId:a,address:o},"invalid")];if(isNaN(Number(a)))return R.warn("FormoAnalytics::chain: chainId must be a valid decimal number"),[2,e8(i,{chainId:a,address:o},"invalid")];if(!o&&!this.currentAddress)return R.warn("FormoAnalytics::chain: address was empty and no previous address has been recorded"),[2,e8(i,{chainId:a,address:o},"invalid")];return this.setChainState(a,{}),[4,this.trackEvent(r.CHAIN,{chainId:a,address:o||this.currentAddress},t,n,i)];case 1:return e.sent(),[2]}})})},e.prototype.signature=function(e,t,n,i){return rF(this,arguments,void 0,function(e,t,n,i){var a=e.status,o=e.chainId,s=e.address,c=e.message;return rN(this,function(e){switch(e.label){case 0:return[4,this.trackEvent(r.SIGNATURE,{status:a,chainId:o,address:s,message:c},t,n,i)];case 1:return e.sent(),[2]}})})},e.prototype.transaction=function(e,t,n,i){return rF(this,arguments,void 0,function(e,t,n,i){var a=e.status,o=e.chainId,s=e.address,c=e.data,u=e.to,l=e.value,d=e.transactionHash,f=e.function_name,p=e.function_args;return rN(this,function(e){switch(e.label){case 0:return[4,this.trackEvent(r.TRANSACTION,rM(rM(rM({status:a,chainId:o,address:s,data:c,to:u,value:l},d&&{transactionHash:d}),f&&{function_name:f}),p&&{function_args:p}),t,n,i)];case 1:return e.sent(),[2]}})})},e.prototype.identify=function(e,t,n,i){return rF(this,void 0,void 0,function(){var a,o,s,c,u,l,d,f,p,h,m,b,y,g,w,E,P,x,A,I,T,S;return rN(this,function(C){switch(C.label){case 0:if(C.trys.push([0,14,,15]),!((a=e)&&"string"==typeof a.id&&void 0===a.address))return[3,2];return[4,function(e,t){var r,n,i,a;return r=this,n=arguments,i=void 0,a=function(e,t,r){var n,i,a,o,s,c,u,l,d,f,p,h,m,b,y;return void 0===r&&(r={}),rj(this,function(g){switch(g.label){case 0:if(!e||!t||(null==(h=(n=e).isTrackingSuppressed)?void 0:h.call(n)))return[2,void 0];if(a=(i=function(e){var t,r,n,i,a,o,s,c,u,l,d,f,p,h,m,b,y,g,v=e.linkedAccounts||[],w={privyDid:e.id,privyCreatedAt:function(e){if(e instanceof Date){var t=e.getTime();return Number.isNaN(t)?void 0:t}if("number"==typeof e){if(!Number.isFinite(e))return;return e<1e11?1e3*e:e}if("string"==typeof e){var r=Date.parse(e);return Number.isNaN(r)?void 0:r}}(e.createdAt)};if((null==(t=e.email)?void 0:t.address)&&(w.email=e.email.address),(null==(r=e.phone)?void 0:r.number)&&(w.phone=e.phone.number),(null==(n=e.apple)?void 0:n.email)&&(w.apple=e.apple.email),(null==(i=e.discord)?void 0:i.username)&&(w.discord=e.discord.username),(null==(a=e.farcaster)?void 0:a.username)&&(w.farcaster=e.farcaster.username),(null==(o=e.github)?void 0:o.username)&&(w.github=e.github.username),(null==(s=e.google)?void 0:s.email)&&(w.google=e.google.email),(null==(c=e.instagram)?void 0:c.username)&&(w.instagram=e.instagram.username),(null==(u=e.line)?void 0:u.email)&&(w.line=e.line.email),(null==(l=e.linkedin)?void 0:l.email)&&(w.linkedin=e.linkedin.email),(null==(d=e.spotify)?void 0:d.email)&&(w.spotify=e.spotify.email),(null==(f=e.telegram)?void 0:f.username)&&(w.telegram=e.telegram.username),(null==(p=e.tiktok)?void 0:p.username)&&(w.tiktok=e.tiktok.username),(null==(h=e.twitch)?void 0:h.username)&&(w.twitch=e.twitch.username),(null==(m=e.twitter)?void 0:m.username)&&(w.twitter=e.twitter.username),!w.email){var E=v.find(function(e){return"email"===e.type});(null==E?void 0:E.address)&&(w.email=E.address)}if(!w.phone){var P=v.find(function(e){return"phone"===e.type});(null==P?void 0:P.number)&&(w.phone=P.number)}if(!w.apple){var x=v.find(function(e){return"apple_oauth"===e.type});(null==x?void 0:x.email)&&(w.apple=x.email)}if(!w.discord){var A=v.find(function(e){return"discord_oauth"===e.type});(null==A?void 0:A.username)&&(w.discord=A.username)}if(!w.farcaster){var I=v.find(function(e){return"farcaster"===e.type});(null==I?void 0:I.username)?w.farcaster=I.username:(null==I?void 0:I.displayName)&&(w.farcaster=I.displayName)}if(!w.github){var T=v.find(function(e){return"github_oauth"===e.type});(null==T?void 0:T.username)&&(w.github=T.username)}if(!w.google){var S=v.find(function(e){return"google_oauth"===e.type});(null==S?void 0:S.email)&&(w.google=S.email)}
2if(!w.instagram){var C=v.find(function(e){return"instagram_oauth"===e.type});(null==C?void 0:C.username)&&(w.instagram=C.username)}if(!w.line){var O=v.find(function(e){return"line_oauth"===e.type});(null==O?void 0:O.email)&&(w.line=O.email)}if(!w.linkedin){var j=v.find(function(e){return"linkedin_oauth"===e.type});(null==j?void 0:j.email)&&(w.linkedin=j.email)}if(!w.spotify){var k=v.find(function(e){return"spotify_oauth"===e.type});(null==k?void 0:k.email)&&(w.spotify=k.email)}if(!w.telegram){var R=v.find(function(e){return"telegram"===e.type});(null==R?void 0:R.username)?w.telegram=R.username:(null==R?void 0:R.telegramUserId)&&(w.telegram=R.telegramUserId)}if(!w.tiktok){var _=v.find(function(e){return"tiktok_oauth"===e.type});(null==_?void 0:_.username)&&(w.tiktok=_.username)}if(!w.twitch){var B=v.find(function(e){return"twitch_oauth"===e.type});(null==B?void 0:B.username)?w.twitch=B.username:(null==B?void 0:B.email)&&(w.twitch=B.email)}if(!w.twitter){var M=v.find(function(e){return"twitter_oauth"===e.type});(null==M?void 0:M.username)&&(w.twitter=M.username)}var F=v.find(function(e){return"custom_auth"===e.type});(null==F?void 0:F.customUserId)&&(w.customUserId=F.customUserId),!w.email&&(w.google?w.email=w.google:w.apple?w.email=w.apple:w.linkedin&&(w.email=w.linkedin));for(var N=[],U=0;U<v.length;U++){var H=v[U];if(("wallet"===H.type||"smart_wallet"===H.type)&&H.address){N.push({address:H.address,walletClient:null!=(b=H.walletClientType||H.walletClient)?b:void 0,chainType:null!=(y=H.chainType)?y:void 0,isEmbedded:"privy"===H.walletClientType||"privy"===H.walletClient});continue}if("cross_app"===H.type)for(var z=rR(rR([],H.embeddedWallets||[],!0),H.smartWallets||[],!0),L=0;L<z.length;L++){var D=z[L];(null==D?void 0:D.address)&&N.push({address:D.address,walletClient:"cross_app",chainType:null!=(g=D.chainType)?g:void 0,isEmbedded:!0,fromCrossApp:!0})}}for(var $=new Map,q=[],W=0;W<N.length;W++){var G=N[W],K=r_.test(G.address)?G.address.toLowerCase():G.address,V=$.get(K);if(void 0===V){$.set(K,q.length),q.push(G);continue}!G.fromCrossApp&&q[V].fromCrossApp&&(q[V]=G)}return{properties:w,wallets:q.map(function(e){return e.fromCrossApp,rk(e,["fromCrossApp"])})}}(t)).properties,0===(o=i.wallets).length)return R.info("identifyPrivyUser: user has no linked wallets; nothing to identify",t.id),[2,void 0];s=rO(rO({},a),r.properties),c=function(e,t,r){if(t)return e.find(function(e){return rB(e.address,t)});if(r){var n=e.find(function(e){return rB(e.address,r)});if(n)return n}var i=e.filter(function(e){return!e.isEmbedded});return i.length>0?i[i.length-1]:e[e.length-1]}(o,null!=(m=r.activeAddress)?m:n.currentAddress,null==(b=t.wallet)?void 0:b.address),null==(y=n.syncPrivyActiveChain)||y.call(n,null==c?void 0:c.chainType,null==c?void 0:c.address),u=n.identify.bind(e),l=0,d=o,g.label=1;case 1:if(!(l<d.length))return[3,4];return f=d[l],p=rO(rO({},s),{is_embedded:f.isEmbedded}),f.walletClient&&(p.wallet_client=f.walletClient),f.chainType&&(p.chain_type=f.chainType),[4,u({address:f.address,userId:t.id,setActive:f===c},p)];case 2:g.sent(),g.label=3;case 3:return l++,[3,1];case 4:return[2,c?{address:c.address,chainType:c.chainType}:void 0]}})},new(i||(i=Promise))(function(e,t){function o(e){try{c(a.next(e))}catch(e){t(e)}}function s(e){try{c(a.throw(e))}catch(e){t(e)}}function c(t){var r;t.done?e(t.value):((r=t.value)instanceof i?r:new i(function(e){e(r)})).then(o,s)}c((a=a.apply(r,n||[])).next())})}(this,a,{activeAddress:(o=null!=t?t:{}).activeAddress,properties:o.properties})];case 1:return C.sent(),[2];case 2:if(s=e,c=t,this.isTrackingSuppressed()||this.trackingPolicy.isChainExcluded())return R.info("identify() skipped: tracking is suppressed for this visitor, environment, or chain"),e8(i,e,"suppressed"),[2];if(s)return[3,12];if(this.isWagmiMode)return R.info("identify() without params is a no-op in Wagmi mode"),[2];R.info("Auto-identifying with providers:",this.evm.all.map(function(e){return e.info.name})),u=0,l=this.evm.all,C.label=3;case 3:if(!(u<l.length))return[3,11];if(!(f=(d=l[u]).provider))return[3,10];C.label=4;case 4:return C.trys.push([4,9,,10]),[4,this.getAddress(f)];case 5:if(!(p=C.sent()))return[3,8];if(h=eS(p),R.info("Auto-identify: Checking deduplication",{validAddress:h,rdns:d.info.rdns,providerName:d.info.name,isAlreadyIdentified:!!h&&this.session.isWalletIdentified(h,d.info.rdns,void 0,c)}),!(h&&!this.session.isWalletIdentified(h,d.info.rdns,void 0,c)))return[3,7];return R.info("Auto-identifying",h,d.info.name,d.info.rdns),[4,this.identify({address:h,providerName:d.info.name,rdns:d.info.rdns},c,n,i)];case 6:return C.sent(),[3,8];case 7:h&&R.info("Auto-identify: Skipping already identified wallet",h,d.info.name,d.info.rdns),C.label=8;case 8:return[3,10];
2case 9:return m=C.sent(),R.error("Failed to identify provider ".concat(d.info.name,":"),m),[3,10];case 10:return u++,[3,3];case 11:case 15:return[2];case 12:if(b=s.address,y=s.providerName,g=s.userId,w=s.rdns,E=s.setActive,!b)return null==(T=R.warn)||T.call(R,"identify() called without address - address is required"),[2,e8(i,e,"invalid")];if(R.info("Identify",b,g,y,w),!(P=eC(b)))return null==(S=R.warn)||S.call(R,"Invalid address provided to identify:",b),[2,e8(i,e,"invalid")];if(!1!==E&&(this.wallet.setActiveAddress(P),g&&(this.currentUserId=g,x=en(this.crossSubdomainCookies),ee().set(v,g,rM(rM({path:"/"},ei()),x?{domain:x}:{})))),A=this.session.isWalletIdentified(P,w||"",g,c),R.debug("Identify: Checking deduplication",{validAddress:P,rdns:w,providerName:y,userId:g,isAlreadyIdentified:A}),A)return R.info("Identify: Wallet ".concat(y||"Unknown"," with address ").concat(P," already identified in this session (rdns: ").concat(w||"empty",")")),e8(i,e,"duplicate"),[2];return this.session.markWalletIdentified(P,w||"",g,c),[4,this.trackEvent(r.IDENTIFY,{address:P,providerName:y,userId:g,rdns:w},c,n,i)];case 13:return C.sent(),[3,15];case 14:return I=C.sent(),R.log("identify error",I),[3,15]}})})},e.prototype.syncPrivyActiveChain=function(e,t){if(void 0!==this.currentChainId&&null!==this.currentChainId){var r,n=null==e?void 0:e.toLowerCase();"solana"===n?r=!0:"ethereum"===n?r=!1:!n&&t&&/^0x[0-9a-f]{40}$/i.test(t)&&(r=!1),void 0!==r&&r!==eP(this.currentChainId)&&this.wallet.setActiveChainId(void 0)}},e.prototype.detect=function(e,t,n,i){return rF(this,arguments,void 0,function(e,t,n,i){var a=e.providerName,o=e.rdns;return rN(this,function(e){switch(e.label){case 0:if(!this.shouldTrack())return R.info("detect() skipped: tracking is suppressed for this visitor or environment"),e8(i,{providerName:a,rdns:o},"suppressed"),[2];if(this.session.isWalletDetected(o))return R.warn("Detect: Wallet ".concat(a," already detected in this session")),e8(i,{providerName:a,rdns:o},"duplicate"),[2];return this.session.markWalletDetected(o),[4,this.trackEvent(r.DETECT,{providerName:a,rdns:o},t,n,i)];case 1:return e.sent(),[2]}})})},e.prototype.track=function(e,t,n,i){return rF(this,void 0,void 0,function(){var a,o,s,c;return rN(this,function(u){switch(u.label){case 0:try{if(t&&Object.prototype.hasOwnProperty.call(t,O))if(c=(o=t)[s=O],t=rU(o,["symbol"==typeof s?s:s+""]),null==c);else if("string"==typeof c&&c.trim().length>0)a=c;else{if(!("number"==typeof c&&Number.isSafeInteger(c)))return R.warn("FormoAnalytics::track: ".concat(O," must be a non-empty string or safe integer")),e8(i,{event:e,properties:t},"invalid_key"),[2];a=String(c)}}catch(e){return R.error("Error tracking event:",e),[2]}return[4,this.trackEvent(r.TRACK,{event:e,idempotencyKey:a},t,n,i)];case 1:return u.sent(),[2]}})})},e.prototype.willTrackEvent=function(e){return this.shouldTrack(e)},e.prototype.optOutTracking=function(){R.info("Opting out of tracking"),function(e,t,r){var n;if("u">typeof document){var i=tb(e,t),a=new Date(Date.now()+31536e6).toUTCString(),o=(null==(n=null==window?void 0:window.location)?void 0:n.protocol)==="https:",s=D();s&&(document.cookie="".concat(i,"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;")),document.cookie="".concat(i,"=").concat(encodeURIComponent(r),"; expires=").concat(a,"; path=/").concat(s?"; domain=.".concat(s):"","; SameSite=Strict").concat(o?"; Secure":"")}}(this.writeKey,P,"true"),this._pageGeneration++,this.eventManager.clear(),this.evmEvents.markRegisteredAdoptionsPending(),this.reset(),eW(E),ee().remove(tg),ee().remove(tv),er().remove(g),R.info("Successfully opted out of tracking")},e.prototype.optInTracking=function(){var e,t=this;setTimeout(function(){if(!t.isCleanedUp)try{t.evmEvents.retryExternalAdoptions()}catch(e){}},0),R.info("Opting back into tracking"),function(e){if("u">typeof document){document.cookie="".concat(e,"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;");var t=D();t&&(document.cookie="".concat(e,"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/; domain=.").concat(t,";"))}}(tb(this.writeKey,P)),null==(e=this.wagmiHandler)||e.retryAdoption(),this.retryWalletDetection(),R.info("Successfully opted back into tracking")},e.prototype.hasOptedOutTracking=function(){return"true"===function(e,t){if("u"<typeof document)return null;for(var r=tb(e,t),n=document.cookie.split(";"),i=0;i<n.length;i++){var a=n[i].trim(),o=a.indexOf("=");if(-1!==o){var s=a.substring(0,o),c=a.substring(o+1);if(s===r)return decodeURIComponent(c||"")}}return null}(this.writeKey,P)},e.prototype.onLocationChange=function(){return rF(this,void 0,void 0,function(){var e;return rN(this,function(t){return this._currentUrl!==window.location.href&&(this._currentUrl=window.location.href,null==(e=this.wagmiHandler)||e.retryAdoption(),this.trackPageHit()),[2]})})},e.prototype.trackPageHits=function(){var t=this;e.installHistoryHooksOnce(),this._onPopStateListener=function(){return t.onLocationChange()},this._onLocationChangeListener=function(){return t.onLocationChange()},window.addEventListener("popstate",this._onPopStateListener),window.addEventListener("locationchange",this._onLocationChangeListener)},e.installHistoryHooksOnce=function(){if(!("u"<typeof history)){var e=Symbol.for("formo.historyWrapped");
2if(!history[e]){history[e]=!0;var t=function(){return window.dispatchEvent(new window.Event("locationchange"))},r=history.pushState;history.pushState=function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var i=r.apply(this,e);return t(),i};var n=history.replaceState;history.replaceState=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var i=n.apply(this,e);return t(),i}}}},e.prototype.trackPageHit=function(e,t,n,i,a){return rF(this,void 0,void 0,function(){var o,s,c=this;return rN(this,function(u){if(o=this.shouldTrack(),!this.isCleanedUp&&o)try{this.evmEvents.retryExternalAdoptions(),this.retryWalletDetection()}catch(e){}return o?(s=this._pageGeneration,setTimeout(function(){c._pageHooksDisposed||s!==c._pageGeneration||rF(c,void 0,void 0,function(){var o;return rN(this,function(s){switch(s.label){case 0:return s.trys.push([0,2,,3]),[4,this.trackEvent(r.PAGE,{category:e,name:t},n,i,a)];case 1:return s.sent(),[3,3];case 2:return o=s.sent(),R.error("Formo: Failed to track page hit",o),[3,3];case 3:return[2]}})})},300)):R.info("Track page hit: Skipping event due to tracking configuration"),[2]})})},e.prototype.trackEvent=function(e,t,r,n,i){return rF(this,void 0,void 0,function(){var a;return rN(this,function(o){switch(o.label){case 0:if(o.trys.push([0,2,,3]),!this.shouldTrack(null==t?void 0:t.chainId))return R.info("Skipping ".concat(e," event due to tracking configuration")),e8(i,t,"suppressed"),[2];return[4,this.eventManager.addEvent(rM(rM({type:e},t),{properties:r,context:n,callback:i}),this.currentAddress,this.currentUserId)];case 1:return o.sent(),[3,3];case 2:return a=o.sent(),R.error("Error tracking event:",a),[3,3];case 3:return[2]}})})},e.prototype.isTrackingSuppressed=function(){return this.trackingPolicy.isTrackingSuppressed()},e.prototype.shouldTrack=function(e){return this.trackingPolicy.shouldTrack({chainId:e})},e.prototype.isAutocaptureEnabled=function(e){return this.trackingPolicy.isAutocaptureEnabled(e)},Object.defineProperty(e.prototype,"providers",{get:function(){return this.evm.all},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"provider",{get:function(){return this._provider},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"solana",{get:function(){return this.solanaManager||(this.solanaManager=new rC(this,void 0,!1)),this.solanaManager},enumerable:!1,configurable:!0}),e.prototype.getCurrentChainId=function(e){return rF(this,void 0,void 0,function(){var t,r,n;return rN(this,function(i){switch(i.label){case 0:if(!(t=e||this.provider))return R.error("Provider not set for chain ID"),[2,0];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,t.request({method:"eth_chainId"})];case 2:if(!(r=i.sent()))return R.info("Chain id not found"),[2,0];return[2,tH(r)];case 3:return n=i.sent(),R.error("eth_chainId threw an error:",n),[2,0];case 4:return[2]}})})},e.prototype._wrapWagmiProvider=function(e,t,r){if(this.isCleanedUp||!tj(e))return!1;try{if(!this.evmRequests.registerRequestListeners(e))return!1;return this.evm.rememberAttribution(e,r),void 0!==t&&this.evm.rememberChain(e,t),!0}catch(e){return R.warn("Failed to wrap wagmi provider for hybrid capture",e),!1}},e.prototype._rememberWagmiProviderChain=function(e,t){if(!this.isCleanedUp)try{this.evm.rememberChain(e,t)}catch(e){}},e.prototype.registerProvider=function(t,r){if(this.isCleanedUp)return R.warn("registerProvider: instance is cleaned up; refusing"),!1;if(this.isEvmDisabled)return R.warn("registerProvider: EVM tracking is disabled; refusing"),!1;if(this.isWagmiMode)return R.warn("registerProvider: wagmi mode tracks connectors already; registering the provider here would double-report its events. Refusing."),!1;if(!tj(t))return R.warn("registerProvider: not a valid EIP-1193 provider; refusing"),!1;var n,i,a,o=tS(t),s=tO(t),c=null!=(n=null==r?void 0:r.rdns)?n:s&&"io.injected.provider"===o.rdns?"com.walletconnect":o.rdns,u=null!=(i=null==r?void 0:r.name)?i:s?"WalletConnect":o.name,l="u">typeof crypto&&"function"==typeof crypto.randomUUID?crypto.randomUUID():"registered-".concat(c.replace(/[^a-zA-Z0-9]/g,"-"),"-").concat(e.registeredProviderSeq+=1);return this.evmEvents.adoptExternalProvider({info:{name:u,rdns:c,uuid:l,icon:null!=(a=null==r?void 0:r.icon)?a:o.icon},provider:t})},e.prototype.getTrackedProvidersCount=function(){return this.evm.counts.trackedProviders},e.prototype.getProviderState=function(){return rM(rM({},this.evm.counts),{activeProvider:!!this._provider})},e.registeredProviderSeq=0,e}(),rz=Symbol.for("formo.live"),rL=Symbol("formofy.superseded"),rD=function(){var e,t=window,r=t[rz];if(r&&"managed"in r)return r;var n={live:null!=r?r:null,managed:new WeakSet};
2if((null==(e=n.live)?void 0:e.instance)&&n.managed.add(n.live.instance),n.live&&!n.live.instance){var i=n.live;i.promise.then(function(e){i.instance=e,n.managed.add(e)}).catch(function(){n.live===i&&(n.live=null)})}return t[rz]=n,n},r$=function(){return rD().live},rq=function(e){rD().live=e},rW=function(e){rD().managed.add(e)};function rG(e,t,r){var n={writeKey:e};r&&!r.instance?n.promise=r.promise.then(function(e){return rV(e)}).catch(function(){}).then(function(){if(r$()!==n)return Promise.reject(rL);var r=rK();return r&&!rD().managed.has(r.instance)?(rW(r.instance),rq(r),r.writeKey===e&&rQ(t,r.instance),Promise.reject(rL)):rH.init(e,t)}):((null==r?void 0:r.instance)&&rV(r.instance),n.promise=rH.init(e,t));var i=n.promise;rq(n),i.then(function(r){if(n.instance=r,rW(r),r$()!==n)return void rV(r);var i=rK();if(i&&i.instance!==r&&!rD().managed.has(i.instance)){rV(r),rW(i.instance),rq(i),i.writeKey===e&&rQ(t,i.instance);return}window.formo=r,rQ(t,r)}).catch(function(e){e!==rL&&(r$()===n&&rq(null),console.error("Error initializing FormoAnalytics:",e))})}function rK(){var e=window.formo;return e&&"string"==typeof e.writeKey?rJ(e)?(rZ(e),null):{writeKey:e.writeKey,promise:Promise.resolve(e),instance:e}:null}function rV(e){rJ(e)||e.cleanup(),rZ(e)}function rJ(e){return!0===e.disposed}function rZ(e){window.formo===e&&delete window.formo}function rQ(e,t){if(null==e?void 0:e.ready)try{e.ready(t)}catch(e){console.error("Error in FormoAnalytics ready callback:",e)}}window.formofy=function(e,t){if(!e)return void console.warn("FormoAnalytics not found");var r,n,i=(r=r$(),n=rK(),r?n&&n.instance!==r.instance&&!rD().managed.has(n.instance)?(r.instance&&rV(r.instance),rW(n.instance),rq(n),n):r:(n&&rW(n.instance),n));if(!i||i.writeKey!==e)return void rG(e,t,i);if(rq(i),i.instance&&!rJ(i.instance)){window.formo||(window.formo=i.instance),rQ(t,i.instance);return}i.promise.then(function(r){if(!rJ(r)){window.formo||(window.formo=r),rQ(t,r);return}var n=r$();if(n!==i){n&&n.writeKey===e&&n.promise.then(function(e){r$()!==n||rJ(e)||rQ(t,e)}).catch(function(){});return}rZ(r),rG(e,t,null)}
2).catch(function(){})},e.s([],895104);var rY=e.i(500824),rX=e.i(767281),r0=function(){return(r0=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},r1=function(e,t){var r,n,i,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return o.next=s(0),o.throw=s(1),o.return=s(2),"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(s){return function(c){var u=[s,c];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(a=0)),a;)try{if(r=1,n&&(i=2&u[0]?n.return:u[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,u[1])).done)return i;switch(n=0,i&&(u=[2&u[0],i.value]),u[0]){case 0:case 1:i=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===u[0]||2===u[0])){a=0;continue}if(3===u[0]&&(!i||u[1]>i[0]&&u[1]<i[3])){a.label=u[1];break}if(6===u[0]&&a.label<i[1]){a.label=i[1],i=u;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(u);break}i[2]&&a.ops.pop(),a.trys.pop();continue}u=t.call(e,a)}catch(e){u=[6,e],n=0}finally{r=i=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}},r6={chain:function(){return Promise.resolve()},page:function(){return Promise.resolve()},reset:function(){},cleanup:function(){},registerProvider:function(){return!1},detect:function(){return Promise.resolve()},connect:function(){return Promise.resolve()},disconnect:function(){return Promise.resolve()},signature:function(){return Promise.resolve()},transaction:function(){return Promise.resolve()},identify:function(){return Promise.resolve()},track:function(){return Promise.resolve()},optOutTracking:function(){},optInTracking:function(){},hasOptedOutTracking:function(){return!1}},r5=(0,rX.createContext)(r6),r2=new WeakMap,r8=1,r3=function(e){if(e){var t=r2.get(e);return void 0===t&&(t=r8++,r2.set(e,t)),t}},r4=function(e){if(!e)return"undefined";var t,r={tracking:e.tracking,autocapture:e.autocapture,crossSubdomainCookies:e.crossSubdomainCookies,apiHost:e.apiHost,flushAt:e.flushAt,flushInterval:e.flushInterval,retryCount:e.retryCount,maxQueueSize:e.maxQueueSize,logger:e.logger,referral:e.referral,evm:e.evm,solana:"object"==typeof e.solana?void 0:e.solana,solanaStoreId:"object"==typeof e.solana?r3(e.solana.store):void 0,solanaCluster:"object"==typeof e.solana?e.solana.cluster:void 0,hasProvider:!!e.provider,hasWagmi:!!e.wagmi,wagmiEip1193Fallback:!!(null==(t=e.wagmi)?void 0:t.eip1193Fallback),hasReady:!!e.ready};try{return JSON.stringify(r)}catch(e){return R.warn("Failed to serialize options, using timestamp",e),Date.now().toString()}},r9=function(e){var t=e.writeKey,r=e.options,n=e.children,i=(0,rX.useState)(r6),a=i[0],o=i[1],s=(0,rX.useRef)(r6);Y(t);var c=(0,rX.useMemo)(function(){return r4(r)},[r]);return(0,rX.useEffect)(function(){var e,n,i,a,c=!1;return e=void 0,n=void 0,i=void 0,a=function(){var e,n;return r1(this,function(i){switch(i.label){case 0:s.current&&s.current!==r6&&(R.log("Cleaning up existing FormoAnalytics SDK instance before re-initialization"),s.current.cleanup(),s.current=r6,o(r6)),i.label=1;case 1:return i.trys.push([1,3,,4]),[4,rH.init(t,r)];case 2:return e=i.sent(),c?(R.log("Component unmounted during initialization, cleaning up SDK"),e.cleanup()):(o(e),s.current=e,R.log("Successfully initialized FormoAnalytics SDK")),[3,4];case 3:return n=i.sent(),c||R.error("Failed to initialize FormoAnalytics SDK",n),[3,4];case 4:return[2]}})},new(i||(i=Promise))(function(t,r){function o(e){try{c(a.next(e))}catch(e){r(e)}}function s(e){try{c(a.throw(e))}catch(e){r(e)}}function c(e){var r;e.done?t(e.value):((r=e.value)instanceof i?r:new i(function(e){e(r)})).then(o,s)}c((a=a.apply(e,n||[])).next())}),function(){c=!0,s.current&&s.current!==r6&&(R.log("Cleaning up FormoAnalytics SDK instance"),s.current.cleanup(),s.current=r6)}},[t,c]),(0,rY.jsx)(r5.Provider,{value:a,children:n})};e.s(["FormoAnalyticsProvider",0,function(e){var t=e.writeKey,r=e.disabled,n=e.children;return t?void 0!==r&&r?(R.warn("FormoAnalytics is disabled"),(0,rY.jsx)(rY.Fragment,{children:n})):(0,rY.jsx)(r9,r0({},e)):(R.error("FormoAnalyticsProvider: No Write Key provided"),(0,rY.jsx)(rY.Fragment,{children:n}))},"useFormo",0,function(){var e=(0,rX.useContext)(r5);return e||R.warn("useFormo called without a valid context"),e}],342330)},566697,(e,t,r)=>{"use strict";
2Object.defineProperty(r,"__esModule",{value:!0}),r.keccak256=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{as:r="string"==typeof e?"Hex":"Bytes"}=t,n=(0,a.keccak_256)(s.from(e));return"Bytes"===r?n:c.fromBytes(n)},r.hmac256=function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{as:i="string"==typeof t?"Hex":"Bytes"}=r,a=(0,n.hmac)(o.sha256,s.from(e),s.from(t));return"Bytes"===i?a:c.fromBytes(a)},r.ripemd160=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{as:r="string"==typeof e?"Hex":"Bytes"}=t,n=(0,i.ripemd160)(s.from(e));return"Bytes"===r?n:c.fromBytes(n)},r.sha256=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{as:r="string"==typeof e?"Hex":"Bytes"}=t,n=(0,o.sha256)(s.from(e));return"Bytes"===r?n:c.fromBytes(n)},r.validate=function(e){return c.validate(e)&&32===c.size(e)};let n=e.r(806403),i=e.r(776928),a=e.r(206492),o=e.r(456782),s=e.r(386319),c=e.r(998576)},46728,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidSerializedSizeError=r.InvalidUncompressedPrefixError=r.InvalidCompressedPrefixError=r.InvalidPrefixError=r.InvalidError=void 0,r.assert=s,r.compress=function(e){let{x:t,y:r}=e;return{prefix:r%2n===0n?2:3,x:t}},r.from=function(e){let t=(()=>{if(a.validate(e))return u(e);if(n.validate(e))return c(e);let{prefix:t,x:r,y:i}=e;return"bigint"==typeof r&&"bigint"==typeof i?{prefix:t??4,x:r,y:i}:{prefix:t,x:r}})();return s(t),t},r.fromBytes=c,r.fromHex=u,r.toBytes=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return n.fromHex(l(e,t))},r.toHex=l,r.validate=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{return s(e,t),!0}catch(e){return!1}};let n=e.r(386319),i=e.r(934704),a=e.r(998576),o=e.r(127008);function s(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{compressed:r}=t,{prefix:n,x:i,y:a}=e;if(!1===r||"bigint"==typeof i&&"bigint"==typeof a){if(4!==n)throw new f({prefix:n,cause:new h});return}if(!0===r||"bigint"==typeof i&&void 0===a){if(3!==n&&2!==n)throw new f({prefix:n,cause:new p});return}throw new d({publicKey:e})}function c(e){return u(a.fromBytes(e))}function u(e){if(132!==e.length&&130!==e.length&&68!==e.length)throw new m({publicKey:e});if(130===e.length)return{prefix:4,x:BigInt(a.slice(e,0,32)),y:BigInt(a.slice(e,32,64))};if(132===e.length){let t=Number(a.slice(e,0,1));return{prefix:t,x:BigInt(a.slice(e,1,33)),y:BigInt(a.slice(e,33,65))}}return{prefix:Number(a.slice(e,0,1)),x:BigInt(a.slice(e,1,33))}}function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};s(e);let{prefix:r,x:n,y:i}=e,{includePrefix:o=!0}=t;return a.concat(o?a.fromNumber(r,{size:1}):"0x",a.fromNumber(n,{size:32}),"bigint"==typeof i?a.fromNumber(i,{size:32}):"0x")}class d extends i.BaseError{constructor({publicKey:e}){super(`Value \`${o.stringify(e)}\` is not a valid public key.`,{metaMessages:["Public key must contain:","- an `x` and `prefix` value (compressed)","- an `x`, `y`, and `prefix` value (uncompressed)"]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PublicKey.InvalidError"})}}r.InvalidError=d;class f extends i.BaseError{constructor({prefix:e,cause:t}){super(`Prefix "${e}" is invalid.`,{cause:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PublicKey.InvalidPrefixError"})}}r.InvalidPrefixError=f;class p extends i.BaseError{constructor(){super("Prefix must be 2 or 3 for compressed public keys."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PublicKey.InvalidCompressedPrefixError"})}}r.InvalidCompressedPrefixError=p;class h extends i.BaseError{constructor(){super("Prefix must be 4 for uncompressed public keys."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PublicKey.InvalidUncompressedPrefixError"})}}r.InvalidUncompressedPrefixError=h;class m extends i.BaseError{constructor({publicKey:e}){super(`Value \`${e}\` is an invalid public key size.`,{metaMessages:["Expected: 33 bytes (compressed + prefix), 64 bytes (uncompressed) or 65 bytes (uncompressed + prefix).",`Received ${a.size(a.from(e))} bytes.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"PublicKey.InvalidSerializedSizeError"})}}r.InvalidSerializedSizeError=m},826527,(e,t,r)=>{"use strict";
2Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidChecksumError=r.InvalidInputError=r.InvalidAddressError=void 0,r.assert=u,r.checksum=l,r.from=d,r.fromPublicKey=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=o.keccak256(`0x${s.toHex(e).slice(4)}`).substring(26);return d(`0x${r}`,t)},r.isEqual=function(e,t){return u(e,{strict:!1}),u(t,{strict:!1}),e.toLowerCase()===t.toLowerCase()},r.validate=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{strict:r=!0}=t??{};try{return u(e,{strict:r}),!0}catch{return!1}};let n=e.r(386319),i=e.r(648350),a=e.r(934704),o=e.r(566697),s=e.r(46728),c=/^0x[a-fA-F0-9]{40}$/;function u(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{strict:r=!0}=t;if(!c.test(e))throw new f({address:e,cause:new p});if(r){if(e.toLowerCase()===e)return;if(l(e)!==e)throw new f({address:e,cause:new h})}}function l(e){if(i.checksum.has(e))return i.checksum.get(e);u(e,{strict:!1});let t=e.substring(2).toLowerCase(),r=o.keccak256(n.fromString(t),{as:"Bytes"}),a=t.split("");for(let e=0;e<40;e+=2)r[e>>1]>>4>=8&&a[e]&&(a[e]=a[e].toUpperCase()),(15&r[e>>1])>=8&&a[e+1]&&(a[e+1]=a[e+1].toUpperCase());let s=`0x${a.join("")}`;return i.checksum.set(e,s),s}function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{checksum:r=!1}=t;return(u(e),r)?l(e):e}class f extends a.BaseError{constructor({address:e,cause:t}){super(`Address "${e}" is invalid.`,{cause:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Address.InvalidAddressError"})}}r.InvalidAddressError=f;class p extends a.BaseError{constructor(){super("Address is not a 20 byte (40 hexadecimal character) value."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Address.InvalidInputError"})}}r.InvalidInputError=p;class h extends a.BaseError{constructor(){super("Address does not match its checksum counterpart."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Address.InvalidChecksumError"})}}r.InvalidChecksumError=h},818919,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.minInt120=r.minInt112=r.minInt104=r.minInt96=r.minInt88=r.minInt80=r.minInt72=r.minInt64=r.minInt56=r.minInt48=r.minInt40=r.minInt32=r.minInt24=r.minInt16=r.minInt8=r.maxInt256=r.maxInt248=r.maxInt240=r.maxInt232=r.maxInt224=r.maxInt216=r.maxInt208=r.maxInt200=r.maxInt192=r.maxInt184=r.maxInt176=r.maxInt168=r.maxInt160=r.maxInt152=r.maxInt144=r.maxInt136=r.maxInt128=r.maxInt120=r.maxInt112=r.maxInt104=r.maxInt96=r.maxInt88=r.maxInt80=r.maxInt72=r.maxInt64=r.maxInt56=r.maxInt48=r.maxInt40=r.maxInt32=r.maxInt24=r.maxInt16=r.maxInt8=r.integerRegex=r.bytesRegex=r.arrayRegex=void 0,r.maxUint256=r.maxUint248=r.maxUint240=r.maxUint232=r.maxUint224=r.maxUint216=r.maxUint208=r.maxUint200=r.maxUint192=r.maxUint184=r.maxUint176=r.maxUint168=r.maxUint160=r.maxUint152=r.maxUint144=r.maxUint136=r.maxUint128=r.maxUint120=r.maxUint112=r.maxUint104=r.maxUint96=r.maxUint88=r.maxUint80=r.maxUint72=r.maxUint64=r.maxUint56=r.maxUint48=r.maxUint40=r.maxUint32=r.maxUint24=r.maxUint16=r.maxUint8=r.minInt256=r.minInt248=r.minInt240=r.minInt232=r.minInt224=r.minInt216=r.minInt208=r.minInt200=r.minInt192=r.minInt184=r.minInt176=r.minInt168=r.minInt160=r.minInt152=r.minInt144=r.minInt136=r.minInt128=void 0,r.arrayRegex=/^(.*)\[([0-9]*)\]$/,r.bytesRegex=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,r.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)?$/,r.maxInt8=2n**(8n-1n)-1n,r.maxInt16=2n**(16n-1n)-1n,r.maxInt24=2n**(24n-1n)-1n,r.maxInt32=2n**(32n-1n)-1n,r.maxInt40=2n**(40n-1n)-1n,r.maxInt48=2n**(48n-1n)-1n,r.maxInt56=2n**(56n-1n)-1n,r.maxInt64=2n**(64n-1n)-1n,r.maxInt72=2n**(72n-1n)-1n,r.maxInt80=2n**(80n-1n)-1n,r.maxInt88=2n**(88n-1n)-1n,r.maxInt96=2n**(96n-1n)-1n,r.maxInt104=2n**(104n-1n)-1n,r.maxInt112=2n**(112n-1n)-1n,r.maxInt120=2n**(120n-1n)-1n,r.maxInt128=2n**(128n-1n)-1n,r.maxInt136=2n**(136n-1n)-1n,r.maxInt144=2n**(144n-1n)-1n,r.maxInt152=2n**(152n-1n)-1n,r.maxInt160=2n**(160n-1n)-1n,r.maxInt168=2n**(168
2n-1n)-1n,r.maxInt176=2n**(176n-1n)-1n,r.maxInt184=2n**(184n-1n)-1n,r.maxInt192=2n**(192n-1n)-1n,r.maxInt200=2n**(200n-1n)-1n,r.maxInt208=2n**(208n-1n)-1n,r.maxInt216=2n**(216n-1n)-1n,r.maxInt224=2n**(224n-1n)-1n,r.maxInt232=2n**(232n-1n)-1n,r.maxInt240=2n**(240n-1n)-1n,r.maxInt248=2n**(248n-1n)-1n,r.maxInt256=2n**(256n-1n)-1n,r.minInt8=-(2n**(8n-1n)),r.minInt16=-(2n**(16n-1n)),r.minInt24=-(2n**(24n-1n)),r.minInt32=-(2n**(32n-1n)),r.minInt40=-(2n**(40n-1n)),r.minInt48=-(2n**(48n-1n)),r.minInt56=-(2n**(56n-1n)),r.minInt64=-(2n**(64n-1n)),r.minInt72=-(2n**(72n-1n)),r.minInt80=-(2n**(80n-1n)),r.minInt88=-(2n**(88n-1n)),r.minInt96=-(2n**(96n-1n)),r.minInt104=-(2n**(104n-1n)),r.minInt112=-(2n**(112n-1n)),r.minInt120=-(2n**(120n-1n)),r.minInt128=-(2n**(128n-1n)),r.minInt136=-(2n**(136n-1n)),r.minInt144=-(2n**(144n-1n)),r.minInt152=-(2n**(152n-1n)),r.minInt160=-(2n**(160n-1n)),r.minInt168=-(2n**(168n-1n)),r.minInt176=-(2n**(176n-1n)),r.minInt184=-(2n**(184n-1n)),r.minInt192=-(2n**(192n-1n)),r.minInt200=-(2n**(200n-1n)),r.minInt208=-(2n**(208n-1n)),r.minInt216=-(2n**(216n-1n)),r.minInt224=-(2n**(224n-1n)),r.minInt232=-(2n**(232n-1n)),r.minInt240=-(2n**(240n-1n)),r.minInt248=-(2n**(248n-1n)),r.minInt256=-(2n**(256n-1n)),r.maxUint8=2n**8n-1n,r.maxUint16=2n**16n-1n,r.maxUint24=2n**24n-1n,r.maxUint32=2n**32n-1n,r.maxUint40=2n**40n-1n,r.maxUint48=2n**48n-1n,r.maxUint56=2n**56n-1n,r.maxUint64=2n**64n-1n,r.maxUint72=2n**72n-1n,r.maxUint80=2n**80n-1n,r.maxUint88=2n**88n-1n,r.maxUint96=2n**96n-1n,r.maxUint104=2n**104n-1n,r.maxUint112=2n**112n-1n,r.maxUint120=2n**120n-1n,r.maxUint128=2n**128n-1n,r.maxUint136=2n**136n-1n,r.maxUint144=2n**144n-1n,r.maxUint152=2n**152n-1n,r.maxUint160=2n**160n-1n,r.maxUint168=2n**168n-1n,r.maxUint176=2n**176n-1n,r.maxUint184=2n**184n-1n,r.maxUint192=2n**192n-1n,r.maxUint200=2n**200n-1n,r.maxUint208=2n**208n-1n,r.maxUint216=2n**216n-1n,r.maxUint224=2n**224n-1n,r.maxUint232=2n**232n-1n,r.maxUint240=2n**240n-1n,r.maxUint248=2n**248n-1n,r.maxUint256=2n**256n-1n},365619,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeParameter=u,r.decodeAddress=l,r.decodeArray=d,r.decodeBool=f,r.decodeBytes=p,r.decodeNumber=h,r.decodeTuple=m,r.decodeString=b,r.prepareParameters=function(e){let{checksumAddress:t,parameters:r,values:n}=e,i=[];for(let e=0;e<r.length;e++)i.push(y({checksumAddress:t,parameter:r[e],value:n[e]}));return i},r.prepareParameter=y,r.encode=g,r.encodeAddress=v,r.encodeArray=w,r.encodeBytes=E,r.encodeBoolean=P,r.encodeNumber=x,r.encodeString=A,r.encodeTuple=I,r.getArrayComponents=T,r.hasDynamicChild=S;let n=e.r(909360),i=e.r(826527),a=e.r(386319),o=e.r(934704),s=e.r(998576),c=e.r(818919);function u(e,t,r){let{checksumAddress:i,staticPosition:a}=r,o=T(t.type);if(o){let[r,n]=o;return d(e,{...t,type:n},{checksumAddress:i,length:r,staticPosition:a})}if("tuple"===t.type)return m(e,t,{checksumAddress:i,staticPosition:a});if("address"===t.type)return l(e,{checksum:i});if("bool"===t.type)return f(e);if(t.type.startsWith("bytes"))return p(e,t,{staticPosition:a});if(t.type.startsWith("uint")||t.type.startsWith("int"))return h(e,t);if("string"===t.type)return b(e,{staticPosition:a});throw new n.InvalidTypeError(t.type)}function l(e){let t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{checksum:n=!1}=r,o=e.readBytes(32);return[(t=s.fromBytes(a.slice(o,-20)),n?i.checksum(t):t),32]}function d(e,t,r){let{checksumAddress:n,length:i,staticPosition:o}=r;if(!i){let r=o+a.toNumber(e.readBytes(32)),i=r+32;e.setPosition(r);let s=a.toNumber(e.readBytes(32)),c=S(t),l=0,d=[];for(let r=0;r<s;++r){e.setPosition(i+(c?32*r:l));let[a,o]=u(e,t,{checksumAddress:n,staticPosition:i});l+=o,d.push(a)}return e.setPosition(o+32),[d,32]}if(S(t)){let r=o+a.toNumber(e.readBytes(32)),s=[];for(let a=0;a<i;++a){e.setPosition(r+32*a);let[i]=u(e,t,{checksumAddress:n,staticPosition:r});s.push(i)}return e.setPosition(o+32),[s,32]}let s=0,c=[];for(let r=0;r<i;++r){let[r,i]=u(e,t,{checksumAddress:n,staticPosition:o+s});s+=i,c.push(r)}return[c,s]}function f(e){return[a.toBoolean(e.readBytes(32),{size:32}),32]}function p(e,t,r){let{staticPosition:n}=r,[i,o]=t.type.split("bytes");if(!o){let t=a.toNumber(e.readBytes(32));e.setPosition(n+t);let r=a.toNumber(e.readBytes(32));if(0===r)return e.setPosition(n+32),["0x",32];let i=e.readBytes(r);return e.setPosition(n+32),[s.fromBytes(i),32]}return[s.fromBytes(e.readBytes(Number.parseInt(o,10),32)),32]}function h(e,t){let r=t.type.startsWith("int"),n=Number.parseInt(t.type.split("int")[1]||"256",10),i=e.readBytes(32);return[n>48?a.toBigInt(i,{signed:r}):a.toNumber(i,{signed:r}),32]}function m(e,t,r){let{checksumAddress:n,staticPosition:i}=r,o=0===t.components.length||t.components.some(e=>{let{name:t}=e;return!t}),s=o?[]:{},c=0;if(S(t)){let r=i+a.toNumber(e.readBytes(32));for(let i=0;i<t.components.length;++i){let a=t.components[i];e.setPosition(r+c);let[l,d]=u(e,a,{checksumAddress:n,staticPosition:r});
vendor: 7,890 bytes, line 2
2c+=d,s[o?i:a?.name]=l}return e.setPosition(i+32),[s,32]}for(let r=0;r<t.components.length;++r){let a=t.components[r],[l,d]=u(e,a,{checksumAddress:n,staticPosition:i});s[o?r:a?.name]=l,c+=d}return[s,c]}function b(e,t){let{staticPosition:r}=t,n=a.toNumber(e.readBytes(32));e.setPosition(r+n);let i=a.toNumber(e.readBytes(32));if(0===i)return e.setPosition(r+32),["",32];let o=e.readBytes(i,32),s=a.toString(a.trimLeft(o));return e.setPosition(r+32),[s,32]}function y(e){let{checksumAddress:t=!1,parameter:r,value:i}=e,a=T(r.type);if(a){let[e,n]=a;return w(i,{checksumAddress:t,length:e,parameter:{...r,type:n}})}if("tuple"===r.type)return I(i,{checksumAddress:t,parameter:r});if("address"===r.type)return v(i,{checksum:t});if("bool"===r.type)return P(i);if(r.type.startsWith("uint")||r.type.startsWith("int")){let e=r.type.startsWith("int"),[,,t="256"]=c.integerRegex.exec(r.type)??[];return x(i,{signed:e,size:Number(t)})}if(r.type.startsWith("bytes"))return E(i,{type:r.type});if("string"===r.type)return A(i);throw new n.InvalidTypeError(r.type)}function g(e){let t=0;for(let r=0;r<e.length;r++){let{dynamic:n,encoded:i}=e[r];n?t+=32:t+=s.size(i)}let r=[],n=[],i=0;for(let a=0;a<e.length;a++){let{dynamic:o,encoded:c}=e[a];o?(r.push(s.fromNumber(t+i,{size:32})),n.push(c),i+=s.size(c)):r.push(c)}return s.concat(...r,...n)}function v(e,t){let{checksum:r=!1}=t;return i.assert(e,{strict:r}),{dynamic:!1,encoded:s.padLeft(e.toLowerCase())}}function w(e,t){let{checksumAddress:r,length:i,parameter:a}=t,o=null===i;if(!Array.isArray(e))throw new n.InvalidArrayError(e);if(!o&&e.length!==i)throw new n.ArrayLengthMismatchError({expectedLength:i,givenLength:e.length,type:`${a.type}[${i}]`});let c=!1,u=[];for(let t=0;t<e.length;t++){let n=y({checksumAddress:r,parameter:a,value:e[t]});n.dynamic&&(c=!0),u.push(n)}if(o||c){let e=g(u);if(o){let t=s.fromNumber(u.length,{size:32});return{dynamic:!0,encoded:u.length>0?s.concat(t,e):t}}if(c)return{dynamic:!0,encoded:e}}return{dynamic:!1,encoded:s.concat(...u.map(e=>{let{encoded:t}=e;return t}))}}function E(e,t){let{type:r}=t,[,i]=r.split("bytes"),a=s.size(e);if(!i){let t=e;return a%32!=0&&(t=s.padRight(t,32*Math.ceil((e.length-2)/2/32))),{dynamic:!0,encoded:s.concat(s.padLeft(s.fromNumber(a,{size:32})),t)}}if(a!==Number.parseInt(i,10))throw new n.BytesSizeMismatchError({expectedSize:Number.parseInt(i,10),value:e});return{dynamic:!1,encoded:s.padRight(e)}}function P(e){if("boolean"!=typeof e)throw new o.BaseError(`Invalid boolean value: "${e}" (type: ${typeof e}). Expected: \`true\` or \`false\`.`);return{dynamic:!1,encoded:s.padLeft(s.fromBoolean(e))}}function x(e,t){let{signed:r,size:n}=t;if("number"==typeof n){let t=2n**(BigInt(n)-(r?1n:0n))-1n,i=r?-t-1n:0n;if(e>t||e<i)throw new s.IntegerOutOfRangeError({max:t.toString(),min:i.toString(),signed:r,size:n/8,value:e.toString()})}return{dynamic:!1,encoded:s.fromNumber(e,{size:32,signed:r})}}function A(e){let t=s.fromString(e),r=Math.ceil(s.size(t)/32),n=[];for(let e=0;e<r;e++)n.push(s.padRight(s.slice(t,32*e,(e+1)*32)));return{dynamic:!0,encoded:s.concat(s.padRight(s.fromNumber(s.size(t),{size:32})),...n)}}function I(e,t){let{checksumAddress:r,parameter:n}=t,i=!1,a=[];for(let t=0;t<n.components.length;t++){let o=n.components[t],s=Array.isArray(e)?t:o.name,c=y({checksumAddress:r,parameter:o,value:e[s]});a.push(c),c.dynamic&&(i=!0)}return{dynamic:i,encoded:i?g(a):s.concat(...a.map(e=>{let{encoded:t}=e;return t}))}}function T(e){let t=e.match(/^(.*)\[(\d+)?\]$/);return t?[t[2]?Number(t[2]):null,t[1]]:void 0}function S(e){let{type:t}=e;if("string"===t||"bytes"===t||t.endsWith("[]"))return!0;if("tuple"===t)return e.components?.some(S);let r=T(e.type);return!!(r&&S({...e,type:r[1]}))}},959432,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.RecursiveReadLimitExceededError=r.PositionOutOfBoundsError=r.NegativeOffsetError=void 0,r.create=function(e){let{recursiveReadLimit:t=8192}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=Object.create(i);return r.bytes=e,r.dataView=new DataView(e.buffer,e.byteOffset,e.byteLength),r.positionReadCount=new Map,r.recursiveReadLimit=t,r};let n=e.r(934704),i={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,positionReadCount:new Map,recursiveReadCount:0,recursiveReadLimit:1/0,assertReadLimit(){if(this.recursiveReadCount>=this.recursiveReadLimit)throw new s({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(e){if(e<0||e>this.bytes.length-1)throw new o({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new a({offset:e});let t=this.position-e;this.assertPosition(t),this.position=t},getReadCount(e){return this.positionReadCount.get(e||this.position)||0},incrementPosition(e){if(e<0)throw new a({offset:e});let t=this.position+e;this.assertPosition(t),this.position=t},inspectByte(e){let t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectBytes(e,t){let r=t??this.position;return this.assertPosition(r+e-1),this.bytes.subarray(r,r+e)},inspectUint8(e){let t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectUint16(e){let t=e??this.position;return this.assertPosition(t+1),this.dataView.getUint16(t)},inspectUint24(e){let t=e??this.position;return this.assertPosition(t+2),(this.dataView.getUint16(t)<<8)+this.dataView.getUint8(t+2)},inspectUint32(e){let t=e??this.position;return this.assertPosition(t+3),this.dataView.getUint32(t)},pushByte(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushBytes(e){this.assertPosition(this.position+e.length-1),this.bytes.set(e,this.position),this.position+=e.length},pushUint8(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushUint16(e){this.assertPosition(this.position+1),this.dataView.setUint16(this.position,e),this.position+=2},pushUint24(e){this.assertPosition(this.position+2),this.dataView.setUint16(this.position,e>>8),this.dataView.setUint8(this.position+2,255&e),this.position+=3},pushUint32(e){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,e),this.position+=4},readByte(){this.assertReadLimit(),this._touch();let e=this.inspectByte();return this.position++,e},readBytes(e,t){this.assertReadLimit(),this._touch();let r=this.inspectBytes(e);return this.position+=t??e,r},readUint8(){this.assertReadLimit(),this._touch();let e=this.inspectUint8();return this.position+=1,e},readUint16(){this.assertReadLimit(),this._touch();let e=this.inspectUint16();return this.position+=2,e},readUint24(){this.assertReadLimit(),this._touch();let e=this.inspectUint24();return this.position+=3,e},readUint32(){this.assertReadLimit(),this._touch();let e=this.inspectUint32();return this.position+=4,e},get remaining(){return this.bytes.length-this.position},setPosition(e){let t=this.position;return this.assertPosition(e),this.position=e,()=>this.position=t},_touch(){if(this.recursiveReadLimit===1/0)return;let e=this.getReadCount();this.positionReadCount.set(this.position,e+1),e>0&&this.recursiveReadCount++}};class a extends n.BaseError{constructor({offset:e}){super(`Offset \`${e}\` cannot be negative.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Cursor.NegativeOffsetError"})}}r.NegativeOffsetError=a;class o extends n.BaseError{constructor({length:e,position:t}){super(`Position \`${t}\` is out of bounds (\`0 < position < ${e}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Cursor.PositionOutOfBoundsError"})}}r.PositionOutOfBoundsError=o;class s extends n.BaseError{constructor({count:e,limit:t}){super(`Recursive read limit of \`${t}\` exceeded (recursive read count: \`${e}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Cursor.RecursiveReadLimitExceededError"})}}r.RecursiveReadLimitExceededError=s}
2,909360,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidTypeError=r.InvalidArrayError=r.LengthMismatchError=r.BytesSizeMismatchError=r.ArrayLengthMismatchError=r.ZeroDataError=r.DataSizeTooSmallError=void 0,r.decode=function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{as:n="Array",checksumAddress:i=!1}=r,o="string"==typeof t?a.fromHex(t):t,l=u.create(o);if(0===a.size(o)&&e.length>0)throw new p;if(a.size(o)&&32>a.size(o))throw new f({data:"string"==typeof t?t:s.fromBytes(t),parameters:e,size:a.size(o)});let d=0,h="Array"===n?[]:{};for(let t=0;t<e.length;++t){let r=e[t];l.setPosition(d);let[a,o]=c.decodeParameter(l,r,{checksumAddress:i,staticPosition:0});d+=o,"Array"===n?h.push(a):h[r.name??t]=a}return h},r.encode=function(e,t,r){let{checksumAddress:n=!1}=r??{};if(e.length!==t.length)throw new b({expectedLength:e.length,givenLength:t.length});let i=c.prepareParameters({checksumAddress:n,parameters:e,values:t}),a=c.encode(i);return 0===a.length?"0x":a},r.encodePacked=d,r.format=function(e){return n.formatAbiParameters(e)},r.from=function(e){return Array.isArray(e)&&"string"==typeof e[0]||"string"==typeof e?n.parseAbiParameters(e):e};let n=e.r(668691),i=e.r(826527),a=e.r(386319),o=e.r(934704),s=e.r(998576),c=e.r(365619),u=e.r(959432),l=e.r(818919);function d(e,t){if(e.length!==t.length)throw new b({expectedLength:e.length,givenLength:t.length});let r=[];for(let n=0;n<e.length;n++){let i=e[n],a=t[n];r.push(d.encode(i,a))}return s.concat(...r)}(d||(r.encodePacked=d={})).encode=function e(t,r){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("address"===t)return i.assert(r),s.padLeft(r.toLowerCase(),32*!!n);if("string"===t)return s.fromString(r);if("bytes"===t)return r;if("bool"===t)return s.padLeft(s.fromBoolean(r),n?32:1);let a=t.match(l.integerRegex);if(a){let[e,t,i="256"]=a,o=Number.parseInt(i,10)/8;return s.fromNumber(r,{size:n?32:o,signed:"int"===t})}let o=t.match(l.bytesRegex);if(o){let[e,t]=o;if(Number.parseInt(t,10)!==(r.length-2)/2)throw new m({expectedSize:Number.parseInt(t,10),value:r});return s.padRight(r,32*!!n)}let c=t.match(l.arrayRegex);if(c&&Array.isArray(r)){let[t,n]=c,i=[];for(let t=0;t<r.length;t++)i.push(e(n,r[t],!0));return 0===i.length?"0x":s.concat(...i)}throw new g(t)};class f extends o.BaseError{constructor({data:e,parameters:t,size:r}){super(`Data size of ${r} bytes is too small for given parameters.`,{metaMessages:[`Params: (${n.formatAbiParameters(t)})`,`Data:   ${e} (${r} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.DataSizeTooSmallError"})}}r.DataSizeTooSmallError=f;class p extends o.BaseError{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.'),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.ZeroDataError"})}}r.ZeroDataError=p;class h extends o.BaseError{constructor({expectedLength:e,givenLength:t,type:r}){super(`Array length mismatch for type \`${r}\`. Expected: \`${e}\`. Given: \`${t}\`.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.ArrayLengthMismatchError"})}}r.ArrayLengthMismatchError=h;class m extends o.BaseError{constructor({expectedSize:e,value:t}){super(`Size of bytes "${t}" (bytes${s.size(t)}) does not match expected size (bytes${e}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.BytesSizeMismatchError"})}}r.BytesSizeMismatchError=m;class b extends o.BaseError{constructor({expectedLength:e,givenLength:t}){super(`ABI encoding parameters/values length mismatch.
3Expected length (parameters): ${e}
4Given length (values): ${t}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.LengthMismatchError"})}}r.LengthMismatchError=b;class y extends o.BaseError{constructor(e){super(`Value \`${e}\` is not a valid array.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.InvalidArrayError"})}}r.InvalidArrayError=y;class g extends o.BaseError{constructor(e){super(`Type \`${e}\` is not a valid ABI Type.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.InvalidTypeError"})}}r.InvalidTypeError=g},604073,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.toBytes=function(e){return s(e,"Bytes")},r.toHex=function(e){return s(e,"Hex")},r.to=s,r.decodeRlpCursor=c,r.readLength=u,r.readList=l,r.from=d,r.fromBytes=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{as:r="Bytes"}=t;return d(e,{as:r})},r.fromHex=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{as:r="Hex"}=t;return d(e,{as:r})};let n=e.r(386319),i=e.r(934704),a=e.r(998576),o=e.r(959432);function s(e,t){let r=t??("string"==typeof e?"Hex":"Bytes"),i=(()=>{if("string"==typeof e){if(e.length>3&&e.length%2!=0)throw new a.InvalidLengthError(e);return n.fromHex(e)}return e})();return c(o.create(i,{recursiveReadLimit:1/0}),r)}function c(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"Hex";if(0===e.bytes.length)return"Hex"===t?a.fromBytes(e.bytes):e.bytes;let r=e.readByte();if(r<128&&e.decrementPosition(1),r<192){let n=u(e,r,128),i=e.readBytes(n);return"Hex"===t?a.fromBytes(i):i}let n=u(e,r,192);return l(e,n,t)}function u(e,t,r){if(128===r&&t<128)return 1;if(t<=r+55)return t-r;if(t===r+55+1)return e.readUint8();if(t===r+55+2)return e.readUint16();if(t===r+55+3)return e.readUint24();if(t===r+55+4)return e.readUint32();throw new i.BaseError("Invalid RLP prefix")}function l(e,t,r){let n=e.position,i=[];for(;e.position-n<t;)i.push(c(e,r));return i}function d(e,t){let{as:r}=t,i=function e(t){var r,i;let a,o,s,c;return Array.isArray(t)?(o=f(a=(r=t.map(t=>e(t))).reduce((e,t)=>e+t.length,0)),{length:a<=55?1+a:1+o+a,encode(e){for(let{encode:t}of(a<=55?e.pushByte(192+a):(e.pushByte(247+o),1===o?e.pushUint8(a):2===o?e.pushUint16(a):3===o?e.pushUint24(a):e.pushUint32(a)),r))t(e)}}):(c=f((s="string"==typeof(i=t)?n.fromHex(i):i).length),{length:1===s.length&&s[0]<128?1:s.length<=55?1+s.length:1+c+s.length,encode(e){1===s.length&&s[0]<128||(s.length<=55?e.pushByte(128+s.length):(e.pushByte(183+c),1===c?e.pushUint8(s.length):2===c?e.pushUint16(s.length):3===c?e.pushUint24(s.length):e.pushUint32(s.length))),e.pushBytes(s)}})}(e),s=o.create(new Uint8Array(i.length));return(i.encode(s),"Hex"===r)?a.fromBytes(s.bytes):s.bytes}function f(e){if(e<=255)return 1;if(e<=65535)return 2;if(e<=0xffffff)return 3;if(e<=0xffffffff)return 4;throw new i.BaseError("Length is too large.")}},978590,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidVError=r.InvalidYParityError=r.InvalidSError=r.InvalidRError=r.MissingPropertiesError=r.InvalidSerializedSizeError=void 0,r.assert=u,r.fromBytes=l,r.fromHex=d,r.extract=function(e){if(void 0!==e.r&&void 0!==e.s)return f(e)},r.from=f,r.fromDerBytes=function(e){return p(o.fromBytes(e))},r.fromDerHex=p,r.fromLegacy=h,r.fromRpc=m,r.fromTuple=function(e){let[t,r,n]=e;return f({r:"0x"===r?0n:BigInt(r),s:"0x"===n?0n:BigInt(n),yParity:"0x"===t?0:Number(t)})},r.toBytes=function(e){return i.fromHex(b(e))},r.toHex=b,r.toDerBytes=function(e){return new n.secp256k1.Signature(e.r,e.s).toDERRawBytes()},r.toDerHex=function(e){let t=new n.secp256k1.Signature(e.r,e.s);return`0x${t.toDERHex()}`},r.toLegacy=function(e){return{r:e.r,s:e.s,v:g(e.yParity)}},r.toRpc=function(e){let{r:t,s:r,yParity:n}=e;return{r:o.fromNumber(t,{size:32}),s:o.fromNumber(r,{size:32}),yParity:0===n?"0x0":"0x1"}},r.toTuple=function(e){let{r:t,s:r,yParity:n}=e;return[n?"0x01":"0x",0n===t?"0x":o.trimLeft(o.fromNumber(t)),0n===r?"0x":o.trimLeft(o.fromNumber(r))]},r.validate=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{return u(e,t),!0}catch{return!1}},r.vToYParity=y,r.yParityToV=g;let n=e.r(759854),i=e.r(386319),a=e.r(934704),o=e.r(998576),s=e.r(127008),c=e.r(818919);function u(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{recovered:r}=t;if(void 0===e.r||void 0===e.s||r&&void 0===e.yParity)throw new w({signature:e});if(e.r<0n||e.r>c.maxUint256)throw new E({value:e.r});if(e.s<0n||e.s>c.maxUint256)throw new P({value:e.s});if("number"==typeof e.yParity&&0!==e.yParity&&1!==e.yParity)throw new x({value:e.yParity})}function l(e){return d(o.fromBytes(e))}function d(e){if(130!==e.length&&132!==e.length)throw new v({signature:e});let t=BigInt(o.slice(e,0,32)),r=BigInt(o.slice(e,32,64)),n=(()=>{let t=Number(`0x${e.slice(130)}`);if(!Number.isNaN(t))try{return y(t)}catch{throw new x({value:t})}})();return void 0===n?{r:t,s:r}:{r:t,s:r,yParity:n}}function f(e){let t="string"==typeof e?d(e):e instanceof Uint8Array?l(e):"str
4ing"==typeof e.r?m(e):e.v?h(e):{r:e.r,s:e.s,...void 0!==e.yParity?{yParity:e.yParity}:{}};return u(t),t}function p(e){let{r:t,s:r}=n.secp256k1.Signature.fromDER(o.from(e).slice(2));return{r:t,s:r}}function h(e){return{r:e.r,s:e.s,yParity:y(e.v)}}function m(e){let t=(()=>{let t=e.v?Number(e.v):void 0,r=e.yParity?Number(e.yParity):void 0;if("number"==typeof t&&"number"!=typeof r&&(r=y(t)),"number"!=typeof r)throw new x({value:e.yParity});return r})();return{r:BigInt(e.r),s:BigInt(e.s),yParity:t}}function b(e){u(e);let t=e.r,r=e.s;return o.concat(o.fromNumber(t,{size:32}),o.fromNumber(r,{size:32}),"number"==typeof e.yParity?o.fromNumber(g(e.yParity),{size:1}):"0x")}function y(e){if(0===e||27===e)return 0;if(1===e||28===e)return 1;if(e>=35)return+(e%2==0);throw new A({value:e})}function g(e){if(0===e)return 27;if(1===e)return 28;throw new x({value:e})}class v extends a.BaseError{constructor({signature:e}){super(`Value \`${e}\` is an invalid signature size.`,{metaMessages:["Expected: 64 bytes or 65 bytes.",`Received ${o.size(o.from(e))} bytes.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidSerializedSizeError"})}}r.InvalidSerializedSizeError=v;class w extends a.BaseError{constructor({signature:e}){super(`Signature \`${s.stringify(e)}\` is missing either an \`r\`, \`s\`, or \`yParity\` property.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.MissingPropertiesError"})}}r.MissingPropertiesError=w;class E extends a.BaseError{constructor({value:e}){super(`Value \`${e}\` is an invalid r value. r must be a positive integer less than 2^256.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidRError"})}}r.InvalidRError=E;class P extends a.BaseError{constructor({value:e}){super(`Value \`${e}\` is an invalid s value. s must be a positive integer less than 2^256.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidSError"})}}r.InvalidSError=P;class x extends a.BaseError{constructor({value:e}){super(`Value \`${e}\` is an invalid y-parity value. Y-parity must be 0 or 1.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidYParityError"})}}r.InvalidYParityError=x;class A extends a.BaseError{constructor({value:e}){super(`Value \`${e}\` is an invalid v value. v must be 27, 28 or >=35.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidVError"})}}r.InvalidVError=A},621927,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.from=s,r.fromRpc=c,r.fromRpcList=function(e){return e.map(c)},r.fromTuple=u,r.fromTupleList=function(e){let t=[];for(let r of e)t.push(u(r));return t},r.getSignPayload=function(e){return l(e,{presign:!0})},r.hash=l,r.toRpc=d,r.toRpcList=function(e){return e.map(d)},r.toTuple=f,r.toTupleList=function(e){if(!e||0===e.length)return[];let t=[];for(let r of e)t.push(f(r));return t};let n=e.r(566697),i=e.r(998576),a=e.r(604073),o=e.r(978590);function s(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof e.chainId?c(e):{...e,...t.signature}}function c(e){let{address:t,chainId:r,nonce:n}=e,i=o.extract(e);return{address:t,chainId:Number(r),nonce:BigInt(n),...i}}function u(e){let[t,r,n,i,a,c]=e,u={address:r,chainId:"0x"===t?0:Number(t),nonce:"0x"===n?0n:BigInt(n)};return i&&a&&c&&(u={...u,...o.fromTuple([i,a,c])}),s(u)}function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{presign:r}=t;return n.keccak256(i.concat("0x05",a.fromHex(f(r?{address:e.address,chainId:e.chainId,nonce:e.nonce}:e))))}function d(e){let{address:t,chainId:r,nonce:n,...a}=e;return{address:t,chainId:i.fromNumber(r),nonce:i.fromNumber(n),...o.toRpc(a)}}function f(e){let{address:t,chainId:r,nonce:n}=e,a=o.extract(e);return[r?i.fromNumber(r):"0x",t,n?i.fromNumber(n):"0x",...a?o.toTuple(a):[]]}},678057,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.extraEntropy=void 0,r.setExtraEntropy=function(e){r.extraEntropy=e},r.extraEntropy=!1},234540,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.noble=void 0,r.createKeyPair=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{as:t="Hex"}=e,r=l({as:t}),n=u({privateKey:r});return{privateKey:r,publicKey:n}},r.getPublicKey=u,r.getSharedSecret=function(e){let{as:t="Hex",privateKey:r,publicKey:i}=e,a=n.secp256k1.ProjectivePoint.fromHex(c.toHex(i).slice(2)).multiply(n.secp256k1.utils.normPrivateKeyToScalar(o.from(r).slice(2))).toRawBytes(!0);return"Hex"===t?o.fromBytes(a):a},r.randomPrivateKey=l,r.recoverAddress=d,r.recoverPublicKey=f,r.sign=function(e){let{extraEntropy:t=s.extraEntropy,hash:r,payload:i,privateKey:c}=e,{r:u,s:l,recovery:d}=n.secp256k1.sign(a.from(i),a.from(c),{extraEntropy:"boolean"==typeof t?t:o.from(t).slice(2),lowS:!0,...r?{prehash:!0}:{}});return{r:u,s:l,yParity:d}},r.verify=function(e){let{address:t,hash:r,payload:o,publicKey:s,signature:u}=e;return t?i.isEqual(t,d({payload:o,signature:u})):n.secp256k1.verify(u,a.from(o),c.toBytes(s),...r?[{prehash:!0,lowS:!0}]:[])};let n=e.r(759854),i=e.r(826527),a=e.r(386319),o=e.r(998576),s=e.r(678057),c=e.r(46728);function u(e){let{privateKey:t}=e,r=n.secp256k1.ProjectivePoint.fromPrivateKey(o.from(t).slice(2));return c.from(r)}function l(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{as:t="Hex"}=e,r=n.secp256k1.utils.randomPrivateKey();return"Hex"===t?o.fromBytes(r):r}function d(e){return i.fromPublicKey(f(e))}function f(e){let{payload:t,signature:r}=e,{r:i,s:a,yParity:s}=r,u=new n.secp256k1.Signature(BigInt(i),BigInt(a)).addRecoveryBit(s).recoverPublicKey(o.from(t).substring(2));return c.from(u)}r.noble=n.secp256k1},171683,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidWrappedSignatureError=r.suffixParameters=r.magicBytes=void 0,r.assert=u,r.from=function(e){return"string"==typeof e?l(e):e},r.unwrap=l,r.wrap=function(e){let{data:t,signature:a}=e;u(e);let l=s.recoverAddress({payload:i.getSignPayload(e.authorization),signature:c.from(e.authorization)}),d=n.encode(r.suffixParameters,[{...e.authorization,delegation:e.authorization.address,chainId:BigInt(e.authorization.chainId)},e.to??l,t??"0x"]),f=o.fromNumber(o.size(d),{size:32});return o.concat(a,d,f,r.magicBytes)},r.validate=function(e){try{return u(e),!0}catch{return!1}};let n=e.r(909360),i=e.r(621927),a=e.r(934704),o=e.r(998576),s=e.r(234540),c=e.r(978590);function u(e){if("string"==typeof e){if(o.slice(e,-32)!==r.magicBytes)throw new d(e)}else c.assert(e.authorization)}function l(e){u(e);
4let t=o.toNumber(o.slice(e,-64,-32)),a=o.slice(e,-t-64,-64),s=o.slice(e,0,-t-64),[c,l,d]=n.decode(r.suffixParameters,a);return{authorization:i.from({address:c.delegation,chainId:Number(c.chainId),nonce:c.nonce,yParity:c.yParity,r:c.r,s:c.s}),signature:s,...d&&"0x"!==d?{data:d,to:l}:{}}}r.magicBytes="0x8010801080108010801080108010801080108010801080108010801080108010",r.suffixParameters=n.from("(uint256 chainId, address delegation, uint256 nonce, uint8 yParity, uint256 r, uint256 s), address to, bytes data");class d extends a.BaseError{constructor(e){super(`Value \`${e}\` is an invalid ERC-8010 wrapped signature.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SignatureErc8010.InvalidWrappedSignatureError"})}}r.InvalidWrappedSignatureError=d},163964,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.SignatureErc8010=void 0,r.SignatureErc8010=e.r(171683)},85928,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isErc8010Signature=function(e){return n.SignatureErc8010.validate(e)};let n=e.r(163964)},259854,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseErc6492Signature=function(e){if(!(0,i.isErc6492Signature)(e))return{signature:e};let[t,r,a]=(0,n.decodeAbiParameters)([{type:"address"},{type:"bytes"},{type:"bytes"}],e);return{address:t,data:r,signature:a}};let n=e.r(239072),i=e.r(284741)},464244,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseErc8010Signature=function(e){if(!(0,a.isErc8010Signature)(e))return{signature:e};let{authorization:t,to:r,...o}=n.SignatureErc8010.unwrap(e);return{authorization:{address:t.address,chainId:t.chainId,nonce:Number(t.nonce),r:(0,i.numberToHex)(t.r,{size:32}),s:(0,i.numberToHex)(t.s,{size:32}),yParity:t.yParity},...r?{address:r}:{},...o}};let n=e.r(163964),i=e.r(850815),a=e.r(85928)},270988,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.recoverMessageAddress=a;let n=e.r(349779),i=e.r(935083);async function a(e){let{message:t,signature:r}=e;return(0,i.recoverAddress)({hash:(0,n.hashMessage)(t),signature:r})}},778956,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.recoverTypedDataAddress=a;let n=e.r(102155),i=e.r(935083);async function a(e){let{domain:t,message:r,primaryType:a,signature:o,types:s}=e;return(0,i.recoverAddress)({hash:(0,n.hashTypedData)({domain:t,message:r,primaryType:a,types:s}),signature:o})}},870872,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeErc6492Signature=function(e){let{address:t,data:r,signature:s,to:c="hex"}=e,u=(0,a.concatHex)([(0,i.encodeAbiParameters)([{type:"address"},{type:"bytes"},{type:"bytes"}],[t,r,s]),n.erc6492MagicBytes]);return"hex"===c?u:(0,o.hexToBytes)(u)};let n=e.r(400282),i=e.r(440747),a=e.r(985269),o=e.r(935603)},296890,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeErc8010Signature=function(e){let{address:t,data:r,signature:a,to:o="hex"}=e,s=n.SignatureErc8010.wrap({authorization:{address:e.authorization.address,chainId:e.authorization.chainId,nonce:BigInt(e.authorization.nonce),r:BigInt(e.authorization.r),s:BigInt(e.authorization.s),yParity:e.authorization.yParity},data:r,signature:a,to:t});return"hex"===o?s:(0,i.hexToBytes)(s)};let n=e.r(163964),i=e.r(935603)},114142,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifyHash=o;let n=e.r(929544),i=e.r(359389),a=e.r(935083);async function o(e){let{address:t,hash:r,signature:o}=e;return(0,i.isAddressEqual)((0,n.getAddress)(t),await (0,a.recoverAddress)({hash:r,signature:o}))}},413996,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifyMessage=o;let n=e.r(929544),i=e.r(359389),a=e.r(270988);async function o(e){let{address:t,message:r,signature:o}=e;return(0,i.isAddressEqual)((0,n.getAddress)(t),await (0,a.recoverMessageAddress)({message:r,signature:o}))}},51057,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifyTypedData=o;let n=e.r(929544),i=e.r(359389),a=e.r(778956);async function o(e){let{address:t,domain:r,message:o,primaryType:s,signature:c,types:u}=e;return(0,i.isAddressEqual)((0,n.getAddress)(t),await (0,a.recoverTypedDataAddress)({domain:r,message:o,primaryType:s,signature:c,types:u}))}},363701,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.getSerializedTransactionType=function(e){let t=(0,i.sliceHex)(e,0,1);if("0x04"===t)return"eip7702";if("0x03"===t)return"eip4844";if("0x02"===t)return"eip1559";if("0x01"===t)return"eip2930";if("0x"!==t&&(0,a.hexToNumber)(t)>=192)return"legacy";throw new n.InvalidSerializedTransactionTypeError({serializedType:t})};let n=e.r(341289),i=e.r(952195),a=e.r(723223)},523060,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseTransaction=function(e){let t=(0,h.getSerializedTransactionType)(e);return"eip1559"===t?function(e){let t=m(e),[r,n,a,o,c,u,d,f,h,g,v,w]=t;if(9!==t.length&&12!==t.length)throw new i.InvalidSerializedTransactionError({attributes:{chainId:r,nonce:n,maxPriorityFeePerGas:a,maxFeePerGas:o,gas:c,to:u,value:d,data:f,accessList:h,...t.length>9?{v:g,r:v,s:w}:{}},serializedTransaction:e,type:"eip1559"});let E={chainId:(0,l.hexToNumber)(r),type:"eip1559"};return(0,s.isHex)(u)&&"0x"!==u&&(E.to=u),(0,s.isHex)(c)&&"0x"!==c&&(E.gas=(0,l.hexToBigInt)(c)),(0,s.isHex)(f)&&"0x"!==f&&(E.data=f),(0,s.isHex)(n)&&(E.nonce="0x"===n?0:(0,l.hexToNumber)(n)),(0,s.isHex)(d)&&"0x"!==d&&(E.value=(0,l.hexToBigInt)(d)),(0,s.isHex)(o)&&"0x"!==o&&(E.maxFeePerGas=(0,l.hexToBigInt)(o)),(0,s.isHex)(a)&&"0x"!==a&&(E.maxPriorityFeePerGas=(0,l.hexToBigInt)(a)),0!==h.length&&"0x"!==h&&(E.accessList=b(h)),(0,p.assertTransactionEIP1559)(E),{...12===t.length?y(t):void 0,...E}}(e):"eip2930"===t?function(e){let t=m(e),[r,n,a,o,c,u,d,f,h,g,v]=t;if(8!==t.length&&11!==t.length)throw new i.InvalidSerializedTransactionError({attributes:{chainId:r,nonce:n,gasPrice:a,gas:o,to:c,value:u,data:d,accessList:f,...t.length>8?{v:h,r:g,s:v}:{}},serializedTransaction:e,type:"eip2930"});let w={chainId:(0,l.hexToNumber)(r),type:"eip2930"};return(0,s.isHex)(c)&&"0x"!==c&&(w.to=c),(0,s.isHex)(o)&&"0x"!==o&&(w.gas=(0,l.hexToBigInt)(o)),(0,s.isHex)(d)&&"0x"!==d&&(w.data=d),(0,s.isHex)(n)&&(w.nonce="0x"===n?0:(0,l.hexToNumber)(n)),(0,s.isHex)(u)&&"0x"!==u&&(w.value=(0,l.hexToBigInt)(u)),(0,s.isHex)(a)&&"0x"!==a&&(w.gasPrice=(0,l.hexToBigInt)(a)),0!==f.length&&"0x"!==f&&(w.accessList=b(f)),(0,p.assertTransactionEIP2930)(w),{...11===t.length?y(t):void 0,...w}}(e):"eip4844"===t?function(e){let t=m(e),r=4===t.length,n=r?t[0]:t,a=r?t.slice(1):[],[c,u,d,f,h,g,v,w,E,P,x,A,I,T]=n,[S,C,O]=a;if(11!==n.length&&14!==n.length)throw new i.InvalidSerializedTransactionError({attributes:{chainId:c,nonce:u,maxPriorityFeePerGas:d,maxFeePerGas:f,gas:h,to:g,value:v,data:w,accessList:E,...n.length>9?{v:A,r:I,s:T}:{}},serializedTransaction:e,type:"eip4844"});let j={blobVersionedHashes:x,chainId:(0,l.hexToNumber)(c),to:g,type:"eip4844"};return(0,s.isHex)(h)&&"0x"!==h&&(j.gas=(0,l.hexToBigInt)(h)),(0,s.isHex)(w)&&"0x"!==w&&(j.data=w),(0,s.isHex)(u)&&(j.nonce="0x"===u?0:(0,l.hexToNumber)(u)),(0,s.isHex)(v)&&"0x"!==v&&(j.value=(0,l.hexToBigInt)(v)),(0,s.isHex)(P)&&"0x"!==P&&(j.maxFeePerBlobGas=(0,l.hexToBigInt)(P)),(0,s.isHex)(f)&&"0x"!==f&&(j.maxFeePerGas=(0,l.hexToBigInt)(f)),(0,s.isHex)(d)&&"0x"!==d&&(j.maxPriorityFeePerGas=(0,l.hexToBigInt)(d)),0!==E.length&&"0x"!==E&&(j.accessList=b(E)),S&&C&&O&&(j.sidecars=(0,o.toBlobSidecars)({blobs:S,commitments:C,proofs:O})),(0,p.assertTransactionEIP4844)(j),{...14===n.length?y(n):void 0,...j}}(e):"eip7702"===t?function(e){let t=m(e),[r,n,a,o,c,u,d,f,h,g,v,w,E]=t;if(10!==t.length&&13!==t.length)throw new i.InvalidSerializedTransactionError({attributes:{chainId:r,nonce:n,maxPriorityFeePerGas:a,maxFeePerGas:o,gas:c,to:u,value:d,data:f,accessList:h,authorizationList:g,...t.length>9?{v,r:w,s:E}:{}},serializedTransaction:e,type:"eip7702"});let P={chainId:(0,l.hexToNumber)(r),type:"eip7702"};return(0,s.isHex)(u)&&"0x"!==u&&(P.to=u),(0,s.isHex)(c)&&"0x"!==c&&(P.gas=(0,l.hexToBigInt)(c)),(0,s.isHex)(f)&&"0x"!==f&&(P.data=f),(0,s.isHex)(n)&&(P.nonce="0x"===n?0:(0,l.hexToNumber)(n)),(0,s.isHex)(d)&&"0x"!==d&&(P.value=(0,l.hexToBigInt)(d)),(0,s.isHex)(o)&&"0x"!==o&&(P.maxFeePerGas=(0,l.hexToBigInt)(o)),(0,s.isHex)(a)&&"0x"!==a&&(P.maxPriorityFeePerGas=(0,l.hexToBigInt)(a)),0!==h.length&&"0x"!==h&&(P.accessList=b(h)),0!==g.length&&"0x"!==g&&(P.authorizationList=function(e){let t=[];for(let r=0;r<e.length;r++){let[n,i,a,o,s,c]=e[r];t.push({address:i,chainId:"0x"===n?0:(0,l.hexToNumber)(n),nonce:"0x"===a?0:(0,l.hexToNumber)(a),...y([o,s,c])})}return t}(g)),(0,p.assertTransactionEIP7702)(P),{...13===t.length?y(t):void 0,...P}}(e):function(e){let t=(0,d.fromRlp)(e,"hex"),[r,n,a,o,c,u,f,h,m]=t;if(6!==t.length&&9!==t.length)throw new i.InvalidSerializedTransactionError({attributes:{nonce:r,gasPrice:n,gas:a,to:o,value:c,data:u,...t.length>6?{v:f,r:h,s:m}:{}},serializedTransaction:e,type:"legacy"});let b={type:"legacy"};
4if((0,s.isHex)(o)&&"0x"!==o&&(b.to=o),(0,s.isHex)(a)&&"0x"!==a&&(b.gas=(0,l.hexToBigInt)(a)),(0,s.isHex)(u)&&"0x"!==u&&(b.data=u),(0,s.isHex)(r)&&(b.nonce="0x"===r?0:(0,l.hexToNumber)(r)),(0,s.isHex)(c)&&"0x"!==c&&(b.value=(0,l.hexToBigInt)(c)),(0,s.isHex)(n)&&"0x"!==n&&(b.gasPrice=(0,l.hexToBigInt)(n)),(0,p.assertTransactionLegacy)(b),6===t.length)return b;let y=(0,s.isHex)(f)&&"0x"!==f?(0,l.hexToBigInt)(f):0n;if("0x"===m&&"0x"===h)return y>0&&(b.chainId=Number(y)),b;let g=Number((y-35n)/2n);if(g>0)b.chainId=g;else if(27n!==y&&28n!==y)throw new i.InvalidLegacyVError({v:y});return b.v=y,b.s=m,b.r=h,b.yParity=+(y%2n===0n),b}(e)},r.toTransactionArray=m,r.parseAccessList=b;let n=e.r(224276),i=e.r(341289),a=e.r(429625),o=e.r(458775),s=e.r(528137),c=e.r(356154),u=e.r(492678),l=e.r(723223),d=e.r(975038),f=e.r(418690),p=e.r(165824),h=e.r(363701);function m(e){return(0,d.fromRlp)(`0x${e.slice(4)}`,"hex")}function b(e){let t=[];for(let r=0;r<e.length;r++){let[i,o]=e[r];if(!(0,a.isAddress)(i,{strict:!1}))throw new n.InvalidAddressError({address:i});t.push({address:i,storageKeys:o.map(e=>(0,f.isHash)(e)?e:(0,u.trim)(e))})}return t}function y(e){let t=e.slice(-3),r="0x"===t[0]||0n===(0,l.hexToBigInt)(t[0])?27n:28n;return{r:(0,c.padHex)(t[1],{size:32}),s:(0,c.padHex)(t[2],{size:32}),v:r,yParity:+(27n!==r)}}},214256,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidDecimalNumberError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({value:e}){super(`Number \`${e}\` is not a valid decimal number.`,{name:"InvalidDecimalNumberError"})}}r.InvalidDecimalNumberError=i},955265,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseUnits=function(e,t){if(!/^(-?)([0-9]*)\.?([0-9]*)$/.test(e))throw new n.InvalidDecimalNumberError({value:e});let[r,i="0"]=e.split("."),a=r.startsWith("-");if(a&&(r=r.slice(1)),i=i.replace(/(0+)$/,""),0===t)1===Math.round(Number(`.${i}`))&&(r=`${BigInt(r)+1n}`),i="";else if(i.length>t){let[e,n,a]=[i.slice(0,t-1),i.slice(t-1,t),i.slice(t)],o=Math.round(Number(`${n}.${a}`));(i=o>9?`${BigInt(e)+BigInt(1)}0`.padStart(e.length+1,"0"):`${e}${o}`).length>t&&(i=i.slice(1),r=`${BigInt(r)+1n}`),i=i.slice(0,t)}else i=i.padEnd(t,"0");return BigInt(`${a?"-":""}${r}${i}`)};let n=e.r(214256)},556170,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseEther=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"wei";return(0,i.parseUnits)(e,n.etherUnits[t])};let n=e.r(883987),i=e.r(955265)},923285,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseGwei=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"wei";return(0,i.parseUnits)(e,n.gweiUnits[t])};let n=e.r(883987),i=e.r(955265)},231058,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.padBytes=r.pad=r.isHex=r.isBytes=r.concatHex=r.concatBytes=r.concat=r.getChainContractAddress=r.extractChain=r.defineChain=r.assertCurrentChain=r.offchainLookupSignature=r.offchainLookupAbiItem=r.offchainLookup=r.ccipFetch=r.ccipRequest=r.buildRequest=r.verifyAuthorization=r.serializeAuthorizationList=r.recoverAuthorizationAddress=r.hashAuthorization=r.isAddressEqual=r.isAddress=r.getCreateAddress=r.getCreate2Address=r.getContractAddress=r.getAddress=r.parseEventLogs=r.getAbiItem=r.formatAbiItemWithArgs=r.formatAbiParams=r.formatAbiItem=r.encodePacked=r.encodeFunctionResult=r.encodeFunctionData=r.encodeEventTopics=r.encodeErrorResult=r.encodeDeployData=r.encodeAbiParameters=r.decodeFunctionResult=r.decodeFunctionData=r.decodeEventLog=r.decodeErrorResult=r.decodeAbiParameters=r.publicKeyToAddress=r.parseAccount=r.parseAbiParameters=r.parseAbiParameter=r.parseAbiItem=r.parseAbi=void 0,r.ripemd160=r.keccak256=r.isHash=r.getAction=r.formatTransactionRequest=r.defineTransactionRequest=r.defineTransactionReceipt=r.transactionType=r.formatTransaction=r.defineTransaction=r.formatLog=r.defineFormatter=r.extract=r.formatBlock=r.defineBlock=r.getTransactionError=r.getNodeError=r.containsNodeError=r.getEstimateGasError=r.getContractError=r.getCallError=r.toRlp=r.toHex=r.stringToHex=r.numberToHex=r.bytesToHex=r.boolToHex=r.toBytes=r.stringToBytes=r.numberToBytes=r.hexToBytes=r.boolToBytes=r.fromRlp=r.hexToString=r.hexToNumber=r.hexToBool=r.hexToBigInt=r.fromHex=r.fromBytes=r.bytesToString=r.bytesToNumber=r.bytesToBool=r.bytesToBigint=r.bytesToBigInt=r.trim=r.sliceHex=r.sliceBytes=r.slice=r.size=r.padHex=void 0,r.validateTypedData=r.serializeTypedData=r.serializeTransaction=r.serializeAccessList=r.parseTransaction=r.getTransactionType=r.getSerializedTransactionType=r.assertTransactionLegacy=r.assertTransactionEIP2930=r.assertTransactionEIP1559=r.assertRequest=r.stringify=r.verifyTypedData=r.verifyMessage=r.verifyHash=r.serializeErc8010Signature=r.serializeErc6492Signature=r.recoverTypedDataAddress=r.recoverPublicKey=r.re
4coverMessageAddress=r.recoverAddress=r.parseErc8010Signature=r.parseErc6492Signature=r.isErc8010Signature=r.isErc6492Signature=r.hashTypedData=r.hashStruct=r.hashMessage=r.getWebSocketRpcClient=r.socketClientCache=r.getSocketRpcClient=r.getHttpRpcClient=r.rpc=r.getSocket=r.integerRegex=r.bytesRegex=r.arrayRegex=r.nonceManager=r.createNonceManager=r.getFunctionSignature=r.toFunctionSignature=r.getFunctionSelector=r.toFunctionSelector=r.toFunctionHash=r.getEventSignature=r.toEventSignature=r.getEventSelector=r.toEventSelector=r.toEventHash=r.sha256=void 0,r.parseUnits=r.parseGwei=r.parseEther=r.formatUnits=r.formatGwei=r.formatEther=void 0;var n=e.r(668691);Object.defineProperty(r,"parseAbi",{enumerable:!0,get:function(){return n.parseAbi}}),Object.defineProperty(r,"parseAbiItem",{enumerable:!0,get:function(){return n.parseAbiItem}}),Object.defineProperty(r,"parseAbiParameter",{enumerable:!0,get:function(){return n.parseAbiParameter}}),Object.defineProperty(r,"parseAbiParameters",{enumerable:!0,get:function(){return n.parseAbiParameters}});var i=e.r(155401);Object.defineProperty(r,"parseAccount",{enumerable:!0,get:function(){return i.parseAccount}});var a=e.r(741867);Object.defineProperty(r,"publicKeyToAddress",{enumerable:!0,get:function(){return a.publicKeyToAddress}});var o=e.r(239072);Object.defineProperty(r,"decodeAbiParameters",{enumerable:!0,get:function(){return o.decodeAbiParameters}});var s=e.r(369165);Object.defineProperty(r,"decodeErrorResult",{enumerable:!0,get:function(){return s.decodeErrorResult}});var c=e.r(197532);Object.defineProperty(r,"decodeEventLog",{enumerable:!0,get:function(){return c.decodeEventLog}});var u=e.r(836501);Object.defineProperty(r,"decodeFunctionData",{enumerable:!0,get:function(){return u.decodeFunctionData}});var l=e.r(320101);Object.defineProperty(r,"decodeFunctionResult",{enumerable:!0,get:function(){return l.decodeFunctionResult}});var d=e.r(440747);Object.defineProperty(r,"encodeAbiParameters",{enumerable:!0,get:function(){return d.encodeAbiParameters}});var f=e.r(286717);Object.defineProperty(r,"encodeDeployData",{enumerable:!0,get:function(){return f.encodeDeployData}});var p=e.r(87425);Object.defineProperty(r,"encodeErrorResult",{enumerable:!0,get:function(){return p.encodeErrorResult}});var h=e.r(725159);Object.defineProperty(r,"encodeEventTopics",{enumerable:!0,get:function(){return h.encodeEventTopics}});var m=e.r(804943);Object.defineProperty(r,"encodeFunctionData",{enumerable:!0,get:function(){return m.encodeFunctionData}});var b=e.r(201219);Object.defineProperty(r,"encodeFunctionResult",{enumerable:!0,get:function(){return b.encodeFunctionResult}});var y=e.r(928659);Object.defineProperty(r,"encodePacked",{enumerable:!0,get:function(){return y.encodePacked}});var g=e.r(199807);Object.defineProperty(r,"formatAbiItem",{enumerable:!0,get:function(){return g.formatAbiItem}}),Object.defineProperty(r,"formatAbiParams",{enumerable:!0,get:function(){return g.formatAbiParams}});var v=e.r(121916);Object.defineProperty(r,"formatAbiItemWithArgs",{enumerable:!0,get:function(){return v.formatAbiItemWithArgs}});var w=e.r(409872);Object.defineProperty(r,"getAbiItem",{enumerable:!0,get:function(){return w.getAbiItem}});var E=e.r(685530);Object.defineProperty(r,"parseEventLogs",{enumerable:!0,get:function(){return E.parseEventLogs}});var P=e.r(929544);Object.defineProperty(r,"getAddress",{enumerable:!0,get:function(){return P.getAddress}});var x=e.r(831047);Object.defineProperty(r,"getContractAddress",{enumerable:!0,get:function(){return x.getContractAddress}}),Object.defineProperty(r,"getCreate2Address",{enumerable:!0,get:function(){return x.getCreate2Address}}),Object.defineProperty(r,"getCreateAddress",{enumerable:!0,get:function(){return x.getCreateAddress}});var A=e.r(429625);Object.defineProperty(r,"isAddress",{enumerable:!0,get:function(){return A.isAddress}});var I=e.r(359389);Object.defineProperty(r,"isAddressEqual",{enumerable:!0,get:function(){return I.isAddressEqual}});var T=e.r(486418);Object.defineProperty(r,"hashAuthorization",{enumerable:!0,get:function(){return T.hashAuthorization}});var S=e.r(271077);Object.defineProperty(r,"recoverAuthorizationAddress",{enumerable:!0,get:function(){return S.recoverAuthorizationAddress}});var C=e.r(344641);Object.defineProperty(r,"serializeAuthorizationList",{enumerable:!0,get:function(){return C.serializeAuthorizationList}});var O=e.r(234696);Object.defineProperty(r,"verifyAuthorization",{enumerable:!0,get:function(){return O.verifyAuthorization}});var j=e.r(566498);Object.defineProperty(r,"buildRequest",{enumerable:!0,get:function(){return j.buildRequest}});var k=e.r(772187);Object.defineProperty(r,"ccipRequest",{enumerable:!0,get:function(){return k.ccipRequest}}),Object.defineProperty(r,"ccipFetch",{enumerable:!0,get:function(){return k.ccipRequest}}),Object.defineProperty(r,"offchainLookup",{enumerable:!0,get:function(){return k.offchainLookup}}),Object.defineProperty(r,"offchainLookupAbiItem",{enumerable:!0,get:function(){return k.offchainLookupAbiItem}}),Object.defineProperty(r,"offchainLookupSignature",{enumerable:!0,get:function(){return k.offchainLookupSignature}});var R=e.r(389421);Object.defineProperty(r,"assertCurrentChain",{enumerable:!0,get:function(){return R.assertCurrentChain}});var _=e.r(528112);Object.defineProperty(r,"defineChain",{enumerable:!0,get:function(){return _.defineChain}});var B=e.r(407245);Object.defineProperty(r,"extractChain",{enumerable:!0,get:function(){return B.extractChain}});var M=e.r(370049);Object.defineProperty(r,"getChainContractAddress",{enumerable:!0,get:function(){return M.getChainContractAddress}});var F=e.r(985269);Object.defineProperty(r,"concat",{enumerable:!0,get:function(){return F.concat}}),Object.defineProperty(r,"concatBytes",{enumerable:!0,get:function(){return F.concatBytes}}),Object.defineProperty(r,"concatHex",{enumerable:!0,get:function(){return F.concatHex}});var N=e.r(361926);Object.defineProperty(r,"isBytes",{enumerable:!0,get:function(){return N.isBytes}});var U=e.r(528137);Object.defineProperty(r,"isHex",{enumerable:!0,get:function(){return U.isHex}});var H=e.r(356154);Object.defineProperty(r,"pad",{enumerable:!0,get:function(){return H.pad}}),Object.defineProperty(r,"padBytes",{enumerable:!0,get:function(){return H.padBytes}}),Object.defineProperty(r,"padHex",{enumerable:!0,get:function(){return H.padHex}});
4var z=e.r(484550);Object.defineProperty(r,"size",{enumerable:!0,get:function(){return z.size}});var L=e.r(952195);Object.defineProperty(r,"slice",{enumerable:!0,get:function(){return L.slice}}),Object.defineProperty(r,"sliceBytes",{enumerable:!0,get:function(){return L.sliceBytes}}),Object.defineProperty(r,"sliceHex",{enumerable:!0,get:function(){return L.sliceHex}});var D=e.r(492678);Object.defineProperty(r,"trim",{enumerable:!0,get:function(){return D.trim}});var $=e.r(783052);Object.defineProperty(r,"bytesToBigInt",{enumerable:!0,get:function(){return $.bytesToBigInt}}),Object.defineProperty(r,"bytesToBigint",{enumerable:!0,get:function(){return $.bytesToBigInt}}),Object.defineProperty(r,"bytesToBool",{enumerable:!0,get:function(){return $.bytesToBool}}),Object.defineProperty(r,"bytesToNumber",{enumerable:!0,get:function(){return $.bytesToNumber}}),Object.defineProperty(r,"bytesToString",{enumerable:!0,get:function(){return $.bytesToString}}),Object.defineProperty(r,"fromBytes",{enumerable:!0,get:function(){return $.fromBytes}});var q=e.r(723223);Object.defineProperty(r,"fromHex",{enumerable:!0,get:function(){return q.fromHex}}),Object.defineProperty(r,"hexToBigInt",{enumerable:!0,get:function(){return q.hexToBigInt}}),Object.defineProperty(r,"hexToBool",{enumerable:!0,get:function(){return q.hexToBool}}),Object.defineProperty(r,"hexToNumber",{enumerable:!0,get:function(){return q.hexToNumber}}),Object.defineProperty(r,"hexToString",{enumerable:!0,get:function(){return q.hexToString}});var W=e.r(975038);Object.defineProperty(r,"fromRlp",{enumerable:!0,get:function(){return W.fromRlp}});var G=e.r(935603);Object.defineProperty(r,"boolToBytes",{enumerable:!0,get:function(){return G.boolToBytes}}),Object.defineProperty(r,"hexToBytes",{enumerable:!0,get:function(){return G.hexToBytes}}),Object.defineProperty(r,"numberToBytes",{enumerable:!0,get:function(){return G.numberToBytes}}),Object.defineProperty(r,"stringToBytes",{enumerable:!0,get:function(){return G.stringToBytes}}),Object.defineProperty(r,"toBytes",{enumerable:!0,get:function(){return G.toBytes}});var K=e.r(850815);Object.defineProperty(r,"boolToHex",{enumerable:!0,get:function(){return K.boolToHex}}),Object.defineProperty(r,"bytesToHex",{enumerable:!0,get:function(){return K.bytesToHex}}),Object.defineProperty(r,"numberToHex",{enumerable:!0,get:function(){return K.numberToHex}}),Object.defineProperty(r,"stringToHex",{enumerable:!0,get:function(){return K.stringToHex}}),Object.defineProperty(r,"toHex",{enumerable:!0,get:function(){return K.toHex}});var V=e.r(178056);Object.defineProperty(r,"toRlp",{enumerable:!0,get:function(){return V.toRlp}});var J=e.r(537665);Object.defineProperty(r,"getCallError",{enumerable:!0,get:function(){return J.getCallError}});var Z=e.r(290881);Object.defineProperty(r,"getContractError",{enumerable:!0,get:function(){return Z.getContractError}});var Q=e.r(379541);Object.defineProperty(r,"getEstimateGasError",{enumerable:!0,get:function(){return Q.getEstimateGasError}});var Y=e.r(255397);Object.defineProperty(r,"containsNodeError",{enumerable:!0,get:function(){return Y.containsNodeError}}),Object.defineProperty(r,"getNodeError",{enumerable:!0,get:function(){return Y.getNodeError}});var X=e.r(724514);Object.defineProperty(r,"getTransactionError",{enumerable:!0,get:function(){return X.getTransactionError}});var ee=e.r(288053);Object.defineProperty(r,"defineBlock",{enumerable:!0,get:function(){return ee.defineBlock}}),Object.defineProperty(r,"formatBlock",{enumerable:!0,get:function(){return ee.formatBlock}});var et=e.r(106636);Object.defineProperty(r,"extract",{enumerable:!0,get:function(){return et.extract}});var er=e.r(544995);Object.defineProperty(r,"defineFormatter",{enumerable:!0,get:function(){return er.defineFormatter}});var en=e.r(798336);Object.defineProperty(r,"formatLog",{enumerable:!0,get:function(){return en.formatLog}});var ei=e.r(728125);Object.defineProperty(r,"defineTransaction",{enumerable:!0,get:function(){return ei.defineTransaction}}),Object.defineProperty(r,"formatTransaction",{enumerable:!0,get:function(){return ei.formatTransaction}}),Object.defineProperty(r,"transactionType",{enumerable:!0,get:function(){return ei.transactionType}});var ea=e.r(941403);Object.defineProperty(r,"defineTransactionReceipt",{enumerable:!0,get:function(){return ea.defineTransactionReceipt}});var eo=e.r(244319);Object.defineProperty(r,"defineTransactionRequest",{enumerable:!0,get:function(){return eo.defineTransactionRequest}}),Object.defineProperty(r,"formatTransactionRequest",{enumerable:!0,get:function(){return eo.formatTransactionRequest}});var es=e.r(388012);Object.defineProperty(r,"getAction",{enumerable:!0,get:function(){return es.getAction}});var ec=e.r(418690);Object.defineProperty(r,"isHash",{enumerable:!0,get:function(){return ec.isHash}});var eu=e.r(585457);Object.defineProperty(r,"keccak256",{enumerable:!0,get:function(){return eu.keccak256}});var el=e.r(218565);Object.defineProperty(r,"ripemd160",{enumerable:!0,get:function(){return el.ripemd160}});var ed=e.r(597025);Object.defineProperty(r,"sha256",{enumerable:!0,get:function(){return ed.sha256}});var ef=e.r(315487);Object.defineProperty(r,"toEventHash",{enumerable:!0,get:function(){return ef.toEventHash}});var ep=e.r(138355);Object.defineProperty(r,"toEventSelector",{enumerable:!0,get:function(){return ep.toEventSelector}}),Object.defineProperty(r,"getEventSelector",{enumerable:!0,get:function(){return ep.toEventSelector}});var eh=e.r(625113);Object.defineProperty(r,"toEventSignature",{enumerable:!0,get:function(){return eh.toEventSignature}}),Object.defineProperty(r,"getEventSignature",{enumerable:!0,get:function(){return eh.toEventSignature}});var em=e.r(476119);Object.defineProperty(r,"toFunctionHash",{enumerable:!0,get:function(){return em.toFunctionHash}});var eb=e.r(832768);Object.defineProperty(r,"toFunctionSelector",{enumerable:!0,get:function(){return eb.toFunctionSelector}}),Object.defineProperty(r,"getFunctionSelector",{enumerable:!0,get:function(){return eb.toFunctionSelector}});var ey=e.r(755535);Object.defineProperty(r,"toFunctionSignature",{enumerable:!0,get:function(){return ey.toFunctionSignature}}),Object.defineProperty(r,"getFunctionSignature",{enumerable:!0,get:function(){return ey.toFunctionSignature}});var eg=e.r(196270);Object.defineProperty(r,"createNonceManager",{enumerable:!0,get:function(){return eg.createNonceManager}}),Object.defineProperty(r,"nonceManager",{enumerable:!0,get:function(){return eg.nonceManager}});var ev=e.r(142433);Object.defineProperty(r,"arrayRegex",{enumerable:!0,get:function(){return ev.arrayRegex}}),Object.defineProperty(r,"bytesRegex",{enumerable:!0,get:function(){return ev.bytesRegex}}),Object.defineProperty(r,"integerRegex",{enumerable:!0,get:function(){return ev.integerRegex}});var ew=e.r(830510);Object.defineProperty(r,"getSocket",{enumerable:!0,get:function(){return ew.getSocket}}),Object.defineProperty(r,"rpc",{enumerable:!0,get:function(){return ew.rpc}});var eE=e.r(237303);Object.defineProperty(r,"getHttpRpcClient",{enumerable:!0,get:function(){return eE.getHttpRpcClient}});var eP=e.r(127063);Object.defineProperty(r,"getSocketRpcClient",{enumerable:!0,get:function(){return eP.getSocketRpcClient}}),Object.defineProperty(r,"socketClientCache",{enumerable:!0,get:function(){return eP.socketClientCache}});var ex=e.r(105960);Object.defineProperty(r,"getWebSocketRpcClient",{enumerable:!0,get:function(){return ex.getWebSocketRpcClient}});var eA=e.r(349779);Object.defineProperty(r,"hashMessage",{enumerable:!0,get:function(){return eA.hashMessage}});var eI=e.r(102155);Object.defineProperty(r,"hashStruct",{enumerable:!0,get:function(){return eI.hashStruct}}),Object.defineProperty(r,"hashTypedData",{enumerable:!0,get:function(){return eI.hashTypedData}
4});var eT=e.r(284741);Object.defineProperty(r,"isErc6492Signature",{enumerable:!0,get:function(){return eT.isErc6492Signature}});var eS=e.r(85928);Object.defineProperty(r,"isErc8010Signature",{enumerable:!0,get:function(){return eS.isErc8010Signature}});var eC=e.r(259854);Object.defineProperty(r,"parseErc6492Signature",{enumerable:!0,get:function(){return eC.parseErc6492Signature}});var eO=e.r(464244);Object.defineProperty(r,"parseErc8010Signature",{enumerable:!0,get:function(){return eO.parseErc8010Signature}});var ej=e.r(935083);Object.defineProperty(r,"recoverAddress",{enumerable:!0,get:function(){return ej.recoverAddress}});var ek=e.r(270988);Object.defineProperty(r,"recoverMessageAddress",{enumerable:!0,get:function(){return ek.recoverMessageAddress}});var eR=e.r(436824);Object.defineProperty(r,"recoverPublicKey",{enumerable:!0,get:function(){return eR.recoverPublicKey}});var e_=e.r(778956);Object.defineProperty(r,"recoverTypedDataAddress",{enumerable:!0,get:function(){return e_.recoverTypedDataAddress}});var eB=e.r(870872);Object.defineProperty(r,"serializeErc6492Signature",{enumerable:!0,get:function(){return eB.serializeErc6492Signature}});var eM=e.r(296890);Object.defineProperty(r,"serializeErc8010Signature",{enumerable:!0,get:function(){return eM.serializeErc8010Signature}});var eF=e.r(114142);Object.defineProperty(r,"verifyHash",{enumerable:!0,get:function(){return eF.verifyHash}});var eN=e.r(413996);Object.defineProperty(r,"verifyMessage",{enumerable:!0,get:function(){return eN.verifyMessage}});var eU=e.r(51057);Object.defineProperty(r,"verifyTypedData",{enumerable:!0,get:function(){return eU.verifyTypedData}});var eH=e.r(905241);Object.defineProperty(r,"stringify",{enumerable:!0,get:function(){return eH.stringify}});var ez=e.r(854495);Object.defineProperty(r,"assertRequest",{enumerable:!0,get:function(){return ez.assertRequest}});var eL=e.r(165824);Object.defineProperty(r,"assertTransactionEIP1559",{enumerable:!0,get:function(){return eL.assertTransactionEIP1559}}),Object.defineProperty(r,"assertTransactionEIP2930",{enumerable:!0,get:function(){return eL.assertTransactionEIP2930}}),Object.defineProperty(r,"assertTransactionLegacy",{enumerable:!0,get:function(){return eL.assertTransactionLegacy}});var eD=e.r(363701);Object.defineProperty(r,"getSerializedTransactionType",{enumerable:!0,get:function(){return eD.getSerializedTransactionType}});var e$=e.r(446558);Object.defineProperty(r,"getTransactionType",{enumerable:!0,get:function(){return e$.getTransactionType}});var eq=e.r(523060);Object.defineProperty(r,"parseTransaction",{enumerable:!0,get:function(){return eq.parseTransaction}});var eW=e.r(687715);Object.defineProperty(r,"serializeAccessList",{enumerable:!0,get:function(){return eW.serializeAccessList}});var eG=e.r(567328);Object.defineProperty(r,"serializeTransaction",{enumerable:!0,get:function(){return eG.serializeTransaction}});var eK=e.r(976056);Object.defineProperty(r,"serializeTypedData",{enumerable:!0,get:function(){return eK.serializeTypedData}}),Object.defineProperty(r,"validateTypedData",{enumerable:!0,get:function(){return eK.validateTypedData}});var eV=e.r(65942);Object.defineProperty(r,"formatEther",{enumerable:!0,get:function(){return eV.formatEther}});var eJ=e.r(42506);Object.defineProperty(r,"formatGwei",{enumerable:!0,get:function(){return eJ.formatGwei}});var eZ=e.r(638809);Object.defineProperty(r,"formatUnits",{enumerable:!0,get:function(){return eZ.formatUnits}});var eQ=e.r(556170);Object.defineProperty(r,"parseEther",{enumerable:!0,get:function(){return eQ.parseEther}});var eY=e.r(923285);Object.defineProperty(r,"parseGwei",{enumerable:!0,get:function(){return eY.parseGwei}});var eX=e.r(955265);Object.defineProperty(r,"parseUnits",{enumerable:!0,get:function(){return eX.parseUnits}})},825585,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatProof=function(e){return{...e,balance:e.balance?BigInt(e.balance):void 0,nonce:e.nonce?(0,n.hexToNumber)(e.nonce):void 0,storageProof:e.storageProof?e.storageProof.map(e=>({...e,value:BigInt(e.value)})):void 0}};let n=e.r(231058)},61078,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.getProof=a;let n=e.r(850815),i=e.r(825585);async function a(e,t){let{address:r,blockNumber:a,blockTag:o,storageKeys:s}=t,c=void 0!==a?(0,n.numberToHex)(a):void 0,u=await e.request({method:"eth_getProof",params:[r,s,c||(o??"latest")]});return(0,i.formatProof)(u)}},835367,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getStorageAt=i;let n=e.r(850815);async function i(e,t){let{address:r,blockNumber:i,blockTag:a="latest",slot:o}=t,s=void 0!==i?(0,n.numberToHex)(i):void 0;return await e.request({method:"eth_getStorageAt",params:[r,o,s||a]})}},571615,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getTransaction=o;let n=e.r(341289),i=e.r(850815),a=e.r(728125);async function o(e,t){let{blockHash:r,blockNumber:o,blockTag:s,hash:c,index:u,sender:l,nonce:d}=t,f=s||"latest",p=void 0!==o?(0,i.numberToHex)(o):void 0,h=null;if(c?h=await e.request({method:"eth_getTransactionByHash",params:[c]},{dedupe:!0}):r?h=await e.request({method:"eth_getTransactionByBlockHashAndIndex",params:[r,(0,i.numberToHex)(u)]},{dedupe:!0}):(p||f)&&"number"==typeof u?h=await e.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[p||f,(0,i.numberToHex)(u)]},{dedupe:!!p}):l&&"number"==typeof d&&(h=await e.request({method:"eth_getTransactionBySenderAndNonce",params:[l,(0,i.numberToHex)(d)]},{dedupe:!0})),!h)throw new n.TransactionNotFoundError({blockHash:r,blockNumber:o,blockTag:f,hash:c,index:u});return(e.chain?.formatters?.transaction?.format||a.formatTransaction)(h,"getTransaction")}},95005,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getTransactionConfirmations=o;let n=e.r(388012),i=e.r(789238),a=e.r(571615);async function o(e,t){let{hash:r,transactionReceipt:o}=t,[s,c]=await Promise.all([(0,n.getAction)(e,i.getBlockNumber,"getBlockNumber")({}),r?(0,n.getAction)(e,a.getTransaction,"getTransaction")({hash:r}):void 0]),u=o?.blockNumber||c?.blockNumber;return u?s-u+1n:0n}},755388,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getTransactionReceipt=a;let n=e.r(341289),i=e.r(941403);async function a(e,t){let{hash:r}=t,a=await e.request({method:"eth_getTransactionReceipt",params:[r]},{dedupe:!0});if(!a)throw new n.TransactionReceiptNotFoundError({hash:r});return(e.chain?.formatters?.transactionReceipt?.format||i.formatTransactionReceipt)(a,"getTransactionReceipt")}},25213,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.multicall=h;let n=e.r(277779),i=e.r(286776),a=e.r(963101),o=e.r(91633),s=e.r(720794),c=e.r(320101),u=e.r(804943),l=e.r(370049),d=e.r(290881),f=e.r(388012),p=e.r(465300);async function h(e,t){let{account:r,authorizationList:h,allowFailure:m=!0,blockNumber:b,blockOverrides:y,blockTag:g,stateOverride:v}=t,w=t.contracts,{batchSize:E=t.batchSize??1024,deployless:P=t.deployless??!1}="object"==typeof e.batch?.multicall?e.batch.multicall:{},x=(()=>{if(t.multicallAddress)return t.multicallAddress;if(P)return null;if(e.chain)return(0,l.getChainContractAddress)({blockNumber:b,chain:e.chain,contract:"multicall3"});throw Error("client chain not configured. multicallAddress is required.")})(),A=[[]],I=0,T=0;for(let e=0;e<w.length;e++){let{abi:t,address:n,args:i,functionName:a}=w[e];try{let e=(0,u.encodeFunctionData)({abi:t,args:i,functionName:a});T+=(e.length-2)/2,E>0&&T>E&&A[I].length>0&&(I++,T=(e.length-2)/2,A[I]=[]),A[I]=[...A[I],{allowFailure:!0,callData:e,target:n}]}catch(o){let e=(0,d.getContractError)(o,{abi:t,address:n,args:i,docsPath:"/docs/contract/multicall",functionName:a,sender:r});if(!m)throw e;A[I]=[...A[I],{allowFailure:!0,callData:"0x",target:n}]}}let S=await Promise.allSettled(A.map(t=>(0,f.getAction)(e,p.readContract,"readContract")({...null===x?{code:i.multicall3Bytecode}:{address:x},abi:n.multicall3Abi,account:r,args:[t],authorizationList:h,blockNumber:b,blockOverrides:y,blockTag:g,functionName:"aggregate3",stateOverride:v}))),C=[];for(let e=0;e<S.length;e++){let t=S[e];if("rejected"===t.status){if(!m)throw t.reason;for(let r=0;r<A[e].length;r++)C.push({status:"failure",error:t.reason,result:void 0});continue}let r=t.value;for(let t=0;t<r.length;t++){let{returnData:n,success:i}=r[t],{callData:o}=A[e][t],{abi:u,address:l,functionName:f,args:p}=w[C.length];try{if("0x"===o)throw new a.AbiDecodingZeroDataError;if(!i)throw new s.RawContractError({data:n});let e=(0,c.decodeFunctionResult)({abi:u,args:p,data:n,functionName:f});C.push(m?{result:e,status:"success"}:e)}catch(t){let e=(0,d.getContractError)(t,{abi:u,address:l,args:p,docsPath:"/docs/contract/multicall",functionName:f});if(!m)throw e;C.push({error:e,result:void 0,status:"failure"})}}}if(C.length!==w.length)throw new o.BaseError("multicall results mismatch");return C}},318309,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.simulateBlocks=v;let n=e.r(872874),i=e.r(155401),a=e.r(963101),o=e.r(720794),s=e.r(659641),c=e.r(320101),u=e.r(804943),l=e.r(985269),d=e.r(850815),f=e.r(290881),p=e.r(255397),h=e.r(288053),m=e.r(798336),b=e.r(244319),y=e.r(434467),g=e.r(854495);async function v(e,t){let{blockNumber:r,blockTag:v=e.experimental_blockTag??"latest",blocks:w,returnFullTransactions:E,traceTransfers:P,validation:x}=t;try{let t=[];for(let e of w){let r=e.blockOverrides?n.toRpc(e.blockOverrides):void 0,a=e.calls.map(e=>{let t=e.account?(0,i.parseAccount)(e.account):void 0,r=e.abi?(0,u.encodeFunctionData)(e):e.data,n={...e,account:t,data:e.dataSuffix?(0,l.concat)([r||"0x",e.dataSuffix]):r,from:e.from??t?.address};return(0,g.assertRequest)(n),(0,b.formatTransactionRequest)(n)}),o=e.stateOverrides?(0,y.serializeStateOverride)(e.stateOverrides):void 0;t.push({blockOverrides:r,calls:a,stateOverrides:o})}let s="bigint"==typeof r?(0,d.numberToHex)(r):void 0;return(await e.request({method:"eth_simulateV1",params:[{blockStateCalls:t,returnFullTransactions:E,traceTransfers:P,validation:x},s||v]})).map((e,t)=>({...(0,h.formatBlock)(e),calls:e.calls.map((e,r)=>{let{abi:n,args:i,functionName:s,to:u}=w[t].calls[r],l=e.error?.data??e.returnData,d=BigInt(e.gasUsed),p=e.logs?.map(e=>(0,m.formatLog)(e)),h="0x1"===e.status?"success":"failure",b=n&&"success"===h&&"0x"!==l?(0,c.decodeFunctionResult)({abi:n,data:l,functionName:s}):null,y=(()=>{let e;if("success"!==h&&("0x"===l?e=new a.AbiDecodingZeroDataError:l&&(e=new o.RawContractError({data:l})),e))return(0,f.getContractError)(e,{abi:n??[],address:u??"0x",args:i,functionName:s??"<unknown>"})})();return{data:l,gasUsed:d,logs:p,status:h,..."success"===h?{result:b}:{error:y}}})}))}catch(t){let e=(0,p.getNodeError)(t,{});if(e instanceof s.UnknownNodeError)throw t;throw e}}},852077,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.normalizeSignature=function(e){let t=!0,r="",n=0,a="",o=!1;for(let i=0;i<e.length;i++){let s=e[i];if(["(",")",","].includes(s)&&(t=!0),"("===s&&n++,")"===s&&n--,t){if(0===n){if(" "===s&&["event","function","error",""].includes(a))a="";else if(a+=s,")"===s){o=!0;break}continue}if(" "===s){","!==e[i-1]&&","!==r&&",("!==r&&(r="",t=!1);continue}a+=s,r+=s}}if(!o)throw new i.BaseError("Unable to normalize signature.");return a},r.isArgOfType=function e(t,r){let i=typeof t,a=r.type;switch(a){case"address":return n.validate(t,{strict:!1});case"bool":return"boolean"===i;case"function":case"string":return"string"===i;default:if("tuple"===a&&"components"in r)return Object.values(r.components).every((r,n)=>e(Object.values(t)[n],r));if(/^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)?$/.test(a))return"number"===i||"bigint"===i;if(/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(a))return"string"===i||t instanceof Uint8Array;
4if(/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(a))return Array.isArray(t)&&t.every(t=>e(t,{...r,type:a.replace(/(\[[0-9]{0,}\])$/,"")}));return!1}},r.getAmbiguousTypes=function e(t,r,i){for(let a in t){let o=t[a],s=r[a];if("tuple"===o.type&&"tuple"===s.type&&"components"in o&&"components"in s)return e(o.components,s.components,i[a]);let c=[o.type,s.type];if(c.includes("address")&&c.includes("bytes20")||(c.includes("address")&&c.includes("string")||c.includes("address")&&c.includes("bytes"))&&n.validate(i[a],{strict:!1}))return c}};let n=e.r(826527),i=e.r(934704)},987216,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidSelectorSizeError=r.NotFoundError=r.AmbiguityError=void 0,r.format=function(e){return n.formatAbiItem(e)},r.from=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{prepare:r=!0}=t,i=Array.isArray(e)||"string"==typeof e?n.parseAbiItem(e):e;return{...i,...r?{hash:d(i)}:{}}},r.fromAbi=c,r.getSelector=u,r.getSignature=l,r.getSignatureHash=d;let n=e.r(668691),i=e.r(934704),a=e.r(566697),o=e.r(998576),s=e.r(852077);function c(e,t,r){let n,{args:i=[],prepare:a=!0}=r??{},c=o.validate(t,{strict:!1}),l=e.filter(e=>c?"function"===e.type||"error"===e.type?u(e)===o.slice(t,0,4):"event"===e.type&&d(e)===t:"name"in e&&e.name===t);if(0===l.length)throw new p({name:t});if(1===l.length)return{...l[0],...a?{hash:d(l[0])}:{}};for(let e of l){if("inputs"in e){if(!i||0===i.length){if(!e.inputs||0===e.inputs.length)return{...e,...a?{hash:d(e)}:{}};continue}if(e.inputs&&0!==e.inputs.length&&e.inputs.length===i.length&&i.every((t,r)=>{let n="inputs"in e&&e.inputs[r];return!!n&&s.isArgOfType(t,n)})){if(n&&"inputs"in n&&n.inputs){let t=s.getAmbiguousTypes(e.inputs,n.inputs,i);if(t)throw new f({abiItem:e,type:t[0]},{abiItem:n,type:t[1]})}n=e}}}let h=(()=>{if(n)return n;let[e,...t]=l;return{...e,overloads:t}})();if(!h)throw new p({name:t});return{...h,...a?{hash:d(h)}:{}}}function u(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let n=(()=>{if(Array.isArray(t[0])){let[e,r]=t;return c(e,r)}return t[0]})();return o.slice(d(n),0,4)}function l(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let i=(()=>{if(Array.isArray(t[0])){let[e,r]=t;return c(e,r)}return t[0]})(),a="string"==typeof i?i:n.formatAbiItem(i);return s.normalizeSignature(a)}function d(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let n=(()=>{if(Array.isArray(t[0])){let[e,r]=t;return c(e,r)}return t[0]})();return"string"!=typeof n&&"hash"in n&&n.hash?n.hash:a.keccak256(o.fromString(l(n)))}class f extends i.BaseError{constructor(e,t){super("Found ambiguous types in overloaded ABI Items.",{metaMessages:[`\`${e.type}\` in \`${s.normalizeSignature(n.formatAbiItem(e.abiItem))}\`, and`,`\`${t.type}\` in \`${s.normalizeSignature(n.formatAbiItem(t.abiItem))}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItem.AmbiguityError"})}}r.AmbiguityError=f;class p extends i.BaseError{constructor({name:e,data:t,type:r="item"}){const n=e?` with name "${e}"`:t?` with data "${t}"`:"";super(`ABI ${r}${n} not found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItem.NotFoundError"})}}r.NotFoundError=p;class h extends i.BaseError{constructor({data:e}){super(`Selector size is invalid. Expected 4 bytes. Received ${o.size(e)} bytes ("${e}").`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItem.InvalidSelectorSizeError"})}}r.InvalidSelectorSizeError=h},505700,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decode=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let[n,i]=(()=>{if(Array.isArray(t[0])){let[e,r]=t;return[s(e),r]}return t})(),{bytecode:o}=i;if(n.inputs?.length===0)return;let c=i.data.replace(o,"0x");return a.decode(n.inputs,c)},r.encode=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let[n,i]=(()=>
4{if(Array.isArray(t[0])){let[e,r]=t;return[s(e),r]}return t})(),{bytecode:c,args:u}=i;return o.concat(c,n.inputs?.length&&u?.length?a.encode(n.inputs,u):"0x")},r.format=function(e){return n.formatAbiItem(e)},r.from=function(e){return i.from(e)},r.fromAbi=s;let n=e.r(668691),i=e.r(987216),a=e.r(909360),o=e.r(998576);function s(e){let t=e.find(e=>"constructor"===e.type);if(!t)throw new i.NotFoundError({name:"constructor"});return t}},966428,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeData=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let[n,c]=(()=>{if(Array.isArray(t[0])){let[e,r,n]=t;return[s(e,r),n]}return t})(),{overloads:u}=n;if(4>o.size(c))throw new i.InvalidSelectorSizeError({data:c});if(n.inputs?.length===0)return;let l=u?s([n,...u],c):n;if(!(4>=o.size(c)))return a.decode(l.inputs,o.slice(c,4))},r.decodeResult=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let[n,i,o={}]=(()=>{if(Array.isArray(t[0])){let[e,r,n,i]=t;return[s(e,r),n,i]}return t})(),c=a.decode(n.outputs,i,o);if(!c||0!==Object.keys(c).length)return c&&1===Object.keys(c).length?Array.isArray(c)?c[0]:Object.values(c)[0]:c},r.encodeData=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let[n,i=[]]=(()=>{if(Array.isArray(t[0])){let[e,r,n]=t;return[s(e,r,{args:n}),n]}let[e,r]=t;return[e,r]})(),{overloads:u}=n,l=u?s([n,...u],n.name,{args:i}):n,d=c(l),f=i.length>0?a.encode(l.inputs,i):void 0;return f?o.concat(d,f):d},r.encodeResult=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let[n,i,o={}]=(()=>{if(Array.isArray(t[0])){let[e,r,n,i]=t;return[s(e,r),n,i]}return t})(),{as:c="Array"}=o,u=1===n.outputs.length?[i]:Array.isArray(i)?i:"Object"===c?Object.values(i):[i];return a.encode(n.outputs,u)},r.format=function(e){return n.formatAbiItem(e)},r.from=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return i.from(e,t)},r.fromAbi=s,r.getSelector=c;let n=e.r(668691),i=e.r(987216),a=e.r(909360),o=e.r(998576);function s(e,t,r){let n=i.fromAbi(e,t,r);if("function"!==n.type)throw new i.NotFoundError({name:t,type:"function"});return n}function c(e){return i.getSelector(e)}},135525,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.zeroAddress=r.ethAddress=void 0,r.ethAddress="0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee",r.zeroAddress="0x0000000000000000000000000000000000000000"},599587,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.simulateCalls=p;let n=e.r(505700),i=e.r(966428),a=e.r(155401),o=e.r(135525),s=e.r(286776),c=e.r(91633),u=e.r(804943),l=e.r(231058),d=e.r(490546),f=e.r(318309);async function p(e,t){let{blockNumber:r,blockTag:p,calls:h,stateOverrides:m,traceAssetChanges:b,traceTransfers:y,validation:g}=t,v=t.account?(0,a.parseAccount)(t.account):void 0;if(b&&!v)throw new c.BaseError("`account` is required when `traceAssetChanges` is true");let w=v?n.encode(n.from("constructor(bytes, bytes)"),{bytecode:s.deploylessCallViaBytecodeBytecode,args:["0x6080604052348015600e575f80fd5b5061016d8061001c5f395ff3fe608060405234801561000f575f80fd5b5060043610610029575f3560e01c8063f8b2cb4f1461002d575b5f80fd5b610047600480360381019061004291906100db565b61005d565b604051610054919061011e565b60405180910390f35b5f8173ffffffffffffffffffffffffffffffffffffffff16319050919050565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f6100aa82610081565b9050919050565b6100ba816100a0565b81146100c4575f80fd5b50565b5f813590506100d5816100b1565b92915050565b5f602082840312156100f0576100ef61007d565b5b5f6100fd848285016100c7565b91505092915050565b5f819050919050565b61011881610106565b82525050565b5f6020820190506101315f83018461010f565b9291505056fea26469706673582212203b9fe929fe995c7cf9887f0bdba8a36dd78e8b73f149b17d2d9ad7cd09d2dc6264736f6c634300081a0033",i.encodeData(i.from("function getBalance(address)"),[v.address])]}):void 0,E=b?await Promise.all(t.calls.map(async t=>{if(!t.data&&!t.abi)return;let{accessList:r}=await (0,d.createAccessList)(e,{account:v.address,...t,data:t.abi?(0,u.encodeFunctionData)(t):t.data});return r.map(e=>{let{address:t,storageKeys:r}=e;return r.length>0?t:null})})).then(e=>
4e.flat().filter(Boolean)):[],P=await (0,f.simulateBlocks)(e,{blockNumber:r,blockTag:p,blocks:[...b?[{calls:[{data:w}],stateOverrides:m},{calls:E.map((e,t)=>({abi:[i.from("function balanceOf(address) returns (uint256)")],functionName:"balanceOf",args:[v.address],to:e,from:o.zeroAddress,nonce:t})),stateOverrides:[{address:o.zeroAddress,nonce:0}]}]:[],{calls:[...h,{to:o.zeroAddress}].map(e=>({...e,from:v?.address})),stateOverrides:m},...b?[{calls:[{data:w}]},{calls:E.map((e,t)=>({abi:[i.from("function balanceOf(address) returns (uint256)")],functionName:"balanceOf",args:[v.address],to:e,from:o.zeroAddress,nonce:t})),stateOverrides:[{address:o.zeroAddress,nonce:0}]},{calls:E.map((e,t)=>({to:e,abi:[i.from("function decimals() returns (uint256)")],functionName:"decimals",from:o.zeroAddress,nonce:t})),stateOverrides:[{address:o.zeroAddress,nonce:0}]},{calls:E.map((e,t)=>({to:e,abi:[i.from("function tokenURI(uint256) returns (string)")],functionName:"tokenURI",args:[0n],from:o.zeroAddress,nonce:t})),stateOverrides:[{address:o.zeroAddress,nonce:0}]},{calls:E.map((e,t)=>({to:e,abi:[i.from("function symbol() returns (string)")],functionName:"symbol",from:o.zeroAddress,nonce:t})),stateOverrides:[{address:o.zeroAddress,nonce:0}]}]:[]],traceTransfers:y,validation:g}),x=b?P[2]:P[0],[A,I,,T,S,C,O,j]=b?P:[],{calls:k,...R}=x,_=k.slice(0,-1)??[],B=[...A?.calls??[],...I?.calls??[]].map(e=>"success"===e.status?(0,l.hexToBigInt)(e.data):null),M=[...T?.calls??[],...S?.calls??[]].map(e=>"success"===e.status?(0,l.hexToBigInt)(e.data):null),F=(C?.calls??[]).map(e=>"success"===e.status?e.result:null),N=(j?.calls??[]).map(e=>"success"===e.status?e.result:null),U=(O?.calls??[]).map(e=>"success"===e.status?e.result:null),H=[];for(let[e,t]of M.entries()){let r=B[e];if("bigint"!=typeof t||"bigint"!=typeof r)continue;let n=F[e-1],i=N[e-1],a=U[e-1],s=0===e?{address:o.ethAddress,decimals:18,symbol:"ETH"}:{address:E[e-1],decimals:a||n?Number(n??1):void 0,symbol:i??void 0};H.some(e=>e.token.address===s.address)||H.push({token:s,value:{pre:r,post:t,diff:t-r}})}return{assetChanges:H,block:R,results:_}}},356539,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidWrappedSignatureError=r.universalSignatureValidatorAbi=r.universalSignatureValidatorBytecode=r.magicBytes=void 0,r.assert=o,r.from=function(e){return"string"==typeof e?s(e):e},r.unwrap=s,r.wrap=function(e){let{data:t,signature:i,to:o}=e;return a.concat(n.encode(n.from("address, bytes, bytes"),[o,t,i]),r.magicBytes)},r.validate=function(e){try{return o(e),!0}catch{return!1}};let n=e.r(909360),i=e.r(934704),a=e.r(998576);function o(e){if(a.slice(e,-32)!==r.magicBytes)throw new c(e)}function s(e){o(e);let[t,r,i]=n.decode(n.from("address, bytes, bytes"),e);return{data:r,signature:i,to:t}}r.magicBytes="0x6492649264926492649264926492649264926492649264926492649264926492",r.universalSignatureValidatorBytecode="0x608060405234801561001057600080fd5b5060405161069438038061069483398101604081905261002f9161051e565b600061003c848484610048565b9050806000526001601ff35b60007f64926492649264926492649264926492649264926492649264926492649264926100748361040c565b036101e7576000606080848060200190518101906100929190610577565b60405192955090935091506000906001600160a01b038516906100b69085906105dd565b6000604051808303816000865af19150503d80600081146100f3576040519150601f19603f3d011682016040523d82523d6000602084013e6100f8565b606091505b50509050876001600160a01b03163b60000361016057806101605760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90610190908b9087906004016105f9565b602060405180830381865afa1580156101ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101d19190610633565b6001600160e01b03191614945050505050610405565b6001600160a01b0384163b1561027a57604051630b135d3f60e11b808252906001600160a01b03861690631626ba7e9061022790879087906004016105f9565b602060405180830381865afa158015610244573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102689190610633565b6001600160e01b031916149050610405565b81516041146102df5760405162461bcd60e51b8152
460206004820152603a602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e6774680000000000006064820152608401610157565b6102e7610425565b5060208201516040808401518451859392600091859190811061030c5761030c61065d565b016020015160f81c9050601b811480159061032b57508060ff16601c14155b1561038c5760405162461bcd60e51b815260206004820152603b602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c756500000000006064820152608401610157565b60408051600081526020810180835289905260ff83169181019190915260608101849052608081018390526001600160a01b0389169060019060a0016020604051602081039080840390855afa1580156103ea573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149450505050505b9392505050565b600060208251101561041d57600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b038116811461045857600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561048c578181015183820152602001610474565b50506000910152565b600082601f8301126104a657600080fd5b81516001600160401b038111156104bf576104bf61045b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156104ed576104ed61045b565b60405281815283820160200185101561050557600080fd5b610516826020830160208701610471565b949350505050565b60008060006060848
4603121561053357600080fd5b835161053e81610443565b6020850151604086015191945092506001600160401b0381111561056157600080fd5b61056d86828701610495565b9150509250925092565b60008060006060848603121561058c57600080fd5b835161059781610443565b60208501519093506001600160401b038111156105b357600080fd5b6105bf86828701610495565b604086015190935090506001600160401b0381111561056157600080fd5b600082516105ef818460208701610471565b9190910192915050565b828152604060208201526000825180604084015261061e816060850160208701610471565b601f01601f1916919091016060019392505050565b60006020828403121561064557600080fd5b81516001600160e01b03198116811461040557600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572",r.universalSignatureValidatorAbi=[{inputs:[{name:"_signer",type:"address"},{name:"_hash",type:"bytes32"},{name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"},{inputs:[{name:"_signer",type:"address"},{name:"_hash",type:"bytes32"},{name:"_signature",type:"bytes"}],outputs:[{type:"bool"}],stateMutability:"nonpayable",type:"function",name:"isValidSig"}];class c extends i.BaseError{constructor(e){super(`Value \`${e}\` is an invalid ERC-6492 wrapped signature.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SignatureErc6492.InvalidWrappedSignatureError"})}}r.InvalidWrappedSignatureError=c},405152,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.SignatureErc6492=void 0,r.SignatureErc6492=e.r(356539)},802567,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeSignature=function(e){let{r:t,s:r,to:o="hex",v:s,yParity:c}=e,u=(()=>{if(0===c||1===c)return c;if(s&&(27n===s||28n===s||s>=35n))return+(s%2n===0n);throw Error("Invalid `v` or `yParity` value")})(),l=`0x${new n.secp256k1.Signature((0,i.hexToBigInt)(t),(0,i.hexToBigInt)(r)).toCompactHex()}${0===u?"1b":"1c"}`;return"hex"===o?l:(0,a.hexToBytes)(l)};let n=e.r(759854),i=e.r(723223),a=e.r(935603)},504644,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifyHash=x,r.verifyErc8010=A,r.verifyErc1271=T;let n=e.r(405152),i=e.r(163964),a=e.r(277779),o=e.r(286776),s=e.r(720794),c=e.r(286717),u=e.r(804943),l=e.r(929544),d=e.r(359389),f=e.r(234696),p=e.r(985269),h=e.r(528137),m=e.r(723223),b=e.r(850815),y=e.r(388012),g=e.r(935083),v=e.r(802567),w=e.r(707041),E=e.r(635437),P=e.r(465300);async function x(e,t){let r,{address:n,chain:a=e.chain,hash:o,erc6492VerifierAddress:s=t.universalSignatureVerifierAddress??a?.contracts?.erc6492Verifier?.address,multicallAddress:c=t.multicallAddress??a?.contracts?.multicall3?.address,mode:u="auto"}=t;if(a?.verifyHash)return await a.verifyHash(e,t);let f=(r=t.signature,(0,h.isHex)(r)?r:"object"==typeof r&&"r"in r&&"s"in r?(0,v.serializeSignature)(r):(0,b.bytesToHex)(r));try{if("eoa"===u)try{if((0,d.isAddressEqual)((0,l.getAddress)(n),await (0,g.recoverAddress)({hash:o,signature:f})))return!0}catch{}if(i.SignatureErc8010.validate(f))return await A(e,{...t,multicallAddress:c,signature:f});return await I(e,{...t,verifierAddress:s,signature:f})}catch(e){if("eoa"!==u)try{if((0,d.isAddressEqual)((0,l.getAddress)(n),await (0,g.recoverAddress)({hash:o,signature:f})))return!0}catch{}if(e instanceof S)return!1;throw e}}async function A(e,t){let{address:r,blockNumber:n,blockTag:s,hash:c,multicallAddress:l}=t,{authorization:d,data:h,signature:m,to:g}=i.SignatureErc8010.unwrap(t.signature);if(await (0,E.getCode)(e,{address:r,blockNumber:n,blockTag:s})===(0,p.concatHex)(["0xef0100",d.address]))return await T(e,{address:r,blockNumber:n,blockTag:s,hash:c,signature:m});let v={address:d.address,chainId:Number(d.chainId),nonce:Number(d.nonce),r:(0,b.numberToHex)(d.r,{size:32}),s:(0,b.numberToHex)(d.s,{size:32}),yParity:d.yParity};if(!await (0,f.verifyAuthorization)({address:r,authorization:v}))throw new S;let w=await (0,y.getAction)(e,P.readContract,"readContract")({...l?{address:l}:{code:o.multicall3Bytecode},authorizationList:[v],abi:a.multicall3Abi,blockNumber:n,blockTag:"pending",functionName:"aggregate3",args:[[...h?[{allowFailure:!0,target:g??r,callData:h}
4]:[],{allowFailure:!0,target:r,callData:(0,u.encodeFunctionData)({abi:a.erc1271Abi,functionName:"isValidSignature",args:[c,m]})}]]}),x=w[w.length-1]?.returnData;if(x?.startsWith("0x1626ba7e"))return!0;throw new S}async function I(e,t){let{address:r,factory:i,factoryData:l,hash:d,signature:f,verifierAddress:p,...h}=t,b=await (async()=>!i&&!l||n.SignatureErc6492.validate(f)?f:n.SignatureErc6492.wrap({data:l,signature:f,to:i}))(),g=p?{to:p,data:(0,u.encodeFunctionData)({abi:a.erc6492SignatureValidatorAbi,functionName:"isValidSig",args:[r,d,b]}),...h}:{data:(0,c.encodeDeployData)({abi:a.erc6492SignatureValidatorAbi,args:[r,d,b],bytecode:o.erc6492SignatureValidatorByteCode}),...h},{data:v}=await (0,y.getAction)(e,w.call,"call")(g).catch(e=>{if(e instanceof s.CallExecutionError)throw new S;throw e});if((0,m.hexToBool)(v??"0x0"))return!0;throw new S}async function T(e,t){let{address:r,blockNumber:n,blockTag:i,hash:o,signature:c}=t;if((await (0,y.getAction)(e,P.readContract,"readContract")({address:r,abi:a.erc1271Abi,args:[o,c],blockNumber:n,blockTag:i,functionName:"isValidSignature"}).catch(e=>{if(e instanceof s.ContractFunctionExecutionError)throw new S;throw e})).startsWith("0x1626ba7e"))return!0;throw new S}class S extends Error{}},990833,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifyMessage=o;let n=e.r(388012),i=e.r(349779),a=e.r(504644);async function o(e,t){let{address:r,message:o,factory:s,factoryData:c,signature:u,...l}=t,d=(0,i.hashMessage)(o);return(0,n.getAction)(e,a.verifyHash,"verifyHash")({address:r,factory:s,factoryData:c,hash:d,signature:u,...l})}},301759,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifyTypedData=o;let n=e.r(388012),i=e.r(102155),a=e.r(504644);async function o(e,t){let{address:r,factory:o,factoryData:s,signature:c,message:u,primaryType:l,types:d,domain:f,...p}=t,h=(0,i.hashTypedData)({message:u,primaryType:l,types:d,domain:f});return(0,n.getAction)(e,a.verifyHash,"verifyHash")({address:r,factory:o,factoryData:s,hash:h,signature:c,...p})}},659915,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.watchBlockNumber=function(e,t){let r,u,l,{emitOnBegin:d=!1,emitMissed:f=!1,onBlockNumber:p,onError:h,poll:m,pollingInterval:b=e.pollingInterval}=t;return(void 0!==m?m:"webSocket"!==e.transport.type&&"ipc"!==e.transport.type&&("fallback"!==e.transport.type||"webSocket"!==e.transport.transports[0].c
4onfig.type&&"ipc"!==e.transport.transports[0].config.type))?(r=(0,s.stringify)(["watchBlockNumber",e.uid,d,f,b]),(0,a.observe)(r,{onBlockNumber:p,onError:h},t=>(0,o.poll)(async()=>{try{let r=await (0,i.getAction)(e,c.getBlockNumber,"getBlockNumber")({cacheTime:0});if(void 0!==l){if(r===l)return;if(r-l>1&&f)for(let e=l+1n;e<r;e++)t.onBlockNumber(e,l),l=e}(void 0===l||r>l)&&(t.onBlockNumber(r,l),l=r)}catch(e){t.onError?.(e)}},{emitOnBegin:d,interval:b}))):(u=(0,s.stringify)(["watchBlockNumber",e.uid,d,f]),(0,a.observe)(u,{onBlockNumber:p,onError:h},t=>{let r=!0,i=()=>r=!1;return(async()=>{try{let a=(()=>{if("fallback"===e.transport.type){let t=e.transport.transports.find(e=>"webSocket"===e.config.type||"ipc"===e.config.type);return t?t.value:e.transport}return e.transport})(),{unsubscribe:o}=await a.subscribe({params:["newHeads"],onData(e){if(!r)return;let i=(0,n.hexToBigInt)(e.result?.number);t.onBlockNumber(i,l),l=i},onError(e){t.onError?.(e)}});i=o,r||i()}catch(e){h?.(e)}})(),()=>i()}))};let n=e.r(723223),i=e.r(388012),a=e.r(457727),o=e.r(319573),s=e.r(905241),c=e.r(789238)},364122,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.waitForTransactionReceipt=h;let n=e.r(201648),i=e.r(341289),a=e.r(388012),o=e.r(457727),s=e.r(205616),c=e.r(607327),u=e.r(905241),l=e.r(578346),d=e.r(571615),f=e.r(755388),p=e.r(659915);async function h(e,t){let r,h,m,b,y,{checkReplacement:g=!0,confirmations:v=1,hash:w,onReplaced:E,retryCount:P=6,retryDelay:x=e=>{let{count:t}=e;return 200*~~(1<<t)},timeout:A=18e4}=t,I=(0,u.stringify)(["waitForTransactionReceipt",e.uid,w]),T=t.pollingInterval?t.pollingInterval:e.chain?.experimental_preconfirmationTime?e.chain.experimental_preconfirmationTime:e.pollingInterval,S=!1,{promise:C,resolve:O,reject:j}=(0,s.withResolvers)(),k=A?setTimeout(()=>{y?.(),b?.(),j(new i.WaitForTransactionReceiptTimeoutError({hash:w}))},A):void 0;return b=(0,o.observe)(I,{onReplaced:E,resolve:O,reject:j},async t=>{if((m=await (0,a.getAction)(e,f.getTransactionReceipt,"getTransactionReceipt")({hash:w}).catch(()=>void 0))&&v<=1){clearTimeout(k),t.resolve(m),b?.();return}y=(0,a.getAction)(e,p.watchBlockNumber,"watchBlockNumber")({emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:T,async onBlockNumber(o){let s=e=>{clearTimeout(k),y?.(),e(),b?.()},u=o;if(!S)try{if(m){if(v>1&&(!m.blockNumber||u-m.blockNumber+1n<v))return;s(()=>t.resolve(m));return}if(g&&!r&&(S=!0,await (0,c.withRetry)(async()=>{(r=await (0,a.getAction)(e,d.getTransaction,"getTransaction")({hash:w})).blockNumber&&(u=r.blockNumber)},{delay:x,retryCount:P}),S=!1),m=await (0,a.getAction)(e,f.getTransactionReceipt,"getTransactionReceipt")({hash:w}),v>1&&(!m.blockNumber||u-m.blockNumber+1n<v))return;s(()=>t.resolve(m))}catch(o){if(o instanceof i.TransactionNotFoundError||o instanceof i.TransactionReceiptNotFoundError){if(!r){S=!1;return}try{h=r,S=!0;let i=await (0,c.withRetry)(()=>(0,a.getAction)(e,l.getBlock,"getBlock")({blockNumber:u,includeTransactions:!0}),{delay:x,retryCount:P,shouldRetry:e=>{let{error:t}=e;return t instanceof n.BlockNotFoundError}});S=!1;let o=i.transactions.find(e=>{let{from:t,nonce:r}=e;return t===h.from&&r===h.nonce});if(!o||(m=await (0,a.getAction)(e,f.getTransactionReceipt,"getTransactionReceipt")({hash:o.hash}),v>1&&(!m.blockNumber||u-m.blockNumber+1n<v)))return;let d="replaced";o.to===h.to&&o.value===h.value&&o.input===h.input?d="repriced":o.from===o.to&&0n===o.value&&(d="cancelled"),s(()=>{t.onReplaced?.({reason:d,replacedTransaction:h,transaction:o,transactionReceipt:m}),t.resolve(m)})}catch(e){s(()=>t.reject(e))}}else s(()=>t.reject(o))}}})}),C}},4071,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.watchBlocks=function(e,t){let r,c,u,l,d,{blockTag:f=e.experimental_blockTag??"latest",emitMissed:p=!1,emitOnBegin:h=!1,onBlock:m,onError:b,includeTransactions:y,poll:g,pollingInterval:v=e.pollingInterval}=t,w=void 0!==g?g:"webSocket"!==e.transport.type&&"ipc"!==e.transport.type&&("fallback"!==e.transport.type||"webSocket"!==e.transport.transports[0].c
4onfig.type&&"ipc"!==e.transport.transports[0].config.type),E=y??!1;return w?(r=(0,o.stringify)(["watchBlocks",e.uid,f,p,h,E,v]),(0,i.observe)(r,{onBlock:m,onError:b},t=>(0,a.poll)(async()=>{try{let r=await (0,n.getAction)(e,s.getBlock,"getBlock")({blockTag:f,includeTransactions:E});if(null!==r.number&&d?.number!=null){if(r.number===d.number)return;if(r.number-d.number>1&&p)for(let i=d?.number+1n;i<r.number;i++){let r=await (0,n.getAction)(e,s.getBlock,"getBlock")({blockNumber:i,includeTransactions:E});t.onBlock(r,d),d=r}}(d?.number==null||"pending"===f&&r?.number==null||null!==r.number&&r.number>d.number)&&(t.onBlock(r,d),d=r)}catch(e){t.onError?.(e)}},{emitOnBegin:h,interval:v}))):(c=!0,u=!0,l=()=>c=!1,(async()=>{try{h&&(0,n.getAction)(e,s.getBlock,"getBlock")({blockTag:f,includeTransactions:E}).then(e=>{!c||u&&(m(e,void 0),u=!1)}).catch(b);let t=(()=>{if("fallback"===e.transport.type){let t=e.transport.transports.find(e=>"webSocket"===e.config.type||"ipc"===e.config.type);return t?t.value:e.transport}return e.transport})(),{unsubscribe:r}=await t.subscribe({params:["newHeads"],async onData(t){if(!c)return;let r=await (0,n.getAction)(e,s.getBlock,"getBlock")({blockNumber:t.result?.number,includeTransactions:E}).catch(()=>{});c&&(m(r,d),u=!1,d=r)},onError(e){b?.(e)}});l=r,c||l()}catch(e){b?.(e)}})(),()=>l())};let n=e.r(388012),i=e.r(457727),a=e.r(319573),o=e.r(905241),s=e.r(578346)},377784,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.watchEvent=function(e,t){let r,y,g,{address:v,args:w,batch:E=!0,event:P,events:x,fromBlock:A,onError:I,onLogs:T,poll:S,pollingInterval:C=e.pollingInterval,strict:O}=t,j=void 0!==S?S:"bigint"==typeof A||"webSocket"!==e.transport.type&&"ipc"!==e.transport.type&&("fallback"!==e.transport.type||"webSocket"!==e.transport.transports[0].c
4onfig.type&&"ipc"!==e.transport.transports[0].config.type),k=O??!1;return j?(r=(0,d.stringify)(["watchEvent",v,w,E,e.uid,P,C,A]),(0,u.observe)(r,{onLogs:T,onError:I},t=>{let r,n;void 0!==A&&(r=A-1n);let a=!1,o=(0,l.poll)(async()=>{if(!a){try{n=await (0,c.getAction)(e,f.createEventFilter,"createEventFilter")({address:v,args:w,event:P,events:x,strict:k,fromBlock:A})}catch{}a=!0;return}try{let i;if(n)i=await (0,c.getAction)(e,h.getFilterChanges,"getFilterChanges")({filter:n});else{let t=await (0,c.getAction)(e,p.getBlockNumber,"getBlockNumber")({});i=r&&r!==t?await (0,c.getAction)(e,m.getLogs,"getLogs")({address:v,args:w,event:P,events:x,fromBlock:r+1n,toBlock:t}):[],r=t}if(0===i.length)return;if(E)t.onLogs(i);else for(let e of i)t.onLogs([e])}catch(e){n&&e instanceof i.InvalidInputRpcError&&(a=!1),t.onError?.(e)}},{emitOnBegin:!0,interval:C});return async()=>{n&&await (0,c.getAction)(e,b.uninstallFilter,"uninstallFilter")({filter:n}),o()}})):(y=!0,g=()=>y=!1,(async()=>{try{let t=(()=>{if("fallback"===e.transport.type){let t=e.transport.transports.find(e=>"webSocket"===e.config.type||"ipc"===e.config.type);return t?t.value:e.transport}return e.transport})(),r=x??(P?[P]:void 0),i=[];r&&(i=[r.flatMap(e=>(0,o.encodeEventTopics)({abi:[e],eventName:e.name,args:w}))],P&&(i=i[0]));let{unsubscribe:c}=await t.subscribe({params:["logs",{address:v,topics:i}],onData(e){if(!y)return;let t=e.result;try{let{eventName:e,args:n}=(0,a.decodeEventLog)({abi:r??[],data:t.data,topics:t.topics,strict:k}),i=(0,s.formatLog)(t,{args:n,eventName:e});T([i])}catch(a){let e,r;if(a instanceof n.DecodeLogDataMismatch||a instanceof n.DecodeLogTopicsMismatch){if(O)return;e=a.abiItem.name,r=a.abiItem.inputs?.some(e=>!("name"in e&&e.name))}let i=(0,s.formatLog)(t,{args:r?[]:{},eventName:e});T([i])}},onError(e){I?.(e)}});g=c,y||g()}catch(e){I?.(e)}})(),()=>g())};let n=e.r(963101),i=e.r(477323),a=e.r(197532),o=e.r(725159),s=e.r(798336),c=e.r(388012),u=e.r(457727),l=e.r(319573),d=e.r(905241),f=e.r(986756),p=e.r(789238),h=e.r(430147),m=e.r(417928),b=e.r(275863)},220704,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.watchPendingTransactions=function(e,t){let r,l,d,{batch:f=!0,onError:p,onTransactions:h,poll:m,pollingInterval:b=e.pollingInterval}=t;return(void 0!==m?m:"webSocket"!==e.transport.type&&"ipc"!==e.transport.type)?(r=(0,o.stringify)(["watchPendingTransactions",e.uid,f,b]),(0,i.observe)(r,{onTransactions:h,onError:p},t=>{let r,i=(0,a.poll)(async()=>{try{if(!r)try{r=await (0,n.getAction)(e,s.createPendingTransactionFilter,"createPendingTransactionFilter")({});return}catch(e){throw i(),e}let a=await (0,n.getAction)(e,c.getFilterChanges,"getFilterChanges")({filter:r});if(0===a.length)return;if(f)t.onTransactions(a);else for(let e of a)t.onTransactions([e])}catch(e){t.onError?.(e)}},{emitOnBegin:!0,interval:b});return async()=>{r&&await (0,n.getAction)(e,u.uninstallFilter,"uninstallFilter")({filter:r}),i()}})):(l=!0,d=()=>l=!1,(async()=>{try{let{unsubscribe:t}=await e.transport.subscribe({params:["newPendingTransactions"],onData(e){if(!l)return;let t=e.result;h([t])},onError(e){p?.(e)}});d=t,l||d()}catch(e){p?.(e)}})(),()=>d())};let n=e.r(388012),i=e.r(457727),a=e.r(319573),o=e.r(905241),s=e.r(902178),c=e.r(430147),u=e.r(275863)},988911,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseSiweMessage=function(e){let{scheme:t,statement:r,...a}=e.match(n)?.groups??{},{chainId:o,expirationTime:s,issuedAt:c,notBefore:u,requestId:l,...d}=e.match(i)?.groups??{},f=e.split("Resources:")[1]?.split("\n- ").slice(1);return{...a,...d,...o?{chainId:Number(o)}:{},...s?{expirationTime:new Date(s)}:{},...c?{issuedAt:new Date(c)}:{},...u?{notBefore:new Date(u)}:{},...l?{requestId:l}:{},...f?{resources:f}:{},...t?{scheme:t}:{},...r?{statement:r}:{}}};let n=/^(?:(?<scheme>[a-zA-Z][a-zA-Z0-9+-.]*):\/\/)?(?<domain>[a-zA-Z0-9+-.]*(?::[0-9]{1,5})?) (?:wants you to sign in with your Ethereum account:\n)(?<address>0x[a-fA-F0-9]{40})\n\n(?:(?<statement>.*)\n\n)?/,i=/(?:URI: (?<uri>.+))\n(?:Version: (?<version>.+))\n(?:Chain ID: (?<chainId>\d+))\n(?:Nonce: (?<nonce>[a-zA-Z0-9]+))\n(?:Issued At: (?<issuedAt>.+))(?:\nExpiration Time: (?<expirationTime>.+))?(?:\nNot Before: (?<notBefore>.+))?(?:\nRequest ID: (?<requestId>.+))?/},279517,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.validateSiweMessage=function(e){let{address:t,domain:r,message:a,nonce:o,scheme:s,time:c=new Date}=e;if(r&&a.domain!==r||o&&a.nonce!==o||s&&a.scheme!==s||a.expirationTime&&c>=a.expirationTime||a.notBefore&&c<a.notBefore)return!1;try{if(!a.address||!(0,n.isAddress)(a.address,{strict:!1})||t&&!(0,i.isAddressEqual)(a.address,t))return!1}catch{return!1}return!0};let n=e.r(429625),i=e.r(359389)},601642,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifySiweMessage=s;let n=e.r(349779),i=e.r(988911),a=e.r(279517),o=e.r(504644);async function s(e,t){let{address:r,domain:s,message:c,nonce:u,scheme:l,signature:d,time:f=new Date,...p}=t,h=(0,i.parseSiweMessage)(c);if(!h.address||!(0,a.validateSiweMessage)({address:r,domain:s,message:h,nonce:u,scheme:l,time:f}))return!1;let m=(0,n.hashMessage)(c);return(0,o.verifyHash)(e,{address:h.address,hash:m,signature:d,...p})}},456159,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.sendRawTransactionSync=a;let n=e.r(341289),i=e.r(941403);async function a(e,t){let{serializedTransaction:r,throwOnReceiptRevert:a,timeout:o}=t,s=await e.request({method:"eth_sendRawTransactionSync",params:o?[r,o]:[r]},{retryCount:0}),c=(e.chain?.formatters?.transactionReceipt?.format||i.formatTransactionReceipt)(s);if("reverted"===c.status&&a)throw new n.TransactionReceiptRevertedError({receipt:c});return c}},645861,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.publicActions=function(e){return{call:t=>(0,c.call)(e,t),createAccessList:t=>(0,u.createAccessList)(e,t),createBlockFilter:()=>(0,l.createBlockFilter)(e),createContractEventFilter:t=>(0,d.createContractEventFilter)(e,t),createEventFilter:t=>(0,f.createEventFilter)(e,t),createPendingTransactionFilter:()=>(0,p.createPendingTransactionFilter)(e),estimateContractGas:t=>(0,h.estimateContractGas)(e,t),estimateGas:t=>(0,b.estimateGas)(e,t),getBalance:t=>(0,v.getBalance)(e,t),getBlobBaseFee:()=>(0,w.getBlobBaseFee)(e),getBlock:t=>(0,E.getBlock)(e,t),getBlockNumber:t=>(0,P.getBlockNumber)(e,t),getBlockTransactionCount:t=>(0,x.getBlockTransactionCount)(e,t),getBytecode:t=>(0,I.getCode)(e,t),getChainId:()=>(0,A.getChainId)(e),getCode:t=>(0,I.getCode)(e,t),getContractEvents:t=>(0,T.getContractEvents)(e,t),getDelegation:t=>(0,S.getDelegation)(e,t),getEip712Domain:t=>(0,C.getEip712Domain)(e,t),getEnsAddress:t=>(0,n.getEnsAddress)(e,t),getEnsAvatar:t=>(0,i.getEnsAvatar)(e,t),getEnsName:t=>(0,a.getEnsName)(e,t),getEnsResolver:t=>(0,o.getEnsResolver)(e,t),getEnsText:t=>(0,s.getEnsText)(e,t),getFeeHistory:t=>(0,O.getFeeHistory)(e,t),estimateFeesPerGas:t=>(0,m.estimateFeesPerGas)(e,t),getFilterChanges:t=>(0,j.getFilterChanges)(e,t),getFilterLogs:t=>(0,k.getFilterLogs)(e,t),getGasPrice:()=>(0,R.getGasPrice)(e),getLogs:t=>(0,_.getLogs)(e,t),getProof:t=>(0,B.getProof)(e,t),estimateMaxPriorityFeePerGas:t=>(0,y.estimateMaxPriorityFeePerGas)(e,t),fillTransaction:t=>(0,g.fillTransaction)(e,t),getStorageAt:t=>(0,M.getStorageAt)(e,t),getTransaction:t=>(0,F.getTransaction)(e,t),getTransactionConfirmations:t=>(0,N.getTransactionConfirmations)(e,t),getTransactionCount:t=>(0,U.getTransactionCount)(e,t),getTransactionReceipt:t=>(0,H.getTransactionReceipt)(e,t),multicall:t=>(0,z.multicall)(e,t),prepareTransactionRequest:t=>(0,er.prepareTransactionRequest)(e,t),readContract:t=>(0,L.readContract)(e,t),sendRawTransaction:t=>(0,en.sendRawTransaction)(e,t),sendRawTransactionSync:t=>(0,ei.sendRawTransactionSync)(e,t),simulate:t=>(0,D.simulateBlocks)(e,t),simulateBlocks:t=>(0,D.simulateBlocks)(e,t),simulateCalls:t=>(0,$.simulateCalls)(e,t),simulateContract:t=>(0,q.simulateContract)(e,t),verifyHash:t=>(0,G.verifyHash)(e,t),verifyMessage:t=>(0,K.verifyMessage)(e,t),verifySiweMessage:t=>(0,et.verifySiweMessage)(e,t),verifyTypedData:t=>(0,V.verifyTypedData)(e,t),uninstallFilter:t=>(0,W.uninstallFilter)(e,t),waitForTransactionReceipt:t=>(0,J.waitForTransactionReceipt)(e,t),watchBlocks:t=>(0,Q.watchBlocks)(e,t),watchBlockNumber:t=>(0,Z.watchBlockNumber)(e,t),watchContractEvent:t=>(0,Y.watchContractEvent)(e,t),watchEvent:t=>(0,X.watchEvent)(e,t),watchPendingTransactions:t=>(0,ee.watchPendingTransactions)(e,t)}};let n=e.r(93164),i=e.r(294686),a=e.r(508311),o=e.r(678355),s=e.r(582007),c=e.r(707041),u=e.r(490546),l=e.r(157707),d=e.r(627977),f=e.r(986756),p=e.r(902178),h=e.r(400744),m=e.r(965094),b=e.r(434032),y=e.r(870256),g=e.r(655267),v=e.r(888342),w=e.r(99944),E=e.r(578346),P=e.r(789238),x=e.r(862865),A=e.r(865654),I=e.r(635437),T=e.r(640653),S=e.r(384136),C=e.r(685067),O=e.r(255606),j=e.r(430147),k=e.r(464404),R=e.r(679790),_=e.r(417928),B=e.r(61078),M=e.r(835367),F=e.r(571615),N=e.r(95005),U=e.r(114488),H=e.r(755388),z=e.r(25213),L=e.r(465300),D=e.r(318309),$=e.r(599587),q=e.r(44592),W=e.r(275863),G=e.r(504644),K=e.r(990833),V=e.r(301759),J=e.r(364122),Z=e.r(659915),Q=e.r(4071),Y=e.r(898019),X=e.r(377784),ee=e.r(220704),et=e.r(601642),er=e.r(113211),en=e.r(535188),ei=e.r(456159)},922563,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.createPublicClient=function(e){let{key:t="public",name:r="Public Client"}=e;return(0,n.createClient)({...e,key:t,name:r,type:"publicClient"}).extend(i.publicActions)};let n=e.r(466543),i=e.r(645861)},278567,(e,t,r)=>{"use strict";async function n(e,t){let{hash:r}=t;await e.request({method:`${e.mode}_dropTransaction`,params:[r]})}Object.defineProperty(r,"__esModule",{value:!0}),r.dropTransaction=n},895359,(e,t,r)=>{"use strict";async function n(e){return e.request({method:`${e.mode}_dumpState`})}Object.defineProperty(r,"__esModule",{value:!0}),r.dumpState=n},61353,(e,t,r)=>{"use strict";async function n(e){return"ganache"===e.mode?await e.request({method:"eth_mining"}):await e.request({method:`${e.mode}_getAutomine`})}Object.defineProperty(r,"__esModule",{value:!0}),r.getAutomine=n},698650,(e,t,r)=>{"use strict";async function n(e){return await e.request({method:"txpool_content"})}Object.defineProperty(r,"__esModule",{value:!0}),r.getTxpoolContent=n},767469,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getTxpoolStatus=i;let n=e.r(723223);async function i(e){let{pending:t,queued:r}=await e.request({method:"txpool_status"});return{pending:(0,n.hexToNumber)(t),queued:(0,n.hexToNumber)(r)}}},928927,(e,t,r)=>{"use strict";async function n(e,t){let{address:r}=t;await e.request({method:`${e.mode}_impersonateAccount`,params:[r]})}Object.defineProperty(r,"__esModule",{value:!0}),r.impersonateAccount=n},936322,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.increaseTime=i;let n=e.r(850815);async function i(e,t){let{seconds:r}=t;return await e.request({method:"evm_increaseTime",params:[(0,n.numberToHex)(r)]})}},249282,(e,t,r)=>{"use strict";async function n(e){return await e.request({method:"txpool_inspect"})}Object.defineProperty(r,"__esModule",{value:!0}),r.inspectTxpool=n},214134,(e,t,r)=>{"use strict";async function n(e,t){let{state:r}=t;await e.request({method:`${e.mode}_loadState`,params:[r]})}Object.defineProperty(r,"__esModule",{value:!0}),r.loadState=n},682104,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.mine=i;let n=e.r(850815);async function i(e,t){let{blocks:r,interval:i}=t;"ganache"===e.mode?await e.request({method:"evm_mine",params:[{blocks:(0,n.numberToHex)(r)}]}):await e.request({method:`${e.mode}_mine`,params:[(0,n.numberToHex)(r),(0,n.numberToHex)(i||0)]})}},324881,(e,t,r)=>{"use strict";async function n(e){await e.request({method:`${e.mode}_removeBlockTimestampInterval`})}Object.defineProperty(r,"__esModule",{value:!0}),r.removeBlockTimestampInterval=n},745904,(e,t,r)=>{"use strict";async function n(e){let{blockNumber:t,jsonRpcUrl:r}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};await e.request({method:`${e.mode}_reset`,params:[{forking:{blockNumber:Number(t),jsonRpcUrl:r}}]})}Object.defineProperty(r,"__esModule",{value:!0}),r.reset=n},640285,(e,t,r)=>{"use strict";async function n(e,t){let{id:r}=t;await e.request({method:"evm_revert",params:[r]})}Object.defineProperty(r,"__esModule",{value:!0}),r.revert=n},559023,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.sendUnsignedTransaction=a;let n=e.r(106636),i=e.r(244319);async function a(e,t){let{accessList:r,data:a,from:o,gas:s,gasPrice:c,maxFeePerGas:u,maxPriorityFeePerGas:l,nonce:d,to:f,value:p,...h}=t,m=e.chain?.formatters?.transactionRequest?.format,b=(m||i.formatTransactionRequest)({...(0,n.extract)(h,{format:m}),accessList:r,data:a,from:o,gas:s,gasPrice:c,maxFeePerGas:u,maxPriorityFeePerGas:l,nonce:d,to:f,value:p},"sendUnsignedTransaction");return await e.request({method:"eth_sendUnsignedTransaction",params:[b]})}},604970,(e,t,r)=>{"use strict";async function n(e,t){"ganache"===e.mode?t?await e.request({method:"miner_start"}):await e.request({method:"miner_stop"}):await e.request({method:"evm_setAutomine",params:[t]})}Object.defineProperty(r,"__esModule",{value:!0}),r.setAutomine=n},252359,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.setBalance=i;let n=e.r(850815);async function i(e,t){let{address:r,value:i}=t;"ganache"===e.mode?await e.request({method:"evm_setAccountBalance",params:[r,(0,n.numberToHex)(i)]}):await e.request({method:`${e.mode}_setBalance`,params:[r,(0,n.numberToHex)(i)]})}},195892,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.setBlockGasLimit=i;let n=e.r(850815);async function i(e,t){let{gasLimit:r}=t;await e.request({method:"evm_setBlockGasLimit",params:[(0,n.numberToHex)(r)]})}},195594,(e,t,r)=>{"use strict";async function n(e,t){let{interval:r}=t,n="hardhat"===e.mode?1e3*r:r;await e.request({method:`${e.mode}_setBlockTimestampInterval`,params:[n]})}Object.defineProperty(r,"__esModule",{value:!0}),r.setBlockTimestampInterval=n},796815,(e,t,r)=>{"use strict";async function n(e,t){let{address:r,bytecode:n}=t;"ganache"===e.mode?await e.request({method:"evm_setAccountCode",params:[r,n]}):await e.request({method:`${e.mode}_setCode`,params:[r,n]})}Object.defineProperty(r,"__esModule",{value:!0}),r.setCode=n},240643,(e,t,r)=>{"use strict";async function n(e,t){let{address:r}=t;await e.request({method:`${e.mode}_setCoinbase`,params:[r]})}Object.defineProperty(r,"__esModule",{value:!0}),r.setCoinbase=n},77636,(e,t,r)=>{"use strict";async function n(e,t){let{interval:r}=t,n="hardhat"===e.mode?1e3*r:r;await e.request({method:"evm_setIntervalMining",params:[n]})}Object.defineProperty(r,"__esModule",{value:!0}),r.setIntervalMining=n},33194,(e,t,r)=>{"use strict";async function n(e,t){await e.request({method:`${e.mode}_setLoggingEnabled`,params:[t]})}Object.defineProperty(r,"__esModule",{value:!0}),r.setLoggingEnabled=n},540616,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.setMinGasPrice=i;let n=e.r(850815);async function i(e,t){let{gasPrice:r}=t;await e.request({method:`${e.mode}_setMinGasPrice`,params:[(0,n.numberToHex)(r)]})}},22777,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.setNextBlockBaseFeePerGas=i;let n=e.r(850815);async function i(e,t){let{baseFeePerGas:r}=t;await e.request({method:`${e.mode}_setNextBlockBaseFeePerGas`,params:[(0,n.numberToHex)(r)]})}},681848,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.setNextBlockTimestamp=i;let n=e.r(850815);async function i(e,t){let{timestamp:r}=t;await e.request({method:"evm_setNextBlockTimestamp",params:[(0,n.numberToHex)(r)]})}},570583,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.setNonce=i;let n=e.r(850815);async function i(e,t){let{address:r,nonce:i}=t;await e.request({method:`${e.mode}_setNonce`,params:[r,(0,n.numberToHex)(i)]})}},582626,(e,t,r)=>{"use strict";async function n(e,t){await e.request({method:`${e.mode}_setRpcUrl`,params:[t]})}Object.defineProperty(r,"__esModule",{value:!0}),r.setRpcUrl=n},799788,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.setStorageAt=i;let n=e.r(850815);async function i(e,t){let{address:r,index:i,value:a}=t;await e.request({method:`${e.mode}_setStorageAt`,params:[r,"number"==typeof i?(0,n.numberToHex)(i):i,a]})}},102713,(e,t,r)=>{"use strict";async function n(e){return await e.request({method:"evm_snapshot"})}Object.defineProperty(r,"__esModule",{value:!0}),r.snapshot=n},789012,(e,t,r)=>{"use strict";async function n(e,t){let{address:r}=t;await e.request({method:`${e.mode}_stopImpersonatingAccount`,params:[r]})}Object.defineProperty(r,"__esModule",{value:!0}),r.stopImpersonatingAccount=n},594026,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.testActions=function(e){let{mode:t}=e;return e=>{let r=e.extend(()=>({mode:t}));return{dropTransaction:e=>(0,n.dropTransaction)(r,e),dumpState:()=>(0,i.dumpState)(r),getAutomine:()=>(0,a.getAutomine)(r),getTxpoolContent:()=>(0,o.getTxpoolContent)(r),getTxpoolStatus:()=>(0,s.getTxpoolStatus)(r),impersonateAccount:e=>(0,c.impersonateAccount)(r,e),increaseTime:e=>(0,u.increaseTime)(r,e),inspectTxpool:()=>(0,l.inspectTxpool)(r),loadState:e=>(0,d.loadState)(r,e),mine:e=>(0,f.mine)(r,e),removeBlockTimestampInterval:()=>(0,p.removeBlockTimestampInterval)(r),reset:e=>(0,h.reset)(r,e),revert:e=>(0,m.revert)(r,e),sendUnsignedTransaction:e=>(0,b.sendUnsignedTransaction)(r,e),setAutomine:e=>(0,y.setAutomine)(r,e),setBalance:e=>(0,g.setBalance)(r,e),setBlockGasLimit:e=>(0,v.setBlockGasLimit)(r,e),setBlockTimestampInterval:e=>(0,w.setBlockTimestampInterval)(r,e),setCode:e=>(0,E.setCode)(r,e),setCoinbase:e=>(0,P.setCoinbase)(r,e),setIntervalMining:e=>(0,x.setIntervalMining)(r,e),setLoggingEnabled:e=>(0,A.setLoggingEnabled)(r,e),setMinGasPrice:e=>(0,I.setMinGasPrice)(r,e),setNextBlockBaseFeePerGas:e=>(0,T.setNextBlockBaseFeePerGas)(r,e),setNextBlockTimestamp:e=>(0,S.setNextBlockTimestamp)(r,e),setNonce:e=>(0,C.setNonce)(r,e),setRpcUrl:e=>
4(0,O.setRpcUrl)(r,e),setStorageAt:e=>(0,j.setStorageAt)(r,e),snapshot:()=>(0,k.snapshot)(r),stopImpersonatingAccount:e=>(0,R.stopImpersonatingAccount)(r,e)}}};let n=e.r(278567),i=e.r(895359),a=e.r(61353),o=e.r(698650),s=e.r(767469),c=e.r(928927),u=e.r(936322),l=e.r(249282),d=e.r(214134),f=e.r(682104),p=e.r(324881),h=e.r(745904),m=e.r(640285),b=e.r(559023),y=e.r(604970),g=e.r(252359),v=e.r(195892),w=e.r(195594),E=e.r(796815),P=e.r(240643),x=e.r(77636),A=e.r(33194),I=e.r(540616),T=e.r(22777),S=e.r(681848),C=e.r(570583),O=e.r(582626),j=e.r(799788),k=e.r(102713),R=e.r(789012)},136615,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createTestClient=function(e){let{key:t="test",name:r="Test Client",mode:a}=e;return(0,n.createClient)({...e,key:t,name:r,type:"testClient"}).extend(e=>({mode:a,...(0,i.testActions)({mode:a})(e)}))};let n=e.r(466543),i=e.r(594026)},673652,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.addChain=i;let n=e.r(850815);async function i(e,t){let{chain:r}=t,{id:i,name:a,nativeCurrency:o,rpcUrls:s,blockExplorers:c}=r;await e.request({method:"wallet_addEthereumChain",params:[{chainId:(0,n.numberToHex)(i),chainName:a,nativeCurrency:o,rpcUrls:s.default.http,blockExplorerUrls:c?Object.values(c).map(e=>{let{url:t}=e;return t}):void 0}]},{dedupe:!0,retryCount:0})}},375541,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.deployContract=function(e,t){let{abi:r,args:a,bytecode:o,...s}=t,c=(0,n.encodeDeployData)({abi:r,args:a,bytecode:o});return(0,i.sendTransaction)(e,{...s,...s.authorizationList?{to:null}:{},data:c})};let n=e.r(286717),i=e.r(412731)},548207,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getAddresses=i;let n=e.r(929544);async function i(e){return e.account?.type==="local"?[e.account.address]:(await e.request({method:"eth_accounts"},{dedupe:!0})).map(e=>(0,n.checksumAddress)(e))}},857438,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getCapabilities=a;let n=e.r(155401),i=e.r(850815);async function a(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{account:r=e.account,chainId:a}=t,o=r?(0,n.parseAccount)(r):void 0,s=a?[o?.address,[(0,i.numberToHex)(a)]]:[o?.address],c=await e.request({method:"wallet_getCapabilities",params:s}),u={};for(let[e,t]of Object.entries(c))for(let[r,n]of(u[Number(e)]={},Object.entries(t)))"addSubAccount"===r&&(r="unstable_addSubAccount"),u[Number(e)][r]=n;return"number"==typeof a?u[a]:u}},221995,(e,t,r)=>{"use strict";async function n(e){return await e.request({method:"wallet_getPermissions"},{dedupe:!0})}Object.defineProperty(r,"__esModule",{value:!0}),r.getPermissions=n},174855,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.prepareAuthorization=u;let n=e.r(155401),i=e.r(825478),a=e.r(359389),o=e.r(388012),s=e.r(865654),c=e.r(114488);async function u(e,t){let{account:r=e.account,chainId:u,nonce:l}=t;if(!r)throw new i.AccountNotFoundError({docsPath:"/docs/eip7702/prepareAuthorization"});let d=(0,n.parseAccount)(r),f=(()=>{if(t.executor)return"self"===t.executor?t.executor:(0,n.parseAccount)(t.executor)})(),p={address:t.contractAddress??t.address,chainId:u,nonce:l};return void 0===p.chainId&&(p.chainId=e.chain?.id??await (0,o.getAction)(e,s.getChainId,"getChainId")({})),void 0===p.nonce&&(p.nonce=await (0,o.getAction)(e,c.getTransactionCount,"getTransactionCount")({address:d.address,blockTag:"pending"}),("self"===f||f?.address&&(0,a.isAddressEqual)(f.address,d.address))&&(p.nonce+=1)),p}},764518,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.requestAddresses=i;let n=e.r(929544);async function i(e){return(await e.request({method:"eth_requestAccounts"},{dedupe:!0,retryCount:0})).map(e=>(0,n.getAddress)(e))}},487887,(e,t,r)=>{"use strict";async function n(e,t){return e.request({method:"wallet_requestPermissions",params:[t]},{retryCount:0})}Object.defineProperty(r,"__esModule",{value:!0}),r.requestPermissions=n},678488,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.sendCallsSync=o;let n=e.r(388012),i=e.r(386691),a=e.r(1260);async function o(e,t){let{chain:r=e.chain}=t,o=t.timeout??Math.max((r?.blockTime??0)*3,5e3),s=await (0,n.getAction)(e,i.sendCalls,"sendCalls")(t);return await (0,n.getAction)(e,a.waitForCallsStatus,"waitForCallsStatus")({...t,id:s.id,timeout:o})}},866833,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.sendTransactionSync=E;let n=e.r(155401),i=e.r(825478),a=e.r(91633),o=e.r(341289),s=e.r(271077),c=e.r(389421),u=e.r(985269),l=e.r(724514),d=e.r(106636),f=e.r(244319),p=e.r(388012),h=e.r(170675),m=e.r(854495),b=e.r(865654),y=e.r(364122),g=e.r(113211),v=e.r(456159),w=new h.LruMap(128);async function E(e,t){let{account:r=e.account,assertChainId:h=!0,chain:E=e.chain,accessList:P,authorizationList:x,blobs:A,data:I,dataSuffix:T="string"==typeof e.dataSuffix?e.dataSuffix:e.dataSuffix?.value,gas:S,gasPrice:C,maxFeePerBlobGas:O,maxFeePerGas:j,maxPriorityFeePerGas:k,nonce:R,pollingInterval:_,throwOnReceiptRevert:B,type:M,value:F,...N}=t,U=t.timeout??Math.max((E?.blockTime??0)*3,5e3);if(void 0===r)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/sendTransactionSync"});let H=r?(0,n.parseAccount)(r):null;try{(0,m.assertRequest)(t);let r=await (async()=>t.to?t.to:null!==t.to&&x&&x.length>0?await (0,s.recoverAuthorizationAddress)({authorization:x[0]}).catch(()=>{throw new a.BaseError("`to` is required. Could not infer from `authorizationList`.")}):void 0)();if(H?.type==="json-rpc"||null===H){let t;null!==E&&(t=await (0,p.getAction)(e,b.getChainId,"getChainId")({}),h&&(0,c.assertCurrentChain)({currentChainId:t,chain:E}));let n=e.chain?.formatters?.transactionRequest?.format,i=(n||f.formatTransactionRequest)({...(0,d.extract)(N,{format:n}),accessList:P,account:H,authorizationList:x,blobs:A,chainId:t,data:I?(0,u.concat)([I,T??"0x"]):I,gas:S,gasPrice:C,maxFeePerBlobGas:O,maxFeePerGas:j,maxPriorityFeePerGas:k,nonce:R,to:r,type:M,value:F},"sendTransaction"),a=w.get(e.uid),s=a?"wallet_sendTransaction":"eth_sendTransaction",l=await (async()=>{try{return await e.request({method:s,params:[i]},{retryCount:0})}catch(t){if(!1===a)throw t;if("InvalidInputRpcError"===t.name||"InvalidParamsRpcError"===t.name||"MethodNotFoundRpcError"===t.name||"MethodNotSupportedRpcError"===t.name)return await e.request({method:"wallet_sendTransaction",params:[i]},{retryCount:0}).then(t=>(w.set(e.uid,!0),t)).catch(r=>{if("MethodNotFoundRpcError"===r.name||"MethodNotSupportedRpcError"===r.name)throw w.set(e.uid,!1),t;throw r});throw t}})(),m=await (0,p.getAction)(e,y.waitForTransactionReceipt,"waitForTransactionReceipt")({checkReplacement:!1,hash:l,pollingInterval:_,timeout:U});if(B&&"reverted"===m.status)throw new o.TransactionReceiptRevertedError({receipt:m});return m}if(H?.type==="local"){let n=await (0,p.getAction)(e,g.prepareTransactionRequest,"prepareTransactionRequest")({account:H,accessList:P,authorizationList:x,blobs:A,chain:E,data:I?(0,u.concat)([I,T??"0x"]):I,gas:S,gasPrice:C,maxFeePerBlobGas:O,maxFeePerGas:j,maxPriorityFeePerGas:k,nonce:R,nonceManager:H.nonceManager,parameters:[...g.defaultParameters,"sidecars"],type:M,value:F,...N,to:r}),i=E?.serializers?.transaction,a=await H.signTransaction(n,{serializer:i});return await (0,p.getAction)(e,v.sendRawTransactionSync,"sendRawTransactionSync")({serializedTransaction:a,throwOnReceiptRevert:B,timeout:t.timeout})}if(H?.type==="smart")throw new i.AccountTypeNotSupportedError({metaMessages:["Consider using the `sendUserOperation` Action instead."],docsPath:"/docs/actions/bundler/sendUserOperation",type:"smart"});throw new i.AccountTypeNotSupportedError({docsPath:"/docs/actions/wallet/sendTransactionSync",type:H?.type})}catch(e){if(e instanceof i.AccountTypeNotSupportedError)throw e;throw(0,l.getTransactionError)(e,{...t,account:H,chain:t.chain||void 0})}}},535912,(e,t,r)=>{"use strict";async function n(e,t){let{id:r}=t;await e.request({method:"wallet_showCallsStatus",params:[r]})}Object.defineProperty(r,"__esModule",{value:!0}),r.showCallsStatus=n},709241,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.signAuthorization=o;let n=e.r(155401),i=e.r(825478),a=e.r(174855);async function o(e,t){let{account:r=e.account}=t;if(!r)throw new i.AccountNotFoundError({docsPath:"/docs/eip7702/signAuthorization"});let o=(0,n.parseAccount)(r);if(!o.signAuthorization)throw new i.AccountTypeNotSupportedError({docsPath:"/docs/eip7702/signAuthorization",metaMessages:["The `signAuthorization` Action does not support JSON-RPC Accounts."],type:o.type});let s=await (0,a.prepareAuthorization)(e,t);return o.signAuthorization(s)}},496959,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.signMessage=o;let n=e.r(155401),i=e.r(825478),a=e.r(850815);async function o(e,t){let{account:r=e.account,message:o}=t;if(!r)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/signMessage"});let s=(0,n.parseAccount)(r);if(s.signMessage)return s.signMessage({message:o});let c="string"==typeof o?(0,a.stringToHex)(o):o.raw instanceof Uint8Array?(0,a.toHex)(o.raw):o.raw;return e.request({method:"personal_sign",params:[c,s.address]},{retryCount:0})}},150139,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.signTransaction=d;let n=e.r(155401),i=e.r(825478),a=e.r(389421),o=e.r(850815),s=e.r(244319),c=e.r(388012),u=e.r(854495),l=e.r(865654);async function d(e,t){let{account:r=e.account,chain:d=e.chain,...f}=t;if(!r)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/signTransaction"});let p=(0,n.parseAccount)(r);(0,u.assertRequest)({account:p,...t});let h=await (0,c.getAction)(e,l.getChainId,"getChainId")({});null!==d&&(0,a.assertCurrentChain)({currentChainId:h,chain:d});let m=d?.formatters||e.chain?.formatters,b=m?.transactionRequest?.format||s.formatTransactionRequest;return p.signTransaction?p.signTransaction({...f,chainId:h},{serializer:e.chain?.serializers?.transaction}):await e.request({method:"eth_signTransaction",params:[{...b({...f,account:p},"signTransaction"),chainId:(0,o.numberToHex)(h),from:p.address}]},{retryCount:0})}},805896,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.signTypedData=o;let n=e.r(155401),i=e.r(825478),a=e.r(976056);async function o(e,t){let{account:r=e.account,domain:o,message:s,primaryType:c}=t;if(!r)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/signTypedData"});let u=(0,n.parseAccount)(r),l={EIP712Domain:(0,a.getTypesForEIP712Domain)({domain:o}),...t.types};if((0,a.validateTypedData)({domain:o,message:s,primaryType:c,types:l}),u.signTypedData)return u.signTypedData({domain:o,message:s,primaryType:c,types:l});let d=(0,a.serializeTypedData)({domain:o,message:s,primaryType:c,types:l});return e.request({method:"eth_signTypedData_v4",params:[u.address,d]},{retryCount:0})}},948533,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.switchChain=i;let n=e.r(850815);async function i(e,t){let{id:r}=t;await e.request({method:"wallet_switchEthereumChain",params:[{chainId:(0,n.numberToHex)(r)}]},{retryCount:0})}},195407,(e,t,r)=>{"use strict";async function n(e,t){return await e.request({method:"wallet_watchAsset",params:t},{retryCount:0})}Object.defineProperty(r,"__esModule",{value:!0}),r.watchAsset=n},549457,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.writeContractSync=a;let n=e.r(866833),i=e.r(31073);async function a(e,t){return i.writeContract.internal(e,n.sendTransactionSync,"sendTransactionSync",t)}},14256,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.walletActions=function(e){return{addChain:t=>(0,a.addChain)(e,t),deployContract:t=>(0,o.deployContract)(e,t),fillTransaction:t=>(0,n.fillTransaction)(e,t),getAddresses:()=>(0,s.getAddresses)(e),getCallsStatus:t=>(0,c.getCallsStatus)(e,t),getCapabilities:t=>(0,u.getCapabilities)(e,t),getChainId:()=>(0,i.getChainId)(e),getPermissions:()=>(0,l.getPermissions)(e),prepareAuthorization:t=>(0,d.prepareAuthorization)(e,t),prepareTransactionRequest:t=>(0,f.prepareTransactionRequest)(e,t),requestAddresses:()=>(0,p.requestAddresses)(e),requestPermissions:t=>(0,h.requestPermissions)(e,t),sendCalls:t=>(0,m.sendCalls)(e,t),sendCallsSync:t=>(0,b.sendCallsSync)(e,t),sendRawTransaction:t=>(0,y.sendRawTransaction)(e,t),sendRawTransactionSync:t=>(0,g.sendRawTransactionSync)(e,t),sendTransaction:t=>(0,v.sendTransaction)(e,t),sendTransactionSync:t=>(0,w.sendTransactionSync)(e,t),showCallsStatus:t=>(0,E.showCallsStatus)(e,t),signAuthorization:t=>(0,P.signAuthorization)(e,t),signMessage:t=>(0,x.signMessage)(e,t),signTransaction:t=>(0,A.signTransaction)(e,t),signTypedData:t=>(0,I.signTypedData)(e,t),switchChain:t=>(0,T.switchChain)(e,t),waitForCallsStatus:t=>(0,S.waitForCallsStatus)(e,t),watchAsset:t=>(0,C.watchAsset)(e,t),writeContract:t=>(0,O.writeContract)(e,t),writeContractSync:t=>(0,j.writeContractSync)(e,t)}};let n=e.r(655267),i=e.r(865654),a=e.r(673652),o=e.r(375541),s=e.r(548207),c=e.r(578007),u=e.r(857438),l=e.r(221995),d=e.r(174855),f=e.r(113211),p=e.r(764518),h=e.r(487887),m=e.r(38
46691),b=e.r(678488),y=e.r(535188),g=e.r(456159),v=e.r(412731),w=e.r(866833),E=e.r(535912),P=e.r(709241),x=e.r(496959),A=e.r(150139),I=e.r(805896),T=e.r(948533),S=e.r(1260),C=e.r(195407),O=e.r(31073),j=e.r(549457)},614085,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createWalletClient=function(e){let{key:t="wallet",name:r="Wallet Client",transport:a}=e;return(0,n.createClient)({...e,key:t,name:r,transport:a,type:"walletClient"}).extend(i.walletActions)};let n=e.r(466543),i=e.r(14256)},181255,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createTransport=function(e,t){let{key:r,methods:a,name:o,request:s,retryCount:c=3,retryDelay:u=150,timeout:l,type:d}=e,f=(0,i.uid)();return{config:{key:r,methods:a,name:o,request:s,retryCount:c,retryDelay:u,timeout:l,type:d},request:(0,n.buildRequest)(s,{methods:a,retryCount:c,retryDelay:u,uid:f}),value:t}};let n=e.r(566498),i=e.r(279995)},441533,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.custom=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{key:r="custom",methods:i,name:a="Custom Provider",retryDelay:o}=t;return s=>{let{retryCount:c}=s;return(0,n.createTransport)({key:r,methods:i,name:a,request:e.request.bind(e),retryCount:t.retryCount??c,retryDelay:o,type:"custom"})}};let n=e.r(181255)},577997,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.fallback=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{key:r="fallback",name:n="Fallback",rank:i=!1,shouldThrow:a=s,retryCount:u,retryDelay:l}=t;return t=>{let{chain:s,pollingInterval:d=4e3,timeout:f,...p}=t,h=e,m=()=>{},b=(0,o.createTransport)({key:r,name:n,async request(e){let t,{method:r,params:n}=e,i=async function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,o=h[e]({...p,chain:s,retryCount:0,timeout:f});try{let e=await o.request({method:r,params:n});return m({method:r,params:n,response:e,transport:o,status:"success"}),e}catch(c){if(m({error:c,method:r,params:n,transport:o,status:"error"}),a(c)||e===h.length-1||!(t??=h.slice(e+1).some(e=>{let{include:t,exclude:n}=e({chain:s}).config.methods||{};return t?t.includes(r):!n||!n.includes(r)})))throw c;return i(e+1)}};return i()},retryCount:u,retryDelay:l,type:"fallback"},{onResponse:e=>m=e,transports:h.map(e=>e({chain:s,retryCount:0}))});if(i){let e="object"==typeof i?i:{};c({chain:s,interval:e.interval??d,onTransports:e=>h=e,ping:e.ping,sampleCount:e.sampleCount,timeout:e.timeout,transports:h,weights:e.weights})}return b}},r.shouldThrow=s,r.rankTransports=c;let n=e.r(659641),i=e.r(477323),a=e.r(465273),o=e.r(181255);function s(e){return!!("code"in e&&"number"==typeof e.code&&(e.code===i.TransactionRejectedRpcError.code||e.code===i.UserRejectedRequestError.code||e.code===i.WalletConnectSessionSettlementError.code||n.ExecutionRevertedError.nodeMessage.test(e.message)||5e3===e.code))}function c(e){let{chain:t,interval:r=4e3,onTransports:n,ping:i,sampleCount:o=10,timeout:s=1e3,transports:c,weights:u={}}=e,{stability:l=.7,latency:d=.3}=u,f=[],p=async()=>{let e=await Promise.all(c.map(async e=>{let r,n,a=e({chain:t,retryCount:0,timeout:s}),o=Date.now();try{await (i?i({transport:a}):a.request({method:"net_listening"})),n=1}catch{n=0}finally{r=Date.now()}return{latency:r-o,success:n}}));f.push(e),f.length>o&&f.shift();let u=Math.max(...f.map(e=>Math.max(...e.map(e=>{let{latency:t}=e;return t}))));n(c.map((e,t)=>{let r=f.map(e=>e[t].latency),n=r.reduce((e,t)=>e+t,0)/r.length,i=f.map(e=>e[t].success),a=i.reduce((e,t)=>e+t,0)/i.length;return 0===a?[0,t]:[d*(1-n/u)+l*a,t]}).sort((e,t)=>t[0]-e[0]).map(e=>{let[,t]=e;return c[t]})),await (0,a.wait)(r),p()};p()}},920905,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.UrlRequiredError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor(){super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.",{docsPath:"/docs/clients/intro",name:"UrlRequiredError"})}}r.UrlRequiredError=i},443910,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.http=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{batch:r,fetchFn:c,fetchOptions:u,key:l="http",methods:d,name:f="HTTP JSON-RPC",onFetchRequest:p,onFetchResponse:h,retryDelay:m,raw:b}=t;return y=>{let{chain:g,retryCount:v,timeout:w}=y,{batchSize:E=1e3,wait:P=0}="object"==typeof r?r:{},x=t.retryCount??v,A=w??t.timeout??1e4,I=e||g?.rpcUrls.default.http[0];if(!I)throw new i.UrlRequiredError;let T=(0,o.getHttpRpcClient)(I,{fetchFn:c,fetchOptions:u,onRequest:p,onResponse:h,timeout:A});return(0,s.createTransport)({key:l,methods:d,name:f,async request(e){let{method:t,params:i}=e,o={method:t,params:i},{schedule:s}=(0,a.createBatchScheduler)({id:I,wait:P,shouldSplitBatch:e=>e.length>E,fn:e=>T.request({body:e}),sort:(e,t)=>e.id-t.id}),c=async e=>r?s(e):[await T.request({body:e})],[{error:u,result:l}]=await c(o);if(b)return{error:u,result:l};if(u)throw new n.RpcRequestError({body:o,error:u,url:I});return l},retryCount:x,retryDelay:m,timeout:A,type:"http"},{fetchOptions:u,url:I})}};let n=e.r(666442),i=e.r(920905),a=e.r(125590),o=e.r(237303),s=e.r(181255)},475410,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.webSocket=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{keepAlive:r,key:c="webSocket",methods:u,name:l="WebSocket JSON-RPC",reconnect:d,retryDelay:f}=t;return p=>{let{chain:h,retryCount:m,timeout:b}=p,y=t.retryCount??m,g=b??t.timeout??1e4,v=e||h?.rpcUrls.default.webSocket?.[0],w={keepAlive:r,reconnect:d};if(!v)throw new i.UrlRequiredError;return(0,s.createTransport)({key:c,methods:u,name:l,async request(e){let{method:t,params:r}=e,i={method:t,params:r},a=await (0,o.getWebSocketRpcClient)(v,w),{error:s,result:c}=await a.requestAsync({body:i,timeout:g});if(s)throw new n.RpcRequestError({body:i,error:s,url:v});return c},retryCount:y,retryDelay:f,timeout:g,type:"webSocket"},{getSocket:()=>(0,a.getSocket)(v),getRpcClient:()=>(0,o.getWebSocketRpcClient)(v,w),async subscribe(e){let{params:t,onData:r,onError:n}=e,i=await (0,o.getWebSocketRpcClient)(v,w),{result:a}=await new Promise((e,a)=>i.request({body:{method:"eth_subscribe",params:t},onError(e){a(e),n?.(e)},onResponse(t){if(t.error){a(t.error),n?.(t.error);return}"number"==typeof t.id?e(t):"eth_subscription"===t.method&&r(t.params)}}));return{subscriptionId:a,unsubscribe:async()=>new Promise(e=>i.request({body:{method:"eth_unsubscribe",params:[a]},onResponse:e}))}}})}};let n=e.r(666442),i=e.r(920905),a=e.r(830510),o=e.r(105960),s=e.r(181255)},945905,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.ProviderRpcError=void 0,r.ProviderRpcError=class extends Error{constructor(e,t){super(t),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.code=e,this.details=t}}},312762,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeDeployData=function(e){let{abi:t,bytecode:r,data:o}=e;if(o===r)return{bytecode:r};let s=t.find(e=>"type"in e&&"constructor"===e.type);if(!s)throw new n.AbiConstructorNotFoundError({docsPath:a});if(!("inputs"in s)||!s.inputs||0===s.inputs.length)throw new n.AbiConstructorParamsNotFoundError({docsPath:a});return{args:(0,i.decodeAbiParameters)(s.inputs,`0x${o.replace(r,"")}`),bytecode:r}};let n=e.r(963101),i=e.r(239072),a="/docs/contract/decodeDeployData"},70927,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.fromBlobs=function(e){let t=e.to??("string"==typeof e.blobs[0]?"hex":"bytes"),r="string"==typeof e.blobs[0]?e.blobs.map(e=>(0,i.hexToBytes)(e)):e.blobs,o=r.reduce((e,t)=>e+t.length,0),s=(0,n.createCursor)(new Uint8Array(o)),c=!0;for(let e of r){let t=(0,n.createCursor)(e);for(;c&&t.position<e.length;){t.incrementPosition(1);let r=31;for(let n in e.length-t.position<31&&(r=e.length-t.position),Array.from({length:r})){let e=t.readByte();if(128===e&&!t.inspectBytes(t.remaining).includes(128)){c=!1;break}s.pushByte(e)}}}let u=s.bytes.slice(0,s.position);return"hex"===t?(0,a.bytesToHex)(u):u};let n=e.r(925294),i=e.r(935603),a=e.r(850815)},36817,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.sidecarsToVersionedHashes=function(e){let{sidecars:t,version:r}=e,i=e.to??("string"==typeof t[0].blob?"hex":"bytes"),a=[];for(let{commitment:e}of t)a.push((0,n.commitmentToVersionedHash)({commitment:e,to:i,version:r}));return a};let n=e.r(397856)},643350,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toCoinType=function(e){if(1===e)return 60n;if(e>=0x80000000||e<0)throw new n.EnsInvalidChainIdError({chainId:e});return BigInt((0x80000000|e)>>>0)};let n=e.r(914102)},81148,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.defineKzg=function(e){let{blobToKzgCommitment:t,computeBlobKzgProof:r}=e;return{blobToKzgCommitment:t,computeBlobKzgProof:r}}},125913,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.setupKzg=function(e,t){try{e.loadTrustedSetup(t)}catch(e){if(!e.message.includes("trusted setup is already loaded"))throw e}return(0,n.defineKzg)(e)};let n=e.r(81148)},210428,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.compactSignatureToSignature=function(e){let{r:t,yParityAndS:r}=e,a=(0,n.hexToBytes)(r),o=128&a[0]?1:0;return 1===o&&(a[0]&=127),{r:t,s:(0,i.bytesToHex)(a),yParity:o}};let n=e.r(935603),i=e.r(850815)},67053,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseCompactSignature=function(e){let{r:t,s:r}=n.secp256k1.Signature.fromCompact(e.slice(2,130));return{r:(0,i.numberToHex)(t,{size:32}),yParityAndS:(0,i.numberToHex)(r,{size:32})}};let n=e.r(759854),i=e.r(850815)},307374,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseSignature=function(e){let{r:t,s:r}=n.secp256k1.Signature.fromCompact(e.slice(2,130)),a=Number(`0x${e.slice(130)}`),[o,s]=(()=>{if(0===a||1===a)return[void 0,a];if(27===a)return[BigInt(a),0];if(28===a)return[BigInt(a),1];throw Error("Invalid yParityOrV value")})();return void 0!==o?{r:(0,i.numberToHex)(t,{size:32}),s:(0,i.numberToHex)(r,{size:32}),v:o,yParity:s}:{r:(0,i.numberToHex)(t,{size:32}),s:(0,i.numberToHex)(r,{size:32}),yParity:s}};let n=e.r(759854),i=e.r(850815)},381585,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.recoverTransactionAddress=s;let n=e.r(585457),i=e.r(523060),a=e.r(567328),o=e.r(935083);async function s(e){let{serializedTransaction:t,signature:r}=e,s=(0,i.parseTransaction)(t),c=r??{r:s.r,s:s.s,v:s.v,yParity:s.yParity},u=(0,a.serializeTransaction)({...s,r:void 0,s:void 0,v:void 0,yParity:void 0,sidecars:void 0});return await (0,o.recoverAddress)({hash:(0,n.keccak256)(u),signature:c})}},287273,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeCompactSignature=function(e){let{r:t,yParityAndS:r}=e;return`0x${new n.secp256k1.Signature((0,i.hexToBigInt)(t),(0,i.hexToBigInt)(r)).toCompactHex()}`};let n=e.r(759854),i=e.r(723223)},748582,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.signatureToCompactSignature=function(e){let{r:t,s:r,v:a,yParity:o}=e,s=Number(o??a-27n),c=r;if(1===s){let e=(0,n.hexToBytes)(r);e[0]|=128,c=(0,i.bytesToHex)(e)}return{r:t,yParityAndS:c}};let n=e.r(935603),i=e.r(850815)},996607,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.maxInt8=r.universalSignatureValidatorByteCode=r.erc6492SignatureValidatorByteCode=r.deploylessCallViaFactoryBytecode=r.deploylessCallViaBytecodeBytecode=r.zeroHash=r.zeroAddress=r.ethAddress=r.multicall3Abi=r.universalSignatureValidatorAbi=r.erc6492SignatureValidatorAbi=r.erc4626Abi=r.erc1155Abi=r.erc721Ab
4i=r.erc20Abi_bytes32=r.erc20Abi=r.webSocket=r.http=r.shouldThrow=r.fallback=r.custom=r.createTransport=r.walletActions=r.testActions=r.publicActions=r.createWalletClient=r.createTestClient=r.createPublicClient=r.rpcSchema=r.createClient=r.WaitForCallsStatusTimeoutError=r.getContract=r.UnknownTypeError=r.UnknownSignatureError=r.SolidityProtectedKeywordError=r.parseAbiParameters=r.parseAbiParameter=r.parseAbiItem=r.parseAbi=r.InvalidStructSignatureError=r.InvalidSignatureError=r.InvalidParenthesisError=r.InvalidParameterError=r.InvalidModifierError=r.InvalidFunctionModifierError=r.InvalidAbiTypeParameterError=r.InvalidAbiParametersError=r.InvalidAbiParameterError=r.InvalidAbiItemError=r.CircularReferenceError=void 0,r.maxUint152=r.maxUint144=r.maxUint136=r.maxUint128=r.maxUint120=r.maxUint112=r.maxUint104=r.maxUint96=r.maxUint88=r.maxUint80=r.maxUint72=r.maxUint64=r.maxUint56=r.maxUint48=r.maxUint40=r.maxUint32=r.maxUint24=r.maxUint16=r.maxUint8=r.maxInt256=r.maxInt248=r.maxInt240=r.maxInt232=r.maxInt224=r.maxInt216=r.maxInt208=r.maxInt200=r.maxInt192=r.maxInt184=r.maxInt176=r.maxInt168=r.maxInt160=r.maxInt152=r.maxInt144=r.maxInt136=r.maxInt128=r.maxInt120=r.maxInt112=r.maxInt104=r.maxInt96=r.maxInt88=r.maxInt80=r.maxInt72=r.maxInt64=r.maxInt56=r.maxInt48=r.maxInt40=r.maxInt32=r.maxInt24=r.maxInt16=void 0,r.AbiConstructorNotFoundError=r.weiUnits=r.gweiUnits=r.etherUnits=r.presignMessagePrefix=r.minInt256=r.minInt248=r.minInt240=r.minInt232=r.minInt224=r.minInt216=r.minInt208=r.minInt200=r.minInt192=r.minInt184=r.minInt176=r.minInt168=r.minInt160=r.minInt152=r.minInt144=r.minInt136=r.minInt128=r.minInt120=r.minInt112=r.minInt104=r.minInt96=r.minInt88=r.minInt80=r.minInt72=r.minInt64=r.minInt56=r.minInt48=r.minInt40=r.minInt32=r.minInt24=r.minInt16=r.minInt8=r.maxUint256=r.maxUint248=r.maxUint240=r.maxUint232=r.maxUint224=r.maxUint216=r.maxUint208=r.maxUint200=r.maxUint192=r.maxUint184=r.maxUint176=r.maxUint168=r.maxUint160=void 0,r.EnsAvatarUriResolutionError=r.EnsAvatarUnsupportedNamespaceError=r.EnsAvatarInvalidNftUriError=r.SizeOverflowError=r.InvalidHexValueError=r.InvalidHexBooleanError=r.InvalidBytesBooleanError=r.IntegerOutOfRangeError=r.SliceOffsetOutOfBoundsError=r.SizeExceedsPaddingSizeError=r.RawContractError=r.CounterfactualDeploymentFailedError=r.ContractFunctionZeroDataError=r.ContractFunctionRevertedError=r.ContractFunctionExecutionError=r.CallExecutionError=r.InvalidChainIdError=r.ClientChainNotConfiguredError=r.ChainNotFoundError=r.ChainMismatchError=r.ChainDoesNotSupportContract=r.BundleFailedError=r.BlockNotFoundError=r.setErrorConfig=r.BaseError=r.InvalidAddressError=r.UnsupportedPackedAbiType=r.InvalidDefinitionTypeError=r.InvalidArrayError=r.InvalidAbiEncodingTypeError=r.InvalidAbiDecodingTypeError=r.DecodeLogTopicsMismatch=r.DecodeLogDataMismatch=r.BytesSizeMismatchError=r.AbiFunctionSignatureNotFoundError=r.AbiFunctionOutputsNotFoundError=r.AbiFunctionNotFoundError=r.AbiEventSignatureNotFoundError=r.AbiEventSignatureEmptyTopicsError=r.AbiEventNotFoundError=r.AbiErrorSignatureNotFoundError=r.AbiErrorNotFoundError=r.AbiErrorInputsNotFoundError=r.AbiEncodingLengthMismatchError=r.AbiEncodingBytesSizeMismatchError=r.AbiEncodingArrayLengthMismatchError=r.AbiDecodingZeroDataError=r.AbiDecodingDataSizeTooSmallError=r.AbiDecodingDataSizeInvalidError=r.AbiConstructorParamsNotFoundError=void 0,r.UnsupportedProviderMethodError=r.UnsupportedNonOptionalCapabilityError=r.UnsupportedChainIdError=r.UnknownRpcError=r.UnknownBundleIdError=r.UnauthorizedProviderError=r.TransactionRejectedRpcError=r.SwitchChainError=r.RpcError=r.ResourceUnavailableRpcError=r.ResourceNotFoundRpcError=r.ProviderRpcError=r.ProviderDisconnectedError=r.ParseRpcError=r.MethodNotSupportedRpcError=r.MethodNotFoundRpcError=r.LimitExceededRpcError=r.JsonRpcVersionUnsupportedError=r.InvalidRequestRpcError=r.InvalidParamsRpcError=r.InvalidInputRpcError=r.InternalRpcError=r.DuplicateIdError=r.ChainDisconnectedError=r.BundleTooLargeError=r.AtomicReadyWalletRejectedUpgradeError=r.AtomicityNotSupportedError=r.WebSocketRequestError=r.TimeoutError=r.SocketClosedError=r.RpcRequestError=r.HttpRequestError=r.UnknownNodeError=r.TransactionTypeNotSupportedError=r.TipAboveFeeCapError=r.NonceTooLowError=r.NonceTooHighError=r.NonceMaxValueError=r.IntrinsicGasTooLowError=r.IntrinsicGasTooHighError=r.InsufficientFundsError=r.FeeCapTooLowError=r.FeeCapTooHighError=r.ExecutionRevertedError=r.FilterTypeNotSupportedError=r.MaxFeePerGasTooLowError=r.Eip1559FeesNotSupportedError=r.BaseFeeScalarError=r.EstimateGasExecutionError=r.EnsInvalidChainIdError=void 0,r.toBlobs=r.toBlobSidecars=r.sidecarsToVersionedHashes=r.fromBlobs=r.commitmentToVersionedHash=r.commitmentsToVersionedHashes=r.blobsToProofs=r.blobsToCommitments=r.isAddressEqual=r.isAddress=r.getCreateAddress=r.getCreate2Address=r.getContractAddress=r.getAddress=r.checksumAddress=r.prepareEncodeFunctionData=r.parseEventLogs=r.getAbiItem=r.encodePacked=r.encodeFunctionResult=r.encodeFunctionData=r.encodeEventTopics=r.encodeErrorResult=r.encodeDeployData=r.encodeAbiParameters=r.decodeFunctionResult=r.decodeFunctionData=r.decodeEventLog=r.decodeErrorResult=r.decodeDeployData=r.decodeAbiParameters=r.EIP1193ProviderRpcError=r.InvalidDecimalNumberError=r.InvalidStructTypeError=r.InvalidPrimaryTypeError=r.InvalidDomainError=r.UrlRequiredError=r.WaitForTransactionReceiptTimeoutError=r.TransactionReceiptNotFoundError=r.TransactionNotFoundError=r.TransactionExecutionError=r.InvalidStorageKeySizeError=r.InvalidSerializedTransactionTypeError=r.InvalidSerializedTransactionError=r.InvalidSerializableTransactionError=r.InvalidLegacyVError=r.FeeConflictError=r.StateAssignmentC
4onflictError=r.AccountStateConflictError=r.UserRejectedRequestError=void 0,r.toCoinType=r.namehash=r.labelhash=r.toRlp=r.hexToRlp=r.bytesToRlp=r.toHex=r.stringToHex=r.numberToHex=r.bytesToHex=r.boolToHex=r.toBytes=r.stringToBytes=r.numberToBytes=r.hexToBytes=r.boolToBytes=r.fromRlp=r.hexToString=r.hexToNumber=r.hexToBool=r.hexToBigInt=r.fromHex=r.fromBytes=r.bytesToString=r.bytesToNumber=r.bytesToBool=r.bytesToBigInt=r.trim=r.sliceHex=r.sliceBytes=r.slice=r.size=r.padHex=r.padBytes=r.pad=r.isHex=r.isBytes=r.concatHex=r.concatBytes=r.concat=r.getChainContractAddress=r.extractChain=r.extendSchema=r.defineChain=r.assertCurrentChain=r.offchainLookupSignature=r.offchainLookupAbiItem=r.offchainLookup=r.ccipFetch=r.ccipRequest=void 0,r.recoverTransactionAddress=r.recoverPublicKey=r.recoverMessageAddress=r.recoverAddress=r.parseSignature=r.hexToSignature=r.parseErc8010Signature=r.parseErc6492Signature=r.parseCompactSignature=r.hexToCompactSignature=r.isErc8010Signature=r.isErc6492Signature=r.hashTypedData=r.hashStruct=r.hashDomain=r.hashMessage=r.compactSignatureToSignature=r.withTimeout=r.withRetry=r.withCache=r.nonceManager=r.createNonceManager=r.setupKzg=r.defineKzg=r.getFunctionSignature=r.toFunctionSignature=r.getFunctionSelector=r.toFunctionSelector=r.toFunctionHash=r.getEventSignature=r.toEventSignature=r.getEventSelector=r.toEventSelector=r.toEventHash=r.sha256=r.ripemd160=r.keccak256=r.isHash=r.rpcTransactionType=r.formatTransactionRequest=r.defineTransactionRequest=r.formatTransactionReceipt=r.defineTransactionReceipt=r.transactionType=r.formatTransaction=r.defineTransaction=r.formatLog=r.formatBlock=r.defineBlock=r.getContractError=void 0,r.parseUnits=r.parseGwei=r.parseEther=r.formatUnits=r.formatGwei=r.formatEther=r.validateTypedData=r.serializeTypedData=r.getTypesForEIP712Domain=r.domainSeparator=r.serializeTransaction=r.serializeAccessList=r.parseTransaction=r.getTransactionType=r.getSerializedTransactionType=r.assertTransactionLegacy=r.assertTransactionEIP2930=r.assertTransactionEIP1559=r.assertRequest=r.stringify=r.verifyTypedData=r.verifyMessage=r.verifyHash=r.toPrefixedMessage=r.signatureToCompactSignature=r.serializeSignature=r.signatureToHex=r.serializeErc8010Signature=r.serializeErc6492Signature=r.serializeCompactSignature=r.compactSignatureToHex=r.recoverTypedDataAddress=void 0;var n=e.r(668691);Object.defineProperty(r,"CircularReferenceError",{enumerable:!0,get:function(){return n.CircularReferenceError}}),Object.defineProperty(r,"InvalidAbiItemError",{enumerable:!0,get:function(){return n.InvalidAbiItemError}}),Object.defineProperty(r,"InvalidAbiParameterError",{enumerable:!0,get:function(){return n.InvalidAbiParameterError}}),Object.defineProperty(r,"InvalidAbiParametersError",{enumerable:!0,get:function(){return n.InvalidAbiParametersError}}),Object.defineProperty(r,"InvalidAbiTypeParameterError",{enumerable:!0,get:function(){return n.InvalidAbiTypeParameterError}}),Object.defineProperty(r,"InvalidFunctionModifierError",{enumerable:!0,get:function(){return n.InvalidFunctionModifierError}}),Object.defineProperty(r,"InvalidModifierError",{enumerable:!0,get:function(){return n.InvalidModifierError}}),Object.defineProperty(r,"InvalidParameterError",{enumerable:!0,get:function(){return n.InvalidParameterError}}),Object.defineProperty(r,"InvalidParenthesisError",{enumerable:!0,get:function(){return n.InvalidParenthesisError}}),Object.defineProperty(r,"InvalidSignatureError",{enumerable:!0,get:function(){return n.InvalidSignatureError}}),Object.defineProperty(r,"InvalidStructSignatureError",{enumerable:!0,get:function(){return n.InvalidStructSignatureError}}),Object.defineProperty(r,"parseAbi",{enumerable:!0,get:function(){return n.parseAbi}}),Object.defineProperty(r,"parseAbiItem",{enumerable:!0,get:function(){return n.parseAbiItem}}),Object.defineProperty(r,"parseAbiParameter",{enumerable:!0,get:function(){return n.parseAbiParameter}}),Object.defineProperty(r,"parseAbiParameters",{enumerable:!0,get:function(){return n.parseAbiParameters}}),Object.defineProperty(r,"SolidityProtectedKeywordError",{enumerable:!0,get:function(){return n.SolidityProtectedKeywordError}}),Object.defineProperty(r,"UnknownSignatureError",{enumerable:!0,get:function(){return n.UnknownSignatureError}}),Object.defineProperty(r,"UnknownTypeError",{enumerable:!0,get:function(){return n.UnknownTypeError}});var i=e.r(106637);Object.defineProperty(r,"getContract",{enumerable:!0,get:function(){return i.getContract}});var a=e.r(1260);Object.defineProperty(r,"WaitForCallsStatusTimeoutError",{enumerable:!0,get:function(){return a.WaitForCallsStatusTimeoutError}});var o=e.r(466543);Object.defineProperty(r,"createClient",{enumerable:!0,get:function(){return o.createClient}}),Object.defineProperty(r,"rpcSchema",{enumerable:!0,get:function(){return o.rpcSchema}});var s=e.r(922563);Object.defineProperty(r,"createPublicClient",{enumerable:!0,get:function(){return s.createPublicClient}});var c=e.r(136615);Object.defineProperty(r,"createTestClient",{enumerable:!0,get:function(){return c.createTestClient}});var u=e.r(614085);Object.defineProperty(r,"createWalletClient",{enumerable:!0,get:function(){return u.createWalletClient}});var l=e.r(645861);Object.defineProperty(r,"publicActions",{enumerable:!0,get:function(){return l.publicActions}});var d=e.r(594026);Object.defineProperty(r,"testActions",{enumerable:!0,get:function(){return d.testActions}});var f=e.r(14256);Object.defineProperty(r,"walletActions",{enumerable:!0,get:function(){return f.walletActions}});var p=e.r(181255);Object.defineProperty(r,"createTransport",{enumerable:!0,get:function(){return p.createTransport}});var h=e.r(441533);Object.defineProperty(r,"custom",{enumerable:!0,get:function(){return h.custom}});var m=e.r(577997);Object.defineProperty(r,"fallback",{enumerable:!0,get:function(){return m.fallback}}),Object.defineProperty(r,"shouldThrow",{enumerable:!0,get:function(){return m.shouldThrow}});var b=e.r(443910);Object.defineProperty(r,"http",{enumerable:!0,get:function(){return b.http}});var y=e.r(475410);Object.defineProperty(r,"webSocket",{enumerable:!0,get:function(){return y.webSocket}});var g=e.r(277779);Object.defineProperty(r,"erc20Abi",{enumerable:!0,get:function(){return g.erc20Abi}}),Object.defineProperty(r,"erc20Abi_bytes32",{enumerable:!0,get:function(){return g.erc20Abi_bytes32}}
4),Object.defineProperty(r,"erc721Abi",{enumerable:!0,get:function(){return g.erc721Abi}}),Object.defineProperty(r,"erc1155Abi",{enumerable:!0,get:function(){return g.erc1155Abi}}),Object.defineProperty(r,"erc4626Abi",{enumerable:!0,get:function(){return g.erc4626Abi}}),Object.defineProperty(r,"erc6492SignatureValidatorAbi",{enumerable:!0,get:function(){return g.erc6492SignatureValidatorAbi}}),Object.defineProperty(r,"universalSignatureValidatorAbi",{enumerable:!0,get:function(){return g.erc6492SignatureValidatorAbi}}),Object.defineProperty(r,"multicall3Abi",{enumerable:!0,get:function(){return g.multicall3Abi}});var v=e.r(135525);Object.defineProperty(r,"ethAddress",{enumerable:!0,get:function(){return v.ethAddress}}),Object.defineProperty(r,"zeroAddress",{enumerable:!0,get:function(){return v.zeroAddress}});var w=e.r(400282);Object.defineProperty(r,"zeroHash",{enumerable:!0,get:function(){return w.zeroHash}});var E=e.r(286776);Object.defineProperty(r,"deploylessCallViaBytecodeBytecode",{enumerable:!0,get:function(){return E.deploylessCallViaBytecodeBytecode}}),Object.defineProperty(r,"deploylessCallViaFactoryBytecode",{enumerable:!0,get:function(){return E.deploylessCallViaFactoryBytecode}}),Object.defineProperty(r,"erc6492SignatureValidatorByteCode",{enumerable:!0,get:function(){return E.erc6492SignatureValidatorByteCode}}),Object.defineProperty(r,"universalSignatureValidatorByteCode",{enumerable:!0,get:function(){return E.erc6492SignatureValidatorByteCode}});var P=e.r(627009);Object.defineProperty(r,"maxInt8",{enumerable:!0,get:function(){return P.maxInt8}}),Object.defineProperty(r,"maxInt16",{enumerable:!0,get:function(){return P.maxInt16}}),Object.defineProperty(r,"maxInt24",{enumerable:!0,get:function(){return P.maxInt24}}),Object.defineProperty(r,"maxInt32",{enumerable:!0,get:function(){return P.maxInt32}}),Object.defineProperty(r,"maxInt40",{enumerable:!0,get:function(){return P.maxInt40}}),Object.defineProperty(r,"maxInt48",{enumerable:!0,get:function(){return P.maxInt48}}),Object.defineProperty(r,"maxInt56",{enumerable:!0,get:function(){return P.maxInt56}}),Object.defineProperty(r,"maxInt64",{enumerable:!0,get:function(){return P.maxInt64}}),Object.defineProperty(r,"maxInt72",{enumerable:!0,get:function(){return P.maxInt72}}),Object.defineProperty(r,"maxInt80",{enumerable:!0,get:function(){return P.maxInt80}}),Object.defineProperty(r,"maxInt88",{enumerable:!0,get:function(){return P.maxInt88}}),Object.defineProperty(r,"maxInt96",{enumerable:!0,get:function(){return P.maxInt96}}),Object.defineProperty(r,"maxInt104",{enumerable:!0,get:function(){return P.maxInt104}}),Object.defineProperty(r,"maxInt112",{enumerable:!0,get:function(){return P.maxInt112}}),Object.defineProperty(r,"maxInt120",{enumerable:!0,get:function(){return P.maxInt120}}),Object.defineProperty(r,"maxInt128",{enumerable:!0,get:function(){return P.maxInt128}}),Object.defineProperty(r,"maxInt136",{enumerable:!0,get:function(){return P.maxInt136}}),Object.defineProperty(r,"maxInt144",{enumerable:!0,get:function(){return P.maxInt144}}),Object.defineProperty(r,"maxInt152",{enumerable:!0,get:function(){return P.maxInt152}}),Object.defineProperty(r,"maxInt160",{enumerable:!0,get:function(){return P.maxInt160}}),Object.defineProperty(r,"maxInt168",{enumerable:!0,get:function(){return P.maxInt168}}),Object.defineProperty(r,"maxInt176",{enumerable:!0,get:function(){return P.maxInt176}}),Object.defineProperty(r,"maxInt184",{enumerable:!0,get:function(){return P.maxInt184}}),Object.defineProperty(r,"maxInt192",{enumerable:!0,get:function(){return P.maxInt192}}),Object.defineProperty(r,"maxInt200",{enumerable:!0,get:function(){return P.maxInt200}}),Object.defineProperty(r,"maxInt208",{enumerable:!0,get:function(){return P.maxInt208}}),Object.defineProperty(r,"maxInt216",{enumerable:!0,get:function(){return P.maxInt216}}),Object.defineProperty(r,"maxInt224",{enumerable:!0,get:function(){return P.maxInt224}}),Object.defineProperty(r,"maxInt232",{enumerable:!0,get:function(){return P.maxInt232}}),Object.defineProperty(r,"maxInt240",{enumerable:!0,get:function(){return P.maxInt240}}),Object.defineProperty(r,"maxInt248",{enumerable:!0,get:function(){return P.maxInt248}}),Object.defineProperty(r,"maxInt256",{enumerable:!0,get:function(){return P.maxInt256}}),Object.defineProperty(r,"maxUint8",{enumerable:!0,get:function(){return P.maxUint8}}),Object.defineProperty(r,"maxUint16",{enumerable:!0,get:function(){return P.maxUint16}}),Object.defineProperty(r,"maxUint24",{enumerable:!0,get:function(){return P.maxUint24}}
4),Object.defineProperty(r,"maxUint32",{enumerable:!0,get:function(){return P.maxUint32}}),Object.defineProperty(r,"maxUint40",{enumerable:!0,get:function(){return P.maxUint40}}),Object.defineProperty(r,"maxUint48",{enumerable:!0,get:function(){return P.maxUint48}}),Object.defineProperty(r,"maxUint56",{enumerable:!0,get:function(){return P.maxUint56}}),Object.defineProperty(r,"maxUint64",{enumerable:!0,get:function(){return P.maxUint64}}),Object.defineProperty(r,"maxUint72",{enumerable:!0,get:function(){return P.maxUint72}}),Object.defineProperty(r,"maxUint80",{enumerable:!0,get:function(){return P.maxUint80}}),Object.defineProperty(r,"maxUint88",{enumerable:!0,get:function(){return P.maxUint88}}),Object.defineProperty(r,"maxUint96",{enumerable:!0,get:function(){return P.maxUint96}}),Object.defineProperty(r,"maxUint104",{enumerable:!0,get:function(){return P.maxUint104}}),Object.defineProperty(r,"maxUint112",{enumerable:!0,get:function(){return P.maxUint112}}),Object.defineProperty(r,"maxUint120",{enumerable:!0,get:function(){return P.maxUint120}}),Object.defineProperty(r,"maxUint128",{enumerable:!0,get:function(){return P.maxUint128}}),Object.defineProperty(r,"maxUint136",{enumerable:!0,get:function(){return P.maxUint136}}),Object.defineProperty(r,"maxUint144",{enumerable:!0,get:function(){return P.maxUint144}}),Object.defineProperty(r,"maxUint152",{enumerable:!0,get:function(){return P.maxUint152}}),Object.defineProperty(r,"maxUint160",{enumerable:!0,get:function(){return P.maxUint160}}),Object.defineProperty(r,"maxUint168",{enumerable:!0,get:function(){return P.maxUint168}}),Object.defineProperty(r,"maxUint176",{enumerable:!0,get:function(){return P.maxUint176}}),Object.defineProperty(r,"maxUint184",{enumerable:!0,get:function(){return P.maxUint184}}),Object.defineProperty(r,"maxUint192",{enumerable:!0,get:function(){return P.maxUint192}}),Object.defineProperty(r,"maxUint200",{enumerable:!0,get:function(){return P.maxUint200}}),Object.defineProperty(r,"maxUint208",{enumerable:!0,get:function(){return P.maxUint208}}),Object.defineProperty(r,"maxUint216",{enumerable:!0,get:function(){return P.maxUint216}}),Object.defineProperty(r,"maxUint224",{enumerable:!0,get:function(){return P.maxUint224}}),Object.defineProperty(r,"maxUint232",{enumerable:!0,get:function(){return P.maxUint232}}),Object.defineProperty(r,"maxUint240",{enumerable:!0,get:function(){return P.maxUint240}}),Object.defineProperty(r,"maxUint248",{enumerable:!0,get:function(){return P.maxUint248}}),Object.defineProperty(r,"maxUint256",{enumerable:!0,get:function(){return P.maxUint256}}),Object.defineProperty(r,"minInt8",{enumerable:!0,get:function(){return P.minInt8}}),Object.defineProperty(r,"minInt16",{enumerable:!0,get:function(){return P.minInt16}}),Object.defineProperty(r,"minInt24",{enumerable:!0,get:function(){return P.minInt24}}),Object.defineProperty(r,"minInt32",{enumerable:!0,get:function(){return P.minInt32}}),Object.defineProperty(r,"minInt40",{enumerable:!0,get:function(){return P.minInt40}}),Object.defineProperty(r,"minInt48",{enumerable:!0,get:function(){return P.minInt48}}),Object.defineProperty(r,"minInt56",{enumerable:!0,get:function(){return P.minInt56}}),Object.defineProperty(r,"minInt64",{enumerable:!0,get:function(){return P.minInt64}}),Object.defineProperty(r,"minInt72",{enumerable:!0,get:function(){return P.minInt72}}),Object.defineProperty(r,"minInt80",{enumerable:!0,get:function(){return P.minInt80}}),Object.defineProperty(r,"minInt88",{enumerable:!0,get:function(){return P.minInt88}}),Object.defineProperty(r,"minInt96",{enumerable:!0,get:function(){return P.minInt96}}),Object.defineProperty(r,"minInt104",{enumerable:!0,get:function(){return P.minInt104}}),Object.defineProperty(r,"minInt112",{enumerable:!0,get:function(){return P.minInt112}}),Object.defineProperty(r,"minInt120",{enumerable:!0,get:function(){return P.minInt120}}),Object.defineProperty(r,"minInt128",{enumerable:!0,get:function(){return P.minInt128}}),Object.defineProperty(r,"minInt136",{enumerable:!0,get:function(){return P.minInt136}}),Object.defineProperty(r,"minInt144",{enumerable:!0,get:function(){return P.minInt144}}),Object.defineProperty(r,"minInt152",{enumerable:!0,get:function(){return P.minInt152}}),Object.defineProperty(r,"minInt160",{enumerable:!0,get:function(){return P.minInt160}}),Object.defineProperty(r,"minInt168",{enumerable:!0,get:function(){return P.minInt168}}),Object.defineProperty(r,"minInt176",{enumerable:!0,get:function(){return P.minInt176}}),Object.defineProperty(r,"minInt184",{enumerable:!0,get:function(){return P.minInt184}}),Object.defineProperty(r,"minInt192",{enumerable:!0,get:function(){return P.minInt192}}),Object.defineProperty(r,"minInt200",{enumerable:!0,get:function(){return P.minInt200}}),Object.defineProperty(r,"minInt208",{enumerable:!0,get:function(){return P.minInt208}}),Object.defineProperty(r,"minInt216",{enumerable:!0,get:function(){return P.minInt216}}),Object.defineProperty(r,"minInt224",{enumerable:!0,get:function(){return P.minInt224}}),Object.defineProperty(r,"minInt232",{enumerable:!0,get:function(){return P.minInt232}}),Object.defineProperty(r,"minInt240",{enumerable:!0,get:function(){return P.minInt240}}),Object.defineProperty(r,"minInt248",{enumerable:!0,get:function(){return P.minInt248}}),Object.defineProperty(r,"minInt256",{enumerable:!0,get:function(){return P.minInt256}});var x=e.r(990127);Object.defineProperty(r,"presignMessagePrefix",{enumerable:!0,get:function(){return x.presignMessagePrefix}});var A=e.r(883987);Object.defineProperty(r,"etherUnits",{enumerable:!0,get:function(){return A.etherUnits}}),Object.defineProperty(r,"gweiUnits",{enumerable:!0,get:function(){return A.gweiUnits}}),Object.defineProperty(r,"weiUnits",{enumerable:!0,get:function(){return A.weiUnits}});var I=e.r(963101);Object.defineProperty(r,"AbiConstructorNotFoundError",{enumerable:!0,get:function(){return I.AbiConstructorNotFoundError}}),Object.defineProperty(r,"AbiConstructorParamsNotFoundError",{enumerable:!0,get:function(){return I.AbiConstructorParamsNotFoundError}}),Object.defineProperty(r,"AbiDecodingDataSizeInvalidError",{enumerable:!0,get:function(){return I.AbiDecodingDataSizeInvalidError}}),Object.defineProperty(r,"AbiDecodingDataSizeTooSmallError",{enumerable:!0,get:function(){return I.AbiDecodingDataSizeTooSmallError}}),Object.defineProperty(r,"AbiDecodingZeroDataError",{enumerable:!0,get:function(){return I.AbiDecodingZeroDataError}}
4),Object.defineProperty(r,"AbiEncodingArrayLengthMismatchError",{enumerable:!0,get:function(){return I.AbiEncodingArrayLengthMismatchError}}),Object.defineProperty(r,"AbiEncodingBytesSizeMismatchError",{enumerable:!0,get:function(){return I.AbiEncodingBytesSizeMismatchError}}),Object.defineProperty(r,"AbiEncodingLengthMismatchError",{enumerable:!0,get:function(){return I.AbiEncodingLengthMismatchError}}),Object.defineProperty(r,"AbiErrorInputsNotFoundError",{enumerable:!0,get:function(){return I.AbiErrorInputsNotFoundError}}),Object.defineProperty(r,"AbiErrorNotFoundError",{enumerable:!0,get:function(){return I.AbiErrorNotFoundError}}),Object.defineProperty(r,"AbiErrorSignatureNotFoundError",{enumerable:!0,get:function(){return I.AbiErrorSignatureNotFoundError}}),Object.defineProperty(r,"AbiEventNotFoundError",{enumerable:!0,get:function(){return I.AbiEventNotFoundError}}),Object.defineProperty(r,"AbiEventSignatureEmptyTopicsError",{enumerable:!0,get:function(){return I.AbiEventSignatureEmptyTopicsError}}),Object.defineProperty(r,"AbiEventSignatureNotFoundError",{enumerable:!0,get:function(){return I.AbiEventSignatureNotFoundError}}),Object.defineProperty(r,"AbiFunctionNotFoundError",{enumerable:!0,get:function(){return I.AbiFunctionNotFoundError}}),Object.defineProperty(r,"AbiFunctionOutputsNotFoundError",{enumerable:!0,get:function(){return I.AbiFunctionOutputsNotFoundError}}),Object.defineProperty(r,"AbiFunctionSignatureNotFoundError",{enumerable:!0,get:function(){return I.AbiFunctionSignatureNotFoundError}}),Object.defineProperty(r,"BytesSizeMismatchError",{enumerable:!0,get:function(){return I.BytesSizeMismatchError}}),Object.defineProperty(r,"DecodeLogDataMismatch",{enumerable:!0,get:function(){return I.DecodeLogDataMismatch}}),Object.defineProperty(r,"DecodeLogTopicsMismatch",{enumerable:!0,get:function(){return I.DecodeLogTopicsMismatch}}),Object.defineProperty(r,"InvalidAbiDecodingTypeError",{enumerable:!0,get:function(){return I.InvalidAbiDecodingTypeError}}),Object.defineProperty(r,"InvalidAbiEncodingTypeError",{enumerable:!0,get:function(){return I.InvalidAbiEncodingTypeError}}),Object.defineProperty(r,"InvalidArrayError",{enumerable:!0,get:function(){return I.InvalidArrayError}}),Object.defineProperty(r,"InvalidDefinitionTypeError",{enumerable:!0,get:function(){return I.InvalidDefinitionTypeError}}),Object.defineProperty(r,"UnsupportedPackedAbiType",{enumerable:!0,get:function(){return I.UnsupportedPackedAbiType}});var T=e.r(224276);Object.defineProperty(r,"InvalidAddressError",{enumerable:!0,get:function(){return T.InvalidAddressError}});var S=e.r(91633);Object.defineProperty(r,"BaseError",{enumerable:!0,get:function(){return S.BaseError}}),Object.defineProperty(r,"setErrorConfig",{enumerable:!0,get:function(){return S.setErrorConfig}});var C=e.r(201648);Object.defineProperty(r,"BlockNotFoundError",{enumerable:!0,get:function(){return C.BlockNotFoundError}});var O=e.r(991739);Object.defineProperty(r,"BundleFailedError",{enumerable:!0,get:function(){return O.BundleFailedError}});var j=e.r(808894);Object.defineProperty(r,"ChainDoesNotSupportContract",{enumerable:!0,get:function(){return j.ChainDoesNotSupportContract}}),Object.defineProperty(r,"ChainMismatchError",{enumerable:!0,get:function(){return j.ChainMismatchError}}),Object.defineProperty(r,"ChainNotFoundError",{enumerable:!0,get:function(){return j.ChainNotFoundError}}),Object.defineProperty(r,"ClientChainNotConfiguredError",{enumerable:!0,get:function(){return j.ClientChainNotConfiguredError}}),Object.defineProperty(r,"InvalidChainIdError",{enumerable:!0,get:function(){return j.InvalidChainIdError}});var k=e.r(720794);Object.defineProperty(r,"CallExecutionError",{enumerable:!0,get:function(){return k.CallExecutionError}}),Object.defineProperty(r,"ContractFunctionExecutionError",{enumerable:!0,get:function(){return k.ContractFunctionExecutionError}}),Object.defineProperty(r,"ContractFunctionRevertedError",{enumerable:!0,get:function(){return k.ContractFunctionRevertedError}}),Object.defineProperty(r,"ContractFunctionZeroDataError",{enumerable:!0,get:function(){return k.ContractFunctionZeroDataError}}),Object.defineProperty(r,"CounterfactualDeploymentFailedError",{enumerable:!0,get:function(){return k.CounterfactualDeploymentFailedError}}),Object.defineProperty(r,"RawContractError",{enumerable:!0,get:function(){return k.RawContractError}});var R=e.r(544609);Object.defineProperty(r,"SizeExceedsPaddingSizeError",{enumerable:!0,get:function(){return R.SizeExceedsPaddingSizeError}}),Object.defineProperty(r,"SliceOffsetOutOfBoundsError",{enumerable:!0,get:function(){return R.SliceOffsetOutOfBoundsError}});var _=e.r(131296);Object.defineProperty(r,"IntegerOutOfRangeError",{enumerable:!0,get:function(){return _.IntegerOutOfRangeError}}),Object.defineProperty(r,"InvalidBytesBooleanError",{enumerable:!0,get:function(){return _.InvalidBytesBooleanError}}),Object.defineProperty(r,"InvalidHexBooleanError",{enumerable:!0,get:function(){return _.InvalidHexBooleanError}}),Object.defineProperty(r,"InvalidHexValueError",{enumerable:!0,get:function(){return _.InvalidHexValueError}}),Object.defineProperty(r,"SizeOverflowError",{enumerable:!0,get:function(){return _.SizeOverflowError}});var B=e.r(914102);Object.defineProperty(r,"EnsAvatarInvalidNftUriError",{enumerable:!0,get:function(){return B.EnsAvatarInvalidNftUriError}}),Object.defineProperty(r,"EnsAvatarUnsupportedNamespaceError",{enumerable:!0,get:function(){return B.EnsAvatarUnsupportedNamespaceError}}),Object.defineProperty(r,"EnsAvatarUriResolutionError",{enumerable:!0,get:function(){return B.EnsAvatarUriResolutionError}}),Object.defineProperty(r,"EnsInvalidChainIdError",{enumerable:!0,get:function(){return B.EnsInvalidChainIdError}});var M=e.r(133591);Object.defineProperty(r,"EstimateGasExecutionError",{enumerable:!0,get:function(){return M.EstimateGasExecutionError}});var F=e.r(615144);Object.defineProperty(r,"BaseFeeScalarError",{enumerable:!0,get:function(){return F.BaseFeeScalarError}}),Object.defineProperty(r,"Eip1559FeesNotSupportedError",{enumerable:!0,get:function(){return F.Eip1559FeesNotSupportedError}}),Object.defineProperty(r,"MaxFeePerGasTooLowError",{enumerable:!0,get:function(){return F.MaxFeePerGasTooLowError}});var N=e.r(92662);Object.defineProperty(r,"FilterTypeNotSupportedError",{enumerable:!0,get:function(){return N.FilterTypeNotSupportedError}});var U=e.r(659641);Object.defineProperty(r,"ExecutionRevertedError",{enumerable:!0,get:function(){return U.ExecutionRevertedError}}),Object.defineProperty(r,"FeeCapTooHighError",{enumerable:!0,get:function(){return U.FeeCapTooHighError}}),Object.defineProperty(r,"FeeCapTooLowError",{enumerable:!0,get:function(){return U.FeeCapTooLowError}}),Object.defineProperty(r,"InsufficientFundsError",{enumerable:!0,get:function(){return U.InsufficientFundsError}}),Object.defineProperty(r,"IntrinsicGasTooHighError",{enumerable:!0,get:function(){return U.IntrinsicGasTooHighError}}),Object.defineProperty(r,"IntrinsicGasTooLowError",{enumerable:!0,get:function(){return U.IntrinsicGasTooLowError}}),Object.defineProperty(r,"NonceMaxValueError",{enumerable:!0,get:function(){return U.NonceMaxValueError}}),Object.defineProperty(r,"NonceTooHighError",{enumerable:!0,get:function(){return U.NonceTooHighError}}),Object.defineProperty(r,"NonceTooLowError",{enumerable:!0,get:function(){return U.NonceTooLowError}}),Object.defineProperty(r,"TipAboveFeeCapError",{enumerable:!0,get:function(){return U.TipAboveFeeCapError}}),Object.defineProperty(r,"TransactionTypeNotSupportedError",{enumerable:!0,get:function(){return U.TransactionTypeNotSupportedError}}),Object.defineProperty(r,"UnknownNodeError",{enumerable:!0,get:function(){return U.UnknownNodeError}});var H=e.r(666442);Object.defineProperty(r,"HttpRequestError",{enumerable:!0,get:function(){return H.HttpRequestError}}),Object.defineProperty(r,"RpcRequestError",{enumerable:!0,get:function(){return H.RpcRequestError}}),Object.defineProperty(r,"SocketClosedError",{enumerable:!0,get:function(){return H.SocketClosedError}}),Object.defineProperty(r,"TimeoutError",{enumerable:!0,get:function(){return H.TimeoutError}}),Object.defineProperty(r,"WebSocketRequestError",{enumerable:!0,get:function(){return H.WebSocketRequestError}});var z=e.r(477323);Object.defineProperty(r,"AtomicityNotSupportedError",{enumerable:!0,get:function(){return z.AtomicityNotSupportedError}}),Object.defineProperty(r,"AtomicReadyWalletRejectedUpgradeError",{enumerable:!0,get:function(){return z.AtomicReadyWalletRejectedUpgradeError}}),Object.defineProperty(r,"BundleTooLargeError",{enumerable:!0,get:function(){return z.BundleTooLargeError}}),Object.defineProperty(r,"ChainDisconnectedError",{enumerable:!0,get:function(){return z.ChainDisconnectedError}}),Object.defineProperty(r,"DuplicateIdError",{enumerable:!0,get:function(){return z.DuplicateIdError}}),Object.defineProperty(r,"InternalRpcError",{enumerable:!0,get:function(){return z.InternalRpcError}}),Object.defineProperty(r,"InvalidInputRpcError",{enumerable:!0,get:function(){return z.InvalidInputRpcError}}),Object.defineProperty(r,"InvalidParamsRpcError",{enumerable:!0,get:function(){return z.InvalidParamsRpcError}}),Object.defineProperty(r,"InvalidRequestRpcError",{enumerable:!0,get:function(){return z.InvalidRequestRpcError}}),Object.defineProperty(r,"JsonRpcVersionUnsupportedError",{enumerable:!0,get:function(){return z.JsonRpcVersionUnsupportedError}}),Object.defineProperty(r,"LimitExceededRpcError",{enumerable:!0,get:function(){return z.LimitExceededRpcError}}),Object.defineProperty(r,"MethodNotFoundRpcError",{enumerable:!0,get:function(){return z.MethodNotFoundRpcError}}),Object.defineProperty(r,"MethodNotSupportedRpcError",{enumerable:!0,get:function(){return z.MethodNotSupportedRpcError}}),Object.defineProperty(r,"ParseRpcError",{enumerable:!0,get:function(){return z.ParseRpcError}}),Object.defineProperty(r,"ProviderDisconnectedError",{enumerable:!0,get:function(){return z.ProviderDisconnectedError}}),Object.defineProperty(r,"ProviderRpcError",{enumerable:!0,get:function(){return z.ProviderRpcError}}),Object.defineProperty(r,"ResourceNotFoundRpcError",{enumerable:!0,get:function(){return z.ResourceNotFoundRpcError}}),Object.defineProperty(r,"ResourceUnavailableRpcError",{enumerable:!0,get:function(){return z.ResourceUnavailableRpcError}}),Object.defineProperty(r,"RpcError",{enumerable:!0,get:function(){return z.RpcError}}),Object.defineProperty(r,"SwitchChainError",{enumerable:!0,get:function(){return z.SwitchChainError}}),Object.defineProperty(r,"TransactionRejectedRpcError",{enumerable:!0,get:function(){return z.TransactionRejectedRpcError}}),Object.defineProperty(r,"UnauthorizedProviderError",{enumerable:!0,get:function(){return z.UnauthorizedProviderError}}),Object.defineProperty(r,"UnknownBundleIdError",{enumerable:!0,get:function(){return z.UnknownBundleIdError}}),Object.defineProperty(r,"UnknownRpcError",{enumerable:!0,get:function(){return z.UnknownRpcError}}),Object.defineProperty(r,"UnsupportedChainIdError",{enumerable:!0,get:function(){return z.UnsupportedChainIdError}}),Object.defineProperty(r,"UnsupportedNonOptionalCapabilityError",{enumerable:!0,get:function(){return z.UnsupportedNonOptionalCapabilityError}}),Object.defineProperty(r,"UnsupportedProviderMethodError",{enumerable:!0,get:function(){return z.UnsupportedProviderMethodError}}),Object.defineProperty(r,"UserRejectedRequestError",{enumerable:!0,get:function(){return z.UserRejectedRequestError}});var L=e.r(779719);Object.defineProperty(r,"AccountStateConflictError",{enumerable:!0,get:function(){return L.AccountStateConflictError}}
4),Object.defineProperty(r,"StateAssignmentConflictError",{enumerable:!0,get:function(){return L.StateAssignmentConflictError}});var D=e.r(341289);Object.defineProperty(r,"FeeConflictError",{enumerable:!0,get:function(){return D.FeeConflictError}}),Object.defineProperty(r,"InvalidLegacyVError",{enumerable:!0,get:function(){return D.InvalidLegacyVError}}),Object.defineProperty(r,"InvalidSerializableTransactionError",{enumerable:!0,get:function(){return D.InvalidSerializableTransactionError}}),Object.defineProperty(r,"InvalidSerializedTransactionError",{enumerable:!0,get:function(){return D.InvalidSerializedTransactionError}}),Object.defineProperty(r,"InvalidSerializedTransactionTypeError",{enumerable:!0,get:function(){return D.InvalidSerializedTransactionTypeError}}),Object.defineProperty(r,"InvalidStorageKeySizeError",{enumerable:!0,get:function(){return D.InvalidStorageKeySizeError}}),Object.defineProperty(r,"TransactionExecutionError",{enumerable:!0,get:function(){return D.TransactionExecutionError}}),Object.defineProperty(r,"TransactionNotFoundError",{enumerable:!0,get:function(){return D.TransactionNotFoundError}}),Object.defineProperty(r,"TransactionReceiptNotFoundError",{enumerable:!0,get:function(){return D.TransactionReceiptNotFoundError}}),Object.defineProperty(r,"WaitForTransactionReceiptTimeoutError",{enumerable:!0,get:function(){return D.WaitForTransactionReceiptTimeoutError}});var $=e.r(920905);Object.defineProperty(r,"UrlRequiredError",{enumerable:!0,get:function(){return $.UrlRequiredError}});var q=e.r(653895);Object.defineProperty(r,"InvalidDomainError",{enumerable:!0,get:function(){return q.InvalidDomainError}}),Object.defineProperty(r,"InvalidPrimaryTypeError",{enumerable:!0,get:function(){return q.InvalidPrimaryTypeError}}),Object.defineProperty(r,"InvalidStructTypeError",{enumerable:!0,get:function(){return q.InvalidStructTypeError}});var W=e.r(214256);Object.defineProperty(r,"InvalidDecimalNumberError",{enumerable:!0,get:function(){return W.InvalidDecimalNumberError}});var G=e.r(945905);Object.defineProperty(r,"EIP1193ProviderRpcError",{enumerable:!0,get:function(){return G.ProviderRpcError}});var K=e.r(239072);Object.defineProperty(r,"decodeAbiParameters",{enumerable:!0,get:function(){return K.decodeAbiParameters}});var V=e.r(312762);Object.defineProperty(r,"decodeDeployData",{enumerable:!0,get:function(){return V.decodeDeployData}});var J=e.r(369165);Object.defineProperty(r,"decodeErrorResult",{enumerable:!0,get:function(){return J.decodeErrorResult}});var Z=e.r(197532);Object.defineProperty(r,"decodeEventLog",{enumerable:!0,get:function(){return Z.decodeEventLog}});var Q=e.r(836501);Object.defineProperty(r,"decodeFunctionData",{enumerable:!0,get:function(){return Q.decodeFunctionData}});var Y=e.r(320101);Object.defineProperty(r,"decodeFunctionResult",{enumerable:!0,get:function(){return Y.decodeFunctionResult}});var X=e.r(440747);Object.defineProperty(r,"encodeAbiParameters",{enumerable:!0,get:function(){return X.encodeAbiParameters}});var ee=e.r(286717);Object.defineProperty(r,"encodeDeployData",{enumerable:!0,get:function(){return ee.encodeDeployData}});var et=e.r(87425);Object.defineProperty(r,"encodeErrorResult",{enumerable:!0,get:function(){return et.encodeErrorResult}});var er=e.r(725159);Object.defineProperty(r,"encodeEventTopics",{enumerable:!0,get:function(){return er.encodeEventTopics}});var en=e.r(804943);Object.defineProperty(r,"encodeFunctionData",{enumerable:!0,get:function(){return en.encodeFunctionData}});var ei=e.r(201219);Object.defineProperty(r,"encodeFunctionResult",{enumerable:!0,get:function(){return ei.encodeFunctionResult}});var ea=e.r(928659);Object.defineProperty(r,"encodePacked",{enumerable:!0,get:function(){return ea.encodePacked}});var eo=e.r(409872);Object.defineProperty(r,"getAbiItem",{enumerable:!0,get:function(){return eo.getAbiItem}});var es=e.r(685530);Object.defineProperty(r,"parseEventLogs",{enumerable:!0,get:function(){return es.parseEventLogs}});var ec=e.r(521681);Object.defineProperty(r,"prepareEncodeFunctionData",{enumerable:!0,get:function(){return ec.prepareEncodeFunctionData}});var eu=e.r(929544);Object.defineProperty(r,"checksumAddress",{enumerable:!0,get:function(){return eu.checksumAddress}}),Object.defineProperty(r,"getAddress",{enumerable:!0,get:function(){return eu.getAddress}});var el=e.r(831047);Object.defineProperty(r,"getContractAddress",{enumerable:!0,get:function(){return el.getContractAddress}}),Object.defineProperty(r,"getCreate2Address",{enumerable:!0,get:function(){return el.getCreate2Address}}),Object.defineProperty(r,"getCreateAddress",{enumerable:!0,get:function(){return el.getCreateAddress}});var ed=e.r(429625);Object.defineProperty(r,"isAddress",{enumerable:!0,get:function(){return ed.isAddress}});var ef=e.r(359389);Object.defineProperty(r,"isAddressEqual",{enumerable:!0,get:function(){return ef.isAddressEqual}});var ep=e.r(830588);Object.defineProperty(r,"blobsToCommitments",{enumerable:!0,get:function(){return ep.blobsToCommitments}});var eh=e.r(764012);Object.defineProperty(r,"blobsToProofs",{enumerable:!0,get:function(){return eh.blobsToProofs}});var em=e.r(444604);Object.defineProperty(r,"commitmentsToVersionedHashes",{enumerable:!0,get:function(){return em.commitmentsToVersionedHashes}});var eb=e.r(397856);Object.defineProperty(r,"commitmentToVersionedHash",{enumerable:!0,get:function(){return eb.commitmentToVersionedHash}});var ey=e.r(70927);Object.defineProperty(r,"fromBlobs",{enumerable:!0,get:function(){return ey.fromBlobs}});var eg=e.r(36817);Object.defineProperty(r,"sidecarsToVersionedHashes",{enumerable:!0,get:function(){return eg.sidecarsToVersionedHashes}});var ev=e.r(458775);Object.defineProperty(r,"toBlobSidecars",{enumerable:!0,get:function(){return ev.toBlobSidecars}});var ew=e.r(767932);Object.defineProperty(r,"toBlobs",{enumerable:!0,get:function(){return ew.toBlobs}});var eE=e.r(772187);Object.defineProperty(r,"ccipRequest",{enumerable:!0,get:function(){return eE.ccipRequest}}),Object.defineProperty(r,"ccipFetch",{enumerable:!0,get:function(){return eE.ccipRequest}}),Object.defineProperty(r,"offchainLookup",{enumerable:!0,get:function(){return eE.offchainLookup}}),Object.defineProperty(r,"offchainLookupAbiItem",{enumerable:!0,get:function(){return eE.offchainLookupAbiItem}}),Object.defineProperty(r,"offchainLookupSignature",{enumerable:!0,get:function(){return eE.offchainLookupSignature}});var eP=e.r(389421);Object.defineProperty(r,"assertCurrentChain",{enumerable:!0,get:function(){return eP.assertCurrentChain}});var ex=e.r(528112);Object.defineProperty(r,"defineChain",{enumerable:!0,get:function(){return ex.defineChain}}),Object.defineProperty(r,"extendSchema",{enumerable:!0,get:function(){return ex.extendSchema}});var eA=e.r(407245);Object.defineProperty(r,"extractChain",{enumerable:!0,get:function(){return eA.extractChain}});var eI=e.r(370049);Object.defineProperty(r,"getChainContractAddress",{enumerable:!0,get:function(){return eI.getChainContractAddress}});var eT=e.r(985269);Object.defineProperty(r,"concat",{enumerable:!0,get:function(){return eT.concat}}),Object.defineProperty(r,"concatBytes",{enumerable:!0,get:function(){return eT.concatBytes}}),Object.defineProperty(r,"concatHex",{enumerable:!0,get:function(){return eT.concatHex}});var eS=e.r(361926);Object.defineProperty(r,"isBytes",{enumerable:!0,get:function(){return eS.isBytes}});var eC=e.r(528137);Object.defineProperty(r,"isHex",{enumerable:!0,get:function(){return eC.isHex}});var eO=e.r(356154);Object.defineProperty(r,"pad",{enumerable:!0,get:function(){return eO.pad}}),Object.defineProperty(r,"padBytes",{enumerable:!0,get:function(){return eO.padBytes}}),Object.defineProperty(r,"padHex",{enumerable:!0,get:function(){return eO.padHex}});
4var ej=e.r(484550);Object.defineProperty(r,"size",{enumerable:!0,get:function(){return ej.size}});var ek=e.r(952195);Object.defineProperty(r,"slice",{enumerable:!0,get:function(){return ek.slice}}),Object.defineProperty(r,"sliceBytes",{enumerable:!0,get:function(){return ek.sliceBytes}}),Object.defineProperty(r,"sliceHex",{enumerable:!0,get:function(){return ek.sliceHex}});var eR=e.r(492678);Object.defineProperty(r,"trim",{enumerable:!0,get:function(){return eR.trim}});var e_=e.r(783052);Object.defineProperty(r,"bytesToBigInt",{enumerable:!0,get:function(){return e_.bytesToBigInt}}),Object.defineProperty(r,"bytesToBool",{enumerable:!0,get:function(){return e_.bytesToBool}}),Object.defineProperty(r,"bytesToNumber",{enumerable:!0,get:function(){return e_.bytesToNumber}}),Object.defineProperty(r,"bytesToString",{enumerable:!0,get:function(){return e_.bytesToString}}),Object.defineProperty(r,"fromBytes",{enumerable:!0,get:function(){return e_.fromBytes}});var eB=e.r(723223);Object.defineProperty(r,"fromHex",{enumerable:!0,get:function(){return eB.fromHex}}),Object.defineProperty(r,"hexToBigInt",{enumerable:!0,get:function(){return eB.hexToBigInt}}),Object.defineProperty(r,"hexToBool",{enumerable:!0,get:function(){return eB.hexToBool}}),Object.defineProperty(r,"hexToNumber",{enumerable:!0,get:function(){return eB.hexToNumber}}),Object.defineProperty(r,"hexToString",{enumerable:!0,get:function(){return eB.hexToString}});var eM=e.r(975038);Object.defineProperty(r,"fromRlp",{enumerable:!0,get:function(){return eM.fromRlp}});var eF=e.r(935603);Object.defineProperty(r,"boolToBytes",{enumerable:!0,get:function(){return eF.boolToBytes}}),Object.defineProperty(r,"hexToBytes",{enumerable:!0,get:function(){return eF.hexToBytes}}),Object.defineProperty(r,"numberToBytes",{enumerable:!0,get:function(){return eF.numberToBytes}}),Object.defineProperty(r,"stringToBytes",{enumerable:!0,get:function(){return eF.stringToBytes}}),Object.defineProperty(r,"toBytes",{enumerable:!0,get:function(){return eF.toBytes}});var eN=e.r(850815);Object.defineProperty(r,"boolToHex",{enumerable:!0,get:function(){return eN.boolToHex}}),Object.defineProperty(r,"bytesToHex",{enumerable:!0,get:function(){return eN.bytesToHex}}),Object.defineProperty(r,"numberToHex",{enumerable:!0,get:function(){return eN.numberToHex}}),Object.defineProperty(r,"stringToHex",{enumerable:!0,get:function(){return eN.stringToHex}}),Object.defineProperty(r,"toHex",{enumerable:!0,get:function(){return eN.toHex}});var eU=e.r(178056);Object.defineProperty(r,"bytesToRlp",{enumerable:!0,get:function(){return eU.bytesToRlp}}),Object.defineProperty(r,"hexToRlp",{enumerable:!0,get:function(){return eU.hexToRlp}}),Object.defineProperty(r,"toRlp",{enumerable:!0,get:function(){return eU.toRlp}});var eH=e.r(53713);Object.defineProperty(r,"labelhash",{enumerable:!0,get:function(){return eH.labelhash}});var ez=e.r(940702);Object.defineProperty(r,"namehash",{enumerable:!0,get:function(){return ez.namehash}});var eL=e.r(643350);Object.defineProperty(r,"toCoinType",{enumerable:!0,get:function(){return eL.toCoinType}});var eD=e.r(290881);Object.defineProperty(r,"getContractError",{enumerable:!0,get:function(){return eD.getContractError}});var e$=e.r(288053);Object.defineProperty(r,"defineBlock",{enumerable:!0,get:function(){return e$.defineBlock}}),Object.defineProperty(r,"formatBlock",{enumerable:!0,get:function(){return e$.formatBlock}});var eq=e.r(798336);Object.defineProperty(r,"formatLog",{enumerable:!0,get:function(){return eq.formatLog}});var eW=e.r(728125);Object.defineProperty(r,"defineTransaction",{enumerable:!0,get:function(){return eW.defineTransaction}}),Object.defineProperty(r,"formatTransaction",{enumerable:!0,get:function(){return eW.formatTransaction}}),Object.defineProperty(r,"transactionType",{enumerable:!0,get:function(){return eW.transactionType}});var eG=e.r(941403);Object.defineProperty(r,"defineTransactionReceipt",{enumerable:!0,get:function(){return eG.defineTransactionReceipt}}),Object.defineProperty(r,"formatTransactionReceipt",{enumerable:!0,get:function(){return eG.formatTransactionReceipt}});var eK=e.r(244319);Object.defineProperty(r,"defineTransactionRequest",{enumerable:!0,get:function(){return eK.defineTransactionRequest}}),Object.defineProperty(r,"formatTransactionRequest",{enumerable:!0,get:function(){return eK.formatTransactionRequest}}),Object.defineProperty(r,"rpcTransactionType",{enumerable:!0,get:function(){return eK.rpcTransactionType}});var eV=e.r(418690);Object.defineProperty(r,"isHash",{enumerable:!0,get:function(){return eV.isHash}});var eJ=e.r(585457);Object.defineProperty(r,"keccak256",{enumerable:!0,get:function(){return eJ.keccak256}});var eZ=e.r(218565);Object.defineProperty(r,"ripemd160",{enumerable:!0,get:function(){return eZ.ripemd160}});var eQ=e.r(597025);Object.defineProperty(r,"sha256",{enumerable:!0,get:function(){return eQ.sha256}});var eY=e.r(315487);Object.defineProperty(r,"toEventHash",{enumerable:!0,get:function(){return eY.toEventHash}});var eX=e.r(138355);Object.defineProperty(r,"toEventSelector",{enumerable:!0,get:function(){return eX.toEventSelector}}),Object.defineProperty(r,"getEventSelector",{enumerable:!0,get:function(){return eX.toEventSelector}});var e0=e.r(625113);Object.defineProperty(r,"toEventSignature",{enumerable:!0,get:function(){return e0.toEventSignature}}),Object.defineProperty(r,"getEventSignature",{enumerable:!0,get:function(){return e0.toEventSignature}});var e1=e.r(476119);Object.defineProperty(r,"toFunctionHash",{enumerable:!0,get:function(){return e1.toFunctionHash}});var e6=e.r(832768);Object.defineProperty(r,"toFunctionSelector",{enumerable:!0,get:function(){return e6.toFunctionSelector}}),Object.defineProperty(r,"getFunctionSelector",{enumerable:!0,get:function(){return e6.toFunctionSelector}});var e5=e.r(755535);Object.defineProperty(r,"toFunctionSignature",{enumerable:!0,get:function(){return e5.toFunctionSignature}}),Object.defineProperty(r,"getFunctionSignature",{enumerable:!0,get:function(){return e5.toFunctionSignature}});var e2=e.r(81148);Object.defineProperty(r,"defineKzg",{enumerable:!0,get:function(){return e2.defineKzg}});var e8=e.r(125913);Object.defineProperty(r,"setupKzg",{enumerable:!0,get:function(){return e8.setupKzg}});var e3=e.r(196270);Object.defineProperty(r,"createNonceManager",{enumerable:!0,get:function(){return e3.createNonceManager}}),Object.defineProperty(r,"nonceManager",{enumerable:!0,get:function(){return e3.nonceManager}});var e4=e.r(961639);Object.defineProperty(r,"withCache",{enumerable:!0,get:function(){return e4.withCache}});var e9=e.r(607327);Object.defineProperty(r,"withRetry",{enumerable:!0,get:function(){return e9.withRetry}});var e7=e.r(631674);Object.defineProperty(r,"withTimeout",{enumerable:!0,get:function(){return e7.withTimeout}});var te=e.r(210428);Object.defineProperty(r,"compactSignatureToSignature",{enumerable:!0,get:function(){return te.compactSignatureToSignature}});var tt=e.r(349779);Object.defineProperty(r,"hashMessage",{enumerable:!0,get:function(){return tt.hashMessage}});var tr=e.r(102155);Object.defineProperty(r,"hashDomain",{enumerable:!0,get:function(){return tr.hashDomain}}),Object.defineProperty(r,"hashStruct",{enumerable:!0,get:function(){return tr.hashStruct}}),Object.defineProperty(r,"hashTypedData",{enumerable:!0,get:function(){return tr.hashTypedData}
4});var tn=e.r(284741);Object.defineProperty(r,"isErc6492Signature",{enumerable:!0,get:function(){return tn.isErc6492Signature}});var ti=e.r(85928);Object.defineProperty(r,"isErc8010Signature",{enumerable:!0,get:function(){return ti.isErc8010Signature}});var ta=e.r(67053);Object.defineProperty(r,"hexToCompactSignature",{enumerable:!0,get:function(){return ta.parseCompactSignature}}),Object.defineProperty(r,"parseCompactSignature",{enumerable:!0,get:function(){return ta.parseCompactSignature}});var to=e.r(259854);Object.defineProperty(r,"parseErc6492Signature",{enumerable:!0,get:function(){return to.parseErc6492Signature}});var ts=e.r(464244);Object.defineProperty(r,"parseErc8010Signature",{enumerable:!0,get:function(){return ts.parseErc8010Signature}});var tc=e.r(307374);Object.defineProperty(r,"hexToSignature",{enumerable:!0,get:function(){return tc.parseSignature}}),Object.defineProperty(r,"parseSignature",{enumerable:!0,get:function(){return tc.parseSignature}});var tu=e.r(935083);Object.defineProperty(r,"recoverAddress",{enumerable:!0,get:function(){return tu.recoverAddress}});var tl=e.r(270988);Object.defineProperty(r,"recoverMessageAddress",{enumerable:!0,get:function(){return tl.recoverMessageAddress}});var td=e.r(436824);Object.defineProperty(r,"recoverPublicKey",{enumerable:!0,get:function(){return td.recoverPublicKey}});var tf=e.r(381585);Object.defineProperty(r,"recoverTransactionAddress",{enumerable:!0,get:function(){return tf.recoverTransactionAddress}});var tp=e.r(778956);Object.defineProperty(r,"recoverTypedDataAddress",{enumerable:!0,get:function(){return tp.recoverTypedDataAddress}});var th=e.r(287273);Object.defineProperty(r,"compactSignatureToHex",{enumerable:!0,get:function(){return th.serializeCompactSignature}}),Object.defineProperty(r,"serializeCompactSignature",{enumerable:!0,get:function(){return th.serializeCompactSignature}});var tm=e.r(870872);Object.defineProperty(r,"serializeErc6492Signature",{enumerable:!0,get:function(){return tm.serializeErc6492Signature}});var tb=e.r(296890);Object.defineProperty(r,"serializeErc8010Signature",{enumerable:!0,get:function(){return tb.serializeErc8010Signature}});var ty=e.r(802567);Object.defineProperty(r,"signatureToHex",{enumerable:!0,get:function(){return ty.serializeSignature}}),Object.defineProperty(r,"serializeSignature",{enumerable:!0,get:function(){return ty.serializeSignature}});var tg=e.r(748582);Object.defineProperty(r,"signatureToCompactSignature",{enumerable:!0,get:function(){return tg.signatureToCompactSignature}});var tv=e.r(145046);Object.defineProperty(r,"toPrefixedMessage",{enumerable:!0,get:function(){return tv.toPrefixedMessage}});var tw=e.r(114142);Object.defineProperty(r,"verifyHash",{enumerable:!0,get:function(){return tw.verifyHash}});var tE=e.r(413996);Object.defineProperty(r,"verifyMessage",{enumerable:!0,get:function(){return tE.verifyMessage}});var tP=e.r(51057);Object.defineProperty(r,"verifyTypedData",{enumerable:!0,get:function(){return tP.verifyTypedData}});var tx=e.r(905241);Object.defineProperty(r,"stringify",{enumerable:!0,get:function(){return tx.stringify}});var tA=e.r(854495);Object.defineProperty(r,"assertRequest",{enumerable:!0,get:function(){return tA.assertRequest}});var tI=e.r(165824);Object.defineProperty(r,"assertTransactionEIP1559",{enumerable:!0,get:function(){return tI.assertTransactionEIP1559}}),Object.defineProperty(r,"assertTransactionEIP2930",{enumerable:!0,get:function(){return tI.assertTransactionEIP2930}}),Object.defineProperty(r,"assertTransactionLegacy",{enumerable:!0,get:function(){return tI.assertTransactionLegacy}});var tT=e.r(363701);Object.defineProperty(r,"getSerializedTransactionType",{enumerable:!0,get:function(){return tT.getSerializedTransactionType}});var tS=e.r(446558);Object.defineProperty(r,"getTransactionType",{enumerable:!0,get:function(){return tS.getTransactionType}});var tC=e.r(523060);Object.defineProperty(r,"parseTransaction",{enumerable:!0,get:function(){return tC.parseTransaction}});var tO=e.r(687715);Object.defineProperty(r,"serializeAccessList",{enumerable:!0,get:function(){return tO.serializeAccessList}});var tj=e.r(567328);Object.defineProperty(r,"serializeTransaction",{enumerable:!0,get:function(){return tj.serializeTransaction}});var tk=e.r(976056);Object.defineProperty(r,"domainSeparator",{enumerable:!0,get:function(){return tk.domainSeparator}}),Object.defineProperty(r,"getTypesForEIP712Domain",{enumerable:!0,get:function(){return tk.getTypesForEIP712Domain}}),Object.defineProperty(r,"serializeTypedData",{enumerable:!0,get:function(){return tk.serializeTypedData}
4}),Object.defineProperty(r,"validateTypedData",{enumerable:!0,get:function(){return tk.validateTypedData}});var tR=e.r(65942);Object.defineProperty(r,"formatEther",{enumerable:!0,get:function(){return tR.formatEther}});var t_=e.r(42506);Object.defineProperty(r,"formatGwei",{enumerable:!0,get:function(){return t_.formatGwei}});var tB=e.r(638809);Object.defineProperty(r,"formatUnits",{enumerable:!0,get:function(){return tB.formatUnits}});var tM=e.r(556170);Object.defineProperty(r,"parseEther",{enumerable:!0,get:function(){return tM.parseEther}});var tF=e.r(923285);Object.defineProperty(r,"parseGwei",{enumerable:!0,get:function(){return tF.parseGwei}});var tN=e.r(955265);Object.defineProperty(r,"parseUnits",{enumerable:!0,get:function(){return tN.parseUnits}})},409467,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.version=void 0,r.version="0.1.1"},860780,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getUrl=function(e){return e},r.getVersion=function(){return n.version},r.prettyPrint=function(e){if(!e)return"";let t=Object.entries(e).map(e=>{let[t,r]=e;return void 0===r||!1===r?null:[t,r]}).filter(Boolean),r=t.reduce((e,t)=>{let[r]=t;return Math.max(e,r.length)},0);return t.map(e=>{let[t,n]=e;return`  ${`${t}:`.padEnd(r+1)}  ${n}`}).join("\n")};let n=e.r(409467)},934704,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.BaseError=void 0;let n=e.r(860780);class i extends Error{static setStaticOptions(e){i.prototype.docsOrigin=e.docsOrigin,i.prototype.showVersion=e.showVersion,i.prototype.version=e.version}constructor(e,t={}){const r=(()=>{if(t.cause instanceof i){if(t.cause.details)return t.cause.details;if(t.cause.shortMessage)return t.cause.shortMessage}return t.cause&&"details"in t.cause&&"string"==typeof t.cause.details?t.cause.details:t.cause?.message?t.cause.message:t.details})(),n=t.cause instanceof i&&t.cause.docsPath||t.docsPath,a=t.docsOrigin??i.prototype.docsOrigin,o=`${a}${n??""}`,s=!!(t.version??i.prototype.showVersion),c=t.version??i.prototype.version;super([e||"An error occurred.",...t.metaMessages?["",...t.metaMessages]:[],...r||n||s?["",r?`Details: ${r}`:void 0,n?`See: ${o}`:void 0,s?`Version: ${c}`:void 0]:[]].filter(e=>"string"==typeof e).join("\n"),t.cause?{cause:t.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsOrigin",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showVersion",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.cause=t.cause,this.details=r,this.docs=o,this.docsOrigin=a,this.docsPath=n,this.shortMessage=e,this.showVersion=s,this.version=c}walk(e){return function e(t,r){return r?.(t)?t:t&&"object"==typeof t&&"cause"in t&&t.cause?e(t.cause,r):r?null:t}(this,e)}}r.BaseError=i,Object.defineProperty(i,"defaultStaticOptions",{enumerable:!0,configurable:!0,writable:!0,value:{docsOrigin:"https://oxlib.sh",showVersion:!1,version:`ox@${(0,n.getVersion)()}`}}),i.setStaticOptions(i.defaultStaticOptions)},85683,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.charCodeMap=void 0,r.assertSize=function(e,t){if(n.size(e)>t)throw new n.SizeOverflowError({givenSize:n.size(e),maxSize:t})},r.assertStartOffset=function(e,t){if("number"==typeof t&&t>0&&t>n.size(e)-1)throw new n.SliceOffsetOutOfBoundsError({offset:t,position:"start",size:n.size(e)})},r.assertEndOffset=function(e,t,r){if("number"==typeof t&&"number"==typeof r&&n.size(e)!==r-t)throw new n.SliceOffsetOutOfBoundsError({offset:r,position:"end",size:n.size(e)}
4)},r.charCodeToBase16=function(e){return e>=r.charCodeMap.zero&&e<=r.charCodeMap.nine?e-r.charCodeMap.zero:e>=r.charCodeMap.A&&e<=r.charCodeMap.F?e-(r.charCodeMap.A-10):e>=r.charCodeMap.a&&e<=r.charCodeMap.f?e-(r.charCodeMap.a-10):void 0},r.pad=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{dir:r,size:i=32}=t;if(0===i)return e;if(e.length>i)throw new n.SizeExceedsPaddingSizeError({size:e.length,targetSize:i,type:"Bytes"});let a=new Uint8Array(i);for(let t=0;t<i;t++){let n="right"===r;a[n?t:i-t-1]=e[n?t:e.length-t-1]}return a},r.trim=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{dir:r="left"}=t,n=e,i=0;for(let e=0;e<n.length-1;e++)if("0"===n["left"===r?e:n.length-e-1].toString())i++;else break;return"left"===r?n.slice(i):n.slice(0,n.length-i)};let n=e.r(386319);r.charCodeMap={zero:48,nine:57,A:65,F:70,a:97,f:102}},948669,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.assertSize=function(e,t){if(n.size(e)>t)throw new n.SizeOverflowError({givenSize:n.size(e),maxSize:t})},r.assertStartOffset=function(e,t){if("number"==typeof t&&t>0&&t>n.size(e)-1)throw new n.SliceOffsetOutOfBoundsError({offset:t,position:"start",size:n.size(e)})},r.assertEndOffset=function(e,t,r){if("number"==typeof t&&"number"==typeof r&&n.size(e)!==r-t)throw new n.SliceOffsetOutOfBoundsError({offset:r,position:"end",size:n.size(e)})},r.pad=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{dir:r,size:i=32}=t;if(0===i)return e;let a=e.replace("0x","");if(a.length>2*i)throw new n.SizeExceedsPaddingSizeError({size:Math.ceil(a.length/2),targetSize:i,type:"Hex"});return`0x${a["right"===r?"padEnd":"padStart"](2*i,"0")}`},r.trim=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{dir:r="left"}=t,n=e.replace("0x",""),i=0;for(let e=0;e<n.length-1;e++)if("0"===n["left"===r?e:n.length-e-1].toString())i++;else break;return"0"===(n="left"===r?n.slice(i):n.slice(0,n.length-i))?"0x":"right"===r&&n.length%2==1?`0x${n}0`:`0x${n}`};let n=e.r(998576)},127008,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.canonicalize=function e(t){if(null===t||"boolean"==typeof t||"string"==typeof t)return JSON.stringify(t);if("number"==typeof t){if(!Number.isFinite(t))throw TypeError("Cannot canonicalize non-finite number");return Object.is(t,-0)?"0":JSON.stringify(t)}if("bigint"==typeof t)throw TypeError("Cannot canonicalize bigint");if(Array.isArray(t))return`[${t.map(t=>e(t)).join(",")}]`;if("object"==typeof t){let r=Object.keys(t).sort().reduce((r,n)=>{let i=t[n];return void 0!==i&&r.push(`${JSON.stringify(n)}:${e(i)}`),r},[]);return`{${r.join(",")}}`}},r.parse=function(e,t){return JSON.parse(e,(e,r)=>"string"==typeof r&&r.endsWith(n)?BigInt(r.slice(0,-n.length)):"function"==typeof t?t(e,r):r)},r.stringify=function(e,t,r){return JSON.stringify(e,(e,r)=>"function"==typeof t?t(e,r):"bigint"==typeof r?r.toString()+n:r,r)};let n="#__bigint"},386319,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.SizeExceedsPaddingSizeError=r.SliceOffsetOutOfBoundsError=r.SizeOverflowError=r.InvalidBytesTypeError=r.InvalidBytesBooleanError=void 0,r.assert=d,r.concat=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let n=0;for(let e of t)n+=e.length;let i=new Uint8Array(n);for(let e=0,r=0;e<t.length;e++){let n=t[e];i.set(n,r),r+=n.length}return i},r.from=function(e){return e instanceof Uint8Array?e:"string"==typeof e?p(e):f(e)},r.fromArray=f,r.fromBoolean=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t,n=new Uint8Array(1);return(n[0]=Number(e),"number"==typeof r)?(o.assertSize(n,r),h(n,r)):n},r.fromHex=p,r.fromNumber=function(e,t){return p(a.fromNumber(e,t))},r.fromString=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t,n=l.encode(e);return"number"==typeof r?(o.assertSize(n,r),m(n,r)):n},r.isEqual=function(e,t){return(0,n.equalBytes)(e,t)},r.padLeft=h,r.padRight=m,r.random=function(e){return crypto.getRandomValues(new Uint8Array(e))},r.size=function(e){return e.length},r.slice=function(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},{strict:i}=n;o.assertStartOffset(e,t);let a=e.slice(t,r);return i&&o.assertEndOffset(a,t,r),a},r.toBigInt=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t;void 0!==r&&o.assertSize(e,r);let n=a.fromBytes(e,t);return a.toBigInt(n,t)},r.toBoolean=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t,n=e;if(void 0!==r&&(o.assertSize(n,r),n=b(n)),n.length>1||n[0]>1)throw new g(n);return!!n[0]},r.toHex=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return a.fromBytes(e,t)},r.toNumber=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t;void 0!==r&&o.assertSize(e,r);let n=a.fromBytes(e,t);return a.toNumber(n,t)},r.toString=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t,n=e;return void 0!==r&&(o.assertSize(n,r),n=y(n)),u.decode(n)},r.trimLeft=b,r.trimRight=y,r.validate=function(e){try{return d(e),!0}catch{return!1}};let n=e.r(832672),i=e.r(934704),a=e.r(998576),o=e.r(85683),s=e.r(948669),c=e.r(127008),u=new TextDecoder,l=new TextEncoder;function d(e){if(!(e instanceof Uint8Array)&&(!e||"object"!=typeof e||!("BYTES_PER_ELEMENT"in e)||1!==e.BYTES_PER_ELEMENT||"Uint8Array"!==e.constructor.name))throw new v(e)}function f(e){return e instanceof Uint8Array?e:new Uint8Array(e)}function p(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t,n=e;r&&(s.assertSize(e,r),n=a.padRight(e,r));let c=n.slice(2);c.length%2&&(c=`0${c}`);let u=c.length/2,l=new Uint8Array(u);for(let e=0,t=0;e<u;
4e++){let r=o.charCodeToBase16(c.charCodeAt(t++)),n=o.charCodeToBase16(c.charCodeAt(t++));if(void 0===r||void 0===n)throw new i.BaseError(`Invalid byte sequence ("${c[t-2]}${c[t-1]}" in "${c}").`);l[e]=r<<4|n}return l}function h(e,t){return o.pad(e,{dir:"left",size:t})}function m(e,t){return o.pad(e,{dir:"right",size:t})}function b(e){return o.trim(e,{dir:"left"})}function y(e){return o.trim(e,{dir:"right"})}class g extends i.BaseError{constructor(e){super(`Bytes value \`${e}\` is not a valid boolean.`,{metaMessages:["The bytes array must contain a single byte of either a `0` or `1` value."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.InvalidBytesBooleanError"})}}r.InvalidBytesBooleanError=g;class v extends i.BaseError{constructor(e){super(`Value \`${"object"==typeof e?c.stringify(e):e}\` of type \`${typeof e}\` is an invalid Bytes value.`,{metaMessages:["Bytes values must be of type `Bytes`."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.InvalidBytesTypeError"})}}r.InvalidBytesTypeError=v;class w extends i.BaseError{constructor({givenSize:e,maxSize:t}){super(`Size cannot exceed \`${t}\` bytes. Given size: \`${e}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeOverflowError"})}}r.SizeOverflowError=w;class E extends i.BaseError{constructor({offset:e,position:t,size:r}){super(`Slice ${"start"===t?"starting":"ending"} at offset \`${e}\` is out-of-bounds (size: \`${r}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SliceOffsetOutOfBoundsError"})}}r.SliceOffsetOutOfBoundsError=E;class P extends i.BaseError{constructor({size:e,targetSize:t,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${e}\`) exceeds padding size (\`${t}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeExceedsPaddingSizeError"})}}r.SizeExceedsPaddingSizeError=P},998576,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.SizeExceedsPaddingSizeError=r.SliceOffsetOutOfBoundsError=r.SizeOverflowError=r.InvalidLengthError=r.InvalidHexValueError=r.InvalidHexTypeError=r.InvalidHexBooleanError=r.IntegerOutOfRangeError=void 0,r.assert=d,r.concat=function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return`0x${t.reduce((e,t)=>e+t.replace("0x",""),"")}`},r.from=function(e){return e instanceof Uint8Array?f(e):Array.isArray(e)?f(new Uint8Array(e)):e},r.fromBoolean=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=`0x${Number(e)}`;return"number"==typeof t.size?(s.assertSize(r,t.size),p(r,t.size)):r},r.fromBytes=f,r.fromNumber=function(e){let t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{signed:n,size:i}=r,a=BigInt(e);i?t=n?(1n<<8n*BigInt(i)-1n)-1n:2n**(8n*BigInt(i))-1n:"number"==typeof e&&(t=BigInt(Number.MAX_SAFE_INTEGER));let o="bigint"==typeof t&&n?-t-1n:0;if(t&&a>t||a<o){let r="bigint"==typeof e?"n":"";throw new y({max:t?`${t}${r}`:void 0,min:`${o}${r}`,signed:n,size:i,value:`${e}${r}`})}let s=(n&&a<0?BigInt.asUintN(8*i,BigInt(a)):a).toString(16),c=`0x${s}`;return i?p(c,i):c},r.fromString=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return f(u.encode(e),t)},r.isEqual=function(e,t){return(0,n.equalBytes)(i.fromHex(e),i.fromHex(t))},r.padLeft=p,r.padRight=h,r.random=function(e){return f(i.random(e))},r.slice=function(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},{strict:i}=n;s.assertStartOffset(e,t);let a=`0x${e.replace("0x","").slice((t??0)*2,(r??e.length)*2)}`;return i&&s.assertEndOffset(a,t,r),a},r.size=function(e){return Math.ceil((e.length-2)/2)},r.trimLeft=m,r.trimRight=function(e){return s.trim(e,{dir:"right"})},r.toBigInt=b,r.toBoolean=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t.size&&s.assertSize(e,t.size);let r=m(e);if("0x"===r)return!1;if("0x1"===r)return!0;throw new g(e)},r.toBytes=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return i.fromHex(e,t)},r.toNumber=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{signed:r,size:n}=t;return r||n?Number(b(e,t)):Number(e)},r.toString=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{size:r}=t,n=i.fromHex(e);return r&&(o.assertSize(n,r),n=i.trimRight(n)),new TextDecoder().decode(n)},r.validate=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{strict:r=!1}=t;try{return d(e,{strict:r}),!0}catch{return!1}};let n=e.r(832672),i=e.r(386319),a=e.r(934704),o=e.r(85683),s=e.r(948669),c=e.r(127008),u=new TextEncoder,l=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{strict:r=!1}=t;if(!e||"string"!=typeof e)throw new v(e);
4if(r&&!/^0x[0-9a-fA-F]*$/.test(e)||!e.startsWith("0x"))throw new w(e)}function f(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r="";for(let t=0;t<e.length;t++)r+=l[e[t]];let n=`0x${r}`;return"number"==typeof t.size?(s.assertSize(n,t.size),h(n,t.size)):n}function p(e,t){return s.pad(e,{dir:"left",size:t})}function h(e,t){return s.pad(e,{dir:"right",size:t})}function m(e){return s.trim(e,{dir:"left"})}function b(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{signed:r}=t;t.size&&s.assertSize(e,t.size);let n=BigInt(e);if(!r)return n;let i=(1n<<8n*BigInt((e.length-2)/2))-1n;return n<=i>>1n?n:n-i-1n}class y extends a.BaseError{constructor({max:e,min:t,signed:r,size:n,value:i}){super(`Number \`${i}\` is not in safe${n?` ${8*n}-bit`:""}${r?" signed":" unsigned"} integer range ${e?`(\`${t}\` to \`${e}\`)`:`(above \`${t}\`)`}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.IntegerOutOfRangeError"})}}r.IntegerOutOfRangeError=y;class g extends a.BaseError{constructor(e){super(`Hex value \`"${e}"\` is not a valid boolean.`,{metaMessages:['The hex value must be `"0x0"` (false) or `"0x1"` (true).']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexBooleanError"})}}r.InvalidHexBooleanError=g;class v extends a.BaseError{constructor(e){super(`Value \`${"object"==typeof e?c.stringify(e):e}\` of type \`${typeof e}\` is an invalid hex type.`,{metaMessages:['Hex types must be represented as `"0x${string}"`.']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexTypeError"})}}r.InvalidHexTypeError=v;class w extends a.BaseError{constructor(e){super(`Value \`${e}\` is an invalid hex value.`,{metaMessages:['Hex values must start with `"0x"` and contain only hexadecimal characters (0-9, a-f, A-F).']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexValueError"})}}r.InvalidHexValueError=w;class E extends a.BaseError{constructor(e){super(`Hex value \`"${e}"\` is an odd length (${e.length-2} nibbles).`,{metaMessages:["It must be an even length."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidLengthError"})}}r.InvalidLengthError=E;class P extends a.BaseError{constructor({givenSize:e,maxSize:t}){super(`Size cannot exceed \`${t}\` bytes. Given size: \`${e}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeOverflowError"})}}r.SizeOverflowError=P;class x extends a.BaseError{constructor({offset:e,position:t,size:r}){super(`Slice ${"start"===t?"starting":"ending"} at offset \`${e}\` is out-of-bounds (size: \`${r}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SliceOffsetOutOfBoundsError"})}}r.SliceOffsetOutOfBoundsError=x;class A extends a.BaseError{constructor({size:e,targetSize:t,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${e}\`) exceeds padding size (\`${t}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeExceedsPaddingSizeError"})}}r.SizeExceedsPaddingSizeError=A},814891,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.fromRpc=function(e){return{...e,amount:BigInt(e.amount),index:Number(e.index),validatorIndex:Number(e.validatorIndex)}},r.toRpc=function(e){return{address:e.address,amount:n.fromNumber(e.amount),index:n.fromNumber(e.index),validatorIndex:n.fromNumber(e.validatorIndex)}};let n=e.r(998576)},872874,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.fromRpc=function(e){return{...e.baseFeePerGas&&{baseFeePerGas:BigInt(e.baseFeePerGas)},...e.blobBaseFee&&{blobBaseFee:BigInt(e.blobBaseFee)},...e.feeRecipient&&{feeRecipient:e.feeRecipient},...e.gasLimit&&{gasLimit:BigInt(e.gasLimit)},...e.number&&{number:BigInt(e.number)},...e.prevRandao&&{prevRandao:BigInt(e.prevRandao)},...e.time&&{time:BigInt(e.time)},...e.withdrawals&&{withdrawals:e.withdrawals.map(i.fromRpc)}}},r.toRpc=function(e){return{..."bigint"==typeof e.baseFeePerGas&&{baseFeePerGas:n.fromNumber(e.baseFeePerGas)},..."bigint"==typeof e.blobBaseFee&&{blobBaseFee:n.fromNumber(e.blobBaseFee)},..."string"==typeof e.feeRecipient&&{feeRecipient:e.feeRecipient},..."bigint"==typeof e.gasLimit&&{gasLimit:n.fromNumber(e.gasLim
4it)},..."bigint"==typeof e.number&&{number:n.fromNumber(e.number)},..."bigint"==typeof e.prevRandao&&{prevRandao:n.fromNumber(e.prevRandao)},..."bigint"==typeof e.time&&{time:n.fromNumber(e.time)},...e.withdrawals&&{withdrawals:e.withdrawals.map(i.toRpc)}}};let n=e.r(998576),i=e.r(814891)},277779,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.erc4626Abi=r.erc721Abi=r.erc1155Abi=r.erc20Abi_bytes32=r.erc20Abi=r.erc6492SignatureValidatorAbi=r.erc1271Abi=r.addressResolverAbi=r.textResolverAbi=r.universalResolverReverseAbi=r.universalResolverResolveAbi=r.batchGatewayAbi=r.multicall3Abi=void 0,r.multicall3Abi=[{inputs:[{components:[{name:"target",type:"address"},{name:"allowFailure",type:"bool"},{name:"callData",type:"bytes"}],name:"calls",type:"tuple[]"}],name:"aggregate3",outputs:[{components:[{name:"success",type:"bool"},{name:"returnData",type:"bytes"}],name:"returnData",type:"tuple[]"}],stateMutability:"view",type:"function"},{inputs:[{name:"addr",type:"address"}],name:"getEthBalance",outputs:[{name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentBlockTimestamp",outputs:[{internalType:"uint256",name:"timestamp",type:"uint256"}],stateMutability:"view",type:"function"}],r.batchGatewayAbi=[{name:"query",type:"function",stateMutability:"view",inputs:[{type:"tuple[]",name:"queries",components:[{type:"address",name:"sender"},{type:"string[]",name:"urls"},{type:"bytes",name:"data"}]}],outputs:[{type:"bool[]",name:"failures"},{type:"bytes[]",name:"responses"}]},{name:"HttpError",type:"error",inputs:[{type:"uint16",name:"status"},{type:"string",name:"message"}]}];let n=[{inputs:[{name:"dns",type:"bytes"}],name:"DNSDecodingFailed",type:"error"},{inputs:[{name:"ens",type:"string"}],name:"DNSEncodingFailed",type:"error"},{inputs:[],name:"EmptyAddress",type:"error"},{inputs:[{name:"status",type:"uint16"},{name:"message",type:"string"}],name:"HttpError",type:"error"},{inputs:[],name:"InvalidBatchGatewayResponse",type:"error"},{inputs:[{name:"errorData",type:"bytes"}],name:"ResolverError",type:"error"},{inputs:[{name:"name",type:"bytes"},{name:"resolver",type:"address"}],name:"ResolverNotContract",type:"error"},{inputs:[{name:"name",type:"bytes"}],name:"ResolverNotFound",type:"error"},{inputs:[{name:"primary",type:"string"},{name:"primaryAddress",type:"bytes"}],name:"ReverseAddressMismatch",type:"error"},{inputs:[{internalType:"bytes4",name:"selector",type:"bytes4"}],name:"UnsupportedResolverProfile",type:"error"}];r.universalResolverResolveAbi=[...n,{name:"resolveWithGateways",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"},{name:"gateways",type:"string[]"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]}],r.universalResolverReverseAbi=[...n,{name:"reverseWithGateways",type:"function",stateMutability:"view",inputs:[{type:"bytes",name:"reverseName"},{type:"uint256",name:"coinType"},{type:"string[]",name:"gateways"}],outputs:[{type:"string",name:"resolvedName"},{type:"address",name:"resolver"},{type:"address",name:"reverseResolver"}]}],r.textResolverAbi=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],r.addressResolverAbi=[{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"}],outputs:[{name:"",type:"address"}]},{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"coinType",type:"uint256"}],outputs:[{name:"",type:"bytes"}]}],r.erc1271Abi=[{name:"isValidSignature",type:"function",stateMutability:"view",inputs:[{name:"hash",type:"bytes32"},{name:"signature",type:"bytes"}],outputs:[{name:"",type:"bytes4"}]}],r.erc6492SignatureValidatorAbi=[{inputs:[{name:"_signer",type:"address"},{name:"_hash",type:"bytes32"},{name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"},{inputs:[{name:"_signer",type:"address"},{name:"_hash",type:"bytes32"},{name:"_signature",type:"bytes"}],outputs:[{type:"bool"}],stateMutability:"nonpayable",type:"function",name:"isValidSig"}
4],r.erc20Abi=[{type:"event",name:"Approval",inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"spender",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"event",name:"Transfer",inputs:[{indexed:!0,name:"from",type:"address"},{indexed:!0,name:"to",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"function",name:"allowance",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"spender",type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"approve",stateMutability:"nonpayable",inputs:[{name:"spender",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]},{type:"function",name:"balanceOf",stateMutability:"view",inputs:[{name:"account",type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"decimals",stateMutability:"view",inputs:[],outputs:[{type:"uint8"}]},{type:"function",name:"name",stateMutability:"view",inputs:[],outputs:[{type:"string"}]},{type:"function",name:"symbol",stateMutability:"view",inputs:[],outputs:[{type:"string"}]},{type:"function",name:"totalSupply",stateMutability:"view",inputs:[],outputs:[{type:"uint256"}]},{type:"function",name:"transfer",stateMutability:"nonpayable",inputs:[{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]},{type:"function",name:"transferFrom",stateMutability:"nonpayable",inputs:[{name:"sender",type:"address"},{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]}],r.erc20Abi_bytes32=[{type:"event",name:"Approval",inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"spender",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"event",name:"Transfer",inputs:[{indexed:!0,name:"from",type:"address"},{indexed:!0,name:"to",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"function",name:"allowance",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"spender",type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"approve",stateMutability:"nonpayable",inputs:[{name:"spender",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]},{type:"function",name:"balanceOf",stateMutability:"view",inputs:[{name:"account",type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"decimals",stateMutability:"view",inputs:[],outputs:[{type:"uint8"}]},{type:"function",name:"name",stateMutability:"view",inputs:[],outputs:[{type:"bytes32"}]},{type:"function",name:"symbol",stateMutability:"view",inputs:[],outputs:[{type:"bytes32"}]},{type:"function",name:"totalSupply",stateMutability:"view",inputs:[],outputs:[{type:"uint256"}]},{type:"function",name:"transfer",stateMutability:"nonpayable",inputs:[{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]},{type:"function",name:"transferFrom",stateMutability:"nonpayable",inputs:[{name:"sender",type:"address"},{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]}],r.erc1155Abi=[{inputs:[{internalType:"address",name:"sender",type:"address"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"needed",type:"uint256"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ERC1155InsufficientBalance",type:"error"},{inputs:[{internalType:"address",name:"approver",type:"address"}],name:"ERC1155InvalidApprover",type:"error"},{inputs:[{internalType:"uint256",name:"idsLength",type:"uint256"},{internalType:"uint256",name:"valuesLength",type:"uint256"}],name:"ERC1155InvalidArrayLength",type:"error"},{inputs:[{internalType:"address",name:"operator",type:"address"}],name:"ERC1155InvalidOperator",type:"error"},{inputs:[{internalType:"address",name:"receiver",type:"address"}],name:"ERC1155InvalidReceiver",type:"error"},{inputs:[{internalType:"address",name:"sender",type:"address"}],name:"ERC1155InvalidSender",type:"error"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"address",name:"owner",type:"address"}],name:"ERC1155MissingApprovalForAll",type:"error"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"account",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256[]",name:"ids",type:"uint256[]"},{indexed:!1,internalType:"uint256[]",name:"values",type:"uint256[]"}],name:"TransferBatch",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"id",type:"uint256"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"TransferSingle",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"string",name:"value",type:"string"},{indexed:!0,internalType:"uint256",name:"id",type:"uint256"}],name:"URI",type:"event"},{inputs:[{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"id",type:"uint256"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address[]",name:"accounts",type:"address[]"},{internalType:"uint256[]",name:"ids",type:"uint256[]"}],name:"balanceOfBatch",outputs:[{internalType:"uint256[]",name:"",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256[]",name:"ids",type:"uint256[]"},{internalType:"uint256[]",name:"values",type:"uint256[]"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeBatchTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"id",type:"uint256"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"uri",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"}
4],r.erc721Abi=[{type:"event",name:"Approval",inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"spender",type:"address"},{indexed:!0,name:"tokenId",type:"uint256"}]},{type:"event",name:"ApprovalForAll",inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"operator",type:"address"},{indexed:!1,name:"approved",type:"bool"}]},{type:"event",name:"Transfer",inputs:[{indexed:!0,name:"from",type:"address"},{indexed:!0,name:"to",type:"address"},{indexed:!0,name:"tokenId",type:"uint256"}]},{type:"function",name:"approve",stateMutability:"payable",inputs:[{name:"spender",type:"address"},{name:"tokenId",type:"uint256"}],outputs:[]},{type:"function",name:"balanceOf",stateMutability:"view",inputs:[{name:"account",type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"getApproved",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{type:"address"}]},{type:"function",name:"isApprovedForAll",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"operator",type:"address"}],outputs:[{type:"bool"}]},{type:"function",name:"name",stateMutability:"view",inputs:[],outputs:[{type:"string"}]},{type:"function",name:"ownerOf",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"owner",type:"address"}]},{type:"function",name:"safeTransferFrom",stateMutability:"payable",inputs:[{name:"from",type:"address"},{name:"to",type:"address"},{name:"tokenId",type:"uint256"}],outputs:[]},{type:"function",name:"safeTransferFrom",stateMutability:"nonpayable",inputs:[{name:"from",type:"address"},{name:"to",type:"address"},{name:"id",type:"uint256"},{name:"data",type:"bytes"}],outputs:[]},{type:"function",name:"setApprovalForAll",stateMutability:"nonpayable",inputs:[{name:"operator",type:"address"},{name:"approved",type:"bool"}],outputs:[]},{type:"function",name:"symbol",stateMutability:"view",inputs:[],outputs:[{type:"string"}]},{type:"function",name:"tokenByIndex",stateMutability:"view",inputs:[{name:"index",type:"uint256"}],outputs:[{type:"uint256"}]},{type:"function",name:"tokenByIndex",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"index",type:"uint256"}],outputs:[{name:"tokenId",type:"uint256"}]},{type:"function",name:"tokenURI",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{type:"string"}]},{type:"function",name:"totalSupply",stateMutability:"view",inputs:[],outputs:[{type:"uint256"}]},{type:"function",name:"transferFrom",stateMutability:"payable",inputs:[{name:"sender",type:"address"},{name:"recipient",type:"address"},{name:"tokenId",type:"uint256"}],outputs:[]}],r.erc4626Abi=[{anonymous:!1,inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"spender",type:"address"},{indexed:!1,name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"sender",type:"address"},{indexed:!0,name:"receiver",type:"address"},{indexed:!1,name:"assets",type:"uint256"},{indexed:!1,name:"shares",type:"uint256"}],name:"Deposit",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"from",type:"address"},{indexed:!0,name:"to",type:"address"},{indexed:!1,name:"value",type:"uint256"}],name:"Transfer",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"sender",type:"address"},{indexed:!0,name:"receiver",type:"address"},{indexed:!0,name:"owner",type:"address"},{indexed:!1,name:"assets",type:"uint256"},{indexed:!1,name:"shares",type:"uint256"}],name:"Withdraw",type:"event"},{inputs:[{name:"owner",type:"address"},{name:"spender",type:"address"}],name:"allowance",outputs:[{type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"spender",type:"address"},{name:"amount",type:"uint256"}],name:"approve",outputs:[{type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"asset",outputs:[{name:"assetTokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{name:"account",type:"address"}],name:"balanceOf",outputs:[{type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"shares",type:"uint256"}],name:"convertToAssets",outputs:[{name:"assets",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"assets",type:"uint256"}],name:"convertToShares",outputs:[{name:"shares",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"assets",type:"uint256"},{name:"receiver",type:"address"}],name:"deposit",outputs:[{name:"shares",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{name:"caller",type:"address"}],name:"maxDeposit",outputs:[{name:"maxAssets",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"caller",type:"address"}],name:"maxMint",outputs:[{name:"maxShares",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"owner",type:"address"}],name:"maxRedeem",outputs:[{name:"maxShares",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"owner",type:"address"}],name:"maxWithdraw",outputs:[{name:"maxAssets",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"shares",type:"uint256"},{name:"receiver",type:"address"}],name:"mint",outputs:[{name:"assets",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{name:"assets",type:"uint256"}],name:"previewDeposit",outputs:[{name:"shares",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"shares",type:"uint256"}],name:"previewMint",outputs:[{name:"assets",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"shares",type:"uint256"}],name:"previewRedeem",outputs:[{name:"assets",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"assets",type:"uint256"}],name:"previewWithdraw",outputs:[{name:"shares",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"shares",type:"uint256"},{name:"receiver",type:"address"},{name:"owner",type:"address"}],name:"redeem",outputs:[{name:"assets",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"totalAssets",outputs:[{name:"totalManagedAssets",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{name:"to",type:"address"},{name:"amount",type:"uint256"}],name:"transfer",outputs:[{type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{name:"from",type:"address"},{name:"to",type:"address"},{name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{name:"assets",type:"uint256"},{name:"receiver",type:"address"},{name:"owner",type:"address"}],name:"withdraw",outputs:[{name:"shares",type:"uint256"}],stateMutability:"nonpayable",type:"function"}]},659481,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.aggregate3Signature=void 0,r.aggregate3Signature="0x82ad56cb"},286776,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.multicall3Bytecode=r.erc6492SignatureValidatorByteCode=r.deploylessCallViaFactoryBytecode=r.deploylessCallViaBytecodeBytecode=void 0,r.deploylessCallViaBytecodeBytecode="0x608060405234801561001057600080fd5b5060405161018e38038061018e83398101604081905261002f91610124565b6000808351602085016000f59050803b61004857600080fd5b6000808351602085016000855af16040513d6000823e81610067573d81fd5b3d81f35b634e487b7160e01b600052604160045260246000fd5b600082601f83011261009257600080fd5b81516001600160401b038111156100ab576100ab61006b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156100d9576100d961006b565b6040528181528382016020018510156100f157600080fd5b60005b82811015610110576020818601810151838301820152016100f4565b506000918101602001919091529392505050565b6000806040838503121561013757600080fd5b82516001600160401b0381111561014d57600080fd5b61015985828601610081565b602085015190935090506001600160401b0381111561017757600080fd5b61018385828601610081565b915050925092905056fe",r.deploylessCallViaFactoryBytecode="0x608060405234801561001057600080fd5b506040516102c03803806102c083398101604081905261002f916101e6565b836001600160a01b03163b6000036100e457600080836001600160a01b03168360405161005c9190610270565b6000604051808303816000865af19150503d8060008114610099576040519150601f19603f3d011682016040523d82523d6000602084013e61009e565b606091505b50915091508115806100b857506001600160a01b0386163b155b156100e1578060405163101bb98d60e01b81526004016100d8919061028c565b60405180910390fd5b50505b6000808451602086016000885af16040513d6000823e81610103573d81fd5b3d81f35b80516001600160a01b038116811461011e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561015457818101518382015260200161013c565b50506000910152565b600082601f83011261016e57600080fd5b81516001600160401b0381111561018757610187610123565b604051601f8201601f19908116603f011681016001600160401b03811182821017156101b5576101b5610123565b6040528181528382016020018510156101cd57600080fd5b6101de826020830160208701610139565b949350505050565b600080600080608085870312156101fc57600080fd5b61020585610107565b60208601519094506001600160401b0381111561022157600080fd5b61022d8782880161015d565b93505061023c60408601610107565b60608601519092506001600160401b0381111561025857600080fd5b6102648782880161015d565b91505092959194509250565b60008251610282818460208701610139565b9190910192915050565b60208152600082518060208401526102ab816040850160208701610139565b601f01601f1916919091016040019291505056fe",r.erc6492SignatureValidatorByteCode="0x608060405234801561001057600080fd5b5060405161069438038061069483398101604081905261002f9161051e565b600061003c848484610048565b9050806000526001601ff35b60007f64926492649264926492649264926492649264926492649264926492649264926100748361040c565b036101e7576000606080848060200190518101906100929190610577565b60405192955090935091506000906001600160a01b038516906100b69085906105dd565b6000604051808303816000865af19150503d80600081146100f3576040519150601f19603f3d011682016040523d82523d6000602084013e6100f8565b606091505b50509050876001600160a01b03163b60000361016057806101605760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90610190908b9087906004016105f9565b602060405180830381865afa1580156101ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101d19190610633565b6001600160e01b03191614945050505050610405565b6001600160a01b0384163b1561027a57604051630b135d3f60e11b808252906001600160a01b03861690631626ba7e9061022790879087906004016105f9565b602060405180830381865afa158015610244573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102689190610633565b6001600160e01b031916149050610405565b81516041146102df5760405162461bcd60e51b815260206004820152603a602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e6774680000000000006064820152608401610157565b6102e7610425565b5060208201516040808401518451859392600091859190811061030c5761030c61065d565b016020015160f81c9050601b811480159061032b57508060ff16601c14155b1561038c5760405162461bcd60e51b8152
460206004820152603b602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c756500000000006064820152608401610157565b60408051600081526020810180835289905260ff83169181019190915260608101849052608081018390526001600160a01b0389169060019060a0016020604051602081039080840390855afa1580156103ea573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149450505050505b9392505050565b600060208251101561041d57600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b038116811461045857600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561048c578181015183820152602001610474565b50506000910152565b600082601f8301126104a657600080fd5b81516001600160401b038111156104bf576104bf61045b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156104ed576104ed61045b565b60405281815283820160200185101561050557600080fd5b610516826020830160208701610471565b949350505050565b60008060006060848603121561053357600080fd5b835161053e81610443565b6020850151604086015191945092506001600160401b0381111561056157600080fd5b61056d86828701610495565b9150509250925092565b60008060006060848
4603121561058c57600080fd5b835161059781610443565b60208501519093506001600160401b038111156105b357600080fd5b6105bf86828701610495565b604086015190935090506001600160401b0381111561056157600080fd5b600082516105ef818460208701610471565b9190910192915050565b828152604060208201526000825180604084015261061e816060850160208701610471565b601f01601f1916919091016060019392505050565b60006020828403121561064557600080fd5b81516001600160e01b03198116811461040557600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572",r.multicall3Bytecode="0x608060405234801561001057600080fd5b506115b9806100206000396000f3fe6080604052600436106100f35760003560e01c80634d2301cc1161008a578063a8b0574e11610059578063a8b0574e14610325578063bce38bd714610350578063c3077fa914610380578063ee82ac5e146103b2576100f3565b80634d2301cc1461026257806372425d9d1461029f57806382ad56cb146102ca57806386d516e8146102fa576100f3565b80633408e470116100c65780633408e470146101af578063399542e9146101da5780633e64a6961461020c57806342cbb15c14610237576100f3565b80630f28c97d146100f8578063174dea7114610123578063252dba421461015357806327e86d6e14610184575b600080fd5b34801561010457600080fd5b5061010d6103ef565b60405161011a9190610c0a565b60405180910390f35b61013d60048036038101906101389190610c94565b6103f7565b60405161014a9190610e94565b60405180910390f35b61016d60048036038101906101689190610f0c565b610615565b60405161017b92919061101b565b60405180910390f35b34801561019057600080fd5b506101996107ab565b6040516101a69190611064565b60405180910390f35b3480156101bb57600080fd5b506101c46107b7565b6040516101d19190610c0a565b60405180910390f35b6101f460048036038101906101ef91906110ab565b6107bf565b6040516102039392919061110b565b60405180910390f35b34801561021857600080fd5b506102216107e1565b60405161022e9190610c0a565b60405180910390f35b34801561024357600080fd5b5061024c6107e9565b6040516102599190610c0a565b60405180910390f35b34801561026e57600080fd5b50610289600480360381019061028491906111a7565b6107f1565b6040516102969190610c0a565b60405180910390f35b3480156102ab57600080fd5b506102b4610812565b6040516102c19190610c0a565b60405180910390f35b6102e460048036038101906102df919061122a565b61081a565b6040516102f19190610e94565b60405180910390f35b34801561030657600080fd5b5061030f6109e4565b60405161031c9190610c0a565b60405180910390f35b34801561033157600080fd5b5061033a6109ec565b6040516103479190611286565b60405180910390f35b61036a600480360381019061036591906110ab565b6109f4565b6040516103779190610e94565b60405180910390f35b61039a60048036038101906103959190610f0c565b610ba6565b6040516103a99392919061110b565b60405180910390f35b3480156103be57600080fd5b506103d960048036038101906103d491906112cd565b610bca565b6040516103e69190611064565b60405180910390f35b600042905090565b60606000808484905090508067ffffffffffffffff81111561041c5761041b6112fa565b5b60405190808252806020026020018201604052801561045557816020015b610442610bd5565b81526020019060019003908161043a5790505b5092503660005b828110156105c957600085828151811061047957610478611329565b5b6020026020010151905087878381811061049657610495611329565b5b90506020028101906104a89190611367565b925060008360400135905080860195508360000160208101906104cb91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16818580606001906104f2919061138f565b604051610500929190611431565b60006040518083038185875af1925050503d806000811461053d576040519150601f19603f3d011682016040523d82523d6000602084013e610542565b606091505b5083600001846020018290528215151515815250505081516020850135176105bc577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260846000fd5b826001019250505061045c565b5082341461060c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610603906114a7565b60405180910390fd5b50505092915050565b6000606043915060008484905090508067ffffffffffffffff81111561063e5761063d6112fa565b5b60405190808252806020026020018201604052801561067157816020015b606081526020019060019003908161065c5790505b5091503660005b828110156107a157600087878381811061069557610694611329565b5b90506020028101906106a791906114c7565b92508260000160208101906106bc91906111a7565b73ffffffffffffffffffffffffffffffffffffffff168380602001906106e2919061138f565b6040516106f0929190611431565b6000604051808303816000865af19150503d806000811461072d576040519150601f19603f3d011682016040523d82523d6000602084013e610732565b606091505b5086848151811061074657610745611329565b5b60200260200101819052819250505080610795576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161078c9061153b565b60405180910390fd5b81600101915050610678565b5050509250929050565b60006001430340905090565b600046905090565b6000806060439250434091506107d68686866109f4565b905093509350939050565b600048905090565b600043905090565b60008173ffffffffffffffffffffffffffffffffffffffff16319050919050565b600044905090565b606060008383905090508067ffffffffffffffff81111561083e5761083d6112fa565b5b60405190808252806020026020018201604052801561087757816020015b610864610bd5565b81526020019060019003908161085c5790505b5091503660005b828110156109db57600084828151811061089b5761089a611329565b5b602002602001015190508686838181106108b8576108b7611329565b5b90506020028101906108ca919061155b565b92508260000160208101906108df91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060400190610905919061138f565b604051610913929190611431565b6000604051808303816000865af19150503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b5082600001836020018290528215151515815250505080516020840135176109cf577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260646000fd5b8160010191505061087e565b50505092915050565b600045905090565b600041905090565b606060008383905090508067ffffffffffffffff811115610a1857610a176112fa565b5b604051908082528060200260200182016040528015610a5157816020015b610a3e610bd5565b815260200190600190039081610a365790505b5091503660005b82811015610b9c576000848281518110610a7557610a74611329565b5b60200260200101519050868683818110610a9257610a91611329565b5b9050602002810190610aa491906114c7565b9250826000016020810190610ab991906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060200190610adf919061138f565b604051610aed929190611431565b6000604051808303816000865af19150503d8060008114610b2a576040519150601f19603f3d011682016040523d82523d6000602084013e610b2f565b606091505b508260000183602001829052821515151581525050508715610b90578060000151610b8f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b869061153b565b60405180910390fd5b5b81600101915050610a58565b5050509392505050565b6000806060610bb7600186866107bf565b8093508194508295505050509250925092565b600081409050919050565b6040518060400160405280600015158152602001606081525090565b6000819050919050565b610c0481610bf1565b82525050565b6000602082019050610c1f6000830184610bfb565b92915050565b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b60008083601f840112610c5457610c53610c2f565b5b8235905067ffffffffffffffff811115610c7157610c70610c34565b5b602083019150836020820283011115610c8d57610c8c610c39565b5b9250929050565b60008060208385031215610cab57610caa610c25565b5b600083013567ffffffffffffffff811115610cc957610cc8610c2a565b5b610cd585828601610c3e565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60008115159050919050565b610d2281610d0d565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b83811015610d62578082015181840152602081019050610d47565b83811115610d71576000848401525b50505050565b6000601f19601f8301169050919050565b6000610d9382610d28565b610d9d8185610d33565b9350610dad818560208601610d44565b610db681610d77565b840191505092915050565b6000604083016000830151610dd96000860182610d19565b5060208301518482036020860152610df18282610d88565b9
4150508091505092915050565b6000610e0a8383610dc1565b905092915050565b6000602082019050919050565b6000610e2a82610ce1565b610e348185610cec565b935083602082028501610e4685610cfd565b8060005b85811015610e825784840389528151610e638582610dfe565b9450610e6e83610e12565b925060208a01995050600181019050610e4a565b50829750879550505050505092915050565b60006020820190508181036000830152610eae8184610e1f565b905092915050565b60008083601f840112610ecc57610ecb610c2f565b5b8235905067ffffffffffffffff811115610ee957610ee8610c34565b5b602083019150836020820283011115610f0557610f04610c39565b5b9250929050565b60008060208385031215610f2357610f22610c25565b5b600083013567ffffffffffffffff811115610f4157610f40610c2a565b5b610f4d85828601610eb6565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000610f918383610d88565b905092915050565b6000602082019050919050565b6000610fb182610f59565b610fbb8185610f64565b935083602082028501610fcd85610f75565b8060005b858110156110095784840389528151610fea8582610f85565b9450610ff583610f99565b925060208a01995050600181019050610fd1565b50829750879550505050505092915050565b60006040820190506110306000830185610bfb565b81810360208301526110428184610fa6565b90509392505050565b6000819050919050565b61105e8161104b565b82525050565b60006020820190506110796000830184611055565b92915050565b61108881610d0d565b811461109357600080fd5b50565b6000813590506110a58161107f565b92915050565b6000806000604084860312156110c4576110c3610c25565b5b60006110d286828701611096565b935050602084013567ffffffffffffffff8111156110f3576110f2610c2a565b5b6110ff86828701610eb6565b92509250509250925092565b60006060820190506111206000830186610bfb565b61112d6020830185611055565b818103604083015261113f8184610e1f565b9050949350505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061117482611149565b9050919050565b61118481611169565b811461118f57600080fd5b50565b6000813590506111a18161117b565b92915050565b6000602082840312156111bd576111bc610c25565b5b60006111cb84828501611192565b91505092915050565b60008083601f8401126111ea576111e9610c2f565b5b8235905067ffffffffffffffff81111561120757611206610c34565b5b60208301915083602082028301111561122357611222610c39565b5b9250929050565b6000806020838503121561124157611240610c25565b5b600083013567ffffffffffffffff81111561125f5761125e610c2a565b5b61126b858286016111d4565b92509250509250929050565b61128081611169565b82525050565b600060208201905061129b6000830184611277565b92915050565b6112aa81610bf1565b81146112b557600080fd5b50565b6000813590506112c7816112a1565b92915050565b6000602082840312156112e3576112e2610c25565b5b60006112f1848285016112b8565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b60008235600160800383360303811261138357611382611358565b5b80830191505092915050565b600080833560016020038436030381126113ac576113ab611358565b5b80840192508235915067ffffffffffffffff8211156113ce576113cd61135d565b5b6020830192506001820236038313156113ea576113e9611362565b5b509250929050565b600081905092915050565b82818337600083830152505050565b600061141883856113f2565b93506114258385846113fd565b82840190509392505050565b600061143e82848661140c565b91508190509392505050565b600082825260208201905092915050565b7f4d756c746963616c6c333a2076616c7565206d69736d61746368000000000000600082015250565b6000611491601a8361144a565b915061149c8261145b565b602082019050919050565b600060208201905081810360008301526114c081611484565b9050919050565b6000823560016040038336030381126114e3576114e2611358565b5b80830191505092915050565b7f4d756c746963616c6c333a2063616c6c206661696c6564000000000000000000600082015250565b600061152560178361144a565b9150611530826114ef565b602082019050919050565b6000602082019050818103600083015261155481611518565b9050919050565b60008235600160600383360303811261157757611576611358565b5b8083019150509291505056fea264697066735822122020c1bc9aacf8e4a6507193432a895a8e77094f45a1395583f07b24e860ef06cd64736f6c634300080c0033"},808894,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidChainIdError=r.ClientChainNotConfiguredError=r.ChainNotFoundError=r.ChainMismatchError=r.ChainDoesNotSupportContract=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({blockNumber:e,chain:t,contract:r}){super(`Chain "${t.name}" does not support contract "${r.name}".`,{metaMessages:["This could be due to any of the following:",...e&&r.blockCreated&&r.blockCreated>e?[`- The contract "${r.name}" was not deployed until block ${r.blockCreated} (current block ${e}).`]:[`- The chain does not have the contract "${r.name}" configured.`]],name:"ChainDoesNotSupportContract"})}}r.ChainDoesNotSupportContract=i;class a extends n.BaseError{constructor({chain:e,currentChainId:t}){super(`The current chain of the wallet (id: ${t}) does not match the target chain for the transaction (id: ${e.id} – ${e.name}).`,{metaMessages:[`Current Chain ID:  ${t}`,`Expected Chain ID: ${e.id} – ${e.name}`],name:"ChainMismatchError"})}}r.ChainMismatchError=a;class o extends n.BaseError{constructor(){super("No chain was provided to the request.\nPlease provide a chain with the `chain` argument on the Action, or by supplying a `chain` to WalletClient.",{name:"ChainNotFoundError"})}}r.ChainNotFoundError=o;class s extends n.BaseError{constructor(){super("No chain was provided to the Client.",{name:"ClientChainNotConfiguredError"})}}r.ClientChainNotConfiguredError=s;class c extends n.BaseError{constructor({chainId:e}){super("number"==typeof e?`Chain ID "${e}
4" is invalid.`:"Chain ID is invalid.",{name:"InvalidChainIdError"})}}r.InvalidChainIdError=c},286717,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.encodeDeployData=function(e){let{abi:t,args:r,bytecode:s}=e;if(!r||0===r.length)return s;let c=t.find(e=>"type"in e&&"constructor"===e.type);if(!c)throw new n.AbiConstructorNotFoundError({docsPath:o});if(!("inputs"in c)||!c.inputs||0===c.inputs.length)throw new n.AbiConstructorParamsNotFoundError({docsPath:o});let u=(0,a.encodeAbiParameters)(c.inputs,r);return(0,i.concatHex)([s,u])};let n=e.r(963101),i=e.r(985269),a=e.r(440747),o="/docs/contract/encodeDeployData"},370049,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getChainContractAddress=function(e){let{blockNumber:t,chain:r,contract:i}=e,a=r?.contracts?.[i];if(!a)throw new n.ChainDoesNotSupportContract({chain:r,contract:{name:i}});if(t&&a.blockCreated&&a.blockCreated>t)throw new n.ChainDoesNotSupportContract({blockNumber:t,chain:r,contract:{name:i,blockCreated:a.blockCreated}});return a.address};let n=e.r(808894)},537665,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getCallError=function(e,t){let r,{docsPath:o,...s}=t,c=(r=(0,a.getNodeError)(e,s))instanceof i.UnknownNodeError?e:r;return new n.CallExecutionError(c,{docsPath:o,...s})};let n=e.r(720794),i=e.r(659641),a=e.r(255397)},205616,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.withResolvers=function(){let e=()=>void 0,t=()=>void 0;return{promise:new Promise((r,n)=>{e=r,t=n}),resolve:e,reject:t}}},125590,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createBatchScheduler=function(e){let{fn:t,id:r,shouldSplitBatch:a,wait:o=0,sort:s}=e,c=async()=>{let e=l();u();let r=e.map(e=>{let{args:t}=e;return t});0!==r.length&&t(r).then(t=>{s&&Array.isArray(t)&&t.sort(s);for(let r=0;r<e.length;r++){let{resolve:n}=e[r];n?.([t[r],t])}}).catch(t=>{for(let r=0;r<e.length;r++){let{reject:n}=e[r];n?.(t)}})},u=()=>i.delete(r),l=()=>i.get(r)||[],d=e=>i.set(r,[...l(),e]);return{flush:u,async schedule(e){let{promise:t,resolve:r,reject:i}=(0,n.withResolvers)();return(a?.([...l().map(e=>{let{args:t}=e;return t}),e])&&c(),l().length>0)?d({args:e,resolve:r,reject:i}):(d({args:e,resolve:r,reject:i}),setTimeout(c,o)),t}}};let n=e.r(205616),i=new Map},716046,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.OffchainLookupSenderMismatchError=r.OffchainLookupResponseMalformedError=r.OffchainLookupError=void 0;let n=e.r(905241),i=e.r(91633),a=e.r(420065);class o extends i.BaseError{constructor({callbackSelector:e,cause:t,data:r,extraData:n,sender:i,urls:o}){super(t.shortMessage||"An error occurred while fetching for an offchain result.",{cause:t,metaMessages:[...t.metaMessages||[],t.metaMessages?.length?"":[],"Offchain Gateway Call:",o&&["  Gateway URL(s):",...o.map(e=>`    ${(0,a.getUrl)(e)}`)],`  Sender: ${i}`,`  Data: ${r}`,`  Callback selector: ${e}`,`  Extra data: ${n}`].flat(),name:"OffchainLookupError"})}}r.OffchainLookupError=o;class s extends i.BaseError{constructor({result:e,url:t}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${(0,a.getUrl)(t)}`,`Response: ${(0,n.stringify)(e)}`],name:"OffchainLookupResponseMalformedError"})}}r.OffchainLookupResponseMalformedError=s;class c extends i.BaseError{constructor({sender:e,to:t}){super("Reverted sender address does not match target contract address (`to`).",{metaMessages:[`Contract address: ${t}`,`OffchainLookup sender address: ${e}`],name:"OffchainLookupSenderMismatchError"})}}r.OffchainLookupSenderMismatchError=c},836501,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeFunctionData=function(e){let{abi:t,data:r}=e,c=(0,i.slice)(r,0,4),u=t.find(e=>"function"===e.type&&c===(0,a.toFunctionSelector)((0,s.formatAbiItem)(e)));if(!u)throw new n.AbiFunctionSignatureNotFoundError(c,{docsPath:"/docs/contract/decodeFunctionData"});return{functionName:u.name,args:"inputs"in u&&u.inputs&&u.inputs.length>0?(0,o.decodeAbiParameters)(u.inputs,(0,i.slice)(r,4)):void 0}};let n=e.r(963101),i=e.r(952195),a=e.r(832768),o=e.r(239072),s=e.r(199807)},87425,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.encodeErrorResult=function(e){let{abi:t,errorName:r,args:l}=e,d=t[0];if(r){let e=(0,c.getAbiItem)({abi:t,args:l,name:r});if(!e)throw new n.AbiErrorNotFoundError(r,{docsPath:u});d=e}if("error"!==d.type)throw new n.AbiErrorNotFoundError(void 0,{docsPath:u});let f=(0,s.formatAbiItem)(d),p=(0,a.toFunctionSelector)(f),h="0x";if(l&&l.length>0){if(!d.inputs)throw new n.AbiErrorInputsNotFoundError(d.name,{docsPath:u});h=(0,o.encodeAbiParameters)(d.inputs,l)}return(0,i.concatHex)([p,h])};let n=e.r(963101),i=e.r(985269),a=e.r(832768),o=e.r(440747),s=e.r(199807),c=e.r(409872),u="/docs/contract/encodeErrorResult"},201219,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.encodeFunctionResult=function(e){let{abi:t,functionName:r,result:s}=e,c=t[0];if(r){let e=(0,a.getAbiItem)({abi:t,name:r});if(!e)throw new n.AbiFunctionNotFoundError(r,{docsPath:o});c=e}if("function"!==c.type)throw new n.AbiFunctionNotFoundError(void 0,{docsPath:o});if(!c.outputs)throw new n.AbiFunctionOutputsNotFoundError(c.name,{docsPath:o});let u=(()=>{if(0===c.outputs.length)return[];if(1===c.outputs.length)return[s];if(Array.isArray(s))return s;throw new n.InvalidArrayError(s)})();return(0,i.encodeAbiParameters)(c.outputs,u)};let n=e.r(963101),i=e.r(440747),a=e.r(409872),o="/docs/contract/encodeFunctionResult"},639701,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.localBatchGatewayUrl=void 0,r.localBatchGatewayRequest=c;let n=e.r(277779),i=e.r(17488),a=e.r(836501),o=e.r(87425),s=e.r(201219);async function c(e){let{data:t,ccipRequest:u}=e,{args:[l]}=(0,a.decodeFunctionData)({abi:n.batchGatewayAbi,data:t}),d=[],f=[];return await Promise.all(l.map(async(e,t)=>{try{f[t]=e.urls.includes(r.localBatchGatewayUrl)?await c({data:e.data,ccipRequest:u}):await u(e),d[t]=!1}catch(e){var a;d[t]=!0,f[t]="HttpRequestError"===(a=e).name&&a.status?(0,o.encodeErrorResult)({abi:n.batchGatewayAbi,errorName:"HttpError",args:[a.status,a.shortMessage]}):(0,o.encodeErrorResult)({abi:[i.solidityError],errorName:"Error",args:["shortMessage"in a?a.shortMessage:a.message]})}})),(0,s.encodeFunctionResult)({abi:n.batchGatewayAbi,functionName:"query",result:[d,f]})}r.localBatchGatewayUrl="x-batch-gateway:true"},772187,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.offchainLookupAbiItem=r.offchainLookupSignature=void 0,r.offchainLookup=p,r.ccipRequest=h;let n=e.r(707041),i=e.r(716046),a=e.r(666442),o=e.r(369165),s=e.r(440747),c=e.r(359389),u=e.r(985269),l=e.r(528137),d=e.r(639701),f=e.r(905241);async function p(e,t){let{blockNumber:a,blockTag:l,data:f,to:p}=t,{args:m}=(0,o.decodeErrorResult)({data:f,abi:[r.offchainLookupAbiItem]}),[b,y,g,v,w]=m,{ccipRead:E}=e,P=E&&"function"==typeof E?.request?E.request:h;try{if(!(0,c.isAddressEqual)(p,b))throw new i.OffchainLookupSenderMismatchError({sender:b,to:p});let t=y.includes(d.localBatchGatewayUrl)?await (0,d.localBatchGatewayRequest)({data:g,ccipRequest:P}):await P({data:g,sender:b,urls:y}),{data:r}=await (0,n.call)(e,{blockNumber:a,blockTag:l,data:(0,u.concat)([v,(0,s.encodeAbiParameters)([{type:"bytes"},{type:"bytes"}],[t,w])]),to:p});return r}catch(e){throw new i.OffchainLookupError({callbackSelector:v,cause:e,data:f,extraData:w,sender:b,urls:y})}}async function h(e){let{data:t,sender:r,urls:n}=e,o=Error("An unknown error occurred.");for(let e=0;e<n.length;e++){let s=n[e],c=s.includes("{data}")?"GET":"POST",u="POST"===c?{data:t,sender:r}:void 0,d="POST"===c?{"Content-Type":"application/json"}:{};try{let e,n=await fetch(s.replace("{sender}",r.toLowerCase()).replace("{data}",t),{body:JSON.stringify(u),headers:d,method:c});if(e=n.headers.get("Content-Type")?.startsWith("application/json")?(await n.json()).data:await n.text(),!n.ok){o=new a.HttpRequestError({body:u,details:e?.error?(0,f.stringify)(e.error):n.statusText,headers:n.headers,status:n.status,url:s});continue}if(!(0,l.isHex)(e)){o=new i.OffchainLookupResponseMalformedError({result:e,url:s});continue}return e}catch(e){o=new a.HttpRequestError({body:u,details:e.message,url:s})}}throw o}r.offchainLookupSignature="0x556f1830",r.offchainLookupAbiItem={name:"OffchainLookup",type:"error",inputs:[{name:"sender",type:"address"},{name:"urls",type:"string[]"},{name:"callData",type:"bytes"},{name:"callbackFunction",type:"bytes4"},{name:"extraData",type:"bytes"}]}},707041,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.call=x,r.getRevertErrorData=T;let n=e.r(668691),i=e.r(872874),a=e.r(155401),o=e.r(277779),s=e.r(659481),c=e.r(286776),u=e.r(91633),l=e.r(808894),d=e.r(720794),f=e.r(320101),p=e.r(286717),h=e.r(804943),m=e.r(370049),b=e.r(850815),y=e.r(537665),g=e.r(106636),v=e.r(244319),w=e.r(125590),E=e.r(434467),P=e.r(854495);async function x(t,r){let{account:o=t.account,authorizationList:f,batch:h=!!t.batch?.multicall,blockNumber:m,blockTag:w=t.experimental_blockTag??"latest",accessList:x,blobs:S,blockOverrides:C,code:O,data:j,factory:k,factoryData:R,gas:_,gasPrice:B,maxFeePerBlobGas:M,maxFeePerGas:F,maxPriorityFeePerGas:N,nonce:U,to:H,value:z,stateOverride:L,...D}=r,$=o?(0,a.parseAccount)(o):void 0;if(O&&(k||R))throw new u.BaseError("Cannot provide both `code` & `factory`/`factoryData` as parameters.");if(O&&H)throw new u.BaseError("Cannot provide both `code` & `to` as parameters.");let q=O&&j,W=k&&R&&H&&j,G=q||W,K=q?I({code:O,data:j}):W?function(e){let{data:t,factory:r,factoryData:i,to:a}=e;return(0,p.encodeDeployData)({abi:(0,n.parseAbi)(["constructor(address, bytes, address, bytes)"]),bytecode:c.deploylessCallViaFactoryBytecode,args:[a,t,r,i]})}({data:j,factory:k,factoryData:R,to:H}):j;try{let e;(0,P.assertRequest)(r);let n=("bigint"==typeof m?(0,b.numberToHex)(m):void 0)||w,a=C?i.toRpc(C):void 0,o=(0,E.serializeStateOverride)(L),c=t.chain?.formatters?.transactionRequest?.format,u=(c||v.formatTransactionRequest)({...(0,g.extract)(D,{format:c}),accessList:x,account:$,authorizationList:f,blobs:S,data:K,gas:_,gasPrice:B,maxFeePerBlobGas:M,maxFeePerGas:F,maxPriorityFeePerGas:N,nonce:U,to:G?void 0:H,value:z},"call");if(h&&function(e){let{request:t}=e,{data:r,to:n,...i}=t;return!(!r||r.startsWith(s.aggregate3Signature))&&!!n&&!(Object.values(i).filter(e=>void 0!==e).length>0)}({request:u})&&!o&&!a)try{return await A(t,{...u,blockNumber:m,blockTag:w})}catch(e){if(!(e instanceof l.ClientChainNotConfiguredError)&&!(e instanceof l.ChainDoesNotSupportContract))throw e}let d=(e=[u,n],o&&a?[...e,o,a]:o?[...e,o]:a?[...e,{},a]:e),p=await t.request({method:"eth_call",params:d});if("0x"===p)return{data:void 0};return{data:p}}catch(o){let n=T(o),{offchainLookup:i,offchainLookupSignature:a}=await Promise.resolve().then(()=>e.r(772187));if(!1!==t.ccipRead&&n?.slice(0,10)===a&&H)return{data:await i(t,{data:n,to:H})};if(G&&n?.slice(0,10)==="0x101bb98d")throw new d.CounterfactualDeploymentFailedError({factory:k});throw(0,y.getCallError)(o,{...r,account:$,chain:t.chain})}}async function A(e,t){let{batchSize:r=1024,deployless:n=!1,wait:i=0}="object"==typeof e.batch?.multicall?e.batch.multicall:{},{blockNumber:a,blockTag:s=e.experimental_blockTag??"latest",data:u,to:p}=t,y=(()=>{if(n)return null;if(t.multicallAddress)return t.multicallAddress;if(e.chain)return(0,m.getChainContractAddress)({blockNumber:a,chain:e.chain,contract:"multicall3"});throw new l.ClientChainNotConfiguredError})(),g=("bigint"==typeof a?(0,b.numberToHex)(a):void 0)||s,{schedule:v}=(0,w.createBatchScheduler)({id:`${e.uid}.${g}`,wait:i,shouldSplitBatch:e=>e.reduce((e,t)=>{let{data:r}=t;return e+(r.length-2)},0)>2*r,fn:async t=>{let r=t.map(e=>({allowFailure:!0,callData:e.data,target:e.to})),n=(0,h.encodeFunctionData)({abi:o.multicall3Abi,args:[r],functionName:"aggregate3"}),i=await e.request({method:"eth_call",params:[{...null===y?{data:I({code:c.multicall3Bytecode,data:n})}:{to:y,data:n}},g]});return(0,f.decodeFunctionResult)({abi:o.multicall3Abi,args:[r],functionName:"aggregate3",data:i||"0x"})}}),[{returnData:E,success:P}]=await v({data:u,to:p});if(!P)throw new d.RawContractError({data:E});return"0x"===E?{data:void 0}:{data:E}}function I(e){let{code:t,data:r}=e;return(0,p.encodeDeployData)({abi:(0,n.parseAbi)(["constructor(bytes, bytes)"]),bytecode:c.deploylessCallViaBytecodeBytecode,args:[t,r]})}function T(e){if(!(e instanceof u.BaseError))return;let t=e.walk();return"object"==typeof t?.data?t.data?.data:t.data}},465300,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.readContract=c;let n=e.r(320101),i=e.r(804943),a=e.r(290881),o=e.r(388012),s=e.r(707041);async function c(e,t){let{abi:r,address:c,args:u,functionName:l,...d}=t,f=(0,i.encodeFunctionData)({abi:r,args:u,functionName:l});try{let{data:t}=await (0,o.getAction)(e,s.call,"call")({...d,data:f,to:c});return(0,n.decodeFunctionResult)({abi:r,args:u,functionName:l,data:t||"0x"})}catch(e){throw(0,a.getContractError)(e,{abi:r,address:c,args:u,docsPath:"/docs/contract/readContract",functionName:l})}}},44592,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.simulateContract=u;let n=e.r(155401),i=e.r(320101),a=e.r(804943),o=e.r(290881),s=e.r(388012),c=e.r(707041);async function u(e,t){let{abi:r,address:u,args:l,functionName:d,dataSuffix:f="string"==typeof e.dataSuffix?e.dataSuffix:e.dataSuffix?.value,...p}=t,h=p.account?(0,n.parseAccount)(p.account):e.account,m=(0,a.encodeFunctionData)({abi:r,args:l,functionName:d});try{let{data:n}=await (0,s.getAction)(e,c.call,"call")({batch:!1,data:`${m}${f?f.replace("0x",""):""}`,to:u,...p,account:h}),a=(0,i.decodeFunctionResult)({abi:r,args:l,functionName:d,data:n||"0x"}),o=r.filter(e=>"name"in e&&e.name===t.functionName);return{result:a,request:{abi:o,address:u,args:l,dataSuffix:f,functionName:d,...p,account:h}}}catch(e){throw(0,o.getContractError)(e,{abi:r,address:u,args:l,docsPath:"/docs/contract/simulateContract",functionName:d,sender:h?.address})}}},457727,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.cleanupCache=r.listenersCache=void 0,r.observe=function(e,t,i){let a=++n,o=()=>r.listenersCache.get(e)||[],s=()=>{let t,n=o();if(!n.some(e=>e.id===a))return;let i=r.cleanupCache.get(e);if(1===n.length&&i){let e=i();e instanceof Promise&&e.catch(()=>{})}t=o(),r.listenersCache.set(e,t.filter(e=>e.id!==a))},c=o();if(r.listenersCache.set(e,[...c,{id:a,fns:t}]),c&&c.length>0)return s;let u={};for(let e in t)u[e]=function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];let i=o();if(0!==i.length)for(let t of i)t.fns[e]?.(...r)};let l=i(u);return"function"==typeof l&&r.cleanupCache.set(e,l),s},r.listenersCache=new Map,r.cleanupCache=new Map;let n=0},465273,(e,t,r)=>{"use strict";async function n(e){return new Promise(t=>setTimeout(t,e))}Object.defineProperty(r,"__esModule",{value:!0}),r.wait=n},319573,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.poll=function(e,t){let{emitOnBegin:r,initialWaitTime:i,interval:a}=t,o=!0,s=()=>o=!1;return(async()=>{let t;r&&(t=await e({unpoll:s}));let c=await i?.(t)??a;await (0,n.wait)(c);let u=async()=>{o&&(await e({unpoll:s}),await (0,n.wait)(a),u())};u()})(),s};let n=e.r(465273)},961639,(e,t,r)=>{"use strict";function n(e){let t=(e,t)=>({clear:()=>t.delete(e),get:()=>t.get(e),set:r=>t.set(e,r)}),n=t(e,r.promiseCache),i=t(e,r.responseCache);return{clear:()=>{n.clear(),i.clear()},promise:n,response:i}}async function i(e,t){let{cacheKey:r,cacheTime:i=1/0}=t,a=n(r),o=a.response.get();if(o&&i>0&&Date.now()-o.created.getTime()<i)return o.data;let s=a.promise.get();s||(s=e(),a.promise.set(s));try{let e=await s;return a.response.set({created:new Date,data:e}),e}finally{a.promise.clear()}}Object.defineProperty(r,"__esModule",{value:!0}),r.responseCache=r.promiseCache=void 0,r.getCache=n,r.withCache=i,r.promiseCache=new Map,r.responseCache=new Map},789238,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getBlockNumberCache=function(e){return(0,n.getCache)(i(e))},r.getBlockNumber=a;let n=e.r(961639),i=e=>`blockNumber.${e}`;async function a(e){let{cacheTime:t=e.cacheTime}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return BigInt(await (0,n.withCache)(()=>e.request({method:"eth_blockNumber"}),{cacheKey:i(e.uid),cacheTime:t}))}},430147,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getFilterChanges=a;let n=e.r(685530),i=e.r(798336);async function a(e,t){let{filter:r}=t,a="strict"in r&&r.strict,o=await r.request({method:"eth_getFilterChanges",params:[r.id]});if("string"==typeof o[0])return o;let s=o.map(e=>(0,i.formatLog)(e));return"abi"in r&&r.abi?(0,n.parseEventLogs)({abi:r.abi,logs:s,strict:a}):s}},275863,(e,t,r)=>{"use strict";async function n(e,t){let{filter:r}=t;return r.request({method:"eth_uninstallFilter",params:[r.id]})}Object.defineProperty(r,"__esModule",{value:!0}),r.uninstallFilter=n},898019,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.watchContractEvent=function(e,t){let r,y,g,v,w,{abi:E,address:P,args:x,batch:A=!0,eventName:I,fromBlock:T,onError:S,onLogs:C,poll:O,pollingInterval:j=e.pollingInterval,strict:k}=t;return(void 0!==O?O:"bigint"==typeof T||"webSocket"!==e.transport.type&&"ipc"!==e.transport.type&&("fallback"!==e.transport.type||"webSocket"!==e.transport.transports[0].c
4onfig.type&&"ipc"!==e.transport.transports[0].config.type))?(r=k??!1,y=(0,d.stringify)(["watchContractEvent",P,x,A,e.uid,I,j,r,T]),(0,u.observe)(y,{onLogs:C,onError:S},t=>{let n,a;void 0!==T&&(n=T-1n);let o=!1,s=(0,l.poll)(async()=>{if(!o){try{a=await (0,c.getAction)(e,f.createContractEventFilter,"createContractEventFilter")({abi:E,address:P,args:x,eventName:I,strict:r,fromBlock:T})}catch{}o=!0;return}try{let i;if(a)i=await (0,c.getAction)(e,m.getFilterChanges,"getFilterChanges")({filter:a});else{let t=await (0,c.getAction)(e,p.getBlockNumber,"getBlockNumber")({});i=n&&n<t?await (0,c.getAction)(e,h.getContractEvents,"getContractEvents")({abi:E,address:P,args:x,eventName:I,fromBlock:n+1n,toBlock:t,strict:r}):[],n=t}if(0===i.length)return;if(A)t.onLogs(i);else for(let e of i)t.onLogs([e])}catch(e){a&&e instanceof i.InvalidInputRpcError&&(o=!1),t.onError?.(e)}},{emitOnBegin:!0,interval:j});return async()=>{a&&await (0,c.getAction)(e,b.uninstallFilter,"uninstallFilter")({filter:a}),s()}})):(g=(0,d.stringify)(["watchContractEvent",P,x,A,e.uid,I,j,k??!1]),v=!0,w=()=>v=!1,(0,u.observe)(g,{onLogs:C,onError:S},t=>((async()=>{try{let r=(()=>{if("fallback"===e.transport.type){let t=e.transport.transports.find(e=>"webSocket"===e.config.type||"ipc"===e.config.type);return t?t.value:e.transport}return e.transport})(),i=I?(0,o.encodeEventTopics)({abi:E,eventName:I,args:x}):[],{unsubscribe:c}=await r.subscribe({params:["logs",{address:P,topics:i}],onData(e){if(!v)return;let r=e.result;try{let{eventName:e,args:n}=(0,a.decodeEventLog)({abi:E,data:r.data,topics:r.topics,strict:k}),i=(0,s.formatLog)(r,{args:n,eventName:e});t.onLogs([i])}catch(o){let e,i;if(o instanceof n.DecodeLogDataMismatch||o instanceof n.DecodeLogTopicsMismatch){if(k)return;e=o.abiItem.name,i=o.abiItem.inputs?.some(e=>!("name"in e&&e.name))}let a=(0,s.formatLog)(r,{args:i?[]:{},eventName:e});t.onLogs([a])}},onError(e){t.onError?.(e)}});w=c,v||w()}catch(e){S?.(e)}})(),()=>w())))};let n=e.r(963101),i=e.r(477323),a=e.r(197532),o=e.r(725159),s=e.r(798336),c=e.r(388012),u=e.r(457727),l=e.r(319573),d=e.r(905241),f=e.r(627977),p=e.r(789238),h=e.r(640653),m=e.r(430147),b=e.r(275863)},825478,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.AccountTypeNotSupportedError=r.AccountNotFoundError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({docsPath:e}={}){super("Could not find an Account to execute with this Action.\nPlease provide an Account with the `account` argument on the Action, or by supplying an `account` to the Client.",{docsPath:e,docsSlug:"account",name:"AccountNotFoundError"})}}r.AccountNotFoundError=i;class a extends n.BaseError{constructor({docsPath:e,metaMessages:t,type:r}){super(`Account type "${r}" is not supported.`,{docsPath:e,metaMessages:t,name:"AccountTypeNotSupportedError"})}}r.AccountTypeNotSupportedError=a},389421,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.assertCurrentChain=function(e){let{chain:t,currentChainId:r}=e;if(!t)throw new n.ChainNotFoundError;if(r!==t.id)throw new n.ChainMismatchError({chain:t,currentChainId:r})};let n=e.r(808894)},535188,(e,t,r)=>{"use strict";async function n(e,t){let{serializedTransaction:r}=t;return e.request({method:"eth_sendRawTransaction",params:[r]},{retryCount:0})}Object.defineProperty(r,"__esModule",{value:!0}),r.sendRawTransaction=n},412731,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.sendTransaction=v;let n=e.r(155401),i=e.r(825478),a=e.r(91633),o=e.r(271077),s=e.r(389421),c=e.r(985269),u=e.r(724514),l=e.r(106636),d=e.r(244319),f=e.r(388012),p=e.r(170675),h=e.r(854495),m=e.r(865654),b=e.r(113211),y=e.r(535188),g=new p.LruMap(128);async function v(e,t){let{account:r=e.account,assertChainId:p=!0,chain:v=e.chain,accessList:w,authorizationList:E,blobs:P,data:x,dataSuffix:A="string"==typeof e.dataSuffix?e.dataSuffix:e.dataSuffix?.value,gas:I,gasPrice:T,maxFeePerBlobGas:S,maxFeePerGas:C,maxPriorityFeePerGas:O,nonce:j,type:k,value:R,..._}=t;if(void 0===r)throw new i.AccountNotFoundError({docsPath:"/docs/actions/wallet/sendTransaction"});let B=r?(0,n.parseAccount)(r):null;try{(0,h.assertRequest)(t);let r=await (async()=>t.to?t.to:null!==t.to&&E&&E.length>0?await (0,o.recoverAuthorizationAddress)({authorization:E[0]}).catch(()=>{throw new a.BaseError("`to` is required. Could not infer from `authorizationList`.")}):void 0)();if(B?.type==="json-rpc"||null===B){let t;null!==v&&(t=await (0,f.getAction)(e,m.getChainId,"getChainId")({}),p&&(0,s.assertCurrentChain)({currentChainId:t,chain:v}));let n=e.chain?.formatters?.transactionRequest?.format,i=(n||d.formatTransactionRequest)({...(0,l.extract)(_,{format:n}),accessList:w,account:B,authorizationList:E,blobs:P,chainId:t,data:A?(0,c.concat)([x??"0x",A]):x,gas:I,gasPrice:T,maxFeePerBlobGas:S,maxFeePerGas:C,maxPriorityFeePerGas:O,nonce:j,to:r,type:k,value:R},"sendTransaction"),a=g.get(e.uid);try{return await e.request({method:a?"wallet_sendTransaction":"eth_sendTransaction",params:[i]},{retryCount:0})}catch(t){if(!1===a)throw t;if("InvalidInputRpcError"===t.name||"InvalidParamsRpcError"===t.name||"MethodNotFoundRpcError"===t.name||"MethodNotSupportedRpcError"===t.name)return await e.request({method:"wallet_sendTransaction",params:[i]},{retryCount:0}).then(t=>(g.set(e.uid,!0),t)).catch(r=>{if("MethodNotFoundRpcError"===r.name||"MethodNotSupportedRpcError"===r.name)throw g.set(e.uid,!1),t;throw r});throw t}}if(B?.type==="local"){let t=await (0,f.getAction)(e,b.prepareTransactionRequest,"prepareTransactionRequest")({account:B,accessList:w,authorizationList:E,blobs:P,chain:v,data:A?(0,c.concat)([x??"0x",A]):x,gas:I,gasPrice:T,maxFeePerBlobGas:S,maxFeePerGas:C,maxPriorityFeePerGas:O,nonce:j,nonceManager:B.nonceManager,parameters:[...b.defaultParameters,"sidecars"],type:k,value:R,..._,to:r}),n=v?.serializers?.transaction,i=await B.signTransaction(t,{serializer:n});return await (0,f.getAction)(e,y.sendRawTransaction,"sendRawTransaction")({serializedTransaction:i})}if(B?.type==="smart")throw new i.AccountTypeNotSupportedError({metaMessages:["Consider using the `sendUserOperation` Action instead."],docsPath:"/docs/actions/bundler/sendUserOperation",type:"smart"});throw new i.AccountTypeNotSupportedError({docsPath:"/docs/actions/wallet/sendTransaction",type:B?.type})}catch(e){if(e instanceof i.AccountTypeNotSupportedError)throw e;throw(0,u.getTransactionError)(e,{...t,account:B,chain:t.chain||void 0})}}},31073,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.writeContract=u;let n=e.r(155401),i=e.r(825478),a=e.r(804943),o=e.r(290881),s=e.r(388012),c=e.r(412731);async function u(e,t){return u.internal(e,c.sendTransaction,"sendTransaction",t)}(u||(r.writeContract=u={})).internal=async function(e,t,r,c){let{abi:u,account:l=e.account,address:d,args:f,functionName:p,...h}=c;if(void 0===l)throw new i.AccountNotFoundError({docsPath:"/docs/contract/writeContract"});let m=l?(0,n.parseAccount)(l):null,b=(0,a.encodeFunctionData)({abi:u,args:f,functionName:p});try{return await (0,s.getAction)(e,t,r)({data:b,to:d,account:m,...h})}catch(e){throw(0,o.getContractError)(e,{abi:u,address:d,args:f,docsPath:"/docs/contract/writeContract",functionName:p,sender:m?.address})}}},106637,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getContract=function(e){let{abi:t,address:r,client:p}=e,[h,m]=p?"public"in p&&"wallet"in p?[p.public,p.wallet]:"public"in p?[p.public,void 0]:"wallet"in p?[void 0,p.wallet]:[p,p]:[void 0,void 0],b=null!=h,y=null!=m,g={},v=!1,w=!1,E=!1;for(let e of t)if("function"===e.type?"view"===e.stateMutability||"pure"===e.stateMutability?v=!0:w=!0:"event"===e.type&&(E=!0),v&&w&&E)break;return b&&(v&&(g.read=new Proxy({},{get:(e,i)=>function(){for(var e=arguments.length,a=Array(e),o=0;o<e;o++)a[o]=arguments[o];let{args:c,options:u}=d(a);return(0,n.getAction)(h,s.readContract,"readContract")({abi:t,address:r,functionName:i,args:c,...u})}})),w&&(g.simulate=new Proxy({},{get:(e,i)=>function(){for(var e=arguments.length,a=Array(e),o=0;o<e;o++)a[o]=arguments[o];let{args:s,options:u}=d(a);return(0,n.getAction)(h,c.simulateContract,"simulateContract")({abi:t,address:r,functionName:i,args:s,...u})}})),E&&(g.createEventFilter=new Proxy({},{get:(e,a)=>function(){for(var e=arguments.length,o=Array(e),s=0;s<e;s++)o[s]=arguments[s];let{args:c,options:u}=f(o,t.find(e=>"event"===e.type&&e.name===a));return(0,n.getAction)(h,i.createContractEventFilter,"createContractEventFilter")({abi:t,address:r,eventName:a,args:c,...u})}}),g.getEvents=new Proxy({},{get:(e,i)=>function(){for(var e=arguments.length,a=Array(e),s=0;s<e;s++)a[s]=arguments[s];let{args:c,options:u}=f(a,t.find(e=>"event"===e.type&&e.name===i));return(0,n.getAction)(h,o.getContractEvents,"getContractEvents")({abi:t,address:r,eventName:i,args:c,...u})}}),g.watchEvent=new Proxy({},{get:(e,i)=>function(){for(var e=arguments.length,a=Array(e),o=0;o<e;o++)a[o]=arguments[o];let{args:s,options:c}=f(a,t.find(e=>"event"===e.type&&e.name===i));return(0,n.getAction)(h,u.watchContractEvent,"watchContractEvent")({abi:t,address:r,eventName:i,args:s,...c})}}))),y&&w&&(g.write=new Proxy({},{get:(e,i)=>function(){for(var e=arguments.length,a=Array(e),o=0;o<e;o++)a[o]=arguments[o];let{args:s,options:c}=d(a);return(0,n.getAction)(m,l.writeContract,"writeContract")({abi:t,address:r,functionName:i,args:s,...c})}})),(b||y)&&w&&(g.estimateGas=new Proxy({},{get:(e,i)=>function(){for(var e=arguments.length,o=Array(e),s=0;s<e;s++)o[s]=arguments[s];let{args:c,options:u}=d(o),l=h??m;return(0,n.getAction)(l,a.estimateContractGas,"estimateContractGas")({abi:t,address:r,functionName:i,args:c,...u,account:u.account??m.account})}})),g.address=r,g.abi=t,g},r.getFunctionParameters=d,r.getEventParameters=f;let n=e.r(388012),i=e.r(627977),a=e.r(400744),o=e.r(640653),s=e.r(465300),c=e.r(44592),u=e.r(898019),l=e.r(31073);function d(e){let t=e.length&&Array.isArray(e[0]);return{args:t?e[0]:[],options:(t?e[1]:e[0])??{}}}function f(e,t){let r=!1;return Array.isArray(e[0])?r=!0:1===e.length?r=t.inputs.some(e=>e.indexed):2===e.length&&(r=!0),{args:r?e[0]:void 0,options:(r?e[1]:e[0])??{}}}},991739,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.BundleFailedError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor(e){super(`Call bundle failed with status: ${e.statusCode}`,{name:"BundleFailedError"}),Object.defineProperty(this,"result",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.result=e}}r.BundleFailedError=i},607327,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.withRetry=function(e){let{delay:t=100,retryCount:r=2,shouldRetry:i=()=>!0}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new Promise((a,o)=>{let s=async function(){let{count:c=0}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},u=async e=>{let{error:r}=e,i="function"==typeof t?t({count:c,error:r}):t;i&&await (0,n.wait)(i),s({count:c+1})};try{let t=await e();a(t)}catch(e){if(c<r&&await i({count:c,error:e}))return u({error:e});o(e)}};s()})};let n=e.r(465273)},941403,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.defineTransactionReceipt=r.receiptStatuses=void 0,r.formatTransactionReceipt=s;let n=e.r(723223),i=e.r(544995),a=e.r(798336),o=e.r(728125);function s(e,t){let i={...e,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,contractAddress:e.contractAddress?e.contractAddress:null,cumulativeGasUsed:e.cumulativeGasUsed?BigInt(e.cumulativeGasUsed):null,effectiveGasPrice:e.effectiveGasPrice?BigInt(e.effectiveGasPrice):null,gasUsed:e.gasUsed?BigInt(e.gasUsed):null,logs:e.logs?e.logs.map(e=>(0,a.formatLog)(e)):null,to:e.to?e.to:null,transactionIndex:e.transactionIndex?(0,n.hexToNumber)(e.transactionIndex):null,status:e.status?r.receiptStatuses[e.status]:null,type:e.type?o.transactionType[e.type]||e.type:null};return e.blobGasPrice&&(i.blobGasPrice=BigInt(e.blobGasPrice)),e.blobGasUsed&&(i.blobGasUsed=BigInt(e.blobGasUsed)),i}r.receiptStatuses={"0x0":"reverted","0x1":"success"},r.defineTransactionReceipt=(0,i.defineFormatter)("transactionReceipt",s)},386691,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.fallbackTransactionErrorMagicIdentifier=r.fallbackMagicIdentifier=void 0,r.sendCalls=f;let n=e.r(155401),i=e.r(91633),a=e.r(477323),o=e.r(804943),s=e.r(985269),c=e.r(723223),u=e.r(850815),l=e.r(724514),d=e.r(412731);async function f(e,t){let{account:f=e.account,chain:p=e.chain,experimental_fallback:h,experimental_fallbackDelay:m=32,forceAtomic:b=!1,id:y,version:g="2.0.0"}=t,v=f?(0,n.parseAccount)(f):null,w=t.capabilities;e.dataSuffix&&!t.capabilities?.dataSuffix&&(w="string"==typeof e.dataSuffix?{...t.capabilities,dataSuffix:{value:e.dataSuffix,optional:!0}}:{...t.capabilities,dataSuffix:{value:e.dataSuffix.value,...e.dataSuffix.required?{}:{optional:!0}}});let E=t.calls.map(e=>{let t=e.abi?(0,o.encodeFunctionData)({abi:e.abi,functionName:e.functionName,args:e.args}):e.data;return{data:e.dataSuffix&&t?(0,s.concat)([t,e.dataSuffix]):t,to:e.to,value:e.value?(0,u.numberToHex)(e.value):void 0}});try{let t=await e.request({method:"wallet_sendCalls",params:[{atomicRequired:b,calls:E,capabilities:w,chainId:(0,u.numberToHex)(p.id),from:v?.address,id:y,version:g}]},{retryCount:0});if("string"==typeof t)return{id:t};return t}catch(n){if(h&&("MethodNotFoundRpcError"===n.name||"MethodNotSupportedRpcError"===n.name||"UnknownRpcError"===n.name||n.details.toLowerCase().includes("does not exist / is not available")||n.details.toLowerCase().includes("missing or invalid. request()")||n.details.toLowerCase().includes("did not match any variant of untagged enum")||n.details.toLowerCase().includes("account upgraded to unsupported contract")||n.details.toLowerCase().includes("eip-7702 not supported")||n.details.toLowerCase().includes("unsupported wc_ method")||n.details.toLowerCase().includes("feature toggled misconfigured")||n.details.toLowerCase().includes("jsonrpcengine: response has no error or result for request"))){if(w&&Object.values(w).some(e=>!e.optional)){let e="non-optional `capabilities` are not supported on fallback to `eth_sendTransaction`.";throw new a.UnsupportedNonOptionalCapabilityError(new i.BaseError(e,{details:e}))}if(b&&E.length>1){let e="`forceAtomic` is not supported on fallback to `eth_sendTransaction`.";throw new a.AtomicityNotSupportedError(new i.BaseError(e,{details:e}))}let t=[];for(let r of E){let n=(0,d.sendTransaction)(e,{account:v,chain:p,data:r.data,to:r.to,value:r.value?(0,c.hexToBigInt)(r.value):void 0});t.push(n),m>0&&await new Promise(e=>setTimeout(e,m))}let n=await Promise.allSettled(t);if(n.every(e=>"rejected"===e.status))throw n[0].reason;let o=n.map(e=>"fulfilled"===e.status?e.value:r.fallbackTransactionErrorMagicIdentifier);return{id:(0,s.concat)([...o,(0,u.numberToHex)(p.id,{size:32}),r.fallbackMagicIdentifier])}}throw(0,l.getTransactionError)(n,{...t,account:v,chain:t.chain})}}r.fallbackMagicIdentifier="0x5792579257925792579257925792579257925792579257925792579257925792",r.fallbackTransactionErrorMagicIdentifier=(0,u.numberToHex)(0,{size:32})},578007,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.getCallsStatus=c;let n=e.r(952195),i=e.r(492678),a=e.r(723223),o=e.r(941403),s=e.r(386691);async function c(e,t){let r;async function c(t){if(t.endsWith(s.fallbackMagicIdentifier.slice(2))){let r=(0,i.trim)((0,n.sliceHex)(t,-64,-32)),o=(0,n.sliceHex)(t,0,-64).slice(2).match(/.{1,64}/g),c=await Promise.all(o.map(t=>s.fallbackTransactionErrorMagicIdentifier.slice(2)!==t?e.request({method:"eth_getTransactionReceipt",params:[`0x${t}`]},{dedupe:!0}):void 0)),u=c.some(e=>null===e)?100:c.every(e=>e?.status==="0x1")?200:c.every(e=>e?.status==="0x0")?500:600;return{atomic:!1,chainId:(0,a.hexToNumber)(r),receipts:c.filter(Boolean),status:u,version:"2.0.0"}}return e.request({method:"wallet_getCallsStatus",params:[t]})}let{atomic:u=!1,chainId:l,receipts:d,version:f="2.0.0",...p}=await c(t.id),[h,m]=(r=p.status)>=100&&r<200?["pending",r]:r>=200&&r<300?["success",r]:r>=300&&r<700?["failure",r]:"CONFIRMED"===r?["success",200]:"PENDING"===r?["pending",100]:[void 0,r];return{...p,atomic:u,chainId:l?(0,a.hexToNumber)(l):void 0,receipts:d?.map(e=>({...e,blockNumber:(0,a.hexToBigInt)(e.blockNumber),gasUsed:(0,a.hexToBigInt)(e.gasUsed),status:o.receiptStatuses[e.status]}))??[],statusCode:m,status:h,version:f}}},1260,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.WaitForCallsStatusTimeoutError=void 0,r.waitForCallsStatus=f;let n=e.r(91633),i=e.r(991739),a=e.r(388012),o=e.r(457727),s=e.r(319573),c=e.r(205616),u=e.r(607327),l=e.r(905241),d=e.r(578007);async function f(e,t){let r,{id:n,pollingInterval:f=e.pollingInterval,status:h=e=>{let{statusCode:t}=e;return 200===t||t>=300},retryCount:m=4,retryDelay:b=e=>{let{count:t}=e;return 200*~~(1<<t)},timeout:y=6e4,throwOnFailure:g=!1}=t,v=(0,l.stringify)(["waitForCallsStatus",e.uid,n]),{promise:w,resolve:E,reject:P}=(0,c.withResolvers)(),x=(0,o.observe)(v,{resolve:E,reject:P},t=>{let o=(0,s.poll)(async()=>{let s=e=>{clearTimeout(r),o(),e(),x()};try{let r=await (0,u.withRetry)(async()=>{let t=await (0,a.getAction)(e,d.getCallsStatus,"getCallsStatus")({id:n});if(g&&"failure"===t.status)throw new i.BundleFailedError(t);return t},{retryCount:m,delay:b});if(!h(r))return;s(()=>t.resolve(r))}catch(e){s(()=>t.reject(e))}},{interval:f,emitOnBegin:!0});return o});return r=y?setTimeout(()=>{x(),clearTimeout(r),P(new p({id:n}))},y):void 0,await w}class p extends n.BaseError{constructor({id:e}){super(`Timed out while waiting for call bundle with id "${e}" to be confirmed.`,{name:"WaitForCallsStatusTimeoutError"})}}r.WaitForCallsStatusTimeoutError=p},279995,(e,t,r)=>{"use strict";let n;Object.defineProperty(r,"__esModule",{value:!0}),r.uid=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:11;if(!n||i+e>512){n="",i=0;for(let e=0;e<256;e++)n+=(256+256*Math.random()|0).toString(16).substring(1)}return n.substring(i,i+++e)};let i=256},466543,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createClient=function(e){let{batch:t,chain:r,ccipRead:a,dataSuffix:o,key:s="base",name:c="Base Client",type:u="base"}=e,l=e.experimental_blockTag??("number"==typeof r?.experimental_preconfirmationTime?"pending":void 0),d=Math.min(Math.max(Math.floor((r?.blockTime??12e3)/2),500),4e3),f=e.pollingInterval??d,p=e.cacheTime??f,h=e.account?(0,n.parseAccount)(e.account):void 0,{config:m,request:b,value:y}=e.transport({account:h,chain:r,pollingInterval:f}),g={account:h,batch:t,cacheTime:p,ccipRead:a,chain:r,dataSuffix:o,key:s,name:c,pollingInterval:f,request:b,transport:{...m,...y},type:u,uid:(0,i.uid)(),...l?{experimental_blockTag:l}:{}};return Object.assign(g,{extend:function e(t){return r=>{let n=r(t);for(let e in g)delete n[e];let i={...t,...n};return Object.assign(i,{extend:e(i)})}}(g)})},r.rpcSchema=function(){return null};let n=e.r(155401),i=e.r(279995)},866540,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isNullUniversalResolverError=function(e){if(!(e instanceof n.BaseError))return!1;let t=e.walk(e=>e instanceof i.ContractFunctionRevertedError);return t instanceof i.ContractFunctionRevertedError&&(t.data?.errorName==="HttpError"||t.data?.errorName==="ResolverError"||t.data?.errorName==="ResolverNotContract"||t.data?.errorName==="ResolverNotFound"||t.data?.errorName==="ReverseAddressMismatch"||t.data?.errorName==="UnsupportedResolverProfile")};let n=e.r(91633),i=e.r(720794)},406121,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.encodedLabelToLabelhash=function(e){if(66!==e.length||0!==e.indexOf("[")||65!==e.indexOf("]"))return null;let t=`0x${e.slice(1,65)}`;return(0,n.isHex)(t)?t:null};let n=e.r(528137)},940702,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.namehash=function(e){let t=new Uint8Array(32).fill(0);if(!e)return(0,a.bytesToHex)(t);let r=e.split(".");for(let e=r.length-1;e>=0;e-=1){let a=(0,s.encodedLabelToLabelhash)(r[e]),c=a?(0,i.toBytes)(a):(0,o.keccak256)((0,i.stringToBytes)(r[e]),"bytes");t=(0,o.keccak256)((0,n.concat)([t,c]),"bytes")}return(0,a.bytesToHex)(t)};let n=e.r(985269),i=e.r(935603),a=e.r(850815),o=e.r(585457),s=e.r(406121)},995761,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.encodeLabelhash=function(e){return`[${e.slice(2)}]`}},53713,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.labelhash=function(e){let t=new Uint8Array(32).fill(0);return e?(0,o.encodedLabelToLabelhash)(e)||(0,a.keccak256)((0,n.stringToBytes)(e)):(0,i.bytesToHex)(t)};let n=e.r(935603),i=e.r(850815),a=e.r(585457),o=e.r(406121)},458837,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.packetToBytes=function(e){let t=e.replace(/^\.|\.$/gm,"");if(0===t.length)return new Uint8Array(1);let r=new Uint8Array((0,n.stringToBytes)(t).byteLength+2),o=0,s=t.split(".");for(let e=0;e<s.length;e++){let t=(0,n.stringToBytes)(s[e]);t.byteLength>255&&(t=(0,n.stringToBytes)((0,i.encodeLabelhash)((0,a.labelhash)(s[e])))),r[o]=t.length,r.set(t,o+1),o+=t.length+1}return r.byteLength!==o+1?r.slice(0,o+1):r};let n=e.r(935603),i=e.r(995761),a=e.r(53713)},93164,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getEnsAddress=m;let n=e.r(277779),i=e.r(320101),a=e.r(804943),o=e.r(370049),s=e.r(492678),c=e.r(850815),u=e.r(866540),l=e.r(639701),d=e.r(940702),f=e.r(458837),p=e.r(388012),h=e.r(465300);async function m(e,t){let{blockNumber:r,blockTag:m,coinType:b,name:y,gatewayUrls:g,strict:v}=t,{chain:w}=e,E=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!w)throw Error("client chain not configured. universalResolverAddress is required.");return(0,o.getChainContractAddress)({blockNumber:r,chain:w,contract:"ensUniversalResolver"})})(),P=w?.ensTlds;if(P&&!P.some(e=>y.endsWith(e)))return null;let x=null!=b?[(0,d.namehash)(y),BigInt(b)]:[(0,d.namehash)(y)];try{let t=(0,a.encodeFunctionData)({abi:n.addressResolverAbi,functionName:"addr",args:x}),o={address:E,abi:n.universalResolverResolveAbi,functionName:"resolveWithGateways",args:[(0,c.toHex)((0,f.packetToBytes)(y)),t,g??[l.localBatchGatewayUrl]],blockNumber:r,blockTag:m},u=(0,p.getAction)(e,h.readContract,"readContract"),d=await u(o);if("0x"===d[0])return null;let b=(0,i.decodeFunctionResult)({abi:n.addressResolverAbi,args:x,functionName:"addr",data:d[0]});if("0x"===b||"0x00"===(0,s.trim)(b))return null;return b}catch(e){if(v)throw e;if((0,u.isNullUniversalResolverError)(e))return null;throw e}}},914102,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.EnsInvalidChainIdError=r.EnsAvatarUnsupportedNamespaceError=r.EnsAvatarUriResolutionError=r.EnsAvatarInvalidNftUriError=r.EnsAvatarInvalidMetadataError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({data:e}){super("Unable to extract image from metadata. The metadata may be malformed or invalid.",{metaMessages:["- Metadata must be a JSON object with at least an `image`, `image_url` or `image_data` property.","",`Provided data: ${JSON.stringify(e)}`],name:"EnsAvatarInvalidMetadataError"})}}r.EnsAvatarInvalidMetadataError=i;class a extends n.BaseError{constructor({reason:e}){super(`ENS NFT avatar URI is invalid. ${e}`,{name:"EnsAvatarInvalidNftUriError"})}}r.EnsAvatarInvalidNftUriError=a;class o extends n.BaseError{constructor({uri:e}){super(`Unable to resolve ENS avatar URI "${e}". The URI may be malformed, invalid, or does not respond with a valid image.`,{name:"EnsAvatarUriResolutionError"})}}r.EnsAvatarUriResolutionError=o;class s extends n.BaseError{constructor({namespace:e}){super(`ENS NFT avatar namespace "${e}" is not supported. Must be "erc721" or "erc1155".`,{name:"EnsAvatarUnsupportedNamespaceError"})}}r.EnsAvatarUnsupportedNamespaceError=s;class c extends n.BaseError{constructor({chainId:e}){super(`Invalid ENSIP-11 chainId: ${e}. Must be between 0 and 0x7fffffff, or 1.`,{name:"EnsInvalidChainIdError"})}}r.EnsInvalidChainIdError=c},512300,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.isImageUri=u,r.getGateway=l,r.resolveAvatarUri=d,r.getJsonImage=f,r.getMetadataAvatarUri=p,r.parseAvatarUri=h,r.parseNftUri=function(e){let t=e;t.startsWith("did:nft:")&&(t=t.replace("did:nft:","").replace(/_/g,"/"));let[r,n,a]=t.split("/"),[o,s]=r.split(":"),[c,u]=n.split(":");if(!o||"eip155"!==o.toLowerCase())throw new i.EnsAvatarInvalidNftUriError({reason:"Only EIP-155 supported"});if(!s)throw new i.EnsAvatarInvalidNftUriError({reason:"Chain ID not found"});if(!u)throw new i.EnsAvatarInvalidNftUriError({reason:"Contract address not found"});if(!a)throw new i.EnsAvatarInvalidNftUriError({reason:"Token ID not found"});if(!c)throw new i.EnsAvatarInvalidNftUriError({reason:"ERC namespace not found"});return{chainID:Number.parseInt(s,10),namespace:c.toLowerCase(),contractAddress:u,tokenID:a}},r.getNftTokenUri=m;let n=e.r(465300),i=e.r(914102),a=/(?<protocol>https?:\/\/[^/]*|ipfs:\/|ipns:\/|ar:\/)?(?<root>\/)?(?<subpath>ipfs\/|ipns\/)?(?<target>[\w\-.]+)(?<subtarget>\/.*)?/,o=/^(Qm[1-9A-HJ-NP-Za-km-z]{44,}|b[A-Za-z2-7]{58,}|B[A-Z2-7]{58,}|z[1-9A-HJ-NP-Za-km-z]{48,}|F[0-9A-F]{50,})(\/(?<target>[\w\-.]+))?(?<subtarget>\/.*)?$/,s=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,c=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function u(e){try{let t=await fetch(e,{method:"HEAD"});if(200===t.status){let e=t.headers.get("content-type");return e?.startsWith("image/")}return!1}catch(t){if("object"==typeof t&&void 0!==t.response||!Object.hasOwn(globalThis,"Image"))return!1;return new Promise(t=>{let r=new Image;r.onload=()=>{t(!0)},r.onerror=()=>{t(!1)},r.src=e})}}function l(e,t){return e?e.endsWith("/")?e.slice(0,-1):e:t}function d(e){let{uri:t,gatewayUrls:r}=e,n=s.test(t);if(n)return{uri:t,isOnChain:!0,isEncoded:n};let u=l(r?.ipfs,"https://ipfs.io"),d=l(r?.arweave,"https://arweave.net"),f=t.match(a),{protocol:p,subpath:h,target:m,subtarget:b=""}=f?.groups||{},y="ipns:/"===p||"ipns/"===h,g="ipfs:/"===p||"ipfs/"===h||o.test(t);if(t.startsWith("http")&&!y&&!g){let e=t;return r?.arweave&&(e=t.replace(/https:\/\/arweave.net/g,r?.arweave)),{uri:e,isOnChain:!1,isEncoded:!1}}if((y||g)&&m)return{uri:`${u}/${y?"ipns":"ipfs"}/${m}${b}`,isOnChain:!1,isEncoded:!1};if("ar:/"===p&&m)return{uri:`${d}/${m}${b||""}`,isOnChain:!1,isEncoded:!1};let v=t.replace(c,"");if(v.startsWith("<svg")&&(v=`data:image/svg+xml;base64,${btoa(v)}`),v.startsWith("data:")||v.startsWith("{"))return{uri:v,isOnChain:!0,isEncoded:!1};throw new i.EnsAvatarUriResolutionError({uri:t})}function f(e){if("object"!=typeof e||!("image"in e)&&!("image_url"in e)&&!("image_data"in e))throw new i.EnsAvatarInvalidMetadataError({data:e});return e.image||e.image_url||e.image_data}async function p(e){let{gatewayUrls:t,uri:r}=e;try{let e=await fetch(r).then(e=>e.json());return await h({gatewayUrls:t,uri:f(e)})}catch{throw new i.EnsAvatarUriResolutionError({uri:r})}}async function h(e){let{gatewayUrls:t,uri:r}=e,{uri:n,isOnChain:a}=d({uri:r,gatewayUrls:t});if(a||await u(n))return n;throw new i.EnsAvatarUriResolutionError({uri:r})}async function m(e,t){let{nft:r}=t;if("erc721"===r.namespace)return(0,n.readContract)(e,{address:r.contractAddress,abi:[{name:"tokenURI",type:"function",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"tokenURI",args:[BigInt(r.tokenID)]});if("erc1155"===r.namespace)return(0,n.readContract)(e,{address:r.contractAddress,abi:[{name:"uri",type:"function",stateMutability:"view",inputs:[{name:"_id",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"uri",args:[BigInt(r.tokenID)]});throw new i.EnsAvatarUnsupportedNamespaceError({namespace:r.namespace})}},542777,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseAvatarRecord=i;let n=e.r(512300);async function i(e,t){let{gatewayUrls:r,record:i}=t;return/eip155:/i.test(i)?a(e,{gatewayUrls:r,record:i}):(0,n.parseAvatarUri)({uri:i,gatewayUrls:r})}async function a(e,t){let{gatewayUrls:r,record:i}=t,a=(0,n.parseNftUri)(i),o=await (0,n.getNftTokenUri)(e,{nft:a}),{uri:s,isOnChain:c,isEncoded:u}=(0,n.resolveAvatarUri)({uri:o,gatewayUrls:r});if(c&&(s.includes("data:application/json;base64,")||s.startsWith("{"))){let e=JSON.parse(u?atob(s.replace("data:application/json;base64,","")):s);return(0,n.parseAvatarUri)({uri:(0,n.getJsonImage)(e),gatewayUrls:r})}let l=a.tokenID;return"erc1155"===a.namespace&&(l=l.replace("0x","").padStart(64,"0")),(0,n.getMetadataAvatarUri)({gatewayUrls:r,uri:s.replace(/(?:0x)?{id}/,l)})}},582007,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.getEnsText=h;let n=e.r(277779),i=e.r(320101),a=e.r(804943),o=e.r(370049),s=e.r(850815),c=e.r(866540),u=e.r(639701),l=e.r(940702),d=e.r(458837),f=e.r(388012),p=e.r(465300);async function h(e,t){let{blockNumber:r,blockTag:h,key:m,name:b,gatewayUrls:y,strict:g}=t,{chain:v}=e,w=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!v)throw Error("client chain not configured. universalResolverAddress is required.");return(0,o.getChainContractAddress)({blockNumber:r,chain:v,contract:"ensUniversalResolver"})})(),E=v?.ensTlds;if(E&&!E.some(e=>b.endsWith(e)))return null;try{let t={address:w,abi:n.universalResolverResolveAbi,args:[(0,s.toHex)((0,d.packetToBytes)(b)),(0,a.encodeFunctionData)({abi:n.textResolverAbi,functionName:"text",args:[(0,l.namehash)(b),m]}),y??[u.localBatchGatewayUrl]],functionName:"resolveWithGateways",blockNumber:r,blockTag:h},o=(0,f.getAction)(e,p.readContract,"readContract"),c=await o(t);if("0x"===c[0])return null;let g=(0,i.decodeFunctionResult)({abi:n.textResolverAbi,functionName:"text",data:c[0]});return""===g?null:g}catch(e){if(g)throw e;if((0,c.isNullUniversalResolverError)(e))return null;throw e}}},294686,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getEnsAvatar=o;let n=e.r(542777),i=e.r(388012),a=e.r(582007);async function o(e,t){let{blockNumber:r,blockTag:o,assetGatewayUrls:s,name:c,gatewayUrls:u,strict:l,universalResolverAddress:d}=t,f=await (0,i.getAction)(e,a.getEnsText,"getEnsText")({blockNumber:r,blockTag:o,key:"avatar",name:c,universalResolverAddress:d,gatewayUrls:u,strict:l});if(!f)return null;try{return await (0,n.parseAvatarRecord)(e,{record:f,gatewayUrls:s})}catch{return null}}},508311,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getEnsName=u;let n=e.r(277779),i=e.r(370049),a=e.r(866540),o=e.r(639701),s=e.r(388012),c=e.r(465300);async function u(e,t){let{address:r,blockNumber:u,blockTag:l,coinType:d=60n,gatewayUrls:f,strict:p}=t,{chain:h}=e,m=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!h)throw Error("client chain not configured. universalResolverAddress is required.");return(0,i.getChainContractAddress)({blockNumber:u,chain:h,contract:"ensUniversalResolver"})})();try{let t={address:m,abi:n.universalResolverReverseAbi,args:[r,d,f??[o.localBatchGatewayUrl]],functionName:"reverseWithGateways",blockNumber:u,blockTag:l},i=(0,s.getAction)(e,c.readContract,"readContract"),[a]=await i(t);return a||null}catch(e){if(p)throw e;if((0,a.isNullUniversalResolverError)(e))return null;throw e}}},678355,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getEnsResolver=c;let n=e.r(370049),i=e.r(850815),a=e.r(458837),o=e.r(388012),s=e.r(465300);async function c(e,t){let{blockNumber:r,blockTag:c,name:u}=t,{chain:l}=e,d=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!l)throw Error("client chain not configured. universalResolverAddress is required.");return(0,n.getChainContractAddress)({blockNumber:r,chain:l,contract:"ensUniversalResolver"})})(),f=l?.ensTlds;if(f&&!f.some(e=>u.endsWith(e)))throw Error(`${u} is not a valid ENS TLD (${f?.join(", ")}) for chain "${l.name}" (id: ${l.id}).`);let[p]=await (0,o.getAction)(e,s.readContract,"readContract")({address:d,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"},{type:"uint256"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[(0,i.toHex)((0,a.packetToBytes)(u))],blockNumber:r,blockTag:c});return p}},490546,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createAccessList=u;let n=e.r(155401),i=e.r(850815),a=e.r(537665),o=e.r(106636),s=e.r(244319),c=e.r(854495);async function u(e,t){let{account:r=e.account,blockNumber:u,blockTag:l="latest",blobs:d,data:f,gas:p,gasPrice:h,maxFeePerBlobGas:m,maxFeePerGas:b,maxPriorityFeePerGas:y,to:g,value:v,...w}=t,E=r?(0,n.parseAccount)(r):void 0;try{(0,c.assertRequest)(t);let r="bigint"==typeof u?(0,i.numberToHex)(u):void 0,n=e.chain?.formatters?.transactionRequest?.format,a=(n||s.formatTransactionRequest)({...(0,o.extract)(w,{format:n}),account:E,blobs:d,data:f,gas:p,gasPrice:h,maxFeePerBlobGas:m,maxFeePerGas:b,maxPriorityFeePerGas:y,to:g,value:v},"createAccessList"),P=await e.request({method:"eth_createAccessList",params:[a,r||l]});return{accessList:P.accessList,gasUsed:BigInt(P.gasUsed)}}catch(r){throw(0,a.getCallError)(r,{...t,account:E,chain:e.chain})}}},157707,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.createBlockFilter=i;let n=e.r(19530);async function i(e){let t=(0,n.createFilterRequestScope)(e,{method:"eth_newBlockFilter"}),r=await e.request({method:"eth_newBlockFilter"});return{id:r,request:t(r),type:"block"}}},986756,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createEventFilter=o;let n=e.r(725159),i=e.r(850815),a=e.r(19530);async function o(e){let{address:t,args:r,event:o,events:s,fromBlock:c,strict:u,toBlock:l}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},d=s??(o?[o]:void 0),f=(0,a.createFilterRequestScope)(e,{method:"eth_newFilter"}),p=[];d&&(p=[d.flatMap(e=>(0,n.encodeEventTopics)({abi:[e],eventName:e.name,args:r}))],o&&(p=p[0]));let h=await e.request({method:"eth_newFilter",params:[{address:t,fromBlock:"bigint"==typeof c?(0,i.numberToHex)(c):c,toBlock:"bigint"==typeof l?(0,i.numberToHex)(l):l,...p.length?{topics:p}:{}}]});return{abi:d,args:r,eventName:o?o.name:void 0,fromBlock:c,id:h,request:f(h),strict:!!u,toBlock:l,type:"event"}}},902178,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createPendingTransactionFilter=i;let n=e.r(19530);async function i(e){let t=(0,n.createFilterRequestScope)(e,{method:"eth_newPendingTransactionFilter"}),r=await e.request({method:"eth_newPendingTransactionFilter"});return{id:r,request:t(r),type:"transaction"}}},888342,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getBalance=u;let n=e.r(277779),i=e.r(320101),a=e.r(804943),o=e.r(850815),s=e.r(388012),c=e.r(707041);async function u(e,t){let{address:r,blockNumber:u,blockTag:l=e.experimental_blockTag??"latest"}=t;if(e.batch?.multicall&&e.chain?.contracts?.multicall3){let t=e.chain.contracts.multicall3.address,o=(0,a.encodeFunctionData)({abi:n.multicall3Abi,functionName:"getEthBalance",args:[r]}),{data:d}=await (0,s.getAction)(e,c.call,"call")({to:t,data:o,blockNumber:u,blockTag:l});return(0,i.decodeFunctionResult)({abi:n.multicall3Abi,functionName:"getEthBalance",args:[r],data:d||"0x"})}let d="bigint"==typeof u?(0,o.numberToHex)(u):void 0;return BigInt(await e.request({method:"eth_getBalance",params:[r,d||l]}))}},99944,(e,t,r)=>{"use strict";async function n(e){return BigInt(await e.request({method:"eth_blobBaseFee"}))}Object.defineProperty(r,"__esModule",{value:!0}),r.getBlobBaseFee=n},862865,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getBlockTransactionCount=a;let n=e.r(723223),i=e.r(850815);async function a(e){let t,{blockHash:r,blockNumber:a,blockTag:o="latest"}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=void 0!==a?(0,i.numberToHex)(a):void 0;return t=r?await e.request({method:"eth_getBlockTransactionCountByHash",params:[r]},{dedupe:!0}):await e.request({method:"eth_getBlockTransactionCountByNumber",params:[s||o]},{dedupe:!!s}),(0,n.hexToNumber)(t)}},635437,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getCode=i;let n=e.r(850815);async function i(e,t){let{address:r,blockNumber:i,blockTag:a="latest"}=t,o=void 0!==i?(0,n.numberToHex)(i):void 0,s=await e.request({method:"eth_getCode",params:[r,o||a]},{dedupe:!!o});if("0x"!==s)return s}},384136,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getDelegation=s;let n=e.r(929544),i=e.r(484550),a=e.r(952195),o=e.r(635437);async function s(e,t){let{address:r,blockNumber:s,blockTag:c="latest"}=t,u=await (0,o.getCode)(e,{address:r,...void 0!==s?{blockNumber:s}:{blockTag:c}});if(u&&23===(0,i.size)(u)&&u.startsWith("0xef0100"))return(0,n.getAddress)((0,a.slice)(u,3,23))}},232561,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.Eip712DomainNotFoundError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({address:e}){super(`No EIP-712 domain found on contract "${e}".`,{metaMessages:["Ensure that:",`- The contract is deployed at the address "${e}".`,"- `eip712Domain()` function exists on the contract.","- `eip712Domain()` function matches signature to ERC-5267 specification."],name:"Eip712DomainNotFoundError"})}}r.Eip712DomainNotFoundError=i},685067,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.getEip712Domain=o;let n=e.r(232561),i=e.r(388012),a=e.r(465300);async function o(e,t){let{address:r,factory:o,factoryData:c}=t;try{let[t,n,u,l,d,f,p]=await (0,i.getAction)(e,a.readContract,"readContract")({abi:s,address:r,functionName:"eip712Domain",factory:o,factoryData:c});return{domain:{name:n,version:u,chainId:Number(l),verifyingContract:d,salt:f},extensions:p,fields:t}}catch(e){if("ContractFunctionExecutionError"===e.name&&"ContractFunctionZeroDataError"===e.cause.name)throw new n.Eip712DomainNotFoundError({address:r});throw e}}let s=[{inputs:[],name:"eip712Domain",outputs:[{name:"fields",type:"bytes1"},{name:"name",type:"string"},{name:"version",type:"string"},{name:"chainId",type:"uint256"},{name:"verifyingContract",type:"address"},{name:"salt",type:"bytes32"},{name:"extensions",type:"uint256[]"}],stateMutability:"view",type:"function"}]},831450,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatFeeHistory=function(e){return{baseFeePerGas:e.baseFeePerGas.map(e=>BigInt(e)),gasUsedRatio:e.gasUsedRatio,oldestBlock:BigInt(e.oldestBlock),reward:e.reward?.map(e=>e.map(e=>BigInt(e)))}}},255606,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getFeeHistory=a;let n=e.r(850815),i=e.r(831450);async function a(e,t){let{blockCount:r,blockNumber:a,blockTag:o="latest",rewardPercentiles:s}=t,c="bigint"==typeof a?(0,n.numberToHex)(a):void 0,u=await e.request({method:"eth_feeHistory",params:[(0,n.numberToHex)(r),c||o,s]},{dedupe:!!c});return(0,i.formatFeeHistory)(u)}},464404,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getFilterLogs=a;let n=e.r(685530),i=e.r(798336);async function a(e,t){let{filter:r}=t,a=r.strict??!1,o=(await r.request({method:"eth_getFilterLogs",params:[r.id]})).map(e=>(0,i.formatLog)(e));return r.abi?(0,n.parseEventLogs)({abi:r.abi,logs:o,strict:a}):o}},928659,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.encodePacked=function(e,t){if(e.length!==t.length)throw new n.AbiEncodingLengthMismatchError({expectedLength:e.length,givenLength:t.length});let r=[];for(let l=0;l<e.length;l++){let d=e[l],f=t[l];r.push(function e(t,r){let l=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("address"===t){if(!(0,a.isAddress)(r))throw new i.InvalidAddressError({address:r});return(0,s.pad)(r.toLowerCase(),{size:l?32:null})}if("string"===t)return(0,c.stringToHex)(r);if("bytes"===t)return r;if("bool"===t)return(0,s.pad)((0,c.boolToHex)(r),{size:l?32:1});let d=t.match(u.integerRegex);if(d){let[e,t,n="256"]=d,i=Number.parseInt(n,10)/8;return(0,c.numberToHex)(r,{size:l?32:i,signed:"int"===t})}let f=t.match(u.bytesRegex);if(f){let[e,t]=f;if(Number.parseInt(t,10)!==(r.length-2)/2)throw new n.BytesSizeMismatchError({expectedSize:Number.parseInt(t,10),givenSize:(r.length-2)/2});return(0,s.pad)(r,{dir:"right",size:l?32:null})}let p=t.match(u.arrayRegex);if(p&&Array.isArray(r)){let[t,n]=p,i=[];for(let t=0;t<r.length;t++)i.push(e(n,r[t],!0));return 0===i.length?"0x":(0,o.concatHex)(i)}throw new n.UnsupportedPackedAbiType(t)}(d,f))}return(0,o.concatHex)(r)};let n=e.r(963101),i=e.r(224276),a=e.r(429625),o=e.r(985269),s=e.r(356154),c=e.r(850815),u=e.r(142433)},361926,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isBytes=function(e){return!!e&&"object"==typeof e&&"BYTES_PER_ELEMENT"in e&&1===e.BYTES_PER_ELEMENT&&"Uint8Array"===e.constructor.name}},831047,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getContractAddress=function(e){return"CREATE2"===e.opcode?f(e):d(e)},r.getCreateAddress=d,r.getCreate2Address=f;let n=e.r(985269),i=e.r(361926),a=e.r(356154),o=e.r(952195),s=e.r(935603),c=e.r(178056),u=e.r(585457),l=e.r(929544);function d(e){let t=(0,s.toBytes)((0,l.getAddress)(e.from)),r=(0,s.toBytes)(e.nonce);return 0===r[0]&&(r=new Uint8Array([])),(0,l.getAddress)(`0x${(0,u.keccak256)((0,c.toRlp)([t,r],"bytes")).slice(26)}`)}function f(e){let t=(0,s.toBytes)((0,l.getAddress)(e.from)),r=(0,a.pad)((0,i.isBytes)(e.salt)?e.salt:(0,s.toBytes)(e.salt),{size:32}),c="bytecodeHash"in e?(0,i.isBytes)(e.bytecodeHash)?e.bytecodeHash:(0,s.toBytes)(e.bytecodeHash):(0,u.keccak256)(e.bytecode,"bytes");return(0,l.getAddress)((0,o.slice)((0,u.keccak256)((0,n.concat)([(0,s.toBytes)("0xff"),t,r,c])),12))}},165824,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.assertTransactionEIP7702=function(e){let{authorizationList:t}=e;if(t)for(let e of t){let{chainId:t}=e,r=e.address;if(!(0,l.isAddress)(r))throw new a.InvalidAddressError({address:r});if(t<0)throw new c.InvalidChainIdError({chainId:t})}h(e)},r.assertTransactionEIP4844=function(e){let{blobVersionedHashes:t}=e;if(t){if(0===t.length)throw new s.EmptyBlobError;for(let e of t){let t=(0,d.size)(e),r=(0,p.hexToNumber)((0,f.slice)(e,0,1));if(32!==t)throw new s.InvalidVersionedHashSizeError({hash:e,size:t});if(r!==n.versionedHashVersionKzg)throw new s.InvalidVersionedHashVersionError({hash:e,version:r})}}h(e)},r.assertTransactionEIP1559=h,r.assertTransactionEIP2930=function(e){let{chainId:t,maxPriorityFeePerGas:r,gasPrice:n,maxFeePerGas:s,to:d}=e;if(t<=0)throw new c.InvalidChainIdError({chainId:t});if(d&&!(0,l.isAddress)(d))throw new a.InvalidAddressError({address:d});if(r||s)throw new o.BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");if(n&&n>i.maxUint256)throw new u.FeeCapTooHighError({maxFeePerGas:n})},r.assertTransactionLegacy=function(e){let{chainId:t,maxPriorityFeePerGas:r,gasPrice:n,maxFeePerGas:s,to:d}=e;if(d&&!(0,l.isAddress)(d))throw new a.InvalidAddressError({address:d});if(void 0!==t&&t<=0)throw new c.InvalidChainIdError({chainId:t});if(r||s)throw new o.BaseError("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");if(n&&n>i.maxUint256)throw new u.FeeCapTooHighError({maxFeePerGas:n})};let n=e.r(487679),i=e.r(627009),a=e.r(224276),o=e.r(91633),s=e.r(23834),c=e.r(808894),u=e.r(659641),l=e.r(429625),d=e.r(484550),f=e.r(952195),p=e.r(723223);function h(e){let{chainId:t,maxPriorityFeePerGas:r,maxFeePerGas:n,to:o}=e;if(t<=0)throw new c.InvalidChainIdError({chainId:t});if(o&&!(0,l.isAddress)(o))throw new a.InvalidAddressError({address:o});if(n&&n>i.maxUint256)throw new u.FeeCapTooHighError({maxFeePerGas:n});if(r&&n&&r>n)throw new u.TipAboveFeeCapError({maxFeePerGas:n,maxPriorityFeePerGas:r})}},687715,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeAccessList=function(e){if(!e||0===e.length)return[];let t=[];for(let r=0;r<e.length;r++){let{address:o,storageKeys:s}=e[r];for(let e=0;e<s.length;e++)if(s[e].length-2!=64)throw new i.InvalidStorageKeySizeError({storageKey:s[e]});if(!(0,a.isAddress)(o,{strict:!1}))throw new n.InvalidAddressError({address:o});t.push([o,s])}return t};let n=e.r(224276),i=e.r(341289),a=e.r(429625)},567328,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeTransaction=function(e,t){let r=(0,h.getTransactionType)(e);return"eip1559"===r?function(e,t){let{chainId:r,gas:n,nonce:i,to:a,value:o,maxFeePerGas:s,maxPriorityFeePerGas:c,accessList:l,data:h}=e;(0,p.assertTransactionEIP1559)(e);let y=(0,m.serializeAccessList)(l),g=[(0,d.numberToHex)(r),i?(0,d.numberToHex)(i):"0x",c?(0,d.numberToHex)(c):"0x",s?(0,d.numberToHex)(s):"0x",n?(0,d.numberToHex)(n):"0x",a??"0x",o?(0,d.numberToHex)(o):"0x",h??"0x",y,...b(e,t)];return(0,u.concatHex)(["0x02",(0,f.toRlp)(g)])}(e,t):"eip2930"===r?function(e,t){let{chainId:r,gas:n,data:i,nonce:a,to:o,value:s,accessList:c,gasPrice:l}=e;(0,p.assertTransactionEIP2930)(e);let h=(0,m.serializeAccessList)(c),y=[(0,d.numberToHex)(r),a?(0,d.numberToHex)(a):"0x",l?(0,d.numberToHex)(l):"0x",n?(0,d.numberToHex)(n):"0x",o??"0x",s?(0,d.numberToHex)(s):"0x",i??"0x",h,...b(e,t)];return(0,u.concatHex)(["0x01",(0,f.toRlp)(y)])}(e,t):"eip4844"===r?function(e,t){let{chainId:r,gas:n,nonce:i,to:l,value:h,maxFeePerBlobGas:y,maxFeePerGas:g,maxPriorityFeePerGas:v,accessList:w,data:E}=e;(0,p.assertTransactionEIP4844)(e);let P=e.blobVersionedHashes,x=e.sidecars;if(e.blobs&&(void 0===P||void 0===x)){let t="string"==typeof e.blobs[0]?e.blobs:e.blobs.map(e=>(0,d.bytesToHex)(e)),r=e.kzg,n=(0,a.blobsToCommitments)({blobs:t,kzg:r});if(void 0===P&&(P=(0,s.commitmentsToVersionedHashes)({commitments:n})),void 0===x){let e=(0,o.blobsToProofs)({blobs:t,commitments:n,kzg:r});x=(0,c.toBlobSidecars)({blobs:t,commitments:n,proofs:e})}}let A=(0,m.serializeAccessList)(w),I=[(0,d.numberToHex)(r),i?(0,d.numberToHex)(i):"0x",v?(0,d.numberToHex)(v):"0x",g?(0,d.numberToHex)(g):"0x",n?(0,d.numberToHex)(n):"0x",l??"0x",h?(0,d.numberToHex)(h):"0x",E??"0x",A,y?(0,d.numberToHex)(y):"0x",P??[],...b(e,t)],T=[],S=[],C=[];if(x)for(let e=0;e<x.length;e++){let{blob:t,commitment:r,proof:n}=x[e];T.push(t),S.push(r),C.push(n)}return(0,u.concatHex)(["0x03",x?(0,f.toRlp)([I,T,S,C]):(0,f.toRlp)(I)])}(e,t):"eip7702"===r?function(e,t){let{authorizationList:r,chainId:n,gas:a,nonce:o,to:s,value:c,maxFeePerGas:l,maxPriorityFeePerGas:h,accessList:y,data:g}=e;(0,p.assertTransactionEIP7702)(e);let v=(0,m.serializeAccessList)(y),w=(0,i.serializeAuthorizationList)(r);return(0,u.concatHex)(["0x04",(0,f.toRlp)([(0,d.numberToHex)(n),o?(0,d.numberToHex)(o):"0x",h?(0,d.numberToHex)(h):"0x",l?(0,d.numberToHex)(l):"0x",a?(0,d.numberToHex)(a):"0x",s??"0x",c?(0,d.numberToHex)(c):"0x",g??"0x",v,w,...b(e,t)])])}(e,t):function(e,t){let{chainId:r=0,gas:i,data:a,nonce:o,to:s,value:c,gasPrice:u}=e;(0,p.assertTransactionLegacy)(e);let h=[o?(0,d.numberToHex)(o):"0x",u?(0,d.numberToHex)(u):"0x",i?(0,d.numberToHex)(i):"0x",s??"0x",c?(0,d.numberToHex)(c):"0x",a??"0x"];if(t){let e=(()=>
4{if(t.v>=35n)return(t.v-35n)/2n>0?t.v:27n+(35n===t.v?0n:1n);if(r>0)return BigInt(2*r)+BigInt(35n+t.v-27n);let e=27n+(27n===t.v?0n:1n);if(t.v!==e)throw new n.InvalidLegacyVError({v:t.v});return e})(),i=(0,l.trim)(t.r),a=(0,l.trim)(t.s);h=[...h,(0,d.numberToHex)(e),"0x00"===i?"0x":i,"0x00"===a?"0x":a]}else r>0&&(h=[...h,(0,d.numberToHex)(r),"0x","0x"]);return(0,f.toRlp)(h)}(e,t)},r.toYParitySignatureArray=b;let n=e.r(341289),i=e.r(344641),a=e.r(830588),o=e.r(764012),s=e.r(444604),c=e.r(458775),u=e.r(985269),l=e.r(492678),d=e.r(850815),f=e.r(178056),p=e.r(165824),h=e.r(446558),m=e.r(687715);function b(e,t){let r=t??e,{v:n,yParity:i}=r;if(void 0===r.r||void 0===r.s||void 0===n&&void 0===i)return[];let a=(0,l.trim)(r.r),o=(0,l.trim)(r.s);return["number"==typeof i?i?(0,d.numberToHex)(1):"0x":0n===n?"0x":1n===n?(0,d.numberToHex)(1):27n===n?"0x":(0,d.numberToHex)(1),"0x00"===a?"0x":a,"0x00"===o?"0x":o]}},344641,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeAuthorizationList=function(e){if(!e||0===e.length)return[];let t=[];for(let r of e){let{chainId:e,nonce:a,...o}=r,s=r.address;t.push([e?(0,n.toHex)(e):"0x",s,a?(0,n.toHex)(a):"0x",...(0,i.toYParitySignatureArray)({},o)])}return t};let n=e.r(850815),i=e.r(567328)},234696,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.verifyAuthorization=o;let n=e.r(929544),i=e.r(359389),a=e.r(271077);async function o(e){let{address:t,authorization:r,signature:o}=e;return(0,i.isAddressEqual)((0,n.getAddress)(t),await (0,a.recoverAuthorizationAddress)({authorization:r,signature:o}))}},947181,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.promiseCache=void 0,r.withDedupe=function(e,t){let{enabled:n=!0,id:i}=t;if(!n||!i)return e();if(r.promiseCache.get(i))return r.promiseCache.get(i);let a=e().finally(()=>r.promiseCache.delete(i));return r.promiseCache.set(i,a),a},r.promiseCache=new(e.r(170675)).LruMap(8192)},566498,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.buildRequest=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return async function(r){let d=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{dedupe:f=!1,methods:p,retryDelay:h=150,retryCount:m=3,uid:b}={...t,...d},{method:y}=r;if(p?.exclude?.includes(y)||p?.include&&!p.include.includes(y))throw new a.MethodNotSupportedRpcError(Error("method not supported"),{method:y});let g=f?(0,o.stringToHex)(`${b}.${(0,u.stringify)(r)}`):void 0;return(0,s.withDedupe)(()=>(0,c.withRetry)(async()=>{try{return await e(r)}catch(e){switch(e.code){case a.ParseRpcError.code:throw new a.ParseRpcError(e);case a.InvalidRequestRpcError.code:throw new a.InvalidRequestRpcError(e);case a.MethodNotFoundRpcError.code:throw new a.MethodNotFoundRpcError(e,{method:r.method});case a.InvalidParamsRpcError.code:throw new a.InvalidParamsRpcError(e);case a.InternalRpcError.code:throw new a.InternalRpcError(e);case a.InvalidInputRpcError.code:throw new a.InvalidInputRpcError(e);case a.ResourceNotFoundRpcError.code:throw new a.ResourceNotFoundRpcError(e);case a.ResourceUnavailableRpcError.code:throw new a.ResourceUnavailableRpcError(e);case a.TransactionRejectedRpcError.code:throw new a.TransactionRejectedRpcError(e);case a.MethodNotSupportedRpcError.code:throw new a.MethodNotSupportedRpcError(e,{method:r.method});case a.LimitExceededRpcError.code:throw new a.LimitExceededRpcError(e);case a.JsonRpcVersionUnsupportedError.code:throw new a.JsonRpcVersionUnsupportedError(e);case a.UserRejectedRequestError.code:throw new a.UserRejectedRequestError(e);case a.UnauthorizedProviderError.code:throw new a.UnauthorizedProviderError(e);case a.UnsupportedProviderMethodError.code:throw new a.UnsupportedProviderMethodError(e);case a.ProviderDisconnectedError.code:throw new a.ProviderDisconnectedError(e);case a.ChainDisconnectedError.code:throw new a.ChainDisconnectedError(e);case a.SwitchChainError.code:throw new a.SwitchChainError(e);case a.UnsupportedNonOptionalCapabilityError.code:throw new a.UnsupportedNonOptionalCapabilityError(e);case a.UnsupportedChainIdError.code:throw new a.UnsupportedChainIdError(e);case a.DuplicateIdError.code:throw new a.DuplicateIdError(e);case a.UnknownBundleIdError.code:throw new a.UnknownBundleIdError(e);case a.BundleTooLargeError.code:throw new a.BundleTooLargeError(e);case a.AtomicReadyWalletRejectedUpgradeError.code:throw new a.AtomicReadyWalletRejectedUpgradeError(e);case a.AtomicityNotSupportedError.code:throw new a.AtomicityNotSupportedError(e);case 5e3:throw new a.UserRejectedRequestError(e);case a.WalletConnectSessionSettlementError.code:throw new a.WalletConnectSessionSettlementError(e);default:if(e instanceof n.BaseError)throw e;throw new a.UnknownRpcError(e)}}},{delay:e=>{let{count:t,error:r}=e;if(r&&r instanceof i.HttpRequestError){let e=r?.headers?.get("Retry-After");if(e?.match(/\d/))return 1e3*Number.parseInt(e,10)}return~~(1<<t)*h},retryCount:m,shouldRetry:e=>{let{error:t}=e;return l(t)}}),{enabled:f,id:g})}},r.shouldRetry=l;let n=e.r(91633),i=e.r(666442),a=e.r(477323),o=e.r(850815),s=e.r(947181),c=e.r(607327),u=e.r(905241);function l(e){return"code"in e&&"number"==typeof e.code?-1===e.code||e.code===a.LimitExceededRpcError.code||e.code===a.InternalRpcError.code:!(e instanceof i.HttpRequestError)||!e.status||403===e.status||408===e.status||413===e.status||429===e.status||500===e.status||502===e.status||503===e.status||504===e.status||!1}},528112,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.defineChain=function(e){let t={formatters:void 0,fees:void 0,serializers:void 0,...e};return Object.assign(t,{extend:function e(t){return r=>{let n="function"==typeof r?r(t):r,i={...t,...n};return Object.assign(i,{extend:e(i)})}}(t)})},r.extendSchema=function(){return{}}},407245,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.extractChain=function(e){let{chains:t,id:r}=e;return t.find(e=>e.id===r)}},975038,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.fromRlp=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"hex",r=(()=>{if("string"==typeof e){if(e.length>3&&e.length%2!=0)throw new i.InvalidHexValueError(e);return(0,o.hexToBytes)(e)}return e})();return function e(t){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"hex";if(0===t.bytes.length)return"hex"===r?(0,s.bytesToHex)(t.bytes):t.bytes;let n=t.readByte();if(n<128&&t.decrementPosition(1),n<192){let e=c(t,n,128),i=t.readBytes(e);return"hex"===r?(0,s.bytesToHex)(i):i}let i=c(t,n,192);var a=t,o=i,u=r;let l=a.position,d=[];for(;a.position-l<o;)d.push(e(a,u));return d}((0,a.createCursor)(r,{recursiveReadLimit:1/0}),t)};let n=e.r(91633),i=e.r(131296),a=e.r(925294),o=e.r(935603),s=e.r(850815);function c(e,t,r){if(128===r&&t<128)return 1;if(t<=r+55)return t-r;if(t===r+55+1)return e.readUint8();if(t===r+55+2)return e.readUint16();if(t===r+55+3)return e.readUint24();if(t===r+55+4)return e.readUint32();throw new n.BaseError("Invalid RLP prefix")}},418690,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isHash=function(e){return(0,n.isHex)(e)&&32===(0,i.size)(e)};let n=e.r(528137),i=e.r(484550)},388012,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getAction=function(e,t,r){let n=e[t.name];if("function"==typeof n)return n;let i=e[r];return"function"==typeof i?i:r=>t(e,r)}},199807,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatAbiItem=function(e){let{includeName:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("function"!==e.type&&"event"!==e.type&&"error"!==e.type)throw new n.InvalidDefinitionTypeError(e.type);return`${e.name}(${i(e.inputs,{includeName:t})})`},r.formatAbiParams=i;let n=e.r(963101);function i(e){let{includeName:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e?e.map(e=>(function(e,t){let{includeName:r}=t;return e.type.startsWith("tuple")?`(${i(e.components,{includeName:r})})${e.type.slice(5)}`:e.type+(r&&e.name?` ${e.name}`:"")})(e,{includeName:t})).join(t?", ":","):""}},528137,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isHex=function(e){let{strict:t=!0}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return!!e&&"string"==typeof e&&(t?/^0x[0-9a-fA-F]*$/.test(e):e.startsWith("0x"))}},484550,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.size=function(e){return(0,n.isHex)(e,{strict:!1})?Math.ceil((e.length-2)/2):e.length};let n=e.r(528137)},310971,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.version=void 0,r.version="2.47.10"},91633,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.BaseError=void 0,r.setErrorConfig=function(e){i=e};let n=e.r(310971),i={getDocsUrl:e=>{let{docsBaseUrl:t,docsPath:r="",docsSlug:n}=e;return r?`${t??"https://viem.sh"}${r}${n?`#${n}`:""}`:void 0},version:`viem@${n.version}`};r.BaseError=class e extends Error{constructor(t,r={}){const a=r.cause instanceof e?r.cause.details:r.cause?.message?r.cause.message:r.details,o=r.cause instanceof e&&r.cause.docsPath||r.docsPath,s=i.getDocsUrl?.({...r,docsPath:o});super([t||"An error occurred.","",...r.metaMessages?[...r.metaMessages,""]:[],...s?[`Docs: ${s}`]:[],...a?[`Details: ${a}`]:[],...i.version?[`Version: ${i.version}`]:[]].join("\n"),r.cause?{cause:r.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.details=a,this.docsPath=o,this.metaMessages=r.metaMessages,this.name=r.name??this.name,this.shortMessage=t,this.version=n.version}walk(e){return function e(t,r){return r?.(t)?t:t&&"object"==typeof t&&"cause"in t&&void 0!==t.cause?e(t.cause,r):r?null:t}(this,e)}}},963101,(e,t,r)=>{"use strict";
4Object.defineProperty(r,"__esModule",{value:!0}),r.UnsupportedPackedAbiType=r.InvalidDefinitionTypeError=r.InvalidArrayError=r.InvalidAbiDecodingTypeError=r.InvalidAbiEncodingTypeError=r.DecodeLogTopicsMismatch=r.DecodeLogDataMismatch=r.BytesSizeMismatchError=r.AbiItemAmbiguityError=r.AbiFunctionSignatureNotFoundError=r.AbiFunctionOutputsNotFoundError=r.AbiFunctionNotFoundError=r.AbiEventNotFoundError=r.AbiEventSignatureNotFoundError=r.AbiEventSignatureEmptyTopicsError=r.AbiErrorSignatureNotFoundError=r.AbiErrorNotFoundError=r.AbiErrorInputsNotFoundError=r.AbiEncodingLengthMismatchError=r.AbiEncodingBytesSizeMismatchError=r.AbiEncodingArrayLengthMismatchError=r.AbiDecodingZeroDataError=r.AbiDecodingDataSizeTooSmallError=r.AbiDecodingDataSizeInvalidError=r.AbiConstructorParamsNotFoundError=r.AbiConstructorNotFoundError=void 0;let n=e.r(199807),i=e.r(484550),a=e.r(91633);class o extends a.BaseError{constructor({docsPath:e}){super("A constructor was not found on the ABI.\nMake sure you are using the correct ABI and that the constructor exists on it.",{docsPath:e,name:"AbiConstructorNotFoundError"})}}r.AbiConstructorNotFoundError=o;class s extends a.BaseError{constructor({docsPath:e}){super("Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.\nMake sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists.",{docsPath:e,name:"AbiConstructorParamsNotFoundError"})}}r.AbiConstructorParamsNotFoundError=s;class c extends a.BaseError{constructor({data:e,size:t}){super(`Data size of ${t}
4 bytes is invalid.
5Size must be in increments of 32 bytes (size % 32 === 0).`,{metaMessages:[`Data: ${e} (${t} bytes)`],name:"AbiDecodingDataSizeInvalidError"})}}r.AbiDecodingDataSizeInvalidError=c;class u extends a.BaseError{constructor({data:e,params:t,size:r}){super(`Data size of ${r} bytes is too small for given parameters.`,{metaMessages:[`Params: (${(0,n.formatAbiParams)(t,{includeName:!0})})`,`Data:   ${e} (${r} bytes)`],name:"AbiDecodingDataSizeTooSmallError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=e,this.params=t,this.size=r}}r.AbiDecodingDataSizeTooSmallError=u;class l extends a.BaseError{constructor({cause:e}={}){super('Cannot decode zero data ("0x") with ABI parameters.',{name:"AbiDecodingZeroDataError",cause:e})}}r.AbiDecodingZeroDataError=l;class d extends a.BaseError{constructor({expectedLength:e,givenLength:t,type:r}){super(`ABI encoding array length mismatch for type ${r}.
6Expected length: ${e}
7Given length: ${t}`,{name:"AbiEncodingArrayLengthMismatchError"})}}r.AbiEncodingArrayLengthMismatchError=d;class f extends a.BaseError{constructor({expectedSize:e,value:t}){super(`Size of bytes "${t}" (bytes${(0,i.size)(t)}) does not match expected size (bytes${e}).`,{name:"AbiEncodingBytesSizeMismatchError"})}}r.AbiEncodingBytesSizeMismatchError=f;class p extends a.BaseError{constructor({expectedLength:e,givenLength:t}){super(`ABI encoding params/values length mismatch.
8Expected length (params): ${e}
9Given length (values): ${t}`,{name:"AbiEncodingLengthMismatchError"})}}r.AbiEncodingLengthMismatchError=p;class h extends a.BaseError{constructor(e,{docsPath:t}){super(`Arguments (\`args\`) were provided to "${e}", but "${e}" on the ABI does not contain any parameters (\`inputs\`).
10Cannot encode error result without knowing what the parameter types are.
11Make sure you are using the correct ABI and that the inputs exist on it.`,{docsPath:t,name:"AbiErrorInputsNotFoundError"})}}r.AbiErrorInputsNotFoundError=h;class m extends a.BaseError{constructor(e,{docsPath:t}={}){super(`Error ${e?`"${e}" `:""}not found on ABI.
12Make sure you are using the correct ABI and that the error exists on it.`,{docsPath:t,name:"AbiErrorNotFoundError"})}}r.AbiErrorNotFoundError=m;class b extends a.BaseError{constructor(e,{docsPath:t,cause:r}){super(`Encoded error signature "${e}" not found on ABI.
13Make sure you are using the correct ABI and that the error exists on it.
14You can look up the decoded signature here: https://4byte.sourcify.dev/?q=${e}.`,{docsPath:t,name:"AbiErrorSignatureNotFoundError",cause:r}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.signature=e}}r.AbiErrorSignatureNotFoundError=b;class y extends a.BaseError{constructor({docsPath:e}){super("Cannot extract event signature from empty topics.",{docsPath:e,name:"AbiEventSignatureEmptyTopicsError"})}}r.AbiEventSignatureEmptyTopicsError=y;class g extends a.BaseError{constructor(e,{docsPath:t}){super(`Encoded event signature "${e}" not found on ABI.
15Make sure you are using the correct ABI and that the event exists on it.
16You can look up the signature here: https://4byte.sourcify.dev/?q=${e}.`,{docsPath:t,name:"AbiEventSignatureNotFoundError"})}}r.AbiEventSignatureNotFoundError=g;class v extends a.BaseError{constructor(e,{docsPath:t}={}){super(`Event ${e?`"${e}" `:""}not found on ABI.
17Make sure you are using the correct ABI and that the event exists on it.`,{docsPath:t,name:"AbiEventNotFoundError"})}}r.AbiEventNotFoundError=v;class w extends a.BaseError{constructor(e,{docsPath:t}={}){super(`Function ${e?`"${e}" `:""}not found on ABI.
18Make sure you are using the correct ABI and that the function exists on it.`,{docsPath:t,name:"AbiFunctionNotFoundError"})}}r.AbiFunctionNotFoundError=w;class E extends a.BaseError{constructor(e,{docsPath:t}){super(`Function "${e}" does not contain any \`outputs\` on ABI.
19Cannot decode function result without knowing what the parameter types are.
20Make sure you are using the correct ABI and that the function exists on it.`,{docsPath:t,name:"AbiFunctionOutputsNotFoundError"})}}r.AbiFunctionOutputsNotFoundError=E;class P extends a.BaseError{constructor(e,{docsPath:t}){super(`Encoded function signature "${e}" not found on ABI.
21Make sure you are using the correct ABI and that the function exists on it.
22You can look up the signature here: https://4byte.sourcify.dev/?q=${e}.`,{docsPath:t,name:"AbiFunctionSignatureNotFoundError"})}}r.AbiFunctionSignatureNotFoundError=P;class x extends a.BaseError{constructor(e,t){super("Found ambiguous types in overloaded ABI items.",{metaMessages:[`\`${e.type}
22\` in \`${(0,n.formatAbiItem)(e.abiItem)}\`, and`,`\`${t.type}\` in \`${(0,n.formatAbiItem)(t.abiItem)}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."],name:"AbiItemAmbiguityError"})}}r.AbiItemAmbiguityError=x;class A extends a.BaseError{constructor({expectedSize:e,givenSize:t}){super(`Expected bytes${e}, got bytes${t}.`,{name:"BytesSizeMismatchError"})}}r.BytesSizeMismatchError=A;class I extends a.BaseError{constructor({abiItem:e,data:t,params:r,size:i}){super(`Data size of ${i} bytes is too small for non-indexed event parameters.`,{metaMessages:[`Params: (${(0,n.formatAbiParams)(r,{includeName:!0})})`,`Data:   ${t} (${i} bytes)`],name:"DecodeLogDataMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=e,this.data=t,this.params=r,this.size=i}}r.DecodeLogDataMismatch=I;class T extends a.BaseError{constructor({abiItem:e,param:t}){super(`Expected a topic for indexed event parameter${t.name?` "${t.name}"`:""} on event "${(0,n.formatAbiItem)(e,{includeName:!0})}".`,{name:"DecodeLogTopicsMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=e}}r.DecodeLogTopicsMismatch=T;class S extends a.BaseError{constructor(e,{docsPath:t}){super(`Type "${e}" is not a valid encoding type.
23Please provide a valid ABI type.`,{docsPath:t,name:"InvalidAbiEncodingType"})}}r.InvalidAbiEncodingTypeError=S;class C extends a.BaseError{constructor(e,{docsPath:t}){super(`Type "${e}" is not a valid decoding type.
24Please provide a valid ABI type.`,{docsPath:t,name:"InvalidAbiDecodingType"})}}r.InvalidAbiDecodingTypeError=C;class O extends a.BaseError{constructor(e){super(`Value "${e}" is not a valid array.`,{name:"InvalidArrayError"})}}r.InvalidArrayError=O;class j extends a.BaseError{constructor(e){super(`"${e}" is not a valid definition type.
25Valid types: "function", "event", "error"`,{name:"InvalidDefinitionTypeError"})}}r.InvalidDefinitionTypeError=j;class k extends a.BaseError{constructor(e){super(`Type "${e}" is not supported for packed encoding.`,{name:"UnsupportedPackedAbiType"})}}r.UnsupportedPackedAbiType=k},92662,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.FilterTypeNotSupportedError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor(e){super(`Filter type "${e}" is not supported.`,{name:"FilterTypeNotSupportedError"})}}r.FilterTypeNotSupportedError=i},544609,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidBytesLengthError=r.SizeExceedsPaddingSizeError=r.SliceOffsetOutOfBoundsError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({offset:e,position:t,size:r}){super(`Slice ${"start"===t?"starting":"ending"} at offset "${e}" is out-of-bounds (size: ${r}).`,{name:"SliceOffsetOutOfBoundsError"})}}r.SliceOffsetOutOfBoundsError=i;class a extends n.BaseError{constructor({size:e,targetSize:t,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (${e}) exceeds padding size (${t}).`,{name:"SizeExceedsPaddingSizeError"})}}r.SizeExceedsPaddingSizeError=a;class o extends n.BaseError{constructor({size:e,targetSize:t,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} is expected to be ${t} ${r} long, but is ${e} ${r} long.`,{name:"InvalidBytesLengthError"})}}r.InvalidBytesLengthError=o},356154,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.pad=function(e){let{dir:t,size:r=32}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof e?i(e,{dir:t,size:r}):a(e,{dir:t,size:r})},r.padHex=i,r.padBytes=a;let n=e.r(544609);function i(e){let{dir:t,size:r=32}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null===r)return e;let i=e.replace("0x","");if(i.length>2*r)throw new n.SizeExceedsPaddingSizeError({size:Math.ceil(i.length/2),targetSize:r,type:"hex"});return`0x${i["right"===t?"padEnd":"padStart"](2*r,"0")}`}function a(e){let{dir:t,size:r=32}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null===r)return e;if(e.length>r)throw new n.SizeExceedsPaddingSizeError({size:e.length,targetSize:r,type:"bytes"});let i=new Uint8Array(r);for(let n=0;n<r;n++){let a="right"===t;i[a?n:r-n-1]=e[a?n:e.length-n-1]}return i}},131296,(e,t,r)=>{"use strict";
25Object.defineProperty(r,"__esModule",{value:!0}),r.SizeOverflowError=r.InvalidHexValueError=r.InvalidHexBooleanError=r.InvalidBytesBooleanError=r.IntegerOutOfRangeError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({max:e,min:t,signed:r,size:n,value:i}){super(`Number "${i}" is not in safe ${n?`${8*n}-bit ${r?"signed":"unsigned"} `:""}integer range ${e?`(${t} to ${e})`:`(above ${t})`}`,{name:"IntegerOutOfRangeError"})}}r.IntegerOutOfRangeError=i;class a extends n.BaseError{constructor(e){super(`Bytes value "${e}" is not a valid boolean. The bytes array must contain a single byte of either a 0 or 1 value.`,{name:"InvalidBytesBooleanError"})}}r.InvalidBytesBooleanError=a;class o extends n.BaseError{constructor(e){super(`Hex value "${e}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`,{name:"InvalidHexBooleanError"})}}r.InvalidHexBooleanError=o;class s extends n.BaseError{constructor(e){super(`Hex value "${e}" is an odd length (${e.length}). It must be an even length.`,{name:"InvalidHexValueError"})}}r.InvalidHexValueError=s;class c extends n.BaseError{constructor({givenSize:e,maxSize:t}){super(`Size cannot exceed ${t} bytes. Given size: ${e} bytes.`,{name:"SizeOverflowError"})}}r.SizeOverflowError=c},492678,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.trim=function(e){let{dir:t="left"}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r="string"==typeof e?e.replace("0x",""):e,n=0;for(let e=0;e<r.length-1;e++)if("0"===r["left"===t?e:r.length-e-1].toString())n++;else break;return(r="left"===t?r.slice(n):r.slice(0,r.length-n),"string"==typeof e)?(1===r.length&&"right"===t&&(r=`${r}0`),`0x${r.length%2==1?`0${r}`:r}`):r}},723223,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.assertSize=s,r.fromHex=function(e,t){let r="string"==typeof t?{to:t}:t,n=r.to;
25return"number"===n?l(e,r):"bigint"===n?c(e,r):"string"===n?d(e,r):"boolean"===n?u(e,r):(0,o.hexToBytes)(e,r)},r.hexToBigInt=c,r.hexToBool=u,r.hexToNumber=l,r.hexToString=d;let n=e.r(131296),i=e.r(484550),a=e.r(492678),o=e.r(935603);function s(e,t){let{size:r}=t;if((0,i.size)(e)>r)throw new n.SizeOverflowError({givenSize:(0,i.size)(e),maxSize:r})}function c(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{signed:r}=t;t.size&&s(e,{size:t.size});let n=BigInt(e);if(!r)return n;let i=(e.length-2)/2;return n<=(1n<<8n*BigInt(i)-1n)-1n?n:n-BigInt(`0x${"f".padStart(2*i,"f")}`)-1n}function u(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e;if(t.size&&(s(r,{size:t.size}),r=(0,a.trim)(r)),"0x00"===(0,a.trim)(r))return!1;if("0x01"===(0,a.trim)(r))return!0;throw new n.InvalidHexBooleanError(r)}function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=c(e,t),i=Number(r);if(!Number.isSafeInteger(i))throw new n.IntegerOutOfRangeError({max:`${Number.MAX_SAFE_INTEGER}`,min:`${Number.MIN_SAFE_INTEGER}`,signed:t.signed,size:t.size,value:`${r}n`});return i}function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=(0,o.hexToBytes)(e);return t.size&&(s(r,{size:t.size}),r=(0,a.trim)(r,{dir:"right"})),new TextDecoder().decode(r)}},850815,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toHex=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"number"==typeof e||"bigint"==typeof e?u(e,t):"string"==typeof e?d(e,t):"boolean"==typeof e?s(e,t):c(e,t)},r.boolToHex=s,r.bytesToHex=c,r.numberToHex=u,r.stringToHex=d;let n=e.r(131296),i=e.r(356154),a=e.r(723223),o=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function s(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=`0x${Number(e)}`;return"number"==typeof t.size?((0,a.assertSize)(r,{size:t.size}),(0,i.pad)(r,{size:t.size})):r}function c(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r="";for(let t=0;t<e.length;t++)r+=o[e[t]];let n=`0x${r}`;return"number"==typeof t.size?((0,a.assertSize)(n,{size:t.size}),(0,i.pad)(n,{dir:"right",size:t.size})):n}function u(e){let t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{signed:a,size:o}=r,s=BigInt(e);o?t=a?(1n<<8n*BigInt(o)-1n)-1n:2n**(8n*BigInt(o))-1n:"number"==typeof e&&(t=BigInt(Number.MAX_SAFE_INTEGER));let c="bigint"==typeof t&&a?-t-1n:0;if(t&&s>t||s<c){let r="bigint"==typeof e?"n":"";throw new n.IntegerOutOfRangeError({max:t?`${t}${r}`:void 0,min:`${c}${r}`,signed:a,size:o,value:`${e}${r}`})}let u=`0x${(a&&s<0?(1n<<BigInt(8*o))+BigInt(s):s).toString(16)}`;return o?(0,i.pad)(u,{size:o}):u}let l=new TextEncoder;function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return c(l.encode(e),t)}},935603,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toBytes=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"number"==typeof e||"bigint"==typeof e?f(e,t):"boolean"==typeof e?u(e,t):(0,i.isHex)(e)?d(e,t):p(e,t)},r.boolToBytes=u,r.hexToBytes=d,r.numberToBytes=f,r.stringToBytes=p;let n=e.r(91633),i=e.r(528137),a=e.r(356154),o=e.r(723223),s=e.r(850815),c=new TextEncoder;function u(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=new Uint8Array(1);return(r[0]=Number(e),"number"==typeof t.size)?((0,o.assertSize)(r,{size:t.size}),(0,a.pad)(r,{size:t.size})):r}function l(e){return e>=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:void 0}function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e;t.size&&((0,o.assertSize)(r,{size:t.size}),r=(0,a.pad)(r,{dir:"right",size:t.size}));let i=r.slice(2);i.length%2&&(i=`0${i}`);let s=i.length/2,c=new Uint8Array(s);for(let e=0,t=0;e<s;e++){let r=l(i.charCodeAt(t++)),a=l(i.charCodeAt(t++));if(void 0===r||void 0===a)throw new n.BaseError(`Invalid byte sequence ("${i[t-2]}${i[t-1]}" in "${i}").`);c[e]=16*r+a}return c}function f(e,t){return d((0,s.numberToHex)(e,t))}function p(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=c.encode(e);return"number"==typeof t.size?((0,o.assertSize)(r,{size:t.size}),(0,a.pad)(r,{dir:"right",size:t.size})):r}},585457,(e,t,r)=>{"use strict";
25Object.defineProperty(r,"__esModule",{value:!0}),r.keccak256=function(e,t){let r=(0,n.keccak_256)((0,i.isHex)(e,{strict:!1})?(0,a.toBytes)(e):e);return"bytes"===(t||"hex")?r:(0,o.toHex)(r)};let n=e.r(206492),i=e.r(528137),a=e.r(935603),o=e.r(850815)},914043,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.hashSignature=function(e){return(0,i.keccak256)((0,n.toBytes)(e))};let n=e.r(935603),i=e.r(585457)},641174,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.normalizeSignature=function(e){let t=!0,r="",i=0,a="",o=!1;for(let n=0;n<e.length;n++){let s=e[n];if(["(",")",","].includes(s)&&(t=!0),"("===s&&i++,")"===s&&i--,t){if(0===i){if(" "===s&&["event","function",""].includes(a))a="";else if(a+=s,")"===s){o=!0;break}continue}if(" "===s){","!==e[n-1]&&","!==r&&",("!==r&&(r="",t=!1);continue}a+=s,r+=s}}if(!o)throw new n.BaseError("Unable to normalize signature.");return a};let n=e.r(91633)},512185,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toSignature=void 0;let n=e.r(668691),i=e.r(641174);r.toSignature=e=>{let t="string"==typeof e?e:(0,n.formatAbiItem)(e);return(0,i.normalizeSignature)(t)}},736787,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toSignatureHash=function(e){return(0,n.hashSignature)((0,i.toSignature)(e))};let n=e.r(914043),i=e.r(512185)},138355,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toEventSelector=void 0,r.toEventSelector=e.r(736787).toSignatureHash},224276,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidAddressError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({address:e}){super(`Address "${e}" is invalid.`,{metaMessages:["- Address must be a hex value of 20 bytes (40 hex characters).","- Address must match its checksum counterpart."],name:"InvalidAddressError"})}}r.InvalidAddressError=i},170675,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.LruMap=void 0;class n extends Map{constructor(e){super(),Object.defineProperty(this,"maxSize",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.maxSize=e}get(e){let t=super.get(e);return super.has(e)&&(super.delete(e),super.set(e,t)),t}set(e,t){if(super.has(e)&&super.delete(e),super.set(e,t),this.maxSize&&this.size>this.maxSize){let e=super.keys().next().value;void 0!==e&&super.delete(e)}return this}}r.LruMap=n},929544,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.checksumAddress=u,r.getAddress=function(e,t){if(!(0,s.isAddress)(e,{strict:!1}))throw new n.InvalidAddressError({address:e});return u(e,t)};let n=e.r(224276),i=e.r(935603),a=e.r(585457),o=e.r(170675),s=e.r(429625),c=new o.LruMap(8192);function u(e,t){if(c.has(`${e}.${t}`))return c.get(`${e}.${t}`);let r=t?`${t}${e.toLowerCase()}`:e.substring(2).toLowerCase(),n=(0,a.keccak256)((0,i.stringToBytes)(r),"bytes"),o=(t?r.substring(`${t}0x`.length):r).split("");for(let e=0;e<40;e+=2)n[e>>1]>>4>=8&&o[e]&&(o[e]=o[e].toUpperCase()),(15&n[e>>1])>=8&&o[e+1]&&(o[e+1]=o[e+1].toUpperCase());let s=`0x${o.join("")}`;return c.set(`${e}.${t}`,s),s}},429625,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isAddressCache=void 0,r.isAddress=function(e,t){let{strict:n=!0}=t??{},o=`${e}.${n}`;if(r.isAddressCache.has(o))return r.isAddressCache.get(o);let s=!!a.test(e)&&(e.toLowerCase()===e||!n||(0,i.checksumAddress)(e)===e);return r.isAddressCache.set(o,s),s};let n=e.r(170675),i=e.r(929544),a=/^0x[a-fA-F0-9]{40}$/;r.isAddressCache=new n.LruMap(8192)},985269,(e,t,r)=>{"use strict";function n(e){let t=0;for(let r of e)t+=r.length;let r=new Uint8Array(t),n=0;for(let t of e)r.set(t,n),n+=t.length;return r}function i(e){return`0x${e.reduce((e,t)=>e+t.replace("0x",""),"")}`}Object.defineProperty(r,"__esModule",{value:!0}),r.concat=function(e){return"string"==typeof e[0]?i(e):n(e)},r.concatBytes=n,r.concatHex=i},952195,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.slice=function(e,t,r){let{strict:n}=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return(0,i.isHex)(e,{strict:!1})?u(e,t,r,{strict:n}):c(e,t,r,{strict:n})},r.sliceBytes=c,r.sliceHex=u;
25let n=e.r(544609),i=e.r(528137),a=e.r(484550);function o(e,t){if("number"==typeof t&&t>0&&t>(0,a.size)(e)-1)throw new n.SliceOffsetOutOfBoundsError({offset:t,position:"start",size:(0,a.size)(e)})}function s(e,t,r){if("number"==typeof t&&"number"==typeof r&&(0,a.size)(e)!==r-t)throw new n.SliceOffsetOutOfBoundsError({offset:r,position:"end",size:(0,a.size)(e)})}function c(e,t,r){let{strict:n}=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};o(e,t);let i=e.slice(t,r);return n&&s(i,t,r),i}function u(e,t,r){let{strict:n}=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};o(e,t);let i=`0x${e.replace("0x","").slice((t??0)*2,(r??e.length)*2)}`;return n&&s(i,t,r),i}},142433,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.integerRegex=r.bytesRegex=r.arrayRegex=void 0,r.arrayRegex=/^(.*)\[([0-9]*)\]$/,r.bytesRegex=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,r.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)?$/},440747,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.encodeAbiParameters=function(e,t){if(e.length!==t.length)throw new n.AbiEncodingLengthMismatchError({expectedLength:e.length,givenLength:t.length});let r=h(function(e){let{params:t,values:r}=e,b=[];for(let e=0;e<t.length;e++)b.push(function e(t){let{param:r,value:b}=t,y=m(r.type);if(y){let[t,i]=y;return function(t,r){let{length:i,param:a}=r,o=null===i;if(!Array.isArray(t))throw new n.InvalidArrayError(t);if(!o&&t.length!==i)throw new n.AbiEncodingArrayLengthMismatchError({expectedLength:i,givenLength:t.length,type:`${a.type}[${i}]`});let s=!1,u=[];for(let r=0;r<t.length;r++){let n=e({param:a,value:t[r]});n.dynamic&&(s=!0),u.push(n)}if(o||s){let e=h(u);if(o){let t=(0,f.numberToHex)(u.length,{size:32});return{dynamic:!0,encoded:u.length>0?(0,c.concat)([t,e]):t}}if(s)return{dynamic:!0,encoded:e}}return{dynamic:!1,encoded:(0,c.concat)(u.map(e=>{let{encoded:t}=e;return t}))}}(b,{length:t,param:{...r,type:i}})}if("tuple"===r.type)return function(t,r){let{param:n}=r,i=!1,a=[];for(let r=0;r<n.components.length;r++){let o=n.components[r],s=Array.isArray(t)?r:o.name,c=e({param:o,value:t[s]});a.push(c),c.dynamic&&(i=!0)}return{dynamic:i,encoded:i?h(a):(0,c.concat)(a.map(e=>{let{encoded:t}=e;return t}))}}(b,{param:r});if("address"===r.type){var g=b;if(!(0,s.isAddress)(g))throw new i.InvalidAddressError({address:g});return{dynamic:!1,encoded:(0,u.padHex)(g.toLowerCase())}}if("bool"===r.type){var v=b;if("boolean"!=typeof v)throw new a.BaseError(`Invalid boolean value: "${v}" (type: ${typeof v}). Expected: \`true\` or \`false\`.`);return{dynamic:!1,encoded:(0,u.padHex)((0,f.boolToHex)(v))}}if(r.type.startsWith("uint")||r.type.startsWith("int")){let e=r.type.startsWith("int"),[,,t="256"]=p.integerRegex.exec(r.type)??[];return function(e,t){let{signed:r,size:n=256}=t;if("number"==typeof n){let t=2n**(BigInt(n)-(r?1n:0n))-1n,i=r?-t-1n:0n;if(e>t||e<i)throw new o.IntegerOutOfRangeError({max:t.toString(),min:i.toString(),signed:r,size:n/8,value:e.toString()})}return{dynamic:!1,encoded:(0,f.numberToHex)(e,{size:32,signed:r})}}(b,{signed:e,size:Number(t)})}if(r.type.startsWith("bytes"))return function(e,t){let{param:r}=t,[,i]=r.type.split("bytes"),a=(0,l.size)(e);if(!i){let t=e;return a%32!=0&&(t=(0,u.padHex)(t,{dir:"right",size:32*Math.ceil((e.length-2)/2/32)})),{dynamic:!0,encoded:(0,c.concat)([(0,u.padHex)((0,f.numberToHex)(a,{size:32})),t])}}if(a!==Number.parseInt(i,10))throw new n.AbiEncodingBytesSizeMismatchError({expectedSize:Number.parseInt(i,10),value:e});return{dynamic:!1,encoded:(0,u.padHex)(e,{dir:"right"})}}(b,{param:r});if("string"===r.type){var w=b;let e=(0,f.stringToHex)(w),t=Math.ceil((0,l.size)(e)/32),r=[];for(let n=0;n<t;n++)r.push((0,u.padHex)((0,d.slice)(e,32*n,(n+1)*32),{dir:"right"}));return{dynamic:!0,encoded:(0,c.concat)([(0,u.padHex)((0,f.numberToHex)((0,l.size)(e),{size:32})),...r])}}throw new n.InvalidAbiEncodingTypeError(r.type,{docsPath:"/docs/contract/encodeAbiParameters"})}({param:t[e],value:r[e]}));return b}({params:e,values:t}));return 0===r.length?"0x":r},r.getArrayComponents=m;let n=e.r(963101),i=e.r(224276),a=e.r(91633),o=e.r(131296),s=e.r(429625),c=e.r(985269),u=e.r(356154),l=e.r(4845
2550),d=e.r(952195),f=e.r(850815),p=e.r(142433);function h(e){let t=0;for(let r=0;r<e.length;r++){let{dynamic:n,encoded:i}=e[r];n?t+=32:t+=(0,l.size)(i)}let r=[],n=[],i=0;for(let a=0;a<e.length;a++){let{dynamic:o,encoded:s}=e[a];o?(r.push((0,f.numberToHex)(t+i,{size:32})),n.push(s),i+=(0,l.size)(s)):r.push(s)}return(0,c.concat)([...r,...n])}function m(e){let t=e.match(/^(.*)\[(\d+)?\]$/);return t?[t[2]?Number(t[2]):null,t[1]]:void 0}},832768,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toFunctionSelector=void 0;let n=e.r(952195),i=e.r(736787);r.toFunctionSelector=e=>(0,n.slice)((0,i.toSignatureHash)(e),0,4)},409872,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getAbiItem=function(e){let t,{abi:r,args:a=[],name:l}=e,d=(0,i.isHex)(l,{strict:!1}),f=r.filter(e=>d?"function"===e.type?(0,s.toFunctionSelector)(e)===l:"event"===e.type&&(0,o.toEventSelector)(e)===l:"name"in e&&e.name===l);if(0!==f.length){if(1===f.length)return f[0];for(let e of f){if("inputs"in e){if(!a||0===a.length){if(!e.inputs||0===e.inputs.length)return e;continue}if(e.inputs&&0!==e.inputs.length&&e.inputs.length===a.length&&a.every((t,r)=>{let n="inputs"in e&&e.inputs[r];return!!n&&c(t,n)})){if(t&&"inputs"in t&&t.inputs){let r=u(e.inputs,t.inputs,a);if(r)throw new n.AbiItemAmbiguityError({abiItem:e,type:r[0]},{abiItem:t,type:r[1]})}t=e}}}return t||f[0]}},r.isArgOfType=c,r.getAmbiguousTypes=u;let n=e.r(963101),i=e.r(528137),a=e.r(429625),o=e.r(138355),s=e.r(832768);function c(e,t){let r=typeof e,n=t.type;switch(n){case"address":return(0,a.isAddress)(e,{strict:!1});case"bool":return"boolean"===r;case"function":case"string":return"string"===r;default:if("tuple"===n&&"components"in t)return Object.values(t.components).every((t,n)=>"object"===r&&c(Object.values(e)[n],t));if(/^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)?$/.test(n))return"number"===r||"bigint"===r;if(/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(n))return"string"===r||e instanceof Uint8Array;
25if(/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(n))return Array.isArray(e)&&e.every(e=>c(e,{...t,type:n.replace(/(\[[0-9]{0,}\])$/,"")}));return!1}}function u(e,t,r){for(let n in e){let i=e[n],o=t[n];if("tuple"===i.type&&"tuple"===o.type&&"components"in i&&"components"in o)return u(i.components,o.components,r[n]);let s=[i.type,o.type];if(s.includes("address")&&s.includes("bytes20")||(s.includes("address")&&s.includes("string")||s.includes("address")&&s.includes("bytes"))&&(0,a.isAddress)(r[n],{strict:!1}))return s}}},725159,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.encodeEventTopics=function(e){let{abi:t,eventName:r,args:i}=e,a=t[0];if(r){let e=(0,l.getAbiItem)({abi:t,name:r});if(!e)throw new n.AbiEventNotFoundError(r,{docsPath:d});a=e}if("event"!==a.type)throw new n.AbiEventNotFoundError(void 0,{docsPath:d});let o=(0,u.formatAbiItem)(a),c=(0,s.toEventSelector)(o),p=[];if(i&&"inputs"in a){let e=a.inputs?.filter(e=>"indexed"in e&&e.indexed),t=Array.isArray(i)?i:Object.values(i).length>0?e?.map(e=>i[e.name])??[]:[];t.length>0&&(p=e?.map((e,r)=>Array.isArray(t[r])?t[r].map((n,i)=>f({param:e,value:t[r][i]})):void 0!==t[r]&&null!==t[r]?f({param:e,value:t[r]}):null)??[])}return[c,...p]};let n=e.r(963101),i=e.r(92662),a=e.r(935603),o=e.r(585457),s=e.r(138355),c=e.r(440747),u=e.r(199807),l=e.r(409872),d="/docs/contract/encodeEventTopics";function f(e){let{param:t,value:r}=e;if("string"===t.type||"bytes"===t.type)return(0,o.keccak256)((0,a.toBytes)(r));if("tuple"===t.type||t.type.match(/^(.*)\[(\d+)?\]$/))throw new i.FilterTypeNotSupportedError(t.type);return(0,c.encodeAbiParameters)([t],[r])}},19530,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createFilterRequestScope=function(e,t){let{method:r}=t,n={};return"fallback"===e.transport.type&&e.transport.onResponse?.(e=>{let{method:t,response:i,status:a,transport:o}=e;"success"===a&&r===t&&(n[i]=o.request)}),t=>n[t]||e.request}},627977,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createContractEventFilter=o;let n=e.r(725159),i=e.r(850815),a=e.r(19530);async function o(e,t){let{address:r,abi:o,args:s,eventName:c,fromBlock:u,strict:l,toBlock:d}=t,f=(0,a.createFilterRequestScope)(e,{method:"eth_newFilter"}),p=c?(0,n.encodeEventTopics)({abi:o,args:s,eventName:c}):void 0,h=await e.request({method:"eth_newFilter",params:[{address:r,fromBlock:"bigint"==typeof u?(0,i.numberToHex)(u):u,toBlock:"bigint"==typeof d?(0,i.numberToHex)(d):d,topics:p}]});return{abi:o,args:s,eventName:c,id:h,request:f(h),strict:!!l,type:"event"}}},155401,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseAccount=function(e){return"string"==typeof e?{address:e,type:"json-rpc"}:e}},521681,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.prepareEncodeFunctionData=function(e){let{abi:t,args:r,functionName:c}=e,u=t[0];if(c){let e=(0,o.getAbiItem)({abi:t,args:r,name:c});if(!e)throw new n.AbiFunctionNotFoundError(c,{docsPath:s});u=e}if("function"!==u.type)throw new n.AbiFunctionNotFoundError(void 0,{docsPath:s});return{abi:[u],functionName:(0,i.toFunctionSelector)((0,a.formatAbiItem)(u))}};let n=e.r(963101),i=e.r(832768),a=e.r(199807),o=e.r(409872),s="/docs/contract/encodeFunctionData"},804943,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.encodeFunctionData=function(e){let{args:t}=e,{abi:r,functionName:o}=1===e.abi.length&&e.functionName?.startsWith("0x")?e:(0,a.prepareEncodeFunctionData)(e),s=r[0],c="inputs"in s&&s.inputs?(0,i.encodeAbiParameters)(s.inputs,t??[]):void 0;return(0,n.concatHex)([o,c??"0x"])};let n=e.r(985269),i=e.r(440747),a=e.r(521681)},17488,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.solidityPanic=r.solidityError=r.panicReasons=void 0,r.panicReasons={1:"An `assert` condition failed.",17:"Arithmetic operation resulted in underflow or overflow.",18:"Division or modulo by zero (e.g. `5 / 0` or `23 % 0`).",33:"Attempted to convert to an invalid type.",34:"Attempted to access a storage byte array that is incorrectly encoded.",49:"Performed `.pop()` on an empty array",50:"Array index is out of bounds.",65:"Allocated too much memory or created an array which is too large.",81:"Attempted to call a zero-initialized variable of internal function type."},r.solidityError={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},r.solidityPanic={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"}},613588,(e,t,r)=>{"use strict";
25Object.defineProperty(r,"__esModule",{value:!0}),r.RecursiveReadLimitExceededError=r.PositionOutOfBoundsError=r.NegativeOffsetError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({offset:e}){super(`Offset \`${e}\` cannot be negative.`,{name:"NegativeOffsetError"})}}r.NegativeOffsetError=i;class a extends n.BaseError{constructor({length:e,position:t}){super(`Position \`${t}\` is out of bounds (\`0 < position < ${e}\`).`,{name:"PositionOutOfBoundsError"})}}r.PositionOutOfBoundsError=a;class o extends n.BaseError{constructor({count:e,limit:t}){super(`Recursive read limit of \`${t}\` exceeded (recursive read count: \`${e}\`).`,{name:"RecursiveReadLimitExceededError"})}}r.RecursiveReadLimitExceededError=o},925294,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.createCursor=function(e){let{recursiveReadLimit:t=8192}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=Object.create(i);return r.bytes=e,r.dataView=new DataView(e.buffer??e,e.byteOffset,e.byteLength),r.positionReadCount=new Map,r.recursiveReadLimit=t,r};let n=e.r(613588),i={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,positionReadCount:new Map,recursiveReadCount:0,recursiveReadLimit:1/0,assertReadLimit(){if(this.recursiveReadCount>=this.recursiveReadLimit)throw new n.RecursiveReadLimitExceededError({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(e){if(e<0||e>this.bytes.length-1)throw new n.PositionOutOfBoundsError({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new n.NegativeOffsetError({offset:e});let t=this.position-e;this.assertPosition(t),this.position=t},getReadCount(e){return this.positionReadCount.get(e||this.position)||0},incrementPosition(e){if(e<0)throw new n.NegativeOffsetError({offset:e});let t=this.position+e;this.assertPosition(t),this.position=t},inspectByte(e){let t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectBytes(e,t){let r=t??this.position;return this.assertPosition(r+e-1),this.bytes.subarray(r,r+e)},inspectUint8(e){let t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectUint16(e){let t=e??this.position;return this.assertPosition(t+1),this.dataView.getUint16(t)},inspectUint24(e){let t=e??this.position;return this.assertPosition(t+2),(this.dataView.getUint16(t)<<8)+this.dataView.getUint8(t+2)},inspectUint32(e){let t=e??this.position;return this.assertPosition(t+3),this.dataView.getUint32(t)},pushByte(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushBytes(e){this.assertPosition(this.position+e.length-1),this.bytes.set(e,this.position),this.position+=e.length},pushUint8(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushUint16(e){this.assertPosition(this.position+1),this.dataView.setUint16(this.position,e),this.position+=2},pushUint24(e){this.assertPosition(this.position+2),this.dataView.setUint16(this.position,e>>8),this.dataView.setUint8(this.position+2,255&e),this.position+=3},pushUint32(e){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,e),this.position+=4},readByte(){this.assertReadLimit(),this._touch();let e=this.inspectByte();return this.position++,e},readBytes(e,t){this.assertReadLimit(),this._touch();let r=this.inspectBytes(e);return this.position+=t??e,r},readUint8(){this.assertReadLimit(),this._touch();let e=this.inspectUint8();return this.position+=1,e},readUint16(){this.assertReadLimit(),this._touch();let e=this.inspectUint16();return this.position+=2,e},readUint24(){this.assertReadLimit(),this._touch();let e=this.inspectUint24();return this.position+=3,e},readUint32(){this.assertReadLimit(),this._touch();let e=this.inspectUint32();return this.position+=4,e},get remaining(){return this.bytes.length-this.position},setPosition(e){let t=this.position;return this.assertPosition(e),this.position=e,()=>this.position=t},_touch(){if(this.recursiveReadLimit===1/0)return;let e=this.getReadCount();this.positionReadCount.set(this.position,e+1),e>0&&this.recursiveReadCount++}}},783052,(e,t,r)=>{"use strict";
25Object.defineProperty(r,"__esModule",{value:!0}),r.fromBytes=function(e,t){let r="string"==typeof t?{to:t}:t,n=r.to;return"number"===n?u(e,r):"bigint"===n?s(e,r):"boolean"===n?c(e,r):"string"===n?l(e,r):(0,o.bytesToHex)(e,r)},r.bytesToBigInt=s,r.bytesToBool=c,r.bytesToNumber=u,r.bytesToString=l;let n=e.r(131296),i=e.r(492678),a=e.r(723223),o=e.r(850815);function s(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};void 0!==t.size&&(0,a.assertSize)(e,{size:t.size});let r=(0,o.bytesToHex)(e,t);return(0,a.hexToBigInt)(r,t)}function c(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e;if(void 0!==t.size&&((0,a.assertSize)(r,{size:t.size}),r=(0,i.trim)(r)),r.length>1||r[0]>1)throw new n.InvalidBytesBooleanError(r);return!!r[0]}function u(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};void 0!==t.size&&(0,a.assertSize)(e,{size:t.size});let r=(0,o.bytesToHex)(e,t);return(0,a.hexToNumber)(r,t)}function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e;return void 0!==t.size&&((0,a.assertSize)(r,{size:t.size}),r=(0,i.trim)(r,{dir:"right"})),new TextDecoder().decode(r)}},239072,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeAbiParameters=function(e,t){let r="string"==typeof t?(0,l.hexToBytes)(t):t,h=(0,a.createCursor)(r);if(0===(0,o.size)(r)&&e.length>0)throw new n.AbiDecodingZeroDataError;if((0,o.size)(t)&&32>(0,o.size)(t))throw new n.AbiDecodingDataSizeTooSmallError({data:"string"==typeof t?t:(0,d.bytesToHex)(t),params:e,size:(0,o.size)(t)});let m=0,b=[];for(let t=0;t<e.length;++t){let r=e[t];h.setPosition(m);let[a,o]=function e(t,r,a){var o,l,h;let{staticPosition:m}=a,b=(0,f.getArrayComponents)(r.type);if(b){let[n,i]=b;return function(t,r,n){let{length:i,staticPosition:a}=n;if(!i){let n=a+(0,u.bytesToNumber)(t.readBytes(32)),i=n+32;t.setPosition(n);let o=(0,u.bytesToNumber)(t.readBytes(32)),s=p(r),c=0,l=[];for(let n=0;n<o;++n){t.setPosition(i+(s?32*n:c));let[a,o]=e(t,r,{staticPosition:i});c+=o,l.push(a)}return t.setPosition(a+32),[l,32]}if(p(r)){let n=a+(0,u.bytesToNumber)(t.readBytes(32)),o=[];for(let a=0;a<i;++a){t.setPosition(n+32*a);let[i]=e(t,r,{staticPosition:n});o.push(i)}return t.setPosition(a+32),[o,32]}let o=0,s=[];for(let n=0;n<i;++n){let[n,i]=e(t,r,{staticPosition:a+o});o+=i,s.push(n)}return[s,o]}(t,{...r,type:i},{length:n,staticPosition:m})}if("tuple"===r.type)return function(t,r,n){let{staticPosition:i}=n,a=0===r.components.length||r.components.some(e=>{let{name:t}=e;return!t}),o=a?[]:{},s=0;if(p(r)){let n=i+(0,u.bytesToNumber)(t.readBytes(32));for(let i=0;i<r.components.length;++i){let c=r.components[i];t.setPosition(n+s);let[u,l]=e(t,c,{staticPosition:n});s+=l,o[a?i:c?.name]=u}return t.setPosition(i+32),[o,32]}for(let n=0;n<r.components.length;++n){let c=r.components[n],[u,l]=e(t,c,{staticPosition:i});o[a?n:c?.name]=u,s+=l}return[o,s]}(t,r,{staticPosition:m});if("address"===r.type){let e;return e=t.readBytes(32),[(0,i.checksumAddress)((0,d.bytesToHex)((0,s.sliceBytes)(e,-20))),32]}if("bool"===r.type){return o=t,[(0,u.bytesToBool)(o.readBytes(32),{size:32}),32]}if(r.type.startsWith("bytes"))return function(e,t,r){let{staticPosition:n}=r,[i,a]=t.type.split("bytes");if(!a){let t=(0,u.bytesToNumber)(e.readBytes(32));e.setPosition(n+t);let r=(0,u.bytesToNumber)(e.readBytes(32));if(0===r)return e.setPosition(n+32),["0x",32];let i=e.readBytes(r);return e.setPosition(n+32),[(0,d.bytesToHex)(i),32]}return[(0,d.bytesToHex)(e.readBytes(Number.parseInt(a,10),32)),32]}(t,r,{staticPosition:m});if(r.type.startsWith("uint")||r.type.startsWith("int")){let e,n,i;return l=t,e=(h=r).type.startsWith("int"),n=Number.parseInt(h.type.split("int")[1]||"256",10),i=l.readBytes(32),[n>48?(0,u.bytesToBigInt)(i,{signed:e}):(0,u.bytesToNumber)(i,{signed:e}),32]}if("string"===r.type)return function(e,t){let{staticPosition:r}=t,n=(0,u.bytesToNumber)(e.readBytes(32));e.setPosition(r+n);let i=(0,u.bytesToNumber)(e.readBytes(32));if(0===i)return e.setPosition(r+32),["",32];let a=e.readBytes(i,32),o=(0,u.bytesToString)((0,c.trim)(a));return e.setPosition(r+32),[o,32]}(t,{staticPosition:m});throw new n.InvalidAbiDecodingTypeError(r.type,{docsPath:"/docs/contract/decodeAbiParameters"})}(h,r,{staticPosition:0});m+=o,b.push(a)}return b};
25let n=e.r(963101),i=e.r(929544),a=e.r(925294),o=e.r(484550),s=e.r(952195),c=e.r(492678),u=e.r(783052),l=e.r(935603),d=e.r(850815),f=e.r(440747);function p(e){let{type:t}=e;if("string"===t||"bytes"===t||t.endsWith("[]"))return!0;if("tuple"===t)return e.components?.some(p);let r=(0,f.getArrayComponents)(e.type);return!!(r&&p({...e,type:r[1]}))}},369165,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeErrorResult=function(e){let{abi:t,data:r,cause:u}=e,l=(0,a.slice)(r,0,4);if("0x"===l)throw new i.AbiDecodingZeroDataError({cause:u});let d=[...t||[],n.solidityError,n.solidityPanic].find(e=>"error"===e.type&&l===(0,o.toFunctionSelector)((0,c.formatAbiItem)(e)));if(!d)throw new i.AbiErrorSignatureNotFoundError(l,{docsPath:"/docs/contract/decodeErrorResult",cause:u});return{abiItem:d,args:"inputs"in d&&d.inputs&&d.inputs.length>0?(0,s.decodeAbiParameters)(d.inputs,(0,a.slice)(r,4)):void 0,errorName:d.name}};let n=e.r(17488),i=e.r(963101),a=e.r(952195),o=e.r(832768),s=e.r(239072),c=e.r(199807)},905241,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.stringify=void 0,r.stringify=(e,t,r)=>JSON.stringify(e,(e,r)=>{let n="bigint"==typeof r?r.toString():r;return"function"==typeof t?t(e,n):n},r)},121916,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatAbiItemWithArgs=function(e){let{abiItem:t,args:r,includeFunctionName:i=!0,includeName:a=!1}=e;if("name"in t&&"inputs"in t&&t.inputs)return`${i?t.name:""}(${t.inputs.map((e,t)=>`${a&&e.name?`${e.name}: `:""}${"object"==typeof r[t]?(0,n.stringify)(r[t]):r[t]}`).join(", ")})`};let n=e.r(905241)},883987,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.weiUnits=r.gweiUnits=r.etherUnits=void 0,r.etherUnits={gwei:9,wei:18},r.gweiUnits={ether:-9,wei:9},r.weiUnits={ether:-18,gwei:-9}},638809,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatUnits=function(e,t){let r=e.toString(),n=r.startsWith("-");n&&(r=r.slice(1));let[i,a]=[(r=r.padStart(t,"0")).slice(0,r.length-t),r.slice(r.length-t)];return a=a.replace(/(0+)$/,""),`${n?"-":""}${i||"0"}${a?`.${a}`:""}`}},65942,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatEther=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"wei";return(0,i.formatUnits)(e,n.etherUnits[t])};let n=e.r(883987),i=e.r(638809)},42506,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatGwei=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"wei";return(0,i.formatUnits)(e,n.gweiUnits[t])};let n=e.r(883987),i=e.r(638809)},779719,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.StateAssignmentConflictError=r.AccountStateConflictError=void 0,r.prettyStateMapping=o,r.prettyStateOverride=function(e){return e.reduce((e,t)=>{let{address:r,...n}=t,i=`${e}    ${r}:
26`;return n.nonce&&(i+=`      nonce: ${n.nonce}
27`),n.balance&&(i+=`      balance: ${n.balance}
28`),n.code&&(i+=`      code: ${n.code}
29`),n.state&&(i+="      state:\n",i+=o(n.state)),n.stateDiff&&(i+="      stateDiff:\n",i+=o(n.stateDiff)),i},"  State Override:\n").slice(0,-1)};let n=e.r(91633);class i extends n.BaseError{constructor({address:e}){super(`State for account "${e}" is set multiple times.`,{name:"AccountStateConflictError"})}}r.AccountStateConflictError=i;class a extends n.BaseError{constructor(){super("state and stateDiff are set on the same account.",{name:"StateAssignmentConflictError"})}}function o(e){return e.reduce((e,t)=>{let{slot:r,value:n}=t;return`${e}        ${r}: ${n}
30`},"")}r.StateAssignmentConflictError=a},341289,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.WaitForTransactionReceiptTimeoutError=r.TransactionReceiptRevertedError=r.TransactionReceiptNotFoundError=r.TransactionNotFoundError=r.TransactionExecutionError=r.InvalidStorageKeySizeError=r.InvalidSerializedTransactionError=r.InvalidSerializedTransactionTypeError=r.InvalidSerializableTransactionError=r.InvalidLegacyVError=r.FeeConflictError=void 0,r.prettyPrint=o;let n=e.r(65942),i=e.r(42506),a=e.r(91633);function o(e){let t=Object.entries(e).map(e=>{let[t,r]=e;return void 0===r||!1===r?null:[t,r]}
30).filter(Boolean),r=t.reduce((e,t)=>{let[r]=t;return Math.max(e,r.length)},0);return t.map(e=>{let[t,n]=e;return`  ${`${t}:`.padEnd(r+1)}  ${n}`}).join("\n")}class s extends a.BaseError{constructor(){super("Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.\nUse `maxFeePerGas`/`maxPriorityFeePerGas` for EIP-1559 compatible networks, and `gasPrice` for others.",{name:"FeeConflictError"})}}r.FeeConflictError=s;class c extends a.BaseError{constructor({v:e}){super(`Invalid \`v\` value "${e}". Expected 27 or 28.`,{name:"InvalidLegacyVError"})}}r.InvalidLegacyVError=c;class u extends a.BaseError{constructor({transaction:e}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",o(e),"}","","To infer the type, either provide:","- a `type` to the Transaction, or","- an EIP-1559 Transaction with `maxFeePerGas`, or","- an EIP-2930 Transaction with `gasPrice` & `accessList`, or","- an EIP-4844 Transaction with `blobs`, `blobVersionedHashes`, `sidecars`, or","- an EIP-7702 Transaction with `authorizationList`, or","- a Legacy Transaction with `gasPrice`"],name:"InvalidSerializableTransactionError"})}}r.InvalidSerializableTransactionError=u;class l extends a.BaseError{constructor({serializedType:e}){super(`Serialized transaction type "${e}" is invalid.`,{name:"InvalidSerializedTransactionType"}),Object.defineProperty(this,"serializedType",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.serializedType=e}}r.InvalidSerializedTransactionTypeError=l;class d extends a.BaseError{constructor({attributes:e,serializedTransaction:t,type:r}){const n=Object.entries(e).map(e=>{let[t,r]=e;return void 0===r?t:void 0}).filter(Boolean);super(`Invalid serialized transaction of type "${r}" was provided.`,{metaMessages:[`Serialized Transaction: "${t}"`,n.length>0?`Missing Attributes: ${n.join(", ")}`:""].filter(Boolean),name:"InvalidSerializedTransactionError"}),Object.defineProperty(this,"serializedTransaction",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"type",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.serializedTransaction=t,this.type=r}}r.InvalidSerializedTransactionError=d;class f extends a.BaseError{constructor({storageKey:e}){super(`Size for storage key "${e}" is invalid. Expected 32 bytes. Got ${Math.floor((e.length-2)/2)} bytes.`,{name:"InvalidStorageKeySizeError"})}}r.InvalidStorageKeySizeError=f;class p extends a.BaseError{constructor(e,{account:t,docsPath:r,chain:a,data:s,gas:c,gasPrice:u,maxFeePerGas:l,maxPriorityFeePerGas:d,nonce:f,to:p,value:h}){const m=o({chain:a&&`${a?.name} (id: ${a?.id})`,from:t?.address,to:p,value:void 0!==h&&`${(0,n.formatEther)(h)} ${a?.nativeCurrency?.symbol||"ETH"}`,data:s,gas:c,gasPrice:void 0!==u&&`${(0,i.formatGwei)(u)} gwei`,maxFeePerGas:void 0!==l&&`${(0,i.formatGwei)(l)} gwei`,maxPriorityFeePerGas:void 0!==d&&`${(0,i.formatGwei)(d)} gwei`,nonce:f});super(e.shortMessage,{cause:e,docsPath:r,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Request Arguments:",m].filter(Boolean),name:"TransactionExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=e}}r.TransactionExecutionError=p;class h extends a.BaseError{constructor({blockHash:e,blockNumber:t,blockTag:r,hash:n,index:i}){let a="Transaction";r&&void 0!==i&&(a=`Transaction at block time "${r}" at index "${i}"`),e&&void 0!==i&&(a=`Transaction at block hash "${e}" at index "${i}"`),t&&void 0!==i&&(a=`Transaction at block number "${t}" at index "${i}"`),n&&(a=`Transaction with hash "${n}"`),super(`${a} could not be found.`,{name:"TransactionNotFoundError"})}}r.TransactionNotFoundError=h;class m extends a.BaseError{constructor({hash:e}){super(`Transaction receipt with hash "${e}" could not be found. The Transaction may not be processed on a block yet.`,{name:"TransactionReceiptNotFoundError"})}}r.TransactionReceiptNotFoundError=m;class b extends a.BaseError{constructor({receipt:e}){super(`Transaction with hash "${e.transactionHash}" reverted.`,{metaMessages:['The receipt marked the transaction as "reverted". This could mean that the function on the contract you are trying to call threw an error.'," ","You can attempt to extract the revert reason by:","- calling the `simulateContract` or `simulateCalls` Action with the `abi` and `functionName` of the contract","- using the `call` Action with raw `data`"],name:"TransactionReceiptRevertedError"}),Object.defineProperty(this,"receipt",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.receipt=e}}r.TransactionReceiptRevertedError=b;class y extends a.BaseError{constructor({hash:e}){super(`Timed out while waiting for transaction with hash "${e}" to be confirmed.`,{name:"WaitForTransactionReceiptTimeoutError"})}}r.WaitForTransactionReceiptTimeoutError=y},420065,(e,t,r)=>{"use strict";
30Object.defineProperty(r,"__esModule",{value:!0}),r.getUrl=r.getContractAddress=void 0,r.getContractAddress=e=>e,r.getUrl=e=>e},720794,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.RawContractError=r.CounterfactualDeploymentFailedError=r.ContractFunctionZeroDataError=r.ContractFunctionRevertedError=r.ContractFunctionExecutionError=r.CallExecutionError=void 0;let n=e.r(155401),i=e.r(17488),a=e.r(369165),o=e.r(199807),s=e.r(121916),c=e.r(409872),u=e.r(65942),l=e.r(42506),d=e.r(963101),f=e.r(91633),p=e.r(779719),h=e.r(341289),m=e.r(420065);class b extends f.BaseError{constructor(e,{account:t,docsPath:r,chain:i,data:a,gas:o,gasPrice:s,maxFeePerGas:c,maxPriorityFeePerGas:d,nonce:f,to:m,value:b,stateOverride:y}){const g=t?(0,n.parseAccount)(t):void 0;let v=(0,h.prettyPrint)({from:g?.address,to:m,value:void 0!==b&&`${(0,u.formatEther)(b)} ${i?.nativeCurrency?.symbol||"ETH"}`,data:a,gas:o,gasPrice:void 0!==s&&`${(0,l.formatGwei)(s)} gwei`,maxFeePerGas:void 0!==c&&`${(0,l.formatGwei)(c)} gwei`,maxPriorityFeePerGas:void 0!==d&&`${(0,l.formatGwei)(d)} gwei`,nonce:f});y&&(v+=`
31${(0,p.prettyStateOverride)(y)}`),super(e.shortMessage,{cause:e,docsPath:r,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Raw Call Arguments:",v].filter(
31Boolean),name:"CallExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=e}}r.CallExecutionError=b;class y extends f.BaseError{constructor(e,{abi:t,args:r,contractAddress:n,docsPath:i,functionName:a,sender:u}){const l=(0,c.getAbiItem)({abi:t,args:r,name:a}),d=l?(0,s.formatAbiItemWithArgs)({abiItem:l,args:r,includeFunctionName:!1,includeName:!1}):void 0,f=l?(0,o.formatAbiItem)(l,{includeName:!0}):void 0,p=(0,h.prettyPrint)({address:n&&(0,m.getContractAddress)(n),function:f,args:d&&"()"!==d&&`${[...Array(a?.length??0).keys()].map(()=>" ").join("")}${d}`,sender:u});super(e.shortMessage||`An unknown error occurred while executing the contract function "${a}".`,{cause:e,docsPath:i,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],p&&"Contract Call:",p].filter(Boolean),name:"ContractFunctionExecutionError"}),Object.defineProperty(this,"abi",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"args",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"contractAddress",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"formattedArgs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"functionName",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sender",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abi=t,this.args=r,this.cause=e,this.contractAddress=n,this.functionName=a,this.sender=u}}r.ContractFunctionExecutionError=y;class g extends f.BaseError{constructor({abi:e,data:t,functionName:r,message:n,cause:c}){let u,l,f,p,h;if(t&&"0x"!==t)try{const{abiItem:r,errorName:n,args:u}=l=(0,a.decodeErrorResult)({abi:e,data:t,cause:c});if("Error"===n)p=u[0];else if("Panic"===n){const[e]=u;p=i.panicReasons[e]}else{const e=r?(0,o.formatAbiItem)(r,{includeName:!0}):void 0,t=r&&u?(0,s.formatAbiItemWithArgs)({abiItem:r,args:u,includeFunctionName:!1,includeName:!1}):void 0;f=[e?`Error: ${e}`:"",t&&"()"!==t?`       ${[...Array(n?.length??0).keys()].map(()=>" ").join("")}${t}`:""]}}catch(e){u=e}else n&&(p=n);u instanceof d.AbiErrorSignatureNotFoundError&&(h=u.signature,f=[`Unable to decode signature "${h}" as it was not found on the provided ABI.`,"Make sure you are using the correct ABI and that the error exists on it.",`You can look up the decoded signature here: https://4byte.sourcify.dev/?q=${h}.`]),super(p&&"execution reverted"!==p||h?[`The contract function "${r}" reverted with the following ${h?"signature":"reason"}:`,p||h].join("\n"):`The contract function "${r}" reverted.`,{cause:u??c,metaMessages:f,name:"ContractFunctionRevertedError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"raw",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"reason",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=l,this.raw=t,this.reason=p,this.signature=h}}r.ContractFunctionRevertedError=g;class v extends f.BaseError{constructor({functionName:e,cause:t}){super(`The contract function "${e}" returned no data ("0x").`,{metaMessages:["This could be due to any of the following:",`  - The contract does not have the function "${e}",`,"  - The parameters passed to the contract function may be invalid, or","  - The address is not a contract."],name:"ContractFunctionZeroDataError",cause:t})}}r.ContractFunctionZeroDataError=v;class w extends f.BaseError{constructor({factory:e}){super(`Deployment for counterfactual contract call failed${e?` for factory "${e}".`:""}`,{metaMessages:["Please ensure:","- The `factory` is a valid contract deployment factory (ie. Create2 Factory, ERC-4337 Factory, etc).","- The `factoryData` is a valid encoded function call for contract deployment function on the factory."],name:"CounterfactualDeploymentFailedError"})}}r.CounterfactualDeploymentFailedError=w;class E extends f.BaseError{constructor({data:e,message:t}){super(t||"",{name:"RawContractError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=e}}r.RawContractError=E},666442,(e,t,r)=>{"use strict";
31Object.defineProperty(r,"__esModule",{value:!0}),r.TimeoutError=r.SocketClosedError=r.RpcRequestError=r.WebSocketRequestError=r.HttpRequestError=void 0;let n=e.r(905241),i=e.r(91633),a=e.r(420065);class o extends i.BaseError{constructor({body:e,cause:t,details:r,headers:i,status:o,url:s}){super("HTTP request failed.",{cause:t,details:r,metaMessages:[o&&`Status: ${o}`,`URL: ${(0,a.getUrl)(s)}`,e&&`Request body: ${(0,n.stringify)(e)}`].filter(Boolean),name:"HttpRequestError"}),Object.defineProperty(this,"body",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"headers",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"status",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.body=e,this.headers=i,this.status=o,this.url=s}}r.HttpRequestError=o;class s extends i.BaseError{constructor({body:e,cause:t,details:r,url:i}){super("WebSocket request failed.",{cause:t,details:r,metaMessages:[`URL: ${(0,a.getUrl)(i)}`,e&&`Request body: ${(0,n.stringify)(e)}`].filter(Boolean),name:"WebSocketRequestError"}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.url=i}}r.WebSocketRequestError=s;class c extends i.BaseError{constructor({body:e,error:t,url:r}){super("RPC Request failed.",{cause:t,details:t.message,metaMessages:[`URL: ${(0,a.getUrl)(r)}`,`Request body: ${(0,n.stringify)(e)}`],name:"RpcRequestError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.code=t.code,this.data=t.data,this.url=r}}r.RpcRequestError=c;class u extends i.BaseError{constructor({url:e}={}){super("The socket has been closed.",{metaMessages:[e&&`URL: ${(0,a.getUrl)(e)}`].filter(Boolean),name:"SocketClosedError"}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.url=e}}r.SocketClosedError=u;class l extends i.BaseError{constructor({body:e,url:t}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${(0,a.getUrl)(t)}`,`Request body: ${(0,n.stringify)(e)}`],name:"TimeoutError"}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.url=t}}r.TimeoutError=l},477323,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.UnknownRpcError=r.WalletConnectSessionSettlementError=r.AtomicityNotSupportedError=r.AtomicReadyWalletRejectedUpgradeError=r.BundleTooLargeError=r.UnknownBundleIdError=r.DuplicateIdError=r.UnsupportedChainIdError=r.UnsupportedNonOptionalCapabilityError=r.SwitchChainError=r.ChainDisconnectedError=r.ProviderDisconnectedError=r.UnsupportedProviderMethodError=r.UnauthorizedProviderError=r.UserRejectedRequestError=r.JsonRpcVersionUnsupportedError=r.LimitExceededRpcError=r.MethodNotSupportedRpcError=r.TransactionRejectedRpcError=r.ResourceUnavailableRpcError=r.ResourceNotFoundRpcError=r.InvalidInputRpcError=r.InternalRpcError=r.InvalidParamsRpcError=r.MethodNotFoundRpcError=r.InvalidRequestRpcError=r.ParseRpcError=r.ProviderRpcError=r.RpcError=void 0;let n=e.r(91633),i=e.r(666442);class a extends n.BaseError{constructor(e,{code:t,docsPath:r,metaMessages:n,name:a,shortMessage:o}){super(o,{cause:e,docsPath:r,metaMessages:n||e?.metaMessages,name:a||"RpcError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.name=a||e.name,this.code=e instanceof i.RpcRequestError?e.code:t??-1}}r.RpcError=a;class o extends a{constructor(e,t){super(e,t),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=t.data}}r.ProviderRpcError=o;class s extends a{constructor(e){super(e,{code:s.code,name:"ParseRpcError",shortMessage:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."})}}r.ParseRpcError=s,Object.defineProperty(s,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32700});class c extends a{constructor(e){super(e,{code:c.code,name:"InvalidRequestRpcError",shortMessage:"JSON is not a valid request object."})}}r.InvalidRequestRpcError=c,Object.defineProperty(c,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32600});class u extends a{constructor(e,{method:t}={}){super(e,{code:u.code,name:"MethodNotFoundRpcError",shortMessage:`The method${t?` "${t}"`:""} does not exist / is not available.`})}}r.MethodNotFoundRpcError=u,Object.defineProperty(u,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32601});class l extends a{constructor(e){super(e,{code:l.code,name:"InvalidParamsRpcError",shortMessage:"Invalid parameters were provided to the RPC method.\nDouble check you have provided the correct parameters."})}}r.InvalidParamsRpcError=l,Object.defineProperty(l,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32602});class d extends a{constructor(e){super(e,{code:d.code,name:"InternalRpcError",shortMessage:"An internal error was received."})}}r.InternalRpcError=d,Object.defineProperty(d,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32603});class f extends a{constructor(e){super(e,{code:f.code,name:"InvalidInputRpcError",shortMessage:"Missing or invalid parameters.\nDouble check you have provided the correct parameters."})}}r.InvalidInputRpcError=f,Object.defineProperty(f,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32e3});class p extends a{constructor(e){super(e,{code:p.code,name:"ResourceNotFoundRpcError",shortMessage:"Requested resource not found."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceNotFoundRpcError"})}}r.ResourceNotFoundRpcError=p,Object.defineProperty(p,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32001});
31class h extends a{constructor(e){super(e,{code:h.code,name:"ResourceUnavailableRpcError",shortMessage:"Requested resource not available."})}}r.ResourceUnavailableRpcError=h,Object.defineProperty(h,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32002});class m extends a{constructor(e){super(e,{code:m.code,name:"TransactionRejectedRpcError",shortMessage:"Transaction creation failed."})}}r.TransactionRejectedRpcError=m,Object.defineProperty(m,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32003});class b extends a{constructor(e,{method:t}={}){super(e,{code:b.code,name:"MethodNotSupportedRpcError",shortMessage:`Method${t?` "${t}"`:""} is not supported.`})}}r.MethodNotSupportedRpcError=b,Object.defineProperty(b,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32004});class y extends a{constructor(e){super(e,{code:y.code,name:"LimitExceededRpcError",shortMessage:"Request exceeds defined limit."})}}r.LimitExceededRpcError=y,Object.defineProperty(y,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32005});class g extends a{constructor(e){super(e,{code:g.code,name:"JsonRpcVersionUnsupportedError",shortMessage:"Version of JSON-RPC protocol is not supported."})}}r.JsonRpcVersionUnsupportedError=g,Object.defineProperty(g,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32006});class v extends o{constructor(e){super(e,{code:v.code,name:"UserRejectedRequestError",shortMessage:"User rejected the request."})}}r.UserRejectedRequestError=v,Object.defineProperty(v,"code",{enumerable:!0,configurable:!0,writable:!0,value:4001});class w extends o{constructor(e){super(e,{code:w.code,name:"UnauthorizedProviderError",shortMessage:"The requested method and/or account has not been authorized by the user."})}}r.UnauthorizedProviderError=w,Object.defineProperty(w,"code",{enumerable:!0,configurable:!0,writable:!0,value:4100});class E extends o{constructor(e,{method:t}={}){super(e,{code:E.code,name:"UnsupportedProviderMethodError",shortMessage:`The Provider does not support the requested method${t?` " ${t}"`:""}.`})}}r.UnsupportedProviderMethodError=E,Object.defineProperty(E,"code",{enumerable:!0,configurable:!0,writable:!0,value:4200});class P extends o{constructor(e){super(e,{code:P.code,name:"ProviderDisconnectedError",shortMessage:"The Provider is disconnected from all chains."})}}r.ProviderDisconnectedError=P,Object.defineProperty(P,"code",{enumerable:!0,configurable:!0,writable:!0,value:4900});class x extends o{constructor(e){super(e,{code:x.code,name:"ChainDisconnectedError",shortMessage:"The Provider is not connected to the requested chain."})}}r.ChainDisconnectedError=x,Object.defineProperty(x,"code",{enumerable:!0,configurable:!0,writable:!0,value:4901});class A extends o{constructor(e){super(e,{code:A.code,name:"SwitchChainError",shortMessage:"An error occurred when attempting to switch chain."})}}r.SwitchChainError=A,Object.defineProperty(A,"code",{enumerable:!0,configurable:!0,writable:!0,value:4902});class I extends o{constructor(e){super(e,{code:I.code,name:"UnsupportedNonOptionalCapabilityError",shortMessage:"This Wallet does not support a capability that was not marked as optional."})}}r.UnsupportedNonOptionalCapabilityError=I,Object.defineProperty(I,"code",{enumerable:!0,configurable:!0,writable:!0,value:5700});class T extends o{constructor(e){super(e,{code:T.code,name:"UnsupportedChainIdError",shortMessage:"This Wallet does not support the requested chain ID."})}}r.UnsupportedChainIdError=T,Object.defineProperty(T,"code",{enumerable:!0,configurable:!0,writable:!0,value:5710});class S extends o{constructor(e){super(e,{code:S.code,name:"DuplicateIdError",shortMessage:"There is already a bundle submitted with this ID."})}}r.DuplicateIdError=S,Object.defineProperty(S,"code",{enumerable:!0,configurable:!0,writable:!0,value:5720});class C extends o{constructor(e){super(e,{code:C.code,name:"UnknownBundleIdError",shortMessage:"This bundle id is unknown / has not been submitted"})}}r.UnknownBundleIdError=C,Object.defineProperty(C,"code",{enumerable:!0,configurable:!0,writable:!0,value:5730});class O extends o{constructor(e){super(e,{code:O.code,name:"BundleTooLargeError",shortMessage:"The call bundle is too large for the Wallet to process."})}}r.BundleTooLargeError=O,Object.defineProperty(O,"code",{enumerable:!0,configurable:!0,writable:!0,value:5740});
31class j extends o{constructor(e){super(e,{code:j.code,name:"AtomicReadyWalletRejectedUpgradeError",shortMessage:"The Wallet can support atomicity after an upgrade, but the user rejected the upgrade."})}}r.AtomicReadyWalletRejectedUpgradeError=j,Object.defineProperty(j,"code",{enumerable:!0,configurable:!0,writable:!0,value:5750});class k extends o{constructor(e){super(e,{code:k.code,name:"AtomicityNotSupportedError",shortMessage:"The wallet does not support atomic execution but the request requires it."})}}r.AtomicityNotSupportedError=k,Object.defineProperty(k,"code",{enumerable:!0,configurable:!0,writable:!0,value:5760});class R extends o{constructor(e){super(e,{code:R.code,name:"WalletConnectSessionSettlementError",shortMessage:"WalletConnect session settlement failed."})}}r.WalletConnectSessionSettlementError=R,Object.defineProperty(R,"code",{enumerable:!0,configurable:!0,writable:!0,value:7e3}),r.UnknownRpcError=class extends a{constructor(e){super(e,{name:"UnknownRpcError",shortMessage:"An unknown RPC error occurred."})}}},290881,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getContractError=function(e,t){let{abi:r,address:c,args:u,docsPath:l,functionName:d,sender:f}=t,p=e instanceof a.RawContractError?e:e instanceof i.BaseError?e.walk(e=>"data"in e)||e.walk():{},{code:h,data:m,details:b,message:y,shortMessage:g}=p,v=e instanceof n.AbiDecodingZeroDataError?new a.ContractFunctionZeroDataError({functionName:d,cause:e}):[3,s.InternalRpcError.code].includes(h)&&(m||b||y||g)||h===s.InvalidInputRpcError.code&&"execution reverted"===b&&m?new a.ContractFunctionRevertedError({abi:r,data:"object"==typeof m?m.data:m,functionName:d,message:p instanceof o.RpcRequestError?b:g??y,cause:e}):e;return new a.ContractFunctionExecutionError(v,{abi:r,args:u,contractAddress:c,docsPath:l,functionName:d,sender:f})};let n=e.r(963101),i=e.r(91633),a=e.r(720794),o=e.r(666442),s=e.r(477323)},741867,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.publicKeyToAddress=function(e){let t=(0,i.keccak256)(`0x${e.substring(4)}`).substring(26);return(0,n.checksumAddress)(`0x${t}`)};let n=e.r(929544),i=e.r(585457)},218565,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.ripemd160=function(e,t){let r=(0,n.ripemd160)((0,i.isHex)(e,{strict:!1})?(0,a.toBytes)(e):e);return"bytes"===(t||"hex")?r:(0,o.toHex)(r)};let n=e.r(776928),i=e.r(528137),a=e.r(935603),o=e.r(850815)},315487,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toEventHash=void 0;var n=e.r(736787);Object.defineProperty(r,"toEventHash",{enumerable:!0,get:function(){return n.toSignatureHash}})},625113,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toEventSignature=void 0;var n=e.r(512185);Object.defineProperty(r,"toEventSignature",{enumerable:!0,get:function(){return n.toSignature}})},476119,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toFunctionHash=void 0;var n=e.r(736787);Object.defineProperty(r,"toFunctionHash",{enumerable:!0,get:function(){return n.toSignatureHash}})},755535,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toFunctionSignature=void 0;var n=e.r(512185);Object.defineProperty(r,"toFunctionSignature",{enumerable:!0,get:function(){return n.toSignature}})},196270,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.nonceManager=void 0,r.createNonceManager=a,r.jsonRpc=o;let n=e.r(114488),i=e.r(170675);function a(e){let{source:t}=e,r=new Map,n=new i.LruMap(8192),a=new Map,o=e=>{let{address:t,chainId:r}=e;return`${t}.${r}`};return{async consume(e){let{address:r,chainId:i,client:a}=e,s=o({address:r,chainId:i}),c=this.get({address:r,chainId:i,client:a});this.increment({address:r,chainId:i});let u=await c;return await t.set({address:r,chainId:i},u),n.set(s,u),u},async increment(e){let{address:t,chainId:n}=e,i=o({address:t,chainId:n}),a=r.get(i)??0;r.set(i,a+1)},async get(e){let{address:i,chainId:s,client:c}=e,u=o({address:i,chainId:s}),l=a.get(u);return l||(l=(async()=>{try{let e=await t.get({address:i,chainId:s,client:c}),r=n.get(u)??0;if(r>0&&e<=r)return r+1;return n.delete(u),e}finally{this.reset({address:i,chainId:s})}})(),a.set(u,l)),(r.get(u)??0)+await l},reset(e){let{address:t,chainId:n}=e,i=o({address:t,chainId:n});r.delete(i),a.delete(i)}}}function o(){return{async get(e){let{address:t,client:r}=e;return(0,n.getTransactionCount)(r,{address:t,blockTag:"pending"})},set(){}}}r.nonceManager=a({source:o()})},631674,(e,t,r)=>{"use strict";
31Object.defineProperty(r,"__esModule",{value:!0}),r.withTimeout=function(e,t){let{errorInstance:r=Error("timed out"),timeout:n,signal:i}=t;return new Promise((t,a)=>{(async()=>{let o;try{let s=new AbortController;n>0&&(o=setTimeout(()=>{i?s.abort():a(r)},n)),t(await e({signal:s?.signal||null}))}catch(e){e?.name==="AbortError"&&a(r),a(e)}finally{clearTimeout(o)}})()})}},61010,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.idCache=void 0,r.idCache={current:0,take(){return this.current++},reset(){this.current=0}}},237303,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getHttpRpcClient=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{url:r,headers:c}=s(e);return{async request(e){let{body:s,fetchFn:u=t.fetchFn??fetch,onRequest:l=t.onRequest,onResponse:d=t.onResponse,timeout:f=t.timeout??1e4}=e,p={...t.fetchOptions??{},...e.fetchOptions??{}},{headers:h,method:m,signal:b}=p;try{let e,t=await (0,i.withTimeout)(async e=>{let{signal:t}=e,n={...p,body:Array.isArray(s)?(0,a.stringify)(s.map(e=>({jsonrpc:"2.0",id:e.id??o.idCache.take(),...e}))):(0,a.stringify)({jsonrpc:"2.0",id:s.id??o.idCache.take(),...s}),headers:{...c,"Content-Type":"application/json",...h},method:m||"POST",signal:b||(f>0?t:null)},i=new Request(r,n),d=await l?.(i,n)??{...n,url:r};return await u(d.url??r,d)},{errorInstance:new n.TimeoutError({body:s,url:r}),timeout:f,signal:!0});if(d&&await d(t),t.headers.get("Content-Type")?.startsWith("application/json"))e=await t.json();else{e=await t.text();try{e=JSON.parse(e||"{}")}catch(r){if(t.ok)throw r;e={error:e}}}if(!t.ok){if("number"==typeof e.error?.code&&"string"==typeof e.error?.message)return e;throw new n.HttpRequestError({body:s,details:(0,a.stringify)(e.error)||t.statusText,headers:t.headers,status:t.status,url:r})}return e}catch(e){if(e instanceof n.HttpRequestError||e instanceof n.TimeoutError)throw e;throw new n.HttpRequestError({body:s,cause:e,url:r})}}}},r.parseUrl=s;let n=e.r(666442),i=e.r(631674),a=e.r(905241),o=e.r(61010);function s(e){try{let t=new URL(e),r=(()=>{if(t.username){let e=`${decodeURIComponent(t.username)}:${decodeURIComponent(t.password)}`;return t.username="",t.password="",{url:t.toString(),headers:{Authorization:`Basic ${btoa(e)}`}}}})();return{url:t.toString(),...r}}catch{return{url:e}}}},127063,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.socketClientCache=void 0,r.getSocketRpcClient=s;let n=e.r(666442),i=e.r(125590),a=e.r(631674),o=e.r(61010);async function s(e){let{getSocket:t,keepAlive:s=!0,key:c="socket",reconnect:u=!0,url:l}=e,{interval:d=3e4}="object"==typeof s?s:{},{attempts:f=5,delay:p=2e3}="object"==typeof u?u:{},h=JSON.stringify({keepAlive:s,key:c,url:l,reconnect:u}),m=r.socketClientCache.get(h);if(m)return m;let b=0,{schedule:y}=(0,i.createBatchScheduler)({id:h,fn:async()=>{let e,i,c,y=new Map,g=new Map,v=!1;function w(){u&&b<f?v||(v=!0,b++,i?.close(),setTimeout(async()=>{await E().catch(console.error),v=!1},p)):(y.clear(),g.clear())}async function E(){let r=await t({onClose(){for(let e of y.values())e.onError?.(new n.SocketClosedError({url:l}));for(let e of g.values())e.onError?.(new n.SocketClosedError({url:l}));w()},onError(t){for(let r of(e=t,y.values()))r.onError?.(e);for(let t of g.values())t.onError?.(e);w()},onOpen(){e=void 0,b=0},onResponse(e){let t="eth_subscription"===e.method,r=t?e.params.subscription:e.id,n=t?g:y,i=n.get(r);i&&i.onResponse(e),t||n.delete(r)}});if(i=r,s&&(c&&clearInterval(c),c=setInterval(()=>i.ping?.(),d)),u&&g.size>0)for(let[e,{onResponse:t,body:r,onError:n}]of g.entries())r&&(g.delete(e),m?.request({body:r,onResponse:t,onError:n}));return r}return await E(),e=void 0,m={close(){c&&clearInterval(c),i.close(),r.socketClientCache.delete(h)},get socket(){return i},request(t){let{body:r,onError:n,onResponse:a}=t;e&&n&&n(e);let s=r.id??o.idCache.take(),c=e=>{("number"!=typeof e.id||s===e.id)&&("eth_subscribe"===r.method&&"string"==typeof e.result&&g.set(e.result,{onResponse:c,onError:n,body:r}),a(e))};"eth_unsubscribe"===r.method&&g.delete(r.params?.[0]),y.set(s,{onResponse:c,onError:n});try{i.request({body:{jsonrpc:"2.0",id:s,...r}})}catch(e){n?.(e)}},requestAsync(e){let{body:t,timeout:r=1e4}=e;return(0,a.withTimeout)(()=>new Promise((e,r)=>this.request({body:t,onError:r,onResponse:e})),{errorInstance:new n.TimeoutError({body:t,url:l}),timeout:r})},requests:y,subscriptions:g,url:l},r.socketClientCache.set(h,m),[m]}}),[g,[v]]=await y();return v}r.socketClientCache=new Map},597025,(e,t,r)=>{"use strict";
31Object.defineProperty(r,"__esModule",{value:!0}),r.sha256=function(e,t){let r=(0,n.sha256)((0,i.isHex)(e,{strict:!1})?(0,a.toBytes)(e):e);return"bytes"===(t||"hex")?r:(0,o.toHex)(r)};let n=e.r(456782),i=e.r(528137),a=e.r(935603),o=e.r(850815)},397856,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.commitmentToVersionedHash=function(e){let{commitment:t,version:r=1}=e,a=e.to??("string"==typeof t?"hex":"bytes"),o=(0,i.sha256)(t,"bytes");return o.set([r],0),"bytes"===a?o:(0,n.bytesToHex)(o)};let n=e.r(850815),i=e.r(597025)},444604,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.commitmentsToVersionedHashes=function(e){let{commitments:t,version:r}=e,i=e.to??("string"==typeof t[0]?"hex":"bytes"),a=[];for(let e of t)a.push((0,n.commitmentToVersionedHash)({commitment:e,to:i,version:r}));return a};let n=e.r(397856)},665729,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.maxBytesPerTransaction=r.bytesPerBlob=r.fieldElementsPerBlob=r.bytesPerFieldElement=void 0,r.bytesPerFieldElement=32,r.fieldElementsPerBlob=4096,r.bytesPerBlob=r.bytesPerFieldElement*r.fieldElementsPerBlob,r.maxBytesPerTransaction=6*r.bytesPerBlob-1-6*r.fieldElementsPerBlob},487679,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.versionedHashVersionKzg=void 0,r.versionedHashVersionKzg=1},23834,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidVersionedHashVersionError=r.InvalidVersionedHashSizeError=r.EmptyBlobError=r.BlobSizeTooLargeError=void 0;let n=e.r(487679),i=e.r(91633);class a extends i.BaseError{constructor({maxSize:e,size:t}){super("Blob size is too large.",{metaMessages:[`Max: ${e} bytes`,`Given: ${t} bytes`],name:"BlobSizeTooLargeError"})}}r.BlobSizeTooLargeError=a;class o extends i.BaseError{constructor(){super("Blob data must not be empty.",{name:"EmptyBlobError"})}}r.EmptyBlobError=o;class s extends i.BaseError{constructor({hash:e,size:t}){super(`Versioned hash "${e}" size is invalid.`,{metaMessages:["Expected: 32",`Received: ${t}`],name:"InvalidVersionedHashSizeError"})}}r.InvalidVersionedHashSizeError=s;class c extends i.BaseError{constructor({hash:e,version:t}){super(`Versioned hash "${e}" version is invalid.`,{metaMessages:[`Expected: ${n.versionedHashVersionKzg}`,`Received: ${t}`],name:"InvalidVersionedHashVersionError"})}}r.InvalidVersionedHashVersionError=c},767932,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toBlobs=function(e){let t=e.to??("string"==typeof e.data?"hex":"bytes"),r="string"==typeof e.data?(0,s.hexToBytes)(e.data):e.data,u=(0,o.size)(r);if(!u)throw new i.EmptyBlobError;if(u>n.maxBytesPerTransaction)throw new i.BlobSizeTooLargeError({maxSize:n.maxBytesPerTransaction,size:u});let l=[],d=!0,f=0;for(;d;){let e=(0,a.createCursor)(new Uint8Array(n.bytesPerBlob)),t=0;for(;t<n.fieldElementsPerBlob;){let i=r.slice(f,f+(n.bytesPerFieldElement-1));if(e.pushByte(0),e.pushBytes(i),i.length<31){e.pushByte(128),d=!1;break}t++,f+=31}l.push(e)}return"bytes"===t?l.map(e=>e.bytes):l.map(e=>(0,c.bytesToHex)(e.bytes))};let n=e.r(665729),i=e.r(23834),a=e.r(925294),o=e.r(484550),s=e.r(935603),c=e.r(850815)},458775,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toBlobSidecars=function(e){let{data:t,kzg:r,to:o}=e,s=e.blobs??(0,a.toBlobs)({data:t,to:o}),c=e.commitments??(0,n.blobsToCommitments)({blobs:s,kzg:r,to:o}),u=e.proofs??(0,i.blobsToProofs)({blobs:s,commitments:c,kzg:r,to:o}),l=[];for(let e=0;e<s.length;e++)l.push({blob:s[e],commitment:c[e],proof:u[e]});return l};let n=e.r(830588),i=e.r(764012),a=e.r(767932)},446558,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getTransactionType=function(e){if(e.type)return e.type;if(void 0!==e.authorizationList)return"eip7702";if(void 0!==e.blobs||void 0!==e.blobVersionedHashes||void 0!==e.maxFeePerBlobGas||void 0!==e.sidecars)return"eip4844";if(void 0!==e.maxFeePerGas||void 0!==e.maxPriorityFeePerGas)return"eip1559";if(void 0!==e.gasPrice)return void 0!==e.accessList?"eip2930":"legacy";throw new n.InvalidSerializableTransactionError({transaction:e})};let n=e.r(341289)},724514,(e,t,r)=>{"use strict";
31Object.defineProperty(r,"__esModule",{value:!0}),r.getTransactionError=function(e,t){let r,{docsPath:o,...s}=t,c=(r=(0,a.getNodeError)(e,s))instanceof n.UnknownNodeError?e:r;return new i.TransactionExecutionError(c,{docsPath:o,...s})};let n=e.r(659641),i=e.r(341289),a=e.r(255397)},865654,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getChainId=i;let n=e.r(723223);async function i(e){let t=await e.request({method:"eth_chainId"},{dedupe:!0});return(0,n.hexToNumber)(t)}},655267,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.fillTransaction=p;let n=e.r(155401),i=e.r(615144),a=e.r(724514),o=e.r(106636),s=e.r(728125),c=e.r(244319),u=e.r(388012),l=e.r(854495),d=e.r(578346),f=e.r(865654);async function p(e,t){let{account:r=e.account,accessList:p,authorizationList:h,chain:m=e.chain,blobVersionedHashes:b,blobs:y,data:g,gas:v,gasPrice:w,maxFeePerBlobGas:E,maxFeePerGas:P,maxPriorityFeePerGas:x,nonce:A,nonceManager:I,to:T,type:S,value:C,...O}=t,j=await (async()=>{if(!r||!I||void 0!==A)return A;let t=(0,n.parseAccount)(r),i=m?m.id:await (0,u.getAction)(e,f.getChainId,"getChainId")({});return await I.consume({address:t.address,chainId:i,client:e})})();(0,l.assertRequest)(t);let k=m?.formatters?.transactionRequest?.format,R=(k||c.formatTransactionRequest)({...(0,o.extract)(O,{format:k}),account:r?(0,n.parseAccount)(r):void 0,accessList:p,authorizationList:h,blobs:y,blobVersionedHashes:b,data:g,gas:v,gasPrice:w,maxFeePerBlobGas:E,maxFeePerGas:P,maxPriorityFeePerGas:x,nonce:j,to:T,type:S,value:C},"fillTransaction");try{let r=await e.request({method:"eth_fillTransaction",params:[R]}),n=(m?.formatters?.transaction?.format||s.formatTransaction)(r.tx);delete n.blockHash,delete n.blockNumber,delete n.r,delete n.s,delete n.transactionIndex,delete n.v,delete n.yParity,n.data=n.input,n.gas&&(n.gas=t.gas??n.gas),n.gasPrice&&(n.gasPrice=t.gasPrice??n.gasPrice),n.maxFeePerBlobGas&&(n.maxFeePerBlobGas=t.maxFeePerBlobGas??n.maxFeePerBlobGas),n.maxFeePerGas&&(n.maxFeePerGas=t.maxFeePerGas??n.maxFeePerGas),n.maxPriorityFeePerGas&&(n.maxPriorityFeePerGas=t.maxPriorityFeePerGas??n.maxPriorityFeePerGas),n.nonce&&(n.nonce=t.nonce??n.nonce);let a=await (async()=>{if("function"==typeof m?.fees?.baseFeeMultiplier){let r=await (0,u.getAction)(e,d.getBlock,"getBlock")({});return m.fees.baseFeeMultiplier({block:r,client:e,request:t})}return m?.fees?.baseFeeMultiplier??1.2})();if(a<1)throw new i.BaseFeeScalarError;let o=a.toString().split(".")[1]?.length??0,c=10**o,l=e=>e*BigInt(Math.ceil(a*c))/BigInt(c);return n.maxFeePerGas&&!t.maxFeePerGas&&(n.maxFeePerGas=l(n.maxFeePerGas)),n.gasPrice&&!t.gasPrice&&(n.gasPrice=l(n.gasPrice)),{raw:r.raw,transaction:{from:R.from,...n}}}catch(r){throw(0,a.getTransactionError)(r,{...t,chain:e.chain})}}},113211,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.supportsFillTransaction=r.eip1559NetworkCache=r.defaultParameters=void 0,r.prepareTransactionRequest=v;let n=e.r(155401),i=e.r(965094),a=e.r(434032),o=e.r(578346),s=e.r(114488),c=e.r(615144),u=e.r(830588),l=e.r(764012),d=e.r(444604),f=e.r(458775),p=e.r(388012),h=e.r(170675),m=e.r(854495),b=e.r(446558),y=e.r(655267),g=e.r(865654);async function v(e,t){let h,v,w=t;w.account??=e.account,w.parameters??=r.defaultParameters;let{account:E,chain:P=e.chain,nonceManager:x,parameters:A}=w,I="function"==typeof P?.prepareTransactionRequest?{fn:P.prepareTransactionRequest,runAt:["beforeFillTransaction"]}:Array.isArray(P?.prepareTransactionRequest)?{fn:P.prepareTransactionRequest[0],runAt:P.prepareTransactionRequest[1].runAt}:void 0;async function T(){return h||(void 0!==w.chainId?w.chainId:P?P.id:h=await (0,p.getAction)(e,g.getChainId,"getChainId")({}))}let S=E?(0,n.parseAccount)(E):E,C=w.nonce;if(A.includes("nonce")&&void 0===C&&S&&x){let t=await T();C=await x.consume({address:S.address,chainId:t,client:e})}I?.fn&&I.runAt?.includes("beforeFillTransaction")&&(w=await I.fn({...w,chain:P},{phase:"beforeFillTransaction"}),C??=w.nonce);let O=(!(A.includes("blobVersionedHashes")||A.includes("sidecars"))||!w.kzg||!w.blobs)&&!1!==r.supportsFillTransaction.get(e.uid)&&["fees","gas"].some(e=>A.includes(e))&&(A.includes("chainId")&&"number"!=typeof w.chainId||A.includes("nonce")&&"number"!=typeof C||A.includes("fees")&&"bigint"!=typeof w.gasPrice&&("bigint"!=typeof w.maxFeePerGas||"bigint"!=typeof w.maxPriorityFeePerGas)||A.includes("gas")&&"bigint"!=typeof w.gas)?await (0,p.getAction)(e,y.fillTransaction,"fillTransaction")({...w,nonce:C}).then(t=>{let{chainId:n,from:i,gas:a,gasPrice:o,nonce:s,maxFeePerBlobGas:c,maxFeePerGas:u,maxPriorityFeePerGas:l,type:d,...f}=t.transaction;return r.supportsFillTransaction.set(e.uid,!0),{...w,...i?{from:i}:{},...d&&!w.type?{type:d}:{},...void 0!==n?{chainId:n}:{},...void 0!==a?{gas:a}:{},...void 0!==o?{gasPrice:o}:{},...void 0!==s?{nonce:s}:{},...void 0!==c&&"legacy"!==w.type&&"eip2930"!==w.type?{maxFeePerBlobGas:c}:{},...void 0!==u&&"legacy"!==w.type&&"eip2930"!==w.type?{maxFeePerGas:u}:{},...void 0!==l&&"legacy"!==w.type&&"eip2930"!==w.type?{maxPriorityFeePerGas:l}:{},..."nonceKey"in f&&void 0!==f.nonceKey?{nonceKey:f.nonceKey}:{},..."keyAuthorization"in f&&void 0!==f.keyAuthorization&&null!==f.keyAuthorization&&!("keyAuthorization"in w)?{keyAuthorization:f.keyAuthorization}:{}}}).catch(t=>{if("TransactionExecutionError"!==t.name)return w;if(t.walk?.(e=>"ExecutionRevertedError"===e.name))throw t;return t.walk?.(e=>"MethodNotFoundRpcError"===e.name||"MethodNotSupportedRpcError"===e.name||e.message?.includes("eth_fillTransaction is not available"))&&r.supportsFillTransaction.set(e.uid,!1),w}):w;C??=O.nonce;let{blobs:j,gas:k,kzg:R,type:_}=w={...O,...S?{from:S?.address}:{},...C?{nonce:C}:{}};async function B(){return v||(v=await (0,p.getAction)(e,o.getBlock,"getBlock")({blockTag:"latest"}))}if(I?.fn&&I.runAt?.includes("beforeFillParameters")&&(w=await I.fn({...w,chain:P},{phase:"beforeFillParameters"})),A.includes("nonce")&&void 0===C&&S&&!x&&(w.nonce=await (0,p.getAction)(e,s.getTransactionCount,"getTransactionCount")({address:S.address,blockTag:"pending"})),(A.includes("blobVersionedHashes")||A.includes("sidecars"))&&j&&R){let e=(0,u.blobsToCommitments)({blobs:j,kzg:R});if(A.includes("blobVersionedHashes")){let t=(0,d.commitmentsToVersionedHashes)({commitments:e,to:"hex"});w.blobVersionedHashes=t}if(A.includes("sidecars")){let t=(0,l.blobsToProofs)({blobs:j,commitments:e,kzg:R}),r=(0,f.toBlobSidecars)({blobs:j,commitments:e,proofs:t,to:"hex"});w.sidecars=r}}if(A.includes("chainId")&&(w.chainId=await T()),(A.includes("fees")||A.includes("type"))&&void 0===_)try{w.type=(0,b.getTransactionType)(w)}catch{let t=r.eip1559NetworkCache.get(e.uid);if(void 0===t){let n=await B();t="bigint"==typeof n?.baseFeePerGas,r.eip1559NetworkCache.set(e.uid,t)}w.type=t?"eip1559":"legacy"}if(A.includes("fees"))if("legacy"!==w.type&&"eip2930"!==w.type){if(void 0===w.maxFeePerGas||void 0===w.maxPriorityFeePerGas){let t=await B(),{maxFeePerGas:r,maxPriorityFeePerGas:n}=await (0,i.internal_estimateFeesPerGas)(e,{block:t,chain:P,request:w});if(void 0===w.maxPriorityFeePerGas&&w.maxFeePerGas&&w.maxFeePerGas<n)throw new c.MaxFeePerGasTooLowError({maxPriorityFeePerGas:n});w.maxPriorityFeePerGas=n,w.maxFeePerGas=r}}else{if(void 0!==w.maxFeePerGas||void 0!==w.maxPriorityFeePerGas)throw new c.Eip1559FeesNotSupportedError;if(void 0===w.gasPrice){let t=await B(),{gasPrice:r}=await (0,i.internal_estimateFeesPerGas)(e,{block:t,chain:P,request:w,type:"legacy"});w.gasPrice=r}}return A.includes("gas")&&void 0===k&&(w.gas=await (0,p.getAction)(e,a.estimateGas,"estimateGas")({...w,account:S,prepare:S?.type==="local"?[]:["blobVersionedHashes"]})),I?.fn&&I.runAt?.includes("afterFillParameters")&&(w=await I.fn({...w,chain:P},{phase:"afterFillParameters"})),(0,m.assertRequest)(w),delete w.parameters,w}r.defaultParameters=["blobVersionedHashes","chainId","fees","gas","nonce","type"],r.eip1559NetworkCache=new Map,r.supportsFillTransaction=new h.LruMap(128)},434032,(e,t,r)=>{"use strict";
31Object.defineProperty(r,"__esModule",{value:!0}),r.estimateGas=p;let n=e.r(155401),i=e.r(91633),a=e.r(271077),o=e.r(850815),s=e.r(379541),c=e.r(106636),u=e.r(244319),l=e.r(434467),d=e.r(854495),f=e.r(113211);async function p(e,t){let{account:r=e.account,prepare:p=!0}=t,h=r?(0,n.parseAccount)(r):void 0,m=Array.isArray(p)?p:h?.type!=="local"?["blobVersionedHashes"]:void 0;try{let r=await (async()=>t.to?t.to:t.authorizationList&&t.authorizationList.length>0?await (0,a.recoverAuthorizationAddress)({authorization:t.authorizationList[0]}).catch(()=>{throw new i.BaseError("`to` is required. Could not infer from `authorizationList`")}):void 0)(),{accessList:n,authorizationList:s,blobs:b,blobVersionedHashes:y,blockNumber:g,blockTag:v,data:w,gas:E,gasPrice:P,maxFeePerBlobGas:x,maxFeePerGas:A,maxPriorityFeePerGas:I,nonce:T,value:S,stateOverride:C,...O}=p?await (0,f.prepareTransactionRequest)(e,{...t,parameters:m,to:r}):t;if(E&&t.gas!==E)return E;let j=("bigint"==typeof g?(0,o.numberToHex)(g):void 0)||v,k=(0,l.serializeStateOverride)(C);(0,d.assertRequest)(t);let R=e.chain?.formatters?.transactionRequest?.format,_=(R||u.formatTransactionRequest)({...(0,c.extract)(O,{format:R}),account:h,accessList:n,authorizationList:s,blobs:b,blobVersionedHashes:y,data:w,gasPrice:P,maxFeePerBlobGas:x,maxFeePerGas:A,maxPriorityFeePerGas:I,nonce:T,to:r,value:S},"estimateGas");return BigInt(await e.request({method:"eth_estimateGas",params:k?[_,j??e.experimental_blockTag??"latest",k]:j?[_,j]:[_]}))}catch(r){throw(0,s.getEstimateGasError)(r,{...t,account:h,chain:e.chain})}}},400744,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.estimateContractGas=c;let n=e.r(155401),i=e.r(804943),a=e.r(290881),o=e.r(388012),s=e.r(434032);async function c(e,t){let{abi:r,address:c,args:u,functionName:l,dataSuffix:d="string"==typeof e.dataSuffix?e.dataSuffix:e.dataSuffix?.value,...f}=t,p=(0,i.encodeFunctionData)({abi:r,args:u,functionName:l});try{return await (0,o.getAction)(e,s.estimateGas,"estimateGas")({data:`${p}${d?d.replace("0x",""):""}`,to:c,...f})}catch(t){let e=f.account?(0,n.parseAccount)(f.account):void 0;throw(0,a.getContractError)(t,{abi:r,address:c,args:u,docsPath:"/docs/contract/estimateContractGas",functionName:l,sender:e?.address})}}},359389,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isAddressEqual=function(e,t){if(!(0,i.isAddress)(e,{strict:!1}))throw new n.InvalidAddressError({address:e});if(!(0,i.isAddress)(t,{strict:!1}))throw new n.InvalidAddressError({address:t});return e.toLowerCase()===t.toLowerCase()};let n=e.r(224276),i=e.r(429625)},798336,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.formatLog=function(e){let{args:t,eventName:r}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,blockTimestamp:e.blockTimestamp?BigInt(e.blockTimestamp):null===e.blockTimestamp?null:void 0,logIndex:e.logIndex?Number(e.logIndex):null,transactionHash:e.transactionHash?e.transactionHash:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,...r?{args:t,eventName:r}:{}}}},197532,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeEventLog=function(e){let{abi:t,data:r,strict:l,topics:d}=e,f=l??!0,[p,...h]=d;if(!p)throw new n.AbiEventSignatureEmptyTopicsError({docsPath:u});let m=t.find(e=>"event"===e.type&&p===(0,o.toEventSelector)((0,c.formatAbiItem)(e)));if(!(m&&"name"in m)||"event"!==m.type)throw new n.AbiEventSignatureNotFoundError(p,{docsPath:u});let{name:b,inputs:y}=m,g=y?.some(e=>!("name"in e&&e.name)),v=g?[]:{},w=y.map((e,t)=>[e,t]).filter(e=>{let[t]=e;return"indexed"in t&&t.indexed}),E=[];for(let e=0;e<w.length;e++){let[t,r]=w[e],i=h[e];if(!i){if(f)throw new n.DecodeLogTopicsMismatch({abiItem:m,param:t});E.push([t,r]);continue}v[g?r:t.name||r]=function(e){let{param:t,value:r}=e;return"string"===t.type||"bytes"===t.type||"tuple"===t.type||t.type.match(/^(.*)\[(\d+)?\]$/)?r:((0,s.decodeAbiParameters)([t],r)||[])[0]}({param:t,value:i})}let P=y.filter(e=>
31!("indexed"in e&&e.indexed)),x=f?P:[...E.map(e=>{let[t]=e;return t}),...P];if(x.length>0){if(r&&"0x"!==r)try{let e=(0,s.decodeAbiParameters)(x,r);if(e){let t=0;if(!f)for(let[r,n]of E)v[g?n:r.name||n]=e[t++];if(g)for(let r=0;r<y.length;r++)void 0===v[r]&&t<e.length&&(v[r]=e[t++]);else for(let r=0;r<P.length;r++)v[P[r].name]=e[t++]}}catch(e){if(f){if(e instanceof n.AbiDecodingDataSizeTooSmallError||e instanceof i.PositionOutOfBoundsError)throw new n.DecodeLogDataMismatch({abiItem:m,data:r,params:x,size:(0,a.size)(r)});throw e}}else if(f)throw new n.DecodeLogDataMismatch({abiItem:m,data:"0x",params:x,size:0})}return{eventName:b,args:Object.values(v).length>0?v:void 0}};let n=e.r(963101),i=e.r(613588),a=e.r(484550),o=e.r(138355),s=e.r(239072),c=e.r(199807),u="/docs/contract/decodeEventLog"},685530,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.parseEventLogs=function(e){let{abi:t,args:r,logs:u,strict:l=!0}=e,d=(()=>{if(e.eventName)return Array.isArray(e.eventName)?e.eventName:[e.eventName]})(),f=t.filter(e=>"event"===e.type).map(e=>({abi:e,selector:(0,s.toEventSelector)(e)}));return u.map(e=>{let t,s,u="string"==typeof e.blockNumber?(0,a.formatLog)(e):e,p=f.filter(e=>u.topics[0]===e.selector);if(0===p.length)return null;for(let e of p)try{t=(0,c.decodeEventLog)({...u,abi:[e.abi],strict:!0}),s=e;break}catch{}if(!t&&!l){s=p[0];try{t=(0,c.decodeEventLog)({data:u.data,topics:u.topics,abi:[s.abi],strict:!1})}catch{let e=s.abi.inputs?.some(e=>!("name"in e&&e.name));return{...u,args:e?[]:{},eventName:s.abi.name}}}return t&&s&&(!d||d.includes(t.eventName))&&function(e){let{args:t,inputs:r,matchArgs:a}=e;if(!a)return!0;if(!t)return!1;function s(e,t,r){try{if("address"===e.type)return(0,n.isAddressEqual)(t,r);if("string"===e.type||"bytes"===e.type)return(0,o.keccak256)((0,i.toBytes)(t))===r;return t===r}catch{return!1}}return Array.isArray(t)&&Array.isArray(a)?a.every((e,n)=>{if(null==e)return!0;let i=r[n];return!!i&&(Array.isArray(e)?e:[e]).some(e=>s(i,e,t[n]))}):!("object"!=typeof t||Array.isArray(t)||"object"!=typeof a||Array.isArray(a))&&Object.entries(a).every(e=>{let[n,i]=e;if(null==i)return!0;let a=r.find(e=>e.name===n);return!!a&&(Array.isArray(i)?i:[i]).some(e=>s(a,e,t[n]))})}({args:t.args,inputs:s.abi.inputs,matchArgs:r})?{...t,...u}:null}).filter(Boolean)};let n=e.r(359389),i=e.r(935603),a=e.r(798336),o=e.r(585457),s=e.r(138355),c=e.r(197532)},417928,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getLogs=s;let n=e.r(725159),i=e.r(685530),a=e.r(850815),o=e.r(798336);async function s(e){let{address:t,blockHash:r,fromBlock:s,toBlock:c,event:u,events:l,args:d,strict:f}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},p=l??(u?[u]:void 0),h=[];p&&(h=[p.flatMap(e=>(0,n.encodeEventTopics)({abi:[e],eventName:e.name,args:l?void 0:d}))],u&&(h=h[0]));let m=(r?await e.request({method:"eth_getLogs",params:[{address:t,topics:h,blockHash:r}]}):await e.request({method:"eth_getLogs",params:[{address:t,topics:h,fromBlock:"bigint"==typeof s?(0,a.numberToHex)(s):s,toBlock:"bigint"==typeof c?(0,a.numberToHex)(c):c}]})).map(e=>(0,o.formatLog)(e));return p?(0,i.parseEventLogs)({abi:p,args:d,logs:m,strict:f??!1}):m}},640653,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getContractEvents=o;let n=e.r(409872),i=e.r(388012),a=e.r(417928);async function o(e,t){let{abi:r,address:o,args:s,blockHash:c,eventName:u,fromBlock:l,toBlock:d,strict:f}=t,p=u?(0,n.getAbiItem)({abi:r,name:u}):void 0,h=p?void 0:r.filter(e=>"event"===e.type);return(0,i.getAction)(e,a.getLogs,"getLogs")({address:o,args:s,blockHash:c,event:p,events:h,fromBlock:l,toBlock:d,strict:f})}},320101,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.decodeFunctionResult=function(e){let{abi:t,args:r,functionName:s,data:c}=e,u=t[0];if(s){let e=(0,a.getAbiItem)({abi:t,args:r,name:s});if(!e)throw new n.AbiFunctionNotFoundError(s,{docsPath:o});u=e}if("function"!==u.type)throw new n.AbiFunctionNotFoundError(void 0,{docsPath:o});if(!u.outputs)throw new n.AbiFunctionOutputsNotFoundError(u.name,{docsPath:o});let l=(0,i.decodeAbiParameters)(u.outputs,c);return l&&l.length>1?l:l&&1===l.length?l[0]:void 0};let n=e.r(963101),i=e.r(239072),a=e.r(409872),o="/docs/contract/decodeFunctionResult"},105960,(e,t,r)=>{"use strict";
31Object.defineProperty(r,"__esModule",{value:!0}),r.getWebSocketRpcClient=a;let n=e.r(666442),i=e.r(127063);async function a(t){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{keepAlive:a,reconnect:o}=r;return(0,i.getSocketRpcClient)({async getSocket(r){let{onClose:i,onError:a,onOpen:o,onResponse:s}=r,c=await Promise.resolve().then(()=>e.r(690785)).then(e=>e.WebSocket),u=new c(t);function l(){u.removeEventListener("close",l),u.removeEventListener("message",d),u.removeEventListener("error",a),u.removeEventListener("open",o),i()}function d(e){let{data:t}=e;if("string"!=typeof t||0!==t.trim().length)try{let e=JSON.parse(t);s(e)}catch(e){a(e)}}u.addEventListener("close",l),u.addEventListener("message",d),u.addEventListener("error",a),u.addEventListener("open",o),u.readyState===c.CONNECTING&&await new Promise((e,t)=>{u&&(u.onopen=e,u.onerror=t)});let{close:f}=u;return Object.assign(u,{close(){f.bind(u)(),l()},ping(){try{if(u.readyState===u.CLOSED||u.readyState===u.CLOSING)throw new n.WebSocketRequestError({url:u.url,cause:new n.SocketClosedError({url:u.url})});u.send(JSON.stringify({jsonrpc:"2.0",id:null,method:"net_version",params:[]}))}catch(e){a(e)}},request(e){let{body:t}=e;if(u.readyState===u.CLOSED||u.readyState===u.CLOSING)throw new n.WebSocketRequestError({body:t,url:u.url,cause:new n.SocketClosedError({url:u.url})});return u.send(JSON.stringify(t))}})},keepAlive:a,reconnect:o,url:t})}},830510,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.rpc=void 0,r.getSocket=a;let n=e.r(237303),i=e.r(105960);async function a(e){let t=await (0,i.getWebSocketRpcClient)(e);return Object.assign(t.socket,{requests:t.requests,subscriptions:t.subscriptions})}r.rpc={http:(e,t)=>(0,n.getHttpRpcClient)(e).request(t),webSocket:function(e,t){let{body:r,onError:n,onResponse:i}=t;return e.request({body:r,onError:n,onResponse:i}),e},webSocketAsync:async function(e,t){let{body:r,timeout:n=1e4}=t;return e.requestAsync({body:r,timeout:n})}}},990127,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.presignMessagePrefix=void 0,r.presignMessagePrefix="\x19Ethereum Signed Message:\n"},145046,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toPrefixedMessage=function(e){let t="string"==typeof e?(0,o.stringToHex)(e):"string"==typeof e.raw?e.raw:(0,o.bytesToHex)(e.raw),r=(0,o.stringToHex)(`${n.presignMessagePrefix}${(0,a.size)(t)}`);return(0,i.concat)([r,t])};let n=e.r(990127),i=e.r(985269),a=e.r(484550),o=e.r(850815)},349779,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.hashMessage=function(e,t){return(0,n.keccak256)((0,i.toPrefixedMessage)(e),t)};let n=e.r(585457),i=e.r(145046)},653895,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.InvalidStructTypeError=r.InvalidPrimaryTypeError=r.InvalidDomainError=void 0;let n=e.r(905241),i=e.r(91633);class a extends i.BaseError{constructor({domain:e}){super(`Invalid domain "${(0,n.stringify)(e)}".`,{metaMessages:["Must be a valid EIP-712 domain."]})}}r.InvalidDomainError=a;class o extends i.BaseError{constructor({primaryType:e,types:t}){super(`Invalid primary type \`${e}\` must be one of \`${JSON.stringify(Object.keys(t))}\`.`,{docsPath:"/api/glossary/Errors#typeddatainvalidprimarytypeerror",metaMessages:["Check that the primary type is a key in `types`."]})}}r.InvalidPrimaryTypeError=o;class s extends i.BaseError{constructor({type:e}){super(`Struct type "${e}" is invalid.`,{metaMessages:["Struct type must not be a Solidity type."],name:"InvalidStructTypeError"})}}r.InvalidStructTypeError=s},976056,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeTypedData=function(e){let{domain:t,message:r,primaryType:n,types:i}=e,a=(e,t)=>{let r={...t};for(let t of e){let{name:e,type:n}=t;"address"===n&&(r[e]=r[e].toLowerCase())}return r},o=i.EIP712Domain&&t?a(i.EIP712Domain,t):{},s=(()=>{if("EIP712Domain"!==n)return a(i[n],r)})();return(0,d.stringify)({domain:o,message:s,primaryType:n,types:i})},r.validateTypedData=function(e){let{domain:t,message:r,primaryType:l,types:d}=e,f=(e,t)=>{for(let r of e){let{name:e,type:l}=r,p=t[e],h=l.match(u.integerRegex);if(h&&("number"==typeof p||"bigint"==typeof p)){let[e,t,r]=h;(0,c.numberToHex)(p,{signed:"int"===t,size:Number.parseInt(r,10)/8})}if("address"===l&&"string"==typeof p&&!(0,o.isAddress)(p))throw new i.InvalidAddressError({address:p});let m=l.match(u.bytesRegex);if(m){let[e,t]=m;if(t&&(0,s.size)(p)!==Number.parseInt(t,10))throw new n.BytesSizeMismatchError({expectedSize:Number.parseInt(t,10),givenSize:(0,s.size)(p)})}let b=d[l];b&&(function(e){if("address"===e||"bool"===e||"string"===e||e.startsWith("bytes")||e.startsWith("uint")||e.startsWith("int"))throw new a.InvalidStructTypeError({type:e})}(l),f(b,p))}};if(d.EIP712Domain&&t){if("object"!=typeof t)throw new a.InvalidDomainError({domain:t});f(d.EIP712Domain,t)}if("EIP712Domain"!==l)if(d[l])f(d[l],r);else throw new a.InvalidPrimaryTypeError({primaryType:l,types:d})},r.getTypesForEIP712Domain=f,r.domainSeparator=function(e){let{domain:t}=e;return(0,l.hashDomain)({domain:t,types:{EIP712Domain:f({domain:t})}})};let n=e.r(963101),i=e.r(224276),a=e.r(653895),o=e.r(429625),s=e.r(4845
3150),c=e.r(850815),u=e.r(142433),l=e.r(102155),d=e.r(905241);function f(e){let{domain:t}=e;return["string"==typeof t?.name&&{name:"name",type:"string"},t?.version&&{name:"version",type:"string"},("number"==typeof t?.chainId||"bigint"==typeof t?.chainId)&&{name:"chainId",type:"uint256"},t?.verifyingContract&&{name:"verifyingContract",type:"address"},t?.salt&&{name:"salt",type:"bytes32"}].filter(Boolean)}},102155,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.hashTypedData=function(e){let{domain:t={},message:r,primaryType:n}=e,a={EIP712Domain:(0,s.getTypesForEIP712Domain)({domain:t}),...e.types};(0,s.validateTypedData)({domain:t,message:r,primaryType:n,types:a});let l=["0x1901"];return t&&l.push(c({domain:t,types:a})),"EIP712Domain"!==n&&l.push(u({data:r,primaryType:n,types:a})),(0,o.keccak256)((0,i.concat)(l))},r.hashDomain=c,r.hashStruct=u,r.encodeType=l;let n=e.r(440747),i=e.r(985269),a=e.r(850815),o=e.r(585457),s=e.r(976056);function c(e){let{domain:t,types:r}=e;return u({data:t,primaryType:"EIP712Domain",types:r})}function u(e){let{data:t,primaryType:r,types:i}=e,s=function e(t){let{data:r,primaryType:i,types:s}=t,c=[{type:"bytes32"}],u=[function(e){let{primaryType:t,types:r}=e,n=(0,a.toHex)(l({primaryType:t,types:r}));return(0,o.keccak256)(n)}({primaryType:i,types:s})];for(let t of s[i]){let[i,l]=function t(r){let{types:i,name:s,type:c,value:u}=r;if(void 0!==i[c])return[{type:"bytes32"},(0,o.keccak256)(e({data:u,primaryType:c,types:i}))];if("bytes"===c)return[{type:"bytes32"},(0,o.keccak256)(u)];if("string"===c)return[{type:"bytes32"},(0,o.keccak256)((0,a.toHex)(u))];if(c.lastIndexOf("]")===c.length-1){let e=c.slice(0,c.lastIndexOf("[")),r=u.map(r=>t({name:s,type:e,types:i,value:r}));return[{type:"bytes32"},(0,o.keccak256)((0,n.encodeAbiParameters)(r.map(e=>{let[t]=e;return t}),r.map(e=>{let[,t]=e;return t})))]}return[{type:c},u]}({types:s,name:t.name,type:t.type,value:r[t.name]});c.push(i),u.push(l)}return(0,n.encodeAbiParameters)(c,u)}({data:t,primaryType:r,types:i});return(0,o.keccak256)(s)}function l(e){let{primaryType:t,types:r}=e,n="",i=function e(t){let{primaryType:r,types:n}=t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:new Set,a=r.match(/^\w*/u),o=a?.[0];if(i.has(o)||void 0===n[o])return i;for(let t of(i.add(o),n[o]))e({primaryType:t.type,types:n},i);return i}({primaryType:t,types:r});for(let e of(i.delete(t),[t,...Array.from(i).sort()]))n+=`${e}(${r[e].map(e=>{let{name:t,type:r}=e;return`${r} ${t}`}).join(",")})`;return n}},400282,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.zeroHash=r.erc6492MagicBytes=void 0,r.erc6492MagicBytes="0x6492649264926492649264926492649264926492649264926492649264926492",r.zeroHash="0x0000000000000000000000000000000000000000000000000000000000000000"},284741,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.isErc6492Signature=function(e){return(0,i.sliceHex)(e,-32)===n.erc6492MagicBytes};let n=e.r(400282),i=e.r(952195)},64332,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.LruMap=void 0;class n extends Map{constructor(e){super(),Object.defineProperty(this,"maxSize",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.maxSize=e}get(e){let t=super.get(e);return super.has(e)&&void 0!==t&&(this.delete(e),super.set(e,t)),t}set(e,t){if(super.set(e,t),this.maxSize&&this.size>this.maxSize){let e=this.keys().next().value;e&&this.delete(e)}return this}}r.LruMap=n},648350,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.checksum=void 0,r.clear=function(){for(let e of Object.values(n))e.clear()};let n={checksum:new(e.r(64332)).LruMap(8192)};r.checksum=n.checksum},436824,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.recoverPublicKey=s;let n=e.r(528137),i=e.r(484550),a=e.r(723223),o=e.r(850815);async function s(t){let{hash:r,signature:s}=t,u=(0,n.isHex)(r)?r:(0,o.toHex)(r),{secp256k1:l}=await Promise.resolve().then(()=>e.r(759854)),d=(()=>{if("object"==typeof s&&"r"in s&&"s"in s){let{r:e,s:t,v:r,yParity:n}=s,i=c(Number(n??r));return new l.Signature((0,a.hexToBigInt)(e),(0,a.hexToBigInt)(t)).addRecoveryBit(i)}let e=(0,n.isHex)(s)?s:(0,o.toHex)(s);if(65!==(0,i.size)(e))throw Error("invalid signature length");let t=c((0,a.hexToNumber)(`0x${e.slice(130)}`));return l.Signature.fromCompact(e.substring(2,130)).addRecoveryBit(t)}
31)().recoverPublicKey(u.substring(2)).toHex(!1);return`0x${d}`}function c(e){if(0===e||1===e)return e;if(27===e)return 0;if(28===e)return 1;throw Error("Invalid yParityOrV value")}},935083,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.recoverAddress=a;let n=e.r(741867),i=e.r(436824);async function a(e){let{hash:t,signature:r}=e;return(0,n.publicKeyToAddress)(await (0,i.recoverPublicKey)({hash:t,signature:r}))}},178056,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.toRlp=s,r.bytesToRlp=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"bytes";return s(e,t)},r.hexToRlp=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"hex";return s(e,t)};let n=e.r(91633),i=e.r(925294),a=e.r(935603),o=e.r(850815);function s(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"hex",r=function e(t){var r,n;let i,o,s,u;return Array.isArray(t)?(o=c(i=(r=t.map(t=>e(t))).reduce((e,t)=>e+t.length,0)),{length:i<=55?1+i:1+o+i,encode(e){for(let{encode:t}of(i<=55?e.pushByte(192+i):(e.pushByte(247+o),1===o?e.pushUint8(i):2===o?e.pushUint16(i):3===o?e.pushUint24(i):e.pushUint32(i)),r))t(e)}}):(u=c((s="string"==typeof(n=t)?(0,a.hexToBytes)(n):n).length),{length:1===s.length&&s[0]<128?1:s.length<=55?1+s.length:1+u+s.length,encode(e){1===s.length&&s[0]<128||(s.length<=55?e.pushByte(128+s.length):(e.pushByte(183+u),1===u?e.pushUint8(s.length):2===u?e.pushUint16(s.length):3===u?e.pushUint24(s.length):e.pushUint32(s.length))),e.pushBytes(s)}})}(e),n=(0,i.createCursor)(new Uint8Array(r.length));return(r.encode(n),"hex"===t)?(0,o.bytesToHex)(n.bytes):n.bytes}function c(e){if(e<256)return 1;if(e<65536)return 2;if(e<0x1000000)return 3;if(e<0x100000000)return 4;throw new n.BaseError("Length is too large.")}},486418,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.hashAuthorization=function(e){let{chainId:t,nonce:r,to:c}=e,u=e.contractAddress??e.address,l=(0,s.keccak256)((0,n.concatHex)(["0x05",(0,o.toRlp)([t?(0,a.numberToHex)(t):"0x",u,r?(0,a.numberToHex)(r):"0x"])]));return"bytes"===c?(0,i.hexToBytes)(l):l};let n=e.r(985269),i=e.r(935603),a=e.r(850815),o=e.r(178056),s=e.r(585457)},271077,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.recoverAuthorizationAddress=a;let n=e.r(935083),i=e.r(486418);async function a(e){let{authorization:t,signature:r}=e;return(0,n.recoverAddress)({hash:(0,i.hashAuthorization)(t),signature:r??t})}},133591,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.EstimateGasExecutionError=void 0;let n=e.r(65942),i=e.r(42506),a=e.r(91633),o=e.r(341289);class s extends a.BaseError{constructor(e,{account:t,docsPath:r,chain:a,data:s,gas:c,gasPrice:u,maxFeePerGas:l,maxPriorityFeePerGas:d,nonce:f,to:p,value:h}){const m=(0,o.prettyPrint)({from:t?.address,to:p,value:void 0!==h&&`${(0,n.formatEther)(h)} ${a?.nativeCurrency?.symbol||"ETH"}`,data:s,gas:c,gasPrice:void 0!==u&&`${(0,i.formatGwei)(u)} gwei`,maxFeePerGas:void 0!==l&&`${(0,i.formatGwei)(l)} gwei`,maxPriorityFeePerGas:void 0!==d&&`${(0,i.formatGwei)(d)} gwei`,nonce:f});super(e.shortMessage,{cause:e,docsPath:r,metaMessages:[...e.metaMessages?[...e.metaMessages," "]:[],"Estimate Gas Arguments:",m].filter(Boolean),name:"EstimateGasExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=e}}r.EstimateGasExecutionError=s},659641,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.UnknownNodeError=r.TipAboveFeeCapError=r.TransactionTypeNotSupportedError=r.IntrinsicGasTooLowError=r.IntrinsicGasTooHighError=r.InsufficientFundsError=r.NonceMaxValueError=r.NonceTooLowError=r.NonceTooHighError=r.FeeCapTooLowError=r.FeeCapTooHighError=r.ExecutionRevertedError=void 0;let n=e.r(42506),i=e.r(91633);class a extends i.BaseError{constructor({cause:e,message:t}={}){const r=t?.replace("execution reverted: ","")?.replace("execution reverted","");super(`Execution reverted ${r?`with reason: ${r}`:"for an unknown reason"}.`,{cause:e,name:"ExecutionRevertedError"})}}r.ExecutionRevertedError=a,Object.defineProperty(a,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(a,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted|gas required exceeds allowance/});class o extends i.BaseError{constructor({cause:e,maxFeePerGas:t}={}){super(`The fee cap (\`maxFeePerGas\`${t?` = ${(0,n.formatGwei)(t)} gwei`:""}) cannot be higher than the maximum allowed value (2^256-1).`,{cause:e,name:"FeeCapTooHighError"})}}r.FeeCapTooHighError=o,Object.defineProperty(o,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/});class s extends i.BaseError{constructor({cause:e,maxFeePerGas:t}={}){super(`The fee cap (\`maxFeePerGas\`${t?` = ${(0,n.formatGwei)(t)}`:""} gwei) cannot be lower than the block base fee.`,{cause:e,name:"FeeCapTooLowError"})}}r.FeeCapTooLowError=s,Object.defineProperty(s,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas less than block base fee|fee cap less than block base fee|transaction is outdated/});class c extends i.BaseError{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}is higher than the next one expected.`,{cause:e,name:"NonceTooHighError"})}}r.NonceTooHighError=c,Object.defineProperty(c,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/});class u extends i.BaseError{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}is lower than the current nonce of the account.
32Try increasing the nonce or find the latest nonce with \`getTransactionCount\`.`,{cause:e,name:"NonceTooLowError"})}}r.NonceTooLowError=u,Object.defineProperty(u,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too low|transaction already imported|already known/});class l extends i.BaseError{constructor({cause:e,nonce:t}={}){super(`Nonce provided for the transaction ${t?`(${t}) `:""}exceeds the maximum allowed nonce.`,{cause:e,name:"NonceMaxValueError"})}}r.NonceMaxValueError=l,Object.defineProperty(l,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce has max value/});class d extends i.BaseError{constructor({cause:e}={}){super("The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account.",{cause:e,metaMessages:["This error could arise when the account does not have enough funds to:"," - pay for the total gas fee,"," - pay for the value to send."," ","The cost of the transaction is calculated as `gas * gas fee + value`, where:"," - `gas` is the amount of gas needed for transaction to execute,"," - `gas fee` is the gas fee,"," - `value` is the amount of ether to send to the recipient."],name:"InsufficientFundsError"})}}r.InsufficientFundsError=d,Object.defineProperty(d,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds|exceeds transaction sender account balance/});class f extends i.BaseError{constructor({cause:e,gas:t}={}){super(`The amount of gas ${t?`(${t}) `:""}provided for the transaction exceeds the limit allowed for the block.`,{cause:e,name:"IntrinsicGasTooHighError"})}}r.IntrinsicGasTooHighError=f,Object.defineProperty(f,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/});class p extends i.BaseError{constructor({cause:e,gas:t}={}){super(`The amount of gas ${t?`(${t}) `:""}provided for the transaction is too low.`,{cause:e,name:"IntrinsicGasTooLowError"})}}r.IntrinsicGasTooLowError=p,Object.defineProperty(p,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too low/});class h extends i.BaseError{constructor({cause:e}){super("The transaction type is not supported for this chain.",{cause:e,name:"TransactionTypeNotSupportedError"})}}r.TransactionTypeNotSupportedError=h,Object.defineProperty(h,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/});class m extends i.BaseError{constructor({cause:e,maxPriorityFeePerGas:t,maxFeePerGas:r}={}){super(`The provided tip (\`maxPriorityFeePerGas\`${t?` = ${(0,n.formatGwei)(t)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${r?` = ${(0,n.formatGwei)(r)} gwei`:""}).`,{cause:e,name:"TipAboveFeeCapError"})}}r.TipAboveFeeCapError=m,Object.defineProperty(m,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max priority fee per gas higher than max fee per gas|tip higher than fee cap/});class b extends i.BaseError{constructor({cause:e}){super(`An error occurred while executing: ${e?.shortMessage}`,{cause:e,name:"UnknownNodeError"})}}r.UnknownNodeError=b},255397,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.containsNodeError=function(e){return e instanceof o.TransactionRejectedRpcError||e instanceof o.InvalidInputRpcError||e instanceof a.RpcRequestError&&e.code===i.ExecutionRevertedError.code},r.getNodeError=function(e,t){let r=(e.details||"").toLowerCase(),a=e instanceof n.BaseError?e.walk(e=>e?.code===i.ExecutionRevertedError.code):e;return a instanceof n.BaseError?new i.ExecutionRevertedError({cause:e,message:a.details}):i.ExecutionRevertedError.nodeMessage.test(r)?new i.ExecutionRevertedError({cause:e,message:e.details}):i.FeeCapTooHighError.nodeMessage.test(r)?new i.FeeCapTooHighError({cause:e,maxFeePerGas:t?.maxFeePerGas}):i.FeeCapTooLowError.nodeMessage.test(r)?new i.FeeCapTooLowError({cause:e,maxFeePerGas:t?.maxFeePerGas}):i.NonceTooHighError.nodeMessage.test(r)?new i.NonceTooHighError({cause:e,nonce:t?.nonce}):i.NonceTooLowError.nodeMessage.test(r)?new i.NonceTooLowError({cause:e,nonce:t?.nonce}):i.NonceMaxValueError.nodeMessage.test(r)?new i.NonceMaxValueError({cause:e,nonce:t?.nonce}):i.InsufficientFundsError.nodeMessage.test(r)?new i.InsufficientFundsError({cause:e}):i.IntrinsicGasTooHighError.nodeMessage.test(r)?new i.IntrinsicGasTooHighError({cause:e,gas:t?.gas}):i.IntrinsicGasTooLowError.nodeMessage.test(r)?new i.IntrinsicGasTooLowError({cause:e,gas:t?.gas}):i.TransactionTypeNotSupportedError.nodeMessage.test(r)?new i.TransactionTypeNotSupportedError({cause:e}):i.TipAboveFeeCapError.nodeMessage.test(r)?new i.TipAboveFeeCapError({cause:e,maxFeePerGas:t?.maxFeePerGas,maxPriorityFeePerGas:t?.maxPriorityFeePerGas}):new i.UnknownNodeError({cause:e})};let n=e.r(91633),i=e.r(659641),a=e.r(666442),o=e.r(477323)},379541,(e,t,r)=>{"use strict";
32Object.defineProperty(r,"__esModule",{value:!0}),r.getEstimateGasError=function(e,t){let r,{docsPath:o,...s}=t,c=(r=(0,a.getNodeError)(e,s))instanceof i.UnknownNodeError?e:r;return new n.EstimateGasExecutionError(c,{docsPath:o,...s})};let n=e.r(133591),i=e.r(659641),a=e.r(255397)},106636,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.extract=function(e,t){let{format:r}=t;if(!r)return{};let n={};return!function t(r){for(let i of Object.keys(r))i in e&&(n[i]=e[i]),r[i]&&"object"==typeof r[i]&&!Array.isArray(r[i])&&t(r[i])}(r(e||{})),n}},544995,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.defineFormatter=function(e,t){return r=>{let{exclude:n,format:i}=r;return{exclude:n,format:(e,r)=>{let a=t(e,r);if(n)for(let e of n)delete a[e];return{...a,...i(e,r)}},type:e}}}},244319,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.defineTransactionRequest=r.rpcTransactionType=void 0,r.formatTransactionRequest=a;let n=e.r(850815),i=e.r(544995);function a(e,t){let i={};return void 0!==e.authorizationList&&(i.authorizationList=e.authorizationList.map(e=>({address:e.address,r:e.r?(0,n.numberToHex)(BigInt(e.r)):e.r,s:e.s?(0,n.numberToHex)(BigInt(e.s)):e.s,chainId:(0,n.numberToHex)(e.chainId),nonce:(0,n.numberToHex)(e.nonce),...void 0!==e.yParity?{yParity:(0,n.numberToHex)(e.yParity)}:{},...void 0!==e.v&&void 0===e.yParity?{v:(0,n.numberToHex)(e.v)}:{}}))),void 0!==e.accessList&&(i.accessList=e.accessList),void 0!==e.blobVersionedHashes&&(i.blobVersionedHashes=e.blobVersionedHashes),void 0!==e.blobs&&("string"!=typeof e.blobs[0]?i.blobs=e.blobs.map(e=>(0,n.bytesToHex)(e)):i.blobs=e.blobs),void 0!==e.data&&(i.data=e.data),e.account&&(i.from=e.account.address),void 0!==e.from&&(i.from=e.from),void 0!==e.gas&&(i.gas=(0,n.numberToHex)(e.gas)),void 0!==e.gasPrice&&(i.gasPrice=(0,n.numberToHex)(e.gasPrice)),void 0!==e.maxFeePerBlobGas&&(i.maxFeePerBlobGas=(0,n.numberToHex)(e.maxFeePerBlobGas)),void 0!==e.maxFeePerGas&&(i.maxFeePerGas=(0,n.numberToHex)(e.maxFeePerGas)),void 0!==e.maxPriorityFeePerGas&&(i.maxPriorityFeePerGas=(0,n.numberToHex)(e.maxPriorityFeePerGas)),void 0!==e.nonce&&(i.nonce=(0,n.numberToHex)(e.nonce)),void 0!==e.to&&(i.to=e.to),void 0!==e.type&&(i.type=r.rpcTransactionType[e.type]),void 0!==e.value&&(i.value=(0,n.numberToHex)(e.value)),i}r.rpcTransactionType={legacy:"0x0",eip2930:"0x1",eip1559:"0x2",eip4844:"0x3",eip7702:"0x4"},r.defineTransactionRequest=(0,i.defineFormatter)("transactionRequest",a)},434467,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.serializeStateMapping=c,r.serializeAccountStateOverride=u,r.serializeStateOverride=function(e){if(!e)return;let t={};for(let{address:r,...i}of e){if(!(0,o.isAddress)(r,{strict:!1}))throw new n.InvalidAddressError({address:r});if(t[r])throw new a.AccountStateConflictError({address:r});t[r]=u(i)}return t};let n=e.r(224276),i=e.r(544609),a=e.r(779719),o=e.r(429625),s=e.r(850815);function c(e){if(e&&0!==e.length)return e.reduce((e,t)=>{let{slot:r,value:n}=t;if(66!==r.length)throw new i.InvalidBytesLengthError({size:r.length,targetSize:66,type:"hex"});if(66!==n.length)throw new i.InvalidBytesLengthError({size:n.length,targetSize:66,type:"hex"});return e[r]=n,e},{})}function u(e){let{balance:t,nonce:r,state:n,stateDiff:i,code:o}=e,u={};if(void 0!==o&&(u.code=o),void 0!==t&&(u.balance=(0,s.numberToHex)(t)),void 0!==r&&(u.nonce=(0,s.numberToHex)(r)),void 0!==n&&(u.state=c(n)),void 0!==i){if(u.state)throw new a.StateAssignmentConflictError;u.stateDiff=c(i)}return u}},627009,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.minInt144=r.minInt136=r.minInt128=r.minInt120=r.minInt112=r.minInt104=r.minInt96=r.minInt88=r.minInt80=r.minInt72=r.minInt64=r.minInt56=r.minInt48=r.minInt40=r.minInt32=r.minInt24=r.minInt16=r.minInt8=r.maxInt256=r.maxInt248=r.maxInt240=r.maxInt232=r.maxInt224=r.maxInt216=r.maxInt208=r.maxInt200=r.maxInt192=r.maxInt184=r.maxInt176=r.maxInt168=r.maxInt160=r.maxInt152=r.maxInt144=r.maxInt136=r.maxInt128=r.maxInt120=r.maxInt112=r.maxInt104=r.maxInt96=r.maxInt88=r.maxInt80=r.maxInt72=r.maxInt64=r.maxInt56=r.maxInt48=r.maxInt40=r.maxInt32=r.maxInt24=r.maxInt16=r.maxInt8=void 0,r.maxUint256=r.maxUint248=r.maxUint240=r.maxUint232=r.maxUint224=r.maxUint216=r.maxUint208=r.maxUint200=r.maxUint192=r.maxUint184=r.maxUint176=r.maxUint168=r.maxUint160=r.maxUint152=r.maxUint144=r.maxUint136=r.maxUint128=r.maxUint120=r.maxUint112=r.maxUint104=r.maxUint96=r.maxUint88=r.maxUint80=r.maxUint72=r.maxUint64=r.maxUint56=r.maxUint48=r.maxUint40=r.maxUint32=r.maxUint24=r.maxUint16=r.maxUint8=r.minInt256=r.minInt248=r.minInt240=r.minInt232=r.minInt224=r.minInt216=r.minInt208=r.minInt200=r.minInt192=r.minInt184=r.minInt176=r.minInt168=r.minInt160=r.minInt152=void 0,r.maxInt8=2n**(8n-1n)-1n,r.maxInt16=2n**(16n-1n)-1n,r.maxInt24=2n**(24n-1n)-1n,r.maxInt32=2n**(32n-1n)-1n,r.maxInt40=2n**(40n-1n)-1n,r.maxInt48=2n**(48n-1n)-1n,r.maxInt56=2n**(56n-1n)-1n,r.maxInt64=2n**(64n-1n)-1n,r.maxInt72=2n**(72n-1n)-1n,r.maxInt80=2n**(80n-1n)-1n,r.maxInt88=2n**(88n-1n)-1n,r.maxInt96=2n**(96n-1n)-1n,r.maxInt104=2n**(104n-1n)-1n,r.maxInt112=2n**(112n-1n)-1n,r.maxInt120=2n**(120n-1n)-1n,r.maxInt128=2n**(128n-1n)-1n,r.maxInt136=2n**(136n-1n)-1n,r.maxInt144=2n**(144n-1n)-1n,r.maxInt152=2n**(152n-1n)-1n,r.maxInt160=2n**(160n-1n)-1n,r.maxInt168=2n**(168
32n-1n)-1n,r.maxInt176=2n**(176n-1n)-1n,r.maxInt184=2n**(184n-1n)-1n,r.maxInt192=2n**(192n-1n)-1n,r.maxInt200=2n**(200n-1n)-1n,r.maxInt208=2n**(208n-1n)-1n,r.maxInt216=2n**(216n-1n)-1n,r.maxInt224=2n**(224n-1n)-1n,r.maxInt232=2n**(232n-1n)-1n,r.maxInt240=2n**(240n-1n)-1n,r.maxInt248=2n**(248n-1n)-1n,r.maxInt256=2n**(256n-1n)-1n,r.minInt8=-(2n**(8n-1n)),r.minInt16=-(2n**(16n-1n)),r.minInt24=-(2n**(24n-1n)),r.minInt32=-(2n**(32n-1n)),r.minInt40=-(2n**(40n-1n)),r.minInt48=-(2n**(48n-1n)),r.minInt56=-(2n**(56n-1n)),r.minInt64=-(2n**(64n-1n)),r.minInt72=-(2n**(72n-1n)),r.minInt80=-(2n**(80n-1n)),r.minInt88=-(2n**(88n-1n)),r.minInt96=-(2n**(96n-1n)),r.minInt104=-(2n**(104n-1n)),r.minInt112=-(2n**(112n-1n)),r.minInt120=-(2n**(120n-1n)),r.minInt128=-(2n**(128n-1n)),r.minInt136=-(2n**(136n-1n)),r.minInt144=-(2n**(144n-1n)),r.minInt152=-(2n**(152n-1n)),r.minInt160=-(2n**(160n-1n)),r.minInt168=-(2n**(168n-1n)),r.minInt176=-(2n**(176n-1n)),r.minInt184=-(2n**(184n-1n)),r.minInt192=-(2n**(192n-1n)),r.minInt200=-(2n**(200n-1n)),r.minInt208=-(2n**(208n-1n)),r.minInt216=-(2n**(216n-1n)),r.minInt224=-(2n**(224n-1n)),r.minInt232=-(2n**(232n-1n)),r.minInt240=-(2n**(240n-1n)),r.minInt248=-(2n**(248n-1n)),r.minInt256=-(2n**(256n-1n)),r.maxUint8=2n**8n-1n,r.maxUint16=2n**16n-1n,r.maxUint24=2n**24n-1n,r.maxUint32=2n**32n-1n,r.maxUint40=2n**40n-1n,r.maxUint48=2n**48n-1n,r.maxUint56=2n**56n-1n,r.maxUint64=2n**64n-1n,r.maxUint72=2n**72n-1n,r.maxUint80=2n**80n-1n,r.maxUint88=2n**88n-1n,r.maxUint96=2n**96n-1n,r.maxUint104=2n**104n-1n,r.maxUint112=2n**112n-1n,r.maxUint120=2n**120n-1n,r.maxUint128=2n**128n-1n,r.maxUint136=2n**136n-1n,r.maxUint144=2n**144n-1n,r.maxUint152=2n**152n-1n,r.maxUint160=2n**160n-1n,r.maxUint168=2n**168n-1n,r.maxUint176=2n**176n-1n,r.maxUint184=2n**184n-1n,r.maxUint192=2n**192n-1n,r.maxUint200=2n**200n-1n,r.maxUint208=2n**208n-1n,r.maxUint216=2n**216n-1n,r.maxUint224=2n**224n-1n,r.maxUint232=2n**232n-1n,r.maxUint240=2n**240n-1n,r.maxUint248=2n**248n-1n,r.maxUint256=2n**256n-1n},854495,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.assertRequest=function(e){let{account:t,maxFeePerGas:r,maxPriorityFeePerGas:c,to:u}=e,l=t?(0,n.parseAccount)(t):void 0;if(l&&!(0,s.isAddress)(l.address))throw new a.InvalidAddressError({address:l.address});if(u&&!(0,s.isAddress)(u))throw new a.InvalidAddressError({address:u});if(r&&r>i.maxUint256)throw new o.FeeCapTooHighError({maxFeePerGas:r});if(c&&r&&c>r)throw new o.TipAboveFeeCapError({maxFeePerGas:r,maxPriorityFeePerGas:c})};let n=e.r(155401),i=e.r(627009),a=e.r(224276),o=e.r(659641),s=e.r(429625)},615144,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.MaxFeePerGasTooLowError=r.Eip1559FeesNotSupportedError=r.BaseFeeScalarError=void 0;let n=e.r(42506),i=e.r(91633);class a extends i.BaseError{constructor(){super("`baseFeeMultiplier` must be greater than 1.",{name:"BaseFeeScalarError"})}}r.BaseFeeScalarError=a;class o extends i.BaseError{constructor(){super("Chain does not support EIP-1559 fees.",{name:"Eip1559FeesNotSupportedError"})}}r.Eip1559FeesNotSupportedError=o;class s extends i.BaseError{constructor({maxPriorityFeePerGas:e}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${(0,n.formatGwei)(e)} gwei).`,{name:"MaxFeePerGasTooLowError"})}}r.MaxFeePerGasTooLowError=s},201648,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.BlockNotFoundError=void 0;let n=e.r(91633);class i extends n.BaseError{constructor({blockHash:e,blockNumber:t}){let r="Block";e&&(r=`Block at hash "${e}"`),t&&(r=`Block at number "${t}"`),super(`${r} could not be found.`,{name:"BlockNotFoundError"})}}r.BlockNotFoundError=i},728125,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.defineTransaction=r.transactionType=void 0,r.formatTransaction=a;let n=e.r(723223),i=e.r(544995);function a(e,t){let i={...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,chainId:e.chainId?(0,n.hexToNumber)(e.chainId):void 0,gas:e.gas?BigInt(e.gas):void 0,gasPrice:e.gasPrice?BigInt(e.gasPrice):void 0,maxFeePerBlobGas:e.maxFeePerBlobGas?BigInt(e.maxFeePerBlobGas):void 0,maxFeePerGas:e.maxFeePerGas?BigInt(e.maxFeePerGas):void 0,maxPriorityFeePerGas:e.maxPriorityFeePerGas?BigInt(e.maxPriorityFeePerGas):void 0,nonce:e.nonce?(0,n.hexToNumber)(e.nonce):void 0,to:e.to?e.to:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,type:e.type?r.transactionType[e.type]:void 0,typeHex:e.type?e.type:void 0,value:e.value?BigInt(e.value):void 0,v:e.v?BigInt(e.v):void 0};return e.authorizationList&&(i.authorizationList=e.authorizationList.map(e=>({address:e.address,chainId:Number(e.chainId),nonce:Number(e.nonce),r:e.r,s:e.s,yParity:Number(e.yParity)}))),i.yParity=(()=>
32{if(e.yParity)return Number(e.yParity);if("bigint"==typeof i.v){if(0n===i.v||27n===i.v)return 0;if(1n===i.v||28n===i.v)return 1;if(i.v>=35n)return+(i.v%2n===0n)}})(),"legacy"===i.type&&(delete i.accessList,delete i.maxFeePerBlobGas,delete i.maxFeePerGas,delete i.maxPriorityFeePerGas,delete i.yParity),"eip2930"===i.type&&(delete i.maxFeePerBlobGas,delete i.maxFeePerGas,delete i.maxPriorityFeePerGas),"eip1559"===i.type&&delete i.maxFeePerBlobGas,i}r.transactionType={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559","0x3":"eip4844","0x4":"eip7702"},r.defineTransaction=(0,i.defineFormatter)("transaction",a)},288053,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.defineBlock=void 0,r.formatBlock=a;let n=e.r(544995),i=e.r(728125);function a(e,t){let r=(e.transactions??[]).map(e=>"string"==typeof e?e:(0,i.formatTransaction)(e));return{...e,baseFeePerGas:e.baseFeePerGas?BigInt(e.baseFeePerGas):null,blobGasUsed:e.blobGasUsed?BigInt(e.blobGasUsed):void 0,difficulty:e.difficulty?BigInt(e.difficulty):void 0,excessBlobGas:e.excessBlobGas?BigInt(e.excessBlobGas):void 0,gasLimit:e.gasLimit?BigInt(e.gasLimit):void 0,gasUsed:e.gasUsed?BigInt(e.gasUsed):void 0,hash:e.hash?e.hash:null,logsBloom:e.logsBloom?e.logsBloom:null,nonce:e.nonce?e.nonce:null,number:e.number?BigInt(e.number):null,size:e.size?BigInt(e.size):void 0,timestamp:e.timestamp?BigInt(e.timestamp):void 0,transactions:r,totalDifficulty:e.totalDifficulty?BigInt(e.totalDifficulty):null}}r.defineBlock=(0,n.defineFormatter)("block",a)},578346,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.getBlock=o;let n=e.r(201648),i=e.r(850815),a=e.r(288053);async function o(e){let{blockHash:t,blockNumber:r,blockTag:o=e.experimental_blockTag??"latest",includeTransactions:s}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},c=s??!1,u=void 0!==r?(0,i.numberToHex)(r):void 0,l=null;if(!(l=t?await e.request({method:"eth_getBlockByHash",params:[t,c]},{dedupe:!0}):await e.request({method:"eth_getBlockByNumber",params:[u||o,c]},{dedupe:!!u})))throw new n.BlockNotFoundError({blockHash:t,blockNumber:r});return(e.chain?.formatters?.block?.format||a.formatBlock)(l,"getBlock")}},679790,(e,t,r)=>{"use strict";async function n(e){return BigInt(await e.request({method:"eth_gasPrice"}))}Object.defineProperty(r,"__esModule",{value:!0}),r.getGasPrice=n},870256,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.estimateMaxPriorityFeePerGas=c,r.internal_estimateMaxPriorityFeePerGas=u;let n=e.r(615144),i=e.r(723223),a=e.r(388012),o=e.r(578346),s=e.r(679790);async function c(e,t){return u(e,t)}async function u(e,t){let{block:r,chain:c=e.chain,request:u}=t||{};try{let t=c?.fees?.maxPriorityFeePerGas??c?.fees?.defaultPriorityFee;if("function"==typeof t){let n=r||await (0,a.getAction)(e,o.getBlock,"getBlock")({}),i=await t({block:n,client:e,request:u});if(null===i)throw Error();return i}if(void 0!==t)return t;let n=await e.request({method:"eth_maxPriorityFeePerGas"});return(0,i.hexToBigInt)(n)}catch{let[t,i]=await Promise.all([r?Promise.resolve(r):(0,a.getAction)(e,o.getBlock,"getBlock")({}),(0,a.getAction)(e,s.getGasPrice,"getGasPrice")({})]);if("bigint"!=typeof t.baseFeePerGas)throw new n.Eip1559FeesNotSupportedError;let c=i-t.baseFeePerGas;if(c<0n)return 0n;return c}}},965094,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.estimateFeesPerGas=c,r.internal_estimateFeesPerGas=u;let n=e.r(615144),i=e.r(388012),a=e.r(870256),o=e.r(578346),s=e.r(679790);async function c(e,t){return u(e,t)}async function u(e,t){let{block:r,chain:c=e.chain,request:u,type:l="eip1559"}=t||{},d=await (async()=>"function"==typeof c?.fees?.baseFeeMultiplier?c.fees.baseFeeMultiplier({block:r,client:e,request:u}):c?.fees?.baseFeeMultiplier??1.2)();if(d<1)throw new n.BaseFeeScalarError;let f=d.toString().split(".")[1]?.length??0,p=10**f,h=e=>e*BigInt(Math.ceil(d*p))/BigInt(p),m=r||await (0,i.getAction)(e,o.getBlock,"getBlock")({});if("function"==typeof c?.fees?.estimateFeesPerGas){let t=await c.fees.estimateFeesPerGas({block:r,client:e,multiply:h,request:u,type:l});if(null!==t)return t}if("eip1559"===l){if("bigint"!=typeof m.baseFeePerGas)throw new n.Eip1559FeesNotSupportedError;let t="bigint"==typeof u?.maxPriorityFeePerGas?u.maxPriorityFeePerGas:await (0,a.internal_estimateMaxPriorityFeePerGas)(e,{block:m,chain:c,request:u}),r=h(m.baseFeePerGas);return{maxFeePerGas:u?.maxFeePerGas??r+t,maxPriorityFeePerGas:t}}return{gasPrice:u?.gasPrice??h(await (0,i.getAction)(e,s.getGasPrice,"getGasPrice")({}))}}},114488,(e,t,r)=>{"use strict";
32Object.defineProperty(r,"__esModule",{value:!0}),r.getTransactionCount=a;let n=e.r(723223),i=e.r(850815);async function a(e,t){let{address:r,blockTag:a="latest",blockNumber:o}=t,s=await e.request({method:"eth_getTransactionCount",params:[r,"bigint"==typeof o?(0,i.numberToHex)(o):a]},{dedupe:!!o});return(0,n.hexToNumber)(s)}},830588,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.blobsToCommitments=function(e){let{kzg:t}=e,r=e.to??("string"==typeof e.blobs[0]?"hex":"bytes"),a="string"==typeof e.blobs[0]?e.blobs.map(e=>(0,n.hexToBytes)(e)):e.blobs,o=[];for(let e of a)o.push(Uint8Array.from(t.blobToKzgCommitment(e)));return"bytes"===r?o:o.map(e=>(0,i.bytesToHex)(e))};let n=e.r(935603),i=e.r(850815)},764012,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.blobsToProofs=function(e){let{kzg:t}=e,r=e.to??("string"==typeof e.blobs[0]?"hex":"bytes"),a="string"==typeof e.blobs[0]?e.blobs.map(e=>(0,n.hexToBytes)(e)):e.blobs,o="string"==typeof e.commitments[0]?e.commitments.map(e=>(0,n.hexToBytes)(e)):e.commitments,s=[];for(let e=0;e<a.length;e++){let r=a[e],n=o[e];s.push(Uint8Array.from(t.computeBlobKzgProof(r,n)))}return"bytes"===r?s:s.map(e=>(0,i.bytesToHex)(e))};let n=e.r(935603),i=e.r(850815)}]);
33
34//# debugId=1ed872c6-958c-af54-16a6-8127c0d2b569

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.