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

Fix Tabs in Rows #9836

Merged
merged 5 commits into from
Oct 25, 2024
Merged

Fix Tabs in Rows #9836

merged 5 commits into from
Oct 25, 2024

Conversation

aliabid94
Copy link
Collaborator

@aliabid94 aliabid94 commented Oct 24, 2024

Tabs in Rows rendered incorrectly, now fixed:

Fixes: #9665

import gradio as gr

with gr.Blocks() as demo:
    with gr.Tabs(): # renders fine
        with gr.Tab("A"):
            gr.Markdown("A")
        with gr.Tab("B"):
            gr.Markdown("B")
    with gr.Row(): # renders weird
        with gr.Tabs():
            with gr.Tab("A"):
                gr.Markdown("A")
            with gr.Tab("B"):
                gr.Markdown("B")


    demo.launch()

@aliabid94 aliabid94 requested a review from hannahblair October 24, 2024 22:12
@gradio-pr-bot
Copy link
Collaborator

gradio-pr-bot commented Oct 24, 2024

🪼 branch checks and previews

Name Status URL
Spaces ready! Spaces preview
Storybook ready! Storybook preview
🦄 Changes detected! Details

Install Gradio from this PR

pip install https://gradio-pypi-previews.s3.amazonaws.com/759c42a231c2917b5737c293a982437ae67e01b8/gradio-5.3.0-py3-none-any.whl

Install Gradio Python Client from this PR

pip install "gradio-client @ git+https://github.com/gradio-app/gradio@759c42a231c2917b5737c293a982437ae67e01b8#subdirectory=client/python"

Install Gradio JS Client from this PR

npm install https://gradio-npm-previews.s3.amazonaws.com/759c42a231c2917b5737c293a982437ae67e01b8/gradio-client-1.7.0.tgz

Use Lite from this PR

<script type="module" src="https://gradio-lite-previews.s3.amazonaws.com/759c42a231c2917b5737c293a982437ae67e01b8/dist/lite.js""></script>

@gradio-pr-bot
Copy link
Collaborator

gradio-pr-bot commented Oct 24, 2024

🦄 change detected

This Pull Request includes changes to the following packages.

Package Version
@gradio/tabs patch
gradio patch
  • Maintainers can select this checkbox to manually select packages to update.

With the following changelog entry.

Fix Tabs in Rows

Maintainers or the PR author can modify the PR title to modify this entry.

Something isn't right?

  • Maintainers can change the version label to modify the version bump.
  • If the bot has failed to detect any changes, or if this pull request needs to update multiple packages to different versions or requires a more comprehensive changelog entry, maintainers can update the changelog file directly.

Copy link
Collaborator

@freddyaboulton freddyaboulton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified the fix @aliabid94 !

@freddyaboulton
Copy link
Collaborator

Going to merge so we can get into the release!

@freddyaboulton freddyaboulton merged commit a4e70f3 into main Oct 25, 2024
23 of 24 checks passed
@freddyaboulton freddyaboulton deleted the fix_tabs_in_row branch October 25, 2024 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

gr.Tab wrapped with gr.Row is displayed in a strange layout in Gradio 5
3 participants