wave-ui 1.45.13 → 1.45.14
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/wave-ui.es.js
CHANGED
|
@@ -3093,20 +3093,21 @@ const __vue2_script$s = {
|
|
|
3093
3093
|
return this.transition || "scale-fade";
|
|
3094
3094
|
},
|
|
3095
3095
|
detachToTarget() {
|
|
3096
|
-
|
|
3096
|
+
const defaultTarget = ".w-app";
|
|
3097
|
+
let target = this.detachTo || defaultTarget;
|
|
3097
3098
|
if (target === true)
|
|
3098
|
-
target =
|
|
3099
|
+
target = defaultTarget;
|
|
3099
3100
|
else if (target && !["object", "string"].includes(typeof target))
|
|
3100
|
-
target =
|
|
3101
|
+
target = defaultTarget;
|
|
3101
3102
|
else if (typeof target === "object" && !target.nodeType) {
|
|
3102
|
-
target =
|
|
3103
|
+
target = defaultTarget;
|
|
3103
3104
|
consoleWarn("Invalid node provided in w-menu `detach-to`. Falling back to .w-app.");
|
|
3104
3105
|
}
|
|
3105
3106
|
if (typeof target === "string")
|
|
3106
3107
|
target = document.querySelector(target);
|
|
3107
3108
|
if (!target) {
|
|
3108
|
-
consoleWarn(`Unable to locate ${this.detachTo ? `target ${this.detachTo}` :
|
|
3109
|
-
target = document.querySelector(
|
|
3109
|
+
consoleWarn(`Unable to locate ${this.detachTo ? `target ${this.detachTo}` : defaultTarget}`);
|
|
3110
|
+
target = document.querySelector(defaultTarget);
|
|
3110
3111
|
}
|
|
3111
3112
|
return target;
|
|
3112
3113
|
},
|
|
@@ -3179,8 +3180,9 @@ const __vue2_script$s = {
|
|
|
3179
3180
|
}, 10);
|
|
3180
3181
|
}
|
|
3181
3182
|
};
|
|
3182
|
-
if ("ontouchstart" in window)
|
|
3183
|
+
if (typeof window !== "undefined" && "ontouchstart" in window) {
|
|
3183
3184
|
handlers.click = this.toggleMenu;
|
|
3185
|
+
}
|
|
3184
3186
|
} else
|
|
3185
3187
|
handlers = { click: this.toggleMenu };
|
|
3186
3188
|
return handlers;
|
|
@@ -5539,20 +5541,21 @@ const __vue2_script$8 = {
|
|
|
5539
5541
|
return this.transition || `w-tooltip-slide-fade-${direction}`;
|
|
5540
5542
|
},
|
|
5541
5543
|
detachToTarget() {
|
|
5542
|
-
|
|
5544
|
+
const defaultTarget = ".w-app";
|
|
5545
|
+
let target = this.detachTo || defaultTarget;
|
|
5543
5546
|
if (target === true)
|
|
5544
|
-
target =
|
|
5547
|
+
target = defaultTarget;
|
|
5545
5548
|
else if (target && !["object", "string"].includes(typeof target))
|
|
5546
|
-
target =
|
|
5549
|
+
target = defaultTarget;
|
|
5547
5550
|
else if (typeof target === "object" && !target.nodeType) {
|
|
5548
|
-
target =
|
|
5551
|
+
target = defaultTarget;
|
|
5549
5552
|
consoleWarn("Invalid node provided in w-tooltip `attach-to`. Falling back to .w-app.");
|
|
5550
5553
|
}
|
|
5551
5554
|
if (typeof target === "string")
|
|
5552
5555
|
target = document.querySelector(target);
|
|
5553
5556
|
if (!target) {
|
|
5554
|
-
consoleWarn(`Unable to locate ${this.detachTo ? `target ${this.detachTo}` :
|
|
5555
|
-
target = document.querySelector(
|
|
5557
|
+
consoleWarn(`Unable to locate ${this.detachTo ? `target ${this.detachTo}` : defaultTarget}`);
|
|
5558
|
+
target = document.querySelector(defaultTarget);
|
|
5556
5559
|
}
|
|
5557
5560
|
return target;
|
|
5558
5561
|
},
|
|
@@ -5623,7 +5626,7 @@ const __vue2_script$8 = {
|
|
|
5623
5626
|
mouseenter: this.toggle,
|
|
5624
5627
|
mouseleave: this.toggle
|
|
5625
5628
|
};
|
|
5626
|
-
if ("ontouchstart" in window)
|
|
5629
|
+
if (typeof window !== "undefined" && "ontouchstart" in window)
|
|
5627
5630
|
handlers.click = this.toggle;
|
|
5628
5631
|
}
|
|
5629
5632
|
return handlers;
|
|
@@ -5632,7 +5635,7 @@ const __vue2_script$8 = {
|
|
|
5632
5635
|
methods: {
|
|
5633
5636
|
toggle(e) {
|
|
5634
5637
|
let shouldShowTooltip = this.showTooltip;
|
|
5635
|
-
if ("ontouchstart" in window) {
|
|
5638
|
+
if (typeof window !== "undefined" && "ontouchstart" in window) {
|
|
5636
5639
|
if (e.type === "click")
|
|
5637
5640
|
shouldShowTooltip = !shouldShowTooltip;
|
|
5638
5641
|
} else if (e.type === "click" && this.showOnClick)
|