uikit 3.9.5-dev.1c5ab040d → 3.9.5-dev.24d436fbb
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 +17 -2
- package/README.md +4 -4
- package/build/less.js +30 -11
- package/build/util.js +1 -20
- package/dist/css/uikit-core-rtl.css +31 -12
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +28 -9
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +31 -12
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +28 -9
- 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 +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 +1 -1
- 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 +1 -1
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +2 -2
- 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 +61 -66
- 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 +62 -67
- package/dist/js/uikit.min.js +1 -1
- package/package.json +6 -8
- package/src/js/components/sortable.js +1 -1
- package/src/js/core/cover.js +1 -2
- package/src/js/core/drop.js +3 -2
- package/src/js/core/img.js +38 -53
- package/src/js/core/sticky.js +6 -1
- package/src/js/util/dom.js +2 -5
- package/src/js/util/selector.js +4 -2
- package/src/less/components/cover.less +1 -2
- package/src/less/components/link.less +6 -3
- package/src/less/components/list.less +1 -1
- package/src/less/components/search.less +31 -6
- package/src/less/components/utility.less +7 -1
- package/src/less/components/width.less +7 -0
- package/src/less/theme/search.less +6 -0
- package/src/scss/components/cover.scss +1 -2
- package/src/scss/components/link.scss +6 -3
- package/src/scss/components/list.scss +1 -1
- package/src/scss/components/search.scss +23 -6
- package/src/scss/components/utility.scss +7 -1
- package/src/scss/components/width.scss +7 -0
- package/src/scss/mixins-theme.scss +12 -0
- package/src/scss/mixins.scss +12 -0
- package/src/scss/theme/search.scss +6 -0
- package/src/scss/variables-theme.scss +3 -0
- package/src/scss/variables.scss +3 -0
- package/tests/search.html +1 -1
package/dist/js/uikit.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.9.5-dev.
|
|
1
|
+
/*! UIkit 3.9.5-dev.24d436fbb | 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() :
|
|
@@ -634,8 +634,9 @@
|
|
|
634
634
|
function domPath(element) {
|
|
635
635
|
var names = [];
|
|
636
636
|
while (element.parentNode) {
|
|
637
|
-
|
|
638
|
-
|
|
637
|
+
var id = attr(element, 'id');
|
|
638
|
+
if (id) {
|
|
639
|
+
names.unshift(("#" + (escape(id))));
|
|
639
640
|
break;
|
|
640
641
|
} else {
|
|
641
642
|
var tagName = element.tagName;
|
|
@@ -1104,10 +1105,7 @@
|
|
|
1104
1105
|
return;
|
|
1105
1106
|
}
|
|
1106
1107
|
|
|
1107
|
-
|
|
1108
|
-
unbind();
|
|
1109
|
-
fn();
|
|
1110
|
-
});
|
|
1108
|
+
once(document, 'DOMContentLoaded', fn);
|
|
1111
1109
|
}
|
|
1112
1110
|
|
|
1113
1111
|
function empty(element) {
|
|
@@ -3465,7 +3463,7 @@
|
|
|
3465
3463
|
UIkit.data = '__uikit__';
|
|
3466
3464
|
UIkit.prefix = 'uk-';
|
|
3467
3465
|
UIkit.options = {};
|
|
3468
|
-
UIkit.version = '3.9.5-dev.
|
|
3466
|
+
UIkit.version = '3.9.5-dev.24d436fbb';
|
|
3469
3467
|
|
|
3470
3468
|
globalAPI(UIkit);
|
|
3471
3469
|
hooksAPI(UIkit);
|
|
@@ -4105,7 +4103,7 @@
|
|
|
4105
4103
|
|
|
4106
4104
|
var cover = {
|
|
4107
4105
|
|
|
4108
|
-
mixins: [
|
|
4106
|
+
mixins: [Video],
|
|
4109
4107
|
|
|
4110
4108
|
props: {
|
|
4111
4109
|
width: Number,
|
|
@@ -4327,7 +4325,8 @@
|
|
|
4327
4325
|
this.target = this.$create('toggle', query(this.toggle, this.$el), {
|
|
4328
4326
|
target: this.$el,
|
|
4329
4327
|
mode: this.mode
|
|
4330
|
-
});
|
|
4328
|
+
}).$el;
|
|
4329
|
+
attr(this.target, 'aria-haspopup', true);
|
|
4331
4330
|
}
|
|
4332
4331
|
|
|
4333
4332
|
},
|
|
@@ -5785,7 +5784,12 @@
|
|
|
5785
5784
|
|
|
5786
5785
|
var img = {
|
|
5787
5786
|
|
|
5787
|
+
args: 'dataSrc',
|
|
5788
|
+
|
|
5788
5789
|
props: {
|
|
5790
|
+
dataSrc: String,
|
|
5791
|
+
dataSrcset: Boolean,
|
|
5792
|
+
sizes: String,
|
|
5789
5793
|
width: Number,
|
|
5790
5794
|
height: Number,
|
|
5791
5795
|
offsetTop: String,
|
|
@@ -5794,6 +5798,9 @@
|
|
|
5794
5798
|
},
|
|
5795
5799
|
|
|
5796
5800
|
data: {
|
|
5801
|
+
dataSrc: '',
|
|
5802
|
+
dataSrcset: false,
|
|
5803
|
+
sizes: false,
|
|
5797
5804
|
width: false,
|
|
5798
5805
|
height: false,
|
|
5799
5806
|
offsetTop: '50vh',
|
|
@@ -5803,8 +5810,10 @@
|
|
|
5803
5810
|
|
|
5804
5811
|
computed: {
|
|
5805
5812
|
|
|
5806
|
-
cacheKey: function() {
|
|
5807
|
-
|
|
5813
|
+
cacheKey: function(ref) {
|
|
5814
|
+
var dataSrc = ref.dataSrc;
|
|
5815
|
+
|
|
5816
|
+
return ((this.$name) + "." + dataSrc);
|
|
5808
5817
|
},
|
|
5809
5818
|
|
|
5810
5819
|
width: function(ref) {
|
|
@@ -5821,6 +5830,17 @@
|
|
|
5821
5830
|
return height || dataHeight;
|
|
5822
5831
|
},
|
|
5823
5832
|
|
|
5833
|
+
sizes: function(ref) {
|
|
5834
|
+
var sizes = ref.sizes;
|
|
5835
|
+
var dataSizes = ref.dataSizes;
|
|
5836
|
+
|
|
5837
|
+
return sizes || dataSizes;
|
|
5838
|
+
},
|
|
5839
|
+
|
|
5840
|
+
isImg: function(_, $el) {
|
|
5841
|
+
return isImg($el);
|
|
5842
|
+
},
|
|
5843
|
+
|
|
5824
5844
|
target: {
|
|
5825
5845
|
|
|
5826
5846
|
get: function(ref) {
|
|
@@ -5852,14 +5872,14 @@
|
|
|
5852
5872
|
connected: function() {
|
|
5853
5873
|
|
|
5854
5874
|
if (!window.IntersectionObserver) {
|
|
5855
|
-
setSrcAttrs(this.$el);
|
|
5875
|
+
setSrcAttrs(this.$el, this.dataSrc, this.dataSrcset, this.sizes);
|
|
5856
5876
|
return;
|
|
5857
5877
|
}
|
|
5858
5878
|
|
|
5859
5879
|
if (storage[this.cacheKey]) {
|
|
5860
|
-
setSrcAttrs(this.$el, storage[this.cacheKey]);
|
|
5861
|
-
} else if (isImg
|
|
5862
|
-
|
|
5880
|
+
setSrcAttrs(this.$el, storage[this.cacheKey], this.dataSrcset, this.sizes);
|
|
5881
|
+
} else if (this.isImg && this.width && this.height) {
|
|
5882
|
+
setSrcAttrs(this.$el, getPlaceholderImage(this.width, this.height, this.sizes));
|
|
5863
5883
|
}
|
|
5864
5884
|
|
|
5865
5885
|
this.observer = new IntersectionObserver(this.load, {
|
|
@@ -5889,7 +5909,7 @@
|
|
|
5889
5909
|
this.load(this.observer.takeRecords());
|
|
5890
5910
|
}
|
|
5891
5911
|
|
|
5892
|
-
if (isImg
|
|
5912
|
+
if (this.isImg) {
|
|
5893
5913
|
return false;
|
|
5894
5914
|
}
|
|
5895
5915
|
|
|
@@ -5897,15 +5917,14 @@
|
|
|
5897
5917
|
|
|
5898
5918
|
},
|
|
5899
5919
|
|
|
5900
|
-
write: function(
|
|
5920
|
+
write: function(data) {
|
|
5901
5921
|
|
|
5902
|
-
|
|
5903
|
-
if (srcset && window.devicePixelRatio !== 1) {
|
|
5922
|
+
if (this.dataSrcset && window.devicePixelRatio !== 1) {
|
|
5904
5923
|
|
|
5905
5924
|
var bgSize = css(this.$el, 'backgroundSize');
|
|
5906
|
-
if (bgSize.match(/^(auto\s?)+$/) || toFloat(bgSize) ===
|
|
5907
|
-
|
|
5908
|
-
css(this.$el, 'backgroundSize', ((
|
|
5925
|
+
if (bgSize.match(/^(auto\s?)+$/) || toFloat(bgSize) === data.bgSize) {
|
|
5926
|
+
data.bgSize = getSourceSize(this.dataSrcset, this.sizes);
|
|
5927
|
+
css(this.$el, 'backgroundSize', ((data.bgSize) + "px"));
|
|
5909
5928
|
}
|
|
5910
5929
|
|
|
5911
5930
|
}
|
|
@@ -5927,9 +5946,9 @@
|
|
|
5927
5946
|
return;
|
|
5928
5947
|
}
|
|
5929
5948
|
|
|
5930
|
-
this._data.image =
|
|
5949
|
+
this._data.image = getImage(this.dataSrc, this.dataSrcset, this.sizes).then(function (img) {
|
|
5931
5950
|
|
|
5932
|
-
setSrcAttrs(this$1$1.$el, currentSrc(img));
|
|
5951
|
+
setSrcAttrs(this$1$1.$el, currentSrc(img), img.srcset, img.sizes);
|
|
5933
5952
|
storage[this$1$1.cacheKey] = currentSrc(img);
|
|
5934
5953
|
return img;
|
|
5935
5954
|
|
|
@@ -5950,18 +5969,13 @@
|
|
|
5950
5969
|
|
|
5951
5970
|
};
|
|
5952
5971
|
|
|
5953
|
-
|
|
5954
|
-
function setSrcAttrs(el, src) {
|
|
5972
|
+
function setSrcAttrs(el, src, srcset, sizes) {
|
|
5955
5973
|
|
|
5956
|
-
var parentNode = parent(el);
|
|
5957
5974
|
if (isImg(el)) {
|
|
5958
|
-
|
|
5959
|
-
|
|
5960
|
-
|
|
5961
|
-
|
|
5962
|
-
}
|
|
5963
|
-
}); }
|
|
5964
|
-
);
|
|
5975
|
+
var set = function (prop, val) { return val && val !== el[prop] && (el[prop] = val); };
|
|
5976
|
+
set('sizes', sizes);
|
|
5977
|
+
set('srcset', srcset);
|
|
5978
|
+
set('src', src);
|
|
5965
5979
|
} else if (src) {
|
|
5966
5980
|
|
|
5967
5981
|
var change = !includes(el.style.backgroundImage, src);
|
|
@@ -5974,12 +5988,9 @@
|
|
|
5974
5988
|
|
|
5975
5989
|
}
|
|
5976
5990
|
|
|
5977
|
-
function getPlaceholderImage(
|
|
5991
|
+
function getPlaceholderImage(width, height, sizes) {
|
|
5978
5992
|
var assign;
|
|
5979
5993
|
|
|
5980
|
-
var sizes = data(el, 'sizes');
|
|
5981
|
-
var width = data(el, 'width');
|
|
5982
|
-
var height = data(el, 'height');
|
|
5983
5994
|
|
|
5984
5995
|
if (sizes) {
|
|
5985
5996
|
((assign = Dimensions.ratio({width: width, height: height}, 'width', toPx(sizesToPixel(sizes))), width = assign.width, height = assign.height));
|
|
@@ -6004,19 +6015,6 @@
|
|
|
6004
6015
|
return matches || '100vw';
|
|
6005
6016
|
}
|
|
6006
6017
|
|
|
6007
|
-
function getImageFromElement(el) {
|
|
6008
|
-
var parentNode = parent(el);
|
|
6009
|
-
if (!isPicture(parentNode)) {
|
|
6010
|
-
return getImage.apply(void 0, srcProps.map(function (prop) { return data(el, prop); }));
|
|
6011
|
-
}
|
|
6012
|
-
|
|
6013
|
-
return new Promise(function (resolve, reject) {
|
|
6014
|
-
var picture = parentNode.cloneNode(true);
|
|
6015
|
-
once(picture, 'load error', function (e) { return e.type === 'error' ? reject(e) : resolve(e.target); }, true);
|
|
6016
|
-
setSrcAttrs(el);
|
|
6017
|
-
});
|
|
6018
|
-
}
|
|
6019
|
-
|
|
6020
6018
|
var sizeRe = /\d+(?:\w+|%)/g;
|
|
6021
6019
|
var additionRe = /[+-]?(\d+)/g;
|
|
6022
6020
|
function evaluateSize(size) {
|
|
@@ -6038,16 +6036,8 @@
|
|
|
6038
6036
|
return descriptors.filter(function (size) { return size >= srcSize; })[0] || descriptors.pop() || '';
|
|
6039
6037
|
}
|
|
6040
6038
|
|
|
6041
|
-
function isPicture(el) {
|
|
6042
|
-
return isA(el, 'PICTURE');
|
|
6043
|
-
}
|
|
6044
|
-
|
|
6045
6039
|
function isImg(el) {
|
|
6046
|
-
return
|
|
6047
|
-
}
|
|
6048
|
-
|
|
6049
|
-
function isA(el, tagName) {
|
|
6050
|
-
return el && el.tagName === tagName;
|
|
6040
|
+
return el.tagName === 'IMG';
|
|
6051
6041
|
}
|
|
6052
6042
|
|
|
6053
6043
|
function currentSrc(el) {
|
|
@@ -7829,7 +7819,7 @@
|
|
|
7829
7819
|
{
|
|
7830
7820
|
|
|
7831
7821
|
read: function(ref, types) {
|
|
7832
|
-
var height = ref.height;
|
|
7822
|
+
var height$1 = ref.height;
|
|
7833
7823
|
|
|
7834
7824
|
|
|
7835
7825
|
this.inactive = !this.matchMedia || !isVisible(this.$el);
|
|
@@ -7840,15 +7830,20 @@
|
|
|
7840
7830
|
|
|
7841
7831
|
if (this.isActive && types.has('resize')) {
|
|
7842
7832
|
this.hide();
|
|
7843
|
-
height = this.$el.offsetHeight;
|
|
7833
|
+
height$1 = this.$el.offsetHeight;
|
|
7844
7834
|
this.show();
|
|
7845
7835
|
}
|
|
7846
7836
|
|
|
7847
|
-
height = !this.isActive ? this.$el.offsetHeight : height;
|
|
7837
|
+
height$1 = !this.isActive ? this.$el.offsetHeight : height$1;
|
|
7838
|
+
|
|
7839
|
+
if (height$1 + this.offset > height(window)) {
|
|
7840
|
+
this.inactive = true;
|
|
7841
|
+
return false;
|
|
7842
|
+
}
|
|
7848
7843
|
|
|
7849
7844
|
var referenceElement = this.isFixed ? this.placeholder : this.$el;
|
|
7850
7845
|
this.topOffset = offset(referenceElement).top;
|
|
7851
|
-
this.bottomOffset = this.topOffset + height;
|
|
7846
|
+
this.bottomOffset = this.topOffset + height$1;
|
|
7852
7847
|
this.offsetParentTop = offset(referenceElement.offsetParent).top;
|
|
7853
7848
|
|
|
7854
7849
|
var bottom = parseProp('bottom', this);
|
|
@@ -7858,7 +7853,7 @@
|
|
|
7858
7853
|
this.width = dimensions(isVisible(this.widthElement) ? this.widthElement : this.$el).width;
|
|
7859
7854
|
|
|
7860
7855
|
return {
|
|
7861
|
-
height: height,
|
|
7856
|
+
height: height$1,
|
|
7862
7857
|
top: offsetPosition(this.placeholder)[0],
|
|
7863
7858
|
margins: css(this.$el, ['marginTop', 'marginBottom', 'marginLeft', 'marginRight'])
|
|
7864
7859
|
};
|
|
@@ -12190,7 +12185,7 @@
|
|
|
12190
12185
|
var dist = (Date.now() - last) * .3;
|
|
12191
12186
|
last = Date.now();
|
|
12192
12187
|
|
|
12193
|
-
scrollParents(document.elementFromPoint(x, pos.y)).reverse().some(function (scrollEl) {
|
|
12188
|
+
scrollParents(document.elementFromPoint(x, pos.y), /auto|scroll/).reverse().some(function (scrollEl) {
|
|
12194
12189
|
|
|
12195
12190
|
var scroll = scrollEl.scrollTop;
|
|
12196
12191
|
var scrollHeight = scrollEl.scrollHeight;
|