Skip to content

Commit

Permalink
Merge pull request #18518 from timvandermeij/viewer-toolbar-height
Browse files Browse the repository at this point in the history
Introduce a CSS variable for the toolbar height (bug 1171799)
  • Loading branch information
timvandermeij authored Aug 1, 2024
2 parents ec0f0f3 + e3838c1 commit 0269cf5
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions web/viewer.css
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
--toolbar-border-color: rgb(184 184 184);
--toolbar-box-shadow: 0 1px 0 var(--toolbar-border-color);
--toolbar-border-bottom: none;
--toolbar-height: 32px;
--toolbarSidebar-box-shadow: inset calc(-1px * var(--dir-factor)) 0 0
rgb(0 0 0 / 0.25),
0 1px 0 rgb(0 0 0 / 0.15), 0 0 1px rgb(0 0 0 / 0.1);
Expand Down Expand Up @@ -270,7 +271,7 @@ body {

#sidebarContainer {
position: absolute;
inset-block: 32px 0;
inset-block: var(--toolbar-height) 0;
inset-inline-start: calc(-1 * var(--sidebar-width));
width: var(--sidebar-width);
visibility: hidden;
Expand All @@ -297,7 +298,7 @@ body {
}

#sidebarContent {
inset-block: 32px 0;
inset-block: var(--toolbar-height) 0;
inset-inline-start: 0;
overflow: auto;
position: absolute;
Expand All @@ -308,7 +309,7 @@ body {
#viewerContainer {
overflow: auto;
position: absolute;
inset: 32px 0 0;
inset: var(--toolbar-height) 0 0;
outline: none;
}
#viewerContainer:not(.pdfPresentationMode) {
Expand Down Expand Up @@ -342,7 +343,7 @@ body {

#toolbarSidebar {
width: 100%;
height: 32px;
height: var(--toolbar-height);
background-color: var(--sidebar-toolbar-bg-color);
box-shadow: var(--toolbarSidebar-box-shadow);
border-bottom: var(--toolbarSidebar-border-bottom);
Expand All @@ -362,14 +363,14 @@ body {
.secondaryToolbar,
.editorParamsToolbar {
position: relative;
height: 32px;
height: var(--toolbar-height);
background-color: var(--toolbar-bg-color);
box-shadow: var(--toolbar-box-shadow);
border-bottom: var(--toolbar-border-bottom);
}

#toolbarViewer {
height: 32px;
height: var(--toolbar-height);
}

#loadingBar {
Expand Down Expand Up @@ -447,7 +448,7 @@ body {
.findbar,
.secondaryToolbar,
.editorParamsToolbar {
top: 32px;
top: var(--toolbar-height);
position: absolute;
z-index: 30000;
height: auto;
Expand All @@ -466,7 +467,7 @@ body {
background-color: var(--toolbar-bg-color);
}
.findbar > div {
height: 32px;
height: var(--toolbar-height);
}
.findbar > div#findbarInputContainer {
margin-inline-end: 4px;
Expand Down

0 comments on commit 0269cf5

Please sign in to comment.