uikit 3.15.11-dev.fd61e70ff → 3.15.12-dev.0c0d42cdf
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 +21 -6
- package/build/util.js +26 -20
- package/dist/css/uikit-core-rtl.css +3 -3
- 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 +3 -3
- 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 +14 -13
- package/dist/js/components/countdown.min.js +1 -1
- package/dist/js/components/filter.js +31 -32
- package/dist/js/components/filter.min.js +1 -1
- package/dist/js/components/lightbox-panel.js +165 -150
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +173 -158
- package/dist/js/components/lightbox.min.js +1 -1
- package/dist/js/components/notification.js +19 -17
- package/dist/js/components/notification.min.js +1 -1
- package/dist/js/components/parallax.js +37 -36
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +38 -29
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +84 -73
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +38 -29
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +95 -78
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +39 -39
- package/dist/js/components/sortable.min.js +1 -1
- package/dist/js/components/tooltip.js +43 -39
- package/dist/js/components/tooltip.min.js +1 -1
- package/dist/js/components/upload.js +12 -12
- package/dist/js/components/upload.min.js +1 -1
- package/dist/js/uikit-core.js +582 -530
- package/dist/js/uikit-core.min.js +1 -17
- package/dist/js/uikit-icons.js +3 -3
- package/dist/js/uikit-icons.min.js +1 -1
- package/dist/js/uikit.js +883 -805
- package/dist/js/uikit.min.js +1 -17
- package/package.json +14 -14
- package/src/js/api/boot.js +3 -1
- package/src/js/components/lightbox-panel.js +5 -2
- package/src/js/components/slider-parallax.js +9 -0
- package/src/js/core/drop.js +5 -1
- package/src/js/core/margin.js +2 -0
- package/src/js/core/sticky.js +6 -7
- package/src/js/core/video.js +4 -3
- package/src/js/mixin/internal/animate-slide.js +1 -4
- package/src/js/util/env.js +1 -3
- package/src/js/util/position.js +11 -6
- package/tests/navbar.html +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.15.
|
|
1
|
+
/*! UIkit 3.15.12-dev.0c0d42cdf | 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(require('uikit-util')) :
|
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
var Class = {
|
|
10
10
|
connected() {
|
|
11
11
|
uikitUtil.addClass(this.$el, this.$options.id);
|
|
12
|
-
}
|
|
12
|
+
}
|
|
13
|
+
};
|
|
13
14
|
|
|
14
15
|
const units = ['days', 'hours', 'minutes', 'seconds'];
|
|
15
16
|
|
|
@@ -18,13 +19,13 @@
|
|
|
18
19
|
|
|
19
20
|
props: {
|
|
20
21
|
date: String,
|
|
21
|
-
clsWrapper: String
|
|
22
|
-
|
|
22
|
+
clsWrapper: String
|
|
23
|
+
},
|
|
23
24
|
|
|
24
25
|
data: {
|
|
25
26
|
date: '',
|
|
26
|
-
clsWrapper: '.uk-countdown-%unit%'
|
|
27
|
-
|
|
27
|
+
clsWrapper: '.uk-countdown-%unit%'
|
|
28
|
+
},
|
|
28
29
|
|
|
29
30
|
connected() {
|
|
30
31
|
this.date = Date.parse(this.$props.date);
|
|
@@ -49,8 +50,8 @@
|
|
|
49
50
|
} else {
|
|
50
51
|
this.start();
|
|
51
52
|
}
|
|
52
|
-
}
|
|
53
|
-
|
|
53
|
+
}
|
|
54
|
+
}],
|
|
54
55
|
|
|
55
56
|
|
|
56
57
|
methods: {
|
|
@@ -94,9 +95,9 @@
|
|
|
94
95
|
digits.forEach((digit, i) => el.children[i].textContent = digit);
|
|
95
96
|
}
|
|
96
97
|
}
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
};
|
|
100
101
|
|
|
101
102
|
function getTimeSpan(date) {
|
|
102
103
|
const total = date - Date.now();
|
|
@@ -106,8 +107,8 @@
|
|
|
106
107
|
seconds: total / 1000 % 60,
|
|
107
108
|
minutes: total / 1000 / 60 % 60,
|
|
108
109
|
hours: total / 1000 / 60 / 60 % 24,
|
|
109
|
-
days: total / 1000 / 60 / 60 / 24
|
|
110
|
-
|
|
110
|
+
days: total / 1000 / 60 / 60 / 24
|
|
111
|
+
};
|
|
111
112
|
}
|
|
112
113
|
|
|
113
114
|
if (typeof window !== 'undefined' && window.UIkit) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
/*! UIkit 3.15.
|
|
1
|
+
/*! UIkit 3.15.12-dev.0c0d42cdf | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */(function(e,s){typeof exports=="object"&&typeof module<"u"?module.exports=s(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitcountdown",["uikit-util"],s):(e=typeof globalThis<"u"?globalThis:e||self,e.UIkitCountdown=s(e.UIkit.util))})(this,function(e){"use strict";var s={connected(){e.addClass(this.$el,this.$options.id)}};const a=["days","hours","minutes","seconds"];var d={mixins:[s],props:{date:String,clsWrapper:String},data:{date:"",clsWrapper:".uk-countdown-%unit%"},connected(){this.date=Date.parse(this.$props.date),this.start()},disconnected(){this.stop()},events:[{name:"visibilitychange",el(){return document},handler(){document.hidden?this.stop():this.start()}}],methods:{start(){this.stop(),this.update(),this.timer=setInterval(this.update,1e3)},stop(){clearInterval(this.timer)},update(){const n=r(this.date);(!this.date||n.total<=0)&&(this.stop(),n.days=n.hours=n.minutes=n.seconds=0);for(const i of a){const o=e.$(this.clsWrapper.replace("%unit%",i),this.$el);if(!o)continue;let t=String(Math.trunc(n[i]));t=t.length<2?"0"+t:t,o.textContent!==t&&(t=t.split(""),t.length!==o.children.length&&e.html(o,t.map(()=>"<span></span>").join("")),t.forEach((u,h)=>o.children[h].textContent=u))}}}};function r(n){const i=n-Date.now();return{total:i,seconds:i/1e3%60,minutes:i/1e3/60%60,hours:i/1e3/60/60%24,days:i/1e3/60/60/24}}return typeof window<"u"&&window.UIkit&&window.UIkit.component("countdown",d),d});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.15.
|
|
1
|
+
/*! UIkit 3.15.12-dev.0c0d42cdf | 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(require('uikit-util')) :
|
|
@@ -67,8 +67,8 @@
|
|
|
67
67
|
top: offsetTop,
|
|
68
68
|
left: offsetLeft,
|
|
69
69
|
bottom: offsetTop + offsetHeight,
|
|
70
|
-
right: offsetLeft + offsetWidth
|
|
71
|
-
|
|
70
|
+
right: offsetLeft + offsetWidth
|
|
71
|
+
};
|
|
72
72
|
}
|
|
73
73
|
|
|
74
74
|
const clsLeave = 'uk-transition-leave';
|
|
@@ -224,10 +224,7 @@
|
|
|
224
224
|
const targetStyle = uikitUtil.attr(target, 'style');
|
|
225
225
|
const targetPropsTo = uikitUtil.css(target, ['height', 'padding']);
|
|
226
226
|
const [propsTo, propsFrom] = getTransitionProps(target, nodes, currentProps);
|
|
227
|
-
const attrsTo = nodes.map((el) => ({
|
|
228
|
-
class: uikitUtil.attr(el, 'class'),
|
|
229
|
-
style: uikitUtil.attr(el, 'style') }));
|
|
230
|
-
|
|
227
|
+
const attrsTo = nodes.map((el) => ({ style: uikitUtil.attr(el, 'style') }));
|
|
231
228
|
|
|
232
229
|
// Reset to previous state
|
|
233
230
|
nodes.forEach((el, i) => propsFrom[i] && uikitUtil.css(el, propsFrom[i]));
|
|
@@ -265,8 +262,8 @@
|
|
|
265
262
|
pointerEvents: 'none',
|
|
266
263
|
position: 'absolute',
|
|
267
264
|
zIndex: zIndex === 'auto' ? uikitUtil.index(el) : zIndex,
|
|
268
|
-
...getPositionWithMargin(el)
|
|
269
|
-
|
|
265
|
+
...getPositionWithMargin(el)
|
|
266
|
+
} :
|
|
270
267
|
false;
|
|
271
268
|
}
|
|
272
269
|
|
|
@@ -320,8 +317,8 @@
|
|
|
320
317
|
width,
|
|
321
318
|
transform: '',
|
|
322
319
|
...uikitUtil.position(el),
|
|
323
|
-
...uikitUtil.css(el, ['marginTop', 'marginLeft'])
|
|
324
|
-
|
|
320
|
+
...uikitUtil.css(el, ['marginTop', 'marginLeft'])
|
|
321
|
+
};
|
|
325
322
|
}
|
|
326
323
|
|
|
327
324
|
function awaitFrame() {
|
|
@@ -331,13 +328,13 @@
|
|
|
331
328
|
var Animate = {
|
|
332
329
|
props: {
|
|
333
330
|
duration: Number,
|
|
334
|
-
animation: Boolean
|
|
335
|
-
|
|
331
|
+
animation: Boolean
|
|
332
|
+
},
|
|
336
333
|
|
|
337
334
|
data: {
|
|
338
335
|
duration: 150,
|
|
339
|
-
animation: 'slide'
|
|
340
|
-
|
|
336
|
+
animation: 'slide'
|
|
337
|
+
},
|
|
341
338
|
|
|
342
339
|
methods: {
|
|
343
340
|
animate(action, target) {if (target === void 0) {target = this.$el;}
|
|
@@ -355,7 +352,9 @@
|
|
|
355
352
|
};
|
|
356
353
|
|
|
357
354
|
return animationFn(action, target, this.duration).catch(uikitUtil.noop);
|
|
358
|
-
}
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
};
|
|
359
358
|
|
|
360
359
|
var Component = {
|
|
361
360
|
mixins: [Animate],
|
|
@@ -364,16 +363,16 @@
|
|
|
364
363
|
|
|
365
364
|
props: {
|
|
366
365
|
target: Boolean,
|
|
367
|
-
selActive: Boolean
|
|
368
|
-
|
|
366
|
+
selActive: Boolean
|
|
367
|
+
},
|
|
369
368
|
|
|
370
369
|
data: {
|
|
371
370
|
target: null,
|
|
372
371
|
selActive: false,
|
|
373
372
|
attrItem: 'uk-filter-control',
|
|
374
373
|
cls: 'uk-active',
|
|
375
|
-
duration: 250
|
|
376
|
-
|
|
374
|
+
duration: 250
|
|
375
|
+
},
|
|
377
376
|
|
|
378
377
|
computed: {
|
|
379
378
|
toggles: {
|
|
@@ -390,8 +389,8 @@
|
|
|
390
389
|
}
|
|
391
390
|
},
|
|
392
391
|
|
|
393
|
-
immediate: true
|
|
394
|
-
|
|
392
|
+
immediate: true
|
|
393
|
+
},
|
|
395
394
|
|
|
396
395
|
children: {
|
|
397
396
|
get(_ref2, $el) {let { target } = _ref2;
|
|
@@ -404,9 +403,9 @@
|
|
|
404
403
|
}
|
|
405
404
|
},
|
|
406
405
|
|
|
407
|
-
immediate: true
|
|
408
|
-
|
|
409
|
-
|
|
406
|
+
immediate: true
|
|
407
|
+
}
|
|
408
|
+
},
|
|
410
409
|
|
|
411
410
|
events: [
|
|
412
411
|
{
|
|
@@ -419,8 +418,8 @@
|
|
|
419
418
|
handler(e) {
|
|
420
419
|
e.preventDefault();
|
|
421
420
|
this.apply(e.current);
|
|
422
|
-
}
|
|
423
|
-
|
|
421
|
+
}
|
|
422
|
+
}],
|
|
424
423
|
|
|
425
424
|
|
|
426
425
|
methods: {
|
|
@@ -438,8 +437,8 @@
|
|
|
438
437
|
filter((item) => uikitUtil.hasClass(item, this.cls)).
|
|
439
438
|
reduce((state, el) => mergeState(el, this.attrItem, state), {
|
|
440
439
|
filter: { '': '' },
|
|
441
|
-
sort: []
|
|
442
|
-
|
|
440
|
+
sort: []
|
|
441
|
+
});
|
|
443
442
|
},
|
|
444
443
|
|
|
445
444
|
async setState(state, animate) {if (animate === void 0) {animate = true;}
|
|
@@ -466,9 +465,9 @@
|
|
|
466
465
|
|
|
467
466
|
updateState() {
|
|
468
467
|
uikitUtil.fastdom.write(() => this.setState(this.getState(), false));
|
|
469
|
-
}
|
|
470
|
-
|
|
471
|
-
|
|
468
|
+
}
|
|
469
|
+
}
|
|
470
|
+
};
|
|
472
471
|
|
|
473
472
|
function getFilter(el, attr) {
|
|
474
473
|
return uikitUtil.parseOptions(uikitUtil.data(el, attr), ['filter']);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
/*! UIkit 3.15.
|
|
1
|
+
/*! UIkit 3.15.12-dev.0c0d42cdf | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */(function(n,y){typeof exports=="object"&&typeof module<"u"?module.exports=y(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitfilter",["uikit-util"],y):(n=typeof globalThis<"u"?globalThis:n||self,n.UIkitFilter=y(n.UIkit.util))})(this,function(n){"use strict";function y(s){return q(s,"top","bottom")}function q(s,e,t){const o=[[]];for(const c of s){if(!n.isVisible(c))continue;let r=u(c);for(let a=o.length-1;a>=0;a--){const f=o[a];if(!f[0]){f.push(c);break}let h;if(f[0].offsetParent===c.offsetParent?h=u(f[0]):(r=u(c,!0),h=u(f[0],!0)),r[e]>=h[t]-1&&r[e]!==h[e]){o.push([c]);break}if(r[t]-1>h[e]||r[e]===h[e]){f.push(c);break}if(a===0){o.unshift([c]);break}}}return o}function u(s,e){e===void 0&&(e=!1);let{offsetTop:t,offsetLeft:o,offsetHeight:c,offsetWidth:r}=s;return e&&([t,o]=n.offsetPosition(s)),{top:t,left:o,bottom:t+c,right:o+r}}const v="uk-transition-leave",g="uk-transition-enter";function T(s,e,t,o){o===void 0&&(o=0);const c=w(e,!0),r={opacity:1},a={opacity:0},f=m=>()=>c===w(e)?m():Promise.reject(),h=f(async()=>{n.addClass(e,v),await Promise.all(F(e).map((m,l)=>new Promise(d=>setTimeout(()=>n.Transition.start(m,a,t/2,"ease").then(d),l*o)))),n.removeClass(e,v)}),p=f(async()=>{const m=n.height(e);n.addClass(e,g),s(),n.css(n.children(e),{opacity:0}),await A();const l=n.children(e),d=n.height(e);n.css(e,"alignContent","flex-start"),n.height(e,m);const i=F(e);n.css(l,a);const x=i.map(async(R,G)=>{await L(G*o),await n.Transition.start(R,r,t/2,"ease")});m!==d&&x.push(n.Transition.start(e,{height:d},t/2+i.length*o,"ease")),await Promise.all(x).then(()=>{n.removeClass(e,g),c===w(e)&&(n.css(e,{height:"",alignContent:""}),n.css(l,{opacity:""}),delete e.dataset.transition)})});return n.hasClass(e,v)?I(e).then(p):n.hasClass(e,g)?I(e).then(h).then(p):h().then(p)}function w(s,e){return e&&(s.dataset.transition=1+w(s)),n.toNumber(s.dataset.transition)||0}function I(s){return Promise.all(n.children(s).filter(n.Transition.inProgress).map(e=>new Promise(t=>n.once(e,"transitionend transitioncanceled",t))))}function F(s){return y(n.children(s)).reduce((e,t)=>e.concat(n.sortBy(t.filter(o=>n.isInView(o)),"offsetLeft")),[])}function A(){return new Promise(s=>requestAnimationFrame(s))}function L(s){return new Promise(e=>setTimeout(e,s))}async function V(s,e,t){await $();let o=n.children(e);const c=o.map(d=>S(d,!0)),r={...n.css(e,["height","padding"]),display:"block"};await Promise.all(o.concat(e).map(n.Transition.cancel)),s(),o=o.concat(n.children(e).filter(d=>!n.includes(o,d))),await Promise.resolve(),n.fastdom.flush();const a=n.attr(e,"style"),f=n.css(e,["height","padding"]),[h,p]=B(e,o,c),m=o.map(d=>({style:n.attr(d,"style")}));o.forEach((d,i)=>p[i]&&n.css(d,p[i])),n.css(e,r),await $();const l=o.map((d,i)=>n.parent(d)===e&&n.Transition.start(d,h[i],t,"ease")).concat(n.Transition.start(e,f,t,"ease"));try{await Promise.all(l),o.forEach((d,i)=>{n.attr(d,m[i]),n.parent(d)===e&&n.css(d,"display",h[i].opacity===0?"none":"")}),n.attr(e,"style",a)}catch{n.attr(o,"style",""),N(e,r)}}function S(s,e){const t=n.css(s,"zIndex");return n.isVisible(s)?{display:"",opacity:e?n.css(s,"opacity"):"0",pointerEvents:"none",position:"absolute",zIndex:t==="auto"?n.index(s):t,...P(s)}:!1}function B(s,e,t){const o=e.map((r,a)=>n.parent(r)&&a in t?t[a]?n.isVisible(r)?P(r):{opacity:0}:{opacity:n.isVisible(r)?1:0}:!1),c=o.map((r,a)=>{const f=n.parent(e[a])===s&&(t[a]||S(e[a]));if(!f)return!1;if(!r)delete f.opacity;else if(!("opacity"in r)){const{opacity:h}=f;h%1?r.opacity=1:delete f.opacity}return f});return[o,c]}function N(s,e){for(const t in e)n.css(s,t,"")}function P(s){const{height:e,width:t}=n.offset(s);return{height:e,width:t,transform:"",...n.position(s),...n.css(s,["marginTop","marginLeft"])}}function $(){return new Promise(s=>requestAnimationFrame(s))}var O={props:{duration:Number,animation:Boolean},data:{duration:150,animation:"slide"},methods:{animate(s,e){e===void 0&&(e=this.$el);const t=this.animation;return(t==="fade"?T:t==="delayed-fade"?function(){for(var c=arguments.length,r=new Array(c),a=0;a<c;a++)r[a]=arguments[a];return T(...r,40)}:t?V:()=>(s(),Promise.resolve()))(s,e,this.duration).catch(n.noop)}}},b={mixins:[O],args:"target",props:{target:Boolean,selActive:Boolean},data:{target:null,selActive:!1,attrItem:"uk-filter-control",cls:"uk-active",duration:250},computed:{toggles:{get(s,e){let{attrItem:t}=s;return n.$$("["+t+"],[data-"+t+"]",e)},watch(){if(this.updateState(),this.selActive!==!1){const s=n.$$(this.selActive,this.$el);this.toggles.forEach(e=>n.toggleClass(e,this.cls,n.includes(s,e)))}},immediate:!0},children:{get(s,e){let{target:t}=s;return n.$$(t+" > *",e)},watch(s,e){e&&!D(s,e)&&this.updateState()},immediate:!0}},events:[{name:"click",delegate(){return"["+this.attrItem+"],[data-"+this.attrItem+"]"},handler(s){s.preventDefault(),this.apply(s.current)}}],methods:{apply(s){const e=this.getState(),t=E(s,this.attrItem,this.getState());z(e,t)||this.setState(t)},getState(){return this.toggles.filter(s=>n.hasClass(s,this.cls)).reduce((s,e)=>E(e,this.attrItem,s),{filter:{"":""},sort:[]})},async setState(s,e){e===void 0&&(e=!0),s={filter:{"":""},sort:[],...s},n.trigger(this.$el,"beforeFilter",[this,s]),this.toggles.forEach(t=>n.toggleClass(t,this.cls,!!j(t,this.attrItem,s))),await Promise.all(n.$$(this.target,this.$el).map(t=>{const o=()=>{H(s,t,n.children(t)),this.$update(this.$el)};return e?this.animate(o,t):o()})),n.trigger(this.$el,"afterFilter",[this])},updateState(){n.fastdom.write(()=>this.setState(this.getState(),!1))}}};function C(s,e){return n.parseOptions(n.data(s,e),["filter"])}function z(s,e){return["filter","sort"].every(t=>n.isEqual(s[t],e[t]))}function H(s,e,t){const o=W(s);t.forEach(a=>n.css(a,"display",o&&!n.matches(a,o)?"none":""));const[c,r]=s.sort;if(c){const a=M(t,c,r);n.isEqual(a,t)||n.append(e,a)}}function E(s,e,t){const{filter:o,group:c,sort:r,order:a="asc"}=C(s,e);return(o||n.isUndefined(r))&&(c?o?(delete t.filter[""],t.filter[c]=o):(delete t.filter[c],(n.isEmpty(t.filter)||""in t.filter)&&(t.filter={"":o||""})):t.filter={"":o||""}),n.isUndefined(r)||(t.sort=[r,a]),t}function j(s,e,t){let{filter:o={"":""},sort:[c,r]}=t;const{filter:a="",group:f="",sort:h,order:p="asc"}=C(s,e);return n.isUndefined(h)?f in o&&a===o[f]||!a&&f&&!(f in o)&&!o[""]:c===h&&r===p}function D(s,e){return s.length===e.length&&s.every(t=>e.includes(t))}function W(s){let{filter:e}=s,t="";return n.each(e,o=>t+=o||""),t}function M(s,e,t){return[...s].sort((o,c)=>n.data(o,e).localeCompare(n.data(c,e),void 0,{numeric:!0})*(t==="asc"||-1))}return typeof window<"u"&&window.UIkit&&window.UIkit.component("filter",b),b});
|