Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## v0.6.0 UNRELEASED

- Paragraph component's hardcoded responsive style has been removed (issue #1476)

## v0.6.0-alpha.7 2021-02-15

- **Breaking TypeScript**: Known colors (_primary_, _text_, _background_, _accent_, _secondary_) in `ColorMode` can now be nested scales.
Expand Down
6 changes: 1 addition & 5 deletions packages/components/src/Paragraph.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,7 @@ export const Paragraph = React.forwardRef(function Paragraph(
sx={{
// reset margin by default: avoid relying on user-agent margins (not aware of theme-ui space scale)
margin: 0,
// set a max-width: avoid full-page paragraphs
'@media screen and (min-width: 36em)': {
maxWidth: '48rem',
},
...sx,
...sx
}}
__themeKey="text"
__css={{
Expand Down
6 changes: 0 additions & 6 deletions packages/components/test/__snapshots__/index.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -1100,12 +1100,6 @@ exports[`Paragraph renders 1`] = `
margin: 0;
}

@media screen and (min-width: 36em) {
.emotion-0 {
max-width: 48rem;
}
}

<p
className="emotion-0"
/>
Expand Down
2 changes: 2 additions & 0 deletions packages/components/test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ const theme = {
fontSize: 3,
},
block: {
my: 0,
maxWidth: [0, '48em'],
variant: 'default',
textAlign: 'justify',
textAlignLast: 'start',
Expand Down