license import { ElementDimensions } from './element-dimensions' ; /** Modifier keys that may be held while typing. */ export interface ModifierKeys { control ? : boolean ; alt ? : boolean ; shift ? : boolean ; meta ? : boolean ; } /** Data that can be attached to a custom event dispatched from a `TestElement`. */ export type EventData = string | number | boolean | undefined | null | EventData [ ] | { [ key ] : EventData ; } ; /** An enum of non-text keys that can be used with the `sendKeys` method. */ export enum TestKey { BACKSPACE , TAB , ENTER , SHIFT , CONTROL , ALT , ESCAPE , PAGE_UP , PAGE_DOWN , END , HOME , LEFT_ARROW , UP_ARROW , RIGHT_ARROW , DOWN_ARROW , INSERT , DELETE , F1 , F2 , F3 , F4 , F5 , F6 , F7 , F8 , F9 , F10 , F11 , F12 , META } /**
 * This acts as a common interface for DOM elements across both unit and e2e tests. It is the
 * interface through which the ComponentHarness interacts with the component's DOM.
 */ export interface TestElement { /** Blur the element. */ blur ( ) : Promise < void > ; /** Clear the element's input (for input and textarea elements only). */ clear ( ) : Promise < void > ; /**
     * Click the element at the default location for the current environment. If you need to guarantee
     * the element is clicked at a specific location, consider using `click('center')` or
     * `click(x, y)` instead.
     */ click ( modifiers ? ) : Promise < void > ; /** Click the element at the element's center. */ click ( location , modifiers ? ) : Promise < void > ; param relativeX param relativeY param modifiers click ( relativeX , relativeY , modifiers ? ) : Promise < void > ; param relativeX param relativeY param modifiers rightClick ( relativeX , relativeY , modifiers ? ) : Promise < void > ; /** Focus the element. */ focus ( ) : Promise < void > ; /** Get the computed value of the given CSS property for the element. */ getCssValue ( property ) : Promise < string > ; /** Hovers the mouse over the element. */ hover ( ) : Promise < void > ; /** Moves the mouse away from the element. */ mouseAway ( ) : Promise < void > ; /**
     * Sends the given string to the input as a series of key presses. Also fires input events
     * and attempts to add the string to the Element's value. Note that some environments cannot
     * reproduce native browser behavior for keyboard shortcuts such as Tab, Ctrl + A, etc.
     */ sendKeys ( ... keys ) : Promise < void > ; /**
     * Sends the given string to the input as a series of key presses. Also fires input events
     * and attempts to add the string to the Element's value.
     */ sendKeys ( modifiers , ... keys ) : Promise < void > ; param options text ( options ? ) : Promise < string > ; /** Gets the value for the given attribute from the element. */ getAttribute ( name ) : Promise < string | null > ; /** Checks whether the element has the given class. */ hasClass ( name ) : Promise < boolean > ; /** Gets the dimensions of the element. */ getDimensions ( ) : Promise < ElementDimensions > ; /** Gets the value of a property of an element. */ getProperty < T = any > ( name ) : Promise < T > ; /** Checks whether this element matches the given selector. */ matchesSelector ( selector ) : Promise < boolean > ; /** Checks whether the element is focused. */ isFocused ( ) : Promise < boolean > ; /** Sets the value of a property of an input. */ setInputValue ( value ) : Promise < void > ; /** Selects the options at the specified indexes inside of a native `select` element. */ selectOptions ( ... optionIndexes ) : Promise < void > ; param name dispatchEvent ( name , data ? ) : Promise < void > ; } export interface TextOptions { /** Optional selector for elements to exclude. */ exclude ? : string ; }