Releases: Shopify/polaris-react
Releases · Shopify/polaris-react
v4.7.0
Enhancements
- Updated
OptionListsection title to matchActionListsection title (#2300) - Added
pressedstate toButton(#2148) - Updated the type of the
labelprop inChoiceList(nested prop ofchoices) fromstringtoReactNode(#2325).
Bug fixes
- Fixed
actionGroupsto only renderMenuActionswhen actions are provided in thePage(#2266) - Fixed
PositionedOverlayincorrectly calculatingTopbar.UserMenuPopoverwidth (#2231) - Fixed
recolor-iconSass mixin to properly scope$secondary-colorto the childsvg(#2298) - Fixed an issue with the
ResourceListcomponent where the plural resource name was not used fortotalItemsCount(#2301) - Fixed Stack Item proportion when shrinking (#2319)
- Fixed animation of
Collapsiblewith children having margins (#1980) - Added vertical adjustment to
OptionListcontrol items (#2313)
Dependency upgrades
- Updated sewing-kit to v0.111.0 and storybook to v5.2.4 (#2326)
v4.7.0-rc.1
v4.7.0-rc.1
v4.6.1
v4.6.0
Enhancements
- Added a
totalItemsCountprop to theResourceListcomponent (#2233) - Prevented the
Headerprimary action label on thePagecomponent from wrapping when the title is too long (#2262)
Bug fixes
- Fixed an issue with the
Stackcomponent where aStack.Itemwas not getting a minimum width (#2273) - Fixed an issue with
Filtersapplying inconsistent border styles to sibling filters when
there is only one filter in the filter list (#2284) - Added
aria-disabledto theSelectcomponent’s content when it is disabled (#2281)
Documentation
- Added accessibility documentation for the
DropZonecomponent (#2243) - Improved accessibility documentation for the
Spinnercomponent (#2258)
Development workflow
- Added support for context customization in Storybook using addon-contexts (#2281)
Code quality
v.4.5.0
Enhancements
- Added
showTotalsInFooterprop toDataTablefor control over placement of “Totals” row (#2200) - Added
hasFocusableParenttoSpinner(#2176)
Bug fixes
- Fixed tabs that don’t wrap correctly on small screens in pre-iOS 13 Safari (#2232)
- Fixed
BulkActionscheckbox losing on selection focus (#2138) - Moved rendering of the portal component’s node within the node created by the theme provider component to enable theming through CSS Custom Properties (#2224)
- Fixed a bug which caused the
Popoveroverlay to remain in the DOM if it was updated during exiting (#2246) - Fixed
Breadcrumbsto useaccessibilityLabelprop when passed in (#2254)
Documentation
- Added accessibility documentation for the date picker component (#2242)
- Added accessibility documentation for the empty state component (#2244)
Code quality
-
Improved code quality for the theme provider component (#2225):
- updated type for
themeprop toThemeConfigto distinguish from the typeThemewhich is shared over context. AThemecontains only the logo properties, whileThemeConfigcan contain acolorsproperty. - converted
ThemeProviderto use hooks - created symmetry in context between app provider and test provider
- added better tests for default topBar colors
- fixed an issue where
colorToHslareturned HSLA strings instead of HSLA objects when given HSL or HSLA strings - fixed an issue with
colorToHslawhere RGB colors with no saturation could result in a divide by zero error - fixed an issue where
colorToHslainconsistently returned an alpha value - fixed an issue where
lightenColoranddarkenColorwould lighten or darken absolute lightness values (0, 100)
- updated type for
v4.4.0
Enhancements
Bug fixes
- Fixed loss of focus on
TextFieldwhen changing connectedRight/connectedLeft content while user is typing (#2170) - Fixed
typefor clearButton (#2060). Thank you chenxsan for the contribution. - Prevented the
onSelectprop ofTabsfrom changing scroll position (#2196) - Fixed 200ms visual delay when activating
Popover(#2209) - Removed the
ResourceListItemhover state whenItemis deselected (#1952) - Fixed
Subheading’sfont-weight(#2218) - Fixed
fullWidthCardSections when contained in a page with aNav(#2227)
Documentation
- Converted
SettingToggle,Sheet, andTabsexamples to functional components (#2134) - Converted
Form,Frame, andLoadingexamples to functional components (#2130) - Replaced Latin abbreviations with English words in Text field content guidelines (#2192)
- Converted
SettingToggle,Sheet, andTabsexamples to functional components (#2134) - Converted
DatePicker,DropZone, andFiltersexamples to functional components (#2129)
Code quality
- Added
MediaQueryProviderto ease the use of media queries and reduce duplication (#2117) - Migrated
Tabto use hooks instead ofwithAppProvider(#2096)
Development workflow
- Added a GitHub action, discoverability-action, that runs
yarn splashon PR diffs and leaves a comment with the output (#2208)
v4.3.0
Enhancements
- Added new label prop to
Paginationwhich is used to insert contextual info between navigation buttons (#2098) - Updated
triggerto useact(#2141) - Changed border color of
Drop zoneto have better contrast from the background and to be lighter when disabled (#2119) - Adjusted search results overlay to take up 100% height of the screen on small screens and to match the width of the search bar on large screens. (#2103)
- Added skipToContentTarget prop to Frame component (#2080)
Bug fixes
- Updated
Cardfooter actions to be left aligned instead of right by default (#2075) - Fixed vertical alignment of Tabs disclosure activator (#2087)
- Fixed
Modalsetting an invalididonaria-labelledbywhen notitleis set (#2115) - Fixed error warnings in
CardandRollupActionstests (#2125) - Fixed modal border not being visible in Windows high contrast mode (#2114)
- Added default accessibility label from
ResourceItem(#2097) - Reverted
Page.primaryActionforcingprimaryto betrue(#2137) - Removed
React.Children.onlyfromAppProviderandThemeProvider(#2121) - Fixed visual bug where button width changed in Filters component. Thank you to @alexieyizhe for the contribution (#2003).
- Changed
text-renderingtoautoinSelectto prevent Safari 13 from crashing (#2179)
Documentation
- Converted
Autocomplete,Banner, andChoiceListexamples to functional components (#2127) - Converted
Collapsible,ColorPicker, andDataTableexamples to functional components (#2128) - Converted
Modal,OptionList, andPopoverexamples to functional components (#2131) - Converted
RadioButton,RangeSlider, andResourceItemexamples to functional components (#2132) - Converted
ResourceList,ResourcePicker, andSelectexamples to functional components (#2133) - Converted
TextField,Toast, andTopBarexamples to functional components (#2135) - Updated the
withContextsection in the v3 to v4 migration guide (#2124) - Clarified when to use the
externalprop on theLinkcomponent (#2153) - Updated documentation examples to include disclosure on
Popoveractivators (#2171)
Development workflow
- Added
yarn splash(beta), a command-line interface to observe the splash zone of a change across the component library (#2113) - Updated Storybook – v5.2 release notes (#2157)
Code quality
- Added
useLazyRefhook to use while building components (#2166) - Migrated
FilterCreatorto use hooks instead of withAppProvider (#2156) - Created a custom error for lack of context providers (#2136)
- Migrated
ContextualSaveBarto use hooks instead ofwithAppProvider. Thank you to @sijad for the contribution (#2091). - Migrated
RangeSlider,ScrollLockandTopBar.SearchFieldto use hooks instead of withAppProvider (#2083) - Updated
ResourceItemto no longer rely on withAppProvider (#2094) - Migrated
TextFieldandResizerto use hooks (#1997) - Migrated
Avatarto use hooks instead of withAppProvider (#2067) - Updated
DayandDatePickerto use hooks (#2089)
v4.2.1
v4.2.0
Enhancements
- Added support for min/max dates in
TextFieldby setting a string onminandmaxprops (#1991) - Made the
titleprop onPageoptional, supporting continued use ofPagefor structure in apps using the App Bridge ReactTitleBar(#2082)
Bug fixes
- Fixed inconsistent padding of sections in
Modal(#2072) - Fixed animation for Modal when being rendered asynchronously (#2076)
- Fixed item content from overflowing past the container in
Stack(#2071) - Fixed
Dropzonehover, disabled, and focus states (#1994) - Added
nameprop toResourceItemto fix accessibility labels (#2077) - Fixed misalignment of
ResourceItemactions (#2051)
Documentation
- Added Android/iOS images for Plain destructive button (#2081)
- Removed mobile mention from right-aligned text component guidelines (#2081)
- Added mobile example images error state of Single Choice List (#2007)
Dependency upgrades
- Updated Prettier to v1.18.2 (#2070)
Development workflow
- Added a displayName to the function generated by the
withAppProviderHoC for a better devtools experience (#2093)
Code quality
- Migrated
ActionMenu.RollupAction,Autocomplete,Card,EmptySearchResult,Form,SkeletonPageandTopBarto use hooks instead of withAppProvider (#2065) - Added
useUniqueIdhook that can be used to get a unique id that remains consistent between rerenders and updated components to use it where appropriate (#2079)
v4.1.0
Enhancements
- Moved
ResourceItemto its own component (#1774) - Updated
ResourceListsort to show an inline label (#1774) - Removed the
tap-highlight-colorforButtons(#1545)
Bug fixes
- Removed
Tooltipon disabledPaginationbuttons (#1963) - Fixed accessibility labels on
ResourceList.Itempersistent action disclosure icon (#1973) - Fixed accessibility issue with
Autocompletewhere keyboard navigation of options was laggy and skipped options (#1887) - Fixed bug where
Autocompletewas bubbling up theEnterkey event unexpectedly (#1887) - Fixed
ContextualSaveBaractions overflowing on small screens (#1967) - Fixed
Tabsrollup automatically opening from keyboard navigation of tab list (#1933)
Documentation
- Updated example section to include new examples and remove old ones (#1979)
- Updated example for the
ResourceList.Itempersistent actions accessibility labels (#1973) - Removed
FilterControldocumentation and case studies fromResourceListdocumentation (#1774) - Updated
ResourceListexamples to useFilters(#1774) - Added an example to
Filtersshowing the use ofchildren(#1774) - Added guidance for making animated gifs in PRs and issues more accessibility-friendly #1998
- Added
RadioButtonguidance to make one option selected by default #2005
Development workflow
- Update subcomponents to use named exports for components and better names props exports (#2058)
Code quality
- Removed mocks in various tests suites that are now redundant (#1978)
Deprecations
- Deprecated
FilterControl. UseFiltersinstead (#1774)