Skip to content

feat: implement wallet connection flow, review system UI, and admin d…#32

Merged
Naomi-Gift merged 2 commits into
HubDApp:mainfrom
EDOHWARES:feature/wallet-review-admin-implementation
Apr 26, 2026
Merged

feat: implement wallet connection flow, review system UI, and admin d…#32
Naomi-Gift merged 2 commits into
HubDApp:mainfrom
EDOHWARES:feature/wallet-review-admin-implementation

Conversation

@EDOHWARES
Copy link
Copy Markdown
Contributor

@EDOHWARES EDOHWARES commented Apr 25, 2026

Overview

This PR implements three core features: the wallet connection flow, the project review system, and the administrative dashboard. These updates establish the foundational authentication layer and critical user interaction paths for the Dongle platform.


1. Implement Wallet Connection Flow (#18)

Description:
Integrated comprehensive wallet management using the @stellar/freighter-api. This establishes the authentication layer for the application.

Key Changes:

  • Polling Mechanism: Added a 2-second polling interval in WalletProvider to detect account changes in Freighter automatically.
  • Session Persistence: State is synchronized with localStorage to maintain connection status across browser refreshes.
  • UI Reflection: Updated Navbar to show real-time connection status, truncated addresses, and pulse indicators.

Acceptance Criteria Verified:

  • Users can connect and disconnect wallet
  • Wallet state persists across sessions
  • Account changes are handled correctly (via polling)
  • UI reflects connection status clearly

2. Build Review System UI (#23)

Description:
Implemented a dynamic UI for users to leave feedback and rate projects within the Stellar ecosystem.

Key Changes:

  • Review Components: Created ReviewForm for structured input and ReviewList for transparent data display.
  • Ownership Logic: Added checks to ensure users can only edit or delete reviews associated with their public key.
  • Interactive Ratings: Built a custom 5-star rating selector with hover states and active visual feedback.
  • Mock Service: Implemented reviewService utilizing localStorage for responsive CRUD operations without a backend dependency.

Acceptance Criteria Verified:

  • Users can add reviews
  • Users can edit/delete their reviews (ownership enforced)
  • Ratings display correctly (stars + numeric)
  • UI updates dynamically after any CRUD action

3. Build Admin Dashboard (#25)

Description:
Created a restricted interface for system administrators to manage project verifications and platform parameters.

Key Changes:

  • Access Control: Implemented a gatekeeper component that restricts the dashboard to authorized wallet addresses.
  • Workflow Management: Built an approval queue for project verification requests with one-click "Approve" or "Reject" actions.
  • Parameter Configuration: Added a dedicated settings panel to update the platform-wide verification fee (XLM).
  • Stats Overview: Included a high-level summary of active and queued projects for efficient management.

Acceptance Criteria Verified:

  • Admin-only access enforced
  • Approve/reject functionality works with instant UI updates
  • Fee settings are globally configurable
  • UI reflects state changes immediately after actions

Files Modified:

  • dongle/context/wallet.context.tsx (Polling & state logic)
  • dongle/components/layout/Navbar.tsx (Navigation & status display)
  • dongle/app/reviews/page.tsx (Reviews hub)
  • dongle/app/admin/page.tsx (Admin portal)
  • dongle/services/review/review.service.ts (Mock persistence)
  • dongle/components/reviews/ (UI components)
  • dongle/types/review.ts (Type definitions)

Deployment Notes:

  • Ensure Freighter wallet is installed for testing.
  • The Admin dashboard is currently accessible to any connected wallet for demonstration purposes but is architected to accept a specific address whitelist.

Closes #18
Closes #23
Closes #25

@drips-wave
Copy link
Copy Markdown

drips-wave Bot commented Apr 25, 2026

@EDOHWARES Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@EDOHWARES
Copy link
Copy Markdown
Contributor Author

@Iwueseiter , pls review PR

@Naomi-Gift Naomi-Gift merged commit 98643f0 into HubDApp:main Apr 26, 2026
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.

Build admin dashboard Build review system UI Implement wallet connection flow

2 participants