UNPKG

@w11k/ngx-present

Version:

Angular based Presentation Tool

15 lines (13 loc) 52.8 kB
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/common"),require("@angular/core"),require("@angular/material/button"),require("@angular/material/card"),require("@angular/material/dialog"),require("@angular/material/icon"),require("@angular/material/list"),require("@angular/material/sidenav"),require("@angular/material/slide-toggle"),require("@angular/material/toolbar"),require("@angular/router"),require("@w11k/tydux-angular"),require("@angular/platform-browser"),require("@w11k/tydux"),require("rxjs"),require("@w11k/ngx-componentdestroyed"),require("@w11k/rx-ninja"),require("rxjs/operators")):"function"==typeof define&&define.amd?define("@w11k/ngx-present",["exports","@angular/common","@angular/core","@angular/material/button","@angular/material/card","@angular/material/dialog","@angular/material/icon","@angular/material/list","@angular/material/sidenav","@angular/material/slide-toggle","@angular/material/toolbar","@angular/router","@w11k/tydux-angular","@angular/platform-browser","@w11k/tydux","rxjs","@w11k/ngx-componentdestroyed","@w11k/rx-ninja","rxjs/operators"],t):t(((e=e||self).w11k=e.w11k||{},e.w11k["ngx-present"]={}),e.ng.common,e.ng.core,e.ng.material.button,e.ng.material.card,e.ng.material.dialog,e.ng.material.icon,e.ng.material.list,e.ng.material.sidenav,e.ng.material.slideToggle,e.ng.material.toolbar,e.ng.router,e.tyduxAngular,e.ng.platformBrowser,e.tydux,e.rxjs,e.ngxComponentdestroyed,e.rxNinja,e.rxjs.operators)}(this,(function(e,t,n,r,o,i,a,s,c,u,l,d,p,f,v,h,m,g,y){"use strict"; /*! ***************************************************************************** Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABLITY OR NON-INFRINGEMENT. See the Apache Version 2.0 License for specific language governing permissions and limitations under the License. ***************************************************************************** */var b=function(e,t){return(b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function x(e,t){function n(){this.constructor=e}b(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var w=function(){return(w=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function k(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function C(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function S(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(C(arguments[t]));return e}function P(e){if(0===e.length)return 0;return function e(t,n){return t.reduce((function(t,r){return Array.isArray(r)?T(e(r,n+1),t):t}),n+1)}(e,0)}function I(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=S([e,t],n);return o.reduce((function(e,t){return e>t?t:e}))}function T(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=S([e,t],n);return o.reduce((function(e,t){return e>t?e:t}))}function j(e,t){var n,r;void 0===t&&(t=[]);try{for(var o=k(e),i=o.next();!i.done;i=o.next()){var a=i.value;Array.isArray(a)?j(a,t):t.push(a)}}catch(e){n={error:e}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return t}function O(e,t){return e.map((function(e){return Array.isArray(e)?O(e,t):t(e)}))}function D(e,t){var n=[];return e.forEach((function(e){if(Array.isArray(e)){var r=D(e,t);r.length>0&&n.push(r)}else t(e)&&n.push(e)})),n}function A(e){for(var t,n,r,o,i=[],a=1;a<arguments.length;a++)i[a-1]=arguments[a];var s={},c=S([e],i);try{for(var u=k(c),l=u.next();!l.done;l=u.next()){var d=l.value;if(void 0!==d){var p=Object.keys(d);try{for(var f=(r=void 0,k(p)),v=f.next();!v.done;v=f.next()){var h=v.value,m=d[h],g=s[h],y="object"==typeof g&&!1===Array.isArray(g),b="object"==typeof m&&!1===Array.isArray(m);if(y&&b){var x=A(g,m);s[h]=x}else d.hasOwnProperty(h)&&(s[h]=m)}}catch(e){r={error:e}}finally{try{v&&!v.done&&(o=f.return)&&o.call(f)}finally{if(r)throw r.error}}}}}catch(e){t={error:e}}finally{try{l&&!l.done&&(n=u.return)&&n.call(u)}finally{if(t)throw t.error}}return s}function M(e){var t=j(e);return new h.Observable((function(e){var n=5,r=function(){e.next(t.slice(0,n)),(n+=5)>t.length?(cancelAnimationFrame(o),e.complete()):o=requestAnimationFrame(r)},o=requestAnimationFrame(r)}))}function N(e,t){return void 0===t||t<0?e:function e(t,n){if(0===n)return[];return t.map((function(t){return Array.isArray(t)?e(t,n-1):t})).filter((function(e){return!1===(Array.isArray(e)&&0===e.length)}))}(e,t)}var L=function(e,t,n){this.component=e,this.coordinates=t,this.index=n};var R={sidebar:{tableOfContent:{enabled:!0,showCoordinates:void 0,separator:void 0,depth:void 0}},tableOfContent:{showCoordinates:!1,separator:")",depth:void 0},coordinates:{separator:"."},title:{separator:" / "},navigation:{overview:{component:void 0}},presenter:{preview1:{move:1,coordinatesToKeep:void 0},preview2:{move:2,coordinatesToKeep:void 0}},code:{theme:"dark"}},B=function(){this.config=R,this.slides=[],this.sideBar={open:!1,expert:!1,settings:!1};var e=Math.random().toString(36).substr(2,9).match(/.{1,3}/g);if(!e)throw new Error("ID generation failed. Couldn't generate chunks from random string");this.id=e.join("-")};var E=function(e){function t(){return e.call(this)||this}return x(t,e),t.prototype.setSlides=function(e){this.state.slides=e},t.prototype.mergeConfig=function(e){this.state.config=A(this.state.config,e)},t.prototype.toggleSideBar=function(){this.state.sideBar=w(w({},this.state.sideBar),{open:!this.state.sideBar.open})},t.prototype.closeSideBar=function(){this.state.sideBar=w(w({},this.state.sideBar),{open:!1})},t.prototype.openSideBar=function(){this.state.sideBar=w(w({},this.state.sideBar),{open:!0})},t.prototype.enableSideBarExpertMode=function(){this.state.sideBar=w(w({},this.state.sideBar),{expert:!0,settings:!0})},t.prototype.setId=function(e){this.state.id=e},t.prototype.setCodeTheme=function(e){this.state.config=w(w({},this.state.config),{code:w(w({},this.state.config.code),{theme:e})})},t}(v.Commands);function $(e,t,n){return Array.isArray(e)?e.map((function(e,r){var o=t.slice();return o.push(r+1),$(e,o,n)})):(n.index++,function(e,t,n){return new L(e,t,n)}(e,t,n.index))}var z=new n.InjectionToken("NgxPresentConfig"),F=new n.InjectionToken("SLIDES"),K=function(e){function t(t){var n=e.call(this,"Presentation",new B,new E)||this;n.dispatch=n.commands;var r=t.get(F),o=t.get(z),i=function(e){var t={index:-1};return e.map((function(e,n){return $(e,[n+1],t)}))}(r);return n.commands.setSlides(i),n.commands.mergeConfig(o),n}return x(t,e),t.prototype.toggleSideBar=function(e){e.altKey&&this.commands.enableSideBarExpertMode(),this.commands.toggleSideBar()},t.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.ctorParameters=function(){return[{type:n.Injector}]},t.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t(n.ɵɵinject(n.INJECTOR))},token:t,providedIn:"root"}),t}(v.Facade);var q=function(){function e(e,t){this.title=e,this.presentation=t,this.original=e.getTitle()}return e.prototype.setTitle=function(e){var t,n=this,r=this.title.getTitle();return this.title.setTitle(e),this.lastReturnedUnset=t=function(){n.lastReturnedUnset===t&&n.title.setTitle(r)},this.lastReturnedUnset},e.prototype.prefixTitle=function(e,t){return void 0===t&&(t=this.presentation.state.config.title.separator),this.setTitle(e+t+this.original)},e.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],e.ctorParameters=function(){return[{type:f.Title},{type:K}]},e.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new e(n.ɵɵinject(f.Title),n.ɵɵinject(K))},token:e,providedIn:"root"}),e}();var _=function(){function e(e,t){this.title=e,this.element=t}return e.prototype.ngAfterViewInit=function(){var e=this.element.nativeElement.innerText;this.unsetTitle=this.title.prefixTitle(e),this.element.nativeElement.hidden=!0},e.prototype.ngOnDestroy=function(){this.unsetTitle&&this.unsetTitle()},e.decorators=[{type:n.Directive,args:[{selector:"[ngxPresentPageTitle]"}]}],e.ctorParameters=function(){return[{type:q},{type:n.ElementRef}]},e}();function V(e){return H(e)&&Z(e)}function Z(e){var t=e.srcElement;if(t instanceof HTMLElement){var n=t.tagName;if("INPUT"===n||"TEXTAREA"===n||t.isContentEditable)return!1}return!0}function H(e){return!(e.altKey||e.ctrlKey||e.shiftKey||e.metaKey)}var G=function(){};var U=function(){function e(e){this.service=e}return e.prototype.init=function(e){var t=this;e.pipe(y.filter(Z),y.filter((function(e){return!(e.ctrlKey||e.metaKey||e.shiftKey)})),y.filter((function(e){return 77===e.keyCode}))).subscribe((function(e){e.preventDefault(),t.service.toggleSideBar(e)}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:K}]},e}();var W=new n.InjectionToken("KEYBOARD_EVENT_PROCESSORS"),J=function(){function e(e){var t,n;this.keyboardEvents$=new h.Subject;var r=e.get(W);try{for(var o=k(r),i=o.next();!i.done;i=o.next()){i.value.init(this.keyboardEvents$)}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}}return e.prototype.processKeyboardEvent=function(e){this.keyboardEvents$.next(e)},e.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],e.ctorParameters=function(){return[{type:n.Injector}]},e.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new e(n.ɵɵinject(n.INJECTOR))},token:e,providedIn:"root"}),e}();var Y=Symbol("TableOfContentEntry");function X(e){return Reflect.getMetadata(Y,e.component)}function Q(e){return e.filter((function(e){return void 0!==X(e)}))}function ee(e,t,n,r,o){if(0===n)return t;if(void 0===r)return e[t.index+n];var i=t.coordinates,a=te(i,r),s=i.slice(0,a);if(n>0&&a<i.length?s.push(i[a]+n):n>0?s.push(n):n<0&&void 0!==i[a+1]&&i[a+1]>1?s.push(i[a]+n+1):n<0&&a<i.length?s.push(T(1,i[a]+n)):n<0&&s.push(1),n<0)for(;s.length<=o;)s.push(1);return(n>=0?e.slice(t.index+1):e.slice(0,t.index).reverse()).find((function(e){var t=ie(e.coordinates,s);return n<0?t<=0:t>=0}))}function te(e,t){return t>=0?I(t,e.length):T(e.length+t,0)}function ne(e){return Object.keys(e).filter((function(e){return e.startsWith("coordinate-")})).map((function(e){var t=parseInt(e.substr("coordinate-".length),10);return{key:e,keyNumber:t}})).sort((function(e,t){return re(e.keyNumber,t.keyNumber)})).map((function(t){return parseInt(e[t.key],10)}))}function re(e,t){return void 0!==e&&void 0===t?1:void 0===e&&void 0!==t?-1:void 0===e&&void 0===t?0:void 0!==e&&void 0!==t&&e>t?1:void 0!==e&&void 0!==t&&e<t?-1:0}function oe(e,t){return 0===ie(e,t)}function ie(e,t){if(e===t)return 0;if(null==e)return-1;if(null==t)return 1;for(var n=T(e.length,t.length),r=0;r<n;r++){var o=re(e[r],t[r]);if(0!==o)return o}return 0}function ae(e,t){var n,r;if(0===t.length)return!1;var o=e;try{for(var i=k(t),a=i.next();!a.done;a=i.next()){var s=a.value,c=s<1,u=Array.isArray(o)&&s-1>=o.length;if(c||u)return!1;var l=o[s-1];o=Array.isArray(l)?l:[]}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}return!0}function se(e,t,n){return e.slice(0,n).join(t)}function ce(e){var t,n,r={};try{for(var o=k(e),i=o.next();!i.done;i=o.next()){var a=i.value;r[se(a.coordinates,".")]=a}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}var ue=function(){this.coordinatesMaxDepth=0,this.slides=[],this.slideMap={}};var le=function(e){function t(){return e.call(this)||this}return x(t,e),t.prototype.setCurrentSlide=function(e){this.state.currentSlide=e},t.prototype.setCurrentMode=function(e){this.state.currentMode=e},t.prototype.setSlides=function(e){this.state.coordinatesMaxDepth=P(e),this.state.slides=j(e),this.state.slideMap=ce(this.state.slides)},t}(v.Commands),de=function(e){function t(t,n,r){var o=e.call(this,"SlideBySlide",new ue,new le)||this;return o.presentation=n,o.router=r,o.onDestroy$=new h.Subject,o.presentation.select((function(e){return e.slides})).pipe(y.takeUntil(o.onDestroy$)).subscribe((function(e){return o.commands.setSlides(e)})),o}return x(t,e),t.prototype.navigateToNext=function(e,t){var n=this;this.nextSlide(e).pipe(y.take(1)).subscribe((function(e){return n.navigateAbsolute(e,t)}))},t.prototype.navigateToPrevious=function(e,t){var n=this;this.previousSlide(e).pipe(y.take(1)).subscribe((function(e){return n.navigateAbsolute(e,t)}))},t.prototype.previousSlide=function(e,t){return this.navigateRelative(-1,e)},t.prototype.nextSlide=function(e){return this.navigateRelative(1,e)},t.prototype.navigateToNextToc=function(e){var t=this;this.nextToc("forward").pipe(y.take(1)).subscribe((function(n){return t.navigateAbsolute(n,e)}))},t.prototype.navigateToPreviousToc=function(e){var t=this;this.nextToc("backward").pipe(y.take(1)).subscribe((function(n){return t.navigateAbsolute(n,e)}))},t.prototype.nextToc=function(e){var t=this.select((function(e){return e.currentSlide})).pipe(g.skipNil()),n=this.select((function(e){return e.slides})).pipe(g.skipNil(),y.filter((function(e){return 0!==e.length})),y.map(Q));return h.combineLatest(t,n).pipe(y.map((function(t){var n=C(t,2),r=n[0],o=n[1];return"forward"===e?o.find((function(e){return 1===ie(e.coordinates,r.coordinates)})):o.slice().reverse().find((function(e){return-1===ie(e.coordinates,r.coordinates)}))})))},t.prototype.navigateRelative=function(e,t){var n=this.select((function(e){return e.currentSlide})).pipe(g.skipNil()),r=this.select((function(e){return e.slides})).pipe(g.skipNil(),y.filter((function(e){return 0!==e.length}))),o=this.select((function(e){return e.coordinatesMaxDepth})).pipe(g.skipNil());return h.combineLatest(r,n,o).pipe(y.map((function(n){var r=C(n,3),o=r[0],i=r[1],a=r[2];return ee(o,i,e,t,a)})))},t.prototype.navigateAbsolute=function(e,t){var n;if(void 0!==(n=e instanceof L?e:this.state.slides.find((function(t){return oe(e,t.coordinates)})))){var r=S(["/"+(void 0!==t?t:void 0!==this.state.currentMode?this.state.currentMode:"slide")],n.coordinates);return this.router.navigate(r,{queryParamsHandling:"merge"})}},t.prototype.navigateToFirst=function(e){var t=this;this.firstSlide().pipe(y.take(1),y.takeUntil(this.onDestroy$)).subscribe((function(n){return t.navigateAbsolute(n,e)}))},t.prototype.firstSlide=function(){return this.select((function(e){return e.slides})).pipe(g.skipNil(),y.filter((function(e){return e.length>0})),y.map((function(e){return e[0]})))},t.prototype.isValidCoordinate=function(e){return this.presentation.select((function(e){return e.slides})).pipe(g.skipNil(),y.filter((function(e){return e.length>0})),y.map((function(t){return ae(t,e)})))},t.prototype.coordinatesToSlide=function(e){return this.state.slideMap[e.join(".")]},t.prototype.setCurrentModeAndSlide=function(e){var t=ne(e.params),n=e.url[0].path,r=this.coordinatesToSlide(t);this.commands.setCurrentSlide(r),this.commands.setCurrentMode(n)},t.prototype.ngOnDestroy=function(){this.onDestroy$.next()},t.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.ctorParameters=function(){return[{type:n.Injector},{type:K},{type:d.Router}]},t.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t(n.ɵɵinject(n.INJECTOR),n.ɵɵinject(K),n.ɵɵinject(d.Router))},token:t,providedIn:"root"}),t}(v.Facade);var pe=function(){function e(e){this.service=e}return e.prototype.init=function(e){var t=this;e.pipe(y.filter(Z),y.filter((function(e){return!(40!==e.keyCode||!e.altKey)||!(39!==e.keyCode||!e.altKey)}))).subscribe((function(){t.service.navigateToNextToc()}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:de}]},e}();var fe=function(){function e(e){this.service=e}return e.prototype.init=function(e){var t=this;e.pipe(y.filter(V),y.filter((function(e){return 40===e.keyCode||39===e.keyCode||34===e.keyCode}))).subscribe((function(){t.service.navigateToNext(-1)}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:de}]},e}();var ve=function(){function e(e){this.service=e}return e.prototype.init=function(e){var t=this;e.pipe(y.filter(Z),y.filter((function(e){return!(38!==e.keyCode||!e.altKey)||!(37!==e.keyCode||!e.altKey)}))).subscribe((function(){t.service.navigateToPreviousToc()}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:de}]},e}();var he=function(){function e(e){this.service=e}return e.prototype.init=function(e){var t=this;e.pipe(y.filter(V),y.filter((function(e){return 38===e.keyCode||37===e.keyCode||33===e.keyCode}))).subscribe((function(){t.service.navigateToPrevious(-1)}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:de}]},e}();var me=function(){function e(e){this.service=e}return e.prototype.init=function(e){var t=this;e.pipe(y.filter(V),y.filter((function(e){return 36===e.keyCode}))).subscribe((function(){t.service.navigateToFirst()}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:de}]},e}();var ge=function(){function e(e,t){this.service=e,this.presentation=t}return e.prototype.init=function(e){var t=this,n=this.presentation.select((function(e){return e.config.navigation.overview})).pipe(g.skipPropertyNil("component")),r=this.service.select().pipe(y.withLatestFrom(n),y.map((function(e){var t=C(e,2),n=t[0],r=t[1];return n.slides.find((function(e){return e.component===r.component}))})));e.pipe(y.filter(V),y.filter((function(e){return 79===e.keyCode})),y.withLatestFrom(r)).subscribe((function(e){var n=C(e,2),r=(n[0],n[1]);t.service.navigateAbsolute(r)}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:de},{type:K}]},e}();var ye=function(){function e(e,t){this.service=e,this.router=t}return e.prototype.init=function(e){var t=this,n=this.service.select();e.pipe(y.filter(Z),y.filter((function(e){return 80===e.keyCode&&e.altKey})),y.withLatestFrom(n)).subscribe((function(e){var n,r=C(e,2),o=(r[0],r[1]);n="presenter"===o.currentMode?"slide":"presenter";var i=[];void 0!==o.currentSlide&&(i=o.currentSlide.coordinates);var a=S([n],i);t.router.navigate(a,{queryParamsHandling:"merge"})}))},e.decorators=[{type:n.Injectable}],e.ctorParameters=function(){return[{type:de},{type:d.Router}]},e}();function be(e){return e instanceof MouseEvent}var xe=function(e){function t(t,n,r,o){var i=e.call(this)||this;return i.service=t,i.router=n,i.element=r,i.routerLinkDirective=o,i.slide$=new h.ReplaySubject(1),o&&i.slide$.pipe(m.untilComponentDestroyed(i)).subscribe((function(e){var t;e?t=S(["/"+i.service.state.currentMode],e.coordinates):t=[];i.routerLinkDirective.routerLink=t,i.routerLinkDirective.ngOnChanges({})})),h.fromEvent(r.nativeElement,"click").pipe(y.filter(be),y.filter((function(e){return e.altKey})),y.withLatestFrom(i.slide$),m.untilComponentDestroyed(i)).subscribe((function(e){var t=C(e,2),n=t[0],r=t[1];n.preventDefault();var o=S(["/presenter"],r.coordinates);i.router.navigate(o,{queryParamsHandling:"merge"})})),i}return x(t,e),Object.defineProperty(t.prototype,"ngxPresentSlideLink",{set:function(e){var t=this;this.service.select((function(e){return e.slides})).pipe(g.skipNil(),m.untilComponentDestroyed(this)).pipe(y.map((function(t){return t.find((function(t){return t.component===e}))})),y.filter((function(e){return void 0!==e})),y.take(1)).subscribe((function(e){return t.slide$.next(e)}))},enumerable:!0,configurable:!0}),t.decorators=[{type:n.Directive,args:[{selector:"[ngxPresentSlideLink]"}]}],t.ctorParameters=function(){return[{type:de},{type:d.Router},{type:n.ElementRef},{type:d.RouterLinkWithHref,decorators:[{type:n.Optional}]}]},t.propDecorators={ngxPresentSlideLink:[{type:n.Input}]},t}(m.OnDestroyMixin);var we=function(){function e(){}return e.prototype.transform=function(e){if(void 0!==e)return e.trim()},e.decorators=[{type:n.Pipe,args:[{name:"trim"}]}],e}(),ke=function(){function e(e,t,n){this.viewContainerRef=e,this.componentFactoryResolver=t,this.injector=n,this.component=null,this.providers=null}return e.prototype.ngOnChanges=function(e){if(this.viewContainerRef.clear(),null!==this.component){var t=n.Injector.create({providers:this.providers||[],parent:this.injector}),r=this.componentFactoryResolver.resolveComponentFactory(this.component);this.viewContainerRef.createComponent(r,void 0,t)}},e.decorators=[{type:n.Component,args:[{selector:"ngx-present-dynamic",template:"\n",styles:[":host{width:100vw;height:100vh}"]}]}],e.ctorParameters=function(){return[{type:n.ViewContainerRef},{type:n.ComponentFactoryResolver},{type:n.Injector}]},e.propDecorators={component:[{type:n.Input}],providers:[{type:n.Input}]},e}();var Ce=function(e){function t(t){var n=e.call(this)||this;return n.presentation=t,n}return x(t,e),t.prototype.ngOnInit=function(){var e=this;this.presentation.select((function(e){return e.slides})).pipe(y.map((function(e){return j(e)})),m.untilComponentDestroyed(this)).subscribe((function(t){return e.slides=t}))},t.decorators=[{type:n.Component,args:[{selector:"ngx-present-export-route",template:'<div ngxPresentPageTitle>Export</div>\n\n<mat-toolbar color="accent">\n <ngx-present-menu-toggle-icon></ngx-present-menu-toggle-icon>\n <h1>Export</h1>\n</mat-toolbar>\n\n<div class="slides">\n\n <div class="slide"\n *ngFor="let slide of slides">\n <ngx-present-slide [slide]="slide"></ngx-present-slide>\n </div>\n</div>\n\n',styles:[".slide{position:relative;width:297mm;height:210mm}"]}]}],t.ctorParameters=function(){return[{type:K}]},t}(m.OnDestroyMixin);var Se=function(){function e(){}return e.decorators=[{type:n.Component,args:[{selector:"ngx-present-help-content",template:'<h2>Navigation</h2>\n\n<p class="presentation-navigation">\n <mat-icon>menu</mat-icon>\n Click on the menu icon in the upper left corner to open the menu.<br>\n Via the menu you can navigate to the different modes like slide-by-slide, overview and presenter.\n You can also use the table of content to jump to specific sections,\n if the author of the presentation uses this feature.\n</p>\n\n<h2>Navigation in Slide Mode</h2>\n\n<table class="key-action">\n <thead>\n <tr>\n <th>Key</th>\n <th>Action</th>\n </tr>\n </thead>\n <tbody>\n <tr>\n <td>Arrow Right</td>\n <td>Go to next slide</td>\n </tr>\n <tr>\n <td>Arrow Down </td>\n <td>Go to next slide</td>\n </tr>\n <tr>\n <td>Page Down</td>\n <td>Go to next slide</td>\n </tr>\n <tr>\n <td>Arrow Left</td>\n <td>Go to previous slide</td>\n </tr>\n <tr>\n <td>Arrow Up</td>\n <td>Go to previous slide</td>\n </tr>\n <tr>\n <td>Page Up</td>\n <td>Go to previous slide</td>\n </tr>\n <tr>\n <td>ALT + Arrow Right</td>\n <td>Go to next table-of-content entry</td>\n </tr>\n <tr>\n <td>ALT + Arrow Down</td>\n <td>Go to next table-of-content entry</td>\n </tr>\n <tr>\n <td>ALT + Arrow Left</td>\n <td>Go to previous table-of-content entry</td>\n </tr>\n <tr>\n <td>ALT + Arrow Up</td>\n <td>Go to previous table-of-content entry</td>\n </tr>\n <tr>\n <td>Pos 1</td>\n <td>Go to first slide</td>\n </tr>\n <tr>\n <td>m</td>\n <td>Open menu</td>\n </tr>\n <tr>\n <td>o</td>\n <td>Go to table of content</td>\n </tr>\n </tbody>\n</table>\n\n<h2>About</h2>\n\n<p>\n <b>@w11k/ngx-present</b> is an <a href="https://angular.io" target="_blank" tabindex="-1">Angular</a> based,\n open source presentation tool developed by <a href="https://w11k.de" target="_blank" tabindex="-1">W11K</a>.\n For more information please visit the project website at\n <a href="https://github.com/w11k/ngx-present" target="_blank" tabindex="-1">github.com/w11k/ngx-present</a>.\n</p>\n',styles:["h2:first-of-type{margin-top:0}p{max-width:600px}p.presentation-navigation{position:relative;clear:both}p.presentation-navigation mat-icon{float:left;margin-right:.25em;margin-bottom:.25em}table.key-action th{text-align:left}table.key-action tr td{vertical-align:middle;padding-right:16px}table.key-action tr td:last-of-type{padding-right:0}"]}]}],e}(),Pe=function(){function e(){}return e.decorators=[{type:n.Component,args:[{selector:"app-help-dialog",template:'<ngx-present-help-content></ngx-present-help-content>\n\n<mat-dialog-actions>\n <button type="button" mat-raised-button mat-dialog-close>Close Help Dialog</button>\n</mat-dialog-actions>\n',styles:[""]}]}],e}(),Ie=function(){function e(){}return e.decorators=[{type:n.Component,args:[{selector:"ngx-present-help-route",template:'<div ngxPresentPageTitle>Help</div>\n\n<mat-toolbar color="accent">\n <ngx-present-menu-toggle-icon></ngx-present-menu-toggle-icon>\n <h1>Help</h1>\n</mat-toolbar>\n\n<div class="content">\n <ngx-present-help-content></ngx-present-help-content>\n</div>\n',styles:[".content{margin:16px;display:flex;justify-content:center;flex-direction:row}"]}]}],e}(),Te=function(){function e(e,t){this.router=e,this.service=t}return e.prototype.resolve=function(e,t){this.service.setCurrentModeAndSlide(e);var n=new h.ReplaySubject;return n.next(),n.pipe(y.delay(0),y.first())},e.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],e.ctorParameters=function(){return[{type:d.Router},{type:de}]},e.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new e(n.ɵɵinject(d.Router),n.ɵɵinject(de))},token:e,providedIn:"root"}),e}();var je=function(){this.defaultZoom=6,this.minZoom=2,this.maxZoom=12,this.zoom=this.defaultZoom,this.lineBreakOnFirstLevel=!0};var Oe=function(e){function t(){return e.call(this)||this}return x(t,e),t.prototype.zoomIn=function(){this.state.zoom>=this.state.minZoom&&(this.state=w(w({},this.state),{zoom:this.state.zoom-1}))},t.prototype.resetZoom=function(){this.state=w(w({},this.state),{zoom:this.state.defaultZoom})},t.prototype.zoomOut=function(){this.state.zoom<=this.state.maxZoom&&(this.state=w(w({},this.state),{zoom:this.state.zoom+1}))},t.prototype.toggleLineBreakOnFirstLevel=function(){this.state.lineBreakOnFirstLevel=!this.state.lineBreakOnFirstLevel},t}(v.Commands),De=function(e){function t(){return e.call(this,"TenThousandFoot",new je,new Oe)||this}return x(t,e),t.prototype.zoomIn=function(){this.commands.zoomIn()},t.prototype.resetZoom=function(){this.commands.resetZoom()},t.prototype.zoomOut=function(){this.commands.zoomOut()},t.prototype.toggleLineBreakOnFirstLevel=function(){this.commands.toggleLineBreakOnFirstLevel()},t.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.ctorParameters=function(){return[]},t.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t},token:t,providedIn:"root"}),t}(v.Facade),Ae=function(e){function t(t,n,r){var o=e.call(this)||this;return o.service=t,o.router=n,o.presentation=r,o.zoomFactor=t.state.defaultZoom,o}return x(t,e),t.prototype.ngOnInit=function(){var e=this;this.presentation.select((function(e){return e.slides})).pipe(y.switchMap((function(e){return M(e)})),m.untilComponentDestroyed(this)).subscribe((function(t){return e.slides=t})),this.service.select((function(e){return e})).pipe(m.untilComponentDestroyed(this)).subscribe((function(t){e.view=t,e.zoomFactor=(100-(t.zoom+1))/t.zoom}))},t.prototype.zoomIn=function(){this.service.zoomIn()},t.prototype.resetZoom=function(){this.service.resetZoom()},t.prototype.zoomOut=function(){this.service.zoomOut()},t.prototype.getRouterLink=function(e){return S(["/slide"],e.coordinates)},t.prototype.navigate=function(e,t){e.altKey&&(e.preventDefault(),this.router.navigate(S(["presenter"],t.coordinates)))},t.prototype.toggleBreak=function(){this.service.toggleLineBreakOnFirstLevel()},t.prototype.shouldBreak=function(e){var t,n;if(!this.service.state.lineBreakOnFirstLevel)return!1;var r=e.coordinates.slice(1);try{for(var o=k(r),i=o.next();!i.done;i=o.next()){if(1!==i.value)return!1}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return!0},t.decorators=[{type:n.Component,args:[{selector:"ngx-present-overview-route",template:'<div ngxPresentPageTitle>Overview</div>\n\n<mat-toolbar color="accent">\n <ngx-present-menu-toggle-icon></ngx-present-menu-toggle-icon>\n <h1>Overview</h1>\n <span class="fill-remaining-space"></span>\n <span>\n <button mat-icon-button (click)="toggleBreak()" *ngIf="!view?.lineBreakOnFirstLevel">\n <mat-icon>format_align_left</mat-icon>\n </button>\n <button mat-icon-button (click)="toggleBreak()" *ngIf="view?.lineBreakOnFirstLevel">\n <mat-icon>format_align_justify</mat-icon>\n </button>\n <button mat-icon-button (click)="zoomIn()" [disabled]="view?.zoom <= view?.minZoom">\n <mat-icon>zoom_in</mat-icon>\n </button>\n <button mat-icon-button (click)="resetZoom()" [disabled]="view?.zoom === view?.defaultZoom">\n <mat-icon>search</mat-icon>\n </button>\n <button mat-icon-button (click)="zoomOut()" [disabled]="view?.zoom >= view?.maxZoom">\n <mat-icon>zoom_out</mat-icon>\n </button>\n </span>\n</mat-toolbar>\n\n<div class="slides">\n\n <ng-container *ngFor="let slide of slides">\n <div class="break" *ngIf="shouldBreak(slide)"></div>\n <div class="slide"\n [style.width]="zoomFactor + \'vw\'"\n [style.height]="zoomFactor + \'vh\'"\n >\n <mat-card>\n <mat-card-content>\n <div class="scale" [style.transform]="\'scale(\' + zoomFactor / 100 + \')\'">\n <ngx-present-slide [slide]="slide"></ngx-present-slide>\n </div>\n <a class="overlay"\n [routerLink]="getRouterLink(slide)"\n (click)="navigate($event, slide)"></a>\n </mat-card-content>\n </mat-card>\n </div>\n </ng-container>\n</div>\n',styles:[".slides{width:100vw;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:flex-start;align-content:flex-start;box-sizing:border-box;padding:.5vw}.break{width:100%}.slide{box-sizing:border-box;margin:.5vw;width:32vw;height:32vh}.slide:hover{cursor:pointer}.slide mat-card{height:100%;box-sizing:border-box;padding:0}.slide mat-card mat-card-content{height:100%;position:relative;overflow:hidden}.slide mat-card mat-card-content>.scale{transform:scale(.32);transform-origin:0 0}.slide mat-card mat-card-content>.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:1000}.fill-remaining-space{flex:1 1 auto}"]}]}],t.ctorParameters=function(){return[{type:De},{type:d.Router},{type:K}]},t}(m.OnDestroyMixin);var Me=function(e){function t(t,n,r){var o=e.call(this)||this;return o.title=t,o.presentation=n,o.slideBySlide=r,o}return x(t,e),t.prototype.setupTitleSync=function(e){var t=this,n=this.presentation.select((function(e){return e.config})).pipe(m.untilComponentDestroyed(this)),r=this.slideBySlide.select((function(e){return e.currentSlide})).pipe(g.skipNil(),m.untilComponentDestroyed(this));h.combineLatest(r,n).pipe(y.delay(10),y.map((function(e){var t=C(e,2),n=t[0],r=t[1];return se(n.coordinates,r.coordinates.separator)})),y.map((function(t){return e+" "+t}))).subscribe((function(e){return t.title.prefixTitle(e)}))},t.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],t.ctorParameters=function(){return[{type:q},{type:K},{type:de}]},t.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new t(n.ɵɵinject(q),n.ɵɵinject(K),n.ɵɵinject(de))},token:t,providedIn:"root"}),t}(m.OnDestroyMixin);var Ne=function(e){function t(t,n,r,o,i){var a=e.call(this)||this;return a.route=t,a.slideRouter=n,a.presentation=r,a.slides=o,a.title=i,a.currentSlide$=a.slides.select((function(e){return e.currentSlide})).pipe(g.skipNil(),m.untilComponentDestroyed(a)),a.preview1$=a.presentation.select((function(e){return e.config.presenter.preview1})).pipe(y.switchMap((function(e){return a.slides.navigateRelative(e.move,e.coordinatesToKeep)})),m.untilComponentDestroyed(a)),a.preview2$=a.presentation.select((function(e){return e.config.presenter.preview2})).pipe(y.switchMap((function(e){return a.slides.navigateRelative(e.move,e.coordinatesToKeep)})),m.untilComponentDestroyed(a)),a.title.setupTitleSync("Presenter"),a}return x(t,e),t.prototype.ngOnInit=function(){var e=this;this.route.queryParamMap.pipe(y.map((function(e){return e.get("id")})),m.untilComponentDestroyed(this)).subscribe((function(t){null!==t&&e.presentation.dispatch.setId(t)}))},t.decorators=[{type:n.Component,args:[{selector:"ngx-present-presenter-route",template:'<ngx-present-presenter-view [currentSlide]="currentSlide$ | async"\n [preview1]="preview1$ | async"\n [preview2]="preview2$ | async">\n</ngx-present-presenter-view>\n'}]}],t.ctorParameters=function(){return[{type:d.ActivatedRoute},{type:Te},{type:K},{type:de},{type:Me}]},t}(m.OnDestroyMixin);var Le=function(e){function t(t,n,r){var o=e.call(this)||this;return o.route=t,o.service=n,o.title=r,o.slide$=o.service.select((function(e){return e.currentSlide})).pipe(g.skipNil(),m.untilComponentDestroyed(o)),o.title.setupTitleSync("Slide"),o}return x(t,e),t.decorators=[{type:n.Component,args:[{selector:"ngx-present-slide-by-slide-route",template:'<div class="slide-container">\n <ngx-present-slide [slide]="slide$ | async"></ngx-present-slide>\n</div>\n\n',styles:["div.slide-container{width:100vw;height:100vh}"]}]}],t.ctorParameters=function(){return[{type:d.ActivatedRoute},{type:de},{type:Me}]},t}(m.OnDestroyMixin);var Re=function(){function e(e,t){this.service=e,this.router=t}return e.prototype.canActivate=function(e){var t=this,n=ne(e.params),r=this.service.isValidCoordinate(n).pipe(y.take(1));return r.pipe(y.filter((function(e){return!e})),y.switchMap((function(){return t.service.state.currentSlide?h.of(t.service.state.currentSlide):t.service.firstSlide().pipe(y.take(1))}))).subscribe((function(r){console.info("slide with coordinate "+JSON.stringify(n)+" does not exist, going to navigate to first slide");var o="slide",i=e.url[0];void 0!==i&&void 0!==i.path&&(o=i.path),t.router.navigate(S([o],r.coordinates),{queryParamsHandling:"merge"})})),r},e.decorators=[{type:n.Injectable,args:[{providedIn:"root"}]}],e.ctorParameters=function(){return[{type:de},{type:d.Router}]},e.ɵprov=n.ɵɵdefineInjectable({factory:function(){return new e(n.ɵɵinject(de),n.ɵɵinject(d.Router))},token:e,providedIn:"root"}),e}();function Be(e){return $e("slide",e)}function Ee(e){return $e("presenter",e)}function $e(e,t){if(0===t.length)return{consumed:[]};var n=t.slice(),r=n.shift();if(r&&r.path===e){for(var o={consumed:[r],posParams:{}},i=0;i<n.length;i++){var a=n[i],s=parseInt(a.path,10);if(!1!==Number.isNaN(s))break;o.consumed.push(a),o.posParams["coordinate-"+i]=a}return o}return{consumed:[]}}var ze=[{matcher:Be,component:Le,canActivate:[Re],resolve:{slide:Te}},{matcher:Ee,component:Ne,canActivate:[Re],resolve:{slide:Te}},{path:"overview",component:Ae},{path:"export",component:Ce},{path:"help",component:Ie}],Fe=function(e){function t(t,n){var r=e.call(this)||this;return r.presentation=t,r.events=n,r}return x(t,e),t.prototype.ngAfterViewInit=function(){var e=this;this.presentation.select((function(e){return e.sideBar.open})).pipe(m.untilComponentDestroyed(this)).subscribe((function(t){if(void 0===e.sideNav)throw new Error("Couldn't find side nav component as child");t?e.sideNav.open():e.sideNav.close()}))},t.prototype.onSideNavClose=function(e){e||this.presentation.dispatch.closeSideBar()},t.prototype.onKeyPressed=function(e){this.events.processKeyboardEvent(e)},t.decorators=[{type:n.Component,args:[{selector:"ngx-present-container",template:'<mat-sidenav-container>\n <mat-sidenav\n (openedChange)="onSideNavClose($event)"\n >\n <ngx-present-sidebar-content>\n </ngx-present-sidebar-content>\n </mat-sidenav>\n\n <mat-sidenav-content>\n <router-outlet></router-outlet>\n </mat-sidenav-content>\n\n</mat-sidenav-container>\n',styles:["mat-sidenav{width:250px}:host,mat-sidenav-container{box-sizing:border-box;width:100vw;max-width:100vw;height:100vh;max-height:100vh;overflow:hidden}"]}]}],t.ctorParameters=function(){return[{type:K},{type:J}]},t.propDecorators={sideNav:[{type:n.ViewChild,args:[c.MatSidenav]}],onKeyPressed:[{type:n.HostListener,args:["document:keydown",["$event"]]}]},t}(m.OnDestroyMixin);var Ke=function(e){function t(t){var n=e.call(this)||this;return n.presentation=t,n.id="",n.presentation.select((function(e){return e.id})).pipe(m.untilComponentDestroyed(n)).subscribe((function(e){return n.id=e})),n.showCoordinates$=n.presentation.select((function(e){return e.config.sidebar.tableOfContent.showCoordinates})).pipe(g.skipNil(),m.untilComponentDestroyed(n)),n.showTableOfContent$=n.presentation.select((function(e){return e.config.sidebar.tableOfContent.enabled})).pipe(g.skipNil(),m.untilComponentDestroyed(n)),n.coordinatesSeparator$=n.presentation.select((function(e){return e.config.sidebar.tableOfContent.separator})).pipe(g.skipNil(),m.untilComponentDestroyed(n)),n.depth$=n.presentation.select((function(e){return e.config.sidebar.tableOfContent.depth})).pipe(m.untilComponentDestroyed(n)),n.showExpertMenu$=n.presentation.select((function(e){return e.sideBar.expert})).pipe(m.untilComponentDestroyed(n)),n.showSettings$=n.presentation.select((function(e){return e.sideBar.settings})).pipe(m.untilComponentDestroyed(n)),n.themeLight$=n.presentation.select((function(e){return"light"===e.config.code.theme})).pipe(m.untilComponentDestroyed(n)),n}return x(t,e),t.prototype.ngOnInit=function(){},t.prototype.closeSideNav=function(){var e=this;setTimeout((function(){e.presentation.dispatch.closeSideBar()}),25)},t.prototype.startP2P=function(){},t.prototype.setTheme=function(e){this.presentation.dispatch.setCodeTheme(e.checked?"light":"dark")},t.decorators=[{type:n.Component,args:[{selector:"ngx-present-sidebar-content",template:'<div class="menu">\n <mat-nav-list (click)="closeSideNav()">\n <a mat-list-item\n routerLink="slide"\n routerLinkActive="active">Slides</a>\n <a mat-list-item\n routerLink="overview"\n routerLinkActive="active">Overview</a>\n <a mat-list-item\n routerLink="help"\n routerLinkActive="active">Help</a>\n </mat-nav-list>\n <mat-divider></mat-divider>\n <div class="mat-nav-list table-of-content"\n *ngIf="showTableOfContent$ | async"\n (click)="closeSideNav()">\n <h2>Table of Content</h2>\n <ngx-present-table-of-content [showCoordinates]="showCoordinates$ | async"\n [depth]="depth$ | async"\n [coordinatesSeparator]="coordinatesSeparator$ | async">\n </ngx-present-table-of-content>\n </div>\n <span class="fill-remaining-space"></span>\n <ng-container *ngIf="showSettings$ | async">\n <mat-divider></mat-divider>\n <mat-nav-list >\n <mat-list-item [disableRipple]="true">\n <mat-slide-toggle #toggle [checked]="themeLight$ | async" (change)="setTheme($event)">Dark / Light</mat-slide-toggle>\n </mat-list-item>\n </mat-nav-list>\n </ng-container>\n <ng-container *ngIf="showExpertMenu$ | async">\n <mat-divider></mat-divider>\n <mat-nav-list (click)="closeSideNav()">\n <a mat-list-item\n (click)="startP2P()"\n routerLink="presenter"\n [queryParams]="{ id: id }">Presenter</a>\n </mat-nav-list>\n </ng-container>\n</div>\n',encapsulation:n.ViewEncapsulation.None,styles:["ngx-present-sidebar-content .mat-nav-list .mat-list-item.active{font-weight:700}ngx-present-sidebar-content div.menu{display:flex;flex-direction:column;height:100vh}ngx-present-sidebar-content .table-of-content{padding-top:8px;overflow-y:scroll}ngx-present-sidebar-content .table-of-content h2{display:block;padding:0 16px;font-size:inherit}ngx-present-sidebar-content .table-of-content ul{list-style-type:none;margin:0;padding:0}ngx-present-sidebar-content .table-of-content ul li{padding:8px 0 8px 16px}ngx-present-sidebar-content .fill-remaining-space{flex:1 1 auto}"]}]}],t.ctorParameters=function(){return[{type:K}]},t}(m.OnDestroyMixin);var qe=function(){};var _e=function(){function e(e,t){var n=this;this.template=e,this.target=t,t&&setTimeout((function(){n.detach=t.attach(e)}),0)}return e.prototype.ngOnDestroy=function(){this.detach&&(this.detach(),this.detach=void 0)},e.decorators=[{type:n.Directive,args:[{selector:"[ngxPresentSpeakerNotes]"}]}],e.ctorParameters=function(){return[{type:n.TemplateRef},{type:qe,decorators:[{type:n.Optional}]}]},e}();var Ve=function(){function e(e){this.service=e,this.speakerNoteProviders=[{provide:qe,useValue:this}]}return e.prototype.attach=function(e){if(void 0===this.container)throw new Error("Couldn't find child speaker notes. Check template to expose it");var t=this.container.createEmbeddedView(e);return function(){t.destroy()}},e.prototype.goTo=function(e){void 0!==e&&this.service.navigateAbsolute(e)},e.decorators=[{type:n.Component,args:[{selector:"ngx-present-presenter-view",template:'<div class="content">\n <div class="slides">\n <div class="currentSlide">\n <mat-card>\n <mat-card-content>\n <div class="scale">\n <ngx-present-slide [slide]="currentSlide" [providers]="speakerNoteProviders"></ngx-present-slide>\n </div>\n </mat-card-content>\n </mat-card>\n </div>\n\n <div class="preview">\n <div class="preview-1">\n <mat-card>\n <mat-card-content>\n <div class="scale">\n <ngx-present-slide [slide]="preview1"></ngx-present-slide>\n </div>\n <a class="overlay" (click)="goTo(preview1)"></a>\n </mat-card-content>\n </mat-card>\n </div>\n\n <div class="preview-2">\n <mat-card>\n <mat-card-content>\n <div class="scale">\n <ngx-present-slide [slide]="preview2"></ngx-present-slide>\n </div>\n <a class="overlay" (click)="goTo(preview2)"></a>\n </mat-card-content>\n </mat-card>\n </div>\n </div>\n\n </div>\n\n <div class="side-bar">\n <div class="speaker-notes">\n <div #speakerNotes></div>\n </div>\n </div>\n\n</div>\n',styles:[".content{display:flex;flex-direction:row;padding:1vh}.content .slides{box-sizing:border-box;margin-right:1vh;display:flex;flex-direction:column}.content .slides .currentSlide mat-card{width:65vw;height:65vh;box-sizing:border-box;padding:0}.content .slides .currentSlide mat-card mat-card-content{width:65vw;height:65vh;position:relative;overflow:hidden}.content .slides .currentSlide mat-card mat-card-content>.scale{transform:scale(.651);transform-origin:0 0}.content .slides .currentSlide mat-card mat-card-content>.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:1000}.content .slides .currentSlide mat-card mat-card-content>.overlay:hover{cursor:pointer}.content .slides .preview{margin-top:1vh;display:flex;flex-direction:row}.content .slides .preview-1 mat-card{width:32vw;height:32vh;box-sizing:border-box;padding:0}.content .slides .preview-1 mat-card mat-card-content{width:32vw;height:32vh;position:relative;overflow:hidden}.content .slides .preview-1 mat-card mat-card-content>.scale{transform:scale(.321);transform-origin:0 0}.content .slides .preview-1 mat-card mat-card-content>.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:1000}.content .slides .preview-1 mat-card mat-card-content>.overlay:hover{cursor:pointer}.content .slides .preview-2{margin-left:1vw}.content .slides .preview-2 mat-card{width:32vw;height:32vh;box-sizing:border-box;padding:0}.content .slides .preview-2 mat-card mat-card-content{width:32vw;height:32vh;position:relative;overflow:hidden}.content .slides .preview-2 mat-card mat-card-content>.scale{transform:scale(.321);transform-origin:0 0}.content .slides .preview-2 mat-card mat-card-content>.overlay{position:absolute;top:0;left:0;width:100%;height:100%;z-index:1000}.content .slides .preview-2 mat-card mat-card-content>.overlay:hover{cursor:pointer}.content .side-bar{display:flex;flex-direction:column}.content .side-bar .speaker-notes{flex:1 0 auto}"]}]}],e.ctorParameters=function(){return[{type:de}]},e.propDecorators={currentSlide:[{type:n.Input}],preview1:[{type:n.Input}],preview2:[{type:n.Input}],container:[{type:n.ViewChild,args:["speakerNotes",{read:n.ViewContainerRef}]}]},e}();var Ze=function(){function e(){this.slide=new h.ReplaySubject(1)}return e.decorators=[{type:n.Injectable}],e}();var He=function(){this.slide=new h.ReplaySubject(1)};var Ge=function(){function e(){this.activatedSlide=new He,this.internalProviders=[{provide:Ze,useValue:this.activatedSlide}],this.providersCombined=S(this.internalProviders)}return Object.defineProperty(e.prototype,"providers",{set:function(e){this.providersCombined=S(e,this.internalProviders)},enumerable:!0,configurable:!0}),e.prototype.ngOnChanges=function(e){e.slide&&this.slide&&this.activatedSlide.slide.next(this.slide)},e.decorators=[{type:n.Component,args:[{selector:"ngx-present-slide",template:'<ngx-present-dynamic [component]="slide?.component" [providers]="providersCombined"></ngx-present-dynamic>\n',styles:[""]}]}],e.ctorParameters=function(){return[]},e.propDecorators={slide:[{type:n.Input}],providers:[{type:n.Input}]},e}();var Ue=function(){function e(e){this.dialog=e}return e.prototype.showHelpDialog=function(){this.dialog.open(Pe)},e.decorators=[{type:n.Component,args:[{selector:"ngx-present-help-dialog-icon",template:'\n <button mat-icon-button (click)="showHelpDialog()">\n <mat-icon>help_outline</mat-icon>\n </button>\n '}]}],e.ctorParameters=function(){return[{type:i.MatDialog}]},e}();var We=function(){function e(e){this.presentation=e}return e.prototype.toggleSideNav=function(e){this.presentation.toggleSideBar(e)},e.decorators=[{type:n.Component,args:[{selector:"ngx-present-menu-toggle-icon",template:'\n <button mat-icon-button (click)="toggleSideNav($event)">\n <mat-icon>menu</mat-icon>\n </button>\n '}]}],e.ctorParameters=function(){return[{type:K}]},e}();var Je=function(e){function t(t,n){var r=e.call(this)||this;r.activatedSlide=t,r.presentation=n;var o=r.presentation.select((function(e){return e.config})).pipe(m.untilComponentDestroyed(r)),i=r.activatedSlide.slide.pipe(y.map((function(e){return e.coordinates})));return r.coordinates$=h.combineLatest(o,i).pipe(y.map((function(e){var t=C(e,2),n=t[0];return se(t[1],n.coordinates.separator)}))),r}return x(t,e),t.decorators=[{type:n.Component,args:[{selector:"ngx-present-slide-index",template:"{{coordinates$ | async}}"}]}],t.ctorParameters=function(){return[{type:Ze},{type:K}]},t}(m.OnDestroyMixin);var Ye=function(){function e(){}return e.prototype.isFlat=function(e){return!Array.isArray(e)&&void 0!==e},e.prototype.isNested=function(e){return Array.isArray(e)&&void 0!==e},e.prototype.first=function(e){return void 0===e||Array.isArray(e[0])?void 0:e[0]},e.decorators=[{type:n.Component,args:[{selector:"ngx-present-table-of-content-view",template:'<ul>\n <li *ngFor="let x of entries" class="keep-together">\n <ng-container *ngIf="isFlat(x)">\n <a routerLink [ngxPresentSlideLink]="x.component">\n {{x.name}}\n </a>\n </ng-container>\n\n <ng-container *ngIf="isNested(x)">\n <ng-container *ngIf="first(x) as y">\n <a routerLink [ngxPresentSlideLink]="y.component">\n {{y.name}}\n </a>\n </ng-container>\n <ng-container *ngIf="(x.length > 1)">\n <ngx-present-table-of-content-view [entries]="x.slice(1)">\n </ngx-present-table-of-content-view>\n </ng-container>\n </ng-container>\n </li>\n</ul>\n'}]}],e.propDecorators={entries:[{type:n.Input}]},e}();var Xe=function(e){function t(t){var n=e.call(this)||this;n.service=t,n.showCoordinates$=new h.BehaviorSubject(void 0),n.coordinatesSeparator$=new h.BehaviorSubject(void 0),n.depth$=new h.BehaviorSubject(void 0);var r=n.service.select((function(e){return e})).pipe(m.untilComponentDestroyed(n));return h.combineLatest(r,n.showCoordinates$,n.coordinatesSeparator$,n.depth$).pipe(y.map((function(e){var t,n,r,o=C(e,4),i=o[0],a=o[1],s=o[2],c=o[3];return D(O(N(i.slides,c||i.config.tableOfContent.depth),(t=i.config,n=a,r=s,function(e){var o=X(e);if(void 0!==o){var i=o.linkName;return(void 0!==n&&n||t.tableOfContent.showCoordinates)&&(i=""+se(e.coordinates,t.coordinates.separator,-1)+(void 0!==r?r:t.tableOfContent.separator)+" "+i),{component:e.component,name:i}}})),(function(e){return void 0!==e}))}))).subscribe((function(e){return n.entries=e})),n}return x(t,e),Object.defineProperty(t.prototype,"showCoordinates",{set:function(e){this.showCoordinates$.next(e)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"coordinatesSeparator",{set:function(e){this.coordinatesSeparator$.next(e)},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"depth",{set:function(e){this.depth$.next(e)},enumerable:!0,configurable:!0}),t.decorators=[{type:n.Component,args:[{selector:"ngx-present-table-of-content",template:'\n <ngx-present-table-of-content-view [entries]="entries"></ngx-present-table-of-content-view>\n '}]}],t.ctorParameters=function(){return[{type:K}]},t.propDecorators={showCoordinates:[{type:n.Input}],coordinatesSeparator:[{type:n.Input}],depth:[{type:n.Input}]},t}(m.OnDestr