diff --git a/packages/presentation/src/components/PDFViewer.svelte b/packages/presentation/src/components/PDFViewer.svelte
index 4023fd5d36..da5fd2c5c3 100644
--- a/packages/presentation/src/components/PDFViewer.svelte
+++ b/packages/presentation/src/components/PDFViewer.svelte
@@ -76,17 +76,17 @@
height: 4.5rem;
min-height: 4.5rem;
- .arrow-back {
- margin-right: 1rem;
- width: 1.5rem;
- height: 1.5rem;
- cursor: pointer;
- .icon {
- color: #1F212B;
- opacity: .4;
- }
- &:hover .icon { opacity: 1; }
- }
+ // .arrow-back {
+ // margin-right: 1rem;
+ // width: 1.5rem;
+ // height: 1.5rem;
+ // cursor: pointer;
+ // .icon {
+ // color: #1F212B;
+ // opacity: .4;
+ // }
+ // &:hover .icon { opacity: 1; }
+ // }
.user { margin-left: .75rem; }
.name {
diff --git a/packages/ui/src/components/Scroller.svelte b/packages/ui/src/components/Scroller.svelte
index 13e852ee0e..1d3a4c0854 100644
--- a/packages/ui/src/components/Scroller.svelte
+++ b/packages/ui/src/components/Scroller.svelte
@@ -24,6 +24,7 @@
let divScroll: HTMLElement
let divBox: HTMLElement
let divBack: HTMLElement
+ let divBar: HTMLElement
let divEl: HTMLElement
const checkBack = (): void => {
@@ -45,6 +46,17 @@
} else divBack.style.visibility = 'hidden'
}
+ const checkBar = (): void => {
+ if (divBar && divScroll) {
+ const proc = divScroll.clientHeight / divScroll.scrollHeight * 100
+ const procScroll = (divScroll.clientHeight - 8) / 100
+ const procTop = divScroll.scrollTop / divScroll.scrollHeight
+ divBar.style.height = procScroll * proc + 'px'
+ divBar.style.top = procTop * (divScroll.clientHeight - 8) + 4 + 'px'
+ divBar.style.visibility = 'visible'
+ }
+ }
+
let observer = new IntersectionObserver(changes => {
for (const change of changes) {
if (divBack) {
@@ -71,6 +83,7 @@
else if (b > 0) mask = 'top'
else mask = 'none'
if (isBack) checkBack()
+ if (mask !== 'none') checkBar()
}
onMount(() => {
@@ -89,22 +102,35 @@
afterUpdate(() => { if (divScroll) checkFade() })
-