UNPKG

@nativescript/core

Version:

A JavaScript library providing an easy to use api for interacting with iOS and Android platform APIs.

57 lines (56 loc) 2.95 kB
import { TextFieldBase, secureProperty } from './text-field-common'; import { textOverflowProperty, whiteSpaceProperty } from '../text-base'; import { hintProperty, placeholderColorProperty } from '../editable-text-base'; import { CoreTypes } from '../../core-types'; import { Color } from '../../color'; import { colorProperty, paddingTopProperty, paddingRightProperty, paddingBottomProperty, paddingLeftProperty, directionProperty } from '../styling/style-properties'; export * from './text-field-common'; declare class UITextFieldImpl extends UITextField { private _owner; static initWithOwner(owner: WeakRef<TextField>): UITextFieldImpl; private _getTextRectForBounds; textRectForBounds(bounds: CGRect): CGRect; editingRectForBounds(bounds: CGRect): CGRect; } export declare class TextField extends TextFieldBase { [hintProperty.getDefault]: () => string; [hintProperty.setNative]: (value: string) => void; [secureProperty.getDefault]: () => boolean; [secureProperty.setNative]: (value: boolean) => void; [colorProperty.getDefault]: () => { textColor: UIColor; tintColor: UIColor; }; [colorProperty.setNative]: (value: Color | { textColor: UIColor; tintColor: UIColor; }) => void; [placeholderColorProperty.getDefault]: () => UIColor; [placeholderColorProperty.setNative]: (value: UIColor | Color) => void; [paddingTopProperty.getDefault]: () => CoreTypes.LengthType; [paddingTopProperty.setNative]: (value: CoreTypes.LengthType) => void; [paddingRightProperty.getDefault]: () => CoreTypes.LengthType; [paddingRightProperty.setNative]: (value: CoreTypes.LengthType) => void; [paddingBottomProperty.getDefault]: () => CoreTypes.LengthType; [paddingBottomProperty.setNative]: (value: CoreTypes.LengthType) => void; [paddingLeftProperty.getDefault]: () => CoreTypes.LengthType; [paddingLeftProperty.setNative]: (value: CoreTypes.LengthType) => void; [whiteSpaceProperty.setNative]: (value: CoreTypes.WhiteSpaceType) => void; [textOverflowProperty.setNative]: (value: CoreTypes.TextOverflowType) => void; [directionProperty.setNative]: (value: CoreTypes.LayoutDirectionType) => void; nativeViewProtected: UITextField; private _delegate; private _firstEdit; createNativeView(): UITextFieldImpl; initNativeView(): void; disposeNativeView(): void; get ios(): UITextField; textFieldShouldBeginEditing(textField: UITextField): boolean; textFieldDidBeginEditing(textField: UITextField): void; textFieldDidEndEditing(textField: UITextField): void; textFieldShouldClear(textField: UITextField): boolean; textFieldShouldReturn(textField: UITextField): boolean; textFieldShouldChangeCharactersInRangeReplacementString(textField: UITextField, range: NSRange, replacementString: string): boolean; _updateAttributedPlaceholder(): void; private adjustLineBreak; }