-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Dropdown Component Updates #3211
Conversation
🎉 The demo notebooks match the run.py files! 🎉 |
All the demos for this PR have been deployed at https://huggingface.co/spaces/gradio-pr-deploys/pr-3211-all-demos |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The design of this dropdown isn't consistent with the previous one. The font size is too large when typing into the box and the padding around the text is not consistent with the other form inputs. As a result the heights of this component don't match with the heights of the other 'input' components.
Compare the dropdown to the Number
component at the top.
@dawoodkhan82 We can find another issue for that person. They are still having difficulties running the project locally. |
@dawoodkhan82 @pngwn for sure! I think it's something to do with the config of codespaces. I'll finally have access to my PC tomorrow (running on Ubuntu 22.04 LTS x64), and I'll take a final shot at it. I'll share an update if it doesn't work, else I'll simply drop a PR for #3163. Thanks again! 🙌🏼 Meanwhile, @dawoodkhan82 if there are any free issues that are up for grabs & need to be resolved, feel free to tag me. I'd love to fix that! |
@Neilblaze I'll be looking into your issue this week too. We don't want to discourage contributions because things are difficult to setup. |
@Neilblaze Will do! |
* add wildcard to image input * simplify mime types * changelog * regen noteboks --------- Co-authored-by: Abubakar Abid <abubakar@huggingface.co> Co-authored-by: pngwn <hello@pngwn.io>
* fix webcam * changelog * fix changelog * fix changelog * fix changelog --------- Co-authored-by: Abubakar Abid <abubakar@huggingface.co>
* latex height fix * changelog * formatting * em * em
* added benchmark queue script * changelg * fix instructions
* Fix matplotlib css * CHANGELOG * Undo lockfile
* Fix + test * Remove print statements + fix import for 3.7 * CHANGELOG * Remove more print statements * Add 60 second timeout for uploading data * Fix test --------- Co-authored-by: Abubakar Abid <abubakar@huggingface.co>
"flaky" backend tests are passing locally. Not sure what's going on |
I would ignore that failure @dawoodkhan82 ! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
@abidlabs mind taking a quick look? |
gradio/components.py
Outdated
@@ -1238,6 +1240,9 @@ def __init__( | |||
if multiselect: | |||
if isinstance(value, str): | |||
value = [value] | |||
if not multiselect and max_choices is not None: | |||
warnings.warn("Max choices is ignored when multiselect is False.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warnings.warn("Max choices is ignored when multiselect is False.") | |
warnings.warn("The `max_choices` parameter is ignored when `multiselect` is False.") |
Some documentation nits, but otherwise looks awesome @dawoodkhan82! |
Description
Default dropdown uses the custom dropdown UI (adding searching ability)
max_choices
param, can be set whenmultiselect
isTrue
Adding A11y accessibility
Some styling updates (hover over tokens)
Please include:
Closes: #3184, #3163
Checklist:
A note about the CHANGELOG
Hello 👋 and thank you for contributing to Gradio!
All pull requests must update the change log located in CHANGELOG.md, unless the pull request is labeled with the "no-changelog-update" label.
Please add a brief summary of the change to the Upcoming Release > Full Changelog section of the CHANGELOG.md file and include
a link to the PR (formatted in markdown) and a link to your github profile (if you like). For example, "* Added a cool new feature by
[@myusername](link-to-your-github-profile)
in[PR 11111](https://github.com/gradio-app/gradio/pull/11111)
".If you would like to elaborate on your change further, feel free to include a longer explanation in the other sections.
If you would like an image/gif/video showcasing your feature, it may be best to edit the CHANGELOG file using the
GitHub web UI since that lets you upload files directly via drag-and-drop.