Skip to content

edited the connection to put the user into the db #9

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: dev
Choose a base branch
from

Conversation

Maxe-afk
Copy link
Collaborator

No description provided.

@Maxe-afk Maxe-afk requested review from Benja-san and Jerome0510 June 27, 2025 07:29
@Benja-san Benja-san requested a review from Copilot June 27, 2025 09:48
Copy link

@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 updates the connection logic for user sign-in by inserting new user records into the database and makes several UI and styling adjustments across the application.

  • Updated login UI to include icon-based sign out and user profile picture
  • Added signIn callback logic to insert users into the database if they do not exist
  • Made various CSS and layout adjustments, and introduced an empty HistoryContext component and middleware for redirects

Reviewed Changes

Copilot reviewed 10 out of 12 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
src/ui/login.tsx Updated login UI to include new logout image and profile picture
src/ui/Login.module.css Adjusted styling for logout button and profile picture positioning
src/context/UseSessionContext.tsx Contains commented-out user context code
src/context/Historycontext.tsx Added an empty HistoryContext component
src/app/page.module.css Modified background image, sizing, and font sizes for home page styles
src/app/layout.tsx Commented out usage of UserProvider
src/app/history/history.module.css Adjusted font weights, sizes, and dimensions for history page
src/app/api/auth/[...nextauth]/route.ts Updated signIn callback to insert missing user records into the db
src/app/a-propos/About.module.css Updated about page styling dimensions and font weights
middleware.ts Added middleware to redirect /about paths to '/home'

import NextAuth, { NextAuthOptions } from "next-auth";
import GoogleProvider from "next-auth/providers/google";

type UserRow = {
Copy link
Contributor

Choose a reason for hiding this comment

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

shift this type into a model in order to use it everywhere

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.

2 participants