Skip to content

Conversation

nikgraf
Copy link
Collaborator

@nikgraf nikgraf commented Jun 5, 2025

No description provided.

Copy link

vercel bot commented Jun 5, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
hypergraph-connect ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 12, 2025 11:54am
hypergraph-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 12, 2025 11:54am

@nikgraf nikgraf marked this pull request as draft June 5, 2025 17:01
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from b38d376 to a3d4591 Compare June 6, 2025 06:57
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from a3d4591 to 38f33b0 Compare June 6, 2025 07:20
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 38f33b0 to 9b8fd31 Compare June 6, 2025 11:51
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 9b8fd31 to 33d775e Compare June 9, 2025 05:32
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 33d775e to a9e20a6 Compare June 9, 2025 08:15
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from a9e20a6 to a0daa2a Compare June 9, 2025 10:31
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from a0daa2a to e1e4eb7 Compare June 9, 2025 10:58
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from e1e4eb7 to 5890f92 Compare June 10, 2025 13:29
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 5890f92 to 2882642 Compare June 11, 2025 11:38
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 18f8f82 to 1687b88 Compare June 12, 2025 06:54
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 1687b88 to 106d6a0 Compare June 12, 2025 10:04
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 106d6a0 to 79e652b Compare June 12, 2025 10:09
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 79e652b to 93dc741 Compare June 12, 2025 10:12
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 93dc741 to d8c1ee9 Compare June 12, 2025 10:18
@nikgraf nikgraf force-pushed the ng/connect-app-features branch from d8c1ee9 to 8595257 Compare June 12, 2025 11:03
@nikgraf nikgraf requested a review from Copilot June 12, 2025 11:07
@nikgraf nikgraf marked this pull request as ready for review June 12, 2025 11:09
@nikgraf nikgraf requested a review from pcarranzav June 12, 2025 11:09
Copy link
Contributor

@Copilot 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 removes the deprecated wallet export feature from the Events app, updates its routing to include an authentication success page, and fully integrates Hypergraph‐based authentication and space management in the Connect app.

  • Events app
    • Adds /authenticate-success route and skips redirect there
    • Removes the export‐wallet link and Privy context provider
    • Displays full user address instead of truncated account ID
  • Connect app
    • Implements Privy + Hypergraph login flow (auto‐login on mount)
    • Adds space creation and listing components communicating with the Connect API
    • Updates routing, Vite, and TypeScript configs for new endpoints

Reviewed Changes

Copilot reviewed 137 out of 137 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
apps/events/src/routes/__root.tsx Adjusted redirect logic and replaced truncated ID with address
apps/events/src/Boot.tsx Removed PrivyProvider wrapper (authentication context)
apps/connect/src/routes/login.lazy.tsx Extended Privy login effect to auto-authenticate with Hypergraph
apps/connect/src/components/create-space.tsx New CreateSpace component with loading state and fetch logic
apps/connect/src/components/spaces.tsx New Spaces component to list existing spaces
apps/connect/src/routeTree.gen.ts Added /authenticate virtual route for the Connect app
Comments suppressed due to low confidence (1)

apps/events/src/Boot.tsx:2

  • The PrivyProvider was removed, but components like login and logout still depend on usePrivy. Wrap the app in PrivyProvider (or another auth provider) so usePrivy hooks have context.
import { HypergraphAppProvider } from '@graphprotocol/hypergraph-react';

const createSpace = async () => {
setIsLoading(true);
if (!accountAddress || !keys || !identityToken) {
console.error('Missing required fields', { accountAddress, keys, identityToken });
Copy link

Copilot AI Jun 12, 2025

Choose a reason for hiding this comment

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

Early return on missing fields leaves isLoading set to true. Move setIsLoading(false) into this branch or wrap the function body in a try/finally to always reset loading.

Suggested change
console.error('Missing required fields', { accountAddress, keys, identityToken });
console.error('Missing required fields', { accountAddress, keys, identityToken });
setIsLoading(false);

Copilot uses AI. Check for mistakes.

queryKey: ['spaces'],
queryFn: async () => {
if (!identityToken) return;
const response = await fetch('http://localhost:3030/connect/spaces', {
Copy link

Copilot AI Jun 12, 2025

Choose a reason for hiding this comment

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

Hardcoded API endpoint URL. Extract the base URI to an environment variable or shared config to ease future changes and environment switching.

Suggested change
const response = await fetch('http://localhost:3030/connect/spaces', {
const response = await fetch(`${process.env.REACT_APP_API_BASE_URL}/connect/spaces`, {

Copilot uses AI. Check for mistakes.

name: spaceName,
};

const response = await fetch('http://localhost:3030/connect/spaces', {
Copy link

Copilot AI Jun 12, 2025

Choose a reason for hiding this comment

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

Hardcoded fetch URL—consider using an env var (e.g. import.meta.env.VITE_API_BASE) or a shared HTTP client for consistency with other calls.

Copilot uses AI. Check for mistakes.

@nikgraf nikgraf force-pushed the ng/connect-app-features branch from 8595257 to d050c01 Compare June 12, 2025 11:53
@nikgraf nikgraf merged commit 7d9f306 into main Jun 12, 2025
7 checks passed
@nikgraf nikgraf deleted the ng/connect-app-features branch June 12, 2025 12:01
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