@coolon/angular-ui-powerups 3.7.0-alpha.1 → 3.7.0-alpha.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +64 -0
- package/bundles/coolon-angular-ui-powerups.umd.js +423 -667
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js.map +1 -1
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/esm2015/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/commands/command/command.component.js +15 -12
- package/esm2015/lib/components/commands/command/command.component.js.map +1 -1
- package/esm2015/lib/components/commands/command/command.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/flex.component.js +2 -9
- package/esm2015/lib/components/commands/flex.component.js.map +1 -1
- package/esm2015/lib/components/commands/flex.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/group/command-container.js +21 -0
- package/esm2015/lib/components/commands/group/command-container.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-container.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-aware.component.js +26 -0
- package/esm2015/lib/components/commands/group/popup-aware.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-aware.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-container.js +3 -0
- package/esm2015/lib/components/commands/group/popup-container.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-container.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.js +65 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.js +47 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.js +90 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.js +42 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.js +12 -15
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.js.map +1 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.scss.ngstyle.js.map +1 -0
- package/esm2015/lib/components/commands/separator.component.js +25 -14
- package/esm2015/lib/components/commands/separator.component.js.map +1 -1
- package/esm2015/lib/components/commands/separator.component.metadata.json +1 -1
- package/esm2015/lib/components/components.module.js +6 -9
- package/esm2015/lib/components/components.module.js.map +1 -1
- package/esm2015/lib/components/components.module.metadata.json +1 -1
- package/esm2015/lib/components/components.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/exports.js +7 -8
- package/esm2015/lib/components/exports.js.map +1 -1
- package/esm2015/lib/components/exports.metadata.json +1 -1
- package/esm2015/lib/interaction/interaction.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.js +12 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.js.map +1 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.metadata.json +1 -1
- package/esm2015/lib/place/guards/place.guard.js +31 -41
- package/esm2015/lib/place/guards/place.guard.js.map +1 -1
- package/esm2015/lib/place/guards/place.guard.metadata.json +1 -1
- package/esm2015/lib/place/place-auth-service.js.map +1 -1
- package/esm2015/lib/place/place-auth-service.metadata.json +1 -1
- package/esm2015/lib/place/place.module.ngfactory.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +361 -562
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/commands/command/command.component.d.ts +7 -6
- package/lib/components/commands/flex.component.d.ts +1 -3
- package/lib/components/commands/group/command-container.d.ts +16 -0
- package/lib/components/commands/group/popup-aware.component.d.ts +12 -0
- package/lib/components/commands/group/popup-container.d.ts +6 -0
- package/lib/components/commands/group/popup-menu/abstract-popup-menu.component.d.ts +25 -0
- package/lib/components/commands/group/popup-menu/more-menu.component.d.ts +12 -0
- package/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.d.ts +33 -0
- package/lib/components/commands/group/popup-menu/popup-menu.component.d.ts +13 -0
- package/lib/components/commands/group/tool-bar/tool-bar.component.d.ts +4 -5
- package/lib/components/commands/separator.component.d.ts +8 -7
- package/lib/components/exports.d.ts +7 -8
- package/lib/place/components/place-outlet/place-outlet.component.d.ts +3 -1
- package/lib/place/guards/place.guard.d.ts +2 -1
- package/lib/place/place-auth-service.d.ts +4 -4
- package/package.json +2 -2
- package/schematics/place-routes/index.d.ts +1 -1
- package/schematics/place-routes/index.js +9 -14
- package/schematics/place-routes/index.js.map +1 -1
- package/schematics/place-routes/place-builder.d.ts +3 -5
- package/schematics/place-routes/place-builder.js +4 -23
- package/schematics/place-routes/place-builder.js.map +1 -1
- package/schematics/place-routes/place-class-scanner.d.ts +3 -2
- package/schematics/place-routes/place-class-scanner.js.map +1 -1
- package/schematics/place-routes/place-def.d.ts +3 -2
- package/schematics/place-routes/place-def.js.map +1 -1
- package/schematics/utils/build-context.js +1 -1
- package/schematics/utils/build-context.js.map +1 -1
- package/schematics/utils/schematic-tree-file-system.d.ts +3 -2
- package/schematics/utils/schematic-tree-file-system.js +11 -2
- package/schematics/utils/schematic-tree-file-system.js.map +1 -1
- package/esm2015/lib/components/commands/group/command-group/command-group.component.js +0 -43
- package/esm2015/lib/components/commands/group/command-group/command-group.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group/command-group.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/command-group/command-group.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js +0 -46
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js +0 -39
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.scss.shim.ngstyle.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group.js +0 -103
- package/esm2015/lib/components/commands/group/command-group.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/more-menu.component.js +0 -53
- package/esm2015/lib/components/commands/group/more-menu.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/more-menu.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/more-menu.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/popup-menu.component.js +0 -52
- package/esm2015/lib/components/commands/group/popup-menu.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/popup-menu.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/popup-menu.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/registration.js +0 -58
- package/esm2015/lib/components/commands/group/registration.js.map +0 -1
- package/esm2015/lib/components/commands/group/registration.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.scss.shim.ngstyle.js.map +0 -1
- package/esm2015/lib/components/commands/group/view-data.js +0 -113
- package/esm2015/lib/components/commands/group/view-data.js.map +0 -1
- package/esm2015/lib/components/commands/group/view-data.metadata.json +0 -1
- package/lib/components/commands/group/command-group/command-group.component.d.ts +0 -12
- package/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.d.ts +0 -21
- package/lib/components/commands/group/command-group-renderer/command-group-renderer.component.d.ts +0 -13
- package/lib/components/commands/group/command-group.d.ts +0 -42
- package/lib/components/commands/group/more-menu.component.d.ts +0 -14
- package/lib/components/commands/group/popup-menu.component.d.ts +0 -17
- package/lib/components/commands/group/registration.d.ts +0 -32
- package/lib/components/commands/group/view-data.d.ts +0 -41
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/common"),require("@angular/core"),require("@angular/forms"),require("@angular/material/form-field"),require("@angular/material/input"),require("@angular/material/select"),require("@angular/material/tabs"),require("@angular/platform-browser/animations"),require("@angular/cdk/portal"),require("@angular/cdk/scrolling"),require("@angular/material/autocomplete"),require("@angular/material/button"),require("@angular/material/checkbox"),require("@angular/material/divider"),require("@angular/material/icon"),require("@angular/material/menu"),require("@angular/material/table"),require("@angular/material/tooltip"),require("@fortawesome/angular-fontawesome"),require("@fortawesome/free-solid-svg-icons"),require("@coolon/pectin"),require("@typescript-plus/fast-memoize-decorator/dist/src"),require("lodash"),require("typescript-string-enums"),require("@coolon/typescript-utilities"),require("immer"),require("@angular/flex-layout"),require("@angular/material/dialog"),require("@angular/router"),require("@angular/cdk/overlay"),require("resize-observer-polyfill"),require("@angular/material/list"),require("@angular/material/progress-spinner"),require("@typescript-plus/fast-memoize-decorator"),require("reflect-metadata"),require("@angular/animations")):"function"==typeof define&&define.amd?define("@coolon/angular-ui-powerups",["exports","@angular/common","@angular/core","@angular/forms","@angular/material/form-field","@angular/material/input","@angular/material/select","@angular/material/tabs","@angular/platform-browser/animations","@angular/cdk/portal","@angular/cdk/scrolling","@angular/material/autocomplete","@angular/material/button","@angular/material/checkbox","@angular/material/divider","@angular/material/icon","@angular/material/menu","@angular/material/table","@angular/material/tooltip","@fortawesome/angular-fontawesome","@fortawesome/free-solid-svg-icons","@coolon/pectin","@typescript-plus/fast-memoize-decorator/dist/src","lodash","typescript-string-enums","@coolon/typescript-utilities","immer","@angular/flex-layout","@angular/material/dialog","@angular/router","@angular/cdk/overlay","resize-observer-polyfill","@angular/material/list","@angular/material/progress-spinner","@typescript-plus/fast-memoize-decorator","reflect-metadata","@angular/animations"],e):e(((t="undefined"!=typeof globalThis?globalThis:t||self).coolon=t.coolon||{},t.coolon["angular-ui-powerups"]={}),t.ng.common,t.ng.core,t.ng.forms,t.ng.material.formField,t.ng.material.input,t.ng.material.select,t.ng.material.tabs,t.ng.platformBrowser.animations,t.ng.cdk.portal,t.ng.cdk.scrolling,t.ng.material.autocomplete,t.ng.material.button,t.ng.material.checkbox,t.ng.material.divider,t.ng.material.icon,t.ng.material.menu,t.ng.material.table,t.ng.material.tooltip,t.angularFontawesome,t.freeSolidSvgIcons,t.pectin,t.src,t._,t.typescriptStringEnums,t.typescriptUtilities,t.produce,t.ng.flexLayout,t.ng.material.dialog,t.ng.router,t.ng.cdk.overlay,t.ResizeObserver,t.ng.material.list,t.ng.material.progressSpinner,t.fastMemoizeDecorator,null,t.ng.animations)}(this,(function(t,e,n,o,i,r,a,s,c,l,u,p,d,f,m,h,g,y,v,b,C,I,w,M,x,P,R,S,D,A,T,O,F,E,k,V,_){"use strict";function L(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var j=L(M),N=L(R),U=L(O),H=function(t,e){return(H=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function B(t,e){function n(){this.constructor=t}H(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function G(t,e,n,o){var i,r=arguments.length,a=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,o);else for(var s=t.length-1;s>=0;s--)(i=t[s])&&(a=(r<3?i(a):r>3?i(e,n,a):i(e,n))||a);return r>3&&a&&Object.defineProperty(e,n,a),a}function q(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function W(t,e,n,o){return new(n||(n=Promise))((function(i,r){function a(t){try{c(o.next(t))}catch(t){r(t)}}function s(t){try{c(o.throw(t))}catch(t){r(t)}}function c(t){var e;t.done?i(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,s)}c((o=o.apply(t,e||[])).next())}))}function z(t,e){var n,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==r[0]&&2!==r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=e.call(t,a)}catch(t){r=[6,t],o=0}finally{n=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}}Object.create;function K(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var o,i,r=n.call(t),a=[];try{for(;(void 0===e||e-- >0)&&!(o=r.next()).done;)a.push(o.value)}catch(t){i={error:t}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(i)throw i.error}}return a}function $(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(K(arguments[e]));return t}Object.create;var X=function(t){function e(e,n,o){var i=t.call(this)||this;return i.elementRef=e,i._commandEnabled=(new I.DelegatingValueModel).withDefault(!1),i._commandParameterProvided=!1,i.matControl=n||o,i}return B(e,t),Object.defineProperty(e.prototype,"pectinCommand",{get:function(){return this._command},set:function(t){this._command=t,this._commandEnabled.setDelegate(t?t.enabled:null)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"commandParameter",{get:function(){return this._commandParameter},set:function(t){this._commandParameterProvided=!0,this._commandParameter=t},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){I.assert.notNil(this.pectinCommand),this.pectinCommand instanceof I.UnaryCommand?this._commandParameterProvided||I.lang.illegalState("UnaryCommands require the command parameter to be specified."):this._commandParameterProvided&&I.lang.illegalState("command parameters are only supported by UnaryCommands")},e.prototype.ngAfterViewInit=function(){var t=this;(0,I.Dsl.disposeWith(this).when)(this._commandEnabled).changes((function(e){return t.updateEnabledState(e)}),{initialValue:"triggerChange"})},e.prototype.updateEnabledState=function(t){var e=this;this.matControl&&setTimeout((function(){e.matControl.disabled=!t}),0),t?(this.elementRef.nativeElement.removeAttribute("disabled"),"A"===this.elementRef.nativeElement.tagName&&this.elementRef.nativeElement.setAttribute("href","javascript:void")):(this.elementRef.nativeElement.setAttribute("disabled","disabled"),"A"===this.elementRef.nativeElement.tagName&&this.elementRef.nativeElement.removeAttribute("href"))},e.prototype.ngOnDestroy=function(){this.dispose()},e.prototype.notifyClick=function(t){t.preventDefault(),t.stopPropagation(),this.pectinCommand.enabled.value?this.pectinCommand instanceof I.UnaryCommand?this.pectinCommand.withContext({event:t}).execute(this.commandParameter):this.pectinCommand.withContext({event:t}).execute():console.warn("disabled command clicked, ignoring.")},e}(I.GarbageCollector);X.decorators=[{type:n.Directive,args:[{selector:"[pectinCommand]"}]}],X.ctorParameters=function(){return[{type:n.ElementRef,decorators:[{type:n.Inject,args:[n.ElementRef]}]},{type:d.MatButton,decorators:[{type:n.Host},{type:n.Optional}]},{type:g.MatMenuItem,decorators:[{type:n.Host},{type:n.Optional}]}]},X.propDecorators={pectinCommand:[{type:n.Input}],commandParameter:[{type:n.Input}],notifyClick:[{type:n.HostListener,args:["click",["$event"]]}]};var Y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e.prototype.ngOnDestroy=function(){this.dispose()},e}(I.GarbageCollector);Y.decorators=[{type:n.Directive}];var J=function(t){function e(e,n,o,i){var r=t.call(this)||this;return r.focusTargetElement=e,r.ngZone=n,r.focusContext=i,r.document=o,(0,I.Dsl.disposeWith(r).when)(r.focusContext.focused).changes((function(t){t&&!r.alreadyHasFocus()&&r.tryAndFocus()}),{initialValue:"triggerChangeUnlessNil"}),r}return B(e,t),e.prototype.onFocusIn=function(){this.focusContext.notifyFocusIn()},e.prototype.onFocusOut=function(){this.focusContext.notifyFocusOut()},e.prototype.alreadyHasFocus=function(){return this.isElementFocused(this.focusTarget)},e.prototype.isElementFocused=function(t){return this.document.activeElement===t},e.prototype.tryAndFocus=function(t){var e=this;void 0===t&&(t=5),this.modelShouldStillHaveFocus()&&this.canFocus()&&(this.alreadyHasFocus()||this.focusTarget.focus(),this.alreadyHasFocus()||(I.Logger.get(this).log("focus failed, trying "+t+" more times"),t>0?requestAnimationFrame((function(){e.tryAndFocus(t-1)})):I.Logger.get(this).warn("Tried to focus but gave up as the component wasn't enabled or visible.")))},Object.defineProperty(e.prototype,"focusTarget",{get:function(){return this.focusTargetElement},enumerable:!1,configurable:!0}),e.prototype.modelShouldStillHaveFocus=function(){return this.focusContext.focused.value},e.prototype.canFocus=function(){var t=this.focusTarget.getBoundingClientRect();return t.height>=0&&t.height>=0&&!this.focusTarget.disabled},e}(I.GarbageCollector);J.ctorParameters=function(){return[{type:HTMLElement},{type:n.NgZone,decorators:[{type:n.Inject,args:[n.NgZone]}]},{type:void 0,decorators:[{type:n.Inject,args:[e.DOCUMENT]}]},{type:void 0}]};var Z=function(){function t(t,e){this.ngZone=t,this.document=e}return t.prototype.createBinding=function(t,e){return new J(t,this.ngZone,this.document,e)},t}();Z.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new Z(n.ɵɵinject(n.NgZone),n.ɵɵinject(e.DOCUMENT))},token:Z,providedIn:"root"}),Z.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],Z.ctorParameters=function(){return[{type:n.NgZone,decorators:[{type:n.Inject,args:[n.NgZone]}]},{type:void 0,decorators:[{type:n.Inject,args:[e.DOCUMENT]}]}]};var Q=function(t){function e(e,n){var o=t.call(this)||this;return o.el=e,o.focusBindingFactory=n,o}return B(e,t),e.prototype.onFocusIn=function(){this.hasBinding()&&this.pectinFocusBinding.notifyFocusIn()},e.prototype.onFocusOut=function(){this.hasBinding()&&this.pectinFocusBinding.notifyFocusOut()},e.prototype.ngOnInit=function(){},e.prototype.ngAfterViewInit=function(){this.hasBinding()?this.registerDisposable(this.focusBindingFactory.createBinding(this.focusTarget,this.pectinFocusBinding)):I.Logger.get(this).warn("pectinFocusBinding was nil")},e.prototype.hasBinding=function(){return!!this.pectinFocusBinding&&!!this.pectinFocusBinding},Object.defineProperty(e.prototype,"focusTarget",{get:function(){return this.focusBindingTarget||this.el.nativeElement},enumerable:!1,configurable:!0}),e}(Y);Q.decorators=[{type:n.Directive,args:[{selector:"[pectinFocusBinding]"}]}],Q.ctorParameters=function(){return[{type:n.ElementRef,decorators:[{type:n.Inject,args:[n.ElementRef]}]},{type:Z}]},Q.propDecorators={pectinFocusBinding:[{type:n.Input}],focusBindingTarget:[{type:n.Input}],onFocusIn:[{type:n.HostListener,args:["focusin"]}],onFocusOut:[{type:n.HostListener,args:["focusout"]}]};var tt=function(){};tt.decorators=[{type:n.NgModule,args:[{declarations:[X,Q],imports:[e.CommonModule,c.BrowserAnimationsModule,o.FormsModule,r.MatInputModule,i.MatFormFieldModule,a.MatSelectModule,s.MatTabsModule],exports:[X,Q]}]}];var et=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.ngOnInit=function(){},e}(Y);et.decorators=[{type:n.Component,args:[{selector:"aup-card-container",template:'<div class="card-container">\n <ng-content></ng-content>\n\n <div class="add-card-container" *ngIf="addCardCommand.enabled.value" [pectinCommand]="addCardCommand">\n <aup-command-face *ngIf="addCardFace" [faces]="[addCardFace]"></aup-command-face>\n <aup-icon *ngIf="!addCardFace" icon="mat:add"></aup-icon>\n </div>\n\n <div class="add-card-template" *ngIf="addCardTemplate">\n <ng-container [ngTemplateOutlet]="addCardTemplate"></ng-container>\n </div>\n\n</div>\n',styles:[":root{--aup-default-background:#fff;--aup-default-padding:var(--default-padding,18px)}.router-outlet-container>*{bottom:0;left:0;position:absolute;right:0;top:0}[no-tab-header]>mat-tab-header{display:none}[full-height-tabs] .mat-tab-body-wrapper,mat-tab-group.full-height-tabs .mat-tab-body-wrapper{flex:1}[full-height-tabs] .mat-tab-body-wrapper .mat-tab-body-content,[full-height-tabs] .mat-tab-body-wrapper mat-tab-body,mat-tab-group.full-height-tabs .mat-tab-body-wrapper .mat-tab-body-content,mat-tab-group.full-height-tabs .mat-tab-body-wrapper mat-tab-body{display:flex;flex-direction:column;justify-content:stretch}.dialog-interaction-context,.dialog-interaction-context mat-dialog-container{max-height:95vh!important;max-width:95vw!important}.dialog-interaction-context mat-dialog-container{padding:0}.activity-outlet-wrapper{align-items:stretch;display:flex;flex-direction:column}.aup-popup-interaction-panel{background:var(--aup-default-background,#fff);box-shadow:0 2px 1px -1px rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 1px 3px 0 rgba(0,0,0,.12);transition:box-shadow .28s cubic-bezier(.4,0,.2,1)}.aup-input-activity{padding:calc(var(--aup-default-padding)/2)}.aup-input-component{display:block}.aup-input-component input,.aup-input-component mat-form-field{width:100%}.aup-input-component input mat-hint.faux-error,.aup-input-component mat-form-field mat-hint.faux-error{color:#f44336}.aup-input-component.dense mat-form-field .mat-form-field-infix{border-top:none}.aup-input-component.dense mat-form-field .mat-form-field-flex{padding-top:0}.aup-input-component.dense mat-form-field .mat-form-field-wrapper{border-bottom:0;padding-bottom:0}.aup-input-component.dense mat-form-field .mat-form-field-underline{bottom:0}.aup-input-component.dense mat-form-field.mat-form-field-can-float.mat-form-field-should-float .mat-form-field-label-wrapper{display:none}.aup-input-component.dense mat-form-field.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(0)}aup-table-cell-renderer>.aup-input-component .mat-form-field-flex{padding-top:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-infix{width:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-label-wrapper{display:none}aup-table{--default-column-gap:var(--column-gap,24px);--resolved-row-hover-background-color:var(--row-hover-background-color,rgba(0,0,0,0.05))}aup-table .mat-table td.mat-cell:first-of-type,aup-table .mat-table td.mat-footer-cell:first-of-type,aup-table .mat-table th.mat-header-cell:first-of-type{padding-left:0}aup-table .mat-table tr.enable-hover:hover{background-color:var(--resolved-row-hover-background-color)}aup-table .mat-table td.enable-cursor{cursor:pointer}aup-table aup-table-cell-renderer,aup-table aup-table-header-cell-renderer{align-items:stretch;display:flex;flex-direction:column;height:100%;justify-content:center;min-height:47px}aup-table aup-table-cell-renderer.first-column,aup-table aup-table-cell-renderer:not(.first-column),aup-table aup-table-header-cell-renderer.first-column,aup-table aup-table-header-cell-renderer:not(.first-column){padding-left:var(--default-column-gap)}aup-table aup-table-cell-renderer.fillCell{justify-content:stretch;padding-left:0!important}aup-table aup-table-cell-renderer.padChild>:first-child{flex:1;padding-left:var(--default-column-gap)}:root{--aup-command-face-icon-gap:8px;--aup-fa-icon-width:18px;--aup-icon-width:24px}aup-icon{--fa-icon-offset:calc((var(--aup-icon-width) - var(--aup-fa-icon-width))/2);position:relative}aup-icon fa-icon .svg-inline--fa{height:var(--aup-fa-icon-width)!important;left:var(--fa-icon-offset);position:absolute;top:var(--fa-icon-offset);width:var(--aup-fa-icon-width)!important}.mat-menu-panel aup-icon .svg-inline--fa{opacity:.54}:host{--resolved-card-background:var(--card-background,#fcfcfb);--resolved-card-gap:var(--card-gap,16px);--resolved-card-height:var(--card-height,auto);--resolved-card-min-height:var(--card-min-height,auto);--resolved-card-width:var(--card-width,300px);background:var(--resolved-card-background);display:block;flex:1}.card-container{box-sizing:border-box;display:-ms-grid;display:grid;grid-gap:var(--resolved-card-gap);grid-template-columns:repeat(auto-fill,var(--resolved-card-width));grid-template-rows:repeat(auto-fit,minmax(var(--resolved-card-min-height),var(--resolved-card-height)));max-width:100%;min-height:calc(var(--resolved-card-height) + 2*var(--resolved-card-gap));min-width:calc(var(--resolved-card-width) + 2*var(--resolved-card-gap));padding:var(--resolved-card-gap);width:calc((var(--resolved-card-width) + var(--resolved-card-gap))*2 + var(--grid-gap))}.add-card-container{align-items:center;background-color:hsla(0,0%,100%,.8);border:2px dashed rgba(0,0,0,.1);border-radius:6px;box-sizing:border-box;color:rgba(0,0,0,.54);cursor:pointer;display:flex;flex-direction:column;font-weight:300;height:var(--resolved-card-height);justify-content:center;min-height:var(--resolved-card-min-height);transition:all .28s cubic-bezier(.4,0,.2,1);width:var(--resolved-card-width)}.add-card-container mat-icon{font-size:200%}.add-card-container:hover{background-color:#fff;border-color:transparent;color:rgba(0,0,0,.54);transition:box-shadow .28s cubic-bezier(.4,0,.2,1);transition:all .28s cubic-bezier(.4,0,.2,1)}.add-card-container:hover:hover{box-shadow:0 2px 4px -1px rgba(0,0,0,.2),0 4px 5px 0 rgba(0,0,0,.14),0 1px 10px 0 rgba(0,0,0,.12)}.add-card-template-container{align-items:stretch;display:flex;flex-direction:column;height:var(--resolved-card-height);justify-content:stretch;width:var(--resolved-card-width)}"]}]}],et.ctorParameters=function(){return[]},et.propDecorators={addCardCommand:[{type:n.Input}],addCardFace:[{type:n.Input}],addCardTemplate:[{type:n.ContentChild,args:["addCardTemplate"]}]},G([I.TrackExternal(),q("design:type",I.Command)],et.prototype,"addCardCommand",void 0),(t.TrackBy||(t.TrackBy={})).byIndex=function(t,e){return e},function(t){!function(t){t.START="start",t.END="end"}(t.Position||(t.Position={})),t.Style=x.Enum({FLAT:"flat",STROKED:"stroked",RAISED:"raised"}),t.getColorOf=function(t){return j.default.isFunction(null==t?void 0:t.color)?t.color():void 0},t.getStyleOf=function(t){return j.default.isFunction(null==t?void 0:t.style)?t.style():void 0},t.getIconOf=function(t){return j.default.isFunction(null==t?void 0:t.icon)?t.icon():void 0},t.getIconPositionOf=function(t){return j.default.isFunction(null==t?void 0:t.iconPosition)?t.iconPosition():void 0},t.getTooltipOf=function(t){return j.default.isFunction(null==t?void 0:t.tooltip)?t.tooltip():void 0},t.getTextOf=function(t){return j.default.isFunction(null==t?void 0:t.text)?t.text():void 0};var e=function(){function e(t){this.face=t}return Object.defineProperty(e.prototype,"text",{get:function(){return t.getTextOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"icon",{get:function(){return t.getIconOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconPosition",{get:function(){return t.getIconPositionOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tooltip",{get:function(){return t.getTooltipOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconPositionStart",{get:function(){return this.iconPosition===t.Position.START},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconPositionEnd",{get:function(){return this.iconPosition===t.Position.END},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"color",{get:function(){return t.getColorOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"style",{get:function(){return t.getStyleOf(this.face)},enumerable:!1,configurable:!0}),e}();G([w.Memoize(),q("design:type",Object),q("design:paramtypes",[])],e.prototype,"text",null),G([w.Memoize(),q("design:type",Object),q("design:paramtypes",[])],e.prototype,"icon",null),G([w.Memoize(),q("design:type",Object),q("design:paramtypes",[])],e.prototype,"iconPosition",null),G([w.Memoize(),q("design:type",Object),q("design:paramtypes",[])],e.prototype,"tooltip",null),G([w.Memoize(),q("design:type",Boolean),q("design:paramtypes",[])],e.prototype,"iconPositionStart",null),G([w.Memoize(),q("design:type",Boolean),q("design:paramtypes",[])],e.prototype,"iconPositionEnd",null),G([w.Memoize(),q("design:type",String),q("design:paramtypes",[])],e.prototype,"color",null),G([w.Memoize(),q("design:type",String),q("design:paramtypes",[])],e.prototype,"style",null),t.Adapter=e}(t.CommandFace||(t.CommandFace={})),t.ViewData=function(){},function(e){var n=function(e){function n(t){var n=e.call(this)||this;return n.faces=t,I.assert.notNil(t),n}return B(n,e),Object.defineProperty(n.prototype,"activeFaceAdapter",{get:function(){return new t.CommandFace.Adapter(this.faces.length>0?this.faces[0]:void 0)},enumerable:!1,configurable:!0}),n}(e);G([w.Memoize(),q("design:type",t.CommandFace.Adapter),q("design:paramtypes",[])],n.prototype,"activeFaceAdapter",null),e.FaceData=n;var o=function(t){function n(e,n,o,i){var r=t.call(this,e)||this;return r.xPosition=n,r.yPosition=o,r.children=i,r}return B(n,t),Object.defineProperty(n.prototype,"hasMixedIcons",{get:function(){var t=this.children.filter((function(t){return e.hasFace(t)})),n=t.filter((function(t){return!!t.activeFaceAdapter.icon})).length;return n>0&&t.length!==n},enumerable:!1,configurable:!0}),n}(n);G([w.Memoize(),q("design:type",Boolean),q("design:paramtypes",[])],o.prototype,"hasMixedIcons",null),e.GroupData=o;var i=function(t){function e(e,n){var o=t.call(this,n)||this;return o.command=e,o}return B(e,t),e}(n);e.CommandData=i;var r=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e}(e);e.SeparatorData=r;var a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e}(e);function s(t,e){return e instanceof t?e:I.lang.illegalState("expected instance of "+t.name+", got "+e.constructor.name)}e.FlexData=a,e.as=s,e.getCommand=function(t){return s(i,t).command},e.getTooltip=function(t){return s(n,t).activeFaceAdapter.tooltip},e.getStyle=function(t){return s(n,t).activeFaceAdapter.style},e.getColor=function(t){return s(n,t).activeFaceAdapter.color},e.hasText=function(t){return!!s(n,t).activeFaceAdapter.text},e.getFaces=function(t){return s(n,t).faces},e.asGroup=function(t){return s(o,t)},e.hasMixedIcons=function(t){return s(o,t).hasMixedIcons},e.isGroup=function(t){return t instanceof o},e.hasFace=function(t){return t instanceof n},e.isCommand=function(t){return t instanceof i},e.isSeparator=function(t){return t instanceof r},e.isFlex=function(t){return t instanceof a}}(t.ViewData||(t.ViewData={}));var nt=function(e){function o(o){var i=e.call(this)||this;i.parent=o,i.groupViewDataModel=new I.MutableValueModel,i.commandFired=new n.EventEmitter,i.ViewData=t.ViewData,i.TrackBy=t.TrackBy;var r=I.Dsl.disposeWith(i),a=r.chain;r.valueOf,r.before,r.when,r.after,r.observe,r.switchOn;return i.children=a(i.groupViewDataModel).pluckList("children"),i.hasMixedIcons=a(i.groupViewDataModel).pluck("hasMixedIcons"),i}return B(o,e),o.prototype.getCommand=function(e){var n=this,o=t.ViewData.getCommand(e);return(0,I.Dsl.disposeWith(this).when)(o.busy).becomesFalsey((function(){return n.commandFired.emit()})),o},o}(Y);nt.decorators=[{type:n.Component,args:[{selector:"aup-command-group-menu",template:'<mat-menu #menu [xPosition]="groupViewData.xPosition" [yPosition]="groupViewData.yPosition">\n <ng-container *ngFor="let data of children.value; trackBy: TrackBy.byIndex" >\n <button *ngIf="ViewData.isCommand(data)"\n [pectinCommand]="getCommand(data)"\n [matTooltip]="ViewData.getTooltip(data)"\n mat-menu-item>\n <aup-command-face [faces]="ViewData.getFaces(data)"\n [includeMissingIconInLayout]="hasMixedIcons.value"></aup-command-face>\n </button>\n\n <ng-container *ngIf="ViewData.isGroup(data)">\n <button mat-menu-item\n #trigger="matMenuTrigger"\n [matMenuTriggerFor]="innerPanel.menuComponent"\n >\n <aup-command-face [faces]="ViewData.getFaces(data)"\n [includeMissingIconInLayout]="hasMixedIcons.value"></aup-command-face>\n </button>\n <aup-command-group-menu #innerPanel\n [groupViewData]="ViewData.asGroup(data)"\n (commandFired)="trigger.closeMenu()"></aup-command-group-menu>\n </ng-container>\n\n <mat-divider *ngIf="ViewData.isSeparator(data)"></mat-divider>\n\n </ng-container>\n</mat-menu>\n'}]}],nt.ctorParameters=function(){return[{type:nt,decorators:[{type:n.Optional},{type:n.SkipSelf}]}]},nt.propDecorators={menuComponent:[{type:n.ViewChild,args:["menu",{static:!0}]}],groupViewData:[{type:n.Input}],commandFired:[{type:n.Output}],triggers:[{type:n.ViewChildren,args:[g.MatMenuTrigger]}]},G([I.StoreInValueModel("groupViewDataModel"),q("design:type",t.ViewData.GroupData)],nt.prototype,"groupViewData",void 0);var ot,it,rt=function(e){function n(){var n=e.call(this)||this;n.renderRootNode=!0,n.ViewData=t.ViewData,n.TrackBy=t.TrackBy;var o=I.Dsl.disposeWith(n),i=o.chain;o.valueOf,o.before,o.when,o.after,o.observe,o.switchOn;return n.childViewDataModels=i(n.groupViewDataModel).pluckList("children"),n}return B(n,e),n}(Y);rt.decorators=[{type:n.Component,args:[{selector:"aup-command-group-renderer",template:'<ng-template #groupTemplate let-group>\n\n <ng-container *ngIf="ViewData.hasText(group)" [ngSwitch]="ViewData.getStyle(group)">\n <ng-container *ngSwitchCase="\'stroked\'">\n <button #trigger="matMenuTrigger"\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="ViewData.getTooltip(group)"\n [color]="ViewData.getColor(group)"\n mat-stroked-button>\n <aup-command-face [faces]="ViewData.getFaces(group)"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]="group" (commandFired)="trigger.closeMenu()"></aup-command-group-menu>\n </ng-container>\n\n <ng-container *ngSwitchCase="\'raised\'">\n <button #trigger="matMenuTrigger"\n [matMenuTriggerFor]="subMenu.menuComponent"\n\n [matTooltip]="ViewData.getTooltip(group)"\n [color]="ViewData.getColor(group)"\n mat-raised-button>\n <aup-command-face [faces]="ViewData.getFaces(group)"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]="group" (commandFired)="trigger.closeMenu()"></aup-command-group-menu>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button #trigger="matMenuTrigger"\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="ViewData.getTooltip(group)"\n [color]="ViewData.getColor(group)"\n mat-button>\n <aup-command-face [faces]="ViewData.getFaces(group)"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]="group" (commandFired)="trigger.closeMenu()"></aup-command-group-menu>\n </ng-container>\n\n </ng-container>\n\n <ng-container *ngIf="!ViewData.hasText(group)">\n <button #trigger="matMenuTrigger"\n mat-icon-button\n [matMenuTriggerFor]="subMenu.menuComponent"\n\n [matTooltip]="ViewData.getTooltip(group)"\n [color]="ViewData.getColor(group)"\n >\n <aup-command-face [faces]="ViewData.getFaces(group)"></aup-command-face>\n </button>\n <aup-command-group-menu #subMenu [groupViewData]="group" (commandFired)="trigger.closeMenu()"></aup-command-group-menu>\n </ng-container>\n\n</ng-template>\n\n\n<ng-template #commandTemplate let-data>\n\n <ng-container *ngIf="ViewData.hasText(data)" [ngSwitch]="ViewData.getStyle(data)">\n <button *ngSwitchCase="\'raised\'"\n [pectinCommand]="ViewData.getCommand(data)"\n [matTooltip]="ViewData.getTooltip(data)"\n [color]="ViewData.getColor(data)"\n mat-raised-button>\n <aup-command-face [faces]="ViewData.getFaces(data)"></aup-command-face>\n </button>\n <button *ngSwitchCase="\'stroked\'"\n [pectinCommand]="ViewData.getCommand(data)"\n [matTooltip]="ViewData.getTooltip(data)"\n [color]="ViewData.getColor(data)"\n mat-stroked-button>\n <aup-command-face [faces]="ViewData.getFaces(data)"></aup-command-face>\n </button>\n <button *ngSwitchDefault\n [pectinCommand]="ViewData.getCommand(data)"\n [matTooltip]="ViewData.getTooltip(data)"\n [color]="ViewData.getColor(data)"\n mat-button>\n <aup-command-face [faces]="ViewData.getFaces(data)"></aup-command-face>\n </button>\n </ng-container>\n\n <button *ngIf="!ViewData.hasText(data)"\n [pectinCommand]="ViewData.getCommand(data)"\n [matTooltip]="ViewData.getTooltip(data)"\n [color]="ViewData.getColor(data)"\n mat-icon-button>\n <aup-command-face [faces]="ViewData.getFaces(data)"></aup-command-face>\n </button>\n\n</ng-template>\n\n\n<ng-template *ngIf="renderRootNode"\n [ngTemplateOutlet]="groupTemplate"\n [ngTemplateOutletContext]="{ $implicit: groupViewDataModel.value }">\n</ng-template>\n\n<ng-container *ngIf="!renderRootNode">\n <ng-container *ngFor="let data of this.childViewDataModels.value; trackBy: TrackBy.byIndex">\n <ng-template *ngIf="ViewData.isGroup(data)"\n [ngTemplateOutlet]="groupTemplate"\n [ngTemplateOutletContext]="{ $implicit: data }">\n </ng-template>\n <ng-template *ngIf="ViewData.isCommand(data)"\n [ngTemplateOutlet]="commandTemplate"\n [ngTemplateOutletContext]="{ $implicit: data }">\n </ng-template>\n\n <mat-divider *ngIf="ViewData.isSeparator(data)" [vertical]="true"></mat-divider>\n </ng-container>\n\n</ng-container>\n',styles:[":host{align-items:center;display:inline-flex;flex-direction:row}:host:not(.render-root) mat-divider{-ms-grid-row-align:stretch;align-self:stretch;margin:4px 0}:host:not(.render-root)>*+*{margin-left:8px}:host span.flex{flex:1}"]}]}],rt.ctorParameters=function(){return[]},rt.propDecorators={groupViewDataModel:[{type:n.Input}],groupViewData:[{type:n.Input}],renderRootNode:[{type:n.Input},{type:n.HostBinding,args:["class.render-root"]}]},G([I.TrackExternal(),q("design:type",I.ValueModel)],rt.prototype,"groupViewDataModel",void 0),G([I.StoreInValueModel("groupViewDataModel"),q("design:type",t.ViewData.GroupData)],rt.prototype,"groupViewData",void 0),t.Registration=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e}(I.GarbageCollector),function(e){var n=function(t){function e(e){var n=t.call(this)||this;return n.faceListModel=e,n}return B(e,t),e}(e);e.FaceRegistration=n;var o=function(e){function n(t,n){var o=e.call(this,n)||this;return o.command=t,o}return B(n,e),n.prototype.toTemplate=function(){return new t.ViewData.CommandData(this.command,this.faceListModel.value)},n}(n);e.CommandRegistration=o;var i=function(e){function n(t,n){var o=e.call(this,t)||this;return o.group=n,o}return B(n,e),n.prototype.toTemplate=function(){return new t.ViewData.GroupData(this.faceListModel.value,this.group.xPosition,this.group.yPosition,this.group.registrations.value.map((function(t){return t.toTemplate()})))},n}(n);e.GroupRegistration=i;var r=function(e){function n(){var n=e.apply(this,$(arguments))||this;return n.template=new t.ViewData.SeparatorData,n}return B(n,e),n.prototype.toTemplate=function(){return this.template},n}(e);e.SeparatorRegistration=r;var a=function(e){function n(){var n=e.apply(this,$(arguments))||this;return n.template=new t.ViewData.FlexData,n}return B(n,e),n.prototype.toTemplate=function(){return this.template},n}(e);e.FlexRegistration=a,e.hasFace=function(t){return t instanceof o||t instanceof i}}(t.Registration||(t.Registration={})),t.CommandGroup=function(e){function n(t){var n=e.call(this)||this;n.parent=t,n._rootTemplate=new I.MutableValueModel,n._registrations=new I.MutableListModel;var o=I.Dsl.disposeWith(n),i=o.chain;o.valueOf,o.before,o.when,o.after,o.observe,o.switchOn;return n.childTemplates=i(n._rootTemplate).pluckList("children"),n.initialised=i(n._rootTemplate).isNotNil(),n}return B(n,e),n.prototype.initialise=function(){this.rebuildTemplates()},Object.defineProperty(n.prototype,"rootTemplate",{get:function(){return this._rootTemplate.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"registrations",{get:function(){return this._registrations.readonly},enumerable:!1,configurable:!0}),n.prototype.notifyChanged=function(){this.parent?this.parent.notifyChanged():this.rebuildTemplates()},n.prototype.notifyChildFaceChanged=function(t,e){this.notifyChanged()},n.prototype.rebuildTemplates=function(){this._rootTemplate.value=new t.ViewData.GroupData(this.faceListModel.value,this.xPosition,this.yPosition,this.registrations.value.map((function(t){return t.toTemplate()})))},Object.defineProperty(n.prototype,"depth",{get:function(){return this.isRoot()?0:this.parent.depth+1},enumerable:!1,configurable:!0}),n.prototype.isRoot=function(){return!1},n.prototype.registerCommand=function(e,n){return this.register(new t.Registration.CommandRegistration(e,n))},n.prototype.registerGroup=function(e,n){return this.register(new t.Registration.GroupRegistration(n,e))},n.prototype.registerFlex=function(e){return this.register(new t.Registration.FlexRegistration)},n.prototype.registerSeparator=function(e){return this.register(new t.Registration.SeparatorRegistration)},n.prototype.register=function(e){var n=this;(this._registrations.push(e),e instanceof t.Registration.FaceRegistration)&&(0,I.Dsl.disposeWith(e).when)(e.faceListModel).changes((function(t,e){n.notifyChildFaceChanged(t,e)}),{asLongAs:this.initialised});return e.onDispose((function(){return n._registrations.remove(e)})),e},n}(I.GarbageCollector),ot=t.CommandGroup||(t.CommandGroup={}),it=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.isRoot=function(){return!0},e}(ot),G([I.TrackExternal(),q("design:type",I.ListModel)],it.prototype,"faceListModel",void 0),G([I.TrackExternal({defaultValue:"after"}),q("design:type",I.ValueModel)],it.prototype,"xPositionModel",void 0),G([I.StoreInValueModel("xPositionModel"),q("design:type",String)],it.prototype,"xPosition",void 0),G([I.TrackExternal({defaultValue:"below"}),q("design:type",I.ValueModel)],it.prototype,"yPositionModel",void 0),G([I.StoreInValueModel("yPositionModel"),q("design:type",String)],it.prototype,"yPosition",void 0),ot.Root=it,ot.factory=function(){return new it};var at=function(t){function e(e){var n=t.call(this,e)||this;n.parent=e,n.xPosition="after",n.yPosition="below";var o=I.Dsl.disposeWith(n),i=o.chain;o.valueOf,o.before,o.when,o.after,o.observe,o.switchOn;return n.faceListModel=i(n.faceModel).mapToList((function(t){return[t]})),n.parent.registerGroup(n,n.faceListModel),n}return B(e,t),e}(t.CommandGroup);at.decorators=[{type:n.Component,args:[{selector:"aup-command-group",template:"",providers:[{provide:t.CommandGroup,useExisting:at}]}]}],at.ctorParameters=function(){return[{type:t.CommandGroup,decorators:[{type:n.SkipSelf}]}]},at.propDecorators={faceModel:[{type:n.Input}],face:[{type:n.Input}],xPosition:[{type:n.Input}],yPosition:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.ValueModel)],at.prototype,"faceModel",void 0),G([I.StoreInValueModel("faceModel"),q("design:type",Object)],at.prototype,"face",void 0);var st=function(e){function n(){var n=e.call(this)||this;n.facesModel=new I.MutableListModel,n.ignoreIcon=!1,n.ignoreText=!1,n.includeMissingIconInLayout=!1;var o=I.Dsl.disposeWith(n),i=o.chain;o.valueOf,o.before,o.when,o.after,o.observe,o.switchOn;n.faceAdapters=i(n.facesModel).map((function(e){return new t.CommandFace.Adapter(e)}));var r=n.faceAdapters.first();return n.activeIcon=r.pluck("icon"),n.activeColor=r.pluck("color"),n}return B(n,e),Object.defineProperty(n.prototype,"requiresMissingIconInLayout",{get:function(){return this.includeMissingIconInLayout&&!this.activeIcon.value},enumerable:!1,configurable:!0}),n.prototype.ngOnInit=function(){},n.prototype.shouldIncludeIcon=function(t){return!this.ignoreIcon&&t.icon||this.includeMissingIconInLayout},n.prototype.hasIconStart=function(e){return this.shouldIncludeIcon(e)&&(!e.iconPosition||e.iconPosition===t.CommandFace.Position.START)},n.prototype.hasIconEnd=function(e){return this.shouldIncludeIcon(e)&&e.iconPosition===t.CommandFace.Position.END},Object.defineProperty(n.prototype,"color",{get:function(){return this.activeColor.value},enumerable:!1,configurable:!0}),n}(Y);st.decorators=[{type:n.Component,args:[{selector:"aup-command-face",template:'<div class="face-container" *ngFor="let face of faceAdapters.value">\n <aup-icon *ngIf="hasIconStart(face)" [icon]="face.icon"></aup-icon>\n <span *ngIf="face.text">{{face.text}}</span>\n <aup-icon *ngIf="hasIconEnd(face)" [icon]="face.icon"></aup-icon>\n</div>\n',encapsulation:n.ViewEncapsulation.None,styles:["aup-command-face{--icon-gap:var(--aup-command-face-icon-gap);display:-ms-inline-grid;display:inline-grid}aup-command-face>.face-container{-ms-grid-column:1;-ms-grid-row:1;align-items:center;display:inline-flex;flex-direction:row;grid-column:1;grid-row:1}aup-command-face>.face-container:not(:first-child){visibility:hidden}aup-command-face>.face-container *+*{margin-left:var(--icon-gap)}aup-command-face.hide-icon aup-icon{visibility:hidden}aup-command-face.centered{justify-items:center}"]}]}],st.ctorParameters=function(){return[]},st.propDecorators={_rawFaces:[{type:n.Input,args:["faces"]}],ignoreIcon:[{type:n.Input}],ignoreText:[{type:n.Input}],includeMissingIconInLayout:[{type:n.Input}],requiresMissingIconInLayout:[{type:n.HostBinding,args:["class.hide-icon"]}],color:[{type:n.HostBinding,args:["attr.color"]}]},G([I.StoreInListModel("facesModel"),q("design:type",Array)],st.prototype,"_rawFaces",void 0);var ct=function(e){function n(n){var o=e.call(this)||this;o.parent=n,o.CommandFace=t.CommandFace;var i=I.Dsl.disposeWith(o),r=i.chain;i.switchOn;return o.faces=r(o.command.busy).mapToList((function(t){return t?[o.busyFaceModel.value,o.faceModel.value]:[o.faceModel.value,o.busyFaceModel.value]}),{allowNil:!0,dependsOn:[o.faceModel,o.busyFaceModel]}).rejectNil(),o.activeFace=o.faces.first(),o.buttonStyle=r(o.activeFace).map((function(e){return t.CommandFace.getStyleOf(e)})),o.colorModel=r(o.activeFace).map((function(e){return t.CommandFace.getColorOf(e)})),n&&o.registerDisposable(o.parent.registerCommand(o.command,o.faces)),o}return B(n,e),n.prototype.isActive=function(t){return this.activeFace.query().equals(t)},n.prototype.ngOnInit=function(){},n}(Y);ct.decorators=[{type:n.Component,args:[{selector:"aup-command",template:'<ng-container *ngIf="!parent">\n <ng-container [ngSwitch]="buttonStyle.value">\n <ng-container *ngSwitchCase="CommandFace.Style.STROKED">\n <button mat-stroked-button [pectinCommand]="command" [color]="colorModel.value" [class.busy]="command.busy.value">\n <aup-command-face class="centered" [faces]="faces.value"></aup-command-face>\n </button>\n </ng-container>\n <ng-container *ngSwitchCase="CommandFace.Style.RAISED">\n <button mat-raised-button [pectinCommand]="command" [color]="colorModel.value" [class.busy]="command.busy.value">\n <aup-command-face class="centered" [faces]="faces.value"></aup-command-face>\n </button>\n </ng-container>\n <ng-container *ngSwitchDefault>\n <button mat-button [pectinCommand]="command" [color]="colorModel.value" [class.busy]="command.busy.value">\n <aup-command-face class="centered" [faces]="faces.value"></aup-command-face>\n </button>\n </ng-container>\n </ng-container>\n</ng-container>\n',styles:[":host{display:inline-flex;flex-direction:row;justify-content:stretch}button{flex:1}"]}]}],ct.ctorParameters=function(){return[{type:t.CommandGroup,decorators:[{type:n.Optional}]}]},ct.propDecorators={command:[{type:n.Input}],faceModel:[{type:n.Input}],face:[{type:n.Input}],busyFaceModel:[{type:n.Input}],busyFace:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.Command)],ct.prototype,"command",void 0),G([I.TrackExternal(),q("design:type",I.ValueModel)],ct.prototype,"faceModel",void 0),G([I.StoreInValueModel("faceModel"),q("design:type",Object)],ct.prototype,"face",void 0),G([I.TrackExternal(),q("design:type",I.ValueModel)],ct.prototype,"busyFaceModel",void 0),G([I.StoreInValueModel("busyFaceModel"),q("design:type",Object)],ct.prototype,"busyFace",void 0);var lt=function(t){function e(e){var n=t.call(this)||this;return n.parent=e,e&&e.registerFlex(n),n}return B(e,t),e.prototype.ngOnInit=function(){},e}(Y);lt.decorators=[{type:n.Component,args:[{selector:"aup-flex",template:""}]}],lt.ctorParameters=function(){return[{type:t.CommandGroup}]};var ut=t.CommandGroup.factory,pt=function(t){function e(e){var n=t.call(this)||this;n.group=e,n.tooltipModel=new I.MutableValueModel;var o=I.Dsl.disposeWith(n),i=o.chain;o.valueOf,o.before,o.when,o.after,o.observe,o.switchOn;return e.xPosition="before",e.faceListModel=i(n.tooltipModel).mapToList((function(t){return[{icon:function(){return"mat:more_vert"},tooltip:function(){return t}}]}),{allowNil:!0}),n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.ngAfterContentInit=function(){this.group.initialise()},e}(Y);pt.decorators=[{type:n.Component,args:[{selector:"aup-more-menu",template:'<aup-command-group-renderer [renderRootNode]="true" [groupViewDataModel]="group.rootTemplate"></aup-command-group-renderer>',providers:[{provide:t.CommandGroup,useFactory:ut}]}]}],pt.ctorParameters=function(){return[{type:t.CommandGroup}]},pt.propDecorators={tooltip:[{type:n.Input}]},G([I.StoreInValueModel("tooltipModel"),q("design:type",String)],pt.prototype,"tooltip",void 0);var dt=t.CommandGroup.factory,ft=function(t){function e(e){var n=t.call(this)||this;n.group=e;var o=I.Dsl.disposeWith(n),i=o.chain;o.valueOf,o.before,o.when,o.after,o.observe,o.switchOn;return e.faceListModel=i(n.faceModel).mapToList((function(t){return[t]})),n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.ngAfterContentInit=function(){this.group.initialise()},e.prototype.ngAfterViewInit=function(){},e}(Y);ft.decorators=[{type:n.Component,args:[{selector:"aup-popup-menu",template:'<aup-command-group-renderer [renderRootNode]="true" [groupViewDataModel]="group.rootTemplate"></aup-command-group-renderer>',providers:[{provide:t.CommandGroup,useFactory:dt}]}]}],ft.ctorParameters=function(){return[{type:t.CommandGroup}]},ft.propDecorators={faceModel:[{type:n.Input}],face:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.ValueModel)],ft.prototype,"faceModel",void 0),G([I.StoreInValueModel("faceModel"),q("design:type",Object)],ft.prototype,"face",void 0);var mt=function(t){function e(e){var n=t.call(this)||this;return n.parent=e,e&&e.registerSeparator(n),n}return B(e,t),e.prototype.isVertical=function(){return null==this?void 0:this.parent.isRoot()},e.prototype.ngOnInit=function(){},e}(Y);mt.decorators=[{type:n.Component,args:[{selector:"aup-separator",template:'\n <mat-divider [vertical]="isVertical()"></mat-divider>'}]}],mt.ctorParameters=function(){return[{type:t.CommandGroup,decorators:[{type:n.Optional}]}]};var ht=t.CommandGroup.factory,gt=function(t){function e(e){var n=t.call(this)||this;return n.group=e,n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.ngAfterContentInit=function(){this.group.initialise()},e.prototype.ngAfterViewInit=function(){},e}(Y);gt.decorators=[{type:n.Component,args:[{selector:"aup-tool-bar",template:'<aup-command-group-renderer [renderRootNode]="false" [groupViewDataModel]="group.rootTemplate"></aup-command-group-renderer>',providers:[{provide:t.CommandGroup,useFactory:ht}],styles:[":host{align-items:center;display:inline-flex;flex-direction:row}:host mat-divider{-ms-grid-row-align:stretch;align-self:stretch;margin:4px 0}:host span.flex{flex:1}:host>*+*{margin-left:8px}"]}]}],gt.ctorParameters=function(){return[{type:t.CommandGroup}]};var yt=function(t){function e(e){var n=t.call(this)||this;return n.focusManager=e,n.restoreFocusCommand=I.Command.create((function(){n.restoreFocus()})),n.tabIndex=-1,n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.restoreFocus=function(){this.focusManager.restoreFocus()},e}(Y);yt.decorators=[{type:n.Component,args:[{selector:"aup-focus-container",template:"<ng-content></ng-content>\n",providers:[{provide:I.FocusManager}],styles:[":host{display:block}"]}]}],yt.ctorParameters=function(){return[{type:I.FocusManager,decorators:[{type:n.Self}]}]},yt.propDecorators={tabIndex:[{type:n.HostBinding,args:["attr.tabindex"]}]};var vt=function(t){function e(e,n,o){var i=t.call(this)||this;i.el=e,i.focusManager=n;var r=I.Dsl.disposeWith(i);r.chain,r.valueOf,r.before,r.when,r.after,r.observe,r.switchOn;return i.focusManager&&(i._focusContext=i.focusManager.registerFocusable(i),i.registerDisposable(i._focusContext),i.registerDisposable(o.createBinding(e.nativeElement,i.focusContext))),i}return B(e,t),Object.defineProperty(e.prototype,"focusable",{get:function(){return this.focusContext?0:void 0},enumerable:!1,configurable:!0}),e.prototype.onFocus=function(){var t;null===(t=this.focusContext)||void 0===t||t.notifyFocusIn()},e.prototype.onBlur=function(){var t;null===(t=this.focusContext)||void 0===t||t.notifyFocusOut()},Object.defineProperty(e.prototype,"focusContext",{get:function(){return this._focusContext},enumerable:!1,configurable:!0}),e}(Y);vt.decorators=[{type:n.Component,args:[{template:""}]}],vt.ctorParameters=function(){return[{type:n.ElementRef},{type:I.FocusManager},{type:Z}]},vt.propDecorators={focusable:[{type:n.HostBinding,args:["attr.tabindex"]}],onFocus:[{type:n.HostListener,args:["focus"]}],onBlur:[{type:n.HostListener,args:["blur"]}]};var bt=function(t){function e(){var e=t.call(this)||this;e.onValueEditedListeners=new I.EventListenerList,e.dense=!1,e.focus=new n.EventEmitter,e.blur=new n.EventEmitter,e.enterKey=new n.EventEmitter,e.escapeKey=new n.EventEmitter,e.baseClassName="aup-input-component";var o=e;return e.errorStateMatcher={isErrorState:function(t,e){return o.hasErrors()}},e}return B(e,t),e.prototype.notifyClick=function(){this.safelyInvoke(this.clickCommand)},e.prototype.notifyFocusIn=function(){this.safelyInvoke(this.focusCommand),this.focus.emit()},e.prototype.notifyFocusOut=function(){this.safelyInvoke(this.blurCommand),this.blur.emit()},e.prototype.notifyEnterKey=function(){this.safelyInvoke(this.enterCommand),this.enterKey.emit()},e.prototype.notifyEscapeKey=function(){this.safelyInvoke(this.escapeCommand),this.escapeKey.emit()},e.prototype.safelyInvoke=function(t){t&&t.enabled.value&&t.execute()},e.prototype.ngOnInit=function(){},e.prototype.isEnabled=function(){return this.enabled.value},Object.defineProperty(e.prototype,"enabled",{get:function(){return this.formValueModel.enabled},enumerable:!1,configurable:!0}),e.prototype.hasErrors=function(){return!this.errorList.query().isEmpty()},Object.defineProperty(e.prototype,"errorList",{get:function(){return this.formValueModel.errorList},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstError",{get:function(){return this.hasErrors()?this.errorList.value[0]:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"focusContext",{get:function(){return this.formValueModel.focusContext},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"floatLabel",{get:function(){return this.dense?"never":this.userFloatLabel},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showHint",{get:function(){return!this.dense&&!!this.hint},enumerable:!1,configurable:!0}),e.prototype.onValueEdited=function(t){return this.onValueEditedListeners.add(t)},e}(Y);bt.decorators=[{type:n.Component,args:[{template:""}]}],bt.ctorParameters=function(){return[]},bt.propDecorators={label:[{type:n.Input}],userFloatLabel:[{type:n.Input,args:["floatLabel"]}],hint:[{type:n.Input}],placeholder:[{type:n.Input}],dense:[{type:n.HostBinding,args:["class.dense"]},{type:n.Input}],focusCommand:[{type:n.Input,args:["command.focus"]}],blurCommand:[{type:n.Input,args:["command.blur"]}],enterCommand:[{type:n.Input,args:["command.enter"]}],escapeCommand:[{type:n.Input,args:["command.escape"]}],clickCommand:[{type:n.Input,args:["command.click"]}],focus:[{type:n.Output}],blur:[{type:n.Output}],enterKey:[{type:n.Output}],escapeKey:[{type:n.Output}],baseClassName:[{type:n.HostBinding,args:["class"]}],notifyClick:[{type:n.HostListener,args:["click"]}],notifyFocusIn:[{type:n.HostListener,args:["focusin"]}],notifyFocusOut:[{type:n.HostListener,args:["focusout"]}]};var Ct=function(t){function e(){var e=t.call(this)||this;e.formValueModel=e.registerDisposable(new I.Form.DelegatingListModel),e.componentListModel=new I.MutableListModel,e.setValueIsInProgress=new I.Guard,e.valueChange=new n.EventEmitter;var o=I.Dsl.disposeWith(e),i=o.when,r=o.valueOf,a=o.chain,s=new I.Binding.Identity(e.formValueModel,e.componentListModel).writeRight(),c=r.any(e.setValueIsInProgress,a(s.direction).equals(I.Binding.Direction.RIGHT)).areTruthy();return i(e.componentListModel).changes((function(t,n){e.valueChange.emit(t),e.onValueEditedListeners.fire((function(e){return e(t,n)}))}),{initialValue:"ignore",unless:c}),I.DebugContext.tag(e.formValueModel,e.constructor.name+".formValueModel"),e}return B(e,t),Object.defineProperty(e.prototype,"value",{set:function(t){var e=this;this.setValueIsInProgress.whileTrue((function(){e.listHolder?e.listHolder.value=t:(e.listHolder=new I.MutableListModel(t),e.listModel=e.listHolder)}))},enumerable:!1,configurable:!0}),e}(bt);Ct.decorators=[{type:n.Component,args:[{template:""}]}],Ct.ctorParameters=function(){return[]},Ct.propDecorators={listModel:[{type:n.Input}],value:[{type:n.Input}],valueChange:[{type:n.Output}]},G([I.TrackExternal({delegateTo:"formValueModel"}),q("design:type",Object)],Ct.prototype,"listModel",void 0);var It=function(t){function e(){var e=t.call(this)||this;e.formValueModel=e.registerDisposable(new I.Form.DelegatingValueModel),e.setValueInProgress=new I.Guard,e.componentValueModel=new I.MutableValueModel,e.valueChange=new n.EventEmitter;var o=I.Dsl.disposeWith(e),i=o.when,r=o.chain,a=o.valueOf,s=new I.Binding.Identity(e.formValueModel,e.componentValueModel).writeRight(),c=a.any(e.setValueInProgress,r(s.direction).equals(I.Binding.Direction.RIGHT)).areTruthy();return i(e.componentValueModel).changes((function(t,n){e.valueChange.emit(t),e.onValueEditedListeners.fire((function(e){return e(t,n)}))}),{initialValue:"ignore",unless:c}),I.DebugContext.tag(e.formValueModel,e.constructor.name+".formValueModel"),e}return B(e,t),Object.defineProperty(e.prototype,"value",{set:function(t){var e=this;this.setValueInProgress.whileTrue((function(){e.plainValueHolder?e.plainValueHolder.value=t:(e.plainValueHolder=new I.MutableValueModel(t),e.valueModel=e.plainValueHolder)}))},enumerable:!1,configurable:!0}),e}(bt);It.decorators=[{type:n.Component,args:[{template:""}]}],It.ctorParameters=function(){return[]},It.propDecorators={valueModel:[{type:n.Input}],value:[{type:n.Input}],valueChange:[{type:n.Output}]},G([I.TrackExternal({delegateTo:"formValueModel"}),q("design:type",Object)],It.prototype,"valueModel",void 0);var wt=function(t){function e(){var e=t.call(this)||this;e.filterValue=new I.MutableValueModel,e.optionLabelFormat=function(t){return t&&e.optionLabel?t[e.optionLabel]:t};var n=I.Dsl.disposeWith(e),o=n.chain,i=(n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn,o(e.filterValue).map((function(t){return j.default.isString(t)?t.toLowerCase():""})));return e.filteredOptions=o(e.optionsModel).select((function(t){return j.default.isEmpty(e.filterValue.value)||e.optionLabelFormat(t).toString().toLowerCase().includes(i.value)}),{dependsOn:i}),e}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.formatOption=function(t){return this.optionLabelFormat(t)},e.prototype.updateFilter=function(t){this.filterValue.value=t},e.prototype.onSelect=function(t){this.valueModel.value=t.option.value},e}(It);wt.decorators=[{type:n.Component,args:[{selector:"aup-autocomplete-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input type="string"\n matInput\n [matAutocomplete]="autocomplete"\n placeholder="{{placeholder}}"\n [ngModel]="componentValueModel.value"\n (ngModelChange)="updateFilter($event)"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-autocomplete #autocomplete [displayWith]="optionLabelFormat" [autoActiveFirstOption]="true" (optionSelected)="onSelect($event)">\n <mat-option *ngFor="let option of filteredOptions.value; let i = index"\n [value]="option"\n >{{formatOption(option)}}</mat-option>\n <mat-option *ngIf="allowNil">{{placeholder}}</mat-option>\n </mat-autocomplete>\n\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[":host{display:inline-block}mat-form-field{width:100%}"]}]}],wt.ctorParameters=function(){return[]},wt.propDecorators={optionsModel:[{type:n.Input}],options:[{type:n.Input}],optionLabel:[{type:n.Input}],allowNil:[{type:n.Input}],nilOptionTemplateRef:[{type:n.ContentChild,args:["nilOptionTemplate"]}],optionLabelFormat:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.ListModel)],wt.prototype,"optionsModel",void 0),G([I.StoreInListModel("optionsModel"),q("design:type",Array)],wt.prototype,"options",void 0);var Mt=function(t){function e(){var e=t.call(this)||this;return e.color="accent",e.labelPosition="after",e}return B(e,t),e.prototype.ngOnInit=function(){},e}(It);Mt.decorators=[{type:n.Component,args:[{selector:"aup-checkbox-input",template:'\x3c!-- TODO: add focus binding --\x3e\n<mat-checkbox\n [(ngModel)]="componentValueModel.value"\n [color]="color"\n [labelPosition]="labelPosition"\n [disabled]="!isEnabled()"\n>{{label}}</mat-checkbox>\n<mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n<mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n',styles:[":host{display:inline-flex;flex-direction:column;padding:24px 0 16px}:host.dense{padding:6px 0 2px}mat-error,mat-hint{font-size:12px;font-weight:400;line-height:13.5px;margin-left:24px;margin-top:4px}"]}]}],Mt.ctorParameters=function(){return[]},Mt.propDecorators={color:[{type:n.Input}],labelPosition:[{type:n.Input}]};var xt=function(t){function e(){var e=t.call(this)||this;return e.optionLabelFormat=function(t){return t&&e.optionLabel?t[e.optionLabel]:t},e}return B(e,t),e.prototype.ngOnInit=function(){},e}(Ct);xt.decorators=[{type:n.Component,args:[{selector:"aup-multiple-select-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <mat-select placeholder="{{placeholder}}"\n multiple\n [(ngModel)]="componentListModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-option *ngFor="let option of optionsModel.value; let i = index" [value]="option">\n <ng-container *ngIf="!optionTemplateRef">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf="optionTemplateRef"\n [ngTemplateOutlet]="optionTemplateRef"\n [ngTemplateOutletContext]="{ $implicit: option, index: i }"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[":host{display:inline-block}mat-form-field{width:100%}"]}]}],xt.ctorParameters=function(){return[]},xt.propDecorators={optionsModel:[{type:n.Input}],options:[{type:n.Input}],optionLabel:[{type:n.Input}],optionTemplateRef:[{type:n.ContentChild,args:["optionTemplate"]}],optionLabelFormat:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.ListModel)],xt.prototype,"optionsModel",void 0),G([I.StoreInListModel("optionsModel"),q("design:type",Array)],xt.prototype,"options",void 0);var Pt=function(t){function e(){var e=t.call(this)||this;return e.min=Number.MIN_SAFE_INTEGER,e.max=Number.MAX_SAFE_INTEGER,e}return B(e,t),e.prototype.ngOnInit=function(){},e}(It);Pt.decorators=[{type:n.Component,args:[{selector:"aup-number-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input type="number"\n matInput\n placeholder="{{placeholder}}"\n [attr.autocomplete]="autocomplete"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n [min]="min"\n [max]="max"\n >\n <mat-hint *ngIf="hint && !dense" >{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[""]}]}],Pt.ctorParameters=function(){return[]},Pt.propDecorators={autocomplete:[{type:n.Input}],min:[{type:n.Input}],max:[{type:n.Input}]};var Rt=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.ngOnInit=function(){},e}(It);Rt.decorators=[{type:n.Component,args:[{selector:"aup-password-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input type="password"\n matInput\n placeholder="{{placeholder}}"\n [attr.autocomplete]="autocomplete"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n\n',styles:[""]}]}],Rt.ctorParameters=function(){return[]},Rt.propDecorators={autocomplete:[{type:n.Input}]};var St=function(t){function e(){var e=t.call(this)||this;return e.optionLabelFormat=function(t){return t&&e.optionLabel?t[e.optionLabel]:t},e}return B(e,t),e.prototype.ngOnInit=function(){},e}(It);St.decorators=[{type:n.Component,args:[{selector:"aup-select-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <mat-select placeholder="{{placeholder}}"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-option *ngIf="allowNil">\n <ng-container *ngIf="!nilOptionTemplateRef">{{placeholder}}</ng-container>\n <ng-container *ngIf="nilOptionTemplateRef" [ngTemplateOutlet]="nilOptionTemplateRef"></ng-container>\n </mat-option>\n <mat-option *ngFor="let option of optionsModel.value; let i = index" [value]="option">\n <ng-container *ngIf="!optionTemplateRef">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf="optionTemplateRef"\n [ngTemplateOutlet]="optionTemplateRef"\n [ngTemplateOutletContext]="{ $implicit: option, index: i }"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[":host{display:inline-block}mat-form-field{width:100%}"]}]}],St.ctorParameters=function(){return[]},St.propDecorators={optionsModel:[{type:n.Input}],options:[{type:n.Input}],optionLabel:[{type:n.Input}],allowNil:[{type:n.Input}],optionTemplateRef:[{type:n.ContentChild,args:["optionTemplate"]}],nilOptionTemplateRef:[{type:n.ContentChild,args:["nilOptionTemplate"]}],optionLabelFormat:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.ListModel)],St.prototype,"optionsModel",void 0),G([I.StoreInListModel("optionsModel"),q("design:type",Array)],St.prototype,"options",void 0);var Dt=function(t){function e(){var e=t.call(this)||this,n=I.Dsl.disposeWith(e),o=n.chain;n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn;return e.clearCommand=I.Command.create((function(){e.componentValueModel.value=null})),e.clearCommand.disableWhile(o.stringValue(e.componentValueModel).isBlank()),e}return B(e,t),e.prototype.ngOnInit=function(){},e}(It);Dt.decorators=[{type:n.Component,args:[{selector:"aup-string-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input matInput\n placeholder="{{placeholder}}"\n [attr.autocomplete]="autocomplete"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n <button mat-button mat-icon-button matSuffix *ngIf="enableClear" [pectinCommand]="clearCommand">\n <aup-icon icon="mat:close"></aup-icon>\n </button>\n</mat-form-field>\n\n',styles:["button[disabled]{visibility:hidden}"]}]}],Dt.ctorParameters=function(){return[]},Dt.propDecorators={autocomplete:[{type:n.Input}],enableClearModel:[{type:n.Input}],enableClear:[{type:n.Input}]},G([I.TrackExternal({defaultValue:!1}),q("design:type",I.ValueModel)],Dt.prototype,"enableClearModel",void 0),G([I.StoreInValueModel("enableClearModel"),q("design:type",Boolean)],Dt.prototype,"enableClear",void 0);var At=function(t){function e(){var e=t.call(this)||this;return e.rows=2,e}return B(e,t),e.prototype.ngOnInit=function(){},e}(It);At.decorators=[{type:n.Component,args:[{selector:"aup-text-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <textarea matInput\n placeholder="{{placeholder}}"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n [rows]="rows"\n [cols]="cols"\n >\n </textarea>\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n\n',styles:["button[disabled]{visibility:hidden}textarea{overflow:auto}"]}]}],At.ctorParameters=function(){return[]},At.propDecorators={rows:[{type:n.Input}],cols:[{type:n.Input}]},t.IconComponent=function(){function t(){this.allowedPrefixes=x.Enum.values(t.IconPrefix).map((function(t){return t+":"})),this.iconPrefix=t.IconPrefix}return Object.defineProperty(t.prototype,"icon",{get:function(){return this._icon},set:function(t){if(this._icon=t,!t)return this.errorMessage="icon is nil",void(this.prefix=void 0);var e=t.indexOf(":");e>0&&(this.prefix=this.icon.slice(0,e),this.suffix=this.icon.slice(e+1)),this.prefix&&(this.errorMessage='Unknown icon "'+t+'"'),this.errorMessage="Unknown icon prefix, expected one of ["+this.allowedPrefixes.join(",")+'] got "'+this.prefix+':"'},enumerable:!1,configurable:!0}),t}(),t.IconComponent.decorators=[{type:n.Component,args:[{selector:"aup-icon",template:'<ng-container [ngSwitch]="prefix">\n\n <mat-icon *ngSwitchCase="iconPrefix.SVG"\n [svgIcon]="suffix"\n class="svgIcon">\n </mat-icon>\n\n <mat-icon *ngSwitchCase="iconPrefix.MATERIAL">\n {{suffix}}\n </mat-icon>\n\n <div *ngSwitchCase="iconPrefix.FONT_AWESOME"\n class="faIconWrapper">\n <fa-icon [icon]="suffix">\n </fa-icon>\n </div>\n\n <mat-icon *ngSwitchDefault\n [matTooltip]="errorMessage">\n bug_report\n </mat-icon>\n\n</ng-container>\n\n',styles:[":host{display:inline-flex;width:24px}fa-icon{vertical-align:middle}.faIconWrapper{text-align:center}.faIconWrapper,.svgIcon{height:24px;width:24px}:host(.mat-chip-remove) mat-icon{font-size:18px}mat-icon{height:inherit;width:inherit}"]}]}],t.IconComponent.propDecorators={icon:[{type:n.Input}]},(t.IconComponent||(t.IconComponent={})).IconPrefix=x.Enum({SVG:"svg",FONT_AWESOME:"fa",MATERIAL:"mat"});var Tt=function(){};Tt.decorators=[{type:n.Component,args:[{selector:"aup-noop",template:"",styles:[":host{display:block}"]}]}],Tt.ctorParameters=function(){return[]};var Ot=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();Ot.decorators=[{type:n.Component,args:[{selector:"aup-scroll-container",template:'<div class="container" cdkScrollable>\n <ng-content></ng-content>\n</div>\n',styles:[":host{flex-direction:column;min-height:0}.container,:host{align-items:stretch;display:flex}.container{flex:1;flex-basis:0;flex-direction:column;overflow-y:scroll}"]}]}],Ot.ctorParameters=function(){return[]};var Ft=function(){function t(){this.underline=!1}return t.prototype.ngOnInit=function(){},t}();Ft.decorators=[{type:n.Component,args:[{selector:"aup-section-header",template:"<ng-content></ng-content>\n",styles:[":host{--def-border-bottom-color:var(--border-bottom-color,rgba(0,0,0,0.07));color:rgba(0,0,0,.5);display:block;font-size:12px;line-height:12px;padding:8px 16px}:host.underline{border-bottom:1px solid var(--def-border-bottom-color)}"]}]}],Ft.ctorParameters=function(){return[]},Ft.propDecorators={underline:[{type:n.Input},{type:n.HostBinding,args:["class.underline"]}]};var Et=function(){function t(t){this.templateRef=t}return Object.defineProperty(t.prototype,"name",{get:function(){return this.constructor.name},enumerable:!1,configurable:!0}),t}(),kt=function(t){function e(e){var n=t.call(this,e)||this;return n.isDefault=!1,n}return B(e,t),e.prototype.matches=function(t){return this.aupSwitchCaseWhen===t},e}(Et);kt.decorators=[{type:n.Directive,args:[{selector:"[aupSwitchCaseWhen]",providers:[{provide:Et,useExisting:kt}]}]}],kt.ctorParameters=function(){return[{type:n.TemplateRef}]},kt.propDecorators={aupSwitchCaseWhen:[{type:n.Input}]};var Vt=function(t){function e(e){var n=t.call(this,e)||this;return n.isDefault=!0,n}return B(e,t),e.prototype.matches=function(t){return!1},e}(Et);Vt.decorators=[{type:n.Directive,args:[{selector:"[aupSwitchCaseDefault]",providers:[{provide:Et,useExisting:Vt}]}]}],Vt.ctorParameters=function(){return[{type:n.TemplateRef}]};var _t=function(t){function e(e){var n=t.call(this)||this;return n.cdr=e,n.selectedIndex=0,n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.ngAfterContentInit=function(){var t=this,e=this.switchCaseOptions.changes.subscribe((function(e){return t.updateSelection()}));this.onDispose((function(){return e.unsubscribe()}));var n=I.Dsl.disposeWith(this);n.chain;(0,n.when)(this.switchModel).changes((function(){return t.updateSelection()}),{initialValue:"triggerChange"}),this.cdr.detectChanges()},e.prototype.updateSelection=function(){var t=this,e=[];this.switchCaseOptions.forEach((function(n,o){n.matches(t.switchModel.value)&&e.push(o)})),e.length>1&&console.warn("found "+e.length+" matching case values, displaying the first."),0===e.length&&(this.switchCaseOptions.forEach((function(t,n){e.push(n)})),e.length>1&&console.warn("found "+e.length+" default case values, displaying the first.")),e.length>0?this.selectedIndex=e[0]:(console.warn("found no matching or default case values."),this.selectedIndex=-1)},e}(Y);_t.decorators=[{type:n.Component,args:[{selector:"aup-switch-case",template:'<mat-tab-group class="content-wrapper" no-tab-header full-height-tabs [selectedIndex]="selectedIndex">\n <mat-tab *ngFor="let option of switchCaseOptions">\n <ng-template [ngTemplateOutlet]="option.templateRef"></ng-template>\n </mat-tab>\n</mat-tab-group>\n\n\n',styles:[":host{align-items:stretch;display:flex;flex-direction:column}mat-tab-group{flex:1}"]}]}],_t.ctorParameters=function(){return[{type:n.ChangeDetectorRef}]},_t.propDecorators={switchModel:[{type:n.Input}],switch:[{type:n.Input}],switchCaseOptions:[{type:n.ContentChildren,args:[Et]}]},G([I.TrackExternal(),q("design:type",I.ValueModel)],_t.prototype,"switchModel",void 0),G([I.StoreInValueModel("switchModel"),q("design:type",Object)],_t.prototype,"switch",void 0);var Lt=Symbol("aup-cell-header-renderer-component-ref"),jt=Symbol("aup-cell-renderer-component-ref"),Nt=Symbol("aup-cell-editor-component-ref"),Ut=Symbol("aup-cell-renderer-portal-component"),Ht=Symbol("aup-cell-editor-portal-component"),Bt=function(){},Gt=function(t){function e(e,n){var o=t.call(this)||this;return o.componentType=e,o.initialiseHeader=n,o}return B(e,t),e.prototype.initialiseHost=function(t,e){P.assert.isTruthy(t),t[Lt]=new l.ComponentPortal(this.componentType)},e.prototype.onPortalAttached=function(t,e){this.initialiseHeader(e,t.column)},e}(Bt),qt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e}(Bt),Wt=function(t){function e(e,n){var o=t.call(this)||this;return o.componentType=e,o.updateComponent=n,o}return B(e,t),e.prototype.initialiseHost=function(t,e){t[jt]=new l.ComponentPortal(this.componentType)},e.prototype.onPortalAttached=function(t,e){t[Ut]=e,this.updateComponent(e,t.getRowData(),!0)},e.prototype.pushState=function(t){t[Ut]&&this.updateComponent(t[Ut],t.getRowData(),!1)},e}(qt),zt=function(t){function e(e,n){var o=t.call(this)||this;return o.componentType=e,o.initialiseEditorSession=n,o}return B(e,t),e.prototype.initialiseHost=function(t,e){P.assert.isTruthy(t),t[Nt]=new l.ComponentPortal(this.componentType)},e.prototype.onPortalAttached=function(t,e){t[Ht]=e,this.initialiseEditorSession(e,t.editSession)},e}(Bt),Kt=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.registerPortal=function(t,e,n,o){this.templateRef=t,this.viewContainer=e,this.fillCell=n,this.padChild=o},e.prototype.initialiseHost=function(t,e){P.assert.isTruthy(t)},e.prototype.onPortalAttached=function(t,e){},e.prototype.pushState=function(t){t[jt]=this.createPortal(t.getRowData()),t.fillCell=this.fillCell,t.padChild=this.padChild},e.prototype.createPortal=function(t){return new l.TemplatePortal(this.templateRef,this.viewContainer,Object.assign(Object.assign({},t),{$implicit:t.row}))},e}(qt),$t=function(){function t(){}return Object.defineProperty(t.prototype,"value",{get:function(){return this._value},set:function(t){this._value=t},enumerable:!1,configurable:!0}),t}();$t.decorators=[{type:n.Component,args:[{selector:"aup-default-cell-renderer",template:"{{value}}\n",styles:[""]}]}],$t.ctorParameters=function(){return[]},$t.propDecorators={value:[{type:n.Input}]};var Xt=function(){};Xt.decorators=[{type:n.Component,args:[{selector:"aup-default-header-renderer",template:"{{headerText}}\n",styles:[""]}]}],Xt.ctorParameters=function(){return[]},Xt.propDecorators={headerText:[{type:n.Input}]};var Yt=function(t){function e(){var e=t.call(this)||this;return e.saveCommand=I.Command.create((function(){e.editSession.saveCommand.execute(e.editSession.form).then((function(t){t&&e.editSession.dispose()}))})),e.cancelCommand=I.Command.create((function(){e.editSession.dispose()})),e}return B(e,t),e.prototype.ngOnInit=function(){},Object.defineProperty(e.prototype,"form",{get:function(){var t;return null===(t=this.editSession)||void 0===t?void 0:t.form},enumerable:!1,configurable:!0}),e}(Y);Yt.decorators=[{type:n.Component,args:[{selector:"aup-row-editor-controls",template:'<button *ngIf="!editSession" mat-icon-button [pectinCommand]="editRowCommand" class="edit-button"><aup-icon icon="mat:edit"></aup-icon></button>\n<button *ngIf="editSession" mat-icon-button [pectinCommand]="saveCommand"><aup-icon icon="mat:done"></aup-icon></button>\n<button *ngIf="editSession" mat-icon-button [pectinCommand]="cancelCommand"><aup-icon icon="mat:clear"></aup-icon></button>\n',styles:[":host{display:block;width:80px}.edit-button{visibility:hidden}:host-context(tr:hover) .edit-button{visibility:visible}"]}]}],Yt.ctorParameters=function(){return[]},Yt.propDecorators={row:[{type:n.Input}],editRowCommand:[{type:n.Input}],editSession:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.Command)],Yt.prototype,"editRowCommand",void 0);var Jt=function(t){function e(){var e=t.call(this)||this;return e.selectCommand=I.Command.create((function(){e.selectionModel.selectCommand.execute(e.row)})),e}return B(e,t),e.prototype.isSelected=function(){return this.selectionModel.isSelected(this.row)},e}(Y);Jt.decorators=[{type:n.Component,args:[{selector:"aup-select-cell-renderer",template:'<mat-checkbox [pectinCommand]="selectCommand" [checked]="isSelected()"></mat-checkbox>\n',styles:[""]}]}],Jt.ctorParameters=function(){return[]},Jt.propDecorators={row:[{type:n.Input}]};var Zt=function(t){function e(){var e=t.call(this)||this;return e.selectCommand=I.Command.create((function(){e.selectionModel.toggleAllCommand.execute()})),e}return B(e,t),e.prototype.isSelected=function(){var t;return(null===(t=this.selectionModel)||void 0===t?void 0:t.allSelected.value)||!1},e.prototype.isIntermediate=function(){var t;return(null===(t=this.selectionModel)||void 0===t?void 0:t.someSelected.value)||!1},e}(Y);Zt.decorators=[{type:n.Component,args:[{selector:"aup-select-header-cell-renderer",template:'<mat-checkbox *ngIf="enableHeaderControls" [pectinCommand]="selectCommand" [checked]="isSelected()" [indeterminate]="this.isIntermediate()"></mat-checkbox>\n',styles:[""]}]}],Zt.ctorParameters=function(){return[]};var Qt=Symbol("aup-cell-renderer:row-data-cache"),te=function(){function t(t,e){this.columnId=t,this.defaults=e,this._selectRowOnClick=void 0,this.cellHeaderRenderer(Xt,(function(t,e){t.headerText=e.getHeaderText()}))}return t.prototype.getHeaderText=function(){var t;return(null===(t=this.getColumnTextProperties())||void 0===t?void 0:t.headerText())||this.getDefaultHeaderText()},t.prototype.getDefaultHeaderText=function(){return this.columnId},t.prototype.getColumnTextProperties=function(){return this._columnTextProperties||this.defaults.getColumnTextProperties(this)},t.prototype.textProperties=function(t){return this._columnTextProperties=t,this},t.prototype.configureHeaderRenderer=function(t){this._columnHeaderPortalRef=t},t.prototype.configureCellRenderer=function(t){this._cellRendererPortalRef=t},t.prototype.configureCellEditor=function(t){this._cellEditorPortalRef=t},t.prototype.cellHeaderRenderer=function(t,e){return this.configureHeaderRenderer(new Gt(t,e)),this},t.prototype.hasEditorPortal=function(){return!!this._cellEditorPortalRef},t.prototype.attachHeaderCell=function(t){this._columnHeaderPortalRef.initialiseHost(t,this)},t.prototype.attachCell=function(t){this._cellRendererPortalRef.initialiseHost(t,this),this.hasEditorPortal()&&this._cellEditorPortalRef.initialiseHost(t,this)},t.prototype.onHeaderAttached=function(t,e){this._columnHeaderPortalRef.onPortalAttached(t,e)},t.prototype.onRendererAttached=function(t,e){this._cellRendererPortalRef.onPortalAttached(t,e)},t.prototype.onEditorAttached=function(t,e){this._cellEditorPortalRef.onPortalAttached(t,e)},t.prototype.updatePortalContent=function(t){this._cellRendererPortalRef.pushState(t)},t.prototype.selectRowOnClick=function(t){return this._selectRowOnClick=t,this},t.prototype.isRowSelectionEnabled=function(){return this._selectRowOnClick},t.prototype.isRowSelectionExplicitlyEnabled=function(){return!0===this._selectRowOnClick},t.prototype.isRowSelectionExplicitlyDisabled=function(){return!1===this._selectRowOnClick},t}();G([w.Memoize(),q("design:type",Function),q("design:paramtypes",[]),q("design:returntype",String)],te.prototype,"getHeaderText",null),G([w.Memoize(),q("design:type",Function),q("design:paramtypes",[]),q("design:returntype",Object)],te.prototype,"getColumnTextProperties",null);var ee,ne=function(t){function e(e,n,o){var i=t.call(this,e,o)||this;return i.property=n,i._format=function(t){return t},i.cellRenderer($t),i}return B(e,t),e.prototype.cellRenderer=function(t,e){var n=this;return this.configureCellRenderer(new Wt(t,(function(t,o,i){i&&(j.default.isFunction(e)?e(t):j.default.isFunction(null==e?void 0:e.onComponentInit)&&e.onComponentInit(t)),t.value=n._format(o.row[n.property]),!j.default.isFunction(e)&&j.default.isFunction(null==e?void 0:e.onRowUpdate)&&e.onRowUpdate(t,o.row)}))),this},e.prototype.mutableCellRenderer=function(t,e){var n=this;return this.configureCellRenderer(new Wt(t,(function(t,o,i){t[Qt]=o.row;var r=!1;i&&(j.default.isFunction(null==e?void 0:e.onComponentInit)&&e.onComponentInit(t),t.onValueEdited((function(n,o){r||e.onValueEdit(t[Qt],n,o)}))),r=!0,t.value=o.row[n.property],r=!1,!j.default.isFunction(e)&&j.default.isFunction(null==e?void 0:e.onRowUpdate)&&e.onRowUpdate(t,o.row)}))),this},e.prototype.cellEditor=function(t,e,n){var o=this,i=Array.isArray(e)?e:void 0,r=j.default.isFunction(e)?e:n;return this.configureCellEditor(new zt(t,(function(t,e){var n=e.form.pluck(o.property);i&&n.validateUsing(i),t.valueModel=n,r&&r(t)}))),this},e.prototype.format=function(t){return P.assert.isFunction(t),this._format=t,this},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(te),oe=function(t){function e(e,n,o){var i=t.call(this,e,o)||this;return i.property=n,i._format=function(t){return t.map((function(t){return null==t?void 0:t.toString()})).join(", ")},i.cellRenderer($t),i}return B(e,t),e.prototype.cellRenderer=function(t){var e=this;return this.configureCellRenderer(new Wt(t,(function(t,n){t.value=e._format(n.row[e.property])}))),this},e.prototype.cellEditor=function(t,e,n){var o=this,i=Array.isArray(e)?e:void 0,r=j.default.isFunction(e)?e:n;return this.configureCellEditor(new zt(t,(function(t,e){var n=e.form.pluckList(o.property);i&&n.validateUsing(i),t.listModel=n,r&&r(t)}))),this},e.prototype.format=function(t){return P.assert.isFunction(t),this._format=t,this},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(te),ie=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.getValue=o,i.cellRenderer($t),i}return B(e,t),e.prototype.cellRenderer=function(t,e){var n=this;return this.configureCellRenderer(new Wt(t,(function(t,o,i){i&&(j.default.isFunction(e)?e(t):j.default.isFunction(null==e?void 0:e.onComponentInit)&&e.onComponentInit(t)),t.value=n.getValue(o.row),!j.default.isFunction(e)&&j.default.isFunction(null==e?void 0:e.onRowUpdate)&&e.onRowUpdate(t,o.row)}))),this},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(te),re=function(t){function e(e,n,o){var i=t.call(this,e,o)||this;return i.cellRenderer(Yt),i}return B(e,t),e.prototype.cellRenderer=function(t){return this.configureCellRenderer(new Wt(t,(function(t,e){t.row=e.row,t.editSession=e.editSession,t.editRowCommand=e.editRowCommand}))),this},e.prototype.getDefaultHeaderText=function(){return""},e}(te),ae=function(t){function e(e,n){var o=t.call(this,e,n)||this;return o.config=new Kt,o.configureCellRenderer(o.config),o}return B(e,t),e.prototype.setTemplate=function(t,e,n,o){this.config.registerPortal(t,e,n,o)},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(te),se=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.selectionModel=o,i._enableHeaderControls=!0,i.selectOnRowClick(!1),o instanceof I.MultipleSelectionModel&&i.cellHeaderRenderer(Zt,(function(t){t.selectionModel=o,t.enableHeaderControls=i._enableHeaderControls})),i.configureCellRenderer(new Wt(Jt,(function(t,e){t.row=e.row,t.selectionModel=o}))),i}return B(e,t),e.prototype.getDefaultHeaderText=function(){return""},e.prototype.isRowSelectionEnabledByDefault=function(){return this.isRowSelectionExplicitlyEnabled()},e.prototype.selectOnRowClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e.prototype.enableHeaderControls=function(t){return this._enableHeaderControls=t,this},e.prototype.selectRow=function(t){this.selectionModel.selectCommand.execute(t)},e}(te),ce=function(t){function e(e,n,o,i){var r=t.call(this)||this;return r.rowId=e,r.form=o,r.saveCommand=i,r._liveRowValue=new I.MutableValueModel,r.liveRowValue=r._liveRowValue.readonly,r.form.load(n),r._liveRowValue.value=n,r.form.onEdit((function(){r._liveRowValue.value=N.default(r._liveRowValue.value,(function(t){r.form.writeDirtyStateTo(t)}))})),r}return B(e,t),e}(I.GarbageCollector),le=function(t,e){this.className=t,this.matches=e};t.TableModel=ee=function(){function t(t){var e=this;this.sourceOfTruth=t,this._garbage=new I.GarbageCollector,this._columns=new I.MutableListModel,this._editorSessions=new I.MutableListModel,this.rowClassNamePredicates=[],this._createForm=function(t){return new I.DirtyTrackingForm},this.trackBy=function(t,n){return e.identityOf?e.identityOf(n):t},this.identityOf=t.identityOf;var n=I.Dsl.disposeWith(this._garbage),o=n.chain;n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn;this._columnsById=o(this._columns).indexBy("columnId"),this._rowsBeingEdited=new I.MutableListModel([],{identifiedWith:this.identityOf}),this._editorSessionByRowId=o(this._editorSessions).indexBy("rowId"),this.editing=o(this._editorSessions).count().isGreaterThan(0),this.dataSource=o(this.sourceOfTruth).replaceAll(this.rowsBeingEdited),this.firstEditableColumn=o(this.columns).select((function(t){return t.hasEditorPortal()})).first(),this.hasColumnsWithRowSelectionExplicitlyEnabled=o(this._columns).findIndex((function(t){return t.isRowSelectionExplicitlyEnabled()})).isGreaterThanOrEqualTo(0),this.addRowClass("enable-hover",(function(){return e.isRowSelectionEnabled()}))}return t.fromList=function(t,e){var n=new ee(t);return e(n),n},Object.defineProperty(t.prototype,"rowsBeingEdited",{get:function(){return this._rowsBeingEdited.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"columns",{get:function(){return this._columns.readonly},enumerable:!1,configurable:!0}),t.prototype.pluck=function(t,e){return this.addColumn(new ne((null==e?void 0:e.columnId)||t.toString(),t,this))},t.prototype.pluckList=function(t,e){return this.addColumn(new oe((null==e?void 0:e.columnId)||t.toString(),t,this))},t.prototype.addSelectionColumn=function(t){return I.assert.isNil(this.selectionColumnModel),this.selectionColumnModel=new se("selection",this,t),this.addColumn(this.selectionColumnModel)},t.prototype.addEditControls=function(t){return this.saveCommand=t,this.addColumn(new re("editControls",t,this))},t.prototype.addCustomColumn=function(t,e){return this.addColumn(new ie(t,this,e))},t.prototype.addComponentColumn=function(t,e,n){return this.addColumn(new ie(t,this,(function(t){return t}))).cellRenderer(e,n)},t.prototype.addTemplateColumn=function(t){return this.addColumn(new ae(t,this))},t.prototype.addRowClass=function(t,e){this.rowClassNamePredicates.push(new le(t,e))},t.prototype.getRowClasses=function(t){var e=[];return this.rowClassNamePredicates.forEach((function(n){n.matches(t)&&e.push(n.className)})),e},t.prototype.useFormFactory=function(t){return this._createForm=t,this},t.prototype.addColumn=function(t){return this._columnsById.get(t.columnId)?I.lang.illegalState("Column with id="+t.columnId+" already exists"):this._columns.push(t),t},t.prototype.columnTextProperties=function(t){this._columnTextPropertiesLookup=t},t.prototype.getColumnTextProperties=function(t){return this._columnTextPropertiesLookup?this._columnTextPropertiesLookup[t.columnId]:void 0},t.prototype.startEditSession=function(t){var e=this,n=this.identityOf(t);if(this._rowsBeingEdited.query().indexOf(t)>-1)return I.lang.illegalState("Row with id="+n+" already being edited");var o=new ce(n,t,this._createForm(t),this.saveCommand);return(0,I.Dsl.disposeWith(o).when)(o.liveRowValue).changes((function(t){e._rowsBeingEdited.replaceOrPush(t)}),{initialValue:"triggerChangeUnlessNil"}),this._editorSessions.push(o),o.onDispose((function(){e._rowsBeingEdited.remove(o.liveRowValue.value),e._editorSessions.remove(o)})),o},t.prototype.getEditSessionFor=function(t){return this._editorSessionByRowId.get(this.identityOf(t))},t.prototype.cancelAllEditorSessions=function(){var t=this;this._editorSessions.runInTransaction((function(e){t._rowsBeingEdited.runInTransaction((function(){e.value.forEach((function(t){return t.dispose()}))}))}))},t.prototype.isRowSelectionEnabledFor=function(t){var e;return this.selectionColumnModel&&(null!==(e=t.isRowSelectionEnabled())&&void 0!==e?e:this.isRowSelectionEnabledByDefault())},t.prototype.isRowSelectionEnabledByDefault=function(){return this.selectionColumnModel&&this.selectionColumnModel.isRowSelectionEnabledByDefault()},t.prototype.isRowSelectionEnabled=function(){return this.hasColumnsWithRowSelectionExplicitlyEnabled.value||this.isRowSelectionEnabledByDefault()},t.prototype.selectRow=function(t){var e;null===(e=this.selectionColumnModel)||void 0===e||e.selectRow(t)},t}(),t.TableModel=ee=G([I.TrackExternal.Strategy(new I.TrackExternal.OneTimeBinding),q("design:paramtypes",[I.ListModel])],t.TableModel);var ue=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.ngOnInit=function(){var t=I.Dsl.disposeWith(this),e=t.chain;t.valueOf,t.before,t.when,t.after,t.observe,t.switchOn;this.columns=e(this.tableModel.columns),this.columnIds=e(this.columns).pluck("columnId"),this.columnsById=e(this.columns).indexBy("columnId")},e.prototype.isEditing=function(t){return!!this.tableModel.getEditSessionFor(t)},e.prototype.registerColumnTemplate=function(t,e,n,o,i){var r=this.columnsById.get(t);r instanceof ae&&r.setTemplate(e,n,o,i)},e.prototype.onCellClicked=function(t,e){this.tableModel.isRowSelectionEnabledFor(t)&&this.tableModel.selectRow(e)},e}(Y);ue.decorators=[{type:n.Component,args:[{selector:"aup-table",template:'<table mat-table [dataSource]="tableModel.dataSource.value" [trackBy]="tableModel.trackBy">\n\n <ng-container *ngFor="let column of columns.value; index as index; first as first; last as last" matColumnDef="{{column.columnId}}">\n <th mat-header-cell *matHeaderCellDef>\n <aup-table-header-cell-renderer [column]="column"\n [attr.column-index]="index"\n [attr.column-id]="column.columnId"\n [class.first-column]="first"\n [class.last-column]="last"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef="let row" (click)="onCellClicked(column, row)" [class.enable-cursor]="tableModel.isRowSelectionEnabledFor(column)">\n <aup-table-cell-renderer [column]="column"\n [row]="row"\n [tableModel]="tableModel"\n [editSession]="tableModel.getEditSessionFor(row)"\n [attr.column-index]="index"\n [attr.column-id]="column.columnId"\n [class.first-column]="first"\n [class.last-column]="last"\n ></aup-table-cell-renderer>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef="columnIds.value"></tr>\n <tr mat-row *matRowDef="let row; columns: columnIds.value; let i = index"\n [ngClass]="tableModel.getRowClasses(row)" [attr.trackBy]="tableModel.trackBy(i, row)"\n ></tr>\n\n</table>\n',styles:[":host{align-items:stretch;display:flex;flex-direction:column}:host table{flex:1}"]}]}],ue.ctorParameters=function(){return[]},ue.propDecorators={tableModel:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",t.TableModel)],ue.prototype,"tableModel",void 0);var pe=function(){function t(t,e,n){this.host=t,this.templateRef=e,this.viewContainer=n,this.aupColumnTemplateFillCell=!1,this.aupColumnTemplateAutoPadChild=void 0}return t.prototype.ngOnInit=function(){var t;I.assert.isTruthy(this.aupColumnTemplateColumnId),this.host.registerColumnTemplate(this.aupColumnTemplateColumnId,this.templateRef,this.viewContainer,this.aupColumnTemplateFillCell,null!==(t=this.aupColumnTemplateAutoPadChild)&&void 0!==t?t:this.aupColumnTemplateFillCell)},t}();pe.decorators=[{type:n.Directive,args:[{selector:"[aupColumnTemplate]"}]}],pe.ctorParameters=function(){return[{type:ue},{type:n.TemplateRef},{type:n.ViewContainerRef}]},pe.propDecorators={aupColumnTemplate:[{type:n.Input}],aupColumnTemplateColumnId:[{type:n.Input}],aupColumnTemplateFillCell:[{type:n.Input}],aupColumnTemplateAutoPadChild:[{type:n.Input}]};var de=function(t){function e(){var e=t.call(this)||this;return e.defaultClassNames="aup-cell-renderer",e.fillCell=!1,e.padChild=!1,e.editRowCommand=I.Command.create((function(){e.tableModel.startEditSession(e.row)})),e}return B(e,t),e.prototype.ngOnInit=function(){var t=I.Dsl.disposeWith(this),e=t.chain;t.valueOf,t.before,t.when,t.after,t.observe,t.switchOn;this.firstEditableColumn=e(this.tableModel.firstEditableColumn).equals(this.column),this.column.attachCell(this)},e.prototype.hasActiveEditor=function(){return!!this.editSession&&!!this.column.hasEditorPortal()},e.prototype.initialiseRenderer=function(t){this.column.onRendererAttached(this,t)},e.prototype.initialiseEditor=function(t){var e=this;this.column.onEditorAttached(this,t),this.firstEditableColumn.value&&setTimeout((function(){return e.tryAndFocusEditor(t)}))},e.prototype.tryAndFocusEditor=function(t){var e;if(t.requestFocus)t.requestFocus();else{var n=t.valueModel||t.listModel;null===(e=null==n?void 0:n.focusContext)||void 0===e||e.requestFocus()}},e.prototype.ngOnChanges=function(t){this.column.updatePortalContent(this)},e.prototype.getRendererPortal=function(){return this[jt]},e.prototype.getEditorPortal=function(){return this[Nt]},e.prototype.getRowData=function(){return{row:this.row,editSession:this.editSession,editRowCommand:this.editRowCommand}},e}(Y);de.decorators=[{type:n.Component,args:[{selector:"aup-table-cell-renderer",template:'<ng-container *ngIf="!hasActiveEditor()" [cdkPortalOutlet]="getRendererPortal()" (attached)="initialiseRenderer($event.instance)"></ng-container>\n<ng-container *ngIf="hasActiveEditor()" [cdkPortalOutlet]="getEditorPortal()" (attached)="initialiseEditor($event.instance)"></ng-container>\n',styles:[""]}]}],de.ctorParameters=function(){return[]},de.propDecorators={row:[{type:n.Input}],column:[{type:n.Input}],editSession:[{type:n.Input}],tableModel:[{type:n.Input}],defaultClassNames:[{type:n.HostBinding,args:["class"]}],fillCell:[{type:n.HostBinding,args:["class.fillCell"]}],padChild:[{type:n.HostBinding,args:["class.padChild"]}]};var fe=function(){function t(){this.defaultClassNames="aup-header-cell-renderer"}return t.prototype.ngOnInit=function(){this.column.attachHeaderCell(this)},t.prototype.initialiseHeader=function(t){this.column.onHeaderAttached(this,t)},t.prototype.getPortal=function(){return this[Lt]},t}();fe.decorators=[{type:n.Component,args:[{selector:"aup-table-header-cell-renderer",template:'<ng-container [cdkPortalOutlet]="getPortal()" (attached)="initialiseHeader($event.instance)"></ng-container>\n',styles:[":host{align-items:stretch;display:flex;flex-direction:column;height:100%;justify-content:center}"]}]}],fe.ctorParameters=function(){return[]},fe.propDecorators={column:[{type:n.Input}],defaultClassNames:[{type:n.HostBinding,args:["class"]}]};var me=function(t,e){this.factory=t,this.face=e},he=function(t){function e(){var e=t.call(this)||this;return e.actions=[],e.moreActions=[],e}return B(e,t),e.prototype.registerAction=function(t,e){this.actions.push(new me(t,e))},e.prototype.registerMoreAction=function(t,e){this.moreActions.push(new me(t,e))},e.prototype.ngOnInit=function(){},e.prototype.createMoreMenuCommand=function(t,e){var n=this,o=I.Dsl.disposeWith(this).when,i=t.factory.create(e);return o(i.busy).becomesFalsey((function(){n.closeMoreMenu()})),i},e.prototype.closeMoreMenu=function(){this.menu.closeMenu()},e}(Y);he.decorators=[{type:n.Component,args:[{selector:"aup-table-row-menu",template:'\n <aup-tool-bar>\n <aup-command *ngFor="let action of actions" [command]="action.factory.create(value)"\n [face]="action.face"></aup-command>\n </aup-tool-bar>\n <ng-container *ngIf="moreActions.length > 0">\n <aup-more-menu>\n <aup-command *ngFor="let action of moreActions" [command]="action.factory.create(value)"\n [face]="action.face"></aup-command>\n </aup-more-menu>\n </ng-container>\n ',styles:[":host {\n display: inline-flex;\n flex-direction: row;\n align-items: center;\n }"]}]}],he.ctorParameters=function(){return[]},he.propDecorators={value:[{type:n.Input}],menu:[{type:n.ViewChild,args:[g.MatMenuTrigger]}]};var ge=function(t){function e(e){var n=t.call(this,e)||this;return n.focusManager=e,n}return B(e,t),e.prototype.arrowLeft=function(t){this.leftArrowCommand.enabled.value&&(t.preventDefault(),t.stopPropagation(),this.leftArrowCommand.execute())},e.prototype.arrowRight=function(t){this.rightArrowCommand.enabled.value&&(t.preventDefault(),t.stopPropagation(),this.rightArrowCommand.execute())},e.prototype.arrowDown=function(t){t.preventDefault(),t.stopPropagation(),this.focusManager.focusNext()},e.prototype.arrowUp=function(t){t.preventDefault(),t.stopPropagation(),this.focusManager.focusPrevious()},e.prototype.ngOnInit=function(){},e}(yt);ge.decorators=[{type:n.Component,args:[{selector:"aup-vertical-focus-container",template:"<ng-content></ng-content>\n",providers:[{provide:I.FocusManager}],styles:[":host{display:block}"]}]}],ge.ctorParameters=function(){return[{type:I.FocusManager,decorators:[{type:n.Self}]}]},ge.propDecorators={rightArrowCommand:[{type:n.Input,args:["command.arrowRight"]}],leftArrowCommand:[{type:n.Input,args:["command.arrowLeft"]}],arrowLeft:[{type:n.HostListener,args:["keyup.arrowLeft",["$event"]]}],arrowRight:[{type:n.HostListener,args:["keyup.arrowRight",["$event"]]}],arrowDown:[{type:n.HostListener,args:["keyup.arrowDown",["$event"]]}],arrowUp:[{type:n.HostListener,args:["keyup.arrowUp",["$event"]]}]},G([I.TrackExternal(),q("design:type",I.Command)],ge.prototype,"rightArrowCommand",void 0),G([I.TrackExternal(),q("design:type",I.Command)],ge.prototype,"leftArrowCommand",void 0);var ye=function(t){t.addIconPacks(C.fas)};ye.decorators=[{type:n.NgModule,args:[{declarations:[bt,It,Ct,Pt,Dt,At,Rt,St,xt,wt,Mt,Ot,Tt,_t,kt,Vt,yt,ge,vt,et,ue,Yt,pe,$t,de,Jt,Zt,Xt,fe,t.IconComponent,Ft,he,gt,ct,ft,at,st,pt,mt,lt,nt,rt],imports:[e.CommonModule,c.BrowserAnimationsModule,o.FormsModule,r.MatInputModule,i.MatFormFieldModule,a.MatSelectModule,s.MatTabsModule,tt,h.MatIconModule,d.MatButtonModule,f.MatCheckboxModule,y.MatTableModule,l.PortalModule,u.CdkScrollableModule,b.FontAwesomeModule,v.MatTooltipModule,p.MatAutocompleteModule,g.MatMenuModule,m.MatDividerModule],exports:[Pt,Dt,At,Rt,Mt,St,xt,wt,Ot,Tt,_t,kt,Vt,yt,ge,vt,et,ue,Yt,pe,t.IconComponent,Ft,he,at,gt,ct,ft,st,pt,mt,lt],providers:[Z]}]}],ye.ctorParameters=function(){return[{type:b.FaIconLibrary}]};var ve=new n.InjectionToken("InteractionActivityData"),be=function(t){function e(){var e=t.apply(this,$(arguments))||this;return e._busyModel=(new I.DelegatingValueModel).withDefault(!1),e._focusedModel=e.registerDisposable(new I.DelegatingValueModel),e.class="aup-activity",e}return B(e,t),Object.defineProperty(e.prototype,"isFocused",{get:function(){return this._focusedModel.value},enumerable:!1,configurable:!0}),e.prototype.initialise=function(t,e){var n=this,o=I.Dsl.disposeWith(this),i=(o.chain,o.when);P.assert.isNil(this._activityContext),this._activityContext=e,this._interactionContext=t,this._focusedModel.setDelegate(e.focused),i(this._focusedModel).becomesTruthy((function(){n.onActivityReady()}))},Object.defineProperty(e.prototype,"interactionContext",{get:function(){return P.assert.isTruthy(this.isInitialised()),this._interactionContext},enumerable:!1,configurable:!0}),e.prototype.done=function(t){return this._activityContext.onDone(t)},e.prototype.cancel=function(t){this._activityContext.onCancel(t)},e.prototype.onActivityReady=function(){},Object.defineProperty(e.prototype,"busy",{get:function(){return this._busyModel.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"focused",{get:function(){return this._focusedModel.readonly},enumerable:!1,configurable:!0}),e.prototype.busyWhile=function(t){this._busyModel.setDelegate(t)},e.prototype.isBusy=function(){return this._busyModel.value},e.prototype.isInitialised=function(){return!!this._activityContext},e}(Y);be.decorators=[{type:n.Component,args:[{template:""}]}],be.propDecorators={class:[{type:n.HostBinding,args:["class"]}],isFocused:[{type:n.HostBinding,args:["attr.focused"]}]};var Ce=function(t){function e(){var e=t.apply(this,$(arguments))||this;return e.align="start",e}return B(e,t),Object.defineProperty(e.prototype,"alignEnd",{get:function(){return"end"===this.align},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"alignStretch",{get:function(){return"stretch"===this.align},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){},e.prototype.hasConfirmCommand=function(){return I.DelegatingCommand.hasDelegate(this.confirmCommand)},e.prototype.hasCancelCommand=function(){return I.DelegatingCommand.hasDelegate(this.cancelCommand)},e}(Y);Ce.decorators=[{type:n.Component,args:[{selector:"aup-activity-actions",template:'<ng-container *ngIf="hasCancelCommand()">\n <aup-command class="cancel" [command]="cancelCommand" [face]="style.cancel"></aup-command>\n</ng-container>\n<ng-container *ngIf="hasConfirmCommand()">\n <aup-command class="confirm" [command]="confirmCommand" [face]="style.confirm"></aup-command>\n</ng-container>\n<div class="content">\n <ng-content></ng-content>\n</div>\n',styles:[':host{-ms-grid-columns:auto auto 1fr;-ms-grid-rows:auto;align-items:center;display:-ms-grid;display:grid;grid-template-areas:"cancel confirm content";grid-template-columns:auto auto 1fr;grid-template-rows:auto;justify-content:end}:host.align-end{-ms-grid-columns:1fr auto auto;grid-template-areas:"content cancel confirm";grid-template-columns:1fr auto auto}:host.align-stretch{-ms-grid-columns:auto 1fr auto;grid-template-areas:"cancel content confirm";grid-template-columns:auto 1fr auto}.cancel{-ms-grid-column:1;-ms-grid-row:1;grid-area:cancel}:host.align-end>.cancel{-ms-grid-column:2;-ms-grid-row:1}:host.align-stretch>.cancel{-ms-grid-column:1;-ms-grid-row:1}.confirm{-ms-grid-column:2;-ms-grid-row:1;grid-area:confirm}.column,:host.align-end>.confirm,:host.align-stretch>.confirm{-ms-grid-column:3;-ms-grid-row:1}.column{grid-area:content;text-align:left}:host.align-end>.column{-ms-grid-column:1;-ms-grid-row:1}:host.align-stretch>.column{-ms-grid-column:2;-ms-grid-row:1}']}]}],Ce.propDecorators={confirmCommand:[{type:n.Input}],cancelCommand:[{type:n.Input}],style:[{type:n.Input}],align:[{type:n.Input}],alignEnd:[{type:n.HostBinding,args:["class.align-end"]}],alignStretch:[{type:n.HostBinding,args:["class.align-stretch"]}]},G([I.TrackExternal(),q("design:type",I.Command)],Ce.prototype,"confirmCommand",void 0),G([I.TrackExternal(),q("design:type",I.Command)],Ce.prototype,"cancelCommand",void 0);var Ie=function(t){function e(e){var n=t.call(this)||this;return n.alert=e,n}return B(e,t),e.prototype.ngOnInit=function(){},e}(be);Ie.decorators=[{type:n.Component,args:[{selector:"aup-alert-dialog",template:'<h3 matDialogTitle *ngIf="alert.title">{{alert.title()}}</h3>\n<div matDialogContent>\n <p *ngFor="let line of alert.content()">{{line}}</p>\n</div>\n<div matDialogActions>\n <button mat-raised-button color="primary" (click)="done()" data-cy="close-button">{{alert.ok()}}</button>\n</div>\n',styles:[":host{display:block;padding:var(--aup-default-padding)}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{align-items:flex-end;justify-content:flex-end;margin-bottom:0!important;padding:0}"]}]}],Ie.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[ve]}]}]};var we=function(t){function e(e){var n=t.call(this)||this;return n.config=e,I.assert.notNil(e),n}return B(e,t),e.prototype.ngOnInit=function(){},Object.defineProperty(e.prototype,"confirm",{get:function(){return this.config.confirm},enumerable:!1,configurable:!0}),e.prototype.isDestructive=function(){return this.confirm.destructive&&this.confirm.destructive()},e.prototype.onConfirm=function(){var t=this;this.interactionContext.startActivity(this.config.activityType,this.config.data).then((function(e){return t.done(e)})).catch((function(e){return t.cancel(e)}))},e}(be);we.decorators=[{type:n.Component,args:[{selector:"aup-confirmation-dialog",template:'<h3 matDialogTitle *ngIf="confirm.title">{{confirm.title()}}</h3>\n<div matDialogContent>\n <p *ngFor="let line of confirm.content()">{{line}}</p>\n</div>\n<div matDialogActions>\n <button mat-button (click)="cancel()" data-cy="cancel-button">{{confirm.cancel()}}</button>\n <button mat-raised-button [color]="isDestructive() ? \'warn\' : \'primary\'"\n (click)="onConfirm()" data-cy="confirm-button">{{confirm.ok()}}</button>\n</div>\n\n',styles:[":host{display:block;padding:var(--aup-default-padding)}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{align-items:flex-end;justify-content:flex-end;margin-bottom:0!important;padding:0}"]}]}],we.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[ve]}]}]};var Me=function(t){function e(e){var n=t.call(this)||this;return n.confirm=e,I.assert.notNil(e),n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.isDestructive=function(){return this.confirm.destructive&&this.confirm.destructive()},e}(be);Me.decorators=[{type:n.Component,args:[{selector:"aup-confirmation-dialog",template:'<h3 matDialogTitle *ngIf="confirm.title">{{confirm.title()}}</h3>\n<div matDialogContent>\n <p *ngFor="let line of confirm.content()">{{line}}</p>\n</div>\n<div matDialogActions>\n <button mat-button (click)="cancel()" data-cy="cancel-button">{{confirm.cancel()}}</button>\n <button mat-raised-button [color]="isDestructive() ? \'warn\' : \'primary\'"\n (click)="done()" data-cy="confirm-button">{{confirm.ok()}}</button>\n</div>\n\n',styles:[":host{display:block;padding:var(--aup-default-padding)}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{align-items:flex-end;justify-content:flex-end;margin-bottom:0!important;padding:0}"]}]}],Me.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[ve]}]}]};var xe=function(){function t(){}return t.prototype.startActivity=function(t,e,n){return this.createAndLaunchActivity(t,e,P.Opts.get(n).getOptional("disableClose",!1))},t.prototype.confirm=function(t){return this.confirmOrReject(t).then((function(){return!0})).catch((function(){return!1}))},t.prototype.alert=function(t){return this.createAndLaunchActivity(Ie,t,!1)},t.prototype.confirmOrReject=function(t){return this.createAndLaunchActivity(Me,t,!0)},t.prototype.confirmThen=function(t,e,n){return this.createAndLaunchActivity(we,{confirm:t,activityType:e,data:n},!0)},t}(),Pe=function(){function t(t,e,n){this.activityClass=t,this.activityData=e,this.onComplete=n,this._complete=!1,this.deferredResult=I.Deferred.defer(),this.focusedModel=new I.MutableValueModel}return t.prototype.isActivityRealised=function(){return!!this._activity},t.prototype.isComplete=function(){return this._complete},Object.defineProperty(t.prototype,"activity",{get:function(){return I.assert.isTruthy(this.isActivityRealised()),this._activity},enumerable:!1,configurable:!0}),t.prototype.setFocused=function(t){this.focusedModel.value=t},Object.defineProperty(t.prototype,"focused",{get:function(){return this.focusedModel.value},enumerable:!1,configurable:!0}),t.prototype.notifyActivityCreated=function(t,e){I.assert.isNil(this._activity),this._activity=t;var n=this;this._activity.initialise(e,{onDone:function(t){n.finishActivity((function(e){return e.resolve(t)}))},onCancel:function(t){n.finishActivity((function(e){return e.reject(t)}))},focused:this.focusedModel.readonly})},t.prototype.finishActivity=function(t){I.assert.isFalsey(this.isComplete()),t(this.deferredResult),this._complete=!0,this.onComplete(this)},t.prototype.cancel=function(){this.activity.cancel()},Object.defineProperty(t.prototype,"activityResult",{get:function(){return this.deferredResult.promise},enumerable:!1,configurable:!0}),t}(),Re=function(){function t(t,e,n){this.componentFactoryResolver=t,this.viewContainerRef=e,this.injector=n}return Object.defineProperty(t.prototype,"activityRef",{get:function(){return this._activityRef},set:function(t){this.activityRef&&!this.activityRef.isComplete()&&P.lang.illegalState("changing activity before previous one has completed"),this._activityRef=t,this.loadActivity(t)},enumerable:!1,configurable:!0}),t.prototype.ngOnInit=function(){},t.prototype.loadActivity=function(t){var e=n.Injector.create({providers:[{provide:ve,useValue:t.activityData}],parent:this.injector}),o=this.componentFactoryResolver.resolveComponentFactory(t.activityClass);this.viewContainerRef.clear(),this.activityComponentRef=this.viewContainerRef.createComponent(o,0,e),this.activityRef.notifyActivityCreated(this.activityComponentRef.instance,this.nestedInteractionContext)},Object.defineProperty(t.prototype,"component",{get:function(){return this.activityComponentRef.instance},enumerable:!1,configurable:!0}),t}();Re.decorators=[{type:n.Component,args:[{selector:"aup-activity-outlet",template:"",styles:[":host{display:block}"]}]}],Re.ctorParameters=function(){return[{type:n.ComponentFactoryResolver},{type:n.ViewContainerRef},{type:n.Injector}]},Re.propDecorators={nestedInteractionContext:[{type:n.Input}],activityRef:[{type:n.Input}]};var Se=function(t){function e(){var e=t.call(this)||this;return e.dynamicHeight=!1,e.activityRefs=[],e.garbage=new I.GarbageCollector,e.inAnimation=new I.MutableValueModel(!1),e}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.ngAfterViewInit=function(){var t=this,e=I.Dsl.disposeWith(this);e.chain;e.observe.valuesFrom(this.tabs.animationDone).subscribe((function(){return t.onAnimationFinished()}))},e.prototype.initialise=function(t,e){I.assert.isFalsey(this.isInitialised()),I.assert.notNil(t),I.assert.notNil(e),this._identifier=t,this.interactionServiceApi=e},Object.defineProperty(e.prototype,"identifier",{get:function(){return this._identifier},enumerable:!1,configurable:!0}),e.prototype.isInitialised=function(){return!!this.identifier},e.prototype.isActive=function(){return this.getActiveActivityCount()>0},e.prototype.registerDisposable=function(t){return this.garbage.registerDisposable(t)},e.prototype.dispose=function(){I.assert.isFalsey(this.isActive()),this.garbage.dispose()},e.prototype.getActiveActivityRef=function(){return this.isActive()||P.lang.illegalState("no activity in progress"),j.default.findLast(this.activityRefs,(function(t){return!t.isComplete()}))},e.prototype.cancelActiveActivity=function(){return W(this,void 0,void 0,(function(){return z(this,(function(t){return this.getActiveActivityRef().cancel(),this.isCleaningUp()?[2,this.waitForInteractionContextCleanupToFinish()]:[2,!this.isActive()]}))}))},e.prototype.createAndLaunchActivity=function(t,e,n){var o=this;I.assert.isTruthy(this.isInitialised());var i=new Pe(t,e,(function(){o.getActiveActivityCount()>0?o.triggerTabSynchronisation():o.finishAndStartCleanup()}));return this.launchActivity(i),1===this.activityRefs.length&&this.interactionServiceApi.notifyActive(this),i.activityResult},e.prototype.getActiveActivityCount=function(){return this.activityRefs.filter((function(t){return!t.isComplete()})).length},e.prototype.isCleaningUp=function(){return!!this._deferredCleanUp},e.prototype.waitForInteractionContextCleanupToFinish=function(){return W(this,void 0,void 0,(function(){return z(this,(function(t){return[2,!this._deferredCleanUp||this._deferredCleanUp]}))}))},e.prototype.finishAndStartCleanup=function(){var t=this;if(!this._deferredCleanUp){this.activityRefs=[];var e=this.interactionServiceApi.notifyFinished(this);this._deferredCleanUp=e.finally((function(){t._deferredCleanUp=null}))}},e.prototype.launchActivity=function(t){var e=this.activityRefs.filter((function(t){return!t.isComplete()}));this.activityRefs=e.concat(t),this.synchroniseSelectedTabIndex()},e.prototype.activityIndex=function(t,e){return t},e.prototype.onAnimationFinished=function(){this.onAnimationFinishedJob&&(this.onAnimationFinishedJob(),this.onAnimationFinishedJob=void 0)},e.prototype.synchroniseSelectedTabIndex=function(){var t=this,e=this.tabs.selectedIndex,n=this.getActiveActivityCount()-1;e!==n&&(this.inAnimation.value=!0,this.activityRefs[n].setFocused(!1),this.tabs.selectedIndex=n,this.onAnimationFinishedJob=function(){t.activityRefs=t.activityRefs.filter((function(t){return!t.isComplete()})),t.inAnimation.value=!1,t.activityRefs.forEach((function(t,e){t.setFocused(e===n)}))})},e.prototype.getSelectedOutlet=function(){return this.activityOutlets.toArray()[this.tabs.selectedIndex]},e.prototype.getSelectedTabIndex=function(){return this.tabs.selectedIndex},e.prototype.triggerTabSynchronisation=function(){var t=this;this.syncSelectedTabTimeout&&clearTimeout(this.syncSelectedTabTimeout),this.syncSelectedTabTimeout=setTimeout((function(){t.syncSelectedTabTimeout=null,t.synchroniseSelectedTabIndex()}),75)},e}(xe);Se.decorators=[{type:n.Component,args:[{selector:"aup-activity-container",template:'<mat-tab-group #tabs no-tab-header\n [dynamicHeight]="dynamicHeight"\n [class.full-height-tabs]="!dynamicHeight">\n <mat-tab *ngFor="let activityRef of activityRefs; let i = index; trackBy: activityIndex">\n \x3c!--\n We have issues where angular is triggering a leave animation when an\n new activity is started, but is not running the enter animation\n when it is scrolled back into view. So we track the tab changes and\n disable all animations inside the tab while we\'re animating.\n --\x3e\n <div class="activity-outlet-wrapper" [@.disabled]="!activityRef.focused">\n <aup-activity-outlet [nestedInteractionContext]="this" [activityRef]="activityRef"></aup-activity-outlet>\n </div>\n </mat-tab>\n</mat-tab-group>\n',styles:[":host{display:flex;flex-direction:column}mat-tab-group{flex:1}"]}]}],Se.ctorParameters=function(){return[]},Se.propDecorators={dynamicHeight:[{type:n.Input}],tabs:[{type:n.ViewChild,args:["tabs",{static:!0}]}],activityOutlets:[{type:n.ViewChildren,args:[Re]}]};var De=function(){function t(t,e,n){this.activeInteractionContextIds=t,this.activeModalContext=e,this.createExclusiveInteractionContext=n}return t.prototype.isActive=function(){return this.getActiveInteractionContextIds().length>0},t.prototype.isModalActive=function(){return!!this.activeModalContext.value},t.prototype.isComponentInteracting=function(t){return t.interactionContext&&t.interactionContext.isActive()},t.prototype.getActiveInteractionContextIds=function(){return this.activeInteractionContextIds.value},t.prototype.cancelCurrentModalInteraction=function(){return this.activeModalContext.value.cancelActiveActivity()},t.prototype.cancelComponentInteraction=function(t){return t.interactionContext.cancelActiveActivity()},t}(),Ae=function(){},Te=0;t.InteractionService=function(){function t(e){this.modelInteractionContextFactory=e,this.garbage=new I.GarbageCollector,this._navigationInProgress=(new I.DelegatingValueModel).withDefault(!1);var n=I.Dsl.disposeWith(this.garbage),o=n.chain,i=n.valueOf;n.before,n.when,n.after,n.observe,n.switchOn;this.exclusiveInteractionRegistry=new t.ContextRegistry,this.modalInteractionRegistry=new t.ContextRegistry,this.inPlaceInteractionRegistry=new t.ContextRegistry,this.modalInteractionRegistry.disableWhen(i.any(this.exclusiveInteractionRegistry.active,this.modalInteractionRegistry.active).areTruthy()),this.inPlaceInteractionRegistry.disableWhen(i.any(this.exclusiveInteractionRegistry.active,this.modalInteractionRegistry.active,this.inPlaceInteractionRegistry.active).areTruthy()),this.active=i.any(this.inPlaceInteractionRegistry.active,this.modalInteractionRegistry.active).areTruthy(),this.activeInteractionContextIds=o(this.inPlaceInteractionRegistry.interactionContextIds).concat(this.modalInteractionRegistry.interactionContextIds),this.activeModalContext=o(this.modalInteractionRegistry.interactionContexts).first(),this.inModalInteraction=o(this.activeModalContext).isNotNil()}return t.prototype.isActive=function(){return this.active.value},t.prototype.createModalInteractionContextFor=function(t){return this.createModalInteractionContextDisposedWith(t)},t.prototype.createModalInteractionContextDisposedWith=function(e){return this.modelInteractionContextFactory.createInteractionContext("modal",new t.ApiAdapter(this.placeRouter,this.modalInteractionRegistry))},t.prototype.registerInplaceInteractionContext=function(e){e.initialise("ip"+ ++Te,new t.ApiAdapter(this.placeRouter,this.inPlaceInteractionRegistry))},t.prototype.registerPlaceRouter=function(e){var n=this;P.assert.isFalsey(this.placeRouter),this.placeRouter=e,this._navigationInProgress.setDelegate(this.placeRouter.navigationInProgress);var o=this;return new De(this.activeInteractionContextIds,this.activeModalContext,(function(){return o.modelInteractionContextFactory.createInteractionContext("exclusive",new t.ApiAdapter(n.placeRouter,n.exclusiveInteractionRegistry))}))},t}(),t.InteractionService.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t.InteractionService(n.ɵɵinject(Ae))},token:t.InteractionService,providedIn:"root"}),t.InteractionService.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.InteractionService.ctorParameters=function(){return[{type:Ae}]},function(t){var e=function(t){function e(){var e=t.call(this)||this;e._interactions=new I.MutableListModel,e._disabledDelegate=(new I.DelegatingValueModel).withDefault(!1);var n=I.Dsl.disposeWith(e),o=n.chain;n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn;return e.active=o(e._interactions).isNotEmpty(),e.interactionContextIds=o(e._interactions).pluck("identifier"),e}return B(e,t),Object.defineProperty(e.prototype,"interactionContexts",{get:function(){return this._interactions.readonly},enumerable:!1,configurable:!0}),e.prototype.start=function(t){this._interactions.push(t)},e.prototype.finish=function(t){this._interactions.remove(t)},e.prototype.isActive=function(){return this.active.value},e.prototype.disableWhen=function(t){this._disabledDelegate.setDelegate(t)},e}(I.GarbageCollector);t.ContextRegistry=e;var n=function(){function t(t,e){this.placeRouter=t,this.contextRegistry=e}return t.prototype.notifyActive=function(t){return P.assert.isTruthy(t.identifier),this.contextRegistry.start(t),this.isNavigationInProgress()?Promise.resolve():this.placeRouter.syncInteractionContextIdsWithRouter()},t.prototype.isNavigationInProgress=function(){return this.placeRouter.navigationInProgress.value},t.prototype.notifyFinished=function(t){return this.contextRegistry.finish(t),this.isNavigationInProgress()?Promise.resolve():this.placeRouter.syncInteractionContextIdsWithRouter()},t}();t.ApiAdapter=n}(t.InteractionService||(t.InteractionService={}));var Oe=function(t){function e(e,n){var o=t.call(this)||this;return o.interactionService=e,o.tabConfig=n,o.animateFirstActivity=!0,o}return B(e,t),Object.defineProperty(e.prototype,"animationDuration",{get:function(){var t;return this.animateFirstActivity?(null===(t=this.tabConfig)||void 0===t?void 0:t.animationDuration)||"500ms":"0ms"},enumerable:!1,configurable:!0}),e.prototype.ngAfterViewInit=function(){this.interactionService.registerInplaceInteractionContext(this)},e.prototype.initialise=function(t,e){this.activityContainerComponent.initialise(t,e)},Object.defineProperty(e.prototype,"identifier",{get:function(){return this.activityContainerComponent.identifier},enumerable:!1,configurable:!0}),e.prototype.alert=function(t){return this.activityContainerComponent.alert(t)},e.prototype.cancelActiveActivity=function(){return this.activityContainerComponent.cancelActiveActivity()},e.prototype.confirm=function(t){return this.activityContainerComponent.confirm(t)},e.prototype.confirmOrReject=function(t){return this.activityContainerComponent.confirmOrReject(t)},e.prototype.confirmThen=function(t,e,n){return this.activityContainerComponent.confirmThen(t,e)},e.prototype.isActive=function(){return this.activityContainerComponent.isActive()},e.prototype.startActivity=function(t,e,n){return this.activityContainerComponent.startActivity(t,e,n)},e}(Y);Oe.decorators=[{type:n.Component,args:[{selector:"aup-in-place-interaction-context",template:'<mat-tab-group no-tab-header [selectedIndex]="isActive() ? 1 : 0" full-height-tabs [dynamicHeight]="false" [animationDuration]="animationDuration">\n <mat-tab>\n <ng-content></ng-content>\n </mat-tab>\n <mat-tab>\n <aup-activity-container #activityContainer [dynamicHeight]="false"></aup-activity-container>\n </mat-tab>\n</mat-tab-group>\n\n',styles:[":host{display:flex;flex-direction:column}mat-tab-group{flex:1}"]}]}],Oe.ctorParameters=function(){return[{type:t.InteractionService},{type:void 0,decorators:[{type:n.Inject,args:[s.MAT_TABS_CONFIG]},{type:n.Optional}]}]},Oe.propDecorators={activityContainerComponent:[{type:n.ViewChild,args:["activityContainer",{static:!0}]}],animateFirstActivity:[{type:n.Input}]};var Fe=function(t){function e(){var e=t.call(this)||this;return e.icon="mat:add",e.tabindex=0,e.clickCommand=I.Command.create((function(t){e.activityClass?e.startActivity(e.activityClass,e.activityData).catch((function(t){})):e.addCommand.withContext(t).execute()})),e}return B(e,t),Object.defineProperty(e.prototype,"active",{get:function(){return!!this.interactionContext&&this.interactionContext.isActive()},enumerable:!1,configurable:!0}),e.prototype.startActivity=function(t,e){return this.interactionContext.startActivity(t,e)},e.prototype.ngOnInit=function(){},e}(Y);Fe.decorators=[{type:n.Component,args:[{selector:"aup-add-item-interaction-context",template:'<aup-in-place-interaction-context [animateFirstActivity]="false">\n <a part="link" class="link" [pectinCommand]="clickCommand"><aup-icon [icon]="icon"></aup-icon> {{label}}</a>\n</aup-in-place-interaction-context>\n',styles:[":host{--def-link-background:var(--link-background,transparent);--def-link-background-hover:var(--link-background-hover,rgba(0,0,0,0.05));--def-link-border-radius:var(--link-border-radius,4px);--def-link-color:var(--link-color,currentColor);--def-link-color-hover:var(--link-color-hover,currentColor);--def-link-padding:var(--link-padding,calc(var(--aup-default-padding)/2));border-radius:var(--def-link-border-radius);box-sizing:border-box;display:flex;flex-direction:column;outline:none}:host:hover a.link{background-color:var(--def-link-background-hover);color:var(--def-link-color-hover)}a.link,aup-in-place-interaction-context{border-radius:var(--def-link-border-radius)}a.link{align-items:center;background:var(--def-link-background);color:var(--def-link-color);cursor:pointer;display:flex;flex-direction:row;padding:var(--def-link-padding);text-decoration:none}a.link mat-icon{margin-right:8px}"]}]}],Fe.ctorParameters=function(){return[]},Fe.propDecorators={label:[{type:n.Input}],icon:[{type:n.Input}],activityClass:[{type:n.Input}],activityData:[{type:n.Input}],addCommand:[{type:n.Input}],interactionContext:[{type:n.ViewChild,args:[Oe]}],active:[{type:n.HostBinding,args:["class.interaction-active"]}],tabindex:[{type:n.HostBinding,args:["tabindex"]}]},G([I.TrackExternal(),q("design:type",I.Command)],Fe.prototype,"addCommand",void 0);var Ee=function(t){function e(e,n,o){var i=t.call(this)||this;return i._element=e,i._overlay=n,i.outputPortal=new l.ComponentPortal(Oe),i.anchorX="start",i.anchorY="bottom",i.scrollContainers=o?[o]:[],i}return B(e,t),Object.defineProperty(e.prototype,"active",{get:function(){return this.isActive()},enumerable:!1,configurable:!0}),e.prototype.startActivity=function(t,e){var n=this,o=this._overlay.create({hasBackdrop:!1,panelClass:"aup-popup-interaction-panel",positionStrategy:this._overlay.position().flexibleConnectedTo(this._element).withPush(!0).withPositions(this.computePositions()).withGrowAfterOpen(!0).withScrollableContainers(this.scrollContainers)}),i=this.scrollContainers.map((function(t){return t.elementScrolled().subscribe((function(){o.updatePosition()}))})),r=o.attach(this.outputPortal);return this.interactionContext=r.instance,new Promise((function(r,a){setTimeout((function(){n.interactionContext.startActivity(t,e).then(r).catch(a).finally((function(){i.forEach((function(t){return t.unsubscribe()})),o.dispose()})),setTimeout((function(){o.updatePosition()}))}))}))},e.prototype.computePositions=function(){var t="start"===this.anchorX?"start":"end",e="top"===this.anchorY?"bottom":"top";return[{originX:this.anchorX,originY:this.anchorY,overlayX:t,overlayY:e}]},e.prototype.cancelActiveActivity=function(){return this.interactionContext.cancelActiveActivity()},e.prototype.isActive=function(){return this.interactionContext&&this.interactionContext.isActive()},e.prototype.ngOnInit=function(){},e}(Y);Ee.decorators=[{type:n.Component,args:[{selector:"aup-popup-interaction-context",template:"<ng-content></ng-content>\n",styles:[":host{display:inline}:host.interaction-active{background:rgba(0,0,0,.05)}"]}]}],Ee.ctorParameters=function(){return[{type:n.ElementRef},{type:T.Overlay},{type:T.CdkScrollable,decorators:[{type:n.Optional},{type:n.SkipSelf}]}]},Ee.propDecorators={active:[{type:n.HostBinding,args:["class.interaction-active"]}],anchorX:[{type:n.Input}],anchorY:[{type:n.Input}]};var ke=function(t){function e(){var e=t.call(this)||this;return e.activityDone=new n.EventEmitter,e.activityCancelled=new n.EventEmitter,e}return B(e,t),e.prototype.onEnter=function(t){t.preventDefault(),t.stopPropagation(),this.aupInteractionContextTriggerFor.isActive()?this.aupInteractionContextTriggerFor.cancelActiveActivity():this.startActivity()},e.prototype.onClick=function(t){t.preventDefault(),t.stopPropagation(),this.aupInteractionContextTriggerFor.isActive()?this.aupInteractionContextTriggerFor.cancelActiveActivity():this.startActivity()},e.prototype.startActivity=function(){var t=this;I.assert.isTruthy(this.aupInteractionContextTriggerFor),I.assert.isFalsey(this.aupInteractionContextTriggerFor.isActive()),I.assert.isTruthy(this.activityClass),this.aupInteractionContextTriggerFor.startActivity(this.activityClass,this.activityData).then((function(e){t.activityDone.emit(e)})).catch((function(e){t.activityCancelled.emit(e)}))},e.prototype.prepareActivityData=function(){return j.default.isFunction(this.activityDataFactory())?this.activityDataFactory():this.activityData},e}(I.GarbageCollector);ke.decorators=[{type:n.Directive,args:[{selector:"[aupInteractionContextTriggerFor]"}]}],ke.ctorParameters=function(){return[]},ke.propDecorators={aupInteractionContextTriggerFor:[{type:n.Input}],activityClass:[{type:n.Input}],activityData:[{type:n.Input}],activityDataFactory:[{type:n.Input}],activityDone:[{type:n.Output}],activityCancelled:[{type:n.Output}],onEnter:[{type:n.HostListener,args:["keyup.enter",["$event"]]}],onClick:[{type:n.HostListener,args:["click",["$event"]]}]};var Ve=function(t){function e(e){var n=t.call(this)||this;n.data=e,n.class="aup-input-activity";var o=new I.DirtyTrackingForm;return n.valueModel=o.valueModel(n.data.initialValue),n.valueModel.validateUsing(e.validators||[]),n.confirmCommand=I.Command.create((function(){if(n.valueModel.validate()){if(e.save)return Promise.resolve(e.save(n.valueModel,n.interactionContext)).then((function(){return n.done()}));n.done(n.valueModel.value)}})),n.cancelCommand=I.Command.create((function(){n.cancel()})),n}return B(e,t),e.prototype.onActivityReady=function(){this.valueModel.focusContext.requestFocus()},e}(be);Ve.decorators=[{type:n.Component,args:[{template:""}]}],Ve.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[ve]}]}]},Ve.propDecorators={class:[{type:n.HostBinding,args:["class"]}]};var _e=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e}(Ve);_e.decorators=[{type:n.Component,args:[{selector:"aup-string-input-activity",template:'\n <aup-string-input [valueModel]="valueModel"\n [label]="data.label"\n [placeholder]="data.placeholder"\n [command.enter]="confirmCommand"\n [command.escape]="cancelCommand"></aup-string-input>\n <aup-activity-actions align="end"\n [confirmCommand]="confirmCommand"\n [cancelCommand]="cancelCommand"\n [style]="data.buttonStyle"></aup-activity-actions>\n '}]}];var Le=function(t){function e(){var e=t.apply(this,$(arguments))||this;return e.defaultOptionLabelFormat=function(t){return e.data.optionLabel?t[e.data.optionLabel]:t},e}return B(e,t),Object.defineProperty(e.prototype,"optionLabelFormat",{get:function(){var t;return null!==(t=this.data.optionLabelFormat)&&void 0!==t?t:this.defaultOptionLabelFormat},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"options",{get:function(){var t;return(null===(t=this.data.optionsModel)||void 0===t?void 0:t.value)||this.data.options},enumerable:!1,configurable:!0}),e}(Ve);Le.decorators=[{type:n.Component,args:[{selector:"aup-select-input-activity",template:'\n <aup-select-input [valueModel]="valueModel"\n [label]="data.label"\n [placeholder]="data.placeholder"\n [command.enter]="confirmCommand"\n [command.escape]="cancelCommand"\n [options]="options"\n [optionLabelFormat]="optionLabelFormat"\n ></aup-select-input>\n <aup-activity-actions align="end"\n [confirmCommand]="confirmCommand"\n [cancelCommand]="cancelCommand"\n [style]="data.buttonStyle"\n ></aup-activity-actions>\n '}]}];var je,Ne=function(t,e){this.width=t,this.height=e},Ue=function(){function t(t,e){this.x=t,this.y=e}return t.from=function(e){return new t(e.x,e.y)},t.prototype.translate=function(e,n){return new t(this.x+e,this.y+n)},t}();t.Bounds=function(t){function e(e,n,o,i){var r=t.call(this,o,i)||this;return r.top=e,r.left=n,r.width=o,r.height=i,r}return B(e,t),e.prototype.relativePositionOf=function(t){return t instanceof MouseEvent?new Ue(t.clientX-this.left,t.clientY-this.top):new Ue(t.x-this.left,t.y-this.top)},e}(Ne),(je=t.Bounds||(t.Bounds={})).ofElement=function(t){var e=t.getBoundingClientRect();return new je(e.top,e.left,e.width,e.height)};var He=function(e){function n(n,o){var i=e.call(this)||this;return i.elementRef=n,i.ngZone=o,i._boundsModel=new I.MutableValueModel(new t.Bounds(0,0,0,0)),i}return B(n,e),n.prototype.ngAfterViewInit=function(){var t=this;this.updateBounds();var e=this.elementRef.nativeElement,n=new U.default((function(e,n){t.ngZone.run((function(){return t.updateBounds()}))}));n.observe(e),this.onDispose((function(){return n.disconnect()}))},Object.defineProperty(n.prototype,"boundsModel",{get:function(){return this._boundsModel.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"nativeElement",{get:function(){return this.elementRef.nativeElement},enumerable:!1,configurable:!0}),n.prototype.relativePositionOf=function(t){return this.bounds.relativePositionOf(t)},Object.defineProperty(n.prototype,"bounds",{get:function(){return this._boundsModel.value},enumerable:!1,configurable:!0}),n.prototype.updateBounds=function(){this._boundsModel.value=t.Bounds.ofElement(this.nativeElement)},n}(Y);He.decorators=[{type:n.Directive}],He.ctorParameters=function(){return[{type:n.ElementRef},{type:n.NgZone}]};var Be=function(){};Be.decorators=[{type:n.NgModule,args:[{imports:[e.CommonModule,d.MatButtonModule,D.MatDialogModule,s.MatTabsModule,l.PortalModule,A.RouterModule,h.MatIconModule,tt,S.FlexModule,S.GridModule,ye],declarations:[Se,Me,we,Ie,Re,Oe,Fe,Ce,Ee,_e,Le,Ve,ke,be],exports:[Se,Re,Oe,Fe,Ce,Ee,ke,_e,Le],entryComponents:[Se,Me,we,Ie],providers:[t.InteractionService]}]}];var Ge=new n.InjectionToken("PlaceAuthService");t.ParameterDefinition=function(){function t(t,e,n){this.propertyName=t,this.urlFormat=n,this.options=P.Opts.get(e),this.remember=this.options.getOptional("remember",!1),this.defaultValue=this.options.getOptional("defaultValue",null)}return Object.defineProperty(t.prototype,"name",{get:function(){return this.options.getOptional("as",this.propertyName)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRouteParameter",{get:function(){return!!this.urlFormat},enumerable:!1,configurable:!0}),t.prototype.getOptionValue=function(t){return this.options.getOptional(t,null)},t.prototype.sanitise=function(t,e,n,o,i){return W(this,void 0,void 0,(function(){var o;return z(this,(function(i){return this.isMissingFrom(e)&&!n.lastVisitIncluded(e.placeDefinition)?(o=n.getMostRecentVisitFor(e.placeDefinition),this.remember&&o&&(t=o.getParameter(this.name)),[2,this.isEmptyValue(t)?this.defaultValue:t]):[2,t]}))}))},t.prototype.isMissingFrom=function(t){return!t.hasParameter(this.name)},t}(),function(t){var e=function(t){function e(){var e=t.apply(this,$(arguments))||this;return e.isRouteId=!0,e.isArray=!1,e}return B(e,t),e.prototype.isEmptyValue=function(t){return j.default.isNil(t)},e.prototype.hasChanged=function(t,e){return t!==e},e}(t);t.RouteId=e;var n=function(t){function e(){var e=t.apply(this,$(arguments))||this;return e.isRouteId=!1,e.isArray=!1,e}return B(e,t),e.prototype.isEmptyValue=function(t){return j.default.isNil(t)},e.prototype.hasChanged=function(t,e){return t!==e},e}(t);t.ValueParameter=n;var o=function(t){function e(e,n,o){var i=t.call(this,e,n,o)||this;return i.isRouteId=!1,i.isArray=!0,i}return B(e,t),e.prototype.isEmptyValue=function(t){return j.default.isNil(t)||t.length<1},e.prototype.hasChanged=function(t,e){return!j.default.isEqual(t,e)},e}(t);t.ArrayParameter=o}(t.ParameterDefinition||(t.ParameterDefinition={}));var qe=function(){function t(t,e,n,o,i,r,a){this.component=t,this.path=e,this.authenticate=n,this.roles=o,this.data=i,this.routeParameters=r,this.children=a}return t.prototype.hasRouteId=function(){return!!this.getRouteIdParameterDef()},t.prototype.getRouteIdParameterDef=function(){return this.routeParameters.find((function(t){return t.isRouteId}))},t.prototype.getRouteParameterDefs=function(t){return void 0===t&&(t=!1),this.getVisitParameterDefs({includeRouteId:t,includeRouteParameters:!0})},t.prototype.getVisitParameterDefs=function(t){var e=P.Opts.get(t),n=!t||e.getOptional("includeRouteId",!1),o=!t||e.getOptional("includeRouteParameters",!1),i=!t||e.getOptional("includeNonRouteParameters",!1);return this.routeParameters.filter((function(t){return n&&t.isRouteId||o&&t.isRouteParameter&&!t.isRouteId||i&&!t.isRouteParameter}))},t.prototype.getPlaceData=function(t,e){return this.data?j.default.isNil(this.data[t])?e:this.data[t]:e},t.prototype.searchPlaceData=function(t,e){var n=this;if(this.data){var o=t.find((function(t){return!j.default.isNil(n.data[t])}));return o?this.data[o]:e}return e},t.prototype.getRouteIdFrom=function(t){var e=this.getRouteIdParameterDef();return e?t.getParameter(e.name):null},t.prototype.getFormattedRouteId=function(t){return t.hasRouteId()?this.getRouteIdParameterDef().urlFormat.format(t.getRouteId()):""},t.prototype.getFormattedRouteParameters=function(t,e){void 0===e&&(e=!1);var n={};return this.getVisitParameterDefs({includeRouteId:e,includeRouteParameters:!0}).forEach((function(e){var o=t.getParameter(e.name);e.isEmptyValue(o)||(e.isArray?(I.assert.isArray(o),n[e.name]=o.map((function(t){return e.urlFormat.format(t)}))):(I.assert.isFalsey(Array.isArray(o)),n[e.name]=e.urlFormat.format(o)))})),n},t.prototype.getNonRouteParameters=function(t){var e={};return this.getVisitParameterDefs({includeNonRouteParameters:!0}).forEach((function(n){var o=t.getParameter(n.name);n.isEmptyValue(o)||(e[n.name]=o)})),e},t.prototype.parseRouteParams=function(t){var e={};return this.getVisitParameterDefs({includeRouteId:!0,includeRouteParameters:!0,includeNonRouteParameters:!1}).forEach((function(n){if(t.has(n.name))if(n.isArray){var o=t.get(n.name).split(",").map((function(t){return t.trim()}));e[n.name]=o.map((function(t){return n.urlFormat.parse(t)}))}else{var i=t.get(n.name);n.isRouteId&&j.default.isEmpty(i)||(e[n.name]=n.urlFormat.parse(i))}})),e},t}();G([w.Memoize(),q("design:type",Function),q("design:paramtypes",[]),q("design:returntype",t.ParameterDefinition)],qe.prototype,"getRouteIdParameterDef",null),G([w.Memoize(),q("design:type",Function),q("design:paramtypes",[Object]),q("design:returntype",Array)],qe.prototype,"getRouteParameterDefs",null),G([w.Memoize(),q("design:type",Function),q("design:paramtypes",[Object]),q("design:returntype",Array)],qe.prototype,"getVisitParameterDefs",null);var We="PLACE_DEFINITION_OPTIONS",ze=Symbol("place:route:parameters");t.PlaceComponent=function(t){function e(){var e=t.call(this)||this;e.visitModel=new I.MutableValueModel,e._inVisitUpdate=new I.Guard,e._active=new I.MutableValueModel(!1);var n=I.Dsl.disposeWith(e),o=(n.chain,n.valueOf,n.before,n.when);n.after,n.observe,n.switchOn;return o(e._active).becomesTruthy((function(){return e.onPlaceReady()})),e}return B(e,t),e.prototype.initialiseVisit=function(t,e){var n=this;I.assert.isNil(this.visitModel.value);var o=I.Dsl.disposeWith(this).when;this.visitModel.value=t,I.DebugContext.getOrCreate(this.visitModel).tag(this.placeDefinition.component.name+".visitModel"),this.placeDefinition.getVisitParameterDefs().forEach((function(t){return n.installBinding(t)})),o(this.visitModel).changes((function(t,n){e(t,n)}),{unless:this._inVisitUpdate})},e.prototype.updateVisit=function(t){var e=this;I.assert.isTruthy(this.isInitialised()),I.assert.notNil(t),this._inVisitUpdate.whileTrue((function(){e.visitModel.value=t}))},e.prototype.isInitialised=function(){return!!this.visitModel.value},e.prototype.installBinding=function(t){var e=this[t.propertyName];I.DebugContext.tag(e,this.placeDefinition.component.name+"."+t.propertyName),this.registerDisposable(new I.Binding(this.visitModel,e,{toRight:function(e){return e.getParameter(t.name)},toLeft:function(e,n){return n.replace(t,e)}})).writeRight()},Object.defineProperty(e.prototype,"placeDefinition",{get:function(){return e.getDefinition(this.constructor)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childPlaces",{get:function(){return this.placeDefinition.children.map((function(t){return t.component}))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"active",{get:function(){return this._active.readonly},enumerable:!1,configurable:!0}),e.prototype._notifyActive=function(t){this._active.value=t},e.prototype.onPlaceReady=function(){},e}(Y),t.PlaceComponent.decorators=[{type:n.Directive}],t.PlaceComponent.ctorParameters=function(){return[]},G([k.Memoize(),q("design:type",qe),q("design:paramtypes",[])],t.PlaceComponent.prototype,"placeDefinition",null),function(t){function e(e){return I.lang.constructorChain(e).includes(t)}t.isPlaceComponentConstructor=e,t.getRouteParameters=function(t){return P.Klass.get(t).getMetadataList(ze)},t.getDefinition=function(t){if(t instanceof A.ActivatedRouteSnapshot){var n=t.component;if(!e(n))throw new Error("ActivatedRouteSnapshot component is not a PlaceComponent, got "+n);return Reflect.getMetadata(We,n)}return Reflect.getMetadata(We,t)},t.injectDefinition=function(t,e){Reflect.defineMetadata(We,e,t)}}(t.PlaceComponent||(t.PlaceComponent={}));var Ke=function(){function t(t,e){void 0===e&&(e={}),this.placeDefinition=t,this.visitParameters=e}return t.prototype.getRouteId=function(){return this.placeDefinition.getRouteIdFrom(this)},t.prototype.hasRouteId=function(){return!M.isNil(this.getRouteId())},t.prototype.getParameter=function(t){return this.visitParameters[t]},t.prototype.hasParameter=function(t){return Object.keys(this.visitParameters).includes(t)},t.prototype.replace=function(e,n){var o;return new t(this.placeDefinition,Object.assign(Object.assign({},this.visitParameters),((o={})[e.name]=n,o)))},t.prototype.mergeRouteParameters=function(e){var n=this,o=Object.keys(e),i={};return this.placeDefinition.getVisitParameterDefs().forEach((function(t){if(t.isRouteId||t.isRouteParameter)o.includes(t.name)&&(i[t.name]=e[t.name]);else{var r=n.getParameter(t.name);n.hasParameter(t.name)&&(i[t.name]=r)}})),new t(this.placeDefinition,i)},t.prototype.hasRoutingChangedFrom=function(t){var e=t.placeDefinition===this.placeDefinition,n=M.isEqual(this.placeDefinition.getFormattedRouteParameters(this,!0),this.placeDefinition.getFormattedRouteParameters(t,!0));return!e||!n},t.prototype.hasChangedFrom=function(t){return!M.isEqual(this.placeDefinition.getNonRouteParameters(this),this.placeDefinition.getNonRouteParameters(t))||this.hasRoutingChangedFrom(t)},t.prototype.toDebugString=function(){var t=this;return Object.keys(this.visitParameters).map((function(e){return e+"="+t.visitParameters[e]})).join(",")},t}(),$e=new n.InjectionToken("AUP_PLACE_CONFIG"),Xe=function(){function t(t,e,n){this.component=t,this.navigationSession=e,this.isPrimaryComponent=n}return Object.defineProperty(t.prototype,"routerInteractionAdapter",{get:function(){return this.navigationSession.interactionServiceAdapter},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"urlService",{get:function(){return this.navigationSession.urlService},enumerable:!1,configurable:!0}),t.prototype.canDeactivate=function(t,e){return W(this,void 0,void 0,(function(){return z(this,(function(n){return this.canDeactivatePromise||(this.canDeactivatePromise=this.canDeactivateComponent(t,e)),[2,this.canDeactivatePromise]}))}))},t.prototype.canDeactivateComponent=function(t,e){return W(this,void 0,void 0,(function(){var t,n;return z(this,(function(o){switch(o.label){case 0:return this.navigationSession.isPopState?this.isPrimaryComponent&&this.routerInteractionAdapter.isModalActive()?(t=this.urlService.getActiveInteractionIdsFromUrl(e.url),n=this.routerInteractionAdapter.getActiveInteractionContextIds(),M.isEqual(n,t)?[3,2]:[4,this.routerInteractionAdapter.cancelCurrentModalInteraction()]):[3,3]:[3,5];case 1:return o.sent(),[2,!1];case 2:return[3,5];case 3:return this.routerInteractionAdapter.isComponentInteracting(this.component)?[4,this.routerInteractionAdapter.cancelComponentInteraction(this.component)]:[3,5];case 4:return o.sent(),[2,!1];case 5:if(this.isNotJustAChangeInRouteId(e)){if(this.component.canDeactivate)return[2,this.component.canDeactivate(this.navigationSession.canDeactivateInteractionContext)];if(this.routerInteractionAdapter.isComponentInteracting(this.component))return console.warn("Route changed while component has active interaction, cancelling navigation"),[2,!1]}return[2,!0]}}))}))},t.prototype.isNotJustAChangeInRouteId=function(t){return!t.includesPathOf(this.component.placeDefinition)},t}(),Ye=function(t){function e(e,n){var o=t.call(this)||this;return o.context=e,o.startingUrl=n,o.debugPropertyKeys=[],o._visits=new Map,o.componentDeactivationHandlers=new Map,o._interactionContext=o.context.routerInteractionAdapter.createExclusiveInteractionContext(),o.onDispose((function(){o._interactionContext&&o._interactionContext.dispose()})),o}return B(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return this.constructor.name},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"urlService",{get:function(){return this.context.urlService},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"interactionServiceAdapter",{get:function(){return this.context.routerInteractionAdapter},enumerable:!1,configurable:!0}),e.prototype.storeVisit=function(t){this._visits.set(t.placeDefinition,t)},e.prototype.getVisitFor=function(t){return this._visits.get(t)},Object.defineProperty(e.prototype,"canDeactivateInteractionContext",{get:function(){return this._interactionContext},enumerable:!1,configurable:!0}),e.prototype.notifyActive=function(){},e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onUrlChange=function(t){this.canDeactivateInteractionContext&&this.canDeactivateInteractionContext.isActive()&&this.cancelCanDeactivateInteraction(t)},e.prototype.onPopState=function(t){return this.illegalTransition(t)},e.prototype.onRouterCancelled=function(t){return this.illegalTransition(t)},e.prototype.onRouterError=function(t){return this.illegalTransition(t)},e.prototype.onRouterEnd=function(t){return this.illegalTransition(t)},e.prototype.getVisits=function(){return Array.from(this._visits.values())},e.prototype.illegalTransition=function(t){return I.lang.illegalState(t.toString()+" not supported by "+this.toString())},e.prototype.currentRouterUrl=function(){return this.urlService.getCurrentRouterUrl()},e.prototype.resetBrowserLocation=function(t,e){void 0===e&&(e={replaceCurrent:!1}),this.urlService.resetBrowserLocation(t,e)},e.prototype.repairBrowserHistoryAndUrlAfterGuardCancellation=function(t,e){I.Logger.get(this).info("WORK-AROUND: Updating browser location after pop state - see angular issue #13586"),console.log("replacing "+this.urlService.getCurrentLocationUrlSnapshot().url+" with "+t),this.urlService.resetBrowserLocation(t,{replaceCurrent:!0}),console.log("pushing "+e+" back onto the history."),this.urlService.resetBrowserLocation(e,{replaceCurrent:!1})},e.prototype.ignore=function(t,e){e=e?" -> "+e:"",I.Logger.get(this).info("Ignoring router event"+e+": "+t.constructor.name+" -> "+t.url+" :: "+this.toString())},e.prototype.toString=function(){return this.constructor.name+"("+this.debugState()+")"},e.prototype.debugState=function(t){var e=this;return(t||this.debugPropertyKeys).map((function(t){return t+": "+e[t]})).join(", ")},e.prototype.canDeactivatePlace=function(t,e,n){return W(this,void 0,void 0,(function(){var o,i;return z(this,(function(r){return(o=this.componentDeactivationHandlers.get(t))||(i=0===this.componentDeactivationHandlers.size,o=new Xe(t,this,i),this.componentDeactivationHandlers.set(t,o)),[2,o.canDeactivate(e,n).then((function(t){return t})).catch((function(t){throw t}))]}))}))},e.prototype.cancelCanDeactivateInteraction=function(t){I.Logger.get(this).info("back button pressed during navigation session interaction promise");var e=this.detachCanDeactivateInteractionContext();I.Logger.get(this).info("cancelling current navigation activity.."),e.cancelActiveActivity().then((function(){e.dispose()})),this.handleCanDeactivateCancelledEventScenario(t)},e.prototype.reinstateUrlAfterAngularChangedItOnCancellation=function(t){this.resetBrowserLocation(t,{replaceCurrent:!0})},e.prototype.detachCanDeactivateInteractionContext=function(){var t=this._interactionContext;return this._interactionContext=null,t},e}(I.GarbageCollector),Je=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e.prototype.handleCanDeactivateCancelledEventScenario=function(t){P.lang.illegalState("onCanDeactivateInteractionCancelled not supported for event clean up states")},e}(Ye),Ze=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.locationChangeTriggerUrl=o,i.isPopState=!1,i.firstCancelHandled=!1,i.popStateHandled=!1,i.debugPropertyKeys=["idle","startingUrl","poppedHistoryUrl","locationChangeTriggerUrl","popStateEventUrl","firstCancelHandled","popStateHandled"],i}return B(e,t),e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.repairBrowserHistoryAndUrlAfterGuardCancellation(this.locationChangeTriggerUrl,this.startingUrl),this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.ignore(t)},e.prototype.canDeactivatePlace=function(t,e,n){return W(this,void 0,void 0,(function(){return z(this,(function(t){return[2,!1]}))}))},e}(Je),Qe=function(t){function e(e,n){var o=t.call(this,e,n)||this;return o.isPopState=!0,o.debugPropertyKeys=["startingUrl","poppedHistoryUrl"],o.finished=I.Deferred.defer(),o}return B(e,t),e.prototype.onPopState=function(t){this.gotPopState=!0},e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.ignore(t)},e.prototype.onUrlChange=function(t){},e.prototype.finishUp=function(){this.context.finishRoutingSession(),this.finished.resolve(!0)},e.prototype.onRouterEnd=function(t){this.gotPopState&&this.finishUp()},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){I.lang.illegalState("onCanDeactivateInteractionCancelled not supported for activity context synchronisation since we should never leave a place")},Object.defineProperty(e.prototype,"finishedPromise",{get:function(){return this.finished.promise},enumerable:!1,configurable:!0}),e}(Ye),tn=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.wasTriggeredByPopState=o,i.isPopState=!1,i}return B(e,t),e.prototype.notifyActive=function(){var t=this;setTimeout((function(){t.syncInteractionIdsWithRouter()}))},e.prototype.onRouterEnd=function(t){this.context.finishRoutingSession()},e.prototype.onRouterCancelled=function(t){this.context.finishRoutingSession()},e.prototype.syncInteractionIdsWithRouter=function(){var t=this.interactionServiceAdapter.getActiveInteractionContextIds(),e=this.urlService.getCurrentLocationUrlSnapshot().getInteractionIds();if(j.default.isEqual(t,e))this.context.finishRoutingSession();else if(t.length>e.length){var n=t.length>e.length&&e.length<1;this.addActivityContextToRoute(t,n)}else this.removeActivityContextFromRoute(t)},e.prototype.addActivityContextToRoute=function(t,e){var n=this,o=this.urlService.getCurrentRouterSnapshot().updateInteractionIds(t);this.context.navigateByUrl(o,{replaceUrl:!e}).then((function(e){n.urlService.getCurrentLocationUrlSnapshot().hasInteractionIds(t)||P.lang.illegalState("Expected url to be "+o.url+" but was "+n.urlService.getCurrentLocationUrl())}))},e.prototype.removeActivityContextFromRoute=function(t){var e=this.urlService.getCurrentRouterSnapshot().updateInteractionIds(t);if(t.length<1)if(this.wasTriggeredByPopState);else{var n=new Qe(this.context,this.urlService.getCurrentRouterUrl());this.context.transitionTo(n),this.urlService.back()}else this.context.navigateByUrl(e,{replaceUrl:!this.wasTriggeredByPopState})},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){P.lang.methodNotSupported()},e}(Ye),en=function(t){function e(){var e=t.apply(this,$(arguments))||this;return e.isPopState=!1,e}return B(e,t),e.prototype.onRouterCancelled=function(t){this.context.finishRoutingSession()},e.prototype.onRouterError=function(t){this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.context.routerInteractionAdapter.isActive()?this.context.transitionTo(new tn(this.context,this.startingUrl,!1)):this.context.finishRoutingSession(this.getVisits())},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.context.transitionTo(new Ze(this.context,this.startingUrl,t))},e}(Ye),nn=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.poppedHistoryUrl=o,i.isPopState=!0,i.debugPropertyKeys=["startingUrl","poppedHistoryUrl"],i}return B(e,t),e.prototype.repairBrowserHistoryAndUrlAfterGuardCancellation=function(){t.prototype.repairBrowserHistoryAndUrlAfterGuardCancellation.call(this,this.poppedHistoryUrl,this.startingUrl)},e}(Ye),on=function(t){function e(e,n,o){return t.call(this,e,n,o)||this}return B(e,t),e.prototype.onRouterCancelled=function(t){this.repairBrowserHistoryAndUrlAfterGuardCancellation(),this.context.transitionTo(new tn(this.context,this.poppedHistoryUrl,!1))},e.prototype.onRouterEnd=function(t){this.context.finishRoutingSession()},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.illegalTransition("Leaving interaction after pop-state should't block so should never see a back button click")},e}(nn),rn=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.clickedLinkUrl=o,i.isPopState=!1,i.clickedLinkMatchedBackButtonUrl=!1,i.debugPropertyKeys=["idle","startingUrl","clickedLinkUrl","firstCancelEventUrl","clickedLinkMatchedBackButtonUrl","popStateEventUrl"],i}return B(e,t),e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){t.url===this.clickedLinkUrl?this.context.transitionTo(new cn(this.context,this.startingUrl,this.clickedLinkUrl)):this.context.transitionTo(new ln(this.context,this.startingUrl,this.clickedLinkUrl))},e.prototype.canDeactivatePlace=function(t,e,n){return W(this,void 0,void 0,(function(){return z(this,(function(t){return[2,!1]}))}))},e}(Je);G([I.Trace(),q("design:type",Function),q("design:paramtypes",[A.NavigationStart]),q("design:returntype",void 0)],rn.prototype,"onRouterStarted",null),G([I.Trace(),q("design:type",Function),q("design:paramtypes",[A.NavigationCancel]),q("design:returntype",void 0)],rn.prototype,"onRouterCancelled",null);var an,sn,cn=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.clickedLinkUrl=o,i.isPopState=!1,i.debugPropertyKeys=["idle","startingUrl","clickedLinkUrl","popStateEventUrl"],i}return B(e,t),e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.popStateEventUrl=t.url,this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.popStateEventUrl&&this.finaliseRouting()},e.prototype.finaliseRouting=function(){return this.repairBrowserHistoryAndUrlAfterGuardCancellation(this.clickedLinkUrl,this.startingUrl),this.context.finishRoutingSession()},e.prototype.canDeactivatePlace=function(t,e,n){return W(this,void 0,void 0,(function(){return z(this,(function(t){return[2,!1]}))}))},e}(Je),ln=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.clickedLinkUrl=o,i.isPopState=!1,i.debugPropertyKeys=["idle","startingUrl","clickedLinkUrl","popStateEventUrl"],i}return B(e,t),e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.popStateEventUrl=t.url,this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.popStateEventUrl&&this.finaliseRouting()},e.prototype.finaliseRouting=function(){return this.repairBrowserHistoryAndUrlAfterGuardCancellation(this.clickedLinkUrl,this.startingUrl),this.context.finishRoutingSession()},e.prototype.canDeactivatePlace=function(t,e,n){return W(this,void 0,void 0,(function(){return z(this,(function(t){return[2,!1]}))}))},e}(Je),un=function(t){function e(){var e=t.apply(this,$(arguments))||this;return e.isPopState=!1,e.debugPropertyKeys=["startingUrl","urlAfterRedirects"],e}return B(e,t),e.prototype.onRouterCancelled=function(t){},e.prototype.onRouterError=function(t){this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.urlAfterRedirects=t.urlAfterRedirects,this.context.finishRoutingSession(this.getVisits())},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.context.transitionTo(new rn(this.context,this.startingUrl,t))},e}(Ye);an=t.NavigationContext||(t.NavigationContext={}),sn=function(t,e,n,o,i){this.urlService=t,this.routerInteractionAdapter=e,this.navigateByUrl=n,this.transitionTo=o,this.finishRoutingSession=i},an.Impl=sn;var pn,dn,fn,mn=function(t){function e(e,n,o,i){var r=t.call(this,e,n)||this;return r.locationChangeTriggerUrl=o,r.poppedHistoryUrl=i,r.isPopState=!1,r.firstCancelHandled=!1,r.popStateHandled=!1,r.debugPropertyKeys=["idle","startingUrl","poppedHistoryUrl","locationChangeTriggerUrl","popStateEventUrl","firstCancelHandled","popStateHandled"],r}return B(e,t),e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){if(this.firstCancelHandled){if(this.popStateHandled){var e=t.url;return this.repairBrowserHistoryAndUrlAfterGuardCancellation(e,this.parentPageUrl),this.resetBrowserLocation(this.startingUrl,{replaceCurrent:!1}),this.context.finishRoutingSession()}}else this.firstCancelHandled=!0,this.parentPageUrl=t.url,this.ignore(t)},e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.popStateHandled=!0,this.popStateEventUrl=t.url,this.ignore(t)},e.prototype.canDeactivatePlace=function(t,e,n){return W(this,void 0,void 0,(function(){return z(this,(function(t){return[2,!1]}))}))},e}(Je),hn=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e.prototype.onRouterCancelled=function(t){this.repairBrowserHistoryAndUrlAfterGuardCancellation(),this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.context.finishRoutingSession(this.getVisits())},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.context.transitionTo(new mn(this.context,this.startingUrl,t,this.poppedHistoryUrl))},e}(nn);t.PlaceHistory=function(){function t(){this._archive=new Map,this.placeHistoryDepth=4}return t.prototype.notifyNavigationStarted=function(){this._activeVisits&&(this.archive(this._activeVisits.visits),this._previousVisits=this._activeVisits)},t.prototype.notifyNavigationFinished=function(e){this._activeVisits=new t.VisitRecord(e)},t.prototype.updateVisit=function(t){I.assert.isTruthy(this._activeVisits),this._activeVisits.update(t)},t.prototype.lastVisitIncluded=function(t){var e;return!!(null===(e=this._previousVisits)||void 0===e?void 0:e.getVisitFor(t))},t.prototype.getMostRecentVisitFor=function(t){return j.default.first(this.getHistory(t))},t.prototype.getHistory=function(t){var e=this._archive.get(t);return e||(e=[],this.setHistory(t,e)),e},t.prototype.setHistory=function(t,e){this._archive.set(t,e)},t.prototype.archive=function(t){var e=this;t.forEach((function(t){var n=e.getHistory(t.placeDefinition),o=j.default.first(n);o&&!t.hasChangedFrom(o)||(n.unshift(t),e.setHistory(t.placeDefinition,n.slice(0,e.placeHistoryDepth)))}))},t}(),t.PlaceHistory.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t.PlaceHistory},token:t.PlaceHistory,providedIn:"root"}),t.PlaceHistory.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.PlaceHistory.ctorParameters=function(){return[]},pn=t.PlaceHistory||(t.PlaceHistory={}),dn=function(){function t(t){this.visits=t}return t.prototype.update=function(t){this.visits=this.visits.filter((function(e){return e.placeDefinition!==t.placeDefinition})).concat(t)},t.prototype.getVisitFor=function(t){return this.visits.find((function(e){return e.placeDefinition===t}))},t}(),pn.VisitRecord=dn,t.UrlSnapshot=function(){function t(t,e){this.urlSerializer=t,this.url=e,this.urlTree=t.parse(e)}return t.prototype.updateVisitSegments=function(e){var n=this.urlSerializer.parse(this.url),o=$(this.getPrimarySegments(n)),i=this.getSegmentsFor(e),r=o.findIndex((function(t){return t.path===i[0].path}));return o.splice.apply(o,$([r,i.length],i)),n.root.children.primary.segments=o,new t(this.urlSerializer,n.toString())},t.prototype.getPrimarySegments=function(t){return this.urlTree.root.children.primary.segments},t.prototype.getSegmentsFor=function(t){return t.placeDefinition.hasRouteId()?[new A.UrlSegment(t.placeDefinition.path,t.placeDefinition.getFormattedRouteParameters(t)),new A.UrlSegment(t.placeDefinition.getFormattedRouteId(t),{})]:[new A.UrlSegment(t.placeDefinition.path,t.placeDefinition.getFormattedRouteParameters(t))]},t.prototype.includesPathOf=function(t){return this.getPrimarySegments(this.urlTree).find((function(e){return e.path===t.path}))},t.prototype.getInteractionIds=function(){var e=this.urlTree.queryParams[t.INTERACTION_QUERY_PARAM];return e?t.parseInteractionIds(e):[]},t.prototype.hasInteractions=function(){return this.getInteractionIds().length>0},t.prototype.hasInteractionIds=function(t){return j.default.isEqual(this.getInteractionIds(),t)},t.prototype.updateInteractionIds=function(e){if(0===e.length)return this.removeInteractionIds();var n=this.urlSerializer.parse(this.url);return n.queryParams[t.INTERACTION_QUERY_PARAM]=t.createPathIdFor(e),new t(this.urlSerializer,n.toString())},t.prototype.removeInteractionIds=function(){var e=this.urlSerializer.parse(this.url);return e.queryParams&&e.queryParams[t.INTERACTION_QUERY_PARAM]&&(e.queryParams={}),new t(this.urlSerializer,e.toString())},t.prototype.toString=function(){return"UrlSnapshot("+this.url+")"},t}(),(fn=t.UrlSnapshot||(t.UrlSnapshot={})).INTERACTION_QUERY_PARAM="aup-interactions",fn.INTERACTION_ID_SEPARATOR="--",fn.parseInteractionIds=function(t){return t.split(fn.INTERACTION_ID_SEPARATOR)},fn.createPathIdFor=function(t){return t.join(fn.INTERACTION_ID_SEPARATOR)};var gn=function(){function e(t,e,n){this.angularRouter=t,this.angularLocation=e,this.urlSerializer=n}return e.prototype.parseUrl=function(e){return new t.UrlSnapshot(this.urlSerializer,e)},e.prototype.createUrlSnapshot=function(){for(var t=this,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var o=[];return e.forEach((function(e){o.push(t.parseUrl(""+e.placeDefinition.path).updateVisitSegments(e).url)})),this.parseUrl(o.join(""))},e.prototype.getCurrentRouterUrl=function(){return this.angularRouter.routerState?this.angularRouter.routerState.snapshot.url:null},e.prototype.getCurrentLocationUrl=function(){return this.angularLocation.path()},e.prototype.getCurrentLocationUrlSnapshot=function(){return this.parseUrl(this.getCurrentLocationUrl())},e.prototype.getCurrentRouterSnapshot=function(){return this.parseUrl(this.getCurrentRouterUrl())},e.prototype.getActiveInteractionIdsFromUrl=function(t){return this.parseUrl(t).getInteractionIds()},e.prototype.hasActiveInteractions=function(t){return this.getActiveInteractionIdsFromUrl(t).length>0},e.prototype.resetBrowserLocation=function(t,e){e.replaceCurrent?this.angularLocation.replaceState(t):this.angularLocation.go(t)},e.prototype.back=function(){this.angularLocation.back()},e}();gn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new gn(n.ɵɵinject(A.Router),n.ɵɵinject(e.Location),n.ɵɵinject(A.UrlSerializer))},token:gn,providedIn:"root"}),gn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],gn.ctorParameters=function(){return[{type:A.Router},{type:e.Location},{type:A.UrlSerializer}]};var yn=function(e){function n(n,o,i,r,a){var s=e.call(this)||this;s.angularRouter=n,s.angularLocation=o,s.interactionService=i,s.urlService=r,s.placeHistory=a,s.navigationSessionModel=new I.MutableValueModel,s._activeVisits=new I.MutableListModel,s.sessionFinishedJobs=[],window.Cypress&&(window["aup.PlaceRouter"]=s),s.routerInteractionAdapter=i.registerPlaceRouter(s),s.navigationContext=new t.NavigationContext.Impl(s.urlService,s.routerInteractionAdapter,(function(t,e){return s.navigateByUrl(t,e)}),(function(t){s.transitionTo(t)}),(function(t){s.routingSessionFinished(t)}));var c=I.Dsl.disposeWith(s),l=c.chain;c.valueOf,c.before,c.when,c.after,c.observe,c.switchOn;s.navigationInProgress=l(s.navigationSessionModel).isNotNil();var u=l(s.interactionService.active).map((function(t){return t?"IdleDuringInteraction":"Idle"}));return s.navigationSessionName=l(s.navigationSessionModel).pluck("name").otherwise(u),I.DebugContext.tag(s._activeVisits,"PlaceRouter.activeVisits"),s.activeVisitsByPlaceDefinition=l(s._activeVisits).indexBy("placeDefinition"),n.events.subscribe((function(t){t instanceof A.NavigationStart&&("popstate"===t.navigationTrigger?s.onPopState(t):s.onRouterStarted(t)),t instanceof A.NavigationEnd&&s.onRouterEnd(t),t instanceof A.NavigationError&&s.onRouterError(t),t instanceof A.NavigationCancel&&s.onRouterCancelled(t)})),o.onUrlChange((function(t){return s.onUrlChanged(t)})),s}return B(n,e),Object.defineProperty(n.prototype,"navigationSession",{get:function(){return this.navigationSessionModel.value},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"currentSession",{get:function(){return this.navigationSessionModel.value},enumerable:!1,configurable:!0}),n.prototype.isNavigating=function(){return this.navigationInProgress.value},n.prototype.onPopState=function(t){if(I.assert.isTruthy("popstate"===t.navigationTrigger),this.currentSession)this.currentSession.onPopState(t);else{var e=t.url,n=this.urlService.getCurrentRouterUrl(),o=this.interactionService.isActive()?new on(this.navigationContext,n,e):new hn(this.navigationContext,n,e);this.transitionTo(o)}},n.prototype.onRouterStarted=function(t){I.assert.isFalsey("popstate"===t.navigationTrigger);this.interactionService.isActive();this.currentSession?this.currentSession.onRouterStarted(t):this.transitionTo(this.createNavigationSession(this.urlService.getCurrentRouterUrl()))},n.prototype.onUrlChanged=function(t){this.currentSession?this.currentSession.onUrlChange(t):console.log("FYI: url changed without a navigation session in progress")},n.prototype.onRouterCancelled=function(t){this.currentSession.onRouterCancelled(t)},n.prototype.onRouterError=function(t){this.currentSession.onRouterError(t)},n.prototype.onRouterEnd=function(t){this.currentSession.onRouterEnd(t)},n.prototype.navigate=function(t,e){var n=this;return this.doNavigation(t,(function(o){return W(n,void 0,void 0,(function(){var n;return z(this,(function(o){switch(o.label){case 0:return n=$([t.placeDefinition.path],this.createRouteParameters(t)),[4,this.angularRouter.navigate(n,{relativeTo:e?e.relativeTo:null})];case 1:return o.sent(),[2]}}))}))}))},n.prototype.doNavigation=function(t,e){return W(this,void 0,void 0,(function(){var n;return z(this,(function(o){switch(o.label){case 0:this.navigationInProgress.value&&I.lang.illegalState("Navigation already in progress"),(n=this.createNavigationSession(this.urlService.getCurrentRouterUrl())).storeVisit(t),this.transitionTo(n),o.label=1;case 1:return o.trys.push([1,,3,4]),[4,e(this.angularRouter)];case 2:return o.sent(),[3,4];case 3:return!this.angularRouter.getCurrentNavigation()&&this.currentSession&&this.currentSession.onRouterEnd(new A.NavigationEnd(-1,"","")),[7];case 4:return[2]}}))}))},n.prototype.navigateByUrl=function(t,e){return this.angularRouter.navigateByUrl(t.urlTree,e)},Object.defineProperty(n.prototype,"activeVisits",{get:function(){return this._activeVisits.readonly},enumerable:!1,configurable:!0}),n.prototype.pushVisitChangesToRoute=function(t,e){return W(this,void 0,void 0,(function(){var n=this;return z(this,(function(o){return this.placeHistory.updateVisit(e),e.hasRoutingChangedFrom(t)?[2,this.doNavigation(e,(function(t){var o=n.urlService.parseUrl(n.angularRouter.routerState.snapshot.url).updateVisitSegments(e);return n.navigateByUrl(o)}))]:[2]}))}))},n.prototype.createNavigationSession=function(t){return this.interactionService.isActive()?new en(this.navigationContext,t):new un(this.navigationContext,t)},n.prototype.transitionTo=function(t){var e=this.navigationSessionModel.value;e||this.placeHistory.notifyNavigationStarted(),I.assert.isTruthy(t!==e),I.Logger.get(this).info("### Router State Transition: "+(e?e.toString():"null")+" -> "+t.toString()),this.navigationSessionModel.value=t,e&&e.dispose(),t.notifyActive()},n.prototype.routingSessionFinished=function(t){t&&t.length>0&&(I.assert.isTruthy(this.navigationInProgress.value),this.placeHistory.notifyNavigationFinished(t),this._activeVisits.value=t);var e=this.currentSession;e.dispose(),this.navigationSessionModel.value=null,console.log("### Router Session Finished (was "+e.toString()+")"),this.sessionFinishedJobs.forEach((function(t){return t()})),this.sessionFinishedJobs=[]},n.prototype.runAfterRoutingSessionFinishes=function(t){I.assert.isTruthy(this.navigationInProgress),this.sessionFinishedJobs.push(t)},n.prototype.syncInteractionContextIdsWithRouter=function(){var t=this;if(this.navigationSession){this.navigationSession;return new Promise((function(e,n){t.runAfterRoutingSessionFinishes((function(){t.runAfterRoutingSessionFinishes(e);var n=new tn(t.navigationContext,t.urlService.getCurrentRouterUrl(),!1);t.transitionTo(n)}))}))}return new Promise((function(e,n){t.runAfterRoutingSessionFinishes(e);var o=new tn(t.navigationContext,t.urlService.getCurrentRouterUrl(),!1);t.transitionTo(o)}))},n.prototype.createRouteParameters=function(t){var e=t.placeDefinition;return t.hasRouteId()?[e.getFormattedRouteId(t),e.getFormattedRouteParameters(t)]:[e.getFormattedRouteParameters(t)]},n}(I.GarbageCollector);yn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new yn(n.ɵɵinject(A.Router),n.ɵɵinject(e.Location),n.ɵɵinject(t.InteractionService),n.ɵɵinject(gn),n.ɵɵinject(t.PlaceHistory))},token:yn,providedIn:"root"}),yn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],yn.ctorParameters=function(){return[{type:A.Router},{type:e.Location},{type:t.InteractionService},{type:gn},{type:t.PlaceHistory}]};var vn=_.style({position:"absolute",top:"0",left:"0",bottom:"0",right:"0"}),bn=[_.query(":enter, :leave",vn,{optional:!0}),_.group([_.query(":enter",[_.style({transform:"translateX(-100%)"}),_.animate("{{duration}} ease-out",_.style({transform:"translateX(0%)"}))],{optional:!0}),_.query(":leave",[_.style({transform:"translateX(0%)"}),_.animate("{{duration}} ease-out",_.style({transform:"translateX(100%)"}))],{optional:!0})])],Cn=[_.query(":enter, :leave",vn,{optional:!0}),_.group([_.query(":enter",[_.style({transform:"translateX(100%)",minHeight:"1px"}),_.animate("{{duration}} ease-out",_.style({transform:"translateX(0%)"}))],{optional:!0}),_.query(":leave",[_.style({transform:"translateX(0%)"}),_.animate("{{duration}} ease-out",_.style({transform:"translateX(-100%)",minHeight:"1px"}))],{optional:!0})])];function In(t){return _.trigger("routeAnimations",[_.transition(":increment",Cn,{params:{duration:t}}),_.transition(":decrement",bn,{params:{duration:t}})])}var wn=In("0.3s"),Mn=function(t){function e(e,o,i,r){var a=t.call(this)||this;a.router=e,a.placeRouter=o,a.placeConfig=i,a.placeChanged=new n.EventEmitter,a.outletActivated=new I.MutableValueModel(!1),a._activatedRouteModel=new I.MutableValueModel,a._activePlaceModel=new I.MutableValueModel,a.initialPlaceIndex=null,a._isPushingVisitToRoute=new I.MutableValueModel(!1),a.isVeryFirstLoad=!0;var s=I.Dsl.disposeWith(a),c=s.chain,l=s.valueOf,u=(s.before,s.when);s.after,s.observe,s.switchOn;a.parentOutletModel=new I.MutableValueModel(r);var p=c(a.parentOutletModel).pullValueModel((function(t){return t.activePlaceModel})).pluck("placeDefinition").pluckList("children").pluck("component"),d=c(a.activePlaceModel).map((function(t){return t.constructor}));return a.placesInAnimationOrder=c(a.customPlaceAnimationOrderModel).otherwise(p),a.activePlaceAnimationPosition=a.placesInAnimationOrder.reduce((function(t){var e=0;return d.value&&(e=t.indexOf(d.value),M.isNil(a.initialPlaceIndex)&&(a.initialPlaceIndex=e)),M.isNil(a.initialPlaceIndex)?0:e-a.initialPlaceIndex}),{dependsOn:d}),a.animationSupported=a.placesInAnimationOrder.count().isGreaterThan(0),a.animationEnabled=l.all(a.animateModel,a.animationSupported).areTruthy(),a._activePlaceDefinition=c(a._activePlaceModel).pluck("placeDefinition"),a.routerVisitModel=a._activePlaceDefinition.findIn(c(o.activeVisitsByPlaceDefinition)),a.navigationInProgress=c(a.placeRouter.navigationInProgress),u(a.navigationInProgress).becomesFalsey((function(){a.checkStateAndInitialise()})),u(a.outletActivated).becomesTruthy((function(){a.checkStateAndInitialise()})),c(a._activePlaceModel).postponeWhile(a.navigationInProgress).subscribe((function(t){return a.placeChanged.emit(t)})),a}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.getAnimationOrder=function(){return this.activePlaceAnimationPosition.value},Object.defineProperty(e.prototype,"animationDuration",{get:function(){return this.placeConfig&&this.placeConfig.animationDuration?this.placeConfig.animationDuration:"500ms"},enumerable:!1,configurable:!0}),e.prototype.navigate=function(t){this.placeRouter.navigate(t,{relativeTo:this.parentOutlet?this.parentOutlet.activatedRouteModel.value:null})},Object.defineProperty(e.prototype,"parentOutlet",{get:function(){return this.parentOutletModel.value},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activePlaceModel",{get:function(){return this._activePlaceModel.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activatedRouteModel",{get:function(){return this._activatedRouteModel.readonly},enumerable:!1,configurable:!0}),e.prototype.onOutletActivated=function(t,e){this._activatedRouteModel.value=t.activatedRoute,this._activePlaceModel.value=e,this.validateAnimationState(e),this.outletActivated.value=!0,this.checkStateAndInitialise()},e.prototype.validateAnimationState=function(t){this.animateModel.value&&(this.placesInAnimationOrder.length<1?console.error("PlaceOutlet.animate === true but placeAnimationOrder has not been set. Animation is disabled."):this.placesInAnimationOrder.query().includes(t.placeDefinition.component)||console.error("PlaceOutlet.animate === true but placeAnimationOrder doesn't contain "+t.placeDefinition.component.name+"."))},e.prototype.onOutletDeactivated=function(){this.outletActivated.value=!1,this._activePlaceModel.value=null,this._activatedRouteModel.value=null},e.prototype.checkStateAndInitialise=function(){var t=this.routerVisitModel.value,e=this.activePlaceModel.value;t&&e&&!e.isInitialised()&&(t.placeDefinition!==e.placeDefinition&&I.lang.illegalState("wrong visit!!!"),this.initialisePlace(t,e))},e.prototype.initialisePlace=function(t,e){var n=this,o=new I.MutableValueModel(t);I.DebugContext.tag(o,"PlaceOutletComponent["+e.constructor.name+")].visitModel"),e.initialiseVisit(t,(function(t,e){n.pushVisitChangeToRoute(e,t)}));var i=function(){n._activePlaceModel.value._notifyActive(!0)};!this.animationEnabled.value||this.isVeryFirstLoad?(this.isVeryFirstLoad=!1,i()):this.onAnimationFinishedJob=i;var r=I.Dsl.disposeWith(e),a=r.when,s=(r.chain,r.valueOf);a(this.routerVisitModel).changes((function(t){e.updateVisit(t)}),{unless:s.any(this._isPushingVisitToRoute,this.routerVisitModel.isNil()).areTruthy()})},e.prototype.pushVisitChangeToRoute=function(t,e){var n=this;this._isPushingVisitToRoute.value=!0,this.placeRouter.pushVisitChangesToRoute(t,e).finally((function(){n._isPushingVisitToRoute.value=!1}))},e.prototype.animationStarted=function(){},e.prototype.animationDone=function(){this.onAnimationFinishedJob&&(this.onAnimationFinishedJob(),this.onAnimationFinishedJob=void 0)},e}(Y);Mn.decorators=[{type:n.Component,args:[{selector:"aup-place-outlet",template:'<ng-container *ngIf="animationEnabled.value">\n <div class="router-outlet-container" cdkScrollable\n [@routeAnimations]="{value: getAnimationOrder(), params:{duration: animationDuration}}"\n (@routeAnimations.start)="animationStarted()"\n (@routeAnimations.done)="animationDone()"\n >\n <router-outlet #routerOutlet="outlet"\n (activate)="onOutletActivated(routerOutlet, $event)"\n (deactivate)="onOutletDeactivated()">\n </router-outlet>\n </div>\n</ng-container>\n\n<ng-container *ngIf="!animationEnabled.value">\n <div class="router-outlet-container" cdkScrollable>\n <router-outlet #routerOutlet="outlet"\n (activate)="onOutletActivated(routerOutlet, $event)"\n (deactivate)="onOutletDeactivated()">\n </router-outlet>\n </div>\n</ng-container>\n\n',animations:[wn],styles:[":host{display:flex;flex-direction:column;min-height:0}.router-outlet-container{display:block;flex:1;min-height:0;overflow-x:hidden;overflow-y:scroll;position:relative}router-outlet{display:none}"]}]}],Mn.ctorParameters=function(){return[{type:A.Router},{type:yn},{type:void 0,decorators:[{type:n.Optional},{type:n.Inject,args:[$e]}]},{type:Mn,decorators:[{type:n.SkipSelf},{type:n.Optional}]}]},Mn.propDecorators={animate:[{type:n.Input}],animateModel:[{type:n.Input}],customPlaceAnimationOrderModel:[{type:n.Input,args:["placeAnimationOrderModel"]}],customPlaceAnimationOrder:[{type:n.Input,args:["placeAnimationOrder"]}],placeChanged:[{type:n.Output}],routerOut:[{type:n.ViewChild,args:["routeOutlet",{static:!0}]}]},G([I.StoreInValueModel("animateModel"),q("design:type",Boolean)],Mn.prototype,"animate",void 0),G([I.TrackExternal({defaultValue:!0}),q("design:type",I.ValueModel)],Mn.prototype,"animateModel",void 0),G([I.TrackExternal(),q("design:type",I.ListModel)],Mn.prototype,"customPlaceAnimationOrderModel",void 0),G([I.StoreInListModel("customPlaceAnimationOrderModel"),q("design:type",Array)],Mn.prototype,"customPlaceAnimationOrder",void 0),G([I.Trace(),q("design:type",Function),q("design:paramtypes",[A.RouterOutlet,t.PlaceComponent]),q("design:returntype",void 0)],Mn.prototype,"onOutletActivated",null),G([I.Trace(),q("design:type",Function),q("design:paramtypes",[]),q("design:returntype",void 0)],Mn.prototype,"onOutletDeactivated",null);var xn=function(e){function n(n){var o=e.call(this)||this;o._activePlaceComponent=new I.DelegatingValueModel;var i=I.Dsl.disposeWith(o),r=i.chain,a=(i.valueOf,i.before,i.when);i.after,i.observe,i.switchOn;return o.placeDefinitions=r(o.placesModel).map((function(e){return t.PlaceComponent.getDefinition(e)})).select((function(t){return n.authoriserModel.value(t)}),{dependsOn:n.authoriserModel}),o.commandFactory=I.Command.createFactory((function(t){o.placeOutlet.navigate(new Ke(t))})),a(o.placeOutletModel).changes((function(t){setTimeout((function(){return o._activePlaceComponent.setDelegate(t?t.activePlaceModel:null)}))})),o.activePlaceDefinition=r(o._activePlaceComponent).pluck("placeDefinition"),o}return B(n,e),n.prototype.getNavigationFace=function(t){var e=t.getPlaceData("nav");return{text:function(){return e?e.title():t.searchPlaceData(["navTitle","title"])},tooltip:function(){return e&&e.tooltip?e.tooltip():t.getPlaceData("navTooltip",null)},icon:function(){return e&&e.icon?e.icon():t.getPlaceData("navIcon",null)}}},n.prototype.isActive=function(t){return this.activePlaceDefinition.query().equals(t)},n.prototype.ngOnInit=function(){},n}(Y);xn.decorators=[{type:n.Component,args:[{template:""}]}],xn.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[Ge]}]}]},xn.propDecorators={places:[{type:n.Input}],placesModel:[{type:n.Input}],placeOutlet:[{type:n.Input}],placeOutletModel:[{type:n.Input}]},G([I.StoreInListModel("placesModel"),q("design:type",Array)],xn.prototype,"places",void 0),G([I.TrackExternal(),q("design:type",I.ListModel)],xn.prototype,"placesModel",void 0),G([I.StoreInValueModel("placeOutletModel"),q("design:type",Mn)],xn.prototype,"placeOutlet",void 0),G([I.TrackExternal(),q("design:type",I.ValueModel)],xn.prototype,"placeOutletModel",void 0),G([w.Memoize(),q("design:type",Function),q("design:paramtypes",[qe]),q("design:returntype",Object)],xn.prototype,"getNavigationFace",null);var Pn=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();Pn.decorators=[{type:n.Component,args:[{selector:"aup-busy-overlay",template:'<ng-content></ng-content>\n<div class="busy-overlay-backdrop" *ngIf="busyModel.value">\n <mat-progress-spinner mode="indeterminate" [diameter]="52"></mat-progress-spinner>\n</div>\n',styles:[":host{position:relative}div.busy-overlay-backdrop{-ms-grid-columns:auto;-ms-grid-rows:auto;background-color:rgba(0,0,0,.2);bottom:0;display:-ms-grid;display:grid;grid-template-columns:auto;grid-template-rows:auto;left:0;place-content:center;position:absolute;right:0;top:0}"]}]}],Pn.ctorParameters=function(){return[]},Pn.propDecorators={busyModel:[{type:n.Input}],busy:[{type:n.Input}]},G([I.TrackExternal(),q("design:type",I.ValueModel)],Pn.prototype,"busyModel",void 0),G([I.StoreInValueModel("busyModel"),q("design:type",Boolean)],Pn.prototype,"busy",void 0);var Rn=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();Rn.decorators=[{type:n.Component,args:[{selector:"aup-empty-state",template:'\n <div class="container">\n <ng-content></ng-content>\n </div>\n ',styles:[":host{align-items:center;display:flex;flex-direction:column;justify-content:center}.container{border:2px dashed rgba(0,0,0,.2);border-radius:5px;font-size:14px;font-weight:300;padding:var(--aup-default-padding)}"]}]}],Rn.ctorParameters=function(){return[]};var Sn=function(t){function e(e){return t.call(this,e)||this}return B(e,t),e}(xn);Sn.decorators=[{type:n.Component,args:[{selector:"aup-list-place-nav",template:'<mat-nav-list fxFlex>\n <a mat-list-item *ngFor="let placeDefinition of placeDefinitions.value"\n [pectinCommand]="commandFactory.create(placeDefinition)"\n [class.active]="isActive(placeDefinition)"\n [matTooltip]="getNavigationFace(placeDefinition).tooltip()">\n <aup-command-face [faces]="[getNavigationFace(placeDefinition)]"></aup-command-face>\n </a>\n</mat-nav-list>\n',styles:[":host{--selected-background:#f1f1f1;--selected-border-color:#838383;--selected-color:inherit;display:flex;flex-direction:column}mat-nav-list{padding-top:0}a{border-right:2px solid transparent}a.active{background:var(--selected-background);border-right:2px solid var(--selected-border-color);color:var(--selected-color)}"]}]}],Sn.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[Ge]}]}]};var Dn=function(t){function e(e,n){var o=t.call(this,n)||this;return o.router=e,o.expanded=!1,o}return B(e,t),e.prototype.expandMenu=function(){this.expanded=!0},e.prototype.collapseMenu=function(){this.expanded=!1},e.prototype.toggleMenu=function(){this.expanded=!this.expanded},e}(xn);Dn.decorators=[{type:n.Component,args:[{selector:"aup-side-place-navigation",template:'<mat-nav-list>\n <a mat-list-item (click)="toggleMenu()" class="home">\n <aup-icon class="collapsed-only" icon="mat:menu"></aup-icon>\n <aup-icon class="expanded-only" icon="mat:arrow_back"></aup-icon>\n <span class="expanded-only">Menu</span>\n </a>\n <a mat-list-item *ngFor="let placeDefinition of placeDefinitions.value"\n [pectinCommand]="commandFactory.create(placeDefinition)"\n [class.active]="isActive(placeDefinition)"\n [matTooltip]="getNavigationFace(placeDefinition).tooltip()">\n <aup-icon *ngIf="getNavigationFace(placeDefinition).icon()" [icon]="getNavigationFace(placeDefinition).icon()"></aup-icon>\n <span class="expanded-only">{{getNavigationFace(placeDefinition).text()}}</span>\n </a>\n <span [style.flex]="1"></span>\n <ng-container *ngIf="navEndTemplate" [ngTemplateOutlet]="navEndTemplate"></ng-container>\n</mat-nav-list>\n',styles:[":host{--resolved-background-color:var(--nav-background-color,#555);--resolved-color:var(--nav-color,hsla(0,0%,100%,0.9));--resolved-expanded-width:var(--nav-expanded-width,235px);--resolved-nav-item-height:var(--nav-item-height,var(--resolved-nav-item-width));--resolved-nav-item-width:var(--nav-width,56px);background-color:var(--resolved-background-color);color:var(--resolved-color);display:flex;flex-direction:column;transition:width 125ms linear;width:var(--resolved-nav-item-width)}:host.expanded{max-width:var(--resolved-expanded-width);width:var(--resolved-expanded-width)}:host-context(.expanded) .expanded-only{max-width:100%}:host-context(.expanded) .collapsed-only{max-width:0}:host-context(.expanded) .mat-list-item aup-icon:not(.collapsed-only){margin-right:12px}:host-context(.expanded) .mat-list-item span{text-wrap:none;white-space:nowrap}.expanded-only{max-width:0;overflow:hidden}.collapsed-only{max-width:100%;overflow:hidden}mat-nav-list{display:flex;flex:1;flex-direction:column}.mat-list-item{color:inherit;height:var(--resolved-nav-item-height);width:var(--resolved-nav-item-width)}.mat-list-item.active{background-color:#444}.mat-list-item.home{text-align:left}mat-icon{color:inherit}mat-icon.flip-horizontal{transform:scaleX(-1)}"]}]}],Dn.ctorParameters=function(){return[{type:A.Router},{type:void 0,decorators:[{type:n.Inject,args:[Ge]}]}]},Dn.propDecorators={expanded:[{type:n.HostBinding,args:["class.expanded"]}],navEndTemplate:[{type:n.ContentChild,args:["navEndTemplate"]}]};var An=function(t){function e(e){return t.call(this,e)||this}return B(e,t),e}(xn);An.decorators=[{type:n.Component,args:[{selector:"aup-tabbed-place-navigation",template:'<nav mat-tab-nav-bar>\n <a mat-tab-link *ngFor="let placeDefinition of placeDefinitions.value"\n [pectinCommand]="commandFactory.create(placeDefinition)"\n [active]="isActive(placeDefinition)"\n [matTooltip]="getNavigationFace(placeDefinition).tooltip()">\n <aup-command-face [faces]="[getNavigationFace(placeDefinition)]"></aup-command-face>\n </a>\n</nav>\n',styles:[""]}]}],An.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[Ge]}]}]};var Tn=function(){};Tn.decorators=[{type:n.NgModule,args:[{imports:[e.CommonModule,c.BrowserAnimationsModule,E.MatProgressSpinnerModule,A.RouterModule,s.MatTabsModule,F.MatListModule,v.MatTooltipModule,h.MatIconModule,tt,S.FlexModule,ye],declarations:[Rn,Pn,Mn,An,Sn,Dn,xn],entryComponents:[Pn],exports:[Pn,Mn,Rn,An,Sn,Dn,xn],providers:[]}]}];var On=function(){};On.decorators=[{type:n.NgModule,args:[{declarations:[],imports:[e.CommonModule,c.BrowserAnimationsModule,o.FormsModule,r.MatInputModule,i.MatFormFieldModule,a.MatSelectModule,s.MatTabsModule,tt,ye,Tn,Be],exports:[Be,Tn,tt,ye,Tt]}]}];var Fn=_.style({opacity:0,height:"0",paddingTop:"0",paddingBottom:"0"}),En=_.trigger("slideDownOnEnter",[_.transition(":enter",[Fn,_.animate("{{duration}}")],{params:{duration:"100ms"}}),_.transition(":leave",[_.animate("{{duration}}",Fn)],{params:{duration:"100ms"}})]),kn=_.style({opacity:0,width:"0",paddingLeft:"0",paddingRight:"0"}),Vn=_.trigger("slideRightOnEnter",[_.transition(":enter",[kn,_.animate("{{duration}}")],{params:{duration:"100ms"}}),_.transition(":leave",[_.animate("{{duration}}",kn)],{params:{duration:"100ms"}})]),_n=function(t){function e(e,n,o,i){var r=t.call(this)||this;return r.identifier=e,r.api=n,r.dialogService=o,r.config=i,r.garbage=new I.GarbageCollector,P.assert.notNil(o),r}return B(e,t),e.prototype.cancelActiveActivity=function(){return this.activityContainer.cancelActiveActivity()},e.prototype.dispose=function(){this.isActive()&&I.lang.illegalState("Dispose called while active."),this.garbage.dispose()},e.prototype.registerDisposable=function(t){return this.garbage.registerDisposable(t)},e.prototype.isActive=function(){return!!this.activityContainer&&this.activityContainer.isActive()},e.prototype.createAndLaunchActivity=function(t,e,n){var o=this;P.assert.isNil(this._currentActivityRef);var i=Object.assign(Object.assign({},this.config),{disableClose:n,panelClass:"dialog-interaction-context"}),r=this.dialogService.open(Se,i),a=this.activityContainer=r.componentInstance;this.activityContainer.initialise(this.identifier,this.api);var s=this.activityContainer.startActivity(t,e);return s.finally((function(){return r.close()})),r.afterClosed().subscribe((function(t){a.isActive()&&a.cancelActiveActivity(),o.activityContainer=null})),r.updateSize(),r.afterOpened().subscribe((function(t){r.updateSize()})),s},e}(xe),Ln=new n.InjectionToken("DIALOG_INTERACTION_SERVICE_DEFAULTS"),jn=function(t){function e(e,n,o){var i=t.call(this)||this;return i.dialogService=e,i.dialogServiceDefaults=n,i.matDialogDefaultConfig=o,P.assert.notNil(e),i}return B(e,t),e.prototype.createInteractionContext=function(t,e,n){var o=Object.assign(Object.assign({autoFocus:!1,hasBackdrop:!0,closeOnNavigation:!1},this.matDialogDefaultConfig),this.dialogServiceDefaults);return new _n(t,e,this.dialogService,o)},e}(Ae);jn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new jn(n.ɵɵinject(D.MatDialog),n.ɵɵinject(Ln,8),n.ɵɵinject(D.MAT_DIALOG_DEFAULT_OPTIONS,8))},token:jn,providedIn:"root"}),jn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],jn.ctorParameters=function(){return[{type:D.MatDialog},{type:D.MatDialogConfig,decorators:[{type:n.Optional},{type:n.Inject,args:[Ln]}]},{type:D.MatDialogConfig,decorators:[{type:n.Optional},{type:n.Inject,args:[D.MAT_DIALOG_DEFAULT_OPTIONS]}]}]};var Nn=function(){function t(t,e){this.paramMaps=[t].concat((e||[]).map((function(t){return new Un(t.parameters)}))).filter((function(t){return!!t}))}return t.prototype.get=function(t){return this.paramMaps.find((function(e){return e.has(t)})).get(t)},t.prototype.getAll=function(t){return this.paramMaps.find((function(e){return e.has(t)})).getAll(t)},t.prototype.has=function(t){return!!this.paramMaps.find((function(e){return e.has(t)}))},Object.defineProperty(t.prototype,"keys",{get:function(){return this.paramMaps.reduce((function(t,e){return t.concat(e.keys)}),[])},enumerable:!1,configurable:!0}),t}();G([w.Memoize(),q("design:type",Array),q("design:paramtypes",[])],Nn.prototype,"keys",null);var Un=function(){function t(t){this.params=t}return t.prototype.get=function(t){return this.params[t]},t.prototype.getAll=function(t){var e=this.get(t);return Array.isArray(e)?e:[e]},t.prototype.has=function(t){return this.keys.includes(t)},Object.defineProperty(t.prototype,"keys",{get:function(){return Object.keys(this.params)},enumerable:!1,configurable:!0}),t}(),Hn=function(){function t(){}return t.prototype.canActivate=function(t,e){return W(this,void 0,void 0,(function(){return z(this,(function(t){return[2,!0]}))}))},t}();Hn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new Hn},token:Hn,providedIn:"root"}),Hn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],Hn.ctorParameters=function(){return[]};var Bn,Gn,qn,Wn,zn=function(){function t(t,e,n,o,i){this.navigationSession=t,this.activatedRoute=e,this.router=n,this.placeHistory=o,this.injector=i}return t.prototype.sanitise=function(t){return W(this,void 0,void 0,(function(){var e,n,o,i,r,a,s,c,l;return z(this,(function(u){switch(u.label){case 0:return(e=t.placeDefinition).hasRouteId()?(n=e.getRouteIdParameterDef(),o=t.getRouteId(),[4,n.sanitise(o,t,this.placeHistory,this.injector,this.navigationSession.isPopState)]):[3,2];case 1:if(l=u.sent(),console.log({routeId:o,sanitisedValue:l}),n.hasChanged(o,l))return[2,t.replace(n,l)];u.label=2;case 2:i=e.getVisitParameterDefs({includeRouteParameters:!0,includeNonRouteParameters:!0}),r=t,a=0,u.label=3;case 3:return a<i.length?(s=i[a],c=t.getParameter(s.name),[4,s.sanitise(c,r,this.placeHistory,this.injector,this.navigationSession.isPopState)]):[3,6];case 4:l=u.sent(),s.hasChanged(c,l)&&(r=r.replace(s,l)),u.label=5;case 5:return a++,[3,3];case 6:return[2,r.hasChangedFrom(t)?r:t]}}))}))},t}(),Kn=function(){function e(t,e,n,o,i,r,a){this.router=t,this.urlService=e,this.placeRouter=n,this.placeHistory=o,this.placeAuthService=i,this.interactionService=r,this.injector=a}return e.prototype.canActivate=function(e,n){return W(this,void 0,void 0,(function(){var o,i,r,a,s=this;return z(this,(function(c){switch(c.label){case 0:return t.PlaceComponent.isPlaceComponentConstructor(e.component)?(o=t.PlaceComponent.getDefinition(e.component),i=o.authenticate,(r=!i)?[3,2]:[4,this.placeAuthService.isAuthenticated()]):[3,4];case 1:r=c.sent(),c.label=2;case 2:return r?this.placeAuthService.isAuthorised(o)?[4,this.cleanInteractionState(e,n,(function(){return W(s,void 0,void 0,(function(){var t,i,r,a,s;return z(this,(function(c){switch(c.label){case 0:return t=new Nn(e.paramMap,e.url),i=o.parseRouteParams(t),r=this.placeRouter.navigationSession,a=r.getVisitFor(o)||new Ke(o,i),[4,new zn(r,e,this.router,this.placeHistory,this.injector).sanitise(a.mergeRouteParameters(i))];case 1:return s=c.sent(),r.storeVisit(s),a.hasRoutingChangedFrom(s)?[2,this.urlService.parseUrl(n.url).updateVisitSegments(s)]:[2,!0]}}))}))}))]:[2,this.handleGuardResult(this.placeAuthService.handleNotAuthorised(e,n))]:[2,this.handleGuardResult(this.placeAuthService.handleNotAuthenticated(e,n))];case 3:return[2,(a=c.sent())instanceof t.UrlSnapshot?a.urlTree:a];case 4:return[2,I.lang.illegalState("expected component to be an instance of PlaceComponent, got "+e.component)]}}))}))},e.prototype.canDeactivate=function(e,n,o,i){return W(this,void 0,void 0,(function(){var n,r,a;return z(this,(function(s){switch(s.label){case 0:return n=this.urlService.parseUrl(o.url),r=this.urlService.parseUrl(i.url),[4,this.placeRouter.navigationSession.canDeactivatePlace(e,n,r)];case 1:return[2,(a=s.sent())instanceof t.UrlSnapshot?a.urlTree:a]}}))}))},e.prototype.handleGuardResult=function(e){return e instanceof t.UrlSnapshot?e.urlTree:this.urlService.createUrlSnapshot(e).urlTree},e.prototype.cleanInteractionState=function(t,e,n){return W(this,void 0,void 0,(function(){var t;return z(this,(function(o){return t=this.urlService.parseUrl(e.url),!this.interactionService.isActive()&&t.hasInteractions()?[2,t.removeInteractionIds()]:[2,n()]}))}))},e}();function $n(t,e,n,o,i){var r={backingModel:n,binding:null},a=o+"("+t.constructor.name+"."+e.toString()+")";I.DebugContext.getOrCreate(r.backingModel).tag(a),Object.defineProperty(t,e,{get:function(){return r.backingModel},set:function(t){r.binding&&r.binding.dispose(),t&&(r.binding=new I.Binding(r.backingModel,t,{toLeft:I.Functions.identity,toRight:I.Functions.identity}),i(t)?r.binding.writeRight():(i(r.backingModel)||console.warn("Assigning a visit model with an existing value to a visit parameter with an existing value. Visit parameter will be overridden"),r.binding.writeLeft()))}})}Kn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new Kn(n.ɵɵinject(A.Router),n.ɵɵinject(gn),n.ɵɵinject(yn),n.ɵɵinject(t.PlaceHistory),n.ɵɵinject(Ge),n.ɵɵinject(t.InteractionService),n.ɵɵinject(n.INJECTOR))},token:Kn,providedIn:"root"}),Kn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],Kn.ctorParameters=function(){return[{type:A.Router},{type:gn},{type:yn},{type:t.PlaceHistory},{type:void 0,decorators:[{type:n.Inject,args:[Ge]}]},{type:t.InteractionService},{type:n.Injector}]},G([I.Trace(),q("design:type",Function),q("design:paramtypes",[A.ActivatedRouteSnapshot,A.RouterStateSnapshot]),q("design:returntype",Promise)],Kn.prototype,"canActivate",null),G([I.Trace(),q("design:type",Function),q("design:paramtypes",[t.PlaceComponent,A.ActivatedRouteSnapshot,A.RouterStateSnapshot,A.RouterStateSnapshot]),q("design:returntype",Promise)],Kn.prototype,"canDeactivate",null),G([I.Trace(),q("design:type",Function),q("design:paramtypes",[Object]),q("design:returntype",void 0)],Kn.prototype,"handleGuardResult",null),G([I.Trace(),q("design:type",Function),q("design:paramtypes",[A.ActivatedRouteSnapshot,A.RouterStateSnapshot,Function]),q("design:returntype",Promise)],Kn.prototype,"cleanInteractionState",null),Bn=t.Formatter||(t.Formatter={}),Gn=function(){function t(){}return t.prototype.format=function(t){return t},t.prototype.parse=function(t){return t},t}(),qn=function(){function t(){}return t.prototype.format=function(t){return j.default.isNumber(t)&&!j.default.isNaN(t)?""+t:null},t.prototype.parse=function(t){var e=Number.parseFloat(t);return j.default.isNaN(e)?null:e},t}(),Wn=function(){function t(){}return t.prototype.format=function(t){return t?"true":"false"},t.prototype.parse=function(t){return"true"===t},t}(),Bn.STRING=new Gn,Bn.NUMBER=new qn,Bn.BOOLEAN=new Wn,t.ACTIVITY_DATA=ve,t.AUP_PLACE_CONFIG=$e,t.AbstractInputActivity=Ve,t.AbstractInputComponent=bt,t.AbstractInteractionContext=xe,t.AbstractListInputComponent=Ct,t.AbstractPlaceNavigationComponent=xn,t.AbstractPopStateNavigation=nn,t.AbstractValueInputComponent=It,t.Activity=be,t.ActivityActionsComponent=Ce,t.ActivityContainerComponent=Se,t.ActivityOutletComponent=Re,t.ActivityRef=Pe,t.AddItemInteractionContextComponent=Fe,t.AlertDialogComponent=Ie,t.AngularUiPowerupsModule=On,t.AutocompleteInputComponent=wt,t.BusyOverlayComponent=Pn,t.CELL_EDITOR_PORTAL=Nt,t.CELL_RENDERER_PORTAL=jt,t.CardContainerComponent=et,t.CellEditorPortalRef=zt,t.CellHeaderPortalRef=Gt,t.CellPortalRef=Bt,t.CellRendererPortalRef=qt,t.CheckboxInputComponent=Mt,t.ColumnModel=te,t.ColumnTemplateDirective=pe,t.CommandComponent=ct,t.CommandDirective=X,t.CommandFaceComponent=st,t.CommandGroupComponent=at,t.CommandGroupMenuRendererComponent=nt,t.CommandGroupRendererComponent=rt,t.ComponentCellRendererPortalRef=Wt,t.ComponentsModule=ye,t.ConfirmThenDialogComponent=we,t.ConfirmationDialogComponent=Me,t.ConsolidatedParameterMap=Nn,t.CustomTemplateColumnModel=ae,t.CustomValueColumnModel=ie,t.DEFINITION_META_DATA_KEY=We,t.DIALOG_INTERACTION_SERVICE_DEFAULTS=Ln,t.DefaultCellRendererComponent=$t,t.DefaultHeaderCellRendererComponent=Xt,t.DialogInteractionContext=_n,t.DialogInteractionContextFactory=jn,t.Dimension=Ne,t.DirectivesModule=tt,t.DisposableComponent=Y,t.EditRowControls=Yt,t.EditSession=ce,t.EditorControlColumnModel=re,t.EmptyStateComponent=Rn,t.EventCleanUpSession=Je,t.FlexComponent=lt,t.FocusBinding=J,t.FocusBindingDirective=Q,t.FocusBindingFactory=Z,t.FocusContainerComponent=yt,t.FocusableComponent=vt,t.HEADER_CELL_RENDERER_PORTAL=Lt,t.InPlaceInteractionContextComponent=Oe,t.InteractionContextTriggerFor=ke,t.InteractionModule=Be,t.InteractionServiceRoutingAdapter=De,t.LEFT_RIGHT_PLACE_ANIMATION=wn,t.ListPlaceNavComponent=Sn,t.ListPropertyColumnModel=oe,t.ModalInteractionContextFactory=Ae,t.MoreMenuComponent=pt,t.MultipleSelectInputComponent=xt,t.Navigating=un,t.NavigatingDuringInteraction=en,t.NavigationSession=Ye,t.NoopAuthGuard=Hn,t.NoopComponent=Tt,t.NumberInputComponent=Pt,t.PLACE_AUTH_SERVICE=Ge,t.PORTAL_EDITOR_COMPONENT=Ht,t.PORTAL_RENDERER_COMPONENT=Ut,t.PasswordInputComponent=Rt,t.Place=function(e){return function(n){t.PlaceComponent.isPlaceComponentConstructor(n)?t.PlaceComponent.injectDefinition(n,new qe(n,e.path,!!M.isNil(e.authenticate)||e.authenticate,M.isNil(e.roles)?[]:e.roles,e.data,t.PlaceComponent.getRouteParameters(n),(e.children||[]).map((function(e){return t.PlaceComponent.getDefinition(e)})))):I.lang.illegalState(n+" must extend PlaceComponent to use the @Place decorator")}},t.PlaceComponentDeactivationHandler=Xe,t.PlaceDefinition=qe,t.PlaceGuard=Kn,t.PlaceModule=Tn,t.PlaceOutletComponent=Mn,t.PlaceRouter=yn,t.Point=Ue,t.PopStateDuringInteractionNavigation=on,t.PopStateNavigation=hn,t.PopupInteractionContextComponent=Ee,t.PopupMenuComponent=ft,t.PropertyColumnModel=ne,t.ROUTE_PARAMETER_LIST_KEY=ze,t.RemoveLastInteractionFromUrlNavigationSession=Qe,t.ResizeAwareComponent=He,t.RouteId=function(e,n){return function(o,i){var r=new t.ParameterDefinition.RouteId(i.toString(),n,e);P.Klass.get(o).addToOwnMetadataList(ze,r),$n(o,i,new I.MutableValueModel,"@RouteId",(function(t){return t.query().isNil()}))}},t.ScrollContainerComponent=Ot,t.SectionHeaderComponent=Ft,t.SelectCellRendererComponent=Jt,t.SelectHeaderCellRendererComponent=Zt,t.SelectInputActivity=Le,t.SelectInputComponent=St,t.SelectionColumnModel=se,t.SeparatorComponent=mt,t.SidePlaceNavigationComponent=Dn,t.StringInputActivity=_e,t.StringInputComponent=Dt,t.SwitchCaseComponent=_t,t.SwitchCaseDefaultDirective=Vt,t.SwitchCaseOption=Et,t.SwitchCaseWhenDirective=kt,t.SynchroniseInteractionContextIdsWithRoute=tn,t.TabbedPlaceNavigationComponent=An,t.TableCellRendererComponent=de,t.TableComponent=ue,t.TableHeaderCellRendererComponent=fe,t.TableRowMenuComponent=he,t.TemplateCellRendererPortalRef=Kt,t.TextInputComponent=At,t.ToolBarComponent=gt,t.UrlService=gn,t.VerticalFocusContainerComponent=ge,t.Visit=Ke,t.VisitParameter=function(e){var n=P.Opts.get(e);return function(o,i){var r=new t.ParameterDefinition.ValueParameter(i.toString(),e,n.getOptional("storeInUrl",null));P.Klass.get(o).addToOwnMetadataList(ze,r),$n(o,i,new I.MutableValueModel,"@VisitParameter",(function(t){return t.query().isNil()}))}},t.VisitParameterList=function(e){var n=P.Opts.get(e);return function(o,i){var r=new t.ParameterDefinition.ArrayParameter(i.toString(),e,n.getOptional("storeInUrl",null));P.Klass.get(o).addToOwnMetadataList(ze,r),$n(o,i,new I.MutableListModel,"@VisitParameterList",(function(t){return t.query().isEmpty()}))}},t.VisitSanitiser=zn,t.WaitUntilLeavingInteractionTransitionCancelled=Ze,t.WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined=rn,t.WaitUntilPopStateDuringCanDeactivateInteractionFinishes=mn,t.leftRightPlaceAnimation=In,t.slideDownOnEnterAnimation=En,t.slideRightOnEnterAnimation=Vn,t.ɵ0=ut,Object.defineProperty(t,"__esModule",{value:!0})}));
|
|
1
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/common"),require("@angular/core"),require("@angular/forms"),require("@angular/material/form-field"),require("@angular/material/input"),require("@angular/material/select"),require("@angular/material/tabs"),require("@angular/platform-browser/animations"),require("@angular/cdk/portal"),require("@angular/cdk/scrolling"),require("@angular/material/autocomplete"),require("@angular/material/button"),require("@angular/material/checkbox"),require("@angular/material/divider"),require("@angular/material/icon"),require("@angular/material/menu"),require("@angular/material/table"),require("@angular/material/tooltip"),require("@fortawesome/angular-fontawesome"),require("@fortawesome/free-solid-svg-icons"),require("@coolon/pectin"),require("@typescript-plus/fast-memoize-decorator/dist/src"),require("lodash"),require("typescript-string-enums"),require("@coolon/typescript-utilities"),require("immer"),require("@angular/flex-layout"),require("@angular/material/dialog"),require("@angular/router"),require("@angular/cdk/overlay"),require("resize-observer-polyfill"),require("@angular/material/list"),require("@angular/material/progress-spinner"),require("@typescript-plus/fast-memoize-decorator"),require("reflect-metadata"),require("@angular/animations")):"function"==typeof define&&define.amd?define("@coolon/angular-ui-powerups",["exports","@angular/common","@angular/core","@angular/forms","@angular/material/form-field","@angular/material/input","@angular/material/select","@angular/material/tabs","@angular/platform-browser/animations","@angular/cdk/portal","@angular/cdk/scrolling","@angular/material/autocomplete","@angular/material/button","@angular/material/checkbox","@angular/material/divider","@angular/material/icon","@angular/material/menu","@angular/material/table","@angular/material/tooltip","@fortawesome/angular-fontawesome","@fortawesome/free-solid-svg-icons","@coolon/pectin","@typescript-plus/fast-memoize-decorator/dist/src","lodash","typescript-string-enums","@coolon/typescript-utilities","immer","@angular/flex-layout","@angular/material/dialog","@angular/router","@angular/cdk/overlay","resize-observer-polyfill","@angular/material/list","@angular/material/progress-spinner","@typescript-plus/fast-memoize-decorator","reflect-metadata","@angular/animations"],e):e(((t="undefined"!=typeof globalThis?globalThis:t||self).coolon=t.coolon||{},t.coolon["angular-ui-powerups"]={}),t.ng.common,t.ng.core,t.ng.forms,t.ng.material.formField,t.ng.material.input,t.ng.material.select,t.ng.material.tabs,t.ng.platformBrowser.animations,t.ng.cdk.portal,t.ng.cdk.scrolling,t.ng.material.autocomplete,t.ng.material.button,t.ng.material.checkbox,t.ng.material.divider,t.ng.material.icon,t.ng.material.menu,t.ng.material.table,t.ng.material.tooltip,t.angularFontawesome,t.freeSolidSvgIcons,t.pectin,t.src,t._,t.typescriptStringEnums,t.typescriptUtilities,t.produce,t.ng.flexLayout,t.ng.material.dialog,t.ng.router,t.ng.cdk.overlay,t.ResizeObserver,t.ng.material.list,t.ng.material.progressSpinner,t.fastMemoizeDecorator,null,t.ng.animations)}(this,(function(t,e,n,o,i,r,a,c,s,l,u,p,d,f,m,h,g,y,v,b,C,I,w,P,M,x,R,S,A,O,D,T,E,F,k,_,L){"use strict";function V(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var j=V(P),N=V(R),U=V(T),H=function(t,e){return(H=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function B(t,e){function n(){this.constructor=t}H(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function q(t,e,n,o){var i,r=arguments.length,a=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,n,o);else for(var c=t.length-1;c>=0;c--)(i=t[c])&&(a=(r<3?i(a):r>3?i(e,n,a):i(e,n))||a);return r>3&&a&&Object.defineProperty(e,n,a),a}function W(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function z(t,e,n,o){return new(n||(n=Promise))((function(i,r){function a(t){try{s(o.next(t))}catch(t){r(t)}}function c(t){try{s(o.throw(t))}catch(t){r(t)}}function s(t){var e;t.done?i(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,c)}s((o=o.apply(t,e||[])).next())}))}function G(t,e){var n,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function c(r){return function(c){return function(r){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==r[0]&&2!==r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=e.call(t,a)}catch(t){r=[6,t],o=0}finally{n=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,c])}}}Object.create;function K(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var o,i,r=n.call(t),a=[];try{for(;(void 0===e||e-- >0)&&!(o=r.next()).done;)a.push(o.value)}catch(t){i={error:t}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(i)throw i.error}}return a}function X(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(K(arguments[e]));return t}Object.create;var $=function(t){function e(e,n,o){var i=t.call(this)||this;return i.elementRef=e,i._commandEnabled=(new I.DelegatingValueModel).withDefault(!1),i._commandParameterProvided=!1,i.matControl=n||o,i}return B(e,t),Object.defineProperty(e.prototype,"pectinCommand",{get:function(){return this._command},set:function(t){this._command=t,this._commandEnabled.setDelegate(t?t.enabled:null)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"commandParameter",{get:function(){return this._commandParameter},set:function(t){this._commandParameterProvided=!0,this._commandParameter=t},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){I.assert.notNil(this.pectinCommand),this.pectinCommand instanceof I.UnaryCommand?this._commandParameterProvided||I.lang.illegalState("UnaryCommands require the command parameter to be specified."):this._commandParameterProvided&&I.lang.illegalState("command parameters are only supported by UnaryCommands")},e.prototype.ngAfterViewInit=function(){var t=this;(0,I.Dsl.disposeWith(this).when)(this._commandEnabled).changes((function(e){return t.updateEnabledState(e)}),{initialValue:"triggerChange"})},e.prototype.updateEnabledState=function(t){var e=this;this.matControl&&setTimeout((function(){e.matControl.disabled=!t}),0),t?(this.elementRef.nativeElement.removeAttribute("disabled"),"A"===this.elementRef.nativeElement.tagName&&this.elementRef.nativeElement.setAttribute("href","javascript:void")):(this.elementRef.nativeElement.setAttribute("disabled","disabled"),"A"===this.elementRef.nativeElement.tagName&&this.elementRef.nativeElement.removeAttribute("href"))},e.prototype.ngOnDestroy=function(){this.dispose()},e.prototype.notifyClick=function(t){t.preventDefault(),t.stopPropagation(),this.pectinCommand.enabled.value?this.pectinCommand instanceof I.UnaryCommand?this.pectinCommand.withContext({event:t}).execute(this.commandParameter):this.pectinCommand.withContext({event:t}).execute():console.warn("disabled command clicked, ignoring.")},e}(I.GarbageCollector);$.decorators=[{type:n.Directive,args:[{selector:"[pectinCommand]"}]}],$.ctorParameters=function(){return[{type:n.ElementRef,decorators:[{type:n.Inject,args:[n.ElementRef]}]},{type:d.MatButton,decorators:[{type:n.Host},{type:n.Optional}]},{type:g.MatMenuItem,decorators:[{type:n.Host},{type:n.Optional}]}]},$.propDecorators={pectinCommand:[{type:n.Input}],commandParameter:[{type:n.Input}],notifyClick:[{type:n.HostListener,args:["click",["$event"]]}]};var Y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e.prototype.ngOnDestroy=function(){this.dispose()},e}(I.GarbageCollector);Y.decorators=[{type:n.Directive}];var J=function(t){function e(e,n,o,i){var r=t.call(this)||this;return r.focusTargetElement=e,r.ngZone=n,r.focusContext=i,r.document=o,(0,I.Dsl.disposeWith(r).when)(r.focusContext.focused).changes((function(t){t&&!r.alreadyHasFocus()&&r.tryAndFocus()}),{initialValue:"triggerChangeUnlessNil"}),r}return B(e,t),e.prototype.onFocusIn=function(){this.focusContext.notifyFocusIn()},e.prototype.onFocusOut=function(){this.focusContext.notifyFocusOut()},e.prototype.alreadyHasFocus=function(){return this.isElementFocused(this.focusTarget)},e.prototype.isElementFocused=function(t){return this.document.activeElement===t},e.prototype.tryAndFocus=function(t){var e=this;void 0===t&&(t=5),this.modelShouldStillHaveFocus()&&this.canFocus()&&(this.alreadyHasFocus()||this.focusTarget.focus(),this.alreadyHasFocus()||(I.Logger.get(this).log("focus failed, trying "+t+" more times"),t>0?requestAnimationFrame((function(){e.tryAndFocus(t-1)})):I.Logger.get(this).warn("Tried to focus but gave up as the component wasn't enabled or visible.")))},Object.defineProperty(e.prototype,"focusTarget",{get:function(){return this.focusTargetElement},enumerable:!1,configurable:!0}),e.prototype.modelShouldStillHaveFocus=function(){return this.focusContext.focused.value},e.prototype.canFocus=function(){var t=this.focusTarget.getBoundingClientRect();return t.height>=0&&t.height>=0&&!this.focusTarget.disabled},e}(I.GarbageCollector);J.ctorParameters=function(){return[{type:HTMLElement},{type:n.NgZone,decorators:[{type:n.Inject,args:[n.NgZone]}]},{type:void 0,decorators:[{type:n.Inject,args:[e.DOCUMENT]}]},{type:void 0}]};var Z=function(){function t(t,e){this.ngZone=t,this.document=e}return t.prototype.createBinding=function(t,e){return new J(t,this.ngZone,this.document,e)},t}();Z.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new Z(n.ɵɵinject(n.NgZone),n.ɵɵinject(e.DOCUMENT))},token:Z,providedIn:"root"}),Z.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],Z.ctorParameters=function(){return[{type:n.NgZone,decorators:[{type:n.Inject,args:[n.NgZone]}]},{type:void 0,decorators:[{type:n.Inject,args:[e.DOCUMENT]}]}]};var Q=function(t){function e(e,n){var o=t.call(this)||this;return o.el=e,o.focusBindingFactory=n,o}return B(e,t),e.prototype.onFocusIn=function(){this.hasBinding()&&this.pectinFocusBinding.notifyFocusIn()},e.prototype.onFocusOut=function(){this.hasBinding()&&this.pectinFocusBinding.notifyFocusOut()},e.prototype.ngOnInit=function(){},e.prototype.ngAfterViewInit=function(){this.hasBinding()?this.registerDisposable(this.focusBindingFactory.createBinding(this.focusTarget,this.pectinFocusBinding)):I.Logger.get(this).warn("pectinFocusBinding was nil")},e.prototype.hasBinding=function(){return!!this.pectinFocusBinding&&!!this.pectinFocusBinding},Object.defineProperty(e.prototype,"focusTarget",{get:function(){return this.focusBindingTarget||this.el.nativeElement},enumerable:!1,configurable:!0}),e}(Y);Q.decorators=[{type:n.Directive,args:[{selector:"[pectinFocusBinding]"}]}],Q.ctorParameters=function(){return[{type:n.ElementRef,decorators:[{type:n.Inject,args:[n.ElementRef]}]},{type:Z}]},Q.propDecorators={pectinFocusBinding:[{type:n.Input}],focusBindingTarget:[{type:n.Input}],onFocusIn:[{type:n.HostListener,args:["focusin"]}],onFocusOut:[{type:n.HostListener,args:["focusout"]}]};var tt=function(){};tt.decorators=[{type:n.NgModule,args:[{declarations:[$,Q],imports:[e.CommonModule,s.BrowserAnimationsModule,o.FormsModule,r.MatInputModule,i.MatFormFieldModule,a.MatSelectModule,c.MatTabsModule],exports:[$,Q]}]}];var et=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.ngOnInit=function(){},e}(Y);et.decorators=[{type:n.Component,args:[{selector:"aup-card-container",template:'<div class="card-container">\n <ng-content></ng-content>\n\n <div class="add-card-container" *ngIf="addCardCommand.enabled.value" [pectinCommand]="addCardCommand">\n <aup-command-face *ngIf="addCardFace" [faces]="[addCardFace]"></aup-command-face>\n <aup-icon *ngIf="!addCardFace" icon="mat:add"></aup-icon>\n </div>\n\n <div class="add-card-template" *ngIf="addCardTemplate">\n <ng-container [ngTemplateOutlet]="addCardTemplate"></ng-container>\n </div>\n\n</div>\n',styles:[":root{--aup-default-background:#fff;--aup-default-padding:var(--default-padding,18px)}.router-outlet-container>*{bottom:0;left:0;position:absolute;right:0;top:0}[no-tab-header]>mat-tab-header{display:none}[full-height-tabs] .mat-tab-body-wrapper,mat-tab-group.full-height-tabs .mat-tab-body-wrapper{flex:1}[full-height-tabs] .mat-tab-body-wrapper .mat-tab-body-content,[full-height-tabs] .mat-tab-body-wrapper mat-tab-body,mat-tab-group.full-height-tabs .mat-tab-body-wrapper .mat-tab-body-content,mat-tab-group.full-height-tabs .mat-tab-body-wrapper mat-tab-body{display:flex;flex-direction:column;justify-content:stretch}.dialog-interaction-context,.dialog-interaction-context mat-dialog-container{max-height:95vh!important;max-width:95vw!important}.dialog-interaction-context mat-dialog-container{padding:0}.activity-outlet-wrapper{align-items:stretch;display:flex;flex-direction:column}.aup-popup-interaction-panel{background:var(--aup-default-background,#fff);box-shadow:0 2px 1px -1px rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 1px 3px 0 rgba(0,0,0,.12);transition:box-shadow .28s cubic-bezier(.4,0,.2,1)}.aup-input-activity{padding:calc(var(--aup-default-padding)/2)}.aup-input-component{display:block}.aup-input-component input,.aup-input-component mat-form-field{width:100%}.aup-input-component input mat-hint.faux-error,.aup-input-component mat-form-field mat-hint.faux-error{color:#f44336}.aup-input-component.dense mat-form-field .mat-form-field-infix{border-top:none}.aup-input-component.dense mat-form-field .mat-form-field-flex{padding-top:0}.aup-input-component.dense mat-form-field .mat-form-field-wrapper{border-bottom:0;padding-bottom:0}.aup-input-component.dense mat-form-field .mat-form-field-underline{bottom:0}.aup-input-component.dense mat-form-field.mat-form-field-can-float.mat-form-field-should-float .mat-form-field-label-wrapper{display:none}.aup-input-component.dense mat-form-field.mat-form-field-appearance-standard.mat-form-field-has-label .mat-select:not(.mat-select-empty) .mat-select-arrow-wrapper{transform:translateY(0)}aup-table-cell-renderer>.aup-input-component .mat-form-field-flex{padding-top:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-infix{width:0}aup-table-cell-renderer>.aup-input-component .mat-form-field-label-wrapper{display:none}aup-table{--default-column-gap:var(--column-gap,24px);--resolved-row-hover-background-color:var(--row-hover-background-color,rgba(0,0,0,0.05))}aup-table .mat-table td.mat-cell:first-of-type,aup-table .mat-table td.mat-footer-cell:first-of-type,aup-table .mat-table th.mat-header-cell:first-of-type{padding-left:0}aup-table .mat-table tr.enable-hover:hover{background-color:var(--resolved-row-hover-background-color)}aup-table .mat-table td.enable-cursor{cursor:pointer}aup-table aup-table-cell-renderer,aup-table aup-table-header-cell-renderer{align-items:stretch;display:flex;flex-direction:column;height:100%;justify-content:center;min-height:47px}aup-table aup-table-cell-renderer.first-column,aup-table aup-table-cell-renderer:not(.first-column),aup-table aup-table-header-cell-renderer.first-column,aup-table aup-table-header-cell-renderer:not(.first-column){padding-left:var(--default-column-gap)}aup-table aup-table-cell-renderer.fillCell{justify-content:stretch;padding-left:0!important}aup-table aup-table-cell-renderer.padChild>:first-child{flex:1;padding-left:var(--default-column-gap)}:root{--aup-command-face-icon-gap:8px;--aup-fa-icon-width:18px;--aup-icon-width:24px}aup-icon{--fa-icon-offset:calc((var(--aup-icon-width) - var(--aup-fa-icon-width))/2);position:relative}aup-icon fa-icon .svg-inline--fa{height:var(--aup-fa-icon-width)!important;left:var(--fa-icon-offset);position:absolute;top:var(--fa-icon-offset);width:var(--aup-fa-icon-width)!important}.mat-menu-panel aup-icon .svg-inline--fa{opacity:.54}:host{--resolved-card-background:var(--card-background,#fcfcfb);--resolved-card-gap:var(--card-gap,16px);--resolved-card-height:var(--card-height,auto);--resolved-card-min-height:var(--card-min-height,auto);--resolved-card-width:var(--card-width,300px);background:var(--resolved-card-background);display:block;flex:1}.card-container{box-sizing:border-box;display:-ms-grid;display:grid;grid-gap:var(--resolved-card-gap);grid-template-columns:repeat(auto-fill,var(--resolved-card-width));grid-template-rows:repeat(auto-fit,minmax(var(--resolved-card-min-height),var(--resolved-card-height)));max-width:100%;min-height:calc(var(--resolved-card-height) + 2*var(--resolved-card-gap));min-width:calc(var(--resolved-card-width) + 2*var(--resolved-card-gap));padding:var(--resolved-card-gap);width:calc((var(--resolved-card-width) + var(--resolved-card-gap))*2 + var(--grid-gap))}.add-card-container{align-items:center;background-color:hsla(0,0%,100%,.8);border:2px dashed rgba(0,0,0,.1);border-radius:6px;box-sizing:border-box;color:rgba(0,0,0,.54);cursor:pointer;display:flex;flex-direction:column;font-weight:300;height:var(--resolved-card-height);justify-content:center;min-height:var(--resolved-card-min-height);transition:all .28s cubic-bezier(.4,0,.2,1);width:var(--resolved-card-width)}.add-card-container mat-icon{font-size:200%}.add-card-container:hover{background-color:#fff;border-color:transparent;color:rgba(0,0,0,.54);transition:box-shadow .28s cubic-bezier(.4,0,.2,1);transition:all .28s cubic-bezier(.4,0,.2,1)}.add-card-container:hover:hover{box-shadow:0 2px 4px -1px rgba(0,0,0,.2),0 4px 5px 0 rgba(0,0,0,.14),0 1px 10px 0 rgba(0,0,0,.12)}.add-card-template-container{align-items:stretch;display:flex;flex-direction:column;height:var(--resolved-card-height);justify-content:stretch;width:var(--resolved-card-width)}"]}]}],et.ctorParameters=function(){return[]},et.propDecorators={addCardCommand:[{type:n.Input}],addCardFace:[{type:n.Input}],addCardTemplate:[{type:n.ContentChild,args:["addCardTemplate"]}]},q([I.TrackExternal(),W("design:type",I.Command)],et.prototype,"addCardCommand",void 0),(t.TrackBy||(t.TrackBy={})).byIndex=function(t,e){return e},function(t){!function(t){t.START="start",t.END="end"}(t.Position||(t.Position={})),t.Style=M.Enum({FLAT:"flat",STROKED:"stroked",RAISED:"raised"}),t.getColorOf=function(t){return j.default.isFunction(null==t?void 0:t.color)?t.color():void 0},t.getStyleOf=function(t){return j.default.isFunction(null==t?void 0:t.style)?t.style():void 0},t.getIconOf=function(t){return j.default.isFunction(null==t?void 0:t.icon)?t.icon():void 0},t.getIconPositionOf=function(t){return j.default.isFunction(null==t?void 0:t.iconPosition)?t.iconPosition():void 0},t.getTooltipOf=function(t){return j.default.isFunction(null==t?void 0:t.tooltip)?t.tooltip():void 0},t.getTextOf=function(t){return j.default.isFunction(null==t?void 0:t.text)?t.text():void 0};var e=function(){function e(t){this.face=t}return Object.defineProperty(e.prototype,"text",{get:function(){return t.getTextOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"icon",{get:function(){return t.getIconOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconPosition",{get:function(){return t.getIconPositionOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tooltip",{get:function(){return t.getTooltipOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconPositionStart",{get:function(){return this.iconPosition===t.Position.START},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconPositionEnd",{get:function(){return this.iconPosition===t.Position.END},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"color",{get:function(){return t.getColorOf(this.face)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"style",{get:function(){return t.getStyleOf(this.face)},enumerable:!1,configurable:!0}),e}();q([w.Memoize(),W("design:type",Object),W("design:paramtypes",[])],e.prototype,"text",null),q([w.Memoize(),W("design:type",Object),W("design:paramtypes",[])],e.prototype,"icon",null),q([w.Memoize(),W("design:type",Object),W("design:paramtypes",[])],e.prototype,"iconPosition",null),q([w.Memoize(),W("design:type",Object),W("design:paramtypes",[])],e.prototype,"tooltip",null),q([w.Memoize(),W("design:type",Boolean),W("design:paramtypes",[])],e.prototype,"iconPositionStart",null),q([w.Memoize(),W("design:type",Boolean),W("design:paramtypes",[])],e.prototype,"iconPositionEnd",null),q([w.Memoize(),W("design:type",String),W("design:paramtypes",[])],e.prototype,"color",null),q([w.Memoize(),W("design:type",String),W("design:paramtypes",[])],e.prototype,"style",null),t.Adapter=e}(t.CommandFace||(t.CommandFace={}));var nt=function(t){function e(e,n){var o=t.call(this)||this;return o.element=e,o.parent=n,n&&o.registerDisposable(o.parent.register(o)),o}return B(e,t),Object.defineProperty(e.prototype,"componentIndex",{get:function(){return this.computeComponentIndex()},enumerable:!1,configurable:!0}),e.prototype.computeComponentIndex=function(){for(var t=this.element.nativeElement,e=0;t=t.previousElementSibling;)e++;return e},e.prototype.getFace=function(){},e}(Y),ot=new n.InjectionToken("popup-component"),it=function(e){function n(n,o){var i=e.call(this,n,o)||this;i.CommandFace=t.CommandFace;var r=I.Dsl.disposeWith(i),a=r.chain;r.switchOn;return i.faces=a(i.command.busy).mapToList((function(t){return t?[i.busyFaceModel.value,i.faceModel.value]:[i.faceModel.value,i.busyFaceModel.value]}),{allowNil:!0,dependsOn:[i.faceModel,i.busyFaceModel]}).rejectNil(),i.activeFace=i.faces.first(),i.buttonStyle=a(i.activeFace).map((function(e){return t.CommandFace.getStyleOf(e)})),i.colorModel=a(i.activeFace).map((function(e){return t.CommandFace.getColorOf(e)})),i}return B(n,e),n.prototype.isActive=function(t){return this.activeFace.query().equals(t)},n.prototype.ngOnInit=function(){},n.prototype.ngAfterViewInit=function(){},n.prototype.getFace=function(){return this.face},n}(nt);it.decorators=[{type:n.Component,args:[{selector:"aup-command",template:'<ng-container [ngSwitch]="buttonStyle.value">\n <ng-container *ngSwitchCase="CommandFace.Style.STROKED">\n <button mat-stroked-button [pectinCommand]="command" [color]="colorModel.value" [class.busy]="command.busy.value">\n <aup-command-face class="centered" [faces]="faces.value"></aup-command-face>\n </button>\n </ng-container>\n <ng-container *ngSwitchCase="CommandFace.Style.RAISED">\n <button mat-raised-button [pectinCommand]="command" [color]="colorModel.value" [class.busy]="command.busy.value">\n <aup-command-face class="centered" [faces]="faces.value"></aup-command-face>\n </button>\n </ng-container>\n <ng-container *ngSwitchDefault>\n <button mat-button [pectinCommand]="command" [color]="colorModel.value" [class.busy]="command.busy.value">\n <aup-command-face class="centered" [faces]="faces.value"></aup-command-face>\n </button>\n </ng-container>\n</ng-container>\n',styles:[":host{display:inline-flex;flex-direction:row;justify-content:stretch}button{flex:1}"]}]}],it.ctorParameters=function(){return[{type:n.ElementRef},{type:void 0,decorators:[{type:n.Inject,args:[ot]},{type:n.Optional}]}]},it.propDecorators={command:[{type:n.Input}],faceModel:[{type:n.Input}],face:[{type:n.Input}],busyFaceModel:[{type:n.Input}],busyFace:[{type:n.Input}]},q([I.TrackExternal(),W("design:type",I.Command)],it.prototype,"command",void 0),q([I.TrackExternal(),W("design:type",I.ValueModel)],it.prototype,"faceModel",void 0),q([I.StoreInValueModel("faceModel"),W("design:type",Object)],it.prototype,"face",void 0),q([I.TrackExternal(),W("design:type",I.ValueModel)],it.prototype,"busyFaceModel",void 0),q([I.StoreInValueModel("busyFaceModel"),W("design:type",Object)],it.prototype,"busyFace",void 0),t.CommandContainer=function(t){function e(e){var n=t.call(this)||this;return n.parent=e,n}return B(e,t),Object.defineProperty(e.prototype,"depth",{get:function(){return this.hasParent()?this.parent.depth+1:0},enumerable:!1,configurable:!0}),e.prototype.hasParent=function(){return!!this.parent},Object.defineProperty(e.prototype,"orientation",{get:function(){return e.Orientation.VERTICAL},enumerable:!1,configurable:!0}),e}(I.GarbageCollector),(t.CommandContainer||(t.CommandContainer={})).Orientation=M.Enum({HORIZONTAL:"horizontal",VERTICAL:"vertical"});var rt=function(e){function n(){return e.call(this)||this}return B(n,e),Object.defineProperty(n.prototype,"orientation",{get:function(){return t.CommandContainer.Orientation.HORIZONTAL},enumerable:!1,configurable:!0}),n.prototype.ngOnInit=function(){},n.prototype.ngAfterContentInit=function(){},n.prototype.ngAfterViewInit=function(){},n}(t.CommandContainer);rt.decorators=[{type:n.Component,args:[{selector:"aup-tool-bar",template:'<div class="toolbar-content"><ng-content></ng-content></div>',encapsulation:n.ViewEncapsulation.None,styles:[":host{display:inline-block}.toolbar-content{align-items:center;display:inline-flex;flex-direction:row}.toolbar-content>aup-separator{-ms-grid-row-align:stretch;align-self:stretch;margin:4px 0 4px 8px}.toolbar-content>aup-flex{flex:1}.toolbar-content>*+*{margin-left:8px}"]}]}],rt.ctorParameters=function(){return[]};var at=function(e){function n(t,n,o){var i=e.call(this,t,n)||this;return i.containerParent=o,i}return B(n,e),n.prototype.isHorizontalContainer=function(){return this.containerParent instanceof rt&&this.containerParent.orientation===t.CommandContainer.Orientation.HORIZONTAL},n.prototype.ngOnInit=function(){},n}(nt);at.decorators=[{type:n.Component,args:[{selector:"aup-separator",template:'\n <mat-divider [vertical]="!isHorizontalContainer()"></mat-divider>',styles:[":host {\n }",":host(.horizontal-container) {\n display: inline-flex;\n flex-direction: row;\n align-items: stretch;\n }"]}]}],at.ctorParameters=function(){return[{type:n.ElementRef},{type:void 0,decorators:[{type:n.Optional},{type:n.Inject,args:[ot]}]},{type:t.CommandContainer,decorators:[{type:n.Optional}]}]},at.propDecorators={isHorizontalContainer:[{type:n.HostBinding,args:["class.horizontal-container"]}]};var ct=function(e){function n(n,o){var i=e.call(this,n,o)||this;i._unorderedChildren=new I.MutableListModel,i.faceModelDelegate=new I.DelegatingValueModel,i.xPosition="after",i.yPosition="below";var r=I.Dsl.disposeWith(i),a=r.chain;r.valueOf,r.before,r.when,r.after,r.observe,r.switchOn;return i.faceAdapterModel=a(i.faceModelDelegate).map((function(e){return new t.CommandFace.Adapter(e)})),i.children=a(i._unorderedChildren).sortBy("componentIndex"),i}return B(n,e),n.prototype.ngAfterContentChecked=function(){this._unorderedChildren.value=X(this._unorderedChildren.value)},Object.defineProperty(n.prototype,"faceAdapter",{get:function(){return this.faceAdapterModel.value},enumerable:!1,configurable:!0}),n.prototype.isRoot=function(){return!this.parent},n.prototype.register=function(t){var e=this;return this._unorderedChildren.push(t),I.Disposable.disposableThatRuns((function(){e._unorderedChildren.remove(t)}))},n.prototype.onCommandFired=function(){this.triggers.forEach((function(t){t.menuOpen&&t.closeMenu()}))},n.prototype.getFace=function(){return this.faceAdapter.face},n}(nt);ct.decorators=[{type:n.Component,args:[{selector:"aup-abstract-popup-menu",template:""}]}],ct.ctorParameters=function(){return[{type:n.ElementRef},{type:void 0,decorators:[{type:n.Inject,args:[ot]}]}]},ct.propDecorators={xPosition:[{type:n.Input}],yPosition:[{type:n.Input}],triggers:[{type:n.ViewChildren,args:[g.MatMenuTrigger]}]};var st=function(e){function o(){var o=e.call(this)||this;o._childList=new I.DelegatingListModel,o.commandFired=new n.EventEmitter,o.TrackBy=t.TrackBy;var i=I.Dsl.disposeWith(o),r=i.chain,a=i.valueOf,c=(i.before,i.when,i.after,i.observe,i.switchOn,r(o._childList).map((function(t){return t.getFace()})).rejectNil()),s=c.select((function(e){return!!t.CommandFace.getIconOf(e)})).count(),l=c.count();return o.hasMixedIcons=a.all(s.isGreaterThan(0),l.doesNotEqual(s)).areTruthy(),o}return B(o,e),Object.defineProperty(o.prototype,"parent",{get:function(){return this._parentComponent},set:function(t){this._parentComponent=t,this._childList.setDelegate(t.children)},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"children",{get:function(){return this.parent.children.value},enumerable:!1,configurable:!0}),o.prototype.executeCommand=function(t){var e=this;this.isCommand(t)&&t.command.execute().finally((function(){e.commandFired.emit()}))},o.prototype.isEnabled=function(t){return!0},o.prototype.onCommandFired=function(){this.commandFired.emit(),this.triggers.forEach((function(t){t.menuOpen&&t.closeMenu()}))},o.prototype.isCommand=function(t){return t instanceof it},o.prototype.isPopupMenu=function(t){return t instanceof ct},o.prototype.isSeparator=function(t){return t instanceof at},o.prototype.getTooltip=function(e){return this.isCommand(e)?t.CommandFace.getTooltipOf(e.face):void 0},o.prototype.getFaces=function(t){return this.isCommand(t)?t.faces.value:this.isPopupMenu(t)?[t.faceAdapter.face]:void 0},o}(Y);st.decorators=[{type:n.Component,args:[{selector:"aup-popup-menu-renderer",template:'<mat-menu #menu [xPosition]="parent.xPosition" [yPosition]="parent.yPosition">\n <ng-template matMenuContent>\n <ng-container *ngFor="let child of children; trackBy: TrackBy.byIndex" >\n <button *ngIf="isCommand(child)"\n (click)="executeCommand(child)"\n [disabled]="!isEnabled(child)"\n [matTooltip]="getTooltip(child)"\n mat-menu-item>\n <aup-command-face [faces]="getFaces(child)"\n [includeMissingIconInLayout]="hasMixedIcons.value"></aup-command-face>\n </button>\n\n <ng-container *ngIf="isPopupMenu(child)">\n <button mat-menu-item\n matMenuTrigger\n [matMenuTriggerFor]="innerPanel.menuComponent"\n >\n <aup-command-face [faces]="getFaces(child)"\n [includeMissingIconInLayout]="hasMixedIcons.value"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #innerPanel\n [parent]="child"\n (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n\n <mat-divider *ngIf="isSeparator(child)"></mat-divider>\n\n </ng-container>\n\n </ng-template>\n</mat-menu>\n'}]}],st.ctorParameters=function(){return[]},st.propDecorators={parent:[{type:n.Input}],menuComponent:[{type:n.ViewChild,args:["menu",{static:!0}]}],commandFired:[{type:n.Output}],triggers:[{type:n.ViewChildren,args:[g.MatMenuTrigger]}]};var lt=function(e){function n(){var n=e.call(this)||this;n.facesModel=new I.MutableListModel,n.ignoreIcon=!1,n.ignoreText=!1,n.includeMissingIconInLayout=!1;var o=I.Dsl.disposeWith(n),i=o.chain;o.valueOf,o.before,o.when,o.after,o.observe,o.switchOn;n.faceAdapters=i(n.facesModel).map((function(e){return new t.CommandFace.Adapter(e)}));var r=n.faceAdapters.first();return n.activeIcon=r.pluck("icon"),n.activeColor=r.pluck("color"),n}return B(n,e),Object.defineProperty(n.prototype,"requiresMissingIconInLayout",{get:function(){return this.includeMissingIconInLayout&&!this.activeIcon.value},enumerable:!1,configurable:!0}),n.prototype.ngOnInit=function(){},n.prototype.shouldIncludeIcon=function(t){return!this.ignoreIcon&&t.icon||this.includeMissingIconInLayout},n.prototype.hasIconStart=function(e){return this.shouldIncludeIcon(e)&&(!e.iconPosition||e.iconPosition===t.CommandFace.Position.START)},n.prototype.hasIconEnd=function(e){return this.shouldIncludeIcon(e)&&e.iconPosition===t.CommandFace.Position.END},Object.defineProperty(n.prototype,"color",{get:function(){return this.activeColor.value},enumerable:!1,configurable:!0}),n}(Y);lt.decorators=[{type:n.Component,args:[{selector:"aup-command-face",template:'<div class="face-container" *ngFor="let face of faceAdapters.value">\n <aup-icon *ngIf="hasIconStart(face)" [icon]="face.icon"></aup-icon>\n <span *ngIf="face.text">{{face.text}}</span>\n <aup-icon *ngIf="hasIconEnd(face)" [icon]="face.icon"></aup-icon>\n</div>\n',encapsulation:n.ViewEncapsulation.None,styles:["aup-command-face{--icon-gap:var(--aup-command-face-icon-gap);display:-ms-inline-grid;display:inline-grid}aup-command-face>.face-container{-ms-grid-column:1;-ms-grid-row:1;align-items:center;display:inline-flex;flex-direction:row;grid-column:1;grid-row:1}aup-command-face>.face-container:not(:first-child){visibility:hidden}aup-command-face>.face-container *+*{margin-left:var(--icon-gap)}aup-command-face.hide-icon aup-icon{visibility:hidden}aup-command-face.centered{justify-items:center}"]}]}],lt.ctorParameters=function(){return[]},lt.propDecorators={_rawFaces:[{type:n.Input,args:["faces"]}],ignoreIcon:[{type:n.Input}],ignoreText:[{type:n.Input}],includeMissingIconInLayout:[{type:n.Input}],requiresMissingIconInLayout:[{type:n.HostBinding,args:["class.hide-icon"]}],color:[{type:n.HostBinding,args:["attr.color"]}]},q([I.StoreInListModel("facesModel"),W("design:type",Array)],lt.prototype,"_rawFaces",void 0);var ut=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.ngOnInit=function(){},e}(Y);ut.decorators=[{type:n.Component,args:[{selector:"aup-flex",template:""}]}],ut.ctorParameters=function(){return[]};var pt=function(t){function e(e,n){var o=t.call(this,e,n)||this;o.tooltipModel=new I.MutableValueModel;var i=I.Dsl.disposeWith(o),r=i.chain;i.valueOf,i.before,i.when,i.after,i.observe,i.switchOn;return o.faceModelDelegate.setDelegate(r(o.tooltipModel).map((function(t){return{icon:function(){return"mat:more_vert"},tooltip:function(){return t}}}),{allowNil:!0})),o}return B(e,t),Object.defineProperty(e.prototype,"face",{get:function(){return this.faceModelDelegate.value},enumerable:!1,configurable:!0}),e}(ct);pt.decorators=[{type:n.Component,args:[{selector:"aup-more-menu",template:'<div class="content" style="display: none">\n <ng-content></ng-content>\n</div>\n<ng-container *ngIf="isRoot()">\n <ng-container *ngIf="faceAdapter.text" [ngSwitch]="faceAdapter.style">\n <ng-container *ngSwitchCase="\'stroked\'">\n <button matMenuTrigger\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n mat-stroked-button>\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]="this"\n (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchCase="\'raised\'">\n <button matMenuTrigger\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n mat-raised-button>\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]="this"\n (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button matMenuTrigger\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n mat-button>\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu [parent]="this" (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n\n </ng-container>\n\n <ng-container *ngIf="!faceAdapter.text">\n <button matMenuTrigger\n mat-icon-button\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n >\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]="this"\n (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n</ng-container>\n',providers:[{provide:ot,useExisting:pt}]}]}],pt.ctorParameters=function(){return[{type:n.ElementRef},{type:void 0,decorators:[{type:n.Inject,args:[ot]},{type:n.Optional},{type:n.SkipSelf}]}]},pt.propDecorators={tooltip:[{type:n.Input}]},q([I.StoreInValueModel("tooltipModel"),W("design:type",String)],pt.prototype,"tooltip",void 0);var dt=function(t){function e(e,n){var o=t.call(this,e,n)||this,i=I.Dsl.disposeWith(o);i.chain,i.valueOf,i.before,i.when,i.after,i.observe,i.switchOn;return o}return B(e,t),e}(ct);dt.decorators=[{type:n.Component,args:[{selector:"aup-popup-menu",template:'<div class="content" style="display: none">\n <ng-content></ng-content>\n</div>\n<ng-container *ngIf="isRoot()">\n <ng-container *ngIf="faceAdapter.text" [ngSwitch]="faceAdapter.style">\n <ng-container *ngSwitchCase="\'stroked\'">\n <button matMenuTrigger\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n mat-stroked-button>\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]="this"\n (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchCase="\'raised\'">\n <button matMenuTrigger\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n mat-raised-button>\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]="this"\n (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button matMenuTrigger\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n mat-button>\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu [parent]="this" (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n\n </ng-container>\n\n <ng-container *ngIf="!faceAdapter.text">\n <button matMenuTrigger\n mat-icon-button\n [matMenuTriggerFor]="subMenu.menuComponent"\n [matTooltip]="faceAdapter.tooltip"\n [color]="faceAdapter.color"\n >\n <aup-command-face [faces]="[face]"></aup-command-face>\n </button>\n <aup-popup-menu-renderer #subMenu\n [parent]="this"\n (commandFired)="onCommandFired()"></aup-popup-menu-renderer>\n </ng-container>\n</ng-container>\n',providers:[{provide:ot,useExisting:dt}]}]}],dt.ctorParameters=function(){return[{type:n.ElementRef},{type:void 0,decorators:[{type:n.Inject,args:[ot]},{type:n.Optional},{type:n.SkipSelf}]}]},dt.propDecorators={faceModel:[{type:n.Input}],face:[{type:n.Input}]},q([I.TrackExternal({delegateTo:"faceModelDelegate"}),W("design:type",I.ValueModel)],dt.prototype,"faceModel",void 0),q([I.StoreInValueModel("faceModel"),W("design:type",Object)],dt.prototype,"face",void 0);var ft=function(t){function e(e){var n=t.call(this)||this;return n.focusManager=e,n.restoreFocusCommand=I.Command.create((function(){n.restoreFocus()})),n.tabIndex=-1,n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.restoreFocus=function(){this.focusManager.restoreFocus()},e}(Y);ft.decorators=[{type:n.Component,args:[{selector:"aup-focus-container",template:"<ng-content></ng-content>\n",providers:[{provide:I.FocusManager}],styles:[":host{display:block}"]}]}],ft.ctorParameters=function(){return[{type:I.FocusManager,decorators:[{type:n.Self}]}]},ft.propDecorators={tabIndex:[{type:n.HostBinding,args:["attr.tabindex"]}]};var mt=function(t){function e(e,n,o){var i=t.call(this)||this;i.el=e,i.focusManager=n;var r=I.Dsl.disposeWith(i);r.chain,r.valueOf,r.before,r.when,r.after,r.observe,r.switchOn;return i.focusManager&&(i._focusContext=i.focusManager.registerFocusable(i),i.registerDisposable(i._focusContext),i.registerDisposable(o.createBinding(e.nativeElement,i.focusContext))),i}return B(e,t),Object.defineProperty(e.prototype,"focusable",{get:function(){return this.focusContext?0:void 0},enumerable:!1,configurable:!0}),e.prototype.onFocus=function(){var t;null===(t=this.focusContext)||void 0===t||t.notifyFocusIn()},e.prototype.onBlur=function(){var t;null===(t=this.focusContext)||void 0===t||t.notifyFocusOut()},Object.defineProperty(e.prototype,"focusContext",{get:function(){return this._focusContext},enumerable:!1,configurable:!0}),e}(Y);mt.decorators=[{type:n.Component,args:[{template:""}]}],mt.ctorParameters=function(){return[{type:n.ElementRef},{type:I.FocusManager},{type:Z}]},mt.propDecorators={focusable:[{type:n.HostBinding,args:["attr.tabindex"]}],onFocus:[{type:n.HostListener,args:["focus"]}],onBlur:[{type:n.HostListener,args:["blur"]}]};var ht=function(t){function e(){var e=t.call(this)||this;e.onValueEditedListeners=new I.EventListenerList,e.dense=!1,e.focus=new n.EventEmitter,e.blur=new n.EventEmitter,e.enterKey=new n.EventEmitter,e.escapeKey=new n.EventEmitter,e.baseClassName="aup-input-component";var o=e;return e.errorStateMatcher={isErrorState:function(t,e){return o.hasErrors()}},e}return B(e,t),e.prototype.notifyClick=function(){this.safelyInvoke(this.clickCommand)},e.prototype.notifyFocusIn=function(){this.safelyInvoke(this.focusCommand),this.focus.emit()},e.prototype.notifyFocusOut=function(){this.safelyInvoke(this.blurCommand),this.blur.emit()},e.prototype.notifyEnterKey=function(){this.safelyInvoke(this.enterCommand),this.enterKey.emit()},e.prototype.notifyEscapeKey=function(){this.safelyInvoke(this.escapeCommand),this.escapeKey.emit()},e.prototype.safelyInvoke=function(t){t&&t.enabled.value&&t.execute()},e.prototype.ngOnInit=function(){},e.prototype.isEnabled=function(){return this.enabled.value},Object.defineProperty(e.prototype,"enabled",{get:function(){return this.formValueModel.enabled},enumerable:!1,configurable:!0}),e.prototype.hasErrors=function(){return!this.errorList.query().isEmpty()},Object.defineProperty(e.prototype,"errorList",{get:function(){return this.formValueModel.errorList},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstError",{get:function(){return this.hasErrors()?this.errorList.value[0]:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"focusContext",{get:function(){return this.formValueModel.focusContext},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"floatLabel",{get:function(){return this.dense?"never":this.userFloatLabel},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showHint",{get:function(){return!this.dense&&!!this.hint},enumerable:!1,configurable:!0}),e.prototype.onValueEdited=function(t){return this.onValueEditedListeners.add(t)},e}(Y);ht.decorators=[{type:n.Component,args:[{template:""}]}],ht.ctorParameters=function(){return[]},ht.propDecorators={label:[{type:n.Input}],userFloatLabel:[{type:n.Input,args:["floatLabel"]}],hint:[{type:n.Input}],placeholder:[{type:n.Input}],dense:[{type:n.HostBinding,args:["class.dense"]},{type:n.Input}],focusCommand:[{type:n.Input,args:["command.focus"]}],blurCommand:[{type:n.Input,args:["command.blur"]}],enterCommand:[{type:n.Input,args:["command.enter"]}],escapeCommand:[{type:n.Input,args:["command.escape"]}],clickCommand:[{type:n.Input,args:["command.click"]}],focus:[{type:n.Output}],blur:[{type:n.Output}],enterKey:[{type:n.Output}],escapeKey:[{type:n.Output}],baseClassName:[{type:n.HostBinding,args:["class"]}],notifyClick:[{type:n.HostListener,args:["click"]}],notifyFocusIn:[{type:n.HostListener,args:["focusin"]}],notifyFocusOut:[{type:n.HostListener,args:["focusout"]}]};var gt=function(t){function e(){var e=t.call(this)||this;e.formValueModel=e.registerDisposable(new I.Form.DelegatingListModel),e.componentListModel=new I.MutableListModel,e.setValueIsInProgress=new I.Guard,e.valueChange=new n.EventEmitter;var o=I.Dsl.disposeWith(e),i=o.when,r=o.valueOf,a=o.chain,c=new I.Binding.Identity(e.formValueModel,e.componentListModel).writeRight(),s=r.any(e.setValueIsInProgress,a(c.direction).equals(I.Binding.Direction.RIGHT)).areTruthy();return i(e.componentListModel).changes((function(t,n){e.valueChange.emit(t),e.onValueEditedListeners.fire((function(e){return e(t,n)}))}),{initialValue:"ignore",unless:s}),I.DebugContext.tag(e.formValueModel,e.constructor.name+".formValueModel"),e}return B(e,t),Object.defineProperty(e.prototype,"value",{set:function(t){var e=this;this.setValueIsInProgress.whileTrue((function(){e.listHolder?e.listHolder.value=t:(e.listHolder=new I.MutableListModel(t),e.listModel=e.listHolder)}))},enumerable:!1,configurable:!0}),e}(ht);gt.decorators=[{type:n.Component,args:[{template:""}]}],gt.ctorParameters=function(){return[]},gt.propDecorators={listModel:[{type:n.Input}],value:[{type:n.Input}],valueChange:[{type:n.Output}]},q([I.TrackExternal({delegateTo:"formValueModel"}),W("design:type",Object)],gt.prototype,"listModel",void 0);var yt=function(t){function e(){var e=t.call(this)||this;e.formValueModel=e.registerDisposable(new I.Form.DelegatingValueModel),e.setValueInProgress=new I.Guard,e.componentValueModel=new I.MutableValueModel,e.valueChange=new n.EventEmitter;var o=I.Dsl.disposeWith(e),i=o.when,r=o.chain,a=o.valueOf,c=new I.Binding.Identity(e.formValueModel,e.componentValueModel).writeRight(),s=a.any(e.setValueInProgress,r(c.direction).equals(I.Binding.Direction.RIGHT)).areTruthy();return i(e.componentValueModel).changes((function(t,n){e.valueChange.emit(t),e.onValueEditedListeners.fire((function(e){return e(t,n)}))}),{initialValue:"ignore",unless:s}),I.DebugContext.tag(e.formValueModel,e.constructor.name+".formValueModel"),e}return B(e,t),Object.defineProperty(e.prototype,"value",{set:function(t){var e=this;this.setValueInProgress.whileTrue((function(){e.plainValueHolder?e.plainValueHolder.value=t:(e.plainValueHolder=new I.MutableValueModel(t),e.valueModel=e.plainValueHolder)}))},enumerable:!1,configurable:!0}),e}(ht);yt.decorators=[{type:n.Component,args:[{template:""}]}],yt.ctorParameters=function(){return[]},yt.propDecorators={valueModel:[{type:n.Input}],value:[{type:n.Input}],valueChange:[{type:n.Output}]},q([I.TrackExternal({delegateTo:"formValueModel"}),W("design:type",Object)],yt.prototype,"valueModel",void 0);var vt=function(t){function e(){var e=t.call(this)||this;e.filterValue=new I.MutableValueModel,e.optionLabelFormat=function(t){return t&&e.optionLabel?t[e.optionLabel]:t};var n=I.Dsl.disposeWith(e),o=n.chain,i=(n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn,o(e.filterValue).map((function(t){return j.default.isString(t)?t.toLowerCase():""})));return e.filteredOptions=o(e.optionsModel).select((function(t){return j.default.isEmpty(e.filterValue.value)||e.optionLabelFormat(t).toString().toLowerCase().includes(i.value)}),{dependsOn:i}),e}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.formatOption=function(t){return this.optionLabelFormat(t)},e.prototype.updateFilter=function(t){this.filterValue.value=t},e.prototype.onSelect=function(t){this.valueModel.value=t.option.value},e}(yt);vt.decorators=[{type:n.Component,args:[{selector:"aup-autocomplete-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input type="string"\n matInput\n [matAutocomplete]="autocomplete"\n placeholder="{{placeholder}}"\n [ngModel]="componentValueModel.value"\n (ngModelChange)="updateFilter($event)"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-autocomplete #autocomplete [displayWith]="optionLabelFormat" [autoActiveFirstOption]="true" (optionSelected)="onSelect($event)">\n <mat-option *ngFor="let option of filteredOptions.value; let i = index"\n [value]="option"\n >{{formatOption(option)}}</mat-option>\n <mat-option *ngIf="allowNil">{{placeholder}}</mat-option>\n </mat-autocomplete>\n\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[":host{display:inline-block}mat-form-field{width:100%}"]}]}],vt.ctorParameters=function(){return[]},vt.propDecorators={optionsModel:[{type:n.Input}],options:[{type:n.Input}],optionLabel:[{type:n.Input}],allowNil:[{type:n.Input}],nilOptionTemplateRef:[{type:n.ContentChild,args:["nilOptionTemplate"]}],optionLabelFormat:[{type:n.Input}]},q([I.TrackExternal(),W("design:type",I.ListModel)],vt.prototype,"optionsModel",void 0),q([I.StoreInListModel("optionsModel"),W("design:type",Array)],vt.prototype,"options",void 0);var bt=function(t){function e(){var e=t.call(this)||this;return e.color="accent",e.labelPosition="after",e}return B(e,t),e.prototype.ngOnInit=function(){},e}(yt);bt.decorators=[{type:n.Component,args:[{selector:"aup-checkbox-input",template:'\x3c!-- TODO: add focus binding --\x3e\n<mat-checkbox\n [(ngModel)]="componentValueModel.value"\n [color]="color"\n [labelPosition]="labelPosition"\n [disabled]="!isEnabled()"\n>{{label}}</mat-checkbox>\n<mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n<mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n',styles:[":host{display:inline-flex;flex-direction:column;padding:24px 0 16px}:host.dense{padding:6px 0 2px}mat-error,mat-hint{font-size:12px;font-weight:400;line-height:13.5px;margin-left:24px;margin-top:4px}"]}]}],bt.ctorParameters=function(){return[]},bt.propDecorators={color:[{type:n.Input}],labelPosition:[{type:n.Input}]};var Ct=function(t){function e(){var e=t.call(this)||this;return e.optionLabelFormat=function(t){return t&&e.optionLabel?t[e.optionLabel]:t},e}return B(e,t),e.prototype.ngOnInit=function(){},e}(gt);Ct.decorators=[{type:n.Component,args:[{selector:"aup-multiple-select-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <mat-select placeholder="{{placeholder}}"\n multiple\n [(ngModel)]="componentListModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-option *ngFor="let option of optionsModel.value; let i = index" [value]="option">\n <ng-container *ngIf="!optionTemplateRef">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf="optionTemplateRef"\n [ngTemplateOutlet]="optionTemplateRef"\n [ngTemplateOutletContext]="{ $implicit: option, index: i }"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[":host{display:inline-block}mat-form-field{width:100%}"]}]}],Ct.ctorParameters=function(){return[]},Ct.propDecorators={optionsModel:[{type:n.Input}],options:[{type:n.Input}],optionLabel:[{type:n.Input}],optionTemplateRef:[{type:n.ContentChild,args:["optionTemplate"]}],optionLabelFormat:[{type:n.Input}]},q([I.TrackExternal(),W("design:type",I.ListModel)],Ct.prototype,"optionsModel",void 0),q([I.StoreInListModel("optionsModel"),W("design:type",Array)],Ct.prototype,"options",void 0);var It=function(t){function e(){var e=t.call(this)||this;return e.min=Number.MIN_SAFE_INTEGER,e.max=Number.MAX_SAFE_INTEGER,e}return B(e,t),e.prototype.ngOnInit=function(){},e}(yt);It.decorators=[{type:n.Component,args:[{selector:"aup-number-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input type="number"\n matInput\n placeholder="{{placeholder}}"\n [attr.autocomplete]="autocomplete"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n [min]="min"\n [max]="max"\n >\n <mat-hint *ngIf="hint && !dense" >{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[""]}]}],It.ctorParameters=function(){return[]},It.propDecorators={autocomplete:[{type:n.Input}],min:[{type:n.Input}],max:[{type:n.Input}]};var wt=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.ngOnInit=function(){},e}(yt);wt.decorators=[{type:n.Component,args:[{selector:"aup-password-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input type="password"\n matInput\n placeholder="{{placeholder}}"\n [attr.autocomplete]="autocomplete"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n\n',styles:[""]}]}],wt.ctorParameters=function(){return[]},wt.propDecorators={autocomplete:[{type:n.Input}]};var Pt=function(t){function e(){var e=t.call(this)||this;return e.optionLabelFormat=function(t){return t&&e.optionLabel?t[e.optionLabel]:t},e}return B(e,t),e.prototype.ngOnInit=function(){},e}(yt);Pt.decorators=[{type:n.Component,args:[{selector:"aup-select-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <mat-select placeholder="{{placeholder}}"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-option *ngIf="allowNil">\n <ng-container *ngIf="!nilOptionTemplateRef">{{placeholder}}</ng-container>\n <ng-container *ngIf="nilOptionTemplateRef" [ngTemplateOutlet]="nilOptionTemplateRef"></ng-container>\n </mat-option>\n <mat-option *ngFor="let option of optionsModel.value; let i = index" [value]="option">\n <ng-container *ngIf="!optionTemplateRef">{{optionLabelFormat(option)}}</ng-container>\n <ng-container *ngIf="optionTemplateRef"\n [ngTemplateOutlet]="optionTemplateRef"\n [ngTemplateOutletContext]="{ $implicit: option, index: i }"\n >\n </ng-container>\n </mat-option>\n </mat-select>\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n',styles:[":host{display:inline-block}mat-form-field{width:100%}"]}]}],Pt.ctorParameters=function(){return[]},Pt.propDecorators={optionsModel:[{type:n.Input}],options:[{type:n.Input}],optionLabel:[{type:n.Input}],allowNil:[{type:n.Input}],optionTemplateRef:[{type:n.ContentChild,args:["optionTemplate"]}],nilOptionTemplateRef:[{type:n.ContentChild,args:["nilOptionTemplate"]}],optionLabelFormat:[{type:n.Input}]},q([I.TrackExternal(),W("design:type",I.ListModel)],Pt.prototype,"optionsModel",void 0),q([I.StoreInListModel("optionsModel"),W("design:type",Array)],Pt.prototype,"options",void 0);var Mt=function(t){function e(){var e=t.call(this)||this,n=I.Dsl.disposeWith(e),o=n.chain;n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn;return e.clearCommand=I.Command.create((function(){e.componentValueModel.value=null})),e.clearCommand.disableWhile(o.stringValue(e.componentValueModel).isBlank()),e}return B(e,t),e.prototype.ngOnInit=function(){},e}(yt);Mt.decorators=[{type:n.Component,args:[{selector:"aup-string-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <input matInput\n placeholder="{{placeholder}}"\n [attr.autocomplete]="autocomplete"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n >\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n <button mat-button mat-icon-button matSuffix *ngIf="enableClear" [pectinCommand]="clearCommand">\n <aup-icon icon="mat:close"></aup-icon>\n </button>\n</mat-form-field>\n\n',styles:["button[disabled]{visibility:hidden}"]}]}],Mt.ctorParameters=function(){return[]},Mt.propDecorators={autocomplete:[{type:n.Input}],enableClearModel:[{type:n.Input}],enableClear:[{type:n.Input}]},q([I.TrackExternal({defaultValue:!1}),W("design:type",I.ValueModel)],Mt.prototype,"enableClearModel",void 0),q([I.StoreInValueModel("enableClearModel"),W("design:type",Boolean)],Mt.prototype,"enableClear",void 0);var xt=function(t){function e(){var e=t.call(this)||this;return e.rows=2,e}return B(e,t),e.prototype.ngOnInit=function(){},e}(yt);xt.decorators=[{type:n.Component,args:[{selector:"aup-text-input",template:'<mat-form-field appearance="standard" [floatLabel]="floatLabel">\n <mat-label *ngIf="label">{{label}}</mat-label>\n <textarea matInput\n placeholder="{{placeholder}}"\n [(ngModel)]="componentValueModel.value"\n [disabled]="!enabled.value"\n (keydown.enter)="notifyEnterKey()"\n (keydown.escape)="notifyEscapeKey()"\n [pectinFocusBinding]="focusContext"\n [errorStateMatcher]="errorStateMatcher"\n [rows]="rows"\n [cols]="cols"\n >\n </textarea>\n <mat-hint *ngIf="showHint">{{hint}}</mat-hint>\n <mat-error *ngIf="hasErrors">{{firstError}}</mat-error>\n</mat-form-field>\n\n',styles:["button[disabled]{visibility:hidden}textarea{overflow:auto}"]}]}],xt.ctorParameters=function(){return[]},xt.propDecorators={rows:[{type:n.Input}],cols:[{type:n.Input}]},t.IconComponent=function(){function t(){this.allowedPrefixes=M.Enum.values(t.IconPrefix).map((function(t){return t+":"})),this.iconPrefix=t.IconPrefix}return Object.defineProperty(t.prototype,"icon",{get:function(){return this._icon},set:function(t){if(this._icon=t,!t)return this.errorMessage="icon is nil",void(this.prefix=void 0);var e=t.indexOf(":");e>0&&(this.prefix=this.icon.slice(0,e),this.suffix=this.icon.slice(e+1)),this.prefix&&(this.errorMessage='Unknown icon "'+t+'"'),this.errorMessage="Unknown icon prefix, expected one of ["+this.allowedPrefixes.join(",")+'] got "'+this.prefix+':"'},enumerable:!1,configurable:!0}),t}(),t.IconComponent.decorators=[{type:n.Component,args:[{selector:"aup-icon",template:'<ng-container [ngSwitch]="prefix">\n\n <mat-icon *ngSwitchCase="iconPrefix.SVG"\n [svgIcon]="suffix"\n class="svgIcon">\n </mat-icon>\n\n <mat-icon *ngSwitchCase="iconPrefix.MATERIAL">\n {{suffix}}\n </mat-icon>\n\n <div *ngSwitchCase="iconPrefix.FONT_AWESOME"\n class="faIconWrapper">\n <fa-icon [icon]="suffix">\n </fa-icon>\n </div>\n\n <mat-icon *ngSwitchDefault\n [matTooltip]="errorMessage">\n bug_report\n </mat-icon>\n\n</ng-container>\n\n',styles:[":host{display:inline-flex;width:24px}fa-icon{vertical-align:middle}.faIconWrapper{text-align:center}.faIconWrapper,.svgIcon{height:24px;width:24px}:host(.mat-chip-remove) mat-icon{font-size:18px}mat-icon{height:inherit;width:inherit}"]}]}],t.IconComponent.propDecorators={icon:[{type:n.Input}]},(t.IconComponent||(t.IconComponent={})).IconPrefix=M.Enum({SVG:"svg",FONT_AWESOME:"fa",MATERIAL:"mat"});var Rt=function(){};Rt.decorators=[{type:n.Component,args:[{selector:"aup-noop",template:"",styles:[":host{display:block}"]}]}],Rt.ctorParameters=function(){return[]};var St=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();St.decorators=[{type:n.Component,args:[{selector:"aup-scroll-container",template:'<div class="container" cdkScrollable>\n <ng-content></ng-content>\n</div>\n',styles:[":host{flex-direction:column;min-height:0}.container,:host{align-items:stretch;display:flex}.container{flex:1;flex-basis:0;flex-direction:column;overflow-y:scroll}"]}]}],St.ctorParameters=function(){return[]};var At=function(){function t(){this.underline=!1}return t.prototype.ngOnInit=function(){},t}();At.decorators=[{type:n.Component,args:[{selector:"aup-section-header",template:"<ng-content></ng-content>\n",styles:[":host{--def-border-bottom-color:var(--border-bottom-color,rgba(0,0,0,0.07));color:rgba(0,0,0,.5);display:block;font-size:12px;line-height:12px;padding:8px 16px}:host.underline{border-bottom:1px solid var(--def-border-bottom-color)}"]}]}],At.ctorParameters=function(){return[]},At.propDecorators={underline:[{type:n.Input},{type:n.HostBinding,args:["class.underline"]}]};var Ot=function(){function t(t){this.templateRef=t}return Object.defineProperty(t.prototype,"name",{get:function(){return this.constructor.name},enumerable:!1,configurable:!0}),t}(),Dt=function(t){function e(e){var n=t.call(this,e)||this;return n.isDefault=!1,n}return B(e,t),e.prototype.matches=function(t){return this.aupSwitchCaseWhen===t},e}(Ot);Dt.decorators=[{type:n.Directive,args:[{selector:"[aupSwitchCaseWhen]",providers:[{provide:Ot,useExisting:Dt}]}]}],Dt.ctorParameters=function(){return[{type:n.TemplateRef}]},Dt.propDecorators={aupSwitchCaseWhen:[{type:n.Input}]};var Tt=function(t){function e(e){var n=t.call(this,e)||this;return n.isDefault=!0,n}return B(e,t),e.prototype.matches=function(t){return!1},e}(Ot);Tt.decorators=[{type:n.Directive,args:[{selector:"[aupSwitchCaseDefault]",providers:[{provide:Ot,useExisting:Tt}]}]}],Tt.ctorParameters=function(){return[{type:n.TemplateRef}]};var Et=function(t){function e(e){var n=t.call(this)||this;return n.cdr=e,n.selectedIndex=0,n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.ngAfterContentInit=function(){var t=this,e=this.switchCaseOptions.changes.subscribe((function(e){return t.updateSelection()}));this.onDispose((function(){return e.unsubscribe()}));var n=I.Dsl.disposeWith(this);n.chain;(0,n.when)(this.switchModel).changes((function(){return t.updateSelection()}),{initialValue:"triggerChange"}),this.cdr.detectChanges()},e.prototype.updateSelection=function(){var t=this,e=[];this.switchCaseOptions.forEach((function(n,o){n.matches(t.switchModel.value)&&e.push(o)})),e.length>1&&console.warn("found "+e.length+" matching case values, displaying the first."),0===e.length&&(this.switchCaseOptions.forEach((function(t,n){e.push(n)})),e.length>1&&console.warn("found "+e.length+" default case values, displaying the first.")),e.length>0?this.selectedIndex=e[0]:(console.warn("found no matching or default case values."),this.selectedIndex=-1)},e}(Y);Et.decorators=[{type:n.Component,args:[{selector:"aup-switch-case",template:'<mat-tab-group class="content-wrapper" no-tab-header full-height-tabs [selectedIndex]="selectedIndex">\n <mat-tab *ngFor="let option of switchCaseOptions">\n <ng-template [ngTemplateOutlet]="option.templateRef"></ng-template>\n </mat-tab>\n</mat-tab-group>\n\n\n',styles:[":host{align-items:stretch;display:flex;flex-direction:column}mat-tab-group{flex:1}"]}]}],Et.ctorParameters=function(){return[{type:n.ChangeDetectorRef}]},Et.propDecorators={switchModel:[{type:n.Input}],switch:[{type:n.Input}],switchCaseOptions:[{type:n.ContentChildren,args:[Ot]}]},q([I.TrackExternal(),W("design:type",I.ValueModel)],Et.prototype,"switchModel",void 0),q([I.StoreInValueModel("switchModel"),W("design:type",Object)],Et.prototype,"switch",void 0);var Ft=Symbol("aup-cell-header-renderer-component-ref"),kt=Symbol("aup-cell-renderer-component-ref"),_t=Symbol("aup-cell-editor-component-ref"),Lt=Symbol("aup-cell-renderer-portal-component"),Vt=Symbol("aup-cell-editor-portal-component"),jt=function(){},Nt=function(t){function e(e,n){var o=t.call(this)||this;return o.componentType=e,o.initialiseHeader=n,o}return B(e,t),e.prototype.initialiseHost=function(t,e){x.assert.isTruthy(t),t[Ft]=new l.ComponentPortal(this.componentType)},e.prototype.onPortalAttached=function(t,e){this.initialiseHeader(e,t.column)},e}(jt),Ut=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e}(jt),Ht=function(t){function e(e,n){var o=t.call(this)||this;return o.componentType=e,o.updateComponent=n,o}return B(e,t),e.prototype.initialiseHost=function(t,e){t[kt]=new l.ComponentPortal(this.componentType)},e.prototype.onPortalAttached=function(t,e){t[Lt]=e,this.updateComponent(e,t.getRowData(),!0)},e.prototype.pushState=function(t){t[Lt]&&this.updateComponent(t[Lt],t.getRowData(),!1)},e}(Ut),Bt=function(t){function e(e,n){var o=t.call(this)||this;return o.componentType=e,o.initialiseEditorSession=n,o}return B(e,t),e.prototype.initialiseHost=function(t,e){x.assert.isTruthy(t),t[_t]=new l.ComponentPortal(this.componentType)},e.prototype.onPortalAttached=function(t,e){t[Vt]=e,this.initialiseEditorSession(e,t.editSession)},e}(jt),qt=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.registerPortal=function(t,e,n,o){this.templateRef=t,this.viewContainer=e,this.fillCell=n,this.padChild=o},e.prototype.initialiseHost=function(t,e){x.assert.isTruthy(t)},e.prototype.onPortalAttached=function(t,e){},e.prototype.pushState=function(t){t[kt]=this.createPortal(t.getRowData()),t.fillCell=this.fillCell,t.padChild=this.padChild},e.prototype.createPortal=function(t){return new l.TemplatePortal(this.templateRef,this.viewContainer,Object.assign(Object.assign({},t),{$implicit:t.row}))},e}(Ut),Wt=function(){function t(){}return Object.defineProperty(t.prototype,"value",{get:function(){return this._value},set:function(t){this._value=t},enumerable:!1,configurable:!0}),t}();Wt.decorators=[{type:n.Component,args:[{selector:"aup-default-cell-renderer",template:"{{value}}\n",styles:[""]}]}],Wt.ctorParameters=function(){return[]},Wt.propDecorators={value:[{type:n.Input}]};var zt=function(){};zt.decorators=[{type:n.Component,args:[{selector:"aup-default-header-renderer",template:"{{headerText}}\n",styles:[""]}]}],zt.ctorParameters=function(){return[]},zt.propDecorators={headerText:[{type:n.Input}]};var Gt=function(t){function e(){var e=t.call(this)||this;return e.saveCommand=I.Command.create((function(){e.editSession.saveCommand.execute(e.editSession.form).then((function(t){t&&e.editSession.dispose()}))})),e.cancelCommand=I.Command.create((function(){e.editSession.dispose()})),e}return B(e,t),e.prototype.ngOnInit=function(){},Object.defineProperty(e.prototype,"form",{get:function(){var t;return null===(t=this.editSession)||void 0===t?void 0:t.form},enumerable:!1,configurable:!0}),e}(Y);Gt.decorators=[{type:n.Component,args:[{selector:"aup-row-editor-controls",template:'<button *ngIf="!editSession" mat-icon-button [pectinCommand]="editRowCommand" class="edit-button"><aup-icon icon="mat:edit"></aup-icon></button>\n<button *ngIf="editSession" mat-icon-button [pectinCommand]="saveCommand"><aup-icon icon="mat:done"></aup-icon></button>\n<button *ngIf="editSession" mat-icon-button [pectinCommand]="cancelCommand"><aup-icon icon="mat:clear"></aup-icon></button>\n',styles:[":host{display:block;width:80px}.edit-button{visibility:hidden}:host-context(tr:hover) .edit-button{visibility:visible}"]}]}],Gt.ctorParameters=function(){return[]},Gt.propDecorators={row:[{type:n.Input}],editRowCommand:[{type:n.Input}],editSession:[{type:n.Input}]},q([I.TrackExternal(),W("design:type",I.Command)],Gt.prototype,"editRowCommand",void 0);var Kt=function(t){function e(){var e=t.call(this)||this;return e.selectCommand=I.Command.create((function(){e.selectionModel.selectCommand.execute(e.row)})),e}return B(e,t),e.prototype.isSelected=function(){return this.selectionModel.isSelected(this.row)},e}(Y);Kt.decorators=[{type:n.Component,args:[{selector:"aup-select-cell-renderer",template:'<mat-checkbox [pectinCommand]="selectCommand" [checked]="isSelected()"></mat-checkbox>\n',styles:[""]}]}],Kt.ctorParameters=function(){return[]},Kt.propDecorators={row:[{type:n.Input}]};var Xt=function(t){function e(){var e=t.call(this)||this;return e.selectCommand=I.Command.create((function(){e.selectionModel.toggleAllCommand.execute()})),e}return B(e,t),e.prototype.isSelected=function(){var t;return(null===(t=this.selectionModel)||void 0===t?void 0:t.allSelected.value)||!1},e.prototype.isIntermediate=function(){var t;return(null===(t=this.selectionModel)||void 0===t?void 0:t.someSelected.value)||!1},e}(Y);Xt.decorators=[{type:n.Component,args:[{selector:"aup-select-header-cell-renderer",template:'<mat-checkbox *ngIf="enableHeaderControls" [pectinCommand]="selectCommand" [checked]="isSelected()" [indeterminate]="this.isIntermediate()"></mat-checkbox>\n',styles:[""]}]}],Xt.ctorParameters=function(){return[]};var $t=function(){},Yt=Symbol("aup-cell-renderer:row-data-cache"),Jt=function(){function t(t,e){this.columnId=t,this.defaults=e,this._selectRowOnClick=void 0,this.cellHeaderRenderer(zt,(function(t,e){t.headerText=e.getHeaderText()}))}return t.prototype.getHeaderText=function(){var t;return(null===(t=this.getColumnTextProperties())||void 0===t?void 0:t.headerText())||this.getDefaultHeaderText()},t.prototype.getDefaultHeaderText=function(){return this.columnId},t.prototype.getColumnTextProperties=function(){return this._columnTextProperties||this.defaults.getColumnTextProperties(this)},t.prototype.textProperties=function(t){return this._columnTextProperties=t,this},t.prototype.configureHeaderRenderer=function(t){this._columnHeaderPortalRef=t},t.prototype.configureCellRenderer=function(t){this._cellRendererPortalRef=t},t.prototype.configureCellEditor=function(t){this._cellEditorPortalRef=t},t.prototype.cellHeaderRenderer=function(t,e){return this.configureHeaderRenderer(new Nt(t,e)),this},t.prototype.hasEditorPortal=function(){return!!this._cellEditorPortalRef},t.prototype.attachHeaderCell=function(t){this._columnHeaderPortalRef.initialiseHost(t,this)},t.prototype.attachCell=function(t){this._cellRendererPortalRef.initialiseHost(t,this),this.hasEditorPortal()&&this._cellEditorPortalRef.initialiseHost(t,this)},t.prototype.onHeaderAttached=function(t,e){this._columnHeaderPortalRef.onPortalAttached(t,e)},t.prototype.onRendererAttached=function(t,e){this._cellRendererPortalRef.onPortalAttached(t,e)},t.prototype.onEditorAttached=function(t,e){this._cellEditorPortalRef.onPortalAttached(t,e)},t.prototype.updatePortalContent=function(t){this._cellRendererPortalRef.pushState(t)},t.prototype.selectRowOnClick=function(t){return this._selectRowOnClick=t,this},t.prototype.isRowSelectionEnabled=function(){return this._selectRowOnClick},t.prototype.isRowSelectionExplicitlyEnabled=function(){return!0===this._selectRowOnClick},t.prototype.isRowSelectionExplicitlyDisabled=function(){return!1===this._selectRowOnClick},t}();q([w.Memoize(),W("design:type",Function),W("design:paramtypes",[]),W("design:returntype",String)],Jt.prototype,"getHeaderText",null),q([w.Memoize(),W("design:type",Function),W("design:paramtypes",[]),W("design:returntype",Object)],Jt.prototype,"getColumnTextProperties",null);var Zt,Qt=function(t){function e(e,n,o){var i=t.call(this,e,o)||this;return i.property=n,i._format=function(t){return t},i.cellRenderer(Wt),i}return B(e,t),e.prototype.cellRenderer=function(t,e){var n=this;return this.configureCellRenderer(new Ht(t,(function(t,o,i){i&&(j.default.isFunction(e)?e(t):j.default.isFunction(null==e?void 0:e.onComponentInit)&&e.onComponentInit(t)),t.value=n._format(o.row[n.property]),!j.default.isFunction(e)&&j.default.isFunction(null==e?void 0:e.onRowUpdate)&&e.onRowUpdate(t,o.row)}))),this},e.prototype.mutableCellRenderer=function(t,e){var n=this;return this.configureCellRenderer(new Ht(t,(function(t,o,i){t[Yt]=o.row;var r=!1;i&&(j.default.isFunction(null==e?void 0:e.onComponentInit)&&e.onComponentInit(t),t.onValueEdited((function(n,o){r||e.onValueEdit(t[Yt],n,o)}))),r=!0,t.value=o.row[n.property],r=!1,!j.default.isFunction(e)&&j.default.isFunction(null==e?void 0:e.onRowUpdate)&&e.onRowUpdate(t,o.row)}))),this},e.prototype.cellEditor=function(t,e,n){var o=this,i=Array.isArray(e)?e:void 0,r=j.default.isFunction(e)?e:n;return this.configureCellEditor(new Bt(t,(function(t,e){var n=e.form.pluck(o.property);i&&n.validateUsing(i),t.valueModel=n,r&&r(t)}))),this},e.prototype.format=function(t){return x.assert.isFunction(t),this._format=t,this},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(Jt),te=function(t){function e(e,n,o){var i=t.call(this,e,o)||this;return i.property=n,i._format=function(t){return t.map((function(t){return null==t?void 0:t.toString()})).join(", ")},i.cellRenderer(Wt),i}return B(e,t),e.prototype.cellRenderer=function(t){var e=this;return this.configureCellRenderer(new Ht(t,(function(t,n){t.value=e._format(n.row[e.property])}))),this},e.prototype.cellEditor=function(t,e,n){var o=this,i=Array.isArray(e)?e:void 0,r=j.default.isFunction(e)?e:n;return this.configureCellEditor(new Bt(t,(function(t,e){var n=e.form.pluckList(o.property);i&&n.validateUsing(i),t.listModel=n,r&&r(t)}))),this},e.prototype.format=function(t){return x.assert.isFunction(t),this._format=t,this},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(Jt),ee=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.getValue=o,i.cellRenderer(Wt),i}return B(e,t),e.prototype.cellRenderer=function(t,e){var n=this;return this.configureCellRenderer(new Ht(t,(function(t,o,i){i&&(j.default.isFunction(e)?e(t):j.default.isFunction(null==e?void 0:e.onComponentInit)&&e.onComponentInit(t)),t.value=n.getValue(o.row),!j.default.isFunction(e)&&j.default.isFunction(null==e?void 0:e.onRowUpdate)&&e.onRowUpdate(t,o.row)}))),this},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(Jt),ne=function(t){function e(e,n,o){var i=t.call(this,e,o)||this;return i.cellRenderer(Gt),i}return B(e,t),e.prototype.cellRenderer=function(t){return this.configureCellRenderer(new Ht(t,(function(t,e){t.row=e.row,t.editSession=e.editSession,t.editRowCommand=e.editRowCommand}))),this},e.prototype.getDefaultHeaderText=function(){return""},e}(Jt),oe=function(t){function e(e,n){var o=t.call(this,e,n)||this;return o.config=new qt,o.configureCellRenderer(o.config),o}return B(e,t),e.prototype.setTemplate=function(t,e,n,o){this.config.registerPortal(t,e,n,o)},e.prototype.selectRowOnClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e}(Jt),ie=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.selectionModel=o,i._enableHeaderControls=!0,i.selectOnRowClick(!1),o instanceof I.MultipleSelectionModel&&i.cellHeaderRenderer(Xt,(function(t){t.selectionModel=o,t.enableHeaderControls=i._enableHeaderControls})),i.configureCellRenderer(new Ht(Kt,(function(t,e){t.row=e.row,t.selectionModel=o}))),i}return B(e,t),e.prototype.getDefaultHeaderText=function(){return""},e.prototype.isRowSelectionEnabledByDefault=function(){return this.isRowSelectionExplicitlyEnabled()},e.prototype.selectOnRowClick=function(e){return t.prototype.selectRowOnClick.call(this,e)},e.prototype.enableHeaderControls=function(t){return this._enableHeaderControls=t,this},e.prototype.selectRow=function(t){this.selectionModel.selectCommand.execute(t)},e}(Jt),re=function(t){function e(e,n,o,i){var r=t.call(this)||this;return r.rowId=e,r.form=o,r.saveCommand=i,r._liveRowValue=new I.MutableValueModel,r.liveRowValue=r._liveRowValue.readonly,r.form.load(n),r._liveRowValue.value=n,r.form.onEdit((function(){r._liveRowValue.value=N.default(r._liveRowValue.value,(function(t){r.form.writeDirtyStateTo(t)}))})),r}return B(e,t),e}(I.GarbageCollector),ae=function(t,e){this.className=t,this.matches=e};t.TableModel=Zt=function(){function t(t){var e=this;this.sourceOfTruth=t,this._garbage=new I.GarbageCollector,this._columns=new I.MutableListModel,this._editorSessions=new I.MutableListModel,this.rowClassNamePredicates=[],this._createForm=function(t){return new I.DirtyTrackingForm},this.trackBy=function(t,n){return e.identityOf?e.identityOf(n):t},this.identityOf=t.identityOf;var n=I.Dsl.disposeWith(this._garbage),o=n.chain;n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn;this._columnsById=o(this._columns).indexBy("columnId"),this._rowsBeingEdited=new I.MutableListModel([],{identifiedWith:this.identityOf}),this._editorSessionByRowId=o(this._editorSessions).indexBy("rowId"),this.editing=o(this._editorSessions).count().isGreaterThan(0),this.dataSource=o(this.sourceOfTruth).replaceAll(this.rowsBeingEdited),this.firstEditableColumn=o(this.columns).select((function(t){return t.hasEditorPortal()})).first(),this.hasColumnsWithRowSelectionExplicitlyEnabled=o(this._columns).findIndex((function(t){return t.isRowSelectionExplicitlyEnabled()})).isGreaterThanOrEqualTo(0),this.addRowClass("enable-hover",(function(){return e.isRowSelectionEnabled()}))}return t.fromList=function(t,e){var n=new Zt(t);return e(n),n},Object.defineProperty(t.prototype,"rowsBeingEdited",{get:function(){return this._rowsBeingEdited.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"columns",{get:function(){return this._columns.readonly},enumerable:!1,configurable:!0}),t.prototype.pluck=function(t,e){return this.addColumn(new Qt((null==e?void 0:e.columnId)||t.toString(),t,this))},t.prototype.pluckList=function(t,e){return this.addColumn(new te((null==e?void 0:e.columnId)||t.toString(),t,this))},t.prototype.addSelectionColumn=function(t){return I.assert.isNil(this.selectionColumnModel),this.selectionColumnModel=new ie("selection",this,t),this.addColumn(this.selectionColumnModel)},t.prototype.addEditControls=function(t){return this.saveCommand=t,this.addColumn(new ne("editControls",t,this))},t.prototype.addCustomColumn=function(t,e){return this.addColumn(new ee(t,this,e))},t.prototype.addComponentColumn=function(t,e,n){return this.addColumn(new ee(t,this,(function(t){return t}))).cellRenderer(e,n)},t.prototype.addTemplateColumn=function(t){return this.addColumn(new oe(t,this))},t.prototype.addRowClass=function(t,e){this.rowClassNamePredicates.push(new ae(t,e))},t.prototype.getRowClasses=function(t){var e=[];return this.rowClassNamePredicates.forEach((function(n){n.matches(t)&&e.push(n.className)})),e},t.prototype.useFormFactory=function(t){return this._createForm=t,this},t.prototype.addColumn=function(t){return this._columnsById.get(t.columnId)?I.lang.illegalState("Column with id="+t.columnId+" already exists"):this._columns.push(t),t},t.prototype.columnTextProperties=function(t){this._columnTextPropertiesLookup=t},t.prototype.getColumnTextProperties=function(t){return this._columnTextPropertiesLookup?this._columnTextPropertiesLookup[t.columnId]:void 0},t.prototype.startEditSession=function(t){var e=this,n=this.identityOf(t);if(this._rowsBeingEdited.query().indexOf(t)>-1)return I.lang.illegalState("Row with id="+n+" already being edited");var o=new re(n,t,this._createForm(t),this.saveCommand);return(0,I.Dsl.disposeWith(o).when)(o.liveRowValue).changes((function(t){e._rowsBeingEdited.replaceOrPush(t)}),{initialValue:"triggerChangeUnlessNil"}),this._editorSessions.push(o),o.onDispose((function(){e._rowsBeingEdited.remove(o.liveRowValue.value),e._editorSessions.remove(o)})),o},t.prototype.getEditSessionFor=function(t){return this._editorSessionByRowId.get(this.identityOf(t))},t.prototype.cancelAllEditorSessions=function(){var t=this;this._editorSessions.runInTransaction((function(e){t._rowsBeingEdited.runInTransaction((function(){e.value.forEach((function(t){return t.dispose()}))}))}))},t.prototype.isRowSelectionEnabledFor=function(t){var e;return this.selectionColumnModel&&(null!==(e=t.isRowSelectionEnabled())&&void 0!==e?e:this.isRowSelectionEnabledByDefault())},t.prototype.isRowSelectionEnabledByDefault=function(){return this.selectionColumnModel&&this.selectionColumnModel.isRowSelectionEnabledByDefault()},t.prototype.isRowSelectionEnabled=function(){return this.hasColumnsWithRowSelectionExplicitlyEnabled.value||this.isRowSelectionEnabledByDefault()},t.prototype.selectRow=function(t){var e;null===(e=this.selectionColumnModel)||void 0===e||e.selectRow(t)},t}(),t.TableModel=Zt=q([I.TrackExternal.Strategy(new I.TrackExternal.OneTimeBinding),W("design:paramtypes",[I.ListModel])],t.TableModel);var ce=function(t){function e(){return t.call(this)||this}return B(e,t),e.prototype.ngOnInit=function(){var t=I.Dsl.disposeWith(this),e=t.chain;t.valueOf,t.before,t.when,t.after,t.observe,t.switchOn;this.columns=e(this.tableModel.columns),this.columnIds=e(this.columns).pluck("columnId"),this.columnsById=e(this.columns).indexBy("columnId")},e.prototype.isEditing=function(t){return!!this.tableModel.getEditSessionFor(t)},e.prototype.registerColumnTemplate=function(t,e,n,o,i){var r=this.columnsById.get(t);r instanceof oe&&r.setTemplate(e,n,o,i)},e.prototype.onCellClicked=function(t,e){this.tableModel.isRowSelectionEnabledFor(t)&&this.tableModel.selectRow(e)},e}(Y);ce.decorators=[{type:n.Component,args:[{selector:"aup-table",template:'<table mat-table [dataSource]="tableModel.dataSource.value" [trackBy]="tableModel.trackBy">\n\n <ng-container *ngFor="let column of columns.value; index as index; first as first; last as last" matColumnDef="{{column.columnId}}">\n <th mat-header-cell *matHeaderCellDef>\n <aup-table-header-cell-renderer [column]="column"\n [attr.column-index]="index"\n [attr.column-id]="column.columnId"\n [class.first-column]="first"\n [class.last-column]="last"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef="let row" (click)="onCellClicked(column, row)" [class.enable-cursor]="tableModel.isRowSelectionEnabledFor(column)">\n <aup-table-cell-renderer [column]="column"\n [row]="row"\n [tableModel]="tableModel"\n [editSession]="tableModel.getEditSessionFor(row)"\n [attr.column-index]="index"\n [attr.column-id]="column.columnId"\n [class.first-column]="first"\n [class.last-column]="last"\n ></aup-table-cell-renderer>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef="columnIds.value"></tr>\n <tr mat-row *matRowDef="let row; columns: columnIds.value; let i = index"\n [ngClass]="tableModel.getRowClasses(row)" [attr.trackBy]="tableModel.trackBy(i, row)"\n ></tr>\n\n</table>\n',styles:[":host{align-items:stretch;display:flex;flex-direction:column}:host table{flex:1}"]}]}],ce.ctorParameters=function(){return[]},ce.propDecorators={tableModel:[{type:n.Input}]},q([I.TrackExternal(),W("design:type",t.TableModel)],ce.prototype,"tableModel",void 0);var se=function(){function t(t,e,n){this.host=t,this.templateRef=e,this.viewContainer=n,this.aupColumnTemplateFillCell=!1,this.aupColumnTemplateAutoPadChild=void 0}return t.prototype.ngOnInit=function(){var t;I.assert.isTruthy(this.aupColumnTemplateColumnId),this.host.registerColumnTemplate(this.aupColumnTemplateColumnId,this.templateRef,this.viewContainer,this.aupColumnTemplateFillCell,null!==(t=this.aupColumnTemplateAutoPadChild)&&void 0!==t?t:this.aupColumnTemplateFillCell)},t}();se.decorators=[{type:n.Directive,args:[{selector:"[aupColumnTemplate]"}]}],se.ctorParameters=function(){return[{type:ce},{type:n.TemplateRef},{type:n.ViewContainerRef}]},se.propDecorators={aupColumnTemplate:[{type:n.Input}],aupColumnTemplateColumnId:[{type:n.Input}],aupColumnTemplateFillCell:[{type:n.Input}],aupColumnTemplateAutoPadChild:[{type:n.Input}]};var le=function(t){function e(){var e=t.call(this)||this;return e.defaultClassNames="aup-cell-renderer",e.fillCell=!1,e.padChild=!1,e.editRowCommand=I.Command.create((function(){e.tableModel.startEditSession(e.row)})),e}return B(e,t),e.prototype.ngOnInit=function(){var t=I.Dsl.disposeWith(this),e=t.chain;t.valueOf,t.before,t.when,t.after,t.observe,t.switchOn;this.firstEditableColumn=e(this.tableModel.firstEditableColumn).equals(this.column),this.column.attachCell(this)},e.prototype.hasActiveEditor=function(){return!!this.editSession&&!!this.column.hasEditorPortal()},e.prototype.initialiseRenderer=function(t){this.column.onRendererAttached(this,t)},e.prototype.initialiseEditor=function(t){var e=this;this.column.onEditorAttached(this,t),this.firstEditableColumn.value&&setTimeout((function(){return e.tryAndFocusEditor(t)}))},e.prototype.tryAndFocusEditor=function(t){var e;if(t.requestFocus)t.requestFocus();else{var n=t.valueModel||t.listModel;null===(e=null==n?void 0:n.focusContext)||void 0===e||e.requestFocus()}},e.prototype.ngOnChanges=function(t){this.column.updatePortalContent(this)},e.prototype.getRendererPortal=function(){return this[kt]},e.prototype.getEditorPortal=function(){return this[_t]},e.prototype.getRowData=function(){return{row:this.row,editSession:this.editSession,editRowCommand:this.editRowCommand}},e}(Y);le.decorators=[{type:n.Component,args:[{selector:"aup-table-cell-renderer",template:'<ng-container *ngIf="!hasActiveEditor()" [cdkPortalOutlet]="getRendererPortal()" (attached)="initialiseRenderer($event.instance)"></ng-container>\n<ng-container *ngIf="hasActiveEditor()" [cdkPortalOutlet]="getEditorPortal()" (attached)="initialiseEditor($event.instance)"></ng-container>\n',styles:[""]}]}],le.ctorParameters=function(){return[]},le.propDecorators={row:[{type:n.Input}],column:[{type:n.Input}],editSession:[{type:n.Input}],tableModel:[{type:n.Input}],defaultClassNames:[{type:n.HostBinding,args:["class"]}],fillCell:[{type:n.HostBinding,args:["class.fillCell"]}],padChild:[{type:n.HostBinding,args:["class.padChild"]}]};var ue=function(){function t(){this.defaultClassNames="aup-header-cell-renderer"}return t.prototype.ngOnInit=function(){this.column.attachHeaderCell(this)},t.prototype.initialiseHeader=function(t){this.column.onHeaderAttached(this,t)},t.prototype.getPortal=function(){return this[Ft]},t}();ue.decorators=[{type:n.Component,args:[{selector:"aup-table-header-cell-renderer",template:'<ng-container [cdkPortalOutlet]="getPortal()" (attached)="initialiseHeader($event.instance)"></ng-container>\n',styles:[":host{align-items:stretch;display:flex;flex-direction:column;height:100%;justify-content:center}"]}]}],ue.ctorParameters=function(){return[]},ue.propDecorators={column:[{type:n.Input}],defaultClassNames:[{type:n.HostBinding,args:["class"]}]};var pe=function(t,e){this.factory=t,this.face=e},de=function(t){function e(){var e=t.call(this)||this;return e.actions=[],e.moreActions=[],e}return B(e,t),e.prototype.registerAction=function(t,e){this.actions.push(new pe(t,e))},e.prototype.registerMoreAction=function(t,e){this.moreActions.push(new pe(t,e))},e.prototype.ngOnInit=function(){},e.prototype.createMoreMenuCommand=function(t,e){var n=this,o=I.Dsl.disposeWith(this).when,i=t.factory.create(e);return o(i.busy).becomesFalsey((function(){n.closeMoreMenu()})),i},e.prototype.closeMoreMenu=function(){this.menu.closeMenu()},e}(Y);de.decorators=[{type:n.Component,args:[{selector:"aup-table-row-menu",template:'\n <aup-tool-bar>\n <aup-command *ngFor="let action of actions" [command]="action.factory.create(value)"\n [face]="action.face"></aup-command>\n </aup-tool-bar>\n <ng-container *ngIf="moreActions.length > 0">\n <aup-more-menu>\n <aup-command *ngFor="let action of moreActions" [command]="action.factory.create(value)"\n [face]="action.face"></aup-command>\n </aup-more-menu>\n </ng-container>\n ',styles:[":host {\n display: inline-flex;\n flex-direction: row;\n align-items: center;\n }"]}]}],de.ctorParameters=function(){return[]},de.propDecorators={value:[{type:n.Input}],menu:[{type:n.ViewChild,args:[g.MatMenuTrigger]}]};var fe=function(t){function e(e){var n=t.call(this,e)||this;return n.focusManager=e,n}return B(e,t),e.prototype.arrowLeft=function(t){this.leftArrowCommand.enabled.value&&(t.preventDefault(),t.stopPropagation(),this.leftArrowCommand.execute())},e.prototype.arrowRight=function(t){this.rightArrowCommand.enabled.value&&(t.preventDefault(),t.stopPropagation(),this.rightArrowCommand.execute())},e.prototype.arrowDown=function(t){t.preventDefault(),t.stopPropagation(),this.focusManager.focusNext()},e.prototype.arrowUp=function(t){t.preventDefault(),t.stopPropagation(),this.focusManager.focusPrevious()},e.prototype.ngOnInit=function(){},e}(ft);fe.decorators=[{type:n.Component,args:[{selector:"aup-vertical-focus-container",template:"<ng-content></ng-content>\n",providers:[{provide:I.FocusManager}],styles:[":host{display:block}"]}]}],fe.ctorParameters=function(){return[{type:I.FocusManager,decorators:[{type:n.Self}]}]},fe.propDecorators={rightArrowCommand:[{type:n.Input,args:["command.arrowRight"]}],leftArrowCommand:[{type:n.Input,args:["command.arrowLeft"]}],arrowLeft:[{type:n.HostListener,args:["keyup.arrowLeft",["$event"]]}],arrowRight:[{type:n.HostListener,args:["keyup.arrowRight",["$event"]]}],arrowDown:[{type:n.HostListener,args:["keyup.arrowDown",["$event"]]}],arrowUp:[{type:n.HostListener,args:["keyup.arrowUp",["$event"]]}]},q([I.TrackExternal(),W("design:type",I.Command)],fe.prototype,"rightArrowCommand",void 0),q([I.TrackExternal(),W("design:type",I.Command)],fe.prototype,"leftArrowCommand",void 0);var me=function(t){t.addIconPacks(C.fas)};me.decorators=[{type:n.NgModule,args:[{declarations:[ht,yt,gt,It,Mt,xt,wt,Pt,Ct,vt,bt,St,Rt,Et,Dt,Tt,ft,fe,mt,et,ce,Gt,se,Wt,le,Kt,Xt,zt,ue,t.IconComponent,At,de,rt,it,dt,lt,pt,at,ut,ct,st],imports:[e.CommonModule,s.BrowserAnimationsModule,o.FormsModule,r.MatInputModule,i.MatFormFieldModule,a.MatSelectModule,c.MatTabsModule,tt,h.MatIconModule,d.MatButtonModule,f.MatCheckboxModule,y.MatTableModule,l.PortalModule,u.CdkScrollableModule,b.FontAwesomeModule,v.MatTooltipModule,p.MatAutocompleteModule,g.MatMenuModule,m.MatDividerModule],exports:[It,Mt,xt,wt,bt,Pt,Ct,vt,St,Rt,Et,Dt,Tt,ft,fe,mt,et,ce,Gt,se,t.IconComponent,At,de,rt,it,dt,lt,pt,at,ut],providers:[Z]}]}],me.ctorParameters=function(){return[{type:b.FaIconLibrary}]};var he=new n.InjectionToken("InteractionActivityData"),ge=function(t){function e(){var e=t.apply(this,X(arguments))||this;return e._busyModel=(new I.DelegatingValueModel).withDefault(!1),e._focusedModel=e.registerDisposable(new I.DelegatingValueModel),e.class="aup-activity",e}return B(e,t),Object.defineProperty(e.prototype,"isFocused",{get:function(){return this._focusedModel.value},enumerable:!1,configurable:!0}),e.prototype.initialise=function(t,e){var n=this,o=I.Dsl.disposeWith(this),i=(o.chain,o.when);x.assert.isNil(this._activityContext),this._activityContext=e,this._interactionContext=t,this._focusedModel.setDelegate(e.focused),i(this._focusedModel).becomesTruthy((function(){n.onActivityReady()}))},Object.defineProperty(e.prototype,"interactionContext",{get:function(){return x.assert.isTruthy(this.isInitialised()),this._interactionContext},enumerable:!1,configurable:!0}),e.prototype.done=function(t){return this._activityContext.onDone(t)},e.prototype.cancel=function(t){this._activityContext.onCancel(t)},e.prototype.onActivityReady=function(){},Object.defineProperty(e.prototype,"busy",{get:function(){return this._busyModel.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"focused",{get:function(){return this._focusedModel.readonly},enumerable:!1,configurable:!0}),e.prototype.busyWhile=function(t){this._busyModel.setDelegate(t)},e.prototype.isBusy=function(){return this._busyModel.value},e.prototype.isInitialised=function(){return!!this._activityContext},e}(Y);ge.decorators=[{type:n.Component,args:[{template:""}]}],ge.propDecorators={class:[{type:n.HostBinding,args:["class"]}],isFocused:[{type:n.HostBinding,args:["attr.focused"]}]};var ye=function(t){function e(){var e=t.apply(this,X(arguments))||this;return e.align="start",e}return B(e,t),Object.defineProperty(e.prototype,"alignEnd",{get:function(){return"end"===this.align},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"alignStretch",{get:function(){return"stretch"===this.align},enumerable:!1,configurable:!0}),e.prototype.ngOnInit=function(){},e.prototype.hasConfirmCommand=function(){return I.DelegatingCommand.hasDelegate(this.confirmCommand)},e.prototype.hasCancelCommand=function(){return I.DelegatingCommand.hasDelegate(this.cancelCommand)},e}(Y);ye.decorators=[{type:n.Component,args:[{selector:"aup-activity-actions",template:'<ng-container *ngIf="hasCancelCommand()">\n <aup-command class="cancel" [command]="cancelCommand" [face]="style.cancel"></aup-command>\n</ng-container>\n<ng-container *ngIf="hasConfirmCommand()">\n <aup-command class="confirm" [command]="confirmCommand" [face]="style.confirm"></aup-command>\n</ng-container>\n<div class="content">\n <ng-content></ng-content>\n</div>\n',styles:[':host{-ms-grid-columns:auto auto 1fr;-ms-grid-rows:auto;align-items:center;display:-ms-grid;display:grid;grid-template-areas:"cancel confirm content";grid-template-columns:auto auto 1fr;grid-template-rows:auto;justify-content:end}:host.align-end{-ms-grid-columns:1fr auto auto;grid-template-areas:"content cancel confirm";grid-template-columns:1fr auto auto}:host.align-stretch{-ms-grid-columns:auto 1fr auto;grid-template-areas:"cancel content confirm";grid-template-columns:auto 1fr auto}.cancel{-ms-grid-column:1;-ms-grid-row:1;grid-area:cancel}:host.align-end>.cancel{-ms-grid-column:2;-ms-grid-row:1}:host.align-stretch>.cancel{-ms-grid-column:1;-ms-grid-row:1}.confirm{-ms-grid-column:2;-ms-grid-row:1;grid-area:confirm}.column,:host.align-end>.confirm,:host.align-stretch>.confirm{-ms-grid-column:3;-ms-grid-row:1}.column{grid-area:content;text-align:left}:host.align-end>.column{-ms-grid-column:1;-ms-grid-row:1}:host.align-stretch>.column{-ms-grid-column:2;-ms-grid-row:1}']}]}],ye.propDecorators={confirmCommand:[{type:n.Input}],cancelCommand:[{type:n.Input}],style:[{type:n.Input}],align:[{type:n.Input}],alignEnd:[{type:n.HostBinding,args:["class.align-end"]}],alignStretch:[{type:n.HostBinding,args:["class.align-stretch"]}]},q([I.TrackExternal(),W("design:type",I.Command)],ye.prototype,"confirmCommand",void 0),q([I.TrackExternal(),W("design:type",I.Command)],ye.prototype,"cancelCommand",void 0);var ve=function(t){function e(e){var n=t.call(this)||this;return n.alert=e,n}return B(e,t),e.prototype.ngOnInit=function(){},e}(ge);ve.decorators=[{type:n.Component,args:[{selector:"aup-alert-dialog",template:'<h3 matDialogTitle *ngIf="alert.title">{{alert.title()}}</h3>\n<div matDialogContent>\n <p *ngFor="let line of alert.content()">{{line}}</p>\n</div>\n<div matDialogActions>\n <button mat-raised-button color="primary" (click)="done()" data-cy="close-button">{{alert.ok()}}</button>\n</div>\n',styles:[":host{display:block;padding:var(--aup-default-padding)}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{align-items:flex-end;justify-content:flex-end;margin-bottom:0!important;padding:0}"]}]}],ve.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[he]}]}]};var be=function(t){function e(e){var n=t.call(this)||this;return n.config=e,I.assert.notNil(e),n}return B(e,t),e.prototype.ngOnInit=function(){},Object.defineProperty(e.prototype,"confirm",{get:function(){return this.config.confirm},enumerable:!1,configurable:!0}),e.prototype.isDestructive=function(){return this.confirm.destructive&&this.confirm.destructive()},e.prototype.onConfirm=function(){var t=this;this.interactionContext.startActivity(this.config.activityType,this.config.data).then((function(e){return t.done(e)})).catch((function(e){return t.cancel(e)}))},e}(ge);be.decorators=[{type:n.Component,args:[{selector:"aup-confirmation-dialog",template:'<h3 matDialogTitle *ngIf="confirm.title">{{confirm.title()}}</h3>\n<div matDialogContent>\n <p *ngFor="let line of confirm.content()">{{line}}</p>\n</div>\n<div matDialogActions>\n <button mat-button (click)="cancel()" data-cy="cancel-button">{{confirm.cancel()}}</button>\n <button mat-raised-button [color]="isDestructive() ? \'warn\' : \'primary\'"\n (click)="onConfirm()" data-cy="confirm-button">{{confirm.ok()}}</button>\n</div>\n\n',styles:[":host{display:block;padding:var(--aup-default-padding)}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{align-items:flex-end;justify-content:flex-end;margin-bottom:0!important;padding:0}"]}]}],be.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[he]}]}]};var Ce=function(t){function e(e){var n=t.call(this)||this;return n.confirm=e,I.assert.notNil(e),n}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.isDestructive=function(){return this.confirm.destructive&&this.confirm.destructive()},e}(ge);Ce.decorators=[{type:n.Component,args:[{selector:"aup-confirmation-dialog",template:'<h3 matDialogTitle *ngIf="confirm.title">{{confirm.title()}}</h3>\n<div matDialogContent>\n <p *ngFor="let line of confirm.content()">{{line}}</p>\n</div>\n<div matDialogActions>\n <button mat-button (click)="cancel()" data-cy="cancel-button">{{confirm.cancel()}}</button>\n <button mat-raised-button [color]="isDestructive() ? \'warn\' : \'primary\'"\n (click)="done()" data-cy="confirm-button">{{confirm.ok()}}</button>\n</div>\n\n',styles:[":host{display:block;padding:var(--aup-default-padding)}.mat-dialog-content{margin:0;padding:0}.mat-dialog-actions{align-items:flex-end;justify-content:flex-end;margin-bottom:0!important;padding:0}"]}]}],Ce.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[he]}]}]};var Ie=function(){function t(){}return t.prototype.startActivity=function(t,e,n){return this.createAndLaunchActivity(t,e,x.Opts.get(n).getOptional("disableClose",!1))},t.prototype.confirm=function(t){return this.confirmOrReject(t).then((function(){return!0})).catch((function(){return!1}))},t.prototype.alert=function(t){return this.createAndLaunchActivity(ve,t,!1)},t.prototype.confirmOrReject=function(t){return this.createAndLaunchActivity(Ce,t,!0)},t.prototype.confirmThen=function(t,e,n){return this.createAndLaunchActivity(be,{confirm:t,activityType:e,data:n},!0)},t}(),we=function(){function t(t,e,n){this.activityClass=t,this.activityData=e,this.onComplete=n,this._complete=!1,this.deferredResult=I.Deferred.defer(),this.focusedModel=new I.MutableValueModel}return t.prototype.isActivityRealised=function(){return!!this._activity},t.prototype.isComplete=function(){return this._complete},Object.defineProperty(t.prototype,"activity",{get:function(){return I.assert.isTruthy(this.isActivityRealised()),this._activity},enumerable:!1,configurable:!0}),t.prototype.setFocused=function(t){this.focusedModel.value=t},Object.defineProperty(t.prototype,"focused",{get:function(){return this.focusedModel.value},enumerable:!1,configurable:!0}),t.prototype.notifyActivityCreated=function(t,e){I.assert.isNil(this._activity),this._activity=t;var n=this;this._activity.initialise(e,{onDone:function(t){n.finishActivity((function(e){return e.resolve(t)}))},onCancel:function(t){n.finishActivity((function(e){return e.reject(t)}))},focused:this.focusedModel.readonly})},t.prototype.finishActivity=function(t){I.assert.isFalsey(this.isComplete()),t(this.deferredResult),this._complete=!0,this.onComplete(this)},t.prototype.cancel=function(){this.activity.cancel()},Object.defineProperty(t.prototype,"activityResult",{get:function(){return this.deferredResult.promise},enumerable:!1,configurable:!0}),t}(),Pe=function(){function t(t,e,n){this.componentFactoryResolver=t,this.viewContainerRef=e,this.injector=n}return Object.defineProperty(t.prototype,"activityRef",{get:function(){return this._activityRef},set:function(t){this.activityRef&&!this.activityRef.isComplete()&&x.lang.illegalState("changing activity before previous one has completed"),this._activityRef=t,this.loadActivity(t)},enumerable:!1,configurable:!0}),t.prototype.ngOnInit=function(){},t.prototype.loadActivity=function(t){var e=n.Injector.create({providers:[{provide:he,useValue:t.activityData}],parent:this.injector}),o=this.componentFactoryResolver.resolveComponentFactory(t.activityClass);this.viewContainerRef.clear(),this.activityComponentRef=this.viewContainerRef.createComponent(o,0,e),this.activityRef.notifyActivityCreated(this.activityComponentRef.instance,this.nestedInteractionContext)},Object.defineProperty(t.prototype,"component",{get:function(){return this.activityComponentRef.instance},enumerable:!1,configurable:!0}),t}();Pe.decorators=[{type:n.Component,args:[{selector:"aup-activity-outlet",template:"",styles:[":host{display:block}"]}]}],Pe.ctorParameters=function(){return[{type:n.ComponentFactoryResolver},{type:n.ViewContainerRef},{type:n.Injector}]},Pe.propDecorators={nestedInteractionContext:[{type:n.Input}],activityRef:[{type:n.Input}]};var Me=function(t){function e(){var e=t.call(this)||this;return e.dynamicHeight=!1,e.activityRefs=[],e.garbage=new I.GarbageCollector,e.inAnimation=new I.MutableValueModel(!1),e}return B(e,t),e.prototype.ngOnInit=function(){},e.prototype.ngAfterViewInit=function(){var t=this,e=I.Dsl.disposeWith(this);e.chain;e.observe.valuesFrom(this.tabs.animationDone).subscribe((function(){return t.onAnimationFinished()}))},e.prototype.initialise=function(t,e){I.assert.isFalsey(this.isInitialised()),I.assert.notNil(t),I.assert.notNil(e),this._identifier=t,this.interactionServiceApi=e},Object.defineProperty(e.prototype,"identifier",{get:function(){return this._identifier},enumerable:!1,configurable:!0}),e.prototype.isInitialised=function(){return!!this.identifier},e.prototype.isActive=function(){return this.getActiveActivityCount()>0},e.prototype.registerDisposable=function(t){return this.garbage.registerDisposable(t)},e.prototype.dispose=function(){I.assert.isFalsey(this.isActive()),this.garbage.dispose()},e.prototype.getActiveActivityRef=function(){return this.isActive()||x.lang.illegalState("no activity in progress"),j.default.findLast(this.activityRefs,(function(t){return!t.isComplete()}))},e.prototype.cancelActiveActivity=function(){return z(this,void 0,void 0,(function(){return G(this,(function(t){return this.getActiveActivityRef().cancel(),this.isCleaningUp()?[2,this.waitForInteractionContextCleanupToFinish()]:[2,!this.isActive()]}))}))},e.prototype.createAndLaunchActivity=function(t,e,n){var o=this;I.assert.isTruthy(this.isInitialised());var i=new we(t,e,(function(){o.getActiveActivityCount()>0?o.triggerTabSynchronisation():o.finishAndStartCleanup()}));return this.launchActivity(i),1===this.activityRefs.length&&this.interactionServiceApi.notifyActive(this),i.activityResult},e.prototype.getActiveActivityCount=function(){return this.activityRefs.filter((function(t){return!t.isComplete()})).length},e.prototype.isCleaningUp=function(){return!!this._deferredCleanUp},e.prototype.waitForInteractionContextCleanupToFinish=function(){return z(this,void 0,void 0,(function(){return G(this,(function(t){return[2,!this._deferredCleanUp||this._deferredCleanUp]}))}))},e.prototype.finishAndStartCleanup=function(){var t=this;if(!this._deferredCleanUp){this.activityRefs=[];var e=this.interactionServiceApi.notifyFinished(this);this._deferredCleanUp=e.finally((function(){t._deferredCleanUp=null}))}},e.prototype.launchActivity=function(t){var e=this.activityRefs.filter((function(t){return!t.isComplete()}));this.activityRefs=e.concat(t),this.synchroniseSelectedTabIndex()},e.prototype.activityIndex=function(t,e){return t},e.prototype.onAnimationFinished=function(){this.onAnimationFinishedJob&&(this.onAnimationFinishedJob(),this.onAnimationFinishedJob=void 0)},e.prototype.synchroniseSelectedTabIndex=function(){var t=this,e=this.tabs.selectedIndex,n=this.getActiveActivityCount()-1;e!==n&&(this.inAnimation.value=!0,this.activityRefs[n].setFocused(!1),this.tabs.selectedIndex=n,this.onAnimationFinishedJob=function(){t.activityRefs=t.activityRefs.filter((function(t){return!t.isComplete()})),t.inAnimation.value=!1,t.activityRefs.forEach((function(t,e){t.setFocused(e===n)}))})},e.prototype.getSelectedOutlet=function(){return this.activityOutlets.toArray()[this.tabs.selectedIndex]},e.prototype.getSelectedTabIndex=function(){return this.tabs.selectedIndex},e.prototype.triggerTabSynchronisation=function(){var t=this;this.syncSelectedTabTimeout&&clearTimeout(this.syncSelectedTabTimeout),this.syncSelectedTabTimeout=setTimeout((function(){t.syncSelectedTabTimeout=null,t.synchroniseSelectedTabIndex()}),75)},e}(Ie);Me.decorators=[{type:n.Component,args:[{selector:"aup-activity-container",template:'<mat-tab-group #tabs no-tab-header\n [dynamicHeight]="dynamicHeight"\n [class.full-height-tabs]="!dynamicHeight">\n <mat-tab *ngFor="let activityRef of activityRefs; let i = index; trackBy: activityIndex">\n \x3c!--\n We have issues where angular is triggering a leave animation when an\n new activity is started, but is not running the enter animation\n when it is scrolled back into view. So we track the tab changes and\n disable all animations inside the tab while we\'re animating.\n --\x3e\n <div class="activity-outlet-wrapper" [@.disabled]="!activityRef.focused">\n <aup-activity-outlet [nestedInteractionContext]="this" [activityRef]="activityRef"></aup-activity-outlet>\n </div>\n </mat-tab>\n</mat-tab-group>\n',styles:[":host{display:flex;flex-direction:column}mat-tab-group{flex:1}"]}]}],Me.ctorParameters=function(){return[]},Me.propDecorators={dynamicHeight:[{type:n.Input}],tabs:[{type:n.ViewChild,args:["tabs",{static:!0}]}],activityOutlets:[{type:n.ViewChildren,args:[Pe]}]};var xe=function(){function t(t,e,n){this.activeInteractionContextIds=t,this.activeModalContext=e,this.createExclusiveInteractionContext=n}return t.prototype.isActive=function(){return this.getActiveInteractionContextIds().length>0},t.prototype.isModalActive=function(){return!!this.activeModalContext.value},t.prototype.isComponentInteracting=function(t){return t.interactionContext&&t.interactionContext.isActive()},t.prototype.getActiveInteractionContextIds=function(){return this.activeInteractionContextIds.value},t.prototype.cancelCurrentModalInteraction=function(){return this.activeModalContext.value.cancelActiveActivity()},t.prototype.cancelComponentInteraction=function(t){return t.interactionContext.cancelActiveActivity()},t}(),Re=function(){},Se=0;t.InteractionService=function(){function t(e){this.modelInteractionContextFactory=e,this.garbage=new I.GarbageCollector,this._navigationInProgress=(new I.DelegatingValueModel).withDefault(!1);var n=I.Dsl.disposeWith(this.garbage),o=n.chain,i=n.valueOf;n.before,n.when,n.after,n.observe,n.switchOn;this.exclusiveInteractionRegistry=new t.ContextRegistry,this.modalInteractionRegistry=new t.ContextRegistry,this.inPlaceInteractionRegistry=new t.ContextRegistry,this.modalInteractionRegistry.disableWhen(i.any(this.exclusiveInteractionRegistry.active,this.modalInteractionRegistry.active).areTruthy()),this.inPlaceInteractionRegistry.disableWhen(i.any(this.exclusiveInteractionRegistry.active,this.modalInteractionRegistry.active,this.inPlaceInteractionRegistry.active).areTruthy()),this.active=i.any(this.inPlaceInteractionRegistry.active,this.modalInteractionRegistry.active).areTruthy(),this.activeInteractionContextIds=o(this.inPlaceInteractionRegistry.interactionContextIds).concat(this.modalInteractionRegistry.interactionContextIds),this.activeModalContext=o(this.modalInteractionRegistry.interactionContexts).first(),this.inModalInteraction=o(this.activeModalContext).isNotNil()}return t.prototype.isActive=function(){return this.active.value},t.prototype.createModalInteractionContextFor=function(t){return this.createModalInteractionContextDisposedWith(t)},t.prototype.createModalInteractionContextDisposedWith=function(e){return this.modelInteractionContextFactory.createInteractionContext("modal",new t.ApiAdapter(this.placeRouter,this.modalInteractionRegistry))},t.prototype.registerInplaceInteractionContext=function(e){e.initialise("ip"+ ++Se,new t.ApiAdapter(this.placeRouter,this.inPlaceInteractionRegistry))},t.prototype.registerPlaceRouter=function(e){var n=this;x.assert.isFalsey(this.placeRouter),this.placeRouter=e,this._navigationInProgress.setDelegate(this.placeRouter.navigationInProgress);var o=this;return new xe(this.activeInteractionContextIds,this.activeModalContext,(function(){return o.modelInteractionContextFactory.createInteractionContext("exclusive",new t.ApiAdapter(n.placeRouter,n.exclusiveInteractionRegistry))}))},t}(),t.InteractionService.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t.InteractionService(n.ɵɵinject(Re))},token:t.InteractionService,providedIn:"root"}),t.InteractionService.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.InteractionService.ctorParameters=function(){return[{type:Re}]},function(t){var e=function(t){function e(){var e=t.call(this)||this;e._interactions=new I.MutableListModel,e._disabledDelegate=(new I.DelegatingValueModel).withDefault(!1);var n=I.Dsl.disposeWith(e),o=n.chain;n.valueOf,n.before,n.when,n.after,n.observe,n.switchOn;return e.active=o(e._interactions).isNotEmpty(),e.interactionContextIds=o(e._interactions).pluck("identifier"),e}return B(e,t),Object.defineProperty(e.prototype,"interactionContexts",{get:function(){return this._interactions.readonly},enumerable:!1,configurable:!0}),e.prototype.start=function(t){this._interactions.push(t)},e.prototype.finish=function(t){this._interactions.remove(t)},e.prototype.isActive=function(){return this.active.value},e.prototype.disableWhen=function(t){this._disabledDelegate.setDelegate(t)},e}(I.GarbageCollector);t.ContextRegistry=e;var n=function(){function t(t,e){this.placeRouter=t,this.contextRegistry=e}return t.prototype.notifyActive=function(t){return x.assert.isTruthy(t.identifier),this.contextRegistry.start(t),this.isNavigationInProgress()?Promise.resolve():this.placeRouter.syncInteractionContextIdsWithRouter()},t.prototype.isNavigationInProgress=function(){return this.placeRouter.navigationInProgress.value},t.prototype.notifyFinished=function(t){return this.contextRegistry.finish(t),this.isNavigationInProgress()?Promise.resolve():this.placeRouter.syncInteractionContextIdsWithRouter()},t}();t.ApiAdapter=n}(t.InteractionService||(t.InteractionService={}));var Ae=function(t){function e(e,n){var o=t.call(this)||this;return o.interactionService=e,o.tabConfig=n,o.animateFirstActivity=!0,o}return B(e,t),Object.defineProperty(e.prototype,"animationDuration",{get:function(){var t;return this.animateFirstActivity?(null===(t=this.tabConfig)||void 0===t?void 0:t.animationDuration)||"500ms":"0ms"},enumerable:!1,configurable:!0}),e.prototype.ngAfterViewInit=function(){this.interactionService.registerInplaceInteractionContext(this)},e.prototype.initialise=function(t,e){this.activityContainerComponent.initialise(t,e)},Object.defineProperty(e.prototype,"identifier",{get:function(){return this.activityContainerComponent.identifier},enumerable:!1,configurable:!0}),e.prototype.alert=function(t){return this.activityContainerComponent.alert(t)},e.prototype.cancelActiveActivity=function(){return this.activityContainerComponent.cancelActiveActivity()},e.prototype.confirm=function(t){return this.activityContainerComponent.confirm(t)},e.prototype.confirmOrReject=function(t){return this.activityContainerComponent.confirmOrReject(t)},e.prototype.confirmThen=function(t,e,n){return this.activityContainerComponent.confirmThen(t,e)},e.prototype.isActive=function(){return this.activityContainerComponent.isActive()},e.prototype.startActivity=function(t,e,n){return this.activityContainerComponent.startActivity(t,e,n)},e}(Y);Ae.decorators=[{type:n.Component,args:[{selector:"aup-in-place-interaction-context",template:'<mat-tab-group no-tab-header [selectedIndex]="isActive() ? 1 : 0" full-height-tabs [dynamicHeight]="false" [animationDuration]="animationDuration">\n <mat-tab>\n <ng-content></ng-content>\n </mat-tab>\n <mat-tab>\n <aup-activity-container #activityContainer [dynamicHeight]="false"></aup-activity-container>\n </mat-tab>\n</mat-tab-group>\n\n',styles:[":host{display:flex;flex-direction:column}mat-tab-group{flex:1}"]}]}],Ae.ctorParameters=function(){return[{type:t.InteractionService},{type:void 0,decorators:[{type:n.Inject,args:[c.MAT_TABS_CONFIG]},{type:n.Optional}]}]},Ae.propDecorators={activityContainerComponent:[{type:n.ViewChild,args:["activityContainer",{static:!0}]}],animateFirstActivity:[{type:n.Input}]};var Oe=function(t){function e(){var e=t.call(this)||this;return e.icon="mat:add",e.tabindex=0,e.clickCommand=I.Command.create((function(t){e.activityClass?e.startActivity(e.activityClass,e.activityData).catch((function(t){})):e.addCommand.withContext(t).execute()})),e}return B(e,t),Object.defineProperty(e.prototype,"active",{get:function(){return!!this.interactionContext&&this.interactionContext.isActive()},enumerable:!1,configurable:!0}),e.prototype.startActivity=function(t,e){return this.interactionContext.startActivity(t,e)},e.prototype.ngOnInit=function(){},e}(Y);Oe.decorators=[{type:n.Component,args:[{selector:"aup-add-item-interaction-context",template:'<aup-in-place-interaction-context [animateFirstActivity]="false">\n <a part="link" class="link" [pectinCommand]="clickCommand"><aup-icon [icon]="icon"></aup-icon> {{label}}</a>\n</aup-in-place-interaction-context>\n',styles:[":host{--def-link-background:var(--link-background,transparent);--def-link-background-hover:var(--link-background-hover,rgba(0,0,0,0.05));--def-link-border-radius:var(--link-border-radius,4px);--def-link-color:var(--link-color,currentColor);--def-link-color-hover:var(--link-color-hover,currentColor);--def-link-padding:var(--link-padding,calc(var(--aup-default-padding)/2));border-radius:var(--def-link-border-radius);box-sizing:border-box;display:flex;flex-direction:column;outline:none}:host:hover a.link{background-color:var(--def-link-background-hover);color:var(--def-link-color-hover)}a.link,aup-in-place-interaction-context{border-radius:var(--def-link-border-radius)}a.link{align-items:center;background:var(--def-link-background);color:var(--def-link-color);cursor:pointer;display:flex;flex-direction:row;padding:var(--def-link-padding);text-decoration:none}a.link mat-icon{margin-right:8px}"]}]}],Oe.ctorParameters=function(){return[]},Oe.propDecorators={label:[{type:n.Input}],icon:[{type:n.Input}],activityClass:[{type:n.Input}],activityData:[{type:n.Input}],addCommand:[{type:n.Input}],interactionContext:[{type:n.ViewChild,args:[Ae]}],active:[{type:n.HostBinding,args:["class.interaction-active"]}],tabindex:[{type:n.HostBinding,args:["tabindex"]}]},q([I.TrackExternal(),W("design:type",I.Command)],Oe.prototype,"addCommand",void 0);var De=function(t){function e(e,n,o){var i=t.call(this)||this;return i._element=e,i._overlay=n,i.outputPortal=new l.ComponentPortal(Ae),i.anchorX="start",i.anchorY="bottom",i.scrollContainers=o?[o]:[],i}return B(e,t),Object.defineProperty(e.prototype,"active",{get:function(){return this.isActive()},enumerable:!1,configurable:!0}),e.prototype.startActivity=function(t,e){var n=this,o=this._overlay.create({hasBackdrop:!1,panelClass:"aup-popup-interaction-panel",positionStrategy:this._overlay.position().flexibleConnectedTo(this._element).withPush(!0).withPositions(this.computePositions()).withGrowAfterOpen(!0).withScrollableContainers(this.scrollContainers)}),i=this.scrollContainers.map((function(t){return t.elementScrolled().subscribe((function(){o.updatePosition()}))})),r=o.attach(this.outputPortal);return this.interactionContext=r.instance,new Promise((function(r,a){setTimeout((function(){n.interactionContext.startActivity(t,e).then(r).catch(a).finally((function(){i.forEach((function(t){return t.unsubscribe()})),o.dispose()})),setTimeout((function(){o.updatePosition()}))}))}))},e.prototype.computePositions=function(){var t="start"===this.anchorX?"start":"end",e="top"===this.anchorY?"bottom":"top";return[{originX:this.anchorX,originY:this.anchorY,overlayX:t,overlayY:e}]},e.prototype.cancelActiveActivity=function(){return this.interactionContext.cancelActiveActivity()},e.prototype.isActive=function(){return this.interactionContext&&this.interactionContext.isActive()},e.prototype.ngOnInit=function(){},e}(Y);De.decorators=[{type:n.Component,args:[{selector:"aup-popup-interaction-context",template:"<ng-content></ng-content>\n",styles:[":host{display:inline}:host.interaction-active{background:rgba(0,0,0,.05)}"]}]}],De.ctorParameters=function(){return[{type:n.ElementRef},{type:D.Overlay},{type:D.CdkScrollable,decorators:[{type:n.Optional},{type:n.SkipSelf}]}]},De.propDecorators={active:[{type:n.HostBinding,args:["class.interaction-active"]}],anchorX:[{type:n.Input}],anchorY:[{type:n.Input}]};var Te=function(t){function e(){var e=t.call(this)||this;return e.activityDone=new n.EventEmitter,e.activityCancelled=new n.EventEmitter,e}return B(e,t),e.prototype.onEnter=function(t){t.preventDefault(),t.stopPropagation(),this.aupInteractionContextTriggerFor.isActive()?this.aupInteractionContextTriggerFor.cancelActiveActivity():this.startActivity()},e.prototype.onClick=function(t){t.preventDefault(),t.stopPropagation(),this.aupInteractionContextTriggerFor.isActive()?this.aupInteractionContextTriggerFor.cancelActiveActivity():this.startActivity()},e.prototype.startActivity=function(){var t=this;I.assert.isTruthy(this.aupInteractionContextTriggerFor),I.assert.isFalsey(this.aupInteractionContextTriggerFor.isActive()),I.assert.isTruthy(this.activityClass),this.aupInteractionContextTriggerFor.startActivity(this.activityClass,this.activityData).then((function(e){t.activityDone.emit(e)})).catch((function(e){t.activityCancelled.emit(e)}))},e.prototype.prepareActivityData=function(){return j.default.isFunction(this.activityDataFactory())?this.activityDataFactory():this.activityData},e}(I.GarbageCollector);Te.decorators=[{type:n.Directive,args:[{selector:"[aupInteractionContextTriggerFor]"}]}],Te.ctorParameters=function(){return[]},Te.propDecorators={aupInteractionContextTriggerFor:[{type:n.Input}],activityClass:[{type:n.Input}],activityData:[{type:n.Input}],activityDataFactory:[{type:n.Input}],activityDone:[{type:n.Output}],activityCancelled:[{type:n.Output}],onEnter:[{type:n.HostListener,args:["keyup.enter",["$event"]]}],onClick:[{type:n.HostListener,args:["click",["$event"]]}]};var Ee=function(t){function e(e){var n=t.call(this)||this;n.data=e,n.class="aup-input-activity";var o=new I.DirtyTrackingForm;return n.valueModel=o.valueModel(n.data.initialValue),n.valueModel.validateUsing(e.validators||[]),n.confirmCommand=I.Command.create((function(){if(n.valueModel.validate()){if(e.save)return Promise.resolve(e.save(n.valueModel,n.interactionContext)).then((function(){return n.done()}));n.done(n.valueModel.value)}})),n.cancelCommand=I.Command.create((function(){n.cancel()})),n}return B(e,t),e.prototype.onActivityReady=function(){this.valueModel.focusContext.requestFocus()},e}(ge);Ee.decorators=[{type:n.Component,args:[{template:""}]}],Ee.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[he]}]}]},Ee.propDecorators={class:[{type:n.HostBinding,args:["class"]}]};var Fe=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e}(Ee);Fe.decorators=[{type:n.Component,args:[{selector:"aup-string-input-activity",template:'\n <aup-string-input [valueModel]="valueModel"\n [label]="data.label"\n [placeholder]="data.placeholder"\n [command.enter]="confirmCommand"\n [command.escape]="cancelCommand"></aup-string-input>\n <aup-activity-actions align="end"\n [confirmCommand]="confirmCommand"\n [cancelCommand]="cancelCommand"\n [style]="data.buttonStyle"></aup-activity-actions>\n '}]}];var ke=function(t){function e(){var e=t.apply(this,X(arguments))||this;return e.defaultOptionLabelFormat=function(t){return e.data.optionLabel?t[e.data.optionLabel]:t},e}return B(e,t),Object.defineProperty(e.prototype,"optionLabelFormat",{get:function(){var t;return null!==(t=this.data.optionLabelFormat)&&void 0!==t?t:this.defaultOptionLabelFormat},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"options",{get:function(){var t;return(null===(t=this.data.optionsModel)||void 0===t?void 0:t.value)||this.data.options},enumerable:!1,configurable:!0}),e}(Ee);ke.decorators=[{type:n.Component,args:[{selector:"aup-select-input-activity",template:'\n <aup-select-input [valueModel]="valueModel"\n [label]="data.label"\n [placeholder]="data.placeholder"\n [command.enter]="confirmCommand"\n [command.escape]="cancelCommand"\n [options]="options"\n [optionLabelFormat]="optionLabelFormat"\n ></aup-select-input>\n <aup-activity-actions align="end"\n [confirmCommand]="confirmCommand"\n [cancelCommand]="cancelCommand"\n [style]="data.buttonStyle"\n ></aup-activity-actions>\n '}]}];var _e,Le=function(t,e){this.width=t,this.height=e},Ve=function(){function t(t,e){this.x=t,this.y=e}return t.from=function(e){return new t(e.x,e.y)},t.prototype.translate=function(e,n){return new t(this.x+e,this.y+n)},t}();t.Bounds=function(t){function e(e,n,o,i){var r=t.call(this,o,i)||this;return r.top=e,r.left=n,r.width=o,r.height=i,r}return B(e,t),e.prototype.relativePositionOf=function(t){return t instanceof MouseEvent?new Ve(t.clientX-this.left,t.clientY-this.top):new Ve(t.x-this.left,t.y-this.top)},e}(Le),(_e=t.Bounds||(t.Bounds={})).ofElement=function(t){var e=t.getBoundingClientRect();return new _e(e.top,e.left,e.width,e.height)};var je=function(e){function n(n,o){var i=e.call(this)||this;return i.elementRef=n,i.ngZone=o,i._boundsModel=new I.MutableValueModel(new t.Bounds(0,0,0,0)),i}return B(n,e),n.prototype.ngAfterViewInit=function(){var t=this;this.updateBounds();var e=this.elementRef.nativeElement,n=new U.default((function(e,n){t.ngZone.run((function(){return t.updateBounds()}))}));n.observe(e),this.onDispose((function(){return n.disconnect()}))},Object.defineProperty(n.prototype,"boundsModel",{get:function(){return this._boundsModel.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"nativeElement",{get:function(){return this.elementRef.nativeElement},enumerable:!1,configurable:!0}),n.prototype.relativePositionOf=function(t){return this.bounds.relativePositionOf(t)},Object.defineProperty(n.prototype,"bounds",{get:function(){return this._boundsModel.value},enumerable:!1,configurable:!0}),n.prototype.updateBounds=function(){this._boundsModel.value=t.Bounds.ofElement(this.nativeElement)},n}(Y);je.decorators=[{type:n.Directive}],je.ctorParameters=function(){return[{type:n.ElementRef},{type:n.NgZone}]};var Ne=function(){};Ne.decorators=[{type:n.NgModule,args:[{imports:[e.CommonModule,d.MatButtonModule,A.MatDialogModule,c.MatTabsModule,l.PortalModule,O.RouterModule,h.MatIconModule,tt,S.FlexModule,S.GridModule,me],declarations:[Me,Ce,be,ve,Pe,Ae,Oe,ye,De,Fe,ke,Ee,Te,ge],exports:[Me,Pe,Ae,Oe,ye,De,Te,Fe,ke],entryComponents:[Me,Ce,be,ve],providers:[t.InteractionService]}]}];var Ue=new n.InjectionToken("PlaceAuthService");t.ParameterDefinition=function(){function t(t,e,n){this.propertyName=t,this.urlFormat=n,this.options=x.Opts.get(e),this.remember=this.options.getOptional("remember",!1),this.defaultValue=this.options.getOptional("defaultValue",null)}return Object.defineProperty(t.prototype,"name",{get:function(){return this.options.getOptional("as",this.propertyName)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRouteParameter",{get:function(){return!!this.urlFormat},enumerable:!1,configurable:!0}),t.prototype.getOptionValue=function(t){return this.options.getOptional(t,null)},t.prototype.sanitise=function(t,e,n,o,i){return z(this,void 0,void 0,(function(){var o;return G(this,(function(i){return this.isMissingFrom(e)&&!n.lastVisitIncluded(e.placeDefinition)?(o=n.getMostRecentVisitFor(e.placeDefinition),this.remember&&o&&(t=o.getParameter(this.name)),[2,this.isEmptyValue(t)?this.defaultValue:t]):[2,t]}))}))},t.prototype.isMissingFrom=function(t){return!t.hasParameter(this.name)},t}(),function(t){var e=function(t){function e(){var e=t.apply(this,X(arguments))||this;return e.isRouteId=!0,e.isArray=!1,e}return B(e,t),e.prototype.isEmptyValue=function(t){return j.default.isNil(t)},e.prototype.hasChanged=function(t,e){return t!==e},e}(t);t.RouteId=e;var n=function(t){function e(){var e=t.apply(this,X(arguments))||this;return e.isRouteId=!1,e.isArray=!1,e}return B(e,t),e.prototype.isEmptyValue=function(t){return j.default.isNil(t)},e.prototype.hasChanged=function(t,e){return t!==e},e}(t);t.ValueParameter=n;var o=function(t){function e(e,n,o){var i=t.call(this,e,n,o)||this;return i.isRouteId=!1,i.isArray=!0,i}return B(e,t),e.prototype.isEmptyValue=function(t){return j.default.isNil(t)||t.length<1},e.prototype.hasChanged=function(t,e){return!j.default.isEqual(t,e)},e}(t);t.ArrayParameter=o}(t.ParameterDefinition||(t.ParameterDefinition={}));var He=function(){function t(t,e,n,o,i,r,a){this.component=t,this.path=e,this.authenticate=n,this.roles=o,this.data=i,this.routeParameters=r,this.children=a}return t.prototype.hasRouteId=function(){return!!this.getRouteIdParameterDef()},t.prototype.getRouteIdParameterDef=function(){return this.routeParameters.find((function(t){return t.isRouteId}))},t.prototype.getRouteParameterDefs=function(t){return void 0===t&&(t=!1),this.getVisitParameterDefs({includeRouteId:t,includeRouteParameters:!0})},t.prototype.getVisitParameterDefs=function(t){var e=x.Opts.get(t),n=!t||e.getOptional("includeRouteId",!1),o=!t||e.getOptional("includeRouteParameters",!1),i=!t||e.getOptional("includeNonRouteParameters",!1);return this.routeParameters.filter((function(t){return n&&t.isRouteId||o&&t.isRouteParameter&&!t.isRouteId||i&&!t.isRouteParameter}))},t.prototype.getPlaceData=function(t,e){return this.data?j.default.isNil(this.data[t])?e:this.data[t]:e},t.prototype.searchPlaceData=function(t,e){var n=this;if(this.data){var o=t.find((function(t){return!j.default.isNil(n.data[t])}));return o?this.data[o]:e}return e},t.prototype.getRouteIdFrom=function(t){var e=this.getRouteIdParameterDef();return e?t.getParameter(e.name):null},t.prototype.getFormattedRouteId=function(t){return t.hasRouteId()?this.getRouteIdParameterDef().urlFormat.format(t.getRouteId()):""},t.prototype.getFormattedRouteParameters=function(t,e){void 0===e&&(e=!1);var n={};return this.getVisitParameterDefs({includeRouteId:e,includeRouteParameters:!0}).forEach((function(e){var o=t.getParameter(e.name);e.isEmptyValue(o)||(e.isArray?(I.assert.isArray(o),n[e.name]=o.map((function(t){return e.urlFormat.format(t)}))):(I.assert.isFalsey(Array.isArray(o)),n[e.name]=e.urlFormat.format(o)))})),n},t.prototype.getNonRouteParameters=function(t){var e={};return this.getVisitParameterDefs({includeNonRouteParameters:!0}).forEach((function(n){var o=t.getParameter(n.name);n.isEmptyValue(o)||(e[n.name]=o)})),e},t.prototype.parseRouteParams=function(t){var e={};return this.getVisitParameterDefs({includeRouteId:!0,includeRouteParameters:!0,includeNonRouteParameters:!1}).forEach((function(n){if(t.has(n.name))if(n.isArray){var o=t.get(n.name).split(",").map((function(t){return t.trim()}));e[n.name]=o.map((function(t){return n.urlFormat.parse(t)}))}else{var i=t.get(n.name);n.isRouteId&&j.default.isEmpty(i)||(e[n.name]=n.urlFormat.parse(i))}})),e},t}();q([w.Memoize(),W("design:type",Function),W("design:paramtypes",[]),W("design:returntype",t.ParameterDefinition)],He.prototype,"getRouteIdParameterDef",null),q([w.Memoize(),W("design:type",Function),W("design:paramtypes",[Object]),W("design:returntype",Array)],He.prototype,"getRouteParameterDefs",null),q([w.Memoize(),W("design:type",Function),W("design:paramtypes",[Object]),W("design:returntype",Array)],He.prototype,"getVisitParameterDefs",null);var Be="PLACE_DEFINITION_OPTIONS",qe=Symbol("place:route:parameters");t.PlaceComponent=function(t){function e(){var e=t.call(this)||this;e.visitModel=new I.MutableValueModel,e._inVisitUpdate=new I.Guard,e._active=new I.MutableValueModel(!1);var n=I.Dsl.disposeWith(e),o=(n.chain,n.valueOf,n.before,n.when);n.after,n.observe,n.switchOn;return o(e._active).becomesTruthy((function(){return e.onPlaceReady()})),e}return B(e,t),e.prototype.initialiseVisit=function(t,e){var n=this;I.assert.isNil(this.visitModel.value);var o=I.Dsl.disposeWith(this).when;this.visitModel.value=t,I.DebugContext.getOrCreate(this.visitModel).tag(this.placeDefinition.component.name+".visitModel"),this.placeDefinition.getVisitParameterDefs().forEach((function(t){return n.installBinding(t)})),o(this.visitModel).changes((function(t,n){e(t,n)}),{unless:this._inVisitUpdate})},e.prototype.updateVisit=function(t){var e=this;I.assert.isTruthy(this.isInitialised()),I.assert.notNil(t),this._inVisitUpdate.whileTrue((function(){e.visitModel.value=t}))},e.prototype.isInitialised=function(){return!!this.visitModel.value},e.prototype.installBinding=function(t){var e=this[t.propertyName];I.DebugContext.tag(e,this.placeDefinition.component.name+"."+t.propertyName),this.registerDisposable(new I.Binding(this.visitModel,e,{toRight:function(e){return e.getParameter(t.name)},toLeft:function(e,n){return n.replace(t,e)}})).writeRight()},Object.defineProperty(e.prototype,"placeDefinition",{get:function(){return e.getDefinition(this.constructor)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childPlaces",{get:function(){return this.placeDefinition.children.map((function(t){return t.component}))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"active",{get:function(){return this._active.readonly},enumerable:!1,configurable:!0}),e.prototype._notifyActive=function(t){this._active.value=t},e.prototype.onPlaceReady=function(){},e}(Y),t.PlaceComponent.decorators=[{type:n.Directive}],t.PlaceComponent.ctorParameters=function(){return[]},q([k.Memoize(),W("design:type",He),W("design:paramtypes",[])],t.PlaceComponent.prototype,"placeDefinition",null),function(t){function e(e){return I.lang.constructorChain(e).includes(t)}t.isPlaceComponentConstructor=e,t.getRouteParameters=function(t){return x.Klass.get(t).getMetadataList(qe)},t.getDefinition=function(t){if(t instanceof O.ActivatedRouteSnapshot){var n=t.component;if(!e(n))throw new Error("ActivatedRouteSnapshot component is not a PlaceComponent, got "+n);return Reflect.getMetadata(Be,n)}return Reflect.getMetadata(Be,t)},t.injectDefinition=function(t,e){Reflect.defineMetadata(Be,e,t)}}(t.PlaceComponent||(t.PlaceComponent={}));var We=function(){function t(t,e){void 0===e&&(e={}),this.placeDefinition=t,this.visitParameters=e}return t.prototype.getRouteId=function(){return this.placeDefinition.getRouteIdFrom(this)},t.prototype.hasRouteId=function(){return!P.isNil(this.getRouteId())},t.prototype.getParameter=function(t){return this.visitParameters[t]},t.prototype.hasParameter=function(t){return Object.keys(this.visitParameters).includes(t)},t.prototype.replace=function(e,n){var o;return new t(this.placeDefinition,Object.assign(Object.assign({},this.visitParameters),((o={})[e.name]=n,o)))},t.prototype.mergeRouteParameters=function(e){var n=this,o=Object.keys(e),i={};return this.placeDefinition.getVisitParameterDefs().forEach((function(t){if(t.isRouteId||t.isRouteParameter)o.includes(t.name)&&(i[t.name]=e[t.name]);else{var r=n.getParameter(t.name);n.hasParameter(t.name)&&(i[t.name]=r)}})),new t(this.placeDefinition,i)},t.prototype.hasRoutingChangedFrom=function(t){var e=t.placeDefinition===this.placeDefinition,n=P.isEqual(this.placeDefinition.getFormattedRouteParameters(this,!0),this.placeDefinition.getFormattedRouteParameters(t,!0));return!e||!n},t.prototype.hasChangedFrom=function(t){return!P.isEqual(this.placeDefinition.getNonRouteParameters(this),this.placeDefinition.getNonRouteParameters(t))||this.hasRoutingChangedFrom(t)},t.prototype.toDebugString=function(){var t=this;return Object.keys(this.visitParameters).map((function(e){return e+"="+t.visitParameters[e]})).join(",")},t}(),ze=new n.InjectionToken("AUP_PLACE_CONFIG"),Ge=function(){function t(t,e,n){this.component=t,this.navigationSession=e,this.isPrimaryComponent=n}return Object.defineProperty(t.prototype,"routerInteractionAdapter",{get:function(){return this.navigationSession.interactionServiceAdapter},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"urlService",{get:function(){return this.navigationSession.urlService},enumerable:!1,configurable:!0}),t.prototype.canDeactivate=function(t,e){return z(this,void 0,void 0,(function(){return G(this,(function(n){return this.canDeactivatePromise||(this.canDeactivatePromise=this.canDeactivateComponent(t,e)),[2,this.canDeactivatePromise]}))}))},t.prototype.canDeactivateComponent=function(t,e){return z(this,void 0,void 0,(function(){var t,n;return G(this,(function(o){switch(o.label){case 0:return this.navigationSession.isPopState?this.isPrimaryComponent&&this.routerInteractionAdapter.isModalActive()?(t=this.urlService.getActiveInteractionIdsFromUrl(e.url),n=this.routerInteractionAdapter.getActiveInteractionContextIds(),P.isEqual(n,t)?[3,2]:[4,this.routerInteractionAdapter.cancelCurrentModalInteraction()]):[3,3]:[3,5];case 1:return o.sent(),[2,!1];case 2:return[3,5];case 3:return this.routerInteractionAdapter.isComponentInteracting(this.component)?[4,this.routerInteractionAdapter.cancelComponentInteraction(this.component)]:[3,5];case 4:return o.sent(),[2,!1];case 5:if(this.isNotJustAChangeInRouteId(e)){if(this.component.canDeactivate)return[2,this.component.canDeactivate(this.navigationSession.canDeactivateInteractionContext)];if(this.routerInteractionAdapter.isComponentInteracting(this.component))return console.warn("Route changed while component has active interaction, cancelling navigation"),[2,!1]}return[2,!0]}}))}))},t.prototype.isNotJustAChangeInRouteId=function(t){return!t.includesPathOf(this.component.placeDefinition)},t}(),Ke=function(t){function e(e,n){var o=t.call(this)||this;return o.context=e,o.startingUrl=n,o.debugPropertyKeys=[],o._visits=new Map,o.componentDeactivationHandlers=new Map,o._interactionContext=o.context.routerInteractionAdapter.createExclusiveInteractionContext(),o.onDispose((function(){o._interactionContext&&o._interactionContext.dispose()})),o}return B(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return this.constructor.name},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"urlService",{get:function(){return this.context.urlService},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"interactionServiceAdapter",{get:function(){return this.context.routerInteractionAdapter},enumerable:!1,configurable:!0}),e.prototype.storeVisit=function(t){this._visits.set(t.placeDefinition,t)},e.prototype.getVisitFor=function(t){return this._visits.get(t)},Object.defineProperty(e.prototype,"canDeactivateInteractionContext",{get:function(){return this._interactionContext},enumerable:!1,configurable:!0}),e.prototype.notifyActive=function(){},e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onUrlChange=function(t){this.canDeactivateInteractionContext&&this.canDeactivateInteractionContext.isActive()&&this.cancelCanDeactivateInteraction(t)},e.prototype.onPopState=function(t){return this.illegalTransition(t)},e.prototype.onRouterCancelled=function(t){return this.illegalTransition(t)},e.prototype.onRouterError=function(t){return this.illegalTransition(t)},e.prototype.onRouterEnd=function(t){return this.illegalTransition(t)},e.prototype.getVisits=function(){return Array.from(this._visits.values())},e.prototype.illegalTransition=function(t){return I.lang.illegalState(t.toString()+" not supported by "+this.toString())},e.prototype.currentRouterUrl=function(){return this.urlService.getCurrentRouterUrl()},e.prototype.resetBrowserLocation=function(t,e){void 0===e&&(e={replaceCurrent:!1}),this.urlService.resetBrowserLocation(t,e)},e.prototype.repairBrowserHistoryAndUrlAfterGuardCancellation=function(t,e){I.Logger.get(this).info("WORK-AROUND: Updating browser location after pop state - see angular issue #13586"),console.log("replacing "+this.urlService.getCurrentLocationUrlSnapshot().url+" with "+t),this.urlService.resetBrowserLocation(t,{replaceCurrent:!0}),console.log("pushing "+e+" back onto the history."),this.urlService.resetBrowserLocation(e,{replaceCurrent:!1})},e.prototype.ignore=function(t,e){e=e?" -> "+e:"",I.Logger.get(this).info("Ignoring router event"+e+": "+t.constructor.name+" -> "+t.url+" :: "+this.toString())},e.prototype.toString=function(){return this.constructor.name+"("+this.debugState()+")"},e.prototype.debugState=function(t){var e=this;return(t||this.debugPropertyKeys).map((function(t){return t+": "+e[t]})).join(", ")},e.prototype.canDeactivatePlace=function(t,e,n){return z(this,void 0,void 0,(function(){var o,i;return G(this,(function(r){return(o=this.componentDeactivationHandlers.get(t))||(i=0===this.componentDeactivationHandlers.size,o=new Ge(t,this,i),this.componentDeactivationHandlers.set(t,o)),[2,o.canDeactivate(e,n).then((function(t){return t})).catch((function(t){throw t}))]}))}))},e.prototype.cancelCanDeactivateInteraction=function(t){I.Logger.get(this).info("back button pressed during navigation session interaction promise");var e=this.detachCanDeactivateInteractionContext();I.Logger.get(this).info("cancelling current navigation activity.."),e.cancelActiveActivity().then((function(){e.dispose()})),this.handleCanDeactivateCancelledEventScenario(t)},e.prototype.reinstateUrlAfterAngularChangedItOnCancellation=function(t){this.resetBrowserLocation(t,{replaceCurrent:!0})},e.prototype.detachCanDeactivateInteractionContext=function(){var t=this._interactionContext;return this._interactionContext=null,t},e}(I.GarbageCollector),Xe=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e.prototype.handleCanDeactivateCancelledEventScenario=function(t){x.lang.illegalState("onCanDeactivateInteractionCancelled not supported for event clean up states")},e}(Ke),$e=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.locationChangeTriggerUrl=o,i.isPopState=!1,i.firstCancelHandled=!1,i.popStateHandled=!1,i.debugPropertyKeys=["idle","startingUrl","poppedHistoryUrl","locationChangeTriggerUrl","popStateEventUrl","firstCancelHandled","popStateHandled"],i}return B(e,t),e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.repairBrowserHistoryAndUrlAfterGuardCancellation(this.locationChangeTriggerUrl,this.startingUrl),this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.ignore(t)},e.prototype.canDeactivatePlace=function(t,e,n){return z(this,void 0,void 0,(function(){return G(this,(function(t){return[2,!1]}))}))},e}(Xe),Ye=function(t){function e(e,n){var o=t.call(this,e,n)||this;return o.isPopState=!0,o.debugPropertyKeys=["startingUrl","poppedHistoryUrl"],o.finished=I.Deferred.defer(),o}return B(e,t),e.prototype.onPopState=function(t){this.gotPopState=!0},e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.ignore(t)},e.prototype.onUrlChange=function(t){},e.prototype.finishUp=function(){this.context.finishRoutingSession(),this.finished.resolve(!0)},e.prototype.onRouterEnd=function(t){this.gotPopState&&this.finishUp()},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){I.lang.illegalState("onCanDeactivateInteractionCancelled not supported for activity context synchronisation since we should never leave a place")},Object.defineProperty(e.prototype,"finishedPromise",{get:function(){return this.finished.promise},enumerable:!1,configurable:!0}),e}(Ke),Je=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.wasTriggeredByPopState=o,i.isPopState=!1,i}return B(e,t),e.prototype.notifyActive=function(){var t=this;setTimeout((function(){t.syncInteractionIdsWithRouter()}))},e.prototype.onRouterEnd=function(t){this.context.finishRoutingSession()},e.prototype.onRouterCancelled=function(t){this.context.finishRoutingSession()},e.prototype.syncInteractionIdsWithRouter=function(){var t=this.interactionServiceAdapter.getActiveInteractionContextIds(),e=this.urlService.getCurrentLocationUrlSnapshot().getInteractionIds();if(j.default.isEqual(t,e))this.context.finishRoutingSession();else if(t.length>e.length){var n=t.length>e.length&&e.length<1;this.addActivityContextToRoute(t,n)}else this.removeActivityContextFromRoute(t)},e.prototype.addActivityContextToRoute=function(t,e){var n=this,o=this.urlService.getCurrentRouterSnapshot().updateInteractionIds(t);this.context.navigateByUrl(o,{replaceUrl:!e}).then((function(e){n.urlService.getCurrentLocationUrlSnapshot().hasInteractionIds(t)||x.lang.illegalState("Expected url to be "+o.url+" but was "+n.urlService.getCurrentLocationUrl())}))},e.prototype.removeActivityContextFromRoute=function(t){var e=this.urlService.getCurrentRouterSnapshot().updateInteractionIds(t);if(t.length<1)if(this.wasTriggeredByPopState);else{var n=new Ye(this.context,this.urlService.getCurrentRouterUrl());this.context.transitionTo(n),this.urlService.back()}else this.context.navigateByUrl(e,{replaceUrl:!this.wasTriggeredByPopState})},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){x.lang.methodNotSupported()},e}(Ke),Ze=function(t){function e(){var e=t.apply(this,X(arguments))||this;return e.isPopState=!1,e}return B(e,t),e.prototype.onRouterCancelled=function(t){this.context.finishRoutingSession()},e.prototype.onRouterError=function(t){this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.context.routerInteractionAdapter.isActive()?this.context.transitionTo(new Je(this.context,this.startingUrl,!1)):this.context.finishRoutingSession(this.getVisits())},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.context.transitionTo(new $e(this.context,this.startingUrl,t))},e}(Ke),Qe=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.poppedHistoryUrl=o,i.isPopState=!0,i.debugPropertyKeys=["startingUrl","poppedHistoryUrl"],i}return B(e,t),e.prototype.repairBrowserHistoryAndUrlAfterGuardCancellation=function(){t.prototype.repairBrowserHistoryAndUrlAfterGuardCancellation.call(this,this.poppedHistoryUrl,this.startingUrl)},e}(Ke),tn=function(t){function e(e,n,o){return t.call(this,e,n,o)||this}return B(e,t),e.prototype.onRouterCancelled=function(t){this.repairBrowserHistoryAndUrlAfterGuardCancellation(),this.context.transitionTo(new Je(this.context,this.poppedHistoryUrl,!1))},e.prototype.onRouterEnd=function(t){this.context.finishRoutingSession()},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.illegalTransition("Leaving interaction after pop-state should't block so should never see a back button click")},e}(Qe),en=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.clickedLinkUrl=o,i.isPopState=!1,i.clickedLinkMatchedBackButtonUrl=!1,i.debugPropertyKeys=["idle","startingUrl","clickedLinkUrl","firstCancelEventUrl","clickedLinkMatchedBackButtonUrl","popStateEventUrl"],i}return B(e,t),e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){t.url===this.clickedLinkUrl?this.context.transitionTo(new rn(this.context,this.startingUrl,this.clickedLinkUrl)):this.context.transitionTo(new an(this.context,this.startingUrl,this.clickedLinkUrl))},e.prototype.canDeactivatePlace=function(t,e,n){return z(this,void 0,void 0,(function(){return G(this,(function(t){return[2,!1]}))}))},e}(Xe);q([I.Trace(),W("design:type",Function),W("design:paramtypes",[O.NavigationStart]),W("design:returntype",void 0)],en.prototype,"onRouterStarted",null),q([I.Trace(),W("design:type",Function),W("design:paramtypes",[O.NavigationCancel]),W("design:returntype",void 0)],en.prototype,"onRouterCancelled",null);var nn,on,rn=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.clickedLinkUrl=o,i.isPopState=!1,i.debugPropertyKeys=["idle","startingUrl","clickedLinkUrl","popStateEventUrl"],i}return B(e,t),e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.popStateEventUrl=t.url,this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.popStateEventUrl&&this.finaliseRouting()},e.prototype.finaliseRouting=function(){return this.repairBrowserHistoryAndUrlAfterGuardCancellation(this.clickedLinkUrl,this.startingUrl),this.context.finishRoutingSession()},e.prototype.canDeactivatePlace=function(t,e,n){return z(this,void 0,void 0,(function(){return G(this,(function(t){return[2,!1]}))}))},e}(Xe),an=function(t){function e(e,n,o){var i=t.call(this,e,n)||this;return i.clickedLinkUrl=o,i.isPopState=!1,i.debugPropertyKeys=["idle","startingUrl","clickedLinkUrl","popStateEventUrl"],i}return B(e,t),e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.popStateEventUrl=t.url,this.ignore(t)},e.prototype.onRouterCancelled=function(t){this.popStateEventUrl&&this.finaliseRouting()},e.prototype.finaliseRouting=function(){return this.repairBrowserHistoryAndUrlAfterGuardCancellation(this.clickedLinkUrl,this.startingUrl),this.context.finishRoutingSession()},e.prototype.canDeactivatePlace=function(t,e,n){return z(this,void 0,void 0,(function(){return G(this,(function(t){return[2,!1]}))}))},e}(Xe),cn=function(t){function e(){var e=t.apply(this,X(arguments))||this;return e.isPopState=!1,e.debugPropertyKeys=["startingUrl","urlAfterRedirects"],e}return B(e,t),e.prototype.onRouterCancelled=function(t){},e.prototype.onRouterError=function(t){this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.urlAfterRedirects=t.urlAfterRedirects,this.context.finishRoutingSession(this.getVisits())},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.context.transitionTo(new en(this.context,this.startingUrl,t))},e}(Ke);nn=t.NavigationContext||(t.NavigationContext={}),on=function(t,e,n,o,i){this.urlService=t,this.routerInteractionAdapter=e,this.navigateByUrl=n,this.transitionTo=o,this.finishRoutingSession=i},nn.Impl=on;var sn,ln,un,pn=function(t){function e(e,n,o,i){var r=t.call(this,e,n)||this;return r.locationChangeTriggerUrl=o,r.poppedHistoryUrl=i,r.isPopState=!1,r.firstCancelHandled=!1,r.popStateHandled=!1,r.debugPropertyKeys=["idle","startingUrl","poppedHistoryUrl","locationChangeTriggerUrl","popStateEventUrl","firstCancelHandled","popStateHandled"],r}return B(e,t),e.prototype.onRouterStarted=function(t){this.ignore(t)},e.prototype.onRouterCancelled=function(t){if(this.firstCancelHandled){if(this.popStateHandled){var e=t.url;return this.repairBrowserHistoryAndUrlAfterGuardCancellation(e,this.parentPageUrl),this.resetBrowserLocation(this.startingUrl,{replaceCurrent:!1}),this.context.finishRoutingSession()}}else this.firstCancelHandled=!0,this.parentPageUrl=t.url,this.ignore(t)},e.prototype.onRouterEnd=function(t){this.ignore(t)},e.prototype.onRouterError=function(t){this.ignore(t)},e.prototype.onPopState=function(t){this.popStateHandled=!0,this.popStateEventUrl=t.url,this.ignore(t)},e.prototype.canDeactivatePlace=function(t,e,n){return z(this,void 0,void 0,(function(){return G(this,(function(t){return[2,!1]}))}))},e}(Xe),dn=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return B(e,t),e.prototype.onRouterCancelled=function(t){this.repairBrowserHistoryAndUrlAfterGuardCancellation(),this.context.finishRoutingSession()},e.prototype.onRouterEnd=function(t){this.context.finishRoutingSession(this.getVisits())},e.prototype.handleCanDeactivateCancelledEventScenario=function(t){this.context.transitionTo(new pn(this.context,this.startingUrl,t,this.poppedHistoryUrl))},e}(Qe);t.PlaceHistory=function(){function t(){this._archive=new Map,this.placeHistoryDepth=4}return t.prototype.notifyNavigationStarted=function(){this._activeVisits&&(this.archive(this._activeVisits.visits),this._previousVisits=this._activeVisits)},t.prototype.notifyNavigationFinished=function(e){this._activeVisits=new t.VisitRecord(e)},t.prototype.updateVisit=function(t){I.assert.isTruthy(this._activeVisits),this._activeVisits.update(t)},t.prototype.lastVisitIncluded=function(t){var e;return!!(null===(e=this._previousVisits)||void 0===e?void 0:e.getVisitFor(t))},t.prototype.getMostRecentVisitFor=function(t){return j.default.first(this.getHistory(t))},t.prototype.getHistory=function(t){var e=this._archive.get(t);return e||(e=[],this.setHistory(t,e)),e},t.prototype.setHistory=function(t,e){this._archive.set(t,e)},t.prototype.archive=function(t){var e=this;t.forEach((function(t){var n=e.getHistory(t.placeDefinition),o=j.default.first(n);o&&!t.hasChangedFrom(o)||(n.unshift(t),e.setHistory(t.placeDefinition,n.slice(0,e.placeHistoryDepth)))}))},t}(),t.PlaceHistory.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t.PlaceHistory},token:t.PlaceHistory,providedIn:"root"}),t.PlaceHistory.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.PlaceHistory.ctorParameters=function(){return[]},sn=t.PlaceHistory||(t.PlaceHistory={}),ln=function(){function t(t){this.visits=t}return t.prototype.update=function(t){this.visits=this.visits.filter((function(e){return e.placeDefinition!==t.placeDefinition})).concat(t)},t.prototype.getVisitFor=function(t){return this.visits.find((function(e){return e.placeDefinition===t}))},t}(),sn.VisitRecord=ln,t.UrlSnapshot=function(){function t(t,e){this.urlSerializer=t,this.url=e,this.urlTree=t.parse(e)}return t.prototype.updateVisitSegments=function(e){var n=this.urlSerializer.parse(this.url),o=X(this.getPrimarySegments(n)),i=this.getSegmentsFor(e),r=o.findIndex((function(t){return t.path===i[0].path}));return o.splice.apply(o,X([r,i.length],i)),n.root.children.primary.segments=o,new t(this.urlSerializer,n.toString())},t.prototype.getPrimarySegments=function(t){return this.urlTree.root.children.primary.segments},t.prototype.getSegmentsFor=function(t){return t.placeDefinition.hasRouteId()?[new O.UrlSegment(t.placeDefinition.path,t.placeDefinition.getFormattedRouteParameters(t)),new O.UrlSegment(t.placeDefinition.getFormattedRouteId(t),{})]:[new O.UrlSegment(t.placeDefinition.path,t.placeDefinition.getFormattedRouteParameters(t))]},t.prototype.includesPathOf=function(t){return this.getPrimarySegments(this.urlTree).find((function(e){return e.path===t.path}))},t.prototype.getInteractionIds=function(){var e=this.urlTree.queryParams[t.INTERACTION_QUERY_PARAM];return e?t.parseInteractionIds(e):[]},t.prototype.hasInteractions=function(){return this.getInteractionIds().length>0},t.prototype.hasInteractionIds=function(t){return j.default.isEqual(this.getInteractionIds(),t)},t.prototype.updateInteractionIds=function(e){if(0===e.length)return this.removeInteractionIds();var n=this.urlSerializer.parse(this.url);return n.queryParams[t.INTERACTION_QUERY_PARAM]=t.createPathIdFor(e),new t(this.urlSerializer,n.toString())},t.prototype.removeInteractionIds=function(){var e=this.urlSerializer.parse(this.url);return e.queryParams&&e.queryParams[t.INTERACTION_QUERY_PARAM]&&(e.queryParams={}),new t(this.urlSerializer,e.toString())},t.prototype.toString=function(){return"UrlSnapshot("+this.url+")"},t}(),(un=t.UrlSnapshot||(t.UrlSnapshot={})).INTERACTION_QUERY_PARAM="aup-interactions",un.INTERACTION_ID_SEPARATOR="--",un.parseInteractionIds=function(t){return t.split(un.INTERACTION_ID_SEPARATOR)},un.createPathIdFor=function(t){return t.join(un.INTERACTION_ID_SEPARATOR)};var fn=function(){function e(t,e,n){this.angularRouter=t,this.angularLocation=e,this.urlSerializer=n}return e.prototype.parseUrl=function(e){return new t.UrlSnapshot(this.urlSerializer,e)},e.prototype.createUrlSnapshot=function(){for(var t=this,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var o=[];return e.forEach((function(e){o.push(t.parseUrl(""+e.placeDefinition.path).updateVisitSegments(e).url)})),this.parseUrl(o.join(""))},e.prototype.getCurrentRouterUrl=function(){return this.angularRouter.routerState?this.angularRouter.routerState.snapshot.url:null},e.prototype.getCurrentLocationUrl=function(){return this.angularLocation.path()},e.prototype.getCurrentLocationUrlSnapshot=function(){return this.parseUrl(this.getCurrentLocationUrl())},e.prototype.getCurrentRouterSnapshot=function(){return this.parseUrl(this.getCurrentRouterUrl())},e.prototype.getActiveInteractionIdsFromUrl=function(t){return this.parseUrl(t).getInteractionIds()},e.prototype.hasActiveInteractions=function(t){return this.getActiveInteractionIdsFromUrl(t).length>0},e.prototype.resetBrowserLocation=function(t,e){e.replaceCurrent?this.angularLocation.replaceState(t):this.angularLocation.go(t)},e.prototype.back=function(){this.angularLocation.back()},e}();fn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new fn(n.ɵɵinject(O.Router),n.ɵɵinject(e.Location),n.ɵɵinject(O.UrlSerializer))},token:fn,providedIn:"root"}),fn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],fn.ctorParameters=function(){return[{type:O.Router},{type:e.Location},{type:O.UrlSerializer}]};var mn=function(e){function n(n,o,i,r,a){var c=e.call(this)||this;c.angularRouter=n,c.angularLocation=o,c.interactionService=i,c.urlService=r,c.placeHistory=a,c.navigationSessionModel=new I.MutableValueModel,c._activeVisits=new I.MutableListModel,c.sessionFinishedJobs=[],window.Cypress&&(window["aup.PlaceRouter"]=c),c.routerInteractionAdapter=i.registerPlaceRouter(c),c.navigationContext=new t.NavigationContext.Impl(c.urlService,c.routerInteractionAdapter,(function(t,e){return c.navigateByUrl(t,e)}),(function(t){c.transitionTo(t)}),(function(t){c.routingSessionFinished(t)}));var s=I.Dsl.disposeWith(c),l=s.chain;s.valueOf,s.before,s.when,s.after,s.observe,s.switchOn;c.navigationInProgress=l(c.navigationSessionModel).isNotNil();var u=l(c.interactionService.active).map((function(t){return t?"IdleDuringInteraction":"Idle"}));return c.navigationSessionName=l(c.navigationSessionModel).pluck("name").otherwise(u),I.DebugContext.tag(c._activeVisits,"PlaceRouter.activeVisits"),c.activeVisitsByPlaceDefinition=l(c._activeVisits).indexBy("placeDefinition"),n.events.subscribe((function(t){t instanceof O.NavigationStart&&("popstate"===t.navigationTrigger?c.onPopState(t):c.onRouterStarted(t)),t instanceof O.NavigationEnd&&c.onRouterEnd(t),t instanceof O.NavigationError&&c.onRouterError(t),t instanceof O.NavigationCancel&&c.onRouterCancelled(t)})),o.onUrlChange((function(t){return c.onUrlChanged(t)})),c}return B(n,e),Object.defineProperty(n.prototype,"navigationSession",{get:function(){return this.navigationSessionModel.value},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"currentSession",{get:function(){return this.navigationSessionModel.value},enumerable:!1,configurable:!0}),n.prototype.isNavigating=function(){return this.navigationInProgress.value},n.prototype.onPopState=function(t){if(I.assert.isTruthy("popstate"===t.navigationTrigger),this.currentSession)this.currentSession.onPopState(t);else{var e=t.url,n=this.urlService.getCurrentRouterUrl(),o=this.interactionService.isActive()?new tn(this.navigationContext,n,e):new dn(this.navigationContext,n,e);this.transitionTo(o)}},n.prototype.onRouterStarted=function(t){I.assert.isFalsey("popstate"===t.navigationTrigger);this.interactionService.isActive();this.currentSession?this.currentSession.onRouterStarted(t):this.transitionTo(this.createNavigationSession(this.urlService.getCurrentRouterUrl()))},n.prototype.onUrlChanged=function(t){this.currentSession?this.currentSession.onUrlChange(t):console.log("FYI: url changed without a navigation session in progress")},n.prototype.onRouterCancelled=function(t){this.currentSession.onRouterCancelled(t)},n.prototype.onRouterError=function(t){this.currentSession.onRouterError(t)},n.prototype.onRouterEnd=function(t){this.currentSession.onRouterEnd(t)},n.prototype.navigate=function(t,e){var n=this;return this.doNavigation(t,(function(o){return z(n,void 0,void 0,(function(){var n;return G(this,(function(o){switch(o.label){case 0:return n=X([t.placeDefinition.path],this.createRouteParameters(t)),[4,this.angularRouter.navigate(n,{relativeTo:e?e.relativeTo:null})];case 1:return o.sent(),[2]}}))}))}))},n.prototype.doNavigation=function(t,e){return z(this,void 0,void 0,(function(){var n;return G(this,(function(o){switch(o.label){case 0:this.navigationInProgress.value&&I.lang.illegalState("Navigation already in progress"),(n=this.createNavigationSession(this.urlService.getCurrentRouterUrl())).storeVisit(t),this.transitionTo(n),o.label=1;case 1:return o.trys.push([1,,3,4]),[4,e(this.angularRouter)];case 2:return o.sent(),[3,4];case 3:return!this.angularRouter.getCurrentNavigation()&&this.currentSession&&this.currentSession.onRouterEnd(new O.NavigationEnd(-1,"","")),[7];case 4:return[2]}}))}))},n.prototype.navigateByUrl=function(t,e){return this.angularRouter.navigateByUrl(t.urlTree,e)},Object.defineProperty(n.prototype,"activeVisits",{get:function(){return this._activeVisits.readonly},enumerable:!1,configurable:!0}),n.prototype.pushVisitChangesToRoute=function(t,e){return z(this,void 0,void 0,(function(){var n=this;return G(this,(function(o){return this.placeHistory.updateVisit(e),e.hasRoutingChangedFrom(t)?[2,this.doNavigation(e,(function(t){var o=n.urlService.parseUrl(n.angularRouter.routerState.snapshot.url).updateVisitSegments(e);return n.navigateByUrl(o)}))]:[2]}))}))},n.prototype.createNavigationSession=function(t){return this.interactionService.isActive()?new Ze(this.navigationContext,t):new cn(this.navigationContext,t)},n.prototype.transitionTo=function(t){var e=this.navigationSessionModel.value;e||this.placeHistory.notifyNavigationStarted(),I.assert.isTruthy(t!==e),I.Logger.get(this).info("### Router State Transition: "+(e?e.toString():"null")+" -> "+t.toString()),this.navigationSessionModel.value=t,e&&e.dispose(),t.notifyActive()},n.prototype.routingSessionFinished=function(t){t&&t.length>0&&(I.assert.isTruthy(this.navigationInProgress.value),this.placeHistory.notifyNavigationFinished(t),this._activeVisits.value=t);var e=this.currentSession;e.dispose(),this.navigationSessionModel.value=null,console.log("### Router Session Finished (was "+e.toString()+")"),this.sessionFinishedJobs.forEach((function(t){return t()})),this.sessionFinishedJobs=[]},n.prototype.runAfterRoutingSessionFinishes=function(t){I.assert.isTruthy(this.navigationInProgress),this.sessionFinishedJobs.push(t)},n.prototype.syncInteractionContextIdsWithRouter=function(){var t=this;if(this.navigationSession){this.navigationSession;return new Promise((function(e,n){t.runAfterRoutingSessionFinishes((function(){t.runAfterRoutingSessionFinishes(e);var n=new Je(t.navigationContext,t.urlService.getCurrentRouterUrl(),!1);t.transitionTo(n)}))}))}return new Promise((function(e,n){t.runAfterRoutingSessionFinishes(e);var o=new Je(t.navigationContext,t.urlService.getCurrentRouterUrl(),!1);t.transitionTo(o)}))},n.prototype.createRouteParameters=function(t){var e=t.placeDefinition;return t.hasRouteId()?[e.getFormattedRouteId(t),e.getFormattedRouteParameters(t)]:[e.getFormattedRouteParameters(t)]},n}(I.GarbageCollector);mn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new mn(n.ɵɵinject(O.Router),n.ɵɵinject(e.Location),n.ɵɵinject(t.InteractionService),n.ɵɵinject(fn),n.ɵɵinject(t.PlaceHistory))},token:mn,providedIn:"root"}),mn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],mn.ctorParameters=function(){return[{type:O.Router},{type:e.Location},{type:t.InteractionService},{type:fn},{type:t.PlaceHistory}]};var hn=L.style({position:"absolute",top:"0",left:"0",bottom:"0",right:"0"}),gn=[L.query(":enter, :leave",hn,{optional:!0}),L.group([L.query(":enter",[L.style({transform:"translateX(-100%)"}),L.animate("{{duration}} ease-out",L.style({transform:"translateX(0%)"}))],{optional:!0}),L.query(":leave",[L.style({transform:"translateX(0%)"}),L.animate("{{duration}} ease-out",L.style({transform:"translateX(100%)"}))],{optional:!0})])],yn=[L.query(":enter, :leave",hn,{optional:!0}),L.group([L.query(":enter",[L.style({transform:"translateX(100%)",minHeight:"1px"}),L.animate("{{duration}} ease-out",L.style({transform:"translateX(0%)"}))],{optional:!0}),L.query(":leave",[L.style({transform:"translateX(0%)"}),L.animate("{{duration}} ease-out",L.style({transform:"translateX(-100%)",minHeight:"1px"}))],{optional:!0})])];function vn(t){return L.trigger("routeAnimations",[L.transition(":increment",yn,{params:{duration:t}}),L.transition(":decrement",gn,{params:{duration:t}})])}var bn=vn("0.3s"),Cn=function(e){function o(o,i,r,a,c){var s=e.call(this)||this;s.router=o,s.placeRouter=i,s.placeAuthService=r,s.placeConfig=a,s.placeChanged=new n.EventEmitter,s.outletActivated=new I.MutableValueModel(!1),s._activatedRouteModel=new I.MutableValueModel,s._activePlaceModel=new I.MutableValueModel,s.initialPlaceIndex=null,s._isPushingVisitToRoute=new I.MutableValueModel(!1),s.isVeryFirstLoad=!0;var l=I.Dsl.disposeWith(s),u=l.chain,p=l.valueOf,d=(l.before,l.when);l.after,l.observe,l.switchOn;s.parentOutletModel=new I.MutableValueModel(c);var f=u(s.parentOutletModel).pullValueModel((function(t){return t.activePlaceModel})).pluck("placeDefinition").pluckList("children").pluck("component"),m=u(s.activePlaceModel).map((function(t){return t.constructor}));return s.placesInAnimationOrder=u(s.customPlaceAnimationOrderModel).otherwise(f),s.activePlaceAnimationPosition=s.placesInAnimationOrder.reduce((function(t){var e=0;return m.value&&(e=t.indexOf(m.value),P.isNil(s.initialPlaceIndex)&&(s.initialPlaceIndex=e)),P.isNil(s.initialPlaceIndex)?0:e-s.initialPlaceIndex}),{dependsOn:m}),s.animationSupported=s.placesInAnimationOrder.count().isGreaterThan(0),s.animationEnabled=p.all(s.animateModel,s.animationSupported).areTruthy(),s._activePlaceDefinition=u(s._activePlaceModel).pluck("placeDefinition"),s.routerVisitModel=s._activePlaceDefinition.findIn(u(i.activeVisitsByPlaceDefinition)),s.navigationInProgress=u(s.placeRouter.navigationInProgress),d(s.navigationInProgress).becomesFalsey((function(){s.checkStateAndInitialise()})),d(s.outletActivated).becomesTruthy((function(){s.checkStateAndInitialise()})),u(s._activePlaceModel).postponeWhile(s.navigationInProgress).subscribe((function(t){return s.placeChanged.emit(t)})),d(r.authoriserModel).changes((function(e){var n=s._activePlaceModel.value;if(n&&!e(n.placeDefinition)){var o=r.handleNotAuthorised(s._activatedRouteModel.value.snapshot,s.router.routerState.snapshot);s.placeRouter.navigate(o instanceof We?o:new We(t.PlaceComponent.getDefinition(o)))}})),s}return B(o,e),o.prototype.ngOnInit=function(){},o.prototype.getAnimationOrder=function(){return this.activePlaceAnimationPosition.value},Object.defineProperty(o.prototype,"animationDuration",{get:function(){return this.placeConfig&&this.placeConfig.animationDuration?this.placeConfig.animationDuration:"500ms"},enumerable:!1,configurable:!0}),o.prototype.navigate=function(t){this.placeRouter.navigate(t,{relativeTo:this.parentOutlet?this.parentOutlet.activatedRouteModel.value:null})},Object.defineProperty(o.prototype,"parentOutlet",{get:function(){return this.parentOutletModel.value},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"activePlaceModel",{get:function(){return this._activePlaceModel.readonly},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"activatedRouteModel",{get:function(){return this._activatedRouteModel.readonly},enumerable:!1,configurable:!0}),o.prototype.onOutletActivated=function(t,e){this._activatedRouteModel.value=t.activatedRoute,this._activePlaceModel.value=e,this.validateAnimationState(e),this.outletActivated.value=!0,this.checkStateAndInitialise()},o.prototype.validateAnimationState=function(t){this.animateModel.value&&(this.placesInAnimationOrder.length<1?console.error("PlaceOutlet.animate === true but placeAnimationOrder has not been set. Animation is disabled."):this.placesInAnimationOrder.query().includes(t.placeDefinition.component)||console.error("PlaceOutlet.animate === true but placeAnimationOrder doesn't contain "+t.placeDefinition.component.name+"."))},o.prototype.onOutletDeactivated=function(){this.outletActivated.value=!1,this._activePlaceModel.value=null,this._activatedRouteModel.value=null},o.prototype.checkStateAndInitialise=function(){var t=this.routerVisitModel.value,e=this.activePlaceModel.value;t&&e&&!e.isInitialised()&&(t.placeDefinition!==e.placeDefinition&&I.lang.illegalState("wrong visit!!!"),this.initialisePlace(t,e))},o.prototype.initialisePlace=function(t,e){var n=this,o=new I.MutableValueModel(t);I.DebugContext.tag(o,"PlaceOutletComponent["+e.constructor.name+")].visitModel"),e.initialiseVisit(t,(function(t,e){n.pushVisitChangeToRoute(e,t)}));var i=function(){n._activePlaceModel.value._notifyActive(!0)};!this.animationEnabled.value||this.isVeryFirstLoad?(this.isVeryFirstLoad=!1,i()):this.onAnimationFinishedJob=i;var r=I.Dsl.disposeWith(e),a=r.when,c=(r.chain,r.valueOf);a(this.routerVisitModel).changes((function(t){e.updateVisit(t)}),{unless:c.any(this._isPushingVisitToRoute,this.routerVisitModel.isNil()).areTruthy()})},o.prototype.pushVisitChangeToRoute=function(t,e){var n=this;this._isPushingVisitToRoute.value=!0,this.placeRouter.pushVisitChangesToRoute(t,e).finally((function(){n._isPushingVisitToRoute.value=!1}))},o.prototype.animationStarted=function(){},o.prototype.animationDone=function(){this.onAnimationFinishedJob&&(this.onAnimationFinishedJob(),this.onAnimationFinishedJob=void 0)},o}(Y);Cn.decorators=[{type:n.Component,args:[{selector:"aup-place-outlet",template:'<ng-container *ngIf="animationEnabled.value">\n <div class="router-outlet-container" cdkScrollable\n [@routeAnimations]="{value: getAnimationOrder(), params:{duration: animationDuration}}"\n (@routeAnimations.start)="animationStarted()"\n (@routeAnimations.done)="animationDone()"\n >\n <router-outlet #routerOutlet="outlet"\n (activate)="onOutletActivated(routerOutlet, $event)"\n (deactivate)="onOutletDeactivated()">\n </router-outlet>\n </div>\n</ng-container>\n\n<ng-container *ngIf="!animationEnabled.value">\n <div class="router-outlet-container" cdkScrollable>\n <router-outlet #routerOutlet="outlet"\n (activate)="onOutletActivated(routerOutlet, $event)"\n (deactivate)="onOutletDeactivated()">\n </router-outlet>\n </div>\n</ng-container>\n\n',animations:[bn],styles:[":host{display:flex;flex-direction:column;min-height:0}.router-outlet-container{display:block;flex:1;min-height:0;overflow-x:hidden;overflow-y:scroll;position:relative}router-outlet{display:none}"]}]}],Cn.ctorParameters=function(){return[{type:O.Router},{type:mn},{type:void 0,decorators:[{type:n.Inject,args:[Ue]}]},{type:void 0,decorators:[{type:n.Optional},{type:n.Inject,args:[ze]}]},{type:Cn,decorators:[{type:n.SkipSelf},{type:n.Optional}]}]},Cn.propDecorators={animate:[{type:n.Input}],animateModel:[{type:n.Input}],customPlaceAnimationOrderModel:[{type:n.Input,args:["placeAnimationOrderModel"]}],customPlaceAnimationOrder:[{type:n.Input,args:["placeAnimationOrder"]}],placeChanged:[{type:n.Output}],routerOut:[{type:n.ViewChild,args:["routeOutlet",{static:!0}]}]},q([I.StoreInValueModel("animateModel"),W("design:type",Boolean)],Cn.prototype,"animate",void 0),q([I.TrackExternal({defaultValue:!0}),W("design:type",I.ValueModel)],Cn.prototype,"animateModel",void 0),q([I.TrackExternal(),W("design:type",I.ListModel)],Cn.prototype,"customPlaceAnimationOrderModel",void 0),q([I.StoreInListModel("customPlaceAnimationOrderModel"),W("design:type",Array)],Cn.prototype,"customPlaceAnimationOrder",void 0),q([I.Trace(),W("design:type",Function),W("design:paramtypes",[O.RouterOutlet,t.PlaceComponent]),W("design:returntype",void 0)],Cn.prototype,"onOutletActivated",null),q([I.Trace(),W("design:type",Function),W("design:paramtypes",[]),W("design:returntype",void 0)],Cn.prototype,"onOutletDeactivated",null);var In=function(e){function n(n){var o=e.call(this)||this;o._activePlaceComponent=new I.DelegatingValueModel;var i=I.Dsl.disposeWith(o),r=i.chain,a=(i.valueOf,i.before,i.when);i.after,i.observe,i.switchOn;return o.placeDefinitions=r(o.placesModel).map((function(e){return t.PlaceComponent.getDefinition(e)})).select((function(t){return n.authoriserModel.value(t)}),{dependsOn:n.authoriserModel}),o.commandFactory=I.Command.createFactory((function(t){o.placeOutlet.navigate(new We(t))})),a(o.placeOutletModel).changes((function(t){setTimeout((function(){return o._activePlaceComponent.setDelegate(t?t.activePlaceModel:null)}))})),o.activePlaceDefinition=r(o._activePlaceComponent).pluck("placeDefinition"),o}return B(n,e),n.prototype.getNavigationFace=function(t){var e=t.getPlaceData("nav");return{text:function(){return e?e.title():t.searchPlaceData(["navTitle","title"])},tooltip:function(){return e&&e.tooltip?e.tooltip():t.getPlaceData("navTooltip",null)},icon:function(){return e&&e.icon?e.icon():t.getPlaceData("navIcon",null)}}},n.prototype.isActive=function(t){return this.activePlaceDefinition.query().equals(t)},n.prototype.ngOnInit=function(){},n}(Y);In.decorators=[{type:n.Component,args:[{template:""}]}],In.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[Ue]}]}]},In.propDecorators={places:[{type:n.Input}],placesModel:[{type:n.Input}],placeOutlet:[{type:n.Input}],placeOutletModel:[{type:n.Input}]},q([I.StoreInListModel("placesModel"),W("design:type",Array)],In.prototype,"places",void 0),q([I.TrackExternal(),W("design:type",I.ListModel)],In.prototype,"placesModel",void 0),q([I.StoreInValueModel("placeOutletModel"),W("design:type",Cn)],In.prototype,"placeOutlet",void 0),q([I.TrackExternal(),W("design:type",I.ValueModel)],In.prototype,"placeOutletModel",void 0),q([w.Memoize(),W("design:type",Function),W("design:paramtypes",[He]),W("design:returntype",Object)],In.prototype,"getNavigationFace",null);var wn=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();wn.decorators=[{type:n.Component,args:[{selector:"aup-busy-overlay",template:'<ng-content></ng-content>\n<div class="busy-overlay-backdrop" *ngIf="busyModel.value">\n <mat-progress-spinner mode="indeterminate" [diameter]="52"></mat-progress-spinner>\n</div>\n',styles:[":host{position:relative}div.busy-overlay-backdrop{-ms-grid-columns:auto;-ms-grid-rows:auto;background-color:rgba(0,0,0,.2);bottom:0;display:-ms-grid;display:grid;grid-template-columns:auto;grid-template-rows:auto;left:0;place-content:center;position:absolute;right:0;top:0}"]}]}],wn.ctorParameters=function(){return[]},wn.propDecorators={busyModel:[{type:n.Input}],busy:[{type:n.Input}]},q([I.TrackExternal(),W("design:type",I.ValueModel)],wn.prototype,"busyModel",void 0),q([I.StoreInValueModel("busyModel"),W("design:type",Boolean)],wn.prototype,"busy",void 0);var Pn=function(){function t(){}return t.prototype.ngOnInit=function(){},t}();Pn.decorators=[{type:n.Component,args:[{selector:"aup-empty-state",template:'\n <div class="container">\n <ng-content></ng-content>\n </div>\n ',styles:[":host{align-items:center;display:flex;flex-direction:column;justify-content:center}.container{border:2px dashed rgba(0,0,0,.2);border-radius:5px;font-size:14px;font-weight:300;padding:var(--aup-default-padding)}"]}]}],Pn.ctorParameters=function(){return[]};var Mn=function(t){function e(e){return t.call(this,e)||this}return B(e,t),e}(In);Mn.decorators=[{type:n.Component,args:[{selector:"aup-list-place-nav",template:'<mat-nav-list fxFlex>\n <a mat-list-item *ngFor="let placeDefinition of placeDefinitions.value"\n [pectinCommand]="commandFactory.create(placeDefinition)"\n [class.active]="isActive(placeDefinition)"\n [matTooltip]="getNavigationFace(placeDefinition).tooltip()">\n <aup-command-face [faces]="[getNavigationFace(placeDefinition)]"></aup-command-face>\n </a>\n</mat-nav-list>\n',styles:[":host{--selected-background:#f1f1f1;--selected-border-color:#838383;--selected-color:inherit;display:flex;flex-direction:column}mat-nav-list{padding-top:0}a{border-right:2px solid transparent}a.active{background:var(--selected-background);border-right:2px solid var(--selected-border-color);color:var(--selected-color)}"]}]}],Mn.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[Ue]}]}]};var xn=function(t){function e(e,n){var o=t.call(this,n)||this;return o.router=e,o.expanded=!1,o}return B(e,t),e.prototype.expandMenu=function(){this.expanded=!0},e.prototype.collapseMenu=function(){this.expanded=!1},e.prototype.toggleMenu=function(){this.expanded=!this.expanded},e}(In);xn.decorators=[{type:n.Component,args:[{selector:"aup-side-place-navigation",template:'<mat-nav-list>\n <a mat-list-item (click)="toggleMenu()" class="home">\n <aup-icon class="collapsed-only" icon="mat:menu"></aup-icon>\n <aup-icon class="expanded-only" icon="mat:arrow_back"></aup-icon>\n <span class="expanded-only">Menu</span>\n </a>\n <a mat-list-item *ngFor="let placeDefinition of placeDefinitions.value"\n [pectinCommand]="commandFactory.create(placeDefinition)"\n [class.active]="isActive(placeDefinition)"\n [matTooltip]="getNavigationFace(placeDefinition).tooltip()">\n <aup-icon *ngIf="getNavigationFace(placeDefinition).icon()" [icon]="getNavigationFace(placeDefinition).icon()"></aup-icon>\n <span class="expanded-only">{{getNavigationFace(placeDefinition).text()}}</span>\n </a>\n <span [style.flex]="1"></span>\n <ng-container *ngIf="navEndTemplate" [ngTemplateOutlet]="navEndTemplate"></ng-container>\n</mat-nav-list>\n',styles:[":host{--resolved-background-color:var(--nav-background-color,#555);--resolved-color:var(--nav-color,hsla(0,0%,100%,0.9));--resolved-expanded-width:var(--nav-expanded-width,235px);--resolved-nav-item-height:var(--nav-item-height,var(--resolved-nav-item-width));--resolved-nav-item-width:var(--nav-width,56px);background-color:var(--resolved-background-color);color:var(--resolved-color);display:flex;flex-direction:column;transition:width 125ms linear;width:var(--resolved-nav-item-width)}:host.expanded{max-width:var(--resolved-expanded-width);width:var(--resolved-expanded-width)}:host-context(.expanded) .expanded-only{max-width:100%}:host-context(.expanded) .collapsed-only{max-width:0}:host-context(.expanded) .mat-list-item aup-icon:not(.collapsed-only){margin-right:12px}:host-context(.expanded) .mat-list-item span{text-wrap:none;white-space:nowrap}.expanded-only{max-width:0;overflow:hidden}.collapsed-only{max-width:100%;overflow:hidden}mat-nav-list{display:flex;flex:1;flex-direction:column}.mat-list-item{color:inherit;height:var(--resolved-nav-item-height);width:var(--resolved-nav-item-width)}.mat-list-item.active{background-color:#444}.mat-list-item.home{text-align:left}mat-icon{color:inherit}mat-icon.flip-horizontal{transform:scaleX(-1)}"]}]}],xn.ctorParameters=function(){return[{type:O.Router},{type:void 0,decorators:[{type:n.Inject,args:[Ue]}]}]},xn.propDecorators={expanded:[{type:n.HostBinding,args:["class.expanded"]}],navEndTemplate:[{type:n.ContentChild,args:["navEndTemplate"]}]};var Rn=function(t){function e(e){return t.call(this,e)||this}return B(e,t),e}(In);Rn.decorators=[{type:n.Component,args:[{selector:"aup-tabbed-place-navigation",template:'<nav mat-tab-nav-bar>\n <a mat-tab-link *ngFor="let placeDefinition of placeDefinitions.value"\n [pectinCommand]="commandFactory.create(placeDefinition)"\n [active]="isActive(placeDefinition)"\n [matTooltip]="getNavigationFace(placeDefinition).tooltip()">\n <aup-command-face [faces]="[getNavigationFace(placeDefinition)]"></aup-command-face>\n </a>\n</nav>\n',styles:[""]}]}],Rn.ctorParameters=function(){return[{type:void 0,decorators:[{type:n.Inject,args:[Ue]}]}]};var Sn=function(){};Sn.decorators=[{type:n.NgModule,args:[{imports:[e.CommonModule,s.BrowserAnimationsModule,F.MatProgressSpinnerModule,O.RouterModule,c.MatTabsModule,E.MatListModule,v.MatTooltipModule,h.MatIconModule,tt,S.FlexModule,me],declarations:[Pn,wn,Cn,Rn,Mn,xn,In],entryComponents:[wn],exports:[wn,Cn,Pn,Rn,Mn,xn,In],providers:[]}]}];var An=function(){};An.decorators=[{type:n.NgModule,args:[{declarations:[],imports:[e.CommonModule,s.BrowserAnimationsModule,o.FormsModule,r.MatInputModule,i.MatFormFieldModule,a.MatSelectModule,c.MatTabsModule,tt,me,Sn,Ne],exports:[Ne,Sn,tt,me,Rt]}]}];var On=L.style({opacity:0,height:"0",paddingTop:"0",paddingBottom:"0"}),Dn=L.trigger("slideDownOnEnter",[L.transition(":enter",[On,L.animate("{{duration}}")],{params:{duration:"100ms"}}),L.transition(":leave",[L.animate("{{duration}}",On)],{params:{duration:"100ms"}})]),Tn=L.style({opacity:0,width:"0",paddingLeft:"0",paddingRight:"0"}),En=L.trigger("slideRightOnEnter",[L.transition(":enter",[Tn,L.animate("{{duration}}")],{params:{duration:"100ms"}}),L.transition(":leave",[L.animate("{{duration}}",Tn)],{params:{duration:"100ms"}})]),Fn=function(t){function e(e,n,o,i){var r=t.call(this)||this;return r.identifier=e,r.api=n,r.dialogService=o,r.config=i,r.garbage=new I.GarbageCollector,x.assert.notNil(o),r}return B(e,t),e.prototype.cancelActiveActivity=function(){return this.activityContainer.cancelActiveActivity()},e.prototype.dispose=function(){this.isActive()&&I.lang.illegalState("Dispose called while active."),this.garbage.dispose()},e.prototype.registerDisposable=function(t){return this.garbage.registerDisposable(t)},e.prototype.isActive=function(){return!!this.activityContainer&&this.activityContainer.isActive()},e.prototype.createAndLaunchActivity=function(t,e,n){var o=this;x.assert.isNil(this._currentActivityRef);var i=Object.assign(Object.assign({},this.config),{disableClose:n,panelClass:"dialog-interaction-context"}),r=this.dialogService.open(Me,i),a=this.activityContainer=r.componentInstance;this.activityContainer.initialise(this.identifier,this.api);var c=this.activityContainer.startActivity(t,e);return c.finally((function(){return r.close()})),r.afterClosed().subscribe((function(t){a.isActive()&&a.cancelActiveActivity(),o.activityContainer=null})),r.updateSize(),r.afterOpened().subscribe((function(t){r.updateSize()})),c},e}(Ie),kn=new n.InjectionToken("DIALOG_INTERACTION_SERVICE_DEFAULTS"),_n=function(t){function e(e,n,o){var i=t.call(this)||this;return i.dialogService=e,i.dialogServiceDefaults=n,i.matDialogDefaultConfig=o,x.assert.notNil(e),i}return B(e,t),e.prototype.createInteractionContext=function(t,e,n){var o=Object.assign(Object.assign({autoFocus:!1,hasBackdrop:!0,closeOnNavigation:!1},this.matDialogDefaultConfig),this.dialogServiceDefaults);return new Fn(t,e,this.dialogService,o)},e}(Re);_n.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new _n(n.ɵɵinject(A.MatDialog),n.ɵɵinject(kn,8),n.ɵɵinject(A.MAT_DIALOG_DEFAULT_OPTIONS,8))},token:_n,providedIn:"root"}),_n.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],_n.ctorParameters=function(){return[{type:A.MatDialog},{type:A.MatDialogConfig,decorators:[{type:n.Optional},{type:n.Inject,args:[kn]}]},{type:A.MatDialogConfig,decorators:[{type:n.Optional},{type:n.Inject,args:[A.MAT_DIALOG_DEFAULT_OPTIONS]}]}]};var Ln=function(){function t(t,e){this.paramMaps=[t].concat((e||[]).map((function(t){return new Vn(t.parameters)}))).filter((function(t){return!!t}))}return t.prototype.get=function(t){return this.paramMaps.find((function(e){return e.has(t)})).get(t)},t.prototype.getAll=function(t){return this.paramMaps.find((function(e){return e.has(t)})).getAll(t)},t.prototype.has=function(t){return!!this.paramMaps.find((function(e){return e.has(t)}))},Object.defineProperty(t.prototype,"keys",{get:function(){return this.paramMaps.reduce((function(t,e){return t.concat(e.keys)}),[])},enumerable:!1,configurable:!0}),t}();q([w.Memoize(),W("design:type",Array),W("design:paramtypes",[])],Ln.prototype,"keys",null);var Vn=function(){function t(t){this.params=t}return t.prototype.get=function(t){return this.params[t]},t.prototype.getAll=function(t){var e=this.get(t);return Array.isArray(e)?e:[e]},t.prototype.has=function(t){return this.keys.includes(t)},Object.defineProperty(t.prototype,"keys",{get:function(){return Object.keys(this.params)},enumerable:!1,configurable:!0}),t}(),jn=function(){function t(){}return t.prototype.canActivate=function(t,e){return z(this,void 0,void 0,(function(){return G(this,(function(t){return[2,!0]}))}))},t}();jn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new jn},token:jn,providedIn:"root"}),jn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],jn.ctorParameters=function(){return[]};var Nn,Un,Hn,Bn,qn=function(){function t(t,e,n,o,i){this.navigationSession=t,this.activatedRoute=e,this.router=n,this.placeHistory=o,this.injector=i}return t.prototype.sanitise=function(t){return z(this,void 0,void 0,(function(){var e,n,o,i,r,a,c,s,l;return G(this,(function(u){switch(u.label){case 0:return(e=t.placeDefinition).hasRouteId()?(n=e.getRouteIdParameterDef(),o=t.getRouteId(),[4,n.sanitise(o,t,this.placeHistory,this.injector,this.navigationSession.isPopState)]):[3,2];case 1:if(l=u.sent(),console.log({routeId:o,sanitisedValue:l}),n.hasChanged(o,l))return[2,t.replace(n,l)];u.label=2;case 2:i=e.getVisitParameterDefs({includeRouteParameters:!0,includeNonRouteParameters:!0}),r=t,a=0,u.label=3;case 3:return a<i.length?(c=i[a],s=t.getParameter(c.name),[4,c.sanitise(s,r,this.placeHistory,this.injector,this.navigationSession.isPopState)]):[3,6];case 4:l=u.sent(),c.hasChanged(s,l)&&(r=r.replace(c,l)),u.label=5;case 5:return a++,[3,3];case 6:return[2,r.hasChangedFrom(t)?r:t]}}))}))},t}(),Wn=function(){function e(t,e,n,o,i,r,a){this.router=t,this.urlService=e,this.placeRouter=n,this.placeHistory=o,this.placeAuthService=i,this.interactionService=r,this.injector=a}return e.prototype.canActivate=function(e,n){return z(this,void 0,void 0,(function(){var o,i,r,a,c=this;return G(this,(function(s){switch(s.label){case 0:return t.PlaceComponent.isPlaceComponentConstructor(e.component)?(o=t.PlaceComponent.getDefinition(e.component)).authenticate?[4,this.placeAuthService.isAuthenticated()]:[3,2]:[3,4];case 1:if(!s.sent())return i=this.placeAuthService.handleNotAuthenticated(e,n),(r=this.getPlaceDefinition(i)).authenticate&&I.lang.illegalState("handleNotAuthenticated hook returned place "+r.component.name+" that requires authentication."),[2,this.createUrlTree(i)];if(!this.placeAuthService.isAuthorised(o))return i=this.placeAuthService.handleNotAuthorised(e,n),r=this.getPlaceDefinition(i),this.placeAuthService.isAuthorised(r)||I.lang.illegalState("handleNotAuthorised hook returned place "+r.component.name+" that is not authorised for the current user."),[2,this.createUrlTree(i)];s.label=2;case 2:return[4,this.cleanInteractionState(e,n,(function(){return z(c,void 0,void 0,(function(){var t,i,r,a,c;return G(this,(function(s){switch(s.label){case 0:return t=new Ln(e.paramMap,e.url),i=o.parseRouteParams(t),r=this.placeRouter.navigationSession,a=r.getVisitFor(o)||new We(o,i),[4,new qn(r,e,this.router,this.placeHistory,this.injector).sanitise(a.mergeRouteParameters(i))];case 1:return c=s.sent(),r.storeVisit(c),a.hasRoutingChangedFrom(c)?[2,this.urlService.parseUrl(n.url).updateVisitSegments(c)]:[2,!0]}}))}))}))];case 3:return[2,(a=s.sent())instanceof t.UrlSnapshot?a.urlTree:a];case 4:return[2,I.lang.illegalState("expected component to be an instance of PlaceComponent, got "+e.component)]}}))}))},e.prototype.canDeactivate=function(e,n,o,i){return z(this,void 0,void 0,(function(){var n,r,a;return G(this,(function(c){switch(c.label){case 0:return n=this.urlService.parseUrl(o.url),r=this.urlService.parseUrl(i.url),[4,this.placeRouter.navigationSession.canDeactivatePlace(e,n,r)];case 1:return[2,(a=c.sent())instanceof t.UrlSnapshot?a.urlTree:a]}}))}))},e.prototype.getPlaceDefinition=function(e){return e instanceof We?e.placeDefinition:t.PlaceComponent.getDefinition(e)},e.prototype.createUrlTree=function(e){var n=e instanceof We?e:new We(t.PlaceComponent.getDefinition(e),{});return this.urlService.createUrlSnapshot(n).urlTree},e.prototype.cleanInteractionState=function(t,e,n){return z(this,void 0,void 0,(function(){var t;return G(this,(function(o){return t=this.urlService.parseUrl(e.url),!this.interactionService.isActive()&&t.hasInteractions()?[2,t.removeInteractionIds()]:[2,n()]}))}))},e}();function zn(t,e,n,o,i){var r={backingModel:n,binding:null},a=o+"("+t.constructor.name+"."+e.toString()+")";I.DebugContext.getOrCreate(r.backingModel).tag(a),Object.defineProperty(t,e,{get:function(){return r.backingModel},set:function(t){r.binding&&r.binding.dispose(),t&&(r.binding=new I.Binding(r.backingModel,t,{toLeft:I.Functions.identity,toRight:I.Functions.identity}),i(t)?r.binding.writeRight():(i(r.backingModel)||console.warn("Assigning a visit model with an existing value to a visit parameter with an existing value. Visit parameter will be overridden"),r.binding.writeLeft()))}})}Wn.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new Wn(n.ɵɵinject(O.Router),n.ɵɵinject(fn),n.ɵɵinject(mn),n.ɵɵinject(t.PlaceHistory),n.ɵɵinject(Ue),n.ɵɵinject(t.InteractionService),n.ɵɵinject(n.INJECTOR))},token:Wn,providedIn:"root"}),Wn.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],Wn.ctorParameters=function(){return[{type:O.Router},{type:fn},{type:mn},{type:t.PlaceHistory},{type:void 0,decorators:[{type:n.Inject,args:[Ue]}]},{type:t.InteractionService},{type:n.Injector}]},Nn=t.Formatter||(t.Formatter={}),Un=function(){function t(){}return t.prototype.format=function(t){return t},t.prototype.parse=function(t){return t},t}(),Hn=function(){function t(){}return t.prototype.format=function(t){return j.default.isNumber(t)&&!j.default.isNaN(t)?""+t:null},t.prototype.parse=function(t){var e=Number.parseFloat(t);return j.default.isNaN(e)?null:e},t}(),Bn=function(){function t(){}return t.prototype.format=function(t){return t?"true":"false"},t.prototype.parse=function(t){return"true"===t},t}(),Nn.STRING=new Un,Nn.NUMBER=new Hn,Nn.BOOLEAN=new Bn,t.ACTIVITY_DATA=he,t.AUP_PLACE_CONFIG=ze,t.AbstractInputActivity=Ee,t.AbstractInputComponent=ht,t.AbstractInteractionContext=Ie,t.AbstractListInputComponent=gt,t.AbstractPlaceNavigationComponent=In,t.AbstractPopStateNavigation=Qe,t.AbstractPopupMenuComponent=ct,t.AbstractValueInputComponent=yt,t.Activity=ge,t.ActivityActionsComponent=ye,t.ActivityContainerComponent=Me,t.ActivityOutletComponent=Pe,t.ActivityRef=we,t.AddItemInteractionContextComponent=Oe,t.AlertDialogComponent=ve,t.AngularUiPowerupsModule=An,t.AutocompleteInputComponent=vt,t.BusyOverlayComponent=wn,t.CELL_EDITOR_PORTAL=_t,t.CELL_RENDERER_PORTAL=kt,t.CardContainerComponent=et,t.CellEditorPortalRef=Bt,t.CellHeaderPortalRef=Nt,t.CellPortalRef=jt,t.CellRendererPortalRef=Ut,t.CheckboxInputComponent=bt,t.ColumnModel=Jt,t.ColumnTemplateDirective=se,t.CommandComponent=it,t.CommandDirective=$,t.CommandFaceComponent=lt,t.ComponentCellRendererPortalRef=Ht,t.ComponentsModule=me,t.ConfirmThenDialogComponent=be,t.ConfirmationDialogComponent=Ce,t.ConsolidatedParameterMap=Ln,t.CustomTemplateColumnModel=oe,t.CustomValueColumnModel=ee,t.DEFINITION_META_DATA_KEY=Be,t.DIALOG_INTERACTION_SERVICE_DEFAULTS=kn,t.DefaultCellRendererComponent=Wt,t.DefaultHeaderCellRendererComponent=zt,t.DialogInteractionContext=Fn,t.DialogInteractionContextFactory=_n,t.Dimension=Le,t.DirectivesModule=tt,t.DisposableComponent=Y,t.EditRowControls=Gt,t.EditSession=re,t.EditorControlColumnModel=ne,t.EmptyStateComponent=Pn,t.EventCleanUpSession=Xe,t.FlexComponent=ut,t.FocusBinding=J,t.FocusBindingDirective=Q,t.FocusBindingFactory=Z,t.FocusContainerComponent=ft,t.FocusableComponent=mt,t.HEADER_CELL_RENDERER_PORTAL=Ft,t.InPlaceInteractionContextComponent=Ae,t.InteractionContextTriggerFor=Te,t.InteractionModule=Ne,t.InteractionServiceRoutingAdapter=xe,t.LEFT_RIGHT_PLACE_ANIMATION=bn,t.ListPlaceNavComponent=Mn,t.ListPropertyColumnModel=te,t.ModalInteractionContextFactory=Re,t.MoreMenuComponent=pt,t.MultipleSelectInputComponent=Ct,t.Navigating=cn,t.NavigatingDuringInteraction=Ze,t.NavigationSession=Ke,t.NoopAuthGuard=jn,t.NoopComponent=Rt,t.NumberInputComponent=It,t.PLACE_AUTH_SERVICE=Ue,t.POPUP_CONTAINER=ot,t.PORTAL_EDITOR_COMPONENT=Vt,t.PORTAL_RENDERER_COMPONENT=Lt,t.PasswordInputComponent=wt,t.Place=function(e){return function(n){t.PlaceComponent.isPlaceComponentConstructor(n)?t.PlaceComponent.injectDefinition(n,new He(n,e.path,!!P.isNil(e.authenticate)||e.authenticate,P.isNil(e.roles)?[]:e.roles,e.data,t.PlaceComponent.getRouteParameters(n),(e.children||[]).map((function(e){return t.PlaceComponent.getDefinition(e)})))):I.lang.illegalState(n+" must extend PlaceComponent to use the @Place decorator")}},t.PlaceComponentDeactivationHandler=Ge,t.PlaceDefinition=He,t.PlaceGuard=Wn,t.PlaceModule=Sn,t.PlaceOutletComponent=Cn,t.PlaceRouter=mn,t.Point=Ve,t.PopStateDuringInteractionNavigation=tn,t.PopStateNavigation=dn,t.PopupAwareComponent=nt,t.PopupInteractionContextComponent=De,t.PopupMenuComponent=dt,t.PopupMenuRendererComponent=st,t.PropertyColumnModel=Qt,t.ROUTE_PARAMETER_LIST_KEY=qe,t.RemoveLastInteractionFromUrlNavigationSession=Ye,t.ResizeAwareComponent=je,t.RouteId=function(e,n){return function(o,i){var r=new t.ParameterDefinition.RouteId(i.toString(),n,e);x.Klass.get(o).addToOwnMetadataList(qe,r),zn(o,i,new I.MutableValueModel,"@RouteId",(function(t){return t.query().isNil()}))}},t.ScrollContainerComponent=St,t.SectionHeaderComponent=At,t.SelectCellRendererComponent=Kt,t.SelectHeaderCellRendererComponent=Xt,t.SelectInputActivity=ke,t.SelectInputComponent=Pt,t.SelectionColumnModel=ie,t.SeparatorComponent=at,t.SidePlaceNavigationComponent=xn,t.StringInputActivity=Fe,t.StringInputComponent=Mt,t.SwitchCaseComponent=Et,t.SwitchCaseDefaultDirective=Tt,t.SwitchCaseOption=Ot,t.SwitchCaseWhenDirective=Dt,t.SynchroniseInteractionContextIdsWithRoute=Je,t.TabbedPlaceNavigationComponent=Rn,t.TableCellRendererComponent=le,t.TableComponent=ce,t.TableHeaderCellRendererComponent=ue,t.TableRowMenuComponent=de,t.TemplateCellRendererPortalRef=qt,t.TextInputComponent=xt,t.ToolBarComponent=rt,t.UrlService=fn,t.VerticalFocusContainerComponent=fe,t.Visit=We,t.VisitParameter=function(e){var n=x.Opts.get(e);return function(o,i){var r=new t.ParameterDefinition.ValueParameter(i.toString(),e,n.getOptional("storeInUrl",null));x.Klass.get(o).addToOwnMetadataList(qe,r),zn(o,i,new I.MutableValueModel,"@VisitParameter",(function(t){return t.query().isNil()}))}},t.VisitParameterList=function(e){var n=x.Opts.get(e);return function(o,i){var r=new t.ParameterDefinition.ArrayParameter(i.toString(),e,n.getOptional("storeInUrl",null));x.Klass.get(o).addToOwnMetadataList(qe,r),zn(o,i,new I.MutableListModel,"@VisitParameterList",(function(t){return t.query().isEmpty()}))}},t.VisitSanitiser=qn,t.WaitUntilLeavingInteractionTransitionCancelled=$e,t.WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined=en,t.WaitUntilPopStateDuringCanDeactivateInteractionFinishes=pn,t.leftRightPlaceAnimation=vn,t.slideDownOnEnterAnimation=Dn,t.slideRightOnEnterAnimation=En,t.ɵ0=$t,Object.defineProperty(t,"__esModule",{value:!0})}));
|
|
2
2
|
//# sourceMappingURL=coolon-angular-ui-powerups.umd.min.js.map
|