@progress/kendo-vue-scrollview 3.5.0-dev.202208020811 → 3.5.0
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("vue"),require("@progress/kendo-licensing")):"function"==typeof define&&define.amd?define(["vue","@progress/kendo-licensing"],t):"object"==typeof exports?exports.KendoVueScrollview=t(require("vue"),require("@progress/kendo-licensing")):e.KendoVueScrollview=t(e.Vue,e.KendoLicensing)}(window,(function(e,t){return function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=2)}([function(t,n){t.exports=e},function(e,n){e.exports=t},function(e,t,n){"use strict";var i=Object.create?function(e,t,n,i){void 0===i&&(i=n),Object.defineProperty(e,i,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]},r=function(e,t){for(var n in e)"default"===n||t.hasOwnProperty(n)||i(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),r(n(3),t),r(n(5),t)},function(e,t,n){"use strict";var i=Object.create?function(e,t,n,i){void 0===i&&(i=n),Object.defineProperty(e,i,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]},r=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t},o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.hasOwnProperty.call(e,n)&&i(t,e,n);return r(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.ScrollViewVue2=t.ScrollView=void 0;var s=o(n(0)),u=s.h,a=s.version&&"3"===s.version[0],c=n(6),l=n(4),d={name:"KendoScrollView",props:{activeView:{type:Number,default:1},dataItems:{type:Array,default:function(){return[]}},arrows:{type:Boolean,default:!0},automaticViewChange:{type:Boolean,default:!0},automaticViewChangeInterval:{type:Number,default:5e3},content:[Object,String,Function],dir:String,endless:Boolean,pageable:{type:Boolean,default:!0},pagerOverlay:{type:String,default:"none"}},created:function(){c.validatePackage(l.packageMetadata),this.timeoutRef=null},mounted:function(){this.wrapElement=c.getRef(this,"wrapElement"),this.currentDir=void 0!==this.$props.dir?this.$props.dir:c.isRtl(this.$el)?"rtl":"ltr",this.runAutomaticChange()},updated:function(){var e=this.dataItems.length;this.wrapElement&&(this.wrapElement.style.setProperty("--kendo-scrollview-views",""+e),this.wrapElement.style.setProperty("--kendo-scrollview-current",""+this.active)),this.runAutomaticChange()},data:function(){return{active:this.activeView||1,currentDir:void 0}},computed:{scrollViewClasses:function(){return{"k-widget":!0,"k-scrollview":!0,"k-scrollview-light":"light"===this.pagerOverlay,"k-scrollview-dark":"dark"===this.pagerOverlay}},displayLeftArrow:function(){var e;return e=this.isRtl?this.active<this.dataItems.length:this.active>1,(this.endless||e)&&this.dataItems.length>0},displayRightArrow:function(){var e;return e=this.isRtl?this.active>1:this.active<this.dataItems.length,(this.endless||e)&&this.dataItems.length>0},isRtl:function(){return"rtl"===this.currentDir}},setup:a?function(){return{v3:!!a}}:void 0,render:function(e){var t=u||e,n=this.$props,i=n.pageable,r=n.arrows,o=n.content,s=this.dataItems.length,a=this.dataItems.map((function(e,n){var i=c.templateRendering.call(this,e.content||o,c.getListeners.call(this)),r=c.getTemplate.call(this,{h:t,template:i,defaultRendering:null,additionalProps:{item:e,items:this.dataItems}});return t("div",{class:"k-scrollview-view","aria-hidden":this.active!==n+1,attrs:this.v3?void 0:{"aria-hidden":this.active!==n+1}},[r])}),this);return t("div",{class:this.scrollViewClasses,tabindex:0,attrs:this.v3?void 0:{tabindex:0,dir:this.currentDir},dir:this.currentDir,onKeydown:this.handleKeyDown,on:this.v3?void 0:{keydown:this.handleKeyDown}},[t("div",{class:"k-scrollview-wrap k-scrollview-animate",style:"--kendo-scrollview-views:"+s+"; --kendo-scrollview-current:"+this.active+";",ref:c.setRef(this,"wrapElement")},[a]),t("div",{class:"k-scrollview-elements"},[r&&[this.displayLeftArrow&&t("a",{class:"k-scrollview-prev","aria-label":"previous",attrs:this.v3?void 0:{"aria-label":"previous"},onClick:this.handlePrevClick,on:this.v3?void 0:{click:this.handlePrevClick}},[t("span",{class:"k-icon k-i-arrowhead-w"})]),this.displayRightArrow&&t("a",{class:"k-scrollview-next","aria-label":"next",attrs:this.v3?void 0:{"aria-label":"next"},onClick:this.handleNextClick,on:this.v3?void 0:{click:this.handleNextClick}},[t("span",{class:"k-icon k-i-arrowhead-e"})])],i&&t("div",{class:"k-scrollview-nav-wrap"},[t("ul",{class:"k-scrollview-nav"},[this.dataItems.map((function(e,n){var i=this;return t("li",{class:c.classNames("k-link",{"k-primary":this.active===n+1}),key:n+1,onClick:function(){return i.setActive(n+1)},on:this.v3?void 0:{click:function(){return i.setActive(n+1)}}})}),this)])])])])},methods:{runAutomaticChange:function(){if(this.automaticViewChange){this.resetTimeout();var e=this,t=this.active;this.timeoutRef=setTimeout((function(){e.setActive(t===e.dataItems.length?e.endless?1:t:t+1)}),this.automaticViewChangeInterval)}},resetTimeout:function(){this.timeoutRef&&clearTimeout(this.timeoutRef)},setActive:function(e){this.active=e},focusElement:function(){this.$el&&this.$el.focus()},prev:function(){this.endless?this.active>1?this.setActive(this.active-1):this.setActive(this.dataItems.length):this.active>1&&this.setActive(this.active-1)},next:function(){this.endless?this.active<this.dataItems.length?this.setActive(this.active+1):this.setActive(1):this.active<this.dataItems.length&&this.setActive(this.active+1)},handlePrevClick:function(){this.isRtl?this.next():this.prev()},handleNextClick:function(){this.isRtl?this.prev():this.next()},handleKeyDown:function(e){switch(e.keyCode){case c.Keys.left:e.preventDefault(),this.isRtl?this.next():this.prev();break;case c.Keys.right:e.preventDefault(),this.isRtl?this.prev():this.next()}}}};t.ScrollViewVue2=d;var f=d;t.ScrollView=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.packageMetadata=void 0,t.packageMetadata={name:"@progress/kendo-vue-scrollview",productName:"Kendo UI for Vue",productCodes:["KENDOUIVUE","KENDOUICOMPLETE"],publishDate:1659427780,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,n){"use strict";n.r(t),n.d(t,"getRef",(function(){return a})),n.d(t,"setRef",(function(){return c})),n.d(t,"classNames",(function(){return r})),n.d(t,"guid",(function(){return o})),n.d(t,"Keys",(function(){return s})),n.d(t,"noop",(function(){return V})),n.d(t,"isObject",(function(){return i})),n.d(t,"getListeners",(function(){return U})),n.d(t,"hasListener",(function(){return Y})),n.d(t,"canUseDOM",(function(){return u})),n.d(t,"firstFocusableChild",(function(){return d})),n.d(t,"focusFirstFocusableChild",(function(){return h})),n.d(t,"lastFocusableChild",(function(){return f})),n.d(t,"focusLastFocusableChild",(function(){return p})),n.d(t,"focusContainer",(function(){return v})),n.d(t,"clone",(function(){return $})),n.d(t,"Draggable",(function(){return R})),n.d(t,"cloneArray",(function(){return I})),n.d(t,"cloneValue",(function(){return K})),n.d(t,"cloneObject",(function(){return E})),n.d(t,"cloneDate",(function(){return M})),n.d(t,"getTemplate",(function(){return J})),n.d(t,"templateRendering",(function(){return G})),n.d(t,"templateDefinition",(function(){return z})),n.d(t,"getTabIndex",(function(){return Z})),n.d(t,"getDefaultSlots",(function(){return S})),n.d(t,"isRtl",(function(){return ee})),n.d(t,"getDir",(function(){return te})),n.d(t,"getter",(function(){return F})),n.d(t,"setter",(function(){return X})),n.d(t,"validatePackage",(function(){return ie})),n.d(t,"kendoThemeMaps",(function(){return re}));var i=function(e){return"object"==typeof e},r=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.filter((function(e){return!0!==e&&!!e})).map((function(e){return Array.isArray(e)?r.apply(void 0,e):i(e)?Object.keys(e).map((function(t,n){return e[n]||e[t]&&t||null})).filter((function(e){return null!==e})).join(" "):e})).filter((function(e){return!!e})).join(" ")},o=function(){var e,t,n="";for(e=0;e<32;e++)t=16*Math.random()|0,8!==e&&12!==e&&16!==e&&20!==e||(n+="-"),n+=(12===e?4:16===e?3&t|8:t).toString(16);return n},s={backspace:8,tab:9,enter:13,shift:16,esc:27,space:32,pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40,delete:46},u=Boolean("undefined"!=typeof window&&window.document&&window.document.createElement);function a(e,t,n){return e.v3?e[t+"Ref"]:e.$refs[""+(n||t)]}function c(e,t,n){return e.v3?function(n){e[t+"Ref"]=n}:n||t}var l='input, [tabindex]:not([tabindex="-1"])',d=function(e){if(e){var t=e.querySelectorAll(l);if(t.length&&t[0].focus)return t[0]}},f=function(e){if(e){var t=e.querySelectorAll(l);if(t.length&&t[t.length-1].focus)return t[t.length-1]}},h=function(e){if(e){var t=e.querySelectorAll(l);t.length&&t[0].focus&&t[0].focus()}},p=function(e){if(e){var t=e.querySelectorAll(l);t.length&&t[t.length-1].focus&&t[t.length-1].focus()}},v=function(e,t){var n=!0;if(e.keyCode!==s.enter&&e.target===t)return!1;if(e.keyCode===s.enter&&e.target===t)n=!0,setTimeout((function(){h(t)}),1);else if(e.keyCode===s.esc)n=!1,t.focus();else if(e.keyCode===s.tab){var i=d(t),r=f(t);r&&!e.shiftKey&&e.target===r&&(e.preventDefault(),i.focus()),i&&e.shiftKey&&e.target===i&&(e.preventDefault(),r.focus())}return n},m=n(0),g=function(e,t){return function(n){return t(e(n))}},y=function(e,t,n){return e.addEventListener&&e.addEventListener(t,n)},w=function(e,t,n){return e&&e.removeEventListener&&e.removeEventListener(t,n)},_=function(){},b=function(e){return e.preventDefault()},k=/touch/;function O(e){return e.type.match(k)?{pageX:e.changedTouches[0].pageX,pageY:e.changedTouches[0].pageY,clientX:e.changedTouches[0].clientX,clientY:e.changedTouches[0].clientY,type:e.type,originalEvent:e,isTouch:!0}:{pageX:e.pageX,pageY:e.pageY,clientX:e.clientX,clientY:e.clientY,offsetX:e.offsetX,offsetY:e.offsetY,type:e.type,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,altKey:e.altKey,originalEvent:e}}var C=function(e){var t=this,n=e.press;void 0===n&&(n=_);var i=e.drag;void 0===i&&(i=_);var r=e.release;void 0===r&&(r=_);var o=e.mouseOnly;void 0===o&&(o=!1),this._pressHandler=g(O,n),this._dragHandler=g(O,i),this._releaseHandler=g(O,r),this._ignoreMouse=!1,this._mouseOnly=o,this._touchstart=function(e){1===e.touches.length&&t._pressHandler(e)},this._touchmove=function(e){1===e.touches.length&&t._dragHandler(e)},this._touchend=function(e){0===e.touches.length&&1===e.changedTouches.length&&(t._releaseHandler(e),t._ignoreMouse=!0,setTimeout(t._restoreMouse,2e3))},this._restoreMouse=function(){t._ignoreMouse=!1},this._mousedown=function(e){var n=e.which;n&&n>1||t._ignoreMouse||(y(t.document,"mousemove",t._mousemove),y(t.document,"mouseup",t._mouseup),t._pressHandler(e))},this._mousemove=function(e){t._dragHandler(e)},this._mouseup=function(e){w(t.document,"mousemove",t._mousemove),w(t.document,"mouseup",t._mouseup),t._releaseHandler(e)},this._pointerdown=function(e){e.isPrimary&&0===e.button&&(y(t.document,"pointermove",t._pointermove),y(t.document,"pointerup",t._pointerup),y(t.document,"pointercancel",t._pointerup),y(t.document,"contextmenu",b),t._pressHandler(e))},this._pointermove=function(e){e.isPrimary&&t._dragHandler(e)},this._pointerup=function(e){e.isPrimary&&(w(t.document,"pointermove",t._pointermove),w(t.document,"pointerup",t._pointerup),w(t.document,"pointercancel",t._pointerup),w(t.document,"contextmenu",b),t._releaseHandler(e))}},P={document:{configurable:!0}};C.supportPointerEvent=function(){return"undefined"!=typeof window&&window.PointerEvent},P.document.get=function(){return this._element?this._element.ownerDocument:document},C.prototype.bindTo=function(e){e!==this._element&&(this._element&&this._unbindFromCurrent(),this._element=e,this._bindToCurrent())},C.prototype._bindToCurrent=function(){var e=this._element;this._usePointers()?y(e,"pointerdown",this._pointerdown):(y(e,"mousedown",this._mousedown),this._mouseOnly||(y(e,"touchstart",this._touchstart),y(e,"touchmove",this._touchmove),y(e,"touchend",this._touchend)))},C.prototype._unbindFromCurrent=function(){var e=this._element;if(this._usePointers())return w(e,"pointerdown",this._pointerdown),w(this.document,"pointermove",this._pointermove),w(this.document,"pointerup",this._pointerup),w(this.document,"contextmenu",b),void w(this.document,"pointercancel",this._pointerup);w(e,"mousedown",this._mousedown),this._mouseOnly||(w(e,"touchstart",this._touchstart),w(e,"touchmove",this._touchmove),w(e,"touchend",this._touchend))},C.prototype._usePointers=function(){return!this._mouseOnly&&C.supportPointerEvent()},C.prototype.update=function(e){var t=e.press;void 0===t&&(t=_);var n=e.drag;void 0===n&&(n=_);var i=e.release;void 0===i&&(i=_);var r=e.mouseOnly;void 0===r&&(r=!1),this._pressHandler=g(O,t),this._dragHandler=g(O,n),this._releaseHandler=g(O,i),this._mouseOnly=r},C.prototype.destroy=function(){this._unbindFromCurrent(),this._element=null},Object.defineProperties(C.prototype,P),C.default=C;var j,x=C;function S(e){var t=e.$slots.default;return e.v3&&t&&"function"==typeof t?t():t}function D(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var A=m,T=(A.h,A.version&&"3"===A.version[0]),R=(D(j={emits:{press:null,drag:null,release:null},inheritAttrs:!1,created:function(){this.element=null,this.draggable=new x({press:this.press,drag:this.drag,release:this.release})},setup:T?function(){return{v3:!!T}}:void 0,mounted:function(){this.$el&&(this.element=3===this.$el.nodeType?this.$el.nextElementSibling:this.$el,this.draggable.bindTo(this.element))},destroyed:T?void 0:function(){this.draggable.destroy()},unmounted:function(){this.draggable.destroy()},methods:{press:function(e){this.element&&this.$emit("press",e,this.element)},drag:function(e){this.element&&this.$emit("drag",e,this.element)},release:function(e){this.element&&this.$emit("release",e,this.element)}}},"setup",T?function(){return{v3:!!T}}:void 0),D(j,"render",(function(e){return S(this)})),j),M=function(e){return e?new Date(e.getTime()):null};function $(e){var t={};return E(e,t),t}function E(e,t){for(var n in e)if(e.hasOwnProperty(n)){var i=e[n];t[n]=K(i,t[n])}}function K(e,t){if(Array.isArray(e))return I(e);if(e instanceof Date)return M(e);if(e&&i(e)){var n=t||{};return E(e,n),n}return e}function I(e){return e.map((function(e){return K(e,void 0)}))}var V=function(){},L=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g,H={};function F(e){if(H[e])return H[e];var t=[];return e.replace(L,(function(e,n,i,r){t.push(void 0!==n?n:i||r)})),H[e]=function(e){for(var n=e,i=0;i<t.length&&n;i++)n=n[t[i]];return n},H[e]}H.undefined=function(){};var N={};function X(e){if(N[e])return N[e];var t=[];return e.replace(L,(function(e,n,i,r){t.push(void 0!==n?n:i||r)})),N[e]=function(e,n){for(var i=e,r=t.length-1,o=0;o<r&&i;o++)i=i[t[o]]=i[t[o]]||{};i[t[r]]=n},N[e]}function Y(e){return this.v3?Object.keys(this.$attrs).map((function(e){return e.toLowerCase()})).some((function(t){return t.endsWith(e.toLowerCase())})):this.$listeners[e]}function U(){if(this.v3){var e={};for(var t in this.$attrs)t.startsWith("on")&&(e[t]=this.$attrs[t]);return e}return this.$listeners}N.undefined=function(e){return e};var q=function(){return(q=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)},B=m,W=B.version&&"3"===B.version[0],z={type:[String,Function,Object,Boolean],default:function(){}};function G(e,t){if(e||!1===e){var n=W?this.$slots[e]||(e.toLowerCase?this.$slots[e.toLowerCase()]:null):this.$scopedSlots[e]||(e.toLowerCase?this.$scopedSlots[e.toLowerCase()]:null);return"string"==typeof e&&n?{kt:!0,type:"slot",render:n,listeners:t}:"string"==typeof e||i(e)||"function"==typeof e&&e.component?{kt:!0,type:"component",render:e,listeners:t}:{kt:!0,type:"renderFunction",render:e,listeners:t}}}function J(e){var t,n,i,r=e.h,o=e.template,s=e.defaultRendering,u=e.defaultSlots,a=e.additionalProps,c=e.additionalListeners,l=e.swapDefaultSlots;if(!o||o&&!0===o.render)return s;if(W){var d=s?s.props:{};t=q(q({},Q(c)),o.listeners),n=q(q(q({},d),a),t),i=q(q({},n),t)}else{var f=s&&s.componentOptions,h=f?s.componentOptions.listeners:{},p=f?s.componentOptions.propsData:{};t=q(q(q(q({},h),c),Q(c)),o.listeners),i={props:n=q(q(q({},p),a),t),on:t}}if("slot"===o.type){var v=o.render({props:n,listeners:t,methods:t,defaultSlots:u});return v?v[0]:void 0}return"renderFunction"===o.type?l?o.render?o.render(r,s,u,n,t):void 0:o.render?o.render(r,s,n,t,u):void 0:r(o.render,i,W?function(){return[u]}:[u])}function Q(e){if(!e)return e;for(var t={},n=Object.keys(e),i=0;i<n.length;i++){var r=n[i];t["on"+r.charAt(0).toUpperCase()+r.slice(1)]=e[r]}return t}var Z=function(e,t,n){var i="string"==typeof e?parseInt(e,void 0):e;if(NaN!==i)return void 0!==i?i:t?n?void 0:-1:0};function ee(e){return Boolean(u&&e&&"rtl"===getComputedStyle(e).direction)}function te(e,t){if(!t&&u&&e){var n=window.getComputedStyle(e).direction;if(n)return n}return t}var ne=n(1);function ie(e){if(void 0!==ne)ne.validatePackage(e);else{var t="License activation failed for "+e.name+"\n";t+="The @progress/kendo-licensing script is not loaded.\n",t+="See "+e.licensingDocsUrl+" for more information.\n",console.warn(t)}}var re={sizeMap:{small:"sm",medium:"md",large:"lg"},roundedMap:{small:"sm",medium:"md",large:"lg"}}}])}));
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("vue"),require("@progress/kendo-licensing")):"function"==typeof define&&define.amd?define(["vue","@progress/kendo-licensing"],t):"object"==typeof exports?exports.KendoVueScrollview=t(require("vue"),require("@progress/kendo-licensing")):e.KendoVueScrollview=t(e.Vue,e.KendoLicensing)}(window,(function(e,t){return function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=2)}([function(t,n){t.exports=e},function(e,n){e.exports=t},function(e,t,n){"use strict";var i=Object.create?function(e,t,n,i){void 0===i&&(i=n),Object.defineProperty(e,i,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]},r=function(e,t){for(var n in e)"default"===n||t.hasOwnProperty(n)||i(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),r(n(3),t),r(n(5),t)},function(e,t,n){"use strict";var i=Object.create?function(e,t,n,i){void 0===i&&(i=n),Object.defineProperty(e,i,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]},r=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t},o=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.hasOwnProperty.call(e,n)&&i(t,e,n);return r(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.ScrollViewVue2=t.ScrollView=void 0;var s=o(n(0)),u=s.h,a=s.version&&"3"===s.version[0],c=n(6),l=n(4),d={name:"KendoScrollView",props:{activeView:{type:Number,default:1},dataItems:{type:Array,default:function(){return[]}},arrows:{type:Boolean,default:!0},automaticViewChange:{type:Boolean,default:!0},automaticViewChangeInterval:{type:Number,default:5e3},content:[Object,String,Function],dir:String,endless:Boolean,pageable:{type:Boolean,default:!0},pagerOverlay:{type:String,default:"none"}},created:function(){c.validatePackage(l.packageMetadata),this.timeoutRef=null},mounted:function(){this.wrapElement=c.getRef(this,"wrapElement"),this.currentDir=void 0!==this.$props.dir?this.$props.dir:c.isRtl(this.$el)?"rtl":"ltr",this.runAutomaticChange()},updated:function(){var e=this.dataItems.length;this.wrapElement&&(this.wrapElement.style.setProperty("--kendo-scrollview-views",""+e),this.wrapElement.style.setProperty("--kendo-scrollview-current",""+this.active)),this.runAutomaticChange()},data:function(){return{active:this.activeView||1,currentDir:void 0}},computed:{scrollViewClasses:function(){return{"k-widget":!0,"k-scrollview":!0,"k-scrollview-light":"light"===this.pagerOverlay,"k-scrollview-dark":"dark"===this.pagerOverlay}},displayLeftArrow:function(){var e;return e=this.isRtl?this.active<this.dataItems.length:this.active>1,(this.endless||e)&&this.dataItems.length>0},displayRightArrow:function(){var e;return e=this.isRtl?this.active>1:this.active<this.dataItems.length,(this.endless||e)&&this.dataItems.length>0},isRtl:function(){return"rtl"===this.currentDir}},setup:a?function(){return{v3:!!a}}:void 0,render:function(e){var t=u||e,n=this.$props,i=n.pageable,r=n.arrows,o=n.content,s=this.dataItems.length,a=this.dataItems.map((function(e,n){var i=c.templateRendering.call(this,e.content||o,c.getListeners.call(this)),r=c.getTemplate.call(this,{h:t,template:i,defaultRendering:null,additionalProps:{item:e,items:this.dataItems}});return t("div",{class:"k-scrollview-view","aria-hidden":this.active!==n+1,attrs:this.v3?void 0:{"aria-hidden":this.active!==n+1}},[r])}),this);return t("div",{class:this.scrollViewClasses,tabindex:0,attrs:this.v3?void 0:{tabindex:0,dir:this.currentDir},dir:this.currentDir,onKeydown:this.handleKeyDown,on:this.v3?void 0:{keydown:this.handleKeyDown}},[t("div",{class:"k-scrollview-wrap k-scrollview-animate",style:"--kendo-scrollview-views:"+s+"; --kendo-scrollview-current:"+this.active+";",ref:c.setRef(this,"wrapElement")},[a]),t("div",{class:"k-scrollview-elements"},[r&&[this.displayLeftArrow&&t("a",{class:"k-scrollview-prev","aria-label":"previous",attrs:this.v3?void 0:{"aria-label":"previous"},onClick:this.handlePrevClick,on:this.v3?void 0:{click:this.handlePrevClick}},[t("span",{class:"k-icon k-i-arrowhead-w"})]),this.displayRightArrow&&t("a",{class:"k-scrollview-next","aria-label":"next",attrs:this.v3?void 0:{"aria-label":"next"},onClick:this.handleNextClick,on:this.v3?void 0:{click:this.handleNextClick}},[t("span",{class:"k-icon k-i-arrowhead-e"})])],i&&t("div",{class:"k-scrollview-nav-wrap"},[t("ul",{class:"k-scrollview-nav"},[this.dataItems.map((function(e,n){var i=this;return t("li",{class:c.classNames("k-link",{"k-primary":this.active===n+1}),key:n+1,onClick:function(){return i.setActive(n+1)},on:this.v3?void 0:{click:function(){return i.setActive(n+1)}}})}),this)])])])])},methods:{runAutomaticChange:function(){if(this.automaticViewChange){this.resetTimeout();var e=this,t=this.active;this.timeoutRef=setTimeout((function(){e.setActive(t===e.dataItems.length?e.endless?1:t:t+1)}),this.automaticViewChangeInterval)}},resetTimeout:function(){this.timeoutRef&&clearTimeout(this.timeoutRef)},setActive:function(e){this.active=e},focusElement:function(){this.$el&&this.$el.focus()},prev:function(){this.endless?this.active>1?this.setActive(this.active-1):this.setActive(this.dataItems.length):this.active>1&&this.setActive(this.active-1)},next:function(){this.endless?this.active<this.dataItems.length?this.setActive(this.active+1):this.setActive(1):this.active<this.dataItems.length&&this.setActive(this.active+1)},handlePrevClick:function(){this.isRtl?this.next():this.prev()},handleNextClick:function(){this.isRtl?this.prev():this.next()},handleKeyDown:function(e){switch(e.keyCode){case c.Keys.left:e.preventDefault(),this.isRtl?this.next():this.prev();break;case c.Keys.right:e.preventDefault(),this.isRtl?this.prev():this.next()}}}};t.ScrollViewVue2=d;var f=d;t.ScrollView=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.packageMetadata=void 0,t.packageMetadata={name:"@progress/kendo-vue-scrollview",productName:"Kendo UI for Vue",productCodes:["KENDOUIVUE","KENDOUICOMPLETE"],publishDate:1659429281,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},function(e,t,n){"use strict";n.r(t),n.d(t,"getRef",(function(){return a})),n.d(t,"setRef",(function(){return c})),n.d(t,"classNames",(function(){return r})),n.d(t,"guid",(function(){return o})),n.d(t,"Keys",(function(){return s})),n.d(t,"noop",(function(){return V})),n.d(t,"isObject",(function(){return i})),n.d(t,"getListeners",(function(){return U})),n.d(t,"hasListener",(function(){return Y})),n.d(t,"canUseDOM",(function(){return u})),n.d(t,"firstFocusableChild",(function(){return d})),n.d(t,"focusFirstFocusableChild",(function(){return h})),n.d(t,"lastFocusableChild",(function(){return f})),n.d(t,"focusLastFocusableChild",(function(){return p})),n.d(t,"focusContainer",(function(){return v})),n.d(t,"clone",(function(){return $})),n.d(t,"Draggable",(function(){return R})),n.d(t,"cloneArray",(function(){return I})),n.d(t,"cloneValue",(function(){return K})),n.d(t,"cloneObject",(function(){return E})),n.d(t,"cloneDate",(function(){return M})),n.d(t,"getTemplate",(function(){return J})),n.d(t,"templateRendering",(function(){return G})),n.d(t,"templateDefinition",(function(){return z})),n.d(t,"getTabIndex",(function(){return Z})),n.d(t,"getDefaultSlots",(function(){return S})),n.d(t,"isRtl",(function(){return ee})),n.d(t,"getDir",(function(){return te})),n.d(t,"getter",(function(){return F})),n.d(t,"setter",(function(){return X})),n.d(t,"validatePackage",(function(){return ie})),n.d(t,"kendoThemeMaps",(function(){return re}));var i=function(e){return"object"==typeof e},r=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.filter((function(e){return!0!==e&&!!e})).map((function(e){return Array.isArray(e)?r.apply(void 0,e):i(e)?Object.keys(e).map((function(t,n){return e[n]||e[t]&&t||null})).filter((function(e){return null!==e})).join(" "):e})).filter((function(e){return!!e})).join(" ")},o=function(){var e,t,n="";for(e=0;e<32;e++)t=16*Math.random()|0,8!==e&&12!==e&&16!==e&&20!==e||(n+="-"),n+=(12===e?4:16===e?3&t|8:t).toString(16);return n},s={backspace:8,tab:9,enter:13,shift:16,esc:27,space:32,pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40,delete:46},u=Boolean("undefined"!=typeof window&&window.document&&window.document.createElement);function a(e,t,n){return e.v3?e[t+"Ref"]:e.$refs[""+(n||t)]}function c(e,t,n){return e.v3?function(n){e[t+"Ref"]=n}:n||t}var l='input, [tabindex]:not([tabindex="-1"])',d=function(e){if(e){var t=e.querySelectorAll(l);if(t.length&&t[0].focus)return t[0]}},f=function(e){if(e){var t=e.querySelectorAll(l);if(t.length&&t[t.length-1].focus)return t[t.length-1]}},h=function(e){if(e){var t=e.querySelectorAll(l);t.length&&t[0].focus&&t[0].focus()}},p=function(e){if(e){var t=e.querySelectorAll(l);t.length&&t[t.length-1].focus&&t[t.length-1].focus()}},v=function(e,t){var n=!0;if(e.keyCode!==s.enter&&e.target===t)return!1;if(e.keyCode===s.enter&&e.target===t)n=!0,setTimeout((function(){h(t)}),1);else if(e.keyCode===s.esc)n=!1,t.focus();else if(e.keyCode===s.tab){var i=d(t),r=f(t);r&&!e.shiftKey&&e.target===r&&(e.preventDefault(),i.focus()),i&&e.shiftKey&&e.target===i&&(e.preventDefault(),r.focus())}return n},m=n(0),g=function(e,t){return function(n){return t(e(n))}},y=function(e,t,n){return e.addEventListener&&e.addEventListener(t,n)},w=function(e,t,n){return e&&e.removeEventListener&&e.removeEventListener(t,n)},_=function(){},b=function(e){return e.preventDefault()},k=/touch/;function O(e){return e.type.match(k)?{pageX:e.changedTouches[0].pageX,pageY:e.changedTouches[0].pageY,clientX:e.changedTouches[0].clientX,clientY:e.changedTouches[0].clientY,type:e.type,originalEvent:e,isTouch:!0}:{pageX:e.pageX,pageY:e.pageY,clientX:e.clientX,clientY:e.clientY,offsetX:e.offsetX,offsetY:e.offsetY,type:e.type,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,altKey:e.altKey,originalEvent:e}}var C=function(e){var t=this,n=e.press;void 0===n&&(n=_);var i=e.drag;void 0===i&&(i=_);var r=e.release;void 0===r&&(r=_);var o=e.mouseOnly;void 0===o&&(o=!1),this._pressHandler=g(O,n),this._dragHandler=g(O,i),this._releaseHandler=g(O,r),this._ignoreMouse=!1,this._mouseOnly=o,this._touchstart=function(e){1===e.touches.length&&t._pressHandler(e)},this._touchmove=function(e){1===e.touches.length&&t._dragHandler(e)},this._touchend=function(e){0===e.touches.length&&1===e.changedTouches.length&&(t._releaseHandler(e),t._ignoreMouse=!0,setTimeout(t._restoreMouse,2e3))},this._restoreMouse=function(){t._ignoreMouse=!1},this._mousedown=function(e){var n=e.which;n&&n>1||t._ignoreMouse||(y(t.document,"mousemove",t._mousemove),y(t.document,"mouseup",t._mouseup),t._pressHandler(e))},this._mousemove=function(e){t._dragHandler(e)},this._mouseup=function(e){w(t.document,"mousemove",t._mousemove),w(t.document,"mouseup",t._mouseup),t._releaseHandler(e)},this._pointerdown=function(e){e.isPrimary&&0===e.button&&(y(t.document,"pointermove",t._pointermove),y(t.document,"pointerup",t._pointerup),y(t.document,"pointercancel",t._pointerup),y(t.document,"contextmenu",b),t._pressHandler(e))},this._pointermove=function(e){e.isPrimary&&t._dragHandler(e)},this._pointerup=function(e){e.isPrimary&&(w(t.document,"pointermove",t._pointermove),w(t.document,"pointerup",t._pointerup),w(t.document,"pointercancel",t._pointerup),w(t.document,"contextmenu",b),t._releaseHandler(e))}},P={document:{configurable:!0}};C.supportPointerEvent=function(){return"undefined"!=typeof window&&window.PointerEvent},P.document.get=function(){return this._element?this._element.ownerDocument:document},C.prototype.bindTo=function(e){e!==this._element&&(this._element&&this._unbindFromCurrent(),this._element=e,this._bindToCurrent())},C.prototype._bindToCurrent=function(){var e=this._element;this._usePointers()?y(e,"pointerdown",this._pointerdown):(y(e,"mousedown",this._mousedown),this._mouseOnly||(y(e,"touchstart",this._touchstart),y(e,"touchmove",this._touchmove),y(e,"touchend",this._touchend)))},C.prototype._unbindFromCurrent=function(){var e=this._element;if(this._usePointers())return w(e,"pointerdown",this._pointerdown),w(this.document,"pointermove",this._pointermove),w(this.document,"pointerup",this._pointerup),w(this.document,"contextmenu",b),void w(this.document,"pointercancel",this._pointerup);w(e,"mousedown",this._mousedown),this._mouseOnly||(w(e,"touchstart",this._touchstart),w(e,"touchmove",this._touchmove),w(e,"touchend",this._touchend))},C.prototype._usePointers=function(){return!this._mouseOnly&&C.supportPointerEvent()},C.prototype.update=function(e){var t=e.press;void 0===t&&(t=_);var n=e.drag;void 0===n&&(n=_);var i=e.release;void 0===i&&(i=_);var r=e.mouseOnly;void 0===r&&(r=!1),this._pressHandler=g(O,t),this._dragHandler=g(O,n),this._releaseHandler=g(O,i),this._mouseOnly=r},C.prototype.destroy=function(){this._unbindFromCurrent(),this._element=null},Object.defineProperties(C.prototype,P),C.default=C;var j,x=C;function S(e){var t=e.$slots.default;return e.v3&&t&&"function"==typeof t?t():t}function D(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var A=m,T=(A.h,A.version&&"3"===A.version[0]),R=(D(j={emits:{press:null,drag:null,release:null},inheritAttrs:!1,created:function(){this.element=null,this.draggable=new x({press:this.press,drag:this.drag,release:this.release})},setup:T?function(){return{v3:!!T}}:void 0,mounted:function(){this.$el&&(this.element=3===this.$el.nodeType?this.$el.nextElementSibling:this.$el,this.draggable.bindTo(this.element))},destroyed:T?void 0:function(){this.draggable.destroy()},unmounted:function(){this.draggable.destroy()},methods:{press:function(e){this.element&&this.$emit("press",e,this.element)},drag:function(e){this.element&&this.$emit("drag",e,this.element)},release:function(e){this.element&&this.$emit("release",e,this.element)}}},"setup",T?function(){return{v3:!!T}}:void 0),D(j,"render",(function(e){return S(this)})),j),M=function(e){return e?new Date(e.getTime()):null};function $(e){var t={};return E(e,t),t}function E(e,t){for(var n in e)if(e.hasOwnProperty(n)){var i=e[n];t[n]=K(i,t[n])}}function K(e,t){if(Array.isArray(e))return I(e);if(e instanceof Date)return M(e);if(e&&i(e)){var n=t||{};return E(e,n),n}return e}function I(e){return e.map((function(e){return K(e,void 0)}))}var V=function(){},L=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g,H={};function F(e){if(H[e])return H[e];var t=[];return e.replace(L,(function(e,n,i,r){t.push(void 0!==n?n:i||r)})),H[e]=function(e){for(var n=e,i=0;i<t.length&&n;i++)n=n[t[i]];return n},H[e]}H.undefined=function(){};var N={};function X(e){if(N[e])return N[e];var t=[];return e.replace(L,(function(e,n,i,r){t.push(void 0!==n?n:i||r)})),N[e]=function(e,n){for(var i=e,r=t.length-1,o=0;o<r&&i;o++)i=i[t[o]]=i[t[o]]||{};i[t[r]]=n},N[e]}function Y(e){return this.v3?Object.keys(this.$attrs).map((function(e){return e.toLowerCase()})).some((function(t){return t.endsWith(e.toLowerCase())})):this.$listeners[e]}function U(){if(this.v3){var e={};for(var t in this.$attrs)t.startsWith("on")&&(e[t]=this.$attrs[t]);return e}return this.$listeners}N.undefined=function(e){return e};var q=function(){return(q=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)},B=m,W=B.version&&"3"===B.version[0],z={type:[String,Function,Object,Boolean],default:function(){}};function G(e,t){if(e||!1===e){var n=W?this.$slots[e]||(e.toLowerCase?this.$slots[e.toLowerCase()]:null):this.$scopedSlots[e]||(e.toLowerCase?this.$scopedSlots[e.toLowerCase()]:null);return"string"==typeof e&&n?{kt:!0,type:"slot",render:n,listeners:t}:"string"==typeof e||i(e)||"function"==typeof e&&e.component?{kt:!0,type:"component",render:e,listeners:t}:{kt:!0,type:"renderFunction",render:e,listeners:t}}}function J(e){var t,n,i,r=e.h,o=e.template,s=e.defaultRendering,u=e.defaultSlots,a=e.additionalProps,c=e.additionalListeners,l=e.swapDefaultSlots;if(!o||o&&!0===o.render)return s;if(W){var d=s?s.props:{};t=q(q({},Q(c)),o.listeners),n=q(q(q({},d),a),t),i=q(q({},n),t)}else{var f=s&&s.componentOptions,h=f?s.componentOptions.listeners:{},p=f?s.componentOptions.propsData:{};t=q(q(q(q({},h),c),Q(c)),o.listeners),i={props:n=q(q(q({},p),a),t),on:t}}if("slot"===o.type){var v=o.render({props:n,listeners:t,methods:t,defaultSlots:u});return v?v[0]:void 0}return"renderFunction"===o.type?l?o.render?o.render(r,s,u,n,t):void 0:o.render?o.render(r,s,n,t,u):void 0:r(o.render,i,W?function(){return[u]}:[u])}function Q(e){if(!e)return e;for(var t={},n=Object.keys(e),i=0;i<n.length;i++){var r=n[i];t["on"+r.charAt(0).toUpperCase()+r.slice(1)]=e[r]}return t}var Z=function(e,t,n){var i="string"==typeof e?parseInt(e,void 0):e;if(NaN!==i)return void 0!==i?i:t?n?void 0:-1:0};function ee(e){return Boolean(u&&e&&"rtl"===getComputedStyle(e).direction)}function te(e,t){if(!t&&u&&e){var n=window.getComputedStyle(e).direction;if(n)return n}return t}var ne=n(1);function ie(e){if(void 0!==ne)ne.validatePackage(e);else{var t="License activation failed for "+e.name+"\n";t+="The @progress/kendo-licensing script is not loaded.\n",t+="See "+e.licensingDocsUrl+" for more information.\n",console.warn(t)}}var re={sizeMap:{small:"sm",medium:"md",large:"lg"},roundedMap:{small:"sm",medium:"md",large:"lg"}}}])}));
|
|
@@ -5,7 +5,7 @@ export var packageMetadata = {
|
|
|
5
5
|
name: '@progress/kendo-vue-scrollview',
|
|
6
6
|
productName: 'Kendo UI for Vue',
|
|
7
7
|
productCodes: ['KENDOUIVUE', 'KENDOUICOMPLETE'],
|
|
8
|
-
publishDate:
|
|
8
|
+
publishDate: 1659429281,
|
|
9
9
|
version: '',
|
|
10
10
|
licensingDocsUrl: 'https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning'
|
|
11
11
|
};
|
|
@@ -8,7 +8,7 @@ exports.packageMetadata = {
|
|
|
8
8
|
name: '@progress/kendo-vue-scrollview',
|
|
9
9
|
productName: 'Kendo UI for Vue',
|
|
10
10
|
productCodes: ['KENDOUIVUE', 'KENDOUICOMPLETE'],
|
|
11
|
-
publishDate:
|
|
11
|
+
publishDate: 1659429281,
|
|
12
12
|
version: '',
|
|
13
13
|
licensingDocsUrl: 'https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning'
|
|
14
14
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-vue-scrollview",
|
|
3
3
|
"description": "Kendo UI for Vue ScrollView package",
|
|
4
|
-
"version": "3.5.0
|
|
4
|
+
"version": "3.5.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/telerik/kendo-vue.git"
|
|
@@ -34,13 +34,13 @@
|
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@progress/kendo-drawing": "^1.8.0",
|
|
36
36
|
"@progress/kendo-licensing": "^1.0.1",
|
|
37
|
-
"@progress/kendo-vue-animation": "3.5.0
|
|
38
|
-
"@progress/kendo-vue-buttons": "3.5.0
|
|
39
|
-
"@progress/kendo-vue-inputs": "3.5.0
|
|
40
|
-
"@progress/kendo-vue-intl": "3.5.0
|
|
37
|
+
"@progress/kendo-vue-animation": "3.5.0",
|
|
38
|
+
"@progress/kendo-vue-buttons": "3.5.0",
|
|
39
|
+
"@progress/kendo-vue-inputs": "3.5.0",
|
|
40
|
+
"@progress/kendo-vue-intl": "3.5.0"
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
|
-
"@progress/kendo-vue-common": "3.5.0
|
|
43
|
+
"@progress/kendo-vue-common": "3.5.0"
|
|
44
44
|
},
|
|
45
45
|
"@progress": {
|
|
46
46
|
"friendlyName": "ScrollView",
|