Skip to content

Commit

Permalink
Fix styling issues with Audio, Image and Video components (#5934)
Browse files Browse the repository at this point in the history
* audio styling fix

* video styling fix

* image examples styling fix

* add changeset

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
  • Loading branch information
aliabd and gradio-pr-bot committed Oct 16, 2023
1 parent 3618238 commit 8d90962
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 21 deletions.
8 changes: 8 additions & 0 deletions .changeset/sad-webs-end.md
@@ -0,0 +1,8 @@
---
"@gradio/audio": minor
"@gradio/image": minor
"@gradio/video": minor
"gradio": minor
---

feat:Fix styling issues with Audio, Image and Video components
6 changes: 0 additions & 6 deletions js/audio/interactive/Audio.svelte
Expand Up @@ -362,10 +362,4 @@
opacity: 0;
}
}
.container {
padding: var(--size-2);
width: var(--size-full);
height: var(--size-14);
}
</style>
9 changes: 9 additions & 0 deletions js/audio/shared/Audio.svelte
Expand Up @@ -31,3 +31,12 @@
{:catch error}
<p style="color: red;">{error.message}</p>
{/await}


<style>
audio {
padding: var(--size-2);
width: var(--size-full);
height: var(--size-14);
}
</style>
5 changes: 0 additions & 5 deletions js/image/example/Image.svelte
Expand Up @@ -17,11 +17,6 @@
</div>

<style>
.container {
border-radius: var(--radius-lg);
max-width: none;
}
.container.selected {
border-color: var(--border-color-accent);
}
Expand Down
2 changes: 2 additions & 0 deletions js/image/shared/Image.svelte
Expand Up @@ -18,5 +18,7 @@
img {
max-width: 100%;
max-height: 100%;
border-radius: var(--radius-lg);
max-width: none;
}
</style>
8 changes: 0 additions & 8 deletions js/video/shared/Player.svelte
Expand Up @@ -169,14 +169,6 @@
background-color: rgba(255, 255, 255, 0.9);
}
video {
position: inherit;
background-color: black;
width: var(--size-full);
height: var(--size-full);
object-fit: contain;
}
.mirror {
transform: scaleX(-1);
}
Expand Down
7 changes: 5 additions & 2 deletions js/video/shared/Video.svelte
Expand Up @@ -61,7 +61,10 @@

<style>
video {
max-width: 100%;
max-height: 100%;
position: inherit;
background-color: black;
width: var(--size-full);
height: var(--size-full);
object-fit: contain;
}
</style>

0 comments on commit 8d90962

Please sign in to comment.