{
divHeight = element.clientHeight
}}
class="scroll relative flex-shrink"
class:overflow-x={horizontal ? 'auto' : 'hidden'}
on:scroll={(evt) => {
if ($tooltipstore.label !== undefined) closeTooltip()
const newPos = divScroll?.scrollTop ?? 0
// TODO: Workaround: https://front.hc.engineering/workbench/platform/tracker/TSK-760
// In Safari scroll could jump on click, with no particular reason.
if (scrollY !== 0 && Math.abs(newPos - scrollY) > 100 && divScroll !== undefined && isSafari()) {
divScroll.scrollTop = scrollY
}
scrollY = divScroll?.scrollTop ?? 0
}}
>
{
checkAutoScroll()
checkFade()
}}
on:dragover
on:drop
on:scroll
>
{#if bottomStart}
{/if}