From cddc1210f1981c2a46f66e15140b307bc368dbc7 Mon Sep 17 00:00:00 2001 From: Steven Lambert Date: Wed, 21 Oct 2020 13:33:04 -0600 Subject: [PATCH] feat(utils): deprecate get/set-scroll-state --- lib/core/utils/get-scroll-state.js | 1 + lib/core/utils/set-scroll-state.js | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/core/utils/get-scroll-state.js b/lib/core/utils/get-scroll-state.js index 9f05b04d45..41ee12353f 100644 --- a/lib/core/utils/get-scroll-state.js +++ b/lib/core/utils/get-scroll-state.js @@ -19,6 +19,7 @@ function getElmScrollRecursive(root) { /** * Get the scroll position of all scrollable elements in a page + * @deprecated */ function getScrollState(win = window) { const root = win.document.documentElement; diff --git a/lib/core/utils/set-scroll-state.js b/lib/core/utils/set-scroll-state.js index c6cb938cec..2f0f8a6eef 100644 --- a/lib/core/utils/set-scroll-state.js +++ b/lib/core/utils/set-scroll-state.js @@ -12,6 +12,7 @@ function setScroll(elm, top, left) { /** * set the scroll position of all items in the scrollState array + * @deprecated */ export function setScrollState(scrollState) { scrollState.forEach(({ elm, top, left }) => setScroll(elm, top, left));