UNPKG

@adaptabletools/adaptable

Version:

Powerful data-agnostic HTML5 AG Grid extension which provides advanced, cutting-edge functionality to meet all DataGrid requirements

38 lines (37 loc) 1.06 kB
import { BaseState } from './BaseState'; import { ColumnScope } from './Common/ColumnScope'; import { SuspendableObject } from './Common/SuspendableObject'; /** * Adaptable State Section for Shortcut Module */ export interface ShortcutState extends BaseState { /** * Collection of Shortcuts - designed to speed up data entry */ Shortcuts?: Shortcut[]; } /** * Shortcut scope data type. */ export type ShortcutScopeDataType = 'number'; /** * Used to define a Shortcut as used in Shortcut State */ export interface Shortcut extends SuspendableObject { /** * Numeric Columns where Shortcut is applied */ Scope: ColumnScope<ShortcutScopeDataType>; /** * Key which triggers the Shortcut when pressed */ ShortcutKey: string; /** * Value acting as 2nd operand for ShortcutOperation (1st operand is the cell value) */ ShortcutValue: number; /** * The Operation: 'Add', 'Subtract', 'Multiply', 'Divide' */ ShortcutOperation: 'Add' | 'Subtract' | 'Multiply' | 'Divide'; }