-
Notifications
You must be signed in to change notification settings - Fork 65
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
📝 Typography documentation #2247
Conversation
b91d4ff
to
c74b725
Compare
@@ -8,7 +8,7 @@ const StyledDialogHeader = styled.div(({ theme }) => { | |||
return css` | |||
display: flex; | |||
justify-content: space-betweene; |
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 one is also typoed 🙃
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.
done
</ul> | ||
|
||
Please do not use <code>light</code> in digital interfaces except in special cases where the font size is over <code>48px</code>. | ||
|
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.
Perhaps a note about how the equinor font is not included in eds by default and has to be added (and how)
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.
Agree
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.
done
grid-gap: 32px; | ||
justify-items: start; | ||
const SBCard = styled(Card)` | ||
border: 1px solid ${mossgreen100}; |
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.
Suggest removing the border and maybe using the elevation
prop on Card
instead?
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.
done
const SBCard = styled(Card)` | ||
border: 1px solid ${mossgreen100}; | ||
max-width: 290px; | ||
display: table-cell; |
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 do you need to set table-cell
for Card?
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.
trash, is done
storyDescription: | ||
'Variants ordered by their required group parameter. Example `<Typography group="input" variant="label"></Typography>`. Variants under `heading` and `paragraph` don’t require the group parameter and are therefore not included here.', | ||
export const GroupsOverview = () => { | ||
return Object.entries(typography).map(([key, group]) => ( |
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 over shows the private property _modes
(denoted by the _ in name). Suggest removing this using .filter()
before .map()
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.
done
Custom token | ||
</Typography> | ||
</Grid> | ||
export const Custom: Story<TypographyProps> = () => ( |
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.
Maybe change this story to be about the token property? Its not really custom as its just examples of different combinations using props.
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.
done
link?: boolean | ||
/** Typography colors. */ | ||
color?: ColorVariants | string | ||
token?: Partial<TypographyType> |
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.
Missing description
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.
done
@@ -8,7 +8,7 @@ const StyledDialogHeader = styled.div(({ theme }) => { | |||
return css` | |||
display: flex; | |||
justify-content: space-betweene; | |||
algin-items: center; | |||
align-items: center; |
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.
Uhm, suggest making a separate issue for tracebility for this as the above line is also wrong "space-betweene"....
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.
Wasn’t Stylelint
extension behind this idea?
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 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.
Thats right, justify-content
haven't been underline.
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.
done, new issue #2417
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.
Suggest reverting these changes and do the fixes in a separate PR for traceability
35dcb4a
to
cad0fab
Compare
<ul> | ||
<li><code>color</code>,</li> | ||
<li><code>fontFamily</code>,</li> | ||
<li><code>fontSize</code>,</li> | ||
<li><code>fontWeight</code>,</li> | ||
<li><code>fontStyle</code>,</li> | ||
<li><code>fontFeature</code>,</li> | ||
<li><code>lineHeight</code>,</li> | ||
<li><code>textAlign</code>,</li> | ||
<li><code>textTransform</code>,</li> | ||
<li><code>textDecoration</code>,</li> | ||
<li><code>letterSpacing</code>.</li> | ||
</ul> |
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.
Good suggestion! Maybe make this example closer to how it would look in code
For example:
const myToken = {
color,
fontFamily,
fontSize,
fontWeight,
lineHeight,
textAlign,
textTransform,
textDecoration,
letterSpacing,
}
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.
done
@@ -8,7 +8,7 @@ const StyledDialogHeader = styled.div(({ theme }) => { | |||
return css` | |||
display: flex; | |||
justify-content: space-betweene; | |||
algin-items: center; | |||
align-items: center; |
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.
Suggest reverting these changes and do the fixes in a separate PR for traceability
cad0fab
to
a467d4b
Compare
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.
A suggestion on change of wording to better describe token
property, else it looks good 👍
packages/eds-core-react/src/components/Typography/Typography.docs.mdx
Outdated
Show resolved
Hide resolved
…ocs.mdx Co-authored-by: Michael Marszalek <[email protected]>
## [0.5.2](https://github.com/equinor/webviz-subsurface-components/compare/[email protected]@0.5.2) (2024-02-13) ### Bug Fixes * bump @equinor/eds-icons from 0.19.3 to 0.21.0 and @equinor/eds-core-react from 0.33.0 to 0.36.0 in /typescript ([#1892](#1892)) ([c7bd611](c7bd611)), closes [equinor/design-system#2367](equinor/design-system#2367) [equinor/design-system#2431](equinor/design-system#2431) [equinor/design-system#2378](equinor/design-system#2378) [equinor/design-system#2399](equinor/design-system#2399) [equinor/design-system#2410](equinor/design-system#2410) [equinor/design-system#2432](equinor/design-system#2432) [equinor/design-system#2442](equinor/design-system#2442) [equinor/design-system#2420](equinor/design-system#2420) [equinor/design-system#2377](equinor/design-system#2377) [equinor/design-system#2384](equinor/design-system#2384) [equinor/design-system#2405](equinor/design-system#2405) [equinor/design-system#2460](equinor/design-system#2460) [equinor/design-system#2247](equinor/design-system#2247) [equinor/design-system#2436](equinor/design-system#2436) [equinor/design-system#2451](equinor/design-system#2451) [equinor/design-system#2303](equinor/design-system#2303) [equinor/design-system#2327](equinor/design-system#2327) [equinor/design-system#2337](equinor/design-system#2337) [equinor/design-system#2335](equinor/design-system#2335) [equinor/design-system#2313](equinor/design-system#2313) [equinor/design-system#3177](equinor/design-system#3177) [#3239](https://github.com/equinor/webviz-subsurface-components/issues/3239) [#3219](https://github.com/equinor/webviz-subsurface-components/issues/3219) [#3177](https://github.com/equinor/webviz-subsurface-components/issues/3177) [#3137](https://github.com/equinor/webviz-subsurface-components/issues/3137) [#3132](https://github.com/equinor/webviz-subsurface-components/issues/3132) [#3121](https://github.com/equinor/webviz-subsurface-components/issues/3121) [#3020](https://github.com/equinor/webviz-subsurface-components/issues/3020) [#3019](https://github.com/equinor/webviz-subsurface-components/issues/3019)
## [1.2.2](https://github.com/equinor/webviz-subsurface-components/compare/[email protected]@1.2.2) (2024-02-13) ### Bug Fixes * bump @equinor/eds-icons from 0.19.3 to 0.21.0 and @equinor/eds-core-react from 0.33.0 to 0.36.0 in /typescript ([#1892](#1892)) ([c7bd611](c7bd611)), closes [equinor/design-system#2367](equinor/design-system#2367) [equinor/design-system#2431](equinor/design-system#2431) [equinor/design-system#2378](equinor/design-system#2378) [equinor/design-system#2399](equinor/design-system#2399) [equinor/design-system#2410](equinor/design-system#2410) [equinor/design-system#2432](equinor/design-system#2432) [equinor/design-system#2442](equinor/design-system#2442) [equinor/design-system#2420](equinor/design-system#2420) [equinor/design-system#2377](equinor/design-system#2377) [equinor/design-system#2384](equinor/design-system#2384) [equinor/design-system#2405](equinor/design-system#2405) [equinor/design-system#2460](equinor/design-system#2460) [equinor/design-system#2247](equinor/design-system#2247) [equinor/design-system#2436](equinor/design-system#2436) [equinor/design-system#2451](equinor/design-system#2451) [equinor/design-system#2303](equinor/design-system#2303) [equinor/design-system#2327](equinor/design-system#2327) [equinor/design-system#2337](equinor/design-system#2337) [equinor/design-system#2335](equinor/design-system#2335) [equinor/design-system#2313](equinor/design-system#2313) [equinor/design-system#3177](equinor/design-system#3177) [#3239](https://github.com/equinor/webviz-subsurface-components/issues/3239) [#3219](https://github.com/equinor/webviz-subsurface-components/issues/3219) [#3177](https://github.com/equinor/webviz-subsurface-components/issues/3177) [#3137](https://github.com/equinor/webviz-subsurface-components/issues/3137) [#3132](https://github.com/equinor/webviz-subsurface-components/issues/3132) [#3121](https://github.com/equinor/webviz-subsurface-components/issues/3121) [#3020](https://github.com/equinor/webviz-subsurface-components/issues/3020) [#3019](https://github.com/equinor/webviz-subsurface-components/issues/3019)
## [0.16.2](https://github.com/equinor/webviz-subsurface-components/compare/[email protected]@0.16.2) (2024-02-13) ### Bug Fixes * bump @equinor/eds-icons from 0.19.3 to 0.21.0 and @equinor/eds-core-react from 0.33.0 to 0.36.0 in /typescript ([#1892](#1892)) ([c7bd611](c7bd611)), closes [equinor/design-system#2367](equinor/design-system#2367) [equinor/design-system#2431](equinor/design-system#2431) [equinor/design-system#2378](equinor/design-system#2378) [equinor/design-system#2399](equinor/design-system#2399) [equinor/design-system#2410](equinor/design-system#2410) [equinor/design-system#2432](equinor/design-system#2432) [equinor/design-system#2442](equinor/design-system#2442) [equinor/design-system#2420](equinor/design-system#2420) [equinor/design-system#2377](equinor/design-system#2377) [equinor/design-system#2384](equinor/design-system#2384) [equinor/design-system#2405](equinor/design-system#2405) [equinor/design-system#2460](equinor/design-system#2460) [equinor/design-system#2247](equinor/design-system#2247) [equinor/design-system#2436](equinor/design-system#2436) [equinor/design-system#2451](equinor/design-system#2451) [equinor/design-system#2303](equinor/design-system#2303) [equinor/design-system#2327](equinor/design-system#2327) [equinor/design-system#2337](equinor/design-system#2337) [equinor/design-system#2335](equinor/design-system#2335) [equinor/design-system#2313](equinor/design-system#2313) [equinor/design-system#3177](equinor/design-system#3177) [#3239](https://github.com/equinor/webviz-subsurface-components/issues/3239) [#3219](https://github.com/equinor/webviz-subsurface-components/issues/3219) [#3177](https://github.com/equinor/webviz-subsurface-components/issues/3177) [#3137](https://github.com/equinor/webviz-subsurface-components/issues/3137) [#3132](https://github.com/equinor/webviz-subsurface-components/issues/3132) [#3121](https://github.com/equinor/webviz-subsurface-components/issues/3121) [#3020](https://github.com/equinor/webviz-subsurface-components/issues/3020) [#3019](https://github.com/equinor/webviz-subsurface-components/issues/3019)
## [1.1.2](https://github.com/equinor/webviz-subsurface-components/compare/[email protected]@1.1.2) (2024-02-13) ### Bug Fixes * bump @equinor/eds-icons from 0.19.3 to 0.21.0 and @equinor/eds-core-react from 0.33.0 to 0.36.0 in /typescript ([#1892](#1892)) ([c7bd611](c7bd611)), closes [equinor/design-system#2367](equinor/design-system#2367) [equinor/design-system#2431](equinor/design-system#2431) [equinor/design-system#2378](equinor/design-system#2378) [equinor/design-system#2399](equinor/design-system#2399) [equinor/design-system#2410](equinor/design-system#2410) [equinor/design-system#2432](equinor/design-system#2432) [equinor/design-system#2442](equinor/design-system#2442) [equinor/design-system#2420](equinor/design-system#2420) [equinor/design-system#2377](equinor/design-system#2377) [equinor/design-system#2384](equinor/design-system#2384) [equinor/design-system#2405](equinor/design-system#2405) [equinor/design-system#2460](equinor/design-system#2460) [equinor/design-system#2247](equinor/design-system#2247) [equinor/design-system#2436](equinor/design-system#2436) [equinor/design-system#2451](equinor/design-system#2451) [equinor/design-system#2303](equinor/design-system#2303) [equinor/design-system#2327](equinor/design-system#2327) [equinor/design-system#2337](equinor/design-system#2337) [equinor/design-system#2335](equinor/design-system#2335) [equinor/design-system#2313](equinor/design-system#2313) [equinor/design-system#3177](equinor/design-system#3177) [#3239](https://github.com/equinor/webviz-subsurface-components/issues/3239) [#3219](https://github.com/equinor/webviz-subsurface-components/issues/3219) [#3177](https://github.com/equinor/webviz-subsurface-components/issues/3177) [#3137](https://github.com/equinor/webviz-subsurface-components/issues/3137) [#3132](https://github.com/equinor/webviz-subsurface-components/issues/3132) [#3121](https://github.com/equinor/webviz-subsurface-components/issues/3121) [#3020](https://github.com/equinor/webviz-subsurface-components/issues/3020) [#3019](https://github.com/equinor/webviz-subsurface-components/issues/3019)
## [1.4.2](https://github.com/equinor/webviz-subsurface-components/compare/[email protected]@1.4.2) (2024-02-13) ### Bug Fixes * bump @equinor/eds-icons from 0.19.3 to 0.21.0 and @equinor/eds-core-react from 0.33.0 to 0.36.0 in /typescript ([#1892](#1892)) ([c7bd611](c7bd611)), closes [equinor/design-system#2367](equinor/design-system#2367) [equinor/design-system#2431](equinor/design-system#2431) [equinor/design-system#2378](equinor/design-system#2378) [equinor/design-system#2399](equinor/design-system#2399) [equinor/design-system#2410](equinor/design-system#2410) [equinor/design-system#2432](equinor/design-system#2432) [equinor/design-system#2442](equinor/design-system#2442) [equinor/design-system#2420](equinor/design-system#2420) [equinor/design-system#2377](equinor/design-system#2377) [equinor/design-system#2384](equinor/design-system#2384) [equinor/design-system#2405](equinor/design-system#2405) [equinor/design-system#2460](equinor/design-system#2460) [equinor/design-system#2247](equinor/design-system#2247) [equinor/design-system#2436](equinor/design-system#2436) [equinor/design-system#2451](equinor/design-system#2451) [equinor/design-system#2303](equinor/design-system#2303) [equinor/design-system#2327](equinor/design-system#2327) [equinor/design-system#2337](equinor/design-system#2337) [equinor/design-system#2335](equinor/design-system#2335) [equinor/design-system#2313](equinor/design-system#2313) [equinor/design-system#3177](equinor/design-system#3177) [#3239](https://github.com/equinor/webviz-subsurface-components/issues/3239) [#3219](https://github.com/equinor/webviz-subsurface-components/issues/3219) [#3177](https://github.com/equinor/webviz-subsurface-components/issues/3177) [#3137](https://github.com/equinor/webviz-subsurface-components/issues/3137) [#3132](https://github.com/equinor/webviz-subsurface-components/issues/3132) [#3121](https://github.com/equinor/webviz-subsurface-components/issues/3121) [#3020](https://github.com/equinor/webviz-subsurface-components/issues/3020) [#3019](https://github.com/equinor/webviz-subsurface-components/issues/3019)
Resolves #452