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
Add option to disable the detailed view of the gallery #4470
Conversation
All the demos for this PR have been deployed at https://huggingface.co/spaces/gradio-pr-deploys/pr-4470-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.
LGTM @freddyaboulton. Tested the parameter directly and with .update()
and works great!
Is there a better term than detailed view? Maybe full screen or zoomed or something? |
@pngwn How about |
Actually we have an existing parameter Some test code confirming import gradio as gr
def test(x: gr.SelectData):
print(x.index)
with gr.Blocks() as demo:
gallery = gr.Gallery(
["cheetah.jpg"]*4,
preview=True,
detailed_view=False
)
gallery.select(test, None, None)
demo.launch() |
Sounds good @abidlabs! In hindsight, we should have renamed Yes, |
Agreed about the naming 馃槄 |
6df101b
to
5c93129
Compare
Thanks @abidlabs ! Renamed to |
Sorry for late reply but I like the new name. |
Description
Closes: #3763
You can test by making the following change to
fake_gan
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.