UNPKG

@selenite/commons

Version:

This typescript package provides a set of frequently used utilities, types and svelte actions for building projects with Typescript and Svelte.

18 lines (17 loc) 547 B
import type { Action } from 'svelte/action'; /** * Adds horizontal scrolling to an element. * * This action removes the needs to press ctrl or right to scroll * horizontally. * @param node - The element to add horizontal scrolling to. * @param params - The duration of the scroll animation. * @returns svelte action */ export declare const horizontalScroll: Action<HTMLElement, { duration?: number; } | undefined>; /** * Scrolls into view an element. */ export declare const scrollIntoView: Action<HTMLElement, boolean | undefined>;