uikit 3.14.1-dev.e15dd286c → 3.14.2-dev.5f6f1e6a6
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 +14 -3
- package/build/util.js +2 -2
- package/dist/css/uikit-core-rtl.css +6 -1
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +6 -1
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +6 -1
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +6 -1
- package/dist/css/uikit.min.css +1 -1
- package/dist/js/components/countdown.js +1 -1
- package/dist/js/components/countdown.min.js +2 -1
- package/dist/js/components/filter.js +1 -1
- package/dist/js/components/filter.min.js +2 -1
- package/dist/js/components/lightbox-panel.js +6 -1
- package/dist/js/components/lightbox-panel.min.js +2 -1
- package/dist/js/components/lightbox.js +6 -1
- package/dist/js/components/lightbox.min.js +2 -1
- package/dist/js/components/notification.js +1 -1
- package/dist/js/components/notification.min.js +2 -1
- package/dist/js/components/parallax.js +1 -1
- package/dist/js/components/parallax.min.js +2 -1
- package/dist/js/components/slider-parallax.js +1 -1
- package/dist/js/components/slider-parallax.min.js +2 -1
- package/dist/js/components/slider.js +1 -1
- package/dist/js/components/slider.min.js +2 -1
- package/dist/js/components/slideshow-parallax.js +1 -1
- package/dist/js/components/slideshow-parallax.min.js +2 -1
- package/dist/js/components/slideshow.js +1 -1
- package/dist/js/components/slideshow.min.js +2 -1
- package/dist/js/components/sortable.js +1 -1
- package/dist/js/components/sortable.min.js +2 -1
- package/dist/js/components/tooltip.js +14 -14
- package/dist/js/components/tooltip.min.js +2 -1
- package/dist/js/components/upload.js +1 -1
- package/dist/js/components/upload.min.js +2 -1
- package/dist/js/uikit-core.js +53 -50
- package/dist/js/uikit-core.min.js +2 -1
- package/dist/js/uikit-icons.js +1 -1
- package/dist/js/uikit-icons.min.js +2 -1
- package/dist/js/uikit.js +53 -50
- package/dist/js/uikit.min.js +2 -1
- package/package.json +12 -12
- package/src/js/api/hooks.js +1 -1
- package/src/js/core/drop.js +16 -7
- package/src/js/core/height-viewport.js +1 -2
- package/src/js/core/scrollspy.js +7 -9
- package/src/js/core/toggle.js +4 -0
- package/src/js/mixin/position.js +7 -22
- package/src/js/mixin/togglable.js +5 -0
- package/src/js/util/position.js +9 -9
- package/src/js/util/viewport.js +2 -8
- package/src/less/components/drop.less +1 -0
- package/src/less/components/dropdown.less +1 -0
- package/src/less/components/navbar.less +2 -0
- package/src/less/components/tooltip.less +1 -0
- package/src/scss/components/drop.scss +1 -0
- package/src/scss/components/dropdown.scss +1 -0
- package/src/scss/components/navbar.scss +2 -0
- package/src/scss/components/tooltip.scss +1 -0
- package/tests/drop.html +20 -2
- package/tests/dropdown.html +6 -0
- package/tests/navbar.html +6 -0
|
@@ -1 +1,2 @@
|
|
|
1
|
-
/*! UIkit 3.14.1-dev.e15dd286c | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */(function(s,p){typeof exports=="object"&&typeof module<"u"?module.exports=p(require("uikit-util")):typeof define=="function"&&define.amd?define("uikitslideshow",["uikit-util"],p):(s=typeof globalThis<"u"?globalThis:s||self,s.UIkitSlideshow=p(s.UIkit.util))})(this,function(s){"use strict";var p={connected(){!s.hasClass(this.$el,this.$name)&&s.addClass(this.$el,this.$name)}},I={slide:{show(e){return[{transform:h(e*-100)},{transform:h()}]},percent(e){return v(e)},translate(e,t){return[{transform:h(t*-100*e)},{transform:h(t*100*(1-e))}]}}};function v(e){return Math.abs(s.css(e,"transform").split(",")[4]/e.offsetWidth)||0}function h(e,t){return e===void 0&&(e=0),t===void 0&&(t="%"),e+=e?t:"","translate3d("+e+", 0, 0)"}function w(e){return"scale3d("+e+", "+e+", 1)"}function b(e,t,n,i){let{animation:l,easing:r}=i;const{percent:a,translate:m,show:c=s.noop}=l,g=c(n),f=new s.Deferred;return{dir:n,show(o,d,E){d===void 0&&(d=0);const x=E?"linear":r;return o-=Math.round(o*s.clamp(d,-1,1)),this.translate(d),u(t,"itemin",{percent:d,duration:o,timing:x,dir:n}),u(e,"itemout",{percent:1-d,duration:o,timing:x,dir:n}),Promise.all([s.Transition.start(t,g[1],o,x),s.Transition.start(e,g[0],o,x)]).then(()=>{this.reset(),f.resolve()},s.noop),f.promise},cancel(){s.Transition.cancel([t,e])},reset(){for(const o in g[0])s.css([t,e],o,"")},forward(o,d){return d===void 0&&(d=this.percent()),s.Transition.cancel([t,e]),this.show(o,d,!0)},translate(o){this.reset();const d=m(o,n);s.css(t,d[1]),s.css(e,d[0]),u(t,"itemtranslatein",{percent:o,dir:n}),u(e,"itemtranslateout",{percent:1-o,dir:n})},percent(){return a(e||t,t,n)},getDistance(){return e?.offsetWidth}}}function u(e,t,n){s.trigger(e,s.createEvent(t,!1,!1,n))}var y={connected(){var e;this.registerObserver(s.observeResize(((e=this.$options.resizeTargets)==null?void 0:e.call(this))||this.$el,()=>this.$emit("resize")))}},A={props:{autoplay:Boolean,autoplayInterval:Number,pauseOnHover:Boolean},data:{autoplay:!1,autoplayInterval:7e3,pauseOnHover:!0},connected(){this.autoplay&&this.startAutoplay()},disconnected(){this.stopAutoplay()},update(){s.attr(this.slides,"tabindex","-1")},events:[{name:"visibilitychange",el(){return document},filter(){return this.autoplay},handler(){document.hidden?this.stopAutoplay():this.startAutoplay()}}],methods:{startAutoplay(){this.stopAutoplay(),this.interval=setInterval(()=>(!this.draggable||!s.$(":focus",this.$el))&&(!this.pauseOnHover||!s.matches(this.$el,":hover"))&&!this.stack.length&&this.show("next"),this.autoplayInterval)},stopAutoplay(){this.interval&&clearInterval(this.interval)}}},_={props:{draggable:Boolean},data:{draggable:!0,threshold:10},created(){for(const e of["start","move","end"]){const t=this[e];this[e]=n=>{const i=s.getEventPos(n).x*(s.isRtl?-1:1);this.prevPos=i===this.pos?this.prevPos:this.pos,this.pos=i,t(n)}}},events:[{name:s.pointerDown,delegate(){return this.selSlides},handler(e){!this.draggable||!s.isTouch(e)&&$(e.target)||s.closest(e.target,s.selInput)||e.button>0||this.length<2||this.start(e)}},{name:"dragstart",handler(e){e.preventDefault()}}],methods:{start(){this.drag=this.pos,this._transitioner?(this.percent=this._transitioner.percent(),this.drag+=this._transitioner.getDistance()*this.percent*this.dir,this._transitioner.cancel(),this._transitioner.translate(this.percent),this.dragging=!0,this.stack=[]):this.prevIndex=this.index,s.on(document,s.pointerMove,this.move,{passive:!1}),s.on(document,s.pointerUp+" "+s.pointerCancel+" input",this.end,!0),s.css(this.list,"userSelect","none")},move(e){const t=this.pos-this.drag;if(t===0||this.prevPos===this.pos||!this.dragging&&Math.abs(t)<this.threshold)return;s.css(this.list,"pointerEvents","none"),e.cancelable&&e.preventDefault(),this.dragging=!0,this.dir=t<0?1:-1;const{slides:n}=this;let{prevIndex:i}=this,l=Math.abs(t),r=this.getIndex(i+this.dir,i),a=this._getDistance(i,r)||n[i].offsetWidth;for(;r!==i&&l>a;)this.drag-=a*this.dir,i=r,l-=a,r=this.getIndex(i+this.dir,i),a=this._getDistance(i,r)||n[i].offsetWidth;this.percent=l/a;const m=n[i],c=n[r],g=this.index!==r,f=i===r;let o;[this.index,this.prevIndex].filter(d=>!s.includes([r,i],d)).forEach(d=>{s.trigger(n[d],"itemhidden",[this]),f&&(o=!0,this.prevIndex=i)}),(this.index===i&&this.prevIndex!==i||o)&&s.trigger(n[this.index],"itemshown",[this]),g&&(this.prevIndex=i,this.index=r,!f&&s.trigger(m,"beforeitemhide",[this]),s.trigger(c,"beforeitemshow",[this])),this._transitioner=this._translate(Math.abs(this.percent),m,!f&&c),g&&(!f&&s.trigger(m,"itemhide",[this]),s.trigger(c,"itemshow",[this]))},end(){if(s.off(document,s.pointerMove,this.move,{passive:!1}),s.off(document,s.pointerUp+" "+s.pointerCancel+" input",this.end,!0),this.dragging)if(this.dragging=null,this.index===this.prevIndex)this.percent=1-this.percent,this.dir*=-1,this._show(!1,this.index,!0),this._transitioner=null;else{const e=(s.isRtl?this.dir*(s.isRtl?1:-1):this.dir)<0==this.prevPos>this.pos;this.index=e?this.index:this.prevIndex,e&&(this.percent=1-this.percent),this.show(this.dir>0&&!e||this.dir<0&&e?"next":"previous",!0)}s.css(this.list,{userSelect:"",pointerEvents:""}),this.drag=this.percent=null}}};function $(e){return!e.children.length&&e.childNodes.length}var N={data:{selNav:!1},computed:{nav(e,t){let{selNav:n}=e;return s.$(n,t)},selNavItem(e){let{attrItem:t}=e;return"["+t+"],[data-"+t+"]"},navItems(e,t){return s.$$(this.selNavItem,t)}},update:{write(){this.nav&&this.length!==this.nav.children.length&&s.html(this.nav,this.slides.map((e,t)=>"<li "+this.attrItem+'="'+t+'"><a href></a></li>').join("")),this.navItems.concat(this.nav).forEach(e=>e&&(e.hidden=!this.maxIndex)),this.updateNav()},events:["resize"]},events:[{name:"click",delegate(){return this.selNavItem},handler(e){e.preventDefault(),this.show(s.data(e.current,this.attrItem))}},{name:"itemshow",handler:"updateNav"}],methods:{updateNav(){const e=this.getValidIndex();for(const t of this.navItems){const n=s.data(t,this.attrItem);s.toggleClass(t,this.clsActive,s.toNumber(n)===e),s.toggleClass(t,"uk-invisible",this.finite&&(n==="previous"&&e===0||n==="next"&&e>=this.maxIndex))}}}},S={mixins:[A,_,N,y],props:{clsActivated:Boolean,easing:String,index:Number,finite:Boolean,velocity:Number,selSlides:String},data:()=>({easing:"ease",finite:!1,velocity:1,index:0,prevIndex:-1,stack:[],percent:0,clsActive:"uk-active",clsActivated:!1,Transitioner:!1,transitionOptions:{}}),connected(){this.prevIndex=-1,this.index=this.getValidIndex(this.$props.index),this.stack=[]},disconnected(){s.removeClass(this.slides,this.clsActive)},computed:{duration(e,t){let{velocity:n}=e;return T(t.offsetWidth/n)},list(e,t){let{selList:n}=e;return s.$(n,t)},maxIndex(){return this.length-1},selSlides(e){let{selList:t,selSlides:n}=e;return t+" "+(n||"> *")},slides:{get(){return s.$$(this.selSlides,this.$el)},watch(){this.$reset()}},length(){return this.slides.length}},methods:{show(e,t){if(t===void 0&&(t=!1),this.dragging||!this.length)return;const{stack:n}=this,i=t?0:n.length,l=()=>{n.splice(i,1),n.length&&this.show(n.shift(),!0)};if(n[t?"unshift":"push"](e),!t&&n.length>1){n.length===2&&this._transitioner.forward(Math.min(this.duration,200));return}const r=this.getIndex(this.index),a=s.hasClass(this.slides,this.clsActive)&&this.slides[r],m=this.getIndex(e,this.index),c=this.slides[m];if(a===c){l();return}if(this.dir=C(e,r),this.prevIndex=r,this.index=m,a&&!s.trigger(a,"beforeitemhide",[this])||!s.trigger(c,"beforeitemshow",[this,a])){this.index=this.prevIndex,l();return}const g=this._show(a,c,t).then(()=>(a&&s.trigger(a,"itemhidden",[this]),s.trigger(c,"itemshown",[this]),new Promise(f=>{s.fastdom.write(()=>{n.shift(),n.length?this.show(n.shift(),!0):this._transitioner=null,f()})})));return a&&s.trigger(a,"itemhide",[this]),s.trigger(c,"itemshow",[this]),g},getIndex(e,t){return e===void 0&&(e=this.index),t===void 0&&(t=this.index),s.clamp(s.getIndex(e,this.slides,t,this.finite),0,this.maxIndex)},getValidIndex(e,t){return e===void 0&&(e=this.index),t===void 0&&(t=this.prevIndex),this.getIndex(e,t)},_show(e,t,n){if(this._transitioner=this._getTransitioner(e,t,this.dir,{easing:n?t.offsetWidth<600?"cubic-bezier(0.25, 0.46, 0.45, 0.94)":"cubic-bezier(0.165, 0.84, 0.44, 1)":this.easing,...this.transitionOptions}),!n&&!e)return this._translate(1),Promise.resolve();const{length:i}=this.stack;return this._transitioner[i>1?"forward":"show"](i>1?Math.min(this.duration,75+75/(i-1)):this.duration,this.percent)},_getDistance(e,t){return this._getTransitioner(e,e!==t&&t).getDistance()},_translate(e,t,n){t===void 0&&(t=this.prevIndex),n===void 0&&(n=this.index);const i=this._getTransitioner(t!==n?t:!1,n);return i.translate(e),i},_getTransitioner(e,t,n,i){return e===void 0&&(e=this.prevIndex),t===void 0&&(t=this.index),n===void 0&&(n=this.dir||1),i===void 0&&(i=this.transitionOptions),new this.Transitioner(s.isNumber(e)?this.slides[e]:e,s.isNumber(t)?this.slides[t]:t,n*(s.isRtl?-1:1),i)}}};function C(e,t){return e==="next"?1:e==="previous"||e<t?-1:1}function T(e){return .5*e+300}var D={mixins:[S],props:{animation:String},data:{animation:"slide",clsActivated:"uk-transition-active",Animations:I,Transitioner:b},computed:{animation(e){let{animation:t,Animations:n}=e;return{...n[t]||n.slide,name:t}},transitionOptions(){return{animation:this.animation}}},events:{beforeitemshow(e){let{target:t}=e;s.addClass(t,this.clsActive)},itemshown(e){let{target:t}=e;s.addClass(t,this.clsActivated)},itemhidden(e){let{target:t}=e;s.removeClass(t,this.clsActive,this.clsActivated)}}},H={...I,fade:{show(){return[{opacity:0,zIndex:0},{zIndex:-1}]},percent(e){return 1-s.css(e,"opacity")},translate(e){return[{opacity:1-e,zIndex:0},{zIndex:-1}]}},scale:{show(){return[{opacity:0,transform:w(1+.5),zIndex:0},{zIndex:-1}]},percent(e){return 1-s.css(e,"opacity")},translate(e){return[{opacity:1-e,transform:w(1+.5*e),zIndex:0},{zIndex:-1}]}},pull:{show(e){return e<0?[{transform:h(30),zIndex:-1},{transform:h(),zIndex:0}]:[{transform:h(-100),zIndex:0},{transform:h(),zIndex:-1}]},percent(e,t,n){return n<0?1-v(t):v(e)},translate(e,t){return t<0?[{transform:h(30*e),zIndex:-1},{transform:h(-100*(1-e)),zIndex:0}]:[{transform:h(-e*100),zIndex:0},{transform:h(30*(1-e)),zIndex:-1}]}},push:{show(e){return e<0?[{transform:h(100),zIndex:0},{transform:h(),zIndex:-1}]:[{transform:h(-30),zIndex:-1},{transform:h(),zIndex:0}]},percent(e,t,n){return n>0?1-v(t):v(e)},translate(e,t){return t<0?[{transform:h(e*100),zIndex:0},{transform:h(-30*(1-e)),zIndex:-1}]:[{transform:h(-30*e),zIndex:-1},{transform:h(100*(1-e)),zIndex:0}]}}},M={update:{write(){if(this.stack.length||this.dragging)return;const e=this.getValidIndex(this.index);(!~this.prevIndex||this.index!==e)&&this.show(e)},events:["resize"]}},O={methods:{lazyload(e,t){e===void 0&&(e=this.$el),t===void 0&&(t=this.$el),this.registerObserver(s.observeIntersection(e,(n,i)=>{for(const l of s.toNodes(s.isFunction(t)?t():t))s.$$('[loading="lazy"]',l).forEach(r=>s.removeAttr(r,"loading"));for(const l of n.filter(r=>{let{isIntersecting:a}=r;return a}).map(r=>{let{target:a}=r;return a}))i.unobserve(l)}))}}},P={mixins:[O],connected(){this.lazyload(this.slides,this.getAdjacentSlides)}},z={mixins:[p,D,M,P],props:{ratio:String,minHeight:Number,maxHeight:Number},data:{ratio:"16:9",minHeight:!1,maxHeight:!1,selList:".uk-slideshow-items",attrItem:"uk-slideshow-item",selNav:".uk-slideshow-nav",Animations:H},update:{read(){if(!this.list)return!1;let[e,t]=this.ratio.split(":").map(Number);return t=t*this.list.offsetWidth/e||0,this.minHeight&&(t=Math.max(this.minHeight,t)),this.maxHeight&&(t=Math.min(this.maxHeight,t)),{height:t-s.boxModelAdjust(this.list,"height","content-box")}},write(e){let{height:t}=e;t>0&&s.css(this.list,"minHeight",t)},events:["resize"]},methods:{getAdjacentSlides(){return[1,-1].map(e=>this.slides[this.getIndex(this.index+e)])}}};return typeof window<"u"&&window.UIkit&&window.UIkit.component("slideshow",z),z});
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
|
|
2
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("uikit-util")):"function"==typeof define&&define.amd?define("uikitslideshow",["uikit-util"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).UIkitSlideshow=e(t.UIkit.util)}(this,(function(t){"use strict";var e={connected(){!t.hasClass(this.$el,this.$name)&&t.addClass(this.$el,this.$name)}},i={slide:{show:t=>[{transform:n(-100*t)},{transform:n()}],percent:t=>s(t),translate:(t,e)=>[{transform:n(-100*e*t)},{transform:n(100*e*(1-t))}]}};function s(e){return Math.abs(t.css(e,"transform").split(",")[4]/e.offsetWidth)||0}function n(t,e){return void 0===t&&(t=0),void 0===e&&(e="%"),"translate3d("+(t+=t?e:"")+", 0, 0)"}function r(t){return"scale3d("+t+", "+t+", 1)"}function h(e,i,s){t.trigger(e,t.createEvent(i,!1,!1,s))}var a={connected(){var e;this.registerObserver(t.observeResize((null==(e=this.$options.resizeTargets)?void 0:e.call(this))||this.$el,(()=>this.$emit("resize"))))}};var o={mixins:[{mixins:[{props:{autoplay:Boolean,autoplayInterval:Number,pauseOnHover:Boolean},data:{autoplay:!1,autoplayInterval:7e3,pauseOnHover:!0},connected(){this.autoplay&&this.startAutoplay()},disconnected(){this.stopAutoplay()},update(){t.attr(this.slides,"tabindex","-1")},events:[{name:"visibilitychange",el:()=>document,filter(){return this.autoplay},handler(){document.hidden?this.stopAutoplay():this.startAutoplay()}}],methods:{startAutoplay(){this.stopAutoplay(),this.interval=setInterval((()=>(!this.draggable||!t.$(":focus",this.$el))&&(!this.pauseOnHover||!t.matches(this.$el,":hover"))&&!this.stack.length&&this.show("next")),this.autoplayInterval)},stopAutoplay(){this.interval&&clearInterval(this.interval)}}},{props:{draggable:Boolean},data:{draggable:!0,threshold:10},created(){for(const e of["start","move","end"]){const i=this[e];this[e]=e=>{const s=t.getEventPos(e).x*(t.isRtl?-1:1);this.prevPos=s===this.pos?this.prevPos:this.pos,this.pos=s,i(e)}}},events:[{name:t.pointerDown,delegate(){return this.selSlides},handler(e){var i;!this.draggable||!t.isTouch(e)&&(i=e.target,!i.children.length&&i.childNodes.length)||t.closest(e.target,t.selInput)||e.button>0||this.length<2||this.start(e)}},{name:"dragstart",handler(t){t.preventDefault()}}],methods:{start(){this.drag=this.pos,this._transitioner?(this.percent=this._transitioner.percent(),this.drag+=this._transitioner.getDistance()*this.percent*this.dir,this._transitioner.cancel(),this._transitioner.translate(this.percent),this.dragging=!0,this.stack=[]):this.prevIndex=this.index,t.on(document,t.pointerMove,this.move,{passive:!1}),t.on(document,t.pointerUp+" "+t.pointerCancel+" input",this.end,!0),t.css(this.list,"userSelect","none")},move(e){const i=this.pos-this.drag;if(0===i||this.prevPos===this.pos||!this.dragging&&Math.abs(i)<this.threshold)return;t.css(this.list,"pointerEvents","none"),e.cancelable&&e.preventDefault(),this.dragging=!0,this.dir=i<0?1:-1;const{slides:s}=this;let{prevIndex:n}=this,r=Math.abs(i),h=this.getIndex(n+this.dir,n),a=this._getDistance(n,h)||s[n].offsetWidth;for(;h!==n&&r>a;)this.drag-=a*this.dir,n=h,r-=a,h=this.getIndex(n+this.dir,n),a=this._getDistance(n,h)||s[n].offsetWidth;this.percent=r/a;const o=s[n],d=s[h],l=this.index!==h,c=n===h;let p;[this.index,this.prevIndex].filter((e=>!t.includes([h,n],e))).forEach((e=>{t.trigger(s[e],"itemhidden",[this]),c&&(p=!0,this.prevIndex=n)})),(this.index===n&&this.prevIndex!==n||p)&&t.trigger(s[this.index],"itemshown",[this]),l&&(this.prevIndex=n,this.index=h,!c&&t.trigger(o,"beforeitemhide",[this]),t.trigger(d,"beforeitemshow",[this])),this._transitioner=this._translate(Math.abs(this.percent),o,!c&&d),l&&(!c&&t.trigger(o,"itemhide",[this]),t.trigger(d,"itemshow",[this]))},end(){if(t.off(document,t.pointerMove,this.move,{passive:!1}),t.off(document,t.pointerUp+" "+t.pointerCancel+" input",this.end,!0),this.dragging)if(this.dragging=null,this.index===this.prevIndex)this.percent=1-this.percent,this.dir*=-1,this._show(!1,this.index,!0),this._transitioner=null;else{const e=(t.isRtl?this.dir*(t.isRtl?1:-1):this.dir)<0==this.prevPos>this.pos;this.index=e?this.index:this.prevIndex,e&&(this.percent=1-this.percent),this.show(this.dir>0&&!e||this.dir<0&&e?"next":"previous",!0)}t.css(this.list,{userSelect:"",pointerEvents:""}),this.drag=this.percent=null}}},{data:{selNav:!1},computed:{nav(e,i){let{selNav:s}=e;return t.$(s,i)},selNavItem(t){let{attrItem:e}=t;return"["+e+"],[data-"+e+"]"},navItems(e,i){return t.$$(this.selNavItem,i)}},update:{write(){this.nav&&this.length!==this.nav.children.length&&t.html(this.nav,this.slides.map(((t,e)=>"<li "+this.attrItem+'="'+e+'"><a href></a></li>')).join("")),this.navItems.concat(this.nav).forEach((t=>t&&(t.hidden=!this.maxIndex))),this.updateNav()},events:["resize"]},events:[{name:"click",delegate(){return this.selNavItem},handler(e){e.preventDefault(),this.show(t.data(e.current,this.attrItem))}},{name:"itemshow",handler:"updateNav"}],methods:{updateNav(){const e=this.getValidIndex();for(const i of this.navItems){const s=t.data(i,this.attrItem);t.toggleClass(i,this.clsActive,t.toNumber(s)===e),t.toggleClass(i,"uk-invisible",this.finite&&("previous"===s&&0===e||"next"===s&&e>=this.maxIndex))}}}},a],props:{clsActivated:Boolean,easing:String,index:Number,finite:Boolean,velocity:Number,selSlides:String},data:()=>({easing:"ease",finite:!1,velocity:1,index:0,prevIndex:-1,stack:[],percent:0,clsActive:"uk-active",clsActivated:!1,Transitioner:!1,transitionOptions:{}}),connected(){this.prevIndex=-1,this.index=this.getValidIndex(this.$props.index),this.stack=[]},disconnected(){t.removeClass(this.slides,this.clsActive)},computed:{duration(t,e){let{velocity:i}=t;return.5*(e.offsetWidth/i)+300},list(e,i){let{selList:s}=e;return t.$(s,i)},maxIndex(){return this.length-1},selSlides(t){let{selList:e,selSlides:i}=t;return e+" "+(i||"> *")},slides:{get(){return t.$$(this.selSlides,this.$el)},watch(){this.$reset()}},length(){return this.slides.length}},methods:{show(e,i){if(void 0===i&&(i=!1),this.dragging||!this.length)return;const{stack:s}=this,n=i?0:s.length,r=()=>{s.splice(n,1),s.length&&this.show(s.shift(),!0)};if(s[i?"unshift":"push"](e),!i&&s.length>1)return void(2===s.length&&this._transitioner.forward(Math.min(this.duration,200)));const h=this.getIndex(this.index),a=t.hasClass(this.slides,this.clsActive)&&this.slides[h],o=this.getIndex(e,this.index),d=this.slides[o];if(a===d)return void r();if(this.dir=function(t,e){return"next"===t?1:"previous"===t||t<e?-1:1}(e,h),this.prevIndex=h,this.index=o,a&&!t.trigger(a,"beforeitemhide",[this])||!t.trigger(d,"beforeitemshow",[this,a]))return this.index=this.prevIndex,void r();const l=this._show(a,d,i).then((()=>(a&&t.trigger(a,"itemhidden",[this]),t.trigger(d,"itemshown",[this]),new Promise((e=>{t.fastdom.write((()=>{s.shift(),s.length?this.show(s.shift(),!0):this._transitioner=null,e()}))})))));return a&&t.trigger(a,"itemhide",[this]),t.trigger(d,"itemshow",[this]),l},getIndex(e,i){return void 0===e&&(e=this.index),void 0===i&&(i=this.index),t.clamp(t.getIndex(e,this.slides,i,this.finite),0,this.maxIndex)},getValidIndex(t,e){return void 0===t&&(t=this.index),void 0===e&&(e=this.prevIndex),this.getIndex(t,e)},_show(t,e,i){if(this._transitioner=this._getTransitioner(t,e,this.dir,{easing:i?e.offsetWidth<600?"cubic-bezier(0.25, 0.46, 0.45, 0.94)":"cubic-bezier(0.165, 0.84, 0.44, 1)":this.easing,...this.transitionOptions}),!i&&!t)return this._translate(1),Promise.resolve();const{length:s}=this.stack;return this._transitioner[s>1?"forward":"show"](s>1?Math.min(this.duration,75+75/(s-1)):this.duration,this.percent)},_getDistance(t,e){return this._getTransitioner(t,t!==e&&e).getDistance()},_translate(t,e,i){void 0===e&&(e=this.prevIndex),void 0===i&&(i=this.index);const s=this._getTransitioner(e!==i&&e,i);return s.translate(t),s},_getTransitioner(e,i,s,n){return void 0===e&&(e=this.prevIndex),void 0===i&&(i=this.index),void 0===s&&(s=this.dir||1),void 0===n&&(n=this.transitionOptions),new this.Transitioner(t.isNumber(e)?this.slides[e]:e,t.isNumber(i)?this.slides[i]:i,s*(t.isRtl?-1:1),n)}}}],props:{animation:String},data:{animation:"slide",clsActivated:"uk-transition-active",Animations:i,Transitioner:function(e,i,s,n){let{animation:r,easing:a}=n;const{percent:o,translate:d,show:l=t.noop}=r,c=l(s),p=new t.Deferred;return{dir:s,show(n,r,o){void 0===r&&(r=0);const d=o?"linear":a;return n-=Math.round(n*t.clamp(r,-1,1)),this.translate(r),h(i,"itemin",{percent:r,duration:n,timing:d,dir:s}),h(e,"itemout",{percent:1-r,duration:n,timing:d,dir:s}),Promise.all([t.Transition.start(i,c[1],n,d),t.Transition.start(e,c[0],n,d)]).then((()=>{this.reset(),p.resolve()}),t.noop),p.promise},cancel(){t.Transition.cancel([i,e])},reset(){for(const s in c[0])t.css([i,e],s,"")},forward(s,n){return void 0===n&&(n=this.percent()),t.Transition.cancel([i,e]),this.show(s,n,!0)},translate(n){this.reset();const r=d(n,s);t.css(i,r[1]),t.css(e,r[0]),h(i,"itemtranslatein",{percent:n,dir:s}),h(e,"itemtranslateout",{percent:1-n,dir:s})},percent:()=>o(e||i,i,s),getDistance:()=>null==e?void 0:e.offsetWidth}}},computed:{animation(t){let{animation:e,Animations:i}=t;return{...i[e]||i.slide,name:e}},transitionOptions(){return{animation:this.animation}}},events:{beforeitemshow(e){let{target:i}=e;t.addClass(i,this.clsActive)},itemshown(e){let{target:i}=e;t.addClass(i,this.clsActivated)},itemhidden(e){let{target:i}=e;t.removeClass(i,this.clsActive,this.clsActivated)}}},d={...i,fade:{show:()=>[{opacity:0,zIndex:0},{zIndex:-1}],percent:e=>1-t.css(e,"opacity"),translate:t=>[{opacity:1-t,zIndex:0},{zIndex:-1}]},scale:{show:()=>[{opacity:0,transform:r(1.5),zIndex:0},{zIndex:-1}],percent:e=>1-t.css(e,"opacity"),translate:t=>[{opacity:1-t,transform:r(1+.5*t),zIndex:0},{zIndex:-1}]},pull:{show:t=>t<0?[{transform:n(30),zIndex:-1},{transform:n(),zIndex:0}]:[{transform:n(-100),zIndex:0},{transform:n(),zIndex:-1}],percent:(t,e,i)=>i<0?1-s(e):s(t),translate:(t,e)=>e<0?[{transform:n(30*t),zIndex:-1},{transform:n(-100*(1-t)),zIndex:0}]:[{transform:n(100*-t),zIndex:0},{transform:n(30*(1-t)),zIndex:-1}]},push:{show:t=>t<0?[{transform:n(100),zIndex:0},{transform:n(),zIndex:-1}]:[{transform:n(-30),zIndex:-1},{transform:n(),zIndex:0}],percent:(t,e,i)=>i>0?1-s(e):s(t),translate:(t,e)=>e<0?[{transform:n(100*t),zIndex:0},{transform:n(-30*(1-t)),zIndex:-1}]:[{transform:n(-30*t),zIndex:-1},{transform:n(100*(1-t)),zIndex:0}]}},l={mixins:[e,o,{update:{write(){if(this.stack.length||this.dragging)return;const t=this.getValidIndex(this.index);~this.prevIndex&&this.index===t||this.show(t)},events:["resize"]}},{mixins:[{methods:{lazyload(e,i){void 0===e&&(e=this.$el),void 0===i&&(i=this.$el),this.registerObserver(t.observeIntersection(e,((e,s)=>{for(const e of t.toNodes(t.isFunction(i)?i():i))t.$$('[loading="lazy"]',e).forEach((e=>t.removeAttr(e,"loading")));for(const t of e.filter((t=>{let{isIntersecting:e}=t;return e})).map((t=>{let{target:e}=t;return e})))s.unobserve(t)})))}}}],connected(){this.lazyload(this.slides,this.getAdjacentSlides)}}],props:{ratio:String,minHeight:Number,maxHeight:Number},data:{ratio:"16:9",minHeight:!1,maxHeight:!1,selList:".uk-slideshow-items",attrItem:"uk-slideshow-item",selNav:".uk-slideshow-nav",Animations:d},update:{read(){if(!this.list)return!1;let[e,i]=this.ratio.split(":").map(Number);return i=i*this.list.offsetWidth/e||0,this.minHeight&&(i=Math.max(this.minHeight,i)),this.maxHeight&&(i=Math.min(this.maxHeight,i)),{height:i-t.boxModelAdjust(this.list,"height","content-box")}},write(e){let{height:i}=e;i>0&&t.css(this.list,"minHeight",i)},events:["resize"]},methods:{getAdjacentSlides(){return[1,-1].map((t=>this.slides[this.getIndex(this.index+t)]))}}};return"undefined"!=typeof window&&window.UIkit&&window.UIkit.component("slideshow",l),l}));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.14.
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | 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,2 @@
|
|
|
1
|
-
/*! UIkit 3.14.
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
|
|
2
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("uikit-util")):"function"==typeof define&&define.amd?define("uikitsortable",["uikit-util"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).UIkitSortable=e(t.UIkit.util)}(this,(function(t){"use strict";function e(e){return function(e,s,n){const o=[[]];for(const r of e){if(!t.isVisible(r))continue;let e=i(r);for(let t=o.length-1;t>=0;t--){const a=o[t];if(!a[0]){a.push(r);break}let h;if(a[0].offsetParent===r.offsetParent?h=i(a[0]):(e=i(r,!0),h=i(a[0],!0)),e[s]>=h[n]-1&&e[s]!==h[s]){o.push([r]);break}if(e[n]-1>h[s]||e[s]===h[s]){a.push(r);break}if(0===t){o.unshift([r]);break}}}return o}(e,"top","bottom")}function i(e,i){void 0===i&&(i=!1);let{offsetTop:s,offsetLeft:n,offsetHeight:o,offsetWidth:r}=e;return i&&([s,n]=t.offsetPosition(e)),{top:s,left:n,bottom:s+o,right:n+r}}const s="uk-transition-leave",n="uk-transition-enter";function o(e,i,o,l){void 0===l&&(l=0);const c=r(i,!0),d={opacity:1},u={opacity:0},p=t=>()=>c===r(i)?t():Promise.reject(),m=p((()=>(t.addClass(i,s),Promise.all(h(i).map(((e,i)=>new Promise((s=>setTimeout((()=>t.Transition.start(e,u,o/2,"ease").then(s)),i*l)))))).then((()=>t.removeClass(i,s)))))),f=p((()=>{const s=t.height(i);return t.addClass(i,n),e(),t.css(t.children(i),{opacity:0}),new Promise((e=>requestAnimationFrame((()=>{const a=t.children(i),p=t.height(i);t.css(i,"alignContent","flex-start"),t.height(i,s);const m=h(i);t.css(a,u);const f=m.map(((e,i)=>new Promise((s=>setTimeout((()=>t.Transition.start(e,d,o/2,"ease").then(s)),i*l)))));s!==p&&f.push(t.Transition.start(i,{height:p},o/2+m.length*l,"ease")),Promise.all(f).then((()=>{t.removeClass(i,n),c===r(i)&&(t.css(i,{height:"",alignContent:""}),t.css(a,{opacity:""}),delete i.dataset.transition),e()}))}))))}));return t.hasClass(i,s)?a(i).then(f):t.hasClass(i,n)?a(i).then(m).then(f):m().then(f)}function r(e,i){return i&&(e.dataset.transition=1+r(e)),t.toNumber(e.dataset.transition)||0}function a(e){return Promise.all(t.children(e).filter(t.Transition.inProgress).map((e=>new Promise((i=>t.once(e,"transitionend transitioncanceled",i))))))}function h(i){return e(t.children(i)).reduce(((e,i)=>e.concat(t.sortBy(i.filter((e=>t.isInView(e))),"offsetLeft"))),[])}function l(e,i,s){return new Promise((n=>requestAnimationFrame((()=>{let o=t.children(i);const r=o.map((t=>c(t,!0))),a=t.css(i,["height","padding"]);t.Transition.cancel(i),o.forEach(t.Transition.cancel),d(i),e(),o=o.concat(t.children(i).filter((e=>!t.includes(o,e)))),Promise.resolve().then((()=>{t.fastdom.flush();const e=t.css(i,["height","padding"]),[h,l]=function(e,i,s){const n=i.map(((e,i)=>!(!t.parent(e)||!(i in s))&&(s[i]?t.isVisible(e)?u(e):{opacity:0}:{opacity:t.isVisible(e)?1:0}))),o=n.map(((n,o)=>{const r=t.parent(i[o])===e&&(s[o]||c(i[o]));if(!r)return!1;if(n){if(!("opacity"in n)){const{opacity:t}=r;t%1?n.opacity=1:delete r.opacity}}else delete r.opacity;return r}));return[n,o]}(i,o,r);o.forEach(((e,i)=>l[i]&&t.css(e,l[i]))),t.css(i,{display:"block",...a}),requestAnimationFrame((()=>{const r=o.map(((e,n)=>t.parent(e)===i&&t.Transition.start(e,h[n],s,"ease"))).concat(t.Transition.start(i,e,s,"ease"));Promise.all(r).then((()=>{o.forEach(((e,s)=>t.parent(e)===i&&t.css(e,"display",0===h[s].opacity?"none":""))),d(i)}),t.noop).then(n)}))}))}))))}function c(e,i){const s=t.css(e,"zIndex");return!!t.isVisible(e)&&{display:"",opacity:i?t.css(e,"opacity"):"0",pointerEvents:"none",position:"absolute",zIndex:"auto"===s?t.index(e):s,...u(e)}}function d(e){t.css(e.children,{height:"",left:"",opacity:"",pointerEvents:"",position:"",top:"",marginTop:"",marginLeft:"",transform:"",width:"",zIndex:""}),t.css(e,{height:"",display:"",padding:""})}function u(e){const{height:i,width:s}=t.offset(e),{top:n,left:o}=t.position(e),{marginLeft:r,marginTop:a}=t.css(e,["marginTop","marginLeft"]);return{top:n,left:o,height:i,width:s,marginLeft:r,marginTop:a,transform:""}}var p={props:{duration:Number,animation:Boolean},data:{duration:150,animation:"slide"},methods:{animate(e,i){void 0===i&&(i=this.$el);const s=this.animation,n="fade"===s?o:"delayed-fade"===s?function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return o(...e,40)}:s?l:()=>(e(),Promise.resolve());return n(e,i,this.duration).then((()=>this.$update(i,"resize")),t.noop)}}},m={mixins:[{connected(){!t.hasClass(this.$el,this.$name)&&t.addClass(this.$el,this.$name)}},p],props:{group:String,threshold:Number,clsItem:String,clsPlaceholder:String,clsDrag:String,clsDragState:String,clsBase:String,clsNoDrag:String,clsEmpty:String,clsCustom:String,handle:String},data:{group:!1,threshold:5,clsItem:"uk-sortable-item",clsPlaceholder:"uk-sortable-placeholder",clsDrag:"uk-sortable-drag",clsDragState:"uk-drag",clsBase:"uk-sortable",clsNoDrag:"uk-sortable-nodrag",clsEmpty:"uk-sortable-empty",clsCustom:"",handle:!1,pos:{}},created(){for(const e of["init","start","move","end"]){const i=this[e];this[e]=e=>{t.assign(this.pos,t.getEventPos(e)),i(e)}}},events:{name:t.pointerDown,passive:!1,handler:"init"},computed:{target(){return(this.$el.tBodies||[this.$el])[0]},items(){return t.children(this.target)},isEmpty:{get(){return t.isEmpty(this.items)},watch(e){t.toggleClass(this.target,this.clsEmpty,e)},immediate:!0},handles:{get(e,i){let{handle:s}=e;return s?t.$$(s,i):this.items},watch(e,i){t.css(i,{touchAction:"",userSelect:""}),t.css(e,{touchAction:t.hasTouch?"none":"",userSelect:"none"})},immediate:!0}},update:{write(e){if(!this.drag||!t.parent(this.placeholder))return;const{pos:{x:i,y:s},origin:{offsetTop:n,offsetLeft:o},placeholder:r}=this;t.css(this.drag,{top:s-n,left:i-o});const a=this.getSortable(document.elementFromPoint(i,s));if(!a)return;const{items:h}=a;if(h.some(t.Transition.inProgress))return;const l=function(e,i){return e[t.findIndex(e,(e=>t.pointInRect(i,e.getBoundingClientRect())))]}(h,{x:i,y:s});if(h.length&&(!l||l===r))return;const c=this.getSortable(r),d=function(e,i,s,n,o,r){if(!t.children(e).length)return;const a=i.getBoundingClientRect();if(!r)return function(e,i){const s=1===t.children(e).length;s&&t.append(e,i);const n=t.children(e),o=n.some(((t,e)=>{const i=t.getBoundingClientRect();return n.slice(e+1).some((t=>{const e=t.getBoundingClientRect();return!g([i.left,i.right],[e.left,e.right])}))}));s&&t.remove(i);return o}(e,s)||o<a.top+a.height/2?i:i.nextElementSibling;const h=s.getBoundingClientRect(),l=g([a.top,a.bottom],[h.top,h.bottom]),c=l?n:o,d=l?"width":"height",u=l?"left":"top",p=l?"right":"bottom",m=h[d]<a[d]?a[d]-h[d]:0;if(h[u]<a[u])return!(m&&c<a[u]+m)&&i.nextElementSibling;if(m&&c>a[p]-m)return!1;return i}(a.target,l,r,i,s,a===c&&e.moved!==l);!1!==d&&(d&&r===d||(a!==c?(c.remove(r),e.moved=l):delete e.moved,a.insert(r,d),this.touched.add(a)))},events:["move"]},methods:{init(e){const{target:i,button:s,defaultPrevented:n}=e,[o]=this.items.filter((e=>t.within(i,e)));!o||n||s>0||t.isInput(i)||t.within(i,"."+this.clsNoDrag)||this.handle&&!t.within(i,this.handle)||(e.preventDefault(),this.touched=new Set([this]),this.placeholder=o,this.origin={target:i,index:t.index(o),...this.pos},t.on(document,t.pointerMove,this.move),t.on(document,t.pointerUp,this.end),this.threshold||this.start(e))},start(e){this.drag=function(e,i){const s=t.append(e,i.outerHTML.replace(/(^<)(?:li|tr)|(?:li|tr)(\/>$)/g,"$1div$2"));return t.css(s,"margin","0","important"),t.css(s,{boxSizing:"border-box",width:i.offsetWidth,height:i.offsetHeight,padding:t.css(i,"padding")}),t.height(s.firstElementChild,t.height(i.firstElementChild)),s}(this.$container,this.placeholder);const{left:i,top:s}=this.placeholder.getBoundingClientRect();t.assign(this.origin,{offsetLeft:this.pos.x-i,offsetTop:this.pos.y-s}),t.addClass(this.drag,this.clsDrag,this.clsCustom),t.addClass(this.placeholder,this.clsPlaceholder),t.addClass(this.items,this.clsItem),t.addClass(document.documentElement,this.clsDragState),t.trigger(this.$el,"start",[this,this.placeholder]),function(e){let i=Date.now();f=setInterval((()=>{let{x:s,y:n}=e;n+=t.scrollTop(window);const o=.3*(Date.now()-i);i=Date.now(),t.scrollParents(document.elementFromPoint(s,e.y),/auto|scroll/).reverse().some((e=>{let{scrollTop:i,scrollHeight:s}=e;const{top:r,bottom:a,height:h}=t.offsetViewport(e);if(r<n&&r+35>n)i-=o;else{if(!(a>n&&a-35<n))return;i+=o}if(i>0&&i<s-h)return t.scrollTop(e,i),!0}))}),15)}(this.pos),this.move(e)},move(t){this.drag?this.$emit("move"):(Math.abs(this.pos.x-this.origin.x)>this.threshold||Math.abs(this.pos.y-this.origin.y)>this.threshold)&&this.start(t)},end(){if(t.off(document,t.pointerMove,this.move),t.off(document,t.pointerUp,this.end),!this.drag)return;clearInterval(f);const e=this.getSortable(this.placeholder);this===e?this.origin.index!==t.index(this.placeholder)&&t.trigger(this.$el,"moved",[this,this.placeholder]):(t.trigger(e.$el,"added",[e,this.placeholder]),t.trigger(this.$el,"removed",[this,this.placeholder])),t.trigger(this.$el,"stop",[this,this.placeholder]),t.remove(this.drag),this.drag=null;for(const{clsPlaceholder:e,clsItem:i}of this.touched)for(const s of this.touched)t.removeClass(s.items,e,i);this.touched=null,t.removeClass(document.documentElement,this.clsDragState)},insert(e,i){t.addClass(this.items,this.clsItem);this.animate((()=>i?t.before(i,e):t.append(this.target,e)))},remove(e){t.within(e,this.target)&&this.animate((()=>t.remove(e)))},getSortable(e){do{const t=this.$getComponent(e,"sortable");if(t&&(t===this||!1!==this.group&&t.group===this.group))return t}while(e=t.parent(e))}}};let f;function g(t,e){return t[1]>e[0]&&e[1]>t[0]}return"undefined"!=typeof window&&window.UIkit&&window.UIkit.component("sortable",m),m}));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.14.
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | 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')) :
|
|
@@ -82,6 +82,11 @@
|
|
|
82
82
|
return Promise.reject();
|
|
83
83
|
}
|
|
84
84
|
|
|
85
|
+
if (!animate) {
|
|
86
|
+
uikitUtil.Animation.cancel(el);
|
|
87
|
+
uikitUtil.Transition.cancel(el);
|
|
88
|
+
}
|
|
89
|
+
|
|
85
90
|
const promise = (
|
|
86
91
|
uikitUtil.isFunction(animate) ?
|
|
87
92
|
animate :
|
|
@@ -230,8 +235,7 @@
|
|
|
230
235
|
data: {
|
|
231
236
|
pos: "bottom-" + (uikitUtil.isRtl ? 'right' : 'left'),
|
|
232
237
|
flip: true,
|
|
233
|
-
offset: false,
|
|
234
|
-
viewportPadding: 10 },
|
|
238
|
+
offset: false },
|
|
235
239
|
|
|
236
240
|
|
|
237
241
|
connected() {
|
|
@@ -243,15 +247,11 @@
|
|
|
243
247
|
positionAt(element, target, boundary) {
|
|
244
248
|
const [dir, align] = this.pos;
|
|
245
249
|
|
|
246
|
-
let
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
uikitUtil.offset(target)[this.axis === 'x' ? 'right' : 'bottom'] :
|
|
252
|
-
0;
|
|
253
|
-
}
|
|
254
|
-
offset = uikitUtil.toPx(offset) + uikitUtil.toPx(uikitUtil.getCssVar('position-offset', element));
|
|
250
|
+
let offset = uikitUtil.toPx(
|
|
251
|
+
this.offset === false ? uikitUtil.getCssVar('position-offset', element) : this.offset,
|
|
252
|
+
this.axis === 'x' ? 'width' : 'height',
|
|
253
|
+
element);
|
|
254
|
+
|
|
255
255
|
offset = [uikitUtil.includes(['left', 'top'], dir) ? -offset : +offset, 0];
|
|
256
256
|
|
|
257
257
|
const attach = {
|
|
@@ -270,8 +270,8 @@
|
|
|
270
270
|
attach,
|
|
271
271
|
offset,
|
|
272
272
|
boundary,
|
|
273
|
-
|
|
274
|
-
|
|
273
|
+
flip: this.flip,
|
|
274
|
+
viewportOffset: uikitUtil.toPx(uikitUtil.getCssVar('position-viewport-offset', element)) });
|
|
275
275
|
|
|
276
276
|
} } };
|
|
277
277
|
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
/*! UIkit 3.14.
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
|
|
2
|
+
!function(t,i){"object"==typeof exports&&"undefined"!=typeof module?module.exports=i(require("uikit-util")):"function"==typeof define&&define.amd?define("uikittooltip",["uikit-util"],i):(t="undefined"!=typeof globalThis?globalThis:t||self).UIkitTooltip=i(t.UIkit.util)}(this,(function(t){"use strict";var i={mixins:[{props:{container:Boolean},data:{container:!0},computed:{container(i){let{container:o}=i;return!0===o&&this.$container||o&&t.$(o)}}},{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:"",height:"",paddingTop:"",paddingBottom:"",marginTop:"",marginBottom:"",boxShadow:""},hideProps:{overflow:"hidden",height:0,paddingTop:0,paddingBottom:0,marginTop:0,marginBottom:0,boxShadow:"none"}},computed:{hasAnimation(t){let{animation:i}=t;return!!i[0]},hasTransition(t){let{animation:i}=t;return this.hasAnimation&&!0===i[0]}},methods:{toggleElement(i,o,e){return new Promise((s=>Promise.all(t.toNodes(i).map((i=>{const s=t.isBoolean(o)?o:!this.isToggled(i);if(!t.trigger(i,"before"+(s?"show":"hide"),[this]))return Promise.reject();e||(t.Animation.cancel(i),t.Transition.cancel(i));const n=(t.isFunction(e)?e:!1!==e&&this.hasAnimation?this.hasTransition?function(i){let{isToggled:o,duration:e,velocity:s,initProps:n,hideProps:h,transition:a,_toggle:l}=i;return(i,r)=>{const d=t.Transition.inProgress(i),p=i.hasChildNodes()?t.toFloat(t.css(i.firstElementChild,"marginTop"))+t.toFloat(t.css(i.lastElementChild,"marginBottom")):0,c=t.isVisible(i)?t.height(i)+(d?0:p):0;t.Transition.cancel(i),o(i)||l(i,!0),t.height(i,""),t.fastdom.flush();const u=t.height(i)+(d?0:p);return e=s*i.offsetHeight+e,t.height(i,c),(r?t.Transition.start(i,{...n,overflow:"hidden",height:u},Math.round(e*(1-c/u)),a):t.Transition.start(i,h,Math.round(e*(c/u)),a).then((()=>l(i,!1)))).then((()=>t.css(i,n)))}}(this):(h=this,(i,o)=>{t.Animation.cancel(i);const{animation:e,duration:s,_toggle:n}=h;return o?(n(i,!0),t.Animation.in(i,e[0],s,h.origin)):t.Animation.out(i,e[1]||e[0],s,h.origin).then((()=>n(i,!1)))}):this._toggle)(i,s);var h;const a=s?this.clsEnter:this.clsLeave;t.addClass(i,a),t.trigger(i,s?"show":"hide",[this]);const l=()=>{t.removeClass(i,a),t.trigger(i,s?"shown":"hidden",[this]),this.$update(i)};return n?n.then(l,(()=>(t.removeClass(i,a),Promise.reject()))):l()}))).then(s,t.noop)))},isToggled(i){return void 0===i&&(i=this.$el),[i]=t.toNodes(i),!!t.hasClass(i,this.clsEnter)||!t.hasClass(i,this.clsLeave)&&(this.cls?t.hasClass(i,this.cls.split(" ")[0]):t.isVisible(i))},_toggle(i,o){if(!i)return;let e;o=Boolean(o),this.cls?(e=t.includes(this.cls," ")||o!==t.hasClass(i,this.cls),e&&t.toggleClass(i,this.cls,t.includes(this.cls," ")?void 0:o)):(e=o===i.hidden,e&&(i.hidden=!o)),t.$$("[autofocus]",i).some((i=>t.isVisible(i)?i.focus()||!0:i.blur())),e&&(t.trigger(i,"toggled",[o,this]),this.$update(i))}}},{props:{pos:String,offset:null,flip:Boolean},data:{pos:"bottom-"+(t.isRtl?"right":"left"),flip:!0,offset:!1},connected(){this.pos=this.$props.pos.split("-").concat("center").slice(0,2),this.axis=t.includes(["top","bottom"],this.pos[0])?"y":"x"},methods:{positionAt(i,o,e){const[s,n]=this.pos;let h=t.toPx(!1===this.offset?t.getCssVar("position-offset",i):this.offset,"x"===this.axis?"width":"height",i);h=[t.includes(["left","top"],s)?-h:+h,0];const a={element:[t.flipPosition(s),n],target:[s,n]};if("y"===this.axis){for(const t in a)a[t]=a[t].reverse();h=h.reverse()}t.positionAt(i,o,{attach:a,offset:h,boundary:e,flip:this.flip,viewportOffset:t.toPx(t.getCssVar("position-viewport-offset",i))})}}}],args:"title",props:{delay:Number,title:String},data:{pos:"top",title:"",delay:0,animation:["uk-animation-scale-up"],duration:100,cls:"uk-active"},beforeConnect(){var i;this._hasTitle=t.hasAttr(this.$el,"title"),t.attr(this.$el,"title",""),this.updateAria(!1),i=this.$el,t.isFocusable(i)||t.attr(i,"tabindex","0")},disconnected(){this.hide(),t.attr(this.$el,"title",this._hasTitle?this.title:null)},methods:{show(){!this.isToggled(this.tooltip||null)&&this.title&&(this._unbind=t.once(document,"show keydown "+t.pointerDown,this.hide,!1,(i=>i.type===t.pointerDown&&!t.within(i.target,this.$el)||"keydown"===i.type&&27===i.keyCode||"show"===i.type&&i.detail[0]!==this&&i.detail[0].$name===this.$name)),clearTimeout(this.showTimer),this.showTimer=setTimeout(this._show,this.delay))},async hide(){t.matches(this.$el,"input:focus")||(clearTimeout(this.showTimer),this.isToggled(this.tooltip||null)&&(await this.toggleElement(this.tooltip,!1,!1),t.remove(this.tooltip),this.tooltip=null,this._unbind()))},_show(){this.tooltip=t.append(this.container,'<div class="uk-'+this.$options.name+'"> <div class="uk-'+this.$options.name+'-inner">'+this.title+"</div> </div>"),t.on(this.tooltip,"toggled",((i,o)=>{if(this.updateAria(o),!o)return;this.positionAt(this.tooltip,this.$el);const[e,s]=function(i,o,e){let[s,n]=e;const h=t.offset(i),a=t.offset(o),l=[["left","right"],["top","bottom"]];for(const t of l){if(h[t[0]]>=a[t[1]]){s=t[1];break}if(h[t[1]]<=a[t[0]]){s=t[0];break}}const r=t.includes(l[0],s)?l[1]:l[0];n=h[r[0]]===a[r[0]]?r[0]:h[r[1]]===a[r[1]]?r[1]:"center";return[s,n]}(this.tooltip,this.$el,this.pos);this.origin="y"===this.axis?t.flipPosition(e)+"-"+s:s+"-"+t.flipPosition(e)})),this.toggleElement(this.tooltip,!0)},updateAria(i){t.attr(this.$el,"aria-expanded",i)}},events:{focus:"show",blur:"hide",[t.pointerEnter+" "+t.pointerLeave](i){t.isTouch(i)||this[i.type===t.pointerEnter?"show":"hide"]()},[t.pointerDown](i){t.isTouch(i)&&this.show()}}};return"undefined"!=typeof window&&window.UIkit&&window.UIkit.component("tooltip",i),i}));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.14.
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | 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,2 @@
|
|
|
1
|
-
/*! UIkit 3.14.
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | https://www.getuikit.com | (c) 2014 - 2022 YOOtheme | MIT License */
|
|
2
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("uikit-util")):"function"==typeof define&&define.amd?define("uikitupload",["uikit-util"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).UIkitUpload=t(e.UIkit.util)}(this,(function(e){"use strict";var t={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:e.noop,beforeAll:e.noop,beforeSend:e.noop,complete:e.noop,completeAll:e.noop,error:e.noop,fail:e.noop,load:e.noop,loadEnd:e.noop,loadStart:e.noop,progress:e.noop},events:{change(t){e.matches(t.target,'input[type="file"]')&&(t.preventDefault(),t.target.files&&this.upload(t.target.files),t.target.value="")},drop(t){o(t);const i=t.dataTransfer;null!=i&&i.files&&(e.removeClass(this.$el,this.clsDragover),this.upload(i.files))},dragenter(e){o(e)},dragover(t){o(t),e.addClass(this.$el,this.clsDragover)},dragleave(t){o(t),e.removeClass(this.$el,this.clsDragover)}},methods:{async upload(t){if(!(t=e.toArray(t)).length)return;e.trigger(this.$el,"upload",[t]);for(const e of t){if(this.maxSize&&1e3*this.maxSize<e.size)return void this.fail(this.msgInvalidSize.replace("%s",this.maxSize));if(this.allow&&!i(this.allow,e.name))return void this.fail(this.msgInvalidName.replace("%s",this.allow));if(this.mime&&!i(this.mime,e.type))return void this.fail(this.msgInvalidMime.replace("%s",this.mime))}this.multiple||(t=t.slice(0,1)),this.beforeAll(this,t);const o=function(e,t){const i=[];for(let o=0;o<e.length;o+=t)i.push(e.slice(o,o+t));return i}(t,this.concurrent),a=async t=>{const i=new FormData;t.forEach((e=>i.append(this.name,e)));for(const e in this.params)i.append(e,this.params[e]);try{const t=await e.ajax(this.url,{data:i,method:this.method,responseType:this.type,beforeSend:t=>{const{xhr:i}=t;i.upload&&e.on(i.upload,"progress",this.progress);for(const t of["loadStart","load","loadEnd","abort"])e.on(i,t.toLowerCase(),this[t]);return this.beforeSend(t)}});this.complete(t),o.length?await a(o.shift()):this.completeAll(t)}catch(e){this.error(e)}};await a(o.shift())}}};function i(e,t){return t.match(new RegExp("^"+e.replace(/\//g,"\\/").replace(/\*\*/g,"(\\/[^\\/]+)*").replace(/\*/g,"[^\\/]+").replace(/((?!\\))\?/g,"$1.")+"$","i"))}function o(e){e.preventDefault(),e.stopPropagation()}return"undefined"!=typeof window&&window.UIkit&&window.UIkit.component("upload",t),t}));
|
package/dist/js/uikit-core.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! UIkit 3.14.
|
|
1
|
+
/*! UIkit 3.14.2-dev.5f6f1e6a6 | 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() :
|
|
@@ -1911,11 +1911,6 @@
|
|
|
1911
1911
|
function offsetViewport(scrollElement) {
|
|
1912
1912
|
let viewportElement = getViewport$1(scrollElement);
|
|
1913
1913
|
|
|
1914
|
-
// iOS 12 returns <body> as scrollingElement
|
|
1915
|
-
if (viewportElement === scrollingElement(viewportElement)) {
|
|
1916
|
-
viewportElement = document.documentElement;
|
|
1917
|
-
}
|
|
1918
|
-
|
|
1919
1914
|
let rect = offset(viewportElement);
|
|
1920
1915
|
for (let [prop, dir, start, end] of [
|
|
1921
1916
|
['width', 'x', 'left', 'right'],
|
|
@@ -1924,9 +1919,8 @@
|
|
|
1924
1919
|
if (!isWindow(getViewport$1(viewportElement))) {
|
|
1925
1920
|
rect[start] += toFloat(css(viewportElement, "border" + ucfirst(start) + "Width"));
|
|
1926
1921
|
}
|
|
1927
|
-
rect[prop] = rect[dir] =
|
|
1928
|
-
isWindow(viewportElement) ?
|
|
1929
|
-
ucfirst(prop)];
|
|
1922
|
+
rect[prop] = rect[dir] =
|
|
1923
|
+
viewportElement[(isWindow(viewportElement) ? 'inner' : 'client') + ucfirst(prop)];
|
|
1930
1924
|
rect[end] = rect[prop] + rect[start];
|
|
1931
1925
|
}
|
|
1932
1926
|
return rect;
|
|
@@ -1990,6 +1984,10 @@
|
|
|
1990
1984
|
return position;
|
|
1991
1985
|
}
|
|
1992
1986
|
|
|
1987
|
+
function moveBy(start, end, dim) {
|
|
1988
|
+
return start === 'center' ? dim / 2 : start === end ? dim : 0;
|
|
1989
|
+
}
|
|
1990
|
+
|
|
1993
1991
|
function attachToWithFlip(element, target, options) {
|
|
1994
1992
|
const position = attachTo(element, target, options);
|
|
1995
1993
|
const targetDim = offset(target);
|
|
@@ -2000,7 +1998,7 @@
|
|
|
2000
1998
|
offset: elOffset,
|
|
2001
1999
|
boundary,
|
|
2002
2000
|
viewport,
|
|
2003
|
-
|
|
2001
|
+
viewportOffset } =
|
|
2004
2002
|
options;
|
|
2005
2003
|
|
|
2006
2004
|
let viewports = scrollParents(element);
|
|
@@ -2021,9 +2019,9 @@
|
|
|
2021
2019
|
|
|
2022
2020
|
viewport = getIntersectionArea(...viewports.filter(Boolean).map(offsetViewport));
|
|
2023
2021
|
|
|
2024
|
-
if (
|
|
2025
|
-
viewport[start] +=
|
|
2026
|
-
viewport[end] -=
|
|
2022
|
+
if (viewportOffset) {
|
|
2023
|
+
viewport[start] += viewportOffset;
|
|
2024
|
+
viewport[end] -= viewportOffset;
|
|
2027
2025
|
}
|
|
2028
2026
|
|
|
2029
2027
|
if (boundary && !willFlip && position[prop] <= offset(boundary)[prop]) {
|
|
@@ -2113,10 +2111,6 @@
|
|
|
2113
2111
|
return offsetPosition;
|
|
2114
2112
|
}
|
|
2115
2113
|
|
|
2116
|
-
function moveBy(start, end, dim) {
|
|
2117
|
-
return start === 'center' ? dim / 2 : start === end ? dim : 0;
|
|
2118
|
-
}
|
|
2119
|
-
|
|
2120
2114
|
function getIntersectionArea() {
|
|
2121
2115
|
let area = {};for (var _len = arguments.length, rects = new Array(_len), _key = 0; _key < _len; _key++) {rects[_key] = arguments[_key];}
|
|
2122
2116
|
for (const rect of rects) {
|
|
@@ -2474,7 +2468,7 @@
|
|
|
2474
2468
|
const {
|
|
2475
2469
|
$options: { computed } } =
|
|
2476
2470
|
this;
|
|
2477
|
-
const values = { ...
|
|
2471
|
+
const values = { ...this._computed };
|
|
2478
2472
|
this._computed = {};
|
|
2479
2473
|
|
|
2480
2474
|
for (const key in computed) {
|
|
@@ -2954,7 +2948,7 @@
|
|
|
2954
2948
|
UIkit.data = '__uikit__';
|
|
2955
2949
|
UIkit.prefix = 'uk-';
|
|
2956
2950
|
UIkit.options = {};
|
|
2957
|
-
UIkit.version = '3.14.
|
|
2951
|
+
UIkit.version = '3.14.2-dev.5f6f1e6a6';
|
|
2958
2952
|
|
|
2959
2953
|
globalAPI(UIkit);
|
|
2960
2954
|
hooksAPI(UIkit);
|
|
@@ -3103,6 +3097,11 @@
|
|
|
3103
3097
|
return Promise.reject();
|
|
3104
3098
|
}
|
|
3105
3099
|
|
|
3100
|
+
if (!animate) {
|
|
3101
|
+
Animation.cancel(el);
|
|
3102
|
+
Transition.cancel(el);
|
|
3103
|
+
}
|
|
3104
|
+
|
|
3106
3105
|
const promise = (
|
|
3107
3106
|
isFunction(animate) ?
|
|
3108
3107
|
animate :
|
|
@@ -3582,8 +3581,7 @@
|
|
|
3582
3581
|
data: {
|
|
3583
3582
|
pos: "bottom-" + (isRtl ? 'right' : 'left'),
|
|
3584
3583
|
flip: true,
|
|
3585
|
-
offset: false,
|
|
3586
|
-
viewportPadding: 10 },
|
|
3584
|
+
offset: false },
|
|
3587
3585
|
|
|
3588
3586
|
|
|
3589
3587
|
connected() {
|
|
@@ -3595,16 +3593,12 @@
|
|
|
3595
3593
|
positionAt(element, target, boundary) {
|
|
3596
3594
|
const [dir, align] = this.pos;
|
|
3597
3595
|
|
|
3598
|
-
let
|
|
3599
|
-
|
|
3600
|
-
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
0;
|
|
3605
|
-
}
|
|
3606
|
-
offset$1 = toPx(offset$1) + toPx(getCssVar('position-offset', element));
|
|
3607
|
-
offset$1 = [includes(['left', 'top'], dir) ? -offset$1 : +offset$1, 0];
|
|
3596
|
+
let offset = toPx(
|
|
3597
|
+
this.offset === false ? getCssVar('position-offset', element) : this.offset,
|
|
3598
|
+
this.axis === 'x' ? 'width' : 'height',
|
|
3599
|
+
element);
|
|
3600
|
+
|
|
3601
|
+
offset = [includes(['left', 'top'], dir) ? -offset : +offset, 0];
|
|
3608
3602
|
|
|
3609
3603
|
const attach = {
|
|
3610
3604
|
element: [flipPosition(dir), align],
|
|
@@ -3615,15 +3609,15 @@
|
|
|
3615
3609
|
for (const prop in attach) {
|
|
3616
3610
|
attach[prop] = attach[prop].reverse();
|
|
3617
3611
|
}
|
|
3618
|
-
offset
|
|
3612
|
+
offset = offset.reverse();
|
|
3619
3613
|
}
|
|
3620
3614
|
|
|
3621
3615
|
positionAt(element, target, {
|
|
3622
3616
|
attach,
|
|
3623
|
-
offset
|
|
3617
|
+
offset,
|
|
3624
3618
|
boundary,
|
|
3625
|
-
|
|
3626
|
-
|
|
3619
|
+
flip: this.flip,
|
|
3620
|
+
viewportOffset: toPx(getCssVar('position-viewport-offset', element)) });
|
|
3627
3621
|
|
|
3628
3622
|
} } };
|
|
3629
3623
|
|
|
@@ -3974,19 +3968,27 @@
|
|
|
3974
3968
|
toggleClass(this.$el, this.clsDrop + "-boundary", this.boundaryAlign);
|
|
3975
3969
|
|
|
3976
3970
|
const boundary = query(this.boundary, this.$el);
|
|
3977
|
-
const
|
|
3978
|
-
|
|
3971
|
+
const scrollParentOffset = offset(
|
|
3972
|
+
scrollParents(boundary && this.boundaryAlign ? boundary : this.$el)[0]);
|
|
3973
|
+
|
|
3979
3974
|
const boundaryOffset = boundary ? offset(boundary) : scrollParentOffset;
|
|
3980
3975
|
|
|
3981
3976
|
css(this.$el, 'maxWidth', '');
|
|
3982
3977
|
const maxWidth =
|
|
3983
|
-
scrollParentOffset.width -
|
|
3978
|
+
scrollParentOffset.width -
|
|
3979
|
+
2 * toPx(getCssVar('position-viewport-offset', this.$el));
|
|
3984
3980
|
|
|
3985
3981
|
if (this.pos[1] === 'justify') {
|
|
3986
3982
|
const prop = this.axis === 'y' ? 'width' : 'height';
|
|
3987
|
-
|
|
3988
|
-
|
|
3989
|
-
|
|
3983
|
+
css(
|
|
3984
|
+
this.$el,
|
|
3985
|
+
prop,
|
|
3986
|
+
Math.min(
|
|
3987
|
+
(boundary ? boundaryOffset : offset(this.target))[prop],
|
|
3988
|
+
scrollParentOffset[prop] -
|
|
3989
|
+
2 * toPx(getCssVar('position-viewport-offset', this.$el))));
|
|
3990
|
+
|
|
3991
|
+
|
|
3990
3992
|
} else if (this.$el.offsetWidth > maxWidth) {
|
|
3991
3993
|
addClass(this.$el, this.clsDrop + "-stack");
|
|
3992
3994
|
}
|
|
@@ -4464,7 +4466,7 @@
|
|
|
4464
4466
|
}
|
|
4465
4467
|
|
|
4466
4468
|
var heightViewport = {
|
|
4467
|
-
mixins: [
|
|
4469
|
+
mixins: [Resize],
|
|
4468
4470
|
|
|
4469
4471
|
props: {
|
|
4470
4472
|
expand: Boolean,
|
|
@@ -6443,13 +6445,13 @@
|
|
|
6443
6445
|
return target ? $$(target, $el) : [$el];
|
|
6444
6446
|
},
|
|
6445
6447
|
|
|
6446
|
-
watch(elements) {
|
|
6448
|
+
watch(elements, prev) {
|
|
6447
6449
|
if (this.hidden) {
|
|
6448
6450
|
css(filter(elements, ":not(." + this.inViewClass + ")"), 'visibility', 'hidden');
|
|
6449
6451
|
}
|
|
6450
6452
|
|
|
6451
|
-
|
|
6452
|
-
this
|
|
6453
|
+
if (!isEqual(elements, prev)) {
|
|
6454
|
+
this.$reset();
|
|
6453
6455
|
}
|
|
6454
6456
|
},
|
|
6455
6457
|
|
|
@@ -6459,10 +6461,9 @@
|
|
|
6459
6461
|
|
|
6460
6462
|
connected() {
|
|
6461
6463
|
this._data.elements = new Map();
|
|
6462
|
-
|
|
6463
6464
|
this.registerObserver(
|
|
6464
|
-
|
|
6465
|
-
|
|
6465
|
+
observeIntersection(
|
|
6466
|
+
this.elements,
|
|
6466
6467
|
(records) => {
|
|
6467
6468
|
const elements = this._data.elements;
|
|
6468
6469
|
for (const { target: el, isIntersecting } of records) {
|
|
@@ -6496,8 +6497,6 @@
|
|
|
6496
6497
|
for (const [el, state] of this._data.elements.entries()) {
|
|
6497
6498
|
removeClass(el, this.inViewClass, (state == null ? void 0 : state.cls) || '');
|
|
6498
6499
|
}
|
|
6499
|
-
|
|
6500
|
-
this._observer = null;
|
|
6501
6500
|
},
|
|
6502
6501
|
|
|
6503
6502
|
update: [
|
|
@@ -7342,6 +7341,10 @@
|
|
|
7342
7341
|
{
|
|
7343
7342
|
name: 'click',
|
|
7344
7343
|
|
|
7344
|
+
filter() {
|
|
7345
|
+
return ['click', 'hover'].some((mode) => includes(this.mode, mode));
|
|
7346
|
+
},
|
|
7347
|
+
|
|
7345
7348
|
handler(e) {
|
|
7346
7349
|
let link;
|
|
7347
7350
|
if (
|