hy-app 0.5.3 → 0.5.5
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/components/hy-action-sheet/typing.d.ts +1 -63
- package/components/hy-address-picker/hy-address-picker.vue +7 -6
- package/components/hy-address-picker/typing.d.ts +0 -84
- package/components/hy-avatar/hy-avatar.vue +4 -3
- package/components/hy-avatar/typing.d.ts +0 -66
- package/components/hy-back-top/typing.d.ts +0 -47
- package/components/hy-badge/hy-badge.vue +3 -3
- package/components/hy-badge/index.scss +0 -1
- package/components/hy-badge/props.ts +6 -1
- package/components/hy-badge/typing.d.ts +0 -62
- package/components/hy-button/typing.d.ts +28 -162
- package/components/hy-calendar/hy-calendar.vue +2 -2
- package/components/hy-calendar/typing.d.ts +0 -128
- package/components/hy-card/hy-card.vue +12 -12
- package/components/hy-card/index.scss +17 -5
- package/components/hy-card/props.ts +1 -2
- package/components/hy-card/typing.d.ts +1 -114
- package/components/hy-cell/props.ts +1 -1
- package/components/hy-cell/typing.d.ts +0 -55
- package/components/hy-check-button/typing.d.ts +0 -43
- package/components/hy-checkbox/typing.d.ts +1 -73
- package/components/hy-checkbox-group/typing.d.ts +0 -65
- package/components/hy-code-input/typing.d.ts +0 -70
- package/components/hy-count-down/typing.d.ts +1 -20
- package/components/hy-count-to/typing.d.ts +0 -47
- package/components/hy-coupon/index.scss +7 -2
- package/components/hy-coupon/props.ts +7 -4
- package/components/hy-coupon/typing.d.ts +1 -134
- package/components/hy-datetime-picker/props.ts +1 -3
- package/components/hy-datetime-picker/typing.d.ts +0 -119
- package/components/hy-dropdown-item/typing.d.ts +12 -31
- package/components/hy-empty/typing.d.ts +1 -59
- package/components/hy-float-button/typing.d.ts +24 -113
- package/components/hy-folding-panel/props.ts +1 -1
- package/components/hy-folding-panel/typing.d.ts +0 -38
- package/components/hy-folding-panel-item/hy-folding-panel-item.vue +2 -3
- package/components/hy-folding-panel-item/typing.d.ts +14 -0
- package/components/hy-form/typing.d.ts +0 -27
- package/components/hy-form-item/hy-form-item.vue +7 -5
- package/components/hy-form-item/typing.d.ts +0 -19
- package/components/hy-grid/typing.d.ts +0 -43
- package/components/hy-icon/hy-icon.vue +3 -8
- package/components/hy-icon/typing.d.ts +0 -86
- package/components/hy-image/typing.d.ts +0 -80
- package/components/hy-input/typing.d.ts +0 -149
- package/components/hy-list/props.ts +1 -1
- package/components/hy-list/typing.d.ts +0 -51
- package/components/hy-menu/typing.d.ts +0 -35
- package/components/hy-modal/typing.d.ts +9 -84
- package/components/hy-navbar/typing.d.ts +0 -81
- package/components/hy-notice-bar/typing.d.ts +2 -65
- package/components/hy-number-step/typing.d.ts +0 -110
- package/components/hy-overlay/typing.d.ts +2 -27
- package/components/hy-pagination/typing.d.ts +6 -49
- package/components/hy-picker/typing.d.ts +27 -124
- package/components/hy-popover/typing.d.ts +25 -66
- package/components/hy-popup/hy-popup.vue +0 -1
- package/components/hy-popup/typing.d.ts +8 -77
- package/components/hy-price/typing.d.ts +0 -41
- package/components/hy-qrcode/hy-qrcode.vue +67 -2
- package/components/hy-qrcode/index.scss +3 -4
- package/components/hy-qrcode/typing.d.ts +0 -66
- package/components/hy-radio/typing.d.ts +1 -86
- package/components/hy-rate/typing.d.ts +0 -62
- package/components/hy-read-more/typing.d.ts +4 -49
- package/components/hy-scroll-list/typing.d.ts +4 -33
- package/components/hy-search/typing.d.ts +19 -120
- package/components/hy-signature/hy-signature.vue +25 -22
- package/components/hy-signature/index.scss +0 -4
- package/components/hy-signature/typing.d.ts +0 -101
- package/components/hy-slider/typing.d.ts +8 -77
- package/components/hy-steps/typing.d.ts +16 -60
- package/components/hy-submit-bar/typing.d.ts +0 -72
- package/components/hy-subsection/typing.d.ts +0 -49
- package/components/hy-swipe-action/index.ts +13 -22
- package/components/hy-swipe-action/typing.d.ts +1 -38
- package/components/hy-swiper/typing.d.ts +0 -101
- package/components/hy-switch/typing.d.ts +0 -62
- package/components/hy-tabbar/hy-tabbar.vue +137 -0
- package/components/{hy-tabBar → hy-tabbar}/index.scss +31 -31
- package/components/hy-tabbar/props.ts +59 -0
- package/components/hy-tabbar/typing.d.ts +21 -0
- package/components/hy-tabbar-group/hy-tabbar-group.vue +87 -0
- package/components/hy-tabbar-group/index.scss +57 -0
- package/components/hy-tabbar-group/props.ts +78 -0
- package/components/hy-tabbar-group/typing.ts +16 -0
- package/components/hy-tabbar-item/hy-tabbar-item.vue +103 -0
- package/components/hy-tabbar-item/index.scss +43 -0
- package/components/hy-tabbar-item/props.ts +24 -0
- package/components/hy-tabbar-item/typing.ts +10 -0
- package/components/hy-tabs/typing.d.ts +25 -92
- package/components/hy-tag/props.ts +8 -2
- package/components/hy-tag/typing.d.ts +9 -78
- package/components/hy-text/props.ts +8 -2
- package/components/hy-text/typing.d.ts +3 -100
- package/components/hy-textarea/props.ts +4 -1
- package/components/hy-textarea/typing.d.ts +0 -27
- package/components/hy-tooltip/props.ts +1 -4
- package/components/hy-tooltip/typing.d.ts +2 -55
- package/components/hy-transition/typing.d.ts +14 -43
- package/components/hy-upload/props.ts +1 -1
- package/components/hy-upload/typing.d.ts +56 -164
- package/components/hy-warn/typing.d.ts +4 -45
- package/components/index.ts +177 -177
- package/global.d.ts +87 -85
- package/package.json +2 -2
- package/web-types.json +1 -1
- package/components/hy-config-provider/typing.d.ts +0 -24
- package/components/hy-divider/typing.d.ts +0 -64
- package/components/hy-dropdown/typing.d.ts +0 -48
- package/components/hy-form-group/typing.d.ts +0 -0
- package/components/hy-line/typing.d.ts +0 -32
- package/components/hy-line-progress/typing.d.ts +0 -32
- package/components/hy-loading/typing.d.ts +0 -52
- package/components/hy-notify/typing.d.ts +0 -48
- package/components/hy-status-bar/typing.d.ts +0 -12
- package/components/hy-tabBar/hy-tabBar.vue +0 -109
- package/components/hy-tabBar/props.ts +0 -13
- package/components/hy-tabBar/typing.d.ts +0 -54
- package/components/hy-waterfall/typing.d.ts +0 -14
- package/components/hy-watermark/typing.d.ts +0 -76
|
@@ -1,89 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { CheckboxColumnsVo, IFieldNames } from '../hy-check-button/typing'
|
|
3
|
-
|
|
4
|
-
export default interface HyRadioProps {
|
|
5
|
-
/**
|
|
6
|
-
* @description 双向绑定值,数组类型
|
|
7
|
-
* */
|
|
8
|
-
modelValue: string | number
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* @description 接受数组值
|
|
12
|
-
* */
|
|
13
|
-
columns: CheckboxColumnsVo[]
|
|
14
|
-
/**
|
|
15
|
-
* @description 自定义接收columns的键
|
|
16
|
-
* */
|
|
17
|
-
fieldNames?: IFieldNames
|
|
18
|
-
/**
|
|
19
|
-
* @description checkbox组件的标示符
|
|
20
|
-
* */
|
|
21
|
-
name?: string
|
|
22
|
-
/**
|
|
23
|
-
* @description 形状,square为方形,circle为圆型
|
|
24
|
-
* */
|
|
25
|
-
shape?: HyApp.ShapeType
|
|
26
|
-
/**
|
|
27
|
-
* @description 整体的大小
|
|
28
|
-
* */
|
|
29
|
-
size?: HyApp.SizeType | string | number
|
|
30
|
-
/**
|
|
31
|
-
* @description 是否默认选中
|
|
32
|
-
* */
|
|
33
|
-
checkbox?: boolean
|
|
34
|
-
/**
|
|
35
|
-
* @description 是否禁用
|
|
36
|
-
* */
|
|
37
|
-
disabled?: boolean
|
|
38
|
-
/**
|
|
39
|
-
* @description 选中状态下的颜色,如设置此值,将会覆盖parent的activeColor值
|
|
40
|
-
* */
|
|
41
|
-
activeColor?: string
|
|
42
|
-
/**
|
|
43
|
-
* @description 未选中的颜色
|
|
44
|
-
* */
|
|
45
|
-
inactiveColor?: string
|
|
46
|
-
/**
|
|
47
|
-
* @description 图标的大小,单位px
|
|
48
|
-
* */
|
|
49
|
-
iconSize?: string
|
|
50
|
-
/**
|
|
51
|
-
* @description 图标颜色
|
|
52
|
-
* */
|
|
53
|
-
iconColor?: string
|
|
54
|
-
/**
|
|
55
|
-
* @description label提示文字,因为nvue下,直接slot进来的文字,由于特殊的结构,无法修改样式
|
|
56
|
-
* */
|
|
57
|
-
label?: string
|
|
58
|
-
/**
|
|
59
|
-
* @description label的字体大小,px单位
|
|
60
|
-
* */
|
|
61
|
-
labelSize?: string | number
|
|
62
|
-
/**
|
|
63
|
-
* @description label的颜色
|
|
64
|
-
* */
|
|
65
|
-
labelColor?: string
|
|
66
|
-
/**
|
|
67
|
-
* @description 勾选图标的对齐方式,left-左边,right-右边
|
|
68
|
-
* */
|
|
69
|
-
iconPlacement?: HyApp.LeftRightType
|
|
70
|
-
/**
|
|
71
|
-
* @description 竖向配列时,是否显示下划线
|
|
72
|
-
* */
|
|
73
|
-
borderBottom?: boolean
|
|
74
|
-
/**
|
|
75
|
-
* @description 是否禁止点击提示语选中复选框
|
|
76
|
-
* */
|
|
77
|
-
labelDisabled?: boolean
|
|
78
|
-
/**
|
|
79
|
-
* @description 定义需要用到的外部样式
|
|
80
|
-
* */
|
|
81
|
-
customStyle?: CSSProperties
|
|
82
|
-
/**
|
|
83
|
-
* @description 布局方式,row-横向,column-纵向
|
|
84
|
-
* */
|
|
85
|
-
placement?: HyApp.DirectionType
|
|
86
|
-
}
|
|
1
|
+
import { CheckboxColumnsVo } from '../hy-check-button/typing'
|
|
87
2
|
|
|
88
3
|
export interface IRadioEmits {
|
|
89
4
|
/** 选择触发 */
|
|
@@ -1,65 +1,3 @@
|
|
|
1
|
-
import type { CSSProperties } from 'vue'
|
|
2
|
-
|
|
3
|
-
export default interface HyRateProps {
|
|
4
|
-
/**
|
|
5
|
-
* @description v-model绑定的值
|
|
6
|
-
* */
|
|
7
|
-
modelValue: number
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* @description 星星的默认最多数
|
|
11
|
-
* */
|
|
12
|
-
count?: number
|
|
13
|
-
/**
|
|
14
|
-
* @description 是否禁用
|
|
15
|
-
* */
|
|
16
|
-
disabled?: boolean
|
|
17
|
-
/**
|
|
18
|
-
* @description 是否只读
|
|
19
|
-
* */
|
|
20
|
-
readonly?: boolean
|
|
21
|
-
/**
|
|
22
|
-
* @description 星星的大小
|
|
23
|
-
* */
|
|
24
|
-
size?: number | string
|
|
25
|
-
/**
|
|
26
|
-
* @description 未激活星星的颜色
|
|
27
|
-
* */
|
|
28
|
-
inactiveColor?: string
|
|
29
|
-
/**
|
|
30
|
-
* @description 激活星星的颜色
|
|
31
|
-
* */
|
|
32
|
-
activeColor?: string
|
|
33
|
-
/**
|
|
34
|
-
* @description 星星之间的间距
|
|
35
|
-
* */
|
|
36
|
-
gutter?: number
|
|
37
|
-
/**
|
|
38
|
-
* @description 最小星星数量
|
|
39
|
-
* */
|
|
40
|
-
minCount?: number
|
|
41
|
-
/**
|
|
42
|
-
* @description 是否允许半星
|
|
43
|
-
* */
|
|
44
|
-
allowHalf?: boolean
|
|
45
|
-
/**
|
|
46
|
-
* @description 激活状态的图标
|
|
47
|
-
* */
|
|
48
|
-
activeIcon?: string
|
|
49
|
-
/**
|
|
50
|
-
* @description 未激活状态的图标
|
|
51
|
-
* */
|
|
52
|
-
inactiveIcon?: string
|
|
53
|
-
/**
|
|
54
|
-
* @description 是否可触摸
|
|
55
|
-
* */
|
|
56
|
-
touchable?: boolean
|
|
57
|
-
/**
|
|
58
|
-
* @description 自定义样式
|
|
59
|
-
* */
|
|
60
|
-
customStyle?: CSSProperties
|
|
61
|
-
}
|
|
62
|
-
|
|
63
1
|
export interface IRateEmits {
|
|
64
2
|
/** 选中的星星发生变化时触发 */
|
|
65
3
|
(e: 'change', index: number): void
|
|
@@ -1,51 +1,6 @@
|
|
|
1
|
-
import type { CSSProperties } from 'vue'
|
|
2
|
-
|
|
3
|
-
export default interface HyReadMoreProps {
|
|
4
|
-
/**
|
|
5
|
-
* @description 内容超出此高度才会显示展开全文按钮,单位px(默认 400 )
|
|
6
|
-
* */
|
|
7
|
-
showHeight?: number
|
|
8
|
-
/**
|
|
9
|
-
* @description 展开后是否显示收起按钮(默认 false )
|
|
10
|
-
* */
|
|
11
|
-
toggle?: boolean
|
|
12
|
-
/**
|
|
13
|
-
* @description 关闭时的提示文字(默认 '展开阅读全文' )
|
|
14
|
-
* */
|
|
15
|
-
closeText?: string
|
|
16
|
-
/**
|
|
17
|
-
* @description 展开时的提示文字(默认 '收起' )
|
|
18
|
-
* */
|
|
19
|
-
openText?: string
|
|
20
|
-
/**
|
|
21
|
-
* @description 提示文字的颜色(默认 '#2979ff' )
|
|
22
|
-
* */
|
|
23
|
-
color?: string
|
|
24
|
-
/**
|
|
25
|
-
* @description 提示文字的大小,单位px (默认 14 )
|
|
26
|
-
* */
|
|
27
|
-
fontSize?: number
|
|
28
|
-
/**
|
|
29
|
-
* @description 段落首行缩进的字符个数 (默认 '2em' )
|
|
30
|
-
* */
|
|
31
|
-
textIndent?: string
|
|
32
|
-
/**
|
|
33
|
-
* @description 用于在 open 和 close 事件中当作回调参数返回
|
|
34
|
-
* */
|
|
35
|
-
name?: string
|
|
36
|
-
/**
|
|
37
|
-
* @description 显示阴影的样式
|
|
38
|
-
* */
|
|
39
|
-
shadowStyle?: CSSProperties
|
|
40
|
-
/**
|
|
41
|
-
* @description 定义需要用到的外部样式
|
|
42
|
-
* */
|
|
43
|
-
customStyle?: CSSProperties
|
|
44
|
-
}
|
|
45
|
-
|
|
46
1
|
export interface IReadMoreEmits {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
2
|
+
/** 打开触发 */
|
|
3
|
+
(e: 'open', name: string): void
|
|
4
|
+
/** 关闭触发 */
|
|
5
|
+
(e: 'close', name: string): void
|
|
51
6
|
}
|
|
@@ -1,35 +1,6 @@
|
|
|
1
|
-
import type { CSSProperties } from 'vue'
|
|
2
|
-
|
|
3
|
-
export default interface HyScrollListProps {
|
|
4
|
-
/**
|
|
5
|
-
* @description 指示器的整体宽度 (默认 50 )
|
|
6
|
-
* */
|
|
7
|
-
indicatorWidth?: number
|
|
8
|
-
/**
|
|
9
|
-
* @description 滑块的宽度 (默认 20 )
|
|
10
|
-
* */
|
|
11
|
-
indicatorBarWidth?: number
|
|
12
|
-
/**
|
|
13
|
-
* @description 是否显示面板指示器 (默认 true )
|
|
14
|
-
* */
|
|
15
|
-
indicator?: boolean
|
|
16
|
-
/**
|
|
17
|
-
* @description 指示器非激活颜色 (默认 '#f2f2f2' )
|
|
18
|
-
* */
|
|
19
|
-
indicatorColor?: string
|
|
20
|
-
/**
|
|
21
|
-
* @description 指示器的激活颜色 (默认 '#3c9cff' )
|
|
22
|
-
* */
|
|
23
|
-
indicatorActiveColor?: string
|
|
24
|
-
/**
|
|
25
|
-
* @description 指示器样式,可通过bottom,left,right进行定位
|
|
26
|
-
* */
|
|
27
|
-
indicatorStyle?: CSSProperties
|
|
28
|
-
}
|
|
29
|
-
|
|
30
1
|
export interface IScrollListEmits {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
2
|
+
/** 滑动到左边时触发 */
|
|
3
|
+
(e: 'scrollLeft'): void
|
|
4
|
+
/** 滑动到右边时触发 */
|
|
5
|
+
(e: 'scrollRight'): void
|
|
35
6
|
}
|
|
@@ -1,123 +1,22 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type HyIconProps from "../hy-icon/typing";
|
|
3
|
-
import type { InputOnConfirmEvent } from "@uni-helper/uni-types";
|
|
4
|
-
|
|
5
|
-
export default interface HySearchProps {
|
|
6
|
-
/**
|
|
7
|
-
* @description 输入框初始值
|
|
8
|
-
* */
|
|
9
|
-
modelValue: string;
|
|
10
|
-
/**
|
|
11
|
-
* @description 搜索框形状,circle-圆形,square-方形(默认 'circle' )
|
|
12
|
-
* */
|
|
13
|
-
shape?: HyApp.ShapeType;
|
|
14
|
-
/**
|
|
15
|
-
* @description 搜索框背景颜色(默认 '#f2f2f2' )
|
|
16
|
-
* */
|
|
17
|
-
bgColor?: string;
|
|
18
|
-
/**
|
|
19
|
-
* @description 占位文字内容(默认 '请输入关键字' )
|
|
20
|
-
* */
|
|
21
|
-
placeholder?: string;
|
|
22
|
-
/**
|
|
23
|
-
* @description 是否启用清除控件(默认 true )
|
|
24
|
-
* */
|
|
25
|
-
clear?: boolean;
|
|
26
|
-
/**
|
|
27
|
-
* @description 是否自动获得焦点(默认 false )
|
|
28
|
-
* */
|
|
29
|
-
focus?: boolean;
|
|
30
|
-
/**
|
|
31
|
-
* @description 是否显示右侧控件(默认 true )
|
|
32
|
-
* */
|
|
33
|
-
showAction?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* @description 右侧控件的样式,对象形式
|
|
36
|
-
* */
|
|
37
|
-
actionStyle?: CSSProperties;
|
|
38
|
-
/**
|
|
39
|
-
* @description 右侧控件文字(默认 '搜索' )
|
|
40
|
-
* */
|
|
41
|
-
actionText?: string;
|
|
42
|
-
/**
|
|
43
|
-
* @description 输入框内容水平对齐方式 (默认 'left' )
|
|
44
|
-
* */
|
|
45
|
-
inputAlign?: HyApp.RowCenterType;
|
|
46
|
-
/**
|
|
47
|
-
* @description 自定义输入框样式,对象形式
|
|
48
|
-
* */
|
|
49
|
-
inputStyle?: CSSProperties;
|
|
50
|
-
/**
|
|
51
|
-
* @description 是否启用输入框(默认 false )
|
|
52
|
-
* */
|
|
53
|
-
disabled?: boolean;
|
|
54
|
-
/**
|
|
55
|
-
* @description 边框颜色,配置了颜色,才会有边框 (默认 'transparent' )
|
|
56
|
-
* */
|
|
57
|
-
borderColor?: string;
|
|
58
|
-
/**
|
|
59
|
-
* @description 输入框字体颜色(默认 '#606266' )
|
|
60
|
-
* */
|
|
61
|
-
color?: string;
|
|
62
|
-
/**
|
|
63
|
-
* @description placeholder的颜色(默认 '#909399' )
|
|
64
|
-
* */
|
|
65
|
-
placeholderColor?: string;
|
|
66
|
-
/**
|
|
67
|
-
* @description 输入框左边的图标属性集合,可以为图标名称或图片路径 (默认 'search' )
|
|
68
|
-
* */
|
|
69
|
-
searchIcon?: Partial<HyIconProps>;
|
|
70
|
-
/**
|
|
71
|
-
* @description 组件与其他上下左右之间的距离,带单位的字符串形式,如"30px" (默认 '0' )
|
|
72
|
-
* */
|
|
73
|
-
margin?: string;
|
|
74
|
-
/**
|
|
75
|
-
* @description 是否开启动画,见上方说明(默认 false )
|
|
76
|
-
* */
|
|
77
|
-
animation?: boolean;
|
|
78
|
-
/**
|
|
79
|
-
* @description 输入框最大能输入的长度,-1为不限制长度 (默认 '-1' )
|
|
80
|
-
* */
|
|
81
|
-
maxlength?: string | number;
|
|
82
|
-
/**
|
|
83
|
-
* @description 输入框高度,单位px(默认 64 )
|
|
84
|
-
* */
|
|
85
|
-
height?: number;
|
|
86
|
-
/**
|
|
87
|
-
* @description 搜索框左边显示内容
|
|
88
|
-
* */
|
|
89
|
-
label?: string | null;
|
|
90
|
-
/**
|
|
91
|
-
* @description 键盘弹起时,是否自动上推页面
|
|
92
|
-
* */
|
|
93
|
-
adjustPosition?: boolean;
|
|
94
|
-
/**
|
|
95
|
-
* @description 键盘收起时,是否自动失去焦点
|
|
96
|
-
* */
|
|
97
|
-
autoBlur?: boolean;
|
|
98
|
-
/**
|
|
99
|
-
* @description 定义需要用到的外部样式
|
|
100
|
-
* */
|
|
101
|
-
customStyle?: CSSProperties;
|
|
102
|
-
}
|
|
1
|
+
import type { InputOnConfirmEvent } from '@uni-helper/uni-types'
|
|
103
2
|
|
|
104
3
|
export interface ISearchEmits {
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
4
|
+
/** disabled为true时,点击输入框,发出此事件,用于跳转搜索页 */
|
|
5
|
+
(e: 'click'): void
|
|
6
|
+
/** 输入框内容发生变化时触发 */
|
|
7
|
+
(e: 'change', value: string): void
|
|
8
|
+
/** 左侧icon点击时候时触发 */
|
|
9
|
+
(e: 'clickIcon', keyword: string): void
|
|
10
|
+
/** 用户确定搜索时触发,用户按回车键,或者手机键盘右下角的"搜索"键时触发 */
|
|
11
|
+
(e: 'search', event: InputOnConfirmEvent, value: string): void
|
|
12
|
+
/** 配置了clearabled后,清空内容时会发出此事件 */
|
|
13
|
+
(e: 'clear'): void
|
|
14
|
+
/** 用户点击右侧控件时触发 */
|
|
15
|
+
(e: 'confirm', value: string): void
|
|
16
|
+
/** 输入框获得焦点时触发 */
|
|
17
|
+
(e: 'focus', e: InputOnFocusEvent, keyword: string): void
|
|
18
|
+
/** 输入框失去焦点时触发 */
|
|
19
|
+
(e: 'blur', e: InputOnBlurEvent, keyword: string): void
|
|
20
|
+
/** 输入框内容发生变化时触发 */
|
|
21
|
+
(e: 'update:modelValue', value: string): void
|
|
123
22
|
}
|
|
@@ -46,37 +46,39 @@
|
|
|
46
46
|
>
|
|
47
47
|
</slot>
|
|
48
48
|
<template v-else>
|
|
49
|
-
<
|
|
49
|
+
<hy-flex gap="12">
|
|
50
|
+
<block v-if="enableHistory">
|
|
51
|
+
<hy-button
|
|
52
|
+
size="small"
|
|
53
|
+
plain
|
|
54
|
+
shape="circle"
|
|
55
|
+
@click="revoke"
|
|
56
|
+
:disabled="lines.length <= 0"
|
|
57
|
+
:text="revokeText"
|
|
58
|
+
></hy-button>
|
|
59
|
+
<hy-button
|
|
60
|
+
size="small"
|
|
61
|
+
plain
|
|
62
|
+
shape="circle"
|
|
63
|
+
@click="restore"
|
|
64
|
+
:disabled="redoLines.length <= 0"
|
|
65
|
+
:text="restoreText"
|
|
66
|
+
></hy-button>
|
|
67
|
+
</block>
|
|
50
68
|
<hy-button
|
|
51
69
|
size="small"
|
|
52
70
|
plain
|
|
53
71
|
shape="circle"
|
|
54
|
-
@click="
|
|
55
|
-
:
|
|
56
|
-
:text="revokeText"
|
|
72
|
+
@click="clear"
|
|
73
|
+
:text="clearText"
|
|
57
74
|
></hy-button>
|
|
58
75
|
<hy-button
|
|
59
76
|
size="small"
|
|
60
|
-
plain
|
|
61
77
|
shape="circle"
|
|
62
|
-
@click="
|
|
63
|
-
:
|
|
64
|
-
:text="restoreText"
|
|
78
|
+
@click="confirmSignature"
|
|
79
|
+
:text="confirmText"
|
|
65
80
|
></hy-button>
|
|
66
|
-
</
|
|
67
|
-
<hy-button
|
|
68
|
-
size="small"
|
|
69
|
-
plain
|
|
70
|
-
shape="circle"
|
|
71
|
-
@click="clear"
|
|
72
|
-
:text="clearText"
|
|
73
|
-
></hy-button>
|
|
74
|
-
<hy-button
|
|
75
|
-
size="small"
|
|
76
|
-
shape="circle"
|
|
77
|
-
@click="confirmSignature"
|
|
78
|
-
:text="confirmText"
|
|
79
|
-
></hy-button>
|
|
81
|
+
</hy-flex>
|
|
80
82
|
</template>
|
|
81
83
|
</view>
|
|
82
84
|
</view>
|
|
@@ -105,6 +107,7 @@ import signatureProps from './props'
|
|
|
105
107
|
|
|
106
108
|
// 组件
|
|
107
109
|
import HyButton from '../hy-button/hy-button.vue'
|
|
110
|
+
import HyFlex from '../hy-flex/hy-flex.vue'
|
|
108
111
|
|
|
109
112
|
/**
|
|
110
113
|
* 用于签名场景,基于 Canvas 实现的签名组件。提供了基础签名、历史记录、笔锋效果等功能。
|
|
@@ -1,104 +1,3 @@
|
|
|
1
|
-
import type { CSSProperties } from 'vue'
|
|
2
|
-
|
|
3
|
-
export default interface HySignatureProps {
|
|
4
|
-
/**
|
|
5
|
-
* @description 签名笔颜色
|
|
6
|
-
* */
|
|
7
|
-
penColor?: string
|
|
8
|
-
/**
|
|
9
|
-
* @description 签名笔宽度(默认 2 )
|
|
10
|
-
* */
|
|
11
|
-
lineWidth?: number
|
|
12
|
-
/**
|
|
13
|
-
* @description 清空按钮的文本
|
|
14
|
-
* */
|
|
15
|
-
clearText?: string
|
|
16
|
-
/**
|
|
17
|
-
* @description 撤回按钮的文本
|
|
18
|
-
* */
|
|
19
|
-
revokeText?: string
|
|
20
|
-
/**
|
|
21
|
-
* @description 恢复按钮的文本
|
|
22
|
-
* */
|
|
23
|
-
restoreText?: string
|
|
24
|
-
/**
|
|
25
|
-
* @description 确认按钮的文本
|
|
26
|
-
* */
|
|
27
|
-
confirmText?: string
|
|
28
|
-
/**
|
|
29
|
-
* @description 目标文件的类型(默认 png )
|
|
30
|
-
* */
|
|
31
|
-
fileType?: string
|
|
32
|
-
/**
|
|
33
|
-
* @description 签名笔颜色
|
|
34
|
-
* */
|
|
35
|
-
quality?: number
|
|
36
|
-
/**
|
|
37
|
-
* @description 目标文件的质量(默认 1 )
|
|
38
|
-
* */
|
|
39
|
-
exportScale?: number
|
|
40
|
-
/**
|
|
41
|
-
* @description 是否禁用签名板(默认 false )
|
|
42
|
-
* */
|
|
43
|
-
disabled?: boolean
|
|
44
|
-
/**
|
|
45
|
-
* @description 画布的高度
|
|
46
|
-
* */
|
|
47
|
-
height?: number
|
|
48
|
-
/**
|
|
49
|
-
* @description 画布的宽度
|
|
50
|
-
* */
|
|
51
|
-
width?: number
|
|
52
|
-
/**
|
|
53
|
-
* @description 边框圆角
|
|
54
|
-
* */
|
|
55
|
-
round?: string | number
|
|
56
|
-
/**
|
|
57
|
-
* @description 画板的背景色
|
|
58
|
-
* */
|
|
59
|
-
backgroundColor?: string
|
|
60
|
-
/**
|
|
61
|
-
* @description 是否禁用画布滚动(默认 true )
|
|
62
|
-
* */
|
|
63
|
-
disableScroll?: boolean
|
|
64
|
-
/**
|
|
65
|
-
* @description 是否开启历史记录(默认 false )
|
|
66
|
-
* */
|
|
67
|
-
enableHistory?: boolean
|
|
68
|
-
/**
|
|
69
|
-
* @description 撤回和恢复的步长(默认 1 )
|
|
70
|
-
* */
|
|
71
|
-
step?: number
|
|
72
|
-
/**
|
|
73
|
-
* @description 撤回按钮的文本(默认 撤销 )
|
|
74
|
-
* */
|
|
75
|
-
undoText?: string
|
|
76
|
-
/**
|
|
77
|
-
* @description 恢复按钮的文本(默认 恢复 )
|
|
78
|
-
* */
|
|
79
|
-
redoText?: string
|
|
80
|
-
/**
|
|
81
|
-
* @description 是否启用压感模式(默认 false )
|
|
82
|
-
* */
|
|
83
|
-
pressure?: boolean
|
|
84
|
-
/**
|
|
85
|
-
* @description 压感模式下笔画最小宽度(默认 2 )
|
|
86
|
-
* */
|
|
87
|
-
minWidth?: number
|
|
88
|
-
/**
|
|
89
|
-
* @description 压感模式下笔画最大宽度(默认 6 )
|
|
90
|
-
* */
|
|
91
|
-
maxWidth?: number
|
|
92
|
-
/**
|
|
93
|
-
* @description 最小速度阈值,影响压感模式下的笔画宽度变化(默认 1.5 )
|
|
94
|
-
* */
|
|
95
|
-
minSpeed?: number
|
|
96
|
-
/**
|
|
97
|
-
* @description 定义需要用到的外部样式
|
|
98
|
-
* */
|
|
99
|
-
customStyle?: CSSProperties
|
|
100
|
-
}
|
|
101
|
-
|
|
102
1
|
/**
|
|
103
2
|
* 签名结果类型
|
|
104
3
|
* @property tempFilePath - 生成图片的临时路径
|
|
@@ -1,79 +1,10 @@
|
|
|
1
|
-
import type { CSSProperties } from "vue";
|
|
2
|
-
|
|
3
|
-
export default interface HySliderProps {
|
|
4
|
-
/**
|
|
5
|
-
* @description 滑块默认值(默认0)
|
|
6
|
-
* */
|
|
7
|
-
modelValue?: number;
|
|
8
|
-
/**
|
|
9
|
-
* @description 滑块的大小,取值范围为 12 - 28
|
|
10
|
-
* */
|
|
11
|
-
blockSize?: number | string;
|
|
12
|
-
/**
|
|
13
|
-
* @description 最小值(默认0)
|
|
14
|
-
* */
|
|
15
|
-
min?: number;
|
|
16
|
-
/**
|
|
17
|
-
* @description 最大值(默认100)
|
|
18
|
-
* */
|
|
19
|
-
max?: number;
|
|
20
|
-
/**
|
|
21
|
-
* @description 步长(默认1)
|
|
22
|
-
* */
|
|
23
|
-
step?: number;
|
|
24
|
-
/**
|
|
25
|
-
* @description 底部选择部分的背景颜色(默认#2979ff)
|
|
26
|
-
* */
|
|
27
|
-
activeColor?: string;
|
|
28
|
-
/**
|
|
29
|
-
* @description 底部条背景颜色(默认#c0c4cc)
|
|
30
|
-
* */
|
|
31
|
-
inactiveColor?: string;
|
|
32
|
-
/**
|
|
33
|
-
* @description 滑块颜色(默认#ffffff)
|
|
34
|
-
* */
|
|
35
|
-
blockColor?: string;
|
|
36
|
-
/**
|
|
37
|
-
* @description 是否显示当前的选择值
|
|
38
|
-
* */
|
|
39
|
-
showValue?: boolean;
|
|
40
|
-
/**
|
|
41
|
-
* @description 是否禁用滑块(默认为false)
|
|
42
|
-
* */
|
|
43
|
-
disabled?: boolean;
|
|
44
|
-
/**
|
|
45
|
-
* @description 给滑块自定义样式,对象形式
|
|
46
|
-
* */
|
|
47
|
-
blockStyle?: CSSProperties;
|
|
48
|
-
/**
|
|
49
|
-
* @description 是否渲染uni-app框架内置组件(默认false)
|
|
50
|
-
* */
|
|
51
|
-
useNative?: boolean;
|
|
52
|
-
/**
|
|
53
|
-
* @description 滑块条高度,单位rpx(默认6)
|
|
54
|
-
* */
|
|
55
|
-
height?: string | number;
|
|
56
|
-
/**
|
|
57
|
-
* @description 双滑块时值
|
|
58
|
-
* */
|
|
59
|
-
rangeValue?: number[];
|
|
60
|
-
/**
|
|
61
|
-
* @description 是否区间的模式
|
|
62
|
-
* */
|
|
63
|
-
isRange?: boolean;
|
|
64
|
-
/**
|
|
65
|
-
* @description 自定义样式
|
|
66
|
-
* */
|
|
67
|
-
customStyle?: CSSProperties;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
1
|
export interface ISliderEmits {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
2
|
+
/** 开始滑动触发 */
|
|
3
|
+
(e: 'start'): void
|
|
4
|
+
/** 触发事件(拖动过程中) */
|
|
5
|
+
(e: 'changing', value: number | number[]): void
|
|
6
|
+
/** 触发事件 */
|
|
7
|
+
(e: 'change', value: number | number[]): void
|
|
8
|
+
/** 数值改变触发 */
|
|
9
|
+
(e: 'update:modelValue', value: number | number[]): void
|
|
79
10
|
}
|