Skip to content

Commit

Permalink
Fix broken css build error caused by Frame (#11917)
Browse files Browse the repository at this point in the history
### WHY are these changes introduced?

Fixes #11784

### WHAT is this pull request doing?

Print css wasn't working here, the nesting was odd. To tophat go to
render settings in dev tools and emulate print media in prod or
storybook.


![image](https://github.com/Shopify/polaris/assets/6844391/3e1b0a53-5dc5-4d94-be83-151003856ae3)

### 🎩 checklist

- [ ] Tested a
[snapshot](https://github.com/Shopify/polaris/blob/main/documentation/Releasing.md#-snapshot-releases)
- [ ] Tested on
[mobile](https://github.com/Shopify/polaris/blob/main/documentation/Tophatting.md#cross-browser-testing)
- [ ] Tested on [multiple
browsers](https://help.shopify.com/en/manual/shopify-admin/supported-browsers)
- [ ] Tested for
[accessibility](https://github.com/Shopify/polaris/blob/main/documentation/Accessibility%20testing.md)
- [ ] Updated the component's `README.md` with documentation changes
- [ ] [Tophatted
documentation](https://github.com/Shopify/polaris/blob/main/documentation/Tophatting%20documentation.md)
changes in the style guide
  • Loading branch information
kyledurand committed Apr 19, 2024
1 parent 993e312 commit 7fa6deb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .changeset/early-pens-hide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@shopify/polaris': patch
---

Fixed broken css build error
9 changes: 6 additions & 3 deletions polaris-react/src/components/Frame/Frame.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -221,9 +221,6 @@
.hasNav & {
/* stylelint-disable-next-line -- polaris custom global property */
padding-left: var(--pg-layout-width-nav-base);
@media print {
padding-left: 0;
}
/* stylelint-disable-next-line -- generated by polaris-migrator DO NOT COPY */
@mixin safe-area-for padding-left, var(--pg-layout-width-nav-base), left;
}
Expand All @@ -236,6 +233,12 @@
padding-top: 0;
}
}

@media print {
.hasNav & {
padding-left: 0;
}
}
}

.Main-TopBarAndReframe {
Expand Down

0 comments on commit 7fa6deb

Please sign in to comment.