react-smooth-scrollbar-z
Version:
A React wrapper for Smooth Scrollbar with hooks and plugin support
20 lines (19 loc) • 616 B
TypeScript
import { ScrollbarPlugin } from "smooth-scrollbar";
export interface HighlightItemOptions {
selector: string;
className?: string;
mode?: "center" | "top" | "bottom" | "firstVisible" | "lastVisible";
}
export default class HighlightItemPlugin extends ScrollbarPlugin {
static pluginName: string;
private items;
private currentActive?;
transformOptions(options: HighlightItemOptions): {
selector: string;
className: string;
mode: "center" | "top" | "bottom" | "firstVisible" | "lastVisible";
};
onInit(): void;
onRender(): void;
onDestroy(): void;
}