@stemy/ngx-utils 10.3.3 → 10.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/stemy-ngx-utils.umd.js +2 -2
- package/bundles/stemy-ngx-utils.umd.js.map +1 -1
- package/bundles/stemy-ngx-utils.umd.min.js +1 -1
- package/bundles/stemy-ngx-utils.umd.min.js.map +1 -1
- package/esm2015/ngx-utils/utils/array.utils.js +3 -3
- package/fesm2015/stemy-ngx-utils.js +2 -2
- package/fesm2015/stemy-ngx-utils.js.map +1 -1
- package/ngx-utils/utils/array.utils.d.ts +2 -2
- package/package.json +1 -1
|
@@ -12,5 +12,5 @@
|
|
|
12
12
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
13
13
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14
14
|
PERFORMANCE OF THIS SOFTWARE.
|
|
15
|
-
***************************************************************************** */var extendStatics=function(e,t){return(extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)};function __extends(e,t){function r(){this.constructor=e}extendStatics(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var __assign=function(){return(__assign=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function __rest(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]])}return r}function __decorate(e,t,r,n){var i,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(i=e[s])&&(a=(o<3?i(a):o>3?i(t,r,a):i(t,r))||a);return o>3&&a&&Object.defineProperty(t,r,a),a}function __param(e,t){return function(r,n){t(r,n,e)}}function __metadata(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function __awaiter(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))}function __generator(e,t){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],n=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}var __createBinding=Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]};function __exportStar(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||__createBinding(t,e,r)}function __values(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}function __spread(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(__read(arguments[t]));return e}function __spreadArrays(){for(var e=0,t=0,r=arguments.length;t<r;t++)e+=arguments[t].length;var n=Array(e),i=0;for(t=0;t<r;t++)for(var o=arguments[t],a=0,s=o.length;a<s;a++,i++)n[i]=o[a];return n}function __await(e){return this instanceof __await?(this.v=e,this):new __await(e)}function __asyncGenerator(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n,i=r.apply(e,t||[]),o=[];return n={},a("next"),a("throw"),a("return"),n[Symbol.asyncIterator]=function(){return this},n;function a(e){i[e]&&(n[e]=function(t){return new Promise((function(r,n){o.push([e,t,r,n])>1||s(e,t)}))})}function s(e,t){try{(r=i[e](t)).value instanceof __await?Promise.resolve(r.value.v).then(c,u):l(o[0][2],r)}catch(e){l(o[0][3],e)}var r}function c(e){s("next",e)}function u(e){s("throw",e)}function l(e,t){e(t),o.shift(),o.length&&s(o[0][0],o[0][1])}}function __asyncDelegator(e){var t,r;return t={},n("next"),n("throw",(function(e){throw e})),n("return"),t[Symbol.iterator]=function(){return this},t;function n(n,i){t[n]=e[n]?function(t){return(r=!r)?{value:__await(e[n](t)),done:"return"===n}:i?i(t):t}:i}}function __asyncValues(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e="function"==typeof __values?__values(e):e[Symbol.iterator](),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(r){t[r]=e[r]&&function(t){return new Promise((function(n,i){(function(e,t,r,n){Promise.resolve(n).then((function(t){e({value:t,done:r})}),t)})(n,i,(t=e[r](t)).done,t.value)}))}}}function __makeTemplateObject(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var __setModuleDefault=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function __importStar(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&__createBinding(t,e,r);return __setModuleDefault(t,e),t}function __importDefault(e){return e&&e.__esModule?e:{default:e}}function __classPrivateFieldGet(e,t){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return t.get(e)}function __classPrivateFieldSet(e,t,r){if(!t.has(e))throw new TypeError("attempted to set private field on non-instance");return t.set(e,r),r}var defaultPredicate=function(){return!0},ɵ0=defaultPredicate,hasBlob="undefined"!=typeof Blob,hasFile="undefined"!=typeof File,ObjectUtils=function(){function ObjectUtils(){}return ObjectUtils.compare=function(e,t){return null===e||null===t||typeof e!=typeof t?null:"string"==typeof e?e.localeCompare(t):(e instanceof Date&&(e=e.getTime(),t=t.getTime()),e>t?1:e<t?-1:0)},ObjectUtils.getProperties=function(e){if(!ObjectUtils.isObject(e)&&!ObjectUtils.isFunction(e))return[];var t=new Set;return Object.keys(e).forEach((function(e){return t.add(e)})),Object.getOwnPropertyNames(e).forEach((function(e){return t.add(e)})),Array.from(t)},ObjectUtils.equals=function(e,t){if(e===t)return!0;if(null===e||null===t)return!1;if(e!=e&&t!=t)return!0;var r,n,i,o=typeof e;if(o==typeof t&&"object"==o){if(!Array.isArray(e)){if(Array.isArray(t))return!1;for(n in i=Object.create(null),e)if(e.hasOwnProperty(n)){if(!ObjectUtils.equals(e[n],t[n]))return!1;i[n]=!0}for(n in t)if(t.hasOwnProperty(n)&&!(n in i)&&void 0!==t[n])return!1;return!0}if(!Array.isArray(t))return!1;if((r=e.length)==t.length){for(n=0;n<r;n++)if(!ObjectUtils.equals(e[n],t[n]))return!1;return!0}}return!1},ObjectUtils.evaluate=function(expr,context,res){void 0===context&&(context={}),void 0===res&&(res={}),expr=Object.keys(context).reduce((function(e,t){return"var "+t+" = this['"+t+"']; "+e}),expr);var result=null;try{result=function(){return eval(expr)}.call(context)}catch(e){res.exception=e,console.log("Failed to parse expression: "+e.message,expr,context)}return res.result=result,result},ObjectUtils.empty=function(e){return!e||0==Object.keys(e).length},ObjectUtils.iterate=function(e,t){e&&(Array.isArray(e)?Array.from(e.keys()):Object.keys(e)).forEach((function(r){t(e[r],r)}))},ObjectUtils.getValue=function(e,t,r,n){void 0===n&&(n=!1);var i=(t=t||"").split("."),o="";do{o+=i.shift(),!ObjectUtils.isDefined(e)||!ObjectUtils.isDefined(e[o])||"object"!=typeof e[o]&&i.length?i.length?o+=".":(r=void 0===r?t.replace(new RegExp(o+"$"),"{"+o+"}"):r,e=n&&e||r):(e=e[o],o="")}while(i.length);return e},ObjectUtils.mapToPath=function(e,t,r){if(void 0===t)return e;if(0==r.length)return t;var n=r.shift();if("*"==n)return ObjectUtils.isArray(t)?(e=ObjectUtils.isArray(e)?e:[],t.map((function(t,n){return ObjectUtils.mapToPath(e[n],t,Array.from(r))}))):ObjectUtils.isObject(t)?(e=ObjectUtils.isObject(e)?e:{},Object.keys(t).reduce((function(n,i){return n[i]=ObjectUtils.mapToPath(e[i],t[i],Array.from(r)),n}),{})):ObjectUtils.isNullOrUndefined(e)?null:e;var i=ObjectUtils.isArray(e);return(e=ObjectUtils.isObject(e)||i?e:{})[n]=ObjectUtils.mapToPath(e[n],t,Array.from(r)),isNaN(n)||i?e:Object.values(e)},ObjectUtils.filter=function(e,t){return ObjectUtils.copyRecursive(null,e,t)},ObjectUtils.copy=function(e){return ObjectUtils.copyRecursive(null,e)},ObjectUtils.assign=function(e,t,r){return ObjectUtils.copyRecursive(e,t,r)},ObjectUtils.getType=function(e){var t=new RegExp("\\s([a-zA-Z]+)");return Object.prototype.toString.call(e).match(t)[1].toLowerCase()},ObjectUtils.isPrimitive=function(e){var t=typeof e;return null==e||"object"!==t&&"function"!==t},ObjectUtils.isObject=function(e){return"object"===ObjectUtils.getType(e)},ObjectUtils.isDefined=function(e){return null!=e},ObjectUtils.isNullOrUndefined=function(e){return void 0===e||null==e},ObjectUtils.isString=function(e){return"string"==typeof e},ObjectUtils.isFunction=function(e){return"function"==typeof e},ObjectUtils.isDate=function(e){return null!==e&&!isNaN(e)&&void 0!==e.getDate},ObjectUtils.isBlob=function(e){return hasBlob&&e instanceof Blob||hasFile&&e instanceof File},ObjectUtils.isBoolean=function(e){return"boolean"==typeof e},ObjectUtils.isNumber=function(e){if("number"!=typeof e)return!1;var t=+e;return t-t==0&&(t===e||void 0)},ObjectUtils.isArray=function(e){return Array.isArray(e)},ObjectUtils.isSet=function(e){return e instanceof Set},ObjectUtils.checkInterface=function(e,t){if(!e)return!1;for(var r in t)if(t.hasOwnProperty(r)&&typeof e[r]!==t[r])return!1;return!0},ObjectUtils.pad=function(e,t,r){void 0===r&&(r="0");var n=ObjectUtils.isDefined(e)?e.toString():"";return n.length>=t?n:new Array(t-n.length+1).join(r)+n},ObjectUtils.copyRecursive=function(e,t,r){return r=r||defaultPredicate,ObjectUtils.isPrimitive(t)||ObjectUtils.isDate(t)||ObjectUtils.isBlob(t)||ObjectUtils.isFunction(t)?t:ObjectUtils.isArray(t)?(e=ObjectUtils.isArray(e)?Array.from(e):[],t.forEach((function(n,i){r(n,i,e,t)&&(e.length>i?e[i]=ObjectUtils.copyRecursive(e[i],n,r):e.push(ObjectUtils.copyRecursive(null,n,r)))})),e):Object.keys(t).reduce((function(e,n){return r(t[n],n,e,t)?(e[n]=ObjectUtils.copyRecursive(e[n],t[n],r),e):e}),Object.assign({},e))},ObjectUtils}(),ReflectUtils=function(){function e(){}return e.defineMetadata=function(e,t,r,n){Reflect.defineMetadata(e,t,r,n)},e.getMetadata=function(e,t,r){return Reflect.getMetadata(e,t,r)},e.getOwnMetadata=function(e,t,r){return Reflect.getOwnMetadata(e,t,r)},e.resolve=function(t,r){if(!ObjectUtils.checkInterface(t,{func:"function"}))return t;var n=t,i=[];if(n.type){var o=ObjectUtils.getProperties(n.type).find((function(e){return n.type[e]===n.func}));i=e.getMetadata("factoryDependencies",n.type,o)||[]}else i=e.getMetadata("factoryDependencies",n.func)||[];var a=i.map((function(e){return r.get(e)})).concat(n.params);return n.func.apply(null,a)},e}(),CanvasColor=function(e,t,r,n){void 0===n&&(n=255),this.r=e,this.g=t,this.b=r,this.a=n},ICON_SERVICE=new core.InjectionToken("icon-service"),LANGUAGE_SERVICE=new core.InjectionToken("language-service"),AUTH_SERVICE=new core.InjectionToken("auth-service"),StorageMode;StorageMode=exports.StorageMode||(exports.StorageMode={}),StorageMode[StorageMode.Local=0]="Local",StorageMode[StorageMode.Session=1]="Session";var TOASTER_SERVICE=new core.InjectionToken("toaster-service"),PROMISE_SERVICE=new core.InjectionToken("promise-service"),UnorederedListTemplate=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t}(core.TemplateRef);function FactoryDependencies(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t,r){ReflectUtils.defineMetadata("factoryDependencies",e,t,r)}}var PaginationItemContext=function(){function e(e,t,r,n,i){this.item=e,this.parallelItem=t,this.count=r,this.index=n,this.dataIndex=i}return Object.defineProperty(e.prototype,"first",{get:function(){return 0===this.index},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"last",{get:function(){return this.index===this.count-1},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"even",{get:function(){return this.index%2==0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"odd",{get:function(){return!this.even},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"row",{get:function(){return console.log("DynamicTable row is deprecated use item instead"),this.item},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parallelRow",{get:function(){return console.log("DynamicTable parallelRow is deprecated use parallelItem instead"),this.parallelItem},enumerable:!1,configurable:!0}),e.prototype.filter=function(e){var t,r,n=Object.keys(this.item);try{for(var i=__values(n),o=i.next();!o.done;o=i.next()){var a=o.value,s=this.item[a];if(!ObjectUtils.isNullOrUndefined(s)&&!ObjectUtils.isObject(s))if((ObjectUtils.isString(s)?s:s.toString()).match(e))return!0}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return!1},e}(),HttpPromise=function(e){function t(t,r){var n=e.call(this,r)||this;return n.rejectHandler=t,n.attachCount=0,n.runCount=0,n}return __extends(t,e),t.prototype.then=function(t,r){var n=this;return this.attachCount++,e.prototype.then.call(this,(function(e){return n.runCount++,t?t(e):null}),(function(e){var t=r?r(e):null;return n.hasRejectHandler=n.hasRejectHandler||r&&!1!==t,n.runCount++,n.rejectHandler(n.runCount!=n.attachCount||n.hasRejectHandler?null:e),t}))},t.prototype.catch=function(e){return this.then(null,e)},t}(Promise),EXPRESS_REQUEST=new core.InjectionToken("express-request"),API_SERVICE=new core.InjectionToken("api-service"),ResourceIfContext=function(){},IConfiguration=function(){},CONFIG_SERVICE=new core.InjectionToken("config-service"),BASE_CONFIG=new core.InjectionToken("base-config"),SCRIPT_PARAMS=new core.InjectionToken("script-params"),ERROR_HANDLER=new core.InjectionToken("error-handler-callback"),AjaxRequestHandler=function(){function e(t,r){var n=this;if(this.pattern=t,this.callback=r,this.listener=function(e){var t=e.detail;n.pattern.test(t.url)&&n.callback(t,n.params)},this.params={},"undefined"!=typeof XMLHttpRequest&&!e.isOverridden){e.isOverridden=!0;var i=XMLHttpRequest.prototype.open;XMLHttpRequest.prototype.open=function(e,t,r,n,o){i.apply(this,arguments),window.dispatchEvent(new CustomEvent("ajaxRequest",{detail:{request:this,method:e,url:t}}))}}}return e.prototype.listen=function(){return"undefined"==typeof window||window.addEventListener("ajaxRequest",this.listener),this},e.prototype.forget=function(){if("undefined"!=typeof window)return window.removeEventListener("ajaxRequest",this.listener),this},e}();AjaxRequestHandler.isOverridden=!1;var DateUtils=function(){function e(){}return e.isHoliday=function(e){return moment.utc(e).isoWeekday()>5},e.isBusinessDay=function(e){return moment.utc(e).isoWeekday()<6},e.add=function(e,t,r){return moment.utc(e).add(t,r).toDate()},e.businessAdd=function(t,r,n){for(var i=r<0?-1:1,o=Math.abs(r),a=t;o;)a=e.add(a,i,n),e.isBusinessDay(a)&&o--;return a},e.businessSubtract=function(t,r,n){return e.businessAdd(t,-r,n)},e}(),BlurStack=function(){this.r=0,this.g=0,this.b=0,this.a=0,this.next=null},mul_table=[512,512,456,512,328,456,335,512,405,328,271,456,388,335,292,512,454,405,364,328,298,271,496,456,420,388,360,335,312,292,273,512,482,454,428,405,383,364,345,328,312,298,284,271,259,496,475,456,437,420,404,388,374,360,347,335,323,312,302,292,282,273,265,512,497,482,468,454,441,428,417,405,394,383,373,364,354,345,337,328,320,312,305,298,291,284,278,271,265,259,507,496,485,475,465,456,446,437,428,420,412,404,396,388,381,374,367,360,354,347,341,335,329,323,318,312,307,302,297,292,287,282,278,273,269,265,261,512,505,497,489,482,475,468,461,454,447,441,435,428,422,417,411,405,399,394,389,383,378,373,368,364,359,354,350,345,341,337,332,328,324,320,316,312,309,305,301,298,294,291,287,284,281,278,274,271,268,265,262,259,257,507,501,496,491,485,480,475,470,465,460,456,451,446,442,437,433,428,424,420,416,412,408,404,400,396,392,388,385,381,377,374,370,367,363,360,357,354,350,347,344,341,338,335,332,329,326,323,320,318,315,312,310,307,304,302,299,297,294,292,289,287,285,282,280,278,275,273,271,269,267,265,263,261,259],shg_table=[9,11,12,13,13,14,14,15,15,15,15,16,16,16,16,17,17,17,17,17,17,17,18,18,18,18,18,18,18,18,18,19,19,19,19,19,19,19,19,19,19,19,19,19,19,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24],CanvasUtils=function(){function e(){}return e.manipulatePixels=function(e,t,r){for(var n=t.getImageData(0,0,e.width,e.height),i=n.data,o=0,a=i.length;o<a;o+=4){var s=new CanvasColor(i[o],i[o+1],i[o+2],i[o+3]),c=r(s,.3*s.r+.59*s.g+.11*s.b);i[o]=c.r,i[o+1]=c.g,i[o+2]=c.b,i[o+3]=c.a}t.putImageData(n,0,0)},e.thresholding=function(t,r,n,i){void 0===n&&(n=50);var o=new CanvasColor(0,0,0,255),a=new CanvasColor(0,0,0,0);i=ObjectUtils.isFunction(i)?i:function(e,t){return t?a:o},e.manipulatePixels(t,r,(function(e,t){return i(e,t>n,t)}))},e.stackBlur=function(e,t,r){if(void 0===r&&(r=10),!(isNaN(r)||r<1)){r|=0;var n=e.width,i=e.height,o=null;try{try{o=t.getImageData(0,0,n,i)}catch(e){try{netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead"),o=t.getImageData(0,0,n,i)}catch(e){throw alert("Cannot access local image"),new Error("unable to access local image data: "+e)}}}catch(e){throw alert("Cannot access image"),new Error("unable to access image data: "+e)}var a,s,c,u,l,p,f,d,h,g,m,y,v,b,P,S,x,O,j,I,w,C,E,T,U=o.data,R=r+r+1,k=n-1,D=i-1,_=r+1,A=_*(_+1)/2,L=new BlurStack,M=null,F=L;for(c=1;c<R;c++)F=F.next=new BlurStack,c==_&&(M=F);F.next=L;var N=null,V=null;f=p=0;var z=mul_table[r],B=shg_table[r];for(s=0;s<i;s++){for(S=x=O=j=d=h=g=m=0,y=_*(I=U[p]),v=_*(w=U[p+1]),b=_*(C=U[p+2]),P=_*(E=U[p+3]),d+=A*I,h+=A*w,g+=A*C,m+=A*E,F=L,c=0;c<_;c++)F.r=I,F.g=w,F.b=C,F.a=E,F=F.next;for(c=1;c<_;c++)u=p+((k<c?k:c)<<2),d+=(F.r=I=U[u])*(T=_-c),h+=(F.g=w=U[u+1])*T,g+=(F.b=C=U[u+2])*T,m+=(F.a=E=U[u+3])*T,S+=I,x+=w,O+=C,j+=E,F=F.next;for(N=L,V=M,a=0;a<n;a++)U[p+3]=E=m*z>>B,0!=E?(E=255/E,U[p]=(d*z>>B)*E,U[p+1]=(h*z>>B)*E,U[p+2]=(g*z>>B)*E):U[p]=U[p+1]=U[p+2]=0,d-=y,h-=v,g-=b,m-=P,y-=N.r,v-=N.g,b-=N.b,P-=N.a,u=f+((u=a+r+1)<k?u:k)<<2,d+=S+=N.r=U[u],h+=x+=N.g=U[u+1],g+=O+=N.b=U[u+2],m+=j+=N.a=U[u+3],N=N.next,y+=I=V.r,v+=w=V.g,b+=C=V.b,P+=E=V.a,S-=I,x-=w,O-=C,j-=E,V=V.next,p+=4;f+=n}for(a=0;a<n;a++){for(x=O=j=S=h=g=m=d=0,y=_*(I=U[p=a<<2]),v=_*(w=U[p+1]),b=_*(C=U[p+2]),P=_*(E=U[p+3]),d+=A*I,h+=A*w,g+=A*C,m+=A*E,F=L,c=0;c<_;c++)F.r=I,F.g=w,F.b=C,F.a=E,F=F.next;for(l=n,c=1;c<=r;c++)p=l+a<<2,d+=(F.r=I=U[p])*(T=_-c),h+=(F.g=w=U[p+1])*T,g+=(F.b=C=U[p+2])*T,m+=(F.a=E=U[p+3])*T,S+=I,x+=w,O+=C,j+=E,F=F.next,c<D&&(l+=n);for(p=a,N=L,V=M,s=0;s<i;s++)U[(u=p<<2)+3]=E=m*z>>B,E>0?(E=255/E,U[u]=(d*z>>B)*E,U[u+1]=(h*z>>B)*E,U[u+2]=(g*z>>B)*E):U[u]=U[u+1]=U[u+2]=0,d-=y,h-=v,g-=b,m-=P,y-=N.r,v-=N.g,b-=N.b,P-=N.a,u=a+((u=s+_)<D?u:D)*n<<2,d+=S+=N.r=U[u],h+=x+=N.g=U[u+1],g+=O+=N.b=U[u+2],m+=j+=N.a=U[u+3],N=N.next,y+=I=V.r,v+=w=V.g,b+=C=V.b,P+=E=V.a,S-=I,x-=w,O-=C,j-=E,V=V.next,p+=n}t.putImageData(o,0,0)}},e.measureTextFontSize=function(t,r,n,i,o,a){void 0===o&&(o=1.1);var s=r,c=a.getContext("2d");a||(a=document.createElement("canvas"),document.body.appendChild(a)),a.width=t+r,a.height=2*r;var u=e.halveValidateFontSize(s,(function(r){e.setFontProps(c,i,r);var o=e.getTextWidth(c,n);return t-o}));return e.getTextBitmapHeight(a,c,n,i,u,o)>r&&(u=e.halveValidateFontSize(u,(function(t){return r-e.getTextBitmapHeight(a,c,n,i,t,o)}))),u},e.drawLines=function(t,r,n,i,o,a,s,c,u){void 0===o&&(o=1.1),void 0===a&&(a="left"),void 0===s&&(s="top"),void 0===c&&(c=0),void 0===u&&(u=0),e.setFontProps(t,n,i,a,s);for(var l=0;l<r.length;l++){var p=r[l];t.fillText(p,c,u),l<r.length-1&&(u+=i*o)}return u},e.wrapText=function(e,t,r,n,i){for(var o=t.split(" "),a=1.3*e.measureText("M").width,s=[],c="",u=0;u<o.length;u++){var l=c+o[u]+" ";e.measureText(l).width>i&&u>0?(s.push(c),c=o[u]+" "):c=l}s.push(c),n-=.5*a*s.length,s.forEach((function(t){e.fillText(t,r,n),n+=a}))},e.setFontProps=function(e,t,r,n,i){void 0===n&&(n="left"),void 0===i&&(i="top"),e.font=r+"px "+t,e.textAlign=n,e.textBaseline=i},e.getTextWidth=function(e,t){for(var r=0,n=0;n<t.length;n++){var i=t[n];r=Math.max(r,e.measureText(i).width)}return r},e.getTextBitmapHeight=function(t,r,n,i,o,a){var s=t.width,c=t.height;r.clearRect(0,0,s,c);var u=e.drawLines(r,n,i,o,a,"left","top",.5*o,.5*o),l=r.getImageData(0,0,s,c),p=0;e:for(var f=0;f<c;f++)for(var d=0;d<s;d++){var h=4*(d+f*s);if(l.data[h+3]>0){p=f+1;continue e}}return Math.max(p,u+o)},e.halveValidateFontSize=function(e,t){for(var r=e,n=0,i=0;i<20;i++){var o=r;if(t(r)<0?r-=Math.abs(r-n)/2:r+=Math.abs(r-n)/2,n=o,Math.abs(r-n)<.1)break}return r=Math.floor(r)},e}(),FileUtils=function(){function e(){}return e.getExtension=function(e){return e?e.name.substr(e.name.lastIndexOf(".")).toLowerCase():null},e.getName=function(e){return e?e.name.substr(0,e.name.lastIndexOf(".")):null},e.toFile=function(e,t){var r=e;return r.lastModifiedDate=new Date,r.name=t.split(/\\|\//g).pop(),r},e.dataToBlob=function(e){for(var t=e.split(","),r=atob(t[1]),n=t[0].split(":")[1].split(";")[0],i=new ArrayBuffer(r.length),o=new Uint8Array(i),a=0;a<r.length;a++)o[a]=r.charCodeAt(a);return new Blob([i],{type:n})},e.saveBlob=function(e,t){if("undefined"==typeof saveAs)throw Error("FileSaver library is not loaded. Please load it: https://www.npmjs.com/package/file-saver");saveAs(e,t)},e.saveJson=function(t,r){ObjectUtils.isObject(t)&&e.saveBlob(new Blob([JSON.stringify(t,null,4)]),r)},e.readFileAsText=function(t){return e.readFile((function(e){return e.readAsText(t)}))},e.readFileAsBinaryString=function(t){return e.readFile((function(e){return e.readAsBinaryString(t)}))},e.readFileAsDataURL=function(t){return e.readFile((function(e){return e.readAsDataURL(t)}))},e.readDataFromUrl=function(t,r){return new Promise((function(n,i){r?/^([A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{4}|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{2}==)$/g.test(r)?n(r):operators.first()(t.get(r,{responseType:"blob"})).subscribe((function(t){e.readFileAsDataURL(t).then(n,i)}),(function(e){e.status>0?i(e):n(r)})):i({message:"The url is not specified"})}))},e.readFile=function(e){return new Promise((function(t,r){var n=new FileReader;n.onload=function(e){return t(e.target.result)},n.onerror=r,e(n)}))},e}(),GenericValue=function(e){function t(t){void 0===t&&(t=null);var r=e.call(this)||this;return r._value=t,r}return __extends(t,e),Object.defineProperty(t.prototype,"value",{get:function(){return this._value},set:function(e){e!=this._value&&(this._value=e,this.next(e))},enumerable:!1,configurable:!0}),t.prototype.setJustValue=function(e){this._value=e},t}(rxjs.Subject),Rect=function(){function e(e,t,r,n,i){void 0===i&&(i=0),this.x=e,this.y=t,this.width=r,this.height=n,this.rotation=i}return Object.defineProperty(e.prototype,"center",{get:function(){return new Point(this.x,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"left",{get:function(){return this.x-.5*this.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"right",{get:function(){return this.x+.5*this.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottom",{get:function(){return this.y-.5*this.height},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"top",{get:function(){return this.y+.5*this.height},enumerable:!1,configurable:!0}),e.prototype.distance=function(e){e=e.rotateAround(this.center,-this.rotation);var t=Math.max(this.left-e.x,0,e.x-this.right),r=Math.max(this.bottom-e.y,0,e.y-this.top);return Math.sqrt(t*t+r*r)},e}(),Circle=function(){function e(e,t,r){this.x=e,this.y=t,this.radius=r}return Object.defineProperty(e.prototype,"center",{get:function(){return new Point(this.x,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"left",{get:function(){return new Point(this.x-this.radius,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"right",{get:function(){return new Point(this.x+this.radius,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"top",{get:function(){return new Point(this.x,this.y+this.radius)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottom",{get:function(){return new Point(this.x,this.y-this.radius)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rect",{get:function(){return new Rect(this.x,this.y,2*this.radius,2*this.radius)},enumerable:!1,configurable:!0}),e.prototype.distance=function(e){return this.center.distance(e)-this.radius},e}(),Point=function(){function e(e,t){this.x=e,this.y=t}return Object.defineProperty(e.prototype,"length",{get:function(){return this.distance(e.Zero)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"perpendicular",{get:function(){return new e(this.y,-this.x)},enumerable:!1,configurable:!0}),e.prototype.add=function(t){return new e(this.x+t.x,this.y+t.y)},e.prototype.subtract=function(t){return new e(this.x-t.x,this.y-t.y)},e.prototype.multiply=function(t){return t instanceof e?new e(this.x*t.x,this.y*t.y):new e(this.x*t,this.y*t)},e.prototype.distance=function(e){var t=e.x-this.x,r=e.y-this.y;return Math.sqrt(t*t+r*r)},e.prototype.lerp=function(e,t){var r=e.subtract(this);return this.add(r.multiply(t))},e.prototype.perpendicularTo=function(e,t){var r=e.perpendicular.subtract(this.perpendicular),n=t/r.length;return this.lerp(e,.5).add(r.multiply(n))},e.prototype.circleWith=function(t,r){var n=(r.y-t.y)/(r.x-t.x),i=(this.y-r.y)/(this.x-r.x),o=(n*i*(t.y-this.y)+i*(t.x+r.x)-n*(r.x+this.x))/(2*(i-n)),a=new e(o,-1*(o-(t.x+r.x)/2)/n+(t.y+r.y)/2);return new Circle(a.x,a.y,a.distance(this))},e.prototype.tangents=function(t){var r=t.center.subtract(this),n=Math.asin(t.radius/r.length),i=Math.atan2(r.y,r.x),o=i-n,a=new e(t.x+t.radius*Math.sin(o),t.y+t.radius*-Math.cos(o));return o=i+n,[a,new e(t.x+t.radius*-Math.sin(o),t.y+t.radius*Math.cos(o))]},e.prototype.angle=function(e){var t=e.subtract(this);return 180*Math.atan2(t.y,t.x)/Math.PI},e.prototype.rotateAround=function(t,r){var n=(t.angle(this)+r)*Math.PI/180,i=t.distance(this),o=new e(Math.cos(n)*i,Math.sin(n)*i);return t.add(o)},e}();Point.Zero=new Point(0,0);var Initializer=function(){function e(e,t){return void 0===t&&(t=!0),this.callback=e,this.shouldInit=t,this.initialized=!this.shouldInit,invokable.Invokable.create(this)}return e.prototype[invokable.Invokable.call]=function(){return this.initialized?null:(this.initialized=!0,this.callback())},e}(),LoaderUtils=function(){function e(){}return e.loadScript=function(e,t){return void 0===t&&(t=!1),this.scriptPromises[e]=this.scriptPromises[e]||new Promise((function(r,n){var i=document.createElement("script");i.type="text/javascript",i.src=e,i.async=t,i.readyState?i.onreadystatechange=function(){"loaded"!==i.readyState&&"complete"!==i.readyState||(i.onreadystatechange=null,r(i))}:i.onload=function(){return r(i)},i.onerror=function(e){return n(e)},document.body.appendChild(i)})),this.scriptPromises[e]},e.loadStyle=function(e){return this.stylePromises[e]=this.stylePromises[e]||new Promise((function(t,r){var n=document.createElement("link");n.rel="stylesheet",n.type="text/css",n.href=e,n.readyState?n.onreadystatechange=function(){"loaded"!==n.readyState&&"complete"!==n.readyState||(n.onreadystatechange=null,t(n))}:n.onload=function(){return t(n)},n.onerror=function(e){return r(e)},document.body.appendChild(n)})),this.stylePromises[e]},e}();LoaderUtils.scriptPromises={},LoaderUtils.stylePromises={};var MathUtils=function(){function e(){}return e.equal=function(e,t,r){return void 0===r&&(r=null),r=ObjectUtils.isNumber(r)?r:Math.E,Math.abs(e-t)<r},e.clamp=function(e,t,r){return Math.max(Math.min(e,r),t)},e.round=function(e,t,r){return void 0===t&&(t=2),void 0===r&&(r=1),t=Math.pow(10,t),Math.round(e*t/r)/t},e}(),emptySnapshot=new router.ActivatedRouteSnapshot,emptyData={id:""},emptyParams={},emptySegments=[],emptyComponents=[],StateService=function(e){function t(t,r,n){void 0===n&&(n=null);var i=e.call(this,null)||this;return i.injector=t,i.zone=r,i.router=n,i.handleRouterEvent=function(e){if(e instanceof router.NavigationEnd){for(var t=i.router.routerState.snapshot,r=t.root,n=i.contexts.getContext("primary"),o=r.url,a=[],s=[];r;)s.push(r),o=o.concat(r.url),n&&(n.outlet&&n.outlet.isActivated&&a.push(n.outlet.component),n=n.children.getContext("primary")),r=r.firstChild;i.comp=a[a.length-1],i.shot=s[s.length-1],i.stateInfo={url:t.url,segments:o,components:a},i.next(i.shot)}},i.router?(i.globalExtras={queryParamsHandling:"merge"},i.router.events.subscribe(i.handleRouterEvent),i.stateInfo={url:"",segments:[],components:[]},i.contexts=n.rootContexts,i):i}return __extends(t,e),t.toPath=function(e,t){var r=e.path||"";return ObjectUtils.iterate(t,(function(e,t){r=r.replace(":"+t,""+e)})),r},Object.defineProperty(t.prototype,"component",{get:function(){return this.comp},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"snapshot",{get:function(){return this.shot||emptySnapshot},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"route",{get:function(){return this.snapshot.routeConfig},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"data",{get:function(){return this.snapshot.data||emptyData},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"params",{get:function(){return this.snapshot.params||emptyParams},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"queryParams",{get:function(){return this.snapshot.queryParams||emptyParams},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"url",{get:function(){return this.stateInfo.url||""},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"urlSegments",{get:function(){return this.stateInfo.segments||emptySegments},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"components",{get:function(){return this.stateInfo.components||emptyComponents},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"routerConfig",{get:function(){return this.router.config},enumerable:!1,configurable:!0}),t.prototype.reload=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,r,n,i,o,a,s,c,u,l;return __generator(this,(function(p){switch(p.label){case 0:e=this.router.routerState.snapshot,t=this.route.resolve||{},r=Object.keys(t),p.label=1;case 1:p.trys.push([1,7,8,9]),n=__values(r),i=n.next(),p.label=2;case 2:return i.done?[3,6]:(o=i.value,a=this.injector.get(t[o]),(s=a.resolve(this.snapshot,e))instanceof rxjs.Observable&&(s=s.toPromise()),s instanceof Promise?[4,s]:[3,4]);case 3:s=p.sent(),p.label=4;case 4:this.data[o]=s,p.label=5;case 5:return i=n.next(),[3,2];case 6:return[3,9];case 7:return c=p.sent(),u={error:c},[3,9];case 8:try{i&&!i.done&&(l=n.return)&&l.call(n)}finally{if(u)throw u.error}return[7];case 9:return[2]}}))}))},t.prototype.navigate=function(e,t){if(!this.router)return Promise.resolve(!1);t=Object.assign({},this.globalExtras,t||{});var r=this.router.createUrlTree(e,t);return this.navigateByUrl(r,t)},t.prototype.navigateByUrl=function(e,t){var r=this;return this.router?(t=Object.assign({},this.globalExtras,t||{}),new Promise((function(n){r.zone.run((function(){r.router.navigateByUrl(e,t).then(n,(function(){return n(!1)}))}))}))):Promise.resolve(!1)},t.prototype.subscribeImmediately=function(e,t,r){return this.pipe(operators.skipWhile((function(e){return null==e}))).subscribe(e,t,r)},t}(rxjs.BehaviorSubject);StateService.decorators=[{type:core.Injectable}],StateService.ctorParameters=function(){return[{type:core.Injector},{type:core.NgZone},{type:router.Router,decorators:[{type:core.Optional}]}]};var AuthGuard=function(){function e(e,t,r){this.injector=e,this.state=t,this.auth=r}return e.guardAuthenticated=function(e){return Promise.resolve(e.isAuthenticated)},e.guardNotAuthenticated=function(e){return Promise.resolve(!e.isAuthenticated)},e.guardNothing=function(){return Promise.resolve(!0)},e.guardAuthField=function(e,t){void 0===t&&(t="auth.isAuthenticated");return function(){return Promise.resolve(ObjectUtils.evaluate(t,{auth:e}))}},e.guardStateField=function(e,t){void 0===t&&(t="state.data");return function(){return Promise.resolve(ObjectUtils.evaluate(t,{state:e}))}},e.guardAuthStateField=function(e,t,r){void 0===r&&(r="auth.isAuthenticated");return function(){return Promise.resolve(ObjectUtils.evaluate(r,{auth:e,state:t}))}},e.wildRouteMatch=function(e){return{consumed:e}},e.noRouteMatch=function(){return null},e.prototype.checkRouteMenu=function(e){return e.data&&e.data.name?this.checkRoute(e):Promise.resolve(!1)},e.prototype.checkRoute=function(e,t){var r=this,n=e.data||{};return n.guards?new Promise((function(i){var o=n.guards.map((function(n){return ReflectUtils.resolve(n,r.injector)(r.auth,e,t)}));Promise.all(o).then((function(e){i(e.indexOf(!1)<0)}))})):Promise.resolve(!e.canActivate||this.auth.isAuthenticated)},e.prototype.canActivate=function(e,t){var r=this,n=e.routeConfig;return new Promise((function(t){r.auth.checkAuthenticated().then((function(){r.checkRoute(n,e).then((function(i){t(i),i||r.getReturnState(n).then((function(t){t&&(console.log(t,e.queryParams),r.state.navigate(t,{queryParams:e.queryParams}))}))}))}))}))},e.prototype.getReturnState=function(e){var t=this;if(!e)return Promise.resolve(null);if(ObjectUtils.isObject(e.data)&&ObjectUtils.isArray(e.data.returnState))return Promise.resolve(e.data.returnState);var r=[],n=this.getConfig(e,this.state.routerConfig,r);return new Promise((function(e){t.getReturnStateRecursive(n).then((function(t){ObjectUtils.isArray(t)?e(r.concat(t)):e(t)}))}))},e.prototype.getReturnStateRecursive=function(e,t){var r=this;return void 0===t&&(t=0),!e||t>=e.length?Promise.resolve(null):new Promise((function(n){var i=e[t];(i.component?r.checkRoute(i):Promise.resolve(!1)).then((function(o){o?n([i.path]):r.getReturnStateRecursive(e,t+1).then(n)}))}))},e.prototype.getConfig=function(e,t,r){var n,i;if(!t)return null;if(t.findIndex((function(t){return t==e}))>=0)return t;try{for(var o=__values(t),a=o.next();!a.done;a=o.next()){var s=a.value;r.push(s.path);var c=(s._loadedConfig||{routes:null}).routes,u=this.getConfig(e,s.children||c,r);if(u)return u;r.length-=1}}catch(e){n={error:e}}finally{try{a&&!a.done&&(i=o.return)&&i.call(o)}finally{if(n)throw n.error}}return null},e}();AuthGuard.decorators=[{type:core.Injectable}],AuthGuard.ctorParameters=function(){return[{type:core.Injector,decorators:[{type:core.Inject,args:[core.Injector]}]},{type:StateService,decorators:[{type:core.Inject,args:[StateService]}]},{type:void 0,decorators:[{type:core.Inject,args:[AUTH_SERVICE]}]}]},__decorate([FactoryDependencies(AUTH_SERVICE)],AuthGuard,"guardAuthField",null),__decorate([FactoryDependencies(StateService)],AuthGuard,"guardStateField",null),__decorate([FactoryDependencies(AUTH_SERVICE,StateService)],AuthGuard,"guardAuthStateField",null);var ObservableUtils=function(){function e(){}return e.toSearch=function(e){return operators.mergeMap((function(t){return e.getSearchResults(t)}))(rxjs.Observable.create((function(t){t.next(e.search)})))},e.multiSubscription=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=function(){e.forEach((function(e){e.unsubscribe()}))};return new rxjs.Subscription(r)},e.subscribe=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var n=[];return t.forEach((function(e){var t=!1;e.subjects.forEach((function(r){var i=r.subscribe((function(){var n=Array.from(arguments);n.unshift(r),t=!0,e.cb.apply(null,n)}));n.push(i)})),t||e.cb()})),e.multiSubscription.apply(e,__spread(n))},e.fromFunction=function(e){var t;return new rxjs.Observable((function(r){if(!t){t=new rxjs.Subject;try{t=rxjs.from(e())}catch(e){canReportError.canReportError(t)?t.error(e):console.warn(e)}}return t.subscribe(r)}))},e}(),StringUtils=function(){function e(){}return e.concat=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return t.filter((function(e){return!!e})).join(e)},e.startsWith=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];for(var n=0;n<t.length;n++)if(e.startsWith(t[n]))return!0;return!1},e.has=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];for(var n=0;n<t.length;n++)if(e.indexOf(t[n])>=0)return!0;return!1},e.lcFirst=function(e){return e?e.charAt(0).toLowerCase()+e.substring(1):""},e.ucFirst=function(e){return e?e.charAt(0).toUpperCase()+e.substring(1):""},e}(),ArrayUtils=function(){function e(){}return e.has=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(!ObjectUtils.isArray(e)||!ObjectUtils.isArray(t))return!1;for(var n=0;n<t.length;n++)if(e.indexOf(t[n])>=0)return!0;return!1},e.match=function(e,t){if(!ObjectUtils.isArray(e)||!ObjectUtils.isString(t))return!1;for(var r=0;r<e.length;r++){if(e[r]instanceof RegExp)if(e[r].test(t))return!0}return!1},e.any=function(e,t){if(!ObjectUtils.isArray(e)||!ObjectUtils.isFunction(t))return!1;for(var r=0;r<e.length;r++)if(t(e[r]))return!0;return!1},e.move=function(e,t,r){if(!ObjectUtils.isArray(e))return[];for(var n=e.length;t<0;)t+=n;for(;r<0;)r+=n;if(r>=n)for(var i=r-n+1;i--;)e.push(void 0);return e.splice(r,0,e.splice(t,1)[0]),e},e.reversed=function(e){var t=[];if(!ObjectUtils.isArray(e))return t;for(var r=e.length-1;r>=0;r--)t.push(e[r]);return t},e.min=function(e,t){if(!ObjectUtils.isArray(e))return 0;for(var r=Number.MAX_SAFE_INTEGER,n=null,i=0;i<e.length;i++){var o=t(e[i],i);(o<r||null===n)&&(r=o,n=e[i])}return n},e.max=function(e,t){if(!ObjectUtils.isArray(e))return 0;for(var r=Number.MIN_SAFE_INTEGER,n=null,i=0;i<e.length;i++){var o=t(e[i],i);(o>r||null===n)&&(r=o,n=e[i])}return n},e.chunk=function(e,t){if(!ObjectUtils.isArray(e))return[];t=Math.max(1,t);for(var r=[],n=0;n<e.length;n+=t)r.push(e.slice(n,n+t));return r},e}(),SetUtils=function(){function e(){}return e.equals=function(e,t){if(!ObjectUtils.isSet(e)||!ObjectUtils.isSet(t))return!1;if(e.size!=t.size)return!1;for(var r in e)if(!t.has(r))return!1;return!0},e.addArray=function(e,t){ObjectUtils.isSet(e)&&ObjectUtils.isArray(t)&&t.forEach((function(t){return e.add(t)}))},e}(),TimerUtils=function(){function e(){}return e.createTimeout=function(t,r){return e.createTimer((function(e){e.clear(),e.id=setTimeout((function(){e.id=null,e.func()}),e.time)}),(function(e){e.id&&(clearTimeout(e.id),e.id=null)}),t,r)},e.createInterval=function(t,r){return e.createTimer((function(e){e.clear(),e.id=setInterval(e.func,e.time)}),(function(e){e.id&&(clearInterval(e.id),e.id=null)}),t,r)},e.createTimer=function(e,t,r,n){var i={},o=function(e,t){i.func=ObjectUtils.isFunction(e)?e:function(){},i.time=ObjectUtils.isNumber(t)?t:100};return i.run=function(){return e(i)},i.clear=function(){return t(i)},i.set=function(e,t){o(e,t),i.run()},o(r,n),i},e}(),UniqueUtils=function(){function e(){}return e.uuid=function(){if("undefined"!=typeof window&&void 0!==window.crypto&&void 0!==window.crypto.getRandomValues){var e=new Uint16Array(8);return window.crypto.getRandomValues(e),this.pad4(e[0])+this.pad4(e[1])+"-"+this.pad4(e[2])+"-"+this.pad4(e[3])+"-"+this.pad4(e[4])+"-"+this.pad4(e[5])+this.pad4(e[6])+this.pad4(e[7])}return this.random4()+this.random4()+"-"+this.random4()+"-"+this.random4()+"-"+this.random4()+"-"+this.random4()+this.random4()+this.random4()},e.pad4=function(e){for(var t=e.toString(16);t.length<4;)t="0"+t;return t},e.random4=function(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)},e}(),Vector=function(){function e(e,t,r){this.x=e,this.y=t,this.z=r}return Object.defineProperty(e.prototype,"negative",{get:function(){return new e(-this.x,-this.y,-this.z)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"length",{get:function(){return Math.sqrt(this.dot(this))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"unit",{get:function(){return this.divide(this.length)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"min",{get:function(){return Math.min(Math.min(this.x,this.y),this.z)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"max",{get:function(){return Math.max(Math.max(this.x,this.y),this.z)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"angles",{get:function(){return{theta:Math.atan2(this.z,this.x),phi:Math.asin(this.y/this.length)}},enumerable:!1,configurable:!0}),e.prototype.add=function(t){return t instanceof e?new e(this.x+t.x,this.y+t.y,this.z+t.z):new e(this.x+t,this.y+t,this.z+t)},e.prototype.subtract=function(t){return t instanceof e?new e(this.x-t.x,this.y-t.y,this.z-t.z):new e(this.x-t,this.y-t,this.z-t)},e.prototype.multiply=function(t){return t instanceof e?new e(this.x*t.x,this.y*t.y,this.z*t.z):new e(this.x*t,this.y*t,this.z*t)},e.prototype.divide=function(t){return t instanceof e?new e(this.x/t.x,this.y/t.y,this.z/t.z):new e(this.x/t,this.y/t,this.z/t)},e.prototype.equals=function(e){return this.x==e.x&&this.y==e.y&&this.z==e.z},e.prototype.dot=function(e){return this.x*e.x+this.y*e.y+this.z*e.z},e.prototype.cross=function(t){return new e(this.y*t.z-this.z*t.y,this.z*t.x-this.x*t.z,this.x*t.y-this.y*t.x)},e.prototype.angleTo=function(e){return Math.acos(this.dot(e)/(this.length*e.length))},e.prototype.toArray=function(e){return[this.x,this.y,this.z].slice(0,e||3)},e.prototype.clone=function(){return new e(this.x,this.y,this.z)},e.prototype.init=function(e,t,r){return this.x=e,this.y=t,this.z=r,this},e}(),UniversalService=function(){function e(e,t){this.platformId=e,this.dds=t;var r=this.dds.getDeviceInfo();this.crawler=/(bot|google|baidu|bing|msn|duckduckbot|teoma|slurp|yandex|lighthouse|angular-universal|PTST)/gi.test(r.userAgent)}return Object.defineProperty(e.prototype,"isBrowser",{get:function(){return common.isPlatformBrowser(this.platformId)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isServer",{get:function(){return common.isPlatformServer(this.platformId)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"deviceInfo",{get:function(){return this.isServer?{userAgent:"angular-universal",os:"unknown",browser:"node",device:"node",os_version:"unknown",browser_version:"unknown"}:this.dds.getDeviceInfo()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"browserName",{get:function(){return this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"browserVersion",{get:function(){return this.dds.browser_version},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isExplorer",{get:function(){return"ie"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isEdge",{get:function(){return"ms-edge"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isChrome",{get:function(){return"chrome"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isFirefox",{get:function(){return"firefox"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSafari",{get:function(){return"safari"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isTablet",{get:function(){return this.dds.isTablet()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isMobile",{get:function(){return this.dds.isMobile()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isDesktop",{get:function(){return this.dds.isDesktop()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isCrawler",{get:function(){return this.crawler},enumerable:!1,configurable:!0}),e}();UniversalService.decorators=[{type:core.Injectable}],UniversalService.ctorParameters=function(){return[{type:String,decorators:[{type:core.Inject,args:[core.PLATFORM_ID]}]},{type:ngxDeviceDetector.DeviceDetectorService}]};var emptyGuards=[],AclService=function(){function e(t,r,n){var i=this;this.injector=t,this.state=r,this.auth=n,this.components=[],this.auth.userChanged.subscribe((function(){i.components.forEach((function(e){return e.dirty=!0}));var t=i.getStateInfo();(t&&t.guard instanceof AuthGuard?t.guard.checkRoute(t.route):Promise.resolve(!0)).then((function(r){r?e.checkStateDirty(t):t.guard.getReturnState(t.route).then((function(e){e&&i.state.navigate(e)}))}))})),this.state.subscribe((function(){var t=i.getStateInfo();e.checkStateDirty(t)}))}return e.checkStateDirty=function(e){if(e&&e.dirty&&(e.dirty=!1,ObjectUtils.checkInterface(e.component,{onUserInitialized:"function",onUserChanged:"function"}))){var t=e.component;if(e.first)return t.onUserInitialized(),void(e.first=!1);t.onUserChanged()}},e.prototype.getStateInfo=function(){var e=this,t=this.state.route;if(!t)return null;var r=this.components.find((function(t){return t.route==e.state.route}));if(!r){var n=(t.canActivate||emptyGuards)[0];r={route:this.state.route,component:this.state.component,guard:n?this.injector.get(n):null,dirty:!1,first:!0},this.components.push(r)}return r},e}();AclService.decorators=[{type:core.Injectable}],AclService.ctorParameters=function(){return[{type:core.Injector},{type:StateService},{type:void 0,decorators:[{type:core.Inject,args:[AUTH_SERVICE]}]}]};var BaseHttpClient=function(e){function t(t){var r=e.call(this,t)||this;return r.requestHeaders={},r.requestParams={},r.extraRequestParams={language:"en"},r}return __extends(t,e),t.prototype.makeHeaders=function(e,t){void 0===t&&(t=!0);var r=(e=Object.assign({},this.requestHeaders,e)).Authorization||"";return t||r.startsWith("Bearer")||delete e.Authorization,new http.HttpHeaders(e)},t.prototype.makeParams=function(e){return e=Object.assign({},this.extraRequestParams,this.requestParams,e),new http.HttpParams({encoder:new http.HttpUrlEncodingCodec,fromObject:Object.keys(e||{}).reduce((function(t,r){var n=e[r];return t[r]=ObjectUtils.isObject(n)?JSON.stringify(n):ObjectUtils.isNullOrUndefined(n)?"":n.toString(),t}),{})})},t.prototype.setExtraRequestParam=function(e,t){void 0!==t?this.extraRequestParams[e]=t:delete this.extraRequestParams[e]},t}(http.HttpClient);BaseHttpClient.decorators=[{type:core.Injectable}],BaseHttpClient.ctorParameters=function(){return[{type:http.HttpHandler}]};var StorageService=function(){function e(e){this.universal=e}return e.prototype.get=function(e,t,r){if(void 0===r&&(r=exports.StorageMode.Local),this.universal.isServer)return t;var n=(r==exports.StorageMode.Local?localStorage:sessionStorage).getItem(e);if(!n)return t;try{return JSON.parse(n)}catch(e){return n}},e.prototype.set=function(e,t,r){if(void 0===r&&(r=exports.StorageMode.Local),!this.universal.isServer){var n=r==exports.StorageMode.Local?localStorage:sessionStorage;"string"!=typeof t?n.setItem(e,JSON.stringify(t)):n.setItem(e,t)}},e.prototype.remove=function(e,t){(void 0===t&&(t=exports.StorageMode.Local),this.universal.isServer)||(t==exports.StorageMode.Local?localStorage:sessionStorage).removeItem(e)},e}();StorageService.decorators=[{type:core.Injectable}],StorageService.ctorParameters=function(){return[{type:UniversalService}]};var BaseHttpService=function(){function e(e,t,r,n,i,o){void 0===o&&(o=null),this.client=e,this.storage=t,this.language=r,this.toaster=n,this.configs=i,this.request=o,this.cache={}}return Object.defineProperty(e.prototype,"name",{get:function(){return"base"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"withCredentials",{get:function(){return!0},enumerable:!1,configurable:!0}),e.retryFailedRequests=function(){e.failedRequests.forEach((function(e){return e()})),e.failedRequests=[]},Object.defineProperty(e.prototype,"universal",{get:function(){return this.storage.universal},enumerable:!1,configurable:!0}),e.prototype.url=function(e){return e},e.prototype.createUrl=function(e,t){var r=this.client.makeParams(t),n=r.keys().map((function(e){return e+"="+r.get(e)})).join("&");return this.url(e)+"?"+n},e.prototype.makeListParams=function(e,t,r,n,i){void 0===r&&(r=null),void 0===n&&(n=null),void 0===i&&(i=null);var o={page:e-1,limit:t};return ObjectUtils.isNullOrUndefined(r)||ObjectUtils.isNullOrUndefined(n)||(o.sort=(n?"-":"")+r),ObjectUtils.isNullOrUndefined(i)||(o.filter=i),o},e.prototype.getPromise=function(e,t,r){return t=this.makeOptions(t,"GET",r),this.toPromise(e,t)},e.prototype.deletePromise=function(e,t,r){return t=this.makeOptions(t,"DELETE",r),this.toPromise(e,t)},e.prototype.postPromise=function(e,t,r){return r=this.makeOptions(r,"POST",t),this.toPromise(e,r)},e.prototype.putPromise=function(e,t,r){return r=this.makeOptions(r,"PUT",t),this.toPromise(e,r)},e.prototype.patchPromise=function(e,t,r){return r=this.makeOptions(r,"PATCH",t),this.toPromise(e,r)},e.prototype.uploadPromise=function(e,t,r,n){var i={};return t instanceof Blob&&(i["Content-Type"]="application/octet-stream"),n=this.makeOptions(Object.assign({headers:i,reportProgress:!0},n),"POST",t),this.toPromise(e,n,r)},e.prototype.listPromise=function(e,t){var r=this;return new Promise((function(n){r.getPromise(e,{params:t}).then((function(e){var t,r;ObjectUtils.isArray(e)?n({total:e.length,items:e,meta:{}}):n({total:(null===(t=e.meta)||void 0===t?void 0:t.total)||(null==e?void 0:e.total)||(null===(r=e.items)||void 0===r?void 0:r.length)||0,items:e.items||[],meta:e.meta||{}})}),(function(e){return 0==e.status||301==e.status?(n({total:1,items:[{id:null,label:"Not implemented."}],meta:{}}),!0):(n({total:0,items:[],meta:{}}),!1)}))}))},e.prototype.handleUnauthorizedError=function(t,r,n){n(),e.failedRequests.length>1||this.universal.isServer||console.log("User auth error",t,r)},e.prototype.toastWarning=function(e,t,r,n){this.toaster.warning(e,{issueContext:t,reason:r,options:n})},e.prototype.toastError=function(e,t,r,n){this.toaster.warning(e,{issueContext:t,reason:r,options:n})},e.prototype.toPromise=function(t,r,n){var i=this,o={url:""};return new HttpPromise((function(e){if(e){var n=e.error||{};if(0!=e.status&&301!=e.status){var a=/((E11000 duplicate key error collection: (.)+\.)|(_1 dup key:(.)+))/g;n.message&&a.test(n.message)?i.toastError("message.duplicate-key.error."+n.message.replace(a,"").replace(" index: ","-"),o,n,r):i.toastWarning(t+" endpoint error is not handled properly! Click here, to quickly create an issue.",o,n,r)}else i.toastWarning(t+" endpoint is not implemented! Click here, to quickly create an issue.",o,n,r)}else{if(i.universal.isServer)return;console.log("You may not need a reject Handler for this request!",i.name,t,r)}}),(function(a,s){i.absoluteUrl(t,r).then((function(c){o.url=c;var u=i.client.request(r.method,c,r);(ObjectUtils.isNumber(r.timeout)&&r.timeout>0?u.pipe(operators.timeout(r.timeout)):u).subscribe((function(e){if(r.reportProgress&&e.type===http.HttpEventType.UploadProgress){var o={percentage:MathUtils.round(e.loaded/e.total,2,.01),loaded:e.loaded,total:e.total};n&&n(o)}else{var s=e instanceof http.HttpResponse?e.body:e;a(i.parseResponse(s,t,r));var c=r.headers;if(i.client.renewTokenFunc&&c.has("Authorization")){var u=(new Date).getTime();u-6e5>(i.storage.get("userTokenTime")||u)&&i.client.renewTokenFunc()}}}),(function(o){if(o instanceof rxjs.TimeoutError||0==o.status||301==o.status)s(o);else{if(r.headers.has("Authorization")&&401==o.status)return e.failedRequests.push((function(){r.headers=i.makeHeaders(r.originalHeaders),i.toPromise(t,r,n).then(a,s)})),void i.handleUnauthorizedError(c,r,(function(){return s(o)}));s(o)}}))}))}))},e.prototype.checkHeaders=function(e){return!!(e&&e.cookie&&e.referer&&e.host)&&e.referer.indexOf(e.host)>=0},e.prototype.makeOptions=function(e,t,r){void 0===t&&(t="GET"),(e=e?Object.assign({},e):{}).params=this.client.makeParams(e.params),e.observe="body",e.originalHeaders=e.originalHeaders||e.headers||{},e.method=t,e.withCredentials=ObjectUtils.isBoolean(e.withCredentials)?e.withCredentials:this.withCredentials,e.body=r||{};var n=this.request?this.request.headers:null;return this.checkHeaders(n)&&(e.headers.Cookie=n.cookie),e.headers=this.makeHeaders(e.originalHeaders,t),e},e.prototype.makeHeaders=function(e,t){return void 0===t&&(t="GET"),this.client.makeHeaders(e)},e.prototype.parseResponse=function(e,t,r){return e},e.prototype.parseUrl=function(e){return this.url(e).replace(/(?:((?!:).\/)\/)/g,"$1")},e.prototype.absoluteUrl=function(e,t){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(r){return t=this.parseUrl(e),"api-docs"==e?[2,t.replace("/api","")]:[2,t]}))}))},e.prototype.expressRequestUrl=function(e){var t=this.request;if(!t||!e||e.startsWith("http")||e.startsWith("//"))return e;var r=e.startsWith("/")?"":"/";return t.protocol+"://"+t.get("host")+r+e},e}();BaseHttpService.failedRequests=[],BaseHttpService.decorators=[{type:core.Injectable}],BaseHttpService.ctorParameters=function(){return[{type:BaseHttpClient,decorators:[{type:core.Inject,args:[BaseHttpClient]}]},{type:StorageService,decorators:[{type:core.Inject,args:[StorageService]}]},{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]},{type:void 0,decorators:[{type:core.Inject,args:[TOASTER_SERVICE]}]},{type:void 0,decorators:[{type:core.Inject,args:[CONFIG_SERVICE]}]},{type:void 0,decorators:[{type:core.Optional},{type:core.Inject,args:[EXPRESS_REQUEST]}]}]};var ApiService=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"name",{get:function(){return"api"},enumerable:!1,configurable:!0}),t.prototype.url=function(e){return this.expressRequestUrl("/api/"+e)},t.prototype.get=function(e,t,r){return this.getPromise(e,t,r)},t.prototype.delete=function(e,t,r){return this.deletePromise(e,t,r)},t.prototype.post=function(e,t,r){return this.postPromise(e,t,r)},t.prototype.put=function(e,t,r){return this.putPromise(e,t,r)},t.prototype.patch=function(e,t,r){return this.patchPromise(e,t,r)},t.prototype.upload=function(e,t,r,n){return this.uploadPromise(e,t,r,n)},t.prototype.list=function(e,t){return this.listPromise(e,t)},t}(BaseHttpService);ApiService.decorators=[{type:core.Injectable}];var StaticAuthService=function(){function e(){this.isAuthenticated=!0,this.userChanged=new core.EventEmitter}return e.prototype.checkAuthenticated=function(){return Promise.resolve(this.isAuthenticated)},e.prototype.getReturnState=function(e){return null},e}(),ConfigService=function(){function e(e,t,r,n){var i=this;for(var o in void 0===r&&(r=null),void 0===n&&(n=null),this.http=e,this.universal=t,[])Object.defineProperty(Array.prototype,o,{enumerable:!1});var a="";if(this.universal.isBrowser){var s=document.currentScript;if(s){var c=s.src,u=c.split(".js");a=c.substr(0,u[0].lastIndexOf("/")+1)}}this.loadedConfig=Object.assign(a?{baseUrl:a}:{},r||{}),this.scriptParameters=n||{},this.loaderFunc=function(){return i.loader=i.loader||new Promise((function(e,t){i.loadJson().then((function(t){i.loadedConfig=t=Object.assign(i.loadedConfig,t),i.prepareConfig(t).then((function(t){t.baseUrl=t.baseUrl||"/",e(t)}))}),t)})),i.loader},this.initService()}return Object.defineProperty(e.prototype,"load",{get:function(){return this.loaderFunc},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"config",{get:function(){return this.loadedConfig},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"configUrl",{get:function(){return this.loadedConfig.baseUrl+"config/config.json"},enumerable:!1,configurable:!0}),e.prototype.initService=function(){},e.prototype.loadJson=function(){var e=this;if(this.universal.isServer)return Promise.resolve(this.loadedConfig);var t=this.configUrl;return new Promise((function(r,n){e.http.get(t).toPromise().then((function(e){r(e)}),(function(){n("Config file not found at: "+t)}))}))},e.prototype.prepareConfig=function(e){return Promise.resolve(e)},e.prototype.prepareUrl=function(e,t){var r=this.loadedConfig?this.loadedConfig.project:"";return e=(e=e?""+e.replace(/\/+$/,"")+t:t).replace("[project]",r),this.universal.isServer&&e.startsWith("//")?"http:"+e:e},e.prototype.getConfigValue=function(e){return this.loadedConfig[e]},e.prototype.getQueryParameter=function(e,t){t=t||(this.universal.isServer?"":window.location.href),e=e.replace(/[\[\]]/g,"\\$&");var r=new RegExp("[?&]"+e+"(=([^&#]*)|&|#|$)").exec(t);return r?r[2]?decodeURIComponent(r[2].replace(/\+/g," ")):"":null},e}();ConfigService.decorators=[{type:core.Injectable}],ConfigService.ctorParameters=function(){return[{type:http.HttpClient},{type:UniversalService},{type:IConfiguration,decorators:[{type:core.Optional},{type:core.Inject,args:[BASE_CONFIG]}]},{type:void 0,decorators:[{type:core.Optional},{type:core.Inject,args:[SCRIPT_PARAMS]}]}]};var ErrorHandlerService=function(e){function t(t){var r=e.call(this)||this;return r.injector=t,r.errorMap={},r}return __extends(t,e),t.prototype.handleError=function(e){try{this.universal=this.universal||this.injector.get(UniversalService)}catch(e){return}var t=new Date;try{this.errorCb=this.errorCb||this.injector.get(ERROR_HANDLER),this.errorCb("["+t+"]: "+e.message+"\n"+e.stack)}catch(r){if(this.universal.isServer)return void console.error("["+t+"]: "+e.message+"\n"+e.stack)}if(!this.universal.isServer){var r=btoa(unescape(encodeURIComponent(e.message+" "+e.stack)));if(!(this.errorMap[r]&&this.errorMap[r].getTime()>t.getTime()-5e3)){this.errorMap[r]=t;try{this.toaster=this.toaster||this.injector.get(TOASTER_SERVICE),this.toaster.error("["+t+"]: "+e.message+"\n"+e.stack)}catch(e){}console.error("["+t+"]: "+e.message+"\n"+e.stack)}}},t}(core.ErrorHandler);ErrorHandlerService.decorators=[{type:core.Injectable}],ErrorHandlerService.ctorParameters=function(){return[{type:core.Injector}]};var EventsService=function(){function e(){this.eventForwarded=new core.EventEmitter,this.stickyUpdated=new core.EventEmitter,this.languageChanged=new core.EventEmitter,this.sticky=!1}return Object.defineProperty(e.prototype,"isSticky",{get:function(){return this.sticky},enumerable:!1,configurable:!0}),e.prototype.event=function(e){this.eventForwarded.emit(e)},e.prototype.updateSticky=function(e){this.sticky=e,this.stickyUpdated.emit(e)},e}();EventsService.decorators=[{type:core.Injectable}],EventsService.ctorParameters=function(){return[]};var FormatterService=function(){function e(e){this.language=e}return Object.defineProperty(e.prototype,"defaultPrecision",{get:function(){return 2},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"defaultNumberFormat",{get:function(){return"num + ' mm'"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"defaultDivider",{get:function(){return 1},enumerable:!1,configurable:!0}),e.prototype.roundNumber=function(e,t,r){return MathUtils.round(e,this.getPrecision(t),r||this.defaultDivider)},e.prototype.formatNumber=function(e,t,r,n){r=this.getPrecision(r),n=n||this.defaultDivider;var i=((ObjectUtils.isNumber(e)?e:parseFloat(e)||0)/n).toLocaleString(this.language.currentLanguage,{minimumFractionDigits:r,maximumFractionDigits:r});return ObjectUtils.evaluate(t||this.defaultNumberFormat,{num:i})},e.prototype.formatMillimeter=function(e,t,r){return this.formatNumber(e,"num + ' mm'",t,r)},e.prototype.getPrecision=function(e){return ObjectUtils.isNumber(e)?e:this.defaultPrecision},e}();FormatterService.decorators=[{type:core.Injectable}],FormatterService.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var GlobalTemplateService=function(){function e(){this.templatesUpdated=new core.EventEmitter,this.globalTemplates={},this.componentModifiers={}}return e.prototype.get=function(e,t){var r=this.globalTemplates[e];if(!r)return null;var n=this.componentModifiers[e];return ObjectUtils.isFunction(n)&&t&&n(t),r},e.prototype.add=function(e,t){this.globalTemplates[e]=t,this.templatesUpdated.emit()},e.prototype.remove=function(e){delete this.globalTemplates[e],this.templatesUpdated.emit()},e.prototype.addComponentModifier=function(e,t){this.componentModifiers[e]=t},e}();GlobalTemplateService.decorators=[{type:core.Injectable}],GlobalTemplateService.ctorParameters=function(){return[]};var IconService=function(){function e(){this.iconsLoaded=new core.EventEmitter,this.disabled=!1}return Object.defineProperty(e.prototype,"isDisabled",{get:function(){return this.disabled},set:function(e){this.disabled=e,this.iconsLoaded.emit()},enumerable:!1,configurable:!0}),e.prototype.getIcon=function(e,t,r){return e="undefined"==typeof icons?e:icons[e]||e,t="undefined"==typeof icons?t:icons[t]||e,Promise.resolve(r?t:e)},e}();IconService.decorators=[{type:core.Injectable}],IconService.ctorParameters=function(){return[]};var StaticLanguageService=function(){function e(e,t,r,n){this.events=e,this.storage=t,this.configs=r,this.client=n,this.editLang=null,this.currentLang=null,this.disableTrans=!1,this.languageList=[],this.translations={none:{}},this.initService()}return Object.defineProperty(e.prototype,"defaultLanguage",{get:function(){return this.configs.getQueryParameter("lang")||this.storage.get("language",this.browserLang)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dictionary",{get:function(){return this.translations[this.currentLanguage]||{}},set:function(e){this.translations[this.currentLanguage]=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"languages",{get:function(){return this.languageList},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentLanguage",{get:function(){return this.currentLang||this.defaultLanguage},set:function(e){this.currentLang=e,this.events.languageChanged.emit(e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"editLanguage",{get:function(){return this.editLang||this.currentLanguage},set:function(e){this.editLang=e||this.currentLanguage},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"disableTranslations",{get:function(){return this.disableTrans},set:function(e){this.disableTrans=e,this.events.languageChanged.emit(this.currentLang)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"httpClient",{get:function(){return this.client},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"config",{get:function(){return this.configs.config},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"browserLang",{get:function(){if(this.universal.isServer||void 0===window.navigator)return"de";var e=(window.navigator.languages?window.navigator.languages[0]:null)||window.navigator.language||window.navigator.browserLanguage||window.navigator.userLanguage||null;return e?(["-","_"].forEach((function(t){e.indexOf(t)>=0&&(e=e.split(t)[0])})),e):e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"universal",{get:function(){return this.storage.universal},enumerable:!1,configurable:!0}),e.prototype.initService=function(){},e.prototype.addLanguages=function(e){var t=this;e.forEach((function(e){t.translations[e]={},t.languageList.push(e)}))},e.prototype.getTranslationSync=function(e,t){void 0===t&&(t=null);var r=(e||"").toLocaleLowerCase(),n=this.dictionary[r]||r;return this.interpolate(n==r?e:n,t)},e.prototype.getTranslation=function(e,t){if(!ObjectUtils.isString(e)||!e.length)throw new Error('Parameter "key" required');var r=ObjectUtils.getValue(this.dictionary,e,e)||e;return Promise.resolve(this.interpolate(r,t))},e.prototype.getTranslations=function(){for(var e=this,t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return new Promise((function(r){Promise.all(t.map((function(t){return e.getTranslation(t)}))).then((function(e){r(t.reduce((function(t,r,n){return t[r]=e[n],t}),{}))}))}))},e.prototype.getTranslationFromObject=function(e,t,r){return r=r||this.currentLanguage,this.interpolate(e&&e[r]||"")},e.prototype.getTranslationFromArray=function(e,t,r){r=r||this.currentLanguage;var n=e?e.find((function(e){return e.lang==r})):null;return this.interpolate(n?n.translation:"",t)},e.prototype.interpolate=function(e,t){return"string"==typeof e?this.interpolateString(e,t):"function"==typeof e?e(t):e},e.prototype.interpolateString=function(e,t){return e&&t?e.replace(/{{\s?([^{}\s]*)\s?}}/g,(function(e,r){var n=ObjectUtils.getValue(t,r);return ObjectUtils.isDefined(n)?n:e})):e},e}();StaticLanguageService.decorators=[{type:core.Injectable}],StaticLanguageService.ctorParameters=function(){return[{type:EventsService,decorators:[{type:core.Inject,args:[EventsService]}]},{type:StorageService,decorators:[{type:core.Inject,args:[StorageService]}]},{type:void 0,decorators:[{type:core.Inject,args:[CONFIG_SERVICE]}]},{type:BaseHttpClient}]};var LanguageService=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"currentLanguage",{get:function(){return this.currentLang||this.defaultLanguage},set:function(e){var t=this;this.useLanguage(e).then((function(){t.events.languageChanged.emit(e)}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"settings",{get:function(){var e=this.languageSettings.value;return e&&e.settings[this.currentLanguage]||{}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"$settings",{get:function(){var e=this;return this.loadSettings().then((function(t){return e.languageSettings.next(t)})),rxjs.combineLatest([this.languageSettings,this.events.languageChanged]).pipe(operators.map((function(e){var t=__read(e,2),r=t[0],n=t[1];return r&&r.settings[n]||{}})))},enumerable:!1,configurable:!0}),t.prototype.initService=function(){var e=this;this.client.setExtraRequestParam("language","de"),this.translationRequests={},this.languageSettings=new rxjs.BehaviorSubject(null),this.universal.isServer||(window.setLanguage=function(t){e.currentLanguage=t})},t.prototype.initFromSettings=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,r,n;return __generator(this,(function(i){switch(i.label){case 0:return e=this.defaultLanguage,[4,this.loadSettings()];case 1:return t=i.sent(),this.languageSettings.next(t),r=t.devLanguages||[],this.languageList=(t.languages||[]).filter((function(e){return r.indexOf(e)<0})),n=this.languages.indexOf(e)<0?t.defaultLanguage:e,[4,this.useLanguage(n)];case 2:return i.sent(),this.events.languageChanged.emit(n),[2]}}))}))},t.prototype.getTranslation=function(e,t){return void 0===t&&(t=null),__awaiter(this,void 0,void 0,(function(){var r,n,i;return __generator(this,(function(o){switch(o.label){case 0:if(!e)return[2,""];o.label=1;case 1:return o.trys.push([1,3,,4]),r=e.toLocaleLowerCase(),[4,this.loadDictionary()];case 2:return n=o.sent(),r in n?[2,this.interpolate(n[r],t)]:[2,this.interpolate(e,t)];case 3:return i=o.sent(),console.log("ERROR IN TRANSLATIONS",i),[2,e];case 4:return[2]}}))}))},t.prototype.useLanguage=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(r){switch(r.label){case 0:return e=this.languages.indexOf(e)<0?this.languages[0]:e,this.client.setExtraRequestParam("language",e),e==this.currentLang?[2,this.dictionary]:(this.storage.set("language",e),this.currentLang=e,[4,this.loadDictionary()]);case 1:return t=r.sent(),this.translations[e]=t,[2,t]}}))}))},t.prototype.loadDictionary=function(){var e=this,t=this.currentLanguage;return this.translationRequests[t]=this.translationRequests[t]||new Promise((function(r){e.httpClient.get(""+e.config.translationUrl+t).toPromise().then((function(e){e=e||{},r(Object.keys(e).reduce((function(t,r){return t[r.toLocaleLowerCase()]=e[r],t}),{}))}),(function(){r({})}))})),this.translationRequests[t]},t.prototype.loadSettings=function(){return this.settingsPromise=this.settingsPromise||this.client.get(this.config.translationUrl+"languageSettings").toPromise().then((function(e){return e}),(function(){return{languages:["de","en","hu"],devLanguages:[],defaultLanguage:"de",settings:{de:{},hu:{},end:{}}}})),this.settingsPromise},t}(StaticLanguageService);LanguageService.decorators=[{type:core.Injectable}];var OpenApiService=function(){function e(e){this.api=e}return e.prototype.getSchemas=function(){var e=this;return this.schemasPromise=this.schemasPromise||new Promise((function(t){e.api.get("api-docs").then((function(e){var r,n=(null===(r=e.components)||void 0===r?void 0:r.schemas)||e.definitions||{};Object.values(n).forEach((function(e){Object.keys(e.properties||{}).forEach((function(t){e.properties[t].id=t}))})),t(n)}),(function(){t({})}))})),this.schemasPromise},e.prototype.getSchema=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(r){switch(r.label){case 0:return[4,this.getSchemas()];case 1:return t=r.sent(),t[e]?[2,t[e]]:[2,null]}}))}))},e}();OpenApiService.decorators=[{type:core.Injectable}],OpenApiService.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[API_SERVICE]}]}]};var ConsoleToasterService=function(){function e(e){this.language=e}return e.prototype.error=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #BD362F; color: #ffffff")}))},e.prototype.info=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #2F96B4; color: #ffffff")}))},e.prototype.success=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #51A351; color: #ffffff")}))},e.prototype.warning=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #F89406; color: #ffffff")}))},e.prototype.translateMessage=function(e,t,r){this.language.getTranslation(e,t).then(r)},e}();ConsoleToasterService.decorators=[{type:core.Injectable}],ConsoleToasterService.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var TranslatedUrlSerializer=function(e){function t(t){var r=e.call(this)||this;return r.language=t,r.cache={},r}return __extends(t,e),t.prototype.serialize=function(t){var r=new router.UrlTree,n=this.getDictionary(!0);return r.root=this.modifyTreeRecursive(t.root,(function(e){e.path=n[e.path]||e.path})),r.queryParams=t.queryParams,e.prototype.serialize.call(this,r)},t.prototype.parse=function(t){var r=e.prototype.parse.call(this,t),n=this.getDictionary(!1);return r.root=this.modifyTreeRecursive(r.root,(function(e){e.path=n[e.path]||e.path})),r},t.prototype.getDictionary=function(e){var t=e?"serialize":"parse",r=this.language.currentLanguage+"-"+t;if(!this.cache[r]){var n=this.language.dictionary;this.cache[r]=Object.keys(n).reduce((function(t,r){if(!r.startsWith("route."))return t;var i=n[r];return r=r.replace("route.",""),t[e?r:i]=e?i:r,t}),{})}return this.cache[r]},t.prototype.modifyTreeRecursive=function(e,t){var r=this;if(!e)return null;var n=[],i=Object.keys(e.children||{}).reduce((function(i,o){var a=r.modifyTreeRecursive(e.children[o],t);return n.push(a),i[o]=a,i}),{}),o=new router.UrlSegmentGroup(e.segments.map((function(e){return e=new router.UrlSegment(e.path,Object.assign({},e.parameters)),t(e),e})),i);return n.forEach((function(e){e.parent=o})),o},t}(router.DefaultUrlSerializer);TranslatedUrlSerializer.decorators=[{type:core.Injectable}],TranslatedUrlSerializer.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var PromiseService=function(){function e(e){this.zone=e,this.promiseCount=0,this.promiseChanged=new core.EventEmitter}return Object.defineProperty(e.prototype,"count",{get:function(){return this.promiseCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onChanged",{get:function(){return this.promiseChanged},enumerable:!1,configurable:!0}),e.prototype.create=function(e){return this.add(this.zone.runOutsideAngular((function(){return new Promise(e)})))},e.prototype.all=function(e){return this.add(this.zone.runOutsideAngular((function(){return Promise.all(e)})))},e.prototype.resolve=function(e){return this.add(this.zone.runOutsideAngular((function(){return Promise.resolve(e)})))},e.prototype.promiseFinished=function(){0!=this.promiseCount&&(this.promiseCount--,this.promiseChanged.emit(this.promiseCount))},e.prototype.add=function(e){var t=this;return this.promiseCount++,this.promiseChanged.emit(this.promiseCount),new Promise((function(r,n){e.then((function(e){r(e),t.promiseFinished()}),(function(e){n(e),t.promiseFinished()}))}))},e}();function emptyRemove(){}PromiseService.decorators=[{type:core.Injectable}],PromiseService.ctorParameters=function(){return[{type:core.NgZone,decorators:[{type:core.Inject,args:[core.NgZone]}]}]};var ResizeEventPlugin=function(e){function t(t,r){var n=e.call(this,t)||this;return n.universal=r,n}return __extends(t,e),t.prototype.supports=function(e){return e===t.EVENT_NAME},t.prototype.addEventListener=function(e,t,r){var n=this,i=this.manager.getZone();return i.runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove;var t=function(e){i.run((function(){return r(e)}))};return resizeDetector.addListener(e,t),function(){try{resizeDetector.removeListener(e,t)}catch(e){}}}))},t.prototype.addGlobalEventListener=function(e,t,r){var n=this;return this.manager.getZone().runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove;if(!StringUtils.has(e,"document","window"))return console.error("Global resize event other than window or document?",e),emptyRemove;var i="window"==e?window:document,o=r;return i.addEventListener(t,o),function(){return i.removeEventListener(t,o)}}))},t}(platformBrowser.ɵangular_packages_platform_browser_platform_browser_g);function emptyRemove$1(){}ResizeEventPlugin.EVENT_NAME="resize",ResizeEventPlugin.decorators=[{type:core.Injectable}],ResizeEventPlugin.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[common.DOCUMENT]}]},{type:UniversalService}]};var ScrollEventPlugin=function(e){function t(t,r){var n=e.call(this,t)||this;return n.universal=r,n}return __extends(t,e),t.prototype.supports=function(e){return e===t.EVENT_NAME},t.prototype.addEventListener=function(e,t,r){var n=this,i=this.manager.getZone();return i.runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove$1;var o=function(e){i.run((function(){return r(e)}))};return e.addEventListener(t,o),function(){return e.removeEventListener(t,o)}}))},t.prototype.addGlobalEventListener=function(e,t,r){var n=this;return this.manager.getZone().runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove$1;if(!StringUtils.has(e,"document","window"))return console.error("Global resize event other than window or document?",e),emptyRemove$1;var i="window"==e?window:document,o=r;return i.addEventListener(t,o),function(){return i.removeEventListener(t,o)}}))},t}(platformBrowser.ɵangular_packages_platform_browser_platform_browser_g);ScrollEventPlugin.EVENT_NAME="scroll",ScrollEventPlugin.decorators=[{type:core.Injectable}],ScrollEventPlugin.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[common.DOCUMENT]}]},{type:UniversalService}]};var ChunkPipe=function(){function e(){}return e.prototype.transform=function(e,t){var r=[],n=null;return e.forEach((function(e,i){i%t==0&&(n=[],r.push(n)),n.push(e)})),r},e}();ChunkPipe.decorators=[{type:core.Pipe,args:[{name:"chunk"}]}];var emptyEntries=[],EntriesPipe=function(){function e(){}return e.prototype.transform=function(e){if(!e)return emptyEntries;var t=[];return ObjectUtils.iterate(e,(function(e,r){t.push({key:r,value:e,index:t.length})})),t},e}();EntriesPipe.decorators=[{type:core.Pipe,args:[{name:"entries"}]}];var ExtraItemPropertiesPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===r&&(r={});var n=Object.keys(t);return n.forEach((function(e){var r=t[e];t[e]=ObjectUtils.isFunction(r)?r:function(e,t,n){return ObjectUtils.evaluate(r,{item:e,index:t,params:n})}})),(e||[]).map((function(e,i){return n.reduce((function(n,o){return n[o]=t[o](e,i,r),n}),Object.assign({},e))}))},e}();function defaultFilter(){return!0}ExtraItemPropertiesPipe.decorators=[{type:core.Pipe,args:[{name:"extraItemProperties"}]}];var FilterPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===t&&(t=defaultFilter),void 0===r&&(r={});var n=ObjectUtils.isObject(e);if(!n&&!ObjectUtils.isArray(e))return[];var i=ObjectUtils.isFunction(t)?t:function(e,r,n){return ObjectUtils.evaluate(t,{value:e,key:r,item:e,index:r,params:n})};return n?Object.keys(e).filter((function(t){return i(e[t],t,r)})).reduce((function(t,r){return t[r]=e[r],t}),{}):e.filter((function(e,t){return i(e,t,r)}))},e}();function defaultFilter$1(){return!0}FilterPipe.decorators=[{type:core.Pipe,args:[{name:"filter"}]}];var FindPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){if(void 0===t&&(t=defaultFilter$1),void 0===r&&(r={}),!ObjectUtils.isArray(e))return[];var n=ObjectUtils.isFunction(t)?t:function(e,r,n){return ObjectUtils.evaluate(t,{value:e,index:r,params:n})};return e.find((function(e,t){return n(e,t,r)}))},e}();FindPipe.decorators=[{type:core.Pipe,args:[{name:"find"}]}];var FormatNumberPipe=function(){function e(e){this.formatter=e}return e.prototype.transform=function(e,t,r,n){return this.formatter.formatNumber(e,t,r,n)},e}();FormatNumberPipe.decorators=[{type:core.Pipe,args:[{name:"formatNumber"}]}],FormatNumberPipe.ctorParameters=function(){return[{type:FormatterService}]};var GetOffsetPipe=function(){function e(){}return e.prototype.transform=function(e,t){return e?ObjectUtils.isNullOrUndefined(t)?e:e[t]:null},e}();GetOffsetPipe.decorators=[{type:core.Pipe,args:[{name:"getOffset"}]}];var GetTypePipe=function(){function e(){}return e.prototype.transform=function(e){return typeof e},e}();GetTypePipe.decorators=[{type:core.Pipe,args:[{name:"getType"}]}];var GlobalTemplatePipe=function(){function e(e){this.globalTemplates=e,this.cachedTemplateId=null,this.cachedTemplate=null}return e.prototype.ngOnInit=function(){var e=this;this.templatesUpdated=this.globalTemplates.templatesUpdated.subscribe((function(){e.cachedTemplate=null}))},e.prototype.ngOnDestroy=function(){this.templatesUpdated&&this.templatesUpdated.unsubscribe()},e.prototype.transform=function(e,t){return null!=this.cachedTemplate&&this.cachedTemplateId===e||(this.cachedTemplateId=e,this.cachedTemplate=this.globalTemplates.get(e,t)),this.cachedTemplate},e}();GlobalTemplatePipe.decorators=[{type:core.Pipe,args:[{pure:!1,name:"globalTemplate"}]}],GlobalTemplatePipe.ctorParameters=function(){return[{type:GlobalTemplateService}]};var GroupByPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===r&&(r=null);var n=(e||[]).reduce((function(e,n){var i=ObjectUtils.getValue(n,t)||"",o=r?r[i]||"":i,a=e[o]||[];return a.push(n),e[o]=a,e}),{});return Object.keys(n).map((function(e){return{group:e,items:n[e]}}))},e}();GroupByPipe.decorators=[{type:core.Pipe,args:[{name:"groupBy"}]}];var IsTypePipe=function(){function e(){}return e.prototype.transform=function(e,t){return typeof e===t},e}();IsTypePipe.decorators=[{type:core.Pipe,args:[{name:"isType"}]}];var JoinPipe=function(){function e(){}return e.prototype.transform=function(e,t){return void 0===t&&(t=", "),ObjectUtils.isArray(e)?e.join(t):""},e}();JoinPipe.decorators=[{type:core.Pipe,args:[{name:"join"}]}];var emptyKeys=[],KeysPipe=function(){function e(){}return e.prototype.transform=function(e){return e?ObjectUtils.isArray(e)?Array.from(e.keys()):Object.keys(e):emptyKeys},e}();function defaultMapper(e){return e}KeysPipe.decorators=[{type:core.Pipe,args:[{name:"keys"}]}];var MapPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){if(void 0===t&&(t=defaultMapper),void 0===r&&(r={}),!ObjectUtils.isArray(e))return[];var n=ObjectUtils.isFunction(t)?t:function(e,r,n){return ObjectUtils.evaluate(t,{value:e,index:r,params:n})};return e.map((function(e,t){return n(e,t,r)}))},e}();MapPipe.decorators=[{type:core.Pipe,args:[{name:"map"}]}];var MaxPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===t&&(t=null),void 0===r&&(r={}),t=t||function(e){return e};var n=ObjectUtils.isFunction(e)?e:function(e,r,n){return ObjectUtils.evaluate(t,{item:e,index:r,params:n})};return ArrayUtils.max(e,(function(e,t){return n(e,t,r)}))},e}();MaxPipe.decorators=[{type:core.Pipe,args:[{name:"max"}]}];var MinPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===t&&(t=null),void 0===r&&(r={}),t=t||function(e){return e};var n=ObjectUtils.isFunction(e)?e:function(e,r,n){return ObjectUtils.evaluate(t,{item:e,index:r,params:n})};return ArrayUtils.min(e,(function(e,t){return n(e,t,r)}))},e}();function defaultReducer(e){return e}MinPipe.decorators=[{type:core.Pipe,args:[{name:"min"}]}];var ReducePipe=function(){function e(){}return e.prototype.transform=function(e,t,r,n){if(void 0===r&&(r=defaultReducer),void 0===n&&(n={}),!ObjectUtils.isArray(e))return[];var i=ObjectUtils.isFunction(r)?r:function(e,t,n,i){return ObjectUtils.evaluate(r,{result:e,value:t,index:n,params:i})};return e.reduce((function(e,t,r){return i(e,t,r,n)}),t)},e}();ReducePipe.decorators=[{type:core.Pipe,args:[{name:"reduce"}]}];var empty={},RemapPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){return void 0===r&&(r="key"),e?t?ObjectUtils.filter({map:ObjectUtils.copy(e)},(function(n,i,o){return!ObjectUtils.isArray(n)||!n.every(ObjectUtils.isString)||(o[i]=n.reduce((function(n,i){return n[i]=ObjectUtils.getValue(t,i,ObjectUtils.evaluate(r,{key:i,map:e,source:t})),n}),{}),!1)})).map:e:empty},e}();RemapPipe.decorators=[{type:core.Pipe,args:[{name:"remap"}]}];var ReplacePipe=function(){function e(){}return e.prototype.transform=function(e,t,r){return e?e.replace(t,r):e},e}();ReplacePipe.decorators=[{type:core.Pipe,args:[{name:"replace"}]}];var emptyArray=[],ReversePipe=function(){function e(){}return e.prototype.transform=function(e){if(!ObjectUtils.isArray(e))return emptyArray;for(var t=[],r=e.length-1;r>=0;r--)t.push(e[r]);return t},e}();ReversePipe.decorators=[{type:core.Pipe,args:[{name:"reverse"}]}];var RoundPipe=function(){function e(e){this.formatter=e}return e.prototype.transform=function(e,t,r){return void 0===t&&(t=2),void 0===r&&(r=1),this.formatter.roundNumber(e,t,r)},e}();RoundPipe.decorators=[{type:core.Pipe,args:[{name:"round"}]}],RoundPipe.ctorParameters=function(){return[{type:FormatterService}]};var SafeHtmlPipe=function(){function e(e){this.sanitizer=e}return e.prototype.transform=function(e,t){switch(void 0===t&&(t="html"),t){case"html":return this.sanitizer.bypassSecurityTrustHtml(e);case"style":return this.sanitizer.bypassSecurityTrustStyle(e);case"script":return this.sanitizer.bypassSecurityTrustScript(e);case"url":return this.sanitizer.bypassSecurityTrustUrl(e);case"resourceUrl":return this.sanitizer.bypassSecurityTrustResourceUrl(e);default:throw new Error("SafePipe unable to bypass security for invalid type: "+t)}},e}();SafeHtmlPipe.decorators=[{type:core.Pipe,args:[{name:"safe"}]}],SafeHtmlPipe.ctorParameters=function(){return[{type:platformBrowser.DomSanitizer}]};var TranslatePipe=function(){function e(e,t){this.cdr=e,this.language=t}return Object.defineProperty(e.prototype,"currentLang",{get:function(){return this.language.currentLanguage},enumerable:!1,configurable:!0}),e.prototype.transform=function(e){for(var t=this,r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];if(!e)return"";var i=!1,o=this.currentLang;this.lang!==o&&(this.lang=o,i=!0);var a=this.language.disableTranslations;if(this.disabled!==a&&(this.disabled=a,i=!0),ObjectUtils.equals(this.query,e)||(this.query=e,i=!0),!ObjectUtils.equals(this.args,r)){if(this.args=r,this.params=null,ObjectUtils.isDefined(r[0])&&r.length)if("string"==typeof r[0]&&r[0].length){var s=r[0].replace(/(\')?([a-zA-Z0-9_]+)(\')?(\s)?:/g,'"$2":').replace(/:(\s)?(\')(.*?)(\')/g,':"$3"');try{this.params=JSON.parse(s)}catch(e){throw new SyntaxError("Wrong parameter in TranslatePipe. Expected a valid Object, received: "+r[0])}}else"object"!=typeof r[0]||Array.isArray(r[0])||(this.params=r[0]);i=!0}if(i){if("object"==typeof e)return this.lastValue=Array.isArray(e)?this.language.getTranslationFromArray(e,this.params,o):this.language.getTranslationFromObject(e,this.params,o),this.lastValue;if(this.disabled)return this.lastValue=e,this.lastValue;this.language.getTranslation(e,this.params).then((function(e){t.lastValue=e,t.cdr.destroyed||t.cdr.detectChanges()}))}return this.lastValue},e}();TranslatePipe.decorators=[{type:core.Injectable},{type:core.Pipe,args:[{name:"translate",pure:!1}]}],TranslatePipe.ctorParameters=function(){return[{type:core.ChangeDetectorRef},{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var emptyValues=[],ValuesPipe=function(){function e(){}return e.prototype.transform=function(e){return e?ObjectUtils.isArray(e)?e:Object.keys(e).map((function(t){return e[t]})):emptyValues},e}();ValuesPipe.decorators=[{type:core.Pipe,args:[{name:"values"}]}];var AsyncMethodDirective=function(){function e(e){this.toaster=e,this.onSuccess=new core.EventEmitter,this.onError=new core.EventEmitter}return Object.defineProperty(e.prototype,"isDisabled",{get:function(){return this.disabled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isLoading",{get:function(){return this.loading},enumerable:!1,configurable:!0}),e.prototype.click=function(){this.disabled||this.callMethod()},e.prototype.callMethod=function(){var e=this;this.loading||(this.loading=!0,this.method(this.context).then((function(t){e.loading=!1,t&&(e.onSuccess.emit(t),e.toaster.success(t.message,t.context))}),(function(t){if(!t||!t.message)throw new Error("Reason must implement IAsyncMessage interface");e.loading=!1,e.onError.emit(t),e.toaster.error(t.message,t.context)})))},e}();AsyncMethodDirective.decorators=[{type:core.Directive,args:[{selector:"[async-method]",exportAs:"async-method"}]}],AsyncMethodDirective.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[TOASTER_SERVICE]}]}]},AsyncMethodDirective.propDecorators={method:[{type:core.Input,args:["async-method"]}],disabled:[{type:core.Input}],context:[{type:core.Input}],onSuccess:[{type:core.Output}],onError:[{type:core.Output}],isDisabled:[{type:core.HostBinding,args:["class.disabled"]}],isLoading:[{type:core.HostBinding,args:["class.loading"]}],click:[{type:core.HostListener,args:["click"]}]};var defaultClass="default-image",loadingClass="loading-image",BackgroundDirective=function(){function e(e,t,r,n){this.http=e,this.element=t,this.renderer=r,this.universal=n}return e.prototype.ngOnChanges=function(e){var t=this;this.universal.isServer?this.setBackground(this.background):(this.renderer.removeClass(this.element.nativeElement,defaultClass),this.renderer.addClass(this.element.nativeElement,loadingClass),FileUtils.readDataFromUrl(this.http,this.background).then((function(e){t.setBackground(e)}),(function(){t.renderer.removeClass(t.element.nativeElement,loadingClass),t.renderer.addClass(t.element.nativeElement,defaultClass)})))},e.prototype.setBackground=function(e){this.renderer.removeClass(this.element.nativeElement,loadingClass),this.renderer.setStyle(this.element.nativeElement,"background-image","url('"+e+"')"),this.backgroundSize&&this.renderer.setStyle(this.element.nativeElement,"background-size",this.backgroundSize)},e}();BackgroundDirective.decorators=[{type:core.Directive,args:[{selector:"[background]"}]}],BackgroundDirective.ctorParameters=function(){return[{type:http.HttpClient},{type:core.ElementRef},{type:core.Renderer2},{type:UniversalService}]},BackgroundDirective.propDecorators={background:[{type:core.Input}],backgroundSize:[{type:core.Input}]};var DynamicTableTemplateDirective=function(e){this.ref=e};DynamicTableTemplateDirective.decorators=[{type:core.Directive,args:[{selector:"ng-template[column]"}]}],DynamicTableTemplateDirective.ctorParameters=function(){return[{type:core.TemplateRef}]},DynamicTableTemplateDirective.propDecorators={column:[{type:core.Input}],pure:[{type:core.Input}]};var GlobalTemplateDirective=function(){function e(e,t){this.globalTemplateService=e,this.template=t}return e.prototype.ngOnInit=function(){this.globalTemplateService.add(this.id,this.template)},e.prototype.ngOnDestroy=function(){this.globalTemplateService.remove(this.id)},e}();GlobalTemplateDirective.decorators=[{type:core.Directive,args:[{selector:"[globalTemplate]"}]}],GlobalTemplateDirective.ctorParameters=function(){return[{type:GlobalTemplateService},{type:core.TemplateRef}]},GlobalTemplateDirective.propDecorators={id:[{type:core.Input,args:["globalTemplate"]}]};var IconDirective=function(){function e(e,t,r){this.element=e,this.renderer=t,this.icons=r,this.renderer.addClass(this.element.nativeElement,"svg-icon"),this.activeChange=new core.EventEmitter}return Object.defineProperty(e.prototype,"isActive",{get:function(){return this.active},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;this.iconsLoaded=this.icons.iconsLoaded.subscribe((function(){return e.changeIcon()}))},e.prototype.ngOnDestroy=function(){this.iconsLoaded&&this.iconsLoaded.unsubscribe()},e.prototype.ngOnChanges=function(e){e.icon&&(this.renderer.removeClass(this.element.nativeElement,"svg-icon-"+e.icon.previousValue),this.renderer.addClass(this.element.nativeElement,"svg-icon-"+e.icon.currentValue)),this.changeIcon()},e.prototype.click=function(){this.active=!this.active,this.activeChange.emit(this.active),this.changeIcon()},e.prototype.changeIcon=function(){var e=this;this.icons.getIcon(this.icon,this.activeIcon||this.icon+"-active",this.active).then((function(t){e.icons.isDisabled||(e.element.nativeElement.innerHTML=t)}))},e}();IconDirective.decorators=[{type:core.Directive,args:[{selector:"[icon]"}]}],IconDirective.ctorParameters=function(){return[{type:core.ElementRef},{type:core.Renderer2},{type:void 0,decorators:[{type:core.Inject,args:[ICON_SERVICE]}]}]},IconDirective.propDecorators={icon:[{type:core.Input}],activeIcon:[{type:core.Input}],active:[{type:core.Input}],activeChange:[{type:core.Output}],isActive:[{type:core.HostBinding,args:["class.active"]}],click:[{type:core.HostListener,args:["click"]}]};var NgxTemplateOutletDirective=function(){function e(e){this._viewContainerRef=e}return e.hasContextShapeChanged=function(e){var t,r,n=Object.keys(e.previousValue||{}),i=Object.keys(e.currentValue||{});if(n.length===i.length){try{for(var o=__values(i),a=o.next();!a.done;a=o.next()){var s=a.value;if(-1===n.indexOf(s))return!0}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(t)throw t.error}}return!1}return!0},e.prototype.ngOnChanges=function(e){this.shouldRecreateView(e)&&(this.viewRef&&this._viewContainerRef.remove(this._viewContainerRef.indexOf(this.viewRef)),this.ngxTemplateOutlet&&(this.viewRef=this._viewContainerRef.createEmbeddedView(this.ngxTemplateOutlet,{}))),this.ngDoCheck()},e.prototype.ngDoCheck=function(){if(this.viewRef){var e=this.viewRef.context;this.updateExistingContext(this.context,e),this.updateExistingContext(this.additionalContext,e),e.$implicit=e}},e.prototype.shouldRecreateView=function(t){var r=t.context,n=t.additionalContext;return!!t.ngxTemplateOutlet||r&&e.hasContextShapeChanged(r)||n&&e.hasContextShapeChanged(n)},e.prototype.updateExistingContext=function(e,t){var r,n,i,o;if(e){var a=Object.getPrototypeOf(e);a==Object.prototype&&(a=e);var s=Object.getOwnPropertyNames(a);try{for(var c=__values(s),u=c.next();!u.done;u=c.next()){var l=u.value;if((h=Object.getOwnPropertyDescriptor(a,l)).get&&"$implicit"!==l)Object.defineProperty(t,l,h);else{var p=ObjectUtils.isFunction(h.value)?h.value.bind(e):null;p&&p!==a.constructor&&(t[l]=p)}}}catch(e){r={error:e}}finally{try{u&&!u.done&&(n=c.return)&&n.call(c)}finally{if(r)throw r.error}}try{for(var f=__values(Object.keys(e)),d=f.next();!d.done;d=f.next()){var h;l=d.value;(h=Object.getOwnPropertyDescriptor(a,l))&&h.get&&!h.set||(t[l]=e[l])}}catch(e){i={error:e}}finally{try{d&&!d.done&&(o=f.return)&&o.call(f)}finally{if(i)throw i.error}}}},e}();NgxTemplateOutletDirective.decorators=[{type:core.Directive,args:[{selector:"[ngxTemplateOutlet]"}]}],NgxTemplateOutletDirective.ctorParameters=function(){return[{type:core.ViewContainerRef}]},NgxTemplateOutletDirective.propDecorators={context:[{type:core.Input}],additionalContext:[{type:core.Input}],ngxTemplateOutlet:[{type:core.Input}]};var PaginationDirective=function(){function e(e){var t=this;this.zone=e,this.pageChange=new core.EventEmitter,this.onRefresh=new core.EventEmitter,this.updateTimer=TimerUtils.createTimeout((function(){return t.loadData()}),this.updateTime)}return Object.defineProperty(e.prototype,"total",{get:function(){return this.data?this.data.total:0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"items",{get:function(){return this.data?this.data.items:[]},enumerable:!1,configurable:!0}),e.prototype.ngOnChanges=function(e){(e.loader||e.itemsPerPage||e.page)&&(this.page=isNaN(this.page)||this.page<1?1:this.page,this.itemsPerPage=isNaN(this.itemsPerPage)||this.itemsPerPage<1?20:this.itemsPerPage,this.updateTimer.time=isNaN(this.updateTime)||this.updateTime<0?100:this.updateTime,this.waitFor=this.waitFor||Promise.resolve(!0),this.refresh())},e.prototype.refresh=function(){var e=this;this.waitFor.then((function(){e.updateTimer.run()}))},e.prototype.paginate=function(e){this.page=e,this.pageChange.emit(e),this.refresh()},e.prototype.loadData=function(){var e=this;this.loader&&this.loader(this.page,this.itemsPerPage).then((function(t){e.maxPage=!t||t.total<=0?1:Math.floor((t.total-1)/e.itemsPerPage)+1,e.data=t;var r=(e.page-1)*e.itemsPerPage,n=t.items||[];t.items=n.map((function(e,t){var i=r+t;return e instanceof PaginationItemContext?e:new PaginationItemContext(e,n,n.length,t,i)})),e.page>e.maxPage?e.paginate(e.maxPage):e.zone.run((function(){return e.onRefresh.emit(e)}))}))},e}();PaginationDirective.decorators=[{type:core.Directive,args:[{selector:"[pagination]",exportAs:"pagination"}]}],PaginationDirective.ctorParameters=function(){return[{type:core.NgZone}]},PaginationDirective.propDecorators={loader:[{type:core.Input,args:["pagination"]}],page:[{type:core.Input}],itemsPerPage:[{type:core.Input}],updateTime:[{type:core.Input}],waitFor:[{type:core.Input}],pageChange:[{type:core.Output}],onRefresh:[{type:core.Output}]};var PaginationItemDirective=function(){function e(e,t,r){this.pagination=e,this.viewContainer=t,this.templateRef=r}return e.prototype.ngOnInit=function(){var e=this;this.onRefresh=this.pagination.onRefresh.subscribe((function(){return e.renderView()}))},e.prototype.ngOnDestroy=function(){this.onRefresh.unsubscribe()},e.prototype.renderView=function(){var e=this;this.viewContainer.clear(),this.pagination.items.forEach((function(t){t.$implicit=t,e.viewContainer.createEmbeddedView(e.templateRef,t)}))},e}();PaginationItemDirective.decorators=[{type:core.Directive,args:[{selector:"[paginationItem]"}]}],PaginationItemDirective.ctorParameters=function(){return[{type:PaginationDirective},{type:core.ViewContainerRef},{type:core.TemplateRef}]};var ResourceIfDirective=function(){function e(e,t,r,n){this.http=e,this.viewContainer=t,this.templateRef=r,this.universal=n,this.context=new ResourceIfContext}return Object.defineProperty(e.prototype,"resourceIf",{get:function(){return this.resource},set:function(e){this.resource=e,this.renderView()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this.context.url},enumerable:!1,configurable:!0}),e.prototype.renderView=function(){var e=this;this.context=new ResourceIfContext,this.context.resource=this.resource,this.viewContainer.clear(),this.universal.isBrowser&&this.resource&&FileUtils.readDataFromUrl(this.http,this.resource).then((function(t){e.context.url=t,e.viewContainer.createEmbeddedView(e.templateRef,e.context)}),console.log)},e}();ResourceIfDirective.decorators=[{type:core.Directive,args:[{selector:"[resourceIf]",exportAs:"resourceIf"}]}],ResourceIfDirective.ctorParameters=function(){return[{type:http.HttpClient},{type:core.ViewContainerRef},{type:core.TemplateRef},{type:UniversalService}]},ResourceIfDirective.propDecorators={resourceIf:[{type:core.Input}]};var StickyDirective=function(){function e(e,t,r){var n=this;this.cdr=e,this.events=t,this.element=r,this.parentElement=this.element.nativeElement.parentElement,this.updateTimer=TimerUtils.createTimeout((function(){n.isUpdating=!1,n.cdr.detectChanges(),n.events.updateSticky(n.isSticky)}),10)}return e.prototype.ngOnInit=function(){var e=this;this.eventForwarded=this.events.eventForwarded.subscribe((function(t){t&&"scroll"===t.type&&e.updateSticky()}))},e.prototype.ngOnDestroy=function(){this.eventForwarded.unsubscribe()},e.prototype.updateSticky=function(){var e=this.parentElement.getBoundingClientRect().top;this.isSticky=e<1,this.isUpdating=!0,this.cdr.detectChanges(),this.updateTimer.run()},e}();StickyDirective.decorators=[{type:core.Directive,args:[{selector:"[sticky]"}]}],StickyDirective.ctorParameters=function(){return[{type:core.ChangeDetectorRef},{type:EventsService},{type:core.ElementRef}]},StickyDirective.propDecorators={isSticky:[{type:core.HostBinding,args:["class.sticky"]}],isUpdating:[{type:core.HostBinding,args:["class.sticky-update"]}],updateSticky:[{type:core.HostListener,args:["window:resize"]},{type:core.HostListener,args:["window:scroll"]}]};var UnorderedListItemDirective=function(){function e(e,t,r){this.elementRef=e,this.renderer=t,this.viewContainer=r}return Object.defineProperty(e.prototype,"elem",{get:function(){return this.elementRef.nativeElement},enumerable:!1,configurable:!0}),e.prototype.ngOnChanges=function(e){var t=this;this.templates&&this.defaultTemplates&&this.item&&(this.item.value instanceof Promise?this.item.value:Promise.resolve(this.item.value)).then((function(e){t.item.value=e,t.path=ObjectUtils.isNullOrUndefined(t.path)?"":t.path.toString(),t.isArray=ObjectUtils.isArray(t.data),t.isObject=ObjectUtils.isObject(t.data),t.valueIsArray=ObjectUtils.isArray(t.item.value),t.valueIsObject=ObjectUtils.isObject(t.item.value),t.valueType=ObjectUtils.getType(t.item.value);var r=t,n=t.templates.find((function(e){return e.type==t.type&&ObjectUtils.evaluate(e.selector,r)}))||t.defaultTemplates[t.type];t.viewContainer.clear(),t.viewContainer.createEmbeddedView(n,r),"item"===t.type&&(t.item.classList=[],t.isClass("is-array",t.valueIsArray),t.isClass("is-object",t.valueIsObject),t.isClass("is-value",!t.valueIsObject&&!t.valueIsArray),t.isClass("type-"+t.valueType),t.isClass("path-"+t.path.replace(/\./g,"-")),t.isClass("key-"+t.item.key))}),(function(e){console.log("Can't handle promise rejection",e)}))},e.prototype.isClass=function(e,t){void 0===t&&(t=!0),t&&this.item.classList.push(e)},e}();UnorderedListItemDirective.decorators=[{type:core.Directive,args:[{selector:"[unorderedListItem]"}]}],UnorderedListItemDirective.ctorParameters=function(){return[{type:core.ElementRef},{type:core.Renderer2},{type:core.ViewContainerRef}]},UnorderedListItemDirective.propDecorators={item:[{type:core.Input,args:["unorderedListItem"]}],type:[{type:core.Input}],data:[{type:core.Input}],keyPrefix:[{type:core.Input}],listStyle:[{type:core.Input}],path:[{type:core.Input}],level:[{type:core.Input}],templates:[{type:core.Input}],defaultTemplates:[{type:core.Input}]};var UnorderedListTemplateDirective=function(e){function t(t,r){var n=e.call(this)||this;return n.elementRef=t,n.templateRef=r,n}return __extends(t,e),t.prototype.createEmbeddedView=function(e){return this.templateRef.createEmbeddedView(e)},t}(UnorederedListTemplate);UnorderedListTemplateDirective.decorators=[{type:core.Directive,args:[{selector:"ng-template[type][selector]"}]}],UnorderedListTemplateDirective.ctorParameters=function(){return[{type:core.ElementRef},{type:core.TemplateRef}]},UnorderedListTemplateDirective.propDecorators={type:[{type:core.Input}],selector:[{type:core.Input}]};var UnorderedListComponent=function(){function e(e){this.cdr=e,this.keyPrefix="",this.listStyle="table",this.path="",this.level=0}return e.prototype.ngOnChanges=function(e){this.isArray=ObjectUtils.isArray(this.data),this.isObject=ObjectUtils.isObject(this.data)},e.prototype.ngAfterContentInit=function(){var e=this.templateDirectives.toArray();this.templates=this.templates?this.templates.concat(e):e,this.cdr.detectChanges()},e.prototype.ngAfterViewInit=function(){this.defaultTemplates={key:this.defaultKeyTemplate,value:this.defaultValueTemplate,item:this.defaultItemTemplate},this.cdr.detectChanges()},e}();UnorderedListComponent.decorators=[{type:core.Component,args:[{selector:"unordered-list",template:'<ng-template let-keyPrefix="keyPrefix" let-key="item.key" let-isArray="isArray" #defaultKeyTemplate>\r\n {{ (keyPrefix ? keyPrefix + key : key) | translate }}:\r\n</ng-template>\r\n<ng-template let-keyPrefix="keyPrefix" let-listStyle="listStyle" let-val="item.value" let-path="path"\r\n let-templates="templates" let-isObject="valueIsObject" let-isArray="valueIsArray" #defaultValueTemplate>\r\n <ng-template #value>{{ val }}</ng-template>\r\n <unordered-list [data]="val"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path"\r\n [level]="level + 1"\r\n [templates]="templates"\r\n *ngIf="(isObject || isArray); else value"></unordered-list>\r\n</ng-template>\r\n<ng-template let-item="item" let-data="data" let-keyPrefix="keyPrefix" let-listStyle="listStyle" let-path="path" let-level="level" let-templates="templates" #defaultItemTemplate>\r\n <ng-template #itemKey>\r\n <ng-container [unorderedListItem]="item"\r\n type="key"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </ng-template>\r\n <ng-template #itemValue>\r\n <ng-container [unorderedListItem]="item"\r\n type="value"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </ng-template>\r\n <ng-container *ngIf="!isArray">\r\n <th *ngIf="listStyle == \'table\'; else itemKey">\r\n <ng-container [ngTemplateOutlet]="itemKey"></ng-container>\r\n </th>\r\n </ng-container>\r\n <td *ngIf="listStyle == \'table\'; else itemValue">\r\n <ng-container [ngTemplateOutlet]="itemValue"></ng-container>\r\n </td>\r\n</ng-template>\r\n<ng-template #value>\r\n {{ data }}\r\n</ng-template>\r\n<ng-container *ngIf="(isObject || isArray); else value" [ngSwitch]="listStyle">\r\n <ul [ngClass]="\'level-\' + level" *ngSwitchCase="\'list\'">\r\n <li *ngFor="let item of data | entries" [ngClass]="item.classList">\r\n <ng-container [unorderedListItem]="item"\r\n type="item"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path ? path + \'.\' + item.key : item.key"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </li>\r\n </ul>\r\n <table [ngClass]="\'level-\' + level" *ngSwitchDefault>\r\n <tr *ngFor="let item of data | entries" [ngClass]="item.classList">\r\n <ng-container [unorderedListItem]="item"\r\n type="item"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path ? path + \'.\' + item.key : item.key"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </tr>\r\n </table>\r\n</ng-container>\r\n'}]}],UnorderedListComponent.ctorParameters=function(){return[{type:core.ChangeDetectorRef}]},UnorderedListComponent.propDecorators={data:[{type:core.Input}],keyPrefix:[{type:core.Input}],listStyle:[{type:core.Input}],path:[{type:core.Input}],level:[{type:core.Input}],templates:[{type:core.Input}],templateDirectives:[{type:core.ContentChildren,args:[UnorderedListTemplateDirective]}],defaultKeyTemplate:[{type:core.ViewChild,args:["defaultKeyTemplate"]}],defaultValueTemplate:[{type:core.ViewChild,args:["defaultValueTemplate"]}],defaultItemTemplate:[{type:core.ViewChild,args:["defaultItemTemplate"]}]};var DynamicTableComponent=function(){function e(){var e=this;this.loadData=function(t,r){var n=e.orders[e.orderBy];return e.dataLoader(t,r,n,e.orderDescending,e.filter)},this.dataLoader=this.loadLocalData,this.placeholder="",this.tableId=UniqueUtils.uuid(),this.templates={},this.filter="",this.orders={}}return Object.defineProperty(e.prototype,"items",{get:function(){return this.pagination?this.pagination.items:[]},enumerable:!1,configurable:!0}),e.compare=function(e,t,r){return t=t.item?t.item[e]:null,r=r.item?r.item[e]:null,ObjectUtils.compare(t,r)},e.prototype.ngAfterContentInit=function(){this.templates=this.templateDirectives.reduce((function(e,t){return ObjectUtils.isArray(t.column)?(t.column.forEach((function(r){e[r]=t})),e):ObjectUtils.isString(t.column)&&0!=t.column.length?(e[t.column]=t,e):e}),{})},e.prototype.ngAfterViewInit=function(){this.rowTemplate=this.rowTemplate||this.defaultRowTemplate,this.filterTemplate=this.filterTemplate||this.defaultFilterTemplate},e.prototype.ngOnChanges=function(e){if(e.columns){var t=e.columns.currentValue||[];this.orders=ObjectUtils.isArray(t)?t.reduce((function(e,t){return e[t]=t,e}),{}):t,this.cols=Object.keys(this.orders),this.orderBy=this.orderBy in this.orders?this.orderBy:this.columns[0]}e.orderBy&&this.orders&&(this.orderBy=this.orderBy in this.orders?this.orderBy:this.columns[0]),(e.data||e.parallelData||e.itemsPerPage||e.orderBy||e.orderDescending)&&this.refresh()},e.prototype.refresh=function(){this.pagination&&this.pagination.refresh()},e.prototype.setFilter=function(e){this.filter=e,this.refresh()},e.prototype.setOrder=function(e){this.orderDescending=e==this.orderBy&&!this.orderDescending,this.orderBy=e,this.refresh()},e.prototype.loadLocalData=function(t,r,n,i,o){if(!this.data)return Promise.resolve({total:0,items:[]});var a=i?function(t,r){return e.compare(n,r,t)}:function(t,r){return e.compare(n,t,r)},s=(t-1)*r,c=this.data.length,u=Math.min(r,c-s),l=this.parallelData||[],p=this.data.map((function(e,t){return new PaginationItemContext(e,l[t]||{},c,t,t)}));if(ObjectUtils.isString(o)&&o.length>0){var f=new RegExp(o,"gi");p=p.filter((function(e){return e.filter(f)}))}var d=n?p.sort(a).splice(s,u):p.splice(s,u);return d.forEach((function(e,t){e.index=s+t})),Promise.resolve({total:c,items:d})},e}();DynamicTableComponent.decorators=[{type:core.Component,args:[{selector:"dynamic-table",template:'<div class="dynamic-table" #pagination="pagination" [pagination]="loadData" [itemsPerPage]="itemsPerPage" [updateTime]="updateTime">\r\n <ng-template #defaultFilterTemplate let-table>\r\n <div class="table-search" *ngIf="table.showFilter">\r\n <label *ngIf="label" [attr.for]="tableId">{{ label | translate }}</label>\r\n <input type="text"\r\n class="form-control"\r\n [attr.id]="tableId"\r\n [placeholder]="placeholder | translate"\r\n [ngModel]="table.filter"\r\n (ngModelChange)="table.setFilter($event)"/>\r\n </div>\r\n </ng-template>\r\n <ng-container [ngxTemplateOutlet]="filterTemplate || defaultFilterTemplate" [context]="this"></ng-container>\r\n <pagination-menu [maxSize]="maxPages" [directionLinks]="directionLinks" [boundaryLinks]="boundaryLinks"></pagination-menu>\r\n <div class="table-responsive">\r\n\r\n <ng-template #columnTemplate let-context let-column="column" let-template="template">\r\n <ng-template #defaultTemplate let-column="column" let-item="item">\r\n <span>{{ item[column] == undefined || item[column] == null ? \'-\' : item[column] }}</span>\r\n </ng-template>\r\n <ng-template #pureTemplate>\r\n <ng-container [ngxTemplateOutlet]="template.ref" [context]="context"></ng-container>\r\n </ng-template>\r\n <td [ngClass]="\'column-\' + column" *ngIf="!template || !template.pure; else pureTemplate">\r\n <ng-container [ngxTemplateOutlet]="!template ? defaultTemplate : template.ref" [context]="context"></ng-container>\r\n </td>\r\n </ng-template>\r\n\r\n <ng-template #columnsTemplate let-context>\r\n <ng-container *ngFor="let column of cols"\r\n [ngxTemplateOutlet]="columnTemplate"\r\n [context]="context"\r\n [additionalContext]="{\r\n template: templates[column],\r\n column: column\r\n }"></ng-container>\r\n </ng-template>\r\n\r\n <ng-template #defaultRowTemplate let-context>\r\n <tr>\r\n <ng-container [ngxTemplateOutlet]="columnsTemplate" [context]="context"></ng-container>\r\n </tr>\r\n </ng-template>\r\n\r\n <ng-template #defaultWrapperTemplate>\r\n <table class="table table-striped">\r\n <thead>\r\n <tr>\r\n <th *ngFor="let column of cols" [ngClass]="\'column-\' + column">\r\n <a *ngIf="orders[column]" (click)="setOrder(column)">\r\n <span>{{ \'label.\' + column | translate }}</span>\r\n <i *ngIf="orderBy == column"\r\n [icon]="orderDescending ? \'sort-desc\' : \'sort-asc\'"\r\n [ngClass]="orderBy == column ? (orderDescending ? \'sort-desc\': \'sort-asc\') : \'\'"></i>\r\n </a>\r\n <span *ngIf="!orders[column]">{{ \'label.\' + column | translate }}</span>\r\n </th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <ng-container *paginationItem="let context"\r\n [ngxTemplateOutlet]="rowTemplate"\r\n [context]="context"\r\n [additionalContext]="this"></ng-container>\r\n </tbody>\r\n </table>\r\n </ng-template>\r\n\r\n <ng-container [ngxTemplateOutlet]="wrapperTemplate || defaultWrapperTemplate"\r\n [context]="this"></ng-container>\r\n </div>\r\n <pagination-menu [maxSize]="maxPages" [directionLinks]="directionLinks" [boundaryLinks]="boundaryLinks"></pagination-menu>\r\n</div>\r\n'}]}],DynamicTableComponent.ctorParameters=function(){return[]},DynamicTableComponent.propDecorators={label:[{type:core.Input}],placeholder:[{type:core.Input}],dataLoader:[{type:core.Input}],data:[{type:core.Input}],parallelData:[{type:core.Input}],columns:[{type:core.Input}],showFilter:[{type:core.Input}],itemsPerPage:[{type:core.Input}],updateTime:[{type:core.Input}],maxPages:[{type:core.Input}],directionLinks:[{type:core.Input}],boundaryLinks:[{type:core.Input}],orderBy:[{type:core.Input}],orderDescending:[{type:core.Input}],rowTemplate:[{type:core.ContentChild,args:["rowTemplate",{static:!0}]}],wrapperTemplate:[{type:core.ContentChild,args:["wrapperTemplate",{static:!0}]}],filterTemplate:[{type:core.ContentChild,args:["filterTemplate",{static:!0}]}],columnsTemplate:[{type:core.ViewChild,args:["columnsTemplate",{static:!0}]}],defaultRowTemplate:[{type:core.ViewChild,args:["defaultRowTemplate",{static:!0}]}],defaultWrapperTemplate:[{type:core.ViewChild,args:["defaultWrapperTemplate",{static:!0}]}],defaultFilterTemplate:[{type:core.ViewChild,args:["defaultFilterTemplate",{static:!0}]}],pagination:[{type:core.ViewChild,args:["pagination"]}],templateDirectives:[{type:core.ContentChildren,args:[DynamicTableTemplateDirective]}]};var PaginationMenuComponent=function(){function e(e,t,r){this.state=e,this.pagination=t,this.icons=r,this.maxSize=5,this.directionLinks=!0,this.boundaryLinks=!0,this.firstLabel="<<",this.prevLabel="<",this.nextLabel=">",this.lastLabel=">>"}return Object.defineProperty(e.prototype,"hasPrev",{get:function(){return this.pagination.page>1},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hasNext",{get:function(){return this.pagination.page<this.pagination.maxPage},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;this.onRefresh=this.pagination.onRefresh.subscribe((function(){return e.setPages()})),this.setIcon("firstLabel","first-page"),this.setIcon("prevLabel","prev-page"),this.setIcon("nextLabel","next-page"),this.setIcon("lastLabel","last-page")},e.prototype.ngOnDestroy=function(){this.onRefresh&&this.onRefresh.unsubscribe()},e.prototype.ngOnChanges=function(e){this.maxSize=isNaN(this.maxSize)||this.maxSize<=0?5:this.maxSize,this.directionLinks=!ObjectUtils.isBoolean(this.directionLinks)||this.directionLinks,this.boundaryLinks=!ObjectUtils.isBoolean(this.boundaryLinks)||this.boundaryLinks,this.setPages()},e.prototype.paginate=function(e){if(!(this.pagination.page==e||this.pagination.maxPage<e||e<1))if(this.urlParam){var t=Object.assign({},this.state.params);t[this.urlParam]=e.toString();var r=StateService.toPath(this.state.route,t);this.state.navigateByUrl(r)}else this.pagination.paginate(e)},e.prototype.setIcon=function(e,t){var r=this;this.icons.getIcon(t,t,!1).then((function(n){n!=t&&(r[e]=n)}))},e.prototype.setPages=function(){if(this.pagination){var e=this.pagination.maxPage,t=Math.max(this.pagination.page-Math.floor(this.maxSize/2),1),r=t+this.maxSize-1;r>e&&(r=e,t=Math.max(r-this.maxSize+1,1));for(var n=[],i=t;i<=r;i++)n.push(i);this.pages=n}},e}();PaginationMenuComponent.decorators=[{type:core.Component,args:[{selector:"pagination-menu",template:'<div class="pagination-menu" *ngIf="pagination.total > pagination.itemsPerPage">\r\n <ul class="pagination">\r\n <li class="page-item" [ngClass]="{disabled: !hasPrev}" *ngIf="boundaryLinks">\r\n <a class="page-link" (click)="paginate(1)" [innerHTML]="firstLabel | safe"></a>\r\n </li>\r\n <li class="page-item" [ngClass]="{disabled: !hasPrev}" *ngIf="directionLinks">\r\n <a class="page-link" (click)="paginate(pagination.page - 1)" [innerHTML]="prevLabel | safe"></a>\r\n </li>\r\n <li class="page-item" [ngClass]="{active: pagination.page == page}" *ngFor="let page of pages">\r\n <a class="page-link" [ngClass]="{active: pagination.page == page}" (click)="paginate(page)">{{ page }}</a>\r\n </li>\r\n <li class="page-item" [ngClass]="{disabled: !hasNext}" *ngIf="directionLinks">\r\n <a class="page-link" (click)="paginate(pagination.page + 1)" [innerHTML]="nextLabel | safe"></a>\r\n </li>\r\n <li class="page-item" [ngClass]="{disabled: !hasNext}" *ngIf="boundaryLinks">\r\n <a class="page-link" (click)="paginate(pagination.maxPage)" [innerHTML]="lastLabel | safe"></a>\r\n </li>\r\n </ul>\r\n</div>\r\n'}]}],PaginationMenuComponent.ctorParameters=function(){return[{type:StateService},{type:PaginationDirective},{type:void 0,decorators:[{type:core.Inject,args:[ICON_SERVICE]}]}]},PaginationMenuComponent.propDecorators={maxSize:[{type:core.Input}],urlParam:[{type:core.Input}],directionLinks:[{type:core.Input}],boundaryLinks:[{type:core.Input}]};var StickyClassDirective=function(){function e(e,t,r){this.events=e,this.element=t,this.renderer=r}return e.prototype.ngOnInit=function(){var e=this;this.stickyUpdated=this.events.stickyUpdated.subscribe((function(){e.events.isSticky?e.renderer.addClass(e.element.nativeElement,e.stickyClass||"sticky-sibling"):e.renderer.removeClass(e.element.nativeElement,e.stickyClass||"sticky-sibling")}))},e.prototype.ngOnDestroy=function(){this.stickyUpdated.unsubscribe()},e}();StickyClassDirective.decorators=[{type:core.Directive,args:[{selector:"[stickyClass]"}]}],StickyClassDirective.ctorParameters=function(){return[{type:EventsService},{type:core.ElementRef},{type:core.Renderer2}]},StickyClassDirective.propDecorators={stickyClass:[{type:core.Input}]};var pipes=[ChunkPipe,EntriesPipe,ExtraItemPropertiesPipe,FilterPipe,FindPipe,FormatNumberPipe,GetOffsetPipe,GetTypePipe,GlobalTemplatePipe,GroupByPipe,IsTypePipe,JoinPipe,KeysPipe,MapPipe,MaxPipe,MinPipe,ReducePipe,RemapPipe,ReplacePipe,ReversePipe,RoundPipe,SafeHtmlPipe,TranslatePipe,ValuesPipe],directives=[AsyncMethodDirective,BackgroundDirective,DynamicTableTemplateDirective,GlobalTemplateDirective,IconDirective,NgxTemplateOutletDirective,PaginationDirective,PaginationItemDirective,ResourceIfDirective,StickyDirective,StickyClassDirective,UnorderedListItemDirective,UnorderedListTemplateDirective],components=[DynamicTableComponent,PaginationMenuComponent,UnorderedListComponent],providers=__spread(pipes,[BaseHttpClient,BaseHttpService,AuthGuard,AclService,ApiService,StaticAuthService,ConfigService,ErrorHandlerService,EventsService,FormatterService,GlobalTemplateService,IconService,LanguageService,OpenApiService,PromiseService,StateService,StaticLanguageService,StorageService,ConsoleToasterService,TranslatedUrlSerializer,UniversalService,ngxDeviceDetector.DeviceDetectorService,{provide:platformBrowser.EVENT_MANAGER_PLUGINS,useClass:ResizeEventPlugin,multi:!0},{provide:platformBrowser.EVENT_MANAGER_PLUGINS,useClass:ScrollEventPlugin,multi:!0},{provide:router.UrlSerializer,useExisting:TranslatedUrlSerializer},{provide:core.ErrorHandler,useExisting:ErrorHandlerService}]);function loadConfig(e){return e.load}var NgxUtilsModule=function(){function e(){}return e.forRoot=function(t){return{ngModule:e,providers:__spread(providers,[{provide:API_SERVICE,useExisting:(t?t.apiService:null)||ApiService},{provide:AUTH_SERVICE,useExisting:(t?t.authService:null)||StaticAuthService},{provide:ICON_SERVICE,useExisting:(t?t.iconService:null)||IconService},{provide:LANGUAGE_SERVICE,useExisting:(t?t.languageService:null)||StaticLanguageService},{provide:TOASTER_SERVICE,useExisting:(t?t.toasterService:null)||ConsoleToasterService},{provide:PROMISE_SERVICE,useExisting:(t?t.promiseService:null)||PromiseService},{provide:CONFIG_SERVICE,useExisting:(t?t.configService:null)||ConfigService}],t&&t.configService?[{provide:core.APP_INITIALIZER,useFactory:loadConfig,multi:!0,deps:[CONFIG_SERVICE]}]:[])}},e}();NgxUtilsModule.decorators=[{type:core.NgModule,args:[{declarations:__spread(pipes,directives,components),imports:[common.CommonModule,forms.FormsModule],exports:__spread(pipes,directives,components,[forms.FormsModule]),providers:pipes}]}],exports.API_SERVICE=API_SERVICE,exports.AUTH_SERVICE=AUTH_SERVICE,exports.AclService=AclService,exports.AjaxRequestHandler=AjaxRequestHandler,exports.ApiService=ApiService,exports.ArrayUtils=ArrayUtils,exports.AsyncMethodDirective=AsyncMethodDirective,exports.AuthGuard=AuthGuard,exports.BASE_CONFIG=BASE_CONFIG,exports.BackgroundDirective=BackgroundDirective,exports.BaseHttpClient=BaseHttpClient,exports.BaseHttpService=BaseHttpService,exports.CONFIG_SERVICE=CONFIG_SERVICE,exports.CanvasColor=CanvasColor,exports.CanvasUtils=CanvasUtils,exports.ChunkPipe=ChunkPipe,exports.Circle=Circle,exports.ConfigService=ConfigService,exports.ConsoleToasterService=ConsoleToasterService,exports.DateUtils=DateUtils,exports.DynamicTableComponent=DynamicTableComponent,exports.DynamicTableTemplateDirective=DynamicTableTemplateDirective,exports.ERROR_HANDLER=ERROR_HANDLER,exports.EXPRESS_REQUEST=EXPRESS_REQUEST,exports.EntriesPipe=EntriesPipe,exports.ErrorHandlerService=ErrorHandlerService,exports.EventsService=EventsService,exports.ExtraItemPropertiesPipe=ExtraItemPropertiesPipe,exports.FactoryDependencies=FactoryDependencies,exports.FileUtils=FileUtils,exports.FilterPipe=FilterPipe,exports.FindPipe=FindPipe,exports.FormatNumberPipe=FormatNumberPipe,exports.FormatterService=FormatterService,exports.GenericValue=GenericValue,exports.GetOffsetPipe=GetOffsetPipe,exports.GetTypePipe=GetTypePipe,exports.GlobalTemplateDirective=GlobalTemplateDirective,exports.GlobalTemplatePipe=GlobalTemplatePipe,exports.GlobalTemplateService=GlobalTemplateService,exports.GroupByPipe=GroupByPipe,exports.HttpPromise=HttpPromise,exports.ICON_SERVICE=ICON_SERVICE,exports.IConfiguration=IConfiguration,exports.IconDirective=IconDirective,exports.IconService=IconService,exports.Initializer=Initializer,exports.IsTypePipe=IsTypePipe,exports.JoinPipe=JoinPipe,exports.KeysPipe=KeysPipe,exports.LANGUAGE_SERVICE=LANGUAGE_SERVICE,exports.LanguageService=LanguageService,exports.LoaderUtils=LoaderUtils,exports.MapPipe=MapPipe,exports.MathUtils=MathUtils,exports.MaxPipe=MaxPipe,exports.MinPipe=MinPipe,exports.NgxTemplateOutletDirective=NgxTemplateOutletDirective,exports.NgxUtilsModule=NgxUtilsModule,exports.ObjectUtils=ObjectUtils,exports.ObservableUtils=ObservableUtils,exports.OpenApiService=OpenApiService,exports.PROMISE_SERVICE=PROMISE_SERVICE,exports.PaginationDirective=PaginationDirective,exports.PaginationItemContext=PaginationItemContext,exports.PaginationItemDirective=PaginationItemDirective,exports.PaginationMenuComponent=PaginationMenuComponent,exports.Point=Point,exports.PromiseService=PromiseService,exports.Rect=Rect,exports.ReducePipe=ReducePipe,exports.ReflectUtils=ReflectUtils,exports.RemapPipe=RemapPipe,exports.ReplacePipe=ReplacePipe,exports.ResizeEventPlugin=ResizeEventPlugin,exports.ResourceIfContext=ResourceIfContext,exports.ResourceIfDirective=ResourceIfDirective,exports.ReversePipe=ReversePipe,exports.RoundPipe=RoundPipe,exports.SCRIPT_PARAMS=SCRIPT_PARAMS,exports.SafeHtmlPipe=SafeHtmlPipe,exports.ScrollEventPlugin=ScrollEventPlugin,exports.SetUtils=SetUtils,exports.StateService=StateService,exports.StaticAuthService=StaticAuthService,exports.StaticLanguageService=StaticLanguageService,exports.StickyDirective=StickyDirective,exports.StorageService=StorageService,exports.StringUtils=StringUtils,exports.TOASTER_SERVICE=TOASTER_SERVICE,exports.TimerUtils=TimerUtils,exports.TranslatePipe=TranslatePipe,exports.TranslatedUrlSerializer=TranslatedUrlSerializer,exports.UniqueUtils=UniqueUtils,exports.UniversalService=UniversalService,exports.UnorderedListComponent=UnorderedListComponent,exports.UnorderedListItemDirective=UnorderedListItemDirective,exports.UnorderedListTemplateDirective=UnorderedListTemplateDirective,exports.UnorederedListTemplate=UnorederedListTemplate,exports.ValuesPipe=ValuesPipe,exports.Vector=Vector,exports.ɵa=pipes,exports.ɵb=directives,exports.ɵc=components,exports.ɵd=providers,exports.ɵe=loadConfig,exports.ɵf=StickyClassDirective,Object.defineProperty(exports,"__esModule",{value:!0})}));
|
|
15
|
+
***************************************************************************** */var extendStatics=function(e,t){return(extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)};function __extends(e,t){function r(){this.constructor=e}extendStatics(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var __assign=function(){return(__assign=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function __rest(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]])}return r}function __decorate(e,t,r,n){var i,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(i=e[s])&&(a=(o<3?i(a):o>3?i(t,r,a):i(t,r))||a);return o>3&&a&&Object.defineProperty(t,r,a),a}function __param(e,t){return function(r,n){t(r,n,e)}}function __metadata(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)}function __awaiter(e,t,r,n){return new(r||(r=Promise))((function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}c((n=n.apply(e,t||[])).next())}))}function __generator(e,t){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],n=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}var __createBinding=Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]};function __exportStar(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||__createBinding(t,e,r)}function __values(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,o=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a}function __spread(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(__read(arguments[t]));return e}function __spreadArrays(){for(var e=0,t=0,r=arguments.length;t<r;t++)e+=arguments[t].length;var n=Array(e),i=0;for(t=0;t<r;t++)for(var o=arguments[t],a=0,s=o.length;a<s;a++,i++)n[i]=o[a];return n}function __await(e){return this instanceof __await?(this.v=e,this):new __await(e)}function __asyncGenerator(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n,i=r.apply(e,t||[]),o=[];return n={},a("next"),a("throw"),a("return"),n[Symbol.asyncIterator]=function(){return this},n;function a(e){i[e]&&(n[e]=function(t){return new Promise((function(r,n){o.push([e,t,r,n])>1||s(e,t)}))})}function s(e,t){try{(r=i[e](t)).value instanceof __await?Promise.resolve(r.value.v).then(c,u):l(o[0][2],r)}catch(e){l(o[0][3],e)}var r}function c(e){s("next",e)}function u(e){s("throw",e)}function l(e,t){e(t),o.shift(),o.length&&s(o[0][0],o[0][1])}}function __asyncDelegator(e){var t,r;return t={},n("next"),n("throw",(function(e){throw e})),n("return"),t[Symbol.iterator]=function(){return this},t;function n(n,i){t[n]=e[n]?function(t){return(r=!r)?{value:__await(e[n](t)),done:"return"===n}:i?i(t):t}:i}}function __asyncValues(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e="function"==typeof __values?__values(e):e[Symbol.iterator](),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(r){t[r]=e[r]&&function(t){return new Promise((function(n,i){(function(e,t,r,n){Promise.resolve(n).then((function(t){e({value:t,done:r})}),t)})(n,i,(t=e[r](t)).done,t.value)}))}}}function __makeTemplateObject(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var __setModuleDefault=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t};function __importStar(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&__createBinding(t,e,r);return __setModuleDefault(t,e),t}function __importDefault(e){return e&&e.__esModule?e:{default:e}}function __classPrivateFieldGet(e,t){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return t.get(e)}function __classPrivateFieldSet(e,t,r){if(!t.has(e))throw new TypeError("attempted to set private field on non-instance");return t.set(e,r),r}var defaultPredicate=function(){return!0},ɵ0=defaultPredicate,hasBlob="undefined"!=typeof Blob,hasFile="undefined"!=typeof File,ObjectUtils=function(){function ObjectUtils(){}return ObjectUtils.compare=function(e,t){return null===e||null===t||typeof e!=typeof t?null:"string"==typeof e?e.localeCompare(t):(e instanceof Date&&(e=e.getTime(),t=t.getTime()),e>t?1:e<t?-1:0)},ObjectUtils.getProperties=function(e){if(!ObjectUtils.isObject(e)&&!ObjectUtils.isFunction(e))return[];var t=new Set;return Object.keys(e).forEach((function(e){return t.add(e)})),Object.getOwnPropertyNames(e).forEach((function(e){return t.add(e)})),Array.from(t)},ObjectUtils.equals=function(e,t){if(e===t)return!0;if(null===e||null===t)return!1;if(e!=e&&t!=t)return!0;var r,n,i,o=typeof e;if(o==typeof t&&"object"==o){if(!Array.isArray(e)){if(Array.isArray(t))return!1;for(n in i=Object.create(null),e)if(e.hasOwnProperty(n)){if(!ObjectUtils.equals(e[n],t[n]))return!1;i[n]=!0}for(n in t)if(t.hasOwnProperty(n)&&!(n in i)&&void 0!==t[n])return!1;return!0}if(!Array.isArray(t))return!1;if((r=e.length)==t.length){for(n=0;n<r;n++)if(!ObjectUtils.equals(e[n],t[n]))return!1;return!0}}return!1},ObjectUtils.evaluate=function(expr,context,res){void 0===context&&(context={}),void 0===res&&(res={}),expr=Object.keys(context).reduce((function(e,t){return"var "+t+" = this['"+t+"']; "+e}),expr);var result=null;try{result=function(){return eval(expr)}.call(context)}catch(e){res.exception=e,console.log("Failed to parse expression: "+e.message,expr,context)}return res.result=result,result},ObjectUtils.empty=function(e){return!e||0==Object.keys(e).length},ObjectUtils.iterate=function(e,t){e&&(Array.isArray(e)?Array.from(e.keys()):Object.keys(e)).forEach((function(r){t(e[r],r)}))},ObjectUtils.getValue=function(e,t,r,n){void 0===n&&(n=!1);var i=(t=t||"").split("."),o="";do{o+=i.shift(),!ObjectUtils.isDefined(e)||!ObjectUtils.isDefined(e[o])||"object"!=typeof e[o]&&i.length?i.length?o+=".":(r=void 0===r?t.replace(new RegExp(o+"$"),"{"+o+"}"):r,e=n&&e||r):(e=e[o],o="")}while(i.length);return e},ObjectUtils.mapToPath=function(e,t,r){if(void 0===t)return e;if(0==r.length)return t;var n=r.shift();if("*"==n)return ObjectUtils.isArray(t)?(e=ObjectUtils.isArray(e)?e:[],t.map((function(t,n){return ObjectUtils.mapToPath(e[n],t,Array.from(r))}))):ObjectUtils.isObject(t)?(e=ObjectUtils.isObject(e)?e:{},Object.keys(t).reduce((function(n,i){return n[i]=ObjectUtils.mapToPath(e[i],t[i],Array.from(r)),n}),{})):ObjectUtils.isNullOrUndefined(e)?null:e;var i=ObjectUtils.isArray(e);return(e=ObjectUtils.isObject(e)||i?e:{})[n]=ObjectUtils.mapToPath(e[n],t,Array.from(r)),isNaN(n)||i?e:Object.values(e)},ObjectUtils.filter=function(e,t){return ObjectUtils.copyRecursive(null,e,t)},ObjectUtils.copy=function(e){return ObjectUtils.copyRecursive(null,e)},ObjectUtils.assign=function(e,t,r){return ObjectUtils.copyRecursive(e,t,r)},ObjectUtils.getType=function(e){var t=new RegExp("\\s([a-zA-Z]+)");return Object.prototype.toString.call(e).match(t)[1].toLowerCase()},ObjectUtils.isPrimitive=function(e){var t=typeof e;return null==e||"object"!==t&&"function"!==t},ObjectUtils.isObject=function(e){return"object"===ObjectUtils.getType(e)},ObjectUtils.isDefined=function(e){return null!=e},ObjectUtils.isNullOrUndefined=function(e){return void 0===e||null==e},ObjectUtils.isString=function(e){return"string"==typeof e},ObjectUtils.isFunction=function(e){return"function"==typeof e},ObjectUtils.isDate=function(e){return null!==e&&!isNaN(e)&&void 0!==e.getDate},ObjectUtils.isBlob=function(e){return hasBlob&&e instanceof Blob||hasFile&&e instanceof File},ObjectUtils.isBoolean=function(e){return"boolean"==typeof e},ObjectUtils.isNumber=function(e){if("number"!=typeof e)return!1;var t=+e;return t-t==0&&(t===e||void 0)},ObjectUtils.isArray=function(e){return Array.isArray(e)},ObjectUtils.isSet=function(e){return e instanceof Set},ObjectUtils.checkInterface=function(e,t){if(!e)return!1;for(var r in t)if(t.hasOwnProperty(r)&&typeof e[r]!==t[r])return!1;return!0},ObjectUtils.pad=function(e,t,r){void 0===r&&(r="0");var n=ObjectUtils.isDefined(e)?e.toString():"";return n.length>=t?n:new Array(t-n.length+1).join(r)+n},ObjectUtils.copyRecursive=function(e,t,r){return r=r||defaultPredicate,ObjectUtils.isPrimitive(t)||ObjectUtils.isDate(t)||ObjectUtils.isBlob(t)||ObjectUtils.isFunction(t)?t:ObjectUtils.isArray(t)?(e=ObjectUtils.isArray(e)?Array.from(e):[],t.forEach((function(n,i){r(n,i,e,t)&&(e.length>i?e[i]=ObjectUtils.copyRecursive(e[i],n,r):e.push(ObjectUtils.copyRecursive(null,n,r)))})),e):Object.keys(t).reduce((function(e,n){return r(t[n],n,e,t)?(e[n]=ObjectUtils.copyRecursive(e[n],t[n],r),e):e}),Object.assign({},e))},ObjectUtils}(),ReflectUtils=function(){function e(){}return e.defineMetadata=function(e,t,r,n){Reflect.defineMetadata(e,t,r,n)},e.getMetadata=function(e,t,r){return Reflect.getMetadata(e,t,r)},e.getOwnMetadata=function(e,t,r){return Reflect.getOwnMetadata(e,t,r)},e.resolve=function(t,r){if(!ObjectUtils.checkInterface(t,{func:"function"}))return t;var n=t,i=[];if(n.type){var o=ObjectUtils.getProperties(n.type).find((function(e){return n.type[e]===n.func}));i=e.getMetadata("factoryDependencies",n.type,o)||[]}else i=e.getMetadata("factoryDependencies",n.func)||[];var a=i.map((function(e){return r.get(e)})).concat(n.params);return n.func.apply(null,a)},e}(),CanvasColor=function(e,t,r,n){void 0===n&&(n=255),this.r=e,this.g=t,this.b=r,this.a=n},ICON_SERVICE=new core.InjectionToken("icon-service"),LANGUAGE_SERVICE=new core.InjectionToken("language-service"),AUTH_SERVICE=new core.InjectionToken("auth-service"),StorageMode;StorageMode=exports.StorageMode||(exports.StorageMode={}),StorageMode[StorageMode.Local=0]="Local",StorageMode[StorageMode.Session=1]="Session";var TOASTER_SERVICE=new core.InjectionToken("toaster-service"),PROMISE_SERVICE=new core.InjectionToken("promise-service"),UnorederedListTemplate=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),t}(core.TemplateRef);function FactoryDependencies(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t,r){ReflectUtils.defineMetadata("factoryDependencies",e,t,r)}}var PaginationItemContext=function(){function e(e,t,r,n,i){this.item=e,this.parallelItem=t,this.count=r,this.index=n,this.dataIndex=i}return Object.defineProperty(e.prototype,"first",{get:function(){return 0===this.index},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"last",{get:function(){return this.index===this.count-1},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"even",{get:function(){return this.index%2==0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"odd",{get:function(){return!this.even},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"row",{get:function(){return console.log("DynamicTable row is deprecated use item instead"),this.item},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parallelRow",{get:function(){return console.log("DynamicTable parallelRow is deprecated use parallelItem instead"),this.parallelItem},enumerable:!1,configurable:!0}),e.prototype.filter=function(e){var t,r,n=Object.keys(this.item);try{for(var i=__values(n),o=i.next();!o.done;o=i.next()){var a=o.value,s=this.item[a];if(!ObjectUtils.isNullOrUndefined(s)&&!ObjectUtils.isObject(s))if((ObjectUtils.isString(s)?s:s.toString()).match(e))return!0}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return!1},e}(),HttpPromise=function(e){function t(t,r){var n=e.call(this,r)||this;return n.rejectHandler=t,n.attachCount=0,n.runCount=0,n}return __extends(t,e),t.prototype.then=function(t,r){var n=this;return this.attachCount++,e.prototype.then.call(this,(function(e){return n.runCount++,t?t(e):null}),(function(e){var t=r?r(e):null;return n.hasRejectHandler=n.hasRejectHandler||r&&!1!==t,n.runCount++,n.rejectHandler(n.runCount!=n.attachCount||n.hasRejectHandler?null:e),t}))},t.prototype.catch=function(e){return this.then(null,e)},t}(Promise),EXPRESS_REQUEST=new core.InjectionToken("express-request"),API_SERVICE=new core.InjectionToken("api-service"),ResourceIfContext=function(){},IConfiguration=function(){},CONFIG_SERVICE=new core.InjectionToken("config-service"),BASE_CONFIG=new core.InjectionToken("base-config"),SCRIPT_PARAMS=new core.InjectionToken("script-params"),ERROR_HANDLER=new core.InjectionToken("error-handler-callback"),AjaxRequestHandler=function(){function e(t,r){var n=this;if(this.pattern=t,this.callback=r,this.listener=function(e){var t=e.detail;n.pattern.test(t.url)&&n.callback(t,n.params)},this.params={},"undefined"!=typeof XMLHttpRequest&&!e.isOverridden){e.isOverridden=!0;var i=XMLHttpRequest.prototype.open;XMLHttpRequest.prototype.open=function(e,t,r,n,o){i.apply(this,arguments),window.dispatchEvent(new CustomEvent("ajaxRequest",{detail:{request:this,method:e,url:t}}))}}}return e.prototype.listen=function(){return"undefined"==typeof window||window.addEventListener("ajaxRequest",this.listener),this},e.prototype.forget=function(){if("undefined"!=typeof window)return window.removeEventListener("ajaxRequest",this.listener),this},e}();AjaxRequestHandler.isOverridden=!1;var DateUtils=function(){function e(){}return e.isHoliday=function(e){return moment.utc(e).isoWeekday()>5},e.isBusinessDay=function(e){return moment.utc(e).isoWeekday()<6},e.add=function(e,t,r){return moment.utc(e).add(t,r).toDate()},e.businessAdd=function(t,r,n){for(var i=r<0?-1:1,o=Math.abs(r),a=t;o;)a=e.add(a,i,n),e.isBusinessDay(a)&&o--;return a},e.businessSubtract=function(t,r,n){return e.businessAdd(t,-r,n)},e}(),BlurStack=function(){this.r=0,this.g=0,this.b=0,this.a=0,this.next=null},mul_table=[512,512,456,512,328,456,335,512,405,328,271,456,388,335,292,512,454,405,364,328,298,271,496,456,420,388,360,335,312,292,273,512,482,454,428,405,383,364,345,328,312,298,284,271,259,496,475,456,437,420,404,388,374,360,347,335,323,312,302,292,282,273,265,512,497,482,468,454,441,428,417,405,394,383,373,364,354,345,337,328,320,312,305,298,291,284,278,271,265,259,507,496,485,475,465,456,446,437,428,420,412,404,396,388,381,374,367,360,354,347,341,335,329,323,318,312,307,302,297,292,287,282,278,273,269,265,261,512,505,497,489,482,475,468,461,454,447,441,435,428,422,417,411,405,399,394,389,383,378,373,368,364,359,354,350,345,341,337,332,328,324,320,316,312,309,305,301,298,294,291,287,284,281,278,274,271,268,265,262,259,257,507,501,496,491,485,480,475,470,465,460,456,451,446,442,437,433,428,424,420,416,412,408,404,400,396,392,388,385,381,377,374,370,367,363,360,357,354,350,347,344,341,338,335,332,329,326,323,320,318,315,312,310,307,304,302,299,297,294,292,289,287,285,282,280,278,275,273,271,269,267,265,263,261,259],shg_table=[9,11,12,13,13,14,14,15,15,15,15,16,16,16,16,17,17,17,17,17,17,17,18,18,18,18,18,18,18,18,18,19,19,19,19,19,19,19,19,19,19,19,19,19,19,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24],CanvasUtils=function(){function e(){}return e.manipulatePixels=function(e,t,r){for(var n=t.getImageData(0,0,e.width,e.height),i=n.data,o=0,a=i.length;o<a;o+=4){var s=new CanvasColor(i[o],i[o+1],i[o+2],i[o+3]),c=r(s,.3*s.r+.59*s.g+.11*s.b);i[o]=c.r,i[o+1]=c.g,i[o+2]=c.b,i[o+3]=c.a}t.putImageData(n,0,0)},e.thresholding=function(t,r,n,i){void 0===n&&(n=50);var o=new CanvasColor(0,0,0,255),a=new CanvasColor(0,0,0,0);i=ObjectUtils.isFunction(i)?i:function(e,t){return t?a:o},e.manipulatePixels(t,r,(function(e,t){return i(e,t>n,t)}))},e.stackBlur=function(e,t,r){if(void 0===r&&(r=10),!(isNaN(r)||r<1)){r|=0;var n=e.width,i=e.height,o=null;try{try{o=t.getImageData(0,0,n,i)}catch(e){try{netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead"),o=t.getImageData(0,0,n,i)}catch(e){throw alert("Cannot access local image"),new Error("unable to access local image data: "+e)}}}catch(e){throw alert("Cannot access image"),new Error("unable to access image data: "+e)}var a,s,c,u,l,p,f,d,h,g,m,y,v,b,P,S,x,O,j,I,w,C,E,T,U=o.data,R=r+r+1,k=n-1,D=i-1,_=r+1,A=_*(_+1)/2,L=new BlurStack,M=null,F=L;for(c=1;c<R;c++)F=F.next=new BlurStack,c==_&&(M=F);F.next=L;var N=null,V=null;f=p=0;var z=mul_table[r],B=shg_table[r];for(s=0;s<i;s++){for(S=x=O=j=d=h=g=m=0,y=_*(I=U[p]),v=_*(w=U[p+1]),b=_*(C=U[p+2]),P=_*(E=U[p+3]),d+=A*I,h+=A*w,g+=A*C,m+=A*E,F=L,c=0;c<_;c++)F.r=I,F.g=w,F.b=C,F.a=E,F=F.next;for(c=1;c<_;c++)u=p+((k<c?k:c)<<2),d+=(F.r=I=U[u])*(T=_-c),h+=(F.g=w=U[u+1])*T,g+=(F.b=C=U[u+2])*T,m+=(F.a=E=U[u+3])*T,S+=I,x+=w,O+=C,j+=E,F=F.next;for(N=L,V=M,a=0;a<n;a++)U[p+3]=E=m*z>>B,0!=E?(E=255/E,U[p]=(d*z>>B)*E,U[p+1]=(h*z>>B)*E,U[p+2]=(g*z>>B)*E):U[p]=U[p+1]=U[p+2]=0,d-=y,h-=v,g-=b,m-=P,y-=N.r,v-=N.g,b-=N.b,P-=N.a,u=f+((u=a+r+1)<k?u:k)<<2,d+=S+=N.r=U[u],h+=x+=N.g=U[u+1],g+=O+=N.b=U[u+2],m+=j+=N.a=U[u+3],N=N.next,y+=I=V.r,v+=w=V.g,b+=C=V.b,P+=E=V.a,S-=I,x-=w,O-=C,j-=E,V=V.next,p+=4;f+=n}for(a=0;a<n;a++){for(x=O=j=S=h=g=m=d=0,y=_*(I=U[p=a<<2]),v=_*(w=U[p+1]),b=_*(C=U[p+2]),P=_*(E=U[p+3]),d+=A*I,h+=A*w,g+=A*C,m+=A*E,F=L,c=0;c<_;c++)F.r=I,F.g=w,F.b=C,F.a=E,F=F.next;for(l=n,c=1;c<=r;c++)p=l+a<<2,d+=(F.r=I=U[p])*(T=_-c),h+=(F.g=w=U[p+1])*T,g+=(F.b=C=U[p+2])*T,m+=(F.a=E=U[p+3])*T,S+=I,x+=w,O+=C,j+=E,F=F.next,c<D&&(l+=n);for(p=a,N=L,V=M,s=0;s<i;s++)U[(u=p<<2)+3]=E=m*z>>B,E>0?(E=255/E,U[u]=(d*z>>B)*E,U[u+1]=(h*z>>B)*E,U[u+2]=(g*z>>B)*E):U[u]=U[u+1]=U[u+2]=0,d-=y,h-=v,g-=b,m-=P,y-=N.r,v-=N.g,b-=N.b,P-=N.a,u=a+((u=s+_)<D?u:D)*n<<2,d+=S+=N.r=U[u],h+=x+=N.g=U[u+1],g+=O+=N.b=U[u+2],m+=j+=N.a=U[u+3],N=N.next,y+=I=V.r,v+=w=V.g,b+=C=V.b,P+=E=V.a,S-=I,x-=w,O-=C,j-=E,V=V.next,p+=n}t.putImageData(o,0,0)}},e.measureTextFontSize=function(t,r,n,i,o,a){void 0===o&&(o=1.1);var s=r,c=a.getContext("2d");a||(a=document.createElement("canvas"),document.body.appendChild(a)),a.width=t+r,a.height=2*r;var u=e.halveValidateFontSize(s,(function(r){e.setFontProps(c,i,r);var o=e.getTextWidth(c,n);return t-o}));return e.getTextBitmapHeight(a,c,n,i,u,o)>r&&(u=e.halveValidateFontSize(u,(function(t){return r-e.getTextBitmapHeight(a,c,n,i,t,o)}))),u},e.drawLines=function(t,r,n,i,o,a,s,c,u){void 0===o&&(o=1.1),void 0===a&&(a="left"),void 0===s&&(s="top"),void 0===c&&(c=0),void 0===u&&(u=0),e.setFontProps(t,n,i,a,s);for(var l=0;l<r.length;l++){var p=r[l];t.fillText(p,c,u),l<r.length-1&&(u+=i*o)}return u},e.wrapText=function(e,t,r,n,i){for(var o=t.split(" "),a=1.3*e.measureText("M").width,s=[],c="",u=0;u<o.length;u++){var l=c+o[u]+" ";e.measureText(l).width>i&&u>0?(s.push(c),c=o[u]+" "):c=l}s.push(c),n-=.5*a*s.length,s.forEach((function(t){e.fillText(t,r,n),n+=a}))},e.setFontProps=function(e,t,r,n,i){void 0===n&&(n="left"),void 0===i&&(i="top"),e.font=r+"px "+t,e.textAlign=n,e.textBaseline=i},e.getTextWidth=function(e,t){for(var r=0,n=0;n<t.length;n++){var i=t[n];r=Math.max(r,e.measureText(i).width)}return r},e.getTextBitmapHeight=function(t,r,n,i,o,a){var s=t.width,c=t.height;r.clearRect(0,0,s,c);var u=e.drawLines(r,n,i,o,a,"left","top",.5*o,.5*o),l=r.getImageData(0,0,s,c),p=0;e:for(var f=0;f<c;f++)for(var d=0;d<s;d++){var h=4*(d+f*s);if(l.data[h+3]>0){p=f+1;continue e}}return Math.max(p,u+o)},e.halveValidateFontSize=function(e,t){for(var r=e,n=0,i=0;i<20;i++){var o=r;if(t(r)<0?r-=Math.abs(r-n)/2:r+=Math.abs(r-n)/2,n=o,Math.abs(r-n)<.1)break}return r=Math.floor(r)},e}(),FileUtils=function(){function e(){}return e.getExtension=function(e){return e?e.name.substr(e.name.lastIndexOf(".")).toLowerCase():null},e.getName=function(e){return e?e.name.substr(0,e.name.lastIndexOf(".")):null},e.toFile=function(e,t){var r=e;return r.lastModifiedDate=new Date,r.name=t.split(/\\|\//g).pop(),r},e.dataToBlob=function(e){for(var t=e.split(","),r=atob(t[1]),n=t[0].split(":")[1].split(";")[0],i=new ArrayBuffer(r.length),o=new Uint8Array(i),a=0;a<r.length;a++)o[a]=r.charCodeAt(a);return new Blob([i],{type:n})},e.saveBlob=function(e,t){if("undefined"==typeof saveAs)throw Error("FileSaver library is not loaded. Please load it: https://www.npmjs.com/package/file-saver");saveAs(e,t)},e.saveJson=function(t,r){ObjectUtils.isObject(t)&&e.saveBlob(new Blob([JSON.stringify(t,null,4)]),r)},e.readFileAsText=function(t){return e.readFile((function(e){return e.readAsText(t)}))},e.readFileAsBinaryString=function(t){return e.readFile((function(e){return e.readAsBinaryString(t)}))},e.readFileAsDataURL=function(t){return e.readFile((function(e){return e.readAsDataURL(t)}))},e.readDataFromUrl=function(t,r){return new Promise((function(n,i){r?/^([A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{4}|[A-Za-z0-9+/]{3}=|[A-Za-z0-9+/]{2}==)$/g.test(r)?n(r):operators.first()(t.get(r,{responseType:"blob"})).subscribe((function(t){e.readFileAsDataURL(t).then(n,i)}),(function(e){e.status>0?i(e):n(r)})):i({message:"The url is not specified"})}))},e.readFile=function(e){return new Promise((function(t,r){var n=new FileReader;n.onload=function(e){return t(e.target.result)},n.onerror=r,e(n)}))},e}(),GenericValue=function(e){function t(t){void 0===t&&(t=null);var r=e.call(this)||this;return r._value=t,r}return __extends(t,e),Object.defineProperty(t.prototype,"value",{get:function(){return this._value},set:function(e){e!=this._value&&(this._value=e,this.next(e))},enumerable:!1,configurable:!0}),t.prototype.setJustValue=function(e){this._value=e},t}(rxjs.Subject),Rect=function(){function e(e,t,r,n,i){void 0===i&&(i=0),this.x=e,this.y=t,this.width=r,this.height=n,this.rotation=i}return Object.defineProperty(e.prototype,"center",{get:function(){return new Point(this.x,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"left",{get:function(){return this.x-.5*this.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"right",{get:function(){return this.x+.5*this.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottom",{get:function(){return this.y-.5*this.height},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"top",{get:function(){return this.y+.5*this.height},enumerable:!1,configurable:!0}),e.prototype.distance=function(e){e=e.rotateAround(this.center,-this.rotation);var t=Math.max(this.left-e.x,0,e.x-this.right),r=Math.max(this.bottom-e.y,0,e.y-this.top);return Math.sqrt(t*t+r*r)},e}(),Circle=function(){function e(e,t,r){this.x=e,this.y=t,this.radius=r}return Object.defineProperty(e.prototype,"center",{get:function(){return new Point(this.x,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"left",{get:function(){return new Point(this.x-this.radius,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"right",{get:function(){return new Point(this.x+this.radius,this.y)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"top",{get:function(){return new Point(this.x,this.y+this.radius)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottom",{get:function(){return new Point(this.x,this.y-this.radius)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"rect",{get:function(){return new Rect(this.x,this.y,2*this.radius,2*this.radius)},enumerable:!1,configurable:!0}),e.prototype.distance=function(e){return this.center.distance(e)-this.radius},e}(),Point=function(){function e(e,t){this.x=e,this.y=t}return Object.defineProperty(e.prototype,"length",{get:function(){return this.distance(e.Zero)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"perpendicular",{get:function(){return new e(this.y,-this.x)},enumerable:!1,configurable:!0}),e.prototype.add=function(t){return new e(this.x+t.x,this.y+t.y)},e.prototype.subtract=function(t){return new e(this.x-t.x,this.y-t.y)},e.prototype.multiply=function(t){return t instanceof e?new e(this.x*t.x,this.y*t.y):new e(this.x*t,this.y*t)},e.prototype.distance=function(e){var t=e.x-this.x,r=e.y-this.y;return Math.sqrt(t*t+r*r)},e.prototype.lerp=function(e,t){var r=e.subtract(this);return this.add(r.multiply(t))},e.prototype.perpendicularTo=function(e,t){var r=e.perpendicular.subtract(this.perpendicular),n=t/r.length;return this.lerp(e,.5).add(r.multiply(n))},e.prototype.circleWith=function(t,r){var n=(r.y-t.y)/(r.x-t.x),i=(this.y-r.y)/(this.x-r.x),o=(n*i*(t.y-this.y)+i*(t.x+r.x)-n*(r.x+this.x))/(2*(i-n)),a=new e(o,-1*(o-(t.x+r.x)/2)/n+(t.y+r.y)/2);return new Circle(a.x,a.y,a.distance(this))},e.prototype.tangents=function(t){var r=t.center.subtract(this),n=Math.asin(t.radius/r.length),i=Math.atan2(r.y,r.x),o=i-n,a=new e(t.x+t.radius*Math.sin(o),t.y+t.radius*-Math.cos(o));return o=i+n,[a,new e(t.x+t.radius*-Math.sin(o),t.y+t.radius*Math.cos(o))]},e.prototype.angle=function(e){var t=e.subtract(this);return 180*Math.atan2(t.y,t.x)/Math.PI},e.prototype.rotateAround=function(t,r){var n=(t.angle(this)+r)*Math.PI/180,i=t.distance(this),o=new e(Math.cos(n)*i,Math.sin(n)*i);return t.add(o)},e}();Point.Zero=new Point(0,0);var Initializer=function(){function e(e,t){return void 0===t&&(t=!0),this.callback=e,this.shouldInit=t,this.initialized=!this.shouldInit,invokable.Invokable.create(this)}return e.prototype[invokable.Invokable.call]=function(){return this.initialized?null:(this.initialized=!0,this.callback())},e}(),LoaderUtils=function(){function e(){}return e.loadScript=function(e,t){return void 0===t&&(t=!1),this.scriptPromises[e]=this.scriptPromises[e]||new Promise((function(r,n){var i=document.createElement("script");i.type="text/javascript",i.src=e,i.async=t,i.readyState?i.onreadystatechange=function(){"loaded"!==i.readyState&&"complete"!==i.readyState||(i.onreadystatechange=null,r(i))}:i.onload=function(){return r(i)},i.onerror=function(e){return n(e)},document.body.appendChild(i)})),this.scriptPromises[e]},e.loadStyle=function(e){return this.stylePromises[e]=this.stylePromises[e]||new Promise((function(t,r){var n=document.createElement("link");n.rel="stylesheet",n.type="text/css",n.href=e,n.readyState?n.onreadystatechange=function(){"loaded"!==n.readyState&&"complete"!==n.readyState||(n.onreadystatechange=null,t(n))}:n.onload=function(){return t(n)},n.onerror=function(e){return r(e)},document.body.appendChild(n)})),this.stylePromises[e]},e}();LoaderUtils.scriptPromises={},LoaderUtils.stylePromises={};var MathUtils=function(){function e(){}return e.equal=function(e,t,r){return void 0===r&&(r=null),r=ObjectUtils.isNumber(r)?r:Math.E,Math.abs(e-t)<r},e.clamp=function(e,t,r){return Math.max(Math.min(e,r),t)},e.round=function(e,t,r){return void 0===t&&(t=2),void 0===r&&(r=1),t=Math.pow(10,t),Math.round(e*t/r)/t},e}(),emptySnapshot=new router.ActivatedRouteSnapshot,emptyData={id:""},emptyParams={},emptySegments=[],emptyComponents=[],StateService=function(e){function t(t,r,n){void 0===n&&(n=null);var i=e.call(this,null)||this;return i.injector=t,i.zone=r,i.router=n,i.handleRouterEvent=function(e){if(e instanceof router.NavigationEnd){for(var t=i.router.routerState.snapshot,r=t.root,n=i.contexts.getContext("primary"),o=r.url,a=[],s=[];r;)s.push(r),o=o.concat(r.url),n&&(n.outlet&&n.outlet.isActivated&&a.push(n.outlet.component),n=n.children.getContext("primary")),r=r.firstChild;i.comp=a[a.length-1],i.shot=s[s.length-1],i.stateInfo={url:t.url,segments:o,components:a},i.next(i.shot)}},i.router?(i.globalExtras={queryParamsHandling:"merge"},i.router.events.subscribe(i.handleRouterEvent),i.stateInfo={url:"",segments:[],components:[]},i.contexts=n.rootContexts,i):i}return __extends(t,e),t.toPath=function(e,t){var r=e.path||"";return ObjectUtils.iterate(t,(function(e,t){r=r.replace(":"+t,""+e)})),r},Object.defineProperty(t.prototype,"component",{get:function(){return this.comp},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"snapshot",{get:function(){return this.shot||emptySnapshot},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"route",{get:function(){return this.snapshot.routeConfig},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"data",{get:function(){return this.snapshot.data||emptyData},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"params",{get:function(){return this.snapshot.params||emptyParams},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"queryParams",{get:function(){return this.snapshot.queryParams||emptyParams},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"url",{get:function(){return this.stateInfo.url||""},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"urlSegments",{get:function(){return this.stateInfo.segments||emptySegments},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"components",{get:function(){return this.stateInfo.components||emptyComponents},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"routerConfig",{get:function(){return this.router.config},enumerable:!1,configurable:!0}),t.prototype.reload=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,r,n,i,o,a,s,c,u,l;return __generator(this,(function(p){switch(p.label){case 0:e=this.router.routerState.snapshot,t=this.route.resolve||{},r=Object.keys(t),p.label=1;case 1:p.trys.push([1,7,8,9]),n=__values(r),i=n.next(),p.label=2;case 2:return i.done?[3,6]:(o=i.value,a=this.injector.get(t[o]),(s=a.resolve(this.snapshot,e))instanceof rxjs.Observable&&(s=s.toPromise()),s instanceof Promise?[4,s]:[3,4]);case 3:s=p.sent(),p.label=4;case 4:this.data[o]=s,p.label=5;case 5:return i=n.next(),[3,2];case 6:return[3,9];case 7:return c=p.sent(),u={error:c},[3,9];case 8:try{i&&!i.done&&(l=n.return)&&l.call(n)}finally{if(u)throw u.error}return[7];case 9:return[2]}}))}))},t.prototype.navigate=function(e,t){if(!this.router)return Promise.resolve(!1);t=Object.assign({},this.globalExtras,t||{});var r=this.router.createUrlTree(e,t);return this.navigateByUrl(r,t)},t.prototype.navigateByUrl=function(e,t){var r=this;return this.router?(t=Object.assign({},this.globalExtras,t||{}),new Promise((function(n){r.zone.run((function(){r.router.navigateByUrl(e,t).then(n,(function(){return n(!1)}))}))}))):Promise.resolve(!1)},t.prototype.subscribeImmediately=function(e,t,r){return this.pipe(operators.skipWhile((function(e){return null==e}))).subscribe(e,t,r)},t}(rxjs.BehaviorSubject);StateService.decorators=[{type:core.Injectable}],StateService.ctorParameters=function(){return[{type:core.Injector},{type:core.NgZone},{type:router.Router,decorators:[{type:core.Optional}]}]};var AuthGuard=function(){function e(e,t,r){this.injector=e,this.state=t,this.auth=r}return e.guardAuthenticated=function(e){return Promise.resolve(e.isAuthenticated)},e.guardNotAuthenticated=function(e){return Promise.resolve(!e.isAuthenticated)},e.guardNothing=function(){return Promise.resolve(!0)},e.guardAuthField=function(e,t){void 0===t&&(t="auth.isAuthenticated");return function(){return Promise.resolve(ObjectUtils.evaluate(t,{auth:e}))}},e.guardStateField=function(e,t){void 0===t&&(t="state.data");return function(){return Promise.resolve(ObjectUtils.evaluate(t,{state:e}))}},e.guardAuthStateField=function(e,t,r){void 0===r&&(r="auth.isAuthenticated");return function(){return Promise.resolve(ObjectUtils.evaluate(r,{auth:e,state:t}))}},e.wildRouteMatch=function(e){return{consumed:e}},e.noRouteMatch=function(){return null},e.prototype.checkRouteMenu=function(e){return e.data&&e.data.name?this.checkRoute(e):Promise.resolve(!1)},e.prototype.checkRoute=function(e,t){var r=this,n=e.data||{};return n.guards?new Promise((function(i){var o=n.guards.map((function(n){return ReflectUtils.resolve(n,r.injector)(r.auth,e,t)}));Promise.all(o).then((function(e){i(e.indexOf(!1)<0)}))})):Promise.resolve(!e.canActivate||this.auth.isAuthenticated)},e.prototype.canActivate=function(e,t){var r=this,n=e.routeConfig;return new Promise((function(t){r.auth.checkAuthenticated().then((function(){r.checkRoute(n,e).then((function(i){t(i),i||r.getReturnState(n).then((function(t){t&&(console.log(t,e.queryParams),r.state.navigate(t,{queryParams:e.queryParams}))}))}))}))}))},e.prototype.getReturnState=function(e){var t=this;if(!e)return Promise.resolve(null);if(ObjectUtils.isObject(e.data)&&ObjectUtils.isArray(e.data.returnState))return Promise.resolve(e.data.returnState);var r=[],n=this.getConfig(e,this.state.routerConfig,r);return new Promise((function(e){t.getReturnStateRecursive(n).then((function(t){ObjectUtils.isArray(t)?e(r.concat(t)):e(t)}))}))},e.prototype.getReturnStateRecursive=function(e,t){var r=this;return void 0===t&&(t=0),!e||t>=e.length?Promise.resolve(null):new Promise((function(n){var i=e[t];(i.component?r.checkRoute(i):Promise.resolve(!1)).then((function(o){o?n([i.path]):r.getReturnStateRecursive(e,t+1).then(n)}))}))},e.prototype.getConfig=function(e,t,r){var n,i;if(!t)return null;if(t.findIndex((function(t){return t==e}))>=0)return t;try{for(var o=__values(t),a=o.next();!a.done;a=o.next()){var s=a.value;r.push(s.path);var c=(s._loadedConfig||{routes:null}).routes,u=this.getConfig(e,s.children||c,r);if(u)return u;r.length-=1}}catch(e){n={error:e}}finally{try{a&&!a.done&&(i=o.return)&&i.call(o)}finally{if(n)throw n.error}}return null},e}();AuthGuard.decorators=[{type:core.Injectable}],AuthGuard.ctorParameters=function(){return[{type:core.Injector,decorators:[{type:core.Inject,args:[core.Injector]}]},{type:StateService,decorators:[{type:core.Inject,args:[StateService]}]},{type:void 0,decorators:[{type:core.Inject,args:[AUTH_SERVICE]}]}]},__decorate([FactoryDependencies(AUTH_SERVICE)],AuthGuard,"guardAuthField",null),__decorate([FactoryDependencies(StateService)],AuthGuard,"guardStateField",null),__decorate([FactoryDependencies(AUTH_SERVICE,StateService)],AuthGuard,"guardAuthStateField",null);var ObservableUtils=function(){function e(){}return e.toSearch=function(e){return operators.mergeMap((function(t){return e.getSearchResults(t)}))(rxjs.Observable.create((function(t){t.next(e.search)})))},e.multiSubscription=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=function(){e.forEach((function(e){e.unsubscribe()}))};return new rxjs.Subscription(r)},e.subscribe=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var n=[];return t.forEach((function(e){var t=!1;e.subjects.forEach((function(r){var i=r.subscribe((function(){var n=Array.from(arguments);n.unshift(r),t=!0,e.cb.apply(null,n)}));n.push(i)})),t||e.cb()})),e.multiSubscription.apply(e,__spread(n))},e.fromFunction=function(e){var t;return new rxjs.Observable((function(r){if(!t){t=new rxjs.Subject;try{t=rxjs.from(e())}catch(e){canReportError.canReportError(t)?t.error(e):console.warn(e)}}return t.subscribe(r)}))},e}(),StringUtils=function(){function e(){}return e.concat=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return t.filter((function(e){return!!e})).join(e)},e.startsWith=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];for(var n=0;n<t.length;n++)if(e.startsWith(t[n]))return!0;return!1},e.has=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];for(var n=0;n<t.length;n++)if(e.indexOf(t[n])>=0)return!0;return!1},e.lcFirst=function(e){return e?e.charAt(0).toLowerCase()+e.substring(1):""},e.ucFirst=function(e){return e?e.charAt(0).toUpperCase()+e.substring(1):""},e}(),ArrayUtils=function(){function e(){}return e.has=function(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(!ObjectUtils.isArray(e)||!ObjectUtils.isArray(t))return!1;for(var n=0;n<t.length;n++)if(e.indexOf(t[n])>=0)return!0;return!1},e.match=function(e,t){if(!ObjectUtils.isArray(e)||!ObjectUtils.isString(t))return!1;for(var r=0;r<e.length;r++){if(e[r]instanceof RegExp)if(e[r].test(t))return!0}return!1},e.any=function(e,t){if(!ObjectUtils.isArray(e)||!ObjectUtils.isFunction(t))return!1;for(var r=0;r<e.length;r++)if(t(e[r]))return!0;return!1},e.move=function(e,t,r){if(!ObjectUtils.isArray(e))return[];for(var n=e.length;t<0;)t+=n;for(;r<0;)r+=n;if(r>=n)for(var i=r-n+1;i--;)e.push(void 0);return e.splice(r,0,e.splice(t,1)[0]),e},e.reversed=function(e){var t=[];if(!ObjectUtils.isArray(e))return t;for(var r=e.length-1;r>=0;r--)t.push(e[r]);return t},e.min=function(e,t){if(!ObjectUtils.isArray(e))return null;for(var r=Number.MAX_SAFE_INTEGER,n=null,i=0;i<e.length;i++){var o=t(e[i],i);(o<r||null===n)&&(r=o,n=e[i])}return n},e.max=function(e,t){if(!ObjectUtils.isArray(e))return null;for(var r=Number.MIN_SAFE_INTEGER,n=null,i=0;i<e.length;i++){var o=t(e[i],i);(o>r||null===n)&&(r=o,n=e[i])}return n},e.chunk=function(e,t){if(!ObjectUtils.isArray(e))return[];t=Math.max(1,t);for(var r=[],n=0;n<e.length;n+=t)r.push(e.slice(n,n+t));return r},e}(),SetUtils=function(){function e(){}return e.equals=function(e,t){if(!ObjectUtils.isSet(e)||!ObjectUtils.isSet(t))return!1;if(e.size!=t.size)return!1;for(var r in e)if(!t.has(r))return!1;return!0},e.addArray=function(e,t){ObjectUtils.isSet(e)&&ObjectUtils.isArray(t)&&t.forEach((function(t){return e.add(t)}))},e}(),TimerUtils=function(){function e(){}return e.createTimeout=function(t,r){return e.createTimer((function(e){e.clear(),e.id=setTimeout((function(){e.id=null,e.func()}),e.time)}),(function(e){e.id&&(clearTimeout(e.id),e.id=null)}),t,r)},e.createInterval=function(t,r){return e.createTimer((function(e){e.clear(),e.id=setInterval(e.func,e.time)}),(function(e){e.id&&(clearInterval(e.id),e.id=null)}),t,r)},e.createTimer=function(e,t,r,n){var i={},o=function(e,t){i.func=ObjectUtils.isFunction(e)?e:function(){},i.time=ObjectUtils.isNumber(t)?t:100};return i.run=function(){return e(i)},i.clear=function(){return t(i)},i.set=function(e,t){o(e,t),i.run()},o(r,n),i},e}(),UniqueUtils=function(){function e(){}return e.uuid=function(){if("undefined"!=typeof window&&void 0!==window.crypto&&void 0!==window.crypto.getRandomValues){var e=new Uint16Array(8);return window.crypto.getRandomValues(e),this.pad4(e[0])+this.pad4(e[1])+"-"+this.pad4(e[2])+"-"+this.pad4(e[3])+"-"+this.pad4(e[4])+"-"+this.pad4(e[5])+this.pad4(e[6])+this.pad4(e[7])}return this.random4()+this.random4()+"-"+this.random4()+"-"+this.random4()+"-"+this.random4()+"-"+this.random4()+this.random4()+this.random4()},e.pad4=function(e){for(var t=e.toString(16);t.length<4;)t="0"+t;return t},e.random4=function(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)},e}(),Vector=function(){function e(e,t,r){this.x=e,this.y=t,this.z=r}return Object.defineProperty(e.prototype,"negative",{get:function(){return new e(-this.x,-this.y,-this.z)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"length",{get:function(){return Math.sqrt(this.dot(this))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"unit",{get:function(){return this.divide(this.length)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"min",{get:function(){return Math.min(Math.min(this.x,this.y),this.z)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"max",{get:function(){return Math.max(Math.max(this.x,this.y),this.z)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"angles",{get:function(){return{theta:Math.atan2(this.z,this.x),phi:Math.asin(this.y/this.length)}},enumerable:!1,configurable:!0}),e.prototype.add=function(t){return t instanceof e?new e(this.x+t.x,this.y+t.y,this.z+t.z):new e(this.x+t,this.y+t,this.z+t)},e.prototype.subtract=function(t){return t instanceof e?new e(this.x-t.x,this.y-t.y,this.z-t.z):new e(this.x-t,this.y-t,this.z-t)},e.prototype.multiply=function(t){return t instanceof e?new e(this.x*t.x,this.y*t.y,this.z*t.z):new e(this.x*t,this.y*t,this.z*t)},e.prototype.divide=function(t){return t instanceof e?new e(this.x/t.x,this.y/t.y,this.z/t.z):new e(this.x/t,this.y/t,this.z/t)},e.prototype.equals=function(e){return this.x==e.x&&this.y==e.y&&this.z==e.z},e.prototype.dot=function(e){return this.x*e.x+this.y*e.y+this.z*e.z},e.prototype.cross=function(t){return new e(this.y*t.z-this.z*t.y,this.z*t.x-this.x*t.z,this.x*t.y-this.y*t.x)},e.prototype.angleTo=function(e){return Math.acos(this.dot(e)/(this.length*e.length))},e.prototype.toArray=function(e){return[this.x,this.y,this.z].slice(0,e||3)},e.prototype.clone=function(){return new e(this.x,this.y,this.z)},e.prototype.init=function(e,t,r){return this.x=e,this.y=t,this.z=r,this},e}(),UniversalService=function(){function e(e,t){this.platformId=e,this.dds=t;var r=this.dds.getDeviceInfo();this.crawler=/(bot|google|baidu|bing|msn|duckduckbot|teoma|slurp|yandex|lighthouse|angular-universal|PTST)/gi.test(r.userAgent)}return Object.defineProperty(e.prototype,"isBrowser",{get:function(){return common.isPlatformBrowser(this.platformId)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isServer",{get:function(){return common.isPlatformServer(this.platformId)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"deviceInfo",{get:function(){return this.isServer?{userAgent:"angular-universal",os:"unknown",browser:"node",device:"node",os_version:"unknown",browser_version:"unknown"}:this.dds.getDeviceInfo()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"browserName",{get:function(){return this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"browserVersion",{get:function(){return this.dds.browser_version},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isExplorer",{get:function(){return"ie"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isEdge",{get:function(){return"ms-edge"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isChrome",{get:function(){return"chrome"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isFirefox",{get:function(){return"firefox"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSafari",{get:function(){return"safari"==this.dds.browser},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isTablet",{get:function(){return this.dds.isTablet()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isMobile",{get:function(){return this.dds.isMobile()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isDesktop",{get:function(){return this.dds.isDesktop()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isCrawler",{get:function(){return this.crawler},enumerable:!1,configurable:!0}),e}();UniversalService.decorators=[{type:core.Injectable}],UniversalService.ctorParameters=function(){return[{type:String,decorators:[{type:core.Inject,args:[core.PLATFORM_ID]}]},{type:ngxDeviceDetector.DeviceDetectorService}]};var emptyGuards=[],AclService=function(){function e(t,r,n){var i=this;this.injector=t,this.state=r,this.auth=n,this.components=[],this.auth.userChanged.subscribe((function(){i.components.forEach((function(e){return e.dirty=!0}));var t=i.getStateInfo();(t&&t.guard instanceof AuthGuard?t.guard.checkRoute(t.route):Promise.resolve(!0)).then((function(r){r?e.checkStateDirty(t):t.guard.getReturnState(t.route).then((function(e){e&&i.state.navigate(e)}))}))})),this.state.subscribe((function(){var t=i.getStateInfo();e.checkStateDirty(t)}))}return e.checkStateDirty=function(e){if(e&&e.dirty&&(e.dirty=!1,ObjectUtils.checkInterface(e.component,{onUserInitialized:"function",onUserChanged:"function"}))){var t=e.component;if(e.first)return t.onUserInitialized(),void(e.first=!1);t.onUserChanged()}},e.prototype.getStateInfo=function(){var e=this,t=this.state.route;if(!t)return null;var r=this.components.find((function(t){return t.route==e.state.route}));if(!r){var n=(t.canActivate||emptyGuards)[0];r={route:this.state.route,component:this.state.component,guard:n?this.injector.get(n):null,dirty:!1,first:!0},this.components.push(r)}return r},e}();AclService.decorators=[{type:core.Injectable}],AclService.ctorParameters=function(){return[{type:core.Injector},{type:StateService},{type:void 0,decorators:[{type:core.Inject,args:[AUTH_SERVICE]}]}]};var BaseHttpClient=function(e){function t(t){var r=e.call(this,t)||this;return r.requestHeaders={},r.requestParams={},r.extraRequestParams={language:"en"},r}return __extends(t,e),t.prototype.makeHeaders=function(e,t){void 0===t&&(t=!0);var r=(e=Object.assign({},this.requestHeaders,e)).Authorization||"";return t||r.startsWith("Bearer")||delete e.Authorization,new http.HttpHeaders(e)},t.prototype.makeParams=function(e){return e=Object.assign({},this.extraRequestParams,this.requestParams,e),new http.HttpParams({encoder:new http.HttpUrlEncodingCodec,fromObject:Object.keys(e||{}).reduce((function(t,r){var n=e[r];return t[r]=ObjectUtils.isObject(n)?JSON.stringify(n):ObjectUtils.isNullOrUndefined(n)?"":n.toString(),t}),{})})},t.prototype.setExtraRequestParam=function(e,t){void 0!==t?this.extraRequestParams[e]=t:delete this.extraRequestParams[e]},t}(http.HttpClient);BaseHttpClient.decorators=[{type:core.Injectable}],BaseHttpClient.ctorParameters=function(){return[{type:http.HttpHandler}]};var StorageService=function(){function e(e){this.universal=e}return e.prototype.get=function(e,t,r){if(void 0===r&&(r=exports.StorageMode.Local),this.universal.isServer)return t;var n=(r==exports.StorageMode.Local?localStorage:sessionStorage).getItem(e);if(!n)return t;try{return JSON.parse(n)}catch(e){return n}},e.prototype.set=function(e,t,r){if(void 0===r&&(r=exports.StorageMode.Local),!this.universal.isServer){var n=r==exports.StorageMode.Local?localStorage:sessionStorage;"string"!=typeof t?n.setItem(e,JSON.stringify(t)):n.setItem(e,t)}},e.prototype.remove=function(e,t){(void 0===t&&(t=exports.StorageMode.Local),this.universal.isServer)||(t==exports.StorageMode.Local?localStorage:sessionStorage).removeItem(e)},e}();StorageService.decorators=[{type:core.Injectable}],StorageService.ctorParameters=function(){return[{type:UniversalService}]};var BaseHttpService=function(){function e(e,t,r,n,i,o){void 0===o&&(o=null),this.client=e,this.storage=t,this.language=r,this.toaster=n,this.configs=i,this.request=o,this.cache={}}return Object.defineProperty(e.prototype,"name",{get:function(){return"base"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"withCredentials",{get:function(){return!0},enumerable:!1,configurable:!0}),e.retryFailedRequests=function(){e.failedRequests.forEach((function(e){return e()})),e.failedRequests=[]},Object.defineProperty(e.prototype,"universal",{get:function(){return this.storage.universal},enumerable:!1,configurable:!0}),e.prototype.url=function(e){return e},e.prototype.createUrl=function(e,t){var r=this.client.makeParams(t),n=r.keys().map((function(e){return e+"="+r.get(e)})).join("&");return this.url(e)+"?"+n},e.prototype.makeListParams=function(e,t,r,n,i){void 0===r&&(r=null),void 0===n&&(n=null),void 0===i&&(i=null);var o={page:e-1,limit:t};return ObjectUtils.isNullOrUndefined(r)||ObjectUtils.isNullOrUndefined(n)||(o.sort=(n?"-":"")+r),ObjectUtils.isNullOrUndefined(i)||(o.filter=i),o},e.prototype.getPromise=function(e,t,r){return t=this.makeOptions(t,"GET",r),this.toPromise(e,t)},e.prototype.deletePromise=function(e,t,r){return t=this.makeOptions(t,"DELETE",r),this.toPromise(e,t)},e.prototype.postPromise=function(e,t,r){return r=this.makeOptions(r,"POST",t),this.toPromise(e,r)},e.prototype.putPromise=function(e,t,r){return r=this.makeOptions(r,"PUT",t),this.toPromise(e,r)},e.prototype.patchPromise=function(e,t,r){return r=this.makeOptions(r,"PATCH",t),this.toPromise(e,r)},e.prototype.uploadPromise=function(e,t,r,n){var i={};return t instanceof Blob&&(i["Content-Type"]="application/octet-stream"),n=this.makeOptions(Object.assign({headers:i,reportProgress:!0},n),"POST",t),this.toPromise(e,n,r)},e.prototype.listPromise=function(e,t){var r=this;return new Promise((function(n){r.getPromise(e,{params:t}).then((function(e){var t,r;ObjectUtils.isArray(e)?n({total:e.length,items:e,meta:{}}):n({total:(null===(t=e.meta)||void 0===t?void 0:t.total)||(null==e?void 0:e.total)||(null===(r=e.items)||void 0===r?void 0:r.length)||0,items:e.items||[],meta:e.meta||{}})}),(function(e){return 0==e.status||301==e.status?(n({total:1,items:[{id:null,label:"Not implemented."}],meta:{}}),!0):(n({total:0,items:[],meta:{}}),!1)}))}))},e.prototype.handleUnauthorizedError=function(t,r,n){n(),e.failedRequests.length>1||this.universal.isServer||console.log("User auth error",t,r)},e.prototype.toastWarning=function(e,t,r,n){this.toaster.warning(e,{issueContext:t,reason:r,options:n})},e.prototype.toastError=function(e,t,r,n){this.toaster.warning(e,{issueContext:t,reason:r,options:n})},e.prototype.toPromise=function(t,r,n){var i=this,o={url:""};return new HttpPromise((function(e){if(e){var n=e.error||{};if(0!=e.status&&301!=e.status){var a=/((E11000 duplicate key error collection: (.)+\.)|(_1 dup key:(.)+))/g;n.message&&a.test(n.message)?i.toastError("message.duplicate-key.error."+n.message.replace(a,"").replace(" index: ","-"),o,n,r):i.toastWarning(t+" endpoint error is not handled properly! Click here, to quickly create an issue.",o,n,r)}else i.toastWarning(t+" endpoint is not implemented! Click here, to quickly create an issue.",o,n,r)}else{if(i.universal.isServer)return;console.log("You may not need a reject Handler for this request!",i.name,t,r)}}),(function(a,s){i.absoluteUrl(t,r).then((function(c){o.url=c;var u=i.client.request(r.method,c,r);(ObjectUtils.isNumber(r.timeout)&&r.timeout>0?u.pipe(operators.timeout(r.timeout)):u).subscribe((function(e){if(r.reportProgress&&e.type===http.HttpEventType.UploadProgress){var o={percentage:MathUtils.round(e.loaded/e.total,2,.01),loaded:e.loaded,total:e.total};n&&n(o)}else{var s=e instanceof http.HttpResponse?e.body:e;a(i.parseResponse(s,t,r));var c=r.headers;if(i.client.renewTokenFunc&&c.has("Authorization")){var u=(new Date).getTime();u-6e5>(i.storage.get("userTokenTime")||u)&&i.client.renewTokenFunc()}}}),(function(o){if(o instanceof rxjs.TimeoutError||0==o.status||301==o.status)s(o);else{if(r.headers.has("Authorization")&&401==o.status)return e.failedRequests.push((function(){r.headers=i.makeHeaders(r.originalHeaders),i.toPromise(t,r,n).then(a,s)})),void i.handleUnauthorizedError(c,r,(function(){return s(o)}));s(o)}}))}))}))},e.prototype.checkHeaders=function(e){return!!(e&&e.cookie&&e.referer&&e.host)&&e.referer.indexOf(e.host)>=0},e.prototype.makeOptions=function(e,t,r){void 0===t&&(t="GET"),(e=e?Object.assign({},e):{}).params=this.client.makeParams(e.params),e.observe="body",e.originalHeaders=e.originalHeaders||e.headers||{},e.method=t,e.withCredentials=ObjectUtils.isBoolean(e.withCredentials)?e.withCredentials:this.withCredentials,e.body=r||{};var n=this.request?this.request.headers:null;return this.checkHeaders(n)&&(e.headers.Cookie=n.cookie),e.headers=this.makeHeaders(e.originalHeaders,t),e},e.prototype.makeHeaders=function(e,t){return void 0===t&&(t="GET"),this.client.makeHeaders(e)},e.prototype.parseResponse=function(e,t,r){return e},e.prototype.parseUrl=function(e){return this.url(e).replace(/(?:((?!:).\/)\/)/g,"$1")},e.prototype.absoluteUrl=function(e,t){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(r){return t=this.parseUrl(e),"api-docs"==e?[2,t.replace("/api","")]:[2,t]}))}))},e.prototype.expressRequestUrl=function(e){var t=this.request;if(!t||!e||e.startsWith("http")||e.startsWith("//"))return e;var r=e.startsWith("/")?"":"/";return t.protocol+"://"+t.get("host")+r+e},e}();BaseHttpService.failedRequests=[],BaseHttpService.decorators=[{type:core.Injectable}],BaseHttpService.ctorParameters=function(){return[{type:BaseHttpClient,decorators:[{type:core.Inject,args:[BaseHttpClient]}]},{type:StorageService,decorators:[{type:core.Inject,args:[StorageService]}]},{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]},{type:void 0,decorators:[{type:core.Inject,args:[TOASTER_SERVICE]}]},{type:void 0,decorators:[{type:core.Inject,args:[CONFIG_SERVICE]}]},{type:void 0,decorators:[{type:core.Optional},{type:core.Inject,args:[EXPRESS_REQUEST]}]}]};var ApiService=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"name",{get:function(){return"api"},enumerable:!1,configurable:!0}),t.prototype.url=function(e){return this.expressRequestUrl("/api/"+e)},t.prototype.get=function(e,t,r){return this.getPromise(e,t,r)},t.prototype.delete=function(e,t,r){return this.deletePromise(e,t,r)},t.prototype.post=function(e,t,r){return this.postPromise(e,t,r)},t.prototype.put=function(e,t,r){return this.putPromise(e,t,r)},t.prototype.patch=function(e,t,r){return this.patchPromise(e,t,r)},t.prototype.upload=function(e,t,r,n){return this.uploadPromise(e,t,r,n)},t.prototype.list=function(e,t){return this.listPromise(e,t)},t}(BaseHttpService);ApiService.decorators=[{type:core.Injectable}];var StaticAuthService=function(){function e(){this.isAuthenticated=!0,this.userChanged=new core.EventEmitter}return e.prototype.checkAuthenticated=function(){return Promise.resolve(this.isAuthenticated)},e.prototype.getReturnState=function(e){return null},e}(),ConfigService=function(){function e(e,t,r,n){var i=this;for(var o in void 0===r&&(r=null),void 0===n&&(n=null),this.http=e,this.universal=t,[])Object.defineProperty(Array.prototype,o,{enumerable:!1});var a="";if(this.universal.isBrowser){var s=document.currentScript;if(s){var c=s.src,u=c.split(".js");a=c.substr(0,u[0].lastIndexOf("/")+1)}}this.loadedConfig=Object.assign(a?{baseUrl:a}:{},r||{}),this.scriptParameters=n||{},this.loaderFunc=function(){return i.loader=i.loader||new Promise((function(e,t){i.loadJson().then((function(t){i.loadedConfig=t=Object.assign(i.loadedConfig,t),i.prepareConfig(t).then((function(t){t.baseUrl=t.baseUrl||"/",e(t)}))}),t)})),i.loader},this.initService()}return Object.defineProperty(e.prototype,"load",{get:function(){return this.loaderFunc},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"config",{get:function(){return this.loadedConfig},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"configUrl",{get:function(){return this.loadedConfig.baseUrl+"config/config.json"},enumerable:!1,configurable:!0}),e.prototype.initService=function(){},e.prototype.loadJson=function(){var e=this;if(this.universal.isServer)return Promise.resolve(this.loadedConfig);var t=this.configUrl;return new Promise((function(r,n){e.http.get(t).toPromise().then((function(e){r(e)}),(function(){n("Config file not found at: "+t)}))}))},e.prototype.prepareConfig=function(e){return Promise.resolve(e)},e.prototype.prepareUrl=function(e,t){var r=this.loadedConfig?this.loadedConfig.project:"";return e=(e=e?""+e.replace(/\/+$/,"")+t:t).replace("[project]",r),this.universal.isServer&&e.startsWith("//")?"http:"+e:e},e.prototype.getConfigValue=function(e){return this.loadedConfig[e]},e.prototype.getQueryParameter=function(e,t){t=t||(this.universal.isServer?"":window.location.href),e=e.replace(/[\[\]]/g,"\\$&");var r=new RegExp("[?&]"+e+"(=([^&#]*)|&|#|$)").exec(t);return r?r[2]?decodeURIComponent(r[2].replace(/\+/g," ")):"":null},e}();ConfigService.decorators=[{type:core.Injectable}],ConfigService.ctorParameters=function(){return[{type:http.HttpClient},{type:UniversalService},{type:IConfiguration,decorators:[{type:core.Optional},{type:core.Inject,args:[BASE_CONFIG]}]},{type:void 0,decorators:[{type:core.Optional},{type:core.Inject,args:[SCRIPT_PARAMS]}]}]};var ErrorHandlerService=function(e){function t(t){var r=e.call(this)||this;return r.injector=t,r.errorMap={},r}return __extends(t,e),t.prototype.handleError=function(e){try{this.universal=this.universal||this.injector.get(UniversalService)}catch(e){return}var t=new Date;try{this.errorCb=this.errorCb||this.injector.get(ERROR_HANDLER),this.errorCb("["+t+"]: "+e.message+"\n"+e.stack)}catch(r){if(this.universal.isServer)return void console.error("["+t+"]: "+e.message+"\n"+e.stack)}if(!this.universal.isServer){var r=btoa(unescape(encodeURIComponent(e.message+" "+e.stack)));if(!(this.errorMap[r]&&this.errorMap[r].getTime()>t.getTime()-5e3)){this.errorMap[r]=t;try{this.toaster=this.toaster||this.injector.get(TOASTER_SERVICE),this.toaster.error("["+t+"]: "+e.message+"\n"+e.stack)}catch(e){}console.error("["+t+"]: "+e.message+"\n"+e.stack)}}},t}(core.ErrorHandler);ErrorHandlerService.decorators=[{type:core.Injectable}],ErrorHandlerService.ctorParameters=function(){return[{type:core.Injector}]};var EventsService=function(){function e(){this.eventForwarded=new core.EventEmitter,this.stickyUpdated=new core.EventEmitter,this.languageChanged=new core.EventEmitter,this.sticky=!1}return Object.defineProperty(e.prototype,"isSticky",{get:function(){return this.sticky},enumerable:!1,configurable:!0}),e.prototype.event=function(e){this.eventForwarded.emit(e)},e.prototype.updateSticky=function(e){this.sticky=e,this.stickyUpdated.emit(e)},e}();EventsService.decorators=[{type:core.Injectable}],EventsService.ctorParameters=function(){return[]};var FormatterService=function(){function e(e){this.language=e}return Object.defineProperty(e.prototype,"defaultPrecision",{get:function(){return 2},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"defaultNumberFormat",{get:function(){return"num + ' mm'"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"defaultDivider",{get:function(){return 1},enumerable:!1,configurable:!0}),e.prototype.roundNumber=function(e,t,r){return MathUtils.round(e,this.getPrecision(t),r||this.defaultDivider)},e.prototype.formatNumber=function(e,t,r,n){r=this.getPrecision(r),n=n||this.defaultDivider;var i=((ObjectUtils.isNumber(e)?e:parseFloat(e)||0)/n).toLocaleString(this.language.currentLanguage,{minimumFractionDigits:r,maximumFractionDigits:r});return ObjectUtils.evaluate(t||this.defaultNumberFormat,{num:i})},e.prototype.formatMillimeter=function(e,t,r){return this.formatNumber(e,"num + ' mm'",t,r)},e.prototype.getPrecision=function(e){return ObjectUtils.isNumber(e)?e:this.defaultPrecision},e}();FormatterService.decorators=[{type:core.Injectable}],FormatterService.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var GlobalTemplateService=function(){function e(){this.templatesUpdated=new core.EventEmitter,this.globalTemplates={},this.componentModifiers={}}return e.prototype.get=function(e,t){var r=this.globalTemplates[e];if(!r)return null;var n=this.componentModifiers[e];return ObjectUtils.isFunction(n)&&t&&n(t),r},e.prototype.add=function(e,t){this.globalTemplates[e]=t,this.templatesUpdated.emit()},e.prototype.remove=function(e){delete this.globalTemplates[e],this.templatesUpdated.emit()},e.prototype.addComponentModifier=function(e,t){this.componentModifiers[e]=t},e}();GlobalTemplateService.decorators=[{type:core.Injectable}],GlobalTemplateService.ctorParameters=function(){return[]};var IconService=function(){function e(){this.iconsLoaded=new core.EventEmitter,this.disabled=!1}return Object.defineProperty(e.prototype,"isDisabled",{get:function(){return this.disabled},set:function(e){this.disabled=e,this.iconsLoaded.emit()},enumerable:!1,configurable:!0}),e.prototype.getIcon=function(e,t,r){return e="undefined"==typeof icons?e:icons[e]||e,t="undefined"==typeof icons?t:icons[t]||e,Promise.resolve(r?t:e)},e}();IconService.decorators=[{type:core.Injectable}],IconService.ctorParameters=function(){return[]};var StaticLanguageService=function(){function e(e,t,r,n){this.events=e,this.storage=t,this.configs=r,this.client=n,this.editLang=null,this.currentLang=null,this.disableTrans=!1,this.languageList=[],this.translations={none:{}},this.initService()}return Object.defineProperty(e.prototype,"defaultLanguage",{get:function(){return this.configs.getQueryParameter("lang")||this.storage.get("language",this.browserLang)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dictionary",{get:function(){return this.translations[this.currentLanguage]||{}},set:function(e){this.translations[this.currentLanguage]=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"languages",{get:function(){return this.languageList},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentLanguage",{get:function(){return this.currentLang||this.defaultLanguage},set:function(e){this.currentLang=e,this.events.languageChanged.emit(e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"editLanguage",{get:function(){return this.editLang||this.currentLanguage},set:function(e){this.editLang=e||this.currentLanguage},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"disableTranslations",{get:function(){return this.disableTrans},set:function(e){this.disableTrans=e,this.events.languageChanged.emit(this.currentLang)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"httpClient",{get:function(){return this.client},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"config",{get:function(){return this.configs.config},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"browserLang",{get:function(){if(this.universal.isServer||void 0===window.navigator)return"de";var e=(window.navigator.languages?window.navigator.languages[0]:null)||window.navigator.language||window.navigator.browserLanguage||window.navigator.userLanguage||null;return e?(["-","_"].forEach((function(t){e.indexOf(t)>=0&&(e=e.split(t)[0])})),e):e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"universal",{get:function(){return this.storage.universal},enumerable:!1,configurable:!0}),e.prototype.initService=function(){},e.prototype.addLanguages=function(e){var t=this;e.forEach((function(e){t.translations[e]={},t.languageList.push(e)}))},e.prototype.getTranslationSync=function(e,t){void 0===t&&(t=null);var r=(e||"").toLocaleLowerCase(),n=this.dictionary[r]||r;return this.interpolate(n==r?e:n,t)},e.prototype.getTranslation=function(e,t){if(!ObjectUtils.isString(e)||!e.length)throw new Error('Parameter "key" required');var r=ObjectUtils.getValue(this.dictionary,e,e)||e;return Promise.resolve(this.interpolate(r,t))},e.prototype.getTranslations=function(){for(var e=this,t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return new Promise((function(r){Promise.all(t.map((function(t){return e.getTranslation(t)}))).then((function(e){r(t.reduce((function(t,r,n){return t[r]=e[n],t}),{}))}))}))},e.prototype.getTranslationFromObject=function(e,t,r){return r=r||this.currentLanguage,this.interpolate(e&&e[r]||"")},e.prototype.getTranslationFromArray=function(e,t,r){r=r||this.currentLanguage;var n=e?e.find((function(e){return e.lang==r})):null;return this.interpolate(n?n.translation:"",t)},e.prototype.interpolate=function(e,t){return"string"==typeof e?this.interpolateString(e,t):"function"==typeof e?e(t):e},e.prototype.interpolateString=function(e,t){return e&&t?e.replace(/{{\s?([^{}\s]*)\s?}}/g,(function(e,r){var n=ObjectUtils.getValue(t,r);return ObjectUtils.isDefined(n)?n:e})):e},e}();StaticLanguageService.decorators=[{type:core.Injectable}],StaticLanguageService.ctorParameters=function(){return[{type:EventsService,decorators:[{type:core.Inject,args:[EventsService]}]},{type:StorageService,decorators:[{type:core.Inject,args:[StorageService]}]},{type:void 0,decorators:[{type:core.Inject,args:[CONFIG_SERVICE]}]},{type:BaseHttpClient}]};var LanguageService=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return __extends(t,e),Object.defineProperty(t.prototype,"currentLanguage",{get:function(){return this.currentLang||this.defaultLanguage},set:function(e){var t=this;this.useLanguage(e).then((function(){t.events.languageChanged.emit(e)}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"settings",{get:function(){var e=this.languageSettings.value;return e&&e.settings[this.currentLanguage]||{}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"$settings",{get:function(){var e=this;return this.loadSettings().then((function(t){return e.languageSettings.next(t)})),rxjs.combineLatest([this.languageSettings,this.events.languageChanged]).pipe(operators.map((function(e){var t=__read(e,2),r=t[0],n=t[1];return r&&r.settings[n]||{}})))},enumerable:!1,configurable:!0}),t.prototype.initService=function(){var e=this;this.client.setExtraRequestParam("language","de"),this.translationRequests={},this.languageSettings=new rxjs.BehaviorSubject(null),this.universal.isServer||(window.setLanguage=function(t){e.currentLanguage=t})},t.prototype.initFromSettings=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,r,n;return __generator(this,(function(i){switch(i.label){case 0:return e=this.defaultLanguage,[4,this.loadSettings()];case 1:return t=i.sent(),this.languageSettings.next(t),r=t.devLanguages||[],this.languageList=(t.languages||[]).filter((function(e){return r.indexOf(e)<0})),n=this.languages.indexOf(e)<0?t.defaultLanguage:e,[4,this.useLanguage(n)];case 2:return i.sent(),this.events.languageChanged.emit(n),[2]}}))}))},t.prototype.getTranslation=function(e,t){return void 0===t&&(t=null),__awaiter(this,void 0,void 0,(function(){var r,n,i;return __generator(this,(function(o){switch(o.label){case 0:if(!e)return[2,""];o.label=1;case 1:return o.trys.push([1,3,,4]),r=e.toLocaleLowerCase(),[4,this.loadDictionary()];case 2:return n=o.sent(),r in n?[2,this.interpolate(n[r],t)]:[2,this.interpolate(e,t)];case 3:return i=o.sent(),console.log("ERROR IN TRANSLATIONS",i),[2,e];case 4:return[2]}}))}))},t.prototype.useLanguage=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(r){switch(r.label){case 0:return e=this.languages.indexOf(e)<0?this.languages[0]:e,this.client.setExtraRequestParam("language",e),e==this.currentLang?[2,this.dictionary]:(this.storage.set("language",e),this.currentLang=e,[4,this.loadDictionary()]);case 1:return t=r.sent(),this.translations[e]=t,[2,t]}}))}))},t.prototype.loadDictionary=function(){var e=this,t=this.currentLanguage;return this.translationRequests[t]=this.translationRequests[t]||new Promise((function(r){e.httpClient.get(""+e.config.translationUrl+t).toPromise().then((function(e){e=e||{},r(Object.keys(e).reduce((function(t,r){return t[r.toLocaleLowerCase()]=e[r],t}),{}))}),(function(){r({})}))})),this.translationRequests[t]},t.prototype.loadSettings=function(){return this.settingsPromise=this.settingsPromise||this.client.get(this.config.translationUrl+"languageSettings").toPromise().then((function(e){return e}),(function(){return{languages:["de","en","hu"],devLanguages:[],defaultLanguage:"de",settings:{de:{},hu:{},end:{}}}})),this.settingsPromise},t}(StaticLanguageService);LanguageService.decorators=[{type:core.Injectable}];var OpenApiService=function(){function e(e){this.api=e}return e.prototype.getSchemas=function(){var e=this;return this.schemasPromise=this.schemasPromise||new Promise((function(t){e.api.get("api-docs").then((function(e){var r,n=(null===(r=e.components)||void 0===r?void 0:r.schemas)||e.definitions||{};Object.values(n).forEach((function(e){Object.keys(e.properties||{}).forEach((function(t){e.properties[t].id=t}))})),t(n)}),(function(){t({})}))})),this.schemasPromise},e.prototype.getSchema=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(r){switch(r.label){case 0:return[4,this.getSchemas()];case 1:return t=r.sent(),t[e]?[2,t[e]]:[2,null]}}))}))},e}();OpenApiService.decorators=[{type:core.Injectable}],OpenApiService.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[API_SERVICE]}]}]};var ConsoleToasterService=function(){function e(e){this.language=e}return e.prototype.error=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #BD362F; color: #ffffff")}))},e.prototype.info=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #2F96B4; color: #ffffff")}))},e.prototype.success=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #51A351; color: #ffffff")}))},e.prototype.warning=function(e,t,r){this.translateMessage(e,t,(function(e){return console.log(e,r,"background: #F89406; color: #ffffff")}))},e.prototype.translateMessage=function(e,t,r){this.language.getTranslation(e,t).then(r)},e}();ConsoleToasterService.decorators=[{type:core.Injectable}],ConsoleToasterService.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var TranslatedUrlSerializer=function(e){function t(t){var r=e.call(this)||this;return r.language=t,r.cache={},r}return __extends(t,e),t.prototype.serialize=function(t){var r=new router.UrlTree,n=this.getDictionary(!0);return r.root=this.modifyTreeRecursive(t.root,(function(e){e.path=n[e.path]||e.path})),r.queryParams=t.queryParams,e.prototype.serialize.call(this,r)},t.prototype.parse=function(t){var r=e.prototype.parse.call(this,t),n=this.getDictionary(!1);return r.root=this.modifyTreeRecursive(r.root,(function(e){e.path=n[e.path]||e.path})),r},t.prototype.getDictionary=function(e){var t=e?"serialize":"parse",r=this.language.currentLanguage+"-"+t;if(!this.cache[r]){var n=this.language.dictionary;this.cache[r]=Object.keys(n).reduce((function(t,r){if(!r.startsWith("route."))return t;var i=n[r];return r=r.replace("route.",""),t[e?r:i]=e?i:r,t}),{})}return this.cache[r]},t.prototype.modifyTreeRecursive=function(e,t){var r=this;if(!e)return null;var n=[],i=Object.keys(e.children||{}).reduce((function(i,o){var a=r.modifyTreeRecursive(e.children[o],t);return n.push(a),i[o]=a,i}),{}),o=new router.UrlSegmentGroup(e.segments.map((function(e){return e=new router.UrlSegment(e.path,Object.assign({},e.parameters)),t(e),e})),i);return n.forEach((function(e){e.parent=o})),o},t}(router.DefaultUrlSerializer);TranslatedUrlSerializer.decorators=[{type:core.Injectable}],TranslatedUrlSerializer.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var PromiseService=function(){function e(e){this.zone=e,this.promiseCount=0,this.promiseChanged=new core.EventEmitter}return Object.defineProperty(e.prototype,"count",{get:function(){return this.promiseCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onChanged",{get:function(){return this.promiseChanged},enumerable:!1,configurable:!0}),e.prototype.create=function(e){return this.add(this.zone.runOutsideAngular((function(){return new Promise(e)})))},e.prototype.all=function(e){return this.add(this.zone.runOutsideAngular((function(){return Promise.all(e)})))},e.prototype.resolve=function(e){return this.add(this.zone.runOutsideAngular((function(){return Promise.resolve(e)})))},e.prototype.promiseFinished=function(){0!=this.promiseCount&&(this.promiseCount--,this.promiseChanged.emit(this.promiseCount))},e.prototype.add=function(e){var t=this;return this.promiseCount++,this.promiseChanged.emit(this.promiseCount),new Promise((function(r,n){e.then((function(e){r(e),t.promiseFinished()}),(function(e){n(e),t.promiseFinished()}))}))},e}();function emptyRemove(){}PromiseService.decorators=[{type:core.Injectable}],PromiseService.ctorParameters=function(){return[{type:core.NgZone,decorators:[{type:core.Inject,args:[core.NgZone]}]}]};var ResizeEventPlugin=function(e){function t(t,r){var n=e.call(this,t)||this;return n.universal=r,n}return __extends(t,e),t.prototype.supports=function(e){return e===t.EVENT_NAME},t.prototype.addEventListener=function(e,t,r){var n=this,i=this.manager.getZone();return i.runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove;var t=function(e){i.run((function(){return r(e)}))};return resizeDetector.addListener(e,t),function(){try{resizeDetector.removeListener(e,t)}catch(e){}}}))},t.prototype.addGlobalEventListener=function(e,t,r){var n=this;return this.manager.getZone().runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove;if(!StringUtils.has(e,"document","window"))return console.error("Global resize event other than window or document?",e),emptyRemove;var i="window"==e?window:document,o=r;return i.addEventListener(t,o),function(){return i.removeEventListener(t,o)}}))},t}(platformBrowser.ɵangular_packages_platform_browser_platform_browser_g);function emptyRemove$1(){}ResizeEventPlugin.EVENT_NAME="resize",ResizeEventPlugin.decorators=[{type:core.Injectable}],ResizeEventPlugin.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[common.DOCUMENT]}]},{type:UniversalService}]};var ScrollEventPlugin=function(e){function t(t,r){var n=e.call(this,t)||this;return n.universal=r,n}return __extends(t,e),t.prototype.supports=function(e){return e===t.EVENT_NAME},t.prototype.addEventListener=function(e,t,r){var n=this,i=this.manager.getZone();return i.runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove$1;var o=function(e){i.run((function(){return r(e)}))};return e.addEventListener(t,o),function(){return e.removeEventListener(t,o)}}))},t.prototype.addGlobalEventListener=function(e,t,r){var n=this;return this.manager.getZone().runOutsideAngular((function(){if(n.universal.isServer)return emptyRemove$1;if(!StringUtils.has(e,"document","window"))return console.error("Global resize event other than window or document?",e),emptyRemove$1;var i="window"==e?window:document,o=r;return i.addEventListener(t,o),function(){return i.removeEventListener(t,o)}}))},t}(platformBrowser.ɵangular_packages_platform_browser_platform_browser_g);ScrollEventPlugin.EVENT_NAME="scroll",ScrollEventPlugin.decorators=[{type:core.Injectable}],ScrollEventPlugin.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[common.DOCUMENT]}]},{type:UniversalService}]};var ChunkPipe=function(){function e(){}return e.prototype.transform=function(e,t){var r=[],n=null;return e.forEach((function(e,i){i%t==0&&(n=[],r.push(n)),n.push(e)})),r},e}();ChunkPipe.decorators=[{type:core.Pipe,args:[{name:"chunk"}]}];var emptyEntries=[],EntriesPipe=function(){function e(){}return e.prototype.transform=function(e){if(!e)return emptyEntries;var t=[];return ObjectUtils.iterate(e,(function(e,r){t.push({key:r,value:e,index:t.length})})),t},e}();EntriesPipe.decorators=[{type:core.Pipe,args:[{name:"entries"}]}];var ExtraItemPropertiesPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===r&&(r={});var n=Object.keys(t);return n.forEach((function(e){var r=t[e];t[e]=ObjectUtils.isFunction(r)?r:function(e,t,n){return ObjectUtils.evaluate(r,{item:e,index:t,params:n})}})),(e||[]).map((function(e,i){return n.reduce((function(n,o){return n[o]=t[o](e,i,r),n}),Object.assign({},e))}))},e}();function defaultFilter(){return!0}ExtraItemPropertiesPipe.decorators=[{type:core.Pipe,args:[{name:"extraItemProperties"}]}];var FilterPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===t&&(t=defaultFilter),void 0===r&&(r={});var n=ObjectUtils.isObject(e);if(!n&&!ObjectUtils.isArray(e))return[];var i=ObjectUtils.isFunction(t)?t:function(e,r,n){return ObjectUtils.evaluate(t,{value:e,key:r,item:e,index:r,params:n})};return n?Object.keys(e).filter((function(t){return i(e[t],t,r)})).reduce((function(t,r){return t[r]=e[r],t}),{}):e.filter((function(e,t){return i(e,t,r)}))},e}();function defaultFilter$1(){return!0}FilterPipe.decorators=[{type:core.Pipe,args:[{name:"filter"}]}];var FindPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){if(void 0===t&&(t=defaultFilter$1),void 0===r&&(r={}),!ObjectUtils.isArray(e))return[];var n=ObjectUtils.isFunction(t)?t:function(e,r,n){return ObjectUtils.evaluate(t,{value:e,index:r,params:n})};return e.find((function(e,t){return n(e,t,r)}))},e}();FindPipe.decorators=[{type:core.Pipe,args:[{name:"find"}]}];var FormatNumberPipe=function(){function e(e){this.formatter=e}return e.prototype.transform=function(e,t,r,n){return this.formatter.formatNumber(e,t,r,n)},e}();FormatNumberPipe.decorators=[{type:core.Pipe,args:[{name:"formatNumber"}]}],FormatNumberPipe.ctorParameters=function(){return[{type:FormatterService}]};var GetOffsetPipe=function(){function e(){}return e.prototype.transform=function(e,t){return e?ObjectUtils.isNullOrUndefined(t)?e:e[t]:null},e}();GetOffsetPipe.decorators=[{type:core.Pipe,args:[{name:"getOffset"}]}];var GetTypePipe=function(){function e(){}return e.prototype.transform=function(e){return typeof e},e}();GetTypePipe.decorators=[{type:core.Pipe,args:[{name:"getType"}]}];var GlobalTemplatePipe=function(){function e(e){this.globalTemplates=e,this.cachedTemplateId=null,this.cachedTemplate=null}return e.prototype.ngOnInit=function(){var e=this;this.templatesUpdated=this.globalTemplates.templatesUpdated.subscribe((function(){e.cachedTemplate=null}))},e.prototype.ngOnDestroy=function(){this.templatesUpdated&&this.templatesUpdated.unsubscribe()},e.prototype.transform=function(e,t){return null!=this.cachedTemplate&&this.cachedTemplateId===e||(this.cachedTemplateId=e,this.cachedTemplate=this.globalTemplates.get(e,t)),this.cachedTemplate},e}();GlobalTemplatePipe.decorators=[{type:core.Pipe,args:[{pure:!1,name:"globalTemplate"}]}],GlobalTemplatePipe.ctorParameters=function(){return[{type:GlobalTemplateService}]};var GroupByPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===r&&(r=null);var n=(e||[]).reduce((function(e,n){var i=ObjectUtils.getValue(n,t)||"",o=r?r[i]||"":i,a=e[o]||[];return a.push(n),e[o]=a,e}),{});return Object.keys(n).map((function(e){return{group:e,items:n[e]}}))},e}();GroupByPipe.decorators=[{type:core.Pipe,args:[{name:"groupBy"}]}];var IsTypePipe=function(){function e(){}return e.prototype.transform=function(e,t){return typeof e===t},e}();IsTypePipe.decorators=[{type:core.Pipe,args:[{name:"isType"}]}];var JoinPipe=function(){function e(){}return e.prototype.transform=function(e,t){return void 0===t&&(t=", "),ObjectUtils.isArray(e)?e.join(t):""},e}();JoinPipe.decorators=[{type:core.Pipe,args:[{name:"join"}]}];var emptyKeys=[],KeysPipe=function(){function e(){}return e.prototype.transform=function(e){return e?ObjectUtils.isArray(e)?Array.from(e.keys()):Object.keys(e):emptyKeys},e}();function defaultMapper(e){return e}KeysPipe.decorators=[{type:core.Pipe,args:[{name:"keys"}]}];var MapPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){if(void 0===t&&(t=defaultMapper),void 0===r&&(r={}),!ObjectUtils.isArray(e))return[];var n=ObjectUtils.isFunction(t)?t:function(e,r,n){return ObjectUtils.evaluate(t,{value:e,index:r,params:n})};return e.map((function(e,t){return n(e,t,r)}))},e}();MapPipe.decorators=[{type:core.Pipe,args:[{name:"map"}]}];var MaxPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===t&&(t=null),void 0===r&&(r={}),t=t||function(e){return e};var n=ObjectUtils.isFunction(e)?e:function(e,r,n){return ObjectUtils.evaluate(t,{item:e,index:r,params:n})};return ArrayUtils.max(e,(function(e,t){return n(e,t,r)}))},e}();MaxPipe.decorators=[{type:core.Pipe,args:[{name:"max"}]}];var MinPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){void 0===t&&(t=null),void 0===r&&(r={}),t=t||function(e){return e};var n=ObjectUtils.isFunction(e)?e:function(e,r,n){return ObjectUtils.evaluate(t,{item:e,index:r,params:n})};return ArrayUtils.min(e,(function(e,t){return n(e,t,r)}))},e}();function defaultReducer(e){return e}MinPipe.decorators=[{type:core.Pipe,args:[{name:"min"}]}];var ReducePipe=function(){function e(){}return e.prototype.transform=function(e,t,r,n){if(void 0===r&&(r=defaultReducer),void 0===n&&(n={}),!ObjectUtils.isArray(e))return[];var i=ObjectUtils.isFunction(r)?r:function(e,t,n,i){return ObjectUtils.evaluate(r,{result:e,value:t,index:n,params:i})};return e.reduce((function(e,t,r){return i(e,t,r,n)}),t)},e}();ReducePipe.decorators=[{type:core.Pipe,args:[{name:"reduce"}]}];var empty={},RemapPipe=function(){function e(){}return e.prototype.transform=function(e,t,r){return void 0===r&&(r="key"),e?t?ObjectUtils.filter({map:ObjectUtils.copy(e)},(function(n,i,o){return!ObjectUtils.isArray(n)||!n.every(ObjectUtils.isString)||(o[i]=n.reduce((function(n,i){return n[i]=ObjectUtils.getValue(t,i,ObjectUtils.evaluate(r,{key:i,map:e,source:t})),n}),{}),!1)})).map:e:empty},e}();RemapPipe.decorators=[{type:core.Pipe,args:[{name:"remap"}]}];var ReplacePipe=function(){function e(){}return e.prototype.transform=function(e,t,r){return e?e.replace(t,r):e},e}();ReplacePipe.decorators=[{type:core.Pipe,args:[{name:"replace"}]}];var emptyArray=[],ReversePipe=function(){function e(){}return e.prototype.transform=function(e){if(!ObjectUtils.isArray(e))return emptyArray;for(var t=[],r=e.length-1;r>=0;r--)t.push(e[r]);return t},e}();ReversePipe.decorators=[{type:core.Pipe,args:[{name:"reverse"}]}];var RoundPipe=function(){function e(e){this.formatter=e}return e.prototype.transform=function(e,t,r){return void 0===t&&(t=2),void 0===r&&(r=1),this.formatter.roundNumber(e,t,r)},e}();RoundPipe.decorators=[{type:core.Pipe,args:[{name:"round"}]}],RoundPipe.ctorParameters=function(){return[{type:FormatterService}]};var SafeHtmlPipe=function(){function e(e){this.sanitizer=e}return e.prototype.transform=function(e,t){switch(void 0===t&&(t="html"),t){case"html":return this.sanitizer.bypassSecurityTrustHtml(e);case"style":return this.sanitizer.bypassSecurityTrustStyle(e);case"script":return this.sanitizer.bypassSecurityTrustScript(e);case"url":return this.sanitizer.bypassSecurityTrustUrl(e);case"resourceUrl":return this.sanitizer.bypassSecurityTrustResourceUrl(e);default:throw new Error("SafePipe unable to bypass security for invalid type: "+t)}},e}();SafeHtmlPipe.decorators=[{type:core.Pipe,args:[{name:"safe"}]}],SafeHtmlPipe.ctorParameters=function(){return[{type:platformBrowser.DomSanitizer}]};var TranslatePipe=function(){function e(e,t){this.cdr=e,this.language=t}return Object.defineProperty(e.prototype,"currentLang",{get:function(){return this.language.currentLanguage},enumerable:!1,configurable:!0}),e.prototype.transform=function(e){for(var t=this,r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];if(!e)return"";var i=!1,o=this.currentLang;this.lang!==o&&(this.lang=o,i=!0);var a=this.language.disableTranslations;if(this.disabled!==a&&(this.disabled=a,i=!0),ObjectUtils.equals(this.query,e)||(this.query=e,i=!0),!ObjectUtils.equals(this.args,r)){if(this.args=r,this.params=null,ObjectUtils.isDefined(r[0])&&r.length)if("string"==typeof r[0]&&r[0].length){var s=r[0].replace(/(\')?([a-zA-Z0-9_]+)(\')?(\s)?:/g,'"$2":').replace(/:(\s)?(\')(.*?)(\')/g,':"$3"');try{this.params=JSON.parse(s)}catch(e){throw new SyntaxError("Wrong parameter in TranslatePipe. Expected a valid Object, received: "+r[0])}}else"object"!=typeof r[0]||Array.isArray(r[0])||(this.params=r[0]);i=!0}if(i){if("object"==typeof e)return this.lastValue=Array.isArray(e)?this.language.getTranslationFromArray(e,this.params,o):this.language.getTranslationFromObject(e,this.params,o),this.lastValue;if(this.disabled)return this.lastValue=e,this.lastValue;this.language.getTranslation(e,this.params).then((function(e){t.lastValue=e,t.cdr.destroyed||t.cdr.detectChanges()}))}return this.lastValue},e}();TranslatePipe.decorators=[{type:core.Injectable},{type:core.Pipe,args:[{name:"translate",pure:!1}]}],TranslatePipe.ctorParameters=function(){return[{type:core.ChangeDetectorRef},{type:void 0,decorators:[{type:core.Inject,args:[LANGUAGE_SERVICE]}]}]};var emptyValues=[],ValuesPipe=function(){function e(){}return e.prototype.transform=function(e){return e?ObjectUtils.isArray(e)?e:Object.keys(e).map((function(t){return e[t]})):emptyValues},e}();ValuesPipe.decorators=[{type:core.Pipe,args:[{name:"values"}]}];var AsyncMethodDirective=function(){function e(e){this.toaster=e,this.onSuccess=new core.EventEmitter,this.onError=new core.EventEmitter}return Object.defineProperty(e.prototype,"isDisabled",{get:function(){return this.disabled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isLoading",{get:function(){return this.loading},enumerable:!1,configurable:!0}),e.prototype.click=function(){this.disabled||this.callMethod()},e.prototype.callMethod=function(){var e=this;this.loading||(this.loading=!0,this.method(this.context).then((function(t){e.loading=!1,t&&(e.onSuccess.emit(t),e.toaster.success(t.message,t.context))}),(function(t){if(!t||!t.message)throw new Error("Reason must implement IAsyncMessage interface");e.loading=!1,e.onError.emit(t),e.toaster.error(t.message,t.context)})))},e}();AsyncMethodDirective.decorators=[{type:core.Directive,args:[{selector:"[async-method]",exportAs:"async-method"}]}],AsyncMethodDirective.ctorParameters=function(){return[{type:void 0,decorators:[{type:core.Inject,args:[TOASTER_SERVICE]}]}]},AsyncMethodDirective.propDecorators={method:[{type:core.Input,args:["async-method"]}],disabled:[{type:core.Input}],context:[{type:core.Input}],onSuccess:[{type:core.Output}],onError:[{type:core.Output}],isDisabled:[{type:core.HostBinding,args:["class.disabled"]}],isLoading:[{type:core.HostBinding,args:["class.loading"]}],click:[{type:core.HostListener,args:["click"]}]};var defaultClass="default-image",loadingClass="loading-image",BackgroundDirective=function(){function e(e,t,r,n){this.http=e,this.element=t,this.renderer=r,this.universal=n}return e.prototype.ngOnChanges=function(e){var t=this;this.universal.isServer?this.setBackground(this.background):(this.renderer.removeClass(this.element.nativeElement,defaultClass),this.renderer.addClass(this.element.nativeElement,loadingClass),FileUtils.readDataFromUrl(this.http,this.background).then((function(e){t.setBackground(e)}),(function(){t.renderer.removeClass(t.element.nativeElement,loadingClass),t.renderer.addClass(t.element.nativeElement,defaultClass)})))},e.prototype.setBackground=function(e){this.renderer.removeClass(this.element.nativeElement,loadingClass),this.renderer.setStyle(this.element.nativeElement,"background-image","url('"+e+"')"),this.backgroundSize&&this.renderer.setStyle(this.element.nativeElement,"background-size",this.backgroundSize)},e}();BackgroundDirective.decorators=[{type:core.Directive,args:[{selector:"[background]"}]}],BackgroundDirective.ctorParameters=function(){return[{type:http.HttpClient},{type:core.ElementRef},{type:core.Renderer2},{type:UniversalService}]},BackgroundDirective.propDecorators={background:[{type:core.Input}],backgroundSize:[{type:core.Input}]};var DynamicTableTemplateDirective=function(e){this.ref=e};DynamicTableTemplateDirective.decorators=[{type:core.Directive,args:[{selector:"ng-template[column]"}]}],DynamicTableTemplateDirective.ctorParameters=function(){return[{type:core.TemplateRef}]},DynamicTableTemplateDirective.propDecorators={column:[{type:core.Input}],pure:[{type:core.Input}]};var GlobalTemplateDirective=function(){function e(e,t){this.globalTemplateService=e,this.template=t}return e.prototype.ngOnInit=function(){this.globalTemplateService.add(this.id,this.template)},e.prototype.ngOnDestroy=function(){this.globalTemplateService.remove(this.id)},e}();GlobalTemplateDirective.decorators=[{type:core.Directive,args:[{selector:"[globalTemplate]"}]}],GlobalTemplateDirective.ctorParameters=function(){return[{type:GlobalTemplateService},{type:core.TemplateRef}]},GlobalTemplateDirective.propDecorators={id:[{type:core.Input,args:["globalTemplate"]}]};var IconDirective=function(){function e(e,t,r){this.element=e,this.renderer=t,this.icons=r,this.renderer.addClass(this.element.nativeElement,"svg-icon"),this.activeChange=new core.EventEmitter}return Object.defineProperty(e.prototype,"isActive",{get:function(){return this.active},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;this.iconsLoaded=this.icons.iconsLoaded.subscribe((function(){return e.changeIcon()}))},e.prototype.ngOnDestroy=function(){this.iconsLoaded&&this.iconsLoaded.unsubscribe()},e.prototype.ngOnChanges=function(e){e.icon&&(this.renderer.removeClass(this.element.nativeElement,"svg-icon-"+e.icon.previousValue),this.renderer.addClass(this.element.nativeElement,"svg-icon-"+e.icon.currentValue)),this.changeIcon()},e.prototype.click=function(){this.active=!this.active,this.activeChange.emit(this.active),this.changeIcon()},e.prototype.changeIcon=function(){var e=this;this.icons.getIcon(this.icon,this.activeIcon||this.icon+"-active",this.active).then((function(t){e.icons.isDisabled||(e.element.nativeElement.innerHTML=t)}))},e}();IconDirective.decorators=[{type:core.Directive,args:[{selector:"[icon]"}]}],IconDirective.ctorParameters=function(){return[{type:core.ElementRef},{type:core.Renderer2},{type:void 0,decorators:[{type:core.Inject,args:[ICON_SERVICE]}]}]},IconDirective.propDecorators={icon:[{type:core.Input}],activeIcon:[{type:core.Input}],active:[{type:core.Input}],activeChange:[{type:core.Output}],isActive:[{type:core.HostBinding,args:["class.active"]}],click:[{type:core.HostListener,args:["click"]}]};var NgxTemplateOutletDirective=function(){function e(e){this._viewContainerRef=e}return e.hasContextShapeChanged=function(e){var t,r,n=Object.keys(e.previousValue||{}),i=Object.keys(e.currentValue||{});if(n.length===i.length){try{for(var o=__values(i),a=o.next();!a.done;a=o.next()){var s=a.value;if(-1===n.indexOf(s))return!0}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(t)throw t.error}}return!1}return!0},e.prototype.ngOnChanges=function(e){this.shouldRecreateView(e)&&(this.viewRef&&this._viewContainerRef.remove(this._viewContainerRef.indexOf(this.viewRef)),this.ngxTemplateOutlet&&(this.viewRef=this._viewContainerRef.createEmbeddedView(this.ngxTemplateOutlet,{}))),this.ngDoCheck()},e.prototype.ngDoCheck=function(){if(this.viewRef){var e=this.viewRef.context;this.updateExistingContext(this.context,e),this.updateExistingContext(this.additionalContext,e),e.$implicit=e}},e.prototype.shouldRecreateView=function(t){var r=t.context,n=t.additionalContext;return!!t.ngxTemplateOutlet||r&&e.hasContextShapeChanged(r)||n&&e.hasContextShapeChanged(n)},e.prototype.updateExistingContext=function(e,t){var r,n,i,o;if(e){var a=Object.getPrototypeOf(e);a==Object.prototype&&(a=e);var s=Object.getOwnPropertyNames(a);try{for(var c=__values(s),u=c.next();!u.done;u=c.next()){var l=u.value;if((h=Object.getOwnPropertyDescriptor(a,l)).get&&"$implicit"!==l)Object.defineProperty(t,l,h);else{var p=ObjectUtils.isFunction(h.value)?h.value.bind(e):null;p&&p!==a.constructor&&(t[l]=p)}}}catch(e){r={error:e}}finally{try{u&&!u.done&&(n=c.return)&&n.call(c)}finally{if(r)throw r.error}}try{for(var f=__values(Object.keys(e)),d=f.next();!d.done;d=f.next()){var h;l=d.value;(h=Object.getOwnPropertyDescriptor(a,l))&&h.get&&!h.set||(t[l]=e[l])}}catch(e){i={error:e}}finally{try{d&&!d.done&&(o=f.return)&&o.call(f)}finally{if(i)throw i.error}}}},e}();NgxTemplateOutletDirective.decorators=[{type:core.Directive,args:[{selector:"[ngxTemplateOutlet]"}]}],NgxTemplateOutletDirective.ctorParameters=function(){return[{type:core.ViewContainerRef}]},NgxTemplateOutletDirective.propDecorators={context:[{type:core.Input}],additionalContext:[{type:core.Input}],ngxTemplateOutlet:[{type:core.Input}]};var PaginationDirective=function(){function e(e){var t=this;this.zone=e,this.pageChange=new core.EventEmitter,this.onRefresh=new core.EventEmitter,this.updateTimer=TimerUtils.createTimeout((function(){return t.loadData()}),this.updateTime)}return Object.defineProperty(e.prototype,"total",{get:function(){return this.data?this.data.total:0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"items",{get:function(){return this.data?this.data.items:[]},enumerable:!1,configurable:!0}),e.prototype.ngOnChanges=function(e){(e.loader||e.itemsPerPage||e.page)&&(this.page=isNaN(this.page)||this.page<1?1:this.page,this.itemsPerPage=isNaN(this.itemsPerPage)||this.itemsPerPage<1?20:this.itemsPerPage,this.updateTimer.time=isNaN(this.updateTime)||this.updateTime<0?100:this.updateTime,this.waitFor=this.waitFor||Promise.resolve(!0),this.refresh())},e.prototype.refresh=function(){var e=this;this.waitFor.then((function(){e.updateTimer.run()}))},e.prototype.paginate=function(e){this.page=e,this.pageChange.emit(e),this.refresh()},e.prototype.loadData=function(){var e=this;this.loader&&this.loader(this.page,this.itemsPerPage).then((function(t){e.maxPage=!t||t.total<=0?1:Math.floor((t.total-1)/e.itemsPerPage)+1,e.data=t;var r=(e.page-1)*e.itemsPerPage,n=t.items||[];t.items=n.map((function(e,t){var i=r+t;return e instanceof PaginationItemContext?e:new PaginationItemContext(e,n,n.length,t,i)})),e.page>e.maxPage?e.paginate(e.maxPage):e.zone.run((function(){return e.onRefresh.emit(e)}))}))},e}();PaginationDirective.decorators=[{type:core.Directive,args:[{selector:"[pagination]",exportAs:"pagination"}]}],PaginationDirective.ctorParameters=function(){return[{type:core.NgZone}]},PaginationDirective.propDecorators={loader:[{type:core.Input,args:["pagination"]}],page:[{type:core.Input}],itemsPerPage:[{type:core.Input}],updateTime:[{type:core.Input}],waitFor:[{type:core.Input}],pageChange:[{type:core.Output}],onRefresh:[{type:core.Output}]};var PaginationItemDirective=function(){function e(e,t,r){this.pagination=e,this.viewContainer=t,this.templateRef=r}return e.prototype.ngOnInit=function(){var e=this;this.onRefresh=this.pagination.onRefresh.subscribe((function(){return e.renderView()}))},e.prototype.ngOnDestroy=function(){this.onRefresh.unsubscribe()},e.prototype.renderView=function(){var e=this;this.viewContainer.clear(),this.pagination.items.forEach((function(t){t.$implicit=t,e.viewContainer.createEmbeddedView(e.templateRef,t)}))},e}();PaginationItemDirective.decorators=[{type:core.Directive,args:[{selector:"[paginationItem]"}]}],PaginationItemDirective.ctorParameters=function(){return[{type:PaginationDirective},{type:core.ViewContainerRef},{type:core.TemplateRef}]};var ResourceIfDirective=function(){function e(e,t,r,n){this.http=e,this.viewContainer=t,this.templateRef=r,this.universal=n,this.context=new ResourceIfContext}return Object.defineProperty(e.prototype,"resourceIf",{get:function(){return this.resource},set:function(e){this.resource=e,this.renderView()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this.context.url},enumerable:!1,configurable:!0}),e.prototype.renderView=function(){var e=this;this.context=new ResourceIfContext,this.context.resource=this.resource,this.viewContainer.clear(),this.universal.isBrowser&&this.resource&&FileUtils.readDataFromUrl(this.http,this.resource).then((function(t){e.context.url=t,e.viewContainer.createEmbeddedView(e.templateRef,e.context)}),console.log)},e}();ResourceIfDirective.decorators=[{type:core.Directive,args:[{selector:"[resourceIf]",exportAs:"resourceIf"}]}],ResourceIfDirective.ctorParameters=function(){return[{type:http.HttpClient},{type:core.ViewContainerRef},{type:core.TemplateRef},{type:UniversalService}]},ResourceIfDirective.propDecorators={resourceIf:[{type:core.Input}]};var StickyDirective=function(){function e(e,t,r){var n=this;this.cdr=e,this.events=t,this.element=r,this.parentElement=this.element.nativeElement.parentElement,this.updateTimer=TimerUtils.createTimeout((function(){n.isUpdating=!1,n.cdr.detectChanges(),n.events.updateSticky(n.isSticky)}),10)}return e.prototype.ngOnInit=function(){var e=this;this.eventForwarded=this.events.eventForwarded.subscribe((function(t){t&&"scroll"===t.type&&e.updateSticky()}))},e.prototype.ngOnDestroy=function(){this.eventForwarded.unsubscribe()},e.prototype.updateSticky=function(){var e=this.parentElement.getBoundingClientRect().top;this.isSticky=e<1,this.isUpdating=!0,this.cdr.detectChanges(),this.updateTimer.run()},e}();StickyDirective.decorators=[{type:core.Directive,args:[{selector:"[sticky]"}]}],StickyDirective.ctorParameters=function(){return[{type:core.ChangeDetectorRef},{type:EventsService},{type:core.ElementRef}]},StickyDirective.propDecorators={isSticky:[{type:core.HostBinding,args:["class.sticky"]}],isUpdating:[{type:core.HostBinding,args:["class.sticky-update"]}],updateSticky:[{type:core.HostListener,args:["window:resize"]},{type:core.HostListener,args:["window:scroll"]}]};var UnorderedListItemDirective=function(){function e(e,t,r){this.elementRef=e,this.renderer=t,this.viewContainer=r}return Object.defineProperty(e.prototype,"elem",{get:function(){return this.elementRef.nativeElement},enumerable:!1,configurable:!0}),e.prototype.ngOnChanges=function(e){var t=this;this.templates&&this.defaultTemplates&&this.item&&(this.item.value instanceof Promise?this.item.value:Promise.resolve(this.item.value)).then((function(e){t.item.value=e,t.path=ObjectUtils.isNullOrUndefined(t.path)?"":t.path.toString(),t.isArray=ObjectUtils.isArray(t.data),t.isObject=ObjectUtils.isObject(t.data),t.valueIsArray=ObjectUtils.isArray(t.item.value),t.valueIsObject=ObjectUtils.isObject(t.item.value),t.valueType=ObjectUtils.getType(t.item.value);var r=t,n=t.templates.find((function(e){return e.type==t.type&&ObjectUtils.evaluate(e.selector,r)}))||t.defaultTemplates[t.type];t.viewContainer.clear(),t.viewContainer.createEmbeddedView(n,r),"item"===t.type&&(t.item.classList=[],t.isClass("is-array",t.valueIsArray),t.isClass("is-object",t.valueIsObject),t.isClass("is-value",!t.valueIsObject&&!t.valueIsArray),t.isClass("type-"+t.valueType),t.isClass("path-"+t.path.replace(/\./g,"-")),t.isClass("key-"+t.item.key))}),(function(e){console.log("Can't handle promise rejection",e)}))},e.prototype.isClass=function(e,t){void 0===t&&(t=!0),t&&this.item.classList.push(e)},e}();UnorderedListItemDirective.decorators=[{type:core.Directive,args:[{selector:"[unorderedListItem]"}]}],UnorderedListItemDirective.ctorParameters=function(){return[{type:core.ElementRef},{type:core.Renderer2},{type:core.ViewContainerRef}]},UnorderedListItemDirective.propDecorators={item:[{type:core.Input,args:["unorderedListItem"]}],type:[{type:core.Input}],data:[{type:core.Input}],keyPrefix:[{type:core.Input}],listStyle:[{type:core.Input}],path:[{type:core.Input}],level:[{type:core.Input}],templates:[{type:core.Input}],defaultTemplates:[{type:core.Input}]};var UnorderedListTemplateDirective=function(e){function t(t,r){var n=e.call(this)||this;return n.elementRef=t,n.templateRef=r,n}return __extends(t,e),t.prototype.createEmbeddedView=function(e){return this.templateRef.createEmbeddedView(e)},t}(UnorederedListTemplate);UnorderedListTemplateDirective.decorators=[{type:core.Directive,args:[{selector:"ng-template[type][selector]"}]}],UnorderedListTemplateDirective.ctorParameters=function(){return[{type:core.ElementRef},{type:core.TemplateRef}]},UnorderedListTemplateDirective.propDecorators={type:[{type:core.Input}],selector:[{type:core.Input}]};var UnorderedListComponent=function(){function e(e){this.cdr=e,this.keyPrefix="",this.listStyle="table",this.path="",this.level=0}return e.prototype.ngOnChanges=function(e){this.isArray=ObjectUtils.isArray(this.data),this.isObject=ObjectUtils.isObject(this.data)},e.prototype.ngAfterContentInit=function(){var e=this.templateDirectives.toArray();this.templates=this.templates?this.templates.concat(e):e,this.cdr.detectChanges()},e.prototype.ngAfterViewInit=function(){this.defaultTemplates={key:this.defaultKeyTemplate,value:this.defaultValueTemplate,item:this.defaultItemTemplate},this.cdr.detectChanges()},e}();UnorderedListComponent.decorators=[{type:core.Component,args:[{selector:"unordered-list",template:'<ng-template let-keyPrefix="keyPrefix" let-key="item.key" let-isArray="isArray" #defaultKeyTemplate>\r\n {{ (keyPrefix ? keyPrefix + key : key) | translate }}:\r\n</ng-template>\r\n<ng-template let-keyPrefix="keyPrefix" let-listStyle="listStyle" let-val="item.value" let-path="path"\r\n let-templates="templates" let-isObject="valueIsObject" let-isArray="valueIsArray" #defaultValueTemplate>\r\n <ng-template #value>{{ val }}</ng-template>\r\n <unordered-list [data]="val"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path"\r\n [level]="level + 1"\r\n [templates]="templates"\r\n *ngIf="(isObject || isArray); else value"></unordered-list>\r\n</ng-template>\r\n<ng-template let-item="item" let-data="data" let-keyPrefix="keyPrefix" let-listStyle="listStyle" let-path="path" let-level="level" let-templates="templates" #defaultItemTemplate>\r\n <ng-template #itemKey>\r\n <ng-container [unorderedListItem]="item"\r\n type="key"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </ng-template>\r\n <ng-template #itemValue>\r\n <ng-container [unorderedListItem]="item"\r\n type="value"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </ng-template>\r\n <ng-container *ngIf="!isArray">\r\n <th *ngIf="listStyle == \'table\'; else itemKey">\r\n <ng-container [ngTemplateOutlet]="itemKey"></ng-container>\r\n </th>\r\n </ng-container>\r\n <td *ngIf="listStyle == \'table\'; else itemValue">\r\n <ng-container [ngTemplateOutlet]="itemValue"></ng-container>\r\n </td>\r\n</ng-template>\r\n<ng-template #value>\r\n {{ data }}\r\n</ng-template>\r\n<ng-container *ngIf="(isObject || isArray); else value" [ngSwitch]="listStyle">\r\n <ul [ngClass]="\'level-\' + level" *ngSwitchCase="\'list\'">\r\n <li *ngFor="let item of data | entries" [ngClass]="item.classList">\r\n <ng-container [unorderedListItem]="item"\r\n type="item"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path ? path + \'.\' + item.key : item.key"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </li>\r\n </ul>\r\n <table [ngClass]="\'level-\' + level" *ngSwitchDefault>\r\n <tr *ngFor="let item of data | entries" [ngClass]="item.classList">\r\n <ng-container [unorderedListItem]="item"\r\n type="item"\r\n [data]="data"\r\n [keyPrefix]="keyPrefix"\r\n [listStyle]="listStyle"\r\n [path]="path ? path + \'.\' + item.key : item.key"\r\n [level]="level"\r\n [templates]="templates"\r\n [defaultTemplates]="defaultTemplates"></ng-container>\r\n </tr>\r\n </table>\r\n</ng-container>\r\n'}]}],UnorderedListComponent.ctorParameters=function(){return[{type:core.ChangeDetectorRef}]},UnorderedListComponent.propDecorators={data:[{type:core.Input}],keyPrefix:[{type:core.Input}],listStyle:[{type:core.Input}],path:[{type:core.Input}],level:[{type:core.Input}],templates:[{type:core.Input}],templateDirectives:[{type:core.ContentChildren,args:[UnorderedListTemplateDirective]}],defaultKeyTemplate:[{type:core.ViewChild,args:["defaultKeyTemplate"]}],defaultValueTemplate:[{type:core.ViewChild,args:["defaultValueTemplate"]}],defaultItemTemplate:[{type:core.ViewChild,args:["defaultItemTemplate"]}]};var DynamicTableComponent=function(){function e(){var e=this;this.loadData=function(t,r){var n=e.orders[e.orderBy];return e.dataLoader(t,r,n,e.orderDescending,e.filter)},this.dataLoader=this.loadLocalData,this.placeholder="",this.tableId=UniqueUtils.uuid(),this.templates={},this.filter="",this.orders={}}return Object.defineProperty(e.prototype,"items",{get:function(){return this.pagination?this.pagination.items:[]},enumerable:!1,configurable:!0}),e.compare=function(e,t,r){return t=t.item?t.item[e]:null,r=r.item?r.item[e]:null,ObjectUtils.compare(t,r)},e.prototype.ngAfterContentInit=function(){this.templates=this.templateDirectives.reduce((function(e,t){return ObjectUtils.isArray(t.column)?(t.column.forEach((function(r){e[r]=t})),e):ObjectUtils.isString(t.column)&&0!=t.column.length?(e[t.column]=t,e):e}),{})},e.prototype.ngAfterViewInit=function(){this.rowTemplate=this.rowTemplate||this.defaultRowTemplate,this.filterTemplate=this.filterTemplate||this.defaultFilterTemplate},e.prototype.ngOnChanges=function(e){if(e.columns){var t=e.columns.currentValue||[];this.orders=ObjectUtils.isArray(t)?t.reduce((function(e,t){return e[t]=t,e}),{}):t,this.cols=Object.keys(this.orders),this.orderBy=this.orderBy in this.orders?this.orderBy:this.columns[0]}e.orderBy&&this.orders&&(this.orderBy=this.orderBy in this.orders?this.orderBy:this.columns[0]),(e.data||e.parallelData||e.itemsPerPage||e.orderBy||e.orderDescending)&&this.refresh()},e.prototype.refresh=function(){this.pagination&&this.pagination.refresh()},e.prototype.setFilter=function(e){this.filter=e,this.refresh()},e.prototype.setOrder=function(e){this.orderDescending=e==this.orderBy&&!this.orderDescending,this.orderBy=e,this.refresh()},e.prototype.loadLocalData=function(t,r,n,i,o){if(!this.data)return Promise.resolve({total:0,items:[]});var a=i?function(t,r){return e.compare(n,r,t)}:function(t,r){return e.compare(n,t,r)},s=(t-1)*r,c=this.data.length,u=Math.min(r,c-s),l=this.parallelData||[],p=this.data.map((function(e,t){return new PaginationItemContext(e,l[t]||{},c,t,t)}));if(ObjectUtils.isString(o)&&o.length>0){var f=new RegExp(o,"gi");p=p.filter((function(e){return e.filter(f)}))}var d=n?p.sort(a).splice(s,u):p.splice(s,u);return d.forEach((function(e,t){e.index=s+t})),Promise.resolve({total:c,items:d})},e}();DynamicTableComponent.decorators=[{type:core.Component,args:[{selector:"dynamic-table",template:'<div class="dynamic-table" #pagination="pagination" [pagination]="loadData" [itemsPerPage]="itemsPerPage" [updateTime]="updateTime">\r\n <ng-template #defaultFilterTemplate let-table>\r\n <div class="table-search" *ngIf="table.showFilter">\r\n <label *ngIf="label" [attr.for]="tableId">{{ label | translate }}</label>\r\n <input type="text"\r\n class="form-control"\r\n [attr.id]="tableId"\r\n [placeholder]="placeholder | translate"\r\n [ngModel]="table.filter"\r\n (ngModelChange)="table.setFilter($event)"/>\r\n </div>\r\n </ng-template>\r\n <ng-container [ngxTemplateOutlet]="filterTemplate || defaultFilterTemplate" [context]="this"></ng-container>\r\n <pagination-menu [maxSize]="maxPages" [directionLinks]="directionLinks" [boundaryLinks]="boundaryLinks"></pagination-menu>\r\n <div class="table-responsive">\r\n\r\n <ng-template #columnTemplate let-context let-column="column" let-template="template">\r\n <ng-template #defaultTemplate let-column="column" let-item="item">\r\n <span>{{ item[column] == undefined || item[column] == null ? \'-\' : item[column] }}</span>\r\n </ng-template>\r\n <ng-template #pureTemplate>\r\n <ng-container [ngxTemplateOutlet]="template.ref" [context]="context"></ng-container>\r\n </ng-template>\r\n <td [ngClass]="\'column-\' + column" *ngIf="!template || !template.pure; else pureTemplate">\r\n <ng-container [ngxTemplateOutlet]="!template ? defaultTemplate : template.ref" [context]="context"></ng-container>\r\n </td>\r\n </ng-template>\r\n\r\n <ng-template #columnsTemplate let-context>\r\n <ng-container *ngFor="let column of cols"\r\n [ngxTemplateOutlet]="columnTemplate"\r\n [context]="context"\r\n [additionalContext]="{\r\n template: templates[column],\r\n column: column\r\n }"></ng-container>\r\n </ng-template>\r\n\r\n <ng-template #defaultRowTemplate let-context>\r\n <tr>\r\n <ng-container [ngxTemplateOutlet]="columnsTemplate" [context]="context"></ng-container>\r\n </tr>\r\n </ng-template>\r\n\r\n <ng-template #defaultWrapperTemplate>\r\n <table class="table table-striped">\r\n <thead>\r\n <tr>\r\n <th *ngFor="let column of cols" [ngClass]="\'column-\' + column">\r\n <a *ngIf="orders[column]" (click)="setOrder(column)">\r\n <span>{{ \'label.\' + column | translate }}</span>\r\n <i *ngIf="orderBy == column"\r\n [icon]="orderDescending ? \'sort-desc\' : \'sort-asc\'"\r\n [ngClass]="orderBy == column ? (orderDescending ? \'sort-desc\': \'sort-asc\') : \'\'"></i>\r\n </a>\r\n <span *ngIf="!orders[column]">{{ \'label.\' + column | translate }}</span>\r\n </th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <ng-container *paginationItem="let context"\r\n [ngxTemplateOutlet]="rowTemplate"\r\n [context]="context"\r\n [additionalContext]="this"></ng-container>\r\n </tbody>\r\n </table>\r\n </ng-template>\r\n\r\n <ng-container [ngxTemplateOutlet]="wrapperTemplate || defaultWrapperTemplate"\r\n [context]="this"></ng-container>\r\n </div>\r\n <pagination-menu [maxSize]="maxPages" [directionLinks]="directionLinks" [boundaryLinks]="boundaryLinks"></pagination-menu>\r\n</div>\r\n'}]}],DynamicTableComponent.ctorParameters=function(){return[]},DynamicTableComponent.propDecorators={label:[{type:core.Input}],placeholder:[{type:core.Input}],dataLoader:[{type:core.Input}],data:[{type:core.Input}],parallelData:[{type:core.Input}],columns:[{type:core.Input}],showFilter:[{type:core.Input}],itemsPerPage:[{type:core.Input}],updateTime:[{type:core.Input}],maxPages:[{type:core.Input}],directionLinks:[{type:core.Input}],boundaryLinks:[{type:core.Input}],orderBy:[{type:core.Input}],orderDescending:[{type:core.Input}],rowTemplate:[{type:core.ContentChild,args:["rowTemplate",{static:!0}]}],wrapperTemplate:[{type:core.ContentChild,args:["wrapperTemplate",{static:!0}]}],filterTemplate:[{type:core.ContentChild,args:["filterTemplate",{static:!0}]}],columnsTemplate:[{type:core.ViewChild,args:["columnsTemplate",{static:!0}]}],defaultRowTemplate:[{type:core.ViewChild,args:["defaultRowTemplate",{static:!0}]}],defaultWrapperTemplate:[{type:core.ViewChild,args:["defaultWrapperTemplate",{static:!0}]}],defaultFilterTemplate:[{type:core.ViewChild,args:["defaultFilterTemplate",{static:!0}]}],pagination:[{type:core.ViewChild,args:["pagination"]}],templateDirectives:[{type:core.ContentChildren,args:[DynamicTableTemplateDirective]}]};var PaginationMenuComponent=function(){function e(e,t,r){this.state=e,this.pagination=t,this.icons=r,this.maxSize=5,this.directionLinks=!0,this.boundaryLinks=!0,this.firstLabel="<<",this.prevLabel="<",this.nextLabel=">",this.lastLabel=">>"}return Object.defineProperty(e.prototype,"hasPrev",{get:function(){return this.pagination.page>1},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hasNext",{get:function(){return this.pagination.page<this.pagination.maxPage},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){var e=this;this.onRefresh=this.pagination.onRefresh.subscribe((function(){return e.setPages()})),this.setIcon("firstLabel","first-page"),this.setIcon("prevLabel","prev-page"),this.setIcon("nextLabel","next-page"),this.setIcon("lastLabel","last-page")},e.prototype.ngOnDestroy=function(){this.onRefresh&&this.onRefresh.unsubscribe()},e.prototype.ngOnChanges=function(e){this.maxSize=isNaN(this.maxSize)||this.maxSize<=0?5:this.maxSize,this.directionLinks=!ObjectUtils.isBoolean(this.directionLinks)||this.directionLinks,this.boundaryLinks=!ObjectUtils.isBoolean(this.boundaryLinks)||this.boundaryLinks,this.setPages()},e.prototype.paginate=function(e){if(!(this.pagination.page==e||this.pagination.maxPage<e||e<1))if(this.urlParam){var t=Object.assign({},this.state.params);t[this.urlParam]=e.toString();var r=StateService.toPath(this.state.route,t);this.state.navigateByUrl(r)}else this.pagination.paginate(e)},e.prototype.setIcon=function(e,t){var r=this;this.icons.getIcon(t,t,!1).then((function(n){n!=t&&(r[e]=n)}))},e.prototype.setPages=function(){if(this.pagination){var e=this.pagination.maxPage,t=Math.max(this.pagination.page-Math.floor(this.maxSize/2),1),r=t+this.maxSize-1;r>e&&(r=e,t=Math.max(r-this.maxSize+1,1));for(var n=[],i=t;i<=r;i++)n.push(i);this.pages=n}},e}();PaginationMenuComponent.decorators=[{type:core.Component,args:[{selector:"pagination-menu",template:'<div class="pagination-menu" *ngIf="pagination.total > pagination.itemsPerPage">\r\n <ul class="pagination">\r\n <li class="page-item" [ngClass]="{disabled: !hasPrev}" *ngIf="boundaryLinks">\r\n <a class="page-link" (click)="paginate(1)" [innerHTML]="firstLabel | safe"></a>\r\n </li>\r\n <li class="page-item" [ngClass]="{disabled: !hasPrev}" *ngIf="directionLinks">\r\n <a class="page-link" (click)="paginate(pagination.page - 1)" [innerHTML]="prevLabel | safe"></a>\r\n </li>\r\n <li class="page-item" [ngClass]="{active: pagination.page == page}" *ngFor="let page of pages">\r\n <a class="page-link" [ngClass]="{active: pagination.page == page}" (click)="paginate(page)">{{ page }}</a>\r\n </li>\r\n <li class="page-item" [ngClass]="{disabled: !hasNext}" *ngIf="directionLinks">\r\n <a class="page-link" (click)="paginate(pagination.page + 1)" [innerHTML]="nextLabel | safe"></a>\r\n </li>\r\n <li class="page-item" [ngClass]="{disabled: !hasNext}" *ngIf="boundaryLinks">\r\n <a class="page-link" (click)="paginate(pagination.maxPage)" [innerHTML]="lastLabel | safe"></a>\r\n </li>\r\n </ul>\r\n</div>\r\n'}]}],PaginationMenuComponent.ctorParameters=function(){return[{type:StateService},{type:PaginationDirective},{type:void 0,decorators:[{type:core.Inject,args:[ICON_SERVICE]}]}]},PaginationMenuComponent.propDecorators={maxSize:[{type:core.Input}],urlParam:[{type:core.Input}],directionLinks:[{type:core.Input}],boundaryLinks:[{type:core.Input}]};var StickyClassDirective=function(){function e(e,t,r){this.events=e,this.element=t,this.renderer=r}return e.prototype.ngOnInit=function(){var e=this;this.stickyUpdated=this.events.stickyUpdated.subscribe((function(){e.events.isSticky?e.renderer.addClass(e.element.nativeElement,e.stickyClass||"sticky-sibling"):e.renderer.removeClass(e.element.nativeElement,e.stickyClass||"sticky-sibling")}))},e.prototype.ngOnDestroy=function(){this.stickyUpdated.unsubscribe()},e}();StickyClassDirective.decorators=[{type:core.Directive,args:[{selector:"[stickyClass]"}]}],StickyClassDirective.ctorParameters=function(){return[{type:EventsService},{type:core.ElementRef},{type:core.Renderer2}]},StickyClassDirective.propDecorators={stickyClass:[{type:core.Input}]};var pipes=[ChunkPipe,EntriesPipe,ExtraItemPropertiesPipe,FilterPipe,FindPipe,FormatNumberPipe,GetOffsetPipe,GetTypePipe,GlobalTemplatePipe,GroupByPipe,IsTypePipe,JoinPipe,KeysPipe,MapPipe,MaxPipe,MinPipe,ReducePipe,RemapPipe,ReplacePipe,ReversePipe,RoundPipe,SafeHtmlPipe,TranslatePipe,ValuesPipe],directives=[AsyncMethodDirective,BackgroundDirective,DynamicTableTemplateDirective,GlobalTemplateDirective,IconDirective,NgxTemplateOutletDirective,PaginationDirective,PaginationItemDirective,ResourceIfDirective,StickyDirective,StickyClassDirective,UnorderedListItemDirective,UnorderedListTemplateDirective],components=[DynamicTableComponent,PaginationMenuComponent,UnorderedListComponent],providers=__spread(pipes,[BaseHttpClient,BaseHttpService,AuthGuard,AclService,ApiService,StaticAuthService,ConfigService,ErrorHandlerService,EventsService,FormatterService,GlobalTemplateService,IconService,LanguageService,OpenApiService,PromiseService,StateService,StaticLanguageService,StorageService,ConsoleToasterService,TranslatedUrlSerializer,UniversalService,ngxDeviceDetector.DeviceDetectorService,{provide:platformBrowser.EVENT_MANAGER_PLUGINS,useClass:ResizeEventPlugin,multi:!0},{provide:platformBrowser.EVENT_MANAGER_PLUGINS,useClass:ScrollEventPlugin,multi:!0},{provide:router.UrlSerializer,useExisting:TranslatedUrlSerializer},{provide:core.ErrorHandler,useExisting:ErrorHandlerService}]);function loadConfig(e){return e.load}var NgxUtilsModule=function(){function e(){}return e.forRoot=function(t){return{ngModule:e,providers:__spread(providers,[{provide:API_SERVICE,useExisting:(t?t.apiService:null)||ApiService},{provide:AUTH_SERVICE,useExisting:(t?t.authService:null)||StaticAuthService},{provide:ICON_SERVICE,useExisting:(t?t.iconService:null)||IconService},{provide:LANGUAGE_SERVICE,useExisting:(t?t.languageService:null)||StaticLanguageService},{provide:TOASTER_SERVICE,useExisting:(t?t.toasterService:null)||ConsoleToasterService},{provide:PROMISE_SERVICE,useExisting:(t?t.promiseService:null)||PromiseService},{provide:CONFIG_SERVICE,useExisting:(t?t.configService:null)||ConfigService}],t&&t.configService?[{provide:core.APP_INITIALIZER,useFactory:loadConfig,multi:!0,deps:[CONFIG_SERVICE]}]:[])}},e}();NgxUtilsModule.decorators=[{type:core.NgModule,args:[{declarations:__spread(pipes,directives,components),imports:[common.CommonModule,forms.FormsModule],exports:__spread(pipes,directives,components,[forms.FormsModule]),providers:pipes}]}],exports.API_SERVICE=API_SERVICE,exports.AUTH_SERVICE=AUTH_SERVICE,exports.AclService=AclService,exports.AjaxRequestHandler=AjaxRequestHandler,exports.ApiService=ApiService,exports.ArrayUtils=ArrayUtils,exports.AsyncMethodDirective=AsyncMethodDirective,exports.AuthGuard=AuthGuard,exports.BASE_CONFIG=BASE_CONFIG,exports.BackgroundDirective=BackgroundDirective,exports.BaseHttpClient=BaseHttpClient,exports.BaseHttpService=BaseHttpService,exports.CONFIG_SERVICE=CONFIG_SERVICE,exports.CanvasColor=CanvasColor,exports.CanvasUtils=CanvasUtils,exports.ChunkPipe=ChunkPipe,exports.Circle=Circle,exports.ConfigService=ConfigService,exports.ConsoleToasterService=ConsoleToasterService,exports.DateUtils=DateUtils,exports.DynamicTableComponent=DynamicTableComponent,exports.DynamicTableTemplateDirective=DynamicTableTemplateDirective,exports.ERROR_HANDLER=ERROR_HANDLER,exports.EXPRESS_REQUEST=EXPRESS_REQUEST,exports.EntriesPipe=EntriesPipe,exports.ErrorHandlerService=ErrorHandlerService,exports.EventsService=EventsService,exports.ExtraItemPropertiesPipe=ExtraItemPropertiesPipe,exports.FactoryDependencies=FactoryDependencies,exports.FileUtils=FileUtils,exports.FilterPipe=FilterPipe,exports.FindPipe=FindPipe,exports.FormatNumberPipe=FormatNumberPipe,exports.FormatterService=FormatterService,exports.GenericValue=GenericValue,exports.GetOffsetPipe=GetOffsetPipe,exports.GetTypePipe=GetTypePipe,exports.GlobalTemplateDirective=GlobalTemplateDirective,exports.GlobalTemplatePipe=GlobalTemplatePipe,exports.GlobalTemplateService=GlobalTemplateService,exports.GroupByPipe=GroupByPipe,exports.HttpPromise=HttpPromise,exports.ICON_SERVICE=ICON_SERVICE,exports.IConfiguration=IConfiguration,exports.IconDirective=IconDirective,exports.IconService=IconService,exports.Initializer=Initializer,exports.IsTypePipe=IsTypePipe,exports.JoinPipe=JoinPipe,exports.KeysPipe=KeysPipe,exports.LANGUAGE_SERVICE=LANGUAGE_SERVICE,exports.LanguageService=LanguageService,exports.LoaderUtils=LoaderUtils,exports.MapPipe=MapPipe,exports.MathUtils=MathUtils,exports.MaxPipe=MaxPipe,exports.MinPipe=MinPipe,exports.NgxTemplateOutletDirective=NgxTemplateOutletDirective,exports.NgxUtilsModule=NgxUtilsModule,exports.ObjectUtils=ObjectUtils,exports.ObservableUtils=ObservableUtils,exports.OpenApiService=OpenApiService,exports.PROMISE_SERVICE=PROMISE_SERVICE,exports.PaginationDirective=PaginationDirective,exports.PaginationItemContext=PaginationItemContext,exports.PaginationItemDirective=PaginationItemDirective,exports.PaginationMenuComponent=PaginationMenuComponent,exports.Point=Point,exports.PromiseService=PromiseService,exports.Rect=Rect,exports.ReducePipe=ReducePipe,exports.ReflectUtils=ReflectUtils,exports.RemapPipe=RemapPipe,exports.ReplacePipe=ReplacePipe,exports.ResizeEventPlugin=ResizeEventPlugin,exports.ResourceIfContext=ResourceIfContext,exports.ResourceIfDirective=ResourceIfDirective,exports.ReversePipe=ReversePipe,exports.RoundPipe=RoundPipe,exports.SCRIPT_PARAMS=SCRIPT_PARAMS,exports.SafeHtmlPipe=SafeHtmlPipe,exports.ScrollEventPlugin=ScrollEventPlugin,exports.SetUtils=SetUtils,exports.StateService=StateService,exports.StaticAuthService=StaticAuthService,exports.StaticLanguageService=StaticLanguageService,exports.StickyDirective=StickyDirective,exports.StorageService=StorageService,exports.StringUtils=StringUtils,exports.TOASTER_SERVICE=TOASTER_SERVICE,exports.TimerUtils=TimerUtils,exports.TranslatePipe=TranslatePipe,exports.TranslatedUrlSerializer=TranslatedUrlSerializer,exports.UniqueUtils=UniqueUtils,exports.UniversalService=UniversalService,exports.UnorderedListComponent=UnorderedListComponent,exports.UnorderedListItemDirective=UnorderedListItemDirective,exports.UnorderedListTemplateDirective=UnorderedListTemplateDirective,exports.UnorederedListTemplate=UnorederedListTemplate,exports.ValuesPipe=ValuesPipe,exports.Vector=Vector,exports.ɵa=pipes,exports.ɵb=directives,exports.ɵc=components,exports.ɵd=providers,exports.ɵe=loadConfig,exports.ɵf=StickyClassDirective,Object.defineProperty(exports,"__esModule",{value:!0})}));
|
|
16
16
|
//# sourceMappingURL=stemy-ngx-utils.umd.min.js.map
|