/** * Get the scrollbar offset distance. * * TODO: Remove in 1.0 (we used this in public examples) */ export function getScrollbarOffset() { try { if (window.innerWidth > document.documentElement.clientWidth) { return window.innerWidth - document.documentElement.clientWidth; } } catch (err) {} return 0; }