uikit 3.11.0 → 3.11.2-dev.4c11be04b
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 +11 -0
- package/build/scope.js +4 -6
- 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 +1 -1
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +1 -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 +33 -26
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +32 -25
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +2 -2
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +32 -25
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +1 -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 +3 -3
- 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 +63 -56
- package/dist/js/uikit.min.js +1 -1
- package/package.json +1 -1
- package/src/js/components/parallax.js +1 -1
- package/src/js/components/slider.js +1 -1
- package/src/js/mixin/parallax.js +32 -21
- package/src/js/util/dimensions.js +1 -1
package/dist/js/uikit.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.11.
|
|
1
|
+
/*! UIkit 3.11.2-dev.4c11be04b | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
|
|
2
2
|
|
|
3
3
|
(function (global, factory) {
|
|
4
4
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
@@ -1587,7 +1587,7 @@
|
|
|
1587
1587
|
height: ['top', 'bottom']
|
|
1588
1588
|
};
|
|
1589
1589
|
|
|
1590
|
-
function dimensions(element) {
|
|
1590
|
+
function dimensions$1(element) {
|
|
1591
1591
|
|
|
1592
1592
|
var rect = isElement(element)
|
|
1593
1593
|
? toNode(element).getBoundingClientRect()
|
|
@@ -1605,7 +1605,7 @@
|
|
|
1605
1605
|
|
|
1606
1606
|
function offset(element, coordinates) {
|
|
1607
1607
|
|
|
1608
|
-
var currentOffset = dimensions(element);
|
|
1608
|
+
var currentOffset = dimensions$1(element);
|
|
1609
1609
|
|
|
1610
1610
|
if (element) {
|
|
1611
1611
|
var ref = toWindow(element);
|
|
@@ -1758,8 +1758,8 @@
|
|
|
1758
1758
|
? percent(width(toWindow(element)), value)
|
|
1759
1759
|
: endsWith(value, '%')
|
|
1760
1760
|
? percent(offsetDim
|
|
1761
|
-
?
|
|
1762
|
-
: dimensions(element)[property], value)
|
|
1761
|
+
? element[("offset" + (ucfirst(property)))]
|
|
1762
|
+
: dimensions$1(element)[property], value)
|
|
1763
1763
|
: toFloat(value);
|
|
1764
1764
|
}
|
|
1765
1765
|
|
|
@@ -2548,7 +2548,7 @@
|
|
|
2548
2548
|
replaceClass: replaceClass,
|
|
2549
2549
|
hasClass: hasClass,
|
|
2550
2550
|
toggleClass: toggleClass,
|
|
2551
|
-
dimensions: dimensions,
|
|
2551
|
+
dimensions: dimensions$1,
|
|
2552
2552
|
offset: offset,
|
|
2553
2553
|
position: position,
|
|
2554
2554
|
offsetPosition: offsetPosition,
|
|
@@ -3462,7 +3462,7 @@
|
|
|
3462
3462
|
UIkit.data = '__uikit__';
|
|
3463
3463
|
UIkit.prefix = 'uk-';
|
|
3464
3464
|
UIkit.options = {};
|
|
3465
|
-
UIkit.version = '3.11.
|
|
3465
|
+
UIkit.version = '3.11.2-dev.4c11be04b';
|
|
3466
3466
|
|
|
3467
3467
|
globalAPI(UIkit);
|
|
3468
3468
|
hooksAPI(UIkit);
|
|
@@ -5222,7 +5222,7 @@
|
|
|
5222
5222
|
css(element, 'display', 'block', 'important');
|
|
5223
5223
|
}
|
|
5224
5224
|
|
|
5225
|
-
var height = dimensions(element).height - boxModelAdjust(element, 'height', 'content-box');
|
|
5225
|
+
var height = dimensions$1(element).height - boxModelAdjust(element, 'height', 'content-box');
|
|
5226
5226
|
|
|
5227
5227
|
if (style !== false) {
|
|
5228
5228
|
css(element, 'display', style);
|
|
@@ -5264,7 +5264,7 @@
|
|
|
5264
5264
|
|
|
5265
5265
|
if (this.expand) {
|
|
5266
5266
|
|
|
5267
|
-
minHeight = height(window) - (dimensions(document.documentElement).height - dimensions(this.$el).height) - box || '';
|
|
5267
|
+
minHeight = height(window) - (dimensions$1(document.documentElement).height - dimensions$1(this.$el).height) - box || '';
|
|
5268
5268
|
|
|
5269
5269
|
} else {
|
|
5270
5270
|
|
|
@@ -5281,7 +5281,7 @@
|
|
|
5281
5281
|
|
|
5282
5282
|
if (this.offsetBottom === true) {
|
|
5283
5283
|
|
|
5284
|
-
minHeight += " - " + (dimensions(this.$el.nextElementSibling).height) + "px";
|
|
5284
|
+
minHeight += " - " + (dimensions$1(this.$el.nextElementSibling).height) + "px";
|
|
5285
5285
|
|
|
5286
5286
|
} else if (isNumeric(this.offsetBottom)) {
|
|
5287
5287
|
|
|
@@ -5293,7 +5293,7 @@
|
|
|
5293
5293
|
|
|
5294
5294
|
} else if (isString(this.offsetBottom)) {
|
|
5295
5295
|
|
|
5296
|
-
minHeight += " - " + (dimensions(query(this.offsetBottom, this.$el)).height) + "px";
|
|
5296
|
+
minHeight += " - " + (dimensions$1(query(this.offsetBottom, this.$el)).height) + "px";
|
|
5297
5297
|
|
|
5298
5298
|
}
|
|
5299
5299
|
|
|
@@ -7325,7 +7325,7 @@
|
|
|
7325
7325
|
|
|
7326
7326
|
return {
|
|
7327
7327
|
current: toFloat(css(this.$el, 'maxHeight')),
|
|
7328
|
-
max: Math.max(this.minHeight, height(this.container) - (dimensions(this.content).height - height(this.$el)))
|
|
7328
|
+
max: Math.max(this.minHeight, height(this.container) - (dimensions$1(this.content).height - height(this.$el)))
|
|
7329
7329
|
};
|
|
7330
7330
|
},
|
|
7331
7331
|
|
|
@@ -7851,7 +7851,7 @@
|
|
|
7851
7851
|
|
|
7852
7852
|
this.top = Math.max(toFloat(parseProp('top', this)), this.topOffset) - this.offset;
|
|
7853
7853
|
this.bottom = bottom && bottom - this.$el.offsetHeight;
|
|
7854
|
-
this.width = dimensions(isVisible(this.widthElement) ? this.widthElement : this.$el).width;
|
|
7854
|
+
this.width = dimensions$1(isVisible(this.widthElement) ? this.widthElement : this.$el).width;
|
|
7855
7855
|
|
|
7856
7856
|
return {
|
|
7857
7857
|
height: height$1,
|
|
@@ -10734,11 +10734,9 @@
|
|
|
10734
10734
|
computed: {
|
|
10735
10735
|
|
|
10736
10736
|
props: function(properties, $el) {
|
|
10737
|
-
var this$1$1 = this;
|
|
10738
|
-
|
|
10739
10737
|
return keys(props).reduce(function (result, prop) {
|
|
10740
10738
|
if (!isUndefined(properties[prop])) {
|
|
10741
|
-
result[prop] = props[prop]
|
|
10739
|
+
result[prop] = props[prop](prop, $el, properties[prop].slice());
|
|
10742
10740
|
}
|
|
10743
10741
|
return result;
|
|
10744
10742
|
}, {});
|
|
@@ -10746,6 +10744,12 @@
|
|
|
10746
10744
|
|
|
10747
10745
|
},
|
|
10748
10746
|
|
|
10747
|
+
events: {
|
|
10748
|
+
bgimageload: function() {
|
|
10749
|
+
this.$emit();
|
|
10750
|
+
}
|
|
10751
|
+
},
|
|
10752
|
+
|
|
10749
10753
|
methods: {
|
|
10750
10754
|
|
|
10751
10755
|
reset: function() {
|
|
@@ -10893,15 +10897,15 @@
|
|
|
10893
10897
|
var bgPos = css(el, 'backgroundPosition').split(' ')[prop === 'x' ? 0 : 1]; // IE 11 can't read background-position-[x|y]
|
|
10894
10898
|
|
|
10895
10899
|
return getCssValue(el, 'backgroundSize', '') === 'cover'
|
|
10896
|
-
? backgroundCoverFn
|
|
10900
|
+
? backgroundCoverFn(prop, el, steps, bgPos, attr)
|
|
10897
10901
|
: setBackgroundPosFn(prop, steps, bgPos);
|
|
10898
10902
|
}
|
|
10899
10903
|
|
|
10900
10904
|
function backgroundCoverFn(prop, el, steps, bgPos, attr) {
|
|
10901
10905
|
|
|
10902
|
-
var
|
|
10906
|
+
var dimImage = getBackgroundImageDimensions(el);
|
|
10903
10907
|
|
|
10904
|
-
if (!
|
|
10908
|
+
if (!dimImage.width) {
|
|
10905
10909
|
return noop;
|
|
10906
10910
|
}
|
|
10907
10911
|
|
|
@@ -10917,11 +10921,6 @@
|
|
|
10917
10921
|
height: el.offsetHeight
|
|
10918
10922
|
};
|
|
10919
10923
|
|
|
10920
|
-
var dimImage = {
|
|
10921
|
-
width: image.naturalWidth,
|
|
10922
|
-
height: image.naturalHeight
|
|
10923
|
-
};
|
|
10924
|
-
|
|
10925
10924
|
var baseDim = Dimensions.cover(dimImage, dimEl);
|
|
10926
10925
|
var span = baseDim[attr] - dimEl[attr];
|
|
10927
10926
|
|
|
@@ -10952,26 +10951,34 @@
|
|
|
10952
10951
|
};
|
|
10953
10952
|
}
|
|
10954
10953
|
|
|
10955
|
-
|
|
10956
|
-
|
|
10957
|
-
|
|
10954
|
+
var dimensions = {};
|
|
10955
|
+
function getBackgroundImageDimensions(el) {
|
|
10958
10956
|
var src = css(el, 'backgroundImage').replace(/^none|url\(["']?(.+?)["']?\)$/, '$1');
|
|
10959
10957
|
|
|
10960
|
-
|
|
10961
|
-
|
|
10962
|
-
if (data[src]) {
|
|
10963
|
-
return data[src];
|
|
10958
|
+
if (dimensions[src]) {
|
|
10959
|
+
return dimensions[src];
|
|
10964
10960
|
}
|
|
10965
10961
|
|
|
10962
|
+
var image = new Image();
|
|
10966
10963
|
if (src) {
|
|
10967
|
-
|
|
10968
|
-
img.src = src;
|
|
10969
|
-
if (!img.naturalWidth) {
|
|
10970
|
-
img.onload = function () { return this$1$1.$update(); };
|
|
10971
|
-
}
|
|
10964
|
+
image.src = src;
|
|
10972
10965
|
|
|
10973
|
-
|
|
10966
|
+
if (!image.naturalWidth) {
|
|
10967
|
+
image.onload = function () {
|
|
10968
|
+
dimensions[src] = toDimensions(image);
|
|
10969
|
+
trigger(el, 'bgimageload');
|
|
10970
|
+
};
|
|
10971
|
+
}
|
|
10974
10972
|
}
|
|
10973
|
+
|
|
10974
|
+
return dimensions[src] = toDimensions(image);
|
|
10975
|
+
}
|
|
10976
|
+
|
|
10977
|
+
function toDimensions(image) {
|
|
10978
|
+
return {
|
|
10979
|
+
width: image.naturalWidth,
|
|
10980
|
+
height: image.naturalHeight
|
|
10981
|
+
};
|
|
10975
10982
|
}
|
|
10976
10983
|
|
|
10977
10984
|
function getStep(steps, percent) {
|
|
@@ -11105,7 +11112,7 @@
|
|
|
11105
11112
|
calc = calc.toString().replace(/\s/g, '');
|
|
11106
11113
|
calcRe.lastIndex = 0;
|
|
11107
11114
|
while ((match = calcRe.exec(calc)) !== null) {
|
|
11108
|
-
result += toPx(match, 'height', el, true);
|
|
11115
|
+
result += toPx(match[0], 'height', el, true);
|
|
11109
11116
|
}
|
|
11110
11117
|
|
|
11111
11118
|
return result;
|
|
@@ -11160,10 +11167,10 @@
|
|
|
11160
11167
|
|
|
11161
11168
|
var from = prev
|
|
11162
11169
|
? getLeft(prev, list, center)
|
|
11163
|
-
: getLeft(next, list, center) + dimensions(next).width * dir;
|
|
11170
|
+
: getLeft(next, list, center) + dimensions$1(next).width * dir;
|
|
11164
11171
|
var to = next
|
|
11165
11172
|
? getLeft(next, list, center)
|
|
11166
|
-
: from + dimensions(prev).width * dir * (isRtl ? -1 : 1);
|
|
11173
|
+
: from + dimensions$1(prev).width * dir * (isRtl ? -1 : 1);
|
|
11167
11174
|
|
|
11168
11175
|
return {
|
|
11169
11176
|
|
|
@@ -11212,7 +11219,7 @@
|
|
|
11212
11219
|
css(list, 'transform', translate(clamp(
|
|
11213
11220
|
-to + (distance - distance * percent),
|
|
11214
11221
|
-getWidth(list),
|
|
11215
|
-
dimensions(list).width
|
|
11222
|
+
dimensions$1(list).width
|
|
11216
11223
|
) * (isRtl ? -1 : 1), 'px'));
|
|
11217
11224
|
|
|
11218
11225
|
var actives = this.getActives();
|
|
@@ -11285,30 +11292,30 @@
|
|
|
11285
11292
|
}
|
|
11286
11293
|
|
|
11287
11294
|
function getMax(list) {
|
|
11288
|
-
return Math.max(0, getWidth(list) - dimensions(list).width);
|
|
11295
|
+
return Math.max(0, getWidth(list) - dimensions$1(list).width);
|
|
11289
11296
|
}
|
|
11290
11297
|
|
|
11291
11298
|
function getWidth(list) {
|
|
11292
|
-
return children(list).reduce(function (right, el) { return dimensions(el).width + right; }, 0);
|
|
11299
|
+
return children(list).reduce(function (right, el) { return dimensions$1(el).width + right; }, 0);
|
|
11293
11300
|
}
|
|
11294
11301
|
|
|
11295
11302
|
function centerEl(el, list) {
|
|
11296
|
-
return dimensions(list).width / 2 - dimensions(el).width / 2;
|
|
11303
|
+
return dimensions$1(list).width / 2 - dimensions$1(el).width / 2;
|
|
11297
11304
|
}
|
|
11298
11305
|
|
|
11299
11306
|
function getElLeft(el, list) {
|
|
11300
|
-
return el && (position(el).left + (isRtl ? dimensions(el).width - dimensions(list).width : 0)) * (isRtl ? -1 : 1) || 0;
|
|
11307
|
+
return el && (position(el).left + (isRtl ? dimensions$1(el).width - dimensions$1(list).width : 0)) * (isRtl ? -1 : 1) || 0;
|
|
11301
11308
|
}
|
|
11302
11309
|
|
|
11303
11310
|
function inView(list, listLeft) {
|
|
11304
11311
|
|
|
11305
11312
|
listLeft -= 1;
|
|
11306
|
-
var listWidth = dimensions(list).width;
|
|
11313
|
+
var listWidth = dimensions$1(list).width;
|
|
11307
11314
|
var listRight = listLeft + listWidth + 2;
|
|
11308
11315
|
|
|
11309
11316
|
return children(list).filter(function (slide) {
|
|
11310
11317
|
var slideLeft = getElLeft(slide, list);
|
|
11311
|
-
var slideRight = slideLeft + Math.min(dimensions(slide).width, listWidth);
|
|
11318
|
+
var slideRight = slideLeft + Math.min(dimensions$1(slide).width, listWidth);
|
|
11312
11319
|
|
|
11313
11320
|
return slideLeft >= listLeft && slideRight <= listRight;
|
|
11314
11321
|
});
|
|
@@ -11346,7 +11353,7 @@
|
|
|
11346
11353
|
finite: function(ref) {
|
|
11347
11354
|
var finite = ref.finite;
|
|
11348
11355
|
|
|
11349
|
-
return finite || Math.ceil(getWidth(this.list)) < dimensions(this.list).width + getMaxElWidth(this.list) + this.center;
|
|
11356
|
+
return finite || Math.ceil(getWidth(this.list)) < Math.floor(dimensions$1(this.list).width + getMaxElWidth(this.list) + this.center);
|
|
11350
11357
|
},
|
|
11351
11358
|
|
|
11352
11359
|
maxIndex: function() {
|
|
@@ -11367,7 +11374,7 @@
|
|
|
11367
11374
|
return true;
|
|
11368
11375
|
}
|
|
11369
11376
|
|
|
11370
|
-
lft += dimensions(el).width;
|
|
11377
|
+
lft += dimensions$1(el).width;
|
|
11371
11378
|
|
|
11372
11379
|
});
|
|
11373
11380
|
|
|
@@ -11383,7 +11390,7 @@
|
|
|
11383
11390
|
return;
|
|
11384
11391
|
}
|
|
11385
11392
|
|
|
11386
|
-
var width = dimensions(this.list).width / (this.center ? 2 : 1);
|
|
11393
|
+
var width = dimensions$1(this.list).width / (this.center ? 2 : 1);
|
|
11387
11394
|
|
|
11388
11395
|
var left = 0;
|
|
11389
11396
|
var leftCenter = width;
|
|
@@ -11391,7 +11398,7 @@
|
|
|
11391
11398
|
|
|
11392
11399
|
sets = sortBy$1(this.slides, 'offsetLeft').reduce(function (sets, slide, i) {
|
|
11393
11400
|
|
|
11394
|
-
var slideWidth = dimensions(slide).width;
|
|
11401
|
+
var slideWidth = dimensions$1(slide).width;
|
|
11395
11402
|
var slideRight = slideLeft + slideWidth;
|
|
11396
11403
|
|
|
11397
11404
|
if (slideRight > left) {
|
|
@@ -11403,7 +11410,7 @@
|
|
|
11403
11410
|
if (!includes(sets, i)) {
|
|
11404
11411
|
|
|
11405
11412
|
var cmp = this$1$1.slides[i + 1];
|
|
11406
|
-
if (this$1$1.center && cmp && slideWidth < leftCenter - dimensions(cmp).width / 2) {
|
|
11413
|
+
if (this$1$1.center && cmp && slideWidth < leftCenter - dimensions$1(cmp).width / 2) {
|
|
11407
11414
|
leftCenter -= slideWidth;
|
|
11408
11415
|
} else {
|
|
11409
11416
|
leftCenter = width;
|
|
@@ -11491,7 +11498,7 @@
|
|
|
11491
11498
|
}
|
|
11492
11499
|
|
|
11493
11500
|
var index = this.dir < 0 || !this.slides[this.prevIndex] ? this.index : this.prevIndex;
|
|
11494
|
-
this.duration = speedUp(this.avgWidth / this.velocity) * (dimensions(this.slides[index]).width / this.avgWidth);
|
|
11501
|
+
this.duration = speedUp(this.avgWidth / this.velocity) * (dimensions$1(this.slides[index]).width / this.avgWidth);
|
|
11495
11502
|
|
|
11496
11503
|
this.reorder();
|
|
11497
11504
|
|
|
@@ -11531,7 +11538,7 @@
|
|
|
11531
11538
|
}
|
|
11532
11539
|
|
|
11533
11540
|
var next = this.slides[index];
|
|
11534
|
-
var width = dimensions(this.list).width / 2 - dimensions(next).width / 2;
|
|
11541
|
+
var width = dimensions$1(this.list).width / 2 - dimensions$1(next).width / 2;
|
|
11535
11542
|
var j = 0;
|
|
11536
11543
|
|
|
11537
11544
|
while (width > 0) {
|
|
@@ -11539,7 +11546,7 @@
|
|
|
11539
11546
|
var slide = this.slides[slideIndex];
|
|
11540
11547
|
|
|
11541
11548
|
css(slide, 'order', slideIndex > index ? -2 : -1);
|
|
11542
|
-
width -= dimensions(slide).width;
|
|
11549
|
+
width -= dimensions$1(slide).width;
|
|
11543
11550
|
}
|
|
11544
11551
|
|
|
11545
11552
|
},
|
|
@@ -11576,7 +11583,7 @@
|
|
|
11576
11583
|
};
|
|
11577
11584
|
|
|
11578
11585
|
function getMaxElWidth(list) {
|
|
11579
|
-
return Math.max.apply(Math, [ 0 ].concat( children(list).map(function (el) { return dimensions(el).width; }) ));
|
|
11586
|
+
return Math.max.apply(Math, [ 0 ].concat( children(list).map(function (el) { return dimensions$1(el).width; }) ));
|
|
11580
11587
|
}
|
|
11581
11588
|
|
|
11582
11589
|
var sliderParallax = {
|