Skip to content

Commit

Permalink
Fix viewer background color overflow
Browse files Browse the repository at this point in the history
  • Loading branch information
allanlasser committed Nov 18, 2024
1 parent a4d4ae6 commit 631d8cf
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion src/lib/components/layouts/ContentLayout.svelte
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
<div class="container">
<script lang="ts">
export let noBgColor = false;
</script>

<div class="container" class:noBgColor>
{#if $$slots.header}
<header>
<slot name="header" />
Expand Down Expand Up @@ -28,6 +32,10 @@
background: var(--gray-1);
box-shadow: inset var(--shadow-2);
}
.container.noBgColor {
background: unset;
box-shadow: unset;
}
header {
flex: 0 0 0;
width: 100%;
Expand Down
2 changes: 1 addition & 1 deletion src/lib/components/viewer/Viewer.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ Assumes it's a child of a ViewerContext
</script>

<div class="container">
<ContentLayout>
<ContentLayout noBgColor>
<!-- toolbars -->
<Flex slot="header">
{#if !embed && $sidebars["navigation"] === false}
Expand Down

0 comments on commit 631d8cf

Please sign in to comment.