-
Notifications
You must be signed in to change notification settings - Fork 8
Web/feature/user overview v2 #164
base: develop
Are you sure you want to change the base?
Conversation
* master: Translation updates (#170) Fixed some miswording in the handbook (#168) Removed a redundant word (#166) Web/chore/profile i18n keys (#138) # Conflicts: # components/UserOverview/UserOverview.test.tsx # features/profile/view/Overview.tsx # features/profile/view/leaveReference/LeaveReferencePage.tsx
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.
This looks great! Sorry it took so long to review!
Just some minor nits that are not particularly important.
@@ -52,12 +52,17 @@ const useStyles = makeStyles((theme) => ({ | |||
flexDirection: "column", | |||
justifyContent: "center", | |||
alignItems: "stretch", | |||
padding: theme.spacing(0.5), | |||
padding: "0px", |
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.
padding: "0px", | |
padding: 0, |
}, | ||
"& > button": { | ||
fontWeight: "bold", | ||
padding: theme.spacing(1.6), |
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.
Why 1.6? If it's to pixel-match figma I'd probably leave it as 1.5 for consistency (we tend to try to have all uses of spacing in 0.5 increments)
</Typography> | ||
<Typography variant="body1" className={classes.intro}> | ||
{user.city} | ||
<Typography variant="h1" className={classes.intro} align={"left"}> |
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.
<Typography variant="h1" className={classes.intro} align={"left"}> | |
<Typography variant="h1" className={classes.intro} align="left"> |
</Typography> | ||
<Typography | ||
color={"textSecondary"} |
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.
color={"textSecondary"} | |
color="textSecondary" |
{actions && ( | ||
<CardActions className={classes.cardActions}>{actions}</CardActions> | ||
)} | ||
<Typography color={"primary"} variant="body1" className={classes.intro}> |
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.
<Typography color={"primary"} variant="body1" className={classes.intro}> | |
<Typography color="primary" variant="body1" className={classes.intro}> |
@@ -1,10 +1,10 @@ | |||
import Alert from "components/Alert"; | |||
import Button from "components/Button"; | |||
import UserOverview from "components/UserOverview/UserOverview"; |
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.
import UserOverview from "components/UserOverview/UserOverview"; | |
import UserOverview from "components/UserOverview"; |
Since you added the index file
@@ -1,10 +1,10 @@ | |||
import Hidden from "@material-ui/core/Hidden"; | |||
import Alert from "components/Alert"; | |||
import CircularProgress from "components/CircularProgress"; | |||
import UserOverview from "components/UserOverview/UserOverview"; |
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.
import UserOverview from "components/UserOverview/UserOverview"; | |
import UserOverview from "components/UserOverview"; |
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.
@@ -2,7 +2,7 @@ import { Meta, Story } from "@storybook/react"; | |||
import { User } from "proto/api_pb"; | |||
import users from "test/fixtures/users.json"; | |||
|
|||
import { ProfileUserProvider } from "../hooks/useProfileUser"; | |||
import { ProfileUserProvider } from "../../features/profile/hooks/useProfileUser"; |
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.
We should prefer absolute imports here when it's more than one level of .
or ..
to ease future changes if needed rather than having to guess how many ..
levels to go up.
import { | ||
hostingStatusLabels, | ||
meetupStatusLabels, | ||
} from "../../features/profile/constants"; | ||
import { ProfileUserProvider } from "../../features/profile/hooks/useProfileUser"; |
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.
Same comment on absolute import as before
import { useProfileUser } from "../../features/profile/hooks/useProfileUser"; | ||
import { | ||
ReferencesLastActiveLabels, | ||
ResponseRateLabel, | ||
} from "../../features/profile/view/userLabels"; |
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.
Same comment on absolute import as before
@iamseye How are you getting on with this? Will you have time to wrap this up? |
Related to Couchers-org/couchers#4139
userOverview
components to the component folderuserOverview
Noted, left some questions for design. still looks very different from the design: https://www.figma.com/file/z1aQUklCQewLsEFUo2HsLz/Desktop-Mockups?node-id=9722%3A63431
Web frontend checklist
make format
make lint