-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support column/row deletion in
gr.DataFrame
(#10420)
* support deletion * changes * changes * add changeset * update icons * add changeset * notebook * changes * simplify * fix icons * changes * changes * change * revert * flaky test --------- Co-authored-by: gradio-pr-bot <[email protected]>
- Loading branch information
1 parent
324383f
commit a69b8e8
Showing
8 changed files
with
198 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
"@gradio/core": patch | ||
"@gradio/dataframe": patch | ||
"gradio": patch | ||
--- | ||
|
||
feat:Support column/row deletion in `gr.DataFrame` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
<script lang="ts"> | ||
export let icon: string; | ||
</script> | ||
|
||
{#if icon == "add-column-right"} | ||
<svg viewBox="0 0 24 24" width="16" height="16"> | ||
<rect | ||
x="4" | ||
y="6" | ||
width="4" | ||
height="12" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
fill="none" | ||
/> | ||
<path | ||
d="M12 12H19M16 8L19 12L16 16" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
fill="none" | ||
stroke-linecap="round" | ||
/> | ||
</svg> | ||
{:else if icon == "add-column-left"} | ||
<svg viewBox="0 0 24 24" width="16" height="16"> | ||
<rect | ||
x="16" | ||
y="6" | ||
width="4" | ||
height="12" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
fill="none" | ||
/> | ||
<path | ||
d="M12 12H5M8 8L5 12L8 16" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
fill="none" | ||
stroke-linecap="round" | ||
/> | ||
</svg> | ||
{:else if icon == "add-row-above"} | ||
<svg viewBox="0 0 24 24" width="16" height="16"> | ||
<rect | ||
x="6" | ||
y="16" | ||
width="12" | ||
height="4" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
/> | ||
<path | ||
d="M12 12V5M8 8L12 5L16 8" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
fill="none" | ||
stroke-linecap="round" | ||
/> | ||
</svg> | ||
{:else if icon == "add-row-below"} | ||
<svg viewBox="0 0 24 24" width="16" height="16"> | ||
<rect | ||
x="6" | ||
y="4" | ||
width="12" | ||
height="4" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
/> | ||
<path | ||
d="M12 12V19M8 16L12 19L16 16" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
fill="none" | ||
stroke-linecap="round" | ||
/> | ||
</svg> | ||
{:else if icon == "delete-row"} | ||
<svg viewBox="0 0 24 24" width="16" height="16"> | ||
<rect | ||
x="5" | ||
y="10" | ||
width="14" | ||
height="4" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
/> | ||
<path | ||
d="M8 7L16 17M16 7L8 17" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
stroke-linecap="round" | ||
/> | ||
</svg> | ||
{:else if icon == "delete-column"} | ||
<svg viewBox="0 0 24 24" width="16" height="16"> | ||
<rect | ||
x="10" | ||
y="5" | ||
width="4" | ||
height="14" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
/> | ||
<path | ||
d="M7 8L17 16M17 8L7 16" | ||
stroke="currentColor" | ||
stroke-width="2" | ||
stroke-linecap="round" | ||
/> | ||
</svg> | ||
{/if} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters