@ray-js/smart-ui 1.0.2-beta-2 → 1.0.2-beta-3
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/dist/@types/action-sheet/index.d.ts +16 -12
- package/dist/@types/base/component.d.ts +1 -1
- package/dist/@types/base/events.d.ts +4 -4
- package/dist/@types/base/external-class-name.d.ts +2 -2
- package/dist/@types/base/open-type.d.ts +11 -11
- package/dist/@types/battery/index.d.ts +3 -3
- package/dist/@types/button/index.d.ts +7 -7
- package/dist/@types/calendar/index.d.ts +14 -14
- package/dist/@types/cascader/index.d.ts +23 -11
- package/dist/@types/cell/index.d.ts +7 -7
- package/dist/@types/cell-group/index.d.ts +4 -4
- package/dist/@types/checkbox/index.d.ts +9 -9
- package/dist/@types/checkbox-group/index.d.ts +5 -5
- package/dist/@types/circle/index.d.ts +3 -3
- package/dist/@types/col/index.d.ts +4 -4
- package/dist/@types/collapse/index.d.ts +10 -10
- package/dist/@types/collapse-item/index.d.ts +4 -4
- package/dist/@types/config-provider/index.d.ts +3 -3
- package/dist/@types/count-down/index.d.ts +8 -8
- package/dist/@types/custom-keyboard/index.d.ts +8 -8
- package/dist/@types/datetime-picker/index.d.ts +10 -10
- package/dist/@types/dialog/dialog.d.ts +22 -22
- package/dist/@types/dialog/index.d.ts +7 -7
- package/dist/@types/divider/index.d.ts +3 -3
- package/dist/@types/dropdown-item/index.d.ts +13 -13
- package/dist/@types/dropdown-menu/index.d.ts +3 -3
- package/dist/@types/empty/index.d.ts +3 -3
- package/dist/@types/field/index.d.ts +20 -20
- package/dist/@types/grid/index.d.ts +4 -4
- package/dist/@types/grid-item/index.d.ts +8 -8
- package/dist/@types/icon/index.d.ts +7 -7
- package/dist/@types/image/index.d.ts +10 -10
- package/dist/@types/index-anchor/index.d.ts +3 -3
- package/dist/@types/index-bar/index.d.ts +6 -6
- package/dist/@types/loading/index.d.ts +4 -4
- package/dist/@types/nav-bar/index.d.ts +7 -7
- package/dist/@types/notice-bar/index.d.ts +7 -7
- package/dist/@types/notify/notify.d.ts +5 -5
- package/dist/@types/overlay/index.d.ts +6 -6
- package/dist/@types/picker/index.d.ts +14 -14
- package/dist/@types/popup/index.d.ts +8 -8
- package/dist/@types/progress/index.d.ts +4 -4
- package/dist/@types/radio/index.d.ts +7 -7
- package/dist/@types/radio-group/index.d.ts +6 -6
- package/dist/@types/rate/index.d.ts +7 -7
- package/dist/@types/row/index.d.ts +4 -4
- package/dist/@types/search/index.d.ts +9 -9
- package/dist/@types/sidebar/index.d.ts +7 -7
- package/dist/@types/sidebar-item/index.d.ts +8 -8
- package/dist/@types/skeleton/index.d.ts +3 -3
- package/dist/@types/slider/index.d.ts +11 -11
- package/dist/@types/stepper/index.d.ts +15 -15
- package/dist/@types/steps/index.d.ts +9 -9
- package/dist/@types/sticky/index.d.ts +6 -6
- package/dist/@types/swipe-cell/index.d.ts +14 -14
- package/dist/@types/switch/index.d.ts +7 -7
- package/dist/@types/tab/index.d.ts +6 -6
- package/dist/@types/tabbar/index.d.ts +6 -6
- package/dist/@types/tabbar-item/index.d.ts +4 -4
- package/dist/@types/tabs/index.d.ts +13 -13
- package/dist/@types/tag/index.d.ts +6 -6
- package/dist/@types/toast/index.d.ts +2 -2
- package/dist/@types/toast/toast.d.ts +11 -11
- package/dist/@types/transition/index.d.ts +11 -11
- package/dist/@types/tree-select/index.d.ts +12 -12
- package/dist/action-sheet/PropTypes.d.ts +2 -2
- package/dist/action-sheet/index.d.ts +2 -2
- package/dist/base/index.d.ts +2 -2
- package/dist/battery/PropTypes.d.ts +2 -2
- package/dist/battery/index.d.ts +2 -2
- package/dist/button/PropTypes.d.ts +2 -2
- package/dist/button/index.d.ts +2 -2
- package/dist/calendar/PropTypes.d.ts +2 -2
- package/dist/calendar/index.d.ts +2 -2
- package/dist/cascader/PropTypes.d.ts +2 -2
- package/dist/cascader/index.d.ts +2 -2
- package/dist/cell/PropTypes.d.ts +2 -2
- package/dist/cell/index.d.ts +2 -2
- package/dist/cell-group/PropTypes.d.ts +2 -2
- package/dist/cell-group/index.d.ts +2 -2
- package/dist/checkbox/PropTypes.d.ts +2 -2
- package/dist/checkbox/index.d.ts +2 -2
- package/dist/checkbox-group/PropTypes.d.ts +2 -2
- package/dist/checkbox-group/index.d.ts +2 -2
- package/dist/circle/PropTypes.d.ts +2 -2
- package/dist/col/PropTypes.d.ts +2 -2
- package/dist/col/index.d.ts +2 -2
- package/dist/collapse/PropTypes.d.ts +2 -2
- package/dist/collapse/index.d.ts +2 -2
- package/dist/collapse-item/PropTypes.d.ts +2 -2
- package/dist/collapse-item/index.d.ts +2 -2
- package/dist/common/withReactProps.js +12 -12
- package/dist/config-provider/PropTypes.d.ts +2 -2
- package/dist/config-provider/index.d.ts +2 -2
- package/dist/count-down/PropTypes.d.ts +2 -2
- package/dist/count-down/index.d.ts +2 -2
- package/dist/custom-keyboard/PropTypes.d.ts +2 -2
- package/dist/custom-keyboard/index.d.ts +2 -2
- package/dist/datetime-picker/PropTypes.d.ts +2 -2
- package/dist/datetime-picker/index.d.ts +2 -2
- package/dist/dialog/Dialog.d.ts +2 -2
- package/dist/dialog/PropTypes.d.ts +2 -2
- package/dist/dialog/index.d.ts +3 -3
- package/dist/divider/PropTypes.d.ts +2 -2
- package/dist/divider/index.d.ts +2 -2
- package/dist/dropdown-item/PropTypes.d.ts +2 -2
- package/dist/dropdown-item/index.d.ts +2 -2
- package/dist/dropdown-menu/PropTypes.d.ts +2 -2
- package/dist/dropdown-menu/index.d.ts +2 -2
- package/dist/empty/PropTypes.d.ts +2 -2
- package/dist/empty/index.d.ts +2 -2
- package/dist/field/PropTypes.d.ts +2 -2
- package/dist/field/index.d.ts +2 -2
- package/dist/grid/PropTypes.d.ts +2 -2
- package/dist/grid/index.d.ts +2 -2
- package/dist/grid-item/PropTypes.d.ts +2 -2
- package/dist/grid-item/index.d.ts +2 -2
- package/dist/icon/PropTypes.d.ts +2 -2
- package/dist/icon/index.d.ts +2 -2
- package/dist/image/PropTypes.d.ts +2 -2
- package/dist/image/index.d.ts +2 -2
- package/dist/index-anchor/PropTypes.d.ts +2 -2
- package/dist/index-anchor/index.d.ts +2 -2
- package/dist/index-bar/PropTypes.d.ts +2 -2
- package/dist/index-bar/index.d.ts +2 -2
- package/dist/index.d.ts +0 -3
- package/dist/index.js +3 -3
- package/dist/loading/PropTypes.d.ts +2 -2
- package/dist/loading/index.d.ts +2 -2
- package/dist/nav-bar/PropTypes.d.ts +2 -2
- package/dist/nav-bar/index.d.ts +2 -2
- package/dist/notice-bar/PropTypes.d.ts +2 -2
- package/dist/notice-bar/index.d.ts +2 -2
- package/dist/notify/PropTypes.d.ts +2 -2
- package/dist/notify/index.d.ts +2 -2
- package/dist/overlay/PropTypes.d.ts +2 -2
- package/dist/overlay/index.d.ts +2 -2
- package/dist/picker/PropTypes.d.ts +2 -2
- package/dist/picker/index.d.ts +2 -2
- package/dist/popup/PropTypes.d.ts +2 -2
- package/dist/popup/index.d.ts +2 -2
- package/dist/radio/PropTypes.d.ts +2 -2
- package/dist/radio/index.d.ts +2 -2
- package/dist/radio-group/PropTypes.d.ts +2 -2
- package/dist/radio-group/index.d.ts +2 -2
- package/dist/rate/PropTypes.d.ts +2 -2
- package/dist/rate/index.d.ts +2 -2
- package/dist/row/PropTypes.d.ts +2 -2
- package/dist/row/index.d.ts +2 -2
- package/dist/search/PropTypes.d.ts +2 -2
- package/dist/search/index.d.ts +2 -2
- package/dist/sidebar/PropTypes.d.ts +2 -2
- package/dist/sidebar/index.d.ts +2 -2
- package/dist/sidebar-item/PropTypes.d.ts +2 -2
- package/dist/sidebar-item/index.d.ts +2 -2
- package/dist/skeleton/PropTypes.d.ts +2 -2
- package/dist/skeleton/index.d.ts +2 -2
- package/dist/slider/PropTypes.d.ts +2 -2
- package/dist/slider/RangeSlider.d.ts +2 -2
- package/dist/slider/index.d.ts +4 -4
- package/dist/stepper/PropTypes.d.ts +2 -2
- package/dist/stepper/index.d.ts +2 -2
- package/dist/steps/PropTypes.d.ts +2 -2
- package/dist/steps/index.d.ts +2 -2
- package/dist/sticky/PropTypes.d.ts +2 -2
- package/dist/sticky/index.d.ts +2 -2
- package/dist/swipe-cell/PropTypes.d.ts +2 -2
- package/dist/swipe-cell/index.d.ts +2 -2
- package/dist/switch/PropTypes.d.ts +2 -2
- package/dist/switch/index.d.ts +2 -2
- package/dist/tab/PropTypes.d.ts +2 -2
- package/dist/tab/index.d.ts +2 -2
- package/dist/tabbar/PropTypes.d.ts +2 -2
- package/dist/tabbar/index.d.ts +2 -2
- package/dist/tabbar-item/PropTypes.d.ts +2 -2
- package/dist/tabbar-item/index.d.ts +2 -2
- package/dist/tabs/PropTypes.d.ts +2 -2
- package/dist/tabs/index.d.ts +2 -2
- package/dist/tag/PropTypes.d.ts +2 -2
- package/dist/tag/index.d.ts +2 -2
- package/dist/toast/PropTypes.d.ts +2 -2
- package/dist/toast/index.d.ts +2 -2
- package/dist/transition/PropTypes.d.ts +2 -2
- package/dist/transition/index.d.ts +2 -2
- package/dist/tree-select/PropTypes.d.ts +2 -2
- package/dist/tree-select/index.d.ts +2 -2
- package/package.json +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="miniprogram-api-typings" />
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { SmartBaseExternalClassName, SmartComponent, SmartEventHandler } from '../base';
|
|
3
|
+
export interface SmartSliderProps {
|
|
4
4
|
/**
|
|
5
5
|
* 当前进度百分比,在双滑块模式下为数组格式
|
|
6
6
|
*
|
|
@@ -75,29 +75,29 @@ export interface VantSliderProps {
|
|
|
75
75
|
/**
|
|
76
76
|
* @deprecated
|
|
77
77
|
*/
|
|
78
|
-
export interface
|
|
78
|
+
export interface SmartSliderChangeEvent extends WechatMiniprogram.BaseEvent {
|
|
79
79
|
detail: number;
|
|
80
80
|
}
|
|
81
|
-
export interface
|
|
81
|
+
export interface SmartSliderDragEventDetail {
|
|
82
82
|
value: number;
|
|
83
83
|
}
|
|
84
|
-
export interface
|
|
84
|
+
export interface SmartSliderEvents {
|
|
85
85
|
/**
|
|
86
86
|
* 拖动进度条时触发
|
|
87
87
|
*/
|
|
88
|
-
'bind:drag'?:
|
|
88
|
+
'bind:drag'?: SmartEventHandler<SmartSliderDragEventDetail>;
|
|
89
89
|
/**
|
|
90
90
|
* 进度值改变后触发
|
|
91
91
|
*/
|
|
92
|
-
'bind:change'?:
|
|
92
|
+
'bind:change'?: SmartEventHandler<number>;
|
|
93
93
|
/**
|
|
94
94
|
* 开始拖动时触发
|
|
95
95
|
*/
|
|
96
|
-
'bind:drag-start'?:
|
|
96
|
+
'bind:drag-start'?: SmartEventHandler;
|
|
97
97
|
/**
|
|
98
98
|
* 结束拖动时触发
|
|
99
99
|
*/
|
|
100
|
-
'bind:drag-end'?:
|
|
100
|
+
'bind:drag-end'?: SmartEventHandler;
|
|
101
101
|
}
|
|
102
|
-
export type
|
|
103
|
-
export type
|
|
102
|
+
export type SmartSliderExternalClassName = SmartBaseExternalClassName;
|
|
103
|
+
export type SmartSlider = SmartComponent<SmartSliderProps, SmartSliderEvents, SmartSliderExternalClassName>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="miniprogram-api-typings" />
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { SmartBaseExternalClassName, SmartComponent, SmartEventHandler } from '../base';
|
|
3
|
+
export interface SmartStepperProps {
|
|
4
4
|
/**
|
|
5
5
|
* 在表单内提交时的标识符
|
|
6
6
|
*/
|
|
@@ -109,50 +109,50 @@ export interface VantStepperProps {
|
|
|
109
109
|
/**
|
|
110
110
|
* @deprecated
|
|
111
111
|
*/
|
|
112
|
-
export interface
|
|
112
|
+
export interface SmartStepperChangeEvent extends WechatMiniprogram.BaseEvent {
|
|
113
113
|
detail: number;
|
|
114
114
|
}
|
|
115
115
|
/**
|
|
116
116
|
* @deprecated
|
|
117
117
|
*/
|
|
118
|
-
export interface
|
|
118
|
+
export interface SmartStepperOverLimitEvent extends WechatMiniprogram.BaseEvent {
|
|
119
119
|
detail: 'plus' | 'minus';
|
|
120
120
|
}
|
|
121
|
-
export interface
|
|
121
|
+
export interface SmartStepperFocusEventDetail {
|
|
122
122
|
value: string;
|
|
123
123
|
height: number;
|
|
124
124
|
}
|
|
125
|
-
export interface
|
|
125
|
+
export interface SmartStepperBlurEventDetail {
|
|
126
126
|
value: number;
|
|
127
127
|
cursor: number;
|
|
128
128
|
}
|
|
129
|
-
export interface
|
|
129
|
+
export interface SmartStepperEvents {
|
|
130
130
|
/**
|
|
131
131
|
* 当绑定值变化时触发的事件
|
|
132
132
|
*/
|
|
133
|
-
onChange?:
|
|
133
|
+
onChange?: SmartEventHandler<number>;
|
|
134
134
|
/**
|
|
135
135
|
* 点击不可用的按钮时触发
|
|
136
136
|
*/
|
|
137
|
-
onOverlimit?:
|
|
137
|
+
onOverlimit?: SmartEventHandler<'plus' | 'minus'>;
|
|
138
138
|
/**
|
|
139
139
|
* 点击增加按钮时触发
|
|
140
140
|
*/
|
|
141
|
-
onPlus?:
|
|
141
|
+
onPlus?: SmartEventHandler;
|
|
142
142
|
/**
|
|
143
143
|
* 点击减少按钮时触发
|
|
144
144
|
*/
|
|
145
|
-
onMinus?:
|
|
145
|
+
onMinus?: SmartEventHandler;
|
|
146
146
|
/**
|
|
147
147
|
* 输入框聚焦时触发
|
|
148
148
|
*/
|
|
149
|
-
onFocus?:
|
|
149
|
+
onFocus?: SmartEventHandler<SmartStepperFocusEventDetail>;
|
|
150
150
|
/**
|
|
151
151
|
* 输入框失焦时触发
|
|
152
152
|
*/
|
|
153
|
-
onBlur?:
|
|
153
|
+
onBlur?: SmartEventHandler<SmartStepperBlurEventDetail>;
|
|
154
154
|
}
|
|
155
|
-
export interface
|
|
155
|
+
export interface SmartStepperExternalClassName extends SmartBaseExternalClassName {
|
|
156
156
|
/**
|
|
157
157
|
* 输入框样式类
|
|
158
158
|
*/
|
|
@@ -166,4 +166,4 @@ export interface VantStepperExternalClassName extends VantBaseExternalClassName
|
|
|
166
166
|
*/
|
|
167
167
|
minusClass?: string;
|
|
168
168
|
}
|
|
169
|
-
export type
|
|
169
|
+
export type SmartStepper = SmartComponent<SmartStepperProps, SmartStepperEvents, SmartStepperExternalClassName>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/// <reference types="miniprogram-api-typings" />
|
|
2
|
-
import {
|
|
2
|
+
import { SmartBaseExternalClassName, SmartComponent, SmartEventHandler } from '../base';
|
|
3
3
|
/**
|
|
4
4
|
* 步骤配置项
|
|
5
5
|
*/
|
|
6
|
-
export interface
|
|
6
|
+
export interface SmartStepsOption {
|
|
7
7
|
/**
|
|
8
8
|
* 当前步骤名称
|
|
9
9
|
*/
|
|
@@ -21,7 +21,7 @@ export interface VantStepsOption {
|
|
|
21
21
|
*/
|
|
22
22
|
activeIcon?: string;
|
|
23
23
|
}
|
|
24
|
-
export interface
|
|
24
|
+
export interface SmartStepsProps {
|
|
25
25
|
/**
|
|
26
26
|
* 当前步骤
|
|
27
27
|
*
|
|
@@ -31,7 +31,7 @@ export interface VantStepsProps {
|
|
|
31
31
|
/**
|
|
32
32
|
* 当前步骤配置
|
|
33
33
|
*/
|
|
34
|
-
steps?:
|
|
34
|
+
steps?: SmartStepsOption[];
|
|
35
35
|
/**
|
|
36
36
|
* 显示方向
|
|
37
37
|
*/
|
|
@@ -62,22 +62,22 @@ export interface VantStepsProps {
|
|
|
62
62
|
/**
|
|
63
63
|
* @deprecated
|
|
64
64
|
*/
|
|
65
|
-
export interface
|
|
65
|
+
export interface SmartStepsClickStepEvent extends WechatMiniprogram.BaseEvent {
|
|
66
66
|
/**
|
|
67
67
|
* 当前选中步骤索引
|
|
68
68
|
*/
|
|
69
69
|
detail: number;
|
|
70
70
|
}
|
|
71
|
-
export interface
|
|
71
|
+
export interface SmartStepsEvents {
|
|
72
72
|
/**
|
|
73
73
|
* 点击步骤时触发的事件
|
|
74
74
|
*/
|
|
75
|
-
onClickStep?:
|
|
75
|
+
onClickStep?: SmartEventHandler<number>;
|
|
76
76
|
}
|
|
77
|
-
export interface
|
|
77
|
+
export interface SmartStepsExternalClassName extends SmartBaseExternalClassName {
|
|
78
78
|
/**
|
|
79
79
|
* 描述信息样式类
|
|
80
80
|
*/
|
|
81
81
|
descClass?: string;
|
|
82
82
|
}
|
|
83
|
-
export type
|
|
83
|
+
export type SmartSteps = SmartComponent<SmartStepsProps, SmartStepsEvents, SmartStepsExternalClassName>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface
|
|
1
|
+
import { SmartComponent, SmartEventHandler } from '../base';
|
|
2
|
+
export interface SmartStickyProps {
|
|
3
3
|
/**
|
|
4
4
|
* 吸顶时与顶部的距离,单位`px`
|
|
5
5
|
*
|
|
@@ -21,16 +21,16 @@ export interface VantStickyProps {
|
|
|
21
21
|
*/
|
|
22
22
|
scrollTop?: number;
|
|
23
23
|
}
|
|
24
|
-
export interface
|
|
24
|
+
export interface SmartStickyScrollEventDetail {
|
|
25
25
|
/** 距离顶部位置 */
|
|
26
26
|
scrollTop: number;
|
|
27
27
|
/** 是否吸顶 */
|
|
28
28
|
isFixed: boolean;
|
|
29
29
|
}
|
|
30
|
-
export interface
|
|
30
|
+
export interface SmartStickyEvents {
|
|
31
31
|
/**
|
|
32
32
|
* 滚动时触发
|
|
33
33
|
*/
|
|
34
|
-
onScroll?:
|
|
34
|
+
onScroll?: SmartEventHandler<SmartStickyScrollEventDetail>;
|
|
35
35
|
}
|
|
36
|
-
export type
|
|
36
|
+
export type SmartSticky = SmartComponent<SmartStickyProps, SmartStickyEvents>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
/// <reference types="miniprogram-api-typings" />
|
|
3
|
-
import {
|
|
4
|
-
export interface
|
|
3
|
+
import { SmartComponent, SmartEventHandler } from '../base';
|
|
4
|
+
export interface SmartSwipeCellProps {
|
|
5
5
|
/**
|
|
6
6
|
* 标识符,可以在 `close` 事件的参数中获取到
|
|
7
7
|
*/
|
|
@@ -40,36 +40,36 @@ export interface VantSwipeCellProps {
|
|
|
40
40
|
right?: React.ReactNode;
|
|
41
41
|
};
|
|
42
42
|
}
|
|
43
|
-
export type
|
|
44
|
-
export type
|
|
43
|
+
export type SmartSwipeCellPosition = 'left' | 'right';
|
|
44
|
+
export type SmartSwipeCellClickPosition = SmartSwipeCellPosition | 'cell' | 'outside';
|
|
45
45
|
/**
|
|
46
46
|
* @deprecated
|
|
47
47
|
*/
|
|
48
|
-
export interface
|
|
49
|
-
detail:
|
|
48
|
+
export interface SmartSwipeCellClickEvent extends WechatMiniprogram.BaseEvent {
|
|
49
|
+
detail: SmartSwipeCellClickPosition;
|
|
50
50
|
}
|
|
51
|
-
export interface
|
|
51
|
+
export interface SmartSwipeCellBaseEventDetail {
|
|
52
52
|
name: string | number;
|
|
53
|
-
position:
|
|
53
|
+
position: SmartSwipeCellPosition;
|
|
54
54
|
}
|
|
55
|
-
export interface
|
|
55
|
+
export interface SmartSwipeCellCloseEventDetail extends SmartSwipeCellBaseEventDetail {
|
|
56
56
|
/**
|
|
57
57
|
* SwipeCell 实例
|
|
58
58
|
*/
|
|
59
59
|
instance: Record<string, any>;
|
|
60
60
|
}
|
|
61
|
-
export interface
|
|
61
|
+
export interface SmartSwipeCellEvents {
|
|
62
62
|
/**
|
|
63
63
|
* 点击时触发
|
|
64
64
|
*/
|
|
65
|
-
onClick?:
|
|
65
|
+
onClick?: SmartEventHandler<SmartSwipeCellClickPosition>;
|
|
66
66
|
/**
|
|
67
67
|
* 关闭时触发
|
|
68
68
|
*/
|
|
69
|
-
onClose?:
|
|
69
|
+
onClose?: SmartEventHandler<SmartSwipeCellCloseEventDetail>;
|
|
70
70
|
/**
|
|
71
71
|
* 打开时触发
|
|
72
72
|
*/
|
|
73
|
-
onOpen?:
|
|
73
|
+
onOpen?: SmartEventHandler<SmartSwipeCellBaseEventDetail>;
|
|
74
74
|
}
|
|
75
|
-
export type
|
|
75
|
+
export type SmartSwipeCell = SmartComponent<SmartSwipeCellProps, SmartSwipeCellEvents>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="miniprogram-api-typings" />
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { SmartBaseExternalClassName, SmartComponent, SmartEventHandler } from '../base';
|
|
3
|
+
export interface SmartSwitchProps {
|
|
4
4
|
/**
|
|
5
5
|
* 在表单内提交时的标识符
|
|
6
6
|
*/
|
|
@@ -57,19 +57,19 @@ export interface VantSwitchProps {
|
|
|
57
57
|
/**
|
|
58
58
|
* @deprecated
|
|
59
59
|
*/
|
|
60
|
-
export interface
|
|
60
|
+
export interface SmartSwitchChangeEvent extends WechatMiniprogram.BaseEvent {
|
|
61
61
|
detail: boolean;
|
|
62
62
|
}
|
|
63
|
-
export interface
|
|
63
|
+
export interface SmartSwitchEvents {
|
|
64
64
|
/**
|
|
65
65
|
* 开关状态切换回调
|
|
66
66
|
*/
|
|
67
|
-
onChange?:
|
|
67
|
+
onChange?: SmartEventHandler<boolean>;
|
|
68
68
|
}
|
|
69
|
-
export interface
|
|
69
|
+
export interface SmartSwitchExternalClassName extends SmartBaseExternalClassName {
|
|
70
70
|
/**
|
|
71
71
|
* 圆点样式类
|
|
72
72
|
*/
|
|
73
73
|
nodeClass?: string;
|
|
74
74
|
}
|
|
75
|
-
export type
|
|
75
|
+
export type SmartSwitch = SmartComponent<SmartSwitchProps, SmartSwitchEvents, SmartSwitchExternalClassName>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { SmartBaseExternalClassName, SmartComponent } from '../base';
|
|
3
|
+
export interface SmartTabProps {
|
|
4
4
|
/**
|
|
5
5
|
* 标签名称,作为匹配的标识符
|
|
6
6
|
*
|
|
@@ -30,12 +30,12 @@ export interface VantTabProps {
|
|
|
30
30
|
*/
|
|
31
31
|
titleStyle?: string;
|
|
32
32
|
}
|
|
33
|
-
export type
|
|
34
|
-
export type
|
|
35
|
-
export interface
|
|
33
|
+
export type SmartTabEvents = {};
|
|
34
|
+
export type SmartTabExternalClassName = SmartBaseExternalClassName;
|
|
35
|
+
export interface SmartTabSlot {
|
|
36
36
|
/**
|
|
37
37
|
* 自定义标签页内容
|
|
38
38
|
*/
|
|
39
39
|
children?: React.ReactNode;
|
|
40
40
|
}
|
|
41
|
-
export type
|
|
41
|
+
export type SmartTab = SmartComponent<SmartTabProps, SmartTabEvents, SmartTabExternalClassName, SmartTabSlot>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="miniprogram-api-typings" />
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { SmartComponent, SmartEventHandler } from '../base';
|
|
3
|
+
export interface SmartTabbarProps {
|
|
4
4
|
/**
|
|
5
5
|
* 当前选中标签的索引
|
|
6
6
|
*/
|
|
@@ -53,16 +53,16 @@ export interface VantTabbarProps {
|
|
|
53
53
|
*
|
|
54
54
|
* @deprecated
|
|
55
55
|
*/
|
|
56
|
-
export interface
|
|
56
|
+
export interface SmartTabbarChangeEvent extends WechatMiniprogram.BaseEvent {
|
|
57
57
|
/**
|
|
58
58
|
* 当前选中标签的名称或索引值
|
|
59
59
|
*/
|
|
60
60
|
detail: number | string;
|
|
61
61
|
}
|
|
62
|
-
export interface
|
|
62
|
+
export interface SmartTabbarEvents {
|
|
63
63
|
/**
|
|
64
64
|
* 切换标签时触发
|
|
65
65
|
*/
|
|
66
|
-
onChange?:
|
|
66
|
+
onChange?: SmartEventHandler<number | string>;
|
|
67
67
|
}
|
|
68
|
-
export type
|
|
68
|
+
export type SmartTabbar = SmartComponent<SmartTabbarProps, SmartTabbarEvents>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface
|
|
1
|
+
import { SmartComponent } from '../base';
|
|
2
|
+
export interface SmartTabbarItemProps {
|
|
3
3
|
/**
|
|
4
4
|
* 标签名称,作为匹配的标识符
|
|
5
5
|
*
|
|
@@ -13,7 +13,7 @@ export interface VantTabbarItemProps {
|
|
|
13
13
|
/**
|
|
14
14
|
* 图标类名前缀,同 `Icon` 组件的 `class-prefix` 属性
|
|
15
15
|
*
|
|
16
|
-
* @default '
|
|
16
|
+
* @default 'smart-icon'
|
|
17
17
|
*/
|
|
18
18
|
'icon-prefix'?: string;
|
|
19
19
|
/**
|
|
@@ -25,4 +25,4 @@ export interface VantTabbarItemProps {
|
|
|
25
25
|
*/
|
|
26
26
|
info?: string | number;
|
|
27
27
|
}
|
|
28
|
-
export type
|
|
28
|
+
export type SmartTabbarItem = SmartComponent<SmartTabbarItemProps>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { SmartBaseExternalClassName, SmartComponent, SmartEventHandler } from '../base';
|
|
3
|
+
export interface SmartTabsProps {
|
|
4
4
|
/**
|
|
5
5
|
* 样式风格
|
|
6
6
|
*/
|
|
@@ -99,7 +99,7 @@ export interface VantTabsProps {
|
|
|
99
99
|
/**
|
|
100
100
|
* @deprecated
|
|
101
101
|
*/
|
|
102
|
-
export interface
|
|
102
|
+
export interface SmartTabsEventDetail {
|
|
103
103
|
/**
|
|
104
104
|
* 标签标识符
|
|
105
105
|
*/
|
|
@@ -113,8 +113,8 @@ export interface VantTabsEventDetail {
|
|
|
113
113
|
*/
|
|
114
114
|
index: number;
|
|
115
115
|
}
|
|
116
|
-
export type
|
|
117
|
-
export interface
|
|
116
|
+
export type SmartTabsBaseEventDetail = SmartTabsEventDetail;
|
|
117
|
+
export interface SmartTabsScrollEventDetail {
|
|
118
118
|
/**
|
|
119
119
|
* 距离顶部位置
|
|
120
120
|
*/
|
|
@@ -124,25 +124,25 @@ export interface VantTabsScrollEventDetail {
|
|
|
124
124
|
*/
|
|
125
125
|
isFixed: boolean;
|
|
126
126
|
}
|
|
127
|
-
export interface
|
|
127
|
+
export interface SmartTabsEvents {
|
|
128
128
|
/**
|
|
129
129
|
* 点击标签时触发
|
|
130
130
|
*/
|
|
131
|
-
onClick?:
|
|
131
|
+
onClick?: SmartEventHandler<SmartTabsBaseEventDetail>;
|
|
132
132
|
/**
|
|
133
133
|
* 当前激活的标签改变时触发
|
|
134
134
|
*/
|
|
135
|
-
onChange?:
|
|
135
|
+
onChange?: SmartEventHandler<SmartTabsBaseEventDetail>;
|
|
136
136
|
/**
|
|
137
137
|
* 点击被禁用的标签时触发
|
|
138
138
|
*/
|
|
139
|
-
onDisabled?:
|
|
139
|
+
onDisabled?: SmartEventHandler<SmartTabsBaseEventDetail>;
|
|
140
140
|
/**
|
|
141
141
|
* 滚动时触发
|
|
142
142
|
*/
|
|
143
|
-
onScroll?:
|
|
143
|
+
onScroll?: SmartEventHandler<SmartTabsScrollEventDetail>;
|
|
144
144
|
}
|
|
145
|
-
export interface
|
|
145
|
+
export interface SmartTabsExternalClassName extends SmartBaseExternalClassName {
|
|
146
146
|
/**
|
|
147
147
|
* 标签栏样式类
|
|
148
148
|
*/
|
|
@@ -156,7 +156,7 @@ export interface VantTabsExternalClassName extends VantBaseExternalClassName {
|
|
|
156
156
|
*/
|
|
157
157
|
tabActiveClass?: string;
|
|
158
158
|
}
|
|
159
|
-
export interface
|
|
159
|
+
export interface SmartTabsSlot {
|
|
160
160
|
/**
|
|
161
161
|
* Tabs Slot
|
|
162
162
|
*/
|
|
@@ -171,4 +171,4 @@ export interface VantTabsSlot {
|
|
|
171
171
|
navRight?: React.ReactNode;
|
|
172
172
|
};
|
|
173
173
|
}
|
|
174
|
-
export type
|
|
174
|
+
export type SmartTabs = SmartComponent<SmartTabsProps, SmartTabsEvents, SmartTabsExternalClassName, SmartTabsSlot>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface
|
|
1
|
+
import { SmartBaseExternalClassName, SmartComponent, SmartEventHandler } from '../base';
|
|
2
|
+
export interface SmartTagProps {
|
|
3
3
|
/**
|
|
4
4
|
* 类型
|
|
5
5
|
*/
|
|
@@ -43,8 +43,8 @@ export interface VantTagProps {
|
|
|
43
43
|
*/
|
|
44
44
|
closeable?: boolean;
|
|
45
45
|
}
|
|
46
|
-
export interface
|
|
47
|
-
onClose?:
|
|
46
|
+
export interface SmartTagEvents {
|
|
47
|
+
onClose?: SmartEventHandler;
|
|
48
48
|
}
|
|
49
|
-
export type
|
|
50
|
-
export type
|
|
49
|
+
export type SmartTagExternalClassName = SmartBaseExternalClassName;
|
|
50
|
+
export type SmartTag = SmartComponent<SmartTagProps, SmartTagEvents, SmartTagExternalClassName>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export type
|
|
1
|
+
import { SmartComponent } from '../base';
|
|
2
|
+
export type SmartToast = SmartComponent;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export interface
|
|
1
|
+
export interface SmartToastOptions {
|
|
2
2
|
id?: string;
|
|
3
3
|
/**
|
|
4
4
|
* 提示类型
|
|
@@ -51,7 +51,7 @@ export interface VantToastOptions {
|
|
|
51
51
|
/**
|
|
52
52
|
* 自定义选择器
|
|
53
53
|
*
|
|
54
|
-
* @default '
|
|
54
|
+
* @default 'smart-toast'
|
|
55
55
|
*/
|
|
56
56
|
selector?: string;
|
|
57
57
|
/**
|
|
@@ -65,30 +65,30 @@ export interface VantToastOptions {
|
|
|
65
65
|
*/
|
|
66
66
|
onClose?: Function;
|
|
67
67
|
}
|
|
68
|
-
export declare interface ToastInstance extends
|
|
69
|
-
setData(options:
|
|
68
|
+
export declare interface ToastInstance extends SmartToast {
|
|
69
|
+
setData(options: SmartToastOptions): void;
|
|
70
70
|
}
|
|
71
|
-
export declare interface
|
|
71
|
+
export declare interface SmartToast {
|
|
72
72
|
/**
|
|
73
73
|
* 展示提示
|
|
74
74
|
*/
|
|
75
75
|
(options: string): ToastInstance;
|
|
76
|
-
(options:
|
|
76
|
+
(options: SmartToastOptions): ToastInstance;
|
|
77
77
|
/**
|
|
78
78
|
* 展示加载提示
|
|
79
79
|
*/
|
|
80
80
|
loading(options: string): ToastInstance;
|
|
81
|
-
loading(options:
|
|
81
|
+
loading(options: SmartToastOptions): ToastInstance;
|
|
82
82
|
/**
|
|
83
83
|
* 展示成功提示
|
|
84
84
|
*/
|
|
85
85
|
success(options: string): ToastInstance;
|
|
86
|
-
success(options:
|
|
86
|
+
success(options: SmartToastOptions): ToastInstance;
|
|
87
87
|
/**
|
|
88
88
|
* 展示失败提示
|
|
89
89
|
*/
|
|
90
90
|
fail(options: string): ToastInstance;
|
|
91
|
-
fail(options:
|
|
91
|
+
fail(options: SmartToastOptions): ToastInstance;
|
|
92
92
|
/**
|
|
93
93
|
* 关闭提示
|
|
94
94
|
*/
|
|
@@ -96,13 +96,13 @@ export declare interface VantToast {
|
|
|
96
96
|
/**
|
|
97
97
|
* 修改默认配置,对所有 Toast 生效
|
|
98
98
|
*/
|
|
99
|
-
setDefaultOptions(options:
|
|
99
|
+
setDefaultOptions(options: SmartToastOptions): void;
|
|
100
100
|
/**
|
|
101
101
|
* 重置默认配置,对所有 Toast 生效
|
|
102
102
|
*/
|
|
103
103
|
resetDefaultOptions(): void;
|
|
104
104
|
}
|
|
105
|
-
type Toast =
|
|
105
|
+
type Toast = SmartToast;
|
|
106
106
|
/**
|
|
107
107
|
* @deprecated
|
|
108
108
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface
|
|
1
|
+
import { SmartBaseExternalClassName, SmartComponent, SmartEventHandler } from '../base';
|
|
2
|
+
export interface SmartTransitionProps {
|
|
3
3
|
/**
|
|
4
4
|
* 动画类型
|
|
5
5
|
*
|
|
@@ -46,33 +46,33 @@ export interface VantTransitionProps {
|
|
|
46
46
|
*/
|
|
47
47
|
customStyle?: string;
|
|
48
48
|
}
|
|
49
|
-
export interface
|
|
49
|
+
export interface SmartTransitionEvents {
|
|
50
50
|
/**
|
|
51
51
|
* 进入前触发
|
|
52
52
|
*/
|
|
53
|
-
onBeforeEnter?:
|
|
53
|
+
onBeforeEnter?: SmartEventHandler;
|
|
54
54
|
/**
|
|
55
55
|
* 进入中触发
|
|
56
56
|
*/
|
|
57
|
-
onEnter?:
|
|
57
|
+
onEnter?: SmartEventHandler;
|
|
58
58
|
/**
|
|
59
59
|
* 进入后触发
|
|
60
60
|
*/
|
|
61
|
-
onAfterEnter?:
|
|
61
|
+
onAfterEnter?: SmartEventHandler;
|
|
62
62
|
/**
|
|
63
63
|
* 离开前触发
|
|
64
64
|
*/
|
|
65
|
-
onBeforeLeave?:
|
|
65
|
+
onBeforeLeave?: SmartEventHandler;
|
|
66
66
|
/**
|
|
67
67
|
* 离开中触发
|
|
68
68
|
*/
|
|
69
|
-
onLeave?:
|
|
69
|
+
onLeave?: SmartEventHandler;
|
|
70
70
|
/**
|
|
71
71
|
* 离开后触发
|
|
72
72
|
*/
|
|
73
|
-
onAfterLeave?:
|
|
73
|
+
onAfterLeave?: SmartEventHandler;
|
|
74
74
|
}
|
|
75
|
-
export interface
|
|
75
|
+
export interface SmartTransitionExternalClassName extends SmartBaseExternalClassName {
|
|
76
76
|
/**
|
|
77
77
|
* 定义进入过渡的开始状态。在元素被插入之前生效,在元素被插入之后的下一帧移除。
|
|
78
78
|
*/
|
|
@@ -102,4 +102,4 @@ export interface VantTransitionExternalClassName extends VantBaseExternalClassNa
|
|
|
102
102
|
*/
|
|
103
103
|
leaveToClass?: string;
|
|
104
104
|
}
|
|
105
|
-
export type
|
|
105
|
+
export type SmartTransition = SmartComponent<SmartTransitionProps, SmartTransitionEvents, SmartTransitionExternalClassName>;
|