Skip to content

Commit

Permalink
Fix share button position (#5470)
Browse files Browse the repository at this point in the history
* fix share button position

* add changeset

* top padding

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
  • Loading branch information
dawoodkhan82 and gradio-pr-bot committed Sep 11, 2023
1 parent b271e73 commit a4e010a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
6 changes: 6 additions & 0 deletions .changeset/tricky-rabbits-glow.md
@@ -0,0 +1,6 @@
---
"@gradio/chatbot": patch
"gradio": patch
---

fix:Fix share button position
11 changes: 8 additions & 3 deletions js/chatbot/static/ChatBot.svelte
Expand Up @@ -96,7 +96,7 @@
</script>

{#if show_share_button && value !== null && value.length > 0}
<div class="icon-button">
<div class="share-button">
<ShareButton
on:error
on:share
Expand Down Expand Up @@ -157,7 +157,7 @@
{/if}

{#if show_copy_button && message && typeof message === "string"}
<div class="icon-button">
<div class="copy-button">
<Copy value={message} />
</div>
{/if}
Expand Down Expand Up @@ -347,10 +347,15 @@
.message-buttons-fit {
margin-right: 0px;
}
.icon-button {
.copy-button {
margin-top: -10px;
margin-bottom: -10px;
}
.share-button {
position: absolute;
top: 4px;
right: 6px;
}
.like {
display: flex;
height: var(--size-8);
Expand Down

0 comments on commit a4e010a

Please sign in to comment.