UNPKG

@wix/design-system

Version:

@wix/design-system

36 lines (33 loc) 1.34 kB
### dataHook - type: string - description: Hook for testing purposes. ### insertPosition - type: "start" | "end" | "any" - description: Position where dragged items will be inserted. Using `any` value will allow the items to be re-ordered within the same column. - default: 'any' ### addItemButtonLabel - type: ReactNode - description: Title of add button. ### columns - type: TimeTableColumn[] - description: Column data configuration. Item content is provided as a simple node or a render function with `content` property. When render function is used the signature is: `({ Item, draggable, disabled }) => {}`: - `Item` - component used to provide default item visual representation. You should render `<Item draggable={draggable} disabled={disabled}>...</Item>` - `draggable` - item is draggable. - `disabled` - item is disabled. ### height - type: string | number - description: Custom table height. - default: '283px' ### onAdd - type: (columnIndex: number) => void - description: Event triggered on add button click: `onAdd(columnIndex)`. When not provided the button will be hidden. ### onChange - type: (columns: TimeTableColumn[], details: TimeTableChangeDetails) => void - description: Event triggered on column data change: `onChange(columns, { addedToColumnIndex, removedFromColumnIndex, addedItemIndex, removedItemIndex })`