uikit 3.14.4-dev.ce706e326 → 3.14.4-dev.dbd727038

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.
Files changed (73) hide show
  1. package/CHANGELOG.md +9 -1
  2. package/dist/css/uikit-core-rtl.css +62 -14
  3. package/dist/css/uikit-core-rtl.min.css +1 -1
  4. package/dist/css/uikit-core.css +62 -14
  5. package/dist/css/uikit-core.min.css +1 -1
  6. package/dist/css/uikit-rtl.css +62 -15
  7. package/dist/css/uikit-rtl.min.css +1 -1
  8. package/dist/css/uikit.css +62 -15
  9. package/dist/css/uikit.min.css +1 -1
  10. package/dist/js/components/countdown.js +1 -1
  11. package/dist/js/components/countdown.min.js +1 -1
  12. package/dist/js/components/filter.js +7 -5
  13. package/dist/js/components/filter.min.js +1 -1
  14. package/dist/js/components/lightbox-panel.js +27 -20
  15. package/dist/js/components/lightbox-panel.min.js +1 -1
  16. package/dist/js/components/lightbox.js +27 -20
  17. package/dist/js/components/lightbox.min.js +1 -1
  18. package/dist/js/components/notification.js +1 -1
  19. package/dist/js/components/notification.min.js +1 -1
  20. package/dist/js/components/parallax.js +1 -1
  21. package/dist/js/components/parallax.min.js +1 -1
  22. package/dist/js/components/slider-parallax.js +1 -1
  23. package/dist/js/components/slider-parallax.min.js +1 -1
  24. package/dist/js/components/slider.js +22 -7
  25. package/dist/js/components/slider.min.js +1 -1
  26. package/dist/js/components/slideshow-parallax.js +1 -1
  27. package/dist/js/components/slideshow-parallax.min.js +1 -1
  28. package/dist/js/components/slideshow.js +22 -7
  29. package/dist/js/components/slideshow.min.js +1 -1
  30. package/dist/js/components/sortable.js +3 -3
  31. package/dist/js/components/sortable.min.js +1 -1
  32. package/dist/js/components/tooltip.js +23 -16
  33. package/dist/js/components/tooltip.min.js +1 -1
  34. package/dist/js/components/upload.js +1 -1
  35. package/dist/js/components/upload.min.js +1 -1
  36. package/dist/js/uikit-core.js +84 -56
  37. package/dist/js/uikit-core.min.js +1 -1
  38. package/dist/js/uikit-icons.js +1 -1
  39. package/dist/js/uikit-icons.min.js +1 -1
  40. package/dist/js/uikit.js +137 -92
  41. package/dist/js/uikit.min.js +1 -1
  42. package/package.json +1 -1
  43. package/src/images/backgrounds/nav-parent-close.svg +1 -1
  44. package/src/images/backgrounds/nav-parent-open.svg +1 -1
  45. package/src/images/components/navbar-parent-icon.svg +3 -0
  46. package/src/js/components/filter.js +5 -3
  47. package/src/js/components/sortable.js +2 -3
  48. package/src/js/core/height-viewport.js +3 -1
  49. package/src/js/core/icon.js +2 -0
  50. package/src/js/core/index.js +1 -0
  51. package/src/js/core/navbar.js +44 -15
  52. package/src/js/core/sticky.js +8 -9
  53. package/src/js/mixin/position.js +24 -7
  54. package/src/js/mixin/slider-drag.js +20 -8
  55. package/src/js/mixin/togglable.js +8 -17
  56. package/src/js/util/position.js +1 -0
  57. package/src/js/util/viewport.js +2 -27
  58. package/src/less/components/dropdown.less +8 -0
  59. package/src/less/components/navbar.less +95 -14
  60. package/src/less/theme/navbar.less +4 -6
  61. package/src/scss/components/dropdown.scss +8 -0
  62. package/src/scss/components/nav.scss +2 -2
  63. package/src/scss/components/navbar.scss +83 -14
  64. package/src/scss/mixins-theme.scss +13 -4
  65. package/src/scss/mixins.scss +12 -0
  66. package/src/scss/theme/navbar.scss +3 -2
  67. package/src/scss/variables-theme.scss +18 -6
  68. package/src/scss/variables.scss +18 -5
  69. package/tests/drop.html +66 -16
  70. package/tests/dropdown.html +103 -16
  71. package/tests/index.html +1 -1
  72. package/tests/nav.html +12 -79
  73. package/tests/navbar.html +283 -56
@@ -1 +1 @@
1
- /*! UIkit 3.14.4-dev.ce706e326 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */(function(s,l){typeof exports=="object"&&typeof module<"u"?module.exports=l(require("uikit-util")):typeof define=="function"&&define.amd?define("uikittooltip",["uikit-util"],l):(s=typeof globalThis<"u"?globalThis:s||self,s.UIkitTooltip=l(s.UIkit.util))})(this,function(s){"use strict";var l={props:{container:Boolean},data:{container:!0},computed:{container(o){let{container:t}=o;return t===!0&&this.$container||t&&s.$(t)}}},b={props:{cls:Boolean,animation:"list",duration:Number,velocity:Number,origin:String,transition:String},data:{cls:!1,animation:[!1],duration:200,velocity:.2,origin:!1,transition:"ease",clsEnter:"uk-togglabe-enter",clsLeave:"uk-togglabe-leave",initProps:{overflow:"",maxHeight:"",paddingTop:"",paddingBottom:"",marginTop:"",marginBottom:"",boxShadow:""},hideProps:{overflow:"hidden",maxHeight:0,paddingTop:0,paddingBottom:0,marginTop:0,marginBottom:0,boxShadow:"none"}},computed:{hasAnimation(o){let{animation:t}=o;return!!t[0]},hasTransition(o){let{animation:t}=o;return s.startsWith(t[0],"slide")}},methods:{toggleElement(o,t,n){return new Promise(e=>Promise.all(s.toNodes(o).map(r=>{const i=s.isBoolean(t)?t:!this.isToggled(r);if(!s.trigger(r,"before"+(i?"show":"hide"),[this]))return Promise.reject();const c=(s.isFunction(n)?n:n===!1||!this.hasAnimation?P(this):this.hasTransition?u(this):$(this))(r,i),h=i?this.clsEnter:this.clsLeave;s.addClass(r,h),s.trigger(r,i?"show":"hide",[this]);const a=()=>{s.removeClass(r,h),s.trigger(r,i?"shown":"hidden",[this]),this.$update(r)};return c?c.then(a,()=>(s.removeClass(r,h),Promise.reject())):a()})).then(e,s.noop))},isToggled(o){return o===void 0&&(o=this.$el),[o]=s.toNodes(o),s.hasClass(o,this.clsEnter)?!0:s.hasClass(o,this.clsLeave)?!1:this.cls?s.hasClass(o,this.cls.split(" ")[0]):s.isVisible(o)},_toggle(o,t){if(!o)return;t=Boolean(t);let n;this.cls?(n=s.includes(this.cls," ")||t!==s.hasClass(o,this.cls),n&&s.toggleClass(o,this.cls,s.includes(this.cls," ")?void 0:t)):(n=t===o.hidden,n&&(o.hidden=!t)),s.$$("[autofocus]",o).some(e=>s.isVisible(e)?e.focus()||!0:e.blur()),n&&(s.trigger(o,"toggled",[t,this]),this.$update(o))}}};function P(o){let{_toggle:t}=o;return(n,e)=>(s.Animation.cancel(n),s.Transition.cancel(n),t(n,e))}function u(o){switch(o.animation[0]){case"slide-left":return v(o);case"slide-right":return v(o,!0)}return x(o)}function x(o){let{isToggled:t,duration:n,velocity:e,initProps:r,hideProps:i,transition:c,_toggle:h}=o;return(a,f)=>{const w=s.Transition.inProgress(a),m=!w&&a.hasChildNodes()?s.toFloat(s.css(a.firstElementChild,"marginTop"))+s.toFloat(s.css(a.lastElementChild,"marginBottom")):0,d=s.isVisible(a)?s.toFloat(s.css(a,"height"))+m:0,p=w?s.css(a,Object.keys(r)):f?i:r;s.Transition.cancel(a),t(a)||h(a,!0),s.css(a,"maxHeight",""),s.fastdom.flush();const g=s.toFloat(s.css(a,"height"))+m;return n=e*g+n,s.css(a,{...p,maxHeight:d}),(f?s.Transition.start(a,{...r,overflow:"hidden",maxHeight:g},n*(1-d/g),c):s.Transition.start(a,i,n*(d/g),c).then(()=>h(a,!1))).then(()=>s.css(a,r))}}function v(o,t){let{isToggled:n,duration:e,velocity:r,transition:i,_toggle:c}=o;return(h,a)=>{const f=s.isVisible(h),w=s.toFloat(s.css(h,"marginLeft"));s.Transition.cancel(h);const[m]=s.scrollParents(h);s.css(m,"overflowX","hidden"),n(h)||c(h,!0);const d=s.toFloat(s.css(h,"width"));e=r*d+e;const p=f?(d+w*(t?-1:1))/d*100:0,g=s.offset(h),T=t?g.right<m.clientWidth:Math.round(g.left)>0;return s.css(h,{clipPath:T?t?"polygon(0 0,"+p+"% 0,"+p+"% 100%,0 100%)":"polygon("+(100-p)+"% 0,100% 0,100% 100%,"+(100-p)+"% 100%)":"",marginLeft:(100-p)*(t?1:-1)/100*d}),(a?s.Transition.start(h,{clipPath:T?"polygon(0 0,100% 0,100% 100%,0 100%)":"",marginLeft:0},e*(1-p/100),i):s.Transition.start(h,{clipPath:T?t?"polygon(0 0,0 0,0 100%,0 100%)":"polygon(100% 0,100% 0,100% 100%,100% 100%)":"",marginLeft:(t?1:-1)*d},e*(p/100),i).then(()=>c(h,!1))).then(()=>{s.css(m,"overflowX",""),s.css(h,{clipPath:"",marginLeft:""})})}}function $(o){return(t,n)=>{s.Animation.cancel(t);const{animation:e,duration:r,_toggle:i}=o;return n?(i(t,!0),s.Animation.in(t,e[0],r,o.origin)):s.Animation.out(t,e[1]||e[0],r,o.origin).then(()=>i(t,!1))}}var C={props:{pos:String,offset:null,flip:Boolean},data:{pos:"bottom-"+(s.isRtl?"right":"left"),flip:!0,offset:!1},connected(){this.pos=this.$props.pos.split("-").concat("center").slice(0,2),[this.dir,this.align]=this.pos,this.axis=s.includes(["top","bottom"],this.dir)?"y":"x"},methods:{positionAt(o,t,n){let e=[this.getPositionOffset(o),this.getShiftOffset(o)];const r={element:[s.flipPosition(this.dir),this.align],target:[this.dir,this.align]};if(this.axis==="y"){for(const c in r)r[c]=r[c].reverse();e=e.reverse()}const i=s.dimensions(o);s.css(o,{top:-i.height,left:-i.width}),s.positionAt(o,t,{attach:r,offset:e,boundary:n,flip:this.flip,viewportOffset:this.getViewportOffset(o)})},getPositionOffset(o){return s.toPx(this.offset===!1?s.getCssVar("position-offset",o):this.offset,this.axis==="x"?"width":"height",o)*(s.includes(["left","top"],this.dir)?-1:1)},getShiftOffset(o){return s.includes(["center","justify","stretch"],this.align)?0:s.toPx(s.getCssVar("position-shift-offset",o),this.axis==="y"?"width":"height",o)*(s.includes(["left","top"],this.align)?1:-1)},getViewportOffset(o){return s.toPx(s.getCssVar("position-viewport-offset",o))}}},y={mixins:[l,b,C],args:"title",props:{delay:Number,title:String},data:{pos:"top",title:"",delay:0,animation:["uk-animation-scale-up"],duration:100,cls:"uk-active"},beforeConnect(){this._hasTitle=s.hasAttr(this.$el,"title"),s.attr(this.$el,"title",""),this.updateAria(!1),A(this.$el)},disconnected(){this.hide(),s.attr(this.$el,"title",this._hasTitle?this.title:null)},methods:{show(){this.isToggled(this.tooltip||null)||!this.title||(this._unbind=s.once(document,"show keydown "+s.pointerDown,this.hide,!1,o=>o.type===s.pointerDown&&!s.within(o.target,this.$el)||o.type==="keydown"&&o.keyCode===27||o.type==="show"&&o.detail[0]!==this&&o.detail[0].$name===this.$name),clearTimeout(this.showTimer),this.showTimer=setTimeout(this._show,this.delay))},async hide(){s.matches(this.$el,"input:focus")||(clearTimeout(this.showTimer),this.isToggled(this.tooltip||null)&&(await this.toggleElement(this.tooltip,!1,!1),s.remove(this.tooltip),this.tooltip=null,this._unbind()))},_show(){this.tooltip=s.append(this.container,'<div class="uk-'+this.$options.name+'"> <div class="uk-'+this.$options.name+'-inner">'+this.title+"</div> </div>"),s.on(this.tooltip,"toggled",(o,t)=>{if(this.updateAria(t),!t)return;this.positionAt(this.tooltip,this.$el);const[n,e]=E(this.tooltip,this.$el,this.pos);this.origin=this.axis==="y"?s.flipPosition(n)+"-"+e:e+"-"+s.flipPosition(n)}),this.toggleElement(this.tooltip,!0)},updateAria(o){s.attr(this.$el,"aria-expanded",o)}},events:{focus:"show",blur:"hide",[s.pointerEnter+" "+s.pointerLeave](o){s.isTouch(o)||this[o.type===s.pointerEnter?"show":"hide"]()},[s.pointerDown](o){s.isTouch(o)&&this.show()}}};function A(o){s.isFocusable(o)||s.attr(o,"tabindex","0")}function E(o,t,n){let[e,r]=n;const i=s.offset(o),c=s.offset(t),h=[["left","right"],["top","bottom"]];for(const f of h){if(i[f[0]]>=c[f[1]]){e=f[1];break}if(i[f[1]]<=c[f[0]]){e=f[0];break}}const a=s.includes(h[0],e)?h[1]:h[0];return i[a[0]]===c[a[0]]?r=a[0]:i[a[1]]===c[a[1]]?r=a[1]:r="center",[e,r]}return typeof window<"u"&&window.UIkit&&window.UIkit.component("tooltip",y),y});
1
+ /*! UIkit 3.14.4-dev.dbd727038 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */(function(s,l){typeof exports=="object"&&typeof module<"u"?module.exports=l(require("uikit-util")):typeof define=="function"&&define.amd?define("uikittooltip",["uikit-util"],l):(s=typeof globalThis<"u"?globalThis:s||self,s.UIkitTooltip=l(s.UIkit.util))})(this,function(s){"use strict";var l={props:{container:Boolean},data:{container:!0},computed:{container(o){let{container:t}=o;return t===!0&&this.$container||t&&s.$(t)}}},b={props:{cls:Boolean,animation:"list",duration:Number,velocity:Number,origin:String,transition:String},data:{cls:!1,animation:[!1],duration:200,velocity:.2,origin:!1,transition:"ease",clsEnter:"uk-togglabe-enter",clsLeave:"uk-togglabe-leave",initProps:{overflow:"",maxHeight:"",paddingTop:"",paddingBottom:"",marginTop:"",marginBottom:"",boxShadow:""},hideProps:{overflow:"hidden",maxHeight:0,paddingTop:0,paddingBottom:0,marginTop:0,marginBottom:0,boxShadow:"none"}},computed:{hasAnimation(o){let{animation:t}=o;return!!t[0]},hasTransition(o){let{animation:t}=o;return s.startsWith(t[0],"slide")}},methods:{toggleElement(o,t,r){return new Promise(n=>Promise.all(s.toNodes(o).map(a=>{const i=s.isBoolean(t)?t:!this.isToggled(a);if(!s.trigger(a,"before"+(i?"show":"hide"),[this]))return Promise.reject();const c=(s.isFunction(r)?r:r===!1||!this.hasAnimation?y(this):this.hasTransition?P(this):x(this))(a,i),h=i?this.clsEnter:this.clsLeave;s.addClass(a,h),s.trigger(a,i?"show":"hide",[this]);const e=()=>{s.removeClass(a,h),s.trigger(a,i?"shown":"hidden",[this]),this.$update(a)};return c?c.then(e,()=>(s.removeClass(a,h),Promise.reject())):e()})).then(n,s.noop))},isToggled(o){return o===void 0&&(o=this.$el),[o]=s.toNodes(o),s.hasClass(o,this.clsEnter)?!0:s.hasClass(o,this.clsLeave)?!1:this.cls?s.hasClass(o,this.cls.split(" ")[0]):s.isVisible(o)},_toggle(o,t){if(!o)return;t=Boolean(t);let r;this.cls?(r=s.includes(this.cls," ")||t!==s.hasClass(o,this.cls),r&&s.toggleClass(o,this.cls,s.includes(this.cls," ")?void 0:t)):(r=t===o.hidden,r&&(o.hidden=!t)),s.$$("[autofocus]",o).some(n=>s.isVisible(n)?n.focus()||!0:n.blur()),r&&(s.trigger(o,"toggled",[t,this]),this.$update(o))}}};function y(o){let{_toggle:t}=o;return(r,n)=>(s.Animation.cancel(r),s.Transition.cancel(r),t(r,n))}function P(o){switch(o.animation[0]){case"slide-left":return T(o);case"slide-right":return T(o,!0)}return u(o)}function u(o){let{isToggled:t,duration:r,velocity:n,initProps:a,hideProps:i,transition:c,_toggle:h}=o;return(e,f)=>{const g=s.Transition.inProgress(e),m=!g&&e.hasChildNodes()?s.toFloat(s.css(e.firstElementChild,"marginTop"))+s.toFloat(s.css(e.lastElementChild,"marginBottom")):0,d=s.isVisible(e)?s.toFloat(s.css(e,"height"))+m:0,p=g?s.css(e,Object.keys(a)):f?i:a;s.Transition.cancel(e),t(e)||h(e,!0),s.css(e,"maxHeight",""),s.fastdom.flush();const w=s.toFloat(s.css(e,"height"))+m;return r=n*w+r,s.css(e,{...p,maxHeight:d}),(f?s.Transition.start(e,{...a,overflow:"hidden",maxHeight:w},r*(1-d/w),c):s.Transition.start(e,i,r*(d/w),c).then(()=>h(e,!1))).then(()=>s.css(e,a))}}function T(o,t){let{isToggled:r,duration:n,velocity:a,transition:i,_toggle:c}=o;return(h,e)=>{const f=s.isVisible(h),g=s.toFloat(s.css(h,"marginLeft"));s.Transition.cancel(h);const[m]=s.scrollParents(h.offsetParent);s.css(m,"overflowX","hidden"),r(h)||c(h,!0);const d=s.toFloat(s.css(h,"width"));n=a*d+n;const p=f?(d+g*(t?-1:1))/d*100:0;return s.css(h,{clipPath:t?"polygon(0 0,"+p+"% 0,"+p+"% 100%,0 100%)":"polygon("+(100-p)+"% 0,100% 0,100% 100%,"+(100-p)+"% 100%)",marginLeft:(100-p)*(t?1:-1)/100*d}),(e?s.Transition.start(h,{clipPath:"polygon(0 0,100% 0,100% 100%,0 100%)",marginLeft:0},n*(1-p/100),i):s.Transition.start(h,{clipPath:t?"polygon(0 0,0 0,0 100%,0 100%)":"polygon(100% 0,100% 0,100% 100%,100% 100%)",marginLeft:(t?1:-1)*d},n*(p/100),i).then(()=>c(h,!1))).then(()=>{s.css(m,"overflowX",""),s.css(h,{clipPath:"",marginLeft:""})})}}function x(o){return(t,r)=>{s.Animation.cancel(t);const{animation:n,duration:a,_toggle:i}=o;return r?(i(t,!0),s.Animation.in(t,n[0],a,o.origin)):s.Animation.out(t,n[1]||n[0],a,o.origin).then(()=>i(t,!1))}}var $={props:{pos:String,offset:null,flip:Boolean},data:{pos:"bottom-"+(s.isRtl?"right":"left"),flip:!0,offset:!1},connected(){this.pos=this.$props.pos.split("-").concat("center").slice(0,2),[this.dir,this.align]=this.pos,this.axis=s.includes(["top","bottom"],this.dir)?"y":"x"},methods:{positionAt(o,t,r){let n=[this.getPositionOffset(o),this.getShiftOffset(o)];const a={element:[s.flipPosition(this.dir),this.align],target:[this.dir,this.align]};if(this.axis==="y"){for(const g in a)a[g]=a[g].reverse();n=n.reverse()}const[i]=s.scrollParents(o,/auto|scroll/),{scrollTop:c,scrollLeft:h}=i,e=s.dimensions(o);s.css(o,{top:-e.height,left:-e.width});const f=[o,t,{attach:a,offset:n,boundary:r,flip:this.flip,viewportOffset:this.getViewportOffset(o)}];s.trigger(o,"beforeposition",f),s.positionAt(...f),i.scrollTop=c,i.scrollLeft=h},getPositionOffset(o){return s.toPx(this.offset===!1?s.getCssVar("position-offset",o):this.offset,this.axis==="x"?"width":"height",o)*(s.includes(["left","top"],this.dir)?-1:1)},getShiftOffset(o){return s.includes(["center","justify","stretch"],this.align)?0:s.toPx(s.getCssVar("position-shift-offset",o),this.axis==="y"?"width":"height",o)*(s.includes(["left","top"],this.align)?1:-1)},getViewportOffset(o){return s.toPx(s.getCssVar("position-viewport-offset",o))}}},v={mixins:[l,b,$],args:"title",props:{delay:Number,title:String},data:{pos:"top",title:"",delay:0,animation:["uk-animation-scale-up"],duration:100,cls:"uk-active"},beforeConnect(){this._hasTitle=s.hasAttr(this.$el,"title"),s.attr(this.$el,"title",""),this.updateAria(!1),C(this.$el)},disconnected(){this.hide(),s.attr(this.$el,"title",this._hasTitle?this.title:null)},methods:{show(){this.isToggled(this.tooltip||null)||!this.title||(this._unbind=s.once(document,"show keydown "+s.pointerDown,this.hide,!1,o=>o.type===s.pointerDown&&!s.within(o.target,this.$el)||o.type==="keydown"&&o.keyCode===27||o.type==="show"&&o.detail[0]!==this&&o.detail[0].$name===this.$name),clearTimeout(this.showTimer),this.showTimer=setTimeout(this._show,this.delay))},async hide(){s.matches(this.$el,"input:focus")||(clearTimeout(this.showTimer),this.isToggled(this.tooltip||null)&&(await this.toggleElement(this.tooltip,!1,!1),s.remove(this.tooltip),this.tooltip=null,this._unbind()))},_show(){this.tooltip=s.append(this.container,'<div class="uk-'+this.$options.name+'"> <div class="uk-'+this.$options.name+'-inner">'+this.title+"</div> </div>"),s.on(this.tooltip,"toggled",(o,t)=>{if(this.updateAria(t),!t)return;this.positionAt(this.tooltip,this.$el);const[r,n]=A(this.tooltip,this.$el,this.pos);this.origin=this.axis==="y"?s.flipPosition(r)+"-"+n:n+"-"+s.flipPosition(r)}),this.toggleElement(this.tooltip,!0)},updateAria(o){s.attr(this.$el,"aria-expanded",o)}},events:{focus:"show",blur:"hide",[s.pointerEnter+" "+s.pointerLeave](o){s.isTouch(o)||this[o.type===s.pointerEnter?"show":"hide"]()},[s.pointerDown](o){s.isTouch(o)&&this.show()}}};function C(o){s.isFocusable(o)||s.attr(o,"tabindex","0")}function A(o,t,r){let[n,a]=r;const i=s.offset(o),c=s.offset(t),h=[["left","right"],["top","bottom"]];for(const f of h){if(i[f[0]]>=c[f[1]]){n=f[1];break}if(i[f[1]]<=c[f[0]]){n=f[0];break}}const e=s.includes(h[0],n)?h[1]:h[0];return i[e[0]]===c[e[0]]?a=e[0]:i[e[1]]===c[e[1]]?a=e[1]:a="center",[n,a]}return typeof window<"u"&&window.UIkit&&window.UIkit.component("tooltip",v),v});
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.14.4-dev.ce706e326 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
1
+ /*! UIkit 3.14.4-dev.dbd727038 | 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')) :
@@ -1 +1 @@
1
- /*! UIkit 3.14.4-dev.ce706e326 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */(function(o,n){typeof exports=="object"&&typeof module<"u"?module.exports=n(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitupload",["uikit-util"],n):(o=typeof globalThis<"u"?globalThis:o||self,o.UIkitUpload=n(o.UIkit.util))})(this,function(o){"use strict";var n={props:{allow:String,clsDragover:String,concurrent:Number,maxSize:Number,method:String,mime:String,msgInvalidMime:String,msgInvalidName:String,msgInvalidSize:String,multiple:Boolean,name:String,params:Object,type:String,url:String},data:{allow:!1,clsDragover:"uk-dragover",concurrent:1,maxSize:0,method:"POST",mime:!1,msgInvalidMime:"Invalid File Type: %s",msgInvalidName:"Invalid File Name: %s",msgInvalidSize:"Invalid File Size: %s Kilobytes Max",multiple:!1,name:"files[]",params:{},type:"",url:"",abort:o.noop,beforeAll:o.noop,beforeSend:o.noop,complete:o.noop,completeAll:o.noop,error:o.noop,fail:o.noop,load:o.noop,loadEnd:o.noop,loadStart:o.noop,progress:o.noop},events:{change(e){!o.matches(e.target,'input[type="file"]')||(e.preventDefault(),e.target.files&&this.upload(e.target.files),e.target.value="")},drop(e){i(e);const t=e.dataTransfer;!(t!=null&&t.files)||(o.removeClass(this.$el,this.clsDragover),this.upload(t.files))},dragenter(e){i(e)},dragover(e){i(e),o.addClass(this.$el,this.clsDragover)},dragleave(e){i(e),o.removeClass(this.$el,this.clsDragover)}},methods:{async upload(e){if(e=o.toArray(e),!e.length)return;o.trigger(this.$el,"upload",[e]);for(const a of e){if(this.maxSize&&this.maxSize*1e3<a.size){this.fail(this.msgInvalidSize.replace("%s",this.maxSize));return}if(this.allow&&!d(this.allow,a.name)){this.fail(this.msgInvalidName.replace("%s",this.allow));return}if(this.mime&&!d(this.mime,a.type)){this.fail(this.msgInvalidMime.replace("%s",this.mime));return}}this.multiple||(e=e.slice(0,1)),this.beforeAll(this,e);const t=c(e,this.concurrent),s=async a=>{const l=new FormData;a.forEach(r=>l.append(this.name,r));for(const r in this.params)l.append(r,this.params[r]);try{const r=await o.ajax(this.url,{data:l,method:this.method,responseType:this.type,beforeSend:h=>{const{xhr:p}=h;p.upload&&o.on(p.upload,"progress",this.progress);for(const m of["loadStart","load","loadEnd","abort"])o.on(p,m.toLowerCase(),this[m]);return this.beforeSend(h)}});this.complete(r),t.length?await s(t.shift()):this.completeAll(r)}catch(r){this.error(r)}};await s(t.shift())}}};function d(e,t){return t.match(new RegExp("^"+e.replace(/\//g,"\\/").replace(/\*\*/g,"(\\/[^\\/]+)*").replace(/\*/g,"[^\\/]+").replace(/((?!\\))\?/g,"$1.")+"$","i"))}function c(e,t){const s=[];for(let a=0;a<e.length;a+=t)s.push(e.slice(a,a+t));return s}function i(e){e.preventDefault(),e.stopPropagation()}return typeof window<"u"&&window.UIkit&&window.UIkit.component("upload",n),n});
1
+ /*! UIkit 3.14.4-dev.dbd727038 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */(function(o,n){typeof exports=="object"&&typeof module<"u"?module.exports=n(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitupload",["uikit-util"],n):(o=typeof globalThis<"u"?globalThis:o||self,o.UIkitUpload=n(o.UIkit.util))})(this,function(o){"use strict";var n={props:{allow:String,clsDragover:String,concurrent:Number,maxSize:Number,method:String,mime:String,msgInvalidMime:String,msgInvalidName:String,msgInvalidSize:String,multiple:Boolean,name:String,params:Object,type:String,url:String},data:{allow:!1,clsDragover:"uk-dragover",concurrent:1,maxSize:0,method:"POST",mime:!1,msgInvalidMime:"Invalid File Type: %s",msgInvalidName:"Invalid File Name: %s",msgInvalidSize:"Invalid File Size: %s Kilobytes Max",multiple:!1,name:"files[]",params:{},type:"",url:"",abort:o.noop,beforeAll:o.noop,beforeSend:o.noop,complete:o.noop,completeAll:o.noop,error:o.noop,fail:o.noop,load:o.noop,loadEnd:o.noop,loadStart:o.noop,progress:o.noop},events:{change(e){!o.matches(e.target,'input[type="file"]')||(e.preventDefault(),e.target.files&&this.upload(e.target.files),e.target.value="")},drop(e){i(e);const t=e.dataTransfer;!(t!=null&&t.files)||(o.removeClass(this.$el,this.clsDragover),this.upload(t.files))},dragenter(e){i(e)},dragover(e){i(e),o.addClass(this.$el,this.clsDragover)},dragleave(e){i(e),o.removeClass(this.$el,this.clsDragover)}},methods:{async upload(e){if(e=o.toArray(e),!e.length)return;o.trigger(this.$el,"upload",[e]);for(const a of e){if(this.maxSize&&this.maxSize*1e3<a.size){this.fail(this.msgInvalidSize.replace("%s",this.maxSize));return}if(this.allow&&!d(this.allow,a.name)){this.fail(this.msgInvalidName.replace("%s",this.allow));return}if(this.mime&&!d(this.mime,a.type)){this.fail(this.msgInvalidMime.replace("%s",this.mime));return}}this.multiple||(e=e.slice(0,1)),this.beforeAll(this,e);const t=c(e,this.concurrent),s=async a=>{const l=new FormData;a.forEach(r=>l.append(this.name,r));for(const r in this.params)l.append(r,this.params[r]);try{const r=await o.ajax(this.url,{data:l,method:this.method,responseType:this.type,beforeSend:h=>{const{xhr:p}=h;p.upload&&o.on(p.upload,"progress",this.progress);for(const m of["loadStart","load","loadEnd","abort"])o.on(p,m.toLowerCase(),this[m]);return this.beforeSend(h)}});this.complete(r),t.length?await s(t.shift()):this.completeAll(r)}catch(r){this.error(r)}};await s(t.shift())}}};function d(e,t){return t.match(new RegExp("^"+e.replace(/\//g,"\\/").replace(/\*\*/g,"(\\/[^\\/]+)*").replace(/\*/g,"[^\\/]+").replace(/((?!\\))\?/g,"$1.")+"$","i"))}function c(e,t){const s=[];for(let a=0;a<e.length;a+=t)s.push(e.slice(a,a+t));return s}function i(e){e.preventDefault(),e.stopPropagation()}return typeof window<"u"&&window.UIkit&&window.UIkit.component("upload",n),n});
@@ -1,4 +1,4 @@
1
- /*! UIkit 3.14.4-dev.ce706e326 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
1
+ /*! UIkit 3.14.4-dev.dbd727038 | 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() :
@@ -1795,20 +1795,6 @@
1795
1795
 
1796
1796
  }
1797
1797
 
1798
- function scrollTop(element, top) {
1799
- if (isWindow(element) || isDocument(element)) {
1800
- element = scrollingElement(element);
1801
- } else {
1802
- element = toNode(element);
1803
- }
1804
-
1805
- if (isUndefined(top)) {
1806
- return element.scrollTop;
1807
- } else {
1808
- element.scrollTop = top;
1809
- }
1810
- }
1811
-
1812
1798
  function scrollIntoView(element, _temp) {let { offset: offsetBy = 0 } = _temp === void 0 ? {} : _temp;
1813
1799
  const parents = isVisible(element) ? scrollParents(element) : [];
1814
1800
  return parents.reduce(
@@ -1850,7 +1836,7 @@
1850
1836
  (function step() {
1851
1837
  const percent = ease(clamp((Date.now() - start) / duration));
1852
1838
 
1853
- scrollTop(element, scroll + top * percent);
1839
+ element.scrollTop = scroll + top * percent;
1854
1840
 
1855
1841
  // scroll more if we have not reached our destination
1856
1842
  if (percent === 1) {
@@ -2106,6 +2092,7 @@
2106
2092
  return newPos;
2107
2093
  }
2108
2094
  }
2095
+ continue;
2109
2096
  }
2110
2097
 
2111
2098
  // Move
@@ -2298,7 +2285,6 @@
2298
2285
  getCssVar: getCssVar,
2299
2286
  propName: propName,
2300
2287
  isInView: isInView,
2301
- scrollTop: scrollTop,
2302
2288
  scrollIntoView: scrollIntoView,
2303
2289
  scrolledOver: scrolledOver,
2304
2290
  scrollParents: scrollParents,
@@ -2961,7 +2947,7 @@
2961
2947
  UIkit.data = '__uikit__';
2962
2948
  UIkit.prefix = 'uk-';
2963
2949
  UIkit.options = {};
2964
- UIkit.version = '3.14.4-dev.ce706e326';
2950
+ UIkit.version = '3.14.4-dev.dbd727038';
2965
2951
 
2966
2952
  globalAPI(UIkit);
2967
2953
  hooksAPI(UIkit);
@@ -3259,7 +3245,7 @@
3259
3245
 
3260
3246
  Transition.cancel(el);
3261
3247
 
3262
- const [scrollElement] = scrollParents(el);
3248
+ const [scrollElement] = scrollParents(el.offsetParent);
3263
3249
  css(scrollElement, 'overflowX', 'hidden');
3264
3250
 
3265
3251
  if (!isToggled(el)) {
@@ -3270,17 +3256,11 @@
3270
3256
  duration = velocity * width + duration;
3271
3257
 
3272
3258
  const percent = visible ? (width + marginLeft * (right ? -1 : 1)) / width * 100 : 0;
3273
- const offsetEl = offset(el);
3274
- const useClipPath = right ?
3275
- offsetEl.right < scrollElement.clientWidth :
3276
- Math.round(offsetEl.left) > 0;
3277
3259
 
3278
3260
  css(el, {
3279
- clipPath: useClipPath ?
3280
- right ? "polygon(0 0," +
3261
+ clipPath: right ? "polygon(0 0," +
3281
3262
  percent + "% 0," + percent + "% 100%,0 100%)" : "polygon(" + (
3282
- 100 - percent) + "% 0,100% 0,100% 100%," + (100 - percent) + "% 100%)" :
3283
- '',
3263
+ 100 - percent) + "% 0,100% 0,100% 100%," + (100 - percent) + "% 100%)",
3284
3264
  marginLeft: (100 - percent) * (right ? 1 : -1) / 100 * width });
3285
3265
 
3286
3266
 
@@ -3289,7 +3269,7 @@
3289
3269
  Transition.start(
3290
3270
  el,
3291
3271
  {
3292
- clipPath: useClipPath ? "polygon(0 0,100% 0,100% 100%,0 100%)" : '',
3272
+ clipPath: "polygon(0 0,100% 0,100% 100%,0 100%)",
3293
3273
  marginLeft: 0 },
3294
3274
 
3295
3275
  duration * (1 - percent / 100),
@@ -3298,11 +3278,9 @@
3298
3278
  Transition.start(
3299
3279
  el,
3300
3280
  {
3301
- clipPath: useClipPath ?
3302
- right ? "polygon(0 0,0 0,0 100%,0 100%)" : "polygon(100% 0,100% 0,100% 100%,100% 100%)" :
3281
+ clipPath: right ? "polygon(0 0,0 0,0 100%,0 100%)" : "polygon(100% 0,100% 0,100% 100%,100% 100%)",
3303
3282
 
3304
3283
 
3305
- '',
3306
3284
  marginLeft: (right ? 1 : -1) * width },
3307
3285
 
3308
3286
  duration * (percent / 100),
@@ -3698,17 +3676,32 @@
3698
3676
  offset = offset.reverse();
3699
3677
  }
3700
3678
 
3679
+ const [scrollElement] = scrollParents(element, /auto|scroll/);
3680
+ const { scrollTop, scrollLeft } = scrollElement;
3681
+
3701
3682
  // Ensure none positioned element does not generate scrollbars
3702
3683
  const elDim = dimensions(element);
3703
3684
  css(element, { top: -elDim.height, left: -elDim.width });
3704
3685
 
3705
- positionAt(element, target, {
3686
+ const args = [
3687
+ element,
3688
+ target,
3689
+ {
3706
3690
  attach,
3707
3691
  offset,
3708
3692
  boundary,
3709
3693
  flip: this.flip,
3710
- viewportOffset: this.getViewportOffset(element) });
3694
+ viewportOffset: this.getViewportOffset(element) }];
3695
+
3696
+
3697
+
3698
+ trigger(element, 'beforeposition', args);
3699
+
3700
+ positionAt(...args);
3711
3701
 
3702
+ // Restore scroll position
3703
+ scrollElement.scrollTop = scrollTop;
3704
+ scrollElement.scrollLeft = scrollLeft;
3712
3705
  },
3713
3706
 
3714
3707
  getPositionOffset(element) {
@@ -4983,7 +4976,9 @@
4983
4976
  0);
4984
4977
 
4985
4978
  } else {
4986
- const isScrollingElement = document.scrollingElement === scrollElement;
4979
+ const { body, scrollingElement } = document;
4980
+ const isScrollingElement =
4981
+ scrollingElement === scrollElement || body === scrollElement;
4987
4982
 
4988
4983
  // on mobile devices (iOS and Android) window.innerHeight !== 100vh
4989
4984
  minHeight = "calc(" + (isScrollingElement ? '100vh' : viewportHeight + "px");
@@ -5237,6 +5232,8 @@
5237
5232
 
5238
5233
  var marker = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"9\" y=\"4\" width=\"1\" height=\"11\"/><rect x=\"4\" y=\"9\" width=\"11\" height=\"1\"/></svg>";
5239
5234
 
5235
+ var navbarParentIcon = "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"12\" viewBox=\"0 0 12 12\"><polyline fill=\"none\" stroke=\"#000\" stroke-width=\"1.1\" points=\"1 3.5 6 8.5 11 3.5\"/></svg>";
5236
+
5240
5237
  var navbarToggleIcon = "<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><rect y=\"9\" width=\"20\" height=\"2\"/><rect y=\"3\" width=\"20\" height=\"2\"/><rect y=\"15\" width=\"20\" height=\"2\"/></svg>";
5241
5238
 
5242
5239
  var overlayIcon = "<svg width=\"40\" height=\"40\" viewBox=\"0 0 40 40\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"19\" y=\"0\" width=\"1\" height=\"40\"/><rect x=\"0\" y=\"19\" width=\"40\" height=\"1\"/></svg>";
@@ -5269,6 +5266,7 @@
5269
5266
  marker,
5270
5267
  'close-icon': closeIcon,
5271
5268
  'close-large': closeLarge,
5269
+ 'navbar-parent-icon': navbarParentIcon,
5272
5270
  'navbar-toggle-icon': navbarToggleIcon,
5273
5271
  'overlay-icon': overlayIcon,
5274
5272
  'pagination-next': paginationNext,
@@ -5915,8 +5913,7 @@
5915
5913
  {
5916
5914
  ...this.$props,
5917
5915
  boundary: this.boundary,
5918
- pos: this.pos,
5919
- offset: this.dropbar || this.offset });
5916
+ pos: this.pos });
5920
5917
 
5921
5918
 
5922
5919
  },
@@ -6077,8 +6074,8 @@
6077
6074
  return this.dropbar;
6078
6075
  },
6079
6076
 
6080
- handler(_, _ref9) {let { $el, align } = _ref9;
6081
- if (!hasClass($el, this.clsDrop) || align === 'stretch') {
6077
+ handler(_ref9) {let { target } = _ref9;
6078
+ if (!this.isDropbarDrop(target)) {
6082
6079
  return;
6083
6080
  }
6084
6081
 
@@ -6086,7 +6083,7 @@
6086
6083
  after(this.dropbarAnchor || this.$el, this.dropbar);
6087
6084
  }
6088
6085
 
6089
- addClass($el, this.clsDrop + "-dropbar");
6086
+ addClass(target, this.clsDrop + "-dropbar");
6090
6087
  } },
6091
6088
 
6092
6089
 
@@ -6101,22 +6098,47 @@
6101
6098
  return this.dropbar;
6102
6099
  },
6103
6100
 
6104
- handler(_, _ref10) {let { $el, align } = _ref10;
6105
- if (!hasClass($el, this.clsDrop) || align === 'stretch') {
6101
+ handler(_ref10) {let { target } = _ref10;
6102
+ if (!this.isDropbarDrop(target)) {
6106
6103
  return;
6107
6104
  }
6108
6105
 
6109
- this._observer = observeResize($el, () =>
6106
+ this._observer = observeResize(target, () =>
6110
6107
  this.transitionTo(
6111
- offset($el).bottom -
6108
+ offset(target).bottom -
6112
6109
  offset(this.dropbar).top +
6113
- toFloat(css($el, 'marginBottom')),
6114
- $el));
6110
+ toFloat(css(target, 'marginBottom')),
6111
+ target));
6115
6112
 
6116
6113
 
6117
6114
  } },
6118
6115
 
6119
6116
 
6117
+ {
6118
+ name: 'beforeposition',
6119
+
6120
+ el() {
6121
+ return this.dropContainer;
6122
+ },
6123
+
6124
+ filter() {
6125
+ return this.dropbar;
6126
+ },
6127
+
6128
+ handler(e, element, target, options) {
6129
+ if (!this.isDropbarDrop(element)) {
6130
+ return;
6131
+ }
6132
+
6133
+ const dropbarOffset = offset(this.dropbar);
6134
+
6135
+ css(element, 'maxWidth', dropbarOffset.width - options.viewportOffset * 2);
6136
+
6137
+ options.offset[1] = dropbarOffset.top - offset(target).bottom;
6138
+ options.viewportOffset += dropbarOffset.left;
6139
+ } },
6140
+
6141
+
6120
6142
  {
6121
6143
  name: 'beforehide',
6122
6144
 
@@ -6128,12 +6150,12 @@
6128
6150
  return this.dropbar;
6129
6151
  },
6130
6152
 
6131
- handler(e, _ref11) {let { $el } = _ref11;
6153
+ handler(e) {
6132
6154
  const active = this.getActive();
6133
6155
 
6134
6156
  if (
6135
6157
  matches(this.dropbar, ':hover') &&
6136
- (active == null ? void 0 : active.$el) === $el &&
6158
+ (active == null ? void 0 : active.$el) === e.target &&
6137
6159
  !this.toggles.some((el) => active.target !== el && matches(el, ':focus')))
6138
6160
  {
6139
6161
  e.preventDefault();
@@ -6152,8 +6174,8 @@
6152
6174
  return this.dropbar;
6153
6175
  },
6154
6176
 
6155
- handler(_, _ref12) {let { $el, align } = _ref12;
6156
- if (!hasClass($el, this.clsDrop) || align === 'stretch') {
6177
+ handler(_ref11) {let { target } = _ref11;
6178
+ if (!this.isDropbarDrop(target)) {
6157
6179
  return;
6158
6180
  }
6159
6181
 
@@ -6161,7 +6183,7 @@
6161
6183
 
6162
6184
  const active = this.getActive();
6163
6185
 
6164
- if (!active || (active == null ? void 0 : active.$el) === $el) {
6186
+ if (!active || (active == null ? void 0 : active.$el) === target) {
6165
6187
  this.transitionTo(0);
6166
6188
  }
6167
6189
  } }],
@@ -6200,6 +6222,11 @@
6200
6222
 
6201
6223
  getDropdown(el) {
6202
6224
  return this.$getComponent(el, 'drop') || this.$getComponent(el, 'dropdown');
6225
+ },
6226
+
6227
+ isDropbarDrop(el) {
6228
+ const drop = this.getDropdown(el);
6229
+ return drop && hasClass(el, this.clsDrop) && drop.align !== 'stretch';
6203
6230
  } } };
6204
6231
 
6205
6232
 
@@ -6925,7 +6952,9 @@
6925
6952
  },
6926
6953
 
6927
6954
  handler() {
6928
- if (!location.hash || scrollTop(window) === 0) {
6955
+ const { scrollingElement } = document;
6956
+
6957
+ if (!location.hash || scrollingElement.scrollTop === 0) {
6929
6958
  return;
6930
6959
  }
6931
6960
 
@@ -6934,13 +6963,11 @@
6934
6963
  const elOffset = offset(this.$el);
6935
6964
 
6936
6965
  if (this.isFixed && intersectRect(targetOffset, elOffset)) {
6937
- scrollTop(
6938
- window,
6966
+ scrollingElement.scrollTop =
6939
6967
  targetOffset.top -
6940
6968
  elOffset.height -
6941
6969
  toPx(this.targetOffset, 'height', this.placeholder) -
6942
- toPx(this.offset, 'height', this.placeholder));
6943
-
6970
+ toPx(this.offset, 'height', this.placeholder);
6944
6971
  }
6945
6972
  });
6946
6973
  } }],
@@ -7038,7 +7065,7 @@
7038
7065
 
7039
7066
 
7040
7067
  {let { scroll: prevScroll = 0, dir: prevDir = 'down', overflow, overflowScroll = 0, start, end } = _ref4;
7041
- const scroll = scrollTop(window);
7068
+ const scroll = document.scrollingElement.scrollTop;
7042
7069
  const dir = prevScroll <= scroll ? 'down' : 'up';
7043
7070
 
7044
7071
  return {
@@ -7668,6 +7695,7 @@
7668
7695
  SlidenavPrevious: Slidenav,
7669
7696
  SearchIcon: Search,
7670
7697
  Marker: IconComponent,
7698
+ NavbarParentIcon: IconComponent,
7671
7699
  NavbarToggleIcon: IconComponent,
7672
7700
  OverlayIcon: IconComponent,
7673
7701
  PaginationNext: IconComponent,