Hide dropdown if in single-select mode (#3678)

* Hide dropdown if in single-select mode

* Update changelog

---------

Co-authored-by: Abubakar Abid <abubakar@huggingface.co>
This commit is contained in:
space-nuko 2023-03-28 22:21:51 -04:00 committed by GitHub
parent 0b91a3363b
commit 61b9a58175
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View File

@ -20,6 +20,7 @@
- Support using an empty list as `gr.Dataframe` value, by [@space-nuko](https://github.com/space-nuko) in [PR 3646](https://github.com/gradio-app/gradio/pull/3646)
- Correct the documentation of `gr.File` component to state that its preprocessing method converts the uploaded file to a temporary file, by @RussellLuo in [PR 3660](https://github.com/gradio-app/gradio/pull/3660)
- Fixed bug in Serializer ValueError text by [@osanseviero](https://github.com/osanseviero) in [PR 3669](https://github.com/gradio-app/gradio/pull/3669)
- Hide `Remove All` button in `gr.Dropdown` single-select mode by [@space-nuko](https://github.com/space-nuko) in [PR 3678](https://github.com/gradio-app/gradio/pull/3678)
## Documentation Changes:

View File

@ -170,7 +170,7 @@
on:keyup={handleKeyup}
/>
<div
class:hide={!value?.length || disabled}
class:hide={!multiselect || !value?.length || disabled}
class="token-remove remove-all"
title="Remove All"
on:click={remove_all}
@ -281,4 +281,8 @@
width: 20px;
height: 20px;
}
.hide {
display: none;
}
</style>