@tuya-miniapp/smart-ui 2.7.4-beta-0 → 2.7.4-beta-2
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/loading/index.js
CHANGED
|
@@ -3,7 +3,6 @@ SmartComponent({
|
|
|
3
3
|
props: {
|
|
4
4
|
color: {
|
|
5
5
|
type: String,
|
|
6
|
-
value: 'var(--loading-text-color, #1989FA)',
|
|
7
6
|
},
|
|
8
7
|
vertical: Boolean,
|
|
9
8
|
type: {
|
|
@@ -15,6 +14,9 @@ SmartComponent({
|
|
|
15
14
|
value: '30',
|
|
16
15
|
},
|
|
17
16
|
textSize: String,
|
|
17
|
+
iconColor: {
|
|
18
|
+
type: String,
|
|
19
|
+
},
|
|
18
20
|
},
|
|
19
21
|
data: {
|
|
20
22
|
spinner: '',
|
|
@@ -22,8 +24,12 @@ SmartComponent({
|
|
|
22
24
|
},
|
|
23
25
|
created() {
|
|
24
26
|
this.setData({
|
|
25
|
-
spinner: this.SpinnerLoading({
|
|
26
|
-
|
|
27
|
+
spinner: this.SpinnerLoading({
|
|
28
|
+
color: this.data.color || 'var(--loading-spinner-color, #1989FA)',
|
|
29
|
+
}),
|
|
30
|
+
circular: this.CircularLoading({
|
|
31
|
+
color: this.data.color || 'var(--loading-spinner-color, #1989FA)',
|
|
32
|
+
}),
|
|
27
33
|
});
|
|
28
34
|
},
|
|
29
35
|
methods: {
|
package/dist/loading/index.wxml
CHANGED
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
<view class="custom-class {{ utils.bem('loading', { vertical }) }}">
|
|
5
5
|
<view
|
|
6
6
|
class="smart-loading__spinner smart-loading__spinner--{{ type }}"
|
|
7
|
-
style="{{ computed.loadingStyle({ size, type, color, spinner, circular }) }}"
|
|
7
|
+
style="{{ computed.loadingStyle({ iconColor, size, type, color, spinner, circular }) }}"
|
|
8
8
|
>
|
|
9
9
|
<view
|
|
10
10
|
class="smart-switch__loading"
|
|
11
|
-
style="{{ computed.loadingStyle({ size, type, color, spinner, circular }) }}"
|
|
11
|
+
style="{{ computed.loadingStyle({ iconColor, size, type, color, spinner, circular }) }}"
|
|
12
12
|
/>
|
|
13
13
|
</view>
|
|
14
14
|
<view class="smart-loading__text" style="{{ computed.textStyle({ textSize, color }) }}">
|
package/dist/loading/index.wxs
CHANGED
|
@@ -5,7 +5,7 @@ var addUnit = require('../wxs/add-unit.wxs');
|
|
|
5
5
|
function textStyle(data) {
|
|
6
6
|
var ret = style({
|
|
7
7
|
'font-size': addUnit(data.textSize),
|
|
8
|
-
color: data.color,
|
|
8
|
+
color: data.color || 'var(--loading-text-color, #1989FA)',
|
|
9
9
|
});
|
|
10
10
|
|
|
11
11
|
return ret;
|
|
@@ -28,6 +28,7 @@ function loadingStyle(data) {
|
|
|
28
28
|
'-webkit-mask-size': addUnit(data.size),
|
|
29
29
|
width: addUnit(data.size),
|
|
30
30
|
height: addUnit(data.size),
|
|
31
|
+
background: data.iconColor || data.color || 'var(--loading-spinner-color, #1989FA)',
|
|
31
32
|
});
|
|
32
33
|
|
|
33
34
|
return ret;
|
package/lib/loading/index.js
CHANGED
|
@@ -5,7 +5,6 @@ var component_1 = require("../common/component");
|
|
|
5
5
|
props: {
|
|
6
6
|
color: {
|
|
7
7
|
type: String,
|
|
8
|
-
value: 'var(--loading-text-color, #1989FA)',
|
|
9
8
|
},
|
|
10
9
|
vertical: Boolean,
|
|
11
10
|
type: {
|
|
@@ -17,6 +16,9 @@ var component_1 = require("../common/component");
|
|
|
17
16
|
value: '30',
|
|
18
17
|
},
|
|
19
18
|
textSize: String,
|
|
19
|
+
iconColor: {
|
|
20
|
+
type: String,
|
|
21
|
+
},
|
|
20
22
|
},
|
|
21
23
|
data: {
|
|
22
24
|
spinner: '',
|
|
@@ -24,8 +26,12 @@ var component_1 = require("../common/component");
|
|
|
24
26
|
},
|
|
25
27
|
created: function () {
|
|
26
28
|
this.setData({
|
|
27
|
-
spinner: this.SpinnerLoading({
|
|
28
|
-
|
|
29
|
+
spinner: this.SpinnerLoading({
|
|
30
|
+
color: this.data.color || 'var(--loading-spinner-color, #1989FA)',
|
|
31
|
+
}),
|
|
32
|
+
circular: this.CircularLoading({
|
|
33
|
+
color: this.data.color || 'var(--loading-spinner-color, #1989FA)',
|
|
34
|
+
}),
|
|
29
35
|
});
|
|
30
36
|
},
|
|
31
37
|
methods: {
|
package/lib/loading/index.wxml
CHANGED
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
<view class="custom-class {{ utils.bem('loading', { vertical }) }}">
|
|
5
5
|
<view
|
|
6
6
|
class="smart-loading__spinner smart-loading__spinner--{{ type }}"
|
|
7
|
-
style="{{ computed.loadingStyle({ size, type, color, spinner, circular }) }}"
|
|
7
|
+
style="{{ computed.loadingStyle({ iconColor, size, type, color, spinner, circular }) }}"
|
|
8
8
|
>
|
|
9
9
|
<view
|
|
10
10
|
class="smart-switch__loading"
|
|
11
|
-
style="{{ computed.loadingStyle({ size, type, color, spinner, circular }) }}"
|
|
11
|
+
style="{{ computed.loadingStyle({ iconColor, size, type, color, spinner, circular }) }}"
|
|
12
12
|
/>
|
|
13
13
|
</view>
|
|
14
14
|
<view class="smart-loading__text" style="{{ computed.textStyle({ textSize, color }) }}">
|
package/lib/loading/index.wxs
CHANGED
|
@@ -5,7 +5,7 @@ var addUnit = require('../wxs/add-unit.wxs');
|
|
|
5
5
|
function textStyle(data) {
|
|
6
6
|
var ret = style({
|
|
7
7
|
'font-size': addUnit(data.textSize),
|
|
8
|
-
color: data.color,
|
|
8
|
+
color: data.color || 'var(--loading-text-color, #1989FA)',
|
|
9
9
|
});
|
|
10
10
|
|
|
11
11
|
return ret;
|
|
@@ -28,6 +28,7 @@ function loadingStyle(data) {
|
|
|
28
28
|
'-webkit-mask-size': addUnit(data.size),
|
|
29
29
|
width: addUnit(data.size),
|
|
30
30
|
height: addUnit(data.size),
|
|
31
|
+
background: data.iconColor || data.color || 'var(--loading-spinner-color, #1989FA)',
|
|
31
32
|
});
|
|
32
33
|
|
|
33
34
|
return ret;
|