Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[BlockStack] Add
id
prop to the returned component (#11592)
<!-- ☝️How to write a good PR title: - Prefix it with [ComponentName] (if applicable), for example: [Button] - Start with a verb, for example: Add, Delete, Improve, Fix… - Give as much context as necessary and as little as possible - Open it as a draft if it’s a work in progress --> ### WHY are these changes introduced? Fixes #11196 <!-- link to issue if one exists --> <!-- Context about the problem that’s being addressed. --> ### WHAT is this pull request doing? It seems we missed returning the `id` prop when we created the final element with the React `createElement` API. ```js export const BlockStack = ({ as = 'div', children, align, inlineAlign, gap, id, reverseOrder = false, ...restProps }: BlockStackProps) => { ... return React.createElement( as, { className, // Missed the id prop in the final return component style: sanitizeCustomProperties(style), ...restProps, }, children, ); }; ``` ### 🎩 checklist - [x] Tested a [snapshot](https://github.com/Shopify/polaris/blob/main/documentation/Releasing.md#-snapshot-releases) - [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
- Loading branch information