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

[sync] _states does not exist in type PaletteColorOptions & Partial<PaletteColorChannel> #382

Open
devleejb opened this issue Aug 12, 2024 · 7 comments
Labels
figma scope: sync Issues related to the Material UI Sync Figma plugin

Comments

@devleejb
Copy link

devleejb commented Aug 12, 2024

Steps to reproduce

Link to live example:

Steps:

  1. Export theme from Material UI Sync Plugin
  2. Apply it to the source code
  3. Check whether the _states are applied

Current behavior

  1. _states does not exist in type PaletteColorOptions & Partial<PaletteColorChannel>
    image

  2. The color isn't applied. (This screenshot is button.)
    image

Expected behavior

  1. _states are applied correctly.
  2. The colors are applied correctly.

Context

No response

Your environment

Software Version
Design file version v5.16.0
Design tool Figma
etc.

Search keywords: _states

@devleejb devleejb added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Aug 12, 2024
@zannager zannager added figma scope: sync Issues related to the Material UI Sync Figma plugin labels Aug 12, 2024
@adrianmanea
Copy link
Collaborator

Hi, as stated in the Figma docs "_states" group is only available in Figma. Simply omit everything that starts with an underscore.

@adrianmanea adrianmanea removed the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Aug 13, 2024
@devleejb
Copy link
Author

@adrianmanea
Some colors references the value in _states.

"background": "var(--mui-palette-primary-_states-hover)"

Then, how can use the color using MUI Sync Plugin?

@adrianmanea
Copy link
Collaborator

Can you please send an email at [email protected] with your Figma order ID so I send you the latest version, I think MUI Sync ignores the "_states" group when using the 5.17.0 library.

@devleejb
Copy link
Author

devleejb commented Aug 14, 2024

@adrianmanea
I sent the mail. Please check it.
Thank you!

@rown89
Copy link

rown89 commented Sep 2, 2024

There is any chance to handle _states in the 5.17.0 library?
MUI Sync generates classes who take care of _states variables but their values produce bugs.

@devleejb
Copy link
Author

It is not resolved in 5.17.0.
image

@yoandry-quantifi
Copy link

I'm facing the same issue in the latest MUI v5
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
figma scope: sync Issues related to the Material UI Sync Figma plugin
Projects
None yet
Development

No branches or pull requests

5 participants