Skip to content

Releases: Shopify/polaris-react

v4.7.0

22 Oct 21:50

Choose a tag to compare

Enhancements

  • Updated OptionList section title to match ActionList section title (#2300)
  • Added pressed state to Button (#2148)
  • Updated the type of the label prop in ChoiceList (nested prop of choices) from string to ReactNode (#2325).

Bug fixes

  • Fixed actionGroups to only render MenuActions when actions are provided in the Page (#2266)
  • Fixed PositionedOverlay incorrectly calculating Topbar.UserMenu Popover width (#2231)
  • Fixed recolor-icon Sass mixin to properly scope $secondary-color to the child svg (#2298)
  • Fixed an issue with the ResourceList component where the plural resource name was not used for totalItemsCount (#2301)
  • Fixed Stack Item proportion when shrinking (#2319)
  • Fixed animation of Collapsible with children having margins (#1980)
  • Added vertical adjustment to OptionList control items (#2313)

Dependency upgrades

  • Updated sewing-kit to v0.111.0 and storybook to v5.2.4 (#2326)

v4.7.0-rc.1

22 Oct 22:05

Choose a tag to compare

v4.7.0-rc.1 Pre-release
Pre-release
v4.7.0-rc.1

v4.6.1

17 Oct 22:46

Choose a tag to compare

Enhancements

  • Added CSS custom properties to Portal container (#2306)

Bug fixes

  • Fixed a regression with the positioning of the Popover component (#2305)

v4.6.0

16 Oct 15:13

Choose a tag to compare

Enhancements

  • Added a totalItemsCount prop to the ResourceList component (#2233)
  • Prevented the Header primary action label on the Page component from wrapping when the title is too long (#2262)

Bug fixes

  • Fixed an issue with the Stack component where a Stack.Item was not getting a minimum width (#2273)
  • Fixed an issue with Filters applying inconsistent border styles to sibling filters when
    there is only one filter in the filter list (#2284)
  • Added aria-disabled to the Select component’s content when it is disabled (#2281)

Documentation

  • Added accessibility documentation for the DropZone component (#2243)
  • Improved accessibility documentation for the Spinner component (#2258)

Development workflow

  • Added support for context customization in Storybook using addon-contexts (#2281)

Code quality

  • Migrated DateSelector to use hooks instead of withAppProvider (#2193)
  • Migrated Toast to use hooks (#2222)
  • Removed link, theme and scrollLockManager from the object returned by withAppProvider as nothing consumes them any more (#2277)

v.4.5.0

08 Oct 18:56

Choose a tag to compare

Enhancements

  • Added showTotalsInFooter prop to DataTable for control over placement of “Totals” row (#2200)
  • Added hasFocusableParent to Spinner (#2176)

Bug fixes

  • Fixed tabs that don’t wrap correctly on small screens in pre-iOS 13 Safari (#2232)
  • Fixed BulkActions checkbox 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 Popover overlay to remain in the DOM if it was updated during exiting (#2246)
  • Fixed Breadcrumbs to use accessibilityLabel prop 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 theme prop to ThemeConfig to distinguish from the type Theme which is shared over context. A Theme contains only the logo properties, while ThemeConfig can contain a colors property.
    • converted ThemeProvider to use hooks
    • created symmetry in context between app provider and test provider
    • added better tests for default topBar colors
    • fixed an issue where colorToHsla returned HSLA strings instead of HSLA objects when given HSL or HSLA strings
    • fixed an issue with colorToHsla where RGB colors with no saturation could result in a divide by zero error
    • fixed an issue where colorToHsla inconsistently returned an alpha value
    • fixed an issue where lightenColor and darkenColor would lighten or darken absolute lightness values (0, 100)

v4.4.0

03 Oct 17:40

Choose a tag to compare

Enhancements

  • Removed the need for z-indexes in Icon (#2207)
  • Added features prop to AppProvider (#2204)

Bug fixes

  • Fixed loss of focus on TextField when changing connectedRight/connectedLeft content while user is typing (#2170)
  • Fixed type for clearButton (#2060). Thank you chenxsan for the contribution.
  • Prevented the onSelect prop of Tabs from changing scroll position (#2196)
  • Fixed 200ms visual delay when activating Popover (#2209)
  • Removed the ResourceList Item hover state when Item is deselected (#1952)
  • Fixed Subheading’s font-weight (#2218)
  • Fixed fullWidth CardSections when contained in a page with a Nav (#2227)

Documentation

  • Converted SettingToggle, Sheet, and Tabs examples to functional components (#2134)
  • Converted Form, Frame, and Loading examples to functional components (#2130)
  • Replaced Latin abbreviations with English words in Text field content guidelines (#2192)
  • Converted SettingToggle, Sheet, and Tabs examples to functional components (#2134)
  • Converted DatePicker, DropZone, and Filters examples to functional components (#2129)

Code quality

  • Added MediaQueryProvider to ease the use of media queries and reduce duplication (#2117)
  • Migrated Tab to use hooks instead of withAppProvider (#2096)

Development workflow

v4.3.0

23 Sep 19:36

Choose a tag to compare

Enhancements

  • Added new label prop to Pagination which is used to insert contextual info between navigation buttons (#2098)
  • Updated trigger to use act (#2141)
  • Changed border color of Drop zone to 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 Card footer actions to be left aligned instead of right by default (#2075)
  • Fixed vertical alignment of Tabs disclosure activator (#2087)
  • Fixed Modal setting an invalid id on aria-labelledby when no title is set (#2115)
  • Fixed error warnings in Card and RollupActions tests (#2125)
  • Fixed modal border not being visible in Windows high contrast mode (#2114)
  • Added default accessibility label from ResourceItem (#2097)
  • Reverted Page.primaryAction forcing primary to be true (#2137)
  • Removed React.Children.only from AppProviderand ThemeProvider (#2121)
  • Fixed visual bug where button width changed in Filters component. Thank you to @alexieyizhe for the contribution (#2003).
  • Changed text-rendering to auto in Select to prevent Safari 13 from crashing (#2179)

Documentation

  • Converted Autocomplete, Banner, and ChoiceList examples to functional components (#2127)
  • Converted Collapsible, ColorPicker, and DataTable examples to functional components (#2128)
  • Converted Modal, OptionList, and Popover examples to functional components (#2131)
  • Converted RadioButton, RangeSlider, and ResourceItem examples to functional components (#2132)
  • Converted ResourceList, ResourcePicker, and Select examples to functional components (#2133)
  • Converted TextField, Toast, and TopBar examples to functional components (#2135)
  • Updated the withContext section in the v3 to v4 migration guide (#2124)
  • Clarified when to use the external prop on the Link component (#2153)
  • Updated documentation examples to include disclosure on Popover activators (#2171)

Development workflow

Code quality

  • Added useLazyRef hook to use while building components (#2166)
  • Migrated FilterCreator to use hooks instead of withAppProvider (#2156)
  • Created a custom error for lack of context providers (#2136)
  • Migrated ContextualSaveBar to use hooks instead of withAppProvider. Thank you to @sijad for the contribution (#2091).
  • Migrated RangeSlider, ScrollLock and TopBar.SearchField to use hooks instead of withAppProvider (#2083)
  • Updated ResourceItem to no longer rely on withAppProvider (#2094)
  • Migrated TextField and Resizer to use hooks (#1997)
  • Migrated Avatar to use hooks instead of withAppProvider (#2067)
  • Updated Day and DatePicker to use hooks (#2089)

v4.2.1

10 Sep 17:56

Choose a tag to compare

Bug fixes

  • Fixed TypeScript not generating correct types for functional components that have subcomponents (#2111)

v4.2.0

09 Sep 21:52

Choose a tag to compare

Enhancements

  • Added support for min/max dates in TextField by setting a string on min and max props (#1991)
  • Made the title prop on Page optional, supporting continued use of Page for structure in apps using the App Bridge React TitleBar (#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 Dropzone hover, disabled, and focus states (#1994)
  • Added name prop to ResourceItem to fix accessibility labels (#2077)
  • Fixed misalignment of ResourceItem actions (#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 withAppProvider HoC for a better devtools experience (#2093)

Code quality

  • Migrated ActionMenu.RollupAction, Autocomplete, Card, EmptySearchResult, Form, SkeletonPage and TopBar to use hooks instead of withAppProvider (#2065)
  • Added useUniqueId hook 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

03 Sep 17:21

Choose a tag to compare

Enhancements

  • Moved ResourceItem to its own component (#1774)
  • Updated ResourceList sort to show an inline label (#1774)
  • Removed the tap-highlight-color for Buttons (#1545)

Bug fixes

  • Removed Tooltip on disabled Pagination buttons (#1963)
  • Fixed accessibility labels on ResourceList.Item persistent action disclosure icon (#1973)
  • Fixed accessibility issue with Autocomplete where keyboard navigation of options was laggy and skipped options (#1887)
  • Fixed bug where Autocomplete was bubbling up the Enter key event unexpectedly (#1887)
  • Fixed ContextualSaveBar actions overflowing on small screens (#1967)
  • Fixed Tabs rollup 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.Item persistent actions accessibility labels (#1973)
  • Removed FilterControl documentation and case studies from ResourceList documentation (#1774)
  • Updated ResourceList examples to use Filters (#1774)
  • Added an example to Filters showing the use of children (#1774)
  • Added guidance for making animated gifs in PRs and issues more accessibility-friendly #1998
  • Added RadioButton guidance 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. Use Filters instead (#1774)