This repository was archived by the owner on Sep 30, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
[IndexFilters] Fix layout shift when going from between default and filtering modes #10428
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
chloerice
approved these changes
Sep 13, 2023
polaris-react/src/components/Filters/components/SearchField/SearchField.scss
Outdated
Show resolved
Hide resolved
.IndexFiltersWrapper { | ||
width: 100%; | ||
|
||
[class*='Button-Button'] { |
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.
Would targeting the class directly work here? Just not sure how this works since the BEM classes are built with a compile script. 🤔
Suggested change
[class*='Button-Button'] { | |
.Button { |
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.
I don't think this would, as we want to target the Polaris <Button>
component here. I should be able to target this a different way, targeting the button
element, but I'll scope it directly to where I need it to.
Co-authored-by: Chloe Rice <chloerice@users.noreply.github.com>
…archField.scss Co-authored-by: Chloe Rice <chloerice@users.noreply.github.com>
jesstelford
approved these changes
Sep 14, 2023
Merged
mrcthms
pushed a commit
that referenced
this pull request
Sep 14, 2023
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @shopify/polaris@11.18.0 ### Minor Changes - [#10429](#10429) [`2e65a7e98`](2e65a7e) Thanks [@mrcthms](https://github.com/mrcthms)! - Fixed `Filters` pinned filter pill not remaining when applied values are cleared - [#10394](#10394) [`b7f25f07f`](b7f25f0) Thanks [@mrcthms](https://github.com/mrcthms)! - Added support for disabling 1Password integration in `TextField` - [#10406](#10406) [`87f559ca1`](87f559c) Thanks [@mrcthms](https://github.com/mrcthms)! - Updated the Toast component to support multiple re-renders being announced on screen readers ### Patch Changes - [#10428](#10428) [`d35d55e5b`](d35d55e) Thanks [@mrcthms](https://github.com/mrcthms)! - Fixed layout shift in `IndexFilters` when switching modes - Updated dependencies \[[`26ab8ce7d`](26ab8ce), [`7514dd1a3`](7514dd1), [`16c61668a`](16c6166)]: - @shopify/polaris-tokens@7.8.0 ## @shopify/polaris-tokens@7.8.0 ### Minor Changes - [#10432](#10432) [`26ab8ce7d`](26ab8ce) Thanks [@lgriffee](https://github.com/lgriffee)! - Added public primitive `border-radius` token scale - [#10448](#10448) [`7514dd1a3`](7514dd1) Thanks [@lgriffee](https://github.com/lgriffee)! - Added public primitive `space` token scale - [#10418](#10418) [`16c61668a`](16c6166) Thanks [@lgriffee](https://github.com/lgriffee)! - Added private primitive `size` token scale ## @shopify/polaris-migrator@0.22.3 ### Patch Changes - Updated dependencies \[[`26ab8ce7d`](26ab8ce), [`7514dd1a3`](7514dd1), [`16c61668a`](16c6166)]: - @shopify/polaris-tokens@7.8.0 - @shopify/stylelint-polaris@14.0.3 ## @shopify/stylelint-polaris@14.0.3 ### Patch Changes - Updated dependencies \[[`26ab8ce7d`](26ab8ce), [`7514dd1a3`](7514dd1), [`16c61668a`](16c6166)]: - @shopify/polaris-tokens@7.8.0 ## polaris.shopify.com@0.57.6 ### Patch Changes - Updated dependencies \[[`2e65a7e98`](2e65a7e), [`b7f25f07f`](b7f25f0), [`26ab8ce7d`](26ab8ce), [`d35d55e5b`](d35d55e), [`7514dd1a3`](7514dd1), [`16c61668a`](16c6166), [`87f559ca1`](87f559c)]: - @shopify/polaris@11.18.0 - @shopify/polaris-tokens@7.8.0 Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
AnnaCheba
pushed a commit
to AnnaCheba/polaris
that referenced
this pull request
Apr 22, 2024
…iltering modes (Shopify#10428) ### WHY are these changes introduced? Fixes an issue in the IndexFilters where it caused a layout shift when toggling between default and filtering modes. This PR fixes that little layout shift. ### Before https://github.com/Shopify/polaris/assets/2562596/85c96dcd-3854-455a-9ccb-cfecaf86b293 ### After https://github.com/Shopify/polaris/assets/2562596/24b55cfc-2ec8-47d7-9d27-be6088c4e2f1 ### 🎩 checklist - [x] Tested on [mobile](https://github.com/Shopify/polaris/blob/main/documentation/Tophatting.md#cross-browser-testing) - [x] Tested on [multiple browsers](https://help.shopify.com/en/manual/shopify-admin/supported-browsers) - [x] Tested for [accessibility](https://github.com/Shopify/polaris/blob/main/documentation/Accessibility%20testing.md) - [x] Updated the component's `README.md` with documentation changes - [x] [Tophatted documentation](https://github.com/Shopify/polaris/blob/main/documentation/Tophatting%20documentation.md) changes in the style guide --------- Co-authored-by: Chloe Rice <chloerice@users.noreply.github.com>
ascherkus
pushed a commit
to ascherkus/polaris
that referenced
this pull request
Feb 19, 2025
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @shopify/polaris@11.18.0 ### Minor Changes - [Shopify#10429](Shopify#10429) [`2e65a7e98`](Shopify@78e3c64) Thanks [@mrcthms](https://github.com/mrcthms)! - Fixed `Filters` pinned filter pill not remaining when applied values are cleared - [Shopify#10394](Shopify#10394) [`b7f25f07f`](Shopify@11a5ec4) Thanks [@mrcthms](https://github.com/mrcthms)! - Added support for disabling 1Password integration in `TextField` - [Shopify#10406](Shopify#10406) [`87f559ca1`](Shopify@87ef9b6) Thanks [@mrcthms](https://github.com/mrcthms)! - Updated the Toast component to support multiple re-renders being announced on screen readers ### Patch Changes - [Shopify#10428](Shopify#10428) [`d35d55e5b`](Shopify@ded82d4) Thanks [@mrcthms](https://github.com/mrcthms)! - Fixed layout shift in `IndexFilters` when switching modes - Updated dependencies \[[`26ab8ce7d`](Shopify@2638248), [`7514dd1a3`](Shopify@beb664a), [`16c61668a`](Shopify@54284eb)]: - @shopify/polaris-tokens@7.8.0 ## @shopify/polaris-tokens@7.8.0 ### Minor Changes - [Shopify#10432](Shopify#10432) [`26ab8ce7d`](Shopify@2638248) Thanks [@lgriffee](https://github.com/lgriffee)! - Added public primitive `border-radius` token scale - [Shopify#10448](Shopify#10448) [`7514dd1a3`](Shopify@beb664a) Thanks [@lgriffee](https://github.com/lgriffee)! - Added public primitive `space` token scale - [Shopify#10418](Shopify#10418) [`16c61668a`](Shopify@54284eb) Thanks [@lgriffee](https://github.com/lgriffee)! - Added private primitive `size` token scale ## @shopify/polaris-migrator@0.22.3 ### Patch Changes - Updated dependencies \[[`26ab8ce7d`](Shopify@2638248), [`7514dd1a3`](Shopify@beb664a), [`16c61668a`](Shopify@54284eb)]: - @shopify/polaris-tokens@7.8.0 - @shopify/stylelint-polaris@14.0.3 ## @shopify/stylelint-polaris@14.0.3 ### Patch Changes - Updated dependencies \[[`26ab8ce7d`](Shopify@2638248), [`7514dd1a3`](Shopify@beb664a), [`16c61668a`](Shopify@54284eb)]: - @shopify/polaris-tokens@7.8.0 ## polaris.shopify.com@0.57.6 ### Patch Changes - Updated dependencies \[[`2e65a7e98`](Shopify@78e3c64), [`b7f25f07f`](Shopify@11a5ec4), [`26ab8ce7d`](Shopify@2638248), [`d35d55e5b`](Shopify@ded82d4), [`7514dd1a3`](Shopify@beb664a), [`16c61668a`](Shopify@54284eb), [`87f559ca1`](Shopify@87ef9b6)]: - @shopify/polaris@11.18.0 - @shopify/polaris-tokens@7.8.0 Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
2023
Contribution tracking for 2023
Component
Contribution
Tracking contribution in conjuction with year and type, e.g., "Component" + "Contribution" + "2023"
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
WHY are these changes introduced?
Fixes an issue in the IndexFilters where it caused a layout shift when toggling between default and filtering modes. This PR fixes that little layout shift.
Before
Screen.Recording.2023-09-13.at.12.33.49.mov
After
Screen.Recording.2023-09-13.at.13.57.19.mov
🎩 checklist
README.md
with documentation changes