@sheetwrite/vueinterface
Framework-neutral named editor definition registered through GridOptions.editors.
- Package
@sheetwrite/vue- Source
packages/core/dist/types/grid.d.ts#L44
Members 1
mount
mount(host: HTMLElement, context: CellEditorContextinterface CellEditorContext {
readonly grid: Grid;
readonly address: Readonly<CellAddress>;
readonly viewAddress: Readonly<CellAddress>;
readonly column: Readonly<Column>;
readonly value: CellScalar;
readonly text: string;
readonly initialInput: string | undefined;
readonly selectAll: boolean;
readonly label: string;
readonly signal: AbortSignal;
commit(value: string, navigation?: CellEditorNavigation): void;
cancel(): void;
}interface CellEditorContext {
readonly grid: Grid;
readonly address: Readonly<CellAddress>;
readonly viewAddress: Readonly<CellAddress>;
readonly column: Readonly<Column>;
readonly value: CellScalar;
readonly text: string;
readonly initialInput: string | undefined;
readonly selectAll: boolean;
readonly label: string;
readonly signal: AbortSignal;
commit(value: string, navigation?: CellEditorNavigation): void;
cancel(): void;
}interface CellEditorContext {
readonly grid: Grid;
readonly address: Readonly<CellAddress>;
readonly viewAddress: Readonly<CellAddress>;
readonly column: Readonly<Column>;
readonly value: CellScalar;
readonly text: string;
readonly initialInput:
string | undefined;
readonly selectAll: boolean;
readonly label: string;
readonly signal: AbortSignal;
commit(
value: string,
navigation?: CellEditorNavigation,
): void;
cancel(): void;
}Immutable state and guarded completion callbacks for one mounted editor.API reference →): CellEditorInstanceinterface CellEditorInstance {
update(context: CellEditorContext): void;
reposition(rect: CellEditorRect): void;
commit(
navigation: CellEditorNavigation,
): string | undefined | Promise<string | undefined>;
cancel(): void;
destroy(): void;
}interface CellEditorInstance {
update(context: CellEditorContext): void;
reposition(rect: CellEditorRect): void;
commit(
navigation: CellEditorNavigation,
): string | undefined | Promise<string | undefined>;
cancel(): void;
destroy(): void;
}interface CellEditorInstance {
update(
context: CellEditorContext,
): void;
reposition(
rect: CellEditorRect,
): void;
commit(
navigation: CellEditorNavigation,
):
| string
| undefined
| Promise<string | undefined>;
cancel(): void;
destroy(): void;
}Retained lifecycle returned by a custom editor's mount method.API reference →;Declaration
View full TypeScript declaration
export interface CellEditor { mount(host: HTMLElement, context: CellEditorContextinterface CellEditorContext {
readonly grid: Grid;
readonly address: Readonly<CellAddress>;
readonly viewAddress: Readonly<CellAddress>;
readonly column: Readonly<Column>;
readonly value: CellScalar;
readonly text: string;
readonly initialInput: string | undefined;
readonly selectAll: boolean;
readonly label: string;
readonly signal: AbortSignal;
commit(value: string, navigation?: CellEditorNavigation): void;
cancel(): void;
}interface CellEditorContext {
readonly grid: Grid;
readonly address: Readonly<CellAddress>;
readonly viewAddress: Readonly<CellAddress>;
readonly column: Readonly<Column>;
readonly value: CellScalar;
readonly text: string;
readonly initialInput: string | undefined;
readonly selectAll: boolean;
readonly label: string;
readonly signal: AbortSignal;
commit(value: string, navigation?: CellEditorNavigation): void;
cancel(): void;
}interface CellEditorContext {
readonly grid: Grid;
readonly address: Readonly<CellAddress>;
readonly viewAddress: Readonly<CellAddress>;
readonly column: Readonly<Column>;
readonly value: CellScalar;
readonly text: string;
readonly initialInput:
string | undefined;
readonly selectAll: boolean;
readonly label: string;
readonly signal: AbortSignal;
commit(
value: string,
navigation?: CellEditorNavigation,
): void;
cancel(): void;
}Immutable state and guarded completion callbacks for one mounted editor.API reference →): CellEditorInstanceinterface CellEditorInstance {
update(context: CellEditorContext): void;
reposition(rect: CellEditorRect): void;
commit(
navigation: CellEditorNavigation,
): string | undefined | Promise<string | undefined>;
cancel(): void;
destroy(): void;
}interface CellEditorInstance {
update(context: CellEditorContext): void;
reposition(rect: CellEditorRect): void;
commit(
navigation: CellEditorNavigation,
): string | undefined | Promise<string | undefined>;
cancel(): void;
destroy(): void;
}interface CellEditorInstance {
update(
context: CellEditorContext,
): void;
reposition(
rect: CellEditorRect,
): void;
commit(
navigation: CellEditorNavigation,
):
| string
| undefined
| Promise<string | undefined>;
cancel(): void;
destroy(): void;
}Retained lifecycle returned by a custom editor's mount method.API reference →;}