/** * Sorting management module for IOI Table. * Handles sort state and operations. */ import type { Ref } from 'vue'; import type { IoiSemanticEvent, IoiSemanticEventType, IoiTableState, SortState } from '../../types'; /** * Sorting API returned to the composable. */ export interface SortingApi { setSortState: (sortState: SortState[]) => void; toggleSort: (field: string, multi?: boolean) => void; } /** * Options for sorting module. */ export interface SortingOptions { onSortChange?: (sortState: SortState[]) => void; } /** * Event emitter function type. */ type EventEmitter = (type: IoiSemanticEventType, payload: TPayload) => IoiSemanticEvent; /** * Creates sorting management functions. */ export declare function createSorting(state: Ref, options: SortingOptions, emitEvent: EventEmitter): SortingApi; export { toggleSortState } from '../../utils/sort';