oui-kit
Version:
🎯 *UI toolkit with a French touch* 🇫🇷
50 lines (49 loc) • 1.34 kB
TypeScript
import { Component } from 'vue';
export interface OuiSliderOption<K> {
value: K;
title?: string;
icon?: Component | string;
sliderClass?: string;
}
export interface OuiTab<K extends string = string> extends OuiSliderOption<K> {
content?: any;
}
export interface OuiSegmentedOption<K = any> extends OuiSliderOption<K> {
}
export type OuiSegmentedOptions<K = any> = OuiSegmentedOption<K>[];
export interface OuiTableColumn<K = string> {
name: K;
title?: string;
sortable?: boolean;
align?: 'left' | 'center' | 'right';
valign?: 'top' | 'middle' | 'bottom';
footer?: string;
width?: number;
minWidth?: number;
maxWidth?: number;
grow?: boolean;
}
export interface OuiDraggableEvent {
startX: number;
startY: number;
pageX: number;
pageY: number;
deltaX: number;
deltaY: number;
moveX: number;
moveY: number;
timeMS: number;
}
export interface OuiSelectItem {
id: string | number;
/** Title to be presented */
title: string;
/** Text to be considered in search */
search?: string;
/** Perform this action on selection */
action?: (title: string) => void;
/** Is not automatically selected, if other possible selections are available */
skipSelection?: boolean;
/** HTML/CSS class of item */
class?: string;
}