Skip to content

INTERMEDIO - feature/#73-Funcionalidad-reset-password-en-Editar-Usuario-a-mock-server #75

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 4 commits into
base: main
Choose a base branch
from

Conversation

manugallegob
Copy link
Collaborator

No description provided.

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 implements the reset password functionality for editing a user on a mock server, adding new UI components, API integrations, and mutation hooks.

  • Introduces a new react-query mutation hook (useUpdateUserPasswordMutation) for updating a user's password.
  • Updates related UI components to trigger a confirmation dialog and display success/error alerts upon password reset.
  • Adds API integration and exports new alert components and dialog components.

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/modules/users/edit-reset-password/edit-reset-password.query.hook.ts Adds a mutation hook for password update.
src/modules/users/edit-reset-password/edit-reset-password.pod.tsx Passes user ID prop to the reset password component.
src/modules/users/edit-reset-password/edit-reset-password.component.tsx Implements UI logic and integrates confirmation dialog and alert components.
src/modules/users/edit-reset-password/components/index.ts Updates exports to include new alert component.
src/modules/users/edit-reset-password/components/confirm-reset-dialog.component.tsx Modifies the reset dialog to use the onConfirm handler and displays a spinner.
src/modules/users/edit-reset-password/components/alerts-reset-password.componet.tsx Introduces new success/error alert components.
src/modules/users/edit-reset-password/api/edit-reset-password.api.ts Adds API call for updating the user password.
Comments suppressed due to low confidence (1)

src/modules/users/edit-reset-password/edit-reset-password.query.hook.ts:9

  • The hook is named 'useUpdateUserPasswordMutation' but returns an object with the property 'savePassword'. Consider renaming 'savePassword' to 'updatePassword' (or vice versa) for consistency.
interface UseSavePasswordMutationResult {

@@ -0,0 +1,25 @@
import React from 'react';
Copy link
Preview

Copilot AI Apr 25, 2025

Choose a reason for hiding this comment

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

The file name 'alerts-reset-password.componet.tsx' appears to contain a typographical error. Consider renaming it to 'alerts-reset-password.component.tsx'.

Copilot uses AI. Check for mistakes.

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.

[Front End] Funcionalidad reset password en Editar Usuario a mock server
2 participants