Skip to content

Comments

Feat/staking pool frontend#150

Merged
camembera merged 38 commits intomainfrom
feat/staking-pool-frontend
Feb 10, 2026
Merged

Feat/staking pool frontend#150
camembera merged 38 commits intomainfrom
feat/staking-pool-frontend

Conversation

@camembera
Copy link
Contributor

@camembera camembera commented Feb 9, 2026

TLDWR check out https://bepolia-pools.vercel.app/

Stack

  • Replaced React/JSX app with Vue 3 + Vite

Configuration and Branding

  • Single-pool mode: serves a FE for one pool, set in the config; Discovery mode: discovers pools from API+chain
  • CONFIG_GUIDE.md: network presets, pool config, branding, theme with samples.
  • Sample deploy configs: config.deploy.bepolia.json, config.deploy.mainnet.json, etc
  • Placeholder/fake logos in public/branding/ for demos and theming.

User-Facing Features

  • Pool discovery: list pools from chain/API; sections by Active / Inactive / Exited / Dead
  • Single-pool staking: stake BERA → stBERA; real-time pool data.
  • Withdrawals: request and finalize withdrawals; queue view.
  • Wallet: MetaMask, WalletConnect, etc. via shared WalletConnect.vue
  • Deep links: routing to a specific pool/view.
  • Nosy mode: read-only "dashboard" for a pool. Scans chain history with getLogs to identify interesting events and shareholders

Docs and Deployment

  • DEPLOYMENT.md: clone → config → build → Vercel or nginx
  • DEVELOPER_GUIDE.md: dev workflow, structure, testing.
  • CONFIG_GUIDE.md: full config reference (see README).
  • Vercel: .vercelignore and config for Vite SPA.

Testing

26 e2e tests with playwright and a mock wallet

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR replaces the existing staking pools frontend with a Vue 3 + Vite SPA and adds supporting configuration, utilities, and automated tests to support single-pool and discovery modes (plus optional “Nosy mode” scanning).

Changes:

  • Migrates the frontend from React/JSX to Vue 3 (Vite + Vue plugin) with updated runtime config handling and theming.
  • Adds unit tests (Vitest) and E2E tests (Playwright) plus enhanced wallet/contract mocking helpers.
  • Updates installer helper to generate a Vue-compatible public/config.draft.json for single-pool deployments.

Reviewed changes

Copilot reviewed 97 out of 109 changed files in this pull request and generated 19 comments.

Show a summary per file
File Description
apps/staking-pools/install-helpers/generate-frontend-config.sh Updates generated config output path/schema for the new Vue frontend.
apps/staking-pools/frontend/vite.config.js Switches Vite plugin to Vue and updates dev server settings.
apps/staking-pools/frontend/vitest.config.js Adds Vitest config for unit tests.
apps/staking-pools/frontend/src/utils/shareholderFromEvents.js Adds shareholder registry computation for Nosy-mode cached events.
apps/staking-pools/frontend/tests/unit/shareholderFromEvents.spec.js Adds unit tests for shareholder registry computation.
apps/staking-pools/frontend/tests/unit/errors.spec.js Adds a placeholder unit test for errors module.
apps/staking-pools/frontend/tests/helpers/pool-scenarios.js Adds reusable E2E scenario/mocks based on live-ish pool data.
apps/staking-pools/frontend/tests/helpers/mock-wallet-enhanced.js Adds enhanced mock wallet transport for deterministic E2E.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

- Add gap-fill logic to scan between maxCachedBlock and chain tip on resume
- Fix missing factoryAddr parameter in runTipScan causing TypeError
- Add debug logging for cached events and ranges
Replace janky .includes('exited') patterns with structured helpers
- Remove unused imports and variables across test helpers
- Replace redundant null checks (v == null || v === undefined) with idiomatic v == null
- Fix BigInt precision loss in pool-scenarios (use formatEther)
- Add real assertion to errors.spec.js unit test
- Set vite server.open to false to avoid unwanted browser launches
- Use validator status helpers instead of string comparisons
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 99 out of 111 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

camembera and others added 3 commits February 9, 2026 22:09
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Camembera <camembear@berachain.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Camembera <camembear@berachain.com>
@camembera camembera merged commit fab1180 into main Feb 10, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant