UNPKG

@tindtechnologies/universalviewer

Version:

The Universal Viewer is a community-developed open source project on a mission to help you share your 📚📜📰📽️📻🗿 with the 🌎

1 lines 21.6 kB
"use strict";(self.webpackChunkUV=self.webpackChunkUV||[]).push([[9676],{5721(e,n,t){t.d(n,{a:()=>r,d:()=>i});var r=function(e,n,t,r,i){return o=void 0,a=void 0,c=function(){var o;return function(e,n){var t,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=n.call(e,a)}catch(e){o=[6,e],r=0}finally{t=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}(this,(function(a){switch(a.label){case 0:if(e)return[2,e.attachViewToDom(n,t,i,r)];if("string"!=typeof t&&!(t instanceof HTMLElement))throw new Error("framework delegate is missing");return o="string"==typeof t?n.ownerDocument&&n.ownerDocument.createElement(t):t,r&&r.forEach((function(e){return o.classList.add(e)})),i&&Object.assign(o,i),n.appendChild(o),o.componentOnReady?[4,o.componentOnReady()]:[3,2];case 1:a.sent(),a.label=2;case 2:return[2,o]}}))},new((s=void 0)||(s=Promise))((function(e,n){function t(e){try{i(c.next(e))}catch(e){n(e)}}function r(e){try{i(c.throw(e))}catch(e){n(e)}}function i(n){n.done?e(n.value):new s((function(e){e(n.value)})).then(t,r)}i((c=c.apply(o,a||[])).next())}));var o,a,s,c},i=function(e,n){if(n){if(e){var t=n.parentElement;return e.removeViewFromDom(t,n)}n.remove()}return Promise.resolve()}},1761(e,n,t){t.d(n,{L:()=>l,a:()=>s,b:()=>c,d:()=>D,g:()=>S,l:()=>k,s:()=>P,t:()=>u});var r=t(5873),i=function(e,n,t,r){return new(t||(t=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((r=r.apply(e,n||[])).next())}))},o=function(e,n){var t,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=n.call(e,a)}catch(e){o=[6,e],r=0}finally{t=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}},a=void 0,s="ionViewWillLeave",c="ionViewDidLeave",l="ionViewWillUnload",u=function(e){return new Promise((function(n,t){(0,r.w)((function(){d(e),f(e).then((function(t){t.animation&&t.animation.destroy(),h(e),n(t)}),(function(n){h(e),t(n)}))}))}))},d=function(e){var n=e.enteringEl,t=e.leavingEl;L(n,t,e.direction),e.showGoBack?n.classList.add("can-go-back"):n.classList.remove("can-go-back"),P(n,!1),t&&P(t,!1)},f=function(e){return i(a,void 0,void 0,(function(){var n;return o(this,(function(t){switch(t.label){case 0:return[4,p(e)];case 1:return[2,(n=t.sent())?m(n,e):v(e)]}}))}))},h=function(e){var n=e.enteringEl,t=e.leavingEl;n.classList.remove("ion-page-invisible"),void 0!==t&&t.classList.remove("ion-page-invisible")},p=function(e){return i(a,void 0,void 0,(function(){var n;return o(this,(function(r){switch(r.label){case 0:return e.leavingEl&&e.animated&&0!==e.duration?e.animationBuilder?[2,e.animationBuilder]:"ios"!==e.mode?[3,2]:[4,Promise.all([t.e(6653),t.e(5480)]).then(t.bind(t,5480))]:[2,void 0];case 1:return n=r.sent().iosTransitionAnimation,[3,4];case 2:return[4,Promise.all([t.e(6653),t.e(3203)]).then(t.bind(t,3203))];case 3:n=r.sent().mdTransitionAnimation,r.label=4;case 4:return[2,n]}}))}))},m=function(e,n){return i(a,void 0,void 0,(function(){var r,i;return o(this,(function(o){switch(o.label){case 0:return[4,b(n,!0)];case 1:o.sent(),o.label=2;case 2:return o.trys.push([2,5,,6]),[4,t.e(1605).then(t.bind(t,1605))];case 3:return[4,o.sent().create(e,n.baseEl,n)];case 4:return r=o.sent(),[3,6];case 5:return o.sent(),r=e(n.baseEl,n),[3,6];case 6:return g(n.enteringEl,n.leavingEl),[4,w(r,n)];case 7:return i=o.sent(),n.progressCallback&&n.progressCallback(void 0),i&&x(n.enteringEl,n.leavingEl),[2,{hasCompleted:i,animation:r}]}}))}))},v=function(e){return i(a,void 0,void 0,(function(){var n,t;return o(this,(function(r){switch(r.label){case 0:return n=e.enteringEl,t=e.leavingEl,[4,b(e,!1)];case 1:return r.sent(),g(n,t),x(n,t),[2,{hasCompleted:!0}]}}))}))},b=function(e,n){return i(a,void 0,void 0,(function(){var t,r;return o(this,(function(i){switch(i.label){case 0:return t=void 0!==e.deepWait?e.deepWait:n,r=t?[D(e.enteringEl),D(e.leavingEl)]:[E(e.enteringEl),E(e.leavingEl)],[4,Promise.all(r)];case 1:return i.sent(),[4,y(e.viewIsReady,e.enteringEl)];case 2:return i.sent(),[2]}}))}))},y=function(e,n){return i(a,void 0,void 0,(function(){return o(this,(function(t){switch(t.label){case 0:return e?[4,e(n)]:[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}}))}))},w=function(e,n){var t=n.progressCallback,r=new Promise((function(n){e.onFinish((function(t){"number"==typeof t?n(1===t):void 0!==e.hasCompleted&&n(e.hasCompleted)}))}));return t?(e.progressStart(!0),t(e)):e.play(),r},g=function(e,n){k(n,s),k(e,"ionViewWillEnter")},x=function(e,n){k(e,"ionViewDidEnter"),k(n,c)},k=function(e,n){if(e){var t=new CustomEvent(n,{bubbles:!1,cancelable:!1});e.dispatchEvent(t)}},E=function(e){return e&&e.componentOnReady?e.componentOnReady():Promise.resolve()},D=function(e){return i(a,void 0,void 0,(function(){var n;return o(this,(function(t){switch(t.label){case 0:return(n=e)?null==n.componentOnReady?[3,2]:[4,n.componentOnReady()]:[3,4];case 1:if(null!=t.sent())return[2];t.label=2;case 2:return[4,Promise.all(Array.from(n.children).map(D))];case 3:t.sent(),t.label=4;case 4:return[2]}}))}))},P=function(e,n){n?(e.setAttribute("aria-hidden","true"),e.classList.add("ion-page-hidden")):(e.hidden=!1,e.removeAttribute("aria-hidden"),e.classList.remove("ion-page-hidden"))},L=function(e,n,t){void 0!==e&&(e.style.zIndex="back"===t?"99":"101"),void 0!==n&&(n.style.zIndex="100")},S=function(e){return e.classList.contains("ion-page")?e:e.querySelector(":scope > .ion-page, :scope > ion-nav, :scope > ion-tabs")||e}},9676(e,n,t){t.r(n),t.d(n,{ion_modal:()=>m});var r=t(5873),i=t(636),o=t(1178),a=t(5721),s=t(6653),c=t(1761),l=function(e,n,t,r){return new(t||(t=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((r=r.apply(e,n||[])).next())}))},u=function(e,n){var t,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=n.call(e,a)}catch(e){o=[6,e],r=0}finally{t=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}},d=function(e){var n=(0,s.c)(),t=(0,s.c)(),r=(0,s.c)();return t.addElement(e.querySelector("ion-backdrop")).fromTo("opacity",.01,.4),r.addElement(e.querySelector(".modal-wrapper")).beforeStyles({opacity:1}).fromTo("transform","translateY(100%)","translateY(0%)"),n.addElement(e).easing("cubic-bezier(0.36,0.66,0.04,1)").duration(400).beforeAddClass("show-modal").addAnimation([t,r])},f=function(e){var n=(0,s.c)(),t=(0,s.c)(),r=(0,s.c)(),i=e.querySelector(".modal-wrapper"),o=i.getBoundingClientRect();return t.addElement(e.querySelector("ion-backdrop")).fromTo("opacity",.4,0),r.addElement(i).beforeStyles({opacity:1}).fromTo("transform","translateY(0%)","translateY("+(e.ownerDocument.defaultView.innerHeight-o.top)+"px)"),n.addElement(e).easing("ease-out").duration(250).addAnimation([t,r])},h=function(e){var n=(0,s.c)(),t=(0,s.c)(),r=(0,s.c)();return t.addElement(e.querySelector("ion-backdrop")).fromTo("opacity",.01,.32),r.addElement(e.querySelector(".modal-wrapper")).keyframes([{offset:0,opacity:.01,transform:"translateY(40px)"},{offset:1,opacity:1,transform:"translateY(0px)"}]),n.addElement(e).easing("cubic-bezier(0.36,0.66,0.04,1)").duration(280).beforeAddClass("show-modal").addAnimation([t,r])},p=function(e){var n=(0,s.c)(),t=(0,s.c)(),r=(0,s.c)(),i=e.querySelector(".modal-wrapper");return t.addElement(e.querySelector("ion-backdrop")).fromTo("opacity",.32,0),r.addElement(i).keyframes([{offset:0,opacity:.99,transform:"translateY(0px)"},{offset:1,opacity:0,transform:"translateY(40px)"}]),n.addElement(e).easing("cubic-bezier(0.47,0,0.745,0.715)").duration(200).addAnimation([t,r])},m=function(){function e(e){var n=this;(0,r.r)(this,e),this.presented=!1,this.mode=(0,r.f)(this),this.keyboardClose=!0,this.backdropDismiss=!0,this.showBackdrop=!0,this.animated=!0,this.onBackdropTap=function(){n.dismiss(void 0,o.B)},this.onDismiss=function(e){e.stopPropagation(),e.preventDefault(),n.dismiss()},this.onLifecycle=function(e){var t=n.usersElement,r=v[e.type];if(t&&r){var i=new CustomEvent(r,{bubbles:!1,cancelable:!1,detail:e.detail});t.dispatchEvent(i)}},(0,o.c)(this.el),this.didPresent=(0,r.c)(this,"ionModalDidPresent",7),this.willPresent=(0,r.c)(this,"ionModalWillPresent",7),this.willDismiss=(0,r.c)(this,"ionModalWillDismiss",7),this.didDismiss=(0,r.c)(this,"ionModalDidDismiss",7)}return e.prototype.present=function(){return l(this,void 0,void 0,(function(){var e,n,t;return u(this,(function(r){switch(r.label){case 0:if(this.presented)return[2];if(!(e=this.el.querySelector(".modal-wrapper")))throw new Error("container is undefined");return n=Object.assign(Object.assign({},this.componentProps),{modal:this.el}),t=this,[4,(0,a.a)(this.delegate,e,this.component,["ion-page"],n)];case 1:return t.usersElement=r.sent(),[4,(0,c.d)(this.usersElement)];case 2:return r.sent(),[2,(0,o.d)(this,"modalEnter",d,h)]}}))}))},e.prototype.dismiss=function(e,n){return l(this,void 0,void 0,(function(){var t;return u(this,(function(r){switch(r.label){case 0:return[4,(0,o.e)(this,e,n,"modalLeave",f,p)];case 1:return(t=r.sent())?[4,(0,a.d)(this.delegate,this.usersElement)]:[3,3];case 2:r.sent(),r.label=3;case 3:return[2,t]}}))}))},e.prototype.onDidDismiss=function(){return(0,o.f)(this.el,"ionModalDidDismiss")},e.prototype.onWillDismiss=function(){return(0,o.f)(this.el,"ionModalWillDismiss")},e.prototype.render=function(){var e,n,t=(0,r.f)(this);return(0,r.h)(r.H,{"no-router":!0,"aria-modal":"true",class:Object.assign((e={},e[t]=!0,e),(0,i.g)(this.cssClass)),style:{zIndex:""+(2e4+this.overlayIndex)},onIonBackdropTap:this.onBackdropTap,onIonDismiss:this.onDismiss,onIonModalDidPresent:this.onLifecycle,onIonModalWillPresent:this.onLifecycle,onIonModalWillDismiss:this.onLifecycle,onIonModalDidDismiss:this.onLifecycle},(0,r.h)("ion-backdrop",{visible:this.showBackdrop,tappable:this.backdropDismiss}),(0,r.h)("div",{role:"dialog",class:(n={},n["modal-wrapper"]=!0,n[t]=!0,n)}))},Object.defineProperty(e.prototype,"el",{get:function(){return(0,r.d)(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e,"style",{get:function(){return".sc-ion-modal-md-h{--width:100%;--min-width:auto;--max-width:auto;--height:100%;--min-height:auto;--max-height:auto;--overflow:hidden;--border-radius:0;--border-width:0;--border-style:none;--border-color:transparent;--background:var(--ion-background-color,#fff);--box-shadow:none;left:0;right:0;top:0;bottom:0;display:-ms-flexbox;display:flex;position:absolute;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;contain:strict}.overlay-hidden.sc-ion-modal-md-h{display:none}.modal-wrapper.sc-ion-modal-md{border-radius:var(--border-radius);width:var(--width);min-width:var(--min-width);max-width:var(--max-width);height:var(--height);min-height:var(--min-height);max-height:var(--max-height);border-width:var(--border-width);border-style:var(--border-style);border-color:var(--border-color);background:var(--background);-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow);overflow:var(--overflow);z-index:10}@media only screen and (min-width:768px) and (min-height:600px){.sc-ion-modal-md-h{--width:600px;--height:500px;--ion-safe-area-top:0px;--ion-safe-area-bottom:0px;--ion-safe-area-right:0px;--ion-safe-area-left:0px}}@media only screen and (min-width:768px) and (min-height:768px){.sc-ion-modal-md-h{--width:600px;--height:600px}}@media only screen and (min-width:768px) and (min-height:600px){.sc-ion-modal-md-h{--border-radius:2px;--box-shadow:0 28px 48px rgba(0,0,0,0.4)}}.modal-wrapper.sc-ion-modal-md{-webkit-transform:translate3d(0,40px,0);transform:translate3d(0,40px,0);opacity:.01}"},enumerable:!0,configurable:!0}),e}(),v={ionModalDidPresent:"ionViewDidEnter",ionModalWillPresent:"ionViewWillEnter",ionModalWillDismiss:"ionViewWillLeave",ionModalDidDismiss:"ionViewDidLeave"}},1178(e,n,t){t.d(n,{B:()=>A,a:()=>u,b:()=>l,c:()=>h,d:()=>y,e:()=>w,f:()=>k,g:()=>p,h:()=>v,i:()=>D,j:()=>b,k:()=>d,p:()=>f,s:()=>S});var r=t(5873),i=function(e,n,t,r){return new(t||(t=Promise))((function(i,o){function a(e){try{c(r.next(e))}catch(e){o(e)}}function s(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((r=r.apply(e,n||[])).next())}))},o=function(e,n){var t,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=n.call(e,a)}catch(e){o=[6,e],r=0}finally{t=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}},a=void 0,s=0,c=function(e){return{create:function(n){return p(e,n)},dismiss:function(n,t,r){return v(document,n,t,e,r)},getTop:function(){return i(this,void 0,void 0,(function(){return o(this,(function(n){return[2,b(document,e)]}))}))}}},l=c("ion-alert"),u=c("ion-action-sheet"),d=c("ion-picker"),f=c("ion-popover"),h=function(e){var n=document;m(n);var t=s++;e.overlayIndex=t,e.hasAttribute("id")||(e.id="ion-overlay-"+t)},p=function(e,n){return customElements.whenDefined(e).then((function(){var t=document,r=t.createElement(e);return r.classList.add("overlay-hidden"),Object.assign(r,n),g(t).appendChild(r),r.componentOnReady()}))},m=function(e){0===s&&(s=1,e.addEventListener("focusin",(function(n){var t=b(e);if(t&&t.backdropDismiss&&!P(t,n.target)){var r=t.querySelector("input,button");r&&r.focus()}})),e.addEventListener("ionBackButton",(function(n){var t=b(e);t&&t.backdropDismiss&&n.detail.register(100,(function(){return t.dismiss(void 0,A)}))})),e.addEventListener("keyup",(function(n){if("Escape"===n.key){var t=b(e);t&&t.backdropDismiss&&t.dismiss(void 0,A)}})))},v=function(e,n,t,r,i){var o=b(e,r,i);return o?o.dismiss(n,t):Promise.reject("overlay does not exist")},b=function(e,n,t){var r=function(e,n){return void 0===n&&(n="ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-picker,ion-popover,ion-toast"),Array.from(e.querySelectorAll(n)).filter((function(e){return e.overlayIndex>0}))}(e,n);return void 0===t?r[r.length-1]:r.find((function(e){return e.id===t}))},y=function(e,n,t,s,c){return i(a,void 0,void 0,(function(){var i;return o(this,(function(o){switch(o.label){case 0:return e.presented?[2]:(e.presented=!0,e.willPresent.emit(),i=e.enterAnimation?e.enterAnimation:r.i.get(n,"ios"===e.mode?t:s),[4,x(e,i,e.el,c)]);case 1:return o.sent()&&e.didPresent.emit(),[2]}}))}))},w=function(e,n,t,s,c,l,u){return i(a,void 0,void 0,(function(){var i,a;return o(this,(function(o){switch(o.label){case 0:if(!e.presented)return[2,!1];e.presented=!1,o.label=1;case 1:return o.trys.push([1,3,,4]),e.willDismiss.emit({data:n,role:t}),i=e.leaveAnimation?e.leaveAnimation:r.i.get(s,"ios"===e.mode?c:l),[4,x(e,i,e.el,u)];case 2:return o.sent(),e.didDismiss.emit({data:n,role:t}),[3,4];case 3:return a=o.sent(),console.error(a),[3,4];case 4:return e.el.remove(),[2,!0]}}))}))},g=function(e){return e.querySelector("ion-app")||e.body},x=function(e,n,s,c){return i(a,void 0,void 0,(function(){var i,a,l,u,d;return o(this,(function(o){switch(o.label){case 0:if(e.animation)return e.animation.destroy(),e.animation=void 0,[2,!1];s.classList.remove("overlay-hidden"),i=s.shadowRoot||e.el,l=!0,o.label=1;case 1:return o.trys.push([1,4,,5]),[4,t.e(1605).then(t.bind(t,1605))];case 2:return[4,o.sent().create(n,i,c)];case 3:return a=o.sent(),[3,5];case 4:return o.sent(),(a=n(i,c)).fill("both"),l=!1,[3,5];case 5:return e.animation=a,e.animated&&r.i.getBoolean("animated",!0)||a.duration(0),e.keyboardClose&&a.beforeAddWrite((function(){var e=s.ownerDocument.activeElement;e&&e.matches("input, ion-input, ion-textarea")&&e.blur()})),[4,a.playAsync()];case 6:return u=o.sent(),d=void 0===u||a.hasCompleted,l&&a.destroy(),e.animation=void 0,[2,d]}}))}))},k=function(e,n){var t,r=new Promise((function(e){return t=e}));return E(e,n,(function(e){t(e.detail)})),r},E=function(e,n,t){var r=function(i){e.removeEventListener(n,r),t(i)};e.addEventListener(n,r)},D=function(e){return"cancel"===e||e===A},P=function(e,n){for(;n;){if(n===e)return!0;n=n.parentElement}return!1},L=function(e){return e()},S=function(e,n){if("function"==typeof e)return r.i.get("_zoneGate",L)((function(){try{return e(n)}catch(e){console.error(e)}}))},A="backdrop"},636(e,n,t){t.d(n,{c:()=>i,g:()=>o,h:()=>r,o:()=>s});var r=function(e,n){return null!==n.closest(e)},i=function(e){var n;return"string"==typeof e&&e.length>0?((n={"ion-color":!0})["ion-color-"+e]=!0,n):void 0},o=function(e){var n={};return function(e){return void 0!==e?(Array.isArray(e)?e:e.split(" ")).filter((function(e){return null!=e})).map((function(e){return e.trim()})).filter((function(e){return""!==e})):[]}(e).forEach((function(e){return n[e]=!0})),n},a=/^[a-z][a-z0-9+\-.]*:/,s=function(e,n,t){return r=void 0,i=void 0,s=function(){var r;return function(e,n){var t,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!((i=(i=a.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=n.call(e,a)}catch(e){o=[6,e],r=0}finally{t=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}(this,(function(i){return null!=e&&"#"!==e[0]&&!a.test(e)&&(r=document.querySelector("ion-router"))?(null!=n&&n.preventDefault(),[2,r.push(e,t)]):[2,!1]}))},new((o=void 0)||(o=Promise))((function(e,n){function t(e){try{c(s.next(e))}catch(e){n(e)}}function a(e){try{c(s.throw(e))}catch(e){n(e)}}function c(n){n.done?e(n.value):new o((function(e){e(n.value)})).then(t,a)}c((s=s.apply(r,i||[])).next())}));var r,i,o,s}}}]);