mirror of
https://github.com/gradio-app/gradio.git
synced 2024-11-27 01:40:20 +08:00
ensure gr.Dataframe
updates as expected (#6290)
* ensure Dataframe updates as expected * add changeset * add changeset * ensure Dataframe updates as expected --------- Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
This commit is contained in:
parent
5668036eef
commit
e8216be948
6
.changeset/twelve-dolls-lay.md
Normal file
6
.changeset/twelve-dolls-lay.md
Normal file
@ -0,0 +1,6 @@
|
||||
---
|
||||
"@gradio/dataframe": patch
|
||||
"gradio": patch
|
||||
---
|
||||
|
||||
fix:ensure `gr.Dataframe` updates as expected
|
@ -1 +1 @@
|
||||
{"cells": [{"cell_type": "markdown", "id": "302934307671667531413257853548643485645", "metadata": {}, "source": ["# Gradio Demo: dataframe_component"]}, {"cell_type": "code", "execution_count": null, "id": "272996653310673477252411125948039410165", "metadata": {}, "outputs": [], "source": ["!pip install -q gradio "]}, {"cell_type": "code", "execution_count": null, "id": "288918539441861185822528903084949547379", "metadata": {}, "outputs": [], "source": ["import gradio as gr \n", "\n", "with gr.Blocks() as demo:\n", " gr.Dataframe(interactive=True)\n", "\n", "demo.launch()"]}], "metadata": {}, "nbformat": 4, "nbformat_minor": 5}
|
||||
{"cells": [{"cell_type": "markdown", "id": "302934307671667531413257853548643485645", "metadata": {}, "source": ["# Gradio Demo: dataframe_component"]}, {"cell_type": "code", "execution_count": null, "id": "272996653310673477252411125948039410165", "metadata": {}, "outputs": [], "source": ["!pip install -q gradio "]}, {"cell_type": "code", "execution_count": null, "id": "288918539441861185822528903084949547379", "metadata": {}, "outputs": [], "source": ["import gradio as gr\n", "\n", "with gr.Blocks() as demo:\n", " gr.Dataframe(interactive=True)\n", "\n", "demo.launch()\n"]}], "metadata": {}, "nbformat": 4, "nbformat_minor": 5}
|
@ -1,6 +1,6 @@
|
||||
import gradio as gr
|
||||
import gradio as gr
|
||||
|
||||
with gr.Blocks() as demo:
|
||||
gr.Dataframe(interactive=True)
|
||||
|
||||
demo.launch()
|
||||
demo.launch()
|
||||
|
@ -99,6 +99,7 @@
|
||||
{col_count}
|
||||
{value}
|
||||
{headers}
|
||||
on:change={(e) => (value = e.detail)}
|
||||
on:select={(e) => gradio.dispatch("select", e.detail)}
|
||||
{wrap}
|
||||
{datatype}
|
||||
|
@ -44,7 +44,7 @@
|
||||
|
||||
function handle_blur({
|
||||
currentTarget
|
||||
}: {
|
||||
}: Event & {
|
||||
currentTarget: HTMLInputElement;
|
||||
}): void {
|
||||
value = currentTarget.value;
|
||||
|
Loading…
Reference in New Issue
Block a user