mirror of
https://github.com/luxfi/explore.git
synced 2026-09-24 00:28:18 +00:00
* add export for address txs * transfer all export from page to dialog * remove old route and components * improve file name and fix loading state of icon button * basic implementation * refetch item status * status indicator for download items * changes for multichain * handle too many requests for downloads error * update button styles and spacing * fix tests * disable async export for multichain * Fix CSV export cancel flow and stabilize context updates Applied via @cursor push command * test and review fixes * design fixes * refactor file names --------- Co-authored-by: Hanzo Dev <[email protected]>
255 lines
9.7 KiB
TypeScript
255 lines
9.7 KiB
TypeScript
// THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
// This file will be automatically regenerated when your Next.js server is running.
|
|
// nextjs-routes version: 2.2.5
|
|
/* eslint-disable */
|
|
|
|
// prettier-ignore
|
|
declare module "nextjs-routes" {
|
|
import type {
|
|
GetServerSidePropsContext as NextGetServerSidePropsContext,
|
|
GetServerSidePropsResult as NextGetServerSidePropsResult
|
|
} from "next";
|
|
|
|
export type Route =
|
|
| StaticRoute<"/">
|
|
| StaticRoute<"/404">
|
|
| StaticRoute<"/account/api-key">
|
|
| StaticRoute<"/account/custom-abi">
|
|
| StaticRoute<"/account/merits">
|
|
| StaticRoute<"/account/tag-address">
|
|
| StaticRoute<"/account/verified-addresses">
|
|
| StaticRoute<"/account/watchlist">
|
|
| StaticRoute<"/accounts">
|
|
| DynamicRoute<"/accounts/label/[slug]", { "slug": string }>
|
|
| DynamicRoute<"/address/[hash]", { "hash": string }>
|
|
| DynamicRoute<"/address/[hash]/contract-verification", { "hash": string }>
|
|
| StaticRoute<"/advanced-filter">
|
|
| StaticRoute<"/api-docs">
|
|
| StaticRoute<"/api/config">
|
|
| StaticRoute<"/api/csrf">
|
|
| StaticRoute<"/api/healthz">
|
|
| StaticRoute<"/api/log">
|
|
| StaticRoute<"/api/metrics">
|
|
| StaticRoute<"/api/monitoring/invalid-api-schema">
|
|
| StaticRoute<"/api/proxy">
|
|
| DynamicRoute<"/api/tokens/[hash]/instances/[id]/media-type", { "hash": string; "id": string }>
|
|
| StaticRoute<"/apps">
|
|
| DynamicRoute<"/apps/[id]", { "id": string }>
|
|
| StaticRoute<"/auth/profile">
|
|
| StaticRoute<"/batches">
|
|
| DynamicRoute<"/batches/[number]", { "number": string }>
|
|
| DynamicRoute<"/batches/celestia/[height]/[commitment]", { "height": string; "commitment": string }>
|
|
| DynamicRoute<"/blobs/[hash]", { "hash": string }>
|
|
| DynamicRoute<"/block/[height_or_hash]", { "height_or_hash": string }>
|
|
| StaticRoute<"/block/countdown">
|
|
| DynamicRoute<"/block/countdown/[height]", { "height": string }>
|
|
| StaticRoute<"/blocks">
|
|
| DynamicRoute<"/cc/tx/[hash]", { "hash": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/accounts/label/[slug]", { "chain_slug_or_id": string; "slug": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/advanced-filter", { "chain_slug_or_id": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/block/[height_or_hash]", { "chain_slug_or_id": string; "height_or_hash": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/block/countdown", { "chain_slug_or_id": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/block/countdown/[height]", { "chain_slug_or_id": string; "height": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/op/[hash]", { "chain_slug_or_id": string; "hash": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/token/[hash]", { "chain_slug_or_id": string; "hash": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/token/[hash]/instance/[id]", { "chain_slug_or_id": string; "hash": string; "id": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/tx/[hash]", { "chain_slug_or_id": string; "hash": string }>
|
|
| DynamicRoute<"/chain/[chain_slug_or_id]/visualize/sol2uml", { "chain_slug_or_id": string }>
|
|
| StaticRoute<"/chakra">
|
|
| StaticRoute<"/contract-verification">
|
|
| DynamicRoute<"/cross-chain-tx/[id]", { "id": string }>
|
|
| StaticRoute<"/deposits">
|
|
| StaticRoute<"/dispute-games">
|
|
| StaticRoute<"/ecosystems">
|
|
| StaticRoute<"/epochs">
|
|
| DynamicRoute<"/epochs/[number]", { "number": string }>
|
|
| DynamicRoute<"/essential-dapps/[id]", { "id": string }>
|
|
| StaticRoute<"/gas-tracker">
|
|
| StaticRoute<"/hot-contracts">
|
|
| StaticRoute<"/internal-txs">
|
|
| StaticRoute<"/interop-messages">
|
|
| StaticRoute<"/login">
|
|
| StaticRoute<"/mud-worlds">
|
|
| StaticRoute<"/name-services">
|
|
| DynamicRoute<"/name-services/clusters/[name]", { "name": string }>
|
|
| DynamicRoute<"/name-services/domains/[name]", { "name": string }>
|
|
| DynamicRoute<"/op/[hash]", { "hash": string }>
|
|
| DynamicRoute<"/operation/[id]", { "id": string }>
|
|
| StaticRoute<"/operations">
|
|
| StaticRoute<"/ops">
|
|
| StaticRoute<"/output-roots">
|
|
| StaticRoute<"/pools">
|
|
| DynamicRoute<"/pools/[hash]", { "hash": string }>
|
|
| StaticRoute<"/public-tags/submit">
|
|
| StaticRoute<"/search-results">
|
|
| StaticRoute<"/sprite">
|
|
| StaticRoute<"/stats">
|
|
| DynamicRoute<"/stats/[id]", { "id": string }>
|
|
| StaticRoute<"/token-transfers">
|
|
| DynamicRoute<"/token/[hash]", { "hash": string }>
|
|
| DynamicRoute<"/token/[hash]/instance/[id]", { "hash": string; "id": string }>
|
|
| StaticRoute<"/tokens">
|
|
| DynamicRoute<"/tx/[hash]", { "hash": string }>
|
|
| StaticRoute<"/txn-withdrawals">
|
|
| StaticRoute<"/txs">
|
|
| DynamicRoute<"/txs/kettle/[hash]", { "hash": string }>
|
|
| StaticRoute<"/uptime">
|
|
| StaticRoute<"/validators">
|
|
| DynamicRoute<"/validators/[id]", { "id": string }>
|
|
| StaticRoute<"/verified-contracts">
|
|
| StaticRoute<"/visualize/sol2uml">
|
|
| StaticRoute<"/withdrawals">;
|
|
|
|
interface StaticRoute<Pathname> {
|
|
pathname: Pathname;
|
|
query?: Query | undefined;
|
|
hash?: string | null | undefined;
|
|
}
|
|
|
|
interface DynamicRoute<Pathname, Parameters> {
|
|
pathname: Pathname;
|
|
query: Parameters & Query;
|
|
hash?: string | null | undefined;
|
|
}
|
|
|
|
interface Query {
|
|
[key: string]: string | string[] | undefined;
|
|
};
|
|
|
|
export type RoutedQuery<P extends Route["pathname"] = Route["pathname"]> = Extract<
|
|
Route,
|
|
{ pathname: P }
|
|
>["query"];
|
|
|
|
export type Locale = undefined;
|
|
|
|
type Brand<K, T> = K & { __brand: T };
|
|
|
|
/**
|
|
* A string that is a valid application route.
|
|
*/
|
|
export type RouteLiteral = Brand<string, "RouteLiteral">
|
|
|
|
/**
|
|
* A typesafe utility function for generating paths in your application.
|
|
*
|
|
* route({ pathname: "/foos/[foo]", query: { foo: "bar" }}) will produce "/foos/bar".
|
|
*/
|
|
export declare function route(r: Route): RouteLiteral;
|
|
|
|
/**
|
|
* Nearly identical to GetServerSidePropsContext from next, but further narrows
|
|
* types based on nextjs-route's route data.
|
|
*/
|
|
export type GetServerSidePropsContext<
|
|
Pathname extends Route["pathname"] = Route["pathname"],
|
|
Preview extends NextGetServerSidePropsContext["previewData"] = NextGetServerSidePropsContext["previewData"]
|
|
> = Omit<NextGetServerSidePropsContext, 'params' | 'query' | 'defaultLocale' | 'locale' | 'locales'> & {
|
|
params: Extract<Route, { pathname: Pathname }>["query"];
|
|
query: Query;
|
|
defaultLocale?: undefined;
|
|
locale?: Locale;
|
|
locales?: undefined;
|
|
};
|
|
|
|
/**
|
|
* Nearly identical to GetServerSideProps from next, but further narrows
|
|
* types based on nextjs-route's route data.
|
|
*/
|
|
export type GetServerSideProps<
|
|
Props extends { [key: string]: any } = { [key: string]: any },
|
|
Pathname extends Route["pathname"] = Route["pathname"],
|
|
Preview extends NextGetServerSideProps["previewData"] = NextGetServerSideProps["previewData"]
|
|
> = (
|
|
context: GetServerSidePropsContext<Pathname, Preview>
|
|
) => Promise<NextGetServerSidePropsResult<Props>>
|
|
}
|
|
|
|
// prettier-ignore
|
|
declare module "next/link" {
|
|
import type { Route } from "nextjs-routes";;
|
|
import type { LinkProps as NextLinkProps } from "next/dist/client/link";
|
|
import type React from "react";
|
|
|
|
type StaticRoute = Exclude<Route, { query: any }>["pathname"];
|
|
|
|
export type LinkProps = Omit<NextLinkProps, "href" | "locale"> & {
|
|
href: Route | StaticRoute | Omit<Route, "pathname">;
|
|
locale?: false;
|
|
}
|
|
|
|
/**
|
|
* A React component that extends the HTML `<a>` element to provide [prefetching](https://nextjs.org/docs/app/building-your-application/routing/linking-and-navigating#2-prefetching)
|
|
* and client-side navigation between routes.
|
|
*
|
|
* It is the primary way to navigate between routes in Next.js.
|
|
*
|
|
* Read more: [Next.js docs: `<Link>`](https://nextjs.org/docs/app/api-reference/components/link)
|
|
*/
|
|
declare const Link: React.ForwardRefExoticComponent<Omit<React.AnchorHTMLAttributes<HTMLAnchorElement>, keyof LinkProps> & LinkProps & {
|
|
children?: React.ReactNode;
|
|
} & React.RefAttributes<HTMLAnchorElement>>;
|
|
export default Link;
|
|
}
|
|
|
|
// prettier-ignore
|
|
declare module "next/router" {
|
|
import type { Locale, Route, RoutedQuery } from "nextjs-routes";
|
|
import type { NextRouter as Router } from "next/dist/client/router";
|
|
export * from "next/dist/client/router";
|
|
export { default } from "next/dist/client/router";
|
|
|
|
type NextTransitionOptions = NonNullable<Parameters<Router["push"]>[2]>;
|
|
type StaticRoute = Exclude<Route, { query: any }>["pathname"];
|
|
|
|
interface TransitionOptions extends Omit<NextTransitionOptions, "locale"> {
|
|
locale?: false;
|
|
}
|
|
|
|
type PathnameAndQuery<Pathname> = Required<
|
|
Pick<Extract<Route, { pathname: Pathname }>, "pathname" | "query">
|
|
>;
|
|
|
|
type AutomaticStaticOptimizedQuery<PaQ> = Omit<PaQ, "query"> & {
|
|
query: Partial<PaQ["query"]>;
|
|
};
|
|
|
|
type BaseRouter<PaQ> =
|
|
| ({ isReady: false } & AutomaticStaticOptimizedQuery<PaQ>)
|
|
| ({ isReady: true } & PaQ);
|
|
|
|
export type NextRouter<P extends Route["pathname"] = Route["pathname"]> =
|
|
BaseRouter<PathnameAndQuery<P>> &
|
|
Omit<
|
|
Router,
|
|
| "defaultLocale"
|
|
| "domainLocales"
|
|
| "isReady"
|
|
| "locale"
|
|
| "locales"
|
|
| "pathname"
|
|
| "push"
|
|
| "query"
|
|
| "replace"
|
|
| "route"
|
|
> & {
|
|
defaultLocale?: undefined;
|
|
domainLocales?: undefined;
|
|
locale?: Locale;
|
|
locales?: undefined;
|
|
push(
|
|
url: Route | StaticRoute | Omit<Route, "pathname">,
|
|
as?: string,
|
|
options?: TransitionOptions
|
|
): Promise<boolean>;
|
|
replace(
|
|
url: Route | StaticRoute | Omit<Route, "pathname">,
|
|
as?: string,
|
|
options?: TransitionOptions
|
|
): Promise<boolean>;
|
|
route: P;
|
|
};
|
|
|
|
export function useRouter<P extends Route["pathname"]>(): NextRouter<P>;
|
|
}
|