@tuya-miniapp/smart-ui 2.12.0-beta-2 → 2.12.0-beta-4
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/common/component.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { basic } from '../mixins/basic';
|
|
2
|
+
import { wrapMethodsWithPropagationCheck } from '@ray-core/event-propagation';
|
|
2
3
|
function mapKeys(source, target, map) {
|
|
3
4
|
Object.keys(map).forEach(key => {
|
|
4
5
|
if (source[key]) {
|
|
@@ -41,6 +42,9 @@ function SmartComponent(smartOptions) {
|
|
|
41
42
|
multipleSlots: true,
|
|
42
43
|
addGlobalClass: true,
|
|
43
44
|
};
|
|
45
|
+
if (options.methods) {
|
|
46
|
+
options.methods = wrapMethodsWithPropagationCheck(options.methods);
|
|
47
|
+
}
|
|
44
48
|
Component(options);
|
|
45
49
|
}
|
|
46
50
|
export { SmartComponent };
|
package/dist/dialog/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import { getCurrentPage, toPromise } from '../common/utils';
|
|
|
6
6
|
import { contextRef, queueRef } from './dialog';
|
|
7
7
|
SmartComponent({
|
|
8
8
|
mixins: [button],
|
|
9
|
-
classes: ['
|
|
9
|
+
classes: ['cancel-button-class', 'confirm-button-class'],
|
|
10
10
|
props: {
|
|
11
11
|
show: {
|
|
12
12
|
type: Boolean,
|
package/dist/dialog/index.wxml
CHANGED
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
loading="{{ loaing.cancel }}"
|
|
57
57
|
is-first
|
|
58
58
|
class="smart-dialog__button smart-hairline--right"
|
|
59
|
-
custom-class="smart-dialog__cancel
|
|
59
|
+
custom-class="smart-dialog__cancel cancel-button-class"
|
|
60
60
|
custom-style="{{ cancelButtonColor ? 'color: ' + cancelButtonColor : '' }}"
|
|
61
61
|
bind:click="onCancel"
|
|
62
62
|
>
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
size="large"
|
|
103
103
|
loading="{{ loading.cancel }}"
|
|
104
104
|
class="smart-dialog__button smart-hairline--right"
|
|
105
|
-
custom-class="smart-dialog__cancel
|
|
105
|
+
custom-class="smart-dialog__cancel cancel-button-class"
|
|
106
106
|
custom-style="color: {{ cancelButtonColor || 'var(--dialog-cancel-color, var(--app-B4-N3, rgba(0, 0, 0, 0.5)))' }}"
|
|
107
107
|
bind:click="onCancel"
|
|
108
108
|
>
|
package/lib/common/component.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.SmartComponent = void 0;
|
|
4
4
|
var basic_1 = require("../mixins/basic");
|
|
5
|
+
var event_propagation_1 = require("@ray-core/event-propagation");
|
|
5
6
|
function mapKeys(source, target, map) {
|
|
6
7
|
Object.keys(map).forEach(function (key) {
|
|
7
8
|
if (source[key]) {
|
|
@@ -44,6 +45,9 @@ function SmartComponent(smartOptions) {
|
|
|
44
45
|
multipleSlots: true,
|
|
45
46
|
addGlobalClass: true,
|
|
46
47
|
};
|
|
48
|
+
if (options.methods) {
|
|
49
|
+
options.methods = (0, event_propagation_1.wrapMethodsWithPropagationCheck)(options.methods);
|
|
50
|
+
}
|
|
47
51
|
Component(options);
|
|
48
52
|
}
|
|
49
53
|
exports.SmartComponent = SmartComponent;
|
package/lib/dialog/index.js
CHANGED
|
@@ -11,7 +11,7 @@ var utils_1 = require("../common/utils");
|
|
|
11
11
|
var dialog_1 = require("./dialog");
|
|
12
12
|
(0, component_1.SmartComponent)({
|
|
13
13
|
mixins: [button_1.button],
|
|
14
|
-
classes: ['
|
|
14
|
+
classes: ['cancel-button-class', 'confirm-button-class'],
|
|
15
15
|
props: {
|
|
16
16
|
show: {
|
|
17
17
|
type: Boolean,
|
package/lib/dialog/index.wxml
CHANGED
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
loading="{{ loaing.cancel }}"
|
|
57
57
|
is-first
|
|
58
58
|
class="smart-dialog__button smart-hairline--right"
|
|
59
|
-
custom-class="smart-dialog__cancel
|
|
59
|
+
custom-class="smart-dialog__cancel cancel-button-class"
|
|
60
60
|
custom-style="{{ cancelButtonColor ? 'color: ' + cancelButtonColor : '' }}"
|
|
61
61
|
bind:click="onCancel"
|
|
62
62
|
>
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
size="large"
|
|
103
103
|
loading="{{ loading.cancel }}"
|
|
104
104
|
class="smart-dialog__button smart-hairline--right"
|
|
105
|
-
custom-class="smart-dialog__cancel
|
|
105
|
+
custom-class="smart-dialog__cancel cancel-button-class"
|
|
106
106
|
custom-style="color: {{ cancelButtonColor || 'var(--dialog-cancel-color, var(--app-B4-N3, rgba(0, 0, 0, 0.5)))' }}"
|
|
107
107
|
bind:click="onCancel"
|
|
108
108
|
>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tuya-miniapp/smart-ui",
|
|
3
|
-
"version": "2.12.0-beta-
|
|
3
|
+
"version": "2.12.0-beta-4",
|
|
4
4
|
"author": "MiniApp Team",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"miniprogram": "lib",
|
|
@@ -88,7 +88,8 @@
|
|
|
88
88
|
],
|
|
89
89
|
"dependencies": {
|
|
90
90
|
"@ray-js/components-ty-slider": "^0.3.8",
|
|
91
|
-
"@tuya-miniapp/icons": "^2.3.0"
|
|
91
|
+
"@tuya-miniapp/icons": "^2.3.0",
|
|
92
|
+
"@ray-core/event-propagation": "^0.4.13"
|
|
92
93
|
},
|
|
93
94
|
"maintainers": [
|
|
94
95
|
{
|