This repository was archived by the owner on Mar 1, 2025. It is now read-only.
show relevant options for buttons#481
Open
muskanbatra-dev wants to merge 1 commit intoRealDevSquad:developfrom
Open
show relevant options for buttons#481muskanbatra-dev wants to merge 1 commit intoRealDevSquad:developfrom
muskanbatra-dev wants to merge 1 commit intoRealDevSquad:developfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
vinayak-trivedi
suggested changes
Nov 5, 2022
Contributor
vinayak-trivedi
left a comment
There was a problem hiding this comment.
Thanks for the PR @muskanbatra-dev
Requesting one change, and also please add test cases for the changes
Comment on lines
+45
to
+59
| if (isUserMember) { | ||
| return ( | ||
| <> | ||
| <button | ||
| className={classNames.moveToMember} | ||
| type="button" | ||
| onClick={() => archiveTheMember(selectedMember)} | ||
| > | ||
| Archive Member | ||
| </button> | ||
| <br /> | ||
| <p>{updateStatus}</p> | ||
| </> | ||
| ); | ||
| } |
Contributor
There was a problem hiding this comment.
we need only one button when the user is a member, so instead of repeating yourself, you can put a condition below where the promote to member button only shows up if the user is not a member, also can you change the text in the button to archive user if the user is not a member
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is the change?
when the super clicks on the setting button to update the role of an existing member he should see only the archive member option.
when he clicks on non-member he should see promote to member and archive button.
Is it a bug?
No
*Dev Tested?
No
*Tested on:
Platforms
Browsers
Chrome
Safari
Firefox
Before Change Screenshots
Before:
https://www.loom.com/share/cd25966dbd9943da866b34d8efe85b94
After:
https://www.loom.com/share/2a58206fc7ba452aab4aa2e2822db5de