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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[material-ui][Menu] Update icons to behave consistently in light & dark mode #35589

Open
2 tasks done
gerdadesign opened this issue Dec 23, 2022 · 3 comments
Open
2 tasks done
Assignees
Labels
bug 馃悰 Something doesn't work component: menu This is the name of the generic UI component, not the React module! design This is about UI or UX design, please involve a designer package: material-ui Specific to @mui/material

Comments

@gerdadesign
Copy link
Member

gerdadesign commented Dec 23, 2022

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Steps to reproduce 馃暪

Link to live example:
Current icon menu: https://mui.com/material-ui/react-menu/#icon-menu in dark mode

Current behavior 馃槸

Light mode:
Active + unfocused icons are at 54% opacity
Active + focused icons do not change

Dark mode:
Active + unfocused icons are at 100% opacity
Active + focused icons do not change

Expected behavior 馃

Material Design 2 guidelines for light and dark mode indicated that active + unfocused in dark mode should be at 70% opacity.
Light mode with icons Active + Focused state at 87% #000000; Active + Unfocused state at 54% #000000; Inactive state at 38% #000000

Dark mode with icons Active + Focused state at 100% #FFFFFF; Active + Unfocused state at 70% #FFFFFF; Inactive state at 50% #FFFFFF

Noting that Material Design 3 handles this differently and does not change the icon color upon focus. They opt for outlined vs filled icons in many examples.

Context 馃敠

#6619 comment

Your environment 馃寧

No response

@gerdadesign gerdadesign added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Dec 23, 2022
@zannager zannager added the package: icons Specific to @mui/icons label Dec 23, 2022
@ZeeshanTamboli
Copy link
Member

ZeeshanTamboli commented Dec 26, 2022

@gerdadesign Even in light mode, I could not see lesser opacity getting applied for icons while in inactive or active + unfocused states:

Recording_1672051808115.webm

Or am I checking in a wrong way? I use Windows OS.

@ZeeshanTamboli ZeeshanTamboli removed the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Dec 26, 2022
@ZeeshanTamboli ZeeshanTamboli added the design: material This is about Material Design, please involve a visual or UX designer in the process label Dec 26, 2022
@gerdadesign gerdadesign changed the title [Icon Menu] Update icons to match dark mode Material Design guidelines [Icon Menu] Update icons to behave consistently in light & dark mode Dec 27, 2022
@gerdadesign
Copy link
Member Author

@ZeeshanTamboli You're correct. I've updated the description. There is lower opacity in our disabled/inactive state, but we do not change opacity for focused.

Furthermore, our dark primary text is at 100% #FFF while Material (MD2) lists it at 87%. MD3 also uses slightly off white and off black color values.

It seems there are a few options:

  1. update the focused state color for both light mode and dark mode (but with Material You's new handling of icons, this may not be worth it)
  2. update dark mode icon to be a lower opacity (70%) and it will then follow the same behaviour as light mode currently
  3. same as 2. and also update the primary text color in dark mode
Dark mode: #FFFFFF 100% Dark mode: #FFFFFF Icon 70%, Text 87%
darkmode_0001_100 opacity darkmode_0000_lower opacity

@oliviertassinari oliviertassinari added component: menu This is the name of the generic UI component, not the React module! and removed package: icons Specific to @mui/icons labels Dec 31, 2022
@oliviertassinari
Copy link
Member

oliviertassinari commented Dec 31, 2022

Chrome v108 main menu in dark mode on Android 13. The icons have an opacity:

@oliviertassinari oliviertassinari added package: material-ui Specific to @mui/material bug 馃悰 Something doesn't work labels Dec 31, 2022
@zanivan zanivan self-assigned this Dec 4, 2023
@zanivan zanivan added design This is about UI or UX design, please involve a designer and removed design: material This is about Material Design, please involve a visual or UX designer in the process labels Dec 4, 2023
@zanivan zanivan changed the title [Icon Menu] Update icons to behave consistently in light & dark mode [material-ui][Menu] Update icons to behave consistently in light & dark mode Dec 4, 2023
@zanivan zanivan added this to the Material UI v6 milestone Dec 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 馃悰 Something doesn't work component: menu This is the name of the generic UI component, not the React module! design This is about UI or UX design, please involve a designer package: material-ui Specific to @mui/material
Projects
Status: Backlog
Development

No branches or pull requests

7 participants