Upgrade functionality and neatness#3
Open
Stentonian wants to merge 38 commits intocosullivan:mainfrom
Open
Conversation
Add flake.nix
…plan Stent/basic explorer plan
Implements the Account Details Page feature as specified in ACCOUNT_DETAILS_PAGE.md: **New Features:** - Account details page at /account?address=0x... with dual-pane layout - HyperEVM (L2) pane: HYPE balance + transaction history with CoreWriter indicators - HyperCore (L1) pane: Account state + perpetual positions + spot balances + trade history - Pagination for transaction lists (25 items per page with "Load More") - Clickable addresses throughout transaction views linking to account pages - Network selector (Mainnet/Testnet) for account queries **New Components:** - HyperCoreAccountState: Refactored account balance display (from AccountBalanceModal) - HyperCoreAccountDetails: L1 account pane wrapper - HyperCoreTransactionList: L1 transaction history with user fills - HyperEvmAccountDetails: L2 account pane with balance - HyperEvmTransactionList: L2 transaction history with block scanning **Enhanced Navigation:** - TransactionInfo: From/To addresses now link to account pages - HyperCoreTransactionInfo: User address links to account page + preserved "View Balance" button - Transaction hashes in account lists link back to main transaction viewer **Technical Details:** - Used query parameters for static export compatibility (no dynamic routes) - Implemented Suspense boundaries for Next.js 15 compliance - Responsive design with mobile-friendly layouts - Comprehensive error handling and loading states - Preserves all existing CoreWriter decoding functionality **Build Status:** ✅ All checks passing 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Removed block scanning approach that caused performance issues with repeated eth_getBlockByNumber calls - Added user-friendly message explaining that HyperEVM transaction history requires an indexer - Reduced bundle size from 3.28 kB to 2.78 kB - Added styling for feature unavailable message with link back to home page This addresses the performance concern while maintaining good UX by being transparent about the limitation. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Improvements based on code review: **HyperCoreTransactionList:** - Cache full transaction list to avoid refetching on "Load More" - Change error type from `any` to `unknown` for better type safety - Remove redundant type annotation on error state **HyperCoreAccountState:** - Remove redundant type annotation on error state - Change error type from `any` to `unknown` for better type safety - Optimize parseFloat calls in position side display (parse once, reuse) - Add validation for numeric balance values to handle malformed API data These changes improve performance, type safety, and error handling. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
This reverts commit 8886e97.
This reverts commit e82a280.
…State.tsx"" This reverts commit 89f9f40.
Implemented comprehensive data validation and error handling improvements: - Add address format validation before API calls to ensure valid 0x-prefixed hex addresses - Validate position.position.szi to prevent NaN values with proper type checking - Improve error message display for invalid balance data with better CSS styling - Fix indentation inconsistencies in JSX structure - Add Number.isFinite checks for numeric values to prevent display issues These changes improve robustness and user experience when handling edge cases and invalid data from the Hyperliquid API. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Changed from userFills to userDetails API to show comprehensive transaction history for all addresses including contracts. Updated display to show action type, block number, and transaction status instead of trade-specific fields. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
The userDetails API returns an object with a txs property containing the transaction array, not a direct array. This commit fixes the TypeScript error by: - Accessing result.txs instead of treating result as an array - Updating the error property type from optional string to string | null to match the API response 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…page feat: Add comprehensive account details page with dual-chain support
- Add Prettier for code formatting with .prettierrc configuration - Add ESLint with TypeScript support and Prettier integration - Update ESLint config to use flat config format (eslint.config.mjs) - Add npm scripts: format, format:check, lint:fix - Run Prettier on entire codebase to standardize formatting - Install dependencies: prettier, eslint-config-prettier, eslint-plugin-prettier, @typescript-eslint/eslint-plugin, @typescript-eslint/parser Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
…ng-formatting-tools-500175 Add standardized linting and formatting tools
- Replace tabbed interface with single intelligent search bar - Add automatic detection of input type (address vs transaction hash) - Implement parallel API calls to both HyperEVM and HyperCore for transaction lookup - Add routing to account details page for address searches - Consolidate network settings into single unified state - Create UnifiedSearchBar component for reusable search UI - Update homepage to use unified search interface Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Add explicit React import for TypeScript React.KeyboardEvent support - Replace deprecated onKeyPress with onKeyDown event handler - Change input type from 'text' to 'search' for semantic HTML - Add aria-label for better screen reader accessibility Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Add network parameter to URL when navigating to account page - Read network from URL query params on account page load - Update URL when user changes network on account page - Ensure network state stays synchronized across navigation Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Add 'HyperEVM Transaction Details' heading for HyperEVM results - Convert subsection headings to h3 for better hierarchy - Add decoder for addApiWallet CoreWriter action (action ID 9) - Define AddApiWalletAction type with apiWallet and apiWalletName fields - Implement decodeAddApiWallet function to parse action parameters Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
Issue 1: Custom RPC testnet support - Add customTestnet state flag to track if custom RPC is testnet - Update transportConfig in loadHyperCore to use customTestnet flag - Update transportConfig in parallel search to use customTestnet flag - Add checkbox UI for users to specify custom RPC is testnet - HyperCore queries now correctly target testnet when custom RPC + testnet flag set Issue 2: Account page routing fix - Coerce 'custom' network to 'mainnet' or 'testnet' before routing to /account - Use customTestnet flag to determine correct network value - Prevents breaking /account page which only supports mainnet|testnet - Preserves plan to add full custom RPC support to /account as future enhancement Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
…earch-navigation-1760502155 Implement Unified Search & Navigation
- Create /tx/[txHash] route with network query parameter - Add LoadingSpinner component with CSS animations - Redirect transaction searches to dedicated /tx page - Add loading states for HyperEVM and HyperCore fetching - Clean up homepage by removing inline transaction display - Improve URL structure consistency with /account route Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Change from dynamic route /tx/[txHash] to query params /tx?hash=... - This fixes the generateStaticParams error with output: export - Update transaction links in HyperCoreTransactionList to use new format - Update homepage redirect to use query parameter format - Now compatible with Next.js static export configuration Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Create utils/validation.ts with isValidTxHash function - Create utils/chainSearch.ts with searchBothChains function - Update app/page.tsx and app/tx/page.tsx to use shared utilities - Replace inline-styled button with Next.js Link using back-button CSS class - Remove duplicate validation and chain search logic Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Add missing import for @nktkas/hyperliquid namespace (hl) - Add missing import for HttpTransportOptions type - Required for loadHyperCore function Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Move app/tx/page.tsx to app/tx/[txHash]/page.tsx
- Update component to receive txHash from route params instead of query params
- Keep network as query param with 'mainnet' fallback
- Update all imports to reflect new directory depth
- Update router.push in app/page.tsx to use /tx/{txHash}?network={network}
- Update transaction links in HyperCoreTransactionList to use new route format
- URLs are now /tx/{txHash}?network={network} for better bookmarking/sharing
Co-authored-by: Stenton Mayne <stentonian@protonmail.com>
- Remove hardcoded chainId 999 from JsonRpcProvider in both home and tx pages to allow dynamic chainId detection (999 for mainnet, 998 for testnet) - Add RawAction event topic filtering before log decoding to prevent incorrect event matches - Wrap decodeEventLog in try-catch blocks to handle unexpected decode errors gracefully - Convert dynamic route /tx/[txHash] to query param route /tx?tx=...&network=... for Next.js static export compatibility - Add Suspense boundary around useSearchParams() to satisfy static export requirements - Update all transaction links to use new query param format - Format code with Prettier 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…improvements-1761074747 Implement dedicated /tx route with loading indicators
|
@Stentonian is attempting to deploy a commit to the Cain's projects Team on Vercel. A member of the Team first needs to authorize it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Best to just run
pnpm devand see the changes