|
| 1 | +"use strict"; |
| 2 | +var __defProp = Object.defineProperty; |
| 3 | +var __getOwnPropDesc = Object.getOwnPropertyDescriptor; |
| 4 | +var __getOwnPropNames = Object.getOwnPropertyNames; |
| 5 | +var __hasOwnProp = Object.prototype.hasOwnProperty; |
| 6 | +var __export = (target, all) => { |
| 7 | + for (var name in all) |
| 8 | + __defProp(target, name, { get: all[name], enumerable: true }); |
| 9 | +}; |
| 10 | +var __copyProps = (to, from, except, desc) => { |
| 11 | + if (from && typeof from === "object" || typeof from === "function") { |
| 12 | + for (let key of __getOwnPropNames(from)) |
| 13 | + if (!__hasOwnProp.call(to, key) && key !== except) |
| 14 | + __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); |
| 15 | + } |
| 16 | + return to; |
| 17 | +}; |
| 18 | +var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); |
| 19 | + |
| 20 | +// src/constants.ts |
| 21 | +var constants_exports = {}; |
| 22 | +__export(constants_exports, { |
| 23 | + ANS_CHAINS: () => ANS_CHAINS, |
| 24 | + ANS_EXPLORER_URLS: () => ANS_EXPLORER_URLS, |
| 25 | + ANS_REGISTRY_ABI: () => ANS_REGISTRY_ABI, |
| 26 | + ANS_REGISTRY_ADDRESSES: () => ANS_REGISTRY_ADDRESSES, |
| 27 | + ANS_RESOLVER_ABI: () => ANS_RESOLVER_ABI, |
| 28 | + ANS_RPC_URLS: () => ANS_RPC_URLS, |
| 29 | + ANS_SUPPORTED_CHAIN_IDS: () => ANS_SUPPORTED_CHAIN_IDS, |
| 30 | + ANS_USDC_ADDRESSES: () => ANS_USDC_ADDRESSES, |
| 31 | + USDC_ERC20_ABI: () => USDC_ERC20_ABI |
| 32 | +}); |
| 33 | +module.exports = __toCommonJS(constants_exports); |
| 34 | +var ANS_REGISTRY_ABI = [ |
| 35 | + "function resolve(string rawLabel) view returns (address)", |
| 36 | + "function reverseResolve(address wallet) view returns (string)", |
| 37 | + "function isAvailable(string rawLabel) view returns (bool)", |
| 38 | + "function getRecord(string rawLabel) view returns (address owner, address resolvedAddress, uint64 expiry, bool expired, bool reserved)", |
| 39 | + "function quotePrice(string rawLabel, uint256 yearsCount) view returns (uint256)", |
| 40 | + "function getOwnedLabels(address wallet) view returns (string[] memory)", |
| 41 | + "function commitRevealRequired() view returns (bool)", |
| 42 | + "function register(string rawLabel, address resolvedAddress)", |
| 43 | + "function submitCommitment(bytes32 commitment)", |
| 44 | + "function registerWithCommit(string rawLabel, address resolvedAddress, bytes32 salt)", |
| 45 | + "function computeCommitment(address registrant, string rawLabel, bytes32 salt) view returns (bytes32)", |
| 46 | + "function renew(string rawLabel)", |
| 47 | + "function release(string rawLabel)", |
| 48 | + "function updateResolvedAddress(string rawLabel, address newAddress)", |
| 49 | + "function transferName(string rawLabel, address newOwner)", |
| 50 | + "function setPrimaryName(string rawLabel)" |
| 51 | +]; |
| 52 | +var ANS_RESOLVER_ABI = [ |
| 53 | + "function resolve(string rawLabel) view returns (address)", |
| 54 | + "function reverseResolve(address wallet) view returns (string)", |
| 55 | + "function isAvailable(string rawLabel) view returns (bool)", |
| 56 | + "function getRecord(string rawLabel) view returns (address owner, address resolvedAddress, uint64 expiry, bool expired, bool reserved)", |
| 57 | + "function quotePrice(string rawLabel, uint256 yearsCount) view returns (uint256)", |
| 58 | + "function getOwnedLabels(address wallet) view returns (string[] memory)" |
| 59 | +]; |
| 60 | +var USDC_ERC20_ABI = [ |
| 61 | + "function allowance(address owner, address spender) view returns (uint256)", |
| 62 | + "function approve(address spender, uint256 amount) returns (bool)", |
| 63 | + "function balanceOf(address owner) view returns (uint256)" |
| 64 | +]; |
| 65 | +var ANS_REGISTRY_ADDRESSES = { |
| 66 | + 5042002: "0xf5e0E328119D16c75Fb4a001282a3a7b733EF6db" |
| 67 | + // Arc Testnet |
| 68 | +}; |
| 69 | +var ANS_USDC_ADDRESSES = { |
| 70 | + 5042002: "0x3600000000000000000000000000000000000000" |
| 71 | + // Arc Testnet |
| 72 | +}; |
| 73 | +var ANS_SUPPORTED_CHAIN_IDS = [5042002]; |
| 74 | +var ANS_RPC_URLS = { |
| 75 | + 5042002: "https://rpc.testnet.arc.network" |
| 76 | +}; |
| 77 | +var ANS_EXPLORER_URLS = { |
| 78 | + 5042002: "https://testnet.arcscan.app" |
| 79 | +}; |
| 80 | +var ANS_CHAINS = { |
| 81 | + 5042002: { |
| 82 | + name: "Arc Testnet", |
| 83 | + chainIdHex: "0x4CEE32", |
| 84 | + nativeCurrency: { name: "USDC", symbol: "USDC", decimals: 18 } |
| 85 | + } |
| 86 | +}; |
| 87 | +// Annotate the CommonJS export names for ESM import in node: |
| 88 | +0 && (module.exports = { |
| 89 | + ANS_CHAINS, |
| 90 | + ANS_EXPLORER_URLS, |
| 91 | + ANS_REGISTRY_ABI, |
| 92 | + ANS_REGISTRY_ADDRESSES, |
| 93 | + ANS_RESOLVER_ABI, |
| 94 | + ANS_RPC_URLS, |
| 95 | + ANS_SUPPORTED_CHAIN_IDS, |
| 96 | + ANS_USDC_ADDRESSES, |
| 97 | + USDC_ERC20_ABI |
| 98 | +}); |
0 commit comments