Skip to content

Commit

Permalink
Fix chatbot visible prop not reacting to changes (#10161)
Browse files Browse the repository at this point in the history
* Fix bug

* add changeset

* add changeset

---------

Co-authored-by: gradio-pr-bot <[email protected]>
  • Loading branch information
freddyaboulton and gradio-pr-bot authored Dec 9, 2024
1 parent 3e93740 commit 3a053cc
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .changeset/new-chefs-build.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@gradio/atoms": patch
"gradio": patch
---

fix:Fix chatbot `visible` prop not reacting to changes
6 changes: 4 additions & 2 deletions js/atoms/src/Block.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@
export let min_width = 0;
export let flex = false;
if (!visible) flex = false;
let tag = type === "fieldset" ? "fieldset" : "div";
const get_dimension = (
Expand All @@ -35,6 +33,10 @@
return dimension_value;
}
};
$: if (!visible) {
flex = false;
}
</script>

<svelte:element
Expand Down

0 comments on commit 3a053cc

Please sign in to comment.