Skip to content
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

Profile Settings Modal has no feedback for user data loading state #179

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

madhav-relish
Copy link

@madhav-relish madhav-relish commented Aug 15, 2024

  • A custom skeleton component is added which can be used further
  • Two loading states are there one for when the profile details are loading and the other when the user submits the form
  • Submit button is disabled when profile details are loading

Fixes: #177

  • What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)

  • Profile Settings Modal has no feedback for user data loading state

  • Why was this change needed? (You can also link to an open issue here)

  • Issue Profile Settings Modal has no feedback for user data loading state #177

  • When the user opens the settings modal they have no indications about the data being loaded

  • When the user saves their changes, again there is no feedback for the user that the form is getting submitted which might cause them to hit the save button again and again.

  • When the profile details are loading the user can still hit the save button without noticing anything, so hence that is disabled now as well till the loading is done

  • Other information:

I saw Mantine as a dependency but I don't think it is being used anywhere in the whole project. Why are we not leveraging it, any specific reasons?

- A custom skeleton component is added which can be used further
- Two loading states are there one for when the profile details are
  loading and the other when the user submits the form
Copy link

vercel bot commented Aug 15, 2024

@madhav-relish is attempting to deploy a commit to the Listinai Team on Vercel.

A member of the Team first needs to authorize it.

@madhav-relish madhav-relish changed the title Fix: #177 Loading state in profile setting modal Fixes: #177 Profile Settings Modal has no feedback for user data loading state Aug 15, 2024
@madhav-relish madhav-relish changed the title Fixes: #177 Profile Settings Modal has no feedback for user data loading state Fixes #177 : Profile Settings Modal has no feedback for user data loading state Aug 15, 2024
@nevo-david
Copy link
Contributor

Hi @madhav-relish, mantine modals are being used everywhere

@madhav-relish
Copy link
Author

Hi @nevo-david Didn't see much of mantine/core being used, otherwise I would've used the skeleton from that only. Let me know if you need any changes in this PR.

@jamesread
Copy link
Collaborator

@madhav-relish , would you mind resolving the merge conflict? Thanks.

@jamesread jamesread changed the title Fixes #177 : Profile Settings Modal has no feedback for user data loading state Profile Settings Modal has no feedback for user data loading state Sep 9, 2024
@madhav-relish
Copy link
Author

Sure, will do!

@jamesread
Copy link
Collaborator

@madhav-relish , many thanks, I've just approved the CI to run.

I'll let @nevo-david decide on if this is the right direction for the code for now, as I'm mostly focussing on infrastructure stuff :-)

Comment on lines +167 to +171
<img
src={picture?.path}
alt="profile"
className="w-full h-full rounded-full"
/>

Check warning

Code scanning / ESLint

Prevent usage of `<img>` element due to slower LCP and higher bandwidth. Warning

Using <img> could result in slower LCP and higher bandwidth. Consider using <Image /> from next/image to automatically optimize images. This may incur additional usage or cost from your provider. See: https://nextjs.org/docs/messages/no-img-element
@madhav-relish
Copy link
Author

@madhav-relish , many thanks, I've just approved the CI to run.

I'll let @nevo-david decide on if this is the right direction for the code for now, as I'm mostly focussing on infrastructure stuff :-)

Alrighty! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Profile Settings Modal has no feedback for user data loading state
3 participants