UNPKG

intentful

Version:

Create Custom Skills with less headache

69 lines (68 loc) 2.55 kB
import { LabeledRequestHandler } from '../../../skill/models'; import { Calculable } from '../../../types'; import { Command, CommandModel, CommandProps } from '../../commands'; import { Gesture, GestureModel, GestureProps } from '../../gestures'; import { KeyboardHandlerProps } from '../../interfaces'; import { APLBaseComponentModel, APLBaseComponentProps, APLComponent } from '../component'; export interface APLTouchWrapperModel extends APLBaseComponentModel, APLTouchWrapperProps { } export interface APLTouchWrapperProps extends APLBaseComponentProps { /** * Command to execute when the component receives focus. */ onFocus?: Command<CommandModel, CommandProps>[]; /** * Command to execute when the component loses focus. */ onBlur?: Command<CommandModel, CommandProps>[]; handleKeyDown?: KeyboardHandlerProps[]; handleKeyUp?: KeyboardHandlerProps[]; /** * The component to focus if the down key is pressed. */ nextFocusDown?: Calculable<string>; /** * The component to focus if the tab key is pressed. */ nextFocusForward?: Calculable<string>; /** * The component to focus if the left key is pressed. */ nextFocusLeft?: Calculable<string>; /** * The component to focus if the right key is pressed. */ nextFocusRight?: Calculable<string>; /** * The component to focus if the up key is pressed. */ nextFocusUp?: Calculable<string>; gestures?: Gesture<GestureModel, GestureProps>[]; /** * Commands to execute when a gesture takes over the pointer. */ onCancel?: Command<CommandModel, CommandProps>[]; /** * Commands to execute when a pointer down event occurs. */ onDown?: Command<CommandModel, CommandProps>[]; /** * Commands to execute while moving the pointer. */ onMove?: Command<CommandModel, CommandProps>[]; /** * Commands to execute for a pointer down followed by an up. */ onPress?: Command<CommandModel, CommandProps>[]; /** * Commands to execute when releasing the pointer. */ onUp?: Command<CommandModel, CommandProps>[]; items?: APLComponent<APLBaseComponentModel, APLBaseComponentProps>[]; } export declare class APLTouchWrapper extends APLComponent<APLTouchWrapperModel, APLTouchWrapperProps> { readonly props: APLTouchWrapperProps; constructor(props: APLTouchWrapperProps); componentSpecificModel(): APLTouchWrapperModel; componentSpecificRequestHandlers(): LabeledRequestHandler[]; }