uview-plus 3.2.3 → 3.2.6
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/changelog.md +9 -0
- package/components/u-checkbox/u-checkbox.vue +2 -2
- package/components/u-number-box/u-number-box.vue +4 -4
- package/components/u-picker/u-picker.vue +1 -1
- package/components/u-radio/u-radio.vue +2 -2
- package/components/u-rate/u-rate.vue +1 -1
- package/components/u-subsection/u-subsection.vue +22 -14
- package/components/u-swipe-action-item/u-swipe-action-item.vue +18 -1
- package/components/u-switch/u-switch.vue +1 -1
- package/components/u-tabbar-item/u-tabbar-item.vue +1 -1
- package/components/u-tag/u-tag.vue +1 -1
- package/index.js +5 -2
- package/libs/css/common.scss +3 -0
- package/libs/mixin/mpShare.js +15 -13
- package/package.json +2 -1
- package/types/comps/_common.d.ts +9 -0
- package/types/comps/actionSheet.d.ts +121 -0
- package/types/comps/album.d.ts +72 -0
- package/types/comps/alert.d.ts +55 -0
- package/types/comps/avatar.d.ts +85 -0
- package/types/comps/avatarGroup.d.ts +62 -0
- package/types/comps/backTop.d.ts +74 -0
- package/types/comps/badge.d.ts +76 -0
- package/types/comps/button.d.ts +169 -0
- package/types/comps/calendar.d.ts +164 -0
- package/types/comps/cell.d.ts +133 -0
- package/types/comps/cellGroup.d.ts +27 -0
- package/types/comps/checkbox.d.ts +69 -0
- package/types/comps/checkboxGroup.d.ts +93 -0
- package/types/comps/code.d.ts +69 -0
- package/types/comps/codeInput.d.ts +98 -0
- package/types/comps/col.d.ts +43 -0
- package/types/comps/collapse.d.ts +52 -0
- package/types/comps/collapseItem.d.ts +83 -0
- package/types/comps/countDown.d.ts +60 -0
- package/types/comps/countTo.d.ts +88 -0
- package/types/comps/datetimePicker.d.ts +146 -0
- package/types/comps/divider.d.ts +58 -0
- package/types/comps/empty.d.ts +72 -0
- package/types/comps/form.d.ts +76 -0
- package/types/comps/formItem.d.ts +68 -0
- package/types/comps/gap.d.ts +35 -0
- package/types/comps/grid.d.ts +34 -0
- package/types/comps/gridItem.d.ts +28 -0
- package/types/comps/icon.d.ts +93 -0
- package/types/comps/image.d.ts +119 -0
- package/types/comps/indexAnchor.d.ts +38 -0
- package/types/comps/indexItem.d.ts +18 -0
- package/types/comps/indexList.d.ts +39 -0
- package/types/comps/input.d.ts +234 -0
- package/types/comps/keyboard.d.ts +125 -0
- package/types/comps/line.d.ts +44 -0
- package/types/comps/lineProgress.d.ts +51 -0
- package/types/comps/link.d.ts +51 -0
- package/types/comps/list.d.ts +92 -0
- package/types/comps/listItem.d.ts +18 -0
- package/types/comps/loadMore.d.ts +108 -0
- package/types/comps/loadingIcon.d.ts +68 -0
- package/types/comps/loadingPage.d.ts +58 -0
- package/types/comps/modal.d.ts +115 -0
- package/types/comps/navbar.d.ts +113 -0
- package/types/comps/noNetwork.d.ts +40 -0
- package/types/comps/noticeBar.d.ts +85 -0
- package/types/comps/notify.d.ts +73 -0
- package/types/comps/numberBox.d.ts +155 -0
- package/types/comps/overlay.d.ts +46 -0
- package/types/comps/parse.d.ts +101 -0
- package/types/comps/picker.d.ts +115 -0
- package/types/comps/popup.d.ts +103 -0
- package/types/comps/radio.d.ts +77 -0
- package/types/comps/radioGroup.d.ts +97 -0
- package/types/comps/rate.d.ts +85 -0
- package/types/comps/readMore.d.ts +80 -0
- package/types/comps/row.d.ts +34 -0
- package/types/comps/scrollList.d.ts +51 -0
- package/types/comps/search.d.ts +167 -0
- package/types/comps/skeleton.d.ts +70 -0
- package/types/comps/slider.d.ts +79 -0
- package/types/comps/steps.d.ts +48 -0
- package/types/comps/stepsItem.d.ts +41 -0
- package/types/comps/sticky.d.ts +48 -0
- package/types/comps/subsection.d.ts +64 -0
- package/types/comps/swipeAction.d.ts +24 -0
- package/types/comps/swipeActionItem.d.ts +58 -0
- package/types/comps/swiper.d.ts +142 -0
- package/types/comps/swiperIndicator.d.ts +37 -0
- package/types/comps/switch.d.ts +73 -0
- package/types/comps/tabbar.d.ts +54 -0
- package/types/comps/tabbarItem.d.ts +52 -0
- package/types/comps/tabs.d.ts +85 -0
- package/types/comps/tag.d.ts +93 -0
- package/types/comps/text.d.ts +110 -0
- package/types/comps/textarea.d.ts +158 -0
- package/types/comps/toast.d.ts +59 -0
- package/types/comps/tooltip.d.ts +71 -0
- package/types/comps/transition.d.ts +61 -0
- package/types/comps/upload.d.ts +163 -0
- package/types/comps.d.ts +99 -0
- package/types/index.d.ts +48 -0
- package/types/package.json +26 -0
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface LinkProps {
|
|
4
|
+
/**
|
|
5
|
+
* 文字颜色
|
|
6
|
+
* @default color['u-primary']
|
|
7
|
+
*/
|
|
8
|
+
color?: string
|
|
9
|
+
/**
|
|
10
|
+
* 字体大小,默认单位px
|
|
11
|
+
* @default 15
|
|
12
|
+
*/
|
|
13
|
+
fontSize?: string | number
|
|
14
|
+
/**
|
|
15
|
+
* 是否显示下划线
|
|
16
|
+
* @default false
|
|
17
|
+
*/
|
|
18
|
+
underLine?: boolean
|
|
19
|
+
/**
|
|
20
|
+
* 跳转的链接,要带上http(s)
|
|
21
|
+
*/
|
|
22
|
+
href?: string
|
|
23
|
+
/**
|
|
24
|
+
* 各个小程序平台把链接复制到粘贴板后的提示语
|
|
25
|
+
* @default "链接已复制,请在浏览器打开"
|
|
26
|
+
*/
|
|
27
|
+
mpTips?: string
|
|
28
|
+
/**
|
|
29
|
+
* 下划线颜色,默认同color参数颜色
|
|
30
|
+
*/
|
|
31
|
+
lineColor?: string
|
|
32
|
+
/**
|
|
33
|
+
* 超链接的问题,不使用slot形式传入,是因为nvue下无法修改颜色
|
|
34
|
+
*/
|
|
35
|
+
text?: string
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
declare interface LinkSlots {
|
|
39
|
+
['default']?: () => any
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
declare interface _Link {
|
|
43
|
+
new (): {
|
|
44
|
+
$props: AllowedComponentProps &
|
|
45
|
+
VNodeProps &
|
|
46
|
+
LinkProps
|
|
47
|
+
$slots: LinkSlots
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export declare const Link: _Link
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface ListProps {
|
|
4
|
+
/**
|
|
5
|
+
* 控制是否出现滚动条,仅nvue有效
|
|
6
|
+
* @default false
|
|
7
|
+
*/
|
|
8
|
+
showScrollbar?: boolean
|
|
9
|
+
/**
|
|
10
|
+
* 距底部多少时触发scrolltolower事件
|
|
11
|
+
* @default 50
|
|
12
|
+
*/
|
|
13
|
+
lowerThreshold?: string | number
|
|
14
|
+
/**
|
|
15
|
+
* 距顶部多少时触发scrolltoupper事件,非nvue有效
|
|
16
|
+
* @default 0
|
|
17
|
+
*/
|
|
18
|
+
upperThreshold?: string | number
|
|
19
|
+
/**
|
|
20
|
+
* 设置竖向滚动条位置
|
|
21
|
+
* @default 0
|
|
22
|
+
*/
|
|
23
|
+
scrollTop?: string | number
|
|
24
|
+
/**
|
|
25
|
+
* 控制 onscroll 事件触发的频率,仅nvue有效
|
|
26
|
+
* @default 10
|
|
27
|
+
*/
|
|
28
|
+
offsetAccuracy?: string | number
|
|
29
|
+
/**
|
|
30
|
+
* 启用 flexbox 布局。开启后,当前节点声明了display: flex就会成为flex container,并作用于其孩子节点,仅微信小程序有效
|
|
31
|
+
* @default false
|
|
32
|
+
*/
|
|
33
|
+
enableFlex?: boolean
|
|
34
|
+
/**
|
|
35
|
+
* 是否按分页模式显示List
|
|
36
|
+
* @default false
|
|
37
|
+
*/
|
|
38
|
+
pagingEnabled?: boolean
|
|
39
|
+
/**
|
|
40
|
+
* 是否允许List滚动
|
|
41
|
+
* @default true
|
|
42
|
+
*/
|
|
43
|
+
scrollable?: boolean
|
|
44
|
+
/**
|
|
45
|
+
* 值应为某子元素id(id不能以数字开头)
|
|
46
|
+
*/
|
|
47
|
+
scrollIntoView?: string
|
|
48
|
+
/**
|
|
49
|
+
* 在设置滚动条位置时使用动画过渡
|
|
50
|
+
* @default false
|
|
51
|
+
*/
|
|
52
|
+
scrollWithAnimation?: boolean
|
|
53
|
+
/**
|
|
54
|
+
* iOS点击顶部状态栏、安卓双击标题栏时,滚动条返回顶部,只对微信小程序有效
|
|
55
|
+
* @default false
|
|
56
|
+
*/
|
|
57
|
+
enableBackToTop?: boolean
|
|
58
|
+
/**
|
|
59
|
+
* 列表的高度
|
|
60
|
+
* @default 0
|
|
61
|
+
*/
|
|
62
|
+
height?: string | number
|
|
63
|
+
/**
|
|
64
|
+
* 列表宽度
|
|
65
|
+
* @default 0
|
|
66
|
+
*/
|
|
67
|
+
width?: string | number
|
|
68
|
+
/**
|
|
69
|
+
* 列表前后预渲染的屏数,1代表一个屏幕的高度,1.5代表1个半屏幕高度
|
|
70
|
+
* @default 1
|
|
71
|
+
*/
|
|
72
|
+
preLoadScreen?: string | number
|
|
73
|
+
/**
|
|
74
|
+
* 滚动条滚动触发事件
|
|
75
|
+
* @param scrollTop 滚动条位置
|
|
76
|
+
*/
|
|
77
|
+
onScroll?: (scrollTop: number) => any
|
|
78
|
+
/**
|
|
79
|
+
* 滚动到底部触发事件
|
|
80
|
+
*/
|
|
81
|
+
onScrolltolower?: () => any
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
declare interface _List {
|
|
85
|
+
new (): {
|
|
86
|
+
$props: AllowedComponentProps &
|
|
87
|
+
VNodeProps &
|
|
88
|
+
ListProps
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export declare const List: _List
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface ListItemProps {
|
|
4
|
+
/**
|
|
5
|
+
* 用于滚动到指定item
|
|
6
|
+
*/
|
|
7
|
+
anchor?: string | number
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
declare interface _ListItem {
|
|
11
|
+
new (): {
|
|
12
|
+
$props: AllowedComponentProps &
|
|
13
|
+
VNodeProps &
|
|
14
|
+
ListItemProps
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export declare const ListItem: _ListItem
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface LoadMoreProps {
|
|
4
|
+
/**
|
|
5
|
+
* 组件状态
|
|
6
|
+
* @default "loadmore"
|
|
7
|
+
*/
|
|
8
|
+
status?: 'loadmore' | 'loading' | 'nomore'
|
|
9
|
+
/**
|
|
10
|
+
* 组件背景颜色,在页面是非白色时会用到
|
|
11
|
+
* @default "transparent"
|
|
12
|
+
*/
|
|
13
|
+
bgColor?: string
|
|
14
|
+
/**
|
|
15
|
+
* 加载中时是否显示图标
|
|
16
|
+
* @default true
|
|
17
|
+
*/
|
|
18
|
+
icon?: boolean
|
|
19
|
+
/**
|
|
20
|
+
* 字体大小,单位rpx
|
|
21
|
+
* @default 14
|
|
22
|
+
*/
|
|
23
|
+
fontSize?: string | number
|
|
24
|
+
/**
|
|
25
|
+
* 图标大小,单位px
|
|
26
|
+
* @default 17
|
|
27
|
+
*/
|
|
28
|
+
iconSize?: string | number
|
|
29
|
+
/**
|
|
30
|
+
* 字体颜色
|
|
31
|
+
* @default "#606266"
|
|
32
|
+
*/
|
|
33
|
+
color?: string
|
|
34
|
+
/**
|
|
35
|
+
* 加载中状态的图标
|
|
36
|
+
* @default "circle"
|
|
37
|
+
*/
|
|
38
|
+
loadingIcon?: 'circle' | 'spinner' | 'semicircle'
|
|
39
|
+
/**
|
|
40
|
+
* 加载前的提示语
|
|
41
|
+
* @default "加载更多"
|
|
42
|
+
*/
|
|
43
|
+
loadmoreText?: string
|
|
44
|
+
/**
|
|
45
|
+
* 加载中提示语
|
|
46
|
+
* @default "正在加载..."
|
|
47
|
+
*/
|
|
48
|
+
loadingText?: string
|
|
49
|
+
/**
|
|
50
|
+
* 没有更多的提示语
|
|
51
|
+
* @default "没有更多了"
|
|
52
|
+
*/
|
|
53
|
+
nomoreText?: string
|
|
54
|
+
/**
|
|
55
|
+
* `status`为`nomore`时,内容显示为一个"●"
|
|
56
|
+
* @default false
|
|
57
|
+
*/
|
|
58
|
+
isDot?: boolean
|
|
59
|
+
/**
|
|
60
|
+
* 加载中的动画图标的颜色
|
|
61
|
+
* @default "#b7b7b7"
|
|
62
|
+
*/
|
|
63
|
+
iconColor?: string
|
|
64
|
+
/**
|
|
65
|
+
* 线条颜色
|
|
66
|
+
* @default "#E6E8EB"
|
|
67
|
+
*/
|
|
68
|
+
lineColor?: string
|
|
69
|
+
/**
|
|
70
|
+
* 是否虚线,false-实线,true-虚线
|
|
71
|
+
* @default false
|
|
72
|
+
*/
|
|
73
|
+
dashed?: boolean
|
|
74
|
+
/**
|
|
75
|
+
* 与前一个元素的距离,单位rpx
|
|
76
|
+
* @default 10
|
|
77
|
+
*/
|
|
78
|
+
marginTop?: string | number
|
|
79
|
+
/**
|
|
80
|
+
* 与后一个元素的距离,单位rpx
|
|
81
|
+
* @default 10
|
|
82
|
+
*/
|
|
83
|
+
marginBottom?: string | number
|
|
84
|
+
/**
|
|
85
|
+
* 高度
|
|
86
|
+
* @default "auto"
|
|
87
|
+
*/
|
|
88
|
+
height?: string | number
|
|
89
|
+
/**
|
|
90
|
+
* 是否显示左边分割线
|
|
91
|
+
* @default false
|
|
92
|
+
*/
|
|
93
|
+
line?: boolean
|
|
94
|
+
/**
|
|
95
|
+
* `status`为`loadmore`时,点击组件会发出此事件
|
|
96
|
+
*/
|
|
97
|
+
onLoadmore?: () => any
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
declare interface _LoadMore {
|
|
101
|
+
new (): {
|
|
102
|
+
$props: AllowedComponentProps &
|
|
103
|
+
VNodeProps &
|
|
104
|
+
LoadMoreProps
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export declare const LoadMore: _LoadMore
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface LoadingIconProps {
|
|
4
|
+
/**
|
|
5
|
+
* 是否显示动画
|
|
6
|
+
* @default true
|
|
7
|
+
*/
|
|
8
|
+
show?: boolean
|
|
9
|
+
/**
|
|
10
|
+
* 图标颜色
|
|
11
|
+
* @default "color['u-tips-color']"
|
|
12
|
+
*/
|
|
13
|
+
color?: string
|
|
14
|
+
/**
|
|
15
|
+
* 提示文本颜色
|
|
16
|
+
* @default "color['u-tips-color']"
|
|
17
|
+
*/
|
|
18
|
+
textColor?: string
|
|
19
|
+
/**
|
|
20
|
+
* 图标和文字是否垂直排列
|
|
21
|
+
* @default false
|
|
22
|
+
*/
|
|
23
|
+
vertical?: boolean
|
|
24
|
+
/**
|
|
25
|
+
* 模式选
|
|
26
|
+
* @default "circle"
|
|
27
|
+
*/
|
|
28
|
+
mode?: 'circle' | 'semicircle'
|
|
29
|
+
/**
|
|
30
|
+
* 加载图标的大小,单位px
|
|
31
|
+
* @default 24
|
|
32
|
+
*/
|
|
33
|
+
size?: string | number
|
|
34
|
+
/**
|
|
35
|
+
* 加载文字的大小,单位px
|
|
36
|
+
* @default 15
|
|
37
|
+
*/
|
|
38
|
+
textSize?: string | number
|
|
39
|
+
/**
|
|
40
|
+
* 文字内容
|
|
41
|
+
*/
|
|
42
|
+
text?: string
|
|
43
|
+
/**
|
|
44
|
+
* 指定`animation-timing-function`的css属性,但只支持`mode`为`circle`或`semicircle`才有效
|
|
45
|
+
* @default "ease-in-out"
|
|
46
|
+
*/
|
|
47
|
+
timingFunction?: string
|
|
48
|
+
/**
|
|
49
|
+
* 动画执行周期时间,单位ms
|
|
50
|
+
* @default 1200
|
|
51
|
+
*/
|
|
52
|
+
duration?: string | number
|
|
53
|
+
/**
|
|
54
|
+
* 图标的暗边颜色, `mode`为`circle` 模式有效
|
|
55
|
+
* @default "transparent"
|
|
56
|
+
*/
|
|
57
|
+
inactiveColor?: string
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
declare interface _LoadingIcon {
|
|
61
|
+
new (): {
|
|
62
|
+
$props: AllowedComponentProps &
|
|
63
|
+
VNodeProps &
|
|
64
|
+
LoadingIconProps
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export declare const LoadingIcon: _LoadingIcon
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface LoadingPageProps {
|
|
4
|
+
/**
|
|
5
|
+
* 提示内容
|
|
6
|
+
* @default "正在加载"
|
|
7
|
+
*/
|
|
8
|
+
loadingText?: string | number
|
|
9
|
+
/**
|
|
10
|
+
* 文字上方用于替换loading动画的图片
|
|
11
|
+
*/
|
|
12
|
+
image?: string
|
|
13
|
+
/**
|
|
14
|
+
* 加载动画的模式
|
|
15
|
+
* @default "circle"
|
|
16
|
+
*/
|
|
17
|
+
loadingMode?: 'circle' | 'spinner' | 'semicircle'
|
|
18
|
+
/**
|
|
19
|
+
* 是否加载中
|
|
20
|
+
* @default false
|
|
21
|
+
*/
|
|
22
|
+
loading?: boolean
|
|
23
|
+
/**
|
|
24
|
+
* 背景颜色
|
|
25
|
+
* @default "#ffffff"
|
|
26
|
+
*/
|
|
27
|
+
bgColor?: string
|
|
28
|
+
/**
|
|
29
|
+
* 文字颜色
|
|
30
|
+
* @default "#C8C8C8"
|
|
31
|
+
*/
|
|
32
|
+
color?: string
|
|
33
|
+
/**
|
|
34
|
+
* 文字大小
|
|
35
|
+
* @default 19
|
|
36
|
+
*/
|
|
37
|
+
fontSize?: string | number
|
|
38
|
+
/**
|
|
39
|
+
* 图标大小
|
|
40
|
+
* @default 28
|
|
41
|
+
*/
|
|
42
|
+
iconSize?: string | number
|
|
43
|
+
/**
|
|
44
|
+
* 加载中图标的颜色
|
|
45
|
+
* @default "#C8C8C8"
|
|
46
|
+
*/
|
|
47
|
+
loadingColor?: string
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
declare interface _LoadingPage {
|
|
51
|
+
new (): {
|
|
52
|
+
$props: AllowedComponentProps &
|
|
53
|
+
VNodeProps &
|
|
54
|
+
LoadingPageProps
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export declare const LoadingPage: _LoadingPage
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface ModalProps {
|
|
4
|
+
/**
|
|
5
|
+
* 是否显示模态框,请赋值给`show`
|
|
6
|
+
* @default false
|
|
7
|
+
*/
|
|
8
|
+
show?: boolean
|
|
9
|
+
/**
|
|
10
|
+
* 标题内容
|
|
11
|
+
*/
|
|
12
|
+
title?: string
|
|
13
|
+
/**
|
|
14
|
+
* 模态框内容,如传入`slot`内容,则此参数无效
|
|
15
|
+
*/
|
|
16
|
+
content?: string
|
|
17
|
+
/**
|
|
18
|
+
* 确认按钮的文字
|
|
19
|
+
* @default "确认"
|
|
20
|
+
*/
|
|
21
|
+
confirmText?: string
|
|
22
|
+
/**
|
|
23
|
+
* 取消按钮的文字
|
|
24
|
+
* @default "取消"
|
|
25
|
+
*/
|
|
26
|
+
cancelText?: string
|
|
27
|
+
/**
|
|
28
|
+
* 是否显示确认按钮
|
|
29
|
+
* @default true
|
|
30
|
+
*/
|
|
31
|
+
showConfirmButton?: boolean
|
|
32
|
+
/**
|
|
33
|
+
* 是否显示取消按钮
|
|
34
|
+
* @default false
|
|
35
|
+
*/
|
|
36
|
+
showCancelButton?: boolean
|
|
37
|
+
/**
|
|
38
|
+
* 确认按钮的颜色
|
|
39
|
+
* @default "#2979ff"
|
|
40
|
+
*/
|
|
41
|
+
confirmColor?: string
|
|
42
|
+
/**
|
|
43
|
+
* 取消按钮的颜色
|
|
44
|
+
* @default "#606266"
|
|
45
|
+
*/
|
|
46
|
+
cancelColor?: string
|
|
47
|
+
/**
|
|
48
|
+
* 对调确认和取消的位置
|
|
49
|
+
* @default false
|
|
50
|
+
*/
|
|
51
|
+
buttonReverse?: boolean
|
|
52
|
+
/**
|
|
53
|
+
* 是否开启缩放模式
|
|
54
|
+
* @default true
|
|
55
|
+
*/
|
|
56
|
+
zoom?: boolean
|
|
57
|
+
/**
|
|
58
|
+
* 是否异步关闭,只对确定按钮有效
|
|
59
|
+
* @default false
|
|
60
|
+
*/
|
|
61
|
+
asyncClose?: boolean
|
|
62
|
+
/**
|
|
63
|
+
* 是否允许点击遮罩关闭Modal(注意:关闭事件需要自行处理,只会在开启closeOnClickOverlay后点击遮罩层执行close回调)
|
|
64
|
+
* @default false
|
|
65
|
+
*/
|
|
66
|
+
closeOnClickOverlay?: boolean
|
|
67
|
+
/**
|
|
68
|
+
* 往上偏移的值,给一个负的margin-top,往上偏移,避免和键盘重合的情况,单位任意,数值则默认为rpx单位
|
|
69
|
+
* @default 0
|
|
70
|
+
*/
|
|
71
|
+
negativeTop?: string | number
|
|
72
|
+
/**
|
|
73
|
+
* modal宽度,不支持百分比,可以数值,px,rpx单位
|
|
74
|
+
* @default "650rpx"
|
|
75
|
+
*/
|
|
76
|
+
width?: string | number
|
|
77
|
+
/**
|
|
78
|
+
* 确认按钮的样式,如设置,将不会显示取消按钮
|
|
79
|
+
*/
|
|
80
|
+
confirmButtonShape?: 'circle' | 'square'
|
|
81
|
+
/**
|
|
82
|
+
* 点击确认按钮时触发
|
|
83
|
+
*/
|
|
84
|
+
onConfirm?: () => any
|
|
85
|
+
/**
|
|
86
|
+
* 点击取消按钮时触发
|
|
87
|
+
*/
|
|
88
|
+
onCancel?: () => any
|
|
89
|
+
/**
|
|
90
|
+
* 点击遮罩关闭出发,closeOnClickOverlay为true有效
|
|
91
|
+
*/
|
|
92
|
+
onClose?: () => any
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
declare interface ModalSlots {
|
|
96
|
+
/**
|
|
97
|
+
* 传入自定义内容,一般为富文本
|
|
98
|
+
*/
|
|
99
|
+
['default']?: () => any
|
|
100
|
+
/**
|
|
101
|
+
* 传入自定义按钮,用于在微信小程序弹窗通过按钮授权的场景
|
|
102
|
+
*/
|
|
103
|
+
['confirm-button']?: () => any
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
declare interface _Modal {
|
|
107
|
+
new (): {
|
|
108
|
+
$props: AllowedComponentProps &
|
|
109
|
+
VNodeProps &
|
|
110
|
+
ModalProps
|
|
111
|
+
$slots: ModalSlots
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
export declare const Modal: _Modal
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface NavbarProps {
|
|
4
|
+
/**
|
|
5
|
+
* 是否开启顶部安全区适配
|
|
6
|
+
* @default true
|
|
7
|
+
*/
|
|
8
|
+
safeAreaInsetTop?: boolean
|
|
9
|
+
/**
|
|
10
|
+
* 固定在顶部时,是否生成一个等高元素,以防止塌陷
|
|
11
|
+
* @default false
|
|
12
|
+
*/
|
|
13
|
+
placeholder?: boolean
|
|
14
|
+
/**
|
|
15
|
+
* 导航栏是否固定在顶部
|
|
16
|
+
* @default true
|
|
17
|
+
*/
|
|
18
|
+
fixed?: boolean
|
|
19
|
+
/**
|
|
20
|
+
* 导航栏底部是否显示下边框
|
|
21
|
+
* @default false
|
|
22
|
+
*/
|
|
23
|
+
border?: boolean
|
|
24
|
+
/**
|
|
25
|
+
* 左边返回图标的名称,只能为uView自带的图标
|
|
26
|
+
* @default "arrow-left"
|
|
27
|
+
*/
|
|
28
|
+
leftIcon?: string
|
|
29
|
+
/**
|
|
30
|
+
* 左边的提示文字
|
|
31
|
+
*/
|
|
32
|
+
leftText?: string
|
|
33
|
+
/**
|
|
34
|
+
* 右边的提示文字
|
|
35
|
+
*/
|
|
36
|
+
rightText?: string
|
|
37
|
+
/**
|
|
38
|
+
* 右边返回图标的名称,只能为uView自带的图标
|
|
39
|
+
*/
|
|
40
|
+
rightIcon?: string
|
|
41
|
+
/**
|
|
42
|
+
* 导航栏标题,如设置为空字符,将会隐藏标题占位区域
|
|
43
|
+
*/
|
|
44
|
+
title?: string
|
|
45
|
+
/**
|
|
46
|
+
* 导航栏背景设置
|
|
47
|
+
* @default"#fff
|
|
48
|
+
*/
|
|
49
|
+
bgColor?: string
|
|
50
|
+
/**
|
|
51
|
+
* 导航栏标题的最大宽度,内容超出会以省略号隐藏,单位rpx
|
|
52
|
+
* @default "400rpx"
|
|
53
|
+
*/
|
|
54
|
+
titleWidth?: string | number
|
|
55
|
+
/**
|
|
56
|
+
* 导航栏高度(不包括状态栏高度在内,内部自动加上),单位px
|
|
57
|
+
* @default "44px"
|
|
58
|
+
*/
|
|
59
|
+
height?: string | number
|
|
60
|
+
/**
|
|
61
|
+
* 左侧返回图标的大小
|
|
62
|
+
* @default "20px"
|
|
63
|
+
*/
|
|
64
|
+
leftIconSize?: string | number
|
|
65
|
+
/**
|
|
66
|
+
* 左侧返回图标的颜色
|
|
67
|
+
* @default "#303133"
|
|
68
|
+
*/
|
|
69
|
+
leftIconColor?: string
|
|
70
|
+
/**
|
|
71
|
+
* 点击左侧区域(返回图标),是否自动返回上一页
|
|
72
|
+
* @default false
|
|
73
|
+
*/
|
|
74
|
+
autoBack?: boolean
|
|
75
|
+
/**
|
|
76
|
+
* 标题的样式
|
|
77
|
+
*/
|
|
78
|
+
titleStyle?: unknown
|
|
79
|
+
/**
|
|
80
|
+
* 点击左侧区域
|
|
81
|
+
*/
|
|
82
|
+
onLeftClick?: () => any
|
|
83
|
+
/**
|
|
84
|
+
* 点击右侧区域
|
|
85
|
+
*/
|
|
86
|
+
onRightClick?: () => any
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
declare interface NavbarSlots {
|
|
90
|
+
/**
|
|
91
|
+
* 自定义左侧部分内容
|
|
92
|
+
*/
|
|
93
|
+
['left']?: () => any
|
|
94
|
+
/**
|
|
95
|
+
* 自定义右侧部分内容
|
|
96
|
+
*/
|
|
97
|
+
['right']?: () => any
|
|
98
|
+
/**
|
|
99
|
+
* 自定义中部内容
|
|
100
|
+
*/
|
|
101
|
+
['center']?: () => any
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
declare interface _Navbar {
|
|
105
|
+
new (): {
|
|
106
|
+
$props: AllowedComponentProps &
|
|
107
|
+
VNodeProps &
|
|
108
|
+
NavbarProps
|
|
109
|
+
$slots: NavbarSlots
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export declare const Navbar: _Navbar
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { AllowedComponentProps, VNodeProps } from './_common'
|
|
2
|
+
|
|
3
|
+
declare interface NoNetworkProps {
|
|
4
|
+
/**
|
|
5
|
+
* 没有网络时的提示语
|
|
6
|
+
* @default "哎呀,网络信号丢失"
|
|
7
|
+
*/
|
|
8
|
+
tips?: string
|
|
9
|
+
/**
|
|
10
|
+
* 组件的`z-index`值
|
|
11
|
+
* @default 10080
|
|
12
|
+
*/
|
|
13
|
+
zIndex?: string | number
|
|
14
|
+
/**
|
|
15
|
+
* 无网络的图片提示,可用的src地址或base64图片
|
|
16
|
+
*/
|
|
17
|
+
image?: string
|
|
18
|
+
/**
|
|
19
|
+
* 用户点击页面的"重试"按钮时触发
|
|
20
|
+
*/
|
|
21
|
+
onRetry?: () => any
|
|
22
|
+
/**
|
|
23
|
+
* "重试"后,有网络触发
|
|
24
|
+
*/
|
|
25
|
+
onConnected?: () => any
|
|
26
|
+
/**
|
|
27
|
+
* "重试"后,无网络触发
|
|
28
|
+
*/
|
|
29
|
+
onDisconnected?: () => any
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
declare interface _NoNetwork {
|
|
33
|
+
new (): {
|
|
34
|
+
$props: AllowedComponentProps &
|
|
35
|
+
VNodeProps &
|
|
36
|
+
NoNetworkProps
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export declare const NoNetwork: _NoNetwork
|