Home: move to the top if the clicked tab is focus

This commit is contained in:
thislight 2024-08-17 19:01:05 +08:00
parent 673760e8f9
commit f8f0356a9f

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 = (