Skip to content

feat(authentication): replace HTML elements with UI components - #1168

Open
sartek430 wants to merge 3 commits into
developfrom
243-featfront-remake-the-oauth-page-component-with-toolkit-buttons
Open

feat(authentication): replace HTML elements with UI components#1168
sartek430 wants to merge 3 commits into
developfrom
243-featfront-remake-the-oauth-page-component-with-toolkit-buttons

Conversation

@sartek430

Copy link
Copy Markdown
Contributor

refactor Authentication, OAuth, SignUp, Error, Dashboard, and Welcome pages to use Heading and Link components for improved consistency and maintainability.

sartek430 added 3 commits July 24, 2026 07:39
Refactor the OAuth component to use Heading and Link components for better consistency and accessibility. Update the worker setup in the mock service worker to include authentication status handlers.
refactor Authentication, OAuth, SignUp, Error, Dashboard, and Welcome pages to use Heading and Link components for improved consistency and maintainability.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Confidence: 97%.

Refactors several frontend pages/components to use shared UI atoms (notably Heading and Link) and adjusts MSW/browser-test authentication defaults to improve consistency and test reliability.

Changes:

  • Replaced raw heading tags with the shared Heading component across multiple pages/components.
  • Updated OAuth provider links to use the shared Link component.
  • Improved browser-test determinism by registering an auth-status MSW handler by default and setting per-test auth state where needed.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
front/src/pages/Home/Welcome/Welcome.tsx Uses Heading atom for the page title.
front/src/pages/Home/Dashboard/Dashboard.tsx Minor import ordering cleanup (no functional change).
front/src/pages/Home/Dashboard/tests/Dashboard.browser.test.tsx Ensures auth status is mocked as authenticated for this browser test.
front/src/pages/Error/Error.tsx Uses Heading atom for the error page title.
front/src/pages/Authentication/SignUp/SignUp.tsx Replaces native inputs/button with TextInput and Button components.
front/src/pages/Authentication/OAuth/OAuth.tsx Uses Heading + Link atoms for OAuth provider list.
front/src/pages/Authentication/Authentication.tsx Uses Heading atom for the page title.
front/src/components/AuthenticationProtection/AuthenticationProtection.tsx Simplifies current-route match selection.
front/mocks/browser.ts Registers a default MSW auth-status handler for browser runtime/tests.

Comment thread front/mocks/browser.ts
Comment on lines +2 to +5
import {
getAuthStatus200,
getAuthStatus401,
} from "./handlers/authStatusHandlers";

@GuillaumeKESTEMAN GuillaumeKESTEMAN Jul 25, 2026

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Dans le mock browser il faut laisser le getAuthStatus200 et non le 401 car c'est celui le plus couramment utilisé. (que ce soit pour naviguer en mode mock dans l'appli ou pour les tests d'intégration)

>
<label htmlFor="username">{t("username")}</label>
<input
<TextInput

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

on utilisera des TextField ici mais on verra ça plus tard, tu peux laisser comme ça

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

L'objectif de cette issue n'est pas juste de remplacer les balises temporaires que j'avais mis par des composants du toolkit.
C'est aussi que la partie OAuth ressemble désormais à la maquette 😅

D'ailleurs c'est là que je me rends compte qu'on a pas de variant sur le ClickIcon pour rajouter un encadré.
Si tu veux tu peux faire cette modif et utiliser un ClickIcon avec la propriété as pour que ce soit une balise de lien et tu pourras garder les props que tu as actuellement.

Voici l'attendu :

Image

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.

feat(front): remake the OAuth page component with toolkit buttons and make the page like the expected model

3 participants