STYLE: ListRow ScrollBar

This commit is contained in:
EvanLin3141
2025-03-04 17:09:22 +00:00
parent 726ba83a98
commit b974ea09c5
2 changed files with 23 additions and 8 deletions

View File

@@ -1,8 +1,23 @@
.hide-scrollbar::-webkit-scrollbar {
display: none;
:root {
--scrollbar-background: linear-gradient(to right, #6a11cb, #2575fc);
--scrollbar-thumb: rgba(255, 255, 255, 0.6);
}
.hide-scrollbar {
-ms-overflow-style: none;
scrollbar-width: none;
}
::-webkit-scrollbar {
height: 4px;
}
::-webkit-scrollbar-track {
background: transparent;
border-radius: 5px;
}
::-webkit-scrollbar-thumb {
background: var(--scrollbar-thumb);
border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
background: rgba(255, 255, 255, 0.9);
}

View File

@@ -47,7 +47,7 @@ const ListRow = forwardRef<ListRowRef, ListRowProps>((props, ref) => {
const [currentItems, setCurrentItems] = useState<ItemType[]>(items);
const slider = useRef<HTMLDivElement>(null);
const scrollAmount = window.innerWidth * 0.3;
const scrollAmount = window.innerWidth * 0.4;
const navigate = useNavigate();
const addMoreItems = (newItems: ItemType[]) => {