mirror of
https://github.com/bendtherules/UiQuestions.git
synced 2026-08-18 22:02:42 +00:00
Accordion - Remove smooth scrolling
It is distracting and unlike normal anchor scroll
This commit is contained in:
@@ -27,7 +27,7 @@ const Accordion = ({ children, title = "More" }) => {
|
|||||||
}
|
}
|
||||||
// 4. and scroll into view and focus
|
// 4. and scroll into view and focus
|
||||||
targetElement.focus();
|
targetElement.focus();
|
||||||
targetElement.scrollIntoView({ behavior: "smooth", block: "center" });
|
targetElement.scrollIntoView({ block: "center" });
|
||||||
if ("scrollRestoration" in history) {
|
if ("scrollRestoration" in history) {
|
||||||
history.scrollRestoration = "auto";
|
history.scrollRestoration = "auto";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user