@para-ui/core 2.1.8 → 2.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AutoBox/index.js +2 -2
- package/AutoTips/index.js +1 -1
- package/Breadcrumbs/index.js +1 -1
- package/Button/index.js +1 -1
- package/ButtonGroup/index.js +1 -1
- package/Checkbox/index.js +1 -1
- package/CheckboxGroup/index.js +1 -1
- package/Collapse/collapsePanel.d.ts +30 -0
- package/Collapse/index.d.ts +56 -0
- package/Collapse/index.js +28 -0
- package/Collapse/motion.d.ts +5 -0
- package/Collapse/util.d.ts +11 -0
- package/ComboSelect/index.js +2 -2
- package/ComboSelect/interface.d.ts +2 -0
- package/Container/index.js +2 -2
- package/DatePicker/index.js +1 -1
- package/Form/index.js +31 -31
- package/FormItem/index.js +31 -31
- package/FormItem/itemType.d.ts +16 -16
- package/FunctionModal/index.js +1 -1
- package/Help/index.js +1 -1
- package/IconList/index.js +2 -2
- package/InputLang/index.js +2 -2
- package/InputNumber/index.d.ts +52 -13
- package/InputNumber/index.js +11 -50
- package/Menu/index.js +2 -2
- package/Message/index.js +2 -2
- package/Modal/index.js +1 -1
- package/MultiBox/index.js +2 -2
- package/Notification/index.js +1 -1
- package/PageHeader/index.js +11 -11
- package/PageHeader/interface.d.ts +3 -3
- package/Pagination/index.js +2 -2
- package/PopConfirm/index.js +1 -1
- package/README.md +37 -4
- package/Radio/index.js +1 -1
- package/RadioGroup/index.js +1 -1
- package/Search/index.js +2 -2
- package/Select/index.d.ts +6 -2
- package/Select/index.js +2 -2
- package/SelectInput/index.d.ts +11 -0
- package/SelectInput/index.js +79 -0
- package/SingleBox/index.js +2 -2
- package/Slider/index.d.ts +4 -4
- package/Slider/index.js +1 -1
- package/Stepper/index.js +1 -1
- package/Switch/index.js +5 -5
- package/Table/index.js +2 -2
- package/Tabs/index.js +1 -1
- package/Tag/TagGroup.d.ts +10 -1
- package/Tag/index.js +2 -2
- package/TextField/index.d.ts +2 -0
- package/TextField/index.js +2 -2
- package/TimePicker/index.js +1 -1
- package/ToggleButton/index.js +1 -1
- package/Tooltip/index.js +1 -1
- package/Transfer/index.js +10 -10
- package/Tree/index.js +1 -1
- package/Upload/index.js +2 -2
- package/Upload/interface.d.ts +2 -0
- package/cdn/AutoBox/index.js +1 -1
- package/cdn/AutoTips/index.js +1 -1
- package/cdn/Breadcrumbs/index.js +1 -1
- package/cdn/Button/index.js +1 -1
- package/cdn/ButtonGroup/index.js +1 -1
- package/cdn/Checkbox/index.js +1 -1
- package/cdn/CheckboxGroup/index.js +1 -1
- package/cdn/Collapse/index.js +27 -0
- package/cdn/ComboSelect/index.js +2 -2
- package/cdn/Container/index.js +1 -1
- package/cdn/DatePicker/index.js +1 -1
- package/cdn/Form/index.js +41 -33
- package/cdn/FormItem/index.js +41 -33
- package/cdn/FunctionModal/index.js +1 -1
- package/cdn/Help/index.js +1 -1
- package/cdn/IconList/index.js +1 -1
- package/cdn/InputLang/index.js +4 -4
- package/cdn/InputNumber/index.js +15 -80
- package/cdn/Menu/index.js +3 -3
- package/cdn/Message/index.js +1 -1
- package/cdn/Modal/index.js +1 -1
- package/cdn/MultiBox/index.js +4 -4
- package/cdn/Notification/index.js +1 -1
- package/cdn/PageHeader/index.js +2 -2
- package/cdn/Pagination/index.js +4 -4
- package/cdn/PopConfirm/index.js +1 -1
- package/cdn/Radio/index.js +1 -1
- package/cdn/RadioGroup/index.js +1 -1
- package/cdn/Search/index.js +2 -2
- package/cdn/Select/index.js +4 -4
- package/cdn/SelectInput/index.js +105 -0
- package/cdn/SingleBox/index.js +4 -4
- package/cdn/Slider/index.js +1 -1
- package/cdn/Stepper/index.js +1 -1
- package/cdn/Switch/index.js +4 -4
- package/cdn/Table/index.js +2 -2
- package/cdn/Tabs/index.js +1 -1
- package/cdn/Tag/index.js +2 -2
- package/cdn/TextField/index.js +4 -4
- package/cdn/TimePicker/index.js +1 -1
- package/cdn/ToggleButton/index.js +1 -1
- package/cdn/Tooltip/index.js +1 -1
- package/cdn/Transfer/index.js +4 -4
- package/cdn/Tree/index.js +1 -1
- package/cdn/Upload/index.js +2 -2
- package/index.d.ts +4 -0
- package/index.js +107 -107
- package/package.json +3 -2
- package/style.css +34 -32
package/InputNumber/index.d.ts
CHANGED
|
@@ -3,30 +3,69 @@
|
|
|
3
3
|
* @date 2021/8/11 13:53
|
|
4
4
|
* @description 数字输入框
|
|
5
5
|
*/
|
|
6
|
-
import { FunctionComponent } from 'react';
|
|
7
|
-
import { TextFieldProps } from "../TextField";
|
|
6
|
+
import React, { FunctionComponent, ReactNode } from 'react';
|
|
8
7
|
import './index.scss';
|
|
9
|
-
|
|
8
|
+
interface InputNumberRcProps {
|
|
9
|
+
/** 样式class */
|
|
10
|
+
className?: string;
|
|
11
|
+
/** style */
|
|
12
|
+
style?: React.CSSProperties;
|
|
13
|
+
/** 大小 */
|
|
14
|
+
size?: 'small' | 'medium' | 'large';
|
|
10
15
|
/** 间隔 */
|
|
11
16
|
step?: number;
|
|
12
17
|
/** 最大值 */
|
|
13
18
|
max?: number;
|
|
14
19
|
/** 最小值 */
|
|
15
20
|
min?: number;
|
|
21
|
+
/** 标题 */
|
|
22
|
+
label?: ReactNode;
|
|
23
|
+
/** 标题在外,还是在内 */
|
|
24
|
+
labelMode?: 'outside' | 'inside';
|
|
25
|
+
/** 标题提示 */
|
|
26
|
+
labelSign?: ReactNode;
|
|
27
|
+
/** 提示语 */
|
|
28
|
+
placeholder?: ReactNode;
|
|
16
29
|
/** 按钮模式 左右/上下/无 */
|
|
17
30
|
btnMode?: 'lr' | 'tb' | 'none';
|
|
18
|
-
/**
|
|
19
|
-
|
|
20
|
-
/** 输入框值 受控 */
|
|
21
|
-
value?: number | null;
|
|
22
|
-
/** 禁止输入字符 */
|
|
23
|
-
disabledStr?: (string | number)[];
|
|
31
|
+
/** 是否禁用 */
|
|
32
|
+
disabled?: boolean;
|
|
24
33
|
/** 禁用加 */
|
|
25
34
|
disabledAdd?: boolean;
|
|
26
35
|
/** 禁用减 */
|
|
27
36
|
disabledReduce?: boolean;
|
|
28
|
-
/**
|
|
29
|
-
|
|
37
|
+
/** 是否必填 */
|
|
38
|
+
required?: boolean;
|
|
39
|
+
/** 是否显示错误 */
|
|
40
|
+
error?: boolean;
|
|
41
|
+
/** 错误提示 */
|
|
42
|
+
helperText?: ReactNode;
|
|
43
|
+
/** 是否启用键盘快捷行为 */
|
|
44
|
+
keyboard?: boolean;
|
|
45
|
+
/** 是否自动获取焦点 */
|
|
46
|
+
autoFocus?: boolean;
|
|
47
|
+
/** 只读 */
|
|
48
|
+
readOnly?: boolean;
|
|
49
|
+
/** 指定输入框展示值的格式 */
|
|
50
|
+
formatter?: (value: number | string, info: {
|
|
51
|
+
userTyping: boolean;
|
|
52
|
+
input: string;
|
|
53
|
+
}) => string;
|
|
54
|
+
/** 指定从 formatter 里转换回数字的方式,和 formatter 搭配使用 */
|
|
55
|
+
parser?: (displayValue: string) => number;
|
|
56
|
+
/** 默认值 不受控 */
|
|
57
|
+
defaultValue?: number;
|
|
58
|
+
/** 默认值 受控 */
|
|
59
|
+
value?: number;
|
|
60
|
+
/** 改变事件 */
|
|
61
|
+
onChange?: (value: number | null) => void;
|
|
62
|
+
/** 回车事件 */
|
|
63
|
+
onEnter?: (event: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
64
|
+
/** 失去焦点 */
|
|
65
|
+
onBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;
|
|
66
|
+
/** 得到焦点 */
|
|
67
|
+
onFocus?: (event: React.FocusEvent<HTMLInputElement>) => void;
|
|
68
|
+
[name: string]: any;
|
|
30
69
|
}
|
|
31
|
-
export declare const
|
|
32
|
-
export default
|
|
70
|
+
export declare const InputNumberRc: FunctionComponent<InputNumberRcProps>;
|
|
71
|
+
export default InputNumberRc;
|