From a177f09b28f5867d771a6f50c5f0eac3b9d783db Mon Sep 17 00:00:00 2001 From: Sergey Pimenov Date: Sun, 19 May 2019 22:19:50 +0300 Subject: [PATCH] upd 4.2.43 --- build/js/metro.js | 2 +- build/js/metro.min.js | 2 +- docs/metro/js/metro.js | 2 +- docs/metro/js/metro.min.js | 2 +- package.json | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/build/js/metro.js b/build/js/metro.js index 091db4254..3d5752889 100644 --- a/build/js/metro.js +++ b/build/js/metro.js @@ -119,7 +119,7 @@ var isTouch = (('ontouchstart' in window) || (navigator.MaxTouchPoints > 0) || ( var Metro = { version: "4.2.43", - compileTime: "19/05/2019 22:17:12", + compileTime: "19/05/2019 22:19:38", buildNumber: "724", isTouchable: isTouch, fullScreenEnabled: document.fullscreenEnabled, diff --git a/build/js/metro.min.js b/build/js/metro.min.js index ce11d2fff..189fa6705 100644 --- a/build/js/metro.min.js +++ b/build/js/metro.min.js @@ -4,5 +4,5 @@ * Licensed under MIT */ -!function(e){"function"==typeof define&&define.amd?define(["jquery"],e):e(jQuery)}(function(t){"use strict";var _=t;if(void 0===t)throw new Error("Metro 4 requires jQuery!");if("MutationObserver"in window==!1)throw new Error("Metro 4 requires MutationObserver!");var e=_("meta[name='metro4:init']").attr("content"),n=_("meta[name='metro4:locale']").attr("content"),i=_("meta[name='metro4:week_start']").attr("content"),s=_("meta[name='metro4:date_format']").attr("content"),a=_("meta[name='metro4:date_format_input']").attr("content"),o=_("meta[name='metro4:animation_duration']").attr("content"),r=_("meta[name='metro4:callback_timeout']").attr("content"),l=_("meta[name='metro4:timeout']").attr("content"),c=_("meta[name='metro4:scroll_multiple']").attr("content"),d=_("meta[name='metro4:cloak']").attr("content"),h=_("meta[name='metro4:cloak_duration']").attr("content"),u=_("meta[name='metro4:about']").attr("content");void 0===window.METRO_SHOW_ABOUT&&(window.METRO_SHOW_ABOUT=void 0===u||JSON.parse(u));var p=_("meta[name='metro4:compile']").attr("content");void 0===window.METRO_SHOW_COMPILE_TIME&&(window.METRO_SHOW_COMPILE_TIME=void 0===p||JSON.parse(p)),void 0===window.METRO_INIT&&(window.METRO_INIT=void 0===e||JSON.parse(e)),void 0===window.METRO_DEBUG&&(window.METRO_DEBUG=!0),void 0===window.METRO_WEEK_START&&(window.METRO_WEEK_START=void 0!==i?parseInt(i):0),void 0===window.METRO_DATE_FORMAT&&(window.METRO_DATE_FORMAT=void 0!==s?s:"%Y-%m-%d"),void 0===window.METRO_DATE_FORMAT_INPUT&&(window.METRO_DATE_FORMAT_INPUT=void 0!==a?a:"%Y-%m-%d"),void 0===window.METRO_LOCALE&&(window.METRO_LOCALE=void 0!==n?n:"en-US"),void 0===window.METRO_ANIMATION_DURATION&&(window.METRO_ANIMATION_DURATION=void 0!==o?parseInt(o):300),void 0===window.METRO_CALLBACK_TIMEOUT&&(window.METRO_CALLBACK_TIMEOUT=void 0!==r?parseInt(r):500),void 0===window.METRO_TIMEOUT&&(window.METRO_TIMEOUT=void 0!==l?parseInt(l):2e3),void 0===window.METRO_SCROLL_MULTIPLE&&(window.METRO_SCROLL_MULTIPLE=void 0!==c?parseInt(c):20),void 0===window.METRO_CLOAK_REMOVE&&(window.METRO_CLOAK_REMOVE=void 0!==d?(""+d).toLowerCase():"fade"),void 0===window.METRO_CLOAK_DURATION&&(window.METRO_CLOAK_DURATION=void 0!==h?parseInt(h):500),void 0===window.METRO_HOTKEYS_FILTER_CONTENT_EDITABLE&&(window.METRO_HOTKEYS_FILTER_CONTENT_EDITABLE=!0),void 0===window.METRO_HOTKEYS_FILTER_INPUT_ACCEPTING_ELEMENTS&&(window.METRO_HOTKEYS_FILTER_INPUT_ACCEPTING_ELEMENTS=!0),void 0===window.METRO_HOTKEYS_FILTER_TEXT_INPUTS&&(window.METRO_HOTKEYS_FILTER_TEXT_INPUTS=!0),void 0===window.METRO_HOTKEYS_BUBBLE_UP&&(window.METRO_HOTKEYS_BUBBLE_UP=!1),void 0===window.METRO_THROWS&&(window.METRO_THROWS=!0),window.METRO_MEDIA=[],"function"!=typeof Object.create&&(Object.create=function(e){function t(){}return t.prototype=e,new t}),"function"!=typeof Object.values&&(Object.values=function(t){return Object.keys(t).map(function(e){return t[e]})}),"function"!=typeof window.setImmediate&&(window.setImmediate=function(e){return setTimeout(e,0)});var f="ontouchstart"in window||0>16)+t;255>8&255)+t;255":".","?":"/","|":"\\"},shiftNumsInverse:{"`":"~",1:"!",2:"@",3:"#",4:"$",5:"%",6:"^",7:"&",8:"*",9:"(",0:")","-":"_","=":"+",";":": ","'":'"',",":"<",".":">","/":"?","\\":"|"},textAcceptingInputTypes:["text","password","number","email","url","range","date","month","week","time","datetime","datetime-local","search","color","tel"],getKey:function(e){var t,n=e.keyCode,i=String.fromCharCode(n).toLowerCase();return t=e.shiftKey?S.shiftNums[i]?S.shiftNums[i]:i:void 0===S.specialKeys[n]?i:S.specialKeys[n],S.getModifier(e).length?S.getModifier(e).join("+")+"+"+t:t},getModifier:function(e){var t=[];return e.altKey&&t.push("alt"),e.ctrlKey&&t.push("ctrl"),e.shiftKey&&t.push("shift"),t}};_.fn.hotkey=function(n,i){return this.each(function(){_(this).on(C.events.keyup+".hotkey-method-"+n,function(e){var t=S.getKey(e);n===t&&z.exec(i,[e,t,n],this)})})},_(document).on(C.events.keyup+".hotkey-data",function(e){var t,n,i;METRO_HOTKEYS_FILTER_INPUT_ACCEPTING_ELEMENTS&&/textarea|input|select/i.test(e.target.nodeName)||METRO_HOTKEYS_FILTER_CONTENT_EDITABLE&&_(e.target).attr("contenteditable")||METRO_HOTKEYS_FILTER_TEXT_INPUTS&&-1>>4&15)+n.charAt(15&t);return i}function I(e){for(var t,n,i="",s=-1;++s>>6&31,128|63&t):t<=65535?i+=String.fromCharCode(224|t>>>12&15,128|t>>>6&63,128|63&t):t<=2097151&&(i+=String.fromCharCode(240|t>>>18&7,128|t>>>12&63,128|t>>>6&63,128|63&t));return i}function D(e){var t,n=new Array(e.length>>2);for(t=0;t>5]|=(255&e.charCodeAt(t/8))<>5]>>>n%32&255);return t}function A(e,t){e[t>>5]|=128<>>9<<4)]=t;for(var n=1732584193,i=-271733879,s=-1732584194,a=271733878,o=0;o>>32-t}(B(B(t,e),B(i,a)),s),n)}function P(e,t,n,i,s,a,o){return E(t&n|~t&i,e,t,s,a,o)}function N(e,t,n,i,s,a,o){return E(t&i|n&~i,e,t,s,a,o)}function R(e,t,n,i,s,a,o){return E(t^n^i,e,t,s,a,o)}function F(e,t,n,i,s,a,o){return E(n^(t|~i),e,t,s,a,o)}function B(e,t){var n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}Number.prototype.format=function(e,t,n,i){var s="\\d(?=(\\d{"+(t||3)+"})+"+(0").addClass("pagination").addClass(t.clsPagination).appendTo(i),0!==t.length&&-1!==t.rows){t.pages=Math.ceil(t.length/t.rows);var l=function(e,t,n){var i,s;return i=_("
  • ").addClass("page-item").addClass(t),(s=_("").addClass("page-link").html(e)).data("page",n),s.appendTo(i),i};if(a=l(t.prevTitle,"service prev-page","prev"),n.append(a),n.append(l(1,1===t.current?"active":"",1)),0===r||t.pages<=7)for(s=2;sr&&n.append(l("...","no-link",null))}else if(t.current<=t.pages&&t.current>t.pages-r+1)for(t.pages>r&&n.append(l("...","no-link",null)),s=t.pages-r+1;s"),s=0;s",n.endToken))),a=(i=new RegExp(o,"g")).exec(e);a;)d(e.slice(c,a.index))(a[1],!0),c=a.index+a[0].length,a=i.exec(e);d(e.substr(c,e.length-c)),l=(l+'return r.join(""); }').replace(/[\r\t\n]/g," ");try{s=new Function("obj",l).apply(t,[t])}catch(e){console.error("'"+e.message+"'"," in \n\nCode:\n",l,"\n")}return s}C.template=H;var z={isUrl:function(e){return/^(ftp|http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/|\/([\w#!:.?+=&%@\-\/]))?/.test(e)},isTag:function(e){return/^<\/?[\w\s="/.':;#-\/\?]+>/gi.test(e)},isColor:function(e){return/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)/i.test(e)},isEmbedObject:function(n){var i=!1;return _.each(["iframe","object","embed","video"],function(e,t){"string"==typeof n&&n.toLowerCase()===t?i=!0:void 0!==n.nodeType&&n.tagName.toLowerCase()===t&&(i=!0)}),i},isVideoUrl:function(e){return/youtu\.be|youtube|vimeo/gi.test(e)},isDate:function(e,t){return!("object"!=typeof e||!z.isFunc(e.getMonth))||"Invalid Date"!==(z.isValue(t)?String(e).toDate(t):String(new Date(e)))},isDateObject:function(e){return"object"==typeof e&&void 0!==e.getMonth},isInt:function(e){return Number(e)===e&&e%1==0},isFloat:function(e){return Number(e)===e&&e%1!=0},isTouchDevice:function(){return"ontouchstart"in window||0"+_(e)[0].outerHTML+""},embedUrl:function(e){return-1!==e.indexOf("youtu.be")&&(e="https://www.youtube.com/embed/"+e.split("/").pop()),"
    "},secondsToTime:function(e){var t=e%3600,n=t%60;return{h:Math.floor(e/3600),m:Math.floor(t/60),s:Math.ceil(n)}},hex2rgba:function(e,t){var n;if(t=isNaN(t)?1:t,/^#([A-Fa-f0-9]{3}){1,2}$/.test(e))return 3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n].join(",")+","+t+")";throw new Error("Hex2rgba error. Bad Hex value")},random:function(e,t){return Math.floor(Math.random()*(t-e+1)+e)},uniqueId:function(){var n=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=(n+16*Math.random())%16|0;return n=Math.floor(n/16),("x"===e?t:3&t|8).toString(16)})},elementId:function(e){return e+"-"+(new Date).getTime()+z.random(1,1e3)},secondsToFormattedString:function(e){var t=parseInt(e,10),n=Math.floor(t/3600),i=Math.floor((t-3600*n)/60),s=t-3600*n-60*i;return n<10&&(n="0"+n),i<10&&(i="0"+i),s<10&&(s="0"+s),[n,i,s].join(":")},callback:function(e,t,n){return z.exec(e,t,n)},func:function(e){return new Function("a",e)},exec:function(e,t,n){var i;if(null==e)return!1;var s=z.isFunc(e);!1===s&&(s=z.func(e));try{i=s.apply(n,t)}catch(e){if(!(i=null)===METRO_THROWS)throw e}return i},isOutsider:function(e){var t,n=_(e),i=n.clone();return i.removeAttr("data-role").css({visibility:"hidden",position:"absolute",display:"block"}),n.parent().append(i),t=i[0].getBoundingClientRect(),i.remove(),0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},inViewport:function(e){var t=z.rect(e);return 0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},rect:function(e){return"function"==typeof t&&e instanceof t&&(e=e[0]),e.getBoundingClientRect()},getCursorPosition:function(e,t){var n=z.rect(e);return{x:z.pageXY(t).x-n.left-window.pageXOffset,y:z.pageXY(t).y-n.top-window.pageYOffset}},getCursorPositionX:function(e,t){return z.getCursorPosition(e,t).x},getCursorPositionY:function(e,t){return z.getCursorPosition(e,t).y},objectLength:function(e){return Object.keys(e).length},percent:function(e,t,n){if(0===e)return 0;var i=100*t/e;return!0===n?Math.round(i):Math.round(100*i)/100},camelCase:function(e){return e.replace(/-([a-z])/g,function(e){return e[1].toUpperCase()})},dashedName:function(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()})},objectShift:function(e){var t=0;return _.each(e,function(e){0===t?t=e:e>16&255,t>>8&255,255&t]):[0,0,0]},hexColorToRgbA:function(e,t){var n;return/^#([A-Fa-f0-9]{3}){1,2}$/.test(e)?(3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n,t||1].join(",")+")"):"rgba(0,0,0,1)"},getInlineStyles:function(e){var t,n,i={},s=_(e)[0];for(t=0,n=s.style.length;t").addClass("circle").appendTo(n)}();break;case"square":!function(){for(e=0;e<4;e++)_("
    ").addClass("square").appendTo(n)}();break;case"cycle":_("
    ").addClass("cycle").appendTo(n);break;case"simple":_('').appendTo(n);break;default:!function(){for(e=0;e<5;e++)t=_("
    ").addClass("wrap").appendTo(n),_("
    ").addClass("circle").appendTo(t)}()}z.exec(this.options.onActivityCreate,[this.element]),n.fire("activitycreate")},changeAttribute:function(e){},destroy:function(){var e=this.element,t=this.options;e.html("").removeClass(t.style+"-style").removeClass("activity-"+t.type)}};C.plugin("activity",Y);var J={expand:!(C.activity={open:function(e){var t='
    ',n=e.text?'
    '+e.text+"
    ":"";return C.dialog.create({content:t+n,defaultAction:!1,clsContent:"d-flex flex-column flex-justify-center flex-align-center bg-transparent no-shadow w-auto",clsDialog:"no-border no-shadow bg-transparent global-dialog",autoHide:e.autoHide?e.autoHide:0,overlayClickClose:!0===e.overlayClickClose,overlayColor:e.overlayColor?e.overlayColor:"#000000",overlayAlpha:e.overlayAlpha?e.overlayAlpha:.5,clsOverlay:"global-overlay"})},close:function(e){C.dialog.close(e)}}),expandPoint:null,duration:100,onAppBarCreate:C.noop};C.appBarSetup=function(e){J=_.extend({},J,e)},window.metroAppBarSetup,C.appBarSetup(window.metroAppBarSetup);var G={init:function(e,t){return this.options=_.extend({},J,e),this.elem=t,this.element=_(t),this._setOptionsFromDOM(),this._create(),this},_setOptionsFromDOM:function(){var e=this.element,i=this.options;_.each(e.data(),function(t,n){if(t in i)try{i[t]=JSON.parse(n)}catch(e){i[t]=n}})},_create:function(){var e=this.element,t=this.options;this._createStructure(),this._createEvents(),z.exec(t.onAppBarCreate,[e]),e.fire("appbarcreate")},_createStructure:function(){var e,t,n=this.element,i=this.options,s=z.elementId("app-bar");if(n.addClass("app-bar"),0===(e=n.find(".hamburger")).length){e=_("
    ").appendTo(n),a[i.view[e]["index-view"]]=n}),t=0;t").addClass("table-inspector")).attr("for",this.element.attr("id")),_("
    "+a.inspectorTitle+"
    ").appendTo(e),t=_("
    ").addClass("table-wrap").appendTo(e),n=_("").addClass("table subcompact"),i=_("").appendTo(n),n.appendTo(t),this._createInspectorItems(i),s=_("
    ").appendTo(e),_("
    ").addClass(a.clsHeadRow).appendTo(o),_.each(this.service,function(){var e=[];i=_("").addClass(i.clsFooter);n.find("tfoot").remove(),0!==this.foots.length&&(e=_("").addClass(i.clsHeadRow).appendTo(s),_.each(this.foots,function(){t=_("").addClass(a.clsBodyRow)).data("original",v),m=t%2==0,p=_("").appendTo(f),g=[];if("function"==typeof y.tableToCSV){for(t=z.isValue(t)?t.toLowerCase():"all-filtered",n=z.isValue(n)?n:z.elementId("table")+"-export.csv",l=_(""),o=this.heads,a=0;a"),z.isValue(this.title)&&c.html(this.title),g[u.view[e]["index-view"]]=c)}),a=0;a"),o=r[s],a=0;a").html(this),g[u.view[e]["index-view"]]=c)}),a=0;a").addClass("tab-marker").addClass(t.clsMarker).appendTo(e)),this.openTab(0===i.length?n[0]:i[0])},_createEvents:function(){var a=this,o=this.element,r=this.options,l=o.find("li");o.on(C.events.click,"li",function(e){var t=_(this),n=o.find("li.active"),i=l.index(t)>l.index(n),s=t.children("a").attr("href");if(z.isValue(s)&&"#"===s[0]){if(t.hasClass("active"))return;if(t.hasClass("disabled"))return;if(!1===z.exec(r.onBeforeTabOpen,[t,s,i],this))return;if(!z.isValue(s))return;a.openTab(t,i),e.preventDefault()}}),o.on(C.events.scroll,function(){var e=this.scroll;this.scrollDir=this.scroll").addClass("tabs tabs-wrapper");if(z.isValue(n.attr("id"))||n.attr("id",z.elementId("tabs")),o.addClass(i.tabsPosition.replace(["-","_","+"]," ")),n.addClass("tabs-list"),"default"!==i.tabsType&&n.addClass("tabs-"+i.tabsType),a||(o.insertBefore(n),n.appendTo(o)),n.data("expanded",!1),e=_("
    ").addClass("expand-title"),o.prepend(e),0===(t=o.find(".hamburger")).length){t=_("
    "},embedUrl:function(e){return-1!==e.indexOf("youtu.be")&&(e="https://www.youtube.com/embed/"+e.split("/").pop()),"
    "},secondsToTime:function(e){var t=e%3600,n=t%60;return{h:Math.floor(e/3600),m:Math.floor(t/60),s:Math.ceil(n)}},hex2rgba:function(e,t){var n;if(t=isNaN(t)?1:t,/^#([A-Fa-f0-9]{3}){1,2}$/.test(e))return 3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n].join(",")+","+t+")";throw new Error("Hex2rgba error. Bad Hex value")},random:function(e,t){return Math.floor(Math.random()*(t-e+1)+e)},uniqueId:function(){var n=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=(n+16*Math.random())%16|0;return n=Math.floor(n/16),("x"===e?t:3&t|8).toString(16)})},elementId:function(e){return e+"-"+(new Date).getTime()+z.random(1,1e3)},secondsToFormattedString:function(e){var t=parseInt(e,10),n=Math.floor(t/3600),i=Math.floor((t-3600*n)/60),s=t-3600*n-60*i;return n<10&&(n="0"+n),i<10&&(i="0"+i),s<10&&(s="0"+s),[n,i,s].join(":")},callback:function(e,t,n){return z.exec(e,t,n)},func:function(e){return new Function("a",e)},exec:function(e,t,n){var i;if(null==e)return!1;var s=z.isFunc(e);!1===s&&(s=z.func(e));try{i=s.apply(n,t)}catch(e){if(!(i=null)===METRO_THROWS)throw e}return i},isOutsider:function(e){var t,n=_(e),i=n.clone();return i.removeAttr("data-role").css({visibility:"hidden",position:"absolute",display:"block"}),n.parent().append(i),t=i[0].getBoundingClientRect(),i.remove(),0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},inViewport:function(e){var t=z.rect(e);return 0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},rect:function(e){return"function"==typeof t&&e instanceof t&&(e=e[0]),e.getBoundingClientRect()},getCursorPosition:function(e,t){var n=z.rect(e);return{x:z.pageXY(t).x-n.left-window.pageXOffset,y:z.pageXY(t).y-n.top-window.pageYOffset}},getCursorPositionX:function(e,t){return z.getCursorPosition(e,t).x},getCursorPositionY:function(e,t){return z.getCursorPosition(e,t).y},objectLength:function(e){return Object.keys(e).length},percent:function(e,t,n){if(0===e)return 0;var i=100*t/e;return!0===n?Math.round(i):Math.round(100*i)/100},camelCase:function(e){return e.replace(/-([a-z])/g,function(e){return e[1].toUpperCase()})},dashedName:function(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()})},objectShift:function(e){var t=0;return _.each(e,function(e){0===t?t=e:e>16&255,t>>8&255,255&t]):[0,0,0]},hexColorToRgbA:function(e,t){var n;return/^#([A-Fa-f0-9]{3}){1,2}$/.test(e)?(3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n,t||1].join(",")+")"):"rgba(0,0,0,1)"},getInlineStyles:function(e){var t,n,i={},s=_(e)[0];for(t=0,n=s.style.length;t").addClass("circle").appendTo(n)}();break;case"square":!function(){for(e=0;e<4;e++)_("
    ").addClass("square").appendTo(n)}();break;case"cycle":_("
    ").addClass("cycle").appendTo(n);break;case"simple":_('').appendTo(n);break;default:!function(){for(e=0;e<5;e++)t=_("
    ").addClass("wrap").appendTo(n),_("
    ").addClass("circle").appendTo(t)}()}z.exec(this.options.onActivityCreate,[this.element]),n.fire("activitycreate")},changeAttribute:function(e){},destroy:function(){var e=this.element,t=this.options;e.html("").removeClass(t.style+"-style").removeClass("activity-"+t.type)}};C.plugin("activity",Y);var J={expand:!(C.activity={open:function(e){var t='
    ',n=e.text?'
    '+e.text+"
    ":"";return C.dialog.create({content:t+n,defaultAction:!1,clsContent:"d-flex flex-column flex-justify-center flex-align-center bg-transparent no-shadow w-auto",clsDialog:"no-border no-shadow bg-transparent global-dialog",autoHide:e.autoHide?e.autoHide:0,overlayClickClose:!0===e.overlayClickClose,overlayColor:e.overlayColor?e.overlayColor:"#000000",overlayAlpha:e.overlayAlpha?e.overlayAlpha:.5,clsOverlay:"global-overlay"})},close:function(e){C.dialog.close(e)}}),expandPoint:null,duration:100,onAppBarCreate:C.noop};C.appBarSetup=function(e){J=_.extend({},J,e)},window.metroAppBarSetup,C.appBarSetup(window.metroAppBarSetup);var G={init:function(e,t){return this.options=_.extend({},J,e),this.elem=t,this.element=_(t),this._setOptionsFromDOM(),this._create(),this},_setOptionsFromDOM:function(){var e=this.element,i=this.options;_.each(e.data(),function(t,n){if(t in i)try{i[t]=JSON.parse(n)}catch(e){i[t]=n}})},_create:function(){var e=this.element,t=this.options;this._createStructure(),this._createEvents(),z.exec(t.onAppBarCreate,[e]),e.fire("appbarcreate")},_createStructure:function(){var e,t,n=this.element,i=this.options,s=z.elementId("app-bar");if(n.addClass("app-bar"),0===(e=n.find(".hamburger")).length){e=_("
    ").appendTo(t),z.isValue(this.title)&&i.html(this.title),z.isValue(this.size)&&i.css({width:this.size}),z.isValue(this.cls)&&e.push(this.cls),e.push(a.clsHeadCell),i.addClass(e.join(" "))}),n=this.heads,e=0;e")).data("index",e),z.isValue(t.title)&&i.html(t.title),z.isValue(t.format)&&i.attr("data-format",t.format),z.isValue(t.name)&&i.attr("data-name",t.name),z.isValue(t.colspan)&&i.attr("colspan",t.colspan),z.isValue(l[e].size)&&i.css({width:l[e].size}),!0===t.sortable&&(n.push("sortable-column"),z.isValue(t.sortDir)&&n.push("sort-"+t.sortDir)),z.isValue(t.cls)&&n.push(t.cls),!1===z.bool(l[e].show)&&n.push("hidden"),n.push(a.clsHeadCell),z.bool(l[e].show)&&z.arrayDelete(n,"hidden"),i.addClass(n.join(" ")),r[l[e]["index-view"]]=i}),e=0;e").addClass(this.options.clsBody).insertAfter(e)},_createTableFooter:function(){var e,t,n=this.element,i=this.options,s=_("
    ").appendTo(e),void 0!==this.title&&t.html(this.title),void 0!==this.name&&t.addClass("foot-column-name-"+this.name),void 0!==this.cls&&t.addClass(this.cls),z.isValue(this.colspan)&&t.attr("colspan",this.colspan),t.appendTo(e)})),n.append(s)},_createTopBlock:function(){var e,t,n,i=this,s=this.element,a=this.options,o=_("
    ").addClass("table-top").addClass(a.clsTableTop).insertBefore(s.parent());return(e=z.isValue(this.wrapperSearch)?this.wrapperSearch:_("
    ").addClass("table-search-block").addClass(a.clsSearch).appendTo(o)).addClass(a.clsSearch),_("").attr("type","text").appendTo(e).input({prepend:a.tableSearchTitle}),!0!==a.showSearch&&e.hide(),(t=z.isValue(this.wrapperRows)?this.wrapperRows:_("
    ").addClass("table-rows-block").appendTo(o)).addClass(a.clsRowsCount),n=_("
    ").html(t+1),void 0!==i.service[0].clsColumn&&p.addClass(i.service[0].clsColumn),p.appendTo(u),p=_(""),f="checkbox"===a.checkType?_(""):_(""),z.isValue(c)&&Array.isArray(c)&&-1"),_("
    ").addClass("cell-wrapper").addClass(a.clsCellWrapper).html(t).appendTo(p)):p=_("
    ").html(t),p.addClass(a.clsBodyCell),z.isValue(i.heads[e].clsColumn)&&p.addClass(i.heads[e].clsColumn),!1===z.bool(d[e].show)&&p.addClass("hidden"),z.bool(d[e].show)&&p.removeClass("hidden"),p.data("original",this),g[d[e]["index-view"]]=p,z.exec(a.onDrawCell,[p,t,e,i.heads[e],v],p[0]),s.fire("drawcell",{td:p,val:t,cellIndex:e,head:i.heads[e],items:v})}),h=0;hthis.pagesCount))return this._draw(),this;this.currentPage=this.pagesCount}},prev:function(){if(0!==this.items.length){if(this.currentPage--,0!==this.currentPage)return this._draw(),this;this.currentPage=1}},first:function(){if(0!==this.items.length)return this.currentPage=1,this._draw(),this},last:function(){if(0!==this.items.length)return this.currentPage=this.pagesCount,this._draw(),this},page:function(e){return e<=0&&(e=1),e>this.pagesCount&&(e=this.pagesCount),this.currentPage=e,this._draw(),this},addFilter:function(e,t){var n,i=null,s=z.isFunc(e);if(!1!==s){for(n=0;n").appendTo(f),v=_("
    ").html("").appendTo(n),_("").html(this.title).appendTo(n),_("").html("").appendTo(n),_("").html("").appendTo(n),a[i.view[e]["index-view"]]=n}),t=0;t").addClass("table-inspector")).attr("for",this.element.attr("id")),_("
    "+a.inspectorTitle+"
    ").appendTo(e),t=_("
    ").addClass("table-wrap").appendTo(e),n=_("").addClass("table subcompact"),i=_("").appendTo(n),n.appendTo(t),this._createInspectorItems(i),s=_("
    ").appendTo(e),_("
    ").addClass(a.clsHeadRow).appendTo(o),_.each(this.service,function(){var e=[];i=_("").addClass(i.clsFooter);n.find("tfoot").remove(),0!==this.foots.length&&(e=_("").addClass(i.clsHeadRow).appendTo(s),_.each(this.foots,function(){t=_("").addClass(a.clsBodyRow)).data("original",v),m=t%2==0,p=_("").appendTo(f),g=[];if("function"==typeof y.tableToCSV){for(t=z.isValue(t)?t.toLowerCase():"all-filtered",n=z.isValue(n)?n:z.elementId("table")+"-export.csv",l=_(""),o=this.heads,a=0;a"),z.isValue(this.title)&&c.html(this.title),g[u.view[e]["index-view"]]=c)}),a=0;a"),o=r[s],a=0;a").html(this),g[u.view[e]["index-view"]]=c)}),a=0;a").addClass("tab-marker").addClass(t.clsMarker).appendTo(e)),this.openTab(0===i.length?n[0]:i[0])},_createEvents:function(){var a=this,o=this.element,r=this.options,l=o.find("li");o.on(C.events.click,"li",function(e){var t=_(this),n=o.find("li.active"),i=l.index(t)>l.index(n),s=t.children("a").attr("href");if(z.isValue(s)&&"#"===s[0]){if(t.hasClass("active"))return;if(t.hasClass("disabled"))return;if(!1===z.exec(r.onBeforeTabOpen,[t,s,i],this))return;if(!z.isValue(s))return;a.openTab(t,i),e.preventDefault()}}),o.on(C.events.scroll,function(){var e=this.scroll;this.scrollDir=this.scroll").addClass("tabs tabs-wrapper");if(z.isValue(n.attr("id"))||n.attr("id",z.elementId("tabs")),o.addClass(i.tabsPosition.replace(["-","_","+"]," ")),n.addClass("tabs-list"),"default"!==i.tabsType&&n.addClass("tabs-"+i.tabsType),a||(o.insertBefore(n),n.appendTo(o)),n.data("expanded",!1),e=_("
    ").addClass("expand-title"),o.prepend(e),0===(t=o.find(".hamburger")).length){t=_("
    "},embedUrl:function(e){return-1!==e.indexOf("youtu.be")&&(e="https://www.youtube.com/embed/"+e.split("/").pop()),"
    "},secondsToTime:function(e){var t=e%3600,n=t%60;return{h:Math.floor(e/3600),m:Math.floor(t/60),s:Math.ceil(n)}},hex2rgba:function(e,t){var n;if(t=isNaN(t)?1:t,/^#([A-Fa-f0-9]{3}){1,2}$/.test(e))return 3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n].join(",")+","+t+")";throw new Error("Hex2rgba error. Bad Hex value")},random:function(e,t){return Math.floor(Math.random()*(t-e+1)+e)},uniqueId:function(){var n=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=(n+16*Math.random())%16|0;return n=Math.floor(n/16),("x"===e?t:3&t|8).toString(16)})},elementId:function(e){return e+"-"+(new Date).getTime()+z.random(1,1e3)},secondsToFormattedString:function(e){var t=parseInt(e,10),n=Math.floor(t/3600),i=Math.floor((t-3600*n)/60),s=t-3600*n-60*i;return n<10&&(n="0"+n),i<10&&(i="0"+i),s<10&&(s="0"+s),[n,i,s].join(":")},callback:function(e,t,n){return z.exec(e,t,n)},func:function(e){return new Function("a",e)},exec:function(e,t,n){var i;if(null==e)return!1;var s=z.isFunc(e);!1===s&&(s=z.func(e));try{i=s.apply(n,t)}catch(e){if(!(i=null)===METRO_THROWS)throw e}return i},isOutsider:function(e){var t,n=_(e),i=n.clone();return i.removeAttr("data-role").css({visibility:"hidden",position:"absolute",display:"block"}),n.parent().append(i),t=i[0].getBoundingClientRect(),i.remove(),0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},inViewport:function(e){var t=z.rect(e);return 0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},rect:function(e){return"function"==typeof t&&e instanceof t&&(e=e[0]),e.getBoundingClientRect()},getCursorPosition:function(e,t){var n=z.rect(e);return{x:z.pageXY(t).x-n.left-window.pageXOffset,y:z.pageXY(t).y-n.top-window.pageYOffset}},getCursorPositionX:function(e,t){return z.getCursorPosition(e,t).x},getCursorPositionY:function(e,t){return z.getCursorPosition(e,t).y},objectLength:function(e){return Object.keys(e).length},percent:function(e,t,n){if(0===e)return 0;var i=100*t/e;return!0===n?Math.round(i):Math.round(100*i)/100},camelCase:function(e){return e.replace(/-([a-z])/g,function(e){return e[1].toUpperCase()})},dashedName:function(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()})},objectShift:function(e){var t=0;return _.each(e,function(e){0===t?t=e:e>16&255,t>>8&255,255&t]):[0,0,0]},hexColorToRgbA:function(e,t){var n;return/^#([A-Fa-f0-9]{3}){1,2}$/.test(e)?(3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n,t||1].join(",")+")"):"rgba(0,0,0,1)"},getInlineStyles:function(e){var t,n,i={},s=_(e)[0];for(t=0,n=s.style.length;t").addClass("circle").appendTo(n)}();break;case"square":!function(){for(e=0;e<4;e++)_("
    ").addClass("square").appendTo(n)}();break;case"cycle":_("
    ").addClass("cycle").appendTo(n);break;case"simple":_('').appendTo(n);break;default:!function(){for(e=0;e<5;e++)t=_("
    ").addClass("wrap").appendTo(n),_("
    ").addClass("circle").appendTo(t)}()}z.exec(this.options.onActivityCreate,[this.element]),n.fire("activitycreate")},changeAttribute:function(e){},destroy:function(){var e=this.element,t=this.options;e.html("").removeClass(t.style+"-style").removeClass("activity-"+t.type)}};C.plugin("activity",Y);var J={expand:!(C.activity={open:function(e){var t='
    ',n=e.text?'
    '+e.text+"
    ":"";return C.dialog.create({content:t+n,defaultAction:!1,clsContent:"d-flex flex-column flex-justify-center flex-align-center bg-transparent no-shadow w-auto",clsDialog:"no-border no-shadow bg-transparent global-dialog",autoHide:e.autoHide?e.autoHide:0,overlayClickClose:!0===e.overlayClickClose,overlayColor:e.overlayColor?e.overlayColor:"#000000",overlayAlpha:e.overlayAlpha?e.overlayAlpha:.5,clsOverlay:"global-overlay"})},close:function(e){C.dialog.close(e)}}),expandPoint:null,duration:100,onAppBarCreate:C.noop};C.appBarSetup=function(e){J=_.extend({},J,e)},window.metroAppBarSetup,C.appBarSetup(window.metroAppBarSetup);var G={init:function(e,t){return this.options=_.extend({},J,e),this.elem=t,this.element=_(t),this._setOptionsFromDOM(),this._create(),this},_setOptionsFromDOM:function(){var e=this.element,i=this.options;_.each(e.data(),function(t,n){if(t in i)try{i[t]=JSON.parse(n)}catch(e){i[t]=n}})},_create:function(){var e=this.element,t=this.options;this._createStructure(),this._createEvents(),z.exec(t.onAppBarCreate,[e]),e.fire("appbarcreate")},_createStructure:function(){var e,t,n=this.element,i=this.options,s=z.elementId("app-bar");if(n.addClass("app-bar"),0===(e=n.find(".hamburger")).length){e=_("
    ").appendTo(t),z.isValue(this.title)&&i.html(this.title),z.isValue(this.size)&&i.css({width:this.size}),z.isValue(this.cls)&&e.push(this.cls),e.push(a.clsHeadCell),i.addClass(e.join(" "))}),n=this.heads,e=0;e")).data("index",e),z.isValue(t.title)&&i.html(t.title),z.isValue(t.format)&&i.attr("data-format",t.format),z.isValue(t.name)&&i.attr("data-name",t.name),z.isValue(t.colspan)&&i.attr("colspan",t.colspan),z.isValue(l[e].size)&&i.css({width:l[e].size}),!0===t.sortable&&(n.push("sortable-column"),z.isValue(t.sortDir)&&n.push("sort-"+t.sortDir)),z.isValue(t.cls)&&n.push(t.cls),!1===z.bool(l[e].show)&&n.push("hidden"),n.push(a.clsHeadCell),z.bool(l[e].show)&&z.arrayDelete(n,"hidden"),i.addClass(n.join(" ")),r[l[e]["index-view"]]=i}),e=0;e").addClass(this.options.clsBody).insertAfter(e)},_createTableFooter:function(){var e,t,n=this.element,i=this.options,s=_("
    ").appendTo(e),void 0!==this.title&&t.html(this.title),void 0!==this.name&&t.addClass("foot-column-name-"+this.name),void 0!==this.cls&&t.addClass(this.cls),z.isValue(this.colspan)&&t.attr("colspan",this.colspan),t.appendTo(e)})),n.append(s)},_createTopBlock:function(){var e,t,n,i=this,s=this.element,a=this.options,o=_("
    ").addClass("table-top").addClass(a.clsTableTop).insertBefore(s.parent());return(e=z.isValue(this.wrapperSearch)?this.wrapperSearch:_("
    ").addClass("table-search-block").addClass(a.clsSearch).appendTo(o)).addClass(a.clsSearch),_("").attr("type","text").appendTo(e).input({prepend:a.tableSearchTitle}),!0!==a.showSearch&&e.hide(),(t=z.isValue(this.wrapperRows)?this.wrapperRows:_("
    ").addClass("table-rows-block").appendTo(o)).addClass(a.clsRowsCount),n=_("
    ").html(t+1),void 0!==i.service[0].clsColumn&&p.addClass(i.service[0].clsColumn),p.appendTo(u),p=_(""),f="checkbox"===a.checkType?_(""):_(""),z.isValue(c)&&Array.isArray(c)&&-1"),_("
    ").addClass("cell-wrapper").addClass(a.clsCellWrapper).html(t).appendTo(p)):p=_("
    ").html(t),p.addClass(a.clsBodyCell),z.isValue(i.heads[e].clsColumn)&&p.addClass(i.heads[e].clsColumn),!1===z.bool(d[e].show)&&p.addClass("hidden"),z.bool(d[e].show)&&p.removeClass("hidden"),p.data("original",this),g[d[e]["index-view"]]=p,z.exec(a.onDrawCell,[p,t,e,i.heads[e],v],p[0]),s.fire("drawcell",{td:p,val:t,cellIndex:e,head:i.heads[e],items:v})}),h=0;hthis.pagesCount))return this._draw(),this;this.currentPage=this.pagesCount}},prev:function(){if(0!==this.items.length){if(this.currentPage--,0!==this.currentPage)return this._draw(),this;this.currentPage=1}},first:function(){if(0!==this.items.length)return this.currentPage=1,this._draw(),this},last:function(){if(0!==this.items.length)return this.currentPage=this.pagesCount,this._draw(),this},page:function(e){return e<=0&&(e=1),e>this.pagesCount&&(e=this.pagesCount),this.currentPage=e,this._draw(),this},addFilter:function(e,t){var n,i=null,s=z.isFunc(e);if(!1!==s){for(n=0;n").appendTo(f),v=_("
    ").html("").appendTo(n),_("").html(this.title).appendTo(n),_("").html("").appendTo(n),_("").html("").appendTo(n),a[i.view[e]["index-view"]]=n}),t=0;t").addClass("table-inspector")).attr("for",this.element.attr("id")),_("
    "+a.inspectorTitle+"
    ").appendTo(e),t=_("
    ").addClass("table-wrap").appendTo(e),n=_("").addClass("table subcompact"),i=_("").appendTo(n),n.appendTo(t),this._createInspectorItems(i),s=_("
    ").appendTo(e),_("
    ").addClass(a.clsHeadRow).appendTo(o),_.each(this.service,function(){var e=[];i=_("").addClass(i.clsFooter);n.find("tfoot").remove(),0!==this.foots.length&&(e=_("").addClass(i.clsHeadRow).appendTo(s),_.each(this.foots,function(){t=_("").addClass(a.clsBodyRow)).data("original",v),m=t%2==0,p=_("").appendTo(f),g=[];if("function"==typeof y.tableToCSV){for(t=z.isValue(t)?t.toLowerCase():"all-filtered",n=z.isValue(n)?n:z.elementId("table")+"-export.csv",l=_(""),o=this.heads,a=0;a"),z.isValue(this.title)&&c.html(this.title),g[u.view[e]["index-view"]]=c)}),a=0;a"),o=r[s],a=0;a").html(this),g[u.view[e]["index-view"]]=c)}),a=0;a").addClass("tab-marker").addClass(t.clsMarker).appendTo(e)),this.openTab(0===i.length?n[0]:i[0])},_createEvents:function(){var a=this,o=this.element,r=this.options,l=o.find("li");o.on(C.events.click,"li",function(e){var t=_(this),n=o.find("li.active"),i=l.index(t)>l.index(n),s=t.children("a").attr("href");if(z.isValue(s)&&"#"===s[0]){if(t.hasClass("active"))return;if(t.hasClass("disabled"))return;if(!1===z.exec(r.onBeforeTabOpen,[t,s,i],this))return;if(!z.isValue(s))return;a.openTab(t,i),e.preventDefault()}}),o.on(C.events.scroll,function(){var e=this.scroll;this.scrollDir=this.scroll").addClass("tabs tabs-wrapper");if(z.isValue(n.attr("id"))||n.attr("id",z.elementId("tabs")),o.addClass(i.tabsPosition.replace(["-","_","+"]," ")),n.addClass("tabs-list"),"default"!==i.tabsType&&n.addClass("tabs-"+i.tabsType),a||(o.insertBefore(n),n.appendTo(o)),n.data("expanded",!1),e=_("
    ").addClass("expand-title"),o.prepend(e),0===(t=o.find(".hamburger")).length){t=_("
    "},embedUrl:function(e){return-1!==e.indexOf("youtu.be")&&(e="https://www.youtube.com/embed/"+e.split("/").pop()),"
    "},secondsToTime:function(e){var t=e%3600,n=t%60;return{h:Math.floor(e/3600),m:Math.floor(t/60),s:Math.ceil(n)}},hex2rgba:function(e,t){var n;if(t=isNaN(t)?1:t,/^#([A-Fa-f0-9]{3}){1,2}$/.test(e))return 3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n].join(",")+","+t+")";throw new Error("Hex2rgba error. Bad Hex value")},random:function(e,t){return Math.floor(Math.random()*(t-e+1)+e)},uniqueId:function(){var n=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=(n+16*Math.random())%16|0;return n=Math.floor(n/16),("x"===e?t:3&t|8).toString(16)})},elementId:function(e){return e+"-"+(new Date).getTime()+z.random(1,1e3)},secondsToFormattedString:function(e){var t=parseInt(e,10),n=Math.floor(t/3600),i=Math.floor((t-3600*n)/60),s=t-3600*n-60*i;return n<10&&(n="0"+n),i<10&&(i="0"+i),s<10&&(s="0"+s),[n,i,s].join(":")},callback:function(e,t,n){return z.exec(e,t,n)},func:function(e){return new Function("a",e)},exec:function(e,t,n){var i;if(null==e)return!1;var s=z.isFunc(e);!1===s&&(s=z.func(e));try{i=s.apply(n,t)}catch(e){if(!(i=null)===METRO_THROWS)throw e}return i},isOutsider:function(e){var t,n=_(e),i=n.clone();return i.removeAttr("data-role").css({visibility:"hidden",position:"absolute",display:"block"}),n.parent().append(i),t=i[0].getBoundingClientRect(),i.remove(),0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},inViewport:function(e){var t=z.rect(e);return 0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)},rect:function(e){return"function"==typeof t&&e instanceof t&&(e=e[0]),e.getBoundingClientRect()},getCursorPosition:function(e,t){var n=z.rect(e);return{x:z.pageXY(t).x-n.left-window.pageXOffset,y:z.pageXY(t).y-n.top-window.pageYOffset}},getCursorPositionX:function(e,t){return z.getCursorPosition(e,t).x},getCursorPositionY:function(e,t){return z.getCursorPosition(e,t).y},objectLength:function(e){return Object.keys(e).length},percent:function(e,t,n){if(0===e)return 0;var i=100*t/e;return!0===n?Math.round(i):Math.round(100*i)/100},camelCase:function(e){return e.replace(/-([a-z])/g,function(e){return e[1].toUpperCase()})},dashedName:function(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()})},objectShift:function(e){var t=0;return _.each(e,function(e){0===t?t=e:e>16&255,t>>8&255,255&t]):[0,0,0]},hexColorToRgbA:function(e,t){var n;return/^#([A-Fa-f0-9]{3}){1,2}$/.test(e)?(3===(n=e.substring(1).split("")).length&&(n=[n[0],n[0],n[1],n[1],n[2],n[2]]),"rgba("+[(n="0x"+n.join(""))>>16&255,n>>8&255,255&n,t||1].join(",")+")"):"rgba(0,0,0,1)"},getInlineStyles:function(e){var t,n,i={},s=_(e)[0];for(t=0,n=s.style.length;t").addClass("circle").appendTo(n)}();break;case"square":!function(){for(e=0;e<4;e++)_("
    ").addClass("square").appendTo(n)}();break;case"cycle":_("
    ").addClass("cycle").appendTo(n);break;case"simple":_('').appendTo(n);break;default:!function(){for(e=0;e<5;e++)t=_("
    ").addClass("wrap").appendTo(n),_("
    ").addClass("circle").appendTo(t)}()}z.exec(this.options.onActivityCreate,[this.element]),n.fire("activitycreate")},changeAttribute:function(e){},destroy:function(){var e=this.element,t=this.options;e.html("").removeClass(t.style+"-style").removeClass("activity-"+t.type)}};C.plugin("activity",Y);var J={expand:!(C.activity={open:function(e){var t='
    ',n=e.text?'
    '+e.text+"
    ":"";return C.dialog.create({content:t+n,defaultAction:!1,clsContent:"d-flex flex-column flex-justify-center flex-align-center bg-transparent no-shadow w-auto",clsDialog:"no-border no-shadow bg-transparent global-dialog",autoHide:e.autoHide?e.autoHide:0,overlayClickClose:!0===e.overlayClickClose,overlayColor:e.overlayColor?e.overlayColor:"#000000",overlayAlpha:e.overlayAlpha?e.overlayAlpha:.5,clsOverlay:"global-overlay"})},close:function(e){C.dialog.close(e)}}),expandPoint:null,duration:100,onAppBarCreate:C.noop};C.appBarSetup=function(e){J=_.extend({},J,e)},window.metroAppBarSetup,C.appBarSetup(window.metroAppBarSetup);var G={init:function(e,t){return this.options=_.extend({},J,e),this.elem=t,this.element=_(t),this._setOptionsFromDOM(),this._create(),this},_setOptionsFromDOM:function(){var e=this.element,i=this.options;_.each(e.data(),function(t,n){if(t in i)try{i[t]=JSON.parse(n)}catch(e){i[t]=n}})},_create:function(){var e=this.element,t=this.options;this._createStructure(),this._createEvents(),z.exec(t.onAppBarCreate,[e]),e.fire("appbarcreate")},_createStructure:function(){var e,t,n=this.element,i=this.options,s=z.elementId("app-bar");if(n.addClass("app-bar"),0===(e=n.find(".hamburger")).length){e=_("
    ").appendTo(t),z.isValue(this.title)&&i.html(this.title),z.isValue(this.size)&&i.css({width:this.size}),z.isValue(this.cls)&&e.push(this.cls),e.push(a.clsHeadCell),i.addClass(e.join(" "))}),n=this.heads,e=0;e")).data("index",e),z.isValue(t.title)&&i.html(t.title),z.isValue(t.format)&&i.attr("data-format",t.format),z.isValue(t.name)&&i.attr("data-name",t.name),z.isValue(t.colspan)&&i.attr("colspan",t.colspan),z.isValue(l[e].size)&&i.css({width:l[e].size}),!0===t.sortable&&(n.push("sortable-column"),z.isValue(t.sortDir)&&n.push("sort-"+t.sortDir)),z.isValue(t.cls)&&n.push(t.cls),!1===z.bool(l[e].show)&&n.push("hidden"),n.push(a.clsHeadCell),z.bool(l[e].show)&&z.arrayDelete(n,"hidden"),i.addClass(n.join(" ")),r[l[e]["index-view"]]=i}),e=0;e").addClass(this.options.clsBody).insertAfter(e)},_createTableFooter:function(){var e,t,n=this.element,i=this.options,s=_("
    ").appendTo(e),void 0!==this.title&&t.html(this.title),void 0!==this.name&&t.addClass("foot-column-name-"+this.name),void 0!==this.cls&&t.addClass(this.cls),z.isValue(this.colspan)&&t.attr("colspan",this.colspan),t.appendTo(e)})),n.append(s)},_createTopBlock:function(){var e,t,n,i=this,s=this.element,a=this.options,o=_("
    ").addClass("table-top").addClass(a.clsTableTop).insertBefore(s.parent());return(e=z.isValue(this.wrapperSearch)?this.wrapperSearch:_("
    ").addClass("table-search-block").addClass(a.clsSearch).appendTo(o)).addClass(a.clsSearch),_("").attr("type","text").appendTo(e).input({prepend:a.tableSearchTitle}),!0!==a.showSearch&&e.hide(),(t=z.isValue(this.wrapperRows)?this.wrapperRows:_("
    ").addClass("table-rows-block").appendTo(o)).addClass(a.clsRowsCount),n=_("
    ").html(t+1),void 0!==i.service[0].clsColumn&&p.addClass(i.service[0].clsColumn),p.appendTo(u),p=_(""),f="checkbox"===a.checkType?_(""):_(""),z.isValue(c)&&Array.isArray(c)&&-1"),_("
    ").addClass("cell-wrapper").addClass(a.clsCellWrapper).html(t).appendTo(p)):p=_("
    ").html(t),p.addClass(a.clsBodyCell),z.isValue(i.heads[e].clsColumn)&&p.addClass(i.heads[e].clsColumn),!1===z.bool(d[e].show)&&p.addClass("hidden"),z.bool(d[e].show)&&p.removeClass("hidden"),p.data("original",this),g[d[e]["index-view"]]=p,z.exec(a.onDrawCell,[p,t,e,i.heads[e],v],p[0]),s.fire("drawcell",{td:p,val:t,cellIndex:e,head:i.heads[e],items:v})}),h=0;hthis.pagesCount))return this._draw(),this;this.currentPage=this.pagesCount}},prev:function(){if(0!==this.items.length){if(this.currentPage--,0!==this.currentPage)return this._draw(),this;this.currentPage=1}},first:function(){if(0!==this.items.length)return this.currentPage=1,this._draw(),this},last:function(){if(0!==this.items.length)return this.currentPage=this.pagesCount,this._draw(),this},page:function(e){return e<=0&&(e=1),e>this.pagesCount&&(e=this.pagesCount),this.currentPage=e,this._draw(),this},addFilter:function(e,t){var n,i=null,s=z.isFunc(e);if(!1!==s){for(n=0;n").appendTo(f),v=_("
    ").html("").appendTo(n),_("").html(this.title).appendTo(n),_("").html("").appendTo(n),_("").html("").appendTo(n),a[i.view[e]["index-view"]]=n}),t=0;t").addClass("table-inspector")).attr("for",this.element.attr("id")),_("
    "+a.inspectorTitle+"
    ").appendTo(e),t=_("
    ").addClass("table-wrap").appendTo(e),n=_("").addClass("table subcompact"),i=_("").appendTo(n),n.appendTo(t),this._createInspectorItems(i),s=_("
    ").appendTo(e),_("
    ").addClass(a.clsHeadRow).appendTo(o),_.each(this.service,function(){var e=[];i=_("").addClass(i.clsFooter);n.find("tfoot").remove(),0!==this.foots.length&&(e=_("").addClass(i.clsHeadRow).appendTo(s),_.each(this.foots,function(){t=_("").addClass(a.clsBodyRow)).data("original",v),m=t%2==0,p=_("").appendTo(f),g=[];if("function"==typeof y.tableToCSV){for(t=z.isValue(t)?t.toLowerCase():"all-filtered",n=z.isValue(n)?n:z.elementId("table")+"-export.csv",l=_(""),o=this.heads,a=0;a"),z.isValue(this.title)&&c.html(this.title),g[u.view[e]["index-view"]]=c)}),a=0;a"),o=r[s],a=0;a").html(this),g[u.view[e]["index-view"]]=c)}),a=0;a").addClass("tab-marker").addClass(t.clsMarker).appendTo(e)),this.openTab(0===i.length?n[0]:i[0])},_createEvents:function(){var a=this,o=this.element,r=this.options,l=o.find("li");o.on(C.events.click,"li",function(e){var t=_(this),n=o.find("li.active"),i=l.index(t)>l.index(n),s=t.children("a").attr("href");if(z.isValue(s)&&"#"===s[0]){if(t.hasClass("active"))return;if(t.hasClass("disabled"))return;if(!1===z.exec(r.onBeforeTabOpen,[t,s,i],this))return;if(!z.isValue(s))return;a.openTab(t,i),e.preventDefault()}}),o.on(C.events.scroll,function(){var e=this.scroll;this.scrollDir=this.scroll").addClass("tabs tabs-wrapper");if(z.isValue(n.attr("id"))||n.attr("id",z.elementId("tabs")),o.addClass(i.tabsPosition.replace(["-","_","+"]," ")),n.addClass("tabs-list"),"default"!==i.tabsType&&n.addClass("tabs-"+i.tabsType),a||(o.insertBefore(n),n.appendTo(o)),n.data("expanded",!1),e=_("
    ").addClass("expand-title"),o.prepend(e),0===(t=o.find(".hamburger")).length){t=_("
    ").appendTo(t),z.isValue(this.title)&&i.html(this.title),z.isValue(this.size)&&i.css({width:this.size}),z.isValue(this.cls)&&e.push(this.cls),e.push(a.clsHeadCell),i.addClass(e.join(" "))}),n=this.heads,e=0;e")).data("index",e),z.isValue(t.title)&&i.html(t.title),z.isValue(t.format)&&i.attr("data-format",t.format),z.isValue(t.name)&&i.attr("data-name",t.name),z.isValue(t.colspan)&&i.attr("colspan",t.colspan),z.isValue(l[e].size)&&i.css({width:l[e].size}),!0===t.sortable&&(n.push("sortable-column"),z.isValue(t.sortDir)&&n.push("sort-"+t.sortDir)),z.isValue(t.cls)&&n.push(t.cls),!1===z.bool(l[e].show)&&n.push("hidden"),n.push(a.clsHeadCell),z.bool(l[e].show)&&z.arrayDelete(n,"hidden"),i.addClass(n.join(" ")),r[l[e]["index-view"]]=i}),e=0;e").addClass(this.options.clsBody).insertAfter(e)},_createTableFooter:function(){var e,t,n=this.element,i=this.options,s=_("
    ").appendTo(e),void 0!==this.title&&t.html(this.title),void 0!==this.name&&t.addClass("foot-column-name-"+this.name),void 0!==this.cls&&t.addClass(this.cls),z.isValue(this.colspan)&&t.attr("colspan",this.colspan),t.appendTo(e)})),n.append(s)},_createTopBlock:function(){var e,t,n,i=this,s=this.element,a=this.options,o=_("
    ").addClass("table-top").addClass(a.clsTableTop).insertBefore(s.parent());return(e=z.isValue(this.wrapperSearch)?this.wrapperSearch:_("
    ").addClass("table-search-block").addClass(a.clsSearch).appendTo(o)).addClass(a.clsSearch),_("").attr("type","text").appendTo(e).input({prepend:a.tableSearchTitle}),!0!==a.showSearch&&e.hide(),(t=z.isValue(this.wrapperRows)?this.wrapperRows:_("
    ").addClass("table-rows-block").appendTo(o)).addClass(a.clsRowsCount),n=_("
    ").html(t+1),void 0!==i.service[0].clsColumn&&p.addClass(i.service[0].clsColumn),p.appendTo(u),p=_(""),f="checkbox"===a.checkType?_(""):_(""),z.isValue(c)&&Array.isArray(c)&&-1"),_("
    ").addClass("cell-wrapper").addClass(a.clsCellWrapper).html(t).appendTo(p)):p=_("
    ").html(t),p.addClass(a.clsBodyCell),z.isValue(i.heads[e].clsColumn)&&p.addClass(i.heads[e].clsColumn),!1===z.bool(d[e].show)&&p.addClass("hidden"),z.bool(d[e].show)&&p.removeClass("hidden"),p.data("original",this),g[d[e]["index-view"]]=p,z.exec(a.onDrawCell,[p,t,e,i.heads[e],v],p[0]),s.fire("drawcell",{td:p,val:t,cellIndex:e,head:i.heads[e],items:v})}),h=0;hthis.pagesCount))return this._draw(),this;this.currentPage=this.pagesCount}},prev:function(){if(0!==this.items.length){if(this.currentPage--,0!==this.currentPage)return this._draw(),this;this.currentPage=1}},first:function(){if(0!==this.items.length)return this.currentPage=1,this._draw(),this},last:function(){if(0!==this.items.length)return this.currentPage=this.pagesCount,this._draw(),this},page:function(e){return e<=0&&(e=1),e>this.pagesCount&&(e=this.pagesCount),this.currentPage=e,this._draw(),this},addFilter:function(e,t){var n,i=null,s=z.isFunc(e);if(!1!==s){for(n=0;n").appendTo(f),v=_("