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

Refactored Disabled component to use React Hooks #23917

Merged
merged 2 commits into from
Jul 14, 2020

Conversation

javidalkaruzi
Copy link
Contributor

Description

See #22890

Refactored the Disabled component to use React Hooks.

How has this been tested?

Tested using existing unit tests.
Observed in Storybook that the components specified were disabled when rendered and automatically disabled again if I, the user, manipulate the DOM

Types of changes

Code refactor

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.
  • I've included developer documentation if appropriate.
  • I've updated all React Native files affected by any refactorings/renamings in this PR.

Copy link
Contributor

@youknowriad youknowriad left a comment

Choose a reason for hiding this comment

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

Left a very minor comment, but this is looking good.

packages/components/src/disabled/index.js Outdated Show resolved Hide resolved
@youknowriad youknowriad merged commit 90920ac into WordPress:master Jul 14, 2020
@github-actions github-actions bot added this to the Gutenberg 8.6 milestone Jul 14, 2020
@ZebulanStanphill ZebulanStanphill added the [Type] Code Quality Issues or PRs that relate to code quality label Jul 14, 2020
@javidalkaruzi javidalkaruzi deleted the refactor/disabled branch July 22, 2020 14:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Code Quality Issues or PRs that relate to code quality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants