@atooyu/uxto-ui 1.1.41 → 1.1.43
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/index.js +13 -40
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +13 -40
- package/dist/index.mjs.map +1 -1
- package/dist/style.css +43 -41
- package/package.json +1 -1
- package/src/components/u-link/u-link.vue +4 -1
- package/src/components/u-tabbar/u-tabbar.vue +3 -0
- package/src/components/u-tooltip/u-tooltip.vue +12 -38
package/dist/style.css
CHANGED
|
@@ -1676,90 +1676,90 @@ to {
|
|
|
1676
1676
|
}
|
|
1677
1677
|
.u-count-down__text[data-v-da70e500] {
|
|
1678
1678
|
font-variant-numeric: tabular-nums;
|
|
1679
|
-
}.u-tooltip[data-v-
|
|
1679
|
+
}.u-tooltip[data-v-0985db7a] {
|
|
1680
1680
|
position: relative;
|
|
1681
1681
|
display: inline-block;
|
|
1682
1682
|
}
|
|
1683
|
-
.u-tooltip--active[data-v-
|
|
1683
|
+
.u-tooltip--active[data-v-0985db7a] {
|
|
1684
1684
|
z-index: 999;
|
|
1685
1685
|
}
|
|
1686
|
-
.u-tooltip__trigger[data-v-
|
|
1686
|
+
.u-tooltip__trigger[data-v-0985db7a] {
|
|
1687
1687
|
display: inline;
|
|
1688
1688
|
transition: background-color 0.15s;
|
|
1689
1689
|
}
|
|
1690
|
-
.u-tooltip__trigger--highlight[data-v-
|
|
1690
|
+
.u-tooltip__trigger--highlight[data-v-0985db7a] {
|
|
1691
1691
|
border-radius: 2px;
|
|
1692
1692
|
}
|
|
1693
|
-
.u-tooltip__popup[data-v-
|
|
1693
|
+
.u-tooltip__popup[data-v-0985db7a] {
|
|
1694
1694
|
position: absolute;
|
|
1695
1695
|
z-index: 1000;
|
|
1696
1696
|
padding: 8px 12px;
|
|
1697
1697
|
background: #323233;
|
|
1698
1698
|
border-radius: 8px;
|
|
1699
1699
|
white-space: nowrap;
|
|
1700
|
-
animation: u-tooltip-fade-in-
|
|
1700
|
+
animation: u-tooltip-fade-in-0985db7a 0.15s ease-out;
|
|
1701
1701
|
}
|
|
1702
|
-
.u-tooltip__popup--top[data-v-
|
|
1702
|
+
.u-tooltip__popup--top[data-v-0985db7a] {
|
|
1703
1703
|
bottom: 100%;
|
|
1704
1704
|
left: 50%;
|
|
1705
1705
|
transform: translateX(-50%);
|
|
1706
1706
|
margin-bottom: 8px;
|
|
1707
1707
|
}
|
|
1708
|
-
.u-tooltip__popup--bottom[data-v-
|
|
1708
|
+
.u-tooltip__popup--bottom[data-v-0985db7a] {
|
|
1709
1709
|
top: 100%;
|
|
1710
1710
|
left: 50%;
|
|
1711
1711
|
transform: translateX(-50%);
|
|
1712
1712
|
margin-top: 8px;
|
|
1713
1713
|
}
|
|
1714
|
-
.u-tooltip__arrow[data-v-
|
|
1714
|
+
.u-tooltip__arrow[data-v-0985db7a] {
|
|
1715
1715
|
position: absolute;
|
|
1716
1716
|
width: 0;
|
|
1717
1717
|
height: 0;
|
|
1718
1718
|
border: 6px solid transparent;
|
|
1719
1719
|
}
|
|
1720
|
-
.u-tooltip__arrow--top[data-v-
|
|
1720
|
+
.u-tooltip__arrow--top[data-v-0985db7a] {
|
|
1721
1721
|
bottom: -12px;
|
|
1722
1722
|
left: 50%;
|
|
1723
1723
|
transform: translateX(-50%);
|
|
1724
1724
|
border-top-color: #323233;
|
|
1725
1725
|
border-bottom: none;
|
|
1726
1726
|
}
|
|
1727
|
-
.u-tooltip__arrow--bottom[data-v-
|
|
1727
|
+
.u-tooltip__arrow--bottom[data-v-0985db7a] {
|
|
1728
1728
|
top: -12px;
|
|
1729
1729
|
left: 50%;
|
|
1730
1730
|
transform: translateX(-50%);
|
|
1731
1731
|
border-bottom-color: #323233;
|
|
1732
1732
|
border-top: none;
|
|
1733
1733
|
}
|
|
1734
|
-
.u-tooltip__content[data-v-
|
|
1734
|
+
.u-tooltip__content[data-v-0985db7a] {
|
|
1735
1735
|
display: flex;
|
|
1736
1736
|
align-items: center;
|
|
1737
1737
|
}
|
|
1738
|
-
.u-tooltip__text[data-v-
|
|
1738
|
+
.u-tooltip__text[data-v-0985db7a] {
|
|
1739
1739
|
font-size: 14px;
|
|
1740
1740
|
color: #fff;
|
|
1741
1741
|
line-height: 1.4;
|
|
1742
1742
|
}
|
|
1743
|
-
.u-tooltip__actions[data-v-
|
|
1743
|
+
.u-tooltip__actions[data-v-0985db7a] {
|
|
1744
1744
|
display: flex;
|
|
1745
1745
|
gap: 16px;
|
|
1746
1746
|
}
|
|
1747
|
-
.u-tooltip__action[data-v-
|
|
1747
|
+
.u-tooltip__action[data-v-0985db7a] {
|
|
1748
1748
|
display: flex;
|
|
1749
1749
|
align-items: center;
|
|
1750
1750
|
padding: 4px 0;
|
|
1751
1751
|
}
|
|
1752
|
-
.u-tooltip__action--disabled[data-v-
|
|
1752
|
+
.u-tooltip__action--disabled[data-v-0985db7a] {
|
|
1753
1753
|
opacity: 0.5;
|
|
1754
1754
|
}
|
|
1755
|
-
.u-tooltip__action[data-v-
|
|
1755
|
+
.u-tooltip__action[data-v-0985db7a]:not(.u-tooltip__action--disabled):active {
|
|
1756
1756
|
opacity: 0.7;
|
|
1757
1757
|
}
|
|
1758
|
-
.u-tooltip__action-text[data-v-
|
|
1758
|
+
.u-tooltip__action-text[data-v-0985db7a] {
|
|
1759
1759
|
font-size: 14px;
|
|
1760
1760
|
color: #fff;
|
|
1761
1761
|
}
|
|
1762
|
-
@keyframes u-tooltip-fade-in-
|
|
1762
|
+
@keyframes u-tooltip-fade-in-0985db7a {
|
|
1763
1763
|
from {
|
|
1764
1764
|
opacity: 0;
|
|
1765
1765
|
transform: translateX(-50%) scale(0.9);
|
|
@@ -2332,31 +2332,31 @@ to {
|
|
|
2332
2332
|
.u-transition--zoom-fade-leave[data-v-13f0f85c] {
|
|
2333
2333
|
opacity: 0;
|
|
2334
2334
|
transform: scale(0.5);
|
|
2335
|
-
}.u-link[data-v-
|
|
2335
|
+
}.u-link[data-v-30210bda] {
|
|
2336
2336
|
display: inline;
|
|
2337
2337
|
color: #646566;
|
|
2338
2338
|
font-size: inherit;
|
|
2339
2339
|
word-break: break-all;
|
|
2340
2340
|
}
|
|
2341
|
-
.u-link--default[data-v-
|
|
2341
|
+
.u-link--default[data-v-30210bda] {
|
|
2342
2342
|
color: #646566;
|
|
2343
2343
|
}
|
|
2344
|
-
.u-link--primary[data-v-
|
|
2344
|
+
.u-link--primary[data-v-30210bda] {
|
|
2345
2345
|
color: #00a29a;
|
|
2346
2346
|
}
|
|
2347
|
-
.u-link--success[data-v-
|
|
2347
|
+
.u-link--success[data-v-30210bda] {
|
|
2348
2348
|
color: #07c160;
|
|
2349
2349
|
}
|
|
2350
|
-
.u-link--warning[data-v-
|
|
2350
|
+
.u-link--warning[data-v-30210bda] {
|
|
2351
2351
|
color: #ff976a;
|
|
2352
2352
|
}
|
|
2353
|
-
.u-link--danger[data-v-
|
|
2353
|
+
.u-link--danger[data-v-30210bda] {
|
|
2354
2354
|
color: #ee0a24;
|
|
2355
2355
|
}
|
|
2356
|
-
.u-link--underline[data-v-
|
|
2356
|
+
.u-link--underline[data-v-30210bda] {
|
|
2357
2357
|
text-decoration: underline;
|
|
2358
2358
|
}
|
|
2359
|
-
.u-link--disabled[data-v-
|
|
2359
|
+
.u-link--disabled[data-v-30210bda] {
|
|
2360
2360
|
color: #969799;
|
|
2361
2361
|
opacity: 0.5;
|
|
2362
2362
|
}.u-read-more__content[data-v-b31720eb] {
|
|
@@ -2380,7 +2380,7 @@ to {
|
|
|
2380
2380
|
}
|
|
2381
2381
|
.u-read-more__toggle-icon[data-v-b31720eb] {
|
|
2382
2382
|
font-size: 12px;
|
|
2383
|
-
}.u-tabbar[data-v-
|
|
2383
|
+
}.u-tabbar[data-v-9b76f6cf] {
|
|
2384
2384
|
position: fixed;
|
|
2385
2385
|
left: 0;
|
|
2386
2386
|
right: 0;
|
|
@@ -2388,8 +2388,10 @@ to {
|
|
|
2388
2388
|
z-index: 999;
|
|
2389
2389
|
width: 100%;
|
|
2390
2390
|
pointer-events: none;
|
|
2391
|
+
padding-bottom: constant(safe-area-inset-bottom);
|
|
2392
|
+
padding-bottom: env(safe-area-inset-bottom);
|
|
2391
2393
|
}
|
|
2392
|
-
.u-tabbar__nav-wrap[data-v-
|
|
2394
|
+
.u-tabbar__nav-wrap[data-v-9b76f6cf] {
|
|
2393
2395
|
pointer-events: auto;
|
|
2394
2396
|
position: absolute;
|
|
2395
2397
|
left: 14px;
|
|
@@ -2406,7 +2408,7 @@ to {
|
|
|
2406
2408
|
padding: 0 8px;
|
|
2407
2409
|
box-sizing: border-box;
|
|
2408
2410
|
}
|
|
2409
|
-
.u-tabbar__tab-btn[data-v-
|
|
2411
|
+
.u-tabbar__tab-btn[data-v-9b76f6cf] {
|
|
2410
2412
|
height: 40px;
|
|
2411
2413
|
border-radius: 20px;
|
|
2412
2414
|
background: transparent;
|
|
@@ -2421,23 +2423,23 @@ to {
|
|
|
2421
2423
|
padding: 0 16px;
|
|
2422
2424
|
margin: 0 20px;
|
|
2423
2425
|
}
|
|
2424
|
-
.u-tabbar__tab-btn--active[data-v-
|
|
2426
|
+
.u-tabbar__tab-btn--active[data-v-9b76f6cf] {
|
|
2425
2427
|
background: #ffffff;
|
|
2426
2428
|
box-shadow: inset 0 0 0 1px rgba(17, 135, 128, 0.14);
|
|
2427
2429
|
}
|
|
2428
|
-
.u-tabbar__tab-text[data-v-
|
|
2430
|
+
.u-tabbar__tab-text[data-v-9b76f6cf] {
|
|
2429
2431
|
font-weight: 600;
|
|
2430
2432
|
font-size: 14px;
|
|
2431
2433
|
overflow: hidden;
|
|
2432
2434
|
text-overflow: ellipsis;
|
|
2433
2435
|
}
|
|
2434
|
-
.u-tabbar__center[data-v-
|
|
2436
|
+
.u-tabbar__center[data-v-9b76f6cf] {
|
|
2435
2437
|
position: relative;
|
|
2436
2438
|
width: 72px;
|
|
2437
2439
|
height: 56px;
|
|
2438
2440
|
flex-shrink: 0;
|
|
2439
2441
|
}
|
|
2440
|
-
.u-tabbar__center-btn[data-v-
|
|
2442
|
+
.u-tabbar__center-btn[data-v-9b76f6cf] {
|
|
2441
2443
|
position: absolute;
|
|
2442
2444
|
left: 50%;
|
|
2443
2445
|
top: -22px;
|
|
@@ -2455,29 +2457,29 @@ to {
|
|
|
2455
2457
|
box-shadow: 0 8px 20px rgba(8, 112, 106, 0.25);
|
|
2456
2458
|
transition: all 200ms ease;
|
|
2457
2459
|
}
|
|
2458
|
-
.u-tabbar__center-btn[data-v-
|
|
2460
|
+
.u-tabbar__center-btn[data-v-9b76f6cf]:active {
|
|
2459
2461
|
transform: translateX(-50%) scale(0.95);
|
|
2460
2462
|
}
|
|
2461
|
-
.u-tabbar__center-btn--active[data-v-
|
|
2463
|
+
.u-tabbar__center-btn--active[data-v-9b76f6cf] {
|
|
2462
2464
|
border-color: #12b6af;
|
|
2463
2465
|
box-shadow: 0 8px 24px rgba(8, 112, 106, 0.35);
|
|
2464
2466
|
}
|
|
2465
|
-
.u-tabbar__center-btn--side-active[data-v-
|
|
2467
|
+
.u-tabbar__center-btn--side-active[data-v-9b76f6cf] {
|
|
2466
2468
|
background: linear-gradient(135deg, #12b6af 0%, #65d8d1 100%);
|
|
2467
2469
|
border-color: #9fe4dd;
|
|
2468
2470
|
}
|
|
2469
|
-
.u-tabbar__center-btn--side-active .u-tabbar__center-brand[data-v-
|
|
2470
|
-
.u-tabbar__center-btn--side-active .u-tabbar__center-text[data-v-
|
|
2471
|
+
.u-tabbar__center-btn--side-active .u-tabbar__center-brand[data-v-9b76f6cf],
|
|
2472
|
+
.u-tabbar__center-btn--side-active .u-tabbar__center-text[data-v-9b76f6cf] {
|
|
2471
2473
|
color: #ffffff;
|
|
2472
2474
|
}
|
|
2473
|
-
.u-tabbar__center-brand[data-v-
|
|
2475
|
+
.u-tabbar__center-brand[data-v-9b76f6cf] {
|
|
2474
2476
|
font-size: 22px;
|
|
2475
2477
|
line-height: 1;
|
|
2476
2478
|
font-weight: 700;
|
|
2477
2479
|
color: #12b6af;
|
|
2478
2480
|
letter-spacing: 1px;
|
|
2479
2481
|
}
|
|
2480
|
-
.u-tabbar__center-text[data-v-
|
|
2482
|
+
.u-tabbar__center-text[data-v-9b76f6cf] {
|
|
2481
2483
|
font-size: 12px;
|
|
2482
2484
|
letter-spacing: 0.5px;
|
|
2483
2485
|
color: #12b6af;
|
package/package.json
CHANGED
|
@@ -55,10 +55,13 @@ const handleClick = () => {
|
|
|
55
55
|
|
|
56
56
|
if (props.href) {
|
|
57
57
|
// 在新窗口打开链接
|
|
58
|
-
// uni-app 环境下使用特定方法
|
|
59
58
|
// #ifdef H5
|
|
60
59
|
window.open(props.href, '_blank')
|
|
61
60
|
// #endif
|
|
61
|
+
// #ifndef H5
|
|
62
|
+
// 非 H5 平台使用 webview 打开外部链接
|
|
63
|
+
uni.navigateTo({ url: `/pages/webview/index?url=${encodeURIComponent(props.href)}` })
|
|
64
|
+
// #endif
|
|
62
65
|
}
|
|
63
66
|
|
|
64
67
|
emit('click')
|
|
@@ -172,33 +172,18 @@ const hide = () => {
|
|
|
172
172
|
}
|
|
173
173
|
|
|
174
174
|
const adjustPlacement = () => {
|
|
175
|
-
//
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
} else if (props.placement === 'bottom' && spaceBelow < 50) {
|
|
186
|
-
actualPlacement.value = 'top'
|
|
187
|
-
} else {
|
|
188
|
-
actualPlacement.value = props.placement
|
|
189
|
-
}
|
|
175
|
+
// 使用 uni-app API 获取窗口高度(跨平台兼容)
|
|
176
|
+
const systemInfo = uni.getSystemInfoSync()
|
|
177
|
+
const windowHeight = systemInfo.windowHeight
|
|
178
|
+
const spaceAbove = triggerRect.top
|
|
179
|
+
const spaceBelow = windowHeight - triggerRect.bottom
|
|
180
|
+
|
|
181
|
+
if (props.placement === 'top' && spaceAbove < 50) {
|
|
182
|
+
actualPlacement.value = 'bottom'
|
|
183
|
+
} else if (props.placement === 'bottom' && spaceBelow < 50) {
|
|
184
|
+
actualPlacement.value = 'top'
|
|
190
185
|
} else {
|
|
191
|
-
|
|
192
|
-
const spaceAbove = triggerRect.top
|
|
193
|
-
const spaceBelow = windowHeight - triggerRect.bottom
|
|
194
|
-
|
|
195
|
-
if (props.placement === 'top' && spaceAbove < 50) {
|
|
196
|
-
actualPlacement.value = 'bottom'
|
|
197
|
-
} else if (props.placement === 'bottom' && spaceBelow < 50) {
|
|
198
|
-
actualPlacement.value = 'top'
|
|
199
|
-
} else {
|
|
200
|
-
actualPlacement.value = props.placement
|
|
201
|
-
}
|
|
186
|
+
actualPlacement.value = props.placement
|
|
202
187
|
}
|
|
203
188
|
}
|
|
204
189
|
|
|
@@ -215,21 +200,10 @@ const handleClickOutside = (event: TouchEvent | MouseEvent) => {
|
|
|
215
200
|
}
|
|
216
201
|
|
|
217
202
|
onMounted(() => {
|
|
218
|
-
|
|
219
|
-
// uni-app 中使用页面生命周期事件处理
|
|
220
|
-
} else {
|
|
221
|
-
document.addEventListener('click', handleClickOutside)
|
|
222
|
-
document.addEventListener('touchstart', handleClickOutside)
|
|
223
|
-
}
|
|
203
|
+
// uni-app 中不需要手动添加点击外部监听,使用页面事件处理
|
|
224
204
|
})
|
|
225
205
|
|
|
226
206
|
onUnmounted(() => {
|
|
227
|
-
if (isUniApp) {
|
|
228
|
-
// uni-app 清理
|
|
229
|
-
} else {
|
|
230
|
-
document.removeEventListener('click', handleClickOutside)
|
|
231
|
-
document.removeEventListener('touchstart', handleClickOutside)
|
|
232
|
-
}
|
|
233
207
|
if (hideTimer) {
|
|
234
208
|
clearTimeout(hideTimer)
|
|
235
209
|
}
|