-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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 limited brush colors in image editor #9234
base: main
Are you sure you want to change the base?
Conversation
🪼 branch checks and previews
Install Gradio from this PR pip install https://gradio-pypi-previews.s3.amazonaws.com/cc8631bf85dcebe9c1b197d0d9769d77c92709e1/gradio-4.44.1-py3-none-any.whl Install Gradio Python Client from this PR pip install "gradio-client @ git+https://github.com/gradio-app/gradio@cc8631bf85dcebe9c1b197d0d9769d77c92709e1#subdirectory=client/python" Install Gradio JS Client from this PR npm install https://gradio-npm-previews.s3.amazonaws.com/cc8631bf85dcebe9c1b197d0d9769d77c92709e1/gradio-client-1.5.2.tgz Use Lite from this PR <script type="module" src="https://gradio-lite-previews.s3.amazonaws.com/cc8631bf85dcebe9c1b197d0d9769d77c92709e1/dist/lite.js""></script> |
🦄 change detectedThis Pull Request includes changes to the following packages.
With the following changelog entry.
Maintainers or the PR author can modify the PR title to modify this entry.
|
I'm not sure about this. I understand the desire but don't know if this is the right UX. at the very least the CSS needs some tweaking to clean up the padding. What do you think @hannahblair? |
Sorry, UX is not something I usually do. I can match the top margin to the bottom one. Is there anything else I should do? |
I know this is a small change, so I'll provide some context. I was trying to use the image editor for drawing a semantic label image. Popular datasets used to train models for this task like COCO-Stuff, Cityscapes, and ADE20K, make use of more than 4 labels in the semantic image, meaning more than 4 colors. Therefore, the current limit on the number of brush colors makes using this component for this particular task very difficult. I've looked for potential workarounds but couldn't find any. Apologies if I've missed something. |
Hey! Totally understand the use case and sorry it's taken us so long to get back to you! We've been a little busy planning the upcoming release. I think @hannahblair is gonna take a closer look at this as soon as possible! Thanks again for submitting the PR and sorry for the delay! |
Description
Related to: #8102
Removes the hardcoded limit of 4 colors in the brush color swatch in the image editor. It now supports displaying all available colors which automatically wrap to new rows by using flex-wrap: wrap.