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

fix(menuitem): prevent disabled and danger styles where it doesn't make sense #13223

Merged

Conversation

janhassel
Copy link
Member

Fixes some illogical uses of disabled and danger for MenuItem.

Testing / Reviewing

  • A MenuItem that is disabled should not emit onClick
  • A MenuItemSelectable that is disabled should not change on click
  • A MenuItem that is disabled and danger should not receive a red background hover
  • A MenuItem with children (submenu) can never be disabled
  • A MenuItem with children (submenu) can never be danger

@janhassel janhassel requested a review from a team as a code owner February 24, 2023 08:15
@netlify
Copy link

netlify bot commented Feb 24, 2023

Deploy Preview for carbon-components-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit a6351cb
🔍 Latest deploy log https://app.netlify.com/sites/carbon-components-react/deploys/63f87234d1d42800085ba641
😎 Deploy Preview https://deploy-preview-13223--carbon-components-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@netlify
Copy link

netlify bot commented Feb 24, 2023

Deploy Preview for carbon-components-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit bc90356
🔍 Latest deploy log https://app.netlify.com/sites/carbon-components-react/deploys/63fccf015a72270009ff4683
😎 Deploy Preview https://deploy-preview-13223--carbon-components-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

Copy link
Member

@tay1orjones tay1orjones left a comment

Choose a reason for hiding this comment

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

Nice! These make a ton of sense 👍

Copy link
Contributor

@andreancardona andreancardona left a comment

Choose a reason for hiding this comment

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

looks good!

@andreancardona andreancardona enabled auto-merge (squash) February 27, 2023 15:41
@andreancardona andreancardona merged commit 0f73b41 into carbon-design-system:main Feb 27, 2023
@janhassel janhassel deleted the menuitem-disabled-fixes branch February 27, 2023 16:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants