@bi-nova/ui-weapp 1.2.1 → 1.3.0-beta.202609181052

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.
@@ -0,0 +1,6 @@
1
+ {
2
+ "component": true,
3
+ "usingComponents": {
4
+ "bi-product-overlay": "../overlay/index"
5
+ }
6
+ }
@@ -0,0 +1,64 @@
1
+ <!--
2
+ @Description 产品投放位底部半屏组件模板
3
+ @Author wutao
4
+ @Date 2026-09-08
5
+ @LastEditors wutao
6
+ @LastEditTime 2026-09-14 14:44:07
7
+ -->
8
+ <bi-product-overlay
9
+ show="{{true}}"
10
+ position="bottom"
11
+ mask-closable="{{panelStyle.maskClosable}}"
12
+ z-index="{{zIndex}}"
13
+ bind:maskclose="handleMaskClose"
14
+ >
15
+ <view
16
+ class="bi-product-half-screen {{panelStyle.skinClass}}"
17
+ style="height: {{panelHeight}}vh;"
18
+ >
19
+ <view class="bi-product-half-screen__header">
20
+ <view class="bi-product-half-screen__drag-indicator"></view>
21
+ <button
22
+ wx:if="{{panelStyle.closeable}}"
23
+ class="bi-product-half-screen__close"
24
+ aria-label="关闭产品半屏"
25
+ catchtap="handleClose"
26
+ >×</button>
27
+ </view>
28
+
29
+ <scroll-view
30
+ class="bi-product-half-screen__scroll"
31
+ data-source="surface"
32
+ scroll-y="{{true}}"
33
+ enhanced="{{true}}"
34
+ bindtap="handleAction"
35
+ >
36
+ <image
37
+ wx:if="{{creative.imageUrl}}"
38
+ class="bi-product-half-screen__image"
39
+ src="{{creative.imageUrl}}"
40
+ mode="widthFix"
41
+ bindload="handleImageLoad"
42
+ binderror="handleImageError"
43
+ />
44
+
45
+ <view class="bi-product-half-screen__body">
46
+ <text wx:if="{{creative.badgeText}}" class="bi-product-half-screen__badge">{{creative.badgeText}}</text>
47
+ <text wx:if="{{creative.title}}" class="bi-product-half-screen__title">{{creative.title}}</text>
48
+ <text wx:if="{{creative.description}}" class="bi-product-half-screen__description">{{creative.description}}</text>
49
+ </view>
50
+ </scroll-view>
51
+
52
+ <view wx:if="{{creative.buttonText}}" class="bi-product-half-screen__footer">
53
+ <button
54
+ class="bi-product-half-screen__button {{!actionable || actionLoading ? 'bi-product-half-screen__button--disabled' : ''}}"
55
+ data-source="button"
56
+ loading="{{actionLoading}}"
57
+ disabled="{{!actionable || actionLoading}}"
58
+ catchtap="handleAction"
59
+ >
60
+ {{creative.buttonText}}
61
+ </button>
62
+ </view>
63
+ </view>
64
+ </bi-product-overlay>
@@ -0,0 +1,145 @@
1
+ /*
2
+ * @Description 产品投放位底部半屏组件样式
3
+ * @Author wutao
4
+ * @Date 2026-09-08
5
+ * @LastEditors wutao
6
+ * @LastEditTime 2026-09-14 14:44:07
7
+ */
8
+ .bi-product-half-screen {
9
+ display: flex;
10
+ overflow: hidden;
11
+ box-sizing: border-box;
12
+ width: 100%;
13
+ min-height: 40vh;
14
+ max-height: 85vh;
15
+ border-radius: 32rpx 32rpx 0 0;
16
+ background: #ffffff;
17
+ box-shadow: 0 -16rpx 48rpx rgba(0, 0, 0, 0.16);
18
+ flex-direction: column;
19
+ animation: bi-product-half-screen-enter 240ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
20
+ }
21
+
22
+ .bi-product-half-screen__header {
23
+ position: relative;
24
+ display: flex;
25
+ flex: 0 0 64rpx;
26
+ align-items: center;
27
+ justify-content: center;
28
+ }
29
+
30
+ .bi-product-half-screen__drag-indicator {
31
+ width: 72rpx;
32
+ height: 8rpx;
33
+ border-radius: 4rpx;
34
+ background: #d8dbe0;
35
+ }
36
+
37
+ .bi-product-half-screen__close {
38
+ position: absolute;
39
+ top: 10rpx;
40
+ right: 24rpx;
41
+ width: 52rpx;
42
+ height: 52rpx;
43
+ margin: 0;
44
+ padding: 0;
45
+ border-radius: 50%;
46
+ background: #f2f3f5;
47
+ color: #646a73;
48
+ font-size: 36rpx;
49
+ font-weight: 300;
50
+ line-height: 48rpx;
51
+ }
52
+
53
+ .bi-product-half-screen__close::after,
54
+ .bi-product-half-screen__button::after {
55
+ border: none;
56
+ }
57
+
58
+ .bi-product-half-screen__scroll {
59
+ flex: 1;
60
+ min-height: 0;
61
+ }
62
+
63
+ .bi-product-half-screen__image {
64
+ display: block;
65
+ width: 100%;
66
+ height: auto;
67
+ }
68
+
69
+ .bi-product-half-screen__body {
70
+ display: flex;
71
+ box-sizing: border-box;
72
+ padding: 24rpx 40rpx 40rpx;
73
+ flex-direction: column;
74
+ }
75
+
76
+ .bi-product-half-screen__badge {
77
+ align-self: flex-start;
78
+ margin-bottom: 16rpx;
79
+ padding: 4rpx 14rpx;
80
+ border-radius: 8rpx;
81
+ background: #fff0e8;
82
+ color: #fa541c;
83
+ font-size: 22rpx;
84
+ line-height: 34rpx;
85
+ }
86
+
87
+ .bi-product-half-screen__title {
88
+ color: #1f2329;
89
+ font-size: 38rpx;
90
+ font-weight: 600;
91
+ line-height: 54rpx;
92
+ }
93
+
94
+ .bi-product-half-screen__description {
95
+ margin-top: 16rpx;
96
+ color: #646a73;
97
+ font-size: 28rpx;
98
+ line-height: 44rpx;
99
+ }
100
+
101
+ .bi-product-half-screen__footer {
102
+ flex: 0 0 auto;
103
+ box-sizing: border-box;
104
+ padding: 20rpx 40rpx calc(20rpx + env(safe-area-inset-bottom));
105
+ border-top: 1rpx solid #f0f1f2;
106
+ background: #ffffff;
107
+ }
108
+
109
+ .bi-product-half-screen__button {
110
+ box-sizing: border-box;
111
+ width: 100%;
112
+ height: 88rpx;
113
+ margin: 0;
114
+ padding: 0 32rpx;
115
+ border-radius: 44rpx;
116
+ background: #1677ff;
117
+ color: #ffffff;
118
+ font-size: 30rpx;
119
+ font-weight: 600;
120
+ line-height: 88rpx;
121
+ }
122
+
123
+ .bi-product-skin--vip-gold .bi-product-half-screen__button {
124
+ background: linear-gradient(135deg, #efc77e 0%, #b8893f 100%);
125
+ color: #35230b;
126
+ }
127
+
128
+ .bi-product-skin--insurance-blue .bi-product-half-screen__button {
129
+ background: #246bfd;
130
+ }
131
+
132
+ .bi-product-half-screen__button.bi-product-half-screen__button--disabled {
133
+ background: #a9c9f7;
134
+ color: rgba(255, 255, 255, 0.9);
135
+ }
136
+
137
+ @keyframes bi-product-half-screen-enter {
138
+ from {
139
+ transform: translateY(100%);
140
+ }
141
+
142
+ to {
143
+ transform: translateY(0);
144
+ }
145
+ }