UNPKG

@uva-glass/component-library

Version:

React components UvA

17 lines (16 loc) 878 B
import { ReactElement } from 'react'; import { SortableItemProps } from './components/SortableItem'; export type Index = string | number; export interface SortableProps { /** The elements to show inside the Sortable. */ children: ReactElement[] | string[]; /** The placement of each item Handle (6 dots 2x3). */ ItemHandlePlacement?: SortableItemProps['handlePlacement']; /** If true, a scrollable version of the list will be rendered (max height 21rem/336px). */ scrollable?: boolean; /** If true, the sorting will be disabled. */ disabled?: boolean; /** The callback function that is invoked when new sorting takes place. */ onSort?: (items: (string | ReactElement)[]) => void; } export declare const Sortable: ({ children, ItemHandlePlacement, scrollable, disabled, onSort }: SortableProps) => import("react/jsx-runtime").JSX.Element;