/**
* DO NOT EDIT
*
* This file was automatically generated by
* https://github.com/Polymer/gen-typescript-declarations
*
* To modify these typings, edit the source file(s):
* paper-input-behavior.html
*/
///
///
///
declare namespace Polymer {
/**
* Use `Polymer.PaperInputBehavior` to implement inputs with
* ``. This behavior is implemented by ``.
* It exposes a number of properties from
* `` and ` ` and they should be
* bound in your template.
*
* The input element can be accessed by the `inputElement` property if you need
* to access properties or methods that are not exposed.
*/
interface PaperInputBehavior extends Polymer.IronControlState, Polymer.IronA11yKeysBehavior {
/**
* Set to true to disable this input. If you're using PaperInputBehavior to
* implement your own paper-input-like element, bind this to
* both the ``'s and the input's `disabled` property.
*/
disabled: boolean|null|undefined;
keyBindings: object;
/**
* The label for this input. If you're using PaperInputBehavior to
* implement your own paper-input-like element, bind this to
* ``'s content and `hidden` property, e.g.
* `[[label]] ` in your `template`
*/
label: string|null|undefined;
/**
* The value for this input. If you're using PaperInputBehavior to
* implement your own paper-input-like element, bind this to
* the ``'s `bindValue`
* property, or the value property of your input that is `notify:true`.
*/
value: any;
/**
* Returns true if the value is invalid. If you're using PaperInputBehavior
* to implement your own paper-input-like element, bind this to both the
* ``'s and the input's `invalid` property.
*
* If `autoValidate` is true, the `invalid` attribute is managed
* automatically, which can clobber attempts to manage it manually.
*/
invalid: boolean|null|undefined;
/**
* Set this to specify the pattern allowed by `preventInvalidInput`. If
* you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `allowedPattern`
* property.
*/
allowedPattern: string|null|undefined;
/**
* The type of the input. The supported types are the
* [native input's
* types](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Form_ _types).
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the (Polymer 1) ` `'s or
* (Polymer 2)
* ``'s `type` property.
*/
type: string|null|undefined;
/**
* The datalist of the input (if any). This should match the id of an
* existing ``. If you're using PaperInputBehavior to implement
* your own paper-input-like element, bind this to the ` `'s `list` property.
*/
list: string|null|undefined;
/**
* A pattern to validate the `input` with. If you're using
* PaperInputBehavior to implement your own paper-input-like element, bind
* this to the ` `'s `pattern` property.
*/
pattern: string|null|undefined;
/**
* Set to true to mark the input as required. If you're using
* PaperInputBehavior to implement your own paper-input-like element, bind
* this to the ` `'s `required` property.
*/
required: boolean|null|undefined;
/**
* The error message to display when the input is invalid. If you're using
* PaperInputBehavior to implement your own paper-input-like element,
* bind this to the ``'s content, if using.
*/
errorMessage: string|null|undefined;
/**
* Set to true to show a character counter.
*/
charCounter: boolean|null|undefined;
/**
* Set to true to disable the floating label. If you're using
* PaperInputBehavior to implement your own paper-input-like element, bind
* this to the ``'s `noLabelFloat` property.
*/
noLabelFloat: boolean|null|undefined;
/**
* Set to true to always float the label. If you're using PaperInputBehavior
* to implement your own paper-input-like element, bind this to the
* ``'s `alwaysFloatLabel` property.
*/
alwaysFloatLabel: boolean|null|undefined;
/**
* Set to true to auto-validate the input value. If you're using
* PaperInputBehavior to implement your own paper-input-like element, bind
* this to the ``'s `autoValidate` property.
*/
autoValidate: boolean|null|undefined;
/**
* Name of the validator to use. If you're using PaperInputBehavior to
* implement your own paper-input-like element, bind this to
* the ` `'s `validator` property.
*/
validator: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `autocomplete`
* property.
*/
autocomplete: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `autofocus`
* property.
*/
autofocus: boolean|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `inputmode`
* property.
*/
inputmode: string|null|undefined;
/**
* The minimum length of the input value.
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `minlength`
* property.
*/
minlength: number|null|undefined;
/**
* The maximum length of the input value.
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `maxlength`
* property.
*/
maxlength: number|null|undefined;
/**
* The minimum (numeric or date-time) input value.
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `min` property.
*/
min: string|null|undefined;
/**
* The maximum (numeric or date-time) input value.
* Can be a String (e.g. `"2000-01-01"`) or a Number (e.g. `2`).
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `max` property.
*/
max: string|null|undefined;
/**
* Limits the numeric or date-time increments.
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `step` property.
*/
step: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `name` property.
*/
name: string|null|undefined;
/**
* A placeholder string in addition to the label. If this is set, the label
* will always float.
*/
placeholder: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `readonly`
* property.
*/
readonly: boolean|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `size` property.
*/
size: number|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `autocapitalize`
* property.
*/
autocapitalize: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `autocorrect`
* property.
*/
autocorrect: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `autosave`
* property, used with type=search.
*/
autosave: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `results` property,
* used with type=search.
*/
results: number|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the ` `'s `accept` property,
* used with type=file.
*/
accept: string|null|undefined;
/**
* If you're using PaperInputBehavior to implement your own paper-input-like
* element, bind this to the` `'s `multiple` property,
* used with type=file.
*/
multiple: boolean|null|undefined;
/**
* Returns a reference to the input element.
*/
readonly inputElement: HTMLElement;
/**
* Returns a reference to the focusable element.
*/
readonly _focusableElement: HTMLElement;
/**
* Forward focus to inputElement. Overriden from IronControlState.
*/
_focusBlurHandler(event: any): void;
attached(): void;
created(): void;
_appendStringWithSpace(str: any, more: any): any;
_onAddonAttached(event: any): void;
/**
* Validates the input element and sets an error style if needed.
*/
validate(): boolean;
/**
* Handler that is called when a shift+tab keypress is detected by the menu.
*
* @param event A key combination event.
*/
_onShiftTabDown(event: CustomEvent|null): void;
/**
* If `autoValidate` is true, then validates the element.
*/
_handleAutoValidate(): void;
/**
* Restores the cursor to its original position after updating the value.
*
* @param newValue The value that should be saved.
*/
updateValueAndPreserveCaret(newValue: string): void;
_computeAlwaysFloatLabel(alwaysFloatLabel: any, placeholder: any): any;
_updateAriaLabelledBy(): void;
_generateInputId(): void;
_onChange(event: any): void;
_autofocusChanged(): void;
}
const PaperInputBehavior: object;
}