Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disabled: update docs to clarify the absence of inert polyfill #45272

Merged
merged 7 commits into from
Oct 26, 2022

Conversation

ciampo
Copy link
Contributor

@ciampo ciampo commented Oct 25, 2022

What?

Closes #45253

Update Disabled docs to clarify that the inert polyfill is not loaded

Why?

To manage expectations when interacting with the component in browsers where the inert attribute is not supported

✍️ Dev Note

The Disabled component internally relies on the inert property. In order to manage expectations when interacting with the component in browsers where the inert attribute is not supported, the component's docs were updated to clarify that the polyfill for the inert property needs to be added by the consumer of the @wordpress/components package.

@ciampo ciampo added [Type] Developer Documentation Documentation for developers Storybook Storybook and its stories for components labels Oct 25, 2022
@ciampo ciampo requested review from youknowriad and mirka October 25, 2022 09:59
@ciampo ciampo self-assigned this Oct 25, 2022
Copy link
Member

@mirka mirka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch!

As far as I could tell, this is only applicable to the inert polyfill, and to the Disabled component. So for now I think it would be more helpful to call this out in the docs for Disabled (specifically mentioning that you need an inert polyfill).

@ciampo ciampo requested a review from ajitbohra as a code owner October 25, 2022 21:15
@ciampo ciampo added the [Package] Components /packages/components label Oct 25, 2022
@ciampo ciampo changed the title Storybook: update docs to clarify the absence of polyfills Disabled: update Storybook example to clarify the absence of inert polyfill Oct 25, 2022
@ciampo
Copy link
Contributor Author

ciampo commented Oct 25, 2022

Good catch!

As far as I could tell, this is only applicable to the inert polyfill, and to the Disabled component. So for now I think it would be more helpful to call this out in the docs for Disabled (specifically mentioning that you need an inert polyfill).

Makes sense! I went ahead and applied the suggestions

@ciampo ciampo requested a review from mirka October 25, 2022 21:17
@ciampo ciampo added [Type] Developer Documentation Documentation for developers and removed [Type] Developer Documentation Documentation for developers labels Oct 25, 2022
Copy link
Member

@mirka mirka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very helpful note with the links! ✨ I feel like it would be better to put that note in the component's main JSDoc and README, since it's not specific to Storybook, no?

@ciampo ciampo changed the title Disabled: update Storybook example to clarify the absence of inert polyfill Disabled: update docs to clarify the absence of inert polyfill Oct 25, 2022
@ciampo
Copy link
Contributor Author

ciampo commented Oct 25, 2022

Makes sense ! Just pushed those updates too

@ciampo ciampo requested a review from mirka October 25, 2022 22:02
Copy link
Member

@mirka mirka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@ciampo ciampo merged commit 69a3cac into trunk Oct 26, 2022
@ciampo ciampo deleted the docs/storybook-no-polyfills branch October 26, 2022 07:28
@github-actions github-actions bot added this to the Gutenberg 14.5 milestone Oct 26, 2022
@bph bph added the Needs Dev Note Requires a developer note for a major WordPress release cycle label Feb 6, 2023
@bph
Copy link
Contributor

bph commented Feb 6, 2023

Flagged for Dev Note in a "Updates to components" dev note to point out that the documentation has changed. :-)

@bph bph mentioned this pull request Feb 6, 2023
47 tasks
@ciampo ciampo added has dev note when dev note is done (for upcoming WordPress release) and removed Needs Dev Note Requires a developer note for a major WordPress release cycle labels Feb 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
has dev note when dev note is done (for upcoming WordPress release) [Package] Components /packages/components Storybook Storybook and its stories for components [Type] Developer Documentation Documentation for developers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Storybook] Disabled component are still focusable in Firefox
3 participants