uikit 3.20.9-dev.50e5c71c4 → 3.20.9-dev.976ee5848
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/CHANGELOG.md +2 -0
- package/dist/css/uikit-core-rtl.css +1 -1
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +1 -1
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +1 -1
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +1 -1
- package/dist/css/uikit.min.css +1 -1
- package/dist/js/components/countdown.js +1 -1
- package/dist/js/components/countdown.min.js +1 -1
- package/dist/js/components/filter.js +1 -1
- package/dist/js/components/filter.min.js +1 -1
- package/dist/js/components/lightbox-panel.js +4 -1
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +4 -1
- package/dist/js/components/lightbox.min.js +1 -1
- package/dist/js/components/notification.js +1 -1
- package/dist/js/components/notification.min.js +1 -1
- package/dist/js/components/parallax.js +1 -1
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +1 -1
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +5 -2
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +1 -1
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +4 -1
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +1 -1
- package/dist/js/components/sortable.min.js +1 -1
- package/dist/js/components/tooltip.js +1 -1
- package/dist/js/components/tooltip.min.js +1 -1
- package/dist/js/components/upload.js +1 -1
- package/dist/js/components/upload.min.js +1 -1
- package/dist/js/uikit-core.js +34 -22
- package/dist/js/uikit-core.min.js +1 -1
- package/dist/js/uikit-icons.js +1 -1
- package/dist/js/uikit-icons.min.js +1 -1
- package/dist/js/uikit.js +46 -28
- package/dist/js/uikit.min.js +1 -1
- package/package.json +1 -1
- package/src/js/api/component.js +1 -1
- package/src/js/components/internal/slider-transitioner.js +4 -0
- package/src/js/components/slider.js +1 -1
- package/src/js/core/inverse.js +30 -3
- package/src/js/core/modal.js +1 -1
- package/src/js/mixin/internal/slideshow-transitioner.js +4 -0
- package/tests/modal.html +1 -1
package/dist/js/uikit-core.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.20.9-dev.
|
|
1
|
+
/*! UIkit 3.20.9-dev.976ee5848 | https://www.getuikit.com | (c) 2014 - 2024 YOOtheme | MIT License */
|
|
2
2
|
|
|
3
3
|
(function (global, factory) {
|
|
4
4
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
@@ -310,7 +310,7 @@
|
|
|
310
310
|
const isVisibleFn = inBrowser && Element.prototype.checkVisibility || function() {
|
|
311
311
|
return this.offsetWidth || this.offsetHeight || this.getClientRects().length;
|
|
312
312
|
};
|
|
313
|
-
function isVisible(element) {
|
|
313
|
+
function isVisible$1(element) {
|
|
314
314
|
return toNodes(element).some((element2) => isVisibleFn.call(element2));
|
|
315
315
|
}
|
|
316
316
|
const selInput = "input,select,textarea,button";
|
|
@@ -1199,7 +1199,7 @@
|
|
|
1199
1199
|
}
|
|
1200
1200
|
|
|
1201
1201
|
function isInView(element, offsetTop = 0, offsetLeft = 0) {
|
|
1202
|
-
if (!isVisible(element)) {
|
|
1202
|
+
if (!isVisible$1(element)) {
|
|
1203
1203
|
return false;
|
|
1204
1204
|
}
|
|
1205
1205
|
return intersectRect(
|
|
@@ -1215,7 +1215,7 @@
|
|
|
1215
1215
|
);
|
|
1216
1216
|
}
|
|
1217
1217
|
function scrollIntoView(element, { offset: offsetBy = 0 } = {}) {
|
|
1218
|
-
const parents2 = isVisible(element) ? scrollParents(element, false, ["hidden"]) : [];
|
|
1218
|
+
const parents2 = isVisible$1(element) ? scrollParents(element, false, ["hidden"]) : [];
|
|
1219
1219
|
return parents2.reduce(
|
|
1220
1220
|
(fn, scrollElement, i) => {
|
|
1221
1221
|
const { scrollTop, scrollHeight, offsetHeight } = scrollElement;
|
|
@@ -1274,7 +1274,7 @@
|
|
|
1274
1274
|
}
|
|
1275
1275
|
}
|
|
1276
1276
|
function scrolledOver(element, startOffset = 0, endOffset = 0) {
|
|
1277
|
-
if (!isVisible(element)) {
|
|
1277
|
+
if (!isVisible$1(element)) {
|
|
1278
1278
|
return 0;
|
|
1279
1279
|
}
|
|
1280
1280
|
const scrollElement = scrollParent(element, true);
|
|
@@ -1611,7 +1611,7 @@
|
|
|
1611
1611
|
isTouch: isTouch,
|
|
1612
1612
|
isUndefined: isUndefined,
|
|
1613
1613
|
isVideo: isVideo,
|
|
1614
|
-
isVisible: isVisible,
|
|
1614
|
+
isVisible: isVisible$1,
|
|
1615
1615
|
isVoidElement: isVoidElement,
|
|
1616
1616
|
isWindow: isWindow,
|
|
1617
1617
|
last: last,
|
|
@@ -2172,7 +2172,7 @@
|
|
|
2172
2172
|
};
|
|
2173
2173
|
App.util = util;
|
|
2174
2174
|
App.options = {};
|
|
2175
|
-
App.version = "3.20.9-dev.
|
|
2175
|
+
App.version = "3.20.9-dev.976ee5848";
|
|
2176
2176
|
|
|
2177
2177
|
const PREFIX = "uk-";
|
|
2178
2178
|
const DATA = "__uikit__";
|
|
@@ -2227,7 +2227,7 @@
|
|
|
2227
2227
|
function detachFromElement(element, instance) {
|
|
2228
2228
|
var _a;
|
|
2229
2229
|
(_a = element[DATA]) == null ? true : delete _a[instance.$options.name];
|
|
2230
|
-
if (
|
|
2230
|
+
if (isEmpty(element[DATA])) {
|
|
2231
2231
|
delete element[DATA];
|
|
2232
2232
|
}
|
|
2233
2233
|
}
|
|
@@ -2550,7 +2550,7 @@
|
|
|
2550
2550
|
},
|
|
2551
2551
|
isToggled(el = this.$el) {
|
|
2552
2552
|
el = toNode(el);
|
|
2553
|
-
return hasClass(el, this.clsEnter) ? true : hasClass(el, this.clsLeave) ? false : this.cls ? hasClass(el, this.cls.split(" ")[0]) : isVisible(el);
|
|
2553
|
+
return hasClass(el, this.clsEnter) ? true : hasClass(el, this.clsLeave) ? false : this.cls ? hasClass(el, this.cls.split(" ")[0]) : isVisible$1(el);
|
|
2554
2554
|
},
|
|
2555
2555
|
_toggle(el, toggled) {
|
|
2556
2556
|
if (!el) {
|
|
@@ -2565,7 +2565,7 @@
|
|
|
2565
2565
|
changed = toggled === el.hidden;
|
|
2566
2566
|
changed && (el.hidden = !toggled);
|
|
2567
2567
|
}
|
|
2568
|
-
$$("[autofocus]", el).some((el2) => isVisible(el2) ? el2.focus() || true : el2.blur());
|
|
2568
|
+
$$("[autofocus]", el).some((el2) => isVisible$1(el2) ? el2.focus() || true : el2.blur());
|
|
2569
2569
|
if (changed) {
|
|
2570
2570
|
trigger(el, "toggled", [toggled, this]);
|
|
2571
2571
|
}
|
|
@@ -3998,7 +3998,7 @@
|
|
|
3998
3998
|
(el, i) => i && elements[i - 1].offsetParent !== el.offsetParent
|
|
3999
3999
|
);
|
|
4000
4000
|
for (const el of elements) {
|
|
4001
|
-
if (!isVisible(el)) {
|
|
4001
|
+
if (!isVisible$1(el)) {
|
|
4002
4002
|
continue;
|
|
4003
4003
|
}
|
|
4004
4004
|
const offset = getOffset(el, withOffset);
|
|
@@ -4257,7 +4257,7 @@
|
|
|
4257
4257
|
}
|
|
4258
4258
|
function getHeight(element) {
|
|
4259
4259
|
const style = pick(element.style, ["display", "minHeight"]);
|
|
4260
|
-
if (!isVisible(element)) {
|
|
4260
|
+
if (!isVisible$1(element)) {
|
|
4261
4261
|
css(element, "display", "block", "important");
|
|
4262
4262
|
}
|
|
4263
4263
|
css(element, "minHeight", "");
|
|
@@ -4312,7 +4312,7 @@
|
|
|
4312
4312
|
],
|
|
4313
4313
|
update: {
|
|
4314
4314
|
read() {
|
|
4315
|
-
if (!isVisible(this.$el)) {
|
|
4315
|
+
if (!isVisible$1(this.$el)) {
|
|
4316
4316
|
return false;
|
|
4317
4317
|
}
|
|
4318
4318
|
let minHeight = "";
|
|
@@ -4857,11 +4857,11 @@
|
|
|
4857
4857
|
let last;
|
|
4858
4858
|
for (const percent of [0.25, 0.5, 0.75]) {
|
|
4859
4859
|
const elements = target.ownerDocument.elementsFromPoint(
|
|
4860
|
-
Math.max(0, left
|
|
4861
|
-
Math.max(0, top
|
|
4860
|
+
Math.max(0, left + width * percent),
|
|
4861
|
+
Math.max(0, top + height / 2)
|
|
4862
4862
|
);
|
|
4863
4863
|
for (const element of elements) {
|
|
4864
|
-
if (target.contains(element) || element.closest('[class*="-leave"]') && elements.some((el) => element !== el && matches(el, '[class*="-enter"]'))) {
|
|
4864
|
+
if (target.contains(element) || !isVisible(element) || element.closest('[class*="-leave"]') && elements.some((el) => element !== el && matches(el, '[class*="-enter"]'))) {
|
|
4865
4865
|
continue;
|
|
4866
4866
|
}
|
|
4867
4867
|
const color = css(element, "--uk-inverse");
|
|
@@ -4876,6 +4876,18 @@
|
|
|
4876
4876
|
}
|
|
4877
4877
|
return last ? `uk-${last}` : "";
|
|
4878
4878
|
}
|
|
4879
|
+
function isVisible(element) {
|
|
4880
|
+
if (css(element, "visibility") !== "visible") {
|
|
4881
|
+
return false;
|
|
4882
|
+
}
|
|
4883
|
+
while (element) {
|
|
4884
|
+
if (css(element, "opacity") === "0") {
|
|
4885
|
+
return false;
|
|
4886
|
+
}
|
|
4887
|
+
element = parent(element);
|
|
4888
|
+
}
|
|
4889
|
+
return true;
|
|
4890
|
+
}
|
|
4879
4891
|
|
|
4880
4892
|
var Media = {
|
|
4881
4893
|
props: {
|
|
@@ -5241,7 +5253,7 @@
|
|
|
5241
5253
|
};
|
|
5242
5254
|
modal.prompt = function(message, value, options) {
|
|
5243
5255
|
const promise = openDialog(
|
|
5244
|
-
({ i18n }) => `<form class="uk-form-stacked"> <div class="uk-modal-body"> <label>${isString(message) ? message : html(message)}</label> <input class="uk-input"
|
|
5256
|
+
({ i18n }) => `<form class="uk-form-stacked"> <div class="uk-modal-body"> <label>${isString(message) ? message : html(message)}</label> <input class="uk-input" autofocus> </div> <div class="uk-modal-footer uk-text-right"> <button class="uk-button uk-button-default uk-modal-close" type="button">${i18n.cancel}</button> <button class="uk-button uk-button-primary">${i18n.ok}</button> </div> </form>`,
|
|
5245
5257
|
options,
|
|
5246
5258
|
() => null,
|
|
5247
5259
|
() => input.value
|
|
@@ -5401,7 +5413,7 @@
|
|
|
5401
5413
|
observe: swipe({ filter: ({ swiping }) => swiping }),
|
|
5402
5414
|
update: {
|
|
5403
5415
|
read() {
|
|
5404
|
-
if (this.isToggled() && !isVisible(this.$el)) {
|
|
5416
|
+
if (this.isToggled() && !isVisible$1(this.$el)) {
|
|
5405
5417
|
this.hide();
|
|
5406
5418
|
}
|
|
5407
5419
|
},
|
|
@@ -5508,7 +5520,7 @@
|
|
|
5508
5520
|
}),
|
|
5509
5521
|
update: {
|
|
5510
5522
|
read() {
|
|
5511
|
-
if (!this.content || !this.container || !isVisible(this.$el)) {
|
|
5523
|
+
if (!this.content || !this.container || !isVisible$1(this.$el)) {
|
|
5512
5524
|
return false;
|
|
5513
5525
|
}
|
|
5514
5526
|
return {
|
|
@@ -5724,7 +5736,7 @@
|
|
|
5724
5736
|
read() {
|
|
5725
5737
|
const targets = this.links.map(getTargetedElement).filter(Boolean);
|
|
5726
5738
|
const { length } = targets;
|
|
5727
|
-
if (!length || !isVisible(this.$el)) {
|
|
5739
|
+
if (!length || !isVisible$1(this.$el)) {
|
|
5728
5740
|
return false;
|
|
5729
5741
|
}
|
|
5730
5742
|
const scrollElement = scrollParent(targets, true);
|
|
@@ -5869,7 +5881,7 @@
|
|
|
5869
5881
|
update: [
|
|
5870
5882
|
{
|
|
5871
5883
|
read({ height: height$1, width, margin, sticky }) {
|
|
5872
|
-
this.inactive = !this.matchMedia || !isVisible(this.$el);
|
|
5884
|
+
this.inactive = !this.matchMedia || !isVisible$1(this.$el);
|
|
5873
5885
|
if (this.inactive) {
|
|
5874
5886
|
return;
|
|
5875
5887
|
}
|
|
@@ -6124,7 +6136,7 @@
|
|
|
6124
6136
|
}
|
|
6125
6137
|
|
|
6126
6138
|
function getMaxPathLength(el) {
|
|
6127
|
-
return isVisible(el) ? Math.ceil(Math.max(0, ...$$("[stroke]", el).map((stroke) => stroke.getTotalLength()))) : 0;
|
|
6139
|
+
return isVisible$1(el) ? Math.ceil(Math.max(0, ...$$("[stroke]", el).map((stroke) => stroke.getTotalLength()))) : 0;
|
|
6128
6140
|
}
|
|
6129
6141
|
|
|
6130
6142
|
var svg = {
|