@tuya-miniapp/smart-ui 0.0.1-beta-4 → 0.0.1-beta-5
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/radio/index.js +2 -0
- package/dist/radio/index.wxml +2 -1
- package/dist/stepper/index.wxml +2 -2
- package/lib/radio/index.js +5 -0
- package/lib/radio/index.wxml +2 -1
- package/lib/stepper/index.wxml +2 -2
- package/package.json +1 -1
package/dist/radio/index.js
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
import CheckMarkIcon from '@tuya-miniapp/icons/dist/svg/Checkmark';
|
1
2
|
import { canIUseModel } from '../common/version';
|
2
3
|
import { VantComponent } from '../common/component';
|
3
4
|
import { useParent } from '../common/relation';
|
@@ -30,6 +31,7 @@ VantComponent({
|
|
30
31
|
data: {
|
31
32
|
direction: '',
|
32
33
|
parentDisabled: false,
|
34
|
+
icon: CheckMarkIcon,
|
33
35
|
},
|
34
36
|
methods: {
|
35
37
|
updateFromParent() {
|
package/dist/radio/index.wxml
CHANGED
@@ -13,7 +13,8 @@
|
|
13
13
|
<slot wx:if="{{ useIconSlot }}" name="icon" />
|
14
14
|
<van-icon
|
15
15
|
wx:else
|
16
|
-
name="
|
16
|
+
name="{{ icon }}"
|
17
|
+
color="{{ value ? '#fff' : 'none'}}"
|
17
18
|
class="{{ utils.bem('radio__icon', [shape, { disabled: disabled || parentDisabled, checked: value === name }]) }}"
|
18
19
|
style="{{ computed.iconStyle({ iconSize, checkedColor, disabled, parentDisabled, value, name }) }}"
|
19
20
|
custom-class="icon-class"
|
package/dist/stepper/index.wxml
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
wx:if="{{ showMinus }}"
|
7
7
|
data-type="minus"
|
8
8
|
style="{{ computed.buttonStyle({ buttonSize }) }}"
|
9
|
-
class="minus-class {{ utils.bem('stepper__minus', { disabled: disabled || disableMinus || currentValue <= min }) }}"
|
9
|
+
class="minus-class {{ utils.bem('stepper__minus', { disabled: disabled || disableMinus || currentValue <= +min }) }}"
|
10
10
|
hover-class="van-stepper__minus--hover"
|
11
11
|
hover-stay-time="70"
|
12
12
|
bind:tap="onTap"
|
@@ -31,7 +31,7 @@
|
|
31
31
|
wx:if="{{ showPlus }}"
|
32
32
|
data-type="plus"
|
33
33
|
style="{{ computed.buttonStyle({ buttonSize }) }}"
|
34
|
-
class="plus-class {{ utils.bem('stepper__plus', { disabled: disabled || disablePlus || currentValue >= max }) }}"
|
34
|
+
class="plus-class {{ utils.bem('stepper__plus', { disabled: disabled || disablePlus || currentValue >= +max }) }}"
|
35
35
|
hover-class="van-stepper__plus--hover"
|
36
36
|
hover-stay-time="70"
|
37
37
|
bind:tap="onTap"
|
package/lib/radio/index.js
CHANGED
@@ -1,5 +1,9 @@
|
|
1
1
|
"use strict";
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
+
};
|
2
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
var Checkmark_1 = __importDefault(require("@tuya-miniapp/icons/dist/svg/Checkmark"));
|
3
7
|
var version_1 = require("../common/version");
|
4
8
|
var component_1 = require("../common/component");
|
5
9
|
var relation_1 = require("../common/relation");
|
@@ -32,6 +36,7 @@ var relation_1 = require("../common/relation");
|
|
32
36
|
data: {
|
33
37
|
direction: '',
|
34
38
|
parentDisabled: false,
|
39
|
+
icon: Checkmark_1.default,
|
35
40
|
},
|
36
41
|
methods: {
|
37
42
|
updateFromParent: function () {
|
package/lib/radio/index.wxml
CHANGED
@@ -13,7 +13,8 @@
|
|
13
13
|
<slot wx:if="{{ useIconSlot }}" name="icon" />
|
14
14
|
<van-icon
|
15
15
|
wx:else
|
16
|
-
name="
|
16
|
+
name="{{ icon }}"
|
17
|
+
color="{{ value ? '#fff' : 'none'}}"
|
17
18
|
class="{{ utils.bem('radio__icon', [shape, { disabled: disabled || parentDisabled, checked: value === name }]) }}"
|
18
19
|
style="{{ computed.iconStyle({ iconSize, checkedColor, disabled, parentDisabled, value, name }) }}"
|
19
20
|
custom-class="icon-class"
|
package/lib/stepper/index.wxml
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
wx:if="{{ showMinus }}"
|
7
7
|
data-type="minus"
|
8
8
|
style="{{ computed.buttonStyle({ buttonSize }) }}"
|
9
|
-
class="minus-class {{ utils.bem('stepper__minus', { disabled: disabled || disableMinus || currentValue <= min }) }}"
|
9
|
+
class="minus-class {{ utils.bem('stepper__minus', { disabled: disabled || disableMinus || currentValue <= +min }) }}"
|
10
10
|
hover-class="van-stepper__minus--hover"
|
11
11
|
hover-stay-time="70"
|
12
12
|
bind:tap="onTap"
|
@@ -31,7 +31,7 @@
|
|
31
31
|
wx:if="{{ showPlus }}"
|
32
32
|
data-type="plus"
|
33
33
|
style="{{ computed.buttonStyle({ buttonSize }) }}"
|
34
|
-
class="plus-class {{ utils.bem('stepper__plus', { disabled: disabled || disablePlus || currentValue >= max }) }}"
|
34
|
+
class="plus-class {{ utils.bem('stepper__plus', { disabled: disabled || disablePlus || currentValue >= +max }) }}"
|
35
35
|
hover-class="van-stepper__plus--hover"
|
36
36
|
hover-stay-time="70"
|
37
37
|
bind:tap="onTap"
|