Merged
Conversation
- forge-std v1.14.0 - openzeppelin-contracts v5.5.0
- Add GitHub Actions workflow for PRs (format, lint, build, test) - Add solhint for Solidity linting with gas optimization rules - Add fix:web and fix:contracts scripts - Update README with dependencies and commands table
- Read NIL_TOKEN_ADDRESS from environment (required) - Add optional DRIP_AMOUNT and COOLDOWN_SECONDS with defaults - Removes hardcoded token address for flexibility across networks
- Add docker-compose.yml with nil-anvil service - Add deploy-faucet.sh script that waits for anvil, deploys faucet, funds it - Add README with usage instructions and test account info
- Add wagmi config with Sepolia and Anvil chains - Add contract ABI and address resolution per chain - Add useFaucetStatus hook for reading faucet state - Add useClaim hook for claim transactions - Add FaucetCard component with claim flow UI - Add shadcn/ui button and card components
- Update layout with RainbowKit and React Query providers - Update page with FaucetCard and network switcher - Add docker:up, docker:down, docker:deploy scripts - Add .env.example with configuration docs
- Replace custom anvil chain definition with wagmi's built-in - Hide ETH balance in ConnectButton (not relevant for faucet UX)
- Add contracts/ to oxlint ignorePatterns - Replace unsafe type assertions with proper type guard
- Source .env file in deploy script if it exists - If DEV_WALLET is set, fund that address with 10 ETH for gas - Document DEV_WALLET in .env.example
- Track shown toasts by txHash to prevent spam on re-renders - Use formatTimeRemaining for human-readable cooldown (e.g. "1m" instead of "0.016h")
- Add Nillion logo from nilpay - Update primary color to Nillion indigo (#4f46e5) - Add subtle grid background pattern - Support light and dark mode with appropriate color variants
Replace faucet balance with user-centric stats: NIL balance, times claimed, and last claimed timestamp. Add explorer links for faucet and token contracts. Clean up gitignore and README formatting.
- Restructure card: balance hero, claim button, collapsible details
- Show network name in balance label ("on the Sepolia network")
- Hide header connect button when not connected (avoid duplication)
- Make Anvil network dev-only (NODE_ENV check)
- Soften card border and details divider (50% opacity)
- Add favicon using Nillion logo
- Update metadata description
Migrate from wagmi v2 to v3 API - useAccount is now useConnection.
- Move drip amount and cooldown into collapsible Details section
- Add polling interval (1s) to fix stuck transaction pending state
- Only show pending when txHash exists
- Use human readable durations ("1 minute" instead of "1m")
- Refetch canClaim when client-side countdown ends - On Anvil only, override canClaim when cooldown timer reaches 0 (block.timestamp doesn't advance without transactions) - On real networks, trust contract's canClaim to avoid reverted txs - Migrate useClaim to write.mutate() pattern (wagmi v3) - Simplify UI text and remove redundant elements
- Consolidate countdown useEffects into single effect with proper cleanup - Extract AddressLink component to eliminate duplicate anchor markup - Add React.memo to ClaimButton for render optimization - Move truncateAddress to format.ts and ANVIL_CHAIN_ID to contracts.ts - Add JSDoc comments to useClaim and useFaucetStatus hooks - Add SSR guard for window.open() in toast action - Remove unused card component exports (CardTitle, CardAction, CardFooter) - Remove debug console.log statement - Improve WalletConnect project ID documentation
Document the full deployment workflow including environment variables, forge script commands, frontend configuration, and admin functions.
Use the same background images and colors as bridge.nillion.network: - Light mode: light gray with decorative background image - Dark mode: deep purple with luminosity blend mode - White title text to contrast against colorful backgrounds
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Instead of hardcoding token addresses per chain, read the TOKEN() address directly from the faucet contract. This removes configuration duplication since the faucet already knows its token.
Prevents showing a disabled claim button when data hasn't loaded yet (e.g. when faucet is empty but canClaim hasn't returned yet).
- next 16.1.4 → 16.1.5 - react/react-dom 19.2.3 → 19.2.4 - viem 2.44.4 → 2.45.0 - oxlint 1.41.0 → 1.42.0 - pnpm 10.28.0 → 10.28.2
- Track loading state from both useReadContract (token) and useReadContracts (main data) to prevent flash of incomplete UI - Show loading when waiting for token address to enable main query - Fix ESLint no-unsafe-type-assertion by using proper type guards with 'in' operator and typeof checks for canClaim result
- Remove duplicate loading indicators from ClaimButton - Add FaucetCardContent component to handle loading/error/ready states - Show single card-level spinner while contract data loads - Display user-friendly error message if contract read fails
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.
No description provided.