X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/c617190905fe74cae33bcbd1e90ec2340f68d9b7..refs/pull/4002/head:/resources/js/services/util.js diff --git a/resources/js/services/util.js b/resources/js/services/util.js index 1a56ebf6c..238f8b1d8 100644 --- a/resources/js/services/util.js +++ b/resources/js/services/util.js @@ -34,7 +34,7 @@ export function scrollAndHighlightElement(element) { if (!element) return; element.scrollIntoView({behavior: 'smooth'}); - const color = document.getElementById('custom-styles').getAttribute('data-color-light'); + const color = getComputedStyle(document.body).getPropertyValue('--color-primary-light'); const initColor = window.getComputedStyle(element).getPropertyValue('background-color'); element.style.backgroundColor = color; setTimeout(() => {