sadais-piui 1.2.7-beta83 → 1.2.7-beta85

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.
@@ -2,7 +2,13 @@
2
2
  <view class="badge-wrap" :style="[customStyle]" :class="[customClass]" @tap="handleClick">
3
3
  <view
4
4
  class="badge"
5
- :class="[{ dot, abso: $slots.default || $slots.$default }]"
5
+ :class="[
6
+ {
7
+ dot,
8
+ 'abso': $slots.default || $slots.$default,
9
+ 'hide-border': !dot && !getContent && !($slots.content || $slots.$content)
10
+ }
11
+ ]"
6
12
  :style="[badgeStyle]"
7
13
  >
8
14
  <slot name="content">
@@ -119,6 +125,10 @@ export default {
119
125
  border: 1px solid #ffffff;
120
126
  border-radius: 16px;
121
127
 
128
+ &.hide-border {
129
+ border: none;
130
+ }
131
+
122
132
  &.dot {
123
133
  min-width: 0;
124
134
  background-color: #ee0a24;
@@ -324,7 +324,7 @@ export default {
324
324
  if (closeIconRect && closeIconRect.width) {
325
325
  this.closeIconWidth = closeIconRect.width
326
326
  }
327
- console.log(TAG, '计算.pi-icon宽度', this.closeIconWidth)
327
+ // console.log(TAG, '计算.pi-icon宽度', this.closeIconWidth)
328
328
  }
329
329
  },
330
330
  handleItemClick(e) {
@@ -222,6 +222,7 @@ export default {
222
222
  borderRadius: this.getBorderRadius,
223
223
  borderWidth: this.getBorder
224
224
  }
225
+
225
226
  if (this.getActiveColor && this.val) {
226
227
  style.borderColor = this.getActiveColor
227
228
  if (['text', 'button'].includes(this.getShape) && this.getActiveMode === 'fill') {
@@ -297,10 +298,9 @@ $unactive-color: #cccccc;
297
298
  transition-property: border, color, background-color;
298
299
  &.text {
299
300
  padding: 12rpx 24rpx;
300
-
301
- color: $unactive-color;
302
301
  border-color: transparent;
303
302
  border-style: solid;
303
+ background-color: #f5f5f5;
304
304
  }
305
305
  &.button {
306
306
  padding: 24rpx;
@@ -331,9 +331,6 @@ $unactive-color: #cccccc;
331
331
  }
332
332
  }
333
333
  &.line {
334
- .radio-label.text {
335
- border-color: $unactive-color;
336
- }
337
334
  .radio-label.button {
338
335
  border-color: $unactive-color;
339
336
  }
@@ -204,6 +204,24 @@ export default {
204
204
  }
205
205
  }
206
206
 
207
+ &.text {
208
+ /* #ifndef MP */
209
+ ::v-deep .pi-radio-wrap {
210
+ .radio-label.text {
211
+ margin-right: 24rpx;
212
+ }
213
+ }
214
+ /* #endif */
215
+ /* #ifdef MP */
216
+ ::v-deep pi-radio {
217
+ /* stylint-disable */
218
+ &:not(:last-child) {
219
+ margin-right: 24rpx;
220
+ }
221
+ }
222
+ /* #endif */
223
+ }
224
+
207
225
  // 按钮样式
208
226
  &.button {
209
227
  flex-direction: row;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sadais-piui",
3
- "version": "1.2.7-beta83",
3
+ "version": "1.2.7-beta85",
4
4
  "description": "piui组件库",
5
5
  "main": "index.js",
6
6
  "scripts": {