UNPKG

svelte-ux

Version:

- Increment version in `package.json` and commit as `Version bump to x.y.z` - `npm run publish`

25 lines (24 loc) 777 B
import { tweened } from 'svelte/motion'; export type DataBackgroundOptions = { value: number; domain: [number, number]; /** * Set color explicitly. Can also use the following: * - tailwind gradient classes (`from-blue-200 to-blue-400`) * - Set CSS variables `--color-from` and `--color-to` */ color?: string; /** * Render as bar. Default to fill (heatmap) */ bar?: boolean; /** Inset bar. Pass as [x,y] to specify per axis */ inset?: number | [number, number]; enabled?: boolean; /** * Show baseline */ baseline?: boolean; tweened?: Parameters<typeof tweened>[1]; }; export declare function dataBackground(node: HTMLElement, options: DataBackgroundOptions): SvelteActionReturnType;