export interface ExplorerFeatureAction {
  title: string
  description: string
  href: string
  label: string
  external?: boolean
}

export interface ExplorerFeaturePage {
  eyebrow: string
  title: string
  description: string
  note?: string
  actions: ExplorerFeatureAction[]
}

const sharedOperationsNote =
  'These pages collect the public monitoring, route, wallet, and topology surfaces that support Chain 138 operations and investigation.'

export const explorerFeaturePages = {
  bridge: {
    eyebrow: 'Bridge Monitoring',
    title: 'Bridge & Relay Monitoring',
    description:
      'Inspect the CCIP relay status, follow the live mission-control stream, trace bridge transactions, and review the managed Mainnet, BSC, Avalanche, Avalanche cW, and Avalanche to Chain 138 lanes.',
    note: sharedOperationsNote,
    actions: [
      {
        title: 'Mission-control live stream',
        description: 'Open the server-sent event stream that powers live relay and RPC monitoring.',
        href: '/explorer-api/v1/mission-control/stream',
        label: 'Open SSE stream',
        external: true,
      },
      {
        title: 'Bridge status snapshot',
        description: 'Review the current relay health payload, queue posture, and destination summary.',
        href: '/explorer-api/v1/track1/bridge/status',
        label: 'Open status JSON',
        external: true,
      },
      {
        title: 'Reverse AVAX lane',
        description: 'Check the managed Avalanche cW burn-back lane to Chain 138 that now runs as its own relay service.',
        href: '/explorer-api/v1/track1/bridge/status',
        label: 'Review AVAX -> 138 lane',
        external: true,
      },
      {
        title: 'Bridge trace API',
        description: 'Resolve source and destination addresses for a bridge transaction through mission control.',
        href: '/explorer-api/v1/mission-control/bridge/trace?tx=0x2f31d4f9a97be754b800f4af1a9eedf3b107d353bfa1a19e81417497a76c05c2',
        label: 'Open trace example',
        external: true,
      },
      {
        title: 'Visual command center',
        description: 'Open the interactive topology map for Chain 138, CCIP, Alltra, and adjacent integrations.',
        href: '/chain138-command-center.html',
        label: 'Open command center',
        external: true,
      },
      {
        title: 'Routes & liquidity',
        description: 'Move from bridge health into route coverage, pools, and execution access points.',
        href: '/routes',
        label: 'Open routes page',
      },
    ],
  },
  routes: {
    eyebrow: 'Route Coverage',
    title: 'Routes, Pools, and Execution Access',
    description:
      'Surface the route matrix, live pool inventory, public liquidity endpoints, and bridge-adjacent execution paths from one public explorer surface.',
    note: sharedOperationsNote,
    actions: [
      {
        title: 'Liquidity access',
        description: 'Review the public Chain 138 PMM access points, route helpers, and fallback execution endpoints.',
        href: '/liquidity',
        label: 'Open liquidity access',
      },
      {
        title: 'Pools inventory',
        description: 'Open the live pools page instead of dropping into a raw backend response.',
        href: '/pools',
        label: 'Open pools inventory',
      },
      {
        title: 'Bridge monitoring',
        description: 'Cross-check route availability with live relay and bridge health before operator actions.',
        href: '/bridge',
        label: 'Open bridge monitoring',
      },
      {
        title: 'Operations hub',
        description: 'Open the consolidated page for WETH utilities, analytics, operator shortcuts, and system views.',
        href: '/operations',
        label: 'Open operations hub',
      },
    ],
  },
  weth: {
    eyebrow: 'WETH Utilities',
    title: 'WETH Utilities & Bridge References',
    description:
      'Reach the WETH-focused tooling that operators use during support and bridge investigation without depending on the hidden legacy explorer navigation.',
    note: sharedOperationsNote,
    actions: [
      {
        title: 'Bridge monitoring',
        description: 'Start with relay and bridge health before reviewing WETH-specific flows.',
        href: '/bridge',
        label: 'Open bridge monitoring',
      },
      {
        title: 'Visual command center',
        description: 'Use the interactive topology map for contract placement, hub flow, and system context.',
        href: '/chain138-command-center.html',
        label: 'Open command center',
        external: true,
      },
      {
        title: 'Wallet tools',
        description: 'Open the wallet page if you need supported network and token setup before testing flows.',
        href: '/wallet',
        label: 'Open wallet tools',
      },
      {
        title: 'Operations hub',
        description: 'Return to the larger operations landing page for adjacent route, analytics, and system shortcuts.',
        href: '/operations',
        label: 'Open operations hub',
      },
    ],
  },
  analytics: {
    eyebrow: 'Analytics Access',
    title: 'Analytics & Network Activity',
    description:
      'Use the public explorer pages and live monitoring endpoints as the visible analytics surface for chain activity, recent blocks, and transaction flow.',
    note: sharedOperationsNote,
    actions: [
      {
        title: 'Blocks',
        description: 'Inspect recent block production, timestamps, and miner attribution.',
        href: '/blocks',
        label: 'Open blocks',
      },
      {
        title: 'Transactions',
        description: 'Review recent transactions, status, and linked address flow.',
        href: '/transactions',
        label: 'Open transactions',
      },
      {
        title: 'Addresses',
        description: 'Browse saved and active addresses as part of the explorer activity surface.',
        href: '/addresses',
        label: 'Open addresses',
      },
      {
        title: 'Mission-control stream',
        description: 'Supplement the explorer pages with the live relay and RPC event feed.',
        href: '/explorer-api/v1/mission-control/stream',
        label: 'Open SSE stream',
        external: true,
      },
    ],
  },
  operator: {
    eyebrow: 'Operator Surface',
    title: 'Operator Surface',
    description:
      'Expose the public operator surface for bridge checks, route validation, planner providers, liquidity entry points, and documentation.',
    note: sharedOperationsNote,
    actions: [
      {
        title: 'Bridge monitoring',
        description: 'Open relay status, queue posture, and bridge trace tools.',
        href: '/bridge',
        label: 'Open bridge monitoring',
      },
      {
        title: 'Routes',
        description: 'Inspect route coverage and liquidity path access before operator intervention.',
        href: '/routes',
        label: 'Open routes page',
      },
      {
        title: 'Liquidity access',
        description: 'Open partner payload helpers, route APIs, and execution-plan endpoints.',
        href: '/liquidity',
        label: 'Open liquidity access',
      },
      {
        title: 'Explorer docs',
        description: 'Open the canonical explorer documentation hub for GRU guidance, transaction evidence notes, and public reference material.',
        href: '/docs',
        label: 'Open docs',
      },
      {
        title: 'Visual command center',
        description: 'Open the graphical deployment and integration topology in a dedicated page.',
        href: '/chain138-command-center.html',
        label: 'Open command center',
        external: true,
      },
    ],
  },
  system: {
    eyebrow: 'System Topology',
    title: 'System & Topology',
    description:
      'Jump straight into the public topology and reference surfaces that describe how Chain 138, bridge monitoring, and adjacent systems fit together.',
    note: sharedOperationsNote,
    actions: [
      {
        title: 'Visual command center',
        description: 'Open the topology map for Chain 138, CCIP, Alltra, OP Stack, and service flows.',
        href: '/chain138-command-center.html',
        label: 'Open command center',
        external: true,
      },
      {
        title: 'Bridge monitoring',
        description: 'Correlate topology context with the live bridge and relay status surface.',
        href: '/bridge',
        label: 'Open bridge monitoring',
      },
      {
        title: 'Explorer docs',
        description: 'Open the canonical explorer documentation hub for public reference material and guide pages.',
        href: '/docs',
        label: 'Open docs',
      },
      {
        title: 'Operations hub',
        description: 'Return to the consolidated operations landing page for adjacent public tools.',
        href: '/operations',
        label: 'Open operations hub',
      },
    ],
  },
  operations: {
    eyebrow: 'Operations Hub',
    title: 'Operations Hub',
    description:
      'This hub exposes the public operational surfaces for bridge monitoring, routes, wrapped-asset references, analytics shortcuts, operator links, and topology views.',
    note: sharedOperationsNote,
    actions: [
      {
        title: 'Bridge & relay monitoring',
        description: 'Open mission-control status, SSE monitoring, and bridge trace helpers.',
        href: '/bridge',
        label: 'Open bridge monitoring',
      },
      {
        title: 'Routes & liquidity',
        description: 'Open route coverage, pools, and public liquidity access points.',
        href: '/routes',
        label: 'Open routes page',
      },
      {
        title: 'WETH utilities',
        description: 'Open the WETH-focused landing page and bridge-adjacent shortcuts.',
        href: '/weth',
        label: 'Open WETH utilities',
      },
      {
        title: 'Analytics',
        description: 'Open the public analytics landing page for blocks, transactions, and live monitoring.',
        href: '/analytics',
        label: 'Open analytics page',
      },
      {
        title: 'Operator panel shortcuts',
        description: 'Open the operator landing page for bridge, route, liquidity, and docs shortcuts.',
        href: '/operator',
        label: 'Open operator page',
      },
      {
        title: 'System topology',
        description: 'Open the system landing page for topology references and command-center access.',
        href: '/system',
        label: 'Open system page',
      },
      {
        title: 'Visual command center',
        description: 'Open the dedicated interactive topology asset in a new tab.',
        href: '/chain138-command-center.html',
        label: 'Open command center',
        external: true,
      },
    ],
  },
} as const satisfies Record<string, ExplorerFeaturePage>
