Releases: Shopify/polaris-react
Releases · Shopify/polaris-react
v2.11.0
Enhancements
Tab.Item
with aurl
prop now renders anUnstyledLink
instead of aButton
when displayed inPopover
and you can now keyboard navigate the disclosure inTabs
- Refs can be placed on
DropZone.FileUpload
- Use the new context API in
ResourceList
- Use the new context API in
DropZone
- Update example description in
ExceptionList
documentation - Move Modal CloseButton into its own subcomponent, instead of being part of the Header subcomponent. This is an internal implementation detail if you are using the React component. If you are using (s)css and are defining class names manually you will need to update references to
Polaris-Modal-Header__CloseButton
andPolaris-Modal-Header--withoutTitle
toPolaris-Modal-CloseButton
andPolaris-Modal-CloseButton--withoutTitle
respectively.
Development workflow
- Added
d.ts
files to test coverage ignore Page
is no longer self-closing in the playground
Bug fixes
- Fixed
Button
alignment issue caused by unnecessary icon markup rendering (thanks to @mbaumbach for the original issue) - Fixed console error and used new ref syntax in
DataTable
(thanks to @duythien0912 for the original issue) - Fixed margin of
InlineError
text to align with theChoiceList
labels - Replaced hardcoded
rem
values with globally scalable ones onDataTable
’s collapsed shadow, andTextStyle
code blocks - Fixed spacing of numbered
List
for double digits - Fixed
ProgressBar
not showing up in Windows high contrast mode - Top aligned all cells in
DataTable
- Fixed stacking order of loading overlay in
ResourceList
- Fixed form inputs in
Popover
that were disappearing instead of top aligning (thanks to @mbaumbach for the original issue) - Removed a redundant class on
OptionList
list items
Documentation
- Made
Modal
examples show the modal dialog by default - Changed fitted
Tabs
to have equal width when enough space is present
New components
withContext
Use withContext
to pass consumer context to a component.
withRef
Use withRef
with compose
to forwardRefs to a component.
v2.10.0
Enhancements
- Updated
Button
to accept aReact.ReactNode
for itsicon
prop
Documentation
- Refined accessibility checklist
Bug Fixes
- Added truncation to
Tag
v2.9.0
Enhancements
- Updated date filter labels in resource list
- Changed
placeholder
prop inSelect
to be the default selection - Added a
loading
prop toResourceList
that places a spinner overtop items and disables bulk actions
Documentation
- Clarified when and how to use icons in the banner component
- Updated footer help component guidelines to include content instructions for app developers
Bug fixes
- Fixed resource list component to correctly handle inclusive filter keys
- Fixed date field in DateSelector to not render an error when date is added by the date picker and field is blurred
- Fixed pagination from firing keypress events while focus is inside inputs or contenteditables
- Fixed
EmptyState
horizontally scrolling when fully condensed - Fixed the bottom margin of elements inside
Page
being ignored in some browsers - Added required
url
prop tobreadcrumbs
inPage
component examples - Fixed
ActionList
wrapping text within aPopover
- Fixed
Banner
spacing when inside of a section - Fixed
Stack
so it doesn't add extra spacing between items in Safari
v2.8.0
Bug fixes
- Reverted a change that caused the built embedded.js bundle to be way larger than it should be due to broad imports
Enhancements
- Added support for boolean type on Choice error prop
Documentation
- Updated banner guidelines to make it clearer when success banners should be used vs success toasts.
- Updated display text documentation to have a separate example for medium and large display
v2.7.2
Bug fixes
- Reverted a change adding Windows high contrast support to popover components that caused items in a popover not to be clickable
2.7.1
2.7.0
Enhancements
- Adjusted spacing for
ChoiceChildren
in choice list for readability - Made
Card.Header
a seperate publically accessible component - Added support for complex operators in
ResourceList
component - Updated the page component's primary action to support
Button
props. - Added validation for non-numeric input in a type="number"
TextField
- Added support for Windows High Contrast mode in the popover component
- Added circle information icon
Documentation
- Updated banner guidelines to make it clearer when success banners should be used vs success toasts.
- Added documentation for iOS and Android section header
v2.6.1
2.6.1 - 2018-08-21
Development workflow
- Moved
pa11y
andobject-hash
from dependencies to devDependencies
Bug fixes
- Fixed inconsistent drop zone error styling
2.6.0 - 2018-08-21
Development workflow
- Added a
test:coverage
script to gather and display test coverage results - Added Codecov test coverage checks to pull requests
- Added automated a11y testing to CI
Enhancements
- Added support for
FilterType.DateSelector
inResourceList
component - Added
code
as an acceptedvariation
of the text style component to provide support for accessible markup and styling of inline code snippets and code-like text - Added new
border-width
SCSS function - Added support for
fullWidth
andconnectedTop
props onButtonGroup
- Added
label
prop toDropZone
for better accessibility - Added support for radio buttons to accept a block as a
label
- Added a
singleColumn
prop to the skeleton page component - Updated the transition on large modals to match the default transition
- Added
nextKeys
,previousKeys
,nextTooltip
, andpreviousTooltip
props to the pagination component to support keypress handling and tooltips in pagination buttons. - Added examples to the layout component documentation for two and three column grid layouts
- Added an export for the
Progress
type to support downstream typechecking of the badge componentprogress
prop - Added an
iFrameName
prop to the modal component to support named iframe children - Added a
ScrollTo
subcomponent to the scrollable component to support scrolling to a child node programmatically - Added support for the button component to accept an array of strings as children
- Changed the primary focus target of an activated popover from the first focusable child to the popover itself
- Added an improved error message when the child of an embedded alert component is not a string(thanks @superwhykz for the original issue)
- Added a minimum width to tab items to improve touch target sizing and account for smaller tab titles
- Added support for additional accessibility attributes to the text field and option list components
- Added support for option list with avatars, icons, and thumbnails when
options
descriptors have amedia
property - Added support for destructive action list items
- Added support for option list
options
descriptors to accept a block for thelabel
property - Added
$page-max-width
variable to capture page calculatedmax-width
value andpage-when-not-max-width
mixin to trigger when page is resized horizontally - Added support for select error messages to be optional
- Updated the breadcrumbs component to support the
CallbackAction
type as a prop(thanks @dylan for the current issue and everyone who identified this.) - Added support for text field error messages to be optional
- Added a
disabled
prop to the choice component. Checkbox and radio labels are now styled to reflect their disabled state - Added support for Windows High Contrast mode in the select, checkbox and radio components
Bug fixes
- Fixed text field resizer rendering when
multiline
was false - Fixed modal header condensing
- Fixed tooltip so active prop activates on initial render
- Fixed popover border radius and left and right alignment
- Fixed visibility of the hidden implicit submit button in form (thanks @cgenevier for the original issue)
- Fixed alignment of wrapped empty state actions
- Swapped the import and export icons
- Fixed incorrect data table column count and content skipping in assistive technologies
- Fixed unintended form submittal by action list items enclosed in a
form
- Fixed text alignment of multiline option list option text
- Fixed an issue where the stack component would render incorrectly nested items
- Fixed spacing above annotated sections on smaller screens
- Fixed an issue that cause problems for some build tools
- Fixed the word-break of long text in labels and banners on small screens
Documentation
- Added examples for iOS and Android radio buttons
- Added examples for iOS and Android banners
- Added toast component
- Added examples for iOS and Android buttons
- Added examples for iOS and Android button groups
- Added examples for iOS and Android badge
- Added stepper component
New components
InlineError
Use inline errors to describe custom form inputs or form groups when invalid.
v2.5.0
Enhancements
- Added
weekStartsOn
prop to Datepicker
Bug fixes
- Remove stickyManager from app provider props interface
Documentation
- Added iOS and Android examples for the card component
Development workflow
- Renamed
yarn start:vrt
toyarn tophat
and updated the folder name to match - Improved
yarn tophat
’s design, and added a/all-components
route