/** * General INPUT widget. */ import { IDomArgs, Observable } from '../../index'; export interface IInputOptions { onInput?: boolean; isValid?: Observable; } /** * Creates a input element tied to the given observable. The required options argument allows * controlling the behavior, see IInputOptions for details. * * This is intended for string input elements, with "type" such as text, email, url, password, * number, tel. * * Note that every change to the observable will affect the input element, but not every change to * the input element will affect the observable. Specifically, unless `{onInput: true}` is set, the * visible content may differ from the observable until the element loses focus or Enter is hit. * * Example usage: * ``` * input(obs, {}, {type: 'text', placeholder: 'Your name...'}); * input(obs, {isValid: isValidObs}, {type: 'email', placeholder: 'Your email...'}); * input(obs, {onInput: true}, {type: 'text'}); * ``` */ export declare function input(obs: Observable, options: IInputOptions, ...args: IDomArgs): HTMLInputElement;