@syncfusion/ej2-lists
Advanced tools
Comparing version 1.0.8 to 1.0.10
@@ -1,1 +0,11 @@ | ||
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("@syncfusion/ej2-base"),require("@syncfusion/ej2-data"));else if("function"==typeof define&&define.amd)define(["@syncfusion/ej2-base","@syncfusion/ej2-data"],t);else{var i="object"==typeof exports?t(require("@syncfusion/ej2-base"),require("@syncfusion/ej2-data")):t(e["@syncfusion/ej2-base"],e["@syncfusion/ej2-data"]);for(var r in i)("object"==typeof exports?exports:e)[r]=i[r]}}(this,function(e,t){return function(e){function t(r){if(i[r])return i[r].exports;var s=i[r]={exports:{},id:r,loaded:!1};return e[r].call(s.exports,s,s.exports,t),s.loaded=!0,s.exports}var i={};return t.m=e,t.c=i,t.p="",t(0)}([function(e,t,i){var r,s;r=[i,t,i(1),i(11)],void 0!==(s=function(e,t,i,r){"use strict";function s(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}Object.defineProperty(t,"__esModule",{value:!0}),s(i),s(r)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(2)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s,n=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])};return function(t,i){function r(){this.constructor=t}e(t,i),t.prototype=null===i?Object.create(i):(r.prototype=i.prototype,new r)}}(),o=this&&this.__decorate||function(e,t,i,r){var s,n=arguments.length,o=n<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(s=e[a])&&(o=(n<3?s(o):n>3?s(t,i,o):s(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o};r=[i,t,i(3),i(5),i(8),i(8),i(8),i(9),i(10)],void 0!==(s=function(e,t,i,r,s,a,l,c,d){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u={None:[],SlideLeft:["SlideRightOut","SlideLeftOut","SlideLeftIn","SlideRightIn"],SlideDown:["SlideTopOut","SlideBottomOut","SlideBottomIn","SlideTopIn"],Zoom:["FadeOut","FadeZoomOut","FadeZoomIn","FadeIn"],Fade:["FadeOut","FadeOut","FadeIn","FadeIn"]},h={None:[],SlideLeft:["SlideLeftOut","SlideRightOut","SlideRightIn","SlideLeftIn"],SlideDown:["SlideBottomOut","SlideTopOut","SlideTopIn","SlideBottomIn"],Zoom:["FadeZoomOut","FadeOut","FadeIn","FadeZoomIn"],Fade:["FadeOut","FadeOut","FadeIn","FadeIn"]},p={root:"e-listview",hover:"e-hover",selected:"e-active",parentItem:"e-list-parent",listItem:"e-list-item",listItemText:"e-list-text",grpListItem:"e-list-group-item",hasChild:"e-has-child",view:"e-view",header:"e-header",headerText:"e-headertext",text:"e-text",disable:"e-disabled",content:"e-content",icon:"e-icons",backIcon:"e-icon-back"},f=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n(t,e),t}(a.ChildProperty);o([s.Property("id")],f.prototype,"id",void 0),o([s.Property("text")],f.prototype,"text",void 0),o([s.Property("isChecked")],f.prototype,"isChecked",void 0),o([s.Property("isVisible")],f.prototype,"isVisible",void 0),o([s.Property("enabled")],f.prototype,"enabled",void 0),o([s.Property("iconCss")],f.prototype,"iconCss",void 0),o([s.Property("child")],f.prototype,"child",void 0),o([s.Property("tooltip")],f.prototype,"tooltip",void 0),o([s.Property("groupBy")],f.prototype,"groupBy",void 0),o([s.Property("text")],f.prototype,"sortBy",void 0),o([s.Property("htmlAttributes")],f.prototype,"htmlAttributes",void 0),o([s.Property("tableName")],f.prototype,"tableName",void 0),t.FieldSettings=f;var v=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.curDSLevel=[],r.curViewDS=[],r.keyConfigs={moveDown:"downarrow",moveUp:"uparrow",select:"enter",back:"backspace"},r.animateOptions={},r.aniObj=new l.Animation(r.animateOptions),r}return n(t,e),t.prototype.onPropertyChanged=function(e,t){for(var i=0,r=Object.keys(e);i<r.length;i++){switch(r[i]){case"htmlAttributes":this.setHTMLAttribute();break;case"cssClass":this.setCSSClass(t.cssClass);break;case"enable":this.setEnable();break;case"width":case"height":this.setSize();break;case"enableRtl":this.setEnableRTL();break;case"fields":this.listBaseOption.fields=this.fields.properties,this.reRender();break;case"headerTitle":this.curDSLevel.length||this.header(this.headerTitle,!1);break;case"showHeader":this.header(this.headerTitle,!1);break;case"dataSource":this.reRender();break;case"sortOrder":case"showIcon":this.listBaseOption.showIcon=this.showIcon,this.curViewDS=this.getSubDS(),this.resetCurrentList()}}},t.prototype.setHTMLAttribute=function(){Object.keys(this.htmlAttributes).length&&r.attributes(this.element,this.htmlAttributes)},t.prototype.setCSSClass=function(e){this.cssClass&&r.addClass([this.element],this.cssClass.split(" ")),e&&r.removeClass([this.element],e.split(" "))},t.prototype.setSize=function(){this.element.style.height=i.formatUnit(this.height),this.element.style.width=i.formatUnit(this.width)},t.prototype.setEnable=function(){this.enableElement(this.element,this.enable)},t.prototype.setEnableRTL=function(){this.enableRtl?this.element.classList.add("e-rtl"):this.element.classList.remove("e-rtl")},t.prototype.enableElement=function(e,t){t?e.classList.remove(p.disable):e.classList.add(p.disable)},t.prototype.header=function(e,t){if(void 0===this.headerEle&&this.showHeader){this.headerEle=r.createElement("div",{className:p.header});var i=r.createElement("span",{className:p.headerText,innerHTML:this.headerTitle}),s=r.createElement("div",{className:p.text,innerHTML:i.outerHTML}),n=r.createElement("div",{className:p.icon+" "+p.backIcon+" e-but-back",attrs:{style:"display:none;"}});this.headerEle.appendChild(n),this.headerEle.appendChild(s),this.element.classList.add("e-has-header"),r.prepend([this.headerEle],this.element)}else if(this.headerEle)if(this.showHeader){this.headerEle.style.display="";var s=this.headerEle.querySelector("."+p.headerText),n=this.headerEle.querySelector("."+p.backIcon);s.innerHTML=e,n.style.display=!0===t?"":"none"}else this.headerEle.style.display="none"},t.prototype.switchView=function(e,t,i){var r=this;if(e&&t){var s=e.style.position,n="hidden"!==this.element.style.overflow?this.element.style.overflow:"";e.style.position="absolute",e.classList.add("e-view");var o=void 0,a=this.animation.duration;if(this.animation.effect)o=this.enableRtl?h[this.animation.effect]:u[this.animation.effect];else{o=this.enableRtl?h.SlideLeft:u.SlideRight,a=0}this.element.style.overflow="hidden",this.aniObj.animate(e,{name:!0===i?o[0]:o[1],duration:a,timingFunction:this.animation.easing,end:function(t){e.style.display="none",r.element.style.overflow=n,e.style.position=s,e.classList.remove("e-view")}}),t.style.display="",this.aniObj.animate(t,{name:!0===i?o[2]:o[3],duration:a,timingFunction:this.animation.easing,end:function(){r.trigger("actionComplete")}}),this.curUL=t}},t.prototype.preRender=function(){this.listBaseOption={template:this.template,groupTemplate:this.groupTemplate,expandCollapse:!0,listClass:"",fields:this.fields.properties,sortOrder:this.sortOrder,showIcon:this.showIcon}},t.prototype.clickHandler=function(e){var t=e.target,i=t.classList;if(i.contains(p.backIcon)||i.contains(p.headerText))this.back();else{var s=r.closest(t.parentNode,"."+p.listItem);null===s&&(s=t),this.setSelectLI(s,e)}},t.prototype.hoverHandler=function(e){var t=r.closest(e.target.parentNode,"."+p.listItem);this.setHoverLI(t)},t.prototype.leaveHandler=function(e){this.removeHover()},t.prototype.keyActionHandler=function(e){switch(e.preventDefault(),e.action){case"moveDown":this.hoverSiblingLI();break;case"moveUp":this.hoverSiblingLI(!0);break;case"select":this.setSelectLI(this.curUL.querySelector("."+p.hover),e);break;case"back":this.back()}},t.prototype.swipeActionHandler=function(e){"Right"===e.swipeDirection&&this.back()},t.prototype.wireEvents=function(){s.EventHandler.add(this.element,"click",this.clickHandler,this),s.EventHandler.add(this.element,"mouseover",this.hoverHandler,this),s.EventHandler.add(this.element,"mouseout",this.leaveHandler,this),this.keyboardModule=new a.KeyboardEvents(this.element,{keyAction:this.keyActionHandler.bind(this),keyConfigs:this.keyConfigs}),this.touchModule=new l.Touch(this.element,{swipe:this.swipeActionHandler.bind(this)})},t.prototype.unWireEvents=function(){s.EventHandler.remove(this.element,"click",this.clickHandler),s.EventHandler.remove(this.element,"mouseover",this.hoverHandler),s.EventHandler.remove(this.element,"mouseout",this.leaveHandler),this.keyboardModule.destroy(),this.touchModule.destroy()},t.prototype.removeHover=function(){var e=this.element.querySelector("."+p.hover);e&&e.classList.remove(p.hover)},t.prototype.removeSelect=function(){for(var e=this.element.querySelectorAll("."+p.selected),t=0,i=e;t<i.length;t++){var r=i[t];r.removeAttribute("aria-selected"),""!==r.className&&r.classList.remove(p.selected)}},t.prototype.isValidLI=function(e){return e&&e.classList.contains(p.listItem)&&!e.classList.contains(p.grpListItem)&&!e.classList.contains(p.disable)},t.prototype.setSelectLI=function(e,t){if(this.isValidLI(e)&&!e.classList.contains(p.selected)&&this.enable){this.removeSelect(),e.classList.add(p.selected),e.setAttribute("aria-selected","true"),this.removeHover();var r=this.getItemData(e);this.selectedItems={item:e,text:r[this.listBaseOption.fields.text],data:r};var s={};i.merge(s,this.selectedItems),t&&i.merge(s,{isInteracted:!0,event:t}),this.trigger("select",s),this.selectedLI=e,this.renderSubList(e)}},t.prototype.setHoverLI=function(e){if(this.isValidLI(e)&&!e.classList.contains(p.hover)&&this.enable){var t=this.element.querySelectorAll("."+p.hover);t&&t.length&&r.removeClass(t,p.hover),e.classList.contains(p.selected)||e.classList.add(p.hover)}},t.prototype.hoverSiblingLI=function(e){var t,i=this.curUL.querySelector("."+p.hover);if(i||(i=this.curUL.querySelector("."+p.selected)),i)t=d.ListBase.getSiblingLI(this.curUL.querySelectorAll("."+p.listItem),i,e);else if(e){var r=this.curUL.querySelectorAll("."+p.listItem);t=r[r.length-1]}else t=this.curUL.querySelector("."+p.listItem);this.setHoverLI(t)},t.prototype.getSubDS=function(){var e=this.curDSLevel;if(e.length){for(var t=this.localData,i=0,r=e;i<r.length;i++){var s=r[i];this.curDSJSON=this.findItemFromDS(t,{id:s}),t=this.curDSJSON?this.curDSJSON[this.fields.child]:t}return t}return this.localData},t.prototype.getItemData=function(e){var t=this.getElementUID(e),i=this.dataSource;return this.findItemFromDS(i,t)},t.prototype.findItemFromDS=function(e,t,i){var r,s=this;return e&&e.length&&t?e.some(function(n){return!t.id&&!t.text||t.id&&n[s.fields.id]!==t.id||t.text&&n[s.fields.text]!==t.text?n.hasOwnProperty(s.fields.child)&&n[s.fields.child].length&&(r=s.findItemFromDS(n[s.fields.child],t,i)):r=i?e:n,!!r}):r=e,r},t.prototype.getQuery=function(){var e=[],t=this.query?this.query:new c.Query;if(!this.query){for(var i=0,r=Object.keys(this.fields.properties);i<r.length;i++){var s=r[i];"tableName"!==s&&this.fields[s]&&this.fields[s]!==d.ListBase.defaultMappedFields[s]&&-1===e.indexOf(this.fields[s])&&e.push(this.fields[s])}t.select(e),this.fields.properties.hasOwnProperty("tableName")&&t.from(this.fields.tableName)}return t},t.prototype.setViewDataSource=function(e){void 0===e&&(e=this.localData),e&&this.fields.groupBy?this.curViewDS=d.ListBase.groupDataSource(e,this.fields,this.sortOrder):e&&"None"!==this.sortOrder?this.curViewDS=d.ListBase.getDataSource(e,d.ListBase.addSorting(this.sortOrder,this.fields.sortBy)):this.curViewDS=e},t.prototype.isInAnimation=function(){return this.curUL.classList.contains(".e-animate")},t.prototype.setLocalData=function(){var e=this;if(this.trigger("actionBegin"),this.dataSource instanceof c.DataManager)this.dataSource.executeQuery(this.getQuery()).then(function(t){e.isDestroyed||(e.localData=t.result,e.renderList(),e.trigger("actionComplete",t))}).catch(function(t){e.isDestroyed||e.trigger("actionFailure",t)});else if(this.dataSource&&this.dataSource.length)this.localData=this.dataSource,this.renderList(),this.trigger("actionComplete",{data:this.localData});else{var t=this.element.querySelector("ul");t&&(t.remove(),this.setProperties({dataSource:d.ListBase.createJsonFromElement(t)},!0),this.localData=this.dataSource,this.renderList(),this.trigger("actionComplete",{data:this.localData}))}},t.prototype.reRender=function(){this.element.innerHTML="",this.curUL=this.headerEle=void 0,this.setLocalData(),this.header(),this.contentContainer=r.createElement("div",{className:p.content}),this.element.appendChild(this.contentContainer),this.renderIntoDom(this.ulElement)},t.prototype.resetCurrentList=function(){this.setViewDataSource(this.curViewDS),this.contentContainer.innerHTML="",this.createList(),this.renderIntoDom(this.curUL)},t.prototype.createList=function(){this.ulElement=this.curUL=d.ListBase.createList(this.curViewDS,this.listBaseOption),this.liCollection=this.curUL.querySelectorAll("."+p.listItem)},t.prototype.renderSubList=function(e){var t=e.getAttribute("uid");if(e.classList.contains(p.hasChild)&&t){var i=r.closest(e.parentNode,"."+p.parentItem),s=this.element.querySelector("[pid='"+t+"']");this.curDSLevel.push(t),this.setViewDataSource(this.getSubDS()),s||(s=d.ListBase.createListFromJson(this.curViewDS,this.listBaseOption,this.curDSLevel.length),s.setAttribute("pID",t),s.style.display="none",this.renderIntoDom(s)),this.switchView(i,s),this.liCollection=this.curUL.querySelectorAll("."+p.listItem),this.header(this.selectedItems.data[this.listBaseOption.fields.text],!0),this.selectedLI=void 0}},t.prototype.renderIntoDom=function(e){this.contentContainer.appendChild(e)},t.prototype.renderList=function(){this.setViewDataSource(),this.createList(),this.contentContainer=r.createElement("div",{className:p.content}),this.element.appendChild(this.contentContainer),this.renderIntoDom(this.ulElement)},t.prototype.getElementUID=function(e){var t={};return e instanceof Element?t.id=e.getAttribute("uid"):t=e,t},t.prototype.render=function(){this.element.classList.add(p.root),r.attributes(this.element,{role:"list"}),this.setCSSClass(),this.setEnableRTL(),this.setEnable(),this.setSize(),this.wireEvents(),this.header(),this.setLocalData(),this.setHTMLAttribute(),this.rippleFn=l.ripple(this.element,".e-list-item")},t.prototype.destroy=function(){this.unWireEvents();var t=[p.root,this.cssClass,p.disable,"e-rtl","e-has-header"];r.removeClass([this.element],t),this.rippleFn(),e.prototype.destroy.call(this)},t.prototype.back=function(){var e=this.curDSLevel[this.curDSLevel.length-1];if(void 0!==e&&!this.isInAnimation()){this.curDSLevel.pop(),this.setViewDataSource(this.getSubDS());var t=this.element.querySelector("[uid='"+e+"']"),i=this.curUL;t?t=t.parentElement:(this.createList(),this.renderIntoDom(this.ulElement),t=this.curUL);var r=this.curDSJSON[this.fields.text];this.switchView(i,t,!0),this.removeSelect(),this.liCollection=this.curUL.querySelectorAll("."+p.listItem),this.header(this.curDSLevel.length?r:this.headerTitle,!!this.curDSLevel.length)}},t.prototype.selectItem=function(e){var t=this.getItemData(e);if(t){var i=this.element.querySelector('[uid="'+t[this.fields.id]+'"]');i&&this.setSelectLI(i)}},t.prototype.getSelectedItem=function(){return this.selectedItems},t.prototype.findItem=function(e){return this.findItemFromDS(this.dataSource,e)},t.prototype.enableItem=function(e){var t=this.getItemData(e);if(t){var i=this.element.querySelector('[uid="'+t[this.fields.id]+'"]');i&&i.classList.remove(p.disable),delete t[this.fields.enabled]}},t.prototype.disableItem=function(e){var t=this.getItemData(e);if(t){var i=this.element.querySelector('[uid="'+t[this.fields.id]+'"]');i&&i.classList.add(p.disable),t[this.fields.enabled]=!1}},t.prototype.showItem=function(e){this.showHideItem(e,!1,"")},t.prototype.hideItem=function(e){this.showHideItem(e,!0,"none")},t.prototype.showHideItem=function(e,t,i){var r=this.getItemData(e);if(r){var s=this.element.querySelector('[uid="'+r[this.fields.id]+'"]');s&&(s.style.display=i),t?r[this.fields.isVisible]=!1:delete r[this.fields.isVisible]}},t.prototype.addItem=function(e,t){var i=this.findItemFromDS(this.dataSource,t),r=i[this.fields.child];r||(r=[]),r=r.concat(e),i instanceof Array?(this.dataSource=this.localData=i.concat(e),this.setViewDataSource()):i[this.fields.child]=r,this.resetCurrentList()},t.prototype.removeItem=function(e){var t=this,i=this.getElementUID(e),r=this.findItemFromDS(this.dataSource,i,!0);if(r&&e){var s,n;r.some(function(e,r,o){return!(!i.id&&!i.text||i.id&&e[t.fields.id]!==i.id||i.text&&e[t.fields.text]!==i.text)&&(s=o,n=r,!0)}),s.splice(n,1),this.resetCurrentList()}},t.prototype.getModuleName=function(){return"listview"},t.prototype.getPersistData=function(){return this.addOnPersist(["cssClass","enableRtl","htmlAttributes","enable","fields","animation","headerTitle","sortOrder","showIcon","height","width"])},t}(s.Component);o([s.Property()],v.prototype,"cssClass",void 0),o([s.Property({})],v.prototype,"htmlAttributes",void 0),o([s.Property(!0)],v.prototype,"enable",void 0),o([s.Property([])],v.prototype,"dataSource",void 0),o([s.Property()],v.prototype,"query",void 0),o([s.Complex(d.ListBase.defaultMappedFields,f)],v.prototype,"fields",void 0),o([s.Property({effect:"SlideLeft",duration:400,easing:"ease"})],v.prototype,"animation",void 0),o([s.Property("None")],v.prototype,"sortOrder",void 0),o([s.Property(!1)],v.prototype,"showIcon",void 0),o([s.Property("")],v.prototype,"headerTitle",void 0),o([s.Property(!1)],v.prototype,"showHeader",void 0),o([s.Property("")],v.prototype,"height",void 0),o([s.Property("")],v.prototype,"width",void 0),o([s.Property(null)],v.prototype,"template",void 0),o([s.Property(null)],v.prototype,"groupTemplate",void 0),o([s.Event()],v.prototype,"select",void 0),o([s.Event()],v.prototype,"actionBegin",void 0),o([s.Event()],v.prototype,"actionComplete",void 0),o([s.Event()],v.prototype,"actionFailure",void 0),v=o([a.NotifyPropertyChanges],v),t.ListView=v,t.listViewBuilder=s.CreateBuilder(v)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(4)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t],void 0!==(s=function(e,t){"use strict";function i(e,t){var i=t;return i.unshift(void 0),new(Function.prototype.bind.apply(e,i))}function r(e){var t,i=new Uint16Array(5);(window.msCrypto||window.crypto).getRandomValues(i);var r="ej2"+w(i),s=function(i){i.source===window&&"string"==typeof i.data&&i.data.length<=32&&i.data===r&&(e(),t())};return window.addEventListener("message",s,!1),window.postMessage(r,"*"),t=function(){window.removeEventListener("message",s)}}function s(e,t){for(var i=t,r=e.split("."),s=0;s<r.length&&!h(i);s++)i=i[r[s]];return i}function n(e,t,i){var r,s,n=e.split("."),o=i||{},a=o,l=n.length;for(r=0;r<l;r++)s=n[r],r+1===l?a[s]=void 0===t?{}:t:u(a[s])&&(a[s]={}),a=a[s];return o}function o(e,t){delete e[t]}function a(e){var t={};return!u(e)&&e.constructor===t.constructor}function l(e,t){return e[t]}function c(e,t){if(!u(t))for(var i=e,r=t,s=Object.keys(t),n=0,o=s;n<o.length;n++){var a=o[n];i[a]=r[a]}}function d(e,t,i,r){var s=e||{},n=arguments.length;r&&(n-=1);for(var o=arguments,l=1;l<n;l++)!function(e){if(!o[e])return"continue";var t=o[e];Object.keys(t).forEach(function(e){var i,n=s[e],o=t[e];r&&a(o)?(i=a(n)?n:{},s[e]=d({},i,o,!0)):s[e]=o})}(l);return s}function u(e){return void 0===e||null===e}function h(e){return void 0===e}function p(e){return e+"_"+O++}function f(e,t){var i,r=this;return function(){for(var s=[],n=0;n<arguments.length;n++)s[n]=arguments[n];var o=s[0],a=function(){return i=null,e.call(r,o)};clearTimeout(i),i=setTimeout(a,t)}}function v(e){for(var t=[],i=Object.keys(e),r=0,s=i;r<s.length;r++){var n=s[r];t.push(encodeURIComponent(n)+"="+encodeURIComponent(""+e[n]))}return t.join("&")}function m(e){var t=Object.prototype.toString;return"[object Array]"===t.call(e)&&"[object Object]"===t.call(e[0])}function y(e,t){var i=e;return i===t||!(i===document||!i)&&y(i.parentNode,t)}function b(e){try{throw new Error(e)}catch(e){throw e.message+"\n"+e.stack}}function g(e,t){var i=document.createElement("div"),r=[].slice.call(document.getElementsByTagName("head")[0].querySelectorAll("link, style")),s="";u(t)&&(t=window.open("","print","height=452,width=1024,tabbar=no")),i.appendChild(e.cloneNode(!0));for(var n=0,o=r.length;n<o;n++)s+=r[n].outerHTML;t.document.write("<!DOCTYPE html> <html><head>"+s+"</head><body>"+i.innerHTML+"<script> (function() { window.ready = true; })(); <\/script></body></html>"),t.document.close(),t.focus();var a=setInterval(function(){t.ready&&(t.print(),t.close(),clearInterval(a))},500);return t}function S(e){var t=e+"";return"auto"===t||-1!==t.indexOf("%")||-1!==t.indexOf("px")?t:t+"px"}function L(e,t){var i="string"==typeof e?document.querySelector(e):e;if(i[I])for(var r=0,s=i[I];r<s.length;r++){var n=s[r];if(n instanceof t)return n}return null}function C(e,t){var i="string"==typeof e?document.querySelector(e):e;i[I]?i[I].push(t):i[I]=[t]}function w(e){for(var t="",i=0;i<5;i++)t+=(i?",":"")+e[i];return t}Object.defineProperty(t,"__esModule",{value:!0});var I="ej2_instances",O=0;t.createInstance=i,t.setImmediate=r,t.getValue=s,t.setValue=n,t.deleteObject=o,t.isObject=a,t.getEnumValue=l,t.merge=c,t.extend=d,t.isNullOrUndefined=u,t.isUndefined=h,t.getUniqueID=p,t.debounce=f,t.queryParams=v,t.isObjectArray=m,t.compareElementParent=y,t.throwError=b,t.print=g,t.formatUnit=S,t.getInstance=L,t.addInstance=C}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(6)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(7),i(4)],void 0!==(s=function(e,t,i,r){"use strict";function s(e,t){var i=document.createElement(e);return void 0===t?i:(i.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(i.className=t.className),void 0!==t.id&&(i.id=t.id),void 0!==t.styles&&i.setAttribute("style",t.styles),void 0!==t.attrs&&p(i,t.attrs),i)}function n(e,t){for(var i=a(t),r=0,s=e;r<s.length;r++)for(var n=s[r],o=0,l=i;o<l.length;o++){var c=l[o];n.classList.contains(c)||n.classList.add(c)}return e}function o(e,t){for(var i=a(t),r=0,s=e;r<s.length;r++){var n=s[r];if(""!==n.className)for(var o=0,l=i;o<l.length;o++){var c=l[o];n.classList.remove(c)}}return e}function a(e){var t=[];return"string"==typeof e?t.push(e):t=e,t}function l(e){var t=e;return""===t.style.visibility&&t.offsetWidth>0}function c(e,t){for(var i=document.createDocumentFragment(),r=0,s=e;r<s.length;r++){var n=s[r];i.appendChild(n)}return t.insertBefore(i,t.firstElementChild),e}function d(e,t){for(var i=document.createDocumentFragment(),r=0,s=e;r<s.length;r++){var n=s[r];i.appendChild(n)}return t.appendChild(i),e}function u(e){return e.parentNode.removeChild(e)}function h(e){var t=e.parentNode;i.EventHandler.clearEvents(e),t.removeChild(e)}function p(e,t){for(var i=Object.keys(t),r=e,s=0,n=i;s<n.length;s++){var o=n[s];r.setAttribute(o,t[o])}return r}function f(e,t){return void 0===t&&(t=document),t.querySelector(e)}function v(e,t){return void 0===t&&(t=document),t.querySelectorAll(e)}function m(e,t){var i=e;if("function"==typeof i.closest)return i.closest(t);for(;i&&1===i.nodeType;){if(L(i,t))return i;i=i.parentNode}return null}function y(e){for(var t=[],i=Array.prototype.slice.call(e.parentNode.childNodes),r=0,s=i;r<s.length;r++){var n=s[r];n.nodeType===Node.ELEMENT_NODE&&e!==n&&t.push(n)}return t}function b(e,t,i){var s=e.getAttribute(t);return r.isNullOrUndefined(s)&&(e.setAttribute(t,i.toString()),s=i),s}function g(e,t){void 0!==t&&Object.keys(t).forEach(function(i){e.style[i]=t[i]})}function S(e,t,i){n([e],t),o([e],i)}function L(e,t){var i=e.matches||e.msMatchesSelector||e.webkitMatchesSelector;return i?i.call(e,t):-1!==[].indexOf.call(document.querySelectorAll(t),e)}Object.defineProperty(t,"__esModule",{value:!0}),t.createElement=s,t.addClass=n,t.removeClass=o,t.isVisible=l,t.prepend=c,t.append=d,t.detach=u,t.remove=h,t.attributes=p,t.select=f,t.selectAll=v,t.closest=m,t.siblings=y,t.getAttributeOrDefault=b,t.setStyleAttribute=g,t.classList=S,t.matches=L}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(4)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){}return e.addOrGetEventData=function(e){return"__eventList"in e?e.__eventList.events:(e.__eventList={},e.__eventList.events=[])},e.add=function(t,r,s,n,o){var a,l=e.addOrGetEventData(t);a=o?i.debounce(s,o):s,n&&(a=a.bind(n));for(var c=r.split(" "),d=0;d<c.length;d++)l.push({name:c[d],listener:s,debounce:a}),t.addEventListener(c[d],a)},e.remove=function(t,i,r){for(var s=e.addOrGetEventData(t),n=i.split(" "),o=0;o<n.length;o++)!function(e){var i,o=-1;s&&0!==s.length&&s.some(function(t,s){return t.name===n[e]&&t.listener.toString()===r.toString()&&(o=s,i=t.debounce,!0)}),-1!==o&&s.splice(o,1),t.removeEventListener(n[e],i)}(o)},e.clearEvents=function(t){var r,s;r=e.addOrGetEventData(t),s=i.extend([],s,r);for(var n=0;n<s.length;n++)t.removeEventListener(s[n].name,s[n].debounce),r.shift()},e.trigger=function(t,i,r){for(var s=e.addOrGetEventData(t),n=0,o=s;n<o.length;n++){var a=o[n];a.name===i&&a.debounce.call(this,r)}},e}();t.EventHandler=r}.apply(t,r))&&(e.exports=s)},function(t,i){t.exports=e},function(e,i){e.exports=t},function(e,t,i){var r,s;r=[i,t,i(3),i(5),i(8),i(9)],void 0!==(s=function(e,t,i,r,s,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.cssClass={li:"e-list-item",ul:"e-list-parent e-ul",group:"e-list-group-item",icon:"e-list-icon",text:"e-list-text",check:"e-list-check",textContent:"e-text-content",hasChild:"e-has-child",level:"e-level",collapsible:"e-icon-collapsible",disabled:"e-disabled",image:"e-list-img"};!function(e){function o(e,t,i){return"string"==typeof e[0]?a(e,i):l(e,t,0,i)}function a(e,t){for(var i=[],r=t?g:S,s=0;s<e.length;s++){var n=r(e[s],t?e[s]:null);i.push(n)}return L(i)}function l(s,n,o,a){void 0===o&&(o=0);for(var l,c=i.extend({},C,n),d=i.extend({},e.defaultMappedFields,c.fields),u=[],h=0;h<s.length;h++){var p=s[h],f=[];if(c.showCheckBox&&f.push(r.createElement("div",{className:t.cssClass.check})),!0===a)c.showIcon&&f.push(r.createElement("span",{className:t.cssClass.icon+" "+p[d.iconCss]})),l=g(p[d.text],p[d.value],c.itemClass,f,!(!p.hasOwnProperty("isHeader")||!p.isHeader));else{if(l=S(p,d,c.itemClass,f,n),l.classList.add(t.cssClass.level+"-"+o),l.setAttribute("aria-level",o+""),d.tooltip&&l.setAttribute("title",p[d.tooltip]),p.hasOwnProperty(d.htmlAttributes)&&p[d.htmlAttributes]&&r.attributes(l,p[d.htmlAttributes]),p.hasOwnProperty(d.enabled)&&!1===p[d.enabled]&&l.classList.add(t.cssClass.disabled),p.hasOwnProperty(d.isVisible)&&!1===p[d.isVisible]&&(l.style.display="none"),b(p,d,s,c,l,o),p.hasOwnProperty(d.imageUrl)){var v={src:p[d.imageUrl]};p.hasOwnProperty(d.imageUrl)&&i.merge(v,p[d.imageAttributes]),r.prepend([r.createElement("img",{className:t.cssClass.image,attrs:v})],l.firstElementChild)}c.showIcon&&!c.template&&r.prepend([r.createElement("div",{className:t.cssClass.icon+" "+p[d.iconCss]})],l.firstElementChild)}u.push(l)}return L(u,c.listClass)}function c(e,i,s){if(e&&e.length){var n,o,a=Array.prototype.slice.call(e);for(o=i?d(i,a):!0===s?a.length:-1,n=a[o+(!0===s?-1:1)];n&&(!r.isVisible(n)||n.classList.contains(t.cssClass.disabled));)o+=!0===s?-1:1,n=a[o];return n}}function d(e,t){if(t&&e){var i=t;return i=Array.prototype.slice.call(t),i.indexOf(e)}}function u(e,t,i){void 0===i&&(i="None");var r=(new n.Query).group(t.groupBy);r=h(i,"key",r);var s=p(e,r);e=[];for(var o=0;o<s.length;o++){var a=s[o].items,l={};l[t.text]=s[o].key,l.isHeader=!0,l.items=a,e.push(l);for(var c=0;c<a.length;c++)e.push(a[c])}return e}function h(e,t,i){return void 0===i&&(i=new n.Query),"Ascending"===e?i.sortBy(t,"ascending",!0):"Descending"===e&&i.sortBy(t,"descending",!0),i}function p(e,t){return new n.DataManager(e).executeLocal(t)}function f(e,t){var r=i.extend({},C,t),s=r.fields,n=e.cloneNode(!0),o=[];n.classList.add("json-parent");var a=n.querySelectorAll(".json-parent>li");n.classList.remove("json-parent");for(var l=0;l<a.length;l++){var c=a[l],d=c.querySelector("ul"),u={};u[s.text]=c.firstChild.textContent,u[s.id]=y(),d&&(u[s.child]=f(d,t)),o.push(u)}return o}function v(e,i,n){for(var o=r.createElement("ul",{className:t.cssClass.ul,attrs:{role:"presentation"}}),a=s.compile(e),l=[],c=0,d=i;c<d.length;c++){var u=d[c],h=u.isHeader,p=r.createElement("li",{className:h?t.cssClass.group:t.cssClass.li,attrs:{role:"presentation"}});if(h)p.innerText=u[n.text];else{p.innerHTML=a(u);var f=u[n.value];p.setAttribute("data-value",f),p.setAttribute("role","option")}l.push(p)}return r.append(l,o),o}function m(e,t,i,r){for(var n=s.compile(e),o=0,a=r;o<a.length;o++){var l=a[o];l.innerHTML=n({text:l.textContent})}return r}function y(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}function b(e,s,n,o,a,c){var d=e[s.child],u=e[s.hasChildren];if(!i.isUndefined(d)&&(u=!0,a.classList.add(t.cssClass.hasChild),o.processSubChild)){var h=l(d,o,++c);a.appendChild(h)}o.expandCollapse&&u&&!o.template&&r.prepend([r.createElement("div",{className:"e-icons "+t.cssClass.collapsible})],a.querySelector("."+t.cssClass.textContent))}function g(e,i,s,n,o){var a=r.createElement("li",{className:(!0===o?t.cssClass.group:t.cssClass.li)+" "+s,attrs:{role:!0===o?"group":"presentation"}});return o?a.innerText=e:(a.setAttribute("data-value",i),a.setAttribute("role","option"),n&&r.append(n,a),a.appendChild(document.createTextNode(e))),a}function S(e,n,o,a,l){var c,d,u=e;"string"!=typeof e&&(u=e[n.text],c=e[n.id],d=!(!e.hasOwnProperty("isHeader")||!e.isHeader));var h=r.createElement("li",{className:(!0===d?t.cssClass.group:t.cssClass.li)+" "+o,attrs:{role:!0===d?"group":"presentation"}});if(c&&h.setAttribute("uID",c),d&&l&&l.groupTemplate){var p=s.compile(l.groupTemplate);h.innerHTML=p(e)}else if(!d&&l&&l.template){var p=s.compile(l.template);h.innerHTML=p(e)}else{var f=r.createElement("div",{className:t.cssClass.textContent});i.isUndefined(a)||r.append(a,h),f.appendChild(r.createElement("span",{className:t.cssClass.text,innerHTML:u,attrs:{role:"list-item"}})),h.appendChild(f)}return h}function L(e,i){var s=r.createElement("ul",{className:t.cssClass.ul+" "+i,attrs:{role:"presentation"}});return r.append(e,s),s}e.defaultMappedFields={id:"id",text:"text",value:"value",isChecked:"isChecked",enabled:"enabled",expanded:"expanded",iconCss:"icon",child:"child",isVisible:"isVisible",hasChildren:null,tooltip:null,htmlAttributes:null,imageAttributes:null,imageUrl:"imageUrl",groupBy:null};var C={showCheckBox:!1,showIcon:!1,expandCollapse:!1,fields:e.defaultMappedFields,listClass:"",itemClass:"",processSubChild:!1,sortOrder:"None",template:null,groupTemplate:null};e.createList=o,e.createListFromArray=a,e.createListFromJson=l,e.getSiblingLI=c,e.indexOf=d,e.groupDataSource=u,e.addSorting=h,e.getDataSource=p,e.createJsonFromElement=f,e.renderContentTemplate=v,e.renderGroupTemplate=m}(t.ListBase||(t.ListBase={}))}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(10)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)}])}); | ||
/*! | ||
* filename: ej2-lists.umd.min.js | ||
* version : 1.0.10 | ||
* Copyright Syncfusion Inc. 2001 - 2017. All rights reserved. | ||
* Use of this code is subject to the terms of our license. | ||
* A copy of the current license can be obtained at any time by e-mailing | ||
* licensing@syncfusion.com. Any infringement will be prosecuted under | ||
* applicable laws. | ||
*/ | ||
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("@syncfusion/ej2-base"),require("@syncfusion/ej2-data"));else if("function"==typeof define&&define.amd)define(["@syncfusion/ej2-base","@syncfusion/ej2-data"],t);else{var i="object"==typeof exports?t(require("@syncfusion/ej2-base"),require("@syncfusion/ej2-data")):t(e["@syncfusion/ej2-base"],e["@syncfusion/ej2-data"]);for(var r in i)("object"==typeof exports?exports:e)[r]=i[r]}}(this,function(e,t){return function(e){function t(r){if(i[r])return i[r].exports;var s=i[r]={exports:{},id:r,loaded:!1};return e[r].call(s.exports,s,s.exports,t),s.loaded=!0,s.exports}var i={};return t.m=e,t.c=i,t.p="",t(0)}([function(e,t,i){var r,s;r=[i,t,i(1),i(11)],void 0!==(s=function(e,t,i,r){"use strict";function s(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}Object.defineProperty(t,"__esModule",{value:!0}),s(i),s(r)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(2)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s,n=this&&this.__extends||function(){var e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])};return function(t,i){function r(){this.constructor=t}e(t,i),t.prototype=null===i?Object.create(i):(r.prototype=i.prototype,new r)}}(),o=this&&this.__decorate||function(e,t,i,r){var s,n=arguments.length,o=n<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(s=e[a])&&(o=(n<3?s(o):n>3?s(t,i,o):s(t,i))||o);return n>3&&o&&Object.defineProperty(t,i,o),o};r=[i,t,i(3),i(5),i(8),i(8),i(8),i(9),i(10)],void 0!==(s=function(e,t,i,r,s,a,l,c,d){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u={None:[],SlideLeft:["SlideRightOut","SlideLeftOut","SlideLeftIn","SlideRightIn"],SlideDown:["SlideTopOut","SlideBottomOut","SlideBottomIn","SlideTopIn"],Zoom:["FadeOut","FadeZoomOut","FadeZoomIn","FadeIn"],Fade:["FadeOut","FadeOut","FadeIn","FadeIn"]},h={None:[],SlideLeft:["SlideLeftOut","SlideRightOut","SlideRightIn","SlideLeftIn"],SlideDown:["SlideBottomOut","SlideTopOut","SlideTopIn","SlideBottomIn"],Zoom:["FadeZoomOut","FadeOut","FadeIn","FadeZoomIn"],Fade:["FadeOut","FadeOut","FadeIn","FadeIn"]},p={root:"e-listview",hover:"e-hover",selected:"e-active",parentItem:"e-list-parent",listItem:"e-list-item",listItemText:"e-list-text",grpListItem:"e-list-group-item",hasChild:"e-has-child",view:"e-view",header:"e-header",headerText:"e-headertext",text:"e-text",disable:"e-disabled",content:"e-content",icon:"e-icons",backIcon:"e-icon-back"},f=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n(t,e),t}(a.ChildProperty);o([s.Property("id")],f.prototype,"id",void 0),o([s.Property("text")],f.prototype,"text",void 0),o([s.Property("isChecked")],f.prototype,"isChecked",void 0),o([s.Property("isVisible")],f.prototype,"isVisible",void 0),o([s.Property("enabled")],f.prototype,"enabled",void 0),o([s.Property("iconCss")],f.prototype,"iconCss",void 0),o([s.Property("child")],f.prototype,"child",void 0),o([s.Property("tooltip")],f.prototype,"tooltip",void 0),o([s.Property("groupBy")],f.prototype,"groupBy",void 0),o([s.Property("text")],f.prototype,"sortBy",void 0),o([s.Property("htmlAttributes")],f.prototype,"htmlAttributes",void 0),o([s.Property("tableName")],f.prototype,"tableName",void 0),t.FieldSettings=f;var v=function(e){function t(t,i){var r=e.call(this,t,i)||this;return r.curDSLevel=[],r.curViewDS=[],r.keyConfigs={moveDown:"downarrow",moveUp:"uparrow",select:"enter",back:"backspace"},r.animateOptions={},r.aniObj=new l.Animation(r.animateOptions),r}return n(t,e),t.prototype.onPropertyChanged=function(e,t){for(var i=0,r=Object.keys(e);i<r.length;i++){switch(r[i]){case"htmlAttributes":this.setHTMLAttribute();break;case"cssClass":this.setCSSClass(t.cssClass);break;case"enable":this.setEnable();break;case"width":case"height":this.setSize();break;case"enableRtl":this.setEnableRTL();break;case"fields":this.listBaseOption.fields=this.fields.properties,this.reRender();break;case"headerTitle":this.curDSLevel.length||this.header(this.headerTitle,!1);break;case"showHeader":this.header(this.headerTitle,!1);break;case"dataSource":this.reRender();break;case"sortOrder":case"showIcon":this.listBaseOption.showIcon=this.showIcon,this.curViewDS=this.getSubDS(),this.resetCurrentList()}}},t.prototype.setHTMLAttribute=function(){Object.keys(this.htmlAttributes).length&&r.attributes(this.element,this.htmlAttributes)},t.prototype.setCSSClass=function(e){this.cssClass&&r.addClass([this.element],this.cssClass.split(" ")),e&&r.removeClass([this.element],e.split(" "))},t.prototype.setSize=function(){this.element.style.height=i.formatUnit(this.height),this.element.style.width=i.formatUnit(this.width)},t.prototype.setEnable=function(){this.enableElement(this.element,this.enable)},t.prototype.setEnableRTL=function(){this.enableRtl?this.element.classList.add("e-rtl"):this.element.classList.remove("e-rtl")},t.prototype.enableElement=function(e,t){t?e.classList.remove(p.disable):e.classList.add(p.disable)},t.prototype.header=function(e,t){if(void 0===this.headerEle&&this.showHeader){this.headerEle=r.createElement("div",{className:p.header});var i=r.createElement("span",{className:p.headerText,innerHTML:this.headerTitle}),s=r.createElement("div",{className:p.text,innerHTML:i.outerHTML}),n=r.createElement("div",{className:p.icon+" "+p.backIcon+" e-but-back",attrs:{style:"display:none;"}});this.headerEle.appendChild(n),this.headerEle.appendChild(s),this.element.classList.add("e-has-header"),r.prepend([this.headerEle],this.element)}else if(this.headerEle)if(this.showHeader){this.headerEle.style.display="";var s=this.headerEle.querySelector("."+p.headerText),n=this.headerEle.querySelector("."+p.backIcon);s.innerHTML=e,n.style.display=!0===t?"":"none"}else this.headerEle.style.display="none"},t.prototype.switchView=function(e,t,i){var r=this;if(e&&t){var s=e.style.position,n="hidden"!==this.element.style.overflow?this.element.style.overflow:"";e.style.position="absolute",e.classList.add("e-view");var o=void 0,a=this.animation.duration;if(this.animation.effect)o=this.enableRtl?h[this.animation.effect]:u[this.animation.effect];else{o=this.enableRtl?h.SlideLeft:u.SlideRight,a=0}this.element.style.overflow="hidden",this.aniObj.animate(e,{name:!0===i?o[0]:o[1],duration:a,timingFunction:this.animation.easing,end:function(t){e.style.display="none",r.element.style.overflow=n,e.style.position=s,e.classList.remove("e-view")}}),t.style.display="",this.aniObj.animate(t,{name:!0===i?o[2]:o[3],duration:a,timingFunction:this.animation.easing,end:function(){r.trigger("actionComplete")}}),this.curUL=t}},t.prototype.preRender=function(){this.listBaseOption={template:this.template,groupTemplate:this.groupTemplate,expandCollapse:!0,listClass:"",fields:this.fields.properties,sortOrder:this.sortOrder,showIcon:this.showIcon}},t.prototype.clickHandler=function(e){var t=e.target,i=t.classList;if(i.contains(p.backIcon)||i.contains(p.headerText))this.back();else{var s=r.closest(t.parentNode,"."+p.listItem);null===s&&(s=t),this.setSelectLI(s,e)}},t.prototype.hoverHandler=function(e){var t=r.closest(e.target.parentNode,"."+p.listItem);this.setHoverLI(t)},t.prototype.leaveHandler=function(e){this.removeHover()},t.prototype.keyActionHandler=function(e){switch(e.preventDefault(),e.action){case"moveDown":this.hoverSiblingLI();break;case"moveUp":this.hoverSiblingLI(!0);break;case"select":this.setSelectLI(this.curUL.querySelector("."+p.hover),e);break;case"back":this.back()}},t.prototype.swipeActionHandler=function(e){"Right"===e.swipeDirection&&this.back()},t.prototype.wireEvents=function(){s.EventHandler.add(this.element,"click",this.clickHandler,this),s.EventHandler.add(this.element,"mouseover",this.hoverHandler,this),s.EventHandler.add(this.element,"mouseout",this.leaveHandler,this),this.keyboardModule=new a.KeyboardEvents(this.element,{keyAction:this.keyActionHandler.bind(this),keyConfigs:this.keyConfigs}),this.touchModule=new l.Touch(this.element,{swipe:this.swipeActionHandler.bind(this)})},t.prototype.unWireEvents=function(){s.EventHandler.remove(this.element,"click",this.clickHandler),s.EventHandler.remove(this.element,"mouseover",this.hoverHandler),s.EventHandler.remove(this.element,"mouseout",this.leaveHandler),this.keyboardModule.destroy(),this.touchModule.destroy()},t.prototype.removeHover=function(){var e=this.element.querySelector("."+p.hover);e&&e.classList.remove(p.hover)},t.prototype.removeSelect=function(){for(var e=this.element.querySelectorAll("."+p.selected),t=0,i=e;t<i.length;t++){var r=i[t];r.removeAttribute("aria-selected"),""!==r.className&&r.classList.remove(p.selected)}},t.prototype.isValidLI=function(e){return e&&e.classList.contains(p.listItem)&&!e.classList.contains(p.grpListItem)&&!e.classList.contains(p.disable)},t.prototype.setSelectLI=function(e,t){if(this.isValidLI(e)&&!e.classList.contains(p.selected)&&this.enable){this.removeSelect(),e.classList.add(p.selected),e.setAttribute("aria-selected","true"),this.removeHover();var r=this.getItemData(e);this.selectedItems={item:e,text:r[this.listBaseOption.fields.text],data:r};var s={};i.merge(s,this.selectedItems),t&&i.merge(s,{isInteracted:!0,event:t}),this.trigger("select",s),this.selectedLI=e,this.renderSubList(e)}},t.prototype.setHoverLI=function(e){if(this.isValidLI(e)&&!e.classList.contains(p.hover)&&this.enable){var t=this.element.querySelectorAll("."+p.hover);t&&t.length&&r.removeClass(t,p.hover),e.classList.contains(p.selected)||e.classList.add(p.hover)}},t.prototype.hoverSiblingLI=function(e){var t,i=this.curUL.querySelector("."+p.hover);if(i||(i=this.curUL.querySelector("."+p.selected)),i)t=d.ListBase.getSiblingLI(this.curUL.querySelectorAll("."+p.listItem),i,e);else if(e){var r=this.curUL.querySelectorAll("."+p.listItem);t=r[r.length-1]}else t=this.curUL.querySelector("."+p.listItem);this.setHoverLI(t)},t.prototype.getSubDS=function(){var e=this.curDSLevel;if(e.length){for(var t=this.localData,i=0,r=e;i<r.length;i++){var s=r[i];this.curDSJSON=this.findItemFromDS(t,{id:s}),t=this.curDSJSON?this.curDSJSON[this.fields.child]:t}return t}return this.localData},t.prototype.getItemData=function(e){var t=this.getElementUID(e),i=this.dataSource;return this.findItemFromDS(i,t)},t.prototype.findItemFromDS=function(e,t,i){var r,s=this;return e&&e.length&&t?e.some(function(n){return!t.id&&!t.text||t.id&&n[s.fields.id]!==t.id||t.text&&n[s.fields.text]!==t.text?n.hasOwnProperty(s.fields.child)&&n[s.fields.child].length&&(r=s.findItemFromDS(n[s.fields.child],t,i)):r=i?e:n,!!r}):r=e,r},t.prototype.getQuery=function(){var e=[],t=this.query?this.query:new c.Query;if(!this.query){for(var i=0,r=Object.keys(this.fields.properties);i<r.length;i++){var s=r[i];"tableName"!==s&&this.fields[s]&&this.fields[s]!==d.ListBase.defaultMappedFields[s]&&-1===e.indexOf(this.fields[s])&&e.push(this.fields[s])}t.select(e),this.fields.properties.hasOwnProperty("tableName")&&t.from(this.fields.tableName)}return t},t.prototype.setViewDataSource=function(e){void 0===e&&(e=this.localData),e&&this.fields.groupBy?this.curViewDS=d.ListBase.groupDataSource(e,this.fields,this.sortOrder):e&&"None"!==this.sortOrder?this.curViewDS=d.ListBase.getDataSource(e,d.ListBase.addSorting(this.sortOrder,this.fields.sortBy)):this.curViewDS=e},t.prototype.isInAnimation=function(){return this.curUL.classList.contains(".e-animate")},t.prototype.setLocalData=function(){var e=this;if(this.trigger("actionBegin"),this.dataSource instanceof c.DataManager)this.dataSource.executeQuery(this.getQuery()).then(function(t){e.isDestroyed||(e.localData=t.result,e.renderList(),e.trigger("actionComplete",t))}).catch(function(t){e.isDestroyed||e.trigger("actionFailure",t)});else if(this.dataSource&&this.dataSource.length)this.localData=this.dataSource,this.renderList(),this.trigger("actionComplete",{data:this.localData});else{var t=this.element.querySelector("ul");t&&(r.remove(t),this.setProperties({dataSource:d.ListBase.createJsonFromElement(t)},!0),this.localData=this.dataSource,this.renderList(),this.trigger("actionComplete",{data:this.localData}))}},t.prototype.reRender=function(){this.element.innerHTML="",this.curUL=this.headerEle=void 0,this.setLocalData(),this.header(),this.contentContainer=r.createElement("div",{className:p.content}),this.element.appendChild(this.contentContainer),this.renderIntoDom(this.ulElement)},t.prototype.resetCurrentList=function(){this.setViewDataSource(this.curViewDS),this.contentContainer.innerHTML="",this.createList(),this.renderIntoDom(this.curUL)},t.prototype.createList=function(){this.ulElement=this.curUL=d.ListBase.createList(this.curViewDS,this.listBaseOption),this.liCollection=this.curUL.querySelectorAll("."+p.listItem)},t.prototype.renderSubList=function(e){var t=e.getAttribute("uid");if(e.classList.contains(p.hasChild)&&t){var i=r.closest(e.parentNode,"."+p.parentItem),s=this.element.querySelector("[pid='"+t+"']");this.curDSLevel.push(t),this.setViewDataSource(this.getSubDS()),s||(s=d.ListBase.createListFromJson(this.curViewDS,this.listBaseOption,this.curDSLevel.length),s.setAttribute("pID",t),s.style.display="none",this.renderIntoDom(s)),this.switchView(i,s),this.liCollection=this.curUL.querySelectorAll("."+p.listItem),this.header(this.selectedItems.data[this.listBaseOption.fields.text],!0),this.selectedLI=void 0}},t.prototype.renderIntoDom=function(e){this.contentContainer.appendChild(e)},t.prototype.renderList=function(){this.setViewDataSource(),this.createList(),this.contentContainer=r.createElement("div",{className:p.content}),this.element.appendChild(this.contentContainer),this.renderIntoDom(this.ulElement)},t.prototype.getElementUID=function(e){var t={};return e instanceof Element?t.id=e.getAttribute("uid"):t=e,t},t.prototype.render=function(){this.element.classList.add(p.root),r.attributes(this.element,{role:"list"}),this.setCSSClass(),this.setEnableRTL(),this.setEnable(),this.setSize(),this.wireEvents(),this.header(),this.setLocalData(),this.setHTMLAttribute(),this.rippleFn=l.ripple(this.element,".e-list-item")},t.prototype.destroy=function(){this.unWireEvents();var t=[p.root,this.cssClass,p.disable,"e-rtl","e-has-header"];r.removeClass([this.element],t),this.rippleFn(),e.prototype.destroy.call(this)},t.prototype.back=function(){var e=this.curDSLevel[this.curDSLevel.length-1];if(void 0!==e&&!this.isInAnimation()){this.curDSLevel.pop(),this.setViewDataSource(this.getSubDS());var t=this.element.querySelector("[uid='"+e+"']"),i=this.curUL;t?t=t.parentElement:(this.createList(),this.renderIntoDom(this.ulElement),t=this.curUL);var r=this.curDSJSON[this.fields.text];this.switchView(i,t,!0),this.removeSelect(),this.liCollection=this.curUL.querySelectorAll("."+p.listItem),this.header(this.curDSLevel.length?r:this.headerTitle,!!this.curDSLevel.length)}},t.prototype.selectItem=function(e){var t=this.getItemData(e);if(t){var i=this.element.querySelector('[uid="'+t[this.fields.id]+'"]');i&&this.setSelectLI(i)}},t.prototype.getSelectedItem=function(){return this.selectedItems},t.prototype.findItem=function(e){return this.findItemFromDS(this.dataSource,e)},t.prototype.enableItem=function(e){var t=this.getItemData(e);if(t){var i=this.element.querySelector('[uid="'+t[this.fields.id]+'"]');i&&i.classList.remove(p.disable),delete t[this.fields.enabled]}},t.prototype.disableItem=function(e){var t=this.getItemData(e);if(t){var i=this.element.querySelector('[uid="'+t[this.fields.id]+'"]');i&&i.classList.add(p.disable),t[this.fields.enabled]=!1}},t.prototype.showItem=function(e){this.showHideItem(e,!1,"")},t.prototype.hideItem=function(e){this.showHideItem(e,!0,"none")},t.prototype.showHideItem=function(e,t,i){var r=this.getItemData(e);if(r){var s=this.element.querySelector('[uid="'+r[this.fields.id]+'"]');s&&(s.style.display=i),t?r[this.fields.isVisible]=!1:delete r[this.fields.isVisible]}},t.prototype.addItem=function(e,t){var i=this.findItemFromDS(this.dataSource,t),r=i[this.fields.child];r||(r=[]),r=r.concat(e),i instanceof Array?(this.dataSource=this.localData=i.concat(e),this.setViewDataSource()):i[this.fields.child]=r,this.resetCurrentList()},t.prototype.removeItem=function(e){var t=this,i=this.getElementUID(e),r=this.findItemFromDS(this.dataSource,i,!0);if(r&&e){var s,n;r.some(function(e,r,o){return!(!i.id&&!i.text||i.id&&e[t.fields.id]!==i.id||i.text&&e[t.fields.text]!==i.text)&&(s=o,n=r,!0)}),s.splice(n,1),this.resetCurrentList()}},t.prototype.getModuleName=function(){return"listview"},t.prototype.getPersistData=function(){return this.addOnPersist(["cssClass","enableRtl","htmlAttributes","enable","fields","animation","headerTitle","sortOrder","showIcon","height","width"])},t}(s.Component);o([s.Property()],v.prototype,"cssClass",void 0),o([s.Property({})],v.prototype,"htmlAttributes",void 0),o([s.Property(!0)],v.prototype,"enable",void 0),o([s.Property([])],v.prototype,"dataSource",void 0),o([s.Property()],v.prototype,"query",void 0),o([s.Complex(d.ListBase.defaultMappedFields,f)],v.prototype,"fields",void 0),o([s.Property({effect:"SlideLeft",duration:400,easing:"ease"})],v.prototype,"animation",void 0),o([s.Property("None")],v.prototype,"sortOrder",void 0),o([s.Property(!1)],v.prototype,"showIcon",void 0),o([s.Property("")],v.prototype,"headerTitle",void 0),o([s.Property(!1)],v.prototype,"showHeader",void 0),o([s.Property("")],v.prototype,"height",void 0),o([s.Property("")],v.prototype,"width",void 0),o([s.Property(null)],v.prototype,"template",void 0),o([s.Property(null)],v.prototype,"groupTemplate",void 0),o([s.Event()],v.prototype,"select",void 0),o([s.Event()],v.prototype,"actionBegin",void 0),o([s.Event()],v.prototype,"actionComplete",void 0),o([s.Event()],v.prototype,"actionFailure",void 0),v=o([a.NotifyPropertyChanges],v),t.ListView=v,t.listViewBuilder=s.CreateBuilder(v)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(4)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t],void 0!==(s=function(e,t){"use strict";function i(e,t){var i=t;return i.unshift(void 0),new(Function.prototype.bind.apply(e,i))}function r(e){var t,i=new Uint16Array(5);(window.msCrypto||window.crypto).getRandomValues(i);var r="ej2"+w(i),s=function(i){i.source===window&&"string"==typeof i.data&&i.data.length<=32&&i.data===r&&(e(),t())};return window.addEventListener("message",s,!1),window.postMessage(r,"*"),t=function(){window.removeEventListener("message",s)}}function s(e,t){for(var i=t,r=e.split("."),s=0;s<r.length&&!h(i);s++)i=i[r[s]];return i}function n(e,t,i){var r,s,n=e.split("."),o=i||{},a=o,l=n.length;for(r=0;r<l;r++)s=n[r],r+1===l?a[s]=void 0===t?{}:t:u(a[s])&&(a[s]={}),a=a[s];return o}function o(e,t){delete e[t]}function a(e){var t={};return!u(e)&&e.constructor===t.constructor}function l(e,t){return e[t]}function c(e,t){if(!u(t))for(var i=e,r=t,s=Object.keys(t),n=0,o=s;n<o.length;n++){var a=o[n];i[a]=r[a]}}function d(e,t,i,r){var s=e||{},n=arguments.length;r&&(n-=1);for(var o=arguments,l=1;l<n;l++)!function(e){if(!o[e])return"continue";var t=o[e];Object.keys(t).forEach(function(e){var i,n=s[e],o=t[e];r&&a(o)?(i=a(n)?n:{},s[e]=d({},i,o,!0)):s[e]=o})}(l);return s}function u(e){return void 0===e||null===e}function h(e){return void 0===e}function p(e){return e+"_"+O++}function f(e,t){var i,r=this;return function(){for(var s=[],n=0;n<arguments.length;n++)s[n]=arguments[n];var o=s[0],a=function(){return i=null,e.call(r,o)};clearTimeout(i),i=setTimeout(a,t)}}function v(e){for(var t=[],i=Object.keys(e),r=0,s=i;r<s.length;r++){var n=s[r];t.push(encodeURIComponent(n)+"="+encodeURIComponent(""+e[n]))}return t.join("&")}function m(e){var t=Object.prototype.toString;return"[object Array]"===t.call(e)&&"[object Object]"===t.call(e[0])}function y(e,t){var i=e;return i===t||!(i===document||!i)&&y(i.parentNode,t)}function b(e){try{throw new Error(e)}catch(e){throw e.message+"\n"+e.stack}}function g(e,t){var i=document.createElement("div"),r=[].slice.call(document.getElementsByTagName("head")[0].querySelectorAll("link, style")),s="";u(t)&&(t=window.open("","print","height=452,width=1024,tabbar=no")),i.appendChild(e.cloneNode(!0));for(var n=0,o=r.length;n<o;n++)s+=r[n].outerHTML;t.document.write("<!DOCTYPE html> <html><head>"+s+"</head><body>"+i.innerHTML+"<script> (function() { window.ready = true; })(); <\/script></body></html>"),t.document.close(),t.focus();var a=setInterval(function(){t.ready&&(t.print(),t.close(),clearInterval(a))},500);return t}function S(e){var t=e+"";return"auto"===t||-1!==t.indexOf("%")||-1!==t.indexOf("px")?t:t+"px"}function L(e,t){var i="string"==typeof e?document.querySelector(e):e;if(i[I])for(var r=0,s=i[I];r<s.length;r++){var n=s[r];if(n instanceof t)return n}return null}function C(e,t){var i="string"==typeof e?document.querySelector(e):e;i[I]?i[I].push(t):i[I]=[t]}function w(e){for(var t="",i=0;i<5;i++)t+=(i?",":"")+e[i];return t}Object.defineProperty(t,"__esModule",{value:!0});var I="ej2_instances",O=0;t.createInstance=i,t.setImmediate=r,t.getValue=s,t.setValue=n,t.deleteObject=o,t.isObject=a,t.getEnumValue=l,t.merge=c,t.extend=d,t.isNullOrUndefined=u,t.isUndefined=h,t.getUniqueID=p,t.debounce=f,t.queryParams=v,t.isObjectArray=m,t.compareElementParent=y,t.throwError=b,t.print=g,t.formatUnit=S,t.getInstance=L,t.addInstance=C}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(6)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(7),i(4)],void 0!==(s=function(e,t,i,r){"use strict";function s(e,t){var i=document.createElement(e);return void 0===t?i:(i.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(i.className=t.className),void 0!==t.id&&(i.id=t.id),void 0!==t.styles&&i.setAttribute("style",t.styles),void 0!==t.attrs&&p(i,t.attrs),i)}function n(e,t){for(var i=a(t),r=0,s=e;r<s.length;r++)for(var n=s[r],o=0,l=i;o<l.length;o++){var c=l[o];n.classList.contains(c)||n.classList.add(c)}return e}function o(e,t){for(var i=a(t),r=0,s=e;r<s.length;r++){var n=s[r];if(""!==n.className)for(var o=0,l=i;o<l.length;o++){var c=l[o];n.classList.remove(c)}}return e}function a(e){var t=[];return"string"==typeof e?t.push(e):t=e,t}function l(e){var t=e;return""===t.style.visibility&&t.offsetWidth>0}function c(e,t){for(var i=document.createDocumentFragment(),r=0,s=e;r<s.length;r++){var n=s[r];i.appendChild(n)}return t.insertBefore(i,t.firstElementChild),e}function d(e,t){for(var i=document.createDocumentFragment(),r=0,s=e;r<s.length;r++){var n=s[r];i.appendChild(n)}return t.appendChild(i),e}function u(e){return e.parentNode.removeChild(e)}function h(e){var t=e.parentNode;i.EventHandler.clearEvents(e),t.removeChild(e)}function p(e,t){for(var i=Object.keys(t),r=e,s=0,n=i;s<n.length;s++){var o=n[s];r.setAttribute(o,t[o])}return r}function f(e,t){return void 0===t&&(t=document),t.querySelector(e)}function v(e,t){return void 0===t&&(t=document),t.querySelectorAll(e)}function m(e,t){var i=e;if("function"==typeof i.closest)return i.closest(t);for(;i&&1===i.nodeType;){if(L(i,t))return i;i=i.parentNode}return null}function y(e){for(var t=[],i=Array.prototype.slice.call(e.parentNode.childNodes),r=0,s=i;r<s.length;r++){var n=s[r];n.nodeType===Node.ELEMENT_NODE&&e!==n&&t.push(n)}return t}function b(e,t,i){var s=e.getAttribute(t);return r.isNullOrUndefined(s)&&(e.setAttribute(t,i.toString()),s=i),s}function g(e,t){void 0!==t&&Object.keys(t).forEach(function(i){e.style[i]=t[i]})}function S(e,t,i){n([e],t),o([e],i)}function L(e,t){var i=e.matches||e.msMatchesSelector||e.webkitMatchesSelector;return i?i.call(e,t):-1!==[].indexOf.call(document.querySelectorAll(t),e)}Object.defineProperty(t,"__esModule",{value:!0}),t.createElement=s,t.addClass=n,t.removeClass=o,t.isVisible=l,t.prepend=c,t.append=d,t.detach=u,t.remove=h,t.attributes=p,t.select=f,t.selectAll=v,t.closest=m,t.siblings=y,t.getAttributeOrDefault=b,t.setStyleAttribute=g,t.classList=S,t.matches=L}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(4)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){}return e.addOrGetEventData=function(e){return"__eventList"in e?e.__eventList.events:(e.__eventList={},e.__eventList.events=[])},e.add=function(t,r,s,n,o){var a,l=e.addOrGetEventData(t);a=o?i.debounce(s,o):s,n&&(a=a.bind(n));for(var c=r.split(" "),d=0;d<c.length;d++)l.push({name:c[d],listener:s,debounce:a}),t.addEventListener(c[d],a)},e.remove=function(t,i,r){for(var s=e.addOrGetEventData(t),n=i.split(" "),o=0;o<n.length;o++)!function(e){var i,o=-1;s&&0!==s.length&&s.some(function(t,s){return t.name===n[e]&&t.listener.toString()===r.toString()&&(o=s,i=t.debounce,!0)}),-1!==o&&s.splice(o,1),t.removeEventListener(n[e],i)}(o)},e.clearEvents=function(t){var r,s;r=e.addOrGetEventData(t),s=i.extend([],s,r);for(var n=0;n<s.length;n++)t.removeEventListener(s[n].name,s[n].debounce),r.shift()},e.trigger=function(t,i,r){for(var s=e.addOrGetEventData(t),n=0,o=s;n<o.length;n++){var a=o[n];a.name===i&&a.debounce.call(this,r)}},e}();t.EventHandler=r}.apply(t,r))&&(e.exports=s)},function(t,i){t.exports=e},function(e,i){e.exports=t},function(e,t,i){var r,s;r=[i,t,i(3),i(5),i(8),i(9)],void 0!==(s=function(e,t,i,r,s,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.cssClass={li:"e-list-item",ul:"e-list-parent e-ul",group:"e-list-group-item",icon:"e-list-icon",text:"e-list-text",check:"e-list-check",textContent:"e-text-content",hasChild:"e-has-child",level:"e-level",collapsible:"e-icon-collapsible",disabled:"e-disabled",image:"e-list-img"};!function(e){function o(e,t,i){return"string"==typeof e[0]?a(e,i):l(e,t,0,i)}function a(e,t){for(var i=[],r=t?g:S,s=0;s<e.length;s++){var n=r(e[s],t?e[s]:null);i.push(n)}return L(i)}function l(s,n,o,a){void 0===o&&(o=0);for(var l,c=i.extend({},C,n),d=i.extend({},e.defaultMappedFields,c.fields),u=[],h=0;h<s.length;h++){var p=s[h],f=[];if(c.showCheckBox&&f.push(r.createElement("div",{className:t.cssClass.check})),!0===a)c.showIcon&&f.push(r.createElement("span",{className:t.cssClass.icon+" "+p[d.iconCss]})),l=g(p[d.text],p[d.value],c.itemClass,f,!(!p.hasOwnProperty("isHeader")||!p.isHeader));else{if(l=S(p,d,c.itemClass,f,n),l.classList.add(t.cssClass.level+"-"+o),l.setAttribute("aria-level",o+""),d.tooltip&&l.setAttribute("title",p[d.tooltip]),p.hasOwnProperty(d.htmlAttributes)&&p[d.htmlAttributes]&&r.attributes(l,p[d.htmlAttributes]),p.hasOwnProperty(d.enabled)&&!1===p[d.enabled]&&l.classList.add(t.cssClass.disabled),p.hasOwnProperty(d.isVisible)&&!1===p[d.isVisible]&&(l.style.display="none"),b(p,d,s,c,l,o),p.hasOwnProperty(d.imageUrl)){var v={src:p[d.imageUrl]};p.hasOwnProperty(d.imageUrl)&&i.merge(v,p[d.imageAttributes]),r.prepend([r.createElement("img",{className:t.cssClass.image,attrs:v})],l.firstElementChild)}c.showIcon&&!c.template&&r.prepend([r.createElement("div",{className:t.cssClass.icon+" "+p[d.iconCss]})],l.firstElementChild)}u.push(l)}return L(u,c.listClass)}function c(e,i,s){if(e&&e.length){var n,o,a=Array.prototype.slice.call(e);for(o=i?d(i,a):!0===s?a.length:-1,n=a[o+(!0===s?-1:1)];n&&(!r.isVisible(n)||n.classList.contains(t.cssClass.disabled));)o+=!0===s?-1:1,n=a[o];return n}}function d(e,t){if(t&&e){var i=t;return i=Array.prototype.slice.call(t),i.indexOf(e)}}function u(e,t,i){void 0===i&&(i="None");var r=(new n.Query).group(t.groupBy);r=h(i,"key",r);var s=p(e,r);e=[];for(var o=0;o<s.length;o++){var a=s[o].items,l={};l[t.text]=s[o].key,l.isHeader=!0,l.items=a,e.push(l);for(var c=0;c<a.length;c++)e.push(a[c])}return e}function h(e,t,i){return void 0===i&&(i=new n.Query),"Ascending"===e?i.sortBy(t,"ascending",!0):"Descending"===e&&i.sortBy(t,"descending",!0),i}function p(e,t){return new n.DataManager(e).executeLocal(t)}function f(e,t){var r=i.extend({},C,t),s=r.fields,n=e.cloneNode(!0),o=[];n.classList.add("json-parent");var a=n.querySelectorAll(".json-parent>li");n.classList.remove("json-parent");for(var l=0;l<a.length;l++){var c=a[l],d=c.querySelector("ul"),u={};u[s.text]=c.firstChild.textContent,u[s.id]=y(),d&&(u[s.child]=f(d,t)),o.push(u)}return o}function v(e,i,n){for(var o=r.createElement("ul",{className:t.cssClass.ul,attrs:{role:"presentation"}}),a=s.compile(e),l=[],c=0,d=i;c<d.length;c++){var u=d[c],h=u.isHeader,p=r.createElement("li",{className:h?t.cssClass.group:t.cssClass.li,attrs:{role:"presentation"}});if(h)p.innerText=u[n.text];else{r.append(a(u),p);var f=u[n.value];p.setAttribute("data-value",f),p.setAttribute("role","option")}l.push(p)}return r.append(l,o),o}function m(e,t,i,n){for(var o=s.compile(e),a=i.groupBy,l={},c=0,d=n;c<d.length;c++){var u=d[c];l[a]=u.textContent,u.innerHTML="",r.append(o(l),u)}return n}function y(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}function b(e,s,n,o,a,c){var d=e[s.child],u=e[s.hasChildren];if(!i.isUndefined(d)&&(u=!0,a.classList.add(t.cssClass.hasChild),o.processSubChild)){var h=l(d,o,++c);a.appendChild(h)}o.expandCollapse&&u&&!o.template&&r.prepend([r.createElement("div",{className:"e-icons "+t.cssClass.collapsible})],a.querySelector("."+t.cssClass.textContent))}function g(e,i,s,n,o){var a=r.createElement("li",{className:(!0===o?t.cssClass.group:t.cssClass.li)+" "+s,attrs:{role:!0===o?"group":"presentation"}});return o?a.innerText=e:(a.setAttribute("data-value",i),a.setAttribute("role","option"),n&&r.append(n,a),a.appendChild(document.createTextNode(e))),a}function S(e,n,o,a,l){var c,d,u=e;"string"!=typeof e&&(u=e[n.text],c=e[n.id],d=!(!e.hasOwnProperty("isHeader")||!e.isHeader));var h=r.createElement("li",{className:(!0===d?t.cssClass.group:t.cssClass.li)+" "+o,attrs:{role:!0===d?"group":"presentation"}});if(c&&h.setAttribute("uID",c),d&&l&&l.groupTemplate){var p=s.compile(l.groupTemplate);r.append(p(e),h)}else if(!d&&l&&l.template){var p=s.compile(l.template);r.append(p(e),h)}else{var f=r.createElement("div",{className:t.cssClass.textContent});i.isUndefined(a)||r.append(a,h),f.appendChild(r.createElement("span",{className:t.cssClass.text,innerHTML:u,attrs:{role:"list-item"}})),h.appendChild(f)}return h}function L(e,i){var s=r.createElement("ul",{className:t.cssClass.ul+" "+i,attrs:{role:"presentation"}});return r.append(e,s),s}e.defaultMappedFields={id:"id",text:"text",value:"value",isChecked:"isChecked",enabled:"enabled",expanded:"expanded",iconCss:"icon",child:"child",isVisible:"isVisible",hasChildren:null,tooltip:null,htmlAttributes:null,imageAttributes:null,imageUrl:"imageUrl",groupBy:null};var C={showCheckBox:!1,showIcon:!1,expandCollapse:!1,fields:e.defaultMappedFields,listClass:"",itemClass:"",processSubChild:!1,sortOrder:"None",template:null,groupTemplate:null};e.createList=o,e.createListFromArray=a,e.createListFromJson=l,e.getSiblingLI=c,e.indexOf=d,e.groupDataSource=u,e.addSorting=h,e.getDataSource=p,e.createJsonFromElement=f,e.renderContentTemplate=v,e.renderGroupTemplate=m}(t.ListBase||(t.ListBase={}))}.apply(t,r))&&(e.exports=s)},function(e,t,i){var r,s;r=[i,t,i(10)],void 0!==(s=function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i)}.apply(t,r))&&(e.exports=s)}])}); |
@@ -226,3 +226,3 @@ import { extend, merge, isUndefined } from '@syncfusion/ej2-base/util'; | ||
else { | ||
li.innerHTML = compiledString(item); | ||
append(compiledString(item), li); | ||
var value = item[fields.value]; | ||
@@ -240,5 +240,9 @@ li.setAttribute('data-value', value); | ||
var compiledString = compile(groupTemplate); | ||
var category = fields.groupBy; | ||
var headerData = {}; | ||
for (var _i = 0, headerItems_1 = headerItems; _i < headerItems_1.length; _i++) { | ||
var header = headerItems_1[_i]; | ||
header.innerHTML = compiledString({ text: header.textContent }); | ||
headerData[category] = header.textContent; | ||
header.innerHTML = ''; | ||
append(compiledString(headerData), header); | ||
} | ||
@@ -305,7 +309,7 @@ return headerItems; | ||
var compiledString = compile(options.groupTemplate); | ||
li.innerHTML = compiledString(item); | ||
append(compiledString(item), li); | ||
} | ||
else if (!grpLI && options && options.template) { | ||
var compiledString = compile(options.template); | ||
li.innerHTML = compiledString(item); | ||
append(compiledString(item), li); | ||
} | ||
@@ -312,0 +316,0 @@ else { |
@@ -18,3 +18,3 @@ var __extends = (this && this.__extends) || (function () { | ||
import { merge, formatUnit } from '@syncfusion/ej2-base/util'; | ||
import { attributes, addClass, removeClass, createElement, prepend, closest } from '@syncfusion/ej2-base/dom'; | ||
import { attributes, addClass, removeClass, createElement, prepend, closest, remove } from '@syncfusion/ej2-base/dom'; | ||
import { Component, EventHandler, Property, Complex, Event, CreateBuilder } from '@syncfusion/ej2-base'; | ||
@@ -515,3 +515,3 @@ import { NotifyPropertyChanges, ChildProperty, KeyboardEvents } from '@syncfusion/ej2-base'; | ||
if (ul) { | ||
ul.remove(); | ||
remove(ul); | ||
this.setProperties({ dataSource: ListBase.createJsonFromElement(ul) }, true); | ||
@@ -518,0 +518,0 @@ this.localData = this.dataSource; |
@@ -13,29 +13,13 @@ { | ||
}, | ||
"D:\\release\\packages\\node_modules\\@syncfusion\\ej2" | ||
], | ||
[ | ||
{ | ||
"raw": "@syncfusion/ej2-lists@^1.0.0", | ||
"scope": "@syncfusion", | ||
"escapedName": "@syncfusion%2fej2-lists", | ||
"name": "@syncfusion/ej2-lists", | ||
"rawSpec": "^1.0.0", | ||
"spec": ">=1.0.0 <2.0.0", | ||
"type": "range" | ||
}, | ||
"C:\\Users\\ajithr\\Desktop\\npm\\node_modules\\@syncfusion\\ej2" | ||
"C:\\Users\\ajithr\\Desktop\\ej2-release\\node_modules\\@syncfusion\\ej2" | ||
] | ||
], | ||
"_from": "@syncfusion/ej2-lists@^1.0.0", | ||
"_id": "@syncfusion/ej2-lists@1.0.5", | ||
"_from": "@syncfusion/ej2-lists@*", | ||
"_id": "@syncfusion/ej2-lists@1.0.10", | ||
"_inCache": true, | ||
"_location": "/@syncfusion/ej2-lists", | ||
"_nodeVersion": "6.10.2", | ||
"_npmOperationalInternal": { | ||
"host": "packages-12-west.internal.npmjs.com", | ||
"tmp": "tmp/ej2-lists-1.0.5.tgz_1494508066496_0.19948332640342414" | ||
}, | ||
"_nodeVersion": "6.11.0", | ||
"_npmUser": { | ||
"name": "ajithr11", | ||
"email": "ajithr@syncfusion.com" | ||
"name": "ej2", | ||
"email": "pipeline@syncfusion.com" | ||
}, | ||
@@ -45,18 +29,19 @@ "_npmVersion": "3.10.10", | ||
"_requested": { | ||
"raw": "@syncfusion/ej2-lists@^1.0.0", | ||
"raw": "@syncfusion/ej2-lists@*", | ||
"scope": "@syncfusion", | ||
"escapedName": "@syncfusion%2fej2-lists", | ||
"name": "@syncfusion/ej2-lists", | ||
"rawSpec": "^1.0.0", | ||
"spec": ">=1.0.0 <2.0.0", | ||
"rawSpec": "*", | ||
"spec": "*", | ||
"type": "range" | ||
}, | ||
"_requiredBy": [ | ||
"/@syncfusion/ej2" | ||
"/@syncfusion/ej2", | ||
"/@syncfusion/ej2-ng-lists" | ||
], | ||
"_resolved": "https://registry.npmjs.org/@syncfusion/ej2-lists/-/ej2-lists-1.0.5.tgz", | ||
"_shasum": "0d2c55abe7c256481821915919ee7e6c39876642", | ||
"_resolved": "http://syncdeskn6525:8081/repository/ej2-production/@syncfusion/ej2-lists/-/ej2-lists-1.0.10.tgz", | ||
"_shasum": "3e6a0a22a0e63a9b49da5deb0a1923bdd56ff777", | ||
"_shrinkwrap": null, | ||
"_spec": "@syncfusion/ej2-lists@^1.0.0", | ||
"_where": "C:\\Users\\ajithr\\Desktop\\npm\\node_modules\\@syncfusion\\ej2", | ||
"_spec": "@syncfusion/ej2-lists@*", | ||
"_where": "C:\\Users\\ajithr\\Desktop\\ej2-release\\node_modules\\@syncfusion\\ej2", | ||
"author": { | ||
@@ -68,12 +53,5 @@ "name": "Syncfusion Inc." | ||
}, | ||
"config": { | ||
"ghooks": { | ||
"pre-commit": "gulp pre-commit", | ||
"pre-push": "gulp pre-push", | ||
"commit-msg": "gulp commit-msg" | ||
} | ||
}, | ||
"dependencies": { | ||
"@syncfusion/ej2-base": "^1.0.0", | ||
"@syncfusion/ej2-data": "^1.0.0" | ||
"@syncfusion/ej2-base": "^1.0.10", | ||
"@syncfusion/ej2-data": "^1.0.10" | ||
}, | ||
@@ -83,3 +61,2 @@ "description": "Syncfusion EJ2 Lists", | ||
"@types/chai": "^3.4.28", | ||
"@types/es6-promise": "0.0.28", | ||
"@types/jasmine": "^2.2.29", | ||
@@ -89,8 +66,7 @@ "@types/jasmine-ajax": "^3.1.27", | ||
}, | ||
"directories": {}, | ||
"dist": { | ||
"shasum": "0d2c55abe7c256481821915919ee7e6c39876642", | ||
"tarball": "https://registry.npmjs.org/@syncfusion/ej2-lists/-/ej2-lists-1.0.5.tgz" | ||
"shasum": "3e6a0a22a0e63a9b49da5deb0a1923bdd56ff777", | ||
"tarball": "http://syncdeskn6525:8081/repository/ej2-production/@syncfusion/ej2-lists/-/ej2-lists-1.0.10.tgz" | ||
}, | ||
"gitHead": "361733fe409c889cbc7037bff1597fef533f68b7", | ||
"gitHead": "9ed431190d0c38708b682287bb419857d550d66c", | ||
"homepage": "https://github.com/syncfusion/ej2-lists#readme", | ||
@@ -101,6 +77,5 @@ "keywords": [ | ||
"ej2-lists", | ||
"list", | ||
"data-list", | ||
"list-view", | ||
"listview" | ||
"list-data", | ||
"list" | ||
], | ||
@@ -110,8 +85,4 @@ "license": "SEE LICENSE IN license", | ||
{ | ||
"name": "ajithr11", | ||
"email": "ajithr@syncfusion.com" | ||
}, | ||
{ | ||
"name": "syncfusionorg", | ||
"email": "npmjs@syncfusion.com" | ||
"name": "ej2", | ||
"email": "pipeline@syncfusion.com" | ||
} | ||
@@ -122,3 +93,4 @@ ], | ||
"optionalDependencies": {}, | ||
"readme": "ERROR: No README data found!", | ||
"readme": "# Overview\r\n\r\nDisplays a list of items from an unordered list or custom data as customized flat or grouped lists. It comes with full documentation and support and is available under commercial and community licenses – please visit www.syncfusion.com to get started.\r\n\r\n## Resources\r\n[Demos](http://ej2.syncfusion.com/demos/#/listview/default.html) \n\n# 1.0.10\r\n## ListView\r\n\r\n### Bug Fixes\r\n-\tResolved rendering issue in IE11 browser.\r\n", | ||
"readmeFilename": "ReadMe.md", | ||
"repository": { | ||
@@ -133,3 +105,3 @@ "type": "git", | ||
}, | ||
"version": "1.0.8" | ||
} | ||
"version": "1.0.10" | ||
} |
# Overview | ||
Displays a list of items from an unordered list or custom data as customized flat or grouped lists. | ||
Displays a list of items from an unordered list or custom data as customized flat or grouped lists. It comes with full documentation and support and is available under commercial and community licenses – please visit www.syncfusion.com to get started. | ||
## Resources | ||
[Demos](http://ej2.syncfusion.com/demos/#/listview/default.html) | ||
[Demos](http://ej2.syncfusion.com/demos/#/listview/default.html) | ||
# 1.0.10 | ||
## ListView | ||
### Bug Fixes | ||
- Resolved rendering issue in IE11 browser. |
@@ -225,3 +225,3 @@ define(["require", "exports", "@syncfusion/ej2-base/util", "@syncfusion/ej2-base/dom", "@syncfusion/ej2-base", "@syncfusion/ej2-data"], function (require, exports, util_1, dom_1, ej2_base_1, ej2_data_1) { | ||
else { | ||
li.innerHTML = compiledString(item); | ||
dom_1.append(compiledString(item), li); | ||
var value = item[fields.value]; | ||
@@ -239,5 +239,9 @@ li.setAttribute('data-value', value); | ||
var compiledString = ej2_base_1.compile(groupTemplate); | ||
var category = fields.groupBy; | ||
var headerData = {}; | ||
for (var _i = 0, headerItems_1 = headerItems; _i < headerItems_1.length; _i++) { | ||
var header = headerItems_1[_i]; | ||
header.innerHTML = compiledString({ text: header.textContent }); | ||
headerData[category] = header.textContent; | ||
header.innerHTML = ''; | ||
dom_1.append(compiledString(headerData), header); | ||
} | ||
@@ -304,7 +308,7 @@ return headerItems; | ||
var compiledString = ej2_base_1.compile(options.groupTemplate); | ||
li.innerHTML = compiledString(item); | ||
dom_1.append(compiledString(item), li); | ||
} | ||
else if (!grpLI && options && options.template) { | ||
var compiledString = ej2_base_1.compile(options.template); | ||
li.innerHTML = compiledString(item); | ||
dom_1.append(compiledString(item), li); | ||
} | ||
@@ -311,0 +315,0 @@ else { |
@@ -40,3 +40,3 @@ import{ListView} from "./list-view"; | ||
*/ | ||
dataSource(value:Object[]|DataManager): BuilderProperties; | ||
dataSource(value:DataManager): BuilderProperties; | ||
/** | ||
@@ -75,5 +75,4 @@ * Specifies whether the ListView is enable or not. | ||
isDestroyed(value:boolean): BuilderProperties; | ||
localData(value:Object[]): BuilderProperties; | ||
/** | ||
* Overrides the global culture and localization value for this component. | ||
* Overrides the global culture and localization value for this component. Default Global culture is 'en-US' | ||
*/ | ||
@@ -80,0 +79,0 @@ locale(value:string): BuilderProperties; |
@@ -1,2 +0,2 @@ | ||
import { merge, formatUnit } from '@syncfusion/ej2-base/util'; import { attributes, addClass, removeClass, createElement, prepend, closest } from '@syncfusion/ej2-base/dom'; import { Component, EventHandler, BaseEventArgs, Property, Complex, Event, CreateBuilder } from '@syncfusion/ej2-base'; import { NotifyPropertyChanges, INotifyPropertyChanged, ChildProperty, KeyboardEvents } from '@syncfusion/ej2-base'; import { KeyboardEventArgs, EmitType } from '@syncfusion/ej2-base'; import { Animation, AnimationOptions, Effect, ripple, Touch, SwipeEventArgs } from '@syncfusion/ej2-base'; import { DataManager, Query } from '@syncfusion/ej2-data'; import { ListBase, ListBaseOptions, SortOrder } from '../common/list-base'; import { ListViewHelper } from './list-view-builder'; | ||
import { merge, formatUnit } from '@syncfusion/ej2-base/util'; import { attributes, addClass, removeClass, createElement, prepend, closest, remove } from '@syncfusion/ej2-base/dom'; import { Component, EventHandler, BaseEventArgs, Property, Complex, Event, CreateBuilder } from '@syncfusion/ej2-base'; import { NotifyPropertyChanges, INotifyPropertyChanged, ChildProperty, KeyboardEvents } from '@syncfusion/ej2-base'; import { KeyboardEventArgs, EmitType } from '@syncfusion/ej2-base'; import { Animation, AnimationOptions, Effect, ripple, Touch, SwipeEventArgs } from '@syncfusion/ej2-base'; import { DataManager, Query } from '@syncfusion/ej2-data'; import { ListBase, ListBaseOptions, SortOrder } from '../common/list-base'; import { ListViewHelper } from './list-view-builder'; | ||
import {AnimationSettings,SelectEventArgs} from "./list-view"; | ||
@@ -3,0 +3,0 @@ import {ComponentModel} from '@syncfusion/ej2-base'; |
@@ -510,3 +510,3 @@ var __extends = (this && this.__extends) || (function () { | ||
if (ul) { | ||
ul.remove(); | ||
dom_1.remove(ul); | ||
this.setProperties({ dataSource: list_base_1.ListBase.createJsonFromElement(ul) }, true); | ||
@@ -513,0 +513,0 @@ this.localData = this.dataSource; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1755479
4
41
16543
13
Updated@syncfusion/ej2-base@^1.0.10
Updated@syncfusion/ej2-data@^1.0.10