-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Feature/35712 redesign of members list #37074
Feature/35712 redesign of members list #37074
Conversation
cc: @Expensify/design |
@shawnborton i wonder if we should also use the new Badge design here? |
Looking pretty good! Totally agree that we should use the new badge component. Has that been merged into main yet? I would think that the "Role" heading would be right-aligned since it's the last column. It also feels like each row has too much padding-right - I would expect the badge to be further over to the right. How much right-padding is currently being applied? |
@shawnborton What is the new badge and where can I find it? Regarding alignment - I recall a long discussion (first in the Proposal document, and later in Slack) and I thought there was a conclusion that the last column should be aligned left and it was finally reflected in Figma. |
Ah okay, you can ignore me then. cc @trjExpensify @JmillsExpensify @Expensify/design for confirmation. Can you show me how much right padding is being used though? |
If you pull main, perhaps the new badge component should be there already. |
<Text style={styles.peopleBadgeText}>{props.translate('common.admin')}</Text> | ||
</View> | ||
) : null, | ||
rightElement: roleBadge, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
App/src/components/MenuItem.tsx
Lines 574 to 583 in 29ad878
<Badge | |
text={badgeText} | |
textStyles={styles.textStrong} | |
badgeStyles={[ | |
styles.alignSelfCenter, | |
styles.badgeBordered, | |
brickRoadIndicator ? styles.mr2 : undefined, | |
focused || isHovered || pressed ? styles.activeItemBadge : {}, | |
badgeStyle, | |
]} |
@shawnborton the last "column" (which is not an actual column because in fact it is not a table) has a fixed width of 60px and right-margin of 16px; the wrapper has padding of 16px so putting this together the badge is 32px far from the right edge of the item container (in Figma it is 29px from the right edge, so I guess it's quite random, but I could change the right margin of the badge to 12px so it would be 30px from the edge then) regarding badge styles - is one of the below designs what we are looking for?: |
@shawnborton Alright, fixed the badge - thanks. It looks like below now: |
@shawnborton I'm down to standardize the padding for "tables" everywhere (here, money page, tags, categories, etc.). Your most recent "tightened spacing" for the money page had the padding at 12px—do we want to standardize on 12px or 16px? I'm good either way, I kinda just want them to be the same for all of these types of rows. Also, this "Role" column label still looks misaligned to me (I realize it is technically properly aligned left, but I think it looks weird). I think we need to center align the column header like we're doing for the "Action" column on the money page designs. |
Yes, it is minor, can be handled later. |
@dannymcclain I think I am team 16px right now, will tag ya in Figma where I'm using that currently. |
|
Thanks for the reviews so far! @burczu would you mind addressing the latest comments and fixing the conflict so we can get this merged today? |
@getusha your comments addressed + storybook updated |
Reviewer Checklist
Screenshots/Videos |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are a couple of small issues, but I think we can address those in a follow up since this PR unblocks Categories main page and the whole dependency chain of issues there.
@@ -195,6 +195,7 @@ export default { | |||
iAcceptThe: 'Acepto los ', | |||
remove: 'Eliminar', | |||
admin: 'Administrador', | |||
owner: 'Poseedor', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NAB I think this should be Dueño
}; | ||
const getHeaderContent = () => ( | ||
<> | ||
<Text style={[styles.pl5, styles.mb5, styles.mt3]}>{translate('workspace.people.membersListTitle')}</Text> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NAB I think this text should use textSupporting
color
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me!
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/luacmartins in version: 1.4.44-0 🚀
|
🚀 Deployed to production by https://github.com/puneetlath in version: 1.4.44-13 🚀
|
pressableStyle={[[styles.selectionListPressableItemWrapper, isFocused && styles.activeComponentBG]]} | ||
wrapperStyle={[styles.flexRow, styles.flex1, styles.justifyContentBetween, styles.userSelectNone, styles.alignItemsCenter, isFocused && styles.sidebarLinkActive]} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi team, come from this issue #37293:
- For a focused background in this case, we should use
styles.sidebarLinkActive
- We don't need to add
isFocused
style inwrapperStyle
otherwise it causes the above bug.
const isAdmin = session?.email === details.login || policyMember.role === CONST.POLICY.ROLE.ADMIN; | ||
|
||
let roleBadge = null; | ||
if (isOwner || isAdmin) { | ||
roleBadge = ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The badge wasn't being styled properly when removing admin while offline in the native apps: #37776
Details
In this PR the list of members displayed on the Workspace Members Page is re-designed to match the new design.
The new design for reference:
Fixed Issues
$ #35712
PROPOSAL: https://docs.google.com/document/d/1gk3xqOs7epMbUrSSiX8K7YcqfPLVgqEos0sf-D-GMDA/edit#heading=h.qjcht79r25s1
Tests
Offline tests
Same as above.
QA Steps
Same as above.
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop