Home: move to the top if the clicked tab is focus
All checks were successful
/ depoly (push) Successful in 1m4s

This commit is contained in:
thislight 2024-08-17 19:01:05 +08:00
parent 0f357a66e8
commit cecebda39b
No known key found for this signature in database
GPG key ID: A50F9451AC56A63E

View file

@ -282,6 +282,12 @@ const Home: ParentComponent = (props) => {
if (items.length > idx) {
items.item(idx).scrollIntoView({ block: "start", behavior: "smooth" });
}
if (isTabFocus(idx)) {
items.item(idx).scrollTo({
top: 0,
behavior: "smooth",
});
}
};
const openFullScreenToot = (