hy-app 0.2.1 → 0.2.4
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-button/index.scss +2 -0
- package/components/hy-cell/index.scss +0 -15
- package/components/hy-code-input/hy-code-input.vue +224 -0
- package/components/hy-code-input/index.scss +108 -0
- package/components/hy-code-input/props.ts +21 -0
- package/components/hy-code-input/typing.d.ts +65 -0
- package/components/hy-config-provider/hy-config-provider.vue +0 -1
- package/components/hy-config-provider/props.ts +1 -1
- package/components/hy-dropdown/props.ts +1 -1
- package/components/hy-dropdown-item/hy-dropdown-item.vue +2 -5
- package/components/hy-dropdown-item/index.scss +11 -13
- package/components/hy-grid/hy-grid.vue +7 -8
- package/components/hy-grid/props.ts +4 -0
- package/components/hy-grid/typing.d.ts +15 -0
- package/components/hy-icon/index.scss +2 -1
- package/components/hy-login/TheUserLogin.vue +0 -1
- package/components/hy-menu/hy-menu.vue +159 -0
- package/components/hy-menu/index.scss +58 -0
- package/components/hy-menu/props.ts +12 -0
- package/components/hy-menu/typing.d.ts +57 -0
- package/components/hy-modal/hy-modal.vue +5 -5
- package/components/hy-modal/index.scss +0 -6
- package/components/hy-notify/hy-notify.vue +169 -0
- package/components/hy-notify/index.scss +25 -0
- package/components/hy-notify/props.ts +14 -0
- package/components/hy-notify/typing.d.ts +44 -0
- package/components/hy-pagination/hy-pagination.vue +125 -0
- package/components/hy-pagination/index.scss +46 -0
- package/components/hy-pagination/props.ts +15 -0
- package/components/hy-pagination/typing.d.ts +44 -0
- package/components/hy-picker/index.scss +4 -0
- package/components/hy-scroll-list/index.scss +1 -1
- package/components/hy-search/index.scss +1 -2
- package/components/hy-signature/canvasHelper.ts +51 -0
- package/components/hy-signature/hy-signature.vue +656 -0
- package/components/hy-signature/index.scss +29 -0
- package/components/hy-signature/props.ts +29 -0
- package/components/hy-signature/typing.d.ts +181 -0
- package/components/hy-slider/index.scss +5 -1
- package/components/hy-subsection/hy-subsection.vue +15 -13
- package/components/hy-subsection/props.ts +2 -2
- package/components/hy-subsection/typing.d.ts +1 -1
- package/components/hy-swipe-action/hy-swipe-action.vue +288 -248
- package/components/hy-swipe-action/index.scss +34 -0
- package/components/hy-swipe-action/index.ts +34 -0
- package/components/hy-swipe-action/props.ts +15 -9
- package/components/hy-swipe-action/typing.d.ts +20 -22
- package/components/hy-swiper/index.scss +5 -0
- package/components/hy-tabBar/hy-tabBar.vue +96 -0
- package/components/hy-tabBar/index.scss +169 -0
- package/components/hy-tabBar/props.ts +13 -0
- package/components/hy-tabBar/typing.d.ts +54 -0
- package/components/hy-tabs/index.scss +2 -2
- package/components/hy-tag/index.scss +1 -1
- package/components/hy-text/index.scss +2 -2
- package/components/hy-textarea/hy-textarea.vue +5 -5
- package/components/hy-textarea/index.scss +5 -6
- package/components/hy-tooltip/index.scss +2 -2
- package/components/hy-upload/index.scss +1 -2
- package/components/hy-watermark/hy-watermark.vue +603 -0
- package/components/hy-watermark/index.scss +15 -0
- package/components/hy-watermark/props.ts +23 -0
- package/components/hy-watermark/typing.d.ts +76 -0
- package/components/index.ts +2 -2
- package/composables/index.ts +1 -0
- package/composables/useTouch.ts +48 -0
- package/index.ts +1 -1
- package/libs/css/mixin.scss +52 -13
- package/libs/css/vars.css +12 -2
- package/package.json +2 -2
- package/theme.scss +24 -46
- package/typing/modules/common.d.ts +1 -1
- package/utils/inspect.ts +20 -0
- package/utils/utils.ts +52 -22
- package/components/hy-swipe-action/index.wxs +0 -235
- package/components/hy-swipe-action/wxs.js +0 -15
- package/components/yk-tabbar/props.ts +0 -49
- package/components/yk-tabbar/yk-tabbar.vue +0 -224
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
export default {
|
|
2
|
-
/**
|
|
3
|
-
* tab当前值
|
|
4
|
-
* */
|
|
5
|
-
current: 0,
|
|
6
|
-
/**
|
|
7
|
-
* 文字颜色
|
|
8
|
-
* */
|
|
9
|
-
textColor: "#FFFFFF",
|
|
10
|
-
/**
|
|
11
|
-
* 底部导航栏背景颜色
|
|
12
|
-
* 支持渐变色--linear-gradient(155deg, #192b6e, #a6307c)
|
|
13
|
-
* */
|
|
14
|
-
bgColor: "linear-gradient(155deg, #192b6e, #a6307c)",
|
|
15
|
-
/**
|
|
16
|
-
* 点击突出按钮的背景颜色
|
|
17
|
-
* 支持渐变色--linear-gradient(0deg, #ffa576,#0951eb)
|
|
18
|
-
* */
|
|
19
|
-
activeColor: "linear-gradient(0deg, #ffa576,#0951eb)",
|
|
20
|
-
/**
|
|
21
|
-
* 导航栏值
|
|
22
|
-
* {
|
|
23
|
-
* key: 唯一建值,
|
|
24
|
-
* label: 中文名,
|
|
25
|
-
* icon: uview-plus里面的矢量图标库
|
|
26
|
-
* iconUrl: 图片地址
|
|
27
|
-
* }
|
|
28
|
-
* */
|
|
29
|
-
list: [
|
|
30
|
-
{
|
|
31
|
-
key: 0,
|
|
32
|
-
label: "首页",
|
|
33
|
-
icon: "home",
|
|
34
|
-
iconUrl: ""
|
|
35
|
-
},
|
|
36
|
-
{
|
|
37
|
-
key: 1,
|
|
38
|
-
label: "工具栏",
|
|
39
|
-
icon: "grid",
|
|
40
|
-
iconUrl: ""
|
|
41
|
-
},
|
|
42
|
-
{
|
|
43
|
-
key: 2,
|
|
44
|
-
label: "我的",
|
|
45
|
-
icon: "account",
|
|
46
|
-
iconUrl: ""
|
|
47
|
-
}
|
|
48
|
-
]
|
|
49
|
-
}
|
|
@@ -1,224 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<view class="placeholder-view"></view>
|
|
3
|
-
<view class="bg">
|
|
4
|
-
<view class="custom-tabbar" :style="{'background': props.bgColor}">
|
|
5
|
-
<view class="ul">
|
|
6
|
-
<view :class="['li', 'list', current === item.key ? 'active' : '']" v-for="item in props.list" :key="item.key" @click="checkItem(item.key)">
|
|
7
|
-
<view class="bar">
|
|
8
|
-
<view class="icon">
|
|
9
|
-
<!-- <text-->
|
|
10
|
-
<!-- :class="['t-icon', `custom-t-icon-${item.icon}`]"-->
|
|
11
|
-
<!-- ></text>-->
|
|
12
|
-
<image
|
|
13
|
-
v-if="item.iconUrl"
|
|
14
|
-
:src="item.iconUrl"
|
|
15
|
-
style="height: 25px; width: 25px"
|
|
16
|
-
></image>
|
|
17
|
-
<u-icon v-else :name="item.icon" :color="props.textColor" size="25"></u-icon>
|
|
18
|
-
</view>
|
|
19
|
-
<text class="text" :style="['color:' + props.textColor]">{{ item.label }}</text>
|
|
20
|
-
<text class="circle"></text>
|
|
21
|
-
</view>
|
|
22
|
-
</view>
|
|
23
|
-
<view
|
|
24
|
-
class="indicator"
|
|
25
|
-
:style="{
|
|
26
|
-
'--num': `translateX(calc(((100vw - 110rpx - ${props.list.length} * 70rpx) / ${props.list.length - 1} + 70rpx) * ${current}))`,
|
|
27
|
-
'background': activeColor
|
|
28
|
-
}"
|
|
29
|
-
></view>
|
|
30
|
-
</view>
|
|
31
|
-
</view>
|
|
32
|
-
</view>
|
|
33
|
-
</template>
|
|
34
|
-
|
|
35
|
-
<script setup lang="ts">
|
|
36
|
-
import { ref, reactive, watch } from "vue";
|
|
37
|
-
import prop from "./props";
|
|
38
|
-
|
|
39
|
-
interface IProps {
|
|
40
|
-
current: number;
|
|
41
|
-
textColor?: string;
|
|
42
|
-
bgColor?: string;
|
|
43
|
-
activeColor?: string;
|
|
44
|
-
list: () => ([]);
|
|
45
|
-
}
|
|
46
|
-
const props = withDefaults(defineProps<IProps>(),{...prop})
|
|
47
|
-
const emit = defineEmits(['clickTab'])
|
|
48
|
-
|
|
49
|
-
const current = ref(0);
|
|
50
|
-
watch(
|
|
51
|
-
() => props.current,
|
|
52
|
-
(newVal) => {
|
|
53
|
-
current.value = newVal
|
|
54
|
-
}
|
|
55
|
-
)
|
|
56
|
-
|
|
57
|
-
const checkItem = (index: number) => {
|
|
58
|
-
current.value = index;
|
|
59
|
-
emit("clickTab", index)
|
|
60
|
-
}
|
|
61
|
-
</script>
|
|
62
|
-
|
|
63
|
-
<style lang="scss" scoped>
|
|
64
|
-
.placeholder-view {
|
|
65
|
-
height: 135rpx;
|
|
66
|
-
}
|
|
67
|
-
.bg {
|
|
68
|
-
background: #F8F8F8;
|
|
69
|
-
height: 135rpx;
|
|
70
|
-
z-index: 999;
|
|
71
|
-
position: fixed;
|
|
72
|
-
bottom: 0;
|
|
73
|
-
}
|
|
74
|
-
.custom-tabbar {
|
|
75
|
-
margin-top: 15rpx;
|
|
76
|
-
position: relative;
|
|
77
|
-
width: 100vw;
|
|
78
|
-
height: 120rpx;
|
|
79
|
-
display: flex;
|
|
80
|
-
justify-content: center;
|
|
81
|
-
align-items: center;
|
|
82
|
-
border-radius: 15rpx 15rpx 0 0;
|
|
83
|
-
padding: 0 20rpx;
|
|
84
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
85
|
-
box-sizing: border-box;
|
|
86
|
-
/* #endif */
|
|
87
|
-
.ul {
|
|
88
|
-
width: 100%;
|
|
89
|
-
display: flex;
|
|
90
|
-
justify-content: space-between;
|
|
91
|
-
align-items: center;
|
|
92
|
-
padding: 0 20rpx;
|
|
93
|
-
.li {
|
|
94
|
-
position: relative;
|
|
95
|
-
width: 100rpx;
|
|
96
|
-
height: 70rpx;
|
|
97
|
-
z-index: 1;
|
|
98
|
-
.bar {
|
|
99
|
-
position: relative;
|
|
100
|
-
display: flex;
|
|
101
|
-
justify-content: center;
|
|
102
|
-
align-items: center;
|
|
103
|
-
flex-direction: column;
|
|
104
|
-
width: 100%;
|
|
105
|
-
text-align: center;
|
|
106
|
-
font-weight: 500;
|
|
107
|
-
.icon {
|
|
108
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
109
|
-
transition: .5s;
|
|
110
|
-
/* #endif */
|
|
111
|
-
}
|
|
112
|
-
.text {
|
|
113
|
-
position: absolute;
|
|
114
|
-
font-weight: 400;
|
|
115
|
-
font-size: .75em;
|
|
116
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
117
|
-
letter-spacing: .05em;
|
|
118
|
-
transition: .5s;
|
|
119
|
-
/* #endif */
|
|
120
|
-
transform: translateY(20px) scale(0);
|
|
121
|
-
}
|
|
122
|
-
.circle {
|
|
123
|
-
position: absolute;
|
|
124
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
125
|
-
display: block;
|
|
126
|
-
/* #endif */
|
|
127
|
-
width: 75rpx;
|
|
128
|
-
height: 75rpx;
|
|
129
|
-
background: transparent;
|
|
130
|
-
border-radius: 50%;
|
|
131
|
-
border: 3rpx solid #fff;
|
|
132
|
-
transform: translateY(-70rpx) scale(0);
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
&.active {
|
|
137
|
-
.bar {
|
|
138
|
-
.icon {
|
|
139
|
-
transform: translate(2rpx, -56rpx);
|
|
140
|
-
}
|
|
141
|
-
.text {
|
|
142
|
-
opacity: 1;
|
|
143
|
-
transform: translateY(20rpx);
|
|
144
|
-
}
|
|
145
|
-
.circle {
|
|
146
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
147
|
-
margin: 0 auto;
|
|
148
|
-
transition: .5s;
|
|
149
|
-
/* #endif */
|
|
150
|
-
transition-delay: .5s;
|
|
151
|
-
transform: translate(2rpx, -56rpx) scale(1);
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
.indicator {
|
|
160
|
-
position: absolute;
|
|
161
|
-
top: -59%;
|
|
162
|
-
left: 30rpx;
|
|
163
|
-
width: 100rpx;
|
|
164
|
-
height: 100rpx;
|
|
165
|
-
border: 12rpx solid #F8F8F8;
|
|
166
|
-
border-radius: 50%;
|
|
167
|
-
display: flex;
|
|
168
|
-
justify-content: center;
|
|
169
|
-
align-items: center;
|
|
170
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
171
|
-
transition: .5s;
|
|
172
|
-
/* #endif */
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
.indicator::before {
|
|
176
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
177
|
-
content: '';
|
|
178
|
-
/* #endif */
|
|
179
|
-
position: absolute;
|
|
180
|
-
top: 59%;
|
|
181
|
-
left: -45rpx;
|
|
182
|
-
width: 50rpx;
|
|
183
|
-
height: 40rpx;
|
|
184
|
-
background: transparent;
|
|
185
|
-
border-top-right-radius: 20px;
|
|
186
|
-
box-shadow: 1px -15rpx 0 #F8F8F8;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
.indicator::after {
|
|
190
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
191
|
-
content: '';
|
|
192
|
-
/* #endif */
|
|
193
|
-
position: absolute;
|
|
194
|
-
top: 58%;
|
|
195
|
-
right: -49rpx;
|
|
196
|
-
width: 50rpx;
|
|
197
|
-
height: 40rpx;
|
|
198
|
-
background: transparent;
|
|
199
|
-
border-top-left-radius: 40rpx;
|
|
200
|
-
box-shadow: -1px -15rpx 0 #F8F8F8;
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
/* #ifndef APP-PLUS-NVUE */
|
|
204
|
-
.custom-tabbar .ul .li:nth-child(1).active~.indicator {
|
|
205
|
-
transform: var(--num);
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
.custom-tabbar .ul .li:nth-child(2).active~.indicator {
|
|
209
|
-
transform: var(--num);
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
.custom-tabbar .ul .li:nth-child(3).active~.indicator {
|
|
213
|
-
transform: var(--num);
|
|
214
|
-
}
|
|
215
|
-
|
|
216
|
-
.custom-tabbar .ul .li:nth-child(4).active~.indicator {
|
|
217
|
-
transform: var(--num);
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
.custom-tabbar .ul .li:nth-child(5).active~.indicator {
|
|
221
|
-
transform: var(--num);
|
|
222
|
-
}
|
|
223
|
-
/* #endif */
|
|
224
|
-
</style>
|