Releases: Shopify/polaris-react
Releases · Shopify/polaris-react
v2.11.0
Enhancements
Tab.Itemwith aurlprop now renders anUnstyledLinkinstead of aButtonwhen displayed inPopoverand 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
ExceptionListdocumentation - 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__CloseButtonandPolaris-Modal-Header--withoutTitletoPolaris-Modal-CloseButtonandPolaris-Modal-CloseButton--withoutTitlerespectively.
Development workflow
- Added
d.tsfiles to test coverage ignore Pageis no longer self-closing in the playground
Bug fixes
- Fixed
Buttonalignment 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
InlineErrortext to align with theChoiceListlabels - Replaced hardcoded
remvalues with globally scalable ones onDataTable’s collapsed shadow, andTextStylecode blocks - Fixed spacing of numbered
Listfor double digits - Fixed
ProgressBarnot 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
Popoverthat were disappearing instead of top aligning (thanks to @mbaumbach for the original issue) - Removed a redundant class on
OptionListlist items
Documentation
- Made
Modalexamples show the modal dialog by default - Changed fitted
Tabsto 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
Buttonto accept aReact.ReactNodefor itsiconprop
Documentation
- Refined accessibility checklist
Bug Fixes
- Added truncation to
Tag
v2.9.0
Enhancements
- Updated date filter labels in resource list
- Changed
placeholderprop inSelectto be the default selection - Added a
loadingprop toResourceListthat 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
EmptyStatehorizontally scrolling when fully condensed - Fixed the bottom margin of elements inside
Pagebeing ignored in some browsers - Added required
urlprop tobreadcrumbsinPagecomponent examples - Fixed
ActionListwrapping text within aPopover - Fixed
Bannerspacing when inside of a section - Fixed
Stackso 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
ChoiceChildrenin choice list for readability - Made
Card.Headera seperate publically accessible component - Added support for complex operators in
ResourceListcomponent - Updated the page component's primary action to support
Buttonprops. - 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
pa11yandobject-hashfrom dependencies to devDependencies
Bug fixes
- Fixed inconsistent drop zone error styling
2.6.0 - 2018-08-21
Development workflow
- Added a
test:coveragescript 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.DateSelectorinResourceListcomponent - Added
codeas an acceptedvariationof the text style component to provide support for accessible markup and styling of inline code snippets and code-like text - Added new
border-widthSCSS function - Added support for
fullWidthandconnectedTopprops onButtonGroup - Added
labelprop toDropZonefor better accessibility - Added support for radio buttons to accept a block as a
label - Added a
singleColumnprop to the skeleton page component - Updated the transition on large modals to match the default transition
- Added
nextKeys,previousKeys,nextTooltip, andpreviousTooltipprops 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
Progresstype to support downstream typechecking of the badge componentprogressprop - Added an
iFrameNameprop to the modal component to support named iframe children - Added a
ScrollTosubcomponent 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
optionsdescriptors have amediaproperty - Added support for destructive action list items
- Added support for option list
optionsdescriptors to accept a block for thelabelproperty - Added
$page-max-widthvariable to capture page calculatedmax-widthvalue andpage-when-not-max-widthmixin to trigger when page is resized horizontally - Added support for select error messages to be optional
- Updated the breadcrumbs component to support the
CallbackActiontype 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
disabledprop 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
multilinewas 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
weekStartsOnprop 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:vrttoyarn tophatand updated the folder name to match - Improved
yarn tophat’s design, and added a/all-componentsroute