View as Markdown

API reference: @salmonui/data-grid

DataGridColumnResizeEventinterface

import type { DataGridColumnResizeEvent } from '@salmonui/data-grid';
interface DataGridColumnResizeEvent extends DataGridEvent {
    readonly field: string;
    readonly width: number;
    readonly previousWidth: number;
}

onColumnResizeStart (cancellable) / onColumnResize (per frame) / onColumnResizeEnd.

DataGridColumnResizeEvent members (7, 4 inherited)
NameSignatureDescription
fieldreadonly field: string;
widthreadonly width: number;

Width in px (live during the drag; committed on end).

previousWidthreadonly previousWidth: number;

Width in px when the resize started.

typeinheritedtype: string;

'sortChange', 'beforeSortChange', ...

sourceinheritedsource: DataGridEventSource;
defaultPreventedinheriteddefaultPrevented: boolean;

True after preventDefault() (before-events and click events).

preventDefaultinheritedpreventDefault: () => void;

Before-events and click events: cancels the action (or the built-in behavior).