props.d.ts 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. import { IBaseProps } from '../../_util/base';
  2. export type InputType = 'text' | 'number' | 'idcard' | 'digit' | 'numberpad' | 'digitpad' | 'idcardpad';
  3. /**
  4. * @description 输入框。
  5. */
  6. export interface InputBlurProps extends IBaseProps {
  7. value: string;
  8. defaultValue: string;
  9. placeholder: string;
  10. placeholderClassName: string;
  11. placeholderStyle: string;
  12. enableNative: boolean;
  13. confirmType: string;
  14. confirmHold: string;
  15. alwaysSystem: boolean;
  16. selectionStart: number;
  17. selectionEnd: number;
  18. cursor: number;
  19. controlled: boolean;
  20. maxLength?: number;
  21. inputClassName: string;
  22. inputStyle: string;
  23. focus?: boolean;
  24. password: boolean;
  25. disabled?: boolean;
  26. /**
  27. * @description 组件名字,用于表单提交获取数据。
  28. */
  29. name?: string;
  30. type?: InputType;
  31. /**
  32. * @description 当 type 为 number, digit, idcard 数字键盘是否随机排列。
  33. * @default false
  34. */
  35. randomNumber?: boolean;
  36. onChange?: (value: string, e: any) => void;
  37. onBlur?: (value: string, e: any) => void;
  38. onFocus?: (value: string, e: any) => void;
  39. onConfirm?: (value: string, e: any) => void;
  40. }
  41. export declare const InputBlurDefaultProps: Partial<InputBlurProps>;