├── .env
├── .eslintrc.json
├── .gitignore
├── .husky
└── pre-commit
├── .prettierrc
├── README.md
├── components
├── Account
│ ├── AccountSummary.js
│ ├── DexOrdersData.js
│ ├── Did.js
│ ├── EscrowData.js
│ ├── IOUData.js
│ ├── LedgerData.js
│ ├── NFTokenData.js
│ ├── ObjectsData.js
│ ├── PublicData.js
│ ├── RelatedLinks.js
│ ├── URITokenData.js
│ ├── XahauRewardTr.js
│ └── XamanData.js
├── Admin
│ ├── BillingCountry.js
│ └── subscriptions
│ │ ├── Api.js
│ │ ├── BithompPro.js
│ │ └── pro
│ │ └── history
│ │ └── TypeToIcon.js
├── Faucet.js
├── Home
│ ├── Converter.js
│ ├── PriceChart.js
│ ├── Products.js
│ ├── Statistics.js
│ └── Whales.js
├── Layout
│ ├── Ads.js
│ ├── BackgroundImage.js
│ ├── ButtonScrollTop.js
│ ├── CookieMessage.js
│ ├── FiltersFrame.js
│ ├── Footer.js
│ ├── Header
│ │ ├── CurrencyTable.js
│ │ ├── LangTable.js
│ │ ├── MobileMenu.js
│ │ ├── NetworkTable.js
│ │ ├── ProgressBar.js
│ │ ├── Switch.js
│ │ └── index.js
│ ├── InfiniteScrolling.js
│ ├── LeftFilters.js
│ ├── LogoAnimated.js
│ ├── LogoSmall.js
│ ├── ScrollToTop.js
│ ├── SearchBlock.js
│ ├── SocialIcons.js
│ ├── ThemeContext.js
│ └── TopLinks.js
├── ListTransactions.js
├── Nft
│ ├── EvernodeLease.js
│ ├── EvernodeRegistartion.js
│ └── ProjectMetadata.js
├── NftImageOrVideo.js
├── NftPreview.js
├── NftsComponent.js
├── Receipt.js
├── SEO.js
├── Services
│ └── NftMint
│ │ ├── NFTokenMint.js
│ │ └── URITokenMint.js
├── SignForm.js
├── SignForms
│ ├── NFTokenCreateOffer.js
│ ├── NftTransfer.js
│ ├── SetAvatar.js
│ ├── SetDid.js
│ └── SetDomain.js
├── SimpleChart.js
├── SocialShare.js
├── Table.js
├── Tabs
│ ├── AdminTabs.js
│ ├── NetworkPagesTabs.js
│ ├── NetworkTabs.js
│ ├── NftTabs.js
│ ├── ProTabs.js
│ ├── WhaleTabs.js
│ └── index.js
├── Tiles.js
├── TopProgressBar.js
├── Transaction
│ ├── TransactionAccountDelete.js
│ ├── TransactionAccountSet.js
│ ├── TransactionAmm.js
│ ├── TransactionCard.js
│ ├── TransactionCheck.js
│ ├── TransactionDID.js
│ ├── TransactionDetails.js
│ ├── TransactionEnableAmendment.js
│ ├── TransactionEscrow.js
│ ├── TransactionImport.js
│ ├── TransactionNFToken.js
│ ├── TransactionOffer.js
│ ├── TransactionPayment
│ │ ├── DestinationTagProblemSolving.js
│ │ ├── PaymentInstructions.js
│ │ └── index.js
│ ├── TransactionRemit.js
│ ├── TransactionSetRegularKey.js
│ ├── TransactionTrustSet.js
│ ├── TransactionURIToken.js
│ └── index.js
├── UI
│ ├── AddressInput.js
│ ├── AgeCheck.js
│ ├── CheckBox.js
│ ├── CopyButton.js
│ ├── CountrySelect.js
│ ├── CountryWithFlag.js
│ ├── CurrencySelect.js
│ ├── DateAndTimeRange.js
│ ├── ExpirationSelect.js
│ ├── FormInput.js
│ ├── IssuerSelect.js
│ ├── RadioOptions.js
│ ├── SimpleSelect.js
│ ├── TargetTableSelect.js
│ └── ViewToggle.js
├── Walletconnect.js
├── WhalesTable.js
└── Xaman
│ └── Qr.js
├── instrumentation-client.js
├── instrumentation.js
├── middleware.js
├── next-i18next.config.js
├── next.config.js
├── package.json
├── pages
├── 404.js
├── [slug].js
├── _app.js
├── _document.js
├── _error.jsx
├── about-us.js
├── account
│ └── [[...id]].js
├── activations.js
├── admin
│ ├── api
│ │ ├── charts.js
│ │ ├── index.js
│ │ ├── requests.js
│ │ └── statistics.js
│ ├── bots
│ │ └── index.js
│ ├── index.js
│ ├── pro
│ │ ├── history.js
│ │ └── index.js
│ ├── subscriptions.js
│ └── watchlist.js
├── advertise.js
├── alerts.js
├── amendments.js
├── amm
│ ├── [id].js
│ └── index.js
├── amms.js
├── api
│ └── robots.js
├── blackholed-address.js
├── blacklisted-address.js
├── build-unl.js
├── customer-support.js
├── disclaimer.js
├── distribution.js
├── domains.js
├── donate.js
├── eaas.js
├── faucet.js
├── genesis.js
├── governance
│ └── [[...id]].js
├── index.js
├── jobs.js
├── last-ledger-information.js
├── ledger
│ └── [[...ledgerIndex]].js
├── manifest.json.js
├── nft-distribution
│ └── [[...id]].js
├── nft-explorer.js
├── nft-minters.js
├── nft-offer
│ └── [[...id]].js
├── nft-offers
│ └── [[...id]].js
├── nft-sales.js
├── nft-statistics.js
├── nft-volumes
│ ├── [issuer].js
│ └── index.js
├── nft
│ └── [[...id]].js
├── nfts
│ └── [[...id]].js
├── nodes.js
├── object
│ ├── [id].js
│ └── index.js
├── press.js
├── privacy-policy.js
├── rlusd.js
├── services
│ ├── check.js
│ ├── nft-mint.js
│ └── send.js
├── sitemap.xml.js
├── social-share.js
├── submit-account-information.js
├── terms-and-conditions.js
├── transaction
│ ├── [id].js
│ └── index.js
├── unl-report.js
├── username.js
├── validators.js
├── verified-domains.js
├── whales
│ ├── fee.js
│ ├── index.js
│ ├── receivers.js
│ ├── senders.js
│ └── submitters.js
├── xrp-xah-taxes.js
└── xrpl-article.js
├── postcss.config.mjs
├── public
├── download
│ └── bithomp-press.zip
├── favicon.ico
├── images
│ ├── advertise
│ │ ├── home-page-banner.png
│ │ ├── new-pages-header.png
│ │ └── old-pages-footer.png
│ ├── chart
│ │ ├── panning.svg
│ │ ├── zoom-in.svg
│ │ ├── zoom-out.svg
│ │ └── zoom.svg
│ ├── checkmark.svg
│ ├── currencies
│ │ ├── xah.png
│ │ └── xrp.svg
│ ├── donate.png
│ ├── download.svg
│ ├── flags
│ │ ├── ae.svg
│ │ ├── ar.svg
│ │ ├── au.svg
│ │ ├── bd.svg
│ │ ├── bh.svg
│ │ ├── br.svg
│ │ ├── ca.svg
│ │ ├── ch.svg
│ │ ├── cl.svg
│ │ ├── cn.svg
│ │ ├── cz.svg
│ │ ├── dk.svg
│ │ ├── eu.svg
│ │ ├── gb.svg
│ │ ├── hk.svg
│ │ ├── hu.svg
│ │ ├── id.svg
│ │ ├── il.svg
│ │ ├── in.svg
│ │ ├── jp.svg
│ │ ├── kr.png
│ │ ├── kw.svg
│ │ ├── mx.svg
│ │ ├── my.svg
│ │ ├── ng.svg
│ │ ├── no.svg
│ │ ├── nz.svg
│ │ ├── ph.svg
│ │ ├── pl.svg
│ │ ├── ru.svg
│ │ ├── sa.svg
│ │ ├── se.svg
│ │ ├── sg.svg
│ │ ├── th.svg
│ │ ├── tr.svg
│ │ ├── tw.svg
│ │ ├── ua.svg
│ │ ├── us.svg
│ │ ├── vn.svg
│ │ └── za.svg
│ ├── fraud-alert.png
│ ├── link.svg
│ ├── loading.gif
│ ├── logo-small.svg
│ ├── nft
│ │ ├── 18plus.jpg
│ │ └── evernode.png
│ ├── pages
│ │ ├── blackholed-picture.png
│ │ ├── blackholed-screen-xahau.png
│ │ ├── blackholed-screen.png
│ │ ├── blacklisted-picture.jpg
│ │ ├── blacklisted-screen-xahau.png
│ │ ├── blacklisted-screen.png
│ │ ├── faucet
│ │ │ └── lastLedgerIndex.png
│ │ ├── jobs.png
│ │ ├── rlusd
│ │ │ └── rocket.png
│ │ ├── verified-domains
│ │ │ ├── domains-screen.png
│ │ │ └── green-checkmark.jpg
│ │ └── xrpl-article.jpeg
│ ├── press.png
│ ├── products
│ │ ├── for-you.png
│ │ ├── network.png
│ │ ├── nft.png
│ │ └── top-lists.png
│ ├── qr.gif
│ ├── social-share
│ │ ├── instagram.svg
│ │ ├── linkedIn.svg
│ │ ├── x.svg
│ │ └── youTube.svg
│ ├── sponsored
│ │ ├── btcbit.svg
│ │ ├── doppler.svg
│ │ ├── easybit.svg
│ │ ├── moon.svg
│ │ ├── nexo.svg
│ │ └── xbit.png
│ ├── sun.svg
│ ├── verified.svg
│ ├── wallets
│ │ ├── crossmark-large.png
│ │ ├── crossmark.png
│ │ ├── ellipal-large.svg
│ │ ├── gemwallet.svg
│ │ ├── ledgerwallet-large.svg
│ │ ├── ledgerwallet.svg
│ │ ├── metamask.svg
│ │ ├── trezor-large.svg
│ │ ├── trezor.svg
│ │ ├── walletconnect-large.svg
│ │ ├── walletconnect.svg
│ │ ├── xaman-large.svg
│ │ └── xaman.png
│ ├── xahauexplorer
│ │ ├── 192.png
│ │ ├── 512.png
│ │ ├── apple-touch-icon.png
│ │ ├── favicon.ico
│ │ ├── long.svg
│ │ ├── longDark.svg
│ │ ├── previews
│ │ │ ├── 1200x630
│ │ │ │ ├── alerts.png
│ │ │ │ ├── amendments.png
│ │ │ │ ├── distribution.png
│ │ │ │ ├── index.png
│ │ │ │ ├── nft-explorer.png
│ │ │ │ ├── nft-sales.png
│ │ │ │ └── validators.png
│ │ │ └── 630x630
│ │ │ │ ├── alerts.png
│ │ │ │ ├── amendments.png
│ │ │ │ ├── distribution.png
│ │ │ │ ├── index.png
│ │ │ │ ├── nft-explorer.png
│ │ │ │ ├── nft-sales.png
│ │ │ │ └── validators.png
│ │ └── verified-domains
│ │ │ ├── checkmark-example-screen.png
│ │ │ └── screen-account-page.png
│ └── xrplexplorer
│ │ ├── 192.png
│ │ ├── 512.png
│ │ ├── apple-touch-icon.png
│ │ ├── favicon.ico
│ │ ├── long.svg
│ │ ├── longDark.svg
│ │ ├── previews
│ │ ├── 1200x630
│ │ │ ├── alerts.png
│ │ │ ├── amendments.png
│ │ │ ├── amms.png
│ │ │ ├── distribution.png
│ │ │ ├── index.png
│ │ │ ├── nft-explorer.png
│ │ │ ├── nft-sales.png
│ │ │ ├── nft-volumes.png
│ │ │ └── validators.png
│ │ └── 630x630
│ │ │ ├── alerts.png
│ │ │ ├── amendments.png
│ │ │ ├── amms.png
│ │ │ ├── distribution.png
│ │ │ ├── index.png
│ │ │ ├── nft-explorer.png
│ │ │ ├── nft-sales.png
│ │ │ ├── nft-volumes.png
│ │ │ └── validators.png
│ │ └── verified-domains
│ │ ├── checkmark-example-screen.png
│ │ └── screen-account-page.png
├── js
│ └── model-viewer.min.js
└── locales
│ ├── de
│ ├── activations.json
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── governance.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── unl-report.json
│ ├── username.json
│ └── validators.json
│ ├── en
│ ├── about-us.json
│ ├── account.json
│ ├── activations.json
│ ├── admin.json
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── governance.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-sort.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── unl-report.json
│ ├── username.json
│ └── validators.json
│ ├── es
│ ├── activations.json
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── governance.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── unl-report.json
│ ├── username.json
│ └── validators.json
│ ├── fr
│ ├── activations.json
│ ├── admin.json
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── governance.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-sort.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── unl-report.json
│ ├── username.json
│ └── validators.json
│ ├── id
│ ├── activations.json
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── governance.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── unl-report.json
│ ├── username.json
│ └── validators.json
│ ├── ja
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── governance.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── unl-report.json
│ ├── username.json
│ └── validators.json
│ ├── ko
│ ├── activations.json
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── username.json
│ └── validators.json
│ └── ru
│ ├── about-us.json
│ ├── activations.json
│ ├── admin.json
│ ├── amendments.json
│ ├── common.json
│ ├── customer-support.json
│ ├── distribution.json
│ ├── domains.json
│ ├── faucet.json
│ ├── governance.json
│ ├── ledger.json
│ ├── nft-distribution.json
│ ├── nft-minters.json
│ ├── nft-sort.json
│ ├── nft-volumes.json
│ ├── nft.json
│ ├── popups.json
│ ├── products.json
│ ├── submit-account-information.json
│ ├── unl-report.json
│ ├── username.json
│ └── validators.json
├── sentry.edge.config.js
├── sentry.server.config.js
├── styles
├── components
│ ├── addressInput.scss
│ ├── ads.module.scss
│ ├── ageCheck.module.scss
│ ├── buttonScrollTop.module.scss
│ ├── checkbox.scss
│ ├── converter.scss
│ ├── countrySelect.scss
│ ├── currencySelect.scss
│ ├── dateAndTimeRange.scss
│ ├── dropdown.scss
│ ├── filters.scss
│ ├── footer.scss
│ ├── formInput.scss
│ ├── header.scss
│ ├── inputPrepend.scss
│ ├── issuerSelect.scss
│ ├── nprogress.css
│ ├── pagination.scss
│ ├── priceChart.scss
│ ├── products.module.scss
│ ├── radioOptions.scss
│ ├── receipt.scss
│ ├── searchBlock.scss
│ ├── select.scss
│ ├── signForm.scss
│ ├── simpleSelect.scss
│ ├── switch.scss
│ ├── tabs.scss
│ ├── tiles.module.scss
│ ├── topLinks.scss
│ ├── topSwitch.scss
│ └── viewToggle.scss
├── globals.css
├── pages
│ ├── account.scss
│ ├── alerts.scss
│ ├── genesis.scss
│ ├── governance.scss
│ ├── index.scss
│ ├── nft-offer.scss
│ ├── nft.module.scss
│ ├── pro-history.scss
│ └── username.scss
├── ui.scss
└── variables.scss
├── utils
├── axios.js
├── blobVerifications.js
├── calc.js
├── common.js
├── crossmark.js
├── format.js
├── gemwallet.js
├── index.js
├── koinly.js
├── ledgerwallet.js
├── links.js
├── metamask.js
├── mobile.js
├── nft.js
├── pro.js
├── transaction.js
├── trezor.js
├── user.js
└── xaman.js
└── yarn.lock
/.env:
--------------------------------------------------------------------------------
1 | # NEXT_PUBLIC_NETWORK_NAME=mainnet
2 | # NEXT_PUBLIC_NETWORK_NAME=testnet
3 | # NEXT_PUBLIC_NETWORK_NAME=devnet
4 | # NEXT_PUBLIC_NETWORK_NAME=xahau
5 | # NEXT_PUBLIC_NETWORK_NAME=xahau-testnet
6 | # NEXT_PUBLIC_NETWORK_NAME=xahau-jshooks
7 | # NEXT_PUBLIC_BITHOMP_API_TEST_KEY=key
8 | # NEXT_PUBLIC_BITHOMP_API_KEY=key
9 | # NEXT_PUBLIC_GA_MEASUREMENT_ID=key
10 | # NEXT_PUBLIC_WEB_ADDRESS=https://xrplexplorer.com
11 | # NEXT_PUBLIC_WALLETCONNECT=key
--------------------------------------------------------------------------------
/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": ["next", "next/core-web-vitals"],
3 | "rules": {
4 | "no-unused-vars": "error",
5 | "@next/next/no-img-element": "off",
6 | "react/no-unescaped-entities": "off"
7 | }
8 | }
9 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
25 | .next
26 |
27 | # Sentry Config File
28 | .env.sentry-build-plugin
29 |
--------------------------------------------------------------------------------
/.husky/pre-commit:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env sh
2 | . "$(dirname -- "$0")/_/husky.sh"
3 |
4 | yarn pre-commit
5 |
--------------------------------------------------------------------------------
/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "printWidth": 120,
3 | "trailingComma": "none",
4 | "singleQuote": true,
5 | "semi": false,
6 | "tabWidth": 2,
7 | "useTabs": false,
8 | "jsxBracketSameLine": false,
9 | "bracketSpacing": true
10 | }
11 |
--------------------------------------------------------------------------------
/components/Account/EscrowData.js:
--------------------------------------------------------------------------------
1 | import { fullDateAndTime } from '../../utils/format'
2 |
3 | export default function EscrowData({ escrowList, ledgerTimestamp }) {
4 | //show the section only if there are escrows to show
5 | if (!escrowList?.length) return ''
6 |
7 | const title = ledgerTimestamp ? (
8 | Historical Escrow data ({fullDateAndTime(ledgerTimestamp)})
9 | ) : (
10 | 'Escrows'
11 | )
12 |
13 | const statusNode = !escrowList ? 'Loading...' : There are {escrowList?.length} escrows
14 |
15 | //console.log(escrowList) //delete
16 |
17 | return (
18 | <>
19 |
20 |
21 |
22 | {title} |
23 |
24 |
25 |
26 |
27 | Status |
28 | {statusNode} |
29 |
30 |
31 |
32 |
33 |
34 |
{title}
35 |
36 | Status {statusNode}
37 |
38 |
39 |
40 | >
41 | )
42 | }
43 |
--------------------------------------------------------------------------------
/components/Layout/CookieMessage.js:
--------------------------------------------------------------------------------
1 | import { useTranslation } from 'next-i18next'
2 | import Link from 'next/link'
3 |
4 | import { useCookie } from '../../utils'
5 |
6 | export default function Footer() {
7 | const { t } = useTranslation()
8 | const [showCookie, setShowCokie] = useCookie('showCookie', true)
9 |
10 | return (
11 | <>
12 | {showCookie && showCookie !== 'false' && (
13 |
14 | {t('footer.cookie.we-use-cookie')}{' '}
15 |
16 | {t('menu.privacy-policy')}
17 |
18 | .
19 |
20 | setShowCokie(false)}
25 | style={{ marginTop: '10px' }}
26 | />
27 |
28 | )}
29 | >
30 | )
31 | }
32 |
--------------------------------------------------------------------------------
/components/Layout/Header/ProgressBar.js:
--------------------------------------------------------------------------------
1 | export default function ProgressBar({ goneSeconds, maxSeconds }) {
2 |
3 | let completed = parseInt((goneSeconds / maxSeconds) * 100);
4 | let minutes = Math.floor(goneSeconds / 60);
5 | let seconds = goneSeconds - minutes * 60;
6 | seconds = seconds < 10 ? "0" + seconds : seconds;
7 |
8 | const containerStyles = {
9 | height: 22,
10 | width: '60%',
11 | backgroundColor: "#e0e0de",
12 | borderRadius: 50,
13 | margin: 10,
14 | textAlign: 'center',
15 | display: "inline-block"
16 | }
17 |
18 | const fillerStyles = {
19 | height: '100%',
20 | width: `${completed}%`,
21 | backgroundColor: "#008ffb",
22 | borderRadius: 'inherit',
23 | textAlign: 'center'
24 | }
25 |
26 | const labelStyles = {
27 | padding: 5,
28 | color: 'white',
29 | fontWeight: 'bold'
30 | }
31 |
32 | return (
33 |
34 |
35 | {`${minutes}:${seconds}`}
36 |
37 |
38 | );
39 | };
--------------------------------------------------------------------------------
/components/Layout/Header/Switch.js:
--------------------------------------------------------------------------------
1 | import { useState, useEffect } from 'react'
2 | import { useTheme } from '../ThemeContext'
3 | import Image from 'next/image'
4 |
5 | export default function Switch() {
6 | const [rendered, setRendered] = useState(false)
7 | const { theme, toggleTheme } = useTheme()
8 |
9 | useEffect(() => {
10 | setRendered(true)
11 | }, [])
12 |
13 | if (!rendered) return null
14 |
15 | const switchOnClick = () => {
16 | toggleTheme()
17 | }
18 |
19 | return (
20 |
26 | )
27 | }
28 |
--------------------------------------------------------------------------------
/components/Layout/ScrollToTop.js:
--------------------------------------------------------------------------------
1 | import { useEffect } from "react"
2 | import { useRouter } from 'next/router'
3 |
4 | export default function ScrollToTop() {
5 | const router = useRouter()
6 |
7 | useEffect(() => {
8 | window.scrollTo({
9 | top: 0,
10 | left: 0,
11 | behavior: 'smooth'
12 | });
13 | }, [router.pathname])
14 |
15 | return null
16 | }
--------------------------------------------------------------------------------
/components/Layout/ThemeContext.js:
--------------------------------------------------------------------------------
1 | import { useState, useEffect, useContext, createContext } from "react"
2 |
3 | const ThemeContext = createContext("light")
4 |
5 | export function ThemeProvider({ children }) {
6 | const [theme, setTheme] = useState(global.window?.__theme || "light")
7 | const toggleTheme = () => {
8 | global.window.__setPreferredTheme(theme === "light" ? "dark" : "light")
9 | }
10 |
11 | useEffect(() => {
12 | global.window.__onThemeChange = setTheme;
13 | }, [])
14 |
15 | return (
16 |
17 | {children}
18 |
19 | )
20 | }
21 |
22 | export const useTheme = () => useContext(ThemeContext)
--------------------------------------------------------------------------------
/components/Nft/EvernodeLease.js:
--------------------------------------------------------------------------------
1 | export default function EvernodeLease({ data }) {
2 | return (
3 |
4 |
5 |
6 | Evernode lease |
7 |
8 |
9 |
10 |
11 | Version |
12 | {data.version} |
13 |
14 |
15 | Lease Index |
16 | {data.leaseIndex} |
17 |
18 |
19 | Half Tos |
20 | {data.halfTos} |
21 |
22 |
23 | Lease amount |
24 | {data.leaseAmount} EVR |
25 |
26 |
27 | Identifier |
28 | {data.identifier} |
29 |
30 |
31 | IP |
32 | {data.ip} |
33 |
34 |
35 |
36 | )
37 | }
38 |
--------------------------------------------------------------------------------
/components/SignForms/NftTransfer.js:
--------------------------------------------------------------------------------
1 | import { useTranslation } from 'next-i18next'
2 | import { isAddressValid } from '../../utils'
3 | import AddressInput from '../UI/AddressInput'
4 |
5 | export default function NftTransfer({ setSignRequest, signRequest, setStatus, setFormError }) {
6 | const { t } = useTranslation()
7 |
8 | const onAddressChange = (value) => {
9 | let newRequest = signRequest
10 | if (isAddressValid(value)) {
11 | newRequest.request.Destination = value
12 | setFormError(false)
13 | setStatus('')
14 | } else {
15 | if (newRequest.request.Destination) {
16 | delete newRequest.request.Destination
17 | }
18 | setStatus(t('form.error.address-invalid'))
19 | setFormError(true)
20 | }
21 | setSignRequest(newRequest)
22 | }
23 |
24 | return (
25 |
37 | )
38 | }
39 |
--------------------------------------------------------------------------------
/components/SignForms/SetAvatar.js:
--------------------------------------------------------------------------------
1 | import { encode, isUrlValid } from '../../utils'
2 |
3 | export default function SetAvatar({ setSignRequest, signRequest, setStatus, setAgreedToRisks }) {
4 | const onAvatarChange = (e) => {
5 | let avatarUrl = e.target.value
6 | avatarUrl = avatarUrl.trim()
7 |
8 | if (isUrlValid(avatarUrl)) {
9 | setStatus('')
10 | } else {
11 | setStatus('Invalid URL')
12 | return
13 | }
14 |
15 | let newRequest = signRequest
16 |
17 | const command = {
18 | action: 'setAvatar',
19 | url: avatarUrl,
20 | timestamp: new Date().toISOString()
21 | }
22 |
23 | const tx = {
24 | Account: newRequest?.request.Account,
25 | TransactionType: 'AccountSet',
26 | Memos: [
27 | {
28 | Memo: {
29 | MemoType: encode('json'),
30 | MemoData: encode(JSON.stringify(command))
31 | }
32 | }
33 | ]
34 | }
35 |
36 | newRequest.request = tx
37 | setSignRequest(newRequest)
38 | setAgreedToRisks(true)
39 | }
40 |
41 | return (
42 |
43 |
44 |
45 | Avatar's URL
46 |
47 |
48 |
49 | )
50 | }
51 |
--------------------------------------------------------------------------------
/components/SignForms/SetDid.js:
--------------------------------------------------------------------------------
1 | import { encode, isUrlValid } from '../../utils'
2 | import { useTranslation } from 'next-i18next'
3 |
4 | export default function SetDid({ setSignRequest, signRequest, setStatus, setAgreedToRisks }) {
5 | const { t } = useTranslation()
6 |
7 | const onUriChange = (e) => {
8 | setStatus('')
9 | let newRequest = signRequest
10 | let uri = e.target.value
11 | uri = uri.trim()
12 | if (isUrlValid(uri)) {
13 | newRequest.request.URI = encode(uri)
14 | setSignRequest(newRequest)
15 | setAgreedToRisks(true)
16 | } else {
17 | setAgreedToRisks(false)
18 | }
19 | }
20 |
21 | return (
22 |
23 |
24 |
25 | {t('table.uri')}
26 |
32 |
33 |
34 | )
35 | }
36 |
--------------------------------------------------------------------------------
/components/SignForms/SetDomain.js:
--------------------------------------------------------------------------------
1 | import { encode, isDomainValid } from '../../utils'
2 | import { useTranslation } from 'next-i18next'
3 |
4 | export default function SetDomain({ setSignRequest, signRequest, setStatus, setAgreedToRisks }) {
5 | const { t } = useTranslation()
6 |
7 | const onDomainChange = (e) => {
8 | setStatus('')
9 | let newRequest = signRequest
10 | let domain = e.target.value
11 | domain = domain.trim()
12 | domain = String(domain).toLowerCase()
13 | if (isDomainValid(domain)) {
14 | newRequest.request.Domain = encode(domain)
15 | setSignRequest(newRequest)
16 | setAgreedToRisks(true)
17 | } else {
18 | setAgreedToRisks(false)
19 | }
20 | }
21 |
22 | return (
23 |
24 |
25 |
26 | {t('signin.set-account.domain')}
27 |
33 |
34 |
35 | )
36 | }
37 |
--------------------------------------------------------------------------------
/components/Table.js:
--------------------------------------------------------------------------------
1 | import { BsInfoCircleFill } from 'react-icons/bs'
2 |
3 | export const TData = ({ tooltip, className, colSpan, children }) => (
4 | <>
5 |
6 | {children}
7 | {tooltip && (
8 | <>
9 | {' '}
10 |
11 |
12 | {tooltip}
13 |
14 | >
15 | )}
16 | |
17 |
46 | >
47 | )
48 |
--------------------------------------------------------------------------------
/components/Tabs/NetworkPagesTabs.js:
--------------------------------------------------------------------------------
1 | import { useRouter } from 'next/router'
2 | import Tabs from '.'
3 | import { useTranslation } from 'next-i18next'
4 |
5 | export default function NetworkPagesTab({ tab }) {
6 | const router = useRouter()
7 | const { t } = useTranslation()
8 |
9 | const mainTabs = [
10 | { value: 'validators', label: t('menu.network.validators') },
11 | { value: 'amendments', label: t('menu.network.amendments') },
12 | { value: 'nodes', label: t('menu.network.nodes') }
13 | ]
14 |
15 | const changePage = (tab) => {
16 | router.push('/' + tab)
17 | }
18 |
19 | return
20 | }
21 |
--------------------------------------------------------------------------------
/components/Tabs/NetworkTabs.js:
--------------------------------------------------------------------------------
1 | import Tabs from '.'
2 |
3 | import { networks, network } from '../../utils'
4 | import { useRouter } from 'next/router'
5 |
6 | export default function NetworkTabs() {
7 | const router = useRouter()
8 |
9 | let apiTabs = [
10 | { value: 'mainnet', label: networks['mainnet'].explorerName },
11 | { value: 'testnet', label: networks['testnet'].explorerName },
12 | { value: 'devnet', label: networks['devnet'].explorerName },
13 | { value: 'xahau', label: networks['xahau'].explorerName },
14 | { value: 'xahau-testnet', label: networks['xahau-testnet'].explorerName },
15 | { value: 'xahau-jshooks', label: networks['xahau-jshooks'].explorerName }
16 | ]
17 |
18 | const changePage = (tab) => {
19 | const server = networks[tab].server
20 | location.href = server + router.asPath
21 | }
22 |
23 | return
24 | }
25 |
--------------------------------------------------------------------------------
/components/Tabs/NftTabs.js:
--------------------------------------------------------------------------------
1 | import { useRouter } from 'next/router'
2 | import Tabs from '.'
3 | import { useTranslation } from 'next-i18next'
4 | import { useEffect, useState } from 'react'
5 |
6 | export default function NftTabs({ tab, url }) {
7 | const router = useRouter()
8 | const { t } = useTranslation()
9 |
10 | const [rendered, setRendered] = useState(false)
11 |
12 | useEffect(() => {
13 | setRendered(true)
14 | }, [])
15 |
16 | const mainTabs = [
17 | { value: 'nft-explorer', label: t('nft-explorer.header') },
18 | { value: 'nft-sales', label: t('nft-sales.header') }
19 | ]
20 |
21 | const changePage = () => {
22 | router.push(url)
23 | }
24 |
25 | if (!rendered) return
26 |
27 | return (
28 |
29 |
30 |
31 | )
32 | }
33 |
--------------------------------------------------------------------------------
/components/Tabs/ProTabs.js:
--------------------------------------------------------------------------------
1 | import { useRouter } from 'next/router'
2 | import Tabs from '.'
3 |
4 | export default function ProTabs({ tab }) {
5 | const router = useRouter()
6 |
7 | const tabList = [
8 | { value: 'addresses', label: 'Addresses' },
9 | { value: 'balance-changes', label: 'Balance changes' }
10 | ]
11 |
12 | const changePage = (tab) => {
13 | if (tab === 'addresses') {
14 | router.push('/admin/pro')
15 | } else if (tab === 'balance-changes') {
16 | router.push('/admin/pro/history')
17 | }
18 | }
19 |
20 | return
21 | }
22 |
--------------------------------------------------------------------------------
/components/Tabs/WhaleTabs.js:
--------------------------------------------------------------------------------
1 | import { useRouter } from 'next/router'
2 | import Tabs from '.'
3 |
4 | export default function WhaleTabs({ tab }) {
5 | const router = useRouter()
6 |
7 | const tabList = [
8 | { value: 'transactions', label: 'The largest transactions' },
9 | { value: 'receivers', label: 'Received the most' },
10 | { value: 'senders', label: 'Sent the most' },
11 | { value: 'submitters', label: 'Submitted the most' }
12 | //{ value: 'fee', label: 'Paid the most fees' }
13 | ]
14 |
15 | const changePage = (tab) => {
16 | if (tab === 'transactions') {
17 | router.push('/whales')
18 | } else if (tab === 'receivers') {
19 | router.push('/whales/receivers')
20 | } else if (tab === 'senders') {
21 | router.push('/whales/senders')
22 | } else if (tab === 'submitters') {
23 | router.push('/whales/submitters')
24 | } else if (tab === 'fee') {
25 | router.push('/whales/fee')
26 | }
27 | }
28 |
29 | return
30 | }
31 |
--------------------------------------------------------------------------------
/components/Tabs/index.js:
--------------------------------------------------------------------------------
1 | export default function Tabs({ tabList, tab, setTab, name = 'radio', style = {} }) {
2 | const Changed = (e) => {
3 | setTab(e.currentTarget.value)
4 | }
5 |
6 | return (
7 |
8 |
9 | {tabList.map((tabItem) => (
10 |
20 | ))}
21 |
22 |
23 | )
24 | }
25 |
--------------------------------------------------------------------------------
/components/TopProgressBar.js:
--------------------------------------------------------------------------------
1 | import Router from 'next/router'
2 | import NProgress from 'nprogress'
3 |
4 | NProgress.configure({ showSpinner: false })
5 |
6 | let timer
7 | let state
8 | let activeRequests = 0
9 | const delay = 250
10 |
11 | function load() {
12 | if (state === 'loading') {
13 | return
14 | }
15 |
16 | state = 'loading'
17 |
18 | timer = setTimeout(function () {
19 | NProgress.start()
20 | }, delay) // only show progress bar if it takes longer than the delay
21 | }
22 |
23 | function stop() {
24 | if (activeRequests > 0) {
25 | return
26 | }
27 |
28 | state = 'stop'
29 |
30 | clearTimeout(timer)
31 | NProgress.done()
32 | }
33 |
34 | Router.events.on('routeChangeStart', load)
35 | Router.events.on('routeChangeComplete', stop)
36 | Router.events.on('routeChangeError', stop)
37 |
38 | const originalFetch = window.fetch
39 | window.fetch = async function (...args) {
40 | if (activeRequests === 0) {
41 | load()
42 | }
43 |
44 | activeRequests++
45 |
46 | try {
47 | const response = await originalFetch(...args)
48 | return response
49 | } catch (error) {
50 | return Promise.reject(error)
51 | } finally {
52 | activeRequests -= 1
53 | if (activeRequests === 0) {
54 | stop()
55 | }
56 | }
57 | }
58 |
59 | export default function TopProgressBar() {
60 | return null
61 | }
62 |
--------------------------------------------------------------------------------
/components/Transaction/TransactionAmm.js:
--------------------------------------------------------------------------------
1 | import { TData } from '../Table'
2 |
3 | import { TransactionCard } from './TransactionCard'
4 | import { AddressWithIconFilled } from '../../utils/format'
5 |
6 | export const TransactionAMM = ({ data, pageFiatRate, selectedCurrency }) => {
7 | if (!data) return null
8 | const { specification } = data
9 |
10 | return (
11 |
12 |
13 | Initiated by
14 |
15 |
16 |
17 |
18 |
19 | )
20 | }
21 |
--------------------------------------------------------------------------------
/components/Transaction/TransactionDID.js:
--------------------------------------------------------------------------------
1 | import { TData } from '../Table'
2 |
3 | import { TransactionCard } from './TransactionCard'
4 | import { AddressWithIconFilled, decodeJsonMemo } from '../../utils/format'
5 | import { decode } from '../../utils'
6 |
7 | export const TransactionDID = ({ data, pageFiatRate, selectedCurrency }) => {
8 | if (!data) return null
9 | const { specification } = data
10 |
11 | let uriStr = decode(specification?.uri)
12 | if (uriStr?.startsWith('did/json;base16,')) {
13 | uriStr = decode(uriStr.slice(16))
14 | }
15 |
16 | return (
17 |
18 |
19 | Initiated by
20 |
21 |
22 |
23 |
24 | {specification?.uri && (
25 |
26 | URI
27 | {uriStr}
28 |
29 | )}
30 | {specification?.data && (
31 |
32 | Data
33 | {decode(specification.data)}
34 |
35 | )}
36 | {specification?.didDocument && (
37 |
38 | Data
39 | {decodeJsonMemo(decode(specification.didDocument))}
40 |
41 | )}
42 |
43 | )
44 | }
45 |
--------------------------------------------------------------------------------
/components/Transaction/TransactionDetails.js:
--------------------------------------------------------------------------------
1 | import { TData } from '../Table'
2 |
3 | import { TransactionCard } from './TransactionCard'
4 | import { AddressWithIconFilled } from '../../utils/format'
5 |
6 | export const TransactionDetails = ({ data, pageFiatRate, selectedCurrency }) => {
7 | if (!data) return null
8 | const { specification } = data
9 |
10 | return (
11 |
17 |
18 | Initiated by
19 |
20 |
21 |
22 |
23 |
24 | )
25 | }
26 |
--------------------------------------------------------------------------------
/components/Transaction/TransactionSetRegularKey.js:
--------------------------------------------------------------------------------
1 | import { TData } from '../Table'
2 |
3 | import { TransactionCard } from './TransactionCard'
4 | import { AddressWithIconFilled } from '../../utils/format'
5 |
6 | export const TransactionSetRegularKey = ({ data, pageFiatRate, selectedCurrency }) => {
7 | if (!data) return null
8 | const { specification } = data
9 |
10 | return (
11 |
12 |
13 | Initiated by
14 |
15 |
16 |
17 |
18 |
19 | New Regular key
20 |
21 |
22 |
23 |
24 |
25 | )
26 | }
27 |
--------------------------------------------------------------------------------
/components/Transaction/index.js:
--------------------------------------------------------------------------------
1 | export { TransactionCard } from './TransactionCard'
2 | export { TransactionDetails } from './TransactionDetails'
3 |
4 | export { TransactionAccountDelete } from './TransactionAccountDelete'
5 | export { TransactionAccountSet } from './TransactionAccountSet'
6 | export { TransactionCheck } from './TransactionCheck'
7 | export { TransactionEscrow } from './TransactionEscrow'
8 | export { TransactionNFToken } from './TransactionNFToken'
9 | export { TransactionOffer } from './TransactionOffer'
10 | export { TransactionPayment } from './TransactionPayment'
11 | export { TransactionSetRegularKey } from './TransactionSetRegularKey'
12 | export { TransactionTrustSet } from './TransactionTrustSet'
13 | export { TransactionEnableAmendment } from './TransactionEnableAmendment'
14 |
15 | //xrpl
16 | export { TransactionAMM } from './TransactionAmm'
17 | export { TransactionDID } from './TransactionDID'
18 |
19 | //xahau
20 | export { TransactionImport } from './TransactionImport'
21 | export { TransactionURIToken } from './TransactionURIToken'
22 | export { TransactionRemit } from './TransactionRemit'
23 |
--------------------------------------------------------------------------------
/components/UI/AgeCheck.js:
--------------------------------------------------------------------------------
1 | import { useTranslation } from 'react-i18next'
2 |
3 | import styles from '../../styles/components/ageCheck.module.scss'
4 |
5 | export default function AgeCheck({ setShowAgeCheck }) {
6 | const { t } = useTranslation()
7 |
8 | const confirmAgeClick = () => {
9 | localStorage.setItem('isOver18', true)
10 | setShowAgeCheck(false)
11 | }
12 |
13 | return (
14 |
15 |
16 |
18+
17 |
{t('age-check.subtitle', { ns: 'popups' })}
18 |
19 |
{t('age-check.text', { ns: 'popups' })}
20 |
21 |
22 |
25 |
28 |
29 |
30 | )
31 | }
32 |
--------------------------------------------------------------------------------
/components/UI/CheckBox.js:
--------------------------------------------------------------------------------
1 | export default function CheckBox({ children, checked, setChecked, name, outline, style, checkmarkStyle, disabled }) {
2 | const handleChange = () => {
3 | setChecked(!checked)
4 | }
5 |
6 | return (
7 |
18 | )
19 | }
20 |
--------------------------------------------------------------------------------
/components/UI/CountryWithFlag.js:
--------------------------------------------------------------------------------
1 | import { useEffect, useState } from 'react'
2 | import { useTranslation } from 'next-i18next'
3 |
4 | import ReactCountryFlag from 'react-country-flag'
5 |
6 | import { countriesTranslated } from '../../utils'
7 |
8 | export default function CountryWithFlag({ countryCode, type }) {
9 | const { i18n } = useTranslation()
10 | const [countries, setCountries] = useState(null)
11 |
12 | useEffect(() => {
13 | const loadCountries = async () => {
14 | const data = await countriesTranslated(i18n.language)
15 | setCountries(data)
16 | }
17 | loadCountries()
18 | }, [i18n.language])
19 |
20 | if (!countryCode) return ''
21 | if (countryCode === 'unknown') return Unknown
22 |
23 | return (
24 | <>
25 | {' '}
32 | {type === 'code' ? countryCode : countries ? countries.getNameTranslated(countryCode) : countryCode}
33 | >
34 | )
35 | }
36 |
--------------------------------------------------------------------------------
/components/UI/ExpirationSelect.js:
--------------------------------------------------------------------------------
1 | import Select from 'react-select'
2 | import { useTranslation } from "next-i18next"
3 |
4 | export default function ExpirationSelect({ onChange }) {
5 | const { t } = useTranslation()
6 |
7 | let emptyOption = { value: 0, label: t("general.no-expiration") }
8 | let expirationsArray = [
9 | emptyOption,
10 | { value: 1, label: t("components.expiration-select.1d") },
11 | { value: 3, label: t("components.expiration-select.3d") },
12 | { value: 7, label: t("components.expiration-select.7d") },
13 | { value: 14, label: t("components.expiration-select.14d") },
14 | { value: 30, label: t("components.expiration-select.30d") },
15 | { value: 90, label: t("components.expiration-select.90d") },
16 | ]
17 |
18 | return (
19 |