UNPKG

tdesign-vue

Version:
155 lines (154 loc) 5.53 kB
import Vue, { CreateElement } from 'vue'; import { InputValue } from './type'; import { InputConfig } from '../config-provider/config-receiver'; import { ClassName } from '../common'; import FormItem from '../form/form-item'; export interface InputParentInjectInstance extends Vue { composing: boolean; tFormItem: InstanceType<typeof FormItem>; } declare const _default: import("vue/types/vue").ExtendedVue<{ useGlobalIcon(tdIcon: Record<string, any>): import("tdesign-icons-vue").GlobalIconConfig; } & Record<never, any> & import("../config-provider/config-receiver").ConfigComponent & Vue & { t<T>(pattern: T, placement?: number | import("../config-provider/config-receiver").Placement): string; } & { global: InputConfig; classPrefix: string; componentName: string; commonSizeClassName: Record<string, string>; commonStatusClassName: Record<string, string>; } & InputParentInjectInstance, { formDisabled: any; isHover: boolean; focused: boolean; renderType: "number" | "search" | "password" | "url" | "hidden" | "text" | "submit" | "tel"; inputValue: any; composingRef: boolean; composingRefValue: any; preValue: any; timer: any; observerTimer: any; containerObserver: ResizeObserver; }, { getOutputValue(val: InputValue): InputValue; addListeners(): void; addResizeObserver(): void; renderIcon(h: CreateElement, icon: string | Function | undefined, iconType: 'prefix-icon' | 'suffix-icon' | 'password-icon'): any; setInputValue(v?: InputValue): void; focus(): void; blur(): void; handleKeydown(e: KeyboardEvent): void; handleKeyUp(e: KeyboardEvent): void; handleKeypress(e: KeyboardEvent): void; handlePaste(e: ClipboardEvent): void; onHandleMousewheel(e: WheelEvent): void; emitPassword(): void; emitClear(e: MouseEvent): void; emitFocus(e: FocusEvent): void; formatAndEmitBlur(e: FocusEvent): void; compositionstartHandler(e: CompositionEvent): void; compositionendHandler(e: CompositionEvent): void; onRootClick(e: MouseEvent): void; throttleChangeCursorPos(ref: HTMLInputElement, pos: number): void; handleInput(e: InputEvent | CompositionEvent): void; onInputMouseenter(e: MouseEvent): void; onInputMouseleave(e: MouseEvent): void; updateInputWidth(): void; getValueByLimitNumber(inputValue: string): string; onValidateChange(): void; useResizeObserver(el: HTMLElement, callback: (data: ResizeObserverEntry[]) => void): ResizeObserver; cleanupObserver(observer: ResizeObserver, container: Element): void; }, { tDisabled: boolean; tPlaceholder: string; showClear: boolean; inputAttrs: Record<string, any>; inputClasses: ClassName; inputWrapClass: ClassName; limitNumber: string; innerStatus: string; tStatus: string; isIE: boolean; }, { showInput: boolean; keepWrapperWidth: boolean; align: "center" | "left" | "right"; allowInputOverMax: boolean; autoWidth: boolean; autocomplete: any; autofocus: boolean; borderless: boolean; clearable: boolean; disabled: any; format: import("./type").InputFormatType; inputClass: ClassName; label: string | ((h: CreateElement) => import("vue/types/vnode").ScopedSlotReturnValue); maxcharacter: number; maxlength: string | number; name: string; placeholder: any; prefixIcon: (h: CreateElement) => import("vue/types/vnode").ScopedSlotReturnValue; readonly: any; showClearIconOnEmpty: boolean; showLimitNumber: boolean; size: import("../common").SizeEnum; spellCheck: boolean; status: "error" | "default" | "success" | "warning"; suffix: string | ((h: CreateElement) => import("vue/types/vnode").ScopedSlotReturnValue); suffixIcon: (h: CreateElement) => import("vue/types/vnode").ScopedSlotReturnValue; tips: string | ((h: CreateElement) => import("vue/types/vnode").ScopedSlotReturnValue); type: "number" | "search" | "password" | "url" | "hidden" | "text" | "submit" | "tel"; value: any; defaultValue: InputValue; onBlur: (value: InputValue, context: { e: FocusEvent; }) => void; onChange: (value: InputValue, context?: { e?: MouseEvent | CompositionEvent | InputEvent; trigger: "input" | "clear" | "initial"; }) => void; onClear: (context: { e: MouseEvent; }) => void; onClick: (context: { e: MouseEvent; }) => void; onCompositionend: (value: string, context: { e: CompositionEvent; }) => void; onCompositionstart: (value: string, context: { e: CompositionEvent; }) => void; onEnter: (value: InputValue, context: { e: KeyboardEvent; }) => void; onFocus: (value: InputValue, context: { e: FocusEvent; }) => void; onKeydown: (value: InputValue, context: { e: KeyboardEvent; }) => void; onKeypress: (value: InputValue, context: { e: KeyboardEvent; }) => void; onKeyup: (value: InputValue, context: { e: KeyboardEvent; }) => void; onMouseenter: (context: { e: MouseEvent; }) => void; onMouseleave: (context: { e: MouseEvent; }) => void; onPaste: (context: { e: ClipboardEvent; pasteValue: string; }) => void; onValidate: (context: { error?: "exceed-maximum" | "below-minimum"; }) => void; onWheel: (context: { e: WheelEvent; }) => void; }>; export default _default;